stripe-android
stripe-android copied to clipboard
[BUG] Card scanning translation errors
Summary
I want to use the 'card scanning' feature of PaymentSheet in my app which is in French language. However, the messages are all in English rather than in French.
Code to reproduce
My supported locale language in my app is French:
ScreenUtilInit(
designSize: const Size(360, 690),
minTextAdapt: true,
builder: (context, _) => MaterialApp.router(
routerConfig: router,
theme: lightTheme,
localizationsDelegates: const [
GlobalMaterialLocalizations.delegate,
GlobalWidgetsLocalizations.delegate,
GlobalCupertinoLocalizations.delegate,
],
supportedLocales: const [
Locale('fr', 'FR'),
],
locale: const Locale('fr', 'FR')));
}
And my paymentSheet configuration adress is also FR:
val address = PaymentSheet.Address(country = "FR")
val billingDetails = PaymentSheet.BillingDetails(
address = address,
)
// Display paymentSheet
activity.paymentSheet.presentWithSetupIntent(
setupIntentClientSecret!!,
PaymentSheet.Configuration(
merchantDisplayName = merchantDisplayName!!,
defaultBillingDetails = billingDetails,
appearance =
PaymentSheet.Appearance(
primaryButton = PaymentSheet.PrimaryButton(
colorsLight = PaymentSheet.PrimaryButtonColors(background = Color.parseColor(
PaymentSheetChannelHandler.PAYMENT_SHEET_PRIMARY_COLOR
),
onBackground = Color.WHITE, border = Color.parseColor(PaymentSheetChannelHandler.PAYMENT_SHEET_PRIMARY_COLOR)),
)
),
primaryButtonLabel = "Ajouter la carte",
))
Android version
Reproduced on android version 12
Impacted devices
All our devices : Samsung S20 FE 5G, Huawei P30 and more...
Installation method
Gradle
Dependency Versions
kotlin: 1.9.0 stripe-android: 21.0.1 Android Gradle Plugin: 8.4.0 Gradle: 8.10.1
SDK classes
PaymentSheet