Improve translucency effect

This commit is contained in:
Arkadiusz Fal
2022-08-06 15:26:59 +02:00
parent 2fd96e3a44
commit 8318b4c5fb
3 changed files with 18 additions and 26 deletions

View File

@@ -114,7 +114,7 @@ struct ControlsOverlay: View {
StreamControl()
.frame(width: 45, height: 30)
#if os(iOS)
.background(VisualEffectBlur(blurStyle: .systemThinMaterial))
.modifier(ControlBackgroundModifier())
#endif
.mask(RoundedRectangle(cornerRadius: 3))
} label: {
@@ -127,12 +127,8 @@ struct ControlsOverlay: View {
.buttonStyle(.plain)
.foregroundColor(.primary)
.frame(width: 140, height: 30)
#if os(macOS)
.background(VisualEffectBlur(material: .hudWindow))
#elseif os(iOS)
.background(VisualEffectBlur(blurStyle: .systemThinMaterial))
#endif
.mask(RoundedRectangle(cornerRadius: 3))
.modifier(ControlBackgroundModifier())
.mask(RoundedRectangle(cornerRadius: 3))
#endif
}