@pi-spi/app 1.5.1 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +64 -30
- package/example/App.tsx +27 -24
- package/lib/module/core/assets.js +0 -7
- package/lib/module/core/assets.js.map +1 -1
- package/lib/module/core/di.js +17 -8
- package/lib/module/core/di.js.map +1 -1
- package/lib/module/core/pi_spi_custom_theme.js +22 -10
- package/lib/module/core/pi_spi_custom_theme.js.map +1 -1
- package/lib/module/core/pi_spi_sdk_config.js +22 -8
- package/lib/module/core/pi_spi_sdk_config.js.map +1 -1
- package/lib/module/core/theme.js +345 -225
- package/lib/module/core/theme.js.map +1 -1
- package/lib/module/index.js +1 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/l10n/app_localizations.js.map +1 -1
- package/lib/module/l10n/app_localizations_en.js +26 -1
- package/lib/module/l10n/app_localizations_en.js.map +1 -1
- package/lib/module/l10n/app_localizations_fr.js +26 -1
- package/lib/module/l10n/app_localizations_fr.js.map +1 -1
- package/lib/module/l10n/app_localizations_pt.js +26 -1
- package/lib/module/l10n/app_localizations_pt.js.map +1 -1
- package/lib/module/modules/alias/presentation/pages/alias_delete_btn_widget.js +15 -19
- package/lib/module/modules/alias/presentation/pages/alias_delete_btn_widget.js.map +1 -1
- package/lib/module/modules/alias/presentation/pages/alias_page_claim.js +4 -11
- package/lib/module/modules/alias/presentation/pages/alias_page_claim.js.map +1 -1
- package/lib/module/modules/compte/presentation/pages/compte_details_widget.js +6 -7
- package/lib/module/modules/compte/presentation/pages/compte_details_widget.js.map +1 -1
- package/lib/module/modules/config/domain/models/config_keys.js +3 -1
- package/lib/module/modules/config/domain/models/config_keys.js.map +1 -1
- package/lib/module/modules/config/domain/services/config_service.js +31 -2
- package/lib/module/modules/config/domain/services/config_service.js.map +1 -1
- package/lib/module/modules/home/presentation/pages/home_tab_compte.js +0 -1
- package/lib/module/modules/home/presentation/pages/home_tab_compte.js.map +1 -1
- package/lib/module/modules/home/presentation/pages/home_tab_compte_more_menu.js +38 -37
- package/lib/module/modules/home/presentation/pages/home_tab_compte_more_menu.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/compte/profile_compte_page.js +25 -11
- package/lib/module/modules/profile/presentation/pages/compte/profile_compte_page.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page.js +14 -20
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page_notifications.js +109 -103
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page_notifications.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page_notifications_son.js +55 -72
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page_notifications_son.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page_qrcode.js +31 -45
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page_qrcode.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page_theme.js +175 -203
- package/lib/module/modules/profile/presentation/pages/parametre/profile_parametre_page_theme.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/profile_app_bar.js +26 -0
- package/lib/module/modules/profile/presentation/pages/profile_app_bar.js.map +1 -0
- package/lib/module/modules/profile/presentation/pages/profile_menu.js +144 -34
- package/lib/module/modules/profile/presentation/pages/profile_menu.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/profile_page.js +95 -63
- package/lib/module/modules/profile/presentation/pages/profile_page.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/profile_page_avatar.js +97 -45
- package/lib/module/modules/profile/presentation/pages/profile_page_avatar.js.map +1 -1
- package/lib/module/modules/profile/presentation/pages/profile_page_contacts.js +9 -8
- package/lib/module/modules/profile/presentation/pages/profile_page_contacts.js.map +1 -1
- package/lib/module/modules/search/presentation/pages/search_fonctionnalites.js +26 -2
- package/lib/module/modules/search/presentation/pages/search_fonctionnalites.js.map +1 -1
- package/lib/module/modules/search/presentation/pages/search_page.js +0 -1
- package/lib/module/modules/search/presentation/pages/search_page.js.map +1 -1
- package/lib/module/modules/transactions/presentation/pages/transaction_details/transaction_details_page_recu.js +3 -1
- package/lib/module/modules/transactions/presentation/pages/transaction_details/transaction_details_page_recu.js.map +1 -1
- package/lib/module/modules/transactions/presentation/pages/transaction_rtp/transaction_rtp_page.js +4 -11
- package/lib/module/modules/transactions/presentation/pages/transaction_rtp/transaction_rtp_page.js.map +1 -1
- package/lib/module/modules/transactions/presentation/pages/transaction_rtp/transaction_rtp_page_actions.js +13 -10
- package/lib/module/modules/transactions/presentation/pages/transaction_rtp/transaction_rtp_page_actions.js.map +1 -1
- package/lib/module/modules/transactions/presentation/pages/transaction_search/transaction_search_page_filters.js +5 -4
- package/lib/module/modules/transactions/presentation/pages/transaction_search/transaction_search_page_filters.js.map +1 -1
- package/lib/module/modules/transactions/presentation/pages/transaction_split/transaction_split_page_repartition.js +2 -2
- package/lib/module/modules/transactions/presentation/pages/transaction_split/transaction_split_page_repartition.js.map +1 -1
- package/lib/module/pi_spi_sdk_entry.js +7 -2
- package/lib/module/pi_spi_sdk_entry.js.map +1 -1
- package/lib/module/shared/utils/color.js +15 -0
- package/lib/module/shared/utils/color.js.map +1 -0
- package/lib/module/shared/widgets/custom_progressbar.js +3 -2
- package/lib/module/shared/widgets/custom_progressbar.js.map +1 -1
- package/lib/module/shared/widgets/error_card_widget.js +70 -0
- package/lib/module/shared/widgets/error_card_widget.js.map +1 -0
- package/lib/module/shared/widgets/selection.js +136 -0
- package/lib/module/shared/widgets/selection.js.map +1 -0
- package/lib/typescript/src/core/assets.d.ts +0 -7
- package/lib/typescript/src/core/assets.d.ts.map +1 -1
- package/lib/typescript/src/core/di.d.ts.map +1 -1
- package/lib/typescript/src/core/pi_spi_custom_theme.d.ts +17 -8
- package/lib/typescript/src/core/pi_spi_custom_theme.d.ts.map +1 -1
- package/lib/typescript/src/core/pi_spi_sdk_config.d.ts +22 -8
- package/lib/typescript/src/core/pi_spi_sdk_config.d.ts.map +1 -1
- package/lib/typescript/src/core/theme.d.ts +123 -53
- package/lib/typescript/src/core/theme.d.ts.map +1 -1
- package/lib/typescript/src/index.d.ts +1 -1
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/l10n/app_localizations.d.ts +50 -0
- package/lib/typescript/src/l10n/app_localizations.d.ts.map +1 -1
- package/lib/typescript/src/l10n/app_localizations_en.d.ts.map +1 -1
- package/lib/typescript/src/l10n/app_localizations_fr.d.ts.map +1 -1
- package/lib/typescript/src/l10n/app_localizations_pt.d.ts.map +1 -1
- package/lib/typescript/src/modules/alias/presentation/pages/alias_delete_btn_widget.d.ts.map +1 -1
- package/lib/typescript/src/modules/alias/presentation/pages/alias_page_claim.d.ts.map +1 -1
- package/lib/typescript/src/modules/compte/presentation/pages/compte_details_widget.d.ts.map +1 -1
- package/lib/typescript/src/modules/config/domain/models/config_keys.d.ts +3 -1
- package/lib/typescript/src/modules/config/domain/models/config_keys.d.ts.map +1 -1
- package/lib/typescript/src/modules/config/domain/services/config_service.d.ts +7 -0
- package/lib/typescript/src/modules/config/domain/services/config_service.d.ts.map +1 -1
- package/lib/typescript/src/modules/home/presentation/pages/home_tab_compte_more_menu.d.ts +2 -0
- package/lib/typescript/src/modules/home/presentation/pages/home_tab_compte_more_menu.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/compte/profile_compte_page.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/parametre/profile_parametre_page.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/parametre/profile_parametre_page_notifications.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/parametre/profile_parametre_page_notifications_son.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/parametre/profile_parametre_page_qrcode.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/parametre/profile_parametre_page_theme.d.ts +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/parametre/profile_parametre_page_theme.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/profile_app_bar.d.ts +5 -0
- package/lib/typescript/src/modules/profile/presentation/pages/profile_app_bar.d.ts.map +1 -0
- package/lib/typescript/src/modules/profile/presentation/pages/profile_menu.d.ts +31 -4
- package/lib/typescript/src/modules/profile/presentation/pages/profile_menu.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/profile_page.d.ts +4 -1
- package/lib/typescript/src/modules/profile/presentation/pages/profile_page.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/profile_page_avatar.d.ts +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/profile_page_avatar.d.ts.map +1 -1
- package/lib/typescript/src/modules/profile/presentation/pages/profile_page_contacts.d.ts.map +1 -1
- package/lib/typescript/src/modules/search/presentation/pages/search_fonctionnalites.d.ts.map +1 -1
- package/lib/typescript/src/modules/transactions/presentation/pages/transaction_rtp/transaction_rtp_page.d.ts.map +1 -1
- package/lib/typescript/src/modules/transactions/presentation/pages/transaction_rtp/transaction_rtp_page_actions.d.ts.map +1 -1
- package/lib/typescript/src/shared/utils/color.d.ts +7 -0
- package/lib/typescript/src/shared/utils/color.d.ts.map +1 -0
- package/lib/typescript/src/shared/widgets/custom_progressbar.d.ts.map +1 -1
- package/lib/typescript/src/shared/widgets/error_card_widget.d.ts +11 -0
- package/lib/typescript/src/shared/widgets/error_card_widget.d.ts.map +1 -0
- package/lib/typescript/src/shared/widgets/selection.d.ts +21 -0
- package/lib/typescript/src/shared/widgets/selection.d.ts.map +1 -0
- package/package.json +1 -1
- package/src/core/assets.ts +0 -7
- package/src/core/di.ts +13 -8
- package/src/core/pi_spi_custom_theme.ts +22 -15
- package/src/core/pi_spi_sdk_config.ts +27 -9
- package/src/core/theme.ts +381 -269
- package/src/index.ts +1 -1
- package/src/l10n/app_localizations.ts +50 -0
- package/src/l10n/app_localizations_en.ts +25 -0
- package/src/l10n/app_localizations_fr.ts +25 -0
- package/src/l10n/app_localizations_pt.ts +25 -0
- package/src/modules/alias/presentation/pages/alias_delete_btn_widget.tsx +13 -12
- package/src/modules/alias/presentation/pages/alias_page_claim.tsx +5 -4
- package/src/modules/compte/presentation/pages/compte_details_widget.tsx +3 -4
- package/src/modules/config/domain/models/config_keys.ts +3 -1
- package/src/modules/config/domain/services/config_service.ts +31 -2
- package/src/modules/home/presentation/pages/home_tab_compte.tsx +1 -1
- package/src/modules/home/presentation/pages/home_tab_compte_more_menu.tsx +34 -42
- package/src/modules/profile/presentation/pages/compte/profile_compte_page.tsx +15 -7
- package/src/modules/profile/presentation/pages/parametre/profile_parametre_page.tsx +12 -17
- package/src/modules/profile/presentation/pages/parametre/profile_parametre_page_notifications.tsx +89 -68
- package/src/modules/profile/presentation/pages/parametre/profile_parametre_page_notifications_son.tsx +84 -54
- package/src/modules/profile/presentation/pages/parametre/profile_parametre_page_qrcode.tsx +28 -24
- package/src/modules/profile/presentation/pages/parametre/profile_parametre_page_theme.tsx +121 -131
- package/src/modules/profile/presentation/pages/profile_app_bar.tsx +21 -0
- package/src/modules/profile/presentation/pages/profile_menu.tsx +126 -33
- package/src/modules/profile/presentation/pages/profile_page.tsx +90 -66
- package/src/modules/profile/presentation/pages/profile_page_avatar.tsx +69 -28
- package/src/modules/profile/presentation/pages/profile_page_contacts.tsx +5 -4
- package/src/modules/search/presentation/pages/search_fonctionnalites.ts +40 -7
- package/src/modules/search/presentation/pages/search_page.tsx +1 -1
- package/src/modules/transactions/presentation/pages/transaction_details/transaction_details_page_recu.tsx +3 -1
- package/src/modules/transactions/presentation/pages/transaction_rtp/transaction_rtp_page.tsx +2 -4
- package/src/modules/transactions/presentation/pages/transaction_rtp/transaction_rtp_page_actions.tsx +13 -6
- package/src/modules/transactions/presentation/pages/transaction_search/transaction_search_page_filters.tsx +4 -4
- package/src/modules/transactions/presentation/pages/transaction_split/transaction_split_page_repartition.tsx +2 -2
- package/src/pi_spi_sdk_entry.tsx +9 -2
- package/src/shared/utils/color.ts +14 -0
- package/src/shared/widgets/custom_progressbar.tsx +3 -2
- package/src/shared/widgets/error_card_widget.tsx +58 -0
- package/src/shared/widgets/selection.tsx +98 -0
- package/assets/images/theme_light_blue.jpeg +0 -0
- package/assets/images/theme_light_green.jpeg +0 -0
- package/assets/images/theme_light_orange.jpeg +0 -0
- package/assets/images/theme_light_pink.jpeg +0 -0
- package/assets/images/theme_light_purple.jpeg +0 -0
- package/assets/images/theme_light_red.jpeg +0 -0
- package/assets/images/theme_light_yellow.jpeg +0 -0
package/src/index.ts
CHANGED
|
@@ -22,7 +22,7 @@ export {
|
|
|
22
22
|
type PiSpiLogLevel,
|
|
23
23
|
} from './core/pi_spi_sdk_config';
|
|
24
24
|
export { PiSpiCustomTheme } from './core/pi_spi_custom_theme';
|
|
25
|
-
export { Themes, type ThemeData } from './core/theme';
|
|
25
|
+
export { Accents, Themes, type ThemeData } from './core/theme';
|
|
26
26
|
export {
|
|
27
27
|
type AppLocalizations,
|
|
28
28
|
type SupportedLocaleCode,
|
|
@@ -915,6 +915,8 @@ export interface AppLocalizations {
|
|
|
915
915
|
readonly transactionDetailsCancelRejectMessage: string;
|
|
916
916
|
/** Send receipt */
|
|
917
917
|
readonly transactionDetailsRecuTitle: string;
|
|
918
|
+
/** Issued on: */
|
|
919
|
+
readonly transactionDetailsRecuPdfEditeLe: string;
|
|
918
920
|
/** You can download or share the PDF file */
|
|
919
921
|
readonly transactionDetailsRecuSubTitle: string;
|
|
920
922
|
/** Identifier */
|
|
@@ -1215,6 +1217,32 @@ export interface AppLocalizations {
|
|
|
1215
1217
|
readonly appSettingPageMenuThemeDefault: string;
|
|
1216
1218
|
/** Apparence */
|
|
1217
1219
|
readonly appSettingPageMenuThemePageTitle: string;
|
|
1220
|
+
/** Theme */
|
|
1221
|
+
readonly appSettingPageThemeSection: string;
|
|
1222
|
+
/** Accent colour */
|
|
1223
|
+
readonly appSettingPageAccentSection: string;
|
|
1224
|
+
/** Default */
|
|
1225
|
+
readonly appSettingPageAccentDefaut: string;
|
|
1226
|
+
/** Green */
|
|
1227
|
+
readonly appSettingPageAccentVert: string;
|
|
1228
|
+
/** Blue */
|
|
1229
|
+
readonly appSettingPageAccentBleu: string;
|
|
1230
|
+
/** Red */
|
|
1231
|
+
readonly appSettingPageAccentRouge: string;
|
|
1232
|
+
/** Orange */
|
|
1233
|
+
readonly appSettingPageAccentOrange: string;
|
|
1234
|
+
/** Purple */
|
|
1235
|
+
readonly appSettingPageAccentViolet: string;
|
|
1236
|
+
/** Pink */
|
|
1237
|
+
readonly appSettingPageAccentRose: string;
|
|
1238
|
+
/** Turquoise */
|
|
1239
|
+
readonly appSettingPageAccentTurquoise: string;
|
|
1240
|
+
/** Terracotta */
|
|
1241
|
+
readonly appSettingPageAccentTerracotta: string;
|
|
1242
|
+
/** Burgundy */
|
|
1243
|
+
readonly appSettingPageAccentBordeaux: string;
|
|
1244
|
+
/** Slate */
|
|
1245
|
+
readonly appSettingPageAccentArdoise: string;
|
|
1218
1246
|
/** My QR code by default */
|
|
1219
1247
|
readonly appSettingPageMenuQrCodeTitle: string;
|
|
1220
1248
|
/** Enable to display your QR Code by default */
|
|
@@ -1389,6 +1417,28 @@ export interface AppLocalizations {
|
|
|
1389
1417
|
readonly searchVoicePrompt: string;
|
|
1390
1418
|
/** Voice search is not available. Check microphone access in settings. */
|
|
1391
1419
|
readonly searchVoiceUnavailable: string;
|
|
1420
|
+
/** Profile */
|
|
1421
|
+
readonly profilePageTitle: string;
|
|
1422
|
+
/** My account */
|
|
1423
|
+
readonly profilePageSectionCompte: string;
|
|
1424
|
+
/** Support */
|
|
1425
|
+
readonly profilePageSectionAssistance: string;
|
|
1426
|
+
/** Preferences */
|
|
1427
|
+
readonly appSettingPageSectionPreferences: string;
|
|
1428
|
+
/** Danger zone */
|
|
1429
|
+
readonly comptePageSectionZoneSensible: string;
|
|
1430
|
+
/** Notifications */
|
|
1431
|
+
readonly searchNotificationsTitle: string;
|
|
1432
|
+
/** App theme */
|
|
1433
|
+
readonly searchThemeTitle: string;
|
|
1434
|
+
/** Notification settings */
|
|
1435
|
+
readonly searchNotificationsParametreTitle: string;
|
|
1436
|
+
/** View the notifications received */
|
|
1437
|
+
readonly searchNotificationsSubTitle: string;
|
|
1438
|
+
/** Light, dark or system, and colour */
|
|
1439
|
+
readonly searchThemeSubTitle: string;
|
|
1440
|
+
/** Notification style, sound and vibration */
|
|
1441
|
+
readonly searchNotificationsParametreSubTitle: string;
|
|
1392
1442
|
}
|
|
1393
1443
|
|
|
1394
1444
|
export const supportedLocales = ['fr', 'en', 'pt'] as const;
|
|
@@ -464,6 +464,7 @@ If this request comes from someone you trust, simply add their alias to your con
|
|
|
464
464
|
transactionDetailsCancelReasonLabel: `Reason`,
|
|
465
465
|
transactionDetailsCancelRejectMessage: `The cancellation request has been successfully rejected`,
|
|
466
466
|
transactionDetailsRecuTitle: `Send receipt`,
|
|
467
|
+
transactionDetailsRecuPdfEditeLe: `Issued on:`,
|
|
467
468
|
transactionDetailsRecuSubTitle: `You can download or share the PDF file`,
|
|
468
469
|
transactionDetailsRecuInfoIdentifiant: `Identifier`,
|
|
469
470
|
transactionDetailsRecuInfoReference: `Reference`,
|
|
@@ -619,6 +620,19 @@ Scanning will be automatic`,
|
|
|
619
620
|
appSettingPageMenuThemeCustom: `App theme`,
|
|
620
621
|
appSettingPageMenuThemeDefault: `System`,
|
|
621
622
|
appSettingPageMenuThemePageTitle: `Apparence`,
|
|
623
|
+
appSettingPageThemeSection: `Theme`,
|
|
624
|
+
appSettingPageAccentSection: `Accent colour`,
|
|
625
|
+
appSettingPageAccentDefaut: `Default`,
|
|
626
|
+
appSettingPageAccentVert: `Green`,
|
|
627
|
+
appSettingPageAccentBleu: `Blue`,
|
|
628
|
+
appSettingPageAccentRouge: `Red`,
|
|
629
|
+
appSettingPageAccentOrange: `Orange`,
|
|
630
|
+
appSettingPageAccentViolet: `Purple`,
|
|
631
|
+
appSettingPageAccentRose: `Pink`,
|
|
632
|
+
appSettingPageAccentTurquoise: `Turquoise`,
|
|
633
|
+
appSettingPageAccentTerracotta: `Terracotta`,
|
|
634
|
+
appSettingPageAccentBordeaux: `Burgundy`,
|
|
635
|
+
appSettingPageAccentArdoise: `Slate`,
|
|
622
636
|
appSettingPageMenuQrCodeTitle: `My QR code by default`,
|
|
623
637
|
appSettingPageMenuQrCodeSelectTitle: `Enable to display your QR Code by default`,
|
|
624
638
|
appSettingPageMenuQrCodeDeselectTitle: `Disable to display the camera by default`,
|
|
@@ -706,4 +720,15 @@ Scanning will be automatic`,
|
|
|
706
720
|
searchVoiceListening: `Listening…`,
|
|
707
721
|
searchVoicePrompt: `Tell me what you would like to do`,
|
|
708
722
|
searchVoiceUnavailable: `Voice search is not available. Check microphone access in settings.`,
|
|
723
|
+
profilePageTitle: `Profile`,
|
|
724
|
+
profilePageSectionCompte: `My account`,
|
|
725
|
+
profilePageSectionAssistance: `Support`,
|
|
726
|
+
appSettingPageSectionPreferences: `Preferences`,
|
|
727
|
+
comptePageSectionZoneSensible: `Danger zone`,
|
|
728
|
+
searchNotificationsTitle: `Notifications`,
|
|
729
|
+
searchThemeTitle: `App theme`,
|
|
730
|
+
searchNotificationsParametreTitle: `Notification settings`,
|
|
731
|
+
searchNotificationsSubTitle: `View the notifications received`,
|
|
732
|
+
searchThemeSubTitle: `Light, dark or system, and colour`,
|
|
733
|
+
searchNotificationsParametreSubTitle: `Notification style, sound and vibration`,
|
|
709
734
|
};
|
|
@@ -464,6 +464,7 @@ Si cette demande provient d'une personne de confiance, il vous suffit d'ajouter
|
|
|
464
464
|
transactionDetailsCancelReasonLabel: `Raison`,
|
|
465
465
|
transactionDetailsCancelRejectMessage: `La demande d’annulation est rejetée avec succès`,
|
|
466
466
|
transactionDetailsRecuTitle: `Reçu de l'envoi`,
|
|
467
|
+
transactionDetailsRecuPdfEditeLe: `Edité le :`,
|
|
467
468
|
transactionDetailsRecuSubTitle: `Vous pouvez partager ou télécharger le PDF`,
|
|
468
469
|
transactionDetailsRecuInfoIdentifiant: `Identifiant`,
|
|
469
470
|
transactionDetailsRecuInfoReference: `Référence`,
|
|
@@ -618,6 +619,19 @@ Le scan se fait automatiquement`,
|
|
|
618
619
|
appSettingPageMenuThemeCustom: `Thème de l'application`,
|
|
619
620
|
appSettingPageMenuThemeDefault: `Système`,
|
|
620
621
|
appSettingPageMenuThemePageTitle: `Apparence`,
|
|
622
|
+
appSettingPageThemeSection: `Thème`,
|
|
623
|
+
appSettingPageAccentSection: `Couleur d'accentuation`,
|
|
624
|
+
appSettingPageAccentDefaut: `Défaut`,
|
|
625
|
+
appSettingPageAccentVert: `Vert`,
|
|
626
|
+
appSettingPageAccentBleu: `Bleu`,
|
|
627
|
+
appSettingPageAccentRouge: `Rouge`,
|
|
628
|
+
appSettingPageAccentOrange: `Orange`,
|
|
629
|
+
appSettingPageAccentViolet: `Violet`,
|
|
630
|
+
appSettingPageAccentRose: `Rose`,
|
|
631
|
+
appSettingPageAccentTurquoise: `Turquoise`,
|
|
632
|
+
appSettingPageAccentTerracotta: `Terracotta`,
|
|
633
|
+
appSettingPageAccentBordeaux: `Bordeaux`,
|
|
634
|
+
appSettingPageAccentArdoise: `Ardoise`,
|
|
621
635
|
appSettingPageMenuQrCodeTitle: `Mon QR code par défaut`,
|
|
622
636
|
appSettingPageMenuQrCodeSelectTitle: `Activer pour afficher votre QR Code par défaut`,
|
|
623
637
|
appSettingPageMenuQrCodeDeselectTitle: `Désactiver pour afficher la caméra par défaut`,
|
|
@@ -705,4 +719,15 @@ Le scan se fait automatiquement`,
|
|
|
705
719
|
searchVoiceListening: `Je vous écoute…`,
|
|
706
720
|
searchVoicePrompt: `Dites-moi ce que vous souhaitez faire`,
|
|
707
721
|
searchVoiceUnavailable: `La recherche vocale n’est pas disponible. Vérifiez l’accès au micro dans les réglages.`,
|
|
722
|
+
profilePageTitle: `Profil`,
|
|
723
|
+
profilePageSectionCompte: `Mon compte`,
|
|
724
|
+
profilePageSectionAssistance: `Assistance`,
|
|
725
|
+
appSettingPageSectionPreferences: `Préférences`,
|
|
726
|
+
comptePageSectionZoneSensible: `Zone sensible`,
|
|
727
|
+
searchNotificationsTitle: `Notifications`,
|
|
728
|
+
searchThemeTitle: `Thème de l'application`,
|
|
729
|
+
searchNotificationsParametreTitle: `Réglages des notifications`,
|
|
730
|
+
searchNotificationsSubTitle: `Consulter les notifications reçues`,
|
|
731
|
+
searchThemeSubTitle: `Clair, sombre ou celui du système, et couleur`,
|
|
732
|
+
searchNotificationsParametreSubTitle: `Style, son et vibration des notifications`,
|
|
708
733
|
};
|
|
@@ -464,6 +464,7 @@ Se este pedido for de uma pessoa de confiança, basta adicionar o alias aos seus
|
|
|
464
464
|
transactionDetailsCancelReasonLabel: `Razão`,
|
|
465
465
|
transactionDetailsCancelRejectMessage: `A demanda de cancelamento foi rejeitada com sucesso`,
|
|
466
466
|
transactionDetailsRecuTitle: `Recebido de envio`,
|
|
467
|
+
transactionDetailsRecuPdfEditeLe: `Emitido em:`,
|
|
467
468
|
transactionDetailsRecuSubTitle: `Você pode compartilhar ou baixar o PDF`,
|
|
468
469
|
transactionDetailsRecuInfoIdentifiant: `Identificador`,
|
|
469
470
|
transactionDetailsRecuInfoReference: `Referência`,
|
|
@@ -619,6 +620,19 @@ O scan é feito automaticamente`,
|
|
|
619
620
|
appSettingPageMenuThemeCustom: `Tema da aplicação`,
|
|
620
621
|
appSettingPageMenuThemeDefault: `Sistema`,
|
|
621
622
|
appSettingPageMenuThemePageTitle: `Aparência`,
|
|
623
|
+
appSettingPageThemeSection: `Tema`,
|
|
624
|
+
appSettingPageAccentSection: `Cor de destaque`,
|
|
625
|
+
appSettingPageAccentDefaut: `Padrão`,
|
|
626
|
+
appSettingPageAccentVert: `Verde`,
|
|
627
|
+
appSettingPageAccentBleu: `Azul`,
|
|
628
|
+
appSettingPageAccentRouge: `Vermelho`,
|
|
629
|
+
appSettingPageAccentOrange: `Laranja`,
|
|
630
|
+
appSettingPageAccentViolet: `Roxo`,
|
|
631
|
+
appSettingPageAccentRose: `Rosa`,
|
|
632
|
+
appSettingPageAccentTurquoise: `Turquesa`,
|
|
633
|
+
appSettingPageAccentTerracotta: `Terracota`,
|
|
634
|
+
appSettingPageAccentBordeaux: `Bordô`,
|
|
635
|
+
appSettingPageAccentArdoise: `Ardósia`,
|
|
622
636
|
appSettingPageMenuQrCodeTitle: `Meu QR Code por defeito`,
|
|
623
637
|
appSettingPageMenuQrCodeSelectTitle: `Ativar para exibir o meu QR Code por defeito`,
|
|
624
638
|
appSettingPageMenuQrCodeDeselectTitle: `Desativar para exibir a câmera por defeito`,
|
|
@@ -706,4 +720,15 @@ O scan é feito automaticamente`,
|
|
|
706
720
|
searchVoiceListening: `Estou a ouvir…`,
|
|
707
721
|
searchVoicePrompt: `Diga-me o que deseja fazer`,
|
|
708
722
|
searchVoiceUnavailable: `A pesquisa por voz não está disponível. Verifique o acesso ao microfone nas definições.`,
|
|
723
|
+
profilePageTitle: `Perfil`,
|
|
724
|
+
profilePageSectionCompte: `A minha conta`,
|
|
725
|
+
profilePageSectionAssistance: `Assistência`,
|
|
726
|
+
appSettingPageSectionPreferences: `Preferências`,
|
|
727
|
+
comptePageSectionZoneSensible: `Zona sensível`,
|
|
728
|
+
searchNotificationsTitle: `Notificações`,
|
|
729
|
+
searchThemeTitle: `Tema da aplicação`,
|
|
730
|
+
searchNotificationsParametreTitle: `Definições das notificações`,
|
|
731
|
+
searchNotificationsSubTitle: `Consultar as notificações recebidas`,
|
|
732
|
+
searchThemeSubTitle: `Claro, escuro ou o do sistema, e cor`,
|
|
733
|
+
searchNotificationsParametreSubTitle: `Estilo, som e vibração das notificações`,
|
|
709
734
|
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { useRef } from 'react';
|
|
2
|
-
import { StyleSheet
|
|
2
|
+
import { StyleSheet } from 'react-native';
|
|
3
3
|
|
|
4
4
|
import { useBloc, useBlocListener } from '../../../../core/bloc_react';
|
|
5
5
|
import { Di } from '../../../../core/di';
|
|
6
6
|
import { AppRouter, useAppRouter } from '../../../../core/router';
|
|
7
7
|
import { useTheme } from '../../../../core/theme';
|
|
8
8
|
import { useAppLocalizations } from '../../../../l10n/localizations';
|
|
9
|
-
import {
|
|
9
|
+
import { Card } from '../../../../shared/material/card';
|
|
10
10
|
import { showDialog, showModalBottomSheet } from '../../../../shared/material/overlays';
|
|
11
11
|
import { CustomAlertDialog } from '../../../../shared/widgets/custom_alert_dialog';
|
|
12
12
|
import { CustomLoadingDialog } from '../../../../shared/widgets/loading_page';
|
|
13
|
-
import { MyPageContainer } from '../../../../shared/widgets/my_page_container';
|
|
14
13
|
import { NotificationDialog, NotificationType } from '../../../../shared/widgets/notification_dialog';
|
|
14
|
+
import { ProfileMenuTile } from '../../../profile/presentation/pages/profile_menu';
|
|
15
15
|
import { AliasType } from '../../domain/models/alias_type';
|
|
16
16
|
import { AliasBloc } from '../bloc/alias_bloc';
|
|
17
17
|
import { AliasDeleteEvent } from '../bloc/alias_event';
|
|
@@ -79,18 +79,19 @@ export function AliasDeleteBtnWidget() {
|
|
|
79
79
|
});
|
|
80
80
|
};
|
|
81
81
|
|
|
82
|
+
// Ligne de menu du profil, en rouge
|
|
82
83
|
return (
|
|
83
|
-
<
|
|
84
|
-
<
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
84
|
+
<Card style={styles.card}>
|
|
85
|
+
<ProfileMenuTile
|
|
86
|
+
icone="delete-outline"
|
|
87
|
+
titre={traductions.compteDetailsPageBtnSupprimer}
|
|
88
|
+
couleur={theme.colorScheme.error}
|
|
89
|
+
onPress={onPress}
|
|
90
|
+
/>
|
|
91
|
+
</Card>
|
|
90
92
|
);
|
|
91
93
|
}
|
|
92
94
|
|
|
93
95
|
const styles = StyleSheet.create({
|
|
94
|
-
|
|
95
|
-
noFlex: { flex: 0 },
|
|
96
|
+
card: { margin: 0, overflow: 'hidden' },
|
|
96
97
|
});
|
|
@@ -14,6 +14,7 @@ import { Card } from '../../../../shared/material/card';
|
|
|
14
14
|
import { showDialog, showModalBottomSheet } from '../../../../shared/material/overlays';
|
|
15
15
|
import { DateFormat } from '../../../../shared/utils/date_format';
|
|
16
16
|
import { CustomAlertDialog } from '../../../../shared/widgets/custom_alert_dialog';
|
|
17
|
+
import { ErrorCardWidget } from '../../../../shared/widgets/error_card_widget';
|
|
17
18
|
import { CustomLoadingDialog, LoadingPage } from '../../../../shared/widgets/loading_page';
|
|
18
19
|
import type { Alias } from '../../domain/models/alias';
|
|
19
20
|
import { AliasError } from '../../domain/models/alias_error';
|
|
@@ -238,12 +239,13 @@ function ClaimDetails({
|
|
|
238
239
|
|
|
239
240
|
{/* Avertissement délai de traitement */}
|
|
240
241
|
{initiee && (
|
|
241
|
-
<
|
|
242
|
-
|
|
242
|
+
<ErrorCardWidget
|
|
243
|
+
icon="schedule"
|
|
244
|
+
message={traductions.aliasClaimDetailsAlert(
|
|
243
245
|
new DateFormat('dd MMMM yyyy', locale).format(claim.dateVerrouillage),
|
|
244
246
|
new DateFormat('dd MMMM yyyy', locale).format(claim.dateCloture),
|
|
245
247
|
)}
|
|
246
|
-
|
|
248
|
+
/>
|
|
247
249
|
)}
|
|
248
250
|
</ScrollView>
|
|
249
251
|
|
|
@@ -292,6 +294,5 @@ const styles = StyleSheet.create({
|
|
|
292
294
|
card: { paddingVertical: 10, paddingHorizontal: 15 },
|
|
293
295
|
detail: { flexDirection: 'row', justifyContent: 'space-between', alignItems: 'center' },
|
|
294
296
|
detailValue: { flex: 1, textAlign: 'right' },
|
|
295
|
-
warning: { marginLeft: 8, marginRight: 20, marginTop: 2, marginBottom: 5 },
|
|
296
297
|
actions: { flexDirection: 'row', paddingVertical: 10, paddingHorizontal: 10 },
|
|
297
298
|
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MaterialIcons } from '@expo/vector-icons';
|
|
2
|
-
import { Pressable, StyleSheet,
|
|
2
|
+
import { Pressable, StyleSheet, useWindowDimensions, View } from 'react-native';
|
|
3
3
|
|
|
4
4
|
import { useBlocBuilder, useCreateBloc } from '../../../../core/bloc_react';
|
|
5
5
|
import { Di } from '../../../../core/di';
|
|
@@ -46,7 +46,6 @@ function CopyButton({ value }: { value: string }) {
|
|
|
46
46
|
/** Informations du compte actif : type, numéro et alias. */
|
|
47
47
|
export function CompteDetailsWidget() {
|
|
48
48
|
const traductions = useAppLocalizations();
|
|
49
|
-
const theme = useTheme();
|
|
50
49
|
const { width } = useWindowDimensions();
|
|
51
50
|
const bloc = useCreateBloc(() => {
|
|
52
51
|
const created = new CompteDetailsBloc(Di.getCompteInputPort());
|
|
@@ -57,8 +56,7 @@ export function CompteDetailsWidget() {
|
|
|
57
56
|
|
|
58
57
|
return (
|
|
59
58
|
<View>
|
|
60
|
-
<
|
|
61
|
-
<View style={styles.gap24} />
|
|
59
|
+
<View style={styles.gap8} />
|
|
62
60
|
{state instanceof GetCompteDetailsSuccessState && (
|
|
63
61
|
<View>
|
|
64
62
|
{/* Type de compte */}
|
|
@@ -113,6 +111,7 @@ export function CompteDetailsWidget() {
|
|
|
113
111
|
}
|
|
114
112
|
|
|
115
113
|
const styles = StyleSheet.create({
|
|
114
|
+
gap8: { height: 8 },
|
|
116
115
|
copy: { padding: 8, marginRight: -8 },
|
|
117
116
|
skeleton: { paddingVertical: 8 },
|
|
118
117
|
gap16: { height: 16 },
|
|
@@ -6,8 +6,10 @@ export enum ConfigKey {
|
|
|
6
6
|
/** l'utilisateur a passé l'introduction */
|
|
7
7
|
introductionPassed = 'INTRODUCTION_PASSED',
|
|
8
8
|
|
|
9
|
-
/** theme de l'utilisateur */
|
|
9
|
+
/** theme de l'utilisateur : système, clair ou sombre */
|
|
10
10
|
preferedTheme = 'PREFERED_THEME',
|
|
11
|
+
/** Couleur d'accentuation (PI-SPI par défaut) */
|
|
12
|
+
preferedAccent = 'PREFERED_ACCENT',
|
|
11
13
|
|
|
12
14
|
/** Permission notification */
|
|
13
15
|
permissionNotification = 'PERMISSION_NOTIFICATION',
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ConfigInputPort } from '../../ports/input/config_input_port';
|
|
2
2
|
import type { ConfigOutputPort } from '../../ports/output/config_output_port';
|
|
3
|
-
import { configKeyValues } from '../models/config_keys';
|
|
3
|
+
import { ConfigKey, configKeyValues } from '../models/config_keys';
|
|
4
4
|
import type { ConfigParams } from '../models/config_params';
|
|
5
5
|
|
|
6
6
|
/** Service contenant la logique de gestion des configurations */
|
|
@@ -11,9 +11,38 @@ export class ConfigService implements ConfigInputPort {
|
|
|
11
11
|
*/
|
|
12
12
|
constructor(readonly configOutputPort: ConfigOutputPort) {}
|
|
13
13
|
|
|
14
|
+
/**
|
|
15
|
+
* Anciens thèmes de couleur, remplacés par le thème clair et une couleur
|
|
16
|
+
* d'accentuation (le jaune, trop proche de l'ambre, devient PI-SPI)
|
|
17
|
+
*/
|
|
18
|
+
static readonly anciensThemes: Readonly<Record<string, string>> = {
|
|
19
|
+
yellowTheme: 'pispi',
|
|
20
|
+
greenTheme: 'vert',
|
|
21
|
+
blueTheme: 'bleu',
|
|
22
|
+
redTheme: 'rouge',
|
|
23
|
+
orangeTheme: 'orange',
|
|
24
|
+
purpleTheme: 'violet',
|
|
25
|
+
pinkTheme: 'rose',
|
|
26
|
+
// Thème personnalisé de l'hôte : sa couleur devient l'accent
|
|
27
|
+
customTheme: 'application',
|
|
28
|
+
};
|
|
29
|
+
|
|
14
30
|
recuperer(): ConfigParams {
|
|
15
31
|
// Récuperer toute la config et Appeler le systeme de stockage
|
|
16
|
-
|
|
32
|
+
const config = this.configOutputPort.recuperer([...configKeyValues]);
|
|
33
|
+
this.migrerTheme(config);
|
|
34
|
+
return config;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/** Convertit une seule fois un ancien thème de couleur en thème clair et couleur d'accentuation, et l'enregistre */
|
|
38
|
+
private migrerTheme(config: ConfigParams): void {
|
|
39
|
+
const ancien = config.params[ConfigKey.preferedTheme];
|
|
40
|
+
const accent = ancien != null ? ConfigService.anciensThemes[ancien] : undefined;
|
|
41
|
+
if (accent == null) return;
|
|
42
|
+
config.params[ConfigKey.preferedTheme] = 'lightTheme';
|
|
43
|
+
config.params[ConfigKey.preferedAccent] = accent;
|
|
44
|
+
void this.configOutputPort.modifier(ConfigKey.preferedTheme, 'lightTheme');
|
|
45
|
+
void this.configOutputPort.modifier(ConfigKey.preferedAccent, accent);
|
|
17
46
|
}
|
|
18
47
|
|
|
19
48
|
async modifier(key: string, value: string): Promise<void> {
|
|
@@ -75,7 +75,7 @@ export function HomeTabCompte() {
|
|
|
75
75
|
<CtaWidget
|
|
76
76
|
icon={(color) => <MaterialIcons name="more-horiz" size={30} color={color} />}
|
|
77
77
|
label={traductions.homeActionMore}
|
|
78
|
-
action={hasAlias ? () => void showModalBottomSheet(router, {
|
|
78
|
+
action={hasAlias ? () => void showModalBottomSheet(router, { builder: () => <HomeTabCompteMoreMenu /> }) : null}
|
|
79
79
|
/>
|
|
80
80
|
</View>
|
|
81
81
|
<View style={styles.gap14} />
|
|
@@ -1,71 +1,63 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
1
|
+
import { StyleSheet, View } from 'react-native';
|
|
3
2
|
|
|
4
3
|
import { Images } from '../../../../core/assets';
|
|
5
4
|
import { AppRouter, useAppRouter } from '../../../../core/router';
|
|
6
|
-
import { useTheme } from '../../../../core/theme';
|
|
7
5
|
import { useAppLocalizations } from '../../../../l10n/localizations';
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
6
|
+
import { SelectionSheet } from '../../../../shared/widgets/selection';
|
|
7
|
+
import { ProfileMenuTile, ProfilePageMenu } from '../../../profile/presentation/pages/profile_menu';
|
|
10
8
|
|
|
11
9
|
/**
|
|
12
10
|
* Menu « Plus » de l'accueil. Le participant peut personnaliser ce menu
|
|
13
11
|
* pour y ajouter des fonctionnalités propres à son système.
|
|
12
|
+
* Même feuille que celles du profil : à ouvrir avec showModalBottomSheet
|
|
13
|
+
* sans `themed`, la feuille dessine elle-même son fond.
|
|
14
14
|
*/
|
|
15
15
|
export function HomeTabCompteMoreMenu() {
|
|
16
16
|
const traductions = useAppLocalizations();
|
|
17
|
-
const theme = useTheme();
|
|
18
17
|
const router = useAppRouter();
|
|
19
|
-
const { height } = useWindowDimensions();
|
|
20
|
-
const insets = useSafeAreaInsets();
|
|
21
18
|
// Fermer le menu avant d'ouvrir la page : sinon il reste affiché par-dessus
|
|
22
19
|
const open = (location: string) => {
|
|
23
20
|
AppRouter.pop(router);
|
|
24
21
|
void AppRouter.push(router, location);
|
|
25
22
|
};
|
|
26
23
|
return (
|
|
27
|
-
<
|
|
28
|
-
|
|
29
|
-
styles.
|
|
30
|
-
|
|
31
|
-
]}
|
|
32
|
-
>
|
|
33
|
-
<Card>
|
|
34
|
-
<ScrollView>
|
|
35
|
-
<MenuActionsWidget
|
|
24
|
+
<SelectionSheet
|
|
25
|
+
contenu={
|
|
26
|
+
<View style={styles.contenu}>
|
|
27
|
+
<ProfilePageMenu
|
|
36
28
|
items={[
|
|
37
29
|
// Programmer un paiement
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
traductions.
|
|
42
|
-
|
|
43
|
-
{
|
|
44
|
-
|
|
30
|
+
<ProfileMenuTile
|
|
31
|
+
key="programmer"
|
|
32
|
+
image={Images.homeFooterTransfer}
|
|
33
|
+
titre={traductions.homeActionMoreSheetProgrammerTitle}
|
|
34
|
+
sousTitre={traductions.homeActionMoreSheetProgrammerSubTitle}
|
|
35
|
+
onPress={() => open(AppRouter.subscriptionSchedule)}
|
|
36
|
+
/>,
|
|
45
37
|
// Trouver un abonnement
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
traductions.
|
|
50
|
-
|
|
51
|
-
{
|
|
52
|
-
|
|
38
|
+
<ProfileMenuTile
|
|
39
|
+
key="abonnement"
|
|
40
|
+
image={Images.homeMoreFindSubscription}
|
|
41
|
+
titre={traductions.homeActionMoreSheetAbonnementTitle}
|
|
42
|
+
sousTitre={traductions.homeActionMoreSheetAbonnementSubTitle}
|
|
43
|
+
onPress={() => open(AppRouter.subscriptionSubscribe)}
|
|
44
|
+
/>,
|
|
53
45
|
// Partager dépenses
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
traductions.
|
|
58
|
-
|
|
59
|
-
{
|
|
60
|
-
|
|
46
|
+
<ProfileMenuTile
|
|
47
|
+
key="partager"
|
|
48
|
+
image={Images.homeMoreSplitPayments}
|
|
49
|
+
titre={traductions.homeActionMoreSheetPartagerTitle}
|
|
50
|
+
sousTitre={traductions.homeActionMoreSheetPartagerSubTitle}
|
|
51
|
+
onPress={() => open(AppRouter.transactionSplitPaymentTx)}
|
|
52
|
+
/>,
|
|
61
53
|
]}
|
|
62
54
|
/>
|
|
63
|
-
</
|
|
64
|
-
|
|
65
|
-
|
|
55
|
+
</View>
|
|
56
|
+
}
|
|
57
|
+
/>
|
|
66
58
|
);
|
|
67
59
|
}
|
|
68
60
|
|
|
69
61
|
const styles = StyleSheet.create({
|
|
70
|
-
|
|
62
|
+
contenu: { paddingHorizontal: 16, paddingTop: 8, paddingBottom: 20 },
|
|
71
63
|
});
|
|
@@ -1,27 +1,35 @@
|
|
|
1
|
-
import { ScrollView, StyleSheet } from 'react-native';
|
|
1
|
+
import { ScrollView, StyleSheet, View } from 'react-native';
|
|
2
2
|
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { useAppLocalizations } from '../../../../../l10n/localizations';
|
|
4
|
+
import { Scaffold } from '../../../../../shared/material/scaffold';
|
|
5
5
|
import { MyPageContainer } from '../../../../../shared/widgets/my_page_container';
|
|
6
6
|
import { AliasDeleteBtnWidget } from '../../../../alias/presentation/pages/alias_delete_btn_widget';
|
|
7
7
|
import { CompteDetailsWidget } from '../../../../compte/presentation/pages/compte_details_widget';
|
|
8
|
+
import { ProfileAppBar } from '../profile_app_bar';
|
|
9
|
+
import { ProfileSectionTitre } from '../profile_menu';
|
|
8
10
|
|
|
9
11
|
/** Compte du client et suppression de l'alias (route `profileCompte`). */
|
|
10
12
|
export function ProfileComptePage() {
|
|
11
|
-
const
|
|
13
|
+
const traductions = useAppLocalizations();
|
|
12
14
|
return (
|
|
13
|
-
<Scaffold appBar={<
|
|
15
|
+
<Scaffold appBar={<ProfileAppBar titre={traductions.compteDetailsPageTitle} />}>
|
|
14
16
|
<MyPageContainer>
|
|
15
17
|
<ScrollView style={styles.flex}>
|
|
16
18
|
<CompteDetailsWidget />
|
|
17
19
|
</ScrollView>
|
|
20
|
+
<View style={styles.gap24} />
|
|
21
|
+
|
|
22
|
+
{/* Suppression de l'alias */}
|
|
23
|
+
<ProfileSectionTitre titre={traductions.comptePageSectionZoneSensible} />
|
|
24
|
+
<AliasDeleteBtnWidget />
|
|
25
|
+
<View style={styles.gap16} />
|
|
18
26
|
</MyPageContainer>
|
|
19
|
-
{/* Bouton supprimer l'alias */}
|
|
20
|
-
<AliasDeleteBtnWidget />
|
|
21
27
|
</Scaffold>
|
|
22
28
|
);
|
|
23
29
|
}
|
|
24
30
|
|
|
25
31
|
const styles = StyleSheet.create({
|
|
26
32
|
flex: { flex: 1 },
|
|
33
|
+
gap16: { height: 16 },
|
|
34
|
+
gap24: { height: 24 },
|
|
27
35
|
});
|
|
@@ -1,20 +1,21 @@
|
|
|
1
|
-
import { ScrollView, StyleSheet,
|
|
1
|
+
import { ScrollView, StyleSheet, View } from 'react-native';
|
|
2
2
|
|
|
3
3
|
import { Images } from '../../../../../core/assets';
|
|
4
4
|
import { useBloc, useBlocBuilder } from '../../../../../core/bloc_react';
|
|
5
5
|
import { Di } from '../../../../../core/di';
|
|
6
|
-
import { AppRouter
|
|
6
|
+
import { AppRouter } from '../../../../../core/router';
|
|
7
7
|
import { SoundManager } from '../../../../../core/sounds';
|
|
8
|
-
import { Themer, Themes
|
|
8
|
+
import { Themer, Themes } from '../../../../../core/theme';
|
|
9
9
|
import type { AppLocalizations } from '../../../../../l10n/app_localizations';
|
|
10
10
|
import { useAppLocalizations } from '../../../../../l10n/localizations';
|
|
11
|
-
import {
|
|
11
|
+
import { Scaffold } from '../../../../../shared/material/scaffold';
|
|
12
12
|
import { LoadingPage } from '../../../../../shared/widgets/loading_page';
|
|
13
13
|
import { MyPageContainer } from '../../../../../shared/widgets/my_page_container';
|
|
14
14
|
import { ConfigBloc } from '../../../../config/adapters/ui/bloc/config_bloc';
|
|
15
15
|
import { ConfigLoadedState } from '../../../../config/adapters/ui/bloc/config_state';
|
|
16
16
|
import { ConfigKey } from '../../../../config/domain/models/config_keys';
|
|
17
17
|
import type { ConfigParams } from '../../../../config/domain/models/config_params';
|
|
18
|
+
import { ProfileAppBar } from '../profile_app_bar';
|
|
18
19
|
import { ProfilePageMenu, ProfileItem } from '../profile_menu';
|
|
19
20
|
import { ProfileParametrePageQRcode } from './profile_parametre_page_qrcode';
|
|
20
21
|
|
|
@@ -45,10 +46,7 @@ function menuItems(traductions: AppLocalizations, configParams: ConfigParams): P
|
|
|
45
46
|
if (Di.config.appConfig.canChangeTheme) {
|
|
46
47
|
items.push(
|
|
47
48
|
new ProfileItem(Images.iconsTheme, traductions.appSettingPageMenuThemeTitle, AppRouter.profileParametreTheme, {
|
|
48
|
-
subtitle:
|
|
49
|
-
params[ConfigKey.preferedTheme] === Themer.customThemeCode
|
|
50
|
-
? traductions.appSettingPageMenuThemeCustom
|
|
51
|
-
: Themes.label(theme, traductions),
|
|
49
|
+
subtitle: `${Themes.label(theme, traductions)} · ${Themer.accentLabel(traductions, params[ConfigKey.preferedAccent])}`,
|
|
52
50
|
}),
|
|
53
51
|
);
|
|
54
52
|
}
|
|
@@ -69,29 +67,27 @@ function menuItems(traductions: AppLocalizations, configParams: ConfigParams): P
|
|
|
69
67
|
/** Paramètres de l'application (route `profileParametre`). */
|
|
70
68
|
export function ProfileParametrePage() {
|
|
71
69
|
const traductions = useAppLocalizations();
|
|
72
|
-
const theme = useTheme();
|
|
73
|
-
const router = useAppRouter();
|
|
74
70
|
const configBloc = useBloc(ConfigBloc);
|
|
75
71
|
const state = useBlocBuilder(
|
|
76
72
|
configBloc,
|
|
77
73
|
(_p, current) =>
|
|
78
74
|
current instanceof ConfigLoadedState &&
|
|
79
75
|
current.updatedKey != null &&
|
|
80
|
-
[ConfigKey.showQRcode, ConfigKey.preferedTheme, ConfigKey.notificationStatus, ConfigKey.notificationAlertSound].includes(
|
|
76
|
+
[ConfigKey.showQRcode, ConfigKey.preferedTheme, ConfigKey.preferedAccent, ConfigKey.notificationStatus, ConfigKey.notificationAlertSound].includes(
|
|
81
77
|
current.updatedKey,
|
|
82
78
|
),
|
|
83
79
|
);
|
|
84
80
|
|
|
85
81
|
return (
|
|
86
|
-
<Scaffold appBar={<
|
|
82
|
+
<Scaffold appBar={<ProfileAppBar titre={traductions.appSettingPageTitle} />}>
|
|
87
83
|
{!(state instanceof ConfigLoadedState) ? (
|
|
88
84
|
<LoadingPage />
|
|
89
85
|
) : (
|
|
90
86
|
<MyPageContainer>
|
|
91
87
|
<ScrollView>
|
|
92
|
-
<
|
|
93
|
-
|
|
94
|
-
<ProfilePageMenu items={menuItems(traductions, state.configParams)} />
|
|
88
|
+
<View style={styles.gap8} />
|
|
89
|
+
{/* Préférences */}
|
|
90
|
+
<ProfilePageMenu titre={traductions.appSettingPageSectionPreferences} items={menuItems(traductions, state.configParams)} />
|
|
95
91
|
</ScrollView>
|
|
96
92
|
</MyPageContainer>
|
|
97
93
|
)}
|
|
@@ -100,6 +96,5 @@ export function ProfileParametrePage() {
|
|
|
100
96
|
}
|
|
101
97
|
|
|
102
98
|
const styles = StyleSheet.create({
|
|
103
|
-
|
|
104
|
-
gap24: { height: 24 },
|
|
99
|
+
gap8: { height: 8 },
|
|
105
100
|
});
|