Deep Dive into TabView Changes in iOS18

Поделиться
HTML-код
  • Опубликовано: 30 ноя 2024

Комментарии • 30

  • @Mahadev-x7u
    @Mahadev-x7u 2 месяца назад +1

    Next excellent lesson… special thanks for example in real project 🔥💯❤️

  • @santhoshVnair
    @santhoshVnair 3 месяца назад

    This is an excellent and insightful video with comprehensive coverage on the possibilities of Tabview coming to iOS 18. It looks like lines are blurring between NavigationStack and TabView. Thanks Steve, exceptional as usual.

  • @swiftodyssey
    @swiftodyssey 2 месяца назад +1

    Awesome video, thank you Stewart!

  • @chrismcnabb797
    @chrismcnabb797 2 месяца назад +1

    Thank you! I was searching for this exact tutorial! 🎉

  • @KristenSwanson
    @KristenSwanson Месяц назад

    Super helpful, thank you! Do you have a recommendation about using a Navigation Stack with a TabView on iPad now? (Now that the tab bar is only at the top on iPad, the “back” being at the top when you’re within a stack of a tab seems confusing.)

  • @dirkfu6280
    @dirkfu6280 2 месяца назад

    Enabling „Requires fullscreen“, to fix the crash prevents using your app in multitasking though!

    • @Scionwest
      @Scionwest Месяц назад

      Are there alternative solutions other than “requires full screen”?

  • @RossBritten
    @RossBritten 7 дней назад

    I can’t work out how to change the color of the new tab bar?! .toolbarBackground is deprecated

  • @OGLerma
    @OGLerma 2 месяца назад

    Extremely helpful video !

  • @MarkMcBride-q4r
    @MarkMcBride-q4r 2 месяца назад

    Great video. You're timing was just right for me. One follow-up question. Is there an approach whereby you can create the tabs dynamically using Swift data and still make the sidebar customizable?

    • @StewartLynch
      @StewartLynch  2 месяца назад

      You cannot dynamically add new views for the tabs

    • @MarkMcBride-q4r
      @MarkMcBride-q4r 2 месяца назад

      @@StewartLynch Thanks. You really do a great job in these videos.

  • @manmandangdang
    @manmandangdang 2 месяца назад

    Thank you very much! If I want to make TabSection closed by default, how can I achieve it?

    • @StewartLynch
      @StewartLynch  2 месяца назад

      I have not found a way to do that. You can remove the sidebar altogether by using .tabViewStyle(.tabBarOnly)
      , but you do not get the option to bring it back

  • @Tachoisdabest
    @Tachoisdabest 2 месяца назад

    Thank you for the video Stewart!! One question: how do you do a custom header at the top of each file? Do you do this manually or otherwise?

    • @StewartLynch
      @StewartLynch  2 месяца назад +1

      I cover this in this video: ruclips.net/video/RACepNDGNyk/видео.html

    • @Tachoisdabest
      @Tachoisdabest 2 месяца назад

      @@StewartLynch thank you! 🤙🏾

  • @Soh965
    @Soh965 2 месяца назад +1

    Bruh… transferable is incredible…

    • @StewartLynch
      @StewartLynch  2 месяца назад

      Yup, pretty amazing, isn't it

  • @gerardgomez5987
    @gerardgomez5987 3 месяца назад

    Let me just start by saying your videos are amazing. The attention to detail is phenomenal. I learned so much. In regard to the TabView, if there's currently a way to hide TabSection headers in the TabBar view while keeping them visible in the Sidebar view, and more importantly, while still showing the tabs themselves in the TabBar. To be more clear I have a section and within those sections I have tabs. In sidebar view I can see the section and its Tabs, in the TabView I can only see the section or the first tab. Now is there a way to hide the section in the TabView and only shows its tabs?

    • @StewartLynch
      @StewartLynch  3 месяца назад

      You can hide a section from the Tab View, using .tabPlacement(.sidebarOnly)
      However, you cannot show the individual tabs by default.
      However, in the sidebar, when the user taps on one of the tabs in the section, it will appear on the tab bar after that.
      What you could do is set the tabPlacement for each of the items in the section as .pinned, but this will pin them to the end of the tab bar and only show the icon.

  • @KiriKiriKiki
    @KiriKiriKiki 2 месяца назад

    thanks

  • @andremethot2787
    @andremethot2787 3 месяца назад

    Great video. I’ve learned a lot

  • @danstutorials3904
    @danstutorials3904 14 дней назад

    NOT WORKING:
    TabView(selection: $currentTab) {
    if #available(iOS 18.0, *) {
    Tab("Installed fonts", systemImage: "signature") {
    Text("Hello")
    }
    } else {
    // Fallback on earlier versions
    }
    }
    It says that "'buildExpression' is unavailable: this expression does not conform to 'View'"

    • @StewartLynch
      @StewartLynch  14 дней назад +1

      You are mixing two different initializers so this won’t work. Bring the if #available outside the TabView. In iOS 18 the selection is set by a value not a tag.
      @State private var currentTab = 0
      var body: some View {
      if #available(iOS 18.0, *) {
      TabView(selection: $currentTab) {
      Tab("Installed fonts", systemImage: "signature", value: 0) {
      Text("Hello")
      }
      }
      } else {
      TabView(selection: $currentTab) {
      Text("Hello")
      .tabItem {
      Label("Installed fonts", systemImage: "signature")
      }
      .tag(0)
      }
      }
      }

    • @danstutorials3904
      @danstutorials3904 11 дней назад

      @@StewartLynch Aah, Ok thanks so much Stewart! All working! I had no idea Swift was this picky about that type of expression go where!
      Have a great day!