This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// CircularProgressBarView.swift | |
// FastingTimer | |
// | |
// Created by Mykola Harmash on 09.08.25. | |
// | |
import SwiftUI | |
struct CircularProgressBarView: View { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// ParticlesView.swift | |
// | |
// Created by Mykola Harmash on 14.07.25. | |
// | |
import SwiftUI | |
fileprivate struct Particle { | |
let birthDate: Date = .now |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// A Color Slider that is similar to one in | |
// iOS 18+ when configuring a tinted Home Screen | |
// Full video-walktrough on building this component: https://youtu.be/VFVyN5hNW24 | |
import SwiftUI | |
fileprivate let SLIDER_HEIGHT = 34.0 | |
fileprivate let KNOB_DIAMETER = SLIDER_HEIGHT + 4.0 | |
struct ColorSlider: View { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
struct CounterView: View { | |
@State var count = 0 | |
var body: some View { | |
Text(String(count)) | |
Button("+ 1", action: { count = count + 1 }) | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
class Counter: ObservableObject { | |
@Published var count: Int | |
init(_ count: Int) { | |
self.count = count | |
} | |
func increment() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
class Counter: ObservableObject { | |
@Published var count: Int | |
init(_ count: Int) { | |
self.count = count | |
} | |
func increment() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
class Counter: ObservableObject { | |
@Published var count: Int | |
init(_ count: Int) { | |
self.count = count | |
} | |
func increment() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
class Counter { | |
var count: Int | |
init(_ count: Int) { | |
self.count = count | |
} | |
func increment() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
class Counter { | |
var count: Int | |
init(_ count: Int) { | |
self.count = count | |
} | |
func increment() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
struct Counter: View { | |
@State var count: Int = 0 | |
init() { | |
print("Counter Created") | |
} | |
var body: some View { |
NewerOlder