@dynamic-labs/sdk-react-core 0.18.0-RC.15 → 0.18.0-RC.17
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 +37 -0
- package/package.cjs +1 -1
- package/package.js +1 -1
- package/package.json +8 -8
- package/src/index.cjs +3 -0
- package/src/index.js +2 -0
- package/src/lib/Main.cjs +1 -0
- package/src/lib/Main.js +1 -0
- package/src/lib/components/Accordion/components/AccordionItem/AccordionItem.cjs +1 -0
- package/src/lib/components/Accordion/components/AccordionItem/AccordionItem.js +1 -0
- package/src/lib/components/AnimatePresence/AnimatePresence.cjs +1 -0
- package/src/lib/components/AnimatePresence/AnimatePresence.js +1 -0
- package/src/lib/components/AuthProviderIcon/AuthProviderIcon.cjs +1 -0
- package/src/lib/components/AuthProviderIcon/AuthProviderIcon.js +1 -0
- package/src/lib/components/Button/Button.cjs +12 -4
- package/src/lib/components/Button/Button.d.ts +3 -2
- package/src/lib/components/Button/Button.js +12 -4
- package/src/lib/components/ChainCard/ChainCard.cjs +1 -1
- package/src/lib/components/ChainCard/ChainCard.js +1 -1
- package/src/lib/components/Divider/Divider.cjs +1 -0
- package/src/lib/components/Divider/Divider.js +1 -0
- package/src/lib/components/IconWithSpinner/IconWithSpinner.cjs +2 -2
- package/src/lib/components/IconWithSpinner/IconWithSpinner.js +2 -2
- package/src/lib/components/LegacySafariCssOverrides/LegacySafariCssOverrides.cjs +9 -0
- package/src/lib/components/LegacySafariCssOverrides/LegacySafariCssOverrides.d.ts +2 -0
- package/src/lib/components/LegacySafariCssOverrides/LegacySafariCssOverrides.js +5 -0
- package/src/lib/components/LegacySafariCssOverrides/index.d.ts +1 -0
- package/src/lib/components/LogoutButton/LogoutButton.cjs +17 -3
- package/src/lib/components/LogoutButton/LogoutButton.js +17 -3
- package/src/lib/components/MenuList/Dropdown/Dropdown.cjs +85 -0
- package/src/lib/components/MenuList/Dropdown/Dropdown.d.ts +16 -0
- package/src/lib/components/MenuList/Dropdown/Dropdown.js +81 -0
- package/src/lib/components/MenuList/Dropdown/index.d.ts +1 -0
- package/src/lib/components/MenuList/MenuList/MenuList.cjs +34 -0
- package/src/lib/components/MenuList/MenuList/MenuList.d.ts +15 -0
- package/src/lib/components/MenuList/MenuList/MenuList.js +30 -0
- package/src/lib/components/MenuList/MenuList/index.d.ts +1 -0
- package/src/lib/components/MenuList/index.d.ts +1 -0
- package/src/lib/components/MenuList/utils/index.d.ts +1 -0
- package/src/lib/components/{Popper → MenuList}/utils/watchToScrollInHierarchy/watchToScrollInHierarchy.cjs +6 -1
- package/src/lib/components/MenuList/utils/watchToScrollInHierarchy/watchToScrollInHierarchy.d.ts +5 -0
- package/src/lib/components/{Popper → MenuList}/utils/watchToScrollInHierarchy/watchToScrollInHierarchy.js +6 -1
- package/src/lib/components/Modal/Modal.cjs +1 -0
- package/src/lib/components/Modal/Modal.js +1 -0
- package/src/lib/components/NetworkPicker/NetworkPicker.cjs +9 -12
- package/src/lib/components/NetworkPicker/NetworkPicker.js +9 -12
- package/src/lib/components/NetworkPicker/components/EvmNetworkControl/EvmNetworkControl.cjs +1 -0
- package/src/lib/components/NetworkPicker/components/EvmNetworkControl/EvmNetworkControl.js +1 -0
- package/src/lib/components/NetworkPicker/components/Network/Network.cjs +1 -0
- package/src/lib/components/NetworkPicker/components/Network/Network.js +1 -0
- package/src/lib/components/NetworkPicker/components/NonNetworkSwitchingSupportedControl/NonNetworkSwitchingSupportedControl.cjs +1 -0
- package/src/lib/components/NetworkPicker/components/NonNetworkSwitchingSupportedControl/NonNetworkSwitchingSupportedControl.js +1 -0
- package/src/lib/components/OTPVerificationView/OTPVerificationView.cjs +1 -0
- package/src/lib/components/OTPVerificationView/OTPVerificationView.js +1 -0
- package/src/lib/components/OverlayCard/OverlayCard.cjs +10 -11
- package/src/lib/components/OverlayCard/OverlayCard.d.ts +4 -2
- package/src/lib/components/OverlayCard/OverlayCard.js +11 -11
- package/src/lib/components/Popper/Popper/Popper.cjs +12 -12
- package/src/lib/components/Popper/Popper/Popper.d.ts +7 -4
- package/src/lib/components/Popper/Popper/Popper.js +12 -12
- package/src/lib/components/Popper/PopperContent/PopperContent.cjs +1 -1
- package/src/lib/components/Popper/PopperContent/PopperContent.d.ts +2 -1
- package/src/lib/components/Popper/PopperContent/PopperContent.js +1 -1
- package/src/lib/components/Popper/utils/getChildPosition/getChildPosition.cjs +1 -0
- package/src/lib/components/Popper/utils/getChildPosition/getChildPosition.d.ts +1 -0
- package/src/lib/components/Popper/utils/getChildPosition/getChildPosition.js +1 -0
- package/src/lib/components/Popper/utils/index.d.ts +0 -1
- package/src/lib/components/Portal/Portal.cjs +3 -2
- package/src/lib/components/Portal/Portal.js +3 -2
- package/src/lib/components/PoweredByDynamic/PoweredByDynamic.cjs +2 -1
- package/src/lib/components/PoweredByDynamic/PoweredByDynamic.js +2 -1
- package/src/lib/components/ShadowDOM/ShadowDOM.cjs +4 -2
- package/src/lib/components/ShadowDOM/ShadowDOM.js +4 -2
- package/src/lib/components/Tooltip/Tooltip.cjs +1 -0
- package/src/lib/components/Tooltip/Tooltip.js +1 -0
- package/src/lib/components/TransactionStatusLayout/TransactionStatusLayout.cjs +1 -0
- package/src/lib/components/TransactionStatusLayout/TransactionStatusLayout.js +1 -0
- package/src/lib/components/Transition/VerticalDrawerTransition/VerticalDrawerTransition.cjs +1 -0
- package/src/lib/components/Transition/VerticalDrawerTransition/VerticalDrawerTransition.js +1 -0
- package/src/lib/components/UserAddress/UserAddress.cjs +1 -0
- package/src/lib/components/UserAddress/UserAddress.js +1 -0
- package/src/lib/components/UserProfile/parts/UserProfileField/UserProfileField.cjs +1 -0
- package/src/lib/components/UserProfile/parts/UserProfileField/UserProfileField.js +1 -0
- package/src/lib/components/UserProfile/parts/UserProfileSection/UserProfileSection.cjs +1 -0
- package/src/lib/components/UserProfile/parts/UserProfileSection/UserProfileSection.js +1 -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/components/index.d.ts +1 -0
- package/src/lib/context/DynamicContext/DynamicContext.cjs +80 -48
- package/src/lib/context/DynamicContext/DynamicContext.d.ts +7 -134
- package/src/lib/context/DynamicContext/DynamicContext.js +81 -49
- package/src/lib/context/DynamicContext/types/index.d.ts +144 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/types.d.ts +5 -1
- package/src/lib/context/DynamicContext/useCustomerCallbacks/useCustomerAuthFlowCallbacks.cjs +1 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/useCustomerAuthFlowCallbacks.js +1 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/useCustomerCallbacks.cjs +9 -3
- package/src/lib/context/DynamicContext/useCustomerCallbacks/useCustomerCallbacks.d.ts +2 -2
- package/src/lib/context/DynamicContext/useCustomerCallbacks/useCustomerCallbacks.js +9 -3
- package/src/lib/context/DynamicContext/useCustomerCallbacks/utils/disableAuthVerificationFlag/disableAuthVerificationFlag.cjs +27 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/utils/disableAuthVerificationFlag/disableAuthVerificationFlag.d.ts +3 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/utils/disableAuthVerificationFlag/disableAuthVerificationFlag.js +23 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/utils/disableAuthVerificationFlag/index.d.ts +1 -0
- package/src/lib/context/DynamicContext/useCustomerCallbacks/utils/index.d.ts +1 -0
- package/src/lib/context/DynamicContext/useDynamicContext.cjs +5 -1
- package/src/lib/context/DynamicContext/useDynamicContext.d.ts +4 -2
- package/src/lib/context/DynamicContext/useDynamicContext.js +5 -1
- package/src/lib/context/DynamicContext/useInternalDynamicContext.d.ts +1 -1
- package/src/lib/context/QrCodeContext/QrCodeContext.cjs +1 -0
- package/src/lib/context/QrCodeContext/QrCodeContext.js +1 -0
- package/src/lib/context/SendBalanceContext/SendBalanceContext.cjs +1 -0
- package/src/lib/context/SendBalanceContext/SendBalanceContext.js +1 -0
- package/src/lib/context/SocialRedirectContext/SocialRedirectContext.cjs +2 -1
- package/src/lib/context/SocialRedirectContext/SocialRedirectContext.js +2 -1
- package/src/lib/context/WalletContext/WalletContext.cjs +3 -3
- package/src/lib/context/WalletContext/WalletContext.d.ts +1 -3
- package/src/lib/context/WalletContext/WalletContext.js +3 -3
- package/src/lib/data/api.cjs +14 -0
- package/src/lib/data/api.d.ts +1 -0
- package/src/lib/data/api.js +14 -1
- package/src/lib/layout/DynamicAuthLayout/DynamicAuthLayout.cjs +1 -0
- package/src/lib/layout/DynamicAuthLayout/DynamicAuthLayout.js +1 -0
- package/src/lib/layout/DynamicAuthLayout/Header/header.cjs +2 -1
- package/src/lib/layout/DynamicAuthLayout/Header/header.js +2 -1
- package/src/lib/layout/DynamicAuthLayout/HelpContent/HelpHeader/HelpHeader.cjs +2 -1
- package/src/lib/layout/DynamicAuthLayout/HelpContent/HelpHeader/HelpHeader.js +2 -1
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/Item/Item.cjs +1 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/Item/Item.js +1 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/WalletExtensionOrAppContinueButton/WalletExtensionOrAppContinueButton.cjs +1 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/WalletExtensionOrAppContinueButton/WalletExtensionOrAppContinueButton.js +1 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/WalletListHelpContent.cjs +1 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletListHelpContent/WalletListHelpContent.js +1 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletMoreInfoContent/WalletMoreInfoContent.cjs +1 -0
- package/src/lib/layout/DynamicAuthLayout/HelpContent/WalletMoreInfoContent/WalletMoreInfoContent.js +1 -0
- package/src/lib/layout/DynamicAuthLayout/ToSFooter/ToSFooter.cjs +1 -0
- package/src/lib/layout/DynamicAuthLayout/ToSFooter/ToSFooter.js +1 -0
- package/src/lib/layout/DynamicAuthLayout/WalletProgressStepper/WalletProgressStepper.cjs +1 -0
- package/src/lib/layout/DynamicAuthLayout/WalletProgressStepper/WalletProgressStepper.js +1 -0
- package/src/lib/layouts/BridgeNextWalletToConnectLayout/BridgeNextWalletToConnectLayout.cjs +1 -0
- package/src/lib/layouts/BridgeNextWalletToConnectLayout/BridgeNextWalletToConnectLayout.js +1 -0
- package/src/lib/layouts/BridgeWelcomeLayout/BridgeWelcomeLayout.cjs +1 -0
- package/src/lib/layouts/BridgeWelcomeLayout/BridgeWelcomeLayout.js +1 -0
- package/src/lib/layouts/ConnectedWalletsListLayout/ConnectedWalletsListLayout.cjs +1 -0
- package/src/lib/layouts/ConnectedWalletsListLayout/ConnectedWalletsListLayout.js +1 -0
- package/src/lib/modals/SendBalanceModal/SendBalanceModal.cjs +1 -0
- package/src/lib/modals/SendBalanceModal/SendBalanceModal.js +1 -0
- package/src/lib/modals/SignMessageConfirmationModal/SignMessageConfirmationModal.cjs +1 -0
- package/src/lib/modals/SignMessageConfirmationModal/SignMessageConfirmationModal.js +1 -0
- package/src/lib/modals/TransactionConfirmationModal/TransactionConfirmationModal.cjs +1 -0
- package/src/lib/modals/TransactionConfirmationModal/TransactionConfirmationModal.js +1 -0
- package/src/lib/shared/types/index.d.ts +2 -1
- package/src/lib/shared/utils/hooks/index.d.ts +1 -0
- package/src/lib/shared/utils/hooks/useForwardedRef/index.d.ts +1 -0
- package/src/lib/shared/utils/hooks/useForwardedRef/useForwardedRef.cjs +25 -0
- package/src/lib/shared/utils/hooks/useForwardedRef/useForwardedRef.d.ts +2 -0
- package/src/lib/shared/utils/hooks/useForwardedRef/useForwardedRef.js +21 -0
- package/src/lib/styles/index.shadow.cjs +1 -1
- package/src/lib/styles/index.shadow.js +1 -1
- package/src/lib/utils/functions/createUserProfile/createUserProfile.cjs +1 -1
- package/src/lib/utils/functions/createUserProfile/createUserProfile.js +1 -1
- package/src/lib/utils/functions/getMissingChains/getMissingChains.cjs +1 -1
- package/src/lib/utils/functions/getMissingChains/getMissingChains.d.ts +1 -1
- package/src/lib/utils/functions/getMissingChains/getMissingChains.js +1 -1
- package/src/lib/utils/hooks/authenticationHooks/useConnectAndSign/useConnectAndSign.cjs +5 -1
- package/src/lib/utils/hooks/authenticationHooks/useConnectAndSign/useConnectAndSign.js +5 -1
- package/src/lib/utils/hooks/authenticationHooks/useConnectAndSignSplitSteps/useConnectAndSignSplitSteps.cjs +7 -1
- package/src/lib/utils/hooks/authenticationHooks/useConnectAndSignSplitSteps/useConnectAndSignSplitSteps.js +7 -1
- package/src/lib/utils/hooks/index.d.ts +0 -1
- package/src/lib/utils/hooks/multiWallet/useSyncPrimaryWallet/useSyncPrimaryWallet.cjs +3 -3
- package/src/lib/utils/hooks/multiWallet/useSyncPrimaryWallet/useSyncPrimaryWallet.d.ts +3 -3
- package/src/lib/utils/hooks/multiWallet/useSyncPrimaryWallet/useSyncPrimaryWallet.js +3 -3
- package/src/lib/utils/hooks/multiWallet/useVerifyOnAwaitingSignature/useVerifyOnAwaitingSignature.cjs +8 -11
- package/src/lib/utils/hooks/multiWallet/useVerifyOnAwaitingSignature/useVerifyOnAwaitingSignature.js +8 -11
- package/src/lib/utils/hooks/useConnectWallet/useConnectWallet.cjs +97 -84
- package/src/lib/utils/hooks/useConnectWallet/useConnectWallet.d.ts +5 -7
- package/src/lib/utils/hooks/useConnectWallet/useConnectWallet.js +99 -86
- package/src/lib/utils/hooks/useConnectWithEmail/useConnectWithEmail.cjs +5 -0
- package/src/lib/utils/hooks/useConnectWithEmail/useConnectWithEmail.js +5 -0
- package/src/lib/utils/hooks/useConnectedWalletsNetworkValidation/useConnectedWalletsNetworkValidation.cjs +69 -0
- package/src/lib/utils/hooks/useConnectedWalletsNetworkValidation/useConnectedWalletsNetworkValidation.d.ts +1 -0
- package/src/lib/utils/hooks/useConnectedWalletsNetworkValidation/useConnectedWalletsNetworkValidation.js +65 -0
- package/src/lib/utils/hooks/useFetchProjectSettings/useFetchProjectSettings.cjs +2 -1
- package/src/lib/utils/hooks/useFetchProjectSettings/useFetchProjectSettings.d.ts +3 -1
- package/src/lib/utils/hooks/useFetchProjectSettings/useFetchProjectSettings.js +3 -2
- package/src/lib/utils/hooks/useHandleWalletsToConnect/useHandleWalletsToConnect.cjs +5 -0
- package/src/lib/utils/hooks/useHandleWalletsToConnect/useHandleWalletsToConnect.js +5 -0
- package/src/lib/utils/hooks/useVerifyWallet/useVerifyWallet.cjs +3 -1
- package/src/lib/utils/hooks/useVerifyWallet/useVerifyWallet.js +3 -1
- package/src/lib/utils/hooks/useWalletConnectors/useWalletConnectors.cjs +11 -2
- package/src/lib/utils/hooks/useWalletConnectors/useWalletConnectors.d.ts +3 -2
- package/src/lib/utils/hooks/useWalletConnectors/useWalletConnectors.js +11 -2
- package/src/lib/utils/hooks/useWalletEventListeners/useWalletEventListeners.cjs +18 -8
- package/src/lib/utils/hooks/useWalletEventListeners/useWalletEventListeners.d.ts +3 -3
- package/src/lib/utils/hooks/useWalletEventListeners/useWalletEventListeners.js +18 -8
- package/src/lib/utils/hooks/useWalletItemActions/useWalletItemActions.cjs +4 -4
- package/src/lib/utils/hooks/useWalletItemActions/useWalletItemActions.js +4 -4
- package/src/lib/utils/hooks/useWalletUiUtils/useWalletUiUtils.cjs +1 -0
- package/src/lib/utils/hooks/useWalletUiUtils/useWalletUiUtils.js +1 -0
- package/src/lib/views/CaptchaVerifyUser/CaptchaVerifyUser.cjs +2 -1
- package/src/lib/views/CaptchaVerifyUser/CaptchaVerifyUser.js +2 -1
- package/src/lib/views/CollectUserDataView/CollectUserDataView.cjs +1 -0
- package/src/lib/views/CollectUserDataView/CollectUserDataView.js +1 -0
- package/src/lib/views/CollectUserDataView/OnboardingUserDataForm/OnboardingUserDataForm.cjs +1 -0
- package/src/lib/views/CollectUserDataView/OnboardingUserDataForm/OnboardingUserDataForm.js +1 -0
- package/src/lib/views/CollectUserDataView/UserDataFields/index.cjs +1 -0
- package/src/lib/views/CollectUserDataView/UserDataFields/index.js +1 -0
- package/src/lib/views/CollectUserDataView/fieldsConfig.cjs +8 -4
- package/src/lib/views/CollectUserDataView/fieldsConfig.js +8 -4
- package/src/lib/views/CollectUserDataViewLoginWithEmail/CollectUserDataViewLoginWithEmail.cjs +1 -0
- package/src/lib/views/CollectUserDataViewLoginWithEmail/CollectUserDataViewLoginWithEmail.js +1 -0
- package/src/lib/views/EmailConfirmationWaitingView/EmailConfirmationWaitingView.cjs +1 -0
- package/src/lib/views/EmailConfirmationWaitingView/EmailConfirmationWaitingView.js +1 -0
- package/src/lib/views/EmailUpdate/EmailUpdate.cjs +1 -0
- package/src/lib/views/EmailUpdate/EmailUpdate.js +1 -0
- package/src/lib/views/EmailVerification/EmailVerification.cjs +1 -0
- package/src/lib/views/EmailVerification/EmailVerification.js +1 -0
- package/src/lib/views/EmailWalletOTPVerificationView/EmailWalletOTPVerificationView.cjs +1 -0
- package/src/lib/views/EmailWalletOTPVerificationView/EmailWalletOTPVerificationView.js +1 -0
- package/src/lib/views/LoginWithEmailView/components/ListItemButton/ListItemButton.cjs +1 -0
- package/src/lib/views/LoginWithEmailView/components/ListItemButton/ListItemButton.js +1 -0
- package/src/lib/views/LoginWithEmailView/components/LoginWithEmailForm/LoginWithEmailForm.cjs +1 -0
- package/src/lib/views/LoginWithEmailView/components/LoginWithEmailForm/LoginWithEmailForm.js +1 -0
- package/src/lib/views/LoginWithEmailView/components/SocialSignIn/SocialSignIn.cjs +1 -0
- package/src/lib/views/LoginWithEmailView/components/SocialSignIn/SocialSignIn.js +1 -0
- package/src/lib/views/NetworkNotSupported/NetworkNotSupported.cjs +9 -10
- package/src/lib/views/NetworkNotSupported/NetworkNotSupported.js +10 -11
- package/src/lib/views/NetworkNotSupportedSwitchManual/NetworkNotSupportedSwitchManual.cjs +12 -12
- package/src/lib/views/NetworkNotSupportedSwitchManual/NetworkNotSupportedSwitchManual.js +13 -13
- package/src/lib/views/NoAccess/NoAccess.cjs +1 -0
- package/src/lib/views/NoAccess/NoAccess.js +1 -0
- package/src/lib/views/NoAccess/useNoAccessText.cjs +1 -1
- package/src/lib/views/NoAccess/useNoAccessText.js +1 -1
- package/src/lib/views/NoQrNotInstalledView/NoQrNotInstalledView.cjs +1 -0
- package/src/lib/views/NoQrNotInstalledView/NoQrNotInstalledView.js +1 -0
- package/src/lib/views/NoQrNotInstalledView/WalletHelpLink.cjs +1 -0
- package/src/lib/views/NoQrNotInstalledView/WalletHelpLink.js +1 -0
- package/src/lib/views/PendingConnectView/PendingConnectView.cjs +1 -0
- package/src/lib/views/PendingConnectView/PendingConnectView.js +1 -0
- package/src/lib/views/PendingSignatureView/PendingSignatureView.cjs +1 -0
- package/src/lib/views/PendingSignatureView/PendingSignatureView.js +1 -0
- package/src/lib/views/QrCodeView/QRCode.cjs +1 -0
- package/src/lib/views/QrCodeView/QRCode.js +1 -0
- package/src/lib/views/QrCodeView/QrCodeContainer/QrCodeContainer.cjs +1 -0
- package/src/lib/views/QrCodeView/QrCodeContainer/QrCodeContainer.js +1 -0
- package/src/lib/views/QrCodeView/QrCodeView.cjs +1 -0
- package/src/lib/views/QrCodeView/QrCodeView.js +1 -0
- package/src/lib/views/SendBalanceView/SendBalanceView.cjs +1 -0
- package/src/lib/views/SendBalanceView/SendBalanceView.js +1 -0
- package/src/lib/views/SocialRedirectView/SocialRedirectView.cjs +1 -0
- package/src/lib/views/SocialRedirectView/SocialRedirectView.js +1 -0
- package/src/lib/views/SocialWrongAccountView/SocialWrongAccountView.cjs +1 -0
- package/src/lib/views/SocialWrongAccountView/SocialWrongAccountView.js +1 -0
- package/src/lib/views/TransactionConfirmationView/TransactionConfirmationView.cjs +1 -0
- package/src/lib/views/TransactionConfirmationView/TransactionConfirmationView.js +1 -0
- package/src/lib/views/TransactionConfirmationView/hooks/useTransactionData/useTransactionData.cjs +1 -0
- package/src/lib/views/TransactionConfirmationView/hooks/useTransactionData/useTransactionData.js +1 -0
- package/src/lib/views/WalletList/SearchNotFoundMessage/SearchNotFoundMessage.cjs +1 -0
- package/src/lib/views/WalletList/SearchNotFoundMessage/SearchNotFoundMessage.js +1 -0
- package/src/lib/views/WalletList/WalletListItem/WalletListItem.cjs +2 -1
- package/src/lib/views/WalletList/WalletListItem/WalletListItem.js +2 -1
- package/src/lib/views/WalletLockedView/WalletLockedView.cjs +1 -0
- package/src/lib/views/WalletLockedView/WalletLockedView.js +1 -0
- package/src/lib/views/WalletSignSpinnerView/WalletSignSpinnerView.cjs +1 -0
- package/src/lib/views/WalletSignSpinnerView/WalletSignSpinnerView.js +1 -0
- package/src/lib/views/WalletUsedView/WalletUsedView.cjs +1 -0
- package/src/lib/views/WalletUsedView/WalletUsedView.js +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/DynamicBridgeWidget.cjs +2 -1
- package/src/lib/widgets/DynamicBridgeWidget/DynamicBridgeWidget.js +2 -1
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeUserProfile/DynamicBridgeUserProfile.cjs +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeUserProfile/DynamicBridgeUserProfile.js +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWalletCard/DynamicBridgeWalletCard.cjs +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWalletCard/DynamicBridgeWalletCard.js +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWalletCardBody/DynamicBridgeWalletCardBody.cjs +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWalletCardBody/DynamicBridgeWalletCardBody.js +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWidgetEmptyCard/DynamicBridgeWidgetEmptyCard.cjs +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/components/DynamicBridgeWidgetEmptyCard/DynamicBridgeWidgetEmptyCard.js +1 -0
- package/src/lib/widgets/DynamicBridgeWidget/context/DynamicBridgeWidgetContext/DynamicBridgeWidgetContext.cjs +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/context/DynamicBridgeWidgetContext/DynamicBridgeWidgetContext.js +2 -0
- package/src/lib/widgets/DynamicBridgeWidget/views/WalletsView/WalletsView.cjs +2 -1
- package/src/lib/widgets/DynamicBridgeWidget/views/WalletsView/WalletsView.js +2 -1
- package/src/lib/widgets/DynamicBridgeWidget/views/WalletsView/components/SecondaryWallets/SecondaryWallets.cjs +1 -1
- package/src/lib/widgets/DynamicBridgeWidget/views/WalletsView/components/SecondaryWallets/SecondaryWallets.js +1 -1
- package/src/lib/widgets/DynamicWidget/DynamicWidget.cjs +10 -3
- package/src/lib/widgets/DynamicWidget/DynamicWidget.js +12 -5
- package/src/lib/widgets/DynamicWidget/components/AccountControl/AccountControl.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/AccountControl/AccountControl.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/ActiveWalletInformation/ActiveWalletInformation.cjs +5 -4
- package/src/lib/widgets/DynamicWidget/components/ActiveWalletInformation/ActiveWalletInformation.js +5 -4
- 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 +5 -4
- package/src/lib/widgets/DynamicWidget/components/DotsMenu/DotsMenu.d.ts +4 -7
- package/src/lib/widgets/DynamicWidget/components/DotsMenu/DotsMenu.js +5 -4
- package/src/lib/widgets/DynamicWidget/components/DotsMenuDropdown/DotsMenuDropdown.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/DotsMenuDropdown/DotsMenuDropdown.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicUserProfile/DynamicUserProfile.cjs +4 -1
- package/src/lib/widgets/DynamicWidget/components/DynamicUserProfile/DynamicUserProfile.js +4 -1
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetHeader.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetHeader.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetWalletHeader/DynamicWidgetWalletHeader.cjs +4 -3
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetWalletHeader/DynamicWidgetWalletHeader.js +4 -3
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/variants/DynamicWidgetDropdown/DynamicWidgetDropdown.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/variants/DynamicWidgetDropdown/DynamicWidgetDropdown.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/variants/DynamicWidgetModal/DynamicWidgetModal.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetVariants/variants/DynamicWidgetModal/DynamicWidgetModal.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetWallets/DynamicWidgetWallets.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/DynamicWidgetWallets/DynamicWidgetWallets.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/EmailConnectorPendingSignModalContent/EmailConnectorPendingSignModalContent.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/EmailConnectorPendingSignModalContent/EmailConnectorPendingSignModalContent.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/EmailOTPConnectorPendingSignModalContent/EmailOTPConnectorPendingSignModalContent.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/EmailOTPConnectorPendingSignModalContent/EmailOTPConnectorPendingSignModalContent.js +1 -0
- package/src/lib/widgets/DynamicWidget/components/EmptyWallets/EmptyWallets.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/EmptyWallets/EmptyWallets.js +1 -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 +2 -1
- package/src/lib/widgets/DynamicWidget/components/Wallet/Wallet.js +2 -1
- package/src/lib/widgets/DynamicWidget/components/WidgetPortal/WidgetPortal.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/components/WidgetPortal/WidgetPortal.js +1 -0
- package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.js +1 -0
- package/src/lib/widgets/DynamicWidget/helpers/helpers.cjs +17 -1
- package/src/lib/widgets/DynamicWidget/helpers/helpers.js +17 -1
- package/src/lib/widgets/DynamicWidget/prompts/DefaultPromptModal/DefaultPromptModal.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/DefaultPromptModal/DefaultPromptModal.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/DetectedNewWalletModal/DetectedNewWalletModal.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/DetectedNewWalletModal/DetectedNewWalletModal.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/NoQrNotInstalledModalView/NoQrNotInstalledModalView.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/NoQrNotInstalledModalView/NoQrNotInstalledModalView.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchModal/SwitchAccountView/SwitchAccountView.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchModal/SwitchAccountView/SwitchAccountView.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchModal/SwitchOrUseActiveAccountView/SwitchOrUseActiveAccountView.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchModal/SwitchOrUseActiveAccountView/SwitchOrUseActiveAccountView.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchToLinkModal/PendingAccountSwitchToLinkModal.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingAccountSwitchToLinkModal/PendingAccountSwitchToLinkModal.js +1 -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 +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PendingSignModal/DefaultPendingSignModalContent/DefaultPendingSignModalContent.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PrimaryNotConnectedModal/PrimaryNotConnectedModal.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/PrimaryNotConnectedModal/PrimaryNotConnectedModal.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/QrCodeModalView/QrCodeModalView.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/QrCodeModalView/QrCodeModalView.js +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/UnlinkWalletPopUp/UnlinkWalletPopUp.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/prompts/UnlinkWalletPopUp/UnlinkWalletPopUp.js +1 -0
- package/src/lib/widgets/DynamicWidget/views/EditProfileView/EditProfileView.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/views/EditProfileView/EditProfileView.js +1 -0
- package/src/lib/widgets/DynamicWidget/views/ProfileView/ProfileView.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/views/ProfileView/ProfileView.js +1 -0
- package/src/lib/widgets/DynamicWidget/views/WalletsView/WalletsView.cjs +1 -0
- package/src/lib/widgets/DynamicWidget/views/WalletsView/WalletsView.js +1 -0
- package/src/lib/widgets/FundingWidget/views/FundWalletView/FundWalletView.cjs +1 -0
- package/src/lib/widgets/FundingWidget/views/FundWalletView/FundWalletView.js +1 -0
- package/src/lib/components/NetworkPicker/components/ActionList/ActionList.cjs +0 -71
- package/src/lib/components/NetworkPicker/components/ActionList/ActionList.d.ts +0 -12
- package/src/lib/components/NetworkPicker/components/ActionList/ActionList.js +0 -65
- package/src/lib/components/NetworkPicker/components/ActionList/index.d.ts +0 -1
- package/src/lib/components/Popper/utils/watchToScrollInHierarchy/watchToScrollInHierarchy.d.ts +0 -1
- package/src/lib/utils/hooks/useWalletConnectorEvents/useWalletConnectorEvents.cjs +0 -17
- package/src/lib/utils/hooks/useWalletConnectorEvents/useWalletConnectorEvents.d.ts +0 -2
- package/src/lib/utils/hooks/useWalletConnectorEvents/useWalletConnectorEvents.js +0 -13
- /package/src/lib/components/{Popper → MenuList}/utils/watchToScrollInHierarchy/index.d.ts +0 -0
|
@@ -5,28 +5,28 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var reactDom = require('react-dom');
|
|
8
|
+
var PopperContent = require('../PopperContent/PopperContent.cjs');
|
|
8
9
|
var PopperContext = require('../PopperContext/PopperContext.cjs');
|
|
9
10
|
var getChildPosition = require('../utils/getChildPosition/getChildPosition.cjs');
|
|
10
|
-
var watchToScrollInHierarchy = require('../utils/watchToScrollInHierarchy/watchToScrollInHierarchy.cjs');
|
|
11
|
-
var PopperContent = require('../PopperContent/PopperContent.cjs');
|
|
12
11
|
|
|
13
|
-
|
|
12
|
+
// eslint-disable-next-line multiline-comment-style
|
|
13
|
+
/** Allows to render content outside of the current DOM parent and specify a reference position
|
|
14
|
+
* To allow for opening and closing of menus, see MenuList and Dropdown components
|
|
15
|
+
*/
|
|
16
|
+
const Popper = React.forwardRef(({ anchorRef, anchorOrigin = 'top-left', transformOrigin = 'top-left', children, style, className, }, ref) => {
|
|
14
17
|
const { containerRef } = PopperContext.usePopper();
|
|
15
18
|
const [anchorPosition, setAnchorPosition] = React.useState();
|
|
16
19
|
const container = containerRef.current;
|
|
20
|
+
// Calculates anchor position based on anchorOrigin's relative position to popper's container
|
|
21
|
+
// and sets up scroll listener to close popper
|
|
17
22
|
React.useEffect(() => {
|
|
18
|
-
if (!isOpen) {
|
|
19
|
-
return setAnchorPosition(undefined);
|
|
20
|
-
}
|
|
21
23
|
const container = containerRef.current;
|
|
22
24
|
const anchor = anchorRef.current;
|
|
23
25
|
if (!container || !anchor)
|
|
24
26
|
return;
|
|
25
27
|
setAnchorPosition(getChildPosition.getChildPosition(container, anchor));
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
});
|
|
29
|
-
}, [anchorRef, containerRef, isOpen, setAnchorPosition, setIsOpen]);
|
|
28
|
+
}, [anchorRef, containerRef, setAnchorPosition]);
|
|
29
|
+
/** Position of the anchor's vertex that was selected by anchorOrigin */
|
|
30
30
|
const anchorOriginPosition = React.useMemo(() => {
|
|
31
31
|
var _a;
|
|
32
32
|
const anchorRect = (_a = anchorRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
@@ -45,9 +45,9 @@ const Popper = React.forwardRef(({ anchorRef, isOpen, setIsOpen, anchorOrigin =
|
|
|
45
45
|
return undefined;
|
|
46
46
|
}
|
|
47
47
|
}, [anchorPosition, anchorRef, anchorOrigin]);
|
|
48
|
-
if (!
|
|
48
|
+
if (!anchorOriginPosition || container === null)
|
|
49
49
|
return null;
|
|
50
|
-
return reactDom.createPortal(jsxRuntime.jsx(PopperContent.PopperContent, Object.assign({ ref: ref, transformOrigin: transformOrigin, style: anchorOriginPosition }, { children: children })), container);
|
|
50
|
+
return reactDom.createPortal(jsxRuntime.jsx(PopperContent.PopperContent, Object.assign({ ref: ref, transformOrigin: transformOrigin, style: Object.assign(Object.assign({}, anchorOriginPosition), style), className: className }, { children: children })), container);
|
|
51
51
|
});
|
|
52
52
|
Popper.displayName = 'Popper';
|
|
53
53
|
|
|
@@ -1,12 +1,15 @@
|
|
|
1
|
-
import { MutableRefObject } from 'react';
|
|
1
|
+
import { CSSProperties, MutableRefObject } from 'react';
|
|
2
2
|
import { AnchorOrigin, TransformOrigin } from '../Popper.types';
|
|
3
3
|
export type PopperProps = {
|
|
4
|
-
anchorOrigin?: AnchorOrigin;
|
|
5
4
|
anchorRef: MutableRefObject<HTMLElement | null>;
|
|
6
|
-
|
|
7
|
-
setIsOpen: (isOpen: boolean) => void;
|
|
5
|
+
anchorOrigin?: AnchorOrigin;
|
|
8
6
|
transformOrigin?: TransformOrigin;
|
|
7
|
+
className?: string;
|
|
8
|
+
style?: CSSProperties;
|
|
9
9
|
};
|
|
10
|
+
/** Allows to render content outside of the current DOM parent and specify a reference position
|
|
11
|
+
* To allow for opening and closing of menus, see MenuList and Dropdown components
|
|
12
|
+
*/
|
|
10
13
|
export declare const Popper: import("react").ForwardRefExoticComponent<PopperProps & {
|
|
11
14
|
children?: import("react").ReactNode;
|
|
12
15
|
} & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { forwardRef, useState, useEffect, useMemo } from 'react';
|
|
3
3
|
import { createPortal } from 'react-dom';
|
|
4
|
+
import { PopperContent } from '../PopperContent/PopperContent.js';
|
|
4
5
|
import { usePopper } from '../PopperContext/PopperContext.js';
|
|
5
6
|
import { getChildPosition } from '../utils/getChildPosition/getChildPosition.js';
|
|
6
|
-
import { watchToScrollInHierarchy } from '../utils/watchToScrollInHierarchy/watchToScrollInHierarchy.js';
|
|
7
|
-
import { PopperContent } from '../PopperContent/PopperContent.js';
|
|
8
7
|
|
|
9
|
-
|
|
8
|
+
// eslint-disable-next-line multiline-comment-style
|
|
9
|
+
/** Allows to render content outside of the current DOM parent and specify a reference position
|
|
10
|
+
* To allow for opening and closing of menus, see MenuList and Dropdown components
|
|
11
|
+
*/
|
|
12
|
+
const Popper = forwardRef(({ anchorRef, anchorOrigin = 'top-left', transformOrigin = 'top-left', children, style, className, }, ref) => {
|
|
10
13
|
const { containerRef } = usePopper();
|
|
11
14
|
const [anchorPosition, setAnchorPosition] = useState();
|
|
12
15
|
const container = containerRef.current;
|
|
16
|
+
// Calculates anchor position based on anchorOrigin's relative position to popper's container
|
|
17
|
+
// and sets up scroll listener to close popper
|
|
13
18
|
useEffect(() => {
|
|
14
|
-
if (!isOpen) {
|
|
15
|
-
return setAnchorPosition(undefined);
|
|
16
|
-
}
|
|
17
19
|
const container = containerRef.current;
|
|
18
20
|
const anchor = anchorRef.current;
|
|
19
21
|
if (!container || !anchor)
|
|
20
22
|
return;
|
|
21
23
|
setAnchorPosition(getChildPosition(container, anchor));
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
});
|
|
25
|
-
}, [anchorRef, containerRef, isOpen, setAnchorPosition, setIsOpen]);
|
|
24
|
+
}, [anchorRef, containerRef, setAnchorPosition]);
|
|
25
|
+
/** Position of the anchor's vertex that was selected by anchorOrigin */
|
|
26
26
|
const anchorOriginPosition = useMemo(() => {
|
|
27
27
|
var _a;
|
|
28
28
|
const anchorRect = (_a = anchorRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
@@ -41,9 +41,9 @@ const Popper = forwardRef(({ anchorRef, isOpen, setIsOpen, anchorOrigin = 'top-l
|
|
|
41
41
|
return undefined;
|
|
42
42
|
}
|
|
43
43
|
}, [anchorPosition, anchorRef, anchorOrigin]);
|
|
44
|
-
if (!
|
|
44
|
+
if (!anchorOriginPosition || container === null)
|
|
45
45
|
return null;
|
|
46
|
-
return createPortal(jsx(PopperContent, Object.assign({ ref: ref, transformOrigin: transformOrigin, style: anchorOriginPosition }, { children: children })), container);
|
|
46
|
+
return createPortal(jsx(PopperContent, Object.assign({ ref: ref, transformOrigin: transformOrigin, style: Object.assign(Object.assign({}, anchorOriginPosition), style), className: className }, { children: children })), container);
|
|
47
47
|
});
|
|
48
48
|
Popper.displayName = 'Popper';
|
|
49
49
|
|
|
@@ -12,7 +12,7 @@ const mapTransformOriginToClassName = {
|
|
|
12
12
|
'top-left': 'popper-content__transform-origin-top-left',
|
|
13
13
|
'top-right': 'popper-content__transform-origin-top-right',
|
|
14
14
|
};
|
|
15
|
-
const PopperContent = React.forwardRef(({ children, transformOrigin, style }, ref) => (jsxRuntime.jsx("div", Object.assign({ "data-testid": 'popper-content', ref: ref, className: classNames.classNames('popper-content', mapTransformOriginToClassName[transformOrigin]), style: style }, { children: children }))));
|
|
15
|
+
const PopperContent = React.forwardRef(({ children, transformOrigin, style, className }, ref) => (jsxRuntime.jsx("div", Object.assign({ "data-testid": 'popper-content', ref: ref, className: classNames.classNames('popper-content', mapTransformOriginToClassName[transformOrigin], className), style: style }, { children: children }))));
|
|
16
16
|
PopperContent.displayName = 'PopperContent';
|
|
17
17
|
|
|
18
18
|
exports.PopperContent = PopperContent;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { CSSProperties } from 'react';
|
|
2
2
|
import { TransformOrigin } from '../Popper.types';
|
|
3
3
|
export type PopperContentProps = {
|
|
4
|
-
style?: CSSProperties;
|
|
5
4
|
transformOrigin: TransformOrigin;
|
|
5
|
+
style?: CSSProperties;
|
|
6
|
+
className?: string;
|
|
6
7
|
};
|
|
7
8
|
export declare const PopperContent: import("react").ForwardRefExoticComponent<PopperContentProps & {
|
|
8
9
|
children?: import("react").ReactNode;
|
|
@@ -8,7 +8,7 @@ const mapTransformOriginToClassName = {
|
|
|
8
8
|
'top-left': 'popper-content__transform-origin-top-left',
|
|
9
9
|
'top-right': 'popper-content__transform-origin-top-right',
|
|
10
10
|
};
|
|
11
|
-
const PopperContent = forwardRef(({ children, transformOrigin, style }, ref) => (jsx("div", Object.assign({ "data-testid": 'popper-content', ref: ref, className: classNames('popper-content', mapTransformOriginToClassName[transformOrigin]), style: style }, { children: children }))));
|
|
11
|
+
const PopperContent = forwardRef(({ children, transformOrigin, style, className }, ref) => (jsx("div", Object.assign({ "data-testid": 'popper-content', ref: ref, className: classNames('popper-content', mapTransformOriginToClassName[transformOrigin], className), style: style }, { children: children }))));
|
|
12
12
|
PopperContent.displayName = 'PopperContent';
|
|
13
13
|
|
|
14
14
|
export { PopperContent };
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
+
/** Return element's top-left position relative to root */
|
|
5
6
|
const getChildPosition = (root, element) => {
|
|
6
7
|
const rootRect = root.getBoundingClientRect();
|
|
7
8
|
const elementRect = element.getBoundingClientRect();
|
|
@@ -38,6 +38,7 @@ require('../Popper/PopperContext/PopperContext.cjs');
|
|
|
38
38
|
require('formik');
|
|
39
39
|
require('yup');
|
|
40
40
|
require('../InlineWidget/InlineWidget.cjs');
|
|
41
|
+
require('../MenuList/Dropdown/Dropdown.cjs');
|
|
41
42
|
require('../../context/MockContext/MockContext.cjs');
|
|
42
43
|
require('../../context/CaptchaContext/CaptchaContext.cjs');
|
|
43
44
|
require('../../utils/hooks/useUserUpdateRequest/useUserUpdateRequest.cjs');
|
|
@@ -69,11 +70,11 @@ const ModalComponent = ({ children, handleClose, withBackdrop = true, zIndex, wh
|
|
|
69
70
|
inputKey: 'Escape',
|
|
70
71
|
onKeyPressed: handleClose,
|
|
71
72
|
});
|
|
72
|
-
return (jsxRuntime.jsxs(ReactFocusLock__default["default"], Object.assign({ className: '
|
|
73
|
+
return (jsxRuntime.jsxs(ReactFocusLock__default["default"], Object.assign({ className: 'portal__container', whiteList: whiteList }, { children: [withBackdrop && (jsxRuntime.jsx("div", { "data-testid": 'portal-backdrop', role: 'button', onClick: (e) => {
|
|
73
74
|
onBackdropClick(e);
|
|
74
75
|
}, onKeyDown: handleKeyClose, tabIndex: 0, "aria-label": 'Close modal',
|
|
75
76
|
// z-index - 2 to ensure that the backdrop is always behind the content
|
|
76
|
-
style: { zIndex: zIndex ? zIndex - 2 : undefined }, className: '
|
|
77
|
+
style: { zIndex: zIndex ? zIndex - 2 : undefined }, className: 'portal__backdrop' })), jsxRuntime.jsx("div", Object.assign({ style: { zIndex } }, { children: children }))] })));
|
|
77
78
|
};
|
|
78
79
|
const Portal = ({ children, isShown, handleClose, withBackdrop, zIndex, transitionEvents, elementId = 'dynamic-modal', }) => {
|
|
79
80
|
const modalRootElementRef = useElementById.useElementById(elementId);
|
|
@@ -34,6 +34,7 @@ import '../Popper/PopperContext/PopperContext.js';
|
|
|
34
34
|
import 'formik';
|
|
35
35
|
import 'yup';
|
|
36
36
|
import '../InlineWidget/InlineWidget.js';
|
|
37
|
+
import '../MenuList/Dropdown/Dropdown.js';
|
|
37
38
|
import '../../context/MockContext/MockContext.js';
|
|
38
39
|
import '../../context/CaptchaContext/CaptchaContext.js';
|
|
39
40
|
import '../../utils/hooks/useUserUpdateRequest/useUserUpdateRequest.js';
|
|
@@ -61,11 +62,11 @@ const ModalComponent = ({ children, handleClose, withBackdrop = true, zIndex, wh
|
|
|
61
62
|
inputKey: 'Escape',
|
|
62
63
|
onKeyPressed: handleClose,
|
|
63
64
|
});
|
|
64
|
-
return (jsxs(ReactFocusLock, Object.assign({ className: '
|
|
65
|
+
return (jsxs(ReactFocusLock, Object.assign({ className: 'portal__container', whiteList: whiteList }, { children: [withBackdrop && (jsx("div", { "data-testid": 'portal-backdrop', role: 'button', onClick: (e) => {
|
|
65
66
|
onBackdropClick(e);
|
|
66
67
|
}, onKeyDown: handleKeyClose, tabIndex: 0, "aria-label": 'Close modal',
|
|
67
68
|
// z-index - 2 to ensure that the backdrop is always behind the content
|
|
68
|
-
style: { zIndex: zIndex ? zIndex - 2 : undefined }, className: '
|
|
69
|
+
style: { zIndex: zIndex ? zIndex - 2 : undefined }, className: 'portal__backdrop' })), jsx("div", Object.assign({ style: { zIndex } }, { children: children }))] })));
|
|
69
70
|
};
|
|
70
71
|
const Portal = ({ children, isShown, handleClose, withBackdrop, zIndex, transitionEvents, elementId = 'dynamic-modal', }) => {
|
|
71
72
|
const modalRootElementRef = useElementById(elementId);
|
|
@@ -15,8 +15,9 @@ const alignClassNames = {
|
|
|
15
15
|
right: 'powered-by-dynamic--right',
|
|
16
16
|
};
|
|
17
17
|
const PoweredByDynamic = ({ align = 'center', classNameLogo, classNameRoot, classNameText, }) => {
|
|
18
|
+
var _a;
|
|
18
19
|
const { projectSettings } = useInternalDynamicContext.useInternalDynamicContext();
|
|
19
|
-
if ((projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.sdk.displayDynamicMessaging) === false) {
|
|
20
|
+
if (((_a = projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.sdk) === null || _a === void 0 ? void 0 : _a.displayDynamicMessaging) === false) {
|
|
20
21
|
return null;
|
|
21
22
|
}
|
|
22
23
|
return (jsxRuntime.jsxs("a", Object.assign({ target: '_blank', href: URL, className: classNames.classNames('powered-by-dynamic', alignClassNames[align], classNameRoot), rel: 'noreferrer' }, { children: [jsxRuntime.jsx(Typography.Typography, Object.assign({ as: 'span', color: 'secondary', weight: 'regular', variant: 'body_mini', className: classNames.classNames('powered-by-dynamic__text', classNameText) }, { children: "Powered by" })), jsxRuntime.jsx(dynamicLogo.ReactComponent, { className: classNames.classNames('powered-by-dynamic__logo', classNameLogo) })] })));
|
|
@@ -11,8 +11,9 @@ const alignClassNames = {
|
|
|
11
11
|
right: 'powered-by-dynamic--right',
|
|
12
12
|
};
|
|
13
13
|
const PoweredByDynamic = ({ align = 'center', classNameLogo, classNameRoot, classNameText, }) => {
|
|
14
|
+
var _a;
|
|
14
15
|
const { projectSettings } = useInternalDynamicContext();
|
|
15
|
-
if ((projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.sdk.displayDynamicMessaging) === false) {
|
|
16
|
+
if (((_a = projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.sdk) === null || _a === void 0 ? void 0 : _a.displayDynamicMessaging) === false) {
|
|
16
17
|
return null;
|
|
17
18
|
}
|
|
18
19
|
return (jsxs("a", Object.assign({ target: '_blank', href: URL, className: classNames('powered-by-dynamic', alignClassNames[align], classNameRoot), rel: 'noreferrer' }, { children: [jsx(Typography, Object.assign({ as: 'span', color: 'secondary', weight: 'regular', variant: 'body_mini', className: classNames('powered-by-dynamic__text', classNameText) }, { children: "Powered by" })), jsx(SvgDynamicLogo, { className: classNames('powered-by-dynamic__logo', classNameLogo) })] })));
|
|
@@ -5,9 +5,11 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var reactDom = require('react-dom');
|
|
8
|
+
var utils$1 = require('@dynamic-labs/utils');
|
|
8
9
|
var useInternalDynamicContext = require('../../context/DynamicContext/useInternalDynamicContext.cjs');
|
|
9
10
|
var index_shadow = require('../../styles/index.shadow.cjs');
|
|
10
11
|
var classNames = require('../../utils/functions/classNames/classNames.cjs');
|
|
12
|
+
var LegacySafariCssOverrides = require('../LegacySafariCssOverrides/LegacySafariCssOverrides.cjs');
|
|
11
13
|
var utils = require('./utils.cjs');
|
|
12
14
|
|
|
13
15
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
@@ -47,10 +49,10 @@ const ShadowDOM = ({ mode = 'open', id, className, children, dataTestId, zIndex,
|
|
|
47
49
|
}, [shadowDOMEnabled, nodeRef, mode]);
|
|
48
50
|
const shouldRenderStyles = Boolean(Object.keys(index_shadow).length);
|
|
49
51
|
if (!shadowDOMEnabled) {
|
|
50
|
-
return (jsxRuntime.jsxs("div", Object.assign({ "data-testid": dataTestId, ref: nodeRef, id: id, className: classNames.classNames('dynamic-shadow-dom', className), style: { zIndex } }, { children: [children, shouldRenderStyles && jsxRuntime.jsx(ShadowDOMStyle, {}), CssOverridesElement && jsxRuntime.jsx(CssOverridesElement, {})] })));
|
|
52
|
+
return (jsxRuntime.jsxs("div", Object.assign({ "data-testid": dataTestId, ref: nodeRef, id: id, className: classNames.classNames('dynamic-shadow-dom', className), style: { zIndex } }, { children: [children, shouldRenderStyles && jsxRuntime.jsx(ShadowDOMStyle, {}), utils$1.isLegacySafari() && jsxRuntime.jsx(LegacySafariCssOverrides.LegacySafariCssOverrides, {}), CssOverridesElement && jsxRuntime.jsx(CssOverridesElement, {})] })));
|
|
51
53
|
}
|
|
52
54
|
return (jsxRuntime.jsx(ShadowDOMContext.Provider, Object.assign({ value: { shadowRoot } }, { children: jsxRuntime.jsx("div", Object.assign({ "data-testid": dataTestId, ref: nodeRef, id: id, className: classNames.classNames('dynamic-shadow-dom', className), style: { zIndex } }, { children: shadowRoot &&
|
|
53
|
-
reactDom.createPortal(jsxRuntime.jsxs("div", Object.assign({ className: 'dynamic-shadow-dom-content' }, { children: [children, shouldRenderStyles && jsxRuntime.jsx(ShadowDOMStyle, {}), CssOverridesElement && jsxRuntime.jsx(CssOverridesElement, {})] })), shadowRoot) })) })));
|
|
55
|
+
reactDom.createPortal(jsxRuntime.jsxs("div", Object.assign({ className: 'dynamic-shadow-dom-content' }, { children: [children, shouldRenderStyles && jsxRuntime.jsx(ShadowDOMStyle, {}), utils$1.isLegacySafari() && jsxRuntime.jsx(LegacySafariCssOverrides.LegacySafariCssOverrides, {}), CssOverridesElement && jsxRuntime.jsx(CssOverridesElement, {})] })), shadowRoot) })) })));
|
|
54
56
|
};
|
|
55
57
|
|
|
56
58
|
exports.ShadowDOM = ShadowDOM;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import React__default, { useRef, useState, useMemo, useLayoutEffect } from 'react';
|
|
3
3
|
import { createPortal } from 'react-dom';
|
|
4
|
+
import { isLegacySafari } from '@dynamic-labs/utils';
|
|
4
5
|
import { useInternalDynamicContext } from '../../context/DynamicContext/useInternalDynamicContext.js';
|
|
5
6
|
import css_248z from '../../styles/index.shadow.js';
|
|
6
7
|
import { classNames } from '../../utils/functions/classNames/classNames.js';
|
|
8
|
+
import { LegacySafariCssOverrides } from '../LegacySafariCssOverrides/LegacySafariCssOverrides.js';
|
|
7
9
|
import { isShadowDOMFlagEnabled } from './utils.js';
|
|
8
10
|
|
|
9
11
|
const ShadowDOMContext = React__default.createContext({});
|
|
@@ -39,10 +41,10 @@ const ShadowDOM = ({ mode = 'open', id, className, children, dataTestId, zIndex,
|
|
|
39
41
|
}, [shadowDOMEnabled, nodeRef, mode]);
|
|
40
42
|
const shouldRenderStyles = Boolean(Object.keys(css_248z).length);
|
|
41
43
|
if (!shadowDOMEnabled) {
|
|
42
|
-
return (jsxs("div", Object.assign({ "data-testid": dataTestId, ref: nodeRef, id: id, className: classNames('dynamic-shadow-dom', className), style: { zIndex } }, { children: [children, shouldRenderStyles && jsx(ShadowDOMStyle, {}), CssOverridesElement && jsx(CssOverridesElement, {})] })));
|
|
44
|
+
return (jsxs("div", Object.assign({ "data-testid": dataTestId, ref: nodeRef, id: id, className: classNames('dynamic-shadow-dom', className), style: { zIndex } }, { children: [children, shouldRenderStyles && jsx(ShadowDOMStyle, {}), isLegacySafari() && jsx(LegacySafariCssOverrides, {}), CssOverridesElement && jsx(CssOverridesElement, {})] })));
|
|
43
45
|
}
|
|
44
46
|
return (jsx(ShadowDOMContext.Provider, Object.assign({ value: { shadowRoot } }, { children: jsx("div", Object.assign({ "data-testid": dataTestId, ref: nodeRef, id: id, className: classNames('dynamic-shadow-dom', className), style: { zIndex } }, { children: shadowRoot &&
|
|
45
|
-
createPortal(jsxs("div", Object.assign({ className: 'dynamic-shadow-dom-content' }, { children: [children, shouldRenderStyles && jsx(ShadowDOMStyle, {}), CssOverridesElement && jsx(CssOverridesElement, {})] })), shadowRoot) })) })));
|
|
47
|
+
createPortal(jsxs("div", Object.assign({ className: 'dynamic-shadow-dom-content' }, { children: [children, shouldRenderStyles && jsx(ShadowDOMStyle, {}), isLegacySafari() && jsx(LegacySafariCssOverrides, {}), CssOverridesElement && jsx(CssOverridesElement, {})] })), shadowRoot) })) })));
|
|
46
48
|
};
|
|
47
49
|
|
|
48
50
|
export { ShadowDOM, ShadowDOMContext, ShadowDOMStyle };
|
|
@@ -42,6 +42,7 @@ require('../Popper/PopperContext/PopperContext.cjs');
|
|
|
42
42
|
require('formik');
|
|
43
43
|
require('yup');
|
|
44
44
|
require('../InlineWidget/InlineWidget.cjs');
|
|
45
|
+
require('../MenuList/Dropdown/Dropdown.cjs');
|
|
45
46
|
require('../../context/MockContext/MockContext.cjs');
|
|
46
47
|
require('../../context/CaptchaContext/CaptchaContext.cjs');
|
|
47
48
|
require('../../utils/hooks/useUserUpdateRequest/useUserUpdateRequest.cjs');
|
|
@@ -38,6 +38,7 @@ import '../Popper/PopperContext/PopperContext.js';
|
|
|
38
38
|
import 'formik';
|
|
39
39
|
import 'yup';
|
|
40
40
|
import '../InlineWidget/InlineWidget.js';
|
|
41
|
+
import '../MenuList/Dropdown/Dropdown.js';
|
|
41
42
|
import '../../context/MockContext/MockContext.js';
|
|
42
43
|
import '../../context/CaptchaContext/CaptchaContext.js';
|
|
43
44
|
import '../../utils/hooks/useUserUpdateRequest/useUserUpdateRequest.js';
|
|
@@ -45,6 +45,7 @@ require('../Popper/PopperContext/PopperContext.cjs');
|
|
|
45
45
|
require('formik');
|
|
46
46
|
require('yup');
|
|
47
47
|
require('../InlineWidget/InlineWidget.cjs');
|
|
48
|
+
require('../MenuList/Dropdown/Dropdown.cjs');
|
|
48
49
|
require('../../context/MockContext/MockContext.cjs');
|
|
49
50
|
require('../../context/CaptchaContext/CaptchaContext.cjs');
|
|
50
51
|
require('../../utils/hooks/useUserUpdateRequest/useUserUpdateRequest.cjs');
|
|
@@ -41,6 +41,7 @@ import '../Popper/PopperContext/PopperContext.js';
|
|
|
41
41
|
import 'formik';
|
|
42
42
|
import 'yup';
|
|
43
43
|
import '../InlineWidget/InlineWidget.js';
|
|
44
|
+
import '../MenuList/Dropdown/Dropdown.js';
|
|
44
45
|
import '../../context/MockContext/MockContext.js';
|
|
45
46
|
import '../../context/CaptchaContext/CaptchaContext.js';
|
|
46
47
|
import '../../utils/hooks/useUserUpdateRequest/useUserUpdateRequest.js';
|
|
@@ -40,6 +40,7 @@ require('../../Popper/PopperContext/PopperContext.cjs');
|
|
|
40
40
|
require('formik');
|
|
41
41
|
require('yup');
|
|
42
42
|
require('../../InlineWidget/InlineWidget.cjs');
|
|
43
|
+
require('../../MenuList/Dropdown/Dropdown.cjs');
|
|
43
44
|
require('../../../context/MockContext/MockContext.cjs');
|
|
44
45
|
require('../../../context/CaptchaContext/CaptchaContext.cjs');
|
|
45
46
|
require('../../../utils/hooks/useUserUpdateRequest/useUserUpdateRequest.cjs');
|
|
@@ -36,6 +36,7 @@ import '../../Popper/PopperContext/PopperContext.js';
|
|
|
36
36
|
import 'formik';
|
|
37
37
|
import 'yup';
|
|
38
38
|
import '../../InlineWidget/InlineWidget.js';
|
|
39
|
+
import '../../MenuList/Dropdown/Dropdown.js';
|
|
39
40
|
import '../../../context/MockContext/MockContext.js';
|
|
40
41
|
import '../../../context/CaptchaContext/CaptchaContext.js';
|
|
41
42
|
import '../../../utils/hooks/useUserUpdateRequest/useUserUpdateRequest.js';
|
|
@@ -40,6 +40,7 @@ require('../Popper/PopperContext/PopperContext.cjs');
|
|
|
40
40
|
require('formik');
|
|
41
41
|
require('yup');
|
|
42
42
|
require('../InlineWidget/InlineWidget.cjs');
|
|
43
|
+
require('../MenuList/Dropdown/Dropdown.cjs');
|
|
43
44
|
require('../../context/MockContext/MockContext.cjs');
|
|
44
45
|
require('../../context/CaptchaContext/CaptchaContext.cjs');
|
|
45
46
|
var usePromise = require('../../utils/hooks/usePromise/usePromise.cjs');
|
|
@@ -36,6 +36,7 @@ import '../Popper/PopperContext/PopperContext.js';
|
|
|
36
36
|
import 'formik';
|
|
37
37
|
import 'yup';
|
|
38
38
|
import '../InlineWidget/InlineWidget.js';
|
|
39
|
+
import '../MenuList/Dropdown/Dropdown.js';
|
|
39
40
|
import '../../context/MockContext/MockContext.js';
|
|
40
41
|
import '../../context/CaptchaContext/CaptchaContext.js';
|
|
41
42
|
import { usePromise } from '../../utils/hooks/usePromise/usePromise.js';
|
|
@@ -40,6 +40,7 @@ require('../../../Popper/PopperContext/PopperContext.cjs');
|
|
|
40
40
|
require('formik');
|
|
41
41
|
require('yup');
|
|
42
42
|
require('../../../InlineWidget/InlineWidget.cjs');
|
|
43
|
+
require('../../../MenuList/Dropdown/Dropdown.cjs');
|
|
43
44
|
var VerifiedEmailIcon = require('./components/VerifiedEmailIcon/VerifiedEmailIcon.cjs');
|
|
44
45
|
|
|
45
46
|
const UserProfileField = ({ name, label, value, }) => {
|
|
@@ -36,6 +36,7 @@ import '../../../Popper/PopperContext/PopperContext.js';
|
|
|
36
36
|
import 'formik';
|
|
37
37
|
import 'yup';
|
|
38
38
|
import '../../../InlineWidget/InlineWidget.js';
|
|
39
|
+
import '../../../MenuList/Dropdown/Dropdown.js';
|
|
39
40
|
import { VerifiedEmailIcon } from './components/VerifiedEmailIcon/VerifiedEmailIcon.js';
|
|
40
41
|
|
|
41
42
|
const UserProfileField = ({ name, label, value, }) => {
|
|
@@ -40,6 +40,7 @@ require('../../../Popper/PopperContext/PopperContext.cjs');
|
|
|
40
40
|
require('formik');
|
|
41
41
|
require('yup');
|
|
42
42
|
require('../../../InlineWidget/InlineWidget.cjs');
|
|
43
|
+
require('../../../MenuList/Dropdown/Dropdown.cjs');
|
|
43
44
|
|
|
44
45
|
const UserProfileSection = ({ title, children, }) => (jsxRuntime.jsxs("div", Object.assign({ className: 'user-profile-section' }, { children: [title && (jsxRuntime.jsx(Typography.Typography, Object.assign({ as: 'h6', color: 'secondary', weight: 'medium', variant: 'body_small', className: 'user-profile-section__title' }, { children: title }))), children] })));
|
|
45
46
|
|
|
@@ -36,6 +36,7 @@ import '../../../Popper/PopperContext/PopperContext.js';
|
|
|
36
36
|
import 'formik';
|
|
37
37
|
import 'yup';
|
|
38
38
|
import '../../../InlineWidget/InlineWidget.js';
|
|
39
|
+
import '../../../MenuList/Dropdown/Dropdown.js';
|
|
39
40
|
|
|
40
41
|
const UserProfileSection = ({ title, children, }) => (jsxs("div", Object.assign({ className: 'user-profile-section' }, { children: [title && (jsx(Typography, Object.assign({ as: 'h6', color: 'secondary', weight: 'medium', variant: 'body_small', className: 'user-profile-section__title' }, { children: title }))), children] })));
|
|
41
42
|
|
package/src/lib/components/UserProfile/parts/UserProfileSocialAccount/UserProfileSocialAccount.cjs
CHANGED
|
@@ -46,6 +46,7 @@ require('../../../Popper/PopperContext/PopperContext.cjs');
|
|
|
46
46
|
require('formik');
|
|
47
47
|
require('yup');
|
|
48
48
|
require('../../../InlineWidget/InlineWidget.cjs');
|
|
49
|
+
require('../../../MenuList/Dropdown/Dropdown.cjs');
|
|
49
50
|
var helpers = require('../../../../widgets/DynamicWidget/helpers/helpers.cjs');
|
|
50
51
|
var useUpdateUserProfileByJWTCallback = require('../../../../utils/hooks/useUpdateUserProfileByJWTCallback/useUpdateUserProfileByJWTCallback.cjs');
|
|
51
52
|
var ConnectedAccountAvatar = require('./components/ConnectedAccountAvatar/ConnectedAccountAvatar.cjs');
|
package/src/lib/components/UserProfile/parts/UserProfileSocialAccount/UserProfileSocialAccount.js
CHANGED
|
@@ -42,6 +42,7 @@ import '../../../Popper/PopperContext/PopperContext.js';
|
|
|
42
42
|
import 'formik';
|
|
43
43
|
import 'yup';
|
|
44
44
|
import '../../../InlineWidget/InlineWidget.js';
|
|
45
|
+
import '../../../MenuList/Dropdown/Dropdown.js';
|
|
45
46
|
import { capitalize } from '../../../../widgets/DynamicWidget/helpers/helpers.js';
|
|
46
47
|
import { useUpdateUserProfileByJWTCallback } from '../../../../utils/hooks/useUpdateUserProfileByJWTCallback/useUpdateUserProfileByJWTCallback.js';
|
|
47
48
|
import { ConnectedAccountAvatar } from './components/ConnectedAccountAvatar/ConnectedAccountAvatar.js';
|