@bifold/core 1.0.0 → 2.0.1
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/lib/commonjs/App.js +26 -22
- package/lib/commonjs/App.js.map +1 -1
- package/lib/commonjs/components/inputs/BiometryControl.js +176 -0
- package/lib/commonjs/components/inputs/BiometryControl.js.map +1 -0
- package/lib/commonjs/components/misc/ConnectionAlert.js +2 -2
- package/lib/commonjs/components/misc/ConnectionAlert.js.map +1 -1
- package/lib/commonjs/components/misc/InfoBox.js +3 -2
- package/lib/commonjs/components/misc/InfoBox.js.map +1 -1
- package/lib/commonjs/components/misc/{PINCreateHeader.js → PINHeader.js} +4 -4
- package/lib/commonjs/components/misc/PINHeader.js.map +1 -0
- package/lib/commonjs/components/misc/PINValidationHelper.js +50 -0
- package/lib/commonjs/components/misc/PINValidationHelper.js.map +1 -0
- package/lib/commonjs/components/views/PushNotificationsContent.js +52 -0
- package/lib/commonjs/components/views/PushNotificationsContent.js.map +1 -0
- package/lib/commonjs/components/views/PushNotificationsDisabledContent.js +47 -0
- package/lib/commonjs/components/views/PushNotificationsDisabledContent.js.map +1 -0
- package/lib/commonjs/container-api.js +8 -3
- package/lib/commonjs/container-api.js.map +1 -1
- package/lib/commonjs/container-impl.js +25 -21
- package/lib/commonjs/container-impl.js.map +1 -1
- package/lib/commonjs/contexts/activity.js +17 -41
- package/lib/commonjs/contexts/activity.js.map +1 -1
- package/lib/commonjs/contexts/auth.js +16 -6
- package/lib/commonjs/contexts/auth.js.map +1 -1
- package/lib/commonjs/contexts/navigation.js +24 -0
- package/lib/commonjs/contexts/navigation.js.map +1 -0
- package/lib/commonjs/contexts/reducers/store.js +14 -0
- package/lib/commonjs/contexts/reducers/store.js.map +1 -1
- package/lib/commonjs/contexts/theme.js +36 -3
- package/lib/commonjs/contexts/theme.js.map +1 -1
- package/lib/commonjs/hooks/deep-links.js +2 -4
- package/lib/commonjs/hooks/deep-links.js.map +1 -1
- package/lib/commonjs/hooks/{initialize-agent.js → useBifoldAgentSetup.js} +24 -44
- package/lib/commonjs/hooks/useBifoldAgentSetup.js.map +1 -0
- package/lib/commonjs/hooks/useOnboardingState.js +3 -3
- package/lib/commonjs/hooks/useOnboardingState.js.map +1 -1
- package/lib/commonjs/hooks/usePINValidation.js +82 -0
- package/lib/commonjs/hooks/usePINValidation.js.map +1 -0
- package/lib/commonjs/index.js +34 -33
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/localization/en/index.js +31 -25
- package/lib/commonjs/localization/en/index.js.map +1 -1
- package/lib/commonjs/localization/fr/index.js +18 -6
- package/lib/commonjs/localization/fr/index.js.map +1 -1
- package/lib/commonjs/localization/pt-br/index.js +43 -37
- package/lib/commonjs/localization/pt-br/index.js.map +1 -1
- package/lib/commonjs/navigators/MainStack.js +31 -8
- package/lib/commonjs/navigators/MainStack.js.map +1 -1
- package/lib/commonjs/navigators/OnboardingScreens.js +8 -8
- package/lib/commonjs/navigators/OnboardingScreens.js.map +1 -1
- package/lib/commonjs/navigators/OnboardingStack.js +20 -12
- package/lib/commonjs/navigators/OnboardingStack.js.map +1 -1
- package/lib/commonjs/navigators/RootStack.js +27 -30
- package/lib/commonjs/navigators/RootStack.js.map +1 -1
- package/lib/commonjs/navigators/SettingStack.js +14 -15
- package/lib/commonjs/navigators/SettingStack.js.map +1 -1
- package/lib/commonjs/navigators/defaultStackOptions.js +13 -2
- package/lib/commonjs/navigators/defaultStackOptions.js.map +1 -1
- package/lib/commonjs/onboarding.js +12 -5
- package/lib/commonjs/onboarding.js.map +1 -1
- package/lib/commonjs/screens/Biometry.js +62 -0
- package/lib/commonjs/screens/Biometry.js.map +1 -0
- package/lib/commonjs/screens/CredentialOffer.js +2 -2
- package/lib/commonjs/screens/CredentialOffer.js.map +1 -1
- package/lib/commonjs/screens/Onboarding.js.map +1 -1
- package/lib/commonjs/screens/PINChange.js +212 -0
- package/lib/commonjs/screens/PINChange.js.map +1 -0
- package/lib/commonjs/screens/PINCreate.js +47 -224
- package/lib/commonjs/screens/PINCreate.js.map +1 -1
- package/lib/commonjs/screens/Preface.js.map +1 -1
- package/lib/commonjs/screens/ProofRequest.js +112 -33
- package/lib/commonjs/screens/ProofRequest.js.map +1 -1
- package/lib/commonjs/screens/PushNotifications.js +71 -0
- package/lib/commonjs/screens/PushNotifications.js.map +1 -0
- package/lib/commonjs/screens/Settings.js +8 -24
- package/lib/commonjs/screens/Settings.js.map +1 -1
- package/lib/commonjs/screens/Splash.js +7 -23
- package/lib/commonjs/screens/Splash.js.map +1 -1
- package/lib/commonjs/screens/Terms.js.map +1 -1
- package/lib/commonjs/screens/ToggleBiometry.js +135 -0
- package/lib/commonjs/screens/ToggleBiometry.js.map +1 -0
- package/lib/commonjs/screens/{PushNotification.js → TogglePushNotifications.js} +41 -99
- package/lib/commonjs/screens/TogglePushNotifications.js.map +1 -0
- package/lib/commonjs/theme.js +4 -2
- package/lib/commonjs/theme.js.map +1 -1
- package/lib/commonjs/types/navigators.js +5 -2
- package/lib/commonjs/types/navigators.js.map +1 -1
- package/lib/commonjs/utils/{PINCreationValidation.js → PINValidation.js} +4 -4
- package/lib/commonjs/utils/PINValidation.js.map +1 -0
- package/lib/commonjs/utils/agent.js.map +1 -1
- package/lib/commonjs/utils/helpers.js +2 -0
- package/lib/commonjs/utils/helpers.js.map +1 -1
- package/lib/module/App.js +24 -20
- package/lib/module/App.js.map +1 -1
- package/lib/module/components/inputs/BiometryControl.js +167 -0
- package/lib/module/components/inputs/BiometryControl.js.map +1 -0
- package/lib/module/components/misc/ConnectionAlert.js +2 -2
- package/lib/module/components/misc/ConnectionAlert.js.map +1 -1
- package/lib/module/components/misc/InfoBox.js +3 -2
- package/lib/module/components/misc/InfoBox.js.map +1 -1
- package/lib/module/components/misc/{PINCreateHeader.js → PINHeader.js} +4 -4
- package/lib/module/components/misc/PINHeader.js.map +1 -0
- package/lib/module/components/misc/PINValidationHelper.js +43 -0
- package/lib/module/components/misc/PINValidationHelper.js.map +1 -0
- package/lib/module/components/views/PushNotificationsContent.js +45 -0
- package/lib/module/components/views/PushNotificationsContent.js.map +1 -0
- package/lib/module/components/views/PushNotificationsDisabledContent.js +40 -0
- package/lib/module/components/views/PushNotificationsDisabledContent.js.map +1 -0
- package/lib/module/container-api.js +7 -2
- package/lib/module/container-api.js.map +1 -1
- package/lib/module/container-impl.js +25 -21
- package/lib/module/container-impl.js.map +1 -1
- package/lib/module/contexts/activity.js +17 -41
- package/lib/module/contexts/activity.js.map +1 -1
- package/lib/module/contexts/auth.js +16 -6
- package/lib/module/contexts/auth.js.map +1 -1
- package/lib/module/contexts/navigation.js +17 -0
- package/lib/module/contexts/navigation.js.map +1 -0
- package/lib/module/contexts/reducers/store.js +14 -0
- package/lib/module/contexts/reducers/store.js.map +1 -1
- package/lib/module/contexts/theme.js +36 -4
- package/lib/module/contexts/theme.js.map +1 -1
- package/lib/module/hooks/deep-links.js +2 -4
- package/lib/module/hooks/deep-links.js.map +1 -1
- package/lib/module/hooks/{initialize-agent.js → useBifoldAgentSetup.js} +25 -45
- package/lib/module/hooks/useBifoldAgentSetup.js.map +1 -0
- package/lib/module/hooks/useOnboardingState.js +3 -3
- package/lib/module/hooks/useOnboardingState.js.map +1 -1
- package/lib/module/hooks/usePINValidation.js +75 -0
- package/lib/module/hooks/usePINValidation.js.map +1 -0
- package/lib/module/index.js +6 -6
- package/lib/module/index.js.map +1 -1
- package/lib/module/localization/en/index.js +31 -25
- package/lib/module/localization/en/index.js.map +1 -1
- package/lib/module/localization/fr/index.js +18 -6
- package/lib/module/localization/fr/index.js.map +1 -1
- package/lib/module/localization/pt-br/index.js +43 -37
- package/lib/module/localization/pt-br/index.js.map +1 -1
- package/lib/module/navigators/MainStack.js +32 -9
- package/lib/module/navigators/MainStack.js.map +1 -1
- package/lib/module/navigators/OnboardingScreens.js +8 -8
- package/lib/module/navigators/OnboardingScreens.js.map +1 -1
- package/lib/module/navigators/OnboardingStack.js +21 -12
- package/lib/module/navigators/OnboardingStack.js.map +1 -1
- package/lib/module/navigators/RootStack.js +26 -29
- package/lib/module/navigators/RootStack.js.map +1 -1
- package/lib/module/navigators/SettingStack.js +14 -15
- package/lib/module/navigators/SettingStack.js.map +1 -1
- package/lib/module/navigators/defaultStackOptions.js +13 -2
- package/lib/module/navigators/defaultStackOptions.js.map +1 -1
- package/lib/module/onboarding.js +10 -4
- package/lib/module/onboarding.js.map +1 -1
- package/lib/module/screens/Biometry.js +53 -0
- package/lib/module/screens/Biometry.js.map +1 -0
- package/lib/module/screens/CredentialOffer.js +2 -2
- package/lib/module/screens/CredentialOffer.js.map +1 -1
- package/lib/module/screens/Onboarding.js.map +1 -1
- package/lib/module/screens/PINChange.js +203 -0
- package/lib/module/screens/PINChange.js.map +1 -0
- package/lib/module/screens/PINCreate.js +49 -226
- package/lib/module/screens/PINCreate.js.map +1 -1
- package/lib/module/screens/Preface.js.map +1 -1
- package/lib/module/screens/ProofRequest.js +113 -34
- package/lib/module/screens/ProofRequest.js.map +1 -1
- package/lib/module/screens/PushNotifications.js +63 -0
- package/lib/module/screens/PushNotifications.js.map +1 -0
- package/lib/module/screens/Settings.js +9 -25
- package/lib/module/screens/Settings.js.map +1 -1
- package/lib/module/screens/Splash.js +7 -23
- package/lib/module/screens/Splash.js.map +1 -1
- package/lib/module/screens/Terms.js.map +1 -1
- package/lib/module/screens/ToggleBiometry.js +126 -0
- package/lib/module/screens/ToggleBiometry.js.map +1 -0
- package/lib/module/screens/TogglePushNotifications.js +112 -0
- package/lib/module/screens/TogglePushNotifications.js.map +1 -0
- package/lib/module/theme.js +3 -1
- package/lib/module/theme.js.map +1 -1
- package/lib/module/types/navigators.js +5 -2
- package/lib/module/types/navigators.js.map +1 -1
- package/lib/module/utils/{PINCreationValidation.js → PINValidation.js} +2 -2
- package/lib/module/utils/PINValidation.js.map +1 -0
- package/lib/module/utils/agent.js.map +1 -1
- package/lib/module/utils/helpers.js +2 -0
- package/lib/module/utils/helpers.js.map +1 -1
- package/lib/typescript/src/App.d.ts +3 -3
- package/lib/typescript/src/App.d.ts.map +1 -1
- package/lib/typescript/src/components/inputs/BiometryControl.d.ts +9 -0
- package/lib/typescript/src/components/inputs/BiometryControl.d.ts.map +1 -0
- package/lib/typescript/src/components/misc/ConnectionAlert.d.ts +1 -1
- package/lib/typescript/src/components/misc/ConnectionAlert.d.ts.map +1 -1
- package/lib/typescript/src/components/misc/InfoBox.d.ts +1 -0
- package/lib/typescript/src/components/misc/InfoBox.d.ts.map +1 -1
- package/lib/typescript/src/components/misc/PINHeader.d.ts +6 -0
- package/lib/typescript/src/components/misc/PINHeader.d.ts.map +1 -0
- package/lib/typescript/src/components/misc/PINValidationHelper.d.ts +8 -0
- package/lib/typescript/src/components/misc/PINValidationHelper.d.ts.map +1 -0
- package/lib/typescript/src/components/views/PushNotificationsContent.d.ts +4 -0
- package/lib/typescript/src/components/views/PushNotificationsContent.d.ts.map +1 -0
- package/lib/typescript/src/components/views/PushNotificationsDisabledContent.d.ts +4 -0
- package/lib/typescript/src/components/views/PushNotificationsDisabledContent.d.ts.map +1 -0
- package/lib/typescript/src/container-api.d.ts +24 -13
- package/lib/typescript/src/container-api.d.ts.map +1 -1
- package/lib/typescript/src/container-impl.d.ts +4 -2
- package/lib/typescript/src/container-impl.d.ts.map +1 -1
- package/lib/typescript/src/contexts/activity.d.ts.map +1 -1
- package/lib/typescript/src/contexts/auth.d.ts +3 -1
- package/lib/typescript/src/contexts/auth.d.ts.map +1 -1
- package/lib/typescript/src/contexts/navigation.d.ts +8 -0
- package/lib/typescript/src/contexts/navigation.d.ts.map +1 -0
- package/lib/typescript/src/contexts/reducers/store.d.ts +3 -1
- package/lib/typescript/src/contexts/reducers/store.d.ts.map +1 -1
- package/lib/typescript/src/contexts/theme.d.ts +9 -3
- package/lib/typescript/src/contexts/theme.d.ts.map +1 -1
- package/lib/typescript/src/hooks/deep-links.d.ts.map +1 -1
- package/lib/typescript/src/hooks/useBifoldAgentSetup.d.ts +10 -0
- package/lib/typescript/src/hooks/useBifoldAgentSetup.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useOnboardingState.d.ts +2 -1
- package/lib/typescript/src/hooks/useOnboardingState.d.ts.map +1 -1
- package/lib/typescript/src/hooks/usePINValidation.d.ts +20 -0
- package/lib/typescript/src/hooks/usePINValidation.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +9 -7
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/localization/en/index.d.ts +23 -17
- package/lib/typescript/src/localization/en/index.d.ts.map +1 -1
- package/lib/typescript/src/localization/fr/index.d.ts +14 -2
- package/lib/typescript/src/localization/fr/index.d.ts.map +1 -1
- package/lib/typescript/src/localization/pt-br/index.d.ts +23 -17
- package/lib/typescript/src/localization/pt-br/index.d.ts.map +1 -1
- package/lib/typescript/src/navigators/MainStack.d.ts.map +1 -1
- package/lib/typescript/src/navigators/OnboardingScreens.d.ts +3 -3
- package/lib/typescript/src/navigators/OnboardingScreens.d.ts.map +1 -1
- package/lib/typescript/src/navigators/OnboardingStack.d.ts +7 -1
- package/lib/typescript/src/navigators/OnboardingStack.d.ts.map +1 -1
- package/lib/typescript/src/navigators/RootStack.d.ts.map +1 -1
- package/lib/typescript/src/navigators/SettingStack.d.ts.map +1 -1
- package/lib/typescript/src/navigators/defaultStackOptions.d.ts.map +1 -1
- package/lib/typescript/src/onboarding.d.ts +4 -2
- package/lib/typescript/src/onboarding.d.ts.map +1 -1
- package/lib/typescript/src/screens/Biometry.d.ts +4 -0
- package/lib/typescript/src/screens/Biometry.d.ts.map +1 -0
- package/lib/typescript/src/screens/{PushNotification.d.ts → PINChange.d.ts} +3 -3
- package/lib/typescript/src/screens/PINChange.d.ts.map +1 -0
- package/lib/typescript/src/screens/PINCreate.d.ts.map +1 -1
- package/lib/typescript/src/screens/ProofRequest.d.ts.map +1 -1
- package/lib/typescript/src/screens/PushNotifications.d.ts +4 -0
- package/lib/typescript/src/screens/PushNotifications.d.ts.map +1 -0
- package/lib/typescript/src/screens/Settings.d.ts.map +1 -1
- package/lib/typescript/src/screens/Splash.d.ts +7 -4
- package/lib/typescript/src/screens/Splash.d.ts.map +1 -1
- package/lib/typescript/src/screens/ToggleBiometry.d.ts +4 -0
- package/lib/typescript/src/screens/ToggleBiometry.d.ts.map +1 -0
- package/lib/typescript/src/screens/TogglePushNotifications.d.ts +4 -0
- package/lib/typescript/src/screens/TogglePushNotifications.d.ts.map +1 -0
- package/lib/typescript/src/theme.d.ts +3 -1
- package/lib/typescript/src/theme.d.ts.map +1 -1
- package/lib/typescript/src/types/navigators.d.ts +11 -13
- package/lib/typescript/src/types/navigators.d.ts.map +1 -1
- package/lib/typescript/src/types/state.d.ts +1 -0
- package/lib/typescript/src/types/state.d.ts.map +1 -1
- package/lib/typescript/src/utils/{PINCreationValidation.d.ts → PINValidation.d.ts} +2 -2
- package/lib/typescript/src/utils/PINValidation.d.ts.map +1 -0
- package/lib/typescript/src/utils/agent.d.ts +1 -2
- package/lib/typescript/src/utils/agent.d.ts.map +1 -1
- package/lib/typescript/src/utils/helpers.d.ts.map +1 -1
- package/package.json +5 -5
- package/src/App.tsx +41 -40
- package/src/components/inputs/BiometryControl.tsx +176 -0
- package/src/components/misc/ConnectionAlert.tsx +3 -3
- package/src/components/misc/InfoBox.tsx +3 -1
- package/src/components/misc/{PINCreateHeader.tsx → PINHeader.tsx} +4 -4
- package/src/components/misc/PINValidationHelper.tsx +48 -0
- package/src/components/views/PushNotificationsContent.tsx +51 -0
- package/src/components/views/PushNotificationsDisabledContent.tsx +47 -0
- package/src/container-api.ts +27 -11
- package/src/container-impl.ts +31 -27
- package/src/contexts/activity.tsx +17 -42
- package/src/contexts/auth.tsx +18 -6
- package/src/contexts/navigation.tsx +19 -0
- package/src/contexts/reducers/store.ts +12 -0
- package/src/contexts/theme.tsx +51 -0
- package/src/hooks/deep-links.ts +2 -4
- package/src/hooks/{initialize-agent.ts → useBifoldAgentSetup.ts} +32 -54
- package/src/hooks/useOnboardingState.ts +10 -3
- package/src/hooks/usePINValidation.ts +98 -0
- package/src/index.ts +12 -14
- package/src/localization/en/index.ts +26 -20
- package/src/localization/fr/index.ts +32 -20
- package/src/localization/pt-br/index.ts +39 -33
- package/src/navigators/MainStack.tsx +29 -8
- package/src/navigators/OnboardingScreens.ts +11 -11
- package/src/navigators/OnboardingStack.tsx +26 -14
- package/src/navigators/RootStack.tsx +31 -25
- package/src/navigators/SettingStack.tsx +15 -16
- package/src/navigators/defaultStackOptions.tsx +13 -2
- package/src/onboarding.ts +12 -5
- package/src/screens/Biometry.tsx +57 -0
- package/src/screens/CredentialOffer.tsx +2 -2
- package/src/screens/Onboarding.tsx +2 -2
- package/src/screens/PINChange.tsx +250 -0
- package/src/screens/PINCreate.tsx +51 -267
- package/src/screens/Preface.tsx +2 -2
- package/src/screens/ProofRequest.tsx +140 -48
- package/src/screens/PushNotifications.tsx +59 -0
- package/src/screens/Settings.tsx +5 -10
- package/src/screens/Splash.tsx +10 -22
- package/src/screens/Terms.tsx +2 -2
- package/src/screens/ToggleBiometry.tsx +167 -0
- package/src/screens/TogglePushNotifications.tsx +118 -0
- package/src/theme.ts +5 -1
- package/src/types/navigators.ts +11 -12
- package/src/types/state.ts +1 -0
- package/src/utils/{PINCreationValidation.ts → PINValidation.ts} +1 -1
- package/src/utils/agent.ts +1 -2
- package/src/utils/helpers.ts +2 -0
- package/lib/commonjs/components/misc/ActivityLogLink.js +0 -44
- package/lib/commonjs/components/misc/ActivityLogLink.js.map +0 -1
- package/lib/commonjs/components/misc/PINCreateHeader.js.map +0 -1
- package/lib/commonjs/components/modals/NotificationModal.js +0 -121
- package/lib/commonjs/components/modals/NotificationModal.js.map +0 -1
- package/lib/commonjs/components/texts/Label.js +0 -57
- package/lib/commonjs/components/texts/Label.js.map +0 -1
- package/lib/commonjs/components/texts/Title.js +0 -29
- package/lib/commonjs/components/texts/Title.js.map +0 -1
- package/lib/commonjs/components/views/ModularView.js +0 -41
- package/lib/commonjs/components/views/ModularView.js.map +0 -1
- package/lib/commonjs/hooks/initialize-agent.js.map +0 -1
- package/lib/commonjs/screens/PushNotification.js.map +0 -1
- package/lib/commonjs/screens/UseBiometry.js +0 -315
- package/lib/commonjs/screens/UseBiometry.js.map +0 -1
- package/lib/commonjs/utils/PINCreationValidation.js.map +0 -1
- package/lib/module/components/misc/ActivityLogLink.js +0 -37
- package/lib/module/components/misc/ActivityLogLink.js.map +0 -1
- package/lib/module/components/misc/PINCreateHeader.js.map +0 -1
- package/lib/module/components/modals/NotificationModal.js +0 -112
- package/lib/module/components/modals/NotificationModal.js.map +0 -1
- package/lib/module/components/texts/Label.js +0 -50
- package/lib/module/components/texts/Label.js.map +0 -1
- package/lib/module/components/texts/Title.js +0 -22
- package/lib/module/components/texts/Title.js.map +0 -1
- package/lib/module/components/views/ModularView.js +0 -34
- package/lib/module/components/views/ModularView.js.map +0 -1
- package/lib/module/hooks/initialize-agent.js.map +0 -1
- package/lib/module/screens/PushNotification.js +0 -170
- package/lib/module/screens/PushNotification.js.map +0 -1
- package/lib/module/screens/UseBiometry.js +0 -306
- package/lib/module/screens/UseBiometry.js.map +0 -1
- package/lib/module/utils/PINCreationValidation.js.map +0 -1
- package/lib/typescript/src/components/misc/ActivityLogLink.d.ts +0 -4
- package/lib/typescript/src/components/misc/ActivityLogLink.d.ts.map +0 -1
- package/lib/typescript/src/components/misc/PINCreateHeader.d.ts +0 -6
- package/lib/typescript/src/components/misc/PINCreateHeader.d.ts.map +0 -1
- package/lib/typescript/src/components/modals/NotificationModal.d.ts +0 -17
- package/lib/typescript/src/components/modals/NotificationModal.d.ts.map +0 -1
- package/lib/typescript/src/components/texts/Label.d.ts +0 -9
- package/lib/typescript/src/components/texts/Label.d.ts.map +0 -1
- package/lib/typescript/src/components/texts/Title.d.ts +0 -8
- package/lib/typescript/src/components/texts/Title.d.ts.map +0 -1
- package/lib/typescript/src/components/views/ModularView.d.ts +0 -9
- package/lib/typescript/src/components/views/ModularView.d.ts.map +0 -1
- package/lib/typescript/src/hooks/initialize-agent.d.ts +0 -7
- package/lib/typescript/src/hooks/initialize-agent.d.ts.map +0 -1
- package/lib/typescript/src/screens/PushNotification.d.ts.map +0 -1
- package/lib/typescript/src/screens/UseBiometry.d.ts +0 -4
- package/lib/typescript/src/screens/UseBiometry.d.ts.map +0 -1
- package/lib/typescript/src/utils/PINCreationValidation.d.ts.map +0 -1
- package/src/components/misc/ActivityLogLink.tsx +0 -34
- package/src/components/modals/NotificationModal.tsx +0 -127
- package/src/components/texts/Label.tsx +0 -51
- package/src/components/texts/Title.tsx +0 -25
- package/src/components/views/ModularView.tsx +0 -35
- package/src/contexts/theme.ts +0 -9
- package/src/screens/PushNotification.tsx +0 -186
- package/src/screens/UseBiometry.tsx +0 -357
|
@@ -1,30 +1,37 @@
|
|
|
1
1
|
/* eslint-disable @typescript-eslint/no-non-null-assertion */
|
|
2
|
+
import { Agent } from '@credo-ts/core'
|
|
2
3
|
import { StackActions, useNavigation, useNavigationState } from '@react-navigation/native'
|
|
3
4
|
import { StackNavigationProp, createStackNavigator } from '@react-navigation/stack'
|
|
4
|
-
import { EventTypes } from '../constants'
|
|
5
5
|
import React, { useMemo, useCallback, useEffect } from 'react'
|
|
6
6
|
import { useTranslation } from 'react-i18next'
|
|
7
|
+
import { DeviceEventEmitter } from 'react-native'
|
|
7
8
|
|
|
9
|
+
import { EventTypes } from '../constants'
|
|
8
10
|
import { TOKENS, useServices } from '../container-api'
|
|
9
11
|
import { DispatchAction } from '../contexts/reducers/store'
|
|
10
12
|
import { useStore } from '../contexts/store'
|
|
11
13
|
import { useTheme } from '../contexts/theme'
|
|
14
|
+
import { useOnboardingState } from '../hooks/useOnboardingState'
|
|
12
15
|
import AttemptLockout from '../screens/AttemptLockout'
|
|
13
16
|
import NameWallet from '../screens/NameWallet'
|
|
14
17
|
import { createCarouselStyle } from '../screens/OnboardingPages'
|
|
15
18
|
import PINCreate from '../screens/PINCreate'
|
|
16
19
|
import PINEnter from '../screens/PINEnter'
|
|
17
|
-
import
|
|
18
|
-
import {
|
|
20
|
+
import PushNotifications from '../screens/PushNotifications'
|
|
21
|
+
import { OnboardingStackParams } from '../types/navigators'
|
|
22
|
+
import { WalletSecret } from '../types/security'
|
|
19
23
|
import { State } from '../types/state'
|
|
20
24
|
import { Config } from '../types/config'
|
|
21
25
|
|
|
22
26
|
import { useDefaultStackOptions } from './defaultStackOptions'
|
|
23
|
-
import { DeviceEventEmitter } from 'react-native'
|
|
24
27
|
import { getOnboardingScreens } from './OnboardingScreens'
|
|
25
|
-
import { useOnboardingState } from '../hooks/useOnboardingState'
|
|
26
28
|
|
|
27
|
-
|
|
29
|
+
export type OnboardingStackProps = {
|
|
30
|
+
initializeAgent: (walletSecret: WalletSecret) => Promise<void>
|
|
31
|
+
agent: Agent | null
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
const OnboardingStack: React.FC<OnboardingStackProps> = ({ initializeAgent, agent }) => {
|
|
28
35
|
const [store, dispatch] = useStore<State>()
|
|
29
36
|
const { t } = useTranslation()
|
|
30
37
|
const Stack = createStackNavigator()
|
|
@@ -35,7 +42,7 @@ const OnboardingStack: React.FC = () => {
|
|
|
35
42
|
config,
|
|
36
43
|
Splash,
|
|
37
44
|
pages,
|
|
38
|
-
|
|
45
|
+
Biometry,
|
|
39
46
|
Onboarding,
|
|
40
47
|
Developer,
|
|
41
48
|
{ screen: Terms, version: termsVersion },
|
|
@@ -49,7 +56,7 @@ const OnboardingStack: React.FC = () => {
|
|
|
49
56
|
TOKENS.CONFIG,
|
|
50
57
|
TOKENS.SCREEN_SPLASH,
|
|
51
58
|
TOKENS.SCREEN_ONBOARDING_PAGES,
|
|
52
|
-
TOKENS.
|
|
59
|
+
TOKENS.SCREEN_BIOMETRY,
|
|
53
60
|
TOKENS.SCREEN_ONBOARDING,
|
|
54
61
|
TOKENS.SCREEN_DEVELOPER,
|
|
55
62
|
TOKENS.SCREEN_TERMS,
|
|
@@ -61,7 +68,7 @@ const OnboardingStack: React.FC = () => {
|
|
|
61
68
|
TOKENS.ONBOARDING,
|
|
62
69
|
])
|
|
63
70
|
const defaultStackOptions = useDefaultStackOptions(theme)
|
|
64
|
-
const navigation = useNavigation<StackNavigationProp<
|
|
71
|
+
const navigation = useNavigation<StackNavigationProp<OnboardingStackParams>>()
|
|
65
72
|
const onTutorialCompleted = onTutorialCompletedCurried(dispatch, navigation)
|
|
66
73
|
const currentRoute = useNavigationState((state) => state?.routes[state?.index])
|
|
67
74
|
const { disableOnboardingSkip } = config as Config
|
|
@@ -69,6 +76,7 @@ const OnboardingStack: React.FC = () => {
|
|
|
69
76
|
store,
|
|
70
77
|
config,
|
|
71
78
|
Number(termsVersion),
|
|
79
|
+
agent,
|
|
72
80
|
generateOnboardingWorkflowSteps
|
|
73
81
|
)
|
|
74
82
|
|
|
@@ -94,6 +102,10 @@ const OnboardingStack: React.FC = () => {
|
|
|
94
102
|
[dispatch]
|
|
95
103
|
)
|
|
96
104
|
|
|
105
|
+
const SplashScreen = useCallback(() => {
|
|
106
|
+
return <Splash initializeAgent={initializeAgent} />
|
|
107
|
+
}, [Splash, initializeAgent])
|
|
108
|
+
|
|
97
109
|
const UpdateAvailableScreen = useCallback(() => {
|
|
98
110
|
return (
|
|
99
111
|
<UpdateAvailable
|
|
@@ -153,13 +165,13 @@ const OnboardingStack: React.FC = () => {
|
|
|
153
165
|
const screens = useMemo(
|
|
154
166
|
() =>
|
|
155
167
|
getOnboardingScreens(t, ScreenOptionsDictionary, {
|
|
156
|
-
|
|
168
|
+
SplashScreen,
|
|
157
169
|
Preface,
|
|
158
170
|
UpdateAvailableScreen,
|
|
159
171
|
Terms,
|
|
160
172
|
NameWallet,
|
|
161
|
-
|
|
162
|
-
|
|
173
|
+
Biometry,
|
|
174
|
+
PushNotifications,
|
|
163
175
|
Developer,
|
|
164
176
|
AttemptLockout,
|
|
165
177
|
OnboardingScreen,
|
|
@@ -167,14 +179,14 @@ const OnboardingStack: React.FC = () => {
|
|
|
167
179
|
EnterPINScreen,
|
|
168
180
|
}),
|
|
169
181
|
[
|
|
170
|
-
|
|
182
|
+
SplashScreen,
|
|
171
183
|
CreatePINScreen,
|
|
172
184
|
Developer,
|
|
173
185
|
EnterPINScreen,
|
|
174
186
|
OnboardingScreen,
|
|
175
187
|
Preface,
|
|
176
188
|
Terms,
|
|
177
|
-
|
|
189
|
+
Biometry,
|
|
178
190
|
t,
|
|
179
191
|
ScreenOptionsDictionary,
|
|
180
192
|
UpdateAvailableScreen,
|
|
@@ -1,34 +1,39 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { useAgent, useProofByState } from '@credo-ts/react-hooks'
|
|
3
|
-
import { ProofCustomMetadata, ProofMetadata } from '@bifold/verifier'
|
|
1
|
+
import AgentProvider from '@credo-ts/react-hooks'
|
|
4
2
|
import React, { useState, useEffect, useMemo } from 'react'
|
|
5
3
|
import { useTranslation } from 'react-i18next'
|
|
6
4
|
import { DeviceEventEmitter } from 'react-native'
|
|
7
5
|
|
|
6
|
+
import { OpenIDCredentialRecordProvider } from '../modules/openid/context/OpenIDCredentialRecordProvider'
|
|
8
7
|
import { EventTypes } from '../constants'
|
|
9
8
|
import { TOKENS, useServices } from '../container-api'
|
|
9
|
+
import { ActivityProvider } from '../contexts/activity'
|
|
10
10
|
import { useStore } from '../contexts/store'
|
|
11
|
-
import { useDeepLinks } from '../hooks/deep-links'
|
|
12
11
|
import { BifoldError } from '../types/error'
|
|
13
12
|
import MainStack from './MainStack'
|
|
14
13
|
|
|
15
14
|
const RootStack: React.FC = () => {
|
|
16
15
|
const [store, dispatch] = useStore()
|
|
17
|
-
const { agent } = useAgent()
|
|
18
16
|
const { t } = useTranslation()
|
|
19
|
-
const [OnboardingStack, loadState] = useServices([
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
17
|
+
const [useAgentSetup, OnboardingStack, loadState] = useServices([
|
|
18
|
+
TOKENS.HOOK_USE_AGENT_SETUP,
|
|
19
|
+
TOKENS.STACK_ONBOARDING,
|
|
20
|
+
TOKENS.LOAD_STATE,
|
|
21
|
+
])
|
|
22
|
+
const { agent, initializeAgent, shutdownAndClearAgentIfExists } = useAgentSetup()
|
|
23
23
|
const [onboardingComplete, setOnboardingComplete] = useState(false)
|
|
24
24
|
|
|
25
|
-
useDeepLinks()
|
|
26
|
-
|
|
27
25
|
const shouldRenderMainStack = useMemo(
|
|
28
26
|
() => onboardingComplete && store.authentication.didAuthenticate,
|
|
29
27
|
[onboardingComplete, store.authentication.didAuthenticate]
|
|
30
28
|
)
|
|
31
29
|
|
|
30
|
+
useEffect(() => {
|
|
31
|
+
// if user gets locked out, erase agent
|
|
32
|
+
if (!store.authentication.didAuthenticate) {
|
|
33
|
+
shutdownAndClearAgentIfExists()
|
|
34
|
+
}
|
|
35
|
+
}, [store.authentication.didAuthenticate, shutdownAndClearAgentIfExists])
|
|
36
|
+
|
|
32
37
|
useEffect(() => {
|
|
33
38
|
const sub = DeviceEventEmitter.addListener(EventTypes.DID_COMPLETE_ONBOARDING, () => {
|
|
34
39
|
setOnboardingComplete(true)
|
|
@@ -38,28 +43,29 @@ const RootStack: React.FC = () => {
|
|
|
38
43
|
}, [])
|
|
39
44
|
|
|
40
45
|
useEffect(() => {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
agent?.connections.deleteById(proof?.connectionId ?? '').catch(() => null)
|
|
45
|
-
proof?.metadata.set(ProofMetadata.customMetadata, { ...meta, delete_conn_after_seen: false })
|
|
46
|
-
}
|
|
47
|
-
})
|
|
48
|
-
}, [declinedProofs, agent, store.preferences.useDataRetention])
|
|
49
|
-
|
|
50
|
-
useEffect(() => {
|
|
46
|
+
// Load state only if it hasn't been loaded yet
|
|
47
|
+
if (store.stateLoaded) return
|
|
48
|
+
|
|
51
49
|
loadState(dispatch).catch((err: unknown) => {
|
|
52
50
|
const error = new BifoldError(t('Error.Title1044'), t('Error.Message1044'), (err as Error).message, 1001)
|
|
53
51
|
|
|
54
52
|
DeviceEventEmitter.emit(EventTypes.ERROR_ADDED, error)
|
|
55
53
|
})
|
|
56
|
-
}, [dispatch, loadState, t])
|
|
54
|
+
}, [dispatch, loadState, t, store.stateLoaded])
|
|
57
55
|
|
|
58
|
-
if (shouldRenderMainStack) {
|
|
59
|
-
return
|
|
56
|
+
if (shouldRenderMainStack && agent) {
|
|
57
|
+
return (
|
|
58
|
+
<AgentProvider agent={agent}>
|
|
59
|
+
<OpenIDCredentialRecordProvider>
|
|
60
|
+
<ActivityProvider>
|
|
61
|
+
<MainStack />
|
|
62
|
+
</ActivityProvider>
|
|
63
|
+
</OpenIDCredentialRecordProvider>
|
|
64
|
+
</AgentProvider>
|
|
65
|
+
)
|
|
60
66
|
}
|
|
61
67
|
|
|
62
|
-
return <OnboardingStack />
|
|
68
|
+
return <OnboardingStack agent={agent} initializeAgent={initializeAgent} />
|
|
63
69
|
}
|
|
64
70
|
|
|
65
71
|
export default RootStack
|
|
@@ -9,8 +9,8 @@ import Language from '../screens/Language'
|
|
|
9
9
|
import NameWallet from '../screens/NameWallet'
|
|
10
10
|
import Onboarding from '../screens/Onboarding'
|
|
11
11
|
import { createCarouselStyle } from '../screens/OnboardingPages'
|
|
12
|
-
import
|
|
13
|
-
import
|
|
12
|
+
import PINChange from '../screens/PINChange'
|
|
13
|
+
import TogglePushNotifications from '../screens/TogglePushNotifications'
|
|
14
14
|
import Settings from '../screens/Settings'
|
|
15
15
|
import Tours from '../screens/Tours'
|
|
16
16
|
import { Screens, SettingStackParams } from '../types/navigators'
|
|
@@ -24,10 +24,10 @@ const SettingStack: React.FC = () => {
|
|
|
24
24
|
const Stack = createStackNavigator<SettingStackParams>()
|
|
25
25
|
const theme = useTheme()
|
|
26
26
|
const { t } = useTranslation()
|
|
27
|
-
const [pages, { screen: terms },
|
|
27
|
+
const [pages, { screen: terms }, ToggleBiometry, developer, ScreenOptionsDictionary] = useServices([
|
|
28
28
|
TOKENS.SCREEN_ONBOARDING_PAGES,
|
|
29
29
|
TOKENS.SCREEN_TERMS,
|
|
30
|
-
TOKENS.
|
|
30
|
+
TOKENS.SCREEN_TOGGLE_BIOMETRY,
|
|
31
31
|
TOKENS.SCREEN_DEVELOPER,
|
|
32
32
|
TOKENS.OBJECT_SCREEN_CONFIG,
|
|
33
33
|
])
|
|
@@ -92,31 +92,30 @@ const SettingStack: React.FC = () => {
|
|
|
92
92
|
}}
|
|
93
93
|
/>
|
|
94
94
|
<Stack.Screen
|
|
95
|
-
name={Screens.
|
|
96
|
-
component={
|
|
95
|
+
name={Screens.ToggleBiometry}
|
|
96
|
+
component={ToggleBiometry}
|
|
97
97
|
options={{
|
|
98
98
|
title: t('Screens.Biometry'),
|
|
99
99
|
headerBackTestID: testIdWithKey('Back'),
|
|
100
|
-
...ScreenOptionsDictionary[Screens.
|
|
100
|
+
...ScreenOptionsDictionary[Screens.ToggleBiometry],
|
|
101
101
|
}}
|
|
102
102
|
/>
|
|
103
103
|
<Stack.Screen
|
|
104
|
-
name={Screens.
|
|
104
|
+
name={Screens.ChangePIN}
|
|
105
|
+
component={PINChange}
|
|
105
106
|
options={{
|
|
106
107
|
title: t('Screens.ChangePIN'),
|
|
107
108
|
headerBackTestID: testIdWithKey('Back'),
|
|
108
|
-
...ScreenOptionsDictionary[Screens.
|
|
109
|
+
...ScreenOptionsDictionary[Screens.ChangePIN],
|
|
109
110
|
}}
|
|
110
|
-
>
|
|
111
|
-
{(props: any) => <PINCreate explainedStatus {...props} />}
|
|
112
|
-
</Stack.Screen>
|
|
111
|
+
></Stack.Screen>
|
|
113
112
|
<Stack.Screen
|
|
114
|
-
name={Screens.
|
|
115
|
-
component={
|
|
113
|
+
name={Screens.TogglePushNotifications}
|
|
114
|
+
component={TogglePushNotifications}
|
|
116
115
|
options={{
|
|
117
|
-
title: t('Screens.
|
|
116
|
+
title: t('Screens.PushNotifications'),
|
|
118
117
|
headerBackTestID: testIdWithKey('Back'),
|
|
119
|
-
...ScreenOptionsDictionary[Screens.
|
|
118
|
+
...ScreenOptionsDictionary[Screens.TogglePushNotifications],
|
|
120
119
|
}}
|
|
121
120
|
/>
|
|
122
121
|
<Stack.Screen
|
|
@@ -27,11 +27,18 @@ export const DefaultScreenOptionsDictionary: ScreenOptionsType = {
|
|
|
27
27
|
[Screens.CreatePIN]: {
|
|
28
28
|
headerBackTestID: testIdWithKey('Back'),
|
|
29
29
|
},
|
|
30
|
+
[Screens.ChangePIN]: {
|
|
31
|
+
headerBackTestID: testIdWithKey('Back'),
|
|
32
|
+
},
|
|
30
33
|
[Screens.NameWallet]: {
|
|
31
34
|
headerTintColor: OnboardingTheme.headerTintColor,
|
|
32
35
|
headerBackTestID: testIdWithKey('Back'),
|
|
33
36
|
},
|
|
34
|
-
[Screens.
|
|
37
|
+
[Screens.Biometry]: {
|
|
38
|
+
headerTintColor: OnboardingTheme.headerTintColor,
|
|
39
|
+
headerBackTestID: testIdWithKey('Back'),
|
|
40
|
+
},
|
|
41
|
+
[Screens.ToggleBiometry]: {
|
|
35
42
|
headerTintColor: OnboardingTheme.headerTintColor,
|
|
36
43
|
headerBackTestID: testIdWithKey('Back'),
|
|
37
44
|
},
|
|
@@ -39,7 +46,11 @@ export const DefaultScreenOptionsDictionary: ScreenOptionsType = {
|
|
|
39
46
|
headerTintColor: OnboardingTheme.headerTintColor,
|
|
40
47
|
headerBackTestID: testIdWithKey('Back'),
|
|
41
48
|
},
|
|
42
|
-
[Screens.
|
|
49
|
+
[Screens.PushNotifications]: {
|
|
50
|
+
headerTintColor: OnboardingTheme.headerTintColor,
|
|
51
|
+
headerBackTestID: testIdWithKey('Back'),
|
|
52
|
+
},
|
|
53
|
+
[Screens.TogglePushNotifications]: {
|
|
43
54
|
headerTintColor: OnboardingTheme.headerTintColor,
|
|
44
55
|
headerBackTestID: testIdWithKey('Back'),
|
|
45
56
|
},
|
package/src/onboarding.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Agent } from '@credo-ts/core'
|
|
2
|
+
import { OnboardingTask, Screens } from './types/navigators'
|
|
2
3
|
|
|
3
|
-
import { State } from './types/state'
|
|
4
4
|
import { Config } from './types/config'
|
|
5
|
+
import { State } from './types/state'
|
|
5
6
|
|
|
6
7
|
export const isPrefaceComplete = (didSeePreface: boolean, showPreface: boolean): OnboardingTask => {
|
|
7
8
|
return { name: Screens.Preface, completed: (didSeePreface && showPreface) || !showPreface }
|
|
@@ -24,7 +25,7 @@ export const isPINCreationComplete = (didCreatePIN: boolean): OnboardingTask =>
|
|
|
24
25
|
}
|
|
25
26
|
|
|
26
27
|
export const isBiometryComplete = (didConsiderBiometry: boolean): OnboardingTask => {
|
|
27
|
-
return { name: Screens.
|
|
28
|
+
return { name: Screens.Biometry, completed: didConsiderBiometry }
|
|
28
29
|
}
|
|
29
30
|
|
|
30
31
|
export const isPushNotificationComplete = (
|
|
@@ -32,7 +33,7 @@ export const isPushNotificationComplete = (
|
|
|
32
33
|
enablePushNotifications: any
|
|
33
34
|
): OnboardingTask => {
|
|
34
35
|
return {
|
|
35
|
-
name: Screens.
|
|
36
|
+
name: Screens.PushNotifications,
|
|
36
37
|
completed: !enablePushNotifications || (didConsiderPushNotifications && enablePushNotifications),
|
|
37
38
|
}
|
|
38
39
|
}
|
|
@@ -49,10 +50,15 @@ export const isAttemptLockoutComplete = (servedPenalty: boolean | undefined): On
|
|
|
49
50
|
return { name: Screens.AttemptLockout, completed: servedPenalty !== false }
|
|
50
51
|
}
|
|
51
52
|
|
|
53
|
+
export const isAgentInitializationComplete = (agent: Agent | null): OnboardingTask => {
|
|
54
|
+
return { name: Screens.Splash, completed: !!agent }
|
|
55
|
+
}
|
|
56
|
+
|
|
52
57
|
export const generateOnboardingWorkflowSteps = (
|
|
53
58
|
state: State,
|
|
54
59
|
config: Config,
|
|
55
|
-
termsVersion: number
|
|
60
|
+
termsVersion: number,
|
|
61
|
+
agent: Agent | null
|
|
56
62
|
): Array<OnboardingTask> => {
|
|
57
63
|
const {
|
|
58
64
|
didSeePreface,
|
|
@@ -79,5 +85,6 @@ export const generateOnboardingWorkflowSteps = (
|
|
|
79
85
|
isNameWalletComplete(didNameWallet, enableWalletNaming),
|
|
80
86
|
isAttemptLockoutComplete(servedPenalty),
|
|
81
87
|
isAuthenticationComplete(didCreatePIN, didAuthenticate),
|
|
88
|
+
isAgentInitializationComplete(agent),
|
|
82
89
|
]
|
|
83
90
|
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import React, { useCallback, useState } from 'react'
|
|
2
|
+
import { useTranslation } from 'react-i18next'
|
|
3
|
+
import { View } from 'react-native'
|
|
4
|
+
|
|
5
|
+
import Button, { ButtonType } from '../components/buttons/Button'
|
|
6
|
+
import BiometryControl from '../components/inputs/BiometryControl'
|
|
7
|
+
import { useAnimatedComponents } from '../contexts/animated-components'
|
|
8
|
+
import { useAuth } from '../contexts/auth'
|
|
9
|
+
import { DispatchAction } from '../contexts/reducers/store'
|
|
10
|
+
import { useStore } from '../contexts/store'
|
|
11
|
+
import { testIdWithKey } from '../utils/testable'
|
|
12
|
+
|
|
13
|
+
const Biometry: React.FC = () => {
|
|
14
|
+
const [store, dispatch] = useStore()
|
|
15
|
+
const { t } = useTranslation()
|
|
16
|
+
const { commitWalletToKeychain } = useAuth()
|
|
17
|
+
const [biometryEnabled, setBiometryEnabled] = useState(store.preferences.useBiometry)
|
|
18
|
+
const [continueEnabled, setContinueEnabled] = useState(true)
|
|
19
|
+
const { ButtonLoading } = useAnimatedComponents()
|
|
20
|
+
|
|
21
|
+
const continueTouched = useCallback(async () => {
|
|
22
|
+
setContinueEnabled(false)
|
|
23
|
+
|
|
24
|
+
await commitWalletToKeychain(biometryEnabled)
|
|
25
|
+
|
|
26
|
+
dispatch({
|
|
27
|
+
type: DispatchAction.USE_BIOMETRY,
|
|
28
|
+
payload: [biometryEnabled],
|
|
29
|
+
})
|
|
30
|
+
}, [biometryEnabled, commitWalletToKeychain, dispatch])
|
|
31
|
+
|
|
32
|
+
const handleBiometryToggle = useCallback((newValue: boolean) => {
|
|
33
|
+
setBiometryEnabled(newValue)
|
|
34
|
+
}, [])
|
|
35
|
+
|
|
36
|
+
return (
|
|
37
|
+
<BiometryControl
|
|
38
|
+
biometryEnabled={biometryEnabled}
|
|
39
|
+
onBiometryToggle={handleBiometryToggle}
|
|
40
|
+
>
|
|
41
|
+
<View style={{ marginTop: 'auto', margin: 20 }}>
|
|
42
|
+
<Button
|
|
43
|
+
title={t('Global.Continue')}
|
|
44
|
+
accessibilityLabel={'Continue'}
|
|
45
|
+
testID={testIdWithKey('Continue')}
|
|
46
|
+
onPress={continueTouched}
|
|
47
|
+
buttonType={ButtonType.Primary}
|
|
48
|
+
disabled={!continueEnabled}
|
|
49
|
+
>
|
|
50
|
+
{!continueEnabled && <ButtonLoading />}
|
|
51
|
+
</Button>
|
|
52
|
+
</View>
|
|
53
|
+
</BiometryControl>
|
|
54
|
+
)
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export default Biometry
|
|
@@ -290,8 +290,8 @@ const CredentialOffer: React.FC<CredentialOfferProps> = ({ navigation, credentia
|
|
|
290
290
|
}}
|
|
291
291
|
>
|
|
292
292
|
{loading ? <RecordLoading /> : null}
|
|
293
|
-
{credentialConnectionLabel && goalCode === 'aries.vc.issue' && (
|
|
294
|
-
<ConnectionAlert
|
|
293
|
+
{Boolean(credentialConnectionLabel) && goalCode === 'aries.vc.issue' && (
|
|
294
|
+
<ConnectionAlert connectionLabel={credentialConnectionLabel} />
|
|
295
295
|
)}
|
|
296
296
|
<View style={styles.footerButton}>
|
|
297
297
|
<Button
|
|
@@ -9,7 +9,7 @@ import IconButton, { ButtonLocation } from '../components/buttons/IconButton'
|
|
|
9
9
|
import { Pagination } from '../components/misc/Pagination'
|
|
10
10
|
import { DispatchAction } from '../contexts/reducers/store'
|
|
11
11
|
import { useStore } from '../contexts/store'
|
|
12
|
-
import {
|
|
12
|
+
import { OnboardingStackParams } from '../types/navigators'
|
|
13
13
|
import { testIdWithKey } from '../utils/testable'
|
|
14
14
|
export interface OnboardingStyleSheet {
|
|
15
15
|
container: ViewStyle
|
|
@@ -41,7 +41,7 @@ const Onboarding: React.FC<OnboardingProps> = ({
|
|
|
41
41
|
const flatList: Ref<FlatList> = useRef(null)
|
|
42
42
|
const scrollX = useRef(new Animated.Value(0)).current
|
|
43
43
|
const { t } = useTranslation()
|
|
44
|
-
const navigation = useNavigation<StackNavigationProp<
|
|
44
|
+
const navigation = useNavigation<StackNavigationProp<OnboardingStackParams>>()
|
|
45
45
|
const [, dispatch] = useStore()
|
|
46
46
|
const { width } = useWindowDimensions()
|
|
47
47
|
|