From 0e388c6a21aa007863afc67333fd60caeca20b67 Mon Sep 17 00:00:00 2001 From: Laurent Date: Fri, 10 Mar 2023 16:47:03 +0100 Subject: [PATCH] look and feel --- .../Views/Countdown/CountdownDialView.swift | 6 +++- LeCountdown/Views/DialView.swift | 34 ++----------------- .../Views/Stopwatch/StopwatchDialView.swift | 2 +- LeCountdown/Views/TimersView.swift | 2 +- 4 files changed, 9 insertions(+), 35 deletions(-) diff --git a/LeCountdown/Views/Countdown/CountdownDialView.swift b/LeCountdown/Views/Countdown/CountdownDialView.swift index 0d2892e..ecec531 100644 --- a/LeCountdown/Views/Countdown/CountdownDialView.swift +++ b/LeCountdown/Views/Countdown/CountdownDialView.swift @@ -17,8 +17,12 @@ struct CountdownDialView: View { HStack { VStack(alignment: .leading) { - Text(countdown.activity?.name?.uppercased() ?? "").multilineTextAlignment(.leading) + Text(countdown.activity?.name?.uppercased() ?? "") + .foregroundColor(.black) + .multilineTextAlignment(.leading) Text(countdown.duration.minuteSecond) + .fontWeight(.semibold) + .foregroundColor(.accentColor) } Spacer() } diff --git a/LeCountdown/Views/DialView.swift b/LeCountdown/Views/DialView.swift index 99b9dfc..5ce60a9 100644 --- a/LeCountdown/Views/DialView.swift +++ b/LeCountdown/Views/DialView.swift @@ -24,10 +24,6 @@ struct DialView: View { var body: some View { ZStack { - Image(self.timer.imageName) - .resizable() - .saturation(self.isEditingBinding.wrappedValue ? 0.0 : 1.0) - switch self.isEditingBinding.wrappedValue { case false: Button { @@ -50,38 +46,12 @@ struct DialView: View { Spacer() } } - -// VStack { -// Spacer() -// self._dialView().padding(.horizontal) -// Spacer() -// } -// -// HStack { -// Spacer() -// NavigationLink { -// self._editView(timer: timer, isPresented: $boringContext.isShowingNewData) -// } label: { -// Image(systemName: "gearshape.fill") -// .font(.system(size: 30.0)) -// .padding(.horizontal) -// .foregroundColor(Color.accentColor) -// } -// } } } + .background(Color(white: 0.95)) .frame(width: frameSize, height: 80.0) .cornerRadius(20.0) -// .alert("Make sure your device is not on silent mode", isPresented: $showSilentModeAlert) { -// Button("OK", role: .cancel) { -// self._launchTimer() -// } -// Button("Don't show this again", role: .destructive) { -// self._launchTimer() -// Preferences.hideSilentModeAlerts(true) -// } -// } } @ViewBuilder @@ -102,7 +72,7 @@ struct DialView: View { } } .monospaced() - .font(Font.system(size: 16.0, weight: .semibold)) + .font(.system(size: 16.0)) .foregroundColor(Color.white) } diff --git a/LeCountdown/Views/Stopwatch/StopwatchDialView.swift b/LeCountdown/Views/Stopwatch/StopwatchDialView.swift index d26f664..19dff92 100644 --- a/LeCountdown/Views/Stopwatch/StopwatchDialView.swift +++ b/LeCountdown/Views/Stopwatch/StopwatchDialView.swift @@ -15,7 +15,7 @@ struct StopwatchDialView: View { var body: some View { HStack { - Text(stopwatch.activity?.name?.uppercased() ?? "") + Text(stopwatch.activity?.name?.uppercased() ?? "").foregroundColor(.black) Spacer() } } diff --git a/LeCountdown/Views/TimersView.swift b/LeCountdown/Views/TimersView.swift index 353a9bc..ae1a8d4 100644 --- a/LeCountdown/Views/TimersView.swift +++ b/LeCountdown/Views/TimersView.swift @@ -27,7 +27,7 @@ struct TimersView: View { GeometryReader { reader in let columns: [GridItem] = self._columns() - let width: CGFloat = reader.size.width / CGFloat(columns.count) - 15.0 + let width: CGFloat = reader.size.width / CGFloat(columns.count) - 5.0 let abstractTimers: [AbstractTimer] = Array(self.timers) if abstractTimers.count > 0 {