From ee4ce4a38eed4ee4ba8e65a084057890185df50e Mon Sep 17 00:00:00 2001 From: jack Date: Sat, 13 Sep 2025 22:02:56 +0200 Subject: [PATCH] UI: replace textual 'close' with X icon\n\n- AppInfoView (iOS): use xmark icon in nav bar to match Location Notes style.\n- LocationChannelsSheet: use xmark icon for close on iOS/macOS toolbars; add accessibility label. --- bitchat/Views/AppInfoView.swift | 10 +++++++--- bitchat/Views/LocationChannelsSheet.swift | 18 ++++++++++++++---- 2 files changed, 21 insertions(+), 7 deletions(-) diff --git a/bitchat/Views/AppInfoView.swift b/bitchat/Views/AppInfoView.swift index fe03c57f..c8a4e779 100644 --- a/bitchat/Views/AppInfoView.swift +++ b/bitchat/Views/AppInfoView.swift @@ -86,10 +86,14 @@ struct AppInfoView: View { .navigationBarTitleDisplayMode(.inline) .toolbar { ToolbarItem(placement: .navigationBarTrailing) { - Button("close") { - dismiss() + Button(action: { dismiss() }) { + Image(systemName: "xmark") + .font(.system(size: 13, weight: .semibold, design: .monospaced)) + .foregroundColor(textColor) + .frame(width: 32, height: 32) } - .foregroundColor(textColor) + .buttonStyle(.plain) + .accessibilityLabel("Close") } } } diff --git a/bitchat/Views/LocationChannelsSheet.swift b/bitchat/Views/LocationChannelsSheet.swift index 162bff2e..705cd178 100644 --- a/bitchat/Views/LocationChannelsSheet.swift +++ b/bitchat/Views/LocationChannelsSheet.swift @@ -58,15 +58,25 @@ struct LocationChannelsSheet: View { .navigationBarTitleDisplayMode(.inline) .toolbar { ToolbarItem(placement: .navigationBarTrailing) { - Button("close") { isPresented = false } - .font(.system(size: 14, design: .monospaced)) + Button(action: { isPresented = false }) { + Image(systemName: "xmark") + .font(.system(size: 13, weight: .semibold, design: .monospaced)) + .frame(width: 32, height: 32) + } + .buttonStyle(.plain) + .accessibilityLabel("Close") } } #else .toolbar { ToolbarItem(placement: .automatic) { - Button("close") { isPresented = false } - .font(.system(size: 14, design: .monospaced)) + Button(action: { isPresented = false }) { + Image(systemName: "xmark") + .font(.system(size: 13, weight: .semibold, design: .monospaced)) + .frame(width: 20, height: 20) + } + .buttonStyle(.plain) + .accessibilityLabel("Close") } } #endif