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
randallli committed Feb 2, 2021
2 parents 672a406 + 01d5029 commit 60e2a6e
Show file tree
Hide file tree
Showing 22 changed files with 99 additions and 98 deletions.
25 changes: 25 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
# 121.0.1

In this patch release we made some internal improvements to our imports and refined our deprecation policy.

## Component changes

### BottomNavigation

* [Fix imports for MDCBottomNavigationItemView.](https://github.com/material-components/material-components-ios/commit/afe4105debedd8c7b3376b5a37e9beeafb9b368e) (Alyssa Weiss)
* [Remove unused 'kOfAnnouncement' and fix imports.](https://github.com/material-components/material-components-ios/commit/3a4270e82053fec7c215a7a766fdfe6c7f153bae) (Alyssa Weiss)

### Ripple

* [Declare parameter type NSArray in the Ripple implementation.](https://github.com/material-components/material-components-ios/commit/73fb0330a6e1b0d6f70a0e50037b255cac1cafba) (Yarden Eitan)

### TextControls

* [Fix imports for clang tidy](https://github.com/material-components/material-components-ios/commit/ee7f2fce52de27f59a209cca2f43f7609e6e0172) (Andrew Overton)

### Typography

* [UIFont MDC simple equality: updated class docs.](https://github.com/material-components/material-components-ios/commit/274ba189abfb3d8065585b64a67f4d4179996e38) (Randall Li)

---

# 121.0.0

In this major release, we added a `scrollViewBounce` property and a `adjustHeightForSafeAreaInsets` property to BottomSheets, added a `shouldAutorotateOverride` property, a `preferredInterfaceOrientationForPresentationOverride` property, a `supportedInterfaceOrientationsOverride` property, and a `modalTransitionStyleOverride` property to MDCAlertController, and converted `progressTintColors` property on MDCProgressView to use light weight generics.
Expand Down
2 changes: 1 addition & 1 deletion 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 = "121.0.0"
mdc.version = "121.0.1"
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
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 = "121.0.0"
s.version = "121.0.1"
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 = "121.0.0"
s.version = "121.0.1"
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 = "121.0.0"
s.version = "121.0.1"
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 @@
121.0.0
121.0.1
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>121.0.0</string>
<string>121.0.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>121.0.0</string>
<string>121.0.1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIAppFonts</key>
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>121.0.0</string>
<string>121.0.1</string>
<key>CFBundleVersion</key>
<string>121.0.0</string>
<string>121.0.1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UILaunchStoryboardName</key>
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 = "121.0.0"
s.version = "121.0.1"
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
4 changes: 2 additions & 2 deletions components/BottomNavigation/src/MDCBottomNavigationBar.m
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@

#import "MDCBottomNavigationBar.h"

#import "MaterialElevation.h"
#import "MaterialInk.h"
#import <MDFInternationalization/MDFInternationalization.h>

#import "private/MDCBottomNavigationBar+Private.h"
Expand All @@ -41,8 +43,6 @@
static const CGFloat kBarHeightAdjacentTitle = 40;
static const CGFloat kItemsHorizontalMargin = 12;

static NSString *const kOfAnnouncement = @"of";

@interface MDCBottomNavigationBar () <MDCInkTouchControllerDelegate,
MDCRippleTouchControllerDelegate>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@

#import "MDCBottomNavigationItemView.h"

#import "MaterialInk.h"
#import "MaterialRipple.h"
#import <MDFInternationalization/MDFInternationalization.h>

#import "MaterialAvailability.h"
#import "MDCBottomNavigationBar.h"
#import "MDCBottomNavigationItemBadge.h"

Expand Down
2 changes: 1 addition & 1 deletion components/LibraryInfo/src/MDCLibraryInfo.m
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
// This string is updated automatically as a part of the release process and should not be edited
// manually. Do not rename this constant or change the formatting without updating the release
// scripts.
static NSString* const kMDCLibraryInfoVersionString = @"121.0.0";
static NSString* const kMDCLibraryInfoVersionString = @"121.0.1";

@implementation MDCLibraryInfo

Expand Down
2 changes: 1 addition & 1 deletion components/LibraryInfo/tests/unit/LibraryInfoTests.m
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ - (void)testVersionFormat {
// Given

// This regex pattern does the following:
// Accept: "121.0.0", etc.
// Accept: "121.0.1", etc.
// Reject: "0.0.0", "1.2", "1", "-1.2.3", "Hi, I'm a version 1.2.3", "1.2.3 is my version", etc.
//
// Note the major version must be >= 1 since "0.0.0" is used as the version when something goes
Expand Down
2 changes: 1 addition & 1 deletion components/Ripple/src/MDCRippleView.m
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ - (void)traitCollectionDidChange:(UITraitCollection *)previousTraitCollection {
- (void)layoutSublayersOfLayer:(CALayer *)layer {
[super layoutSublayersOfLayer:layer];

NSArray *sublayers = self.layer.sublayers;
NSArray<CALayer *> *sublayers = self.layer.sublayers;
if (sublayers.count > 0) {
[self updateRippleStyle];
}
Expand Down
2 changes: 2 additions & 0 deletions components/TextControls/src/BaseTextFields/MDCBaseTextField.m
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@

#import <Foundation/Foundation.h>

#import "MaterialTextControls+Enums.h"
#import "MDCTextControlAssistiveLabelDrawPriority.h"
#import <MDFInternationalization/MDFInternationalization.h>

#import "MDCBaseTextFieldDelegate.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@

#import <UIKit/UIKit.h>

#import "MaterialTextControls+FilledTextFieldsTheming.h"
#import "MaterialTextControls+OutlinedTextFieldsTheming.h"
#import "supplemental/MDCBaseTextFieldTestsSnapshotTestHelpers.h"
#import "supplemental/MDCTextControlSnapshotTestHelpers.h"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@
#import "supplemental/MDCBaseTextFieldTestsSnapshotTestHelpers.h"
#import "supplemental/MDCTextControlSnapshotTestHelpers.h"
#import "MaterialTextControls+FilledTextFields.h"
#import "MaterialTextControls+FilledTextFieldsTheming.h"
#import "MaterialTextControls+OutlinedTextFieldsTheming.h"

@interface MDCFilledTextFieldTestsSnapshotTests : MDCSnapshotTestCase
@property(strong, nonatomic) MDCFilledTextField *textField;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@

#import "supplemental/MDCBaseTextFieldTestsSnapshotTestHelpers.h"
#import "supplemental/MDCTextControlSnapshotTestHelpers.h"
#import "MaterialTextControls+FilledTextFieldsTheming.h"
#import "MaterialTextControls+OutlinedTextFields.h"
#import "MaterialTextControls+OutlinedTextFieldsTheming.h"

@interface MDCOutlinedTextFieldTestsSnapshotTests : MDCSnapshotTestCase
@property(strong, nonatomic) MDCOutlinedTextField *textField;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,11 @@
#import <UIKit/UIKit.h>

#import "MaterialTextControls+BaseTextFields.h"
#import "MaterialTextControls+Enums.h"
#import "MaterialTextControls+FilledTextFields.h"
#import "MaterialTextControls+OutlinedTextFields.h"
#import "MaterialTextControls+UnderlinedTextFields.h"
#import "MDCTextControlSnapshotTestHelpers.h"
#import "MaterialSnapshot.h"

@interface MDCBaseTextField (AnimationDuration)
@property(nonatomic, assign) NSTimeInterval animationDuration;
Expand Down
12 changes: 3 additions & 9 deletions components/Typography/src/UIFont+MaterialSimpleEquality.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,11 @@
// See the License for the specific language governing permissions and
// limitations under the License.

/**
The Typography component provides methods for getting sized fonts and opacities following Material
style guidelines.
This header is the umbrella header for the component and should be imported by consumers of the
Typography component. Please do not directly import other headers. This will allow the componet to
expand or contract the header file space without consumer modifications.
*/

#import <UIKit/UIKit.h>

/**
This UIFont category provides a shallow equality check. http://www.openradar.appspot.com/28406766
*/
@interface UIFont (MaterialSimpleEquality)

/*
Expand Down
112 changes: 47 additions & 65 deletions contributing/deprecation_policy.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,40 +25,22 @@ the deprecation process below.
## Our deprecation process (Googlers)

1. Measure internal usage of the API.
2. Create a GitHub issue.
3. Write a migration guide.
4. Add a comment to the API indicating that it will be deprecated.
5. Determine a schedule for the API deletion.
6. Announce that the API will be deprecated
7. After the deprecation date, annotate the API as deprecated.
8. After the deletion date, re-evaluate usage of the API.
9. Delete the API and migration guide.
2. Write a migration guide.
3. Determine a schedule for the API deprecation and deletion.
4. Mark the API as To Be Deprecated.
5. Announce that the API will be deprecated.
6. After the deprecation date, annotate the API as deprecated.
7. After the deletion date, re-evaluate usage of the API.
8. Delete the API and migration guide.

### Step 1: Measure internal usage of the API

Read [go/mdc-ios-measuring-api-usage](http://go/mdc-ios-measuring-api-usage) to learn how to measure
API usage internally.

If there is zero API usage beyond our own library: skip to step 7 (Deprecate the API).
Otherwise, proceed to step 2.

### Step 2: Create a GitHub issue

Create a GitHub issue with the following template:

```
- [x] Measure internal usage of the API.
- [x] Create a GitHub issue.
- [ ] Write a migration guide.
- [ ] Add a comment to the API indicating that it will be deprecated.
- [ ] Determine a schedule for the API deletion.
- [ ] Announce that the API will be deprecated
- [ ] After the deprecation date, annotate the API as deprecated.
- [ ] After the deletion date, re-evaluate usage of the API.
- [ ] Delete the API and migration guide.
```

### Step 3: Write a migration guide
### Step 2: Write a migration guide

This guide should be placed in the component's docs/ folder and have a prefix `migration-guide-`.

Expand All @@ -67,41 +49,7 @@ MDCAppBarViewController.

Send this migration guide out for review as a standalone pull request.

### Step 4: Add a comment to the API indicating that it will be deprecated.

Add a `@warning` annotation to the API's public documentation indicating the intent for this API to
eventually be deprecated. This warning should also provide a short suggested alternative, if one
exists, and a link to the migration guide.

For example:

```objc
@warning This method will soon be deprecated. Consider using
@c +applySemanticColorScheme:toFlexibleHeaderView: instead. Learn more at
components/schemes/Color/docs/migration-guide-semantic-color-scheme.md
```

If the API to be deprecated is a method or property of a class, also move the API to a category
named `ToBeDeprecated`. This will cause the API to show up in our release notes automatically as
a to-be-deprecated API.

For example:

```objc
@interface MDCAppBarContainerViewController (ToBeDeprecated)

/**
The App Bar views that will be presented in front of the contentViewController's view.

@warning This API will eventually be deprecated. Use appBarViewController instead. Learn more at
components/AppBar/docs/migration-guide-appbar-appbarviewcontroller.md
*/
@property(nonatomic, strong, nonnull, readonly) MDCAppBar *appBar;

@end
```

### Step 5: Determine a schedule for the API deletion
### Step 3: Determine a schedule for the API deprecation and deletion

Generally speaking deprecations take a long time unless you take an active part in migrating
clients. Calculate your estimates with this in mind. A rough guideline:
Expand Down Expand Up @@ -135,7 +83,41 @@ Map this schedule onto reality:

**Once you have determined a schedule, add the schedule to the migration guide**.

### Step 6: Announce that the API will be deprecated
### Step 4: Mark the API as To Be Deprecated

Add a `@warning` annotation to the API's public documentation indicating the intent for this API to
eventually be deprecated. This warning should also provide a short suggested alternative, if one
exists, and a link to the migration guide.

For example:

```objc
@warning This method will soon be deprecated. Consider using
@c +applySemanticColorScheme:toFlexibleHeaderView: instead. Learn more at
components/schemes/Color/docs/migration-guide-semantic-color-scheme.md
```

If the API to be deprecated is a method or property of a class, also move the API to a category
named `ToBeDeprecated`. This will cause the API to show up in our release notes automatically as
a to-be-deprecated API.

For example:

```objc
@interface MDCAppBarContainerViewController (ToBeDeprecated)

/**
The App Bar views that will be presented in front of the contentViewController's view.

@warning This API will eventually be deprecated. Use appBarViewController instead. Learn more at
components/AppBar/docs/migration-guide-appbar-appbarviewcontroller.md
*/
@property(nonatomic, strong, nonnull, readonly) MDCAppBar *appBar;

@end
```

### Step 5: Announce that the API will be deprecated

Inform internal clients of the impending deprecation by sending an email with the following
format:
Expand All @@ -152,12 +134,12 @@ The timeline for this deprecation is as follows:
- <Deletion date>: The API will be deleted.
```

### Step 7: After the deprecation date, annotate the API as deprecated
### Step 6: After the deprecation date, annotate the API as deprecated

Send a pull request annotating the API as deprecated. Use `__deprecated_msg("")` and provide a
concise message with a recommendation for an alternative API, if any is available.

### Step 8: After the deletion date, re-evaluate usage of the API
### Step 7: After the deletion date, re-evaluate usage of the API

Once the deletion date has passed and at least one release has been cut since the API was marked as
deprecated, you can now consider deleting the API. But first: you must evaluate whether the API is
Expand All @@ -170,7 +152,7 @@ If the API is still being used by clients, you have a few options:

Proceed to step 9 once you've confirmed that there are zero internal usages of the API.

### Step 9: Delete the API and migration guide
### Step 8: Delete the API and migration guide

Once you have confirmed that there is no internal usage of the API, you can safely delete it and the migration guide.

Expand Down
2 changes: 1 addition & 1 deletion demos/supplemental/RemoteImageServiceForMDCDemos.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "RemoteImageServiceForMDCDemos"
s.version = "121.0.0"
s.version = "121.0.1"
s.summary = "A helper image class for the MDC demos."
s.description = "This spec is made for use in the MDC demos. It gets images via url."
s.homepage = "https://github.com/material-components/material-components-ios"
Expand Down

0 comments on commit 60e2a6e

Please sign in to comment.