This repository was archived by the owner on Dec 11, 2025. It is now read-only.
v87.0.0
This major release improves the traitCollectionDidChangeBlock for
MDCButton.
Breaking changes
MDCButton.traitCollectionDidChangeBlock now requires an MDCButton *
instance as its first parameter. This is to allow passing the button itself
into the block and eliminate the need for retaining the button in its own
block.
Previous Releases
button.traitCollectionDidChangeBlock =
^(UITraitCollection *_Nullable previousTraitCollection) {
// Code
};In This Release
button.traitCollectionDidChangeBlock =
^(MDCButton *_Nonnull buttonInBlock, UITraitCollection *_Nullable previousTraitCollection) {
// Code
};API changes
Buttons
MDCButton
modified property: traitCollectionDidChangeBlock in MDCButton
| Type of change: | Swift declaration |
|---|---|
| From: | var traitCollectionDidChangeBlock: ((UITraitCollection?) -> Void)? { get set } |
| To: | var traitCollectionDidChangeBlock: ((MDCButton, UITraitCollection?) -> Void)? { get set } |
modified property: traitCollectionDidChangeBlock in MDCButton
| Type of change: | Declaration |
|---|---|
| From: | @property (readwrite, copy, nonatomic, nullable) void (^) (UITraitCollection *_Nullable) traitCollectionDidChangeBlock; |
| To: | @property (readwrite, copy, nonatomic, nullable) void (^) (MDCButton *_Nonnull, UITraitCollection *_Nullable) traitCollectionDidChangeBlock; |
Changes
ActionSheet
- Add dark mode support to theming extension (#8245) (Cody Weaver)
- Stop running swift tests on Autobot. (#8274) (Wenyu Zhang)
ButtonBar
- Stop running swift tests on Autobot. (#8267) (Wenyu Zhang)
Buttons
- Add missing self to traitCollectionDidChangeBlock (#8276) (Yarden Eitan)
FlexibleHeader
- Stop running swift tests on Autobot. (#8269) (Wenyu Zhang)
NavigationBar
- Stop running swift tests on Autobot. (#8272) (Wenyu Zhang)
TextFields
- Add non-experimental MDCBaseTextField example (#8287) (Andrew Overton)
- Stop running swift tests on Autobot. (#8275) (Wenyu Zhang)