diff options
| author | Dustin Mierau <dustin@mierau.me> | 2025-11-14 09:56:46 -0800 |
|---|---|---|
| committer | Dustin Mierau <dustin@mierau.me> | 2025-11-14 09:56:46 -0800 |
| commit | da1d7001f5132115bfdbe19cd95e73b04ba76c95 (patch) | |
| tree | ba9b446db9a15e4b32d9101be518bdf65ac105a2 /Hotline/macOS/UserClientInfoSheet.swift | |
| parent | 46384d99b78cca150aa720eb915d161b5be8c08d (diff) | |
Add kick and improve client info display. Also improve error messages when can't connect (server down) or can't login (show server message).
Diffstat (limited to 'Hotline/macOS/UserClientInfoSheet.swift')
| -rw-r--r-- | Hotline/macOS/UserClientInfoSheet.swift | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/Hotline/macOS/UserClientInfoSheet.swift b/Hotline/macOS/UserClientInfoSheet.swift new file mode 100644 index 0000000..8fa4db8 --- /dev/null +++ b/Hotline/macOS/UserClientInfoSheet.swift @@ -0,0 +1,25 @@ +import SwiftUI + +struct UserClientInfoSheet: View { + @Environment(\.dismiss) private var dismiss + + let info: HotlineUserClientInfo + + var body: some View { + ScrollView(.vertical) { + Text(self.info.details) + .fontDesign(.monospaced) + .textSelection(.enabled) + .frame(maxWidth: .infinity, alignment: .topLeading) + .padding() + } + .frame(width: 350, height: 400) + .toolbar { + ToolbarItem(placement: .confirmationAction) { + Button("OK") { + self.dismiss() + } + } + } + } +} |