From 2f3c47dfa14cd2066ebfff89c3c43eb12c12a119 Mon Sep 17 00:00:00 2001 From: Michael Shafrir Date: Tue, 14 Jan 2020 09:01:04 -0500 Subject: [PATCH 1/3] Fix styling of CardInputWidget `com.google.android.material:material:1.1.0-rc01` breaks `CardInputWidget` styling. Fix this by explicitly setting a style that extends `Widget.Design.TextInputLayout`. Fixes #2053 --- example/build.gradle | 3 ++- example/res/values/themes.xml | 3 +-- stripe/res/layout/card_input_widget.xml | 12 ++++++++---- stripe/res/values/styles.xml | 7 +++++++ 4 files changed, 18 insertions(+), 7 deletions(-) diff --git a/example/build.gradle b/example/build.gradle index d77849a43d7..2b72fa30cba 100644 --- a/example/build.gradle +++ b/example/build.gradle @@ -44,12 +44,13 @@ dependencies { implementation 'androidx.recyclerview:recyclerview:1.1.0' implementation "androidx.lifecycle:lifecycle-viewmodel:2.1.0" implementation 'androidx.lifecycle:lifecycle-extensions:2.1.0' + implementation 'com.google.android.material:material:1.1.0-rc01' implementation 'com.google.android.gms:play-services-wallet:18.0.0' /* Needed for RxAndroid */ implementation 'io.reactivex.rxjava2:rxandroid:2.1.1' - implementation 'io.reactivex.rxjava2:rxjava:2.2.16' + implementation 'io.reactivex.rxjava2:rxjava:2.2.17' /* Needed for Rx Bindings on views */ implementation 'com.jakewharton.rxbinding2:rxbinding:2.2.0' diff --git a/example/res/values/themes.xml b/example/res/values/themes.xml index 4f001b53f70..6652dd42d58 100644 --- a/example/res/values/themes.xml +++ b/example/res/values/themes.xml @@ -1,6 +1,6 @@ - - diff --git a/stripe/res/layout/card_input_widget.xml b/stripe/res/layout/card_input_widget.xml index 40e11e6d1f0..a8f6dd6ea5b 100644 --- a/stripe/res/layout/card_input_widget.xml +++ b/stripe/res/layout/card_input_widget.xml @@ -36,7 +36,8 @@ android:nextFocusForward="@+id/tl_expiry_date" android:nextFocusDown="@+id/tl_expiry_date" android:contentDescription="@string/acc_label_card_number" - app:hintEnabled="false"> + app:hintEnabled="false" + style="@style/Stripe.CardInputWidget.TextInputLayout"> + app:hintEnabled="false" + style="@style/Stripe.CardInputWidget.TextInputLayout"> + app:hintEnabled="false" + style="@style/Stripe.CardInputWidget.TextInputLayout"> + app:hintEnabled="false" + style="@style/Stripe.CardInputWidget.TextInputLayout"> + +