Rotate

struct Rotate : GeometryEffect, @unchecked Sendable

The rotate animation

Note

A ‘GeometryEffect’ instead of a simple animation so we can observe it
  • Do we want to rotate or not?

    Declaration

    Swift

    var rotate: Bool
  • A flip/flop when a rotation is completed

    Declaration

    Swift

    @Binding
    var status: Bool { get nonmutating set }
  • The percentage of the animation

    Declaration

    Swift

    var percent: Double
  • The animation data

    Declaration

    Swift

    var animatableData: Double { get set }
  • Init the struct

    Declaration

    Swift

    init(rotate: Bool, status: Binding<Bool>)
  • The rotating effect

    Declaration

    Swift

    func effectValue(size: CGSize) -> ProjectionTransform