diff --git a/bitchat/Views/LocationChannelsSheet.swift b/bitchat/Views/LocationChannelsSheet.swift index 8c95ce92..80a9c0e4 100644 --- a/bitchat/Views/LocationChannelsSheet.swift +++ b/bitchat/Views/LocationChannelsSheet.swift @@ -93,7 +93,7 @@ struct LocationChannelsSheet: View { private var channelList: some View { List { // Mesh option first - channelRow(title: meshTitleWithCount(), subtitle: "#bluetooth", isSelected: isMeshSelected, titleColor: standardBlue) { + channelRow(title: meshTitleWithCount(), subtitle: "#bluetooth • \(bluetoothRangeString())", isSelected: isMeshSelected, titleColor: standardBlue) { manager.select(ChannelID.mesh) isPresented = false } @@ -336,6 +336,18 @@ extension LocationChannelsSheet { return String(format: "%.1f", value) } + private func bluetoothRangeString() -> String { + let usesMetric: Bool = { + if #available(iOS 16.0, *) { + return Locale.current.measurementSystem == .metric + } else { + return Locale.current.usesMetricSystem + } + }() + // Approximate Bluetooth LE range for typical mobile devices; environment dependent + return usesMetric ? "~10–50 m" : "~30–160 ft" + } + private func locationName(for level: GeohashChannelLevel) -> String? { manager.locationNames[level] }