* [Button] Add custom font properties
* Add example and tests
* Add sample supporting custom font and dynamic type
* Clean up tests
* Fix C&P error in Copyright date.
* Remove outdated warning
* Fix misuse of standardFont and simplify scale invocation.
* [Buttons] Remove .largeIcon shape from FloatingButton (#2513)
The LargeIcon shape is not required, since the same behavior (support
for 36-point images) can be achieved by setting the contentEdgeInsets to
.zero.
Also updates one of the button examples to use a 36-point icon.
* [Buttons] Add extended FAB layout code (#2528)
Creating (internal for now) the required properties and layout code to support
the extended FAB. Unit tests to confirm the behavior and some minor
adjustments to existing values like default contentEdgeInsets values.
Implements #2495
* [Buttons] Expose Extended FAB properties (#2543)
Making the new properties public and also migrating away from simple
property setters to the new forShape:inMode: setters required for
UIAppearance support.
* minimumSize
* maximumSize
* contentEdgeInsets
* hitAreaInsets
Implements #2495
* [Buttons] Add basic Floating Button example (#2554)
Includes automatic adjustment of extended/normal layout depending on size
classes.
Demonstrates #2495
* [Buttons] Update README for Extended FAB (#2561)
The README includes usage examples for the FAB. Adding a section to
demonstrate how to configure the FAB in its different shapes and modes.
Documents #2495
* Added warnings to examples.
* fixed some warnings
* using button sender parameter.
* use button sender in example
* use button sender in example
* removed sender from methods that don’t use it.
* removed sender from methods that don’t use it.
* use button sender in example
* use button sender in example
* use button sender in example
* use button sender in example
* Fixed init of header configurator to use passed in parameter
* removed unused API
* use button sender in example
* Revert "Added warnings to examples."
This reverts commit 91f0480f86cb609c47b00f1346f82de67c31c4e9.
* fixed example: Using the view controllers navigationItem rather than creating a new one.
* removed finished checks from animation blocks in examples.
* reverted id sender checks
* revert id sender check for Flexible header UINavigationBar
* revert clug
* revert clug
* addressing nits
* removed sender check for FeatureHighlightTypicalUseView
* more nits
The FAB in Typical Use was misaligned, resulting in a blurry image. The
Storyboard and Swift example had misaligned buttons due to
safeAreaInsets on iOS 11.
* [Buttons] Deprecate subclassing cornerRadius and defaultContentEdgeInsets
* Remove unused import
* Set contentEdgeInsets via UIAppearance
* Content edge insets comment
* Use correct value for FAB hit area insets
* Fix FAB contentEdgeInsets
* [Buttons] Deprecate subclassing cornerRadius and defaultContentEdgeInsets
* Remove unused import
* Set contentEdgeInsets via UIAppearance
* Content edge insets comment
* Use correct value for FAB hit area insets
* Fix FAB contentEdgeInsets
All examples now have at least the required `+catalogBreadcrumbs` and `+catalogIsPrimaryDemo`. All examples in the same breadcrumbs path have only one primary demo. There should be only one `-catalogDescription` attached to the primary demo.
Closes#1897
The manual layout code was disabling automatic constraints generation
and trying to lay-out the view before subviews were laid-out. The
combination led to broken layout on iOS 9 the first time the view was
loaded.
Resolves#1757
The Floating Action Button (FAB) is supposed to "pop-in" to a view when the
view appears. Adding some basic animation code to allow the FAB to be
animated-in and -out of views.
Adding a new function to realign a CGRect (frame) to pixel boundaries
based on the screen scale. After a review of the catalog, I'm updating
the areas where I found misaligned frames.
Closes#1723
* Update ButtonsStoryboardAndProgrammatic example with more distinct colors and comment explaining use
* Fix MDCButton for loading colors from storyboard without clobbering values
* [Buttons] Unbounded ink aligns to content insets
Unbounded ink should be centered on the content of buttons, but bounded
ink should remain aligned with the bounds of the button.
* Changing Ink behavior for unbounded ink
* Modified Content Rect Insets example in the Catalog
Closes#1669
* Making example buttons have same width
The `contentEdgeInsets` value of an MDCButton causes the `_inkView` to
realign to match the `contentRect`. This results in a ripple/highlight
that does not match the position of the button on-screen (doesn't align
with the background).
This commit removes the re-alignment code, so `_inkView` will remain
aligned with the rest of the button's view.
* [TextFields] Linting
* [Catalog] Swift style.
* [Catalog] Swift style.
* [Buttons] Swift style.
* [FlexibleHeader] Swift style.
* [NavBar] Swift style.
* [Snackbar] Swift style.
* [Tabs] Swift style.
Discussed merge with Ian offline. Issues with Travis CI may be resolved once the PR is merged.
* Add color to tiles.
* Add theming to catalog
* Update text field tile.
* Implementation method signatures should match those in header.
* Update MDCDrawFunc typedef
* Pass color scheme through NSNotification
* Add component theming
* Add tabbar themer
* Update tab example to use UIAppearance
* Theme sliders based on UIAppearance proxy
* Allow any class conforming to MDCColorScheme
* Override navigation bar color theme for imagery example.
* Update AppBar and ButtonBar color theming
* Update button bar themer comment
* Update button theming
* Remove theme imports where not necessary.
* Fix case of private
* Replace MDC all icons
* Update border
* Replace MDCActionExtension icon with new logo
* Update all headers to be white on black
* Make Catalog greyscale to match Material’s style.
* Fix collection tile
* Update all headers to be white on black
* Make Catalog greyscale to match Material’s style.
* Fix collection tile
* WIP: Updating TabBar example to use black/green theme.
* WIP: Monochoroming all examples.
* Switch MDC Catalog to a black and white theme (#1355)
* Replace MDC all icons
* Update border
* Replace MDCActionExtension icon with new logo
* Update all headers to be white on black
* Make Catalog greyscale to match Material’s style.
* Fix collection tile
* Update all headers to be white on black
* Make Catalog greyscale to match Material’s style.
* Fix collection tile
* Fix floats
* Make Catalog greyscale to match Material’s style.
* More black and whiting
* WIP: Snackbar and global style
* Simplify snack bar examples.
* Page control
* ClangFormat changes.
* Added swiftlint to scripts/format_all.`
* Fix scripts/lint_all to work from any directory.
* Fixed swiftlint invocation.
* Remove the checks for force casting (! operator).
* Some fixes.
* More Swift fixes.
* Integrate SwiftLint in the Catalog.
* Update the disabled SwiftLint rules.
* Reference a local swiftlint.yml symlink.
This prevents us from getting warnings about code style violations from the other demos.
* Fix SwiftLint violations in the Catalog and Components.
* Ignore the `third_party` directory when running the linter.
We should not have to deal with warnings in code we may not be able to fix easily.
* Integrate SwiftLint into Shrine.
Additionally, fix a number of warnings introduced.
* Run SwiftLint on Travis.
* Enable many of the previously disabled rules and correct them.
* Fix control statement violations from SwiftLint.
* Center the Storyboard button demo.
This uses an outer container to set up a view which is 50% the screen width (to allow for the other half of the button demo), and then an inner container to vertically and horizontally center the buttons.
* Center the buttons added programatically.
* WIP
* WIP
* Simplified build script and fixed it to build all schemes.
* WIP
* Renamed script to build_all and added better output.
* Add scripts/list_xcode_workspaces.
* Filtered out the CocoaPods schemes.
* Use Xcode to update Swift to v3.
* Updated tracked touches map from NSNumber to Int.
* Fixed button sorting that was not actually sorting.
* targetContentOffset no longer allowed to be nil.
* "Fixed" failing test by reducing random number range?
* Swift 3 syntax change.
* Swift 3 syntax change.
* Removed invalid center-aligning tests.
Fixed default nav bar alignment test.
* [MDCInkView] cancelAllAnimationsAnimated should support disabling animation
* [MDCProgressView] Allow completion block to be modified if setHidden:animated:completion is called sequentially
* Call completion block immediately rather than storing as a property.
* Add nil check for completion block
* [Shrine] Update to Swift 3
* [AppBar] Add Objective C AppBar storyboard example
* Add right button bar item to AppBar swift demo
* Add plus shape icon to FAB
* Move plus symbol to example code
* Add plus icon asset, move to supplemental
* Remove unused methods
* Undo change to print.
* Move plus CAShapeLayer code into its own method
* Remove plus path method
* Use supplemental method to get plus symbol CAShapeLayer
We can credit any contributor who would like to be credited this way, by adding them on request to the AUTHORS file. The copyright statement changes are required for this to work. Note that this has...
Summary:
We can credit any contributor who would like to be credited this way, by adding them on request to the AUTHORS file. The copyright statement changes are required for this to work. Note that this has no legal change, since the contributors always retained their copyright despite the copyright notice, but it's a nice acknowledgement.
Changed copyright statement to include non-Google authors.
Command run:
find * \( -name '*\.m' -or -name '*\.h' -or -name '*\.swift' \) -and -not \( -path 'scripts/external*' -name Pods \) -print0 | xargs -0 sed -i '' 's/Copyright \(.*\) Google Inc/Copyright \1 the Material Components for iOS authors/'
Added non-source files.
Command run:
grep -Rl 'Copyright .* Google Inc' * --exclude-dir scripts/external --null | xargs -0 sed -i '' 's/Copyright \(.*\) Google Inc/Copyright \1 the Material Components for iOS authors/'
Reviewers: featherless, O1 Material components iOS, randallli
Reviewed By: O1 Material components iOS, randallli
Tags: #material_components_ios
Differential Revision: http://codereview.cc/D1415
Summary: "Material design" is not capitalized except when referring to the actual Material Design team at Google.
Reviewers: O1 Material components iOS, randallli
Reviewed By: O1 Material components iOS, randallli
Subscribers: randallli, featherless
Tags: #material_components_ios
Differential Revision: http://codereview.cc/D1306
Summary: Use the default value in our example
Test Plan: UI change is visible in the Button Storyboard and Programmatic sample.
Reviewers: randallli, O1 Material components iOS
Reviewed By: randallli, O1 Material components iOS
Tags: #material_components_ios
Differential Revision: http://codereview.cc/D1250