Skip to content

v111.0.0

Compare
Choose a tag to compare
@randallli randallli released this 21 Jul 14:04
· 571 commits to stable since this release

111.0.0

In this Major release we removed some deprecated action sheet themers, made visual improvements to Chips, ProgressView, Banner and Tabs. We also made links clickable in Alert Dialogs

Breaking changes

ActionSheet

We deleted ActionSheet Themers. Use theming extensions.

New features

ButtonBar

Add UIMenu support for MDCButtonBar.

MDCButtonBar *buttonBar = [[MDCButtonBar alloc] init];
UIMenu *primaryMenu = [self exampleMenuWithTitle:@"A primary action menu"];
menuAsPrimaryActionItem = [[UIBarButtonItem alloc] initWithImage:nil menu:primaryMenu];
menuAsPrimaryActionItem.title = @"Menu on tap";

buttonBar.items = @[ menuAsSecondaryActionItem, menuAsPrimaryActionItem, changingActionItem ];

…
- (UIMenu *)exampleMenuWithTitle:(NSString *)title API_AVAILABLE(ios(14.0)) {
  UIAction *firstAction = [UIAction actionWithTitle:@"An action"
                                              image:nil
                                         identifier:nil
                                            handler:^(__kindof UIAction *_Nonnull action) {
                                              NSLog(@"First element was tapped.");
                                            }];
  UIAction *secondAction = [UIAction actionWithTitle:@"A second action"
                                               image:nil
                                          identifier:nil
                                             handler:^(__kindof UIAction *_Nonnull action) {
                                               NSLog(@"Second element was tapped.");
                                             }];

  NSArray<UIAction *> *menuElements = @[ firstAction, secondAction ];
  return [UIMenu menuWithTitle:title children:menuElements];
}

Tabs

Add non fixed clustered centered layout style.

tabBar.preferredLayoutStyle =
                    MDCTabBarViewLayoutStyleNonFixedClusteredCentered;

API changes

TabBarView

new enum: MDCTabBarViewLayoutStyleNonFixedClusteredCentered

Component changes

ActionSheet

Banner

BottomAppBar

ButtonBar

Chips

Dialogs

NavigationDrawer

ProgressView

Tabs