mirror of
https://github.com/yattee/yattee.git
synced 2024-12-14 14:20:32 +05:30
17 lines
336 B
Swift
17 lines
336 B
Swift
import Foundation
|
|
import SwiftUI
|
|
|
|
struct ControlBackgroundModifier: ViewModifier {
|
|
var enabled = true
|
|
var edgesIgnoringSafeArea = Edge.Set()
|
|
|
|
func body(content: Content) -> some View {
|
|
if enabled {
|
|
content
|
|
.background(.thinMaterial)
|
|
} else {
|
|
content
|
|
}
|
|
}
|
|
}
|