diff --git a/TheNoiseClock/Views/Alarms/AddAlarmView.swift b/TheNoiseClock/Views/Alarms/AddAlarmView.swift index ba3d642..9784ebc 100644 --- a/TheNoiseClock/Views/Alarms/AddAlarmView.swift +++ b/TheNoiseClock/Views/Alarms/AddAlarmView.swift @@ -29,57 +29,47 @@ struct AddAlarmView: View { TimePickerSection(selectedTime: $newAlarmTime) TimeUntilAlarmSection(alarmTime: newAlarmTime) - LazyVStack(spacing: 0) { + List { // Label Section NavigationLink(destination: LabelEditView(label: $alarmLabel)) { HStack { Image(systemName: "textformat") - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) .frame(width: 24) Text("Label") Spacer() Text(alarmLabel) .foregroundColor(.secondary) } - .padding() - .background(Color(.systemGroupedBackground)) } - .buttonStyle(PlainButtonStyle()) // Sound Section NavigationLink(destination: SoundSelectionView(selectedSound: $selectedSoundName)) { HStack { Image(systemName: "music.note") - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) .frame(width: 24) Text("Sound") Spacer() Text(getSoundDisplayName(selectedSoundName)) .foregroundColor(.secondary) } - .padding() - .background(Color(.systemGroupedBackground)) } - .buttonStyle(PlainButtonStyle()) // Snooze Section NavigationLink(destination: SnoozeSelectionView(snoozeDuration: $snoozeDuration)) { HStack { Image(systemName: "clock.arrow.circlepath") - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) .frame(width: 24) Text("Snooze") Spacer() Text("for \(snoozeDuration) min") .foregroundColor(.secondary) } - .padding() - .background(Color(.systemGroupedBackground)) } - .buttonStyle(PlainButtonStyle()) } - .cornerRadius(10) - .padding(.horizontal) + .listStyle(.insetGrouped) } } .navigationTitle("Alarm") @@ -90,7 +80,7 @@ struct AddAlarmView: View { Button("Cancel") { isPresented = false } - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) } ToolbarItem(placement: .navigationBarTrailing) { @@ -109,7 +99,7 @@ struct AddAlarmView: View { isPresented = false } } - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) .fontWeight(.semibold) } } diff --git a/TheNoiseClock/Views/Alarms/Components/LabelEditView.swift b/TheNoiseClock/Views/Alarms/Components/LabelEditView.swift index 1508c3f..20a0b5a 100644 --- a/TheNoiseClock/Views/Alarms/Components/LabelEditView.swift +++ b/TheNoiseClock/Views/Alarms/Components/LabelEditView.swift @@ -13,14 +13,15 @@ struct LabelEditView: View { @Environment(\.dismiss) private var dismiss var body: some View { - VStack(spacing: 20) { + VStack(spacing: UIConstants.Spacing.large) { TextField("Alarm Label", text: $label) .textFieldStyle(RoundedBorderTextFieldStyle()) - .padding() + .contentPadding(horizontal: UIConstants.Spacing.large) Spacer() } .navigationTitle("Label") .navigationBarTitleDisplayMode(.inline) + .contentPadding(vertical: UIConstants.Spacing.large) } } diff --git a/TheNoiseClock/Views/Alarms/Components/SnoozeSelectionView.swift b/TheNoiseClock/Views/Alarms/Components/SnoozeSelectionView.swift index 2f4f715..8bded51 100644 --- a/TheNoiseClock/Views/Alarms/Components/SnoozeSelectionView.swift +++ b/TheNoiseClock/Views/Alarms/Components/SnoozeSelectionView.swift @@ -23,7 +23,7 @@ struct SnoozeSelectionView: View { Spacer() if snoozeDuration == duration { Image(systemName: "checkmark") - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) } } .contentShape(Rectangle()) diff --git a/TheNoiseClock/Views/Alarms/Components/SoundSelectionView.swift b/TheNoiseClock/Views/Alarms/Components/SoundSelectionView.swift index 65fc82c..d7f7de7 100644 --- a/TheNoiseClock/Views/Alarms/Components/SoundSelectionView.swift +++ b/TheNoiseClock/Views/Alarms/Components/SoundSelectionView.swift @@ -29,7 +29,7 @@ struct SoundSelectionView: View { Spacer() if selectedSound == sound.fileName { Image(systemName: "checkmark") - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) } } .contentShape(Rectangle()) @@ -55,7 +55,7 @@ struct SoundSelectionView: View { } }) { Image(systemName: isPlaying && currentlyPlayingSound == selectedSound ? "stop.fill" : "play.fill") - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) } } } diff --git a/TheNoiseClock/Views/Alarms/Components/TimeUntilAlarmSection.swift b/TheNoiseClock/Views/Alarms/Components/TimeUntilAlarmSection.swift index 1ba54d2..bde57bd 100644 --- a/TheNoiseClock/Views/Alarms/Components/TimeUntilAlarmSection.swift +++ b/TheNoiseClock/Views/Alarms/Components/TimeUntilAlarmSection.swift @@ -15,7 +15,7 @@ struct TimeUntilAlarmSection: View { VStack(spacing: 4) { HStack { Image(systemName: "calendar") - .foregroundColor(.orange) + .foregroundColor(UIConstants.Colors.accentColor) Text(timeUntilAlarm) .font(.subheadline) .foregroundColor(.secondary)