2 Commits

Author SHA1 Message Date
Robert Moore
93700ab4d9 [Tabs] Improve accessibility for TabBar example. (#8983)
The Tab Bar View Controller with Interface Builder example had no way to
dismiss with Voice Over, disappearing labels, and too much code.  Provides an
AppBar with back button, labels on every child view controller, and better
support for Dynamic Type.

|Before|After 1 AXXXL|After 2 XS|
|---|---|---|
|![IMG_0110](https://user-images.githubusercontent.com/1753199/68987915-134aa200-07fd-11ea-8424-277e0b6eb1ee.PNG)|![IMG_0114](https://user-images.githubusercontent.com/1753199/68987917-1d6ca080-07fd-11ea-8a1c-d1c372665fe5.PNG)|![IMG_0115](https://user-images.githubusercontent.com/1753199/68987918-22c9eb00-07fd-11ea-8b74-ec85cb602e93.PNG)|

Closes #8978
2019-11-18 08:31:07 -05:00
ianegordon
f88dc55511 [Tabs] Add MDCTabViewController (#1482)
* MDCTabBarViewController - like UITabBarViewController, but uses Material Design's MDCTabBar

* MDCTabBarViewController Interface Builder example

It's integrated into the Catalog app as a Tab example. Also demonstrates moving the tab bar from the unselected state to the selected state. Note: this reveals a bug with the unselected state that https://github.com/material-components/material-components-ios/pull/1441 fixes.

* Copyright date is 2017 for these TabBarViewController files. Fix white space issues.

* Add <UITabBarItem *> to local variable in updateTabBarItems

* Address Brian Moore's comments: ran clang-format -style=file on these files,
Modified tabBar delegate protocol: tabBar:willSelectItem: becomes tabBar:shouldSelectItem:
so that MDCTabBarViewController can have a 'shouldSelect' delegate.

* comment correction of ViewController to view controller.

* Add new API to MDCItemBar in preparation for deprecating willSelect: from the delegate protocol, replacing it with shouldSelect:. Revert changes to comment lines that appear to be a mis-configuration at my end to 80 columns.

* Tested more thoroughly, verified that the class still works.

* Restore the delegate willSelect method that we intended in favor of shouldSelect:

* Simplify private/MDCItemBar's delegate protocol, write MDCTabBar public protocol in terms of it, as Brian asked.

* Comment fixes.

* Address Brian Moore's May 31 comments. Adjust color of TabBar in Interface builder example.

* Update README.md
2017-06-06 17:32:21 -04:00