411 questions
1
vote
1
answer
105
views
SwiftUI iOS 26 TabView: Background gets added on scrollable content
I'm rather new to SwiftUI developing and started developing an App for our company earlier this year. I decided to have look on the new iOS and be sure the app doesn't break with it. Now I'm ...
1
vote
2
answers
76
views
ios SwiftUI tabbview overflow "more" page background color
Is there a way to set the background color for the generated "overflow" "more" page for when you have lots of tabs in TabView?
SwiftUI iOS
9
votes
4
answers
996
views
SwiftUI's tabViewBottomAccessory - bug in conditionally showing/hiding it?
We use SwiftUI's tabViewBottomAccessory in our iOS apps for displaying an Audio MiniPlayer View (like in the Apple Music App).
TabView(selection: $viewModel.selectedTab) {
// Tabs here
}
....
1
vote
0
answers
119
views
How can I fix the broken layout with a ScrollView inside a TabView that is inside a NavigationStack in SwiftUI?
I'd like to achieve a layout similar to the one shown in the Apple Fitness app. When I insert a ScrollView into a TabView, everything works fine, but if I try to add a NavigationStack to wrap the ...
1
vote
1
answer
94
views
How to "unfill" the SF- Symbols inside the TabView [closed]
The SF- Symbols inside the TabView are in my case always displayed filled.
Meaning instead of showing book, it shows book.fill.
Is there a way to display the "unfilled" version of the symbol?...
0
votes
1
answer
58
views
iPad layout shift hiding the tab bar after navigation
In SwiftUI, I have a layout shift bug. Here's a code sample that reproduces the issue.
struct ContentView: View {
var body: some View {
TabView {
Tab("Home", ...
0
votes
1
answer
92
views
How to make Custom TabBar with curved selected tab that stays?
I’m new to SwiftUI and have completed half of my TabBar UI. However, I’m stuck on adding an outer corner to the selected tab.
This is what I currently have:
This is what I'm tring to do:
Below is my ...
0
votes
1
answer
274
views
SwiftUI Full Cover of Screen With TabView Not Working
I am attempting to cover the entire screen (iPad and iPhone) while using a TabView, but there always remains the bottom strip that is not covered.
struct CoverTestApp: App {
var body: some Scene {
...
0
votes
1
answer
445
views
How to hide `TabViewBottomAccessory` when drilling down?
I would like to conditionally render TabViewBottomAccessory because I don't want to show it when I am drilling down. When going to the child view I want to hide both tab view (which I achieved by ....
1
vote
0
answers
140
views
iOS 26: .tabViewBottomAccessory - How to open a new view on the tabViewBottomAccessory
If you are currently on the beta of iOS 26, open Apple Music and you'll see a tabViewBottomAccessory that is the mini NowPlayingView. When tapped, it opens the NowPlayingView. Is there a similar way ...
0
votes
0
answers
1k
views
How to use iOS 26 .tabViewBottomAccessory with nested TabViews
I'm trying to use .tabViewBottomAccessory introduced in iOS 26 to have an audio bar that exists throughout my entire app. The problem I'm having is that I have some nested TabViews, which seems to ...
0
votes
0
answers
40
views
Why Tab in settings view under chevron is disabled?
If the window width is not enough to display all the tabs, then some may be hidden by the arrow.
I have exactly this situation. But the problem is that the hidden tab turns out to be inactive/...
3
votes
2
answers
2k
views
Liquid Glass bar above tab view like the Apple Music app?
Apple's new iOS 26 Liquid Glass design language includes a bar that floats above the new tab bar.
Seen here in the Music app:
As you scroll, the bar elegantly flows down into the tab bar space, which ...
2
votes
1
answer
395
views
Adopting both NavigationSplitView and TabView depending on Window/Screen Width [closed]
I’m building a Files-style SwiftUI app and my primary goal is to adopt both:
NavigationSplitView on wider (regular) widths (iPad/macOS), and
TabView + NavigationStack on narrow (compact) widths (...
14
votes
3
answers
21k
views
How to implement iOS 26 Liquid Glass tab bar with separate floating action button?
Apple's iOS 26 "Liquid Glass" introduces a new UI paradigm of a tab bar with a separate floating action button off to the side. This seems to be a common UI design used in many of Apple's ...
0
votes
2
answers
105
views
SwiftUI - Control Tabview State from Controller
I am trying to drive programatic changes to the tab state of a TabView from a coordinator. The tabview works and changes state when I click a new tab, but does not work when I change the state in the ...
0
votes
0
answers
115
views
How to maintain scroll position across tabs and rotation in SwiftUI?
I have a view called SurahView. In this view, I need 2 modes: translation and reading.
In the translation mode, I have a series of verses with both the Arabic text and English text for each verse.
In ...
1
vote
0
answers
62
views
How can I show the parent view without dismissing the child view pushed by a NavigationLink inside a TabView?
File: ContentView
struct ContentView: View {
var body: some View {
TabView {
ListView()
.tabItem {
Image(systemName: "book")
}
}...
0
votes
1
answer
80
views
SwiftUI - How to set color scheme only for specific tabs in TabView?
I have a TabView with two tabs, and I want the first tab to have color scheme of light and the second tab to have color scheme of dark.
I've tried this:
struct ContentView: View {
var body: some ...
1
vote
0
answers
110
views
Hiding tab bar on iOS 18 when pushing screens with NavigationStack animation glitch
Given that on iPadOS 18 the TabBar is on the top, and I need to hide/show it based on push/pop a view to/from a NavigationStack I am experiencing a weird animation glitch.
This question is similar an ...
1
vote
1
answer
104
views
How can I use animation in a TabView for an onboarding flow?
I'm trying to create an animated onboarding experience where the content of each tab animates when it appears. My code does work as intended when swiping between tabs:
However, it behaves ...
4
votes
1
answer
325
views
Hiding new tab view in iOS 18 when pushing screens
With iOS 18 Apple decided to move our beloved bottom tab bar controller to the top of the screen (apparently thats more modern). I am having the following situation: I have TabView where we have root ...
0
votes
1
answer
277
views
SwiftUI TabView hidden tabbar navigation stack animation order issue
I am having the following view:
import SwiftUI
struct HiddenTabs: View {
var body: some View {
TabView {
NavigationStack {
NavigationLink("Tap Me") {...
0
votes
0
answers
45
views
Auto-Collapsing navigationTitle when using TabView w/ shared toolbar?
Suppose I have a TabView which is the root of my app. I need to be able to tab between each of these, but some of them have their own NavigationStack Every one of them has a List associated with them, ...
0
votes
0
answers
117
views
SwiftUI: Restrict .sheet to one view only (or hide .sheet immediately)
Here is simplistic code just to showcase what I mean and approximately what I have in my project:
ContentView.swift:
struct ContentView: View {
var body: some View {
TabView {
...
-1
votes
1
answer
78
views
Why does every item create an new TabView? [duplicate]
Every element in my SwiftUI code becomes its own TabView. It is not on one side how i want it. Every item is spread on another TabView.
I tried asking Chatgpt. He thought i gave every item its own ...
0
votes
0
answers
76
views
visionOS custom hover effect and click sound
I have created a custom hover effect per this WWDC video and many other examples on the net:
https://developer.apple.com/videos/play/wwdc2024/10152/
I can get the button to expand when looked at ...
1
vote
1
answer
123
views
How to add a .background to ScrollView without breaking scroll-to-top integration with TabView?
When a ScrollView is nested in a TabView, you can press on the tab button and the scroll view will scroll to top.
import SwiftUI
struct SwiftUIView: View {
let items = (1...100).map { "Item \($...
0
votes
0
answers
91
views
Overflowing title in tabView tab item
I am using TabView in my main view and the tab bar looks perfect when the labels are in English but an issue arises when my titles are translated as my app needs to support Spanish localization. When ...
1
vote
1
answer
380
views
SafeArea Ignored Issue with TabView and NavigationSplitView
Does anyone know a solution to the issue where SafeArea is ignored when using TabView with NavigationSplitView in SwiftUI?
When using UISplitViewController, the new tab view style and split view are ...
0
votes
1
answer
349
views
TipKit with TabView
In my SwiftUI app for iOS, I have a TabView with two tabs.
Now I want to add a ToolTip to the second tabItem label.
I am trying to use the TipKit framework, but I just don't see the tip.
Here is an ...
1
vote
0
answers
68
views
TabView views only show when I remove the ScrollView. But I need the ScrollView for my complex UI, so how do I fix this?
TabView views only show when I remove the ScrollView. But I need the ScrollView for my complex UI, so how do I fix this?
ScrollView {
VStack {
if showDivider {
Divider(...
1
vote
0
answers
51
views
Routing in NavigationStack not working as expected
I have a full code example below. The problem is that when I tap "Go to Detail" in the DogsView, the detail view is not visually pushed, although the path does get added to the path array ...
0
votes
0
answers
41
views
SwiftUI table view not updated on selection change [duplicate]
I have implemented a tree view representing different types of objects. Details for these objects should be displayed in a tabbed table view. If I do select an object in the tree, the details of this ...
0
votes
1
answer
89
views
SwiftUI Only hide dot indicator on the last screen of Tabview
I'm working on a project written in SwiftUI and I want to create an Onboarding screen which has 4 pages. Each page has a full-screen image introducing about app. I use Tabview and enable page ...
0
votes
0
answers
54
views
TabView occupies all free space, how to fix it?
I create a TabView, but for some reason it occupies the entire area on the screen although the view it contains is not on the entire screen.
VStack {
TabView(selection: $selectedPage) {
...
2
votes
0
answers
381
views
Change font of tab bar labels?
I'm trying to implement a custom font (OpenSans) in my SwiftUI app.
Most of my views are happy to take the font and I know therefore that it's being loaded from the bundle correctly. However, there ...
0
votes
1
answer
70
views
Push/pop animation of NavigationView not work when nested in TabView.tabViewStyle(.page(indexDisplayMode: .never))
I have this sample code:
@main
struct SwiftUITestApp: App {
var body: some Scene {
WindowGroup {
VStack {
TabView {
HomeView()
...
0
votes
2
answers
97
views
Sheet Presentation Sync Issue when Switching Tabs
In my app, I have a tabView which contains two tabs presenting the same view. The content in each view is dictated within the respective view. The views have a .sheet modifier which currently triggers ...
0
votes
2
answers
473
views
How to move SwiftUI Bottom Tab to the top?
The following SwiftUI code will generate Bottom Tab
public struct TeamBContentView : View {
public init() {}
public var body: some View {
VStack {
TabView {
...
0
votes
0
answers
147
views
Index display is not showing in TabView
I have a pretty simple TabView. The .tabViewStyle is .page. It is my understanding that for this style the index indicator is supposed to show up at the bottom–which is currently not the case.
Here's ...
1
vote
3
answers
202
views
How can I create a custom tab bar that triggers onAppear
I need a custom tab bar for my application. The implementations of custom nav bar I've seen so far stacks screens in a ZStack and use opacity to conditionally show the selected screen. My issue is ...
0
votes
0
answers
397
views
SwiftUI VideoPlayer in TabView with PageTabViewStyle controls not showing
In one of my projects I have a VideoPlayer() in a TabView with .tabViewStyle(.page(indexDisplayMode: .always)) to make a paginated carousel. The VideoPlayer has built-in controls for playing/pausing ...
2
votes
1
answer
438
views
TabView breaks navigation on Xcode 16 using TCA
I'm seeing inconsistent behavior when using NavigationStack inside a TabView. On my device (iOS 17.6.1) with Xcode 16.0, the "drilling down" stops working after navigating back to the root ...
2
votes
2
answers
901
views
How to hide Tabbar in detail pages/ specific pages in iOS18 SwiftUI?
With Xcode 16 and iOS18, I'm facing an issue with Tabbar SwiftUI.
Now in iOS18, we have a floating Tabbar in the iPad. Earlier, before iOS18, when I pushed any view, a new view was above the Tabbar. ...
2
votes
2
answers
184
views
SwiftUI Text, changing the text with @State property causing whole view to re-render
I am facing a really strange issue and I have no clue how to solve this problem. There is a Text and a TabView in a VStack. Now the problem is, when I am trying to set the Text's text based on some @...
0
votes
0
answers
94
views
SwiftUI: NavigationStack with TabView: switching tab make the title animation to fail
I have 2 tabs in TabView in NavigationStack.
Each tab has ScrollView for all over the screen.
While switching between those tabs, the navigation title becomes not animated and stuck.
The attached ...
1
vote
2
answers
218
views
Swiftui Bug - Button (only top part is clickable)
I'm having an issue with SwiftUI where only the top part of the button is clickable, while the bottom part is not clickable at all.
Here is my code snippet. Does anyone know how I can fix this?
struct ...
2
votes
1
answer
129
views
Different Nav Bar Appearances for different tabs in TabView in SwiftUI
I've got a TabView which hosts 3 tabs (Liabilities, In/Out, and Assets). Each tab has a NavigationView in it. I want to have a different Nav Bar Appearance for each (red themed for Liabilities, white ...
0
votes
1
answer
225
views
TabView tabItem makes items to align verticaly SwiftUI, tabItem not applying style
So I have this style for my label that makes icon and text aligned horizontally, It works fine out of tabItem
But once I add that to the tabItem in TabView the icon and the text become vertically ...