1228 Commits

Author SHA1 Message Date
Andreas Rossbacher
db7fde2cd6 [CardView] Fix potential Proguard/Dexguard/R8(?) optimization problem
Resolves https://github.com/material-components/material-components-android/pull/790

GIT_ORIGIN_REV_ID=fddc631d7a7c010044ab66247bec85f0aba097aa
PiperOrigin-RevId: 282769919
2019-12-02 17:31:16 -05:00
connieshi
3a337c0110 Hardcode non-framework classname used to call AccessibilityNodeInfo#setClassName so it doesn't get obfuscated by Proguard.
PiperOrigin-RevId: 282618314
2019-12-02 17:28:30 -05:00
cketcham
5d1a369ea0 Update Slider to use TooltipDrawable
PiperOrigin-RevId: 282583539
2019-12-02 17:27:40 -05:00
leticiars
29f3d05fa8 Adding helper text to the hint node so that TalkBack announces it when a text field is selected.
This provides more context for the user since the helper text is located below the text field (which is still focusable via TalkBack for now).

PiperOrigin-RevId: 282560641
2019-12-02 17:26:39 -05:00
cketcham
a282afe559 Initial implementation of TooltipDrawable
PiperOrigin-RevId: 282041829
2019-12-02 17:23:58 -05:00
marianomartin
c421319497 Remove tooltip from gradle
PiperOrigin-RevId: 282013901
2019-12-02 17:16:29 -05:00
cketcham
5f4a1394e5 Add OffsetEdgeTreatment
PiperOrigin-RevId: 281991688
2019-11-22 21:45:35 +00:00
marianomartin
781e79f4b1 Disable MaterialCardView bitmap drawing
PiperOrigin-RevId: 281825046
2019-11-22 21:27:37 +00:00
Material Design Team
cc9b9c1103 Add CollectionInfos and CollectionItemInfos to tabs for accessibility. Also make a tab non-clickable by a11y when it is selected.
PiperOrigin-RevId: 281785987
2019-11-22 21:25:50 +00:00
marianomartin
bb1e9e47a4 Enable non convex shadows on Q
PiperOrigin-RevId: 281750600
2019-11-22 21:24:52 +00:00
Material Design Team
bb72e50930 Automated g4 rollback of changelist 281530369
PiperOrigin-RevId: 281569140
2019-11-22 21:24:02 +00:00
hunterstich
7601cfda8e Add materialAlertDialogTheme to public resources.
Resolves https://github.com/material-components/material-components-android/issues/769

PiperOrigin-RevId: 281547191
2019-11-22 21:23:33 +00:00
Material Design Team
32362bed3d Automated g4 rollback of changelist 281519201
PiperOrigin-RevId: 281530369
2019-11-22 21:23:01 +00:00
connieshi
39e62ec220 Remove attrs check inside Chip#initMinTarget because the current context's theme may have custom values.
PiperOrigin-RevId: 281519201
2019-11-20 14:40:33 -05:00
cketcham
8ed1484690 Update MaterialShapeDrawable to handle overlapping edge and corners
PiperOrigin-RevId: 281498365
2019-11-20 14:39:06 -05:00
marianomartin
a4b90321e3 Add selection required option to MaterialButtonToggleGroup
Setting selectionRequired = true. Makes it so that the last option on the Group cannot be unselected. Similar to how a Text Alignment toggle works.

PiperOrigin-RevId: 281366158
2019-11-20 14:36:15 -05:00
marianomartin
573efa4b2f Add selection required option to ChipGroup
Resolves https://github.com/material-components/material-components-android/issues/651

PiperOrigin-RevId: 281274404
2019-11-19 10:31:43 -08:00
haodong
7823e88bb0 Forward fix lint error.
PiperOrigin-RevId: 281150048
2019-11-19 10:30:54 -08:00
cketcham
67491fca21 Add paddingBottomSystemWindowInsets to public attrs and update documentation
PiperOrigin-RevId: 281120848
2019-11-19 10:28:31 -08:00
connieshi
b200a3b6d2 Hardcode classname used to set accessibility item type to avoid being proguarded.
PiperOrigin-RevId: 281120646
2019-11-19 10:27:29 -08:00
connieshi
2eb666a7d8 Update chip's public.xml to include attributes for chipIconTint and closeIconTint
PiperOrigin-RevId: 281119011
2019-11-19 10:25:52 -08:00
dniz
1882fa96b5 Remove ThemeOverlay.AppCompat.Dark from Snackbar mtrl layouts
The theme overlay should no longer be needed now that we explicitly set colors on the Snackbar's message text and action button

Resolves https://github.com/material-components/material-components-android/issues/706

PiperOrigin-RevId: 281067788
2019-11-19 10:21:00 -08:00
leticiars
d2870fbb3f Fixing a11y warning when AutoCompleteTextView inside a TextInputLayout doesn't have a hint.
The hint should be retrieved from the text input layout as it is what takes care of the hint behavior.

PiperOrigin-RevId: 280526998
2019-11-15 15:12:41 -05:00
leticiars
aeb9eea9d8 Allow a content description to be set on a text field error view. This is useful for when the error message has special characters that TalkBack cannot read.
PiperOrigin-RevId: 280508115
2019-11-15 15:12:03 -05:00
marianomartin
1cc1dd5778 Automated g4 rollback of changelist 278624814
PiperOrigin-RevId: 280494190
2019-11-15 15:11:32 -05:00
ldjesper
e56db0cee9 Update CHAR_LIMIT to 2 for MaterialCalendar strings that require a sub-character for i18n
PiperOrigin-RevId: 280474887
2019-11-15 15:10:57 -05:00
marianomartin
7eb1af5f8e Support disabling bitmap drawing in MaterialShapeDrawable
Creating an additional bitmap affects performance and there are instances where it's not necessary.

Add the option to disable that.

PiperOrigin-RevId: 280434620
2019-11-15 15:09:41 -05:00
marianomartin
c266251ee9 Cleanup HeaderBehavior
PiperOrigin-RevId: 280004172
2019-11-12 16:24:26 -05:00
leticiars
20f113212d [TextInputLayout] Adding support for the collapsed label position to be determined via the edit text gravity, such as center_horizontal.
Resolves https://github.com/material-components/material-components-android/pull/311
Resolves https://github.com/material-components/material-components-android/issues/609

PiperOrigin-RevId: 279998938
2019-11-12 16:23:41 -05:00
Mahdi Hosseinzadeh
d0ddeb05c3 [TextField] Fix documentation errors
Resolves https://github.com/material-components/material-components-android/pull/749

GIT_ORIGIN_REV_ID=b019c4846473655df0f3ca9a2b9ef8a4fbf66334
PiperOrigin-RevId: 279996234
2019-11-12 16:23:14 -05:00
ldjesper
62a2164f18 Include separator characters for Samsung devices in MaterialDatePicker
Resolves https://github.com/material-components/material-components-android/issues/682

PiperOrigin-RevId: 279146671
2019-11-07 16:12:20 -05:00
leticiars
816f080be2 Fixing helper text disappearing when setError(null) is called and the error is already null.
Resolves https://github.com/material-components/material-components-android/issues/525
Resolves https://github.com/material-components/material-components-android/pull/737

PiperOrigin-RevId: 279121898
2019-11-07 16:11:49 -05:00
leticiars
4bff089310 Making sure hoveredFilledBackgroundColor defaults to default color if not set on a stateful CSL instead of to the disabled color.
PiperOrigin-RevId: 279120861
2019-11-07 16:11:23 -05:00
ldjesper
c097d3d335 Separate date format string from date hint string in MaterialDatePicker for better hints.
Resolves https://github.com/material-components/material-components-android/issues/695

PiperOrigin-RevId: 279095896
2019-11-07 16:10:05 -05:00
Mattia
d29daab572 [TextInputLayout] focusedStrokeColor should take into account the enabled color
Resolves https://github.com/material-components/material-components-android/pull/734

GIT_ORIGIN_REV_ID=36549f1519805be416aaf75cbb67be948c4b02e7
PiperOrigin-RevId: 278910639
2019-11-07 16:07:36 -05:00
marianomartin
5c922b4140 Add getter for listener to SwipeDismissBehavior
PiperOrigin-RevId: 278862529
2019-11-07 16:07:07 -05:00
connieshi
b58d3481c3 Restore padding after #setRippleColor update a chip's background.
PiperOrigin-RevId: 278660797
2019-11-06 10:18:27 -05:00
dniz
7f043206c0 Update ElevationOverlayProvider compositeOverlay() to preserve original background color alpha
PiperOrigin-RevId: 278625128
2019-11-06 10:17:01 -05:00
marianomartin
95c110bea2 Fix swipe dismiss behavior
PiperOrigin-RevId: 278624814
2019-11-06 10:15:20 -05:00
connieshi
de005027bc Fix bug in bottom navigation badge state restoration that did not set the badges on the menu item views.
Update catalog demo to save and restore states in the bottom navigation demos.

PiperOrigin-RevId: 278436621
2019-11-06 10:14:43 -05:00
marianomartin
56fbbe9ee5 Fix BottomNavigationView SavedState bug for null loader
Resolves https://github.com/material-components/material-components-android/issues/549

PiperOrigin-RevId: 278416562
2019-11-06 10:13:46 -05:00
haodong
7bcd5f606e Fixed popup menu on action bar.
* Made sure light/dark theme always shows popup menu in corresponding theme.
* Increased contrast of text in popup menu in dark theme.

PiperOrigin-RevId: 278397458
2019-11-04 13:09:28 -05:00
leticiars
27f7f4c6ba Fixing text field icons that are not clickable having ripple effect when text field is pressed.
Non clickable ImageViews inherit pressed state of parent views, so icons appeared as pressed even if they were not clickable/focusable.

PiperOrigin-RevId: 278381886
2019-11-04 13:05:10 -05:00
leticiars
61c00d746e Updating boxBackgroundColor filled text fields attr documentation to specify that default colors are used for hover and disabled states when a non stateful resource is specified.
PiperOrigin-RevId: 277983799
2019-11-04 13:04:16 -05:00
nkotula
8ca8e1bbdd [TextInputLayout] Add support for focused background color
Resolves https://github.com/material-components/material-components-android/pull/724

GIT_ORIGIN_REV_ID=8b272d736167cd0bff236b47049e247e3ec383a5
PiperOrigin-RevId: 277959398
2019-11-04 13:03:21 -05:00
hunterstich
f89b09f512 Add onBackground ColorStateLists
PiperOrigin-RevId: 277818139
2019-11-04 13:02:40 -05:00
haodong
7708ca4db1 Automated g4 rollback of changelist 277103254
PiperOrigin-RevId: 277545348
2019-11-01 13:28:40 -07:00
dniz
aa7d83333e Add popupMenuBackground theme attribute and combine light and dark Menu styles
into one style that references the new attribute

PiperOrigin-RevId: 277340044
2019-11-01 13:28:40 -07:00
xxfast
45bfd96a61 [Slider] Fix slider to invalidate after set value
Resolves https://github.com/material-components/material-components-android/pull/720

GIT_ORIGIN_REV_ID=e1eaf165d734b1c60c05116d200af4ff6f5c583e
PiperOrigin-RevId: 277319683
2019-11-01 13:28:40 -07:00
hunterstich
fdc243959f Update ExtendedFAB to use ShapeAppearanceModel.PILL
PiperOrigin-RevId: 277302581
2019-11-01 13:28:40 -07:00