This file contains 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 Foundation | |
import CoreText | |
import SwiftUI | |
import PlaygroundSupport | |
typealias VoidHandler = @convention(block) () -> Void | |
@objc | |
protocol X { |
This file contains 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
//Button scaling animation test | |
//Supporting GIST for https://stackoverflow.com/a/73637703/3970488 | |
import SwiftUI | |
import PlaygroundSupport | |
/// An animatable modifier that is used for observing animations for a given animatable value. | |
public struct AnimationCompletionObserverModifier<Value>: AnimatableModifier where Value: VectorArithmetic { | |
/// While animating, SwiftUI changes the old input value to the new target value using this property. This value is set to the old value until the animation completes. | |
public var animatableData: Value { |
This file contains 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
// "b" > "a" | |
// "3" > "1" | |
// "ac" > "ab" | |
// "32" > "25" | |
// "abcd1" > "abc2" | |
// "abc123a" > "abc2a" | |
// "abc123a" < "abc1234a" | |
// "abc123" < "abc123a" | |
// "abc12a49" > "abc12a39" | |
// "123ab3" = "123ab3" |