@dynamic-labs/sdk-react-core 0.19.2 → 0.19.4
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/CHANGELOG.md +31 -0
- package/package.cjs +2 -2
- package/package.js +2 -2
- package/package.json +10 -10
- package/src/index.cjs +8 -2
- package/src/index.js +5 -1
- package/src/lib/components/Accordion/components/AccordionItem/AccordionItem.cjs +2 -0
- package/src/lib/components/Accordion/components/AccordionItem/AccordionItem.js +2 -0
- package/src/lib/components/AnimatePresence/AnimatePresence.cjs +2 -0
- package/src/lib/components/AnimatePresence/AnimatePresence.js +2 -0
- package/src/lib/components/AuthProviderIcon/AuthProviderIcon.cjs +2 -0
- package/src/lib/components/AuthProviderIcon/AuthProviderIcon.js +2 -0
- package/src/lib/components/Button/Button.cjs +4 -2
- package/src/lib/components/Button/Button.d.ts +1 -0
- package/src/lib/components/Button/Button.js +4 -2
- package/src/lib/components/Divider/Divider.cjs +2 -0
- package/src/lib/components/Divider/Divider.js +2 -0
- package/src/lib/components/MenuList/Dropdown/Dropdown.cjs +2 -0
- package/src/lib/components/MenuList/Dropdown/Dropdown.js +2 -0
- package/src/lib/components/Modal/Modal.cjs +2 -0
- package/src/lib/components/Modal/Modal.js +2 -0
- package/src/lib/components/NeedHelpSection/NeedHelpSection.cjs +5 -2
- package/src/lib/components/NeedHelpSection/NeedHelpSection.js +5 -2
- package/src/lib/components/NetworkPicker/NetworkPicker.cjs +2 -0
- package/src/lib/components/NetworkPicker/NetworkPicker.js +2 -0
- package/src/lib/components/NetworkPicker/components/EvmNetworkControl/EvmNetworkControl.cjs +2 -0
- package/src/lib/components/NetworkPicker/components/EvmNetworkControl/EvmNetworkControl.js +2 -0
- package/src/lib/components/NetworkPicker/components/Network/Network.cjs +2 -0
- package/src/lib/components/NetworkPicker/components/Network/Network.js +2 -0
- package/src/lib/components/NetworkPicker/components/NonNetworkSwitchingSupportedControl/NonNetworkSwitchingSupportedControl.cjs +2 -0
- package/src/lib/components/NetworkPicker/components/NonNetworkSwitchingSupportedControl/NonNetworkSwitchingSupportedControl.js +2 -0
- package/src/lib/components/OTPVerificationView/OTPVerificationView.cjs +2 -0
- package/src/lib/components/OTPVerificationView/OTPVerificationView.js +2 -0
- package/src/lib/components/OverlayCard/OverlayCard.cjs +2 -0
- package/src/lib/components/OverlayCard/OverlayCard.js +2 -0
- package/src/lib/components/Portal/Portal.cjs +2 -0
- package/src/lib/components/Portal/Portal.js +2 -0
- package/src/lib/components/SocialSignIn/SocialSignIn.cjs +2 -0
- package/src/lib/components/SocialSignIn/SocialSignIn.js +2 -0
- package/src/lib/components/SyncPasskeyFlow/SyncPasskeyFlow.cjs +18 -5
- package/src/lib/components/SyncPasskeyFlow/SyncPasskeyFlow.js +18 -5
- package/src/lib/components/Textarea/Textarea.d.ts +2 -0
- package/src/lib/components/Textarea/Textarea.types.d.ts +14 -0
- package/src/lib/components/Textarea/index.d.ts +1 -0
- package/src/lib/components/Tooltip/Tooltip.cjs +2 -0
- package/src/lib/components/Tooltip/Tooltip.js +2 -0
- package/src/lib/components/TransactionStatusLayout/TransactionStatusLayout.cjs +2 -0
- package/src/lib/components/TransactionStatusLayout/TransactionStatusLayout.js +2 -0
- package/src/lib/components/Transition/VerticalDrawerTransition/VerticalDrawerTransition.cjs +2 -0
- package/src/lib/components/Transition/VerticalDrawerTransition/VerticalDrawerTransition.js +2 -0
- package/src/lib/components/UserAddress/UserAddress.cjs +2 -0
- package/src/lib/components/UserAddress/UserAddress.js +2 -0
- package/src/lib/components/UserProfile/parts/UserProfileField/UserProfileField.cjs +2 -0
- package/src/lib/components/UserProfile/parts/UserProfileField/UserProfileField.js +2 -0
- package/src/lib/components/UserProfile/parts/UserProfileSection/UserProfileSection.cjs +2 -0
- package/src/lib/components/UserProfile/parts/UserProfileSection/UserProfileSection.js +2 -0
- package/src/lib/components/UserProfile/parts/UserProfileSocialAccount/UserProfileSocialAccount.cjs +1 -0
- package/src/lib/components/UserProfile/parts/UserProfileSocialAccount/UserProfileSocialAccount.js +1 -0
- package/src/lib/context/DynamicContext/DynamicContext.cjs +15 -14
- package/src/lib/context/DynamicContext/DynamicContext.js +16 -15
- package/src/lib/context/DynamicContext/internalEvents/internalEvents.d.ts +2 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/useCustomerAuthFlowCallbacks.cjs +2 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/useCustomerAuthFlowCallbacks.js +2 -0
- package/src/lib/context/QrCodeContext/QrCodeContext.cjs +2 -0
- package/src/lib/context/QrCodeContext/QrCodeContext.js +2 -0
- package/src/lib/context/SendBalanceContext/SendBalanceContext.cjs +2 -0
- package/src/lib/context/SendBalanceContext/SendBalanceContext.js +2 -0
- package/src/lib/context/SocialRedirectContext/SocialRedirectContext.cjs +2 -0
- package/src/lib/context/SocialRedirectContext/SocialRedirectContext.js +2 -0
- package/src/lib/context/UserFieldEditorContext/UserFieldEditorContext.cjs +2 -0
- package/src/lib/context/UserFieldEditorContext/UserFieldEditorContext.js +2 -0
- package/src/lib/context/ViewContext/ViewContext.d.ts +1 -1
- package/src/lib/data/api.cjs +37 -0
- package/src/lib/data/api.d.ts +20 -0
- package/src/lib/data/api.js +36 -2
- package/src/lib/layout/DynamicAuthLayout/DynamicAuthLayout.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/DynamicAuthLayout.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/Header/header.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/Header/header.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/HelpHeader/HelpHeader.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/HelpHeader/HelpHeader.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/PasskeyInfoHelper/PasskeyInfoHelper.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/PasskeyInfoHelper/PasskeyInfoHelper.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/Item/Item.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/Item/Item.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/WalletExtensionOrAppContinueButton/WalletExtensionOrAppContinueButton.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/WalletExtensionOrAppContinueButton/WalletExtensionOrAppContinueButton.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/WalletListHelpContent.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/WalletListHelpContent.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletMoreInfoContent/WalletMoreInfoContent.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletMoreInfoContent/WalletMoreInfoContent.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/ToSFooter/ToSFooter.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/ToSFooter/ToSFooter.js +2 -0
- package/src/lib/layout/DynamicAuthLayout/WalletProgressStepper/WalletProgressStepper.cjs +2 -0
- package/src/lib/layout/DynamicAuthLayout/WalletProgressStepper/WalletProgressStepper.js +2 -0
- package/src/lib/layout/DynamicUserProfileLayout/DynamicUserProfileLayout.cjs +7 -1
- package/src/lib/layout/DynamicUserProfileLayout/DynamicUserProfileLayout.js +7 -1
- package/src/lib/layouts/BridgeNextWalletToConnectLayout/BridgeNextWalletToConnectLayout.cjs +2 -0
- package/src/lib/layouts/BridgeNextWalletToConnectLayout/BridgeNextWalletToConnectLayout.js +2 -0
- package/src/lib/layouts/BridgeWelcomeLayout/BridgeWelcomeLayout.cjs +2 -0
- package/src/lib/layouts/BridgeWelcomeLayout/BridgeWelcomeLayout.js +2 -0
- package/src/lib/layouts/ConnectedWalletsListLayout/ConnectedWalletsListLayout.cjs +2 -0
- package/src/lib/layouts/ConnectedWalletsListLayout/ConnectedWalletsListLayout.js +2 -0
- package/src/lib/locale/en/translation.cjs +123 -5
- package/src/lib/locale/en/translation.d.ts +122 -4
- package/src/lib/locale/en/translation.js +123 -5
- package/src/lib/main.global.cjs +1 -1
- package/src/lib/main.global.js +1 -1
- package/src/lib/modals/DynamicAuthModal/DynamicAuthModal.cjs +2 -0
- package/src/lib/modals/DynamicAuthModal/DynamicAuthModal.js +2 -0
- package/src/lib/modals/SendBalanceModal/SendBalanceModal.cjs +2 -0
- package/src/lib/modals/SendBalanceModal/SendBalanceModal.js +2 -0
- package/src/lib/modals/SignMessageConfirmationModal/SignMessageConfirmationModal.cjs +2 -0
- package/src/lib/modals/SignMessageConfirmationModal/SignMessageConfirmationModal.js +2 -0
- package/src/lib/modals/SignMessageConfirmationModal/SignMessageConfirmationModal.types.d.ts +2 -7
- package/src/lib/modals/SignMessageConfirmationModal/getProperErrorMessage.cjs +17 -8
- package/src/lib/modals/SignMessageConfirmationModal/getProperErrorMessage.d.ts +1 -1
- package/src/lib/modals/SignMessageConfirmationModal/getProperErrorMessage.js +17 -8
- package/src/lib/modals/TransactionConfirmationModal/TransactionConfirmationModal.cjs +5 -2
- package/src/lib/modals/TransactionConfirmationModal/TransactionConfirmationModal.js +5 -2
- package/src/lib/modals/UserFieldEditorModal/UserFieldEditorModal.cjs +2 -0
- package/src/lib/modals/UserFieldEditorModal/UserFieldEditorModal.js +2 -0
- package/src/lib/shared/assets/circle-locker.cjs +53 -0
- package/src/lib/shared/assets/circle-locker.js +29 -0
- package/src/lib/shared/assets/index.d.ts +2 -0
- package/src/lib/shared/assets/turnkey.cjs +79 -0
- package/src/lib/shared/assets/turnkey.js +55 -0
- package/src/lib/shared/utils/functions/detectBrowser/detectBrowser.cjs +5 -5
- package/src/lib/shared/utils/functions/detectBrowser/detectBrowser.d.ts +1 -1
- package/src/lib/shared/utils/functions/detectBrowser/detectBrowser.js +5 -5
- package/src/lib/styles/index.shadow.cjs +1 -1
- package/src/lib/styles/index.shadow.js +1 -1
- package/src/lib/utils/functions/index.d.ts +1 -0
- package/src/lib/utils/functions/removeElementById/index.d.ts +1 -0
- package/src/lib/utils/functions/removeElementById/removeElementById.cjs +16 -0
- package/src/lib/utils/functions/removeElementById/removeElementById.d.ts +1 -0
- package/src/lib/utils/functions/removeElementById/removeElementById.js +12 -0
- package/src/lib/utils/hooks/useAuthLayoutChecks/useAuthLayoutChecks.cjs +5 -2
- package/src/lib/utils/hooks/useAuthLayoutChecks/useAuthLayoutChecks.js +5 -2
- package/src/lib/utils/hooks/useDynamicLayoutData/useDynamicLayoutData.cjs +9 -0
- package/src/lib/utils/hooks/useDynamicLayoutData/useDynamicLayoutData.js +9 -0
- package/src/lib/utils/hooks/useEmbeddedWallet/useEmbeddedWallet.cjs +35 -18
- package/src/lib/utils/hooks/useEmbeddedWallet/useEmbeddedWallet.js +35 -18
- package/src/lib/utils/hooks/useIsFirstRender/useIsFirstRender.cjs +6 -4
- package/src/lib/utils/hooks/useIsFirstRender/useIsFirstRender.js +7 -5
- package/src/lib/utils/hooks/usePasskeyRecovery/index.d.ts +1 -0
- package/src/lib/utils/hooks/usePasskeyRecovery/usePasskeyRecovery.cjs +67 -0
- package/src/lib/utils/hooks/usePasskeyRecovery/usePasskeyRecovery.d.ts +4 -0
- package/src/lib/utils/hooks/usePasskeyRecovery/usePasskeyRecovery.js +63 -0
- package/src/lib/utils/hooks/useUserUpdateRequest/useUpdateUser/useUpdateUser.cjs +5 -1
- package/src/lib/utils/hooks/useUserUpdateRequest/useUpdateUser/useUpdateUser.js +5 -1
- package/src/lib/utils/hooks/useWalletUiUtils/useWalletUiUtils.cjs +2 -0
- package/src/lib/utils/hooks/useWalletUiUtils/useWalletUiUtils.js +2 -0
- package/src/lib/utils/hooks/useWalletsConnectionState/useWalletsConnectionState.cjs +13 -1
- package/src/lib/utils/hooks/useWalletsConnectionState/useWalletsConnectionState.js +14 -2
- package/src/lib/views/AccountExistsView/AccountExistsView.cjs +2 -0
- package/src/lib/views/AccountExistsView/AccountExistsView.js +2 -0
- package/src/lib/views/CaptchaVerifyUser/CaptchaVerifyUser.cjs +2 -0
- package/src/lib/views/CaptchaVerifyUser/CaptchaVerifyUser.js +2 -0
- package/src/lib/views/CollectUserDataView/CollectUserDataView.cjs +2 -0
- package/src/lib/views/CollectUserDataView/CollectUserDataView.js +2 -0
- package/src/lib/views/CollectUserDataView/OnboardingUserDataForm/OnboardingUserDataForm.cjs +2 -0
- package/src/lib/views/CollectUserDataView/OnboardingUserDataForm/OnboardingUserDataForm.js +2 -0
- package/src/lib/views/CollectUserDataView/UserDataFields/index.cjs +2 -0
- package/src/lib/views/CollectUserDataView/UserDataFields/index.js +2 -0
- package/src/lib/views/CollectUserDataViewLoginWithEmail/CollectUserDataViewLoginWithEmail.cjs +2 -0
- package/src/lib/views/CollectUserDataViewLoginWithEmail/CollectUserDataViewLoginWithEmail.js +2 -0
- package/src/lib/views/EmailConfirmationWaitingView/EmailConfirmationWaitingView.cjs +2 -0
- package/src/lib/views/EmailConfirmationWaitingView/EmailConfirmationWaitingView.js +2 -0
- package/src/lib/views/EmailUpdate/EmailUpdate.cjs +2 -0
- package/src/lib/views/EmailUpdate/EmailUpdate.js +2 -0
- package/src/lib/views/EmailVerification/EmailVerification.cjs +2 -0
- package/src/lib/views/EmailVerification/EmailVerification.js +2 -0
- package/src/lib/views/EmailWalletOTPVerificationView/EmailWalletOTPVerificationView.cjs +2 -0
- package/src/lib/views/EmailWalletOTPVerificationView/EmailWalletOTPVerificationView.js +2 -0
- package/src/lib/views/LoginView/sections/EmailSignInSection/LoginEmailForm.cjs +2 -0
- package/src/lib/views/LoginView/sections/EmailSignInSection/LoginEmailForm.js +2 -0
- package/src/lib/views/LoginView/sections/SocialSignInSection/DynamicSocialSignIn/DynamicSocialSignIn.cjs +2 -0
- package/src/lib/views/LoginView/sections/SocialSignInSection/DynamicSocialSignIn/DynamicSocialSignIn.js +2 -0
- package/src/lib/views/LoginView/sections/SocialSignInSection/MagicSocialSignIn/MagicSocialSignIn.cjs +2 -0
- package/src/lib/views/LoginView/sections/SocialSignInSection/MagicSocialSignIn/MagicSocialSignIn.js +2 -0
- package/src/lib/views/LoginView/sections/WalletSignInSection/ListItemButton/ListItemButton.cjs +2 -0
- package/src/lib/views/LoginView/sections/WalletSignInSection/ListItemButton/ListItemButton.js +2 -0
- package/src/lib/views/LoginView/sections/WalletSignInSection/WalletSignInSection.cjs +2 -0
- package/src/lib/views/LoginView/sections/WalletSignInSection/WalletSignInSection.js +2 -0
- package/src/lib/views/MergeUserAccountsView/MergeUserAccountsView.cjs +2 -0
- package/src/lib/views/MergeUserAccountsView/MergeUserAccountsView.js +2 -0
- package/src/lib/views/NetworkNotSupported/NetworkNotSupported.cjs +2 -0
- package/src/lib/views/NetworkNotSupported/NetworkNotSupported.js +2 -0
- package/src/lib/views/NetworkNotSupportedSwitchManual/NetworkNotSupportedSwitchManual.cjs +2 -0
- package/src/lib/views/NetworkNotSupportedSwitchManual/NetworkNotSupportedSwitchManual.js +2 -0
- package/src/lib/views/NoAccess/NoAccess.cjs +2 -0
- package/src/lib/views/NoAccess/NoAccess.js +2 -0
- package/src/lib/views/NoQrNotInstalledView/NoQrNotInstalledView.cjs +2 -0
- package/src/lib/views/NoQrNotInstalledView/NoQrNotInstalledView.js +2 -0
- package/src/lib/views/NoQrNotInstalledView/WalletHelpLink.cjs +2 -0
- package/src/lib/views/NoQrNotInstalledView/WalletHelpLink.js +2 -0
- package/src/lib/views/Passkey/PasskeyDeviceIcon/PasskeyDeviceIcon.cjs +90 -0
- package/src/lib/views/Passkey/PasskeyDeviceIcon/PasskeyDeviceIcon.d.ts +2 -0
- package/src/lib/views/Passkey/PasskeyDeviceIcon/PasskeyDeviceIcon.js +86 -0
- package/src/lib/views/Passkey/PasskeyDeviceIcon/index.d.ts +1 -0
- package/src/lib/views/Passkey/PasskeyIntroView/PasskeyIntroView.cjs +133 -0
- package/src/lib/views/{PasskeyIntroView → Passkey/PasskeyIntroView}/PasskeyIntroView.d.ts +1 -1
- package/src/lib/views/Passkey/PasskeyIntroView/PasskeyIntroView.js +129 -0
- package/src/lib/views/Passkey/PasskeyRecovery/BundleValidation/PasskeyBundleRecovery.cjs +136 -0
- package/src/lib/views/Passkey/PasskeyRecovery/BundleValidation/PasskeyBundleRecovery.d.ts +2 -0
- package/src/lib/views/Passkey/PasskeyRecovery/BundleValidation/PasskeyBundleRecovery.js +132 -0
- package/src/lib/views/Passkey/PasskeyRecovery/BundleValidation/index.d.ts +1 -0
- package/src/lib/views/Passkey/PasskeyRecovery/CompleteRecovery/PasskeyCompleteRecovery.cjs +108 -0
- package/src/lib/views/Passkey/PasskeyRecovery/CompleteRecovery/PasskeyCompleteRecovery.d.ts +2 -0
- package/src/lib/views/Passkey/PasskeyRecovery/CompleteRecovery/PasskeyCompleteRecovery.js +104 -0
- package/src/lib/views/Passkey/PasskeyRecovery/CompleteRecovery/index.d.ts +1 -0
- package/src/lib/views/Passkey/PasskeyRecovery/InitRecovery/PasskeyInitRecovery.cjs +115 -0
- package/src/lib/views/Passkey/PasskeyRecovery/InitRecovery/PasskeyInitRecovery.d.ts +2 -0
- package/src/lib/views/Passkey/PasskeyRecovery/InitRecovery/PasskeyInitRecovery.js +111 -0
- package/src/lib/views/Passkey/PasskeyRecovery/InitRecovery/index.d.ts +1 -0
- package/src/lib/views/Passkey/PasskeyRecovery/constants.cjs +9 -0
- package/src/lib/views/Passkey/PasskeyRecovery/constants.d.ts +2 -0
- package/src/lib/views/Passkey/PasskeyRecovery/constants.js +4 -0
- package/src/lib/views/Passkey/PasskeyRecovery/index.d.ts +3 -0
- package/src/lib/views/Passkey/index.d.ts +2 -0
- package/src/lib/views/Passkey/passkey.types.d.ts +8 -0
- package/src/lib/views/Passkey/utils/passkeyRecovery/index.d.ts +1 -0
- package/src/lib/views/Passkey/utils/passkeyRecovery/passkeyRecovery.cjs +141 -0
- package/src/lib/views/Passkey/utils/passkeyRecovery/passkeyRecovery.d.ts +26 -0
- package/src/lib/views/Passkey/utils/passkeyRecovery/passkeyRecovery.js +134 -0
- package/src/lib/views/PendingConnectView/PendingConnectView.cjs +2 -0
- package/src/lib/views/PendingConnectView/PendingConnectView.js +2 -0
- package/src/lib/views/PendingSignatureView/PendingSignatureView.cjs +2 -0
- package/src/lib/views/PendingSignatureView/PendingSignatureView.js +2 -0
- package/src/lib/views/QrCodeView/QRCode.cjs +2 -0
- package/src/lib/views/QrCodeView/QRCode.js +2 -0
- package/src/lib/views/QrCodeView/QrCodeContainer/QrCodeContainer.cjs +2 -0
- package/src/lib/views/QrCodeView/QrCodeContainer/QrCodeContainer.js +2 -0
- package/src/lib/views/QrCodeView/QrCodeView.cjs +2 -0
- package/src/lib/views/QrCodeView/QrCodeView.js +2 -0
- package/src/lib/views/SendBalanceView/SendBalanceView.cjs +2 -0
- package/src/lib/views/SendBalanceView/SendBalanceView.js +2 -0
- package/src/lib/views/SendBalanceView/components/TransactionStage/TransactionStage.cjs +2 -0
- package/src/lib/views/SendBalanceView/components/TransactionStage/TransactionStage.js +2 -0
- package/src/lib/views/SocialRedirectView/SocialRedirectView.cjs +2 -0
- package/src/lib/views/SocialRedirectView/SocialRedirectView.js +2 -0
- package/src/lib/views/SocialWrongAccountView/SocialWrongAccountView.cjs +2 -0
- package/src/lib/views/SocialWrongAccountView/SocialWrongAccountView.js +2 -0
- package/src/lib/views/TransactionConfirmationView/TransactionConfirmationView.cjs +2 -0
- package/src/lib/views/TransactionConfirmationView/TransactionConfirmationView.js +2 -0
- package/src/lib/views/TransactionConfirmationView/hooks/useTransactionGas/useTransactionGas.cjs +2 -0
- package/src/lib/views/TransactionConfirmationView/hooks/useTransactionGas/useTransactionGas.js +2 -0
- package/src/lib/views/UserFieldEditorView/UserFieldEditorView.cjs +2 -0
- package/src/lib/views/UserFieldEditorView/UserFieldEditorView.js +2 -0
- package/src/lib/views/WalletCannotBeTransferredView/WalletCannotBeTransferredView.cjs +2 -0
- package/src/lib/views/WalletCannotBeTransferredView/WalletCannotBeTransferredView.js +2 -0
- package/src/lib/views/WalletList/SearchNotFoundMessage/SearchNotFoundMessage.cjs +2 -0
- package/src/lib/views/WalletList/SearchNotFoundMessage/SearchNotFoundMessage.js +2 -0
- package/src/lib/views/WalletList/WalletListItem/WalletListItem.cjs +2 -0
- package/src/lib/views/WalletList/WalletListItem/WalletListItem.js +2 -0
- package/src/lib/views/WalletLockedView/WalletLockedView.cjs +2 -0
- package/src/lib/views/WalletLockedView/WalletLockedView.js +2 -0
- package/src/lib/views/WalletSignSpinnerView/WalletSignSpinnerView.cjs +2 -0
- package/src/lib/views/WalletSignSpinnerView/WalletSignSpinnerView.js +2 -0
- package/src/lib/views/WalletUsedView/WalletUsedView.cjs +2 -0
- package/src/lib/views/WalletUsedView/WalletUsedView.js +2 -0
- package/src/lib/views/viewToComponentMap.cjs +7 -1
- package/src/lib/views/viewToComponentMap.js +7 -1
- package/src/lib/widgets/DynamicBridgeWidget/DynamicBridgeWidget.cjs +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/DynamicBridgeWidget.js +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeUserProfile/DynamicBridgeUserProfile.cjs +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeUserProfile/DynamicBridgeUserProfile.js +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWalletCard/DynamicBridgeWalletCard.cjs +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWalletCard/DynamicBridgeWalletCard.js +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWalletCardBody/DynamicBridgeWalletCardBody.cjs +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWalletCardBody/DynamicBridgeWalletCardBody.js +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWidgetEmptyCard/DynamicBridgeWidgetEmptyCard.cjs +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWidgetEmptyCard/DynamicBridgeWidgetEmptyCard.js +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/views/WalletsView/WalletsView.cjs +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/views/WalletsView/WalletsView.js +2 -0
- package/src/lib/widgets/DynamicEmbeddedWidget/DynamicEmbeddedAuthFlow/DynamicEmbeddedAuthFlow.cjs +4 -1
- package/src/lib/widgets/DynamicEmbeddedWidget/DynamicEmbeddedAuthFlow/DynamicEmbeddedAuthFlow.d.ts +1 -1
- package/src/lib/widgets/DynamicEmbeddedWidget/DynamicEmbeddedAuthFlow/DynamicEmbeddedAuthFlow.js +4 -1
- package/src/lib/widgets/DynamicEmbeddedWidget/DynamicEmbeddedUserProfile/DynamicEmbeddedUserProfile.cjs +2 -1
- package/src/lib/widgets/DynamicEmbeddedWidget/DynamicEmbeddedUserProfile/DynamicEmbeddedUserProfile.d.ts +1 -1
- package/src/lib/widgets/DynamicEmbeddedWidget/DynamicEmbeddedUserProfile/DynamicEmbeddedUserProfile.js +2 -1
- package/src/lib/widgets/DynamicWidget/DynamicWidget.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/DynamicWidget.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/AccountControl/AccountControl.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/AccountControl/AccountControl.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/ActiveWalletInformation/ActiveWalletInformation.cjs +11 -2
- package/src/lib/widgets/DynamicWidget/components/ActiveWalletInformation/ActiveWalletInformation.js +11 -2
- package/src/lib/widgets/DynamicWidget/components/Balance/Balance.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/Balance/Balance.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/DotsMenu/DotsMenu.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DotsMenu/DotsMenu.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/DotsMenuDropdown/DotsMenuDropdown.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DotsMenuDropdown/DotsMenuDropdown.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicNav/DynamicNav.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicNav/DynamicNav.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicUserProfile/DynamicUserProfile.cjs +1 -1
- package/src/lib/widgets/DynamicWidget/components/DynamicUserProfile/DynamicUserProfile.js +1 -1
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetHeader.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetHeader.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetWalletHeader/DynamicWidgetWalletHeader.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetWalletHeader/DynamicWidgetWalletHeader.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/DynamicWidgetVariants.cjs +10 -1
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/DynamicWidgetVariants.js +10 -1
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/variants/DynamicWidgetDropdown/DynamicWidgetDropdown.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/variants/DynamicWidgetDropdown/DynamicWidgetDropdown.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/variants/DynamicWidgetModal/DynamicWidgetModal.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/variants/DynamicWidgetModal/DynamicWidgetModal.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetViews/DynamicWidgetViews.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetViews/DynamicWidgetViews.d.ts +2 -2
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetViews/DynamicWidgetViews.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetWallets/DynamicWidgetWallets.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetWallets/DynamicWidgetWallets.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/EmailConnectorPendingSignModalContent/EmailConnectorPendingSignModalContent.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/EmailConnectorPendingSignModalContent/EmailConnectorPendingSignModalContent.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/EmailOTPConnectorPendingSignModalContent/EmailOTPConnectorPendingSignModalContent.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/EmailOTPConnectorPendingSignModalContent/EmailOTPConnectorPendingSignModalContent.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/EmptyWallets/EmptyWallets.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/EmptyWallets/EmptyWallets.js +2 -0
- package/src/lib/widgets/DynamicWidget/components/SingleWalletButtons/SingleWalletButtons.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/SingleWalletButtons/SingleWalletButtons.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/Wallet/Wallet.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/Wallet/Wallet.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/WidgetPortal/WidgetPortal.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/components/WidgetPortal/WidgetPortal.js +2 -0
- package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.d.ts +2 -13
- package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.js +2 -0
- package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.types.cjs +9 -0
- package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.types.d.ts +17 -0
- package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.types.js +4 -0
- package/src/lib/widgets/DynamicWidget/helpers/getPasskeyProviderFromUserAgent.cjs +33 -0
- package/src/lib/widgets/DynamicWidget/helpers/getPasskeyProviderFromUserAgent.d.ts +2 -0
- package/src/lib/widgets/DynamicWidget/helpers/getPasskeyProviderFromUserAgent.js +29 -0
- package/src/lib/widgets/DynamicWidget/helpers/getTimeSince.cjs +64 -0
- package/src/lib/widgets/DynamicWidget/helpers/getTimeSince.d.ts +4 -0
- package/src/lib/widgets/DynamicWidget/helpers/getTimeSince.js +60 -0
- package/src/lib/widgets/DynamicWidget/helpers/helpers.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/helpers/helpers.d.ts +2 -1
- package/src/lib/widgets/DynamicWidget/helpers/helpers.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/DefaultPromptModal/DefaultPromptModal.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/DefaultPromptModal/DefaultPromptModal.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/DetectedNewWalletModal/DetectedNewWalletModal.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/DetectedNewWalletModal/DetectedNewWalletModal.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/NoQrNotInstalledModalView/NoQrNotInstalledModalView.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/NoQrNotInstalledModalView/NoQrNotInstalledModalView.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchModal/SwitchAccountView/SwitchAccountView.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchModal/SwitchAccountView/SwitchAccountView.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchModal/SwitchOrUseActiveAccountView/SwitchOrUseActiveAccountView.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchModal/SwitchOrUseActiveAccountView/SwitchOrUseActiveAccountView.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchToLinkModal/PendingAccountSwitchToLinkModal.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchToLinkModal/PendingAccountSwitchToLinkModal.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingConnectionModal/PendingConnectionModal.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingConnectionModal/PendingConnectionModal.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingSignModal/DefaultPendingSignModalContent/DefaultPendingSignModalContent.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingSignModal/DefaultPendingSignModalContent/DefaultPendingSignModalContent.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PrimaryNotConnectedModal/PrimaryNotConnectedModal.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/PrimaryNotConnectedModal/PrimaryNotConnectedModal.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/QrCodeModalView/QrCodeModalView.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/QrCodeModalView/QrCodeModalView.js +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/UnlinkWalletPopUp/UnlinkWalletPopUp.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/prompts/UnlinkWalletPopUp/UnlinkWalletPopUp.js +2 -0
- package/src/lib/widgets/DynamicWidget/views/EditProfileView/EditProfileView.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/views/EditProfileView/EditProfileView.js +2 -0
- package/src/lib/widgets/DynamicWidget/views/ManagePasskeysWidgetView/ManagePasskeysWidgetView.cjs +96 -0
- package/src/lib/widgets/DynamicWidget/views/ManagePasskeysWidgetView/ManagePasskeysWidgetView.d.ts +2 -0
- package/src/lib/widgets/DynamicWidget/views/ManagePasskeysWidgetView/ManagePasskeysWidgetView.js +92 -0
- package/src/lib/widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.cjs +98 -0
- package/src/lib/widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.d.ts +7 -0
- package/src/lib/widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.js +94 -0
- package/src/lib/widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/index.d.ts +1 -0
- package/src/lib/widgets/DynamicWidget/views/ManagePasskeysWidgetView/index.d.ts +1 -0
- package/src/lib/widgets/DynamicWidget/views/ProfileView/ProfileView.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/views/ProfileView/ProfileView.js +2 -0
- package/src/lib/widgets/DynamicWidget/views/WalletsView/WalletsView.cjs +2 -0
- package/src/lib/widgets/DynamicWidget/views/WalletsView/WalletsView.js +2 -0
- package/src/lib/widgets/DynamicWidget/views/index.d.ts +1 -0
- package/src/lib/widgets/FundingWidget/views/FundWalletView/FundWalletView.cjs +2 -0
- package/src/lib/widgets/FundingWidget/views/FundWalletView/FundWalletView.js +2 -0
- package/src/lib/views/PasskeyIntroView/PasskeyIntroView.cjs +0 -156
- package/src/lib/views/PasskeyIntroView/PasskeyIntroView.js +0 -152
- /package/src/lib/views/{PasskeyIntroView → Passkey/PasskeyIntroView}/index.d.ts +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/createEmbeddedWalletWithPasskey/createEmbeddedWalletWithPasskey.cjs +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/createEmbeddedWalletWithPasskey/createEmbeddedWalletWithPasskey.d.ts +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/createEmbeddedWalletWithPasskey/createEmbeddedWalletWithPasskey.js +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/createEmbeddedWalletWithPasskey/index.d.ts +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/findPasskeyEmailWalletConnector/findPasskeyEmailWalletConnector.cjs +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/findPasskeyEmailWalletConnector/findPasskeyEmailWalletConnector.d.ts +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/findPasskeyEmailWalletConnector/findPasskeyEmailWalletConnector.js +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/findPasskeyEmailWalletConnector/index.d.ts +0 -0
- /package/src/lib/views/{PasskeyIntroView → Passkey}/utils/index.d.ts +0 -0
|
@@ -39,6 +39,7 @@ import '../../context/CaptchaContext/CaptchaContext.js';
|
|
|
39
39
|
import '../../context/EmailVerificationContext/EmailVerificationContext.js';
|
|
40
40
|
import 'qrcode';
|
|
41
41
|
import '../../context/LoadingContext/LoadingContext.js';
|
|
42
|
+
import 'i18next';
|
|
42
43
|
import '../../widgets/DynamicWidget/context/DynamicWidgetContext.js';
|
|
43
44
|
import 'yup';
|
|
44
45
|
import '../../components/UserProfile/parts/UserProfileField/components/VerifiedEmailIcon/VerifiedEmailIcon.js';
|
|
@@ -47,6 +48,7 @@ import '../../utils/hooks/useUserUpdateRequest/useUpdateUser/useUpdateUser.js';
|
|
|
47
48
|
import '../../context/UserFieldEditorContext/UserFieldEditorContext.js';
|
|
48
49
|
import 'formik';
|
|
49
50
|
import { SendBalanceView } from '../../views/SendBalanceView/SendBalanceView.js';
|
|
51
|
+
import '../../widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.js';
|
|
50
52
|
import '../../components/IconButton/IconButton.js';
|
|
51
53
|
import '../../components/Alert/Alert.js';
|
|
52
54
|
import '../../components/Popper/Popper/Popper.js';
|
|
@@ -50,6 +50,7 @@ require('../../context/CaptchaContext/CaptchaContext.cjs');
|
|
|
50
50
|
require('../../context/EmailVerificationContext/EmailVerificationContext.cjs');
|
|
51
51
|
require('qrcode');
|
|
52
52
|
require('../../context/LoadingContext/LoadingContext.cjs');
|
|
53
|
+
require('i18next');
|
|
53
54
|
require('../../widgets/DynamicWidget/context/DynamicWidgetContext.cjs');
|
|
54
55
|
require('yup');
|
|
55
56
|
var ErrorContainer = require('../../components/ErrorContainer/ErrorContainer.cjs');
|
|
@@ -63,6 +64,7 @@ var ModalHeader = require('../../components/ModalHeader/ModalHeader.cjs');
|
|
|
63
64
|
var IconButton = require('../../components/IconButton/IconButton.cjs');
|
|
64
65
|
require('../../components/Alert/Alert.cjs');
|
|
65
66
|
var AppOriginTile = require('../../components/AppOriginTile/AppOriginTile.cjs');
|
|
67
|
+
require('../../widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.cjs');
|
|
66
68
|
var getProperErrorMessage = require('./getProperErrorMessage.cjs');
|
|
67
69
|
var useMutation = require('../../utils/hooks/useMutation/useMutation.cjs');
|
|
68
70
|
require('../../components/Popper/Popper/Popper.cjs');
|
|
@@ -46,6 +46,7 @@ import '../../context/CaptchaContext/CaptchaContext.js';
|
|
|
46
46
|
import '../../context/EmailVerificationContext/EmailVerificationContext.js';
|
|
47
47
|
import 'qrcode';
|
|
48
48
|
import '../../context/LoadingContext/LoadingContext.js';
|
|
49
|
+
import 'i18next';
|
|
49
50
|
import '../../widgets/DynamicWidget/context/DynamicWidgetContext.js';
|
|
50
51
|
import 'yup';
|
|
51
52
|
import { ErrorContainer } from '../../components/ErrorContainer/ErrorContainer.js';
|
|
@@ -59,6 +60,7 @@ import { ModalHeader } from '../../components/ModalHeader/ModalHeader.js';
|
|
|
59
60
|
import { IconButton } from '../../components/IconButton/IconButton.js';
|
|
60
61
|
import '../../components/Alert/Alert.js';
|
|
61
62
|
import { AppOriginTile } from '../../components/AppOriginTile/AppOriginTile.js';
|
|
63
|
+
import '../../widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.js';
|
|
62
64
|
import { getProperErrorMessage } from './getProperErrorMessage.js';
|
|
63
65
|
import { useMutation } from '../../utils/hooks/useMutation/useMutation.js';
|
|
64
66
|
import '../../components/Popper/Popper/Popper.js';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
|
+
import { PasskeyError } from '../../views/Passkey/passkey.types';
|
|
2
3
|
export type SignMessageConfirmationModalProps = {
|
|
3
4
|
appLogoUrl?: string;
|
|
4
5
|
appName?: string;
|
|
@@ -9,12 +10,6 @@ export type SignMessageConfirmationModalProps = {
|
|
|
9
10
|
onSignMessage: (signedMessage: string) => void;
|
|
10
11
|
};
|
|
11
12
|
export type SignMessageConfirmationModalComponent = FC<SignMessageConfirmationModalProps>;
|
|
12
|
-
export type
|
|
13
|
+
export type SignMessageError = Error & PasskeyError & {
|
|
13
14
|
reason?: string;
|
|
14
|
-
cause?: {
|
|
15
|
-
code: number;
|
|
16
|
-
name: string;
|
|
17
|
-
message: string;
|
|
18
|
-
};
|
|
19
15
|
};
|
|
20
|
-
export type SignMessageError = Error & SignMessageErrorDetails;
|
|
@@ -2,17 +2,26 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const
|
|
6
|
-
0: '
|
|
5
|
+
const TurnkeyErrorMap = {
|
|
6
|
+
0: 'Operation was canceled.',
|
|
7
7
|
16: 'Invalid Passkey signature. Select the passkey for this account and device.',
|
|
8
|
+
3: 'You reached the limit of passkeys for this account.',
|
|
8
9
|
};
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
const DOMExceptionErrorMap = {
|
|
11
|
+
NotAllowedError: 'Make sure to have you browser tab focused.',
|
|
12
|
+
};
|
|
13
|
+
const getProperErrorMessage = (originalError) => {
|
|
14
|
+
var _a, _b;
|
|
15
|
+
let error = originalError.reason || 'Something went wrong';
|
|
16
|
+
if (originalError instanceof DOMException) {
|
|
17
|
+
return DOMExceptionErrorMap[originalError.name] || error;
|
|
18
|
+
}
|
|
12
19
|
// turnkey request errors
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
20
|
+
const code = ((_a = originalError === null || originalError === void 0 ? void 0 : originalError.cause) === null || _a === void 0 ? void 0 : _a.code) !== undefined
|
|
21
|
+
? (_b = originalError === null || originalError === void 0 ? void 0 : originalError.cause) === null || _b === void 0 ? void 0 : _b.code
|
|
22
|
+
: originalError === null || originalError === void 0 ? void 0 : originalError.code;
|
|
23
|
+
if (code !== undefined) {
|
|
24
|
+
error = TurnkeyErrorMap[code] || error;
|
|
16
25
|
}
|
|
17
26
|
return error;
|
|
18
27
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { SignMessageError } from './SignMessageConfirmationModal.types';
|
|
2
|
-
export declare const getProperErrorMessage: (
|
|
2
|
+
export declare const getProperErrorMessage: (originalError: SignMessageError) => string;
|
|
@@ -1,14 +1,23 @@
|
|
|
1
|
-
const
|
|
2
|
-
0: '
|
|
1
|
+
const TurnkeyErrorMap = {
|
|
2
|
+
0: 'Operation was canceled.',
|
|
3
3
|
16: 'Invalid Passkey signature. Select the passkey for this account and device.',
|
|
4
|
+
3: 'You reached the limit of passkeys for this account.',
|
|
4
5
|
};
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
const DOMExceptionErrorMap = {
|
|
7
|
+
NotAllowedError: 'Make sure to have you browser tab focused.',
|
|
8
|
+
};
|
|
9
|
+
const getProperErrorMessage = (originalError) => {
|
|
10
|
+
var _a, _b;
|
|
11
|
+
let error = originalError.reason || 'Something went wrong';
|
|
12
|
+
if (originalError instanceof DOMException) {
|
|
13
|
+
return DOMExceptionErrorMap[originalError.name] || error;
|
|
14
|
+
}
|
|
8
15
|
// turnkey request errors
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
16
|
+
const code = ((_a = originalError === null || originalError === void 0 ? void 0 : originalError.cause) === null || _a === void 0 ? void 0 : _a.code) !== undefined
|
|
17
|
+
? (_b = originalError === null || originalError === void 0 ? void 0 : originalError.cause) === null || _b === void 0 ? void 0 : _b.code
|
|
18
|
+
: originalError === null || originalError === void 0 ? void 0 : originalError.code;
|
|
19
|
+
if (code !== undefined) {
|
|
20
|
+
error = TurnkeyErrorMap[code] || error;
|
|
12
21
|
}
|
|
13
22
|
return error;
|
|
14
23
|
};
|
|
@@ -4,6 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
var React = require('react');
|
|
7
|
+
var viem = require('viem');
|
|
7
8
|
require('@dynamic-labs/sdk-api');
|
|
8
9
|
require('../../shared/logger.cjs');
|
|
9
10
|
require('@dynamic-labs/iconic');
|
|
@@ -12,7 +13,6 @@ require('../../context/ViewContext/ViewContext.cjs');
|
|
|
12
13
|
require('@dynamic-labs/wallet-book');
|
|
13
14
|
require('../../utils/constants/colors.cjs');
|
|
14
15
|
require('../../shared/utils/classes/storage/localStorage.cjs');
|
|
15
|
-
require('viem');
|
|
16
16
|
var usePreventPageScroll = require('../../shared/utils/hooks/usePreventPageScroll/usePreventPageScroll.cjs');
|
|
17
17
|
var index = require('../../shared/consts/index.cjs');
|
|
18
18
|
require('../../context/DynamicContext/DynamicContext.cjs');
|
|
@@ -44,6 +44,7 @@ require('../../context/CaptchaContext/CaptchaContext.cjs');
|
|
|
44
44
|
require('../../context/EmailVerificationContext/EmailVerificationContext.cjs');
|
|
45
45
|
require('qrcode');
|
|
46
46
|
require('../../context/LoadingContext/LoadingContext.cjs');
|
|
47
|
+
require('i18next');
|
|
47
48
|
require('../../widgets/DynamicWidget/context/DynamicWidgetContext.cjs');
|
|
48
49
|
require('yup');
|
|
49
50
|
require('../../components/UserProfile/parts/UserProfileField/components/VerifiedEmailIcon/VerifiedEmailIcon.cjs');
|
|
@@ -54,6 +55,7 @@ require('formik');
|
|
|
54
55
|
require('../../components/IconButton/IconButton.cjs');
|
|
55
56
|
require('../../components/Alert/Alert.cjs');
|
|
56
57
|
var TransactionConfirmationView = require('../../views/TransactionConfirmationView/TransactionConfirmationView.cjs');
|
|
58
|
+
require('../../widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.cjs');
|
|
57
59
|
var useTransactionWithGasPrice = require('../../utils/hooks/useTransactionWithGasPrice/useTransactionWithGasPrice.cjs');
|
|
58
60
|
require('../../components/Popper/Popper/Popper.cjs');
|
|
59
61
|
require('../../components/Popper/PopperContext/PopperContext.cjs');
|
|
@@ -80,7 +82,8 @@ const TransactionConfirmationModal = ({ title, handler, onReject, onTransactionR
|
|
|
80
82
|
if (transactionResponseRef.current) {
|
|
81
83
|
return onTransactionResponseSuccess(transactionResponseRef.current);
|
|
82
84
|
}
|
|
83
|
-
onReject(errorRef.current ||
|
|
85
|
+
return onReject(errorRef.current ||
|
|
86
|
+
new viem.TransactionExecutionError(new viem.BaseError('user rejected transaction'), Object.assign({}, transactionWithGasPrice)));
|
|
84
87
|
}, [onTransactionResponseSuccess, onReject]);
|
|
85
88
|
return (jsxRuntime.jsx(Portal.Portal, { handleClose: closeModal, isShown: show, zIndex: index.authModalZIndex, withBackdrop: true, elementId: 'dynamic-send-transaction', transitionEvents: {
|
|
86
89
|
onUnmount: handleOnModalUnmount,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { useState, useRef, useCallback } from 'react';
|
|
3
|
+
import { TransactionExecutionError, BaseError } from 'viem';
|
|
3
4
|
import '@dynamic-labs/sdk-api';
|
|
4
5
|
import '../../shared/logger.js';
|
|
5
6
|
import '@dynamic-labs/iconic';
|
|
@@ -8,7 +9,6 @@ import '../../context/ViewContext/ViewContext.js';
|
|
|
8
9
|
import '@dynamic-labs/wallet-book';
|
|
9
10
|
import '../../utils/constants/colors.js';
|
|
10
11
|
import '../../shared/utils/classes/storage/localStorage.js';
|
|
11
|
-
import 'viem';
|
|
12
12
|
import { usePreventPageScroll } from '../../shared/utils/hooks/usePreventPageScroll/usePreventPageScroll.js';
|
|
13
13
|
import { authModalZIndex } from '../../shared/consts/index.js';
|
|
14
14
|
import '../../context/DynamicContext/DynamicContext.js';
|
|
@@ -40,6 +40,7 @@ import '../../context/CaptchaContext/CaptchaContext.js';
|
|
|
40
40
|
import '../../context/EmailVerificationContext/EmailVerificationContext.js';
|
|
41
41
|
import 'qrcode';
|
|
42
42
|
import '../../context/LoadingContext/LoadingContext.js';
|
|
43
|
+
import 'i18next';
|
|
43
44
|
import '../../widgets/DynamicWidget/context/DynamicWidgetContext.js';
|
|
44
45
|
import 'yup';
|
|
45
46
|
import '../../components/UserProfile/parts/UserProfileField/components/VerifiedEmailIcon/VerifiedEmailIcon.js';
|
|
@@ -50,6 +51,7 @@ import 'formik';
|
|
|
50
51
|
import '../../components/IconButton/IconButton.js';
|
|
51
52
|
import '../../components/Alert/Alert.js';
|
|
52
53
|
import { TransactionConfirmationView } from '../../views/TransactionConfirmationView/TransactionConfirmationView.js';
|
|
54
|
+
import '../../widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.js';
|
|
53
55
|
import { useTransactionWithGasPrice } from '../../utils/hooks/useTransactionWithGasPrice/useTransactionWithGasPrice.js';
|
|
54
56
|
import '../../components/Popper/Popper/Popper.js';
|
|
55
57
|
import '../../components/Popper/PopperContext/PopperContext.js';
|
|
@@ -76,7 +78,8 @@ const TransactionConfirmationModal = ({ title, handler, onReject, onTransactionR
|
|
|
76
78
|
if (transactionResponseRef.current) {
|
|
77
79
|
return onTransactionResponseSuccess(transactionResponseRef.current);
|
|
78
80
|
}
|
|
79
|
-
onReject(errorRef.current ||
|
|
81
|
+
return onReject(errorRef.current ||
|
|
82
|
+
new TransactionExecutionError(new BaseError('user rejected transaction'), Object.assign({}, transactionWithGasPrice)));
|
|
80
83
|
}, [onTransactionResponseSuccess, onReject]);
|
|
81
84
|
return (jsx(Portal, { handleClose: closeModal, isShown: show, zIndex: authModalZIndex, withBackdrop: true, elementId: 'dynamic-send-transaction', transitionEvents: {
|
|
82
85
|
onUnmount: handleOnModalUnmount,
|
|
@@ -42,6 +42,7 @@ require('../../context/CaptchaContext/CaptchaContext.cjs');
|
|
|
42
42
|
require('../../context/EmailVerificationContext/EmailVerificationContext.cjs');
|
|
43
43
|
require('qrcode');
|
|
44
44
|
require('../../context/LoadingContext/LoadingContext.cjs');
|
|
45
|
+
require('i18next');
|
|
45
46
|
require('../../widgets/DynamicWidget/context/DynamicWidgetContext.cjs');
|
|
46
47
|
require('yup');
|
|
47
48
|
require('../../components/UserProfile/parts/UserProfileField/components/VerifiedEmailIcon/VerifiedEmailIcon.cjs');
|
|
@@ -51,6 +52,7 @@ require('../../context/UserFieldEditorContext/UserFieldEditorContext.cjs');
|
|
|
51
52
|
require('formik');
|
|
52
53
|
require('../../components/IconButton/IconButton.cjs');
|
|
53
54
|
require('../../components/Alert/Alert.cjs');
|
|
55
|
+
require('../../widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.cjs');
|
|
54
56
|
var UserFieldEditorView = require('../../views/UserFieldEditorView/UserFieldEditorView.cjs');
|
|
55
57
|
require('../../components/Popper/Popper/Popper.cjs');
|
|
56
58
|
require('../../components/Popper/PopperContext/PopperContext.cjs');
|
|
@@ -38,6 +38,7 @@ import '../../context/CaptchaContext/CaptchaContext.js';
|
|
|
38
38
|
import '../../context/EmailVerificationContext/EmailVerificationContext.js';
|
|
39
39
|
import 'qrcode';
|
|
40
40
|
import '../../context/LoadingContext/LoadingContext.js';
|
|
41
|
+
import 'i18next';
|
|
41
42
|
import '../../widgets/DynamicWidget/context/DynamicWidgetContext.js';
|
|
42
43
|
import 'yup';
|
|
43
44
|
import '../../components/UserProfile/parts/UserProfileField/components/VerifiedEmailIcon/VerifiedEmailIcon.js';
|
|
@@ -47,6 +48,7 @@ import '../../context/UserFieldEditorContext/UserFieldEditorContext.js';
|
|
|
47
48
|
import 'formik';
|
|
48
49
|
import '../../components/IconButton/IconButton.js';
|
|
49
50
|
import '../../components/Alert/Alert.js';
|
|
51
|
+
import '../../widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.js';
|
|
50
52
|
import { UserFieldEditorView } from '../../views/UserFieldEditorView/UserFieldEditorView.js';
|
|
51
53
|
import '../../components/Popper/Popper/Popper.js';
|
|
52
54
|
import '../../components/Popper/PopperContext/PopperContext.js';
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var React = require('react');
|
|
6
|
+
|
|
7
|
+
function _interopNamespace(e) {
|
|
8
|
+
if (e && e.__esModule) return e;
|
|
9
|
+
var n = Object.create(null);
|
|
10
|
+
if (e) {
|
|
11
|
+
Object.keys(e).forEach(function (k) {
|
|
12
|
+
if (k !== 'default') {
|
|
13
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
14
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: function () { return e[k]; }
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
n["default"] = e;
|
|
22
|
+
return Object.freeze(n);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
26
|
+
|
|
27
|
+
var _path;
|
|
28
|
+
var _excluded = ["title", "titleId"];
|
|
29
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
30
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
31
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
32
|
+
var SvgCircleLocker = function SvgCircleLocker(_ref) {
|
|
33
|
+
var title = _ref.title,
|
|
34
|
+
titleId = _ref.titleId,
|
|
35
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
36
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends({
|
|
37
|
+
width: 65,
|
|
38
|
+
height: 64,
|
|
39
|
+
viewBox: "0 0 65 64",
|
|
40
|
+
fill: "none",
|
|
41
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
42
|
+
"aria-labelledby": titleId
|
|
43
|
+
}, props), title ? /*#__PURE__*/React__namespace.createElement("title", {
|
|
44
|
+
id: titleId
|
|
45
|
+
}, title) : null, _path || (_path = /*#__PURE__*/React__namespace.createElement("path", {
|
|
46
|
+
fillRule: "evenodd",
|
|
47
|
+
clipRule: "evenodd",
|
|
48
|
+
d: "M32.5 64c17.673 0 32-14.327 32-32 0-17.673-14.327-32-32-32C14.827 0 .5 14.327.5 32c0 17.673 14.327 32 32 32Zm-7.618-39.89v-4.037a8.074 8.074 0 0 1 16.147 0v4.036a13.436 13.436 0 0 1 5.383 10.766c0 7.431-6.025 13.456-13.456 13.456-7.432 0-13.456-6.025-13.456-13.456 0-4.402 2.114-8.31 5.382-10.765Zm13.147-1.702v-2.335a5.074 5.074 0 0 0-10.147 0v2.336a13.416 13.416 0 0 1 5.074-.99c1.795 0 3.507.352 5.073.99ZM34.5 35.663a3.5 3.5 0 1 0-3 0V38.5a1.5 1.5 0 0 0 3 0v-2.837Z",
|
|
49
|
+
fill: "#4779FF"
|
|
50
|
+
})));
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
exports.ReactComponent = SvgCircleLocker;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
var _path;
|
|
4
|
+
var _excluded = ["title", "titleId"];
|
|
5
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
6
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
7
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
8
|
+
var SvgCircleLocker = function SvgCircleLocker(_ref) {
|
|
9
|
+
var title = _ref.title,
|
|
10
|
+
titleId = _ref.titleId,
|
|
11
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
12
|
+
return /*#__PURE__*/React.createElement("svg", _extends({
|
|
13
|
+
width: 65,
|
|
14
|
+
height: 64,
|
|
15
|
+
viewBox: "0 0 65 64",
|
|
16
|
+
fill: "none",
|
|
17
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
18
|
+
"aria-labelledby": titleId
|
|
19
|
+
}, props), title ? /*#__PURE__*/React.createElement("title", {
|
|
20
|
+
id: titleId
|
|
21
|
+
}, title) : null, _path || (_path = /*#__PURE__*/React.createElement("path", {
|
|
22
|
+
fillRule: "evenodd",
|
|
23
|
+
clipRule: "evenodd",
|
|
24
|
+
d: "M32.5 64c17.673 0 32-14.327 32-32 0-17.673-14.327-32-32-32C14.827 0 .5 14.327.5 32c0 17.673 14.327 32 32 32Zm-7.618-39.89v-4.037a8.074 8.074 0 0 1 16.147 0v4.036a13.436 13.436 0 0 1 5.383 10.766c0 7.431-6.025 13.456-13.456 13.456-7.432 0-13.456-6.025-13.456-13.456 0-4.402 2.114-8.31 5.382-10.765Zm13.147-1.702v-2.335a5.074 5.074 0 0 0-10.147 0v2.336a13.416 13.416 0 0 1 5.074-.99c1.795 0 3.507.352 5.073.99ZM34.5 35.663a3.5 3.5 0 1 0-3 0V38.5a1.5 1.5 0 0 0 3 0v-2.837Z",
|
|
25
|
+
fill: "#4779FF"
|
|
26
|
+
})));
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export { SvgCircleLocker as ReactComponent };
|
|
@@ -48,6 +48,8 @@ export { ReactComponent as UserCardIcon } from './user-card.svg';
|
|
|
48
48
|
export { ReactComponent as WorkSuitcaseIcon } from './work-suitcase.svg';
|
|
49
49
|
export { ReactComponent as LocationIcon } from './location.svg';
|
|
50
50
|
export { ReactComponent as SparklesIcon } from './sparkles.svg';
|
|
51
|
+
export { ReactComponent as CircleLockerIcon } from './circle-locker.svg';
|
|
52
|
+
export { ReactComponent as TurnkeyIcon } from './turnkey.svg';
|
|
51
53
|
export { ReactComponent as JustifiedTextIcon } from './justified-text.svg';
|
|
52
54
|
export { ReactComponent as SignInWithEmailIcon } from './sign-in-with-email.svg';
|
|
53
55
|
export { ReactComponent as PasskeyIntroIcon } from './passkey-intro-icon.svg';
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var React = require('react');
|
|
6
|
+
|
|
7
|
+
function _interopNamespace(e) {
|
|
8
|
+
if (e && e.__esModule) return e;
|
|
9
|
+
var n = Object.create(null);
|
|
10
|
+
if (e) {
|
|
11
|
+
Object.keys(e).forEach(function (k) {
|
|
12
|
+
if (k !== 'default') {
|
|
13
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
14
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: function () { return e[k]; }
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
n["default"] = e;
|
|
22
|
+
return Object.freeze(n);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
26
|
+
|
|
27
|
+
var _path, _path2, _g, _defs;
|
|
28
|
+
var _excluded = ["title", "titleId"];
|
|
29
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
30
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
31
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
32
|
+
var SvgTurnkey = function SvgTurnkey(_ref) {
|
|
33
|
+
var title = _ref.title,
|
|
34
|
+
titleId = _ref.titleId,
|
|
35
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
36
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends({
|
|
37
|
+
width: 56,
|
|
38
|
+
height: 12,
|
|
39
|
+
viewBox: "0 0 56 12",
|
|
40
|
+
fill: "none",
|
|
41
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
42
|
+
"aria-labelledby": titleId
|
|
43
|
+
}, props), title ? /*#__PURE__*/React__namespace.createElement("title", {
|
|
44
|
+
id: titleId
|
|
45
|
+
}, title) : null, /*#__PURE__*/React__namespace.createElement("g", {
|
|
46
|
+
clipPath: "url(#turnkey_svg__a)"
|
|
47
|
+
}, _path || (_path = /*#__PURE__*/React__namespace.createElement("path", {
|
|
48
|
+
fillRule: "evenodd",
|
|
49
|
+
clipRule: "evenodd",
|
|
50
|
+
d: "M34.892 0h1.388v9.261h-1.388V0ZM12.24 8.002V3.141h1.478V1.878H12.12c.094-.117.169-.248.223-.388.1-.255.153-.58.148-1.017V0h-1.338v.489a1.78 1.78 0 0 1-.164.805c-.174.357-.547.752-1.356.942l-.086.02v.885h1.291v5.193a.93.93 0 0 0 .93.928h1.971v-1.26H12.24Zm11.4-4.898c.54-.767 1.256-1.217 2.123-1.217h.692V3.23h-.845c-.592 0-1.067.192-1.404.596-.336.405-.538 1.037-.538 1.935v3.501h-1.416V1.887h1.388v1.217Zm30.22-1.217h1.355l.16.006-.059.148-3.537 9.144-.086-.033.01.004.075.029a1.336 1.336 0 0 1-1.2.815h-1.569v-1.246h1.52l.636-1.605-2.773-7.113-.058-.149h1.56l.027.075 1.951 5.433 1.962-5.434.026-.074Zm-34.422 0h1.4v7.377h-1.332v-.91c-.526.73-1.3 1.077-2.247 1.077-.964 0-1.624-.282-2.028-.773-.404-.49-.553-1.175-.553-1.954V1.887h1.403v4.952c0 .412.13.742.357.968.228.226.561.36.988.36.688 0 1.184-.228 1.514-.601.329-.373.497-.904.497-1.53V1.888Zm25.35-.166c-1.048 0-1.913.386-2.513 1.067-.6.682-.928 1.646-.928 2.793 0 1.148.34 2.118.95 2.793.61.675 1.486 1.054 2.533 1.054.833 0 1.549-.239 2.108-.678.56-.44.956-1.073 1.163-1.853l.037-.14h-1.444l-.027.074c-.318.874-.973 1.352-1.837 1.352-.621 0-1.1-.233-1.44-.623-.322-.37-.524-.884-.599-1.492h5.357l.011-.1a3.41 3.41 0 0 0 .014-.385c0-1.146-.313-2.112-.898-2.792-.585-.68-1.438-1.07-2.487-1.07Zm-1.947 3.071c.099-.518.304-.968.607-1.288a1.782 1.782 0 0 1 1.338-.55 1.738 1.738 0 0 1 1.278.515c.305.31.52.758.627 1.323h-3.85Zm-11.794-3.07c-.947 0-1.72.345-2.247 1.075v-.91h-1.332v7.375h1.401v-4.15c0-.624.17-1.156.498-1.53.33-.374.826-.6 1.514-.6.427 0 .76.134.988.36.227.226.357.556.357.967v4.954h1.403V4.446c0-.778-.15-1.462-.553-1.953-.405-.49-1.064-.772-2.029-.772Zm10.718.185-3.681 3.672 3.679 3.67-1.858-.003-2.687-2.682a1.39 1.39 0 0 1 0-1.97l2.694-2.688h1.853Z",
|
|
51
|
+
fill: "#383C48"
|
|
52
|
+
})), /*#__PURE__*/React__namespace.createElement("mask", {
|
|
53
|
+
id: "turnkey_svg__b",
|
|
54
|
+
style: {
|
|
55
|
+
maskType: "luminance"
|
|
56
|
+
},
|
|
57
|
+
maskUnits: "userSpaceOnUse",
|
|
58
|
+
x: 0,
|
|
59
|
+
y: 0,
|
|
60
|
+
width: 7,
|
|
61
|
+
height: 10
|
|
62
|
+
}, _path2 || (_path2 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
63
|
+
d: "M.625 0h5.452v9.603H.625V0Z",
|
|
64
|
+
fill: "#fff"
|
|
65
|
+
}))), _g || (_g = /*#__PURE__*/React__namespace.createElement("g", {
|
|
66
|
+
mask: "url(#turnkey_svg__b)"
|
|
67
|
+
}, /*#__PURE__*/React__namespace.createElement("path", {
|
|
68
|
+
d: "m3.634 4.258 2.444 5.345H.625l2.444-5.345a.31.31 0 0 1 .565 0Zm-.283-.829A1.716 1.716 0 0 0 4.008.13a1.716 1.716 0 0 0-1.87 2.798c.322.321.758.502 1.213.501Z",
|
|
69
|
+
fill: "#383C48"
|
|
70
|
+
})))), _defs || (_defs = /*#__PURE__*/React__namespace.createElement("defs", null, /*#__PURE__*/React__namespace.createElement("clipPath", {
|
|
71
|
+
id: "turnkey_svg__a"
|
|
72
|
+
}, /*#__PURE__*/React__namespace.createElement("path", {
|
|
73
|
+
fill: "#fff",
|
|
74
|
+
transform: "translate(.625)",
|
|
75
|
+
d: "M0 0h54.75v12H0z"
|
|
76
|
+
})))));
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
exports.ReactComponent = SvgTurnkey;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
var _path, _path2, _g, _defs;
|
|
4
|
+
var _excluded = ["title", "titleId"];
|
|
5
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
6
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
7
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
8
|
+
var SvgTurnkey = function SvgTurnkey(_ref) {
|
|
9
|
+
var title = _ref.title,
|
|
10
|
+
titleId = _ref.titleId,
|
|
11
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
12
|
+
return /*#__PURE__*/React.createElement("svg", _extends({
|
|
13
|
+
width: 56,
|
|
14
|
+
height: 12,
|
|
15
|
+
viewBox: "0 0 56 12",
|
|
16
|
+
fill: "none",
|
|
17
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
18
|
+
"aria-labelledby": titleId
|
|
19
|
+
}, props), title ? /*#__PURE__*/React.createElement("title", {
|
|
20
|
+
id: titleId
|
|
21
|
+
}, title) : null, /*#__PURE__*/React.createElement("g", {
|
|
22
|
+
clipPath: "url(#turnkey_svg__a)"
|
|
23
|
+
}, _path || (_path = /*#__PURE__*/React.createElement("path", {
|
|
24
|
+
fillRule: "evenodd",
|
|
25
|
+
clipRule: "evenodd",
|
|
26
|
+
d: "M34.892 0h1.388v9.261h-1.388V0ZM12.24 8.002V3.141h1.478V1.878H12.12c.094-.117.169-.248.223-.388.1-.255.153-.58.148-1.017V0h-1.338v.489a1.78 1.78 0 0 1-.164.805c-.174.357-.547.752-1.356.942l-.086.02v.885h1.291v5.193a.93.93 0 0 0 .93.928h1.971v-1.26H12.24Zm11.4-4.898c.54-.767 1.256-1.217 2.123-1.217h.692V3.23h-.845c-.592 0-1.067.192-1.404.596-.336.405-.538 1.037-.538 1.935v3.501h-1.416V1.887h1.388v1.217Zm30.22-1.217h1.355l.16.006-.059.148-3.537 9.144-.086-.033.01.004.075.029a1.336 1.336 0 0 1-1.2.815h-1.569v-1.246h1.52l.636-1.605-2.773-7.113-.058-.149h1.56l.027.075 1.951 5.433 1.962-5.434.026-.074Zm-34.422 0h1.4v7.377h-1.332v-.91c-.526.73-1.3 1.077-2.247 1.077-.964 0-1.624-.282-2.028-.773-.404-.49-.553-1.175-.553-1.954V1.887h1.403v4.952c0 .412.13.742.357.968.228.226.561.36.988.36.688 0 1.184-.228 1.514-.601.329-.373.497-.904.497-1.53V1.888Zm25.35-.166c-1.048 0-1.913.386-2.513 1.067-.6.682-.928 1.646-.928 2.793 0 1.148.34 2.118.95 2.793.61.675 1.486 1.054 2.533 1.054.833 0 1.549-.239 2.108-.678.56-.44.956-1.073 1.163-1.853l.037-.14h-1.444l-.027.074c-.318.874-.973 1.352-1.837 1.352-.621 0-1.1-.233-1.44-.623-.322-.37-.524-.884-.599-1.492h5.357l.011-.1a3.41 3.41 0 0 0 .014-.385c0-1.146-.313-2.112-.898-2.792-.585-.68-1.438-1.07-2.487-1.07Zm-1.947 3.071c.099-.518.304-.968.607-1.288a1.782 1.782 0 0 1 1.338-.55 1.738 1.738 0 0 1 1.278.515c.305.31.52.758.627 1.323h-3.85Zm-11.794-3.07c-.947 0-1.72.345-2.247 1.075v-.91h-1.332v7.375h1.401v-4.15c0-.624.17-1.156.498-1.53.33-.374.826-.6 1.514-.6.427 0 .76.134.988.36.227.226.357.556.357.967v4.954h1.403V4.446c0-.778-.15-1.462-.553-1.953-.405-.49-1.064-.772-2.029-.772Zm10.718.185-3.681 3.672 3.679 3.67-1.858-.003-2.687-2.682a1.39 1.39 0 0 1 0-1.97l2.694-2.688h1.853Z",
|
|
27
|
+
fill: "#383C48"
|
|
28
|
+
})), /*#__PURE__*/React.createElement("mask", {
|
|
29
|
+
id: "turnkey_svg__b",
|
|
30
|
+
style: {
|
|
31
|
+
maskType: "luminance"
|
|
32
|
+
},
|
|
33
|
+
maskUnits: "userSpaceOnUse",
|
|
34
|
+
x: 0,
|
|
35
|
+
y: 0,
|
|
36
|
+
width: 7,
|
|
37
|
+
height: 10
|
|
38
|
+
}, _path2 || (_path2 = /*#__PURE__*/React.createElement("path", {
|
|
39
|
+
d: "M.625 0h5.452v9.603H.625V0Z",
|
|
40
|
+
fill: "#fff"
|
|
41
|
+
}))), _g || (_g = /*#__PURE__*/React.createElement("g", {
|
|
42
|
+
mask: "url(#turnkey_svg__b)"
|
|
43
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
44
|
+
d: "m3.634 4.258 2.444 5.345H.625l2.444-5.345a.31.31 0 0 1 .565 0Zm-.283-.829A1.716 1.716 0 0 0 4.008.13a1.716 1.716 0 0 0-1.87 2.798c.322.321.758.502 1.213.501Z",
|
|
45
|
+
fill: "#383C48"
|
|
46
|
+
})))), _defs || (_defs = /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("clipPath", {
|
|
47
|
+
id: "turnkey_svg__a"
|
|
48
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
49
|
+
fill: "#fff",
|
|
50
|
+
transform: "translate(.625)",
|
|
51
|
+
d: "M0 0h54.75v12H0z"
|
|
52
|
+
})))));
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
export { SvgTurnkey as ReactComponent };
|
|
@@ -2,11 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const detectBrowserName = () => {
|
|
6
|
-
const
|
|
5
|
+
const detectBrowserName = (customUserAgent) => {
|
|
6
|
+
const userAgent = customUserAgent || navigator.userAgent;
|
|
7
7
|
if (userAgent.match(/brave/i)) {
|
|
8
8
|
return 'brave';
|
|
9
9
|
}
|
|
10
|
+
else if (userAgent.match(/edg/i)) {
|
|
11
|
+
return 'edge';
|
|
12
|
+
}
|
|
10
13
|
else if (userAgent.match(/chrome|chromium|crios/i)) {
|
|
11
14
|
return 'chrome';
|
|
12
15
|
}
|
|
@@ -16,9 +19,6 @@ const detectBrowserName = () => {
|
|
|
16
19
|
else if (userAgent.match(/safari/i)) {
|
|
17
20
|
return 'safari';
|
|
18
21
|
}
|
|
19
|
-
else if (userAgent.match(/edg/i)) {
|
|
20
|
-
return 'edge';
|
|
21
|
-
}
|
|
22
22
|
return undefined;
|
|
23
23
|
};
|
|
24
24
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { BrowserName } from '../../../types';
|
|
2
|
-
export declare const detectBrowserName: () => BrowserName | undefined;
|
|
2
|
+
export declare const detectBrowserName: (customUserAgent?: string) => BrowserName | undefined;
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
const detectBrowserName = () => {
|
|
2
|
-
const
|
|
1
|
+
const detectBrowserName = (customUserAgent) => {
|
|
2
|
+
const userAgent = customUserAgent || navigator.userAgent;
|
|
3
3
|
if (userAgent.match(/brave/i)) {
|
|
4
4
|
return 'brave';
|
|
5
5
|
}
|
|
6
|
+
else if (userAgent.match(/edg/i)) {
|
|
7
|
+
return 'edge';
|
|
8
|
+
}
|
|
6
9
|
else if (userAgent.match(/chrome|chromium|crios/i)) {
|
|
7
10
|
return 'chrome';
|
|
8
11
|
}
|
|
@@ -12,9 +15,6 @@ const detectBrowserName = () => {
|
|
|
12
15
|
else if (userAgent.match(/safari/i)) {
|
|
13
16
|
return 'safari';
|
|
14
17
|
}
|
|
15
|
-
else if (userAgent.match(/edg/i)) {
|
|
16
|
-
return 'edge';
|
|
17
|
-
}
|
|
18
18
|
return undefined;
|
|
19
19
|
};
|
|
20
20
|
|