Chip was setting chipCornerRadius in the style.
The chipCornerRadius attribute takes precedence over shapeAppearance cornerSize attributes in order to respect values previously set by the user. However, including it in the chip style prevents a cornerSize set in a shapeAppearance or shapeAppearanceOverlay from taking effect. This commit removes chipCornerSize from the chip style to respect cornerSize values.
PiperOrigin-RevId: 241014276
The shapeAppearanceOverlay attribute was not necessary to achieve the rounded 0 shape appearance for the BottomSheet styles. This commit removes the shapeAppearanceOverlay.
PiperOrigin-RevId: 241006967
Some public methods were missing documentation.
Also remove unnecessary hyphenation from methods that used hyphenation to describe the corner treatment positioning (ex: top-left -> top left).
PiperOrigin-RevId: 239882358
Caused by AppBarLayout + WindowInset commit, which breaks some incorrect
assumptions in CTL. Fixed by breaking apart ViewOffsetHelper
so that its tracking of layout coordinates, and applying
offsets, are done at different times.
Also fixed catalog's AppBar sample layouts to set IDs,
enabling state restoration to work.
PiperOrigin-RevId: 239592953
The boxCornerRadius attributes were still in the MDC styles, which means that the shapeAppearance and shapeAppearanceOverlay attributes were not respected. This commit removes the boxCornerRadius attributes to ensure that changes to shapeAppearance or shapeAppearanceOverlay are respected where shape theming is enabled.
PiperOrigin-RevId: 239214930
The TabLayoutMediator makes it possible for a ViewPager2 to be linked to
a TabLayout similarly to how a ViewPager was linked to TabLayout.
PiperOrigin-RevId: 239207045
NOTE: This case is not supported. Limited support is provided when feasible in order to avoid breaking existing usages, but all TextInputLayouts used with a Widget.MaterialComponents style and a non-Widget.MaterialComponents input child should update the input child to use a Widget.MaterialComponents.TextInputEditText style to avoid future breakages.
PiperOrigin-RevId: 239047527
For that reason, users should opt to use the start icon API instead of setting a start/left compound drawable on the text field's edit text.
PiperOrigin-RevId: 238984066
The OnChangedListener provides a callback that MaterialShapeDrawables can use to invalidate themselves when the associated ShapeAppearanceModel changes. This allows for modifying the ShapeAppearanceModel through the get/setShapeAppearance methods that the Shapeable interface exposes without having to update the client to redraw itself.
PiperOrigin-RevId: 238703600
For API 18+, the BadgeDrawable will be added as a view overlay.
For pre-API 18, the BadgeDrawable will be set as the foreground of a FrameLayout that is an ancestor of the anchor.
PiperOrigin-RevId: 238661951
When AppBarLayout is used with a CollapsingToolbarLayout
child, it currently does not handle WindowInsets
very well. This commit fixes that by properly handling
insets.
The primary issue is when an AppBarLayout is used
with a single Toolbar (very common use case), where
the Toolbar will currently be displayed behind the status bar.
Another issue is with HeaderScrollingViewBehavior.
To workaround CoordinatorLayout using its 'compatible measuring'
for insets, the behavior manually sets the scrolling view to fit
system windows. This has other issues though because
that view will get padded in. Fixed by manually adding the insets
back into the measured dimensions.
Also updated the catalog layouts to make use of
android:fitsSystemWindows=true
Resolves https://github.com/material-components/material-components-android/pull/299
PiperOrigin-RevId: 238396626