Skip to content

Commit

Permalink
Merge branch 'release-candidate' into stable
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewoverton committed Jun 3, 2020
2 parents 87351aa + 316c550 commit 90914be
Show file tree
Hide file tree
Showing 62 changed files with 1,064 additions and 347 deletions.
91 changes: 91 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,94 @@
# 109.6.0

This minor release adds new functionality to NavigationDrawer, ActionSheet, and Dialogs, and adds accessibility improvements to Buttons, Chips, and private/Color.

## New deprecations

While there are no new deprecations in this release, the `hitAreaInsets` APIs on `MDCChipView` and `MDCButton` have been moved to a `ToBeDeprecated` category. `hitAreaInsets` will eventually be deprecated across components. Its replacement, `visibleHitAreaInsets`, is in the process of being added to all relevant components.

## New features

### ActionSheet

- `MDCActionSheetControllerDelegate` has a new method, `-actionSheetController:willDisplayView:forRowAtIndexPath:`.

### Buttons

- `MDCButton` has a new `visibleHitAreaInsets` property.

### Chips

- `MDCChipView` has a new `visibleHitAreaInsets` property.

### Dialogs

- `MDCAlertController` has a new `attributedMessageAction` property.

### NavigationDrawer

- `MDCBottonDrawerPresentationController` has a new `maximumDrawerHeight` property.

## Component changes

### ActionSheet

* [internal change](https://github.com/material-components/material-components-ios/commit/abde17e493928c9ed2fd09620a4f2c7d848658b5) (Nobody)

### AppBar

* [Inject AppBars after view controllers have been added to the navigation controller.](https://github.com/material-components/material-components-ios/commit/b78737be488e0e3131d75aca928a4bff9d6f04fd) (Jeff Verkoeyen)

### Banner

* [Add example snapshot tests for verifying MDCColorSchemeDefaultsMaterial201907 color scheme.](https://github.com/material-components/material-components-ios/commit/f2f99a45206b546991b4ef19fef501997940ba58) (Wenyu Zhang)
* [Apply container theme in examples.](https://github.com/material-components/material-components-ios/commit/be3c97421b9466ad0228dbace95dc9c15c752c04) (Wenyu Zhang)

### Buttons

* [Add a visibleAreaInsets API.](https://github.com/material-components/material-components-ios/commit/e8a1c4e7e14ff72cefd68eef1c0e8d2c0a801b14) (Yarden Eitan)

### Chips

* [Add visibleAreaInsets API to MDCChipView.](https://github.com/material-components/material-components-ios/commit/db48cefa9b3817bee3372ad77e64b0346d5f0487) (Wenyu Zhang)

### Dialogs

* [Adding tappable link support to the alert message](https://github.com/material-components/material-components-ios/commit/6bb3ece3935540754d20adeb45eaa856a9f63766) (Galia Kaufman)
* [replace the message UILabel type to UITextview](https://github.com/material-components/material-components-ios/commit/f4fd6d015fedbb111adf25218f122825d465a51f) (Galia Kaufman)

### FeatureHighlight

* [Delete unused accessibility hint string and unused localization support.](https://github.com/material-components/material-components-ios/commit/b2ae9cdce12f2fc50816199417a4165b3ddcc052) (Bryan Oltman)

### FlexibleHeader

* [Remove ShiftBehaviorWithStatusBar from the public API.](https://github.com/material-components/material-components-ios/commit/0c4d18595824b22b0e9675723bf7e022e94db33e) (Jeff Verkoeyen)

### NavigationDrawer

* [Clarify `trackingScrollView` API.](https://github.com/material-components/material-components-ios/commit/57f25fd95aac12ca69567d74c2fac1fa74977254) (Cody Weaver)
* [Fix bug where `maximumDrawerHeight` wouldn't allow for the correct height.](https://github.com/material-components/material-components-ios/commit/11db172e79913c3fafa379e91061a9aad213359c) (Cody Weaver)
* [Fix bug where setting `maximumDrawerHeight` and `maximumInitialDrawerHeight` would allow scrolling.](https://github.com/material-components/material-components-ios/commit/2d533759d11e2596ea8106a3d7a8c1025f545e4c) (Cody Weaver)
* [Support a max height](https://github.com/material-components/material-components-ios/commit/33daf325e650b27a44004ff44b97a61d98221b79) (Cody Weaver)

### Shapes

* [Resolve UIColor instance when it is set as shapedBackgroundColor to MDCShapedShadowLayer.](https://github.com/material-components/material-components-ios/commit/245b90cd57ced5096476824cefc3bf7c522d95ee) (Wenyu Zhang)

### Tabs

* [Internal change](https://github.com/material-components/material-components-ios/commit/d404e5e83271250b544431767e348cd411794445) (Jeff Verkoeyen)

### private/Color

* [Add colorWithAccessibilityContrastHigh:normal: API to support Increase Contrast color.](https://github.com/material-components/material-components-ios/commit/45b9b222e30dbd77e508ff742892ea1fe45b650b) (Wenyu Zhang)

## Multi-component changes

* [Add prepareShadowPath to MDCShadowLayer to allow its subclass preparing shadow path before MDCShadowLayer lays out its sublayers.](https://github.com/material-components/material-components-ios/commit/b19e4e964d5a60e800d8ae71f7b87af7828094c8) (Wenyu Zhang)

---

# 109.5.0

This minor release adds functionality to MDCSnackbarManagerDelegate and includes internal cleanup of FlexibleHeader.
Expand Down
6 changes: 2 additions & 4 deletions MaterialComponents.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ load 'scripts/generated/icons.rb'

Pod::Spec.new do |mdc|
mdc.name = "MaterialComponents"
mdc.version = "109.5.0"
mdc.version = "109.6.0"
mdc.authors = "The Material Components authors."
mdc.summary = "A collection of stand-alone production-ready UI libraries focused on design details."
mdc.homepage = "https://github.com/material-components/material-components-ios"
Expand Down Expand Up @@ -422,6 +422,7 @@ Pod::Spec.new do |mdc|
component.dependency "MaterialComponents/Ripple"
component.dependency "MaterialComponents/ShadowElevations"
component.dependency "MaterialComponents/ShadowLayer"
component.dependency "MaterialComponents/ShapeLibrary"
component.dependency "MaterialComponents/Shapes"
component.dependency "MaterialComponents/Typography"
component.dependency "MaterialComponents/private/Math"
Expand Down Expand Up @@ -846,9 +847,6 @@ Pod::Spec.new do |mdc|
"components/#{component.base_name}/src/*.{h,m}",
"components/#{component.base_name}/src/private/*.{h,m}"
]
component.resources = [
"components/#{component.base_name}/src/Material#{component.base_name}.bundle"
]

component.dependency "MaterialComponents/Availability"
component.dependency "MaterialComponents/private/Math"
Expand Down
2 changes: 1 addition & 1 deletion MaterialComponentsBeta.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |mdc|
mdc.name = "MaterialComponentsBeta"
mdc.version = "109.5.0"
mdc.version = "109.6.0"
mdc.authors = "The Material Components authors."
mdc.summary = "A collection of stand-alone alpha UI libraries that are not yet guaranteed to be ready for general production use. Use with caution."
mdc.homepage = "https://github.com/material-components/material-components-ios"
Expand Down
2 changes: 1 addition & 1 deletion MaterialComponentsEarlGreyTests.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "MaterialComponentsEarlGreyTests"
s.version = "109.5.0"
s.version = "109.6.0"
s.authors = "The Material Components authors."
s.summary = "This spec is an aggregate of all the Material Components EarlGrey tests."
s.description = "This spec is made for use in the MDC Catalog."
Expand Down
2 changes: 1 addition & 1 deletion MaterialComponentsExamples.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "MaterialComponentsExamples"
s.version = "109.5.0"
s.version = "109.6.0"
s.authors = "The Material Components authors."
s.summary = "This spec is an aggregate of all the Material Components examples."
s.description = "This spec is made for use in the MDC Catalog. Used in conjunction with CatalogByConvention we create our Material Catalog."
Expand Down
2 changes: 1 addition & 1 deletion MaterialComponentsSnapshotTests.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ end

Pod::Spec.new do |s|
s.name = "MaterialComponentsSnapshotTests"
s.version = "109.5.0"
s.version = "109.6.0"
s.authors = "The Material Components authors."
s.summary = "This spec is an aggregate of all the Material Components snapshot tests."
s.homepage = "https://github.com/material-components/material-components-ios"
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
109.5.0
109.6.0
4 changes: 2 additions & 2 deletions catalog/MDCCatalog/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>109.5.0</string>
<string>109.6.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>109.5.0</string>
<string>109.6.0</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIAppFonts</key>
Expand Down
11 changes: 7 additions & 4 deletions catalog/MDCDragons/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,13 @@ import CatalogByConvention

@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
var window: MDCCatalogWindow?

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
self.window = UIWindow(frame: UIScreen.main.bounds)
func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
self.window = MDCCatalogWindow(frame: UIScreen.main.bounds)
UIApplication.shared.statusBarStyle = .lightContent
let tree = CBCCreateNavigationTree()
var rootNodeViewController: UIViewController
Expand All @@ -39,7 +42,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
}
let navigationController = UINavigationController(rootViewController: rootNodeViewController)
navigationController.interactivePopGestureRecognizer?.delegate = navigationController

self.window?.rootViewController = navigationController
self.window?.makeKeyAndVisible()
return true
Expand Down
4 changes: 2 additions & 2 deletions catalog/MDCDragons/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>109.5.0</string>
<string>109.6.0</string>
<key>CFBundleVersion</key>
<string>109.5.0</string>
<string>109.6.0</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UILaunchStoryboardName</key>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2017-present the Material Components for iOS authors. All Rights Reserved.
// Copyright 2020-present the Material Components for iOS authors. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand All @@ -12,11 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.

// GENERATED CODE: DO NOT EDIT BY HAND
// GENERATED FROM:
// components/FeatureHighlight/src/MaterialFeatureHighlight.bundle/Resources/en.lproj/MaterialFeatureHighlight.strings
// GENERATED BY: generate_string_tables.py
import UIKit

typedef enum {
kStr_MaterialFeatureHighlightDismissAccessibilityHint = 0,
} MaterialFeatureHighlightStringId;
class MDCCatalogWindow: UIWindow {}
14 changes: 14 additions & 0 deletions catalog/MDCDragons/MDCDragonsController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ import MaterialComponents.MaterialShadowElevations
import MaterialComponents.MaterialShadowLayer
import MaterialComponents.MaterialThemes
import MaterialComponents.MaterialTypography
import MaterialComponents.MaterialColorScheme
import MaterialComponents.MaterialContainerScheme

import UIKit

Expand Down Expand Up @@ -242,6 +244,18 @@ class MDCDragonsController: UIViewController,

func setupTransition(nodeData: DragonCell) {
var vc = nodeData.node.createExampleViewController()

let containerSchemeSel = NSSelectorFromString("containerScheme");
if vc.responds(to: containerSchemeSel) {
let containerScheme = MDCContainerScheme()

containerScheme.colorScheme = MDCSemanticColorScheme(defaults: .material201907)
containerScheme.typographyScheme = MDCTypographyScheme(defaults: .material201902)
containerScheme.shapeScheme = MDCShapeScheme()

vc.setValue(containerScheme, forKey: "containerScheme")
}

if !vc.responds(to: NSSelectorFromString("catalogShouldHideNavigation")) {
let container = MDCAppBarContainerViewController(contentViewController: vc)
container.appBar.headerViewController.headerView.backgroundColor = headerViewController.headerView.backgroundColor
Expand Down
2 changes: 1 addition & 1 deletion catalog/MaterialCatalog/MaterialCatalog.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "MaterialCatalog"
s.version = "109.5.0"
s.version = "109.6.0"
s.summary = "Helper Objective-C classes for the MDC catalog."
s.description = "This spec is made for use in the MDC Catalog."
s.homepage = "https://github.com/material-components/material-components-ios"
Expand Down
9 changes: 9 additions & 0 deletions components/ActionSheet/src/MDCActionSheetController.m
Original file line number Diff line number Diff line change
Expand Up @@ -373,6 +373,15 @@ - (UITableViewCell *)tableView:(UITableView *)tableView
return cell;
}

- (void)tableView:(UITableView *)tableView
willDisplayCell:(nonnull UITableViewCell *)cell
forRowAtIndexPath:(nonnull NSIndexPath *)indexPath {
if ([self.delegate respondsToSelector:@selector(actionSheetController:
willDisplayView:forRowAtIndexPath:)]) {
[self.delegate actionSheetController:self willDisplayView:cell forRowAtIndexPath:indexPath];
}
}

- (void)setContentEdgeInsets:(UIEdgeInsets)contentEdgeInsets {
if (UIEdgeInsetsEqualToEdgeInsets(_contentEdgeInsets, contentEdgeInsets)) {
return;
Expand Down
7 changes: 7 additions & 0 deletions components/ActionSheet/src/MDCActionSheetControllerDelegate.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,11 @@
Tells the delegate that the action sheet was dismissed.
*/
- (void)actionSheetControllerDidDismiss:(nonnull MDCActionSheetController *)actionSheetController;

/**
Tells the delegate that the action sheet will display a view.
*/
- (void)actionSheetController:(nonnull MDCActionSheetController *)actionSheetController
willDisplayView:(nonnull UIView *)view
forRowAtIndexPath:(nonnull NSIndexPath *)indexPath;
@end
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ import MaterialComponents.MaterialAppBar
import MaterialComponents.MaterialAppBar_Theming
import MaterialComponents.MaterialContainerScheme

// This example demonstrates that it is possible to hide a view controller's
// navigationController.navigationBar during viewDidLoad when presented within an
// MDCAppBarNavigationController.
class AppBarNavigationControllerWithAppBarInitiallyHiddenExample:
UIViewController,
MDCAppBarNavigationControllerDelegate {
Expand Down Expand Up @@ -153,7 +156,6 @@ extension AppBarNavigationControllerWithAppBarInitiallyHiddenExample {
extension AppBarNavigationControllerWithAppBarInitiallyHiddenExample {

@objc func testPresented() {
// TODO(b/152510959): The AppBar is expected to be hidden, but it is not.
presentModal(animated: false)
}
}
Loading

0 comments on commit 90914be

Please sign in to comment.