From 75f8850115ced2fa5ff88d7d662e9edcedad1ec7 Mon Sep 17 00:00:00 2001 From: Rafal Kolarz Date: Fri, 23 Oct 2026 01:56:51 +0100 Subject: [PATCH] Add liquid glass highlights to wallet cards --- Kasztelan.xcodeproj/project.pbxproj | 4 +-- Kasztelan/Theme.swift | 41 +++++++++++++++++++++++++++-- 2 files changed, 41 insertions(+), 4 deletions(-) diff --git a/Kasztelan.xcodeproj/project.pbxproj b/Kasztelan.xcodeproj/project.pbxproj index 6f4fa3c..e06660e 100644 --- a/Kasztelan.xcodeproj/project.pbxproj +++ b/Kasztelan.xcodeproj/project.pbxproj @@ -292,7 +292,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 15; + CURRENT_PROJECT_VERSION = 16; GENERATE_INFOPLIST_FILE = NO; INFOPLIST_FILE = Kasztelan/Info.plist; INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.food-and-drink"; @@ -316,7 +316,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 15; + CURRENT_PROJECT_VERSION = 16; GENERATE_INFOPLIST_FILE = NO; INFOPLIST_FILE = Kasztelan/Info.plist; INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.food-and-drink"; diff --git a/Kasztelan/Theme.swift b/Kasztelan/Theme.swift index 5eac3c1..a7a71fc 100644 --- a/Kasztelan/Theme.swift +++ b/Kasztelan/Theme.swift @@ -81,17 +81,54 @@ struct GlassDepthDeck: View { .shadow(color: KTheme.purple.opacity(0.30), radius: 24, x: -8, y: 8) .shadow(color: KTheme.pink.opacity(0.30), radius: 20, x: 10, y: 4) + RoundedRectangle(cornerRadius: cornerRadius, style: .continuous) + .fill( + LinearGradient( + colors: [.white.opacity(0.20), .clear, .clear, .black.opacity(0.12)], + startPoint: .topLeading, + endPoint: .bottomTrailing + ) + ) + .allowsHitTesting(false) + RoundedRectangle(cornerRadius: cornerRadius, style: .continuous) .stroke( LinearGradient( - colors: [.white.opacity(0.76), .white.opacity(0.10), KTheme.purple.opacity(0.46)], + colors: [.white.opacity(0.92), .white.opacity(0.18), KTheme.purple.opacity(0.52)], startPoint: .topLeading, endPoint: .bottomTrailing ), - lineWidth: 1.6 + lineWidth: 2.2 ) .allowsHitTesting(false) + + RoundedRectangle(cornerRadius: cornerRadius - 3, style: .continuous) + .inset(by: 3) + .stroke( + LinearGradient( + colors: [.white.opacity(0.34), .clear, .black.opacity(0.28)], + startPoint: .top, + endPoint: .bottom + ), + lineWidth: 1 + ) + .allowsHitTesting(false) + + VStack { + HStack { + Capsule() + .fill(.white.opacity(0.58)) + .frame(width: 112, height: 4) + .blur(radius: 0.6) + .padding(.top, 8) + .padding(.leading, 22) + Spacer() + } + Spacer() + } + .allowsHitTesting(false) } + .compositingGroup() .padding(.bottom, 20) } }