diff --git a/IceCubesApp/App/IceCubesApp.swift b/IceCubesApp/App/IceCubesApp.swift index 5158d9b9..e8c00546 100644 --- a/IceCubesApp/App/IceCubesApp.swift +++ b/IceCubesApp/App/IceCubesApp.swift @@ -11,7 +11,7 @@ struct IceCubesApp: App { @Environment(\.scenePhase) private var scenePhase @StateObject private var appAccountsManager = AppAccountsManager() - @StateObject private var currenInstance = CurrentInstance() + @StateObject private var currentInstance = CurrentInstance() @StateObject private var currentAccount = CurrentAccount() @StateObject private var watcher = StreamWatcher() @StateObject private var quickLook = QuickLook() @@ -54,7 +54,7 @@ struct IceCubesApp: App { .environmentObject(appAccountsManager.currentClient) .environmentObject(quickLook) .environmentObject(currentAccount) - .environmentObject(currenInstance) + .environmentObject(currentInstance) .environmentObject(theme) .environmentObject(watcher) .quickLookPreview($quickLook.url, in: quickLook.urls) @@ -75,7 +75,7 @@ struct IceCubesApp: App { private func setNewClientsInEnv(client: Client) { currentAccount.setClient(client: client) - currenInstance.setClient(client: client) + currentInstance.setClient(client: client) watcher.setClient(client: client) } diff --git a/IceCubesApp/App/Tabs/TimelineTab.swift b/IceCubesApp/App/Tabs/TimelineTab.swift index 13ca6d0d..894c1453 100644 --- a/IceCubesApp/App/Tabs/TimelineTab.swift +++ b/IceCubesApp/App/Tabs/TimelineTab.swift @@ -23,7 +23,7 @@ struct TimelineTab: View { .withAppRouteur() .withSheetDestinations(sheetDestinations: $routeurPath.presentedSheet) .toolbar { - ToolbarItem(placement: .principal) { + ToolbarTitleMenu { timelineFilterButton } if client.isAuth { @@ -60,27 +60,13 @@ struct TimelineTab: View { private var timelineFilterButton: some View { - Menu { - ForEach(TimelineFilter.availableTimeline(client: client), id: \.self) { timeline in - Button { - self.timeline = timeline - } label: { - Label(timeline.title(), systemImage: timeline.iconName() ?? "") - } + ForEach(TimelineFilter.availableTimeline(client: client), id: \.self) { timeline in + Button { + self.timeline = timeline + } label: { + Label(timeline.title(), systemImage: timeline.iconName() ?? "") } - } label: { - HStack { - Text(timeline.title()) - Image(systemName: "chevron.down") - .resizable() - .aspectRatio(contentMode: .fit) - .frame(width: 12) - .offset(y: 2) - } - .font(.headline) - .foregroundColor(theme.labelColor) } - .menuStyle(.button) } private var accountButton: some View {