From 161487aa164c6fd887c2b6be2a9693c98d44e8a1 Mon Sep 17 00:00:00 2001 From: Michael Freno Date: Sun, 11 Jan 2026 11:42:07 -0500 Subject: [PATCH] general: aesthetic matching --- Gaze/Extensions/ViewExtensions.swift | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/Gaze/Extensions/ViewExtensions.swift b/Gaze/Extensions/ViewExtensions.swift index f5d622a..6ebb400 100644 --- a/Gaze/Extensions/ViewExtensions.swift +++ b/Gaze/Extensions/ViewExtensions.swift @@ -8,7 +8,6 @@ import SwiftUI extension View { - /// Applies a glass effect on macOS 26.0+, with a fallback visual treatment for earlier versions @ViewBuilder func glassEffectIfAvailable( _ style: GlassStyle, @@ -19,17 +18,24 @@ extension View { } else { self.background { shape - .fill(.ultraThinMaterial) + .fill( + style.tintColor ?? .white + ) + .overlay( + shape + .stroke( + (style.tintColor ?? .white).opacity(0.2), + lineWidth: 1 + ) + ) .shadow(color: .black.opacity(0.1), radius: 4, x: 0, y: 2) } } } } -// MARK: - GlassStyle Wrapper -/// Cross-version wrapper for glass effect styling struct GlassStyle { - private let tintColor: Color? + let tintColor: Color? private let isInteractive: Bool static let regular = GlassStyle(tintColor: nil, isInteractive: false)