* [Collections] Update collections to support iPhone X
The collections use the contentInset to compute the width of the cells.
With iPhone X, the width must take into account possible inset of the side.
This patch makes sure that the collection takes into account the adjustedContentInset, which may take the safe area into consideration.
Closes#1980
* Correct respondsToSelect
* Use macro + @available instead of NSInvocation
* Fix CollectionCellsExamples and add a swift version check to the swift example.
* Make UIScrollViewContentInsetAdjustmentAlways the default
* Remove override from CollectionsSectionInsetsExample
Using `[self class]` when loading a bundle can result in missed resources when
a method is called from a subclass. To prevent these errors, components should
be explicit about which class is being used to load bundles.
References #1941 (Components)
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
Dismissing a cell or section in a UICollectionView that uses an
MDCCollectionViewController with the default editor will now use a
simple linear dismiss animation.
Closes#1833
MDCCollectionViewController does not receive messages for
`-collectionView:didSelectItemAtIndexPath:` if it responds `NO` to
`-collectionView:shouldHighlightCellAtIndexPath:`. By allowing
highlight, but not performing a highlight animation on the cell, the delegate
will receive *didSelect* messages for cells with hidden ink.
Closes#1446
If a section no longer has any cells remaining, the
UICollectionViewLayoutAttributes for that section's decorationView
should not set the frame to CGRectNull. Instead, the frame should
remain untouched.
Closes#1844
When using the swipe-to-dimiss gesture on large screens, the distance on which the user has to move the item can be big. This commit limits the distance by using the width of the item instead of the width of the collection.
Closes#1780
The Info Bar view wasn't correctly applying the z-index value from the
LayoutAttributes. This resulted in the header appearing behind the
collectionView cells on iOS 11.
Closes#1786
Calling the public API for determining the insets for a CollectionView
section instead of the internal method. This allows subclasses to
override the implementation and determine custom section insets.
Closes#1738
References #1711
* [Collections] - Fix for possible infinite recursion in the case the UICOllectionViewDelegate methods call loadView if self.collectionView has not been set.
* [Collections] - Removed commented code, added comment as to why we shouldn’t call delegate method, updated passed argument in method
* [Collections] - Changed from self.collectionView to passed in collectionView param in delegate methods. Added check for nil _styler and divide by zero for column count
* [Collections] Add "editing" performance example
New example to demonstrate scrolling performance when a collection
contains a large number of cells. "Editing" mode is currently very
inefficient.
* Refactoring, pulling some code into supplemental
* Making cell identifier symbol unique
* [Collections] Add StylingDelegate methods to control separator display
Adds methods to MDCCollectionViewStylingDelegate, allowing the delegate to control the display of the separator on cells, header and footer.
Closes#1406
* [Collections] Allow custom UIEdgeInsets
MDCCollectionViewController implements custom logic for computing the
`UIEdgeInsets` depending on the `MDCCollectionViewCellStyle` and the
`MDCCollectionViewCellLayoutType`. Subclasses need to override this
functionality to customize their presentation.
* MDCCollectionViewController will use the public
`-collectionView:layout:section` to compute the width of its
supplementary view instead of the internal implementation directly.
* Update the Collections layout example to have different horizontal
edge insets depending on the view's horizontal size class.
Closes#1507
* Add EarlGrey test to verify the insets exampl
* Removing changes to Collection Cells example
* Running code formatter
* Supplemental files.
* Some code clean-up based on willlarche@'s comments
* Removing old header, small cleanup
* Changing block parameter types to match the desired class
* One last id to remove
* Making Earl Grey test a bit better. Some formatting
* Fixing a bug with the flowLayout delegate
If Swipe-to-Dismiss is enabled on a collection, all gestures different from swipe-to-dismiss trigger UIGestureRecognizerStateEnded on the swipe-to-dismiss gesture.
This commit modifies the cancellation of the gesture by not invalidating the layout if the dismissal has not started.
This closes#1613
Make the code base more portable by replacing some GNU extension code
with C99-compatible versions.
* Replace shortcut ?: operator with explicit middle (true) terms
* Remove pointer inequality checks in conditionals
* (Cleanup) Change to #include for <tgmath.h> based on style guide
Closes#846
* [ColorThemes] Use umbrella header instead of MDCColorScheme
* [Application] Use umbrella header instead of class header
* [Button] use umbrella header in private header
* [Typography] use umbrella header in private header
* icons using umbrella header in individual icon class
* [Icons] added header to umbrella header
* [collection] umbrella header instead of class header in test
* [Collections] use umbrella header in private header
* [ActivityIndicator] use umbrella header in private header
* [ButtonBar] use umbrella header in private header
* [Dialog] use umbrella header in private header
* [featurehighlight] use umbrella header in private header
* [snackbar] use umbrella header in private header
* [textFields] use umbrella header in private header
* [thumbtrack] use umbrella header in private header
* [Overlay] use umbrella header in private header
also removed spurious ’s’ at end of MaterialOverlay.h file
* [slider] use umbrella header in private header
* [buttonBar] use umbrella header in private header
* [slider] use umbrella header in test
* [Overlay] fixed overlay reference to use umbrella header
* [Docs] Marks component files as API documentation roots.
Used by the site generator to determine where to build API docs. I
marked everything built by the previous version.
* [Docs] Adds a prefix to all Material guidelines links.
* [Docs] Adds API doc links to some components.
* [Docs] Changes an icon list class name.
* [Docs] Adds annotations to all installation code snippets.
* [Docs] Fixes screenshot sizes in PageControl README.
* [Docs] Fixes a broken link on the homepage.
* [Docs] Adds a stable repository branch field to the site metadata.
Used to link to the GitHub source tree.
* [Docs] Specify platform in docs root title.
* [Docs] Adds platform configuration for the doc site.
* [Docs] Adds path metadata for documentation site.
This field is used to determine where the file will appear in the
doc site.
* [Docs] Updates Material guideline links to latest URL.
material.google.com -> material.io/guidelines
* [Docs] Introduces a separate component index for the docsite.
* [Docs] Changes the directory used for site generation.
* [Docs] Moves documentation-site-only Markdown into its own directory.
* [Docs] Changes material.io links to use https.
* [Docs] Renames the howto and contributing docsite sections to docs.
* [Docs] Adds a navTitle field to the collection editing/styling pages.
* [Docs] Changes the FAQ heading to be one size bigger.
* [Docs] Changes the tutorial title.
* [Docs] Adds icons to three more components.
* [Docs] Introduces a root component directory called /catalog/.
* [Docs] Adds an icon to the AnimationTiming component.
* [Docs] Adds an icon for the typography component.
* [Docs] Reformats the docsite index.