another.im-ios/ConversationsClassic/UIToolkit/View+Flip.swift
2024-08-19 00:11:30 +02:00

16 lines
309 B
Swift

import SwiftUI
struct FlipView: ViewModifier {
func body(content: Content) -> some View {
content
.rotationEffect(.radians(Double.pi))
.scaleEffect(x: -1, y: 1, anchor: .center)
}
}
extension View {
func flip() -> some View {
modifier(FlipView())
}
}