Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-25953] Android: Add "Ti.UI.TabbedBar" support

GitHub Issuen/a
TypeNew Feature
PriorityLow
StatusClosed
ResolutionFixed
Resolution Date2019-01-04T23:28:12.000+0000
Affected Version/sn/a
Fix Version/sRelease 8.0.0
ComponentsAndroid
Labelsandroid, parity, tabbedbar
ReporterJoshua Quick
AssigneeYordan Banev
Created2018-04-10T18:26:06.000+0000
Updated2019-01-07T11:22:22.000+0000

Description

*Summary:* Currently, Titanium's TabbedBar feature is iOS only. We should add support on Android for parity. This would also be a solution for developers who want to see tabs at the bottom of the Android screen, such as how it works on iOS. The TabbedBar can be used in conjunction with a ScrollableView with scrolling disabled to have the same effect as a TabGroup. *Recommended Solution:* Use the Google "design" support library's TabLayout class which only shows tabs. https://developer.android.com/reference/android/support/design/widget/TabLayout.html https://material.io/guidelines/components/tabs.html#tabs-usage Alternatively, use the Java TabHost class. The TabHost content area for the tabbed view can be set with a zero height so that only the tab bar is shown. https://developer.android.com/reference/android/widget/TabHost.html The iOS Ti.UI.TabbedGrouped is currently flagged deprecated. We should un-deprecate it and make the Ti.UI.iOS.TabbedGroup deprecated instead. https://docs.appcelerator.com/platform/latest/#!/api/Titanium.UI.TabbedBar https://docs.appcelerator.com/platform/latest/#!/api/Titanium.UI.iOS.TabbedBar *Future:* Google's material design guidelines suggests that you use a BottomNavigationView if the tabbed bar is shown at the bottom of the screen. It doesn't show an underline for tab selection and instead highlights the text and image. Unfortunately, this solution has a limit on how many tabs can be shown. It doesn't support horizontal scrolling. Perhaps this should be a style setting upon TabbedBar creation that can be implemented later? https://developer.android.com/reference/android/support/design/widget/BottomNavigationView.html https://material.io/guidelines/components/bottom-navigation.html

Comments

  1. Yordan Banev 2018-08-24

    PR: https://github.com/appcelerator/titanium_mobile/pull/10286
  2. Matthew Delmarter 2018-09-10

    Very excited about this thank you. I am an iOS focussed dev who is wanting to transition my apps to support Android. Parity in Ti of bottom aligned TabGroups across Android / iOS will be super helpful.
  3. Matthew Delmarter 2018-10-12

    Very sorry to see this moved. Hope the priority can be increased on this.
  4. Joshua Quick 2018-10-13

    [~mdelmarter], for 7.5.0 (due to time constraints) we're going to focus on improving TabGroup instead. This includes add a bottom tabs style to it. Please see: [TIMOB-26354]
  5. Lokesh Choudhary 2018-12-17

    FR Passed. Waiting for build issues to be fixed to merge.
  6. Hans Knöchel 2018-12-17

    Thanks for taking this into 8.0.0!
  7. Lokesh Choudhary 2019-01-04

    FR Passed. PR Merged.
  8. Josh Longton 2019-01-07

    *Closing ticket.* The feature is present in SDK: {noformat} 8.0.0.v20190104153150 {noformat}

JSON Source