Explorar el Código

Change button role for dual confirmation dialog in home view

Deniz Cengiz hace 1 año
padre
commit
98eae93066
Se han modificado 1 ficheros con 3 adiciones y 3 borrados
  1. 3 3
      FreeAPS/Sources/Modules/Home/View/HomeRootView.swift

+ 3 - 3
FreeAPS/Sources/Modules/Home/View/HomeRootView.swift

@@ -670,14 +670,14 @@ extension Home {
                             .foregroundStyle(Color.clear)
                     }
                 }.padding(.horizontal, 10)
-                    .confirmationDialog("Adjustment to Cancel", isPresented: $showCancelConfirmDialog) {
-                        Button("Stop Override") {
+                    .confirmationDialog("Adjustment to Stop", isPresented: $showCancelConfirmDialog) {
+                        Button("Stop Override", role: .destructive) {
                             Task {
                                 guard let objectID = latestOverride.first?.objectID else { return }
                                 await state.cancelOverride(withID: objectID)
                             }
                         }
-                        Button("Stop Temp Target") {
+                        Button("Stop Temp Target", role: .destructive) {
                             Task {
                                 guard let objectID = latestTempTarget.first?.objectID else { return }
                                 await state.cancelTempTarget(withID: objectID)