Skip to content

Commit 32e563d

Browse files
[LiPS] Verification dialog / full screen design adjustments (#10777)
* WIP. * Updates colors. * Adds colors. * Updates colors. * Updates darkMode. * Style fixes. * Updates screenshots. * Ktlint fixes. * Updates colors. * Updates colors. * Updates screenshots. * Merge fixes. * Updates text color. * Static analysis. * Regenerates screenshots. * Updates comment. * Adds missing screenshots. * Adds missing screenshots. * Fixes screenshots. * Updates screenshots. * Updates UI. * Reverts inline signup changes. * Reverts inline signup changes. * Updates test. * Adds new screenshots. * Deletes screenshots. * Reverts screenshots. * Reverts screenshots. * Reverts comment. * Apply custom stroke width only to Link * Fix lint --------- Co-authored-by: Till Hellmund <[email protected]>
1 parent 0e23e91 commit 32e563d

File tree

25 files changed

+551
-366
lines changed

25 files changed

+551
-366
lines changed

paymentsheet/api/paymentsheet.api

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -533,12 +533,32 @@ public final class com/stripe/android/link/ui/updatecard/ComposableSingletons$Up
533533
public final fun getLambda-2$paymentsheet_release ()Lkotlin/jvm/functions/Function2;
534534
}
535535

536+
public final class com/stripe/android/link/ui/verification/ComposableSingletons$VerificationBodyKt {
537+
public static final field INSTANCE Lcom/stripe/android/link/ui/verification/ComposableSingletons$VerificationBodyKt;
538+
public fun <init> ()V
539+
public final fun getLambda-1$paymentsheet_release ()Lkotlin/jvm/functions/Function2;
540+
public final fun getLambda-2$paymentsheet_release ()Lkotlin/jvm/functions/Function3;
541+
}
542+
543+
public final class com/stripe/android/link/ui/verification/ComposableSingletons$VerificationDialogKt {
544+
public static final field INSTANCE Lcom/stripe/android/link/ui/verification/ComposableSingletons$VerificationDialogKt;
545+
public fun <init> ()V
546+
public final fun getLambda-1$paymentsheet_release ()Lkotlin/jvm/functions/Function2;
547+
public final fun getLambda-2$paymentsheet_release ()Lkotlin/jvm/functions/Function2;
548+
}
549+
536550
public final class com/stripe/android/link/ui/verification/ComposableSingletons$VerificationScreenKt {
537551
public static final field INSTANCE Lcom/stripe/android/link/ui/verification/ComposableSingletons$VerificationScreenKt;
538552
public fun <init> ()V
539553
public final fun getLambda-1$paymentsheet_release ()Lkotlin/jvm/functions/Function2;
540-
public final fun getLambda-2$paymentsheet_release ()Lkotlin/jvm/functions/Function3;
541-
public final fun getLambda-3$paymentsheet_release ()Lkotlin/jvm/functions/Function2;
554+
}
555+
556+
public final class com/stripe/android/link/ui/verification/VerificationDialogKt {
557+
public static final fun VerificationDialogPreview (Landroidx/compose/runtime/Composer;I)V
558+
}
559+
560+
public final class com/stripe/android/link/ui/verification/VerificationScreenKt {
561+
public static final fun VerificationPreview (Landroidx/compose/runtime/Composer;I)V
542562
}
543563

544564
public final class com/stripe/android/link/ui/verification/VerificationViewState$Creator : android/os/Parcelable$Creator {

paymentsheet/detekt-baseline.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@
5252
<ID>LongMethod:USBankAccountForm.kt$@Composable private fun BillingDetailsForm( instantDebits: Boolean, formArgs: FormArguments, enabled: Boolean, isPaymentFlow: Boolean, nameController: TextFieldController, emailController: TextFieldController, phoneController: PhoneNumberController, addressController: AddressController, lastTextFieldIdentifier: IdentifierSpec?, sameAsShippingElement: SameAsShippingElement?, )</ID>
5353
<ID>LongMethod:USBankAccountFormViewModel.kt$USBankAccountFormViewModel$private fun createNewPaymentSelection( resultIdentifier: ResultIdentifier, last4: String?, bankName: String?, billingDetails: PaymentMethod.BillingDetails, ): PaymentSelection.New.USBankAccount</ID>
5454
<ID>LongMethod:UpdatePaymentMethodUI.kt$@Composable internal fun UpdatePaymentMethodUI(interactor: UpdatePaymentMethodInteractor, modifier: Modifier)</ID>
55+
<ID>LongMethod:VerificationBody.kt$@Composable internal fun VerificationBody( state: VerificationViewState, otpElement: OTPElement, onBack: () -> Unit, onFocusRequested: () -> Unit, didShowCodeSentNotification: () -> Unit, onChangeEmailClick: () -> Unit, onResendCodeClick: () -> Unit, )</ID>
56+
<ID>LongMethod:VerificationScreenshotTest.kt$VerificationScreenshotTest.Companion$private fun testCases(isDialog: Boolean): List&lt;TestCase></ID>
5557
<ID>MagicNumber:NewPaymentMethodTabLayoutUI.kt$.3f</ID>
5658
<ID>MagicNumber:NewPaymentMethodTabLayoutUI.kt$.4f</ID>
5759
<ID>MagicNumber:NewPaymentMethodTabLayoutUI.kt$.5f</ID>

paymentsheet/res/values/strings.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,8 @@ to be saved and used in future checkout sessions. -->
5555
<string name="stripe_link_update_card_title">Update card</string>
5656
<!-- Instructs the user to enter the code sent to their phone number in order to login to Link -->
5757
<string name="stripe_link_verification_message">Enter the code sent to %s to use your saved information.</string>
58+
<!-- Instructs the user to enter the code sent to their phone number in order to login to Link -->
59+
<string name="stripe_link_verification_message_short">Enter the code sent to %s.</string>
5860
<!-- Menu option to update card on the wallet screen on Link native -->
5961
<string name="stripe_link_wallet_menu_action_update_card">Update card</string>
6062
<!-- Title of the logout action. -->
@@ -226,6 +228,8 @@ to be saved and used in future checkout sessions. -->
226228
<string name="stripe_upi_polling_payment_failed_title">Payment failed</string>
227229
<!-- Title for a button that allows the user to use a different email in the signup flow. -->
228230
<string name="stripe_verification_change_email">Change email</string>
231+
<!-- Title for a button that allows the user to use a different email in the signup flow. -->
232+
<string name="stripe_verification_change_email_new">Not you?</string>
229233
<!-- Text of a notification shown to the user when a login code is successfully sent via SMS. -->
230234
<string name="stripe_verification_code_sent">Code sent</string>
231235
<!-- Two factor authentication screen heading -->

paymentsheet/src/main/java/com/stripe/android/link/theme/Color.kt

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -140,12 +140,6 @@ internal object LinkThemeConfig {
140140
selectedColor = LinkTheme.colors.buttonBrand,
141141
unselectedColor = if (isSystemInDarkTheme()) Neutral700 else LinkTheme.colors.borderDefault
142142
)
143-
144-
/**
145-
* Scrim color does not have a match in the Link theme, so we use a default color matching Elements.
146-
*/
147-
internal val LinkColors.scrim: Color
148-
get() = Color.Black.copy(alpha = 0.32f)
149143
}
150144

151145
@Composable

0 commit comments

Comments
 (0)