From 83fa9a73f6a05bbe5062f07509f3629dad4ffd3d Mon Sep 17 00:00:00 2001 From: Garth Vander Houwen Date: Tue, 15 Jul 2025 15:08:14 -0700 Subject: [PATCH] Pass router to each tab in the content view --- Meshtastic/Views/Bluetooth/Connect.swift | 1 + Meshtastic/Views/ContentView.swift | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Meshtastic/Views/Bluetooth/Connect.swift b/Meshtastic/Views/Bluetooth/Connect.swift index 284eba62..8d154d8a 100644 --- a/Meshtastic/Views/Bluetooth/Connect.swift +++ b/Meshtastic/Views/Bluetooth/Connect.swift @@ -20,6 +20,7 @@ struct Connect: View { @Environment(\.managedObjectContext) var context @EnvironmentObject var bleManager: BLEManager + @ObservedObject var router: Router @State var node: NodeInfoEntity? @State var isUnsetRegion = false @State var invalidFirmwareVersion = false diff --git a/Meshtastic/Views/ContentView.swift b/Meshtastic/Views/ContentView.swift index 05f227b5..d57a0792 100644 --- a/Meshtastic/Views/ContentView.swift +++ b/Meshtastic/Views/ContentView.swift @@ -29,7 +29,9 @@ struct ContentView: View { .tag(NavigationState.Tab.messages) .badge(appState.totalUnreadMessages) - Connect() + Connect( + router: appState.router + ) .tabItem { Label("Bluetooth", systemImage: "antenna.radiowaves.left.and.right") }