refactor(ios): dedupe status, gateway, and service flows

This commit is contained in:
Peter Steinberger
2026-03-02 11:32:00 +00:00
parent 2ca5722221
commit cd011897d0
19 changed files with 334 additions and 626 deletions

View File

@@ -0,0 +1,25 @@
import SwiftUI
extension View {
func gatewayActionsDialog(
isPresented: Binding<Bool>,
onDisconnect: @escaping () -> Void,
onOpenSettings: @escaping () -> Void) -> some View
{
self.confirmationDialog(
"Gateway",
isPresented: isPresented,
titleVisibility: .visible)
{
Button("Disconnect", role: .destructive) {
onDisconnect()
}
Button("Open Settings") {
onOpenSettings()
}
Button("Cancel", role: .cancel) {}
} message: {
Text("Disconnect from the gateway?")
}
}
}