@stridge/kit 0.1.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/dist/KitProvider.d.ts +91 -0
- package/dist/KitProvider.js +1 -0
- package/dist/_internal/deposit/driver/index.d.ts +5 -0
- package/dist/_internal/deposit/driver/index.js +1 -0
- package/dist/_internal/deposit/widgets/index.d.ts +11 -0
- package/dist/_internal/deposit/widgets/index.js +1 -0
- package/dist/_internal/drivers/stridge/index.d.ts +6 -0
- package/dist/_internal/drivers/stridge/index.js +1 -0
- package/dist/_internal/drivers/stridge-mock/index.d.ts +5 -0
- package/dist/_internal/drivers/stridge-mock/index.js +1 -0
- package/dist/_internal/index.d.ts +2 -0
- package/dist/_internal/index.js +1 -0
- package/dist/_internal/withdraw/driver/index.d.ts +6 -0
- package/dist/_internal/withdraw/driver/index.js +1 -0
- package/dist/_internal/withdraw/widgets/index.d.ts +5 -0
- package/dist/_internal/withdraw/widgets/index.js +1 -0
- package/dist/banners/index.d.ts +1 -0
- package/dist/banners/index.js +1 -0
- package/dist/banners/useBannerAck.d.ts +61 -0
- package/dist/banners/useBannerAck.js +1 -0
- package/dist/deposit/compound/index.d.ts +28 -0
- package/dist/deposit/compound/index.js +1 -0
- package/dist/deposit/dialog/index.d.ts +2 -0
- package/dist/deposit/dialog/index.js +1 -0
- package/dist/drivers/stridge/createStridgeDepositDriver.d.ts +29 -0
- package/dist/drivers/stridge/createStridgeDepositDriver.js +1 -0
- package/dist/drivers/stridge/createStridgeWithdrawDriver.d.ts +113 -0
- package/dist/drivers/stridge/createStridgeWithdrawDriver.js +1 -0
- package/dist/drivers/stridge/internal/encoding.js +1 -0
- package/dist/drivers/stridge/internal/env.js +1 -0
- package/dist/drivers/stridge/internal/metadata.js +1 -0
- package/dist/drivers/stridge/internal/pollOnce.js +1 -0
- package/dist/drivers/stridge/internal/signAndConfirm.js +1 -0
- package/dist/drivers/stridge/poll.js +1 -0
- package/dist/drivers/stridge/rpc.d.ts +77 -0
- package/dist/drivers/stridge/rpc.js +1 -0
- package/dist/drivers/stridge/types.d.ts +145 -0
- package/dist/drivers/stridge/types.js +1 -0
- package/dist/drivers/stridge/wagmiSigner.js +1 -0
- package/dist/drivers/stridge-mock/createStridgeMockDriver.d.ts +120 -0
- package/dist/drivers/stridge-mock/createStridgeMockDriver.js +1 -0
- package/dist/drivers/stridge-mock/createStridgeMockWithdrawDriver.d.ts +118 -0
- package/dist/drivers/stridge-mock/createStridgeMockWithdrawDriver.js +1 -0
- package/dist/drivers/stridge-mock/fixtures.d.ts +127 -0
- package/dist/drivers/stridge-mock/fixtures.js +1 -0
- package/dist/drivers/stridge-mock/store.js +1 -0
- package/dist/drivers/stridge-mock/triggers.d.ts +41 -0
- package/dist/flows/deposit/dialog/DepositBootstrapErrorState.js +1 -0
- package/dist/flows/deposit/dialog/DepositBootstrapErrorState.styles.js +1 -0
- package/dist/flows/deposit/dialog/DepositDialog.d.ts +112 -0
- package/dist/flows/deposit/dialog/DepositDialog.js +1 -0
- package/dist/flows/deposit/driver/context.d.ts +37 -0
- package/dist/flows/deposit/driver/context.js +1 -0
- package/dist/flows/deposit/driver/payloads.d.ts +342 -0
- package/dist/flows/deposit/driver/transformers/balanceToBalancesPayload.js +1 -0
- package/dist/flows/deposit/driver/transformers/quoteToPayload.js +1 -0
- package/dist/flows/deposit/driver/transformers/settlementToPayload.js +1 -0
- package/dist/flows/deposit/driver/transformers/startToAddressesPayload.js +1 -0
- package/dist/flows/deposit/driver/transformers/startToBrandPayload.js +1 -0
- package/dist/flows/deposit/driver/transformers/startToTargetPayload.js +1 -0
- package/dist/flows/deposit/driver/transformers/walletAddressToWalletPayload.js +1 -0
- package/dist/flows/deposit/driver/types.d.ts +177 -0
- package/dist/flows/deposit/orchestrator/controller.d.ts +11 -0
- package/dist/flows/deposit/orchestrator/controller.js +1 -0
- package/dist/flows/deposit/orchestrator/reducer.js +1 -0
- package/dist/flows/deposit/orchestrator/resolveAssetById.js +1 -0
- package/dist/flows/deposit/orchestrator/steps.d.ts +23 -0
- package/dist/flows/deposit/orchestrator/steps.js +1 -0
- package/dist/flows/deposit/orchestrator/types.d.ts +266 -0
- package/dist/flows/deposit/orchestrator/useDeposit.d.ts +35 -0
- package/dist/flows/deposit/orchestrator/useDeposit.js +1 -0
- package/dist/flows/deposit/widgets/amount-entry/AmountEntry.d.ts +35 -0
- package/dist/flows/deposit/widgets/amount-entry/AmountEntry.js +1 -0
- package/dist/flows/deposit/widgets/amount-entry/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/amount-entry/index.js +1 -0
- package/dist/flows/deposit/widgets/asset-picker/AssetPicker.d.ts +25 -0
- package/dist/flows/deposit/widgets/asset-picker/AssetPicker.js +1 -0
- package/dist/flows/deposit/widgets/asset-picker/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/asset-picker/index.js +1 -0
- package/dist/flows/deposit/widgets/confirm-deposit/ConfirmDeposit.d.ts +31 -0
- package/dist/flows/deposit/widgets/confirm-deposit/ConfirmDeposit.js +1 -0
- package/dist/flows/deposit/widgets/confirm-deposit/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/confirm-deposit/index.js +1 -0
- package/dist/flows/deposit/widgets/deposit/Deposit.d.ts +30 -0
- package/dist/flows/deposit/widgets/deposit/Deposit.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/Deposit.d.ts +51 -0
- package/dist/flows/deposit/widgets/deposit/compound/Deposit.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/Deposit.slots.d.ts +11 -0
- package/dist/flows/deposit/widgets/deposit/compound/Deposit.slots.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/Deposit.styles.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/components/Header.d.ts +15 -0
- package/dist/flows/deposit/widgets/deposit/compound/components/Header.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/components/Method.d.ts +32 -0
- package/dist/flows/deposit/widgets/deposit/compound/components/Method.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/components/Methods.d.ts +23 -0
- package/dist/flows/deposit/widgets/deposit/compound/components/Methods.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/context.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/index.d.ts +3 -0
- package/dist/flows/deposit/widgets/deposit/compound/index.js +1 -0
- package/dist/flows/deposit/widgets/deposit/compound/types.d.ts +129 -0
- package/dist/flows/deposit/widgets/deposit/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/deposit/index.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/DepositStatusBanner.d.ts +20 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/DepositStatusBanner.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/DepositStatusBanner.d.ts +102 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/DepositStatusBanner.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/DepositStatusBanner.slots.d.ts +20 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/DepositStatusBanner.slots.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/DepositStatusBanner.styles.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Body.d.ts +17 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Body.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Close.d.ts +13 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Close.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Detail.d.ts +14 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Detail.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Details.d.ts +20 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Details.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Footer.d.ts +17 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Footer.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Hero.d.ts +17 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Hero.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/PrimaryAction.d.ts +26 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/PrimaryAction.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Rows.d.ts +35 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Rows.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Toggle.d.ts +18 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Toggle.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/context.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/index.d.ts +3 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/index.js +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/compound/types.d.ts +188 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/deposit-status-banner/index.js +1 -0
- package/dist/flows/deposit/widgets/error-state/ErrorState.d.ts +30 -0
- package/dist/flows/deposit/widgets/error-state/ErrorState.js +1 -0
- package/dist/flows/deposit/widgets/error-state/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/error-state/index.js +1 -0
- package/dist/flows/deposit/widgets/processing-state/ProcessingState.d.ts +31 -0
- package/dist/flows/deposit/widgets/processing-state/ProcessingState.js +1 -0
- package/dist/flows/deposit/widgets/processing-state/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/processing-state/index.js +1 -0
- package/dist/flows/deposit/widgets/success-state/SuccessState.d.ts +30 -0
- package/dist/flows/deposit/widgets/success-state/SuccessState.js +1 -0
- package/dist/flows/deposit/widgets/success-state/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/success-state/index.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/TransferCrypto.d.ts +41 -0
- package/dist/flows/deposit/widgets/transfer-crypto/TransferCrypto.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/TransferCrypto.d.ts +56 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/TransferCrypto.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/TransferCrypto.slots.d.ts +15 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/TransferCrypto.slots.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/TransferCrypto.styles.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Address.d.ts +10 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Address.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Disclosure.d.ts +17 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Disclosure.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Header.d.ts +15 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Header.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/InfoTooltip.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/QrCode.d.ts +21 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/QrCode.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Selectors.d.ts +11 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Selectors.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Summary.d.ts +11 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Summary.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/context.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/index.d.ts +3 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/index.js +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/compound/types.d.ts +187 -0
- package/dist/flows/deposit/widgets/transfer-crypto/index.d.ts +1 -0
- package/dist/flows/deposit/widgets/transfer-crypto/index.js +1 -0
- package/dist/flows/shared/transformers/classifySettlementStatus.js +1 -0
- package/dist/flows/shared/transformers/computeQuoteAttrs.js +1 -0
- package/dist/flows/shared/transformers/parseIsoMs.js +1 -0
- package/dist/flows/shared/transformers/parseSmallestUnit.js +1 -0
- package/dist/flows/shared/transformers/pickRelevantSettlement.js +1 -0
- package/dist/flows/withdraw/dialog/WithdrawDialog.d.ts +103 -0
- package/dist/flows/withdraw/dialog/WithdrawDialog.js +1 -0
- package/dist/flows/withdraw/dialog/WithdrawDialogEventsContext.d.ts +36 -0
- package/dist/flows/withdraw/dialog/WithdrawDialogEventsContext.js +1 -0
- package/dist/flows/withdraw/driver/context.d.ts +24 -0
- package/dist/flows/withdraw/driver/context.js +1 -0
- package/dist/flows/withdraw/driver/dto.d.ts +41 -0
- package/dist/flows/withdraw/driver/payloads.d.ts +206 -0
- package/dist/flows/withdraw/driver/transformers/balanceToWithdrawableBalancesPayload.js +1 -0
- package/dist/flows/withdraw/driver/transformers/quoteToWithdrawalPayload.js +1 -0
- package/dist/flows/withdraw/driver/transformers/settlementToWithdrawalPayload.js +1 -0
- package/dist/flows/withdraw/driver/transformers/supportedAssetsToReceiveOptionsPayload.js +1 -0
- package/dist/flows/withdraw/driver/types.d.ts +133 -0
- package/dist/flows/withdraw/orchestrator/controller.d.ts +11 -0
- package/dist/flows/withdraw/orchestrator/controller.js +1 -0
- package/dist/flows/withdraw/orchestrator/index.d.ts +4 -0
- package/dist/flows/withdraw/orchestrator/index.js +1 -0
- package/dist/flows/withdraw/orchestrator/reducer.js +1 -0
- package/dist/flows/withdraw/orchestrator/types.d.ts +156 -0
- package/dist/flows/withdraw/orchestrator/useWithdraw.d.ts +23 -0
- package/dist/flows/withdraw/orchestrator/useWithdraw.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-error/WithdrawError.d.ts +22 -0
- package/dist/flows/withdraw/widgets/withdraw-error/WithdrawError.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-error/index.d.ts +1 -0
- package/dist/flows/withdraw/widgets/withdraw-error/index.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/WithdrawForm.d.ts +29 -0
- package/dist/flows/withdraw/widgets/withdraw-form/WithdrawForm.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/WithdrawForm.d.ts +55 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/WithdrawForm.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/WithdrawForm.slots.d.ts +31 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/WithdrawForm.slots.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/WithdrawForm.styles.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/AmountField.d.ts +12 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/AmountField.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Body.d.ts +20 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Body.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/BreakdownCard.d.ts +17 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/BreakdownCard.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Footer.d.ts +18 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Footer.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Header.d.ts +21 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Header.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/InfoTooltip.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/ReceiveSelectors.d.ts +13 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/ReceiveSelectors.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/RecipientField.d.ts +19 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/components/RecipientField.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/context.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/index.d.ts +3 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/index.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/compound/types.d.ts +149 -0
- package/dist/flows/withdraw/widgets/withdraw-form/index.d.ts +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/index.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-form/validation.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-in-progress/WithdrawInProgress.d.ts +19 -0
- package/dist/flows/withdraw/widgets/withdraw-in-progress/WithdrawInProgress.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-in-progress/index.d.ts +1 -0
- package/dist/flows/withdraw/widgets/withdraw-in-progress/index.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-success/WithdrawSuccess.d.ts +20 -0
- package/dist/flows/withdraw/widgets/withdraw-success/WithdrawSuccess.js +1 -0
- package/dist/flows/withdraw/widgets/withdraw-success/index.d.ts +1 -0
- package/dist/flows/withdraw/widgets/withdraw-success/index.js +1 -0
- package/dist/format/index.d.ts +10 -0
- package/dist/format/index.js +1 -0
- package/dist/i18n/index.d.ts +9 -0
- package/dist/i18n/index.js +1 -0
- package/dist/i18n/locales/ar.d.ts +6 -0
- package/dist/i18n/locales/ar.js +1 -0
- package/dist/i18n/locales/es.d.ts +6 -0
- package/dist/i18n/locales/es.js +1 -0
- package/dist/icons/index.d.ts +27 -0
- package/dist/icons/index.js +1 -0
- package/dist/index.d.ts +26 -0
- package/dist/index.js +1 -0
- package/dist/kit/package.js +1 -0
- package/dist/scope/KitPortalScope.d.ts +31 -0
- package/dist/scope/KitPortalScope.js +1 -0
- package/dist/scope/KitScope.d.ts +63 -0
- package/dist/scope/KitScope.js +1 -0
- package/dist/scope/KitScope.slots.js +1 -0
- package/dist/scope/context.d.ts +67 -0
- package/dist/scope/context.js +1 -0
- package/dist/scope/index.d.ts +3 -0
- package/dist/scope/index.js +1 -0
- package/dist/shared/chains/index.d.ts +40 -0
- package/dist/shared/chains/index.js +1 -0
- package/dist/shared/constants/brand-links.js +1 -0
- package/dist/shared/dialog/DialogShell.d.ts +63 -0
- package/dist/shared/dialog/DialogShell.js +1 -0
- package/dist/shared/dialog/Frame.js +1 -0
- package/dist/shared/dialog/GatewayKitRoot.js +1 -0
- package/dist/shared/dialog/StepTransition.js +1 -0
- package/dist/shared/dialog/useDirectionalChevronTransform.js +1 -0
- package/dist/shared/driver/types.d.ts +69 -0
- package/dist/shared/error-handling/components/GatewayKitBoundary.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/GatewayKitErrorCard.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/GatewayKitErrorCard.slots.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/GatewayKitErrorCard.styles.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/Action.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/Actions.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/CodeSample.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/Description.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/DetailRow.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/Guidance.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/Section.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/TechnicalDetails.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/TechnicalDetailsToggle.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/components/Title.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/context.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitErrorCard/index.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitRecoveryError.js +1 -0
- package/dist/shared/error-handling/components/GatewayKitSetupError.js +1 -0
- package/dist/shared/error-handling/constants/guides.js +1 -0
- package/dist/shared/error-handling/constants/snippets.js +6 -0
- package/dist/shared/error-handling/index.js +1 -0
- package/dist/shared/error-handling/lib/isWagmiProviderMissingError.js +1 -0
- package/dist/shared/format/formatDurationCoarse.d.ts +29 -0
- package/dist/shared/format/formatDurationCoarse.js +1 -0
- package/dist/shared/format/formatDurationCompact.d.ts +28 -0
- package/dist/shared/format/formatDurationCompact.js +1 -0
- package/dist/shared/format/formatNetworkName.d.ts +27 -0
- package/dist/shared/format/formatNetworkName.js +1 -0
- package/dist/shared/format/formatPercent.d.ts +23 -0
- package/dist/shared/format/formatPercent.js +1 -0
- package/dist/shared/format/formatTimestamp.d.ts +22 -0
- package/dist/shared/format/formatTimestamp.js +1 -0
- package/dist/shared/format/formatTokenAmount.d.ts +46 -0
- package/dist/shared/format/formatTokenAmount.js +1 -0
- package/dist/shared/format/formatUsd.d.ts +41 -0
- package/dist/shared/format/formatUsd.js +1 -0
- package/dist/shared/format/shortenAddress.d.ts +27 -0
- package/dist/shared/format/shortenAddress.js +1 -0
- package/dist/shared/format/types.d.ts +33 -0
- package/dist/shared/i18n/KitI18nProvider.d.ts +23 -0
- package/dist/shared/i18n/KitI18nProvider.js +1 -0
- package/dist/shared/i18n/Trans.d.ts +39 -0
- package/dist/shared/i18n/Trans.js +1 -0
- package/dist/shared/i18n/createKitI18n.d.ts +41 -0
- package/dist/shared/i18n/createKitI18n.js +1 -0
- package/dist/shared/i18n/defaultI18n.js +1 -0
- package/dist/shared/i18n/getLocaleDirection.d.ts +24 -0
- package/dist/shared/i18n/getLocaleDirection.js +1 -0
- package/dist/shared/i18n/locales.d.ts +31 -0
- package/dist/shared/i18n/locales.js +1 -0
- package/dist/shared/i18n/useKitI18n.d.ts +14 -0
- package/dist/shared/i18n/useKitI18n.js +1 -0
- package/dist/shared/i18n/useLingui.d.ts +35 -0
- package/dist/shared/i18n/useLingui.js +1 -0
- package/dist/shared/i18n/useT.d.ts +25 -0
- package/dist/shared/i18n/useT.js +1 -0
- package/dist/shared/icons/AlertIcon.d.ts +12 -0
- package/dist/shared/icons/AlertIcon.js +1 -0
- package/dist/shared/icons/ArrowDownIcon.d.ts +7 -0
- package/dist/shared/icons/ArrowDownIcon.js +1 -0
- package/dist/shared/icons/ArrowRightIcon.d.ts +7 -0
- package/dist/shared/icons/ArrowRightIcon.js +1 -0
- package/dist/shared/icons/ArrowRightLeftIcon.d.ts +7 -0
- package/dist/shared/icons/ArrowRightLeftIcon.js +1 -0
- package/dist/shared/icons/CheckIcon.d.ts +7 -0
- package/dist/shared/icons/CheckIcon.js +1 -0
- package/dist/shared/icons/ChevronDownIcon.d.ts +7 -0
- package/dist/shared/icons/ChevronDownIcon.js +1 -0
- package/dist/shared/icons/ChevronLeftIcon.d.ts +7 -0
- package/dist/shared/icons/ChevronLeftIcon.js +1 -0
- package/dist/shared/icons/ChevronRightIcon.d.ts +7 -0
- package/dist/shared/icons/ChevronRightIcon.js +1 -0
- package/dist/shared/icons/ChevronUpIcon.d.ts +7 -0
- package/dist/shared/icons/ChevronUpIcon.js +1 -0
- package/dist/shared/icons/CircleArrowUpIcon.d.ts +7 -0
- package/dist/shared/icons/CircleArrowUpIcon.js +1 -0
- package/dist/shared/icons/CircleHelpIcon.d.ts +7 -0
- package/dist/shared/icons/CircleHelpIcon.js +1 -0
- package/dist/shared/icons/ClockIcon.d.ts +7 -0
- package/dist/shared/icons/ClockIcon.js +1 -0
- package/dist/shared/icons/CopyIcon.d.ts +7 -0
- package/dist/shared/icons/CopyIcon.js +1 -0
- package/dist/shared/icons/ExternalLinkIcon.d.ts +7 -0
- package/dist/shared/icons/ExternalLinkIcon.js +1 -0
- package/dist/shared/icons/InfoIcon.d.ts +7 -0
- package/dist/shared/icons/InfoIcon.js +1 -0
- package/dist/shared/icons/LoaderIcon.d.ts +7 -0
- package/dist/shared/icons/LoaderIcon.js +1 -0
- package/dist/shared/icons/MailIcon.d.ts +7 -0
- package/dist/shared/icons/MailIcon.js +1 -0
- package/dist/shared/icons/PackageIcon.d.ts +7 -0
- package/dist/shared/icons/PackageIcon.js +1 -0
- package/dist/shared/icons/QrCodeIcon.d.ts +7 -0
- package/dist/shared/icons/QrCodeIcon.js +1 -0
- package/dist/shared/icons/WalletIcon.d.ts +7 -0
- package/dist/shared/icons/WalletIcon.js +1 -0
- package/dist/shared/icons/XIcon.d.ts +7 -0
- package/dist/shared/icons/XIcon.js +1 -0
- package/dist/shared/icons/exchanges/BinanceIcon.d.ts +7 -0
- package/dist/shared/icons/exchanges/BinanceIcon.js +1 -0
- package/dist/shared/icons/exchanges/CoinbaseIcon.d.ts +7 -0
- package/dist/shared/icons/exchanges/CoinbaseIcon.js +1 -0
- package/dist/shared/icons/exchanges/KrakenIcon.d.ts +7 -0
- package/dist/shared/icons/exchanges/KrakenIcon.js +1 -0
- package/dist/shared/icons/exchanges/OkxIcon.d.ts +7 -0
- package/dist/shared/icons/exchanges/OkxIcon.js +1 -0
- package/dist/shared/icons/exchanges/RobinhoodIcon.d.ts +7 -0
- package/dist/shared/icons/exchanges/RobinhoodIcon.js +1 -0
- package/dist/shared/icons/exchanges/index.d.ts +5 -0
- package/dist/shared/icons/exchanges/index.js +1 -0
- package/dist/shared/orchestrator/failureReason.js +1 -0
- package/dist/shared/orchestrator/index.js +1 -0
- package/dist/shared/orchestrator/toFailure.js +1 -0
- package/dist/shared/orchestrator/types.d.ts +20 -0
- package/dist/shared/orchestrator/useDialogLifecycle.js +1 -0
- package/dist/shared/orchestrator/useDriverSettlementListener.js +1 -0
- package/dist/shared/orchestrator/useEffectiveState.js +1 -0
- package/dist/shared/orchestrator/useSettlementWatcher.js +1 -0
- package/dist/shared/orchestrator/userRejection.js +1 -0
- package/dist/shared/primitives/TxHashValue/TxHashValue.d.ts +20 -0
- package/dist/shared/primitives/TxHashValue/TxHashValue.js +1 -0
- package/dist/shared/primitives/TxHashValue/TxHashValue.slots.js +1 -0
- package/dist/shared/primitives/TxHashValue/TxHashValue.styles.js +1 -0
- package/dist/shared/primitives/TxHashValue/index.d.ts +2 -0
- package/dist/shared/primitives/TxHashValue/index.js +1 -0
- package/dist/shared/primitives/TxHashValue/types.d.ts +25 -0
- package/dist/shared/primitives/WalletValue/WalletValue.d.ts +40 -0
- package/dist/shared/primitives/WalletValue/WalletValue.js +1 -0
- package/dist/shared/primitives/WalletValue/index.d.ts +1 -0
- package/dist/shared/primitives/WalletValue/index.js +1 -0
- package/dist/shared/quote/index.js +1 -0
- package/dist/shared/quote/useQuoteCountdown.js +1 -0
- package/dist/shared/styles/tokens.stylex.js +1 -0
- package/dist/shared/ui/Alert/Alert.d.ts +105 -0
- package/dist/shared/ui/Alert/Alert.js +1 -0
- package/dist/shared/ui/Alert/Alert.slots.d.ts +10 -0
- package/dist/shared/ui/Alert/Alert.slots.js +1 -0
- package/dist/shared/ui/Alert/Alert.styles.js +1 -0
- package/dist/shared/ui/Alert/index.d.ts +2 -0
- package/dist/shared/ui/Alert/index.js +1 -0
- package/dist/shared/ui/AmountInput/AmountInput.d.ts +132 -0
- package/dist/shared/ui/AmountInput/AmountInput.js +1 -0
- package/dist/shared/ui/AmountInput/AmountInput.slots.d.ts +11 -0
- package/dist/shared/ui/AmountInput/AmountInput.slots.js +1 -0
- package/dist/shared/ui/AmountInput/AmountInput.styles.js +1 -0
- package/dist/shared/ui/AmountInput/attachInputNormalization.js +1 -0
- package/dist/shared/ui/AmountInput/context.js +1 -0
- package/dist/shared/ui/AmountInput/index.d.ts +3 -0
- package/dist/shared/ui/AmountInput/index.js +1 -0
- package/dist/shared/ui/AmountInput/useAutoShrinkFontSize.js +14 -0
- package/dist/shared/ui/AmountInput/utils.d.ts +12 -0
- package/dist/shared/ui/AmountInput/utils.js +1 -0
- package/dist/shared/ui/Badge/Badge.d.ts +89 -0
- package/dist/shared/ui/Badge/Badge.js +1 -0
- package/dist/shared/ui/Badge/Badge.slots.d.ts +7 -0
- package/dist/shared/ui/Badge/Badge.slots.js +1 -0
- package/dist/shared/ui/Badge/Badge.styles.js +1 -0
- package/dist/shared/ui/Badge/index.d.ts +2 -0
- package/dist/shared/ui/Badge/index.js +1 -0
- package/dist/shared/ui/Button/Button.d.ts +82 -0
- package/dist/shared/ui/Button/Button.js +1 -0
- package/dist/shared/ui/Button/Button.slots.d.ts +7 -0
- package/dist/shared/ui/Button/Button.slots.js +1 -0
- package/dist/shared/ui/Button/Button.styles.js +1 -0
- package/dist/shared/ui/Button/index.d.ts +2 -0
- package/dist/shared/ui/Button/index.js +1 -0
- package/dist/shared/ui/Card/Card.d.ts +93 -0
- package/dist/shared/ui/Card/Card.js +1 -0
- package/dist/shared/ui/Card/Card.slots.d.ts +10 -0
- package/dist/shared/ui/Card/Card.slots.js +1 -0
- package/dist/shared/ui/Card/Card.styles.js +1 -0
- package/dist/shared/ui/Card/index.d.ts +2 -0
- package/dist/shared/ui/Card/index.js +1 -0
- package/dist/shared/ui/Collapsible/Collapsible.d.ts +57 -0
- package/dist/shared/ui/Collapsible/Collapsible.js +1 -0
- package/dist/shared/ui/Collapsible/Collapsible.slots.d.ts +10 -0
- package/dist/shared/ui/Collapsible/Collapsible.slots.js +1 -0
- package/dist/shared/ui/Collapsible/Collapsible.styles.js +1 -0
- package/dist/shared/ui/Collapsible/index.d.ts +2 -0
- package/dist/shared/ui/Collapsible/index.js +1 -0
- package/dist/shared/ui/Details/Details.d.ts +76 -0
- package/dist/shared/ui/Details/Details.js +1 -0
- package/dist/shared/ui/Details/Details.slots.d.ts +9 -0
- package/dist/shared/ui/Details/Details.slots.js +1 -0
- package/dist/shared/ui/Details/Details.styles.js +1 -0
- package/dist/shared/ui/Details/index.d.ts +2 -0
- package/dist/shared/ui/Details/index.js +1 -0
- package/dist/shared/ui/Dialog/Dialog.d.ts +147 -0
- package/dist/shared/ui/Dialog/Dialog.js +1 -0
- package/dist/shared/ui/Dialog/Dialog.slots.d.ts +17 -0
- package/dist/shared/ui/Dialog/Dialog.slots.js +1 -0
- package/dist/shared/ui/Dialog/Dialog.styles.js +1 -0
- package/dist/shared/ui/Dialog/index.d.ts +2 -0
- package/dist/shared/ui/Dialog/index.js +1 -0
- package/dist/shared/ui/ExternalLink/ExternalLink.d.ts +41 -0
- package/dist/shared/ui/ExternalLink/ExternalLink.js +1 -0
- package/dist/shared/ui/ExternalLink/ExternalLink.slots.d.ts +7 -0
- package/dist/shared/ui/ExternalLink/ExternalLink.slots.js +1 -0
- package/dist/shared/ui/ExternalLink/ExternalLink.styles.js +1 -0
- package/dist/shared/ui/ExternalLink/index.d.ts +2 -0
- package/dist/shared/ui/ExternalLink/index.js +1 -0
- package/dist/shared/ui/ExternalLink/toSafeHref.js +1 -0
- package/dist/shared/ui/Field/Field.d.ts +185 -0
- package/dist/shared/ui/Field/Field.js +1 -0
- package/dist/shared/ui/Field/Field.slots.d.ts +21 -0
- package/dist/shared/ui/Field/Field.slots.js +1 -0
- package/dist/shared/ui/Field/Field.styles.js +1 -0
- package/dist/shared/ui/Field/index.d.ts +2 -0
- package/dist/shared/ui/Field/index.js +1 -0
- package/dist/shared/ui/IconButton/IconButton.d.ts +48 -0
- package/dist/shared/ui/IconButton/IconButton.js +1 -0
- package/dist/shared/ui/IconButton/IconButton.slots.d.ts +7 -0
- package/dist/shared/ui/IconButton/IconButton.slots.js +1 -0
- package/dist/shared/ui/IconButton/IconButton.styles.js +1 -0
- package/dist/shared/ui/IconButton/index.d.ts +2 -0
- package/dist/shared/ui/IconButton/index.js +1 -0
- package/dist/shared/ui/Image/Image.d.ts +43 -0
- package/dist/shared/ui/Image/Image.js +1 -0
- package/dist/shared/ui/Image/Image.slots.d.ts +14 -0
- package/dist/shared/ui/Image/Image.slots.js +1 -0
- package/dist/shared/ui/Image/Image.styles.js +1 -0
- package/dist/shared/ui/Image/index.d.ts +3 -0
- package/dist/shared/ui/Image/index.js +1 -0
- package/dist/shared/ui/Image/types.d.ts +131 -0
- package/dist/shared/ui/InputGroup/InputGroup.d.ts +129 -0
- package/dist/shared/ui/InputGroup/InputGroup.js +1 -0
- package/dist/shared/ui/InputGroup/InputGroup.slots.d.ts +16 -0
- package/dist/shared/ui/InputGroup/InputGroup.slots.js +1 -0
- package/dist/shared/ui/InputGroup/InputGroup.styles.js +1 -0
- package/dist/shared/ui/InputGroup/index.d.ts +2 -0
- package/dist/shared/ui/InputGroup/index.js +1 -0
- package/dist/shared/ui/LtrAtom/LtrAtom.d.ts +31 -0
- package/dist/shared/ui/LtrAtom/LtrAtom.js +1 -0
- package/dist/shared/ui/LtrAtom/index.d.ts +1 -0
- package/dist/shared/ui/LtrAtom/index.js +1 -0
- package/dist/shared/ui/ScrollArea/ScrollArea.d.ts +86 -0
- package/dist/shared/ui/ScrollArea/ScrollArea.js +1 -0
- package/dist/shared/ui/ScrollArea/ScrollArea.slots.d.ts +12 -0
- package/dist/shared/ui/ScrollArea/ScrollArea.slots.js +1 -0
- package/dist/shared/ui/ScrollArea/ScrollArea.styles.js +1 -0
- package/dist/shared/ui/ScrollArea/index.d.ts +2 -0
- package/dist/shared/ui/ScrollArea/index.js +1 -0
- package/dist/shared/ui/Select/Select.context.d.ts +10 -0
- package/dist/shared/ui/Select/Select.context.js +1 -0
- package/dist/shared/ui/Select/Select.d.ts +243 -0
- package/dist/shared/ui/Select/Select.js +1 -0
- package/dist/shared/ui/Select/Select.slots.d.ts +20 -0
- package/dist/shared/ui/Select/Select.slots.js +1 -0
- package/dist/shared/ui/Select/Select.styles.js +1 -0
- package/dist/shared/ui/Select/index.d.ts +3 -0
- package/dist/shared/ui/Select/index.js +1 -0
- package/dist/shared/ui/SelectableTile/SelectableTile.d.ts +83 -0
- package/dist/shared/ui/SelectableTile/SelectableTile.js +1 -0
- package/dist/shared/ui/SelectableTile/SelectableTile.slots.d.ts +7 -0
- package/dist/shared/ui/SelectableTile/SelectableTile.slots.js +1 -0
- package/dist/shared/ui/SelectableTile/SelectableTile.styles.js +1 -0
- package/dist/shared/ui/SelectableTile/SelectableTileGroup.d.ts +82 -0
- package/dist/shared/ui/SelectableTile/SelectableTileGroup.js +1 -0
- package/dist/shared/ui/SelectableTile/index.d.ts +3 -0
- package/dist/shared/ui/SelectableTile/index.js +1 -0
- package/dist/shared/ui/Skeleton/Skeleton.d.ts +41 -0
- package/dist/shared/ui/Skeleton/Skeleton.js +1 -0
- package/dist/shared/ui/Skeleton/Skeleton.slots.d.ts +7 -0
- package/dist/shared/ui/Skeleton/Skeleton.slots.js +1 -0
- package/dist/shared/ui/Skeleton/Skeleton.styles.js +1 -0
- package/dist/shared/ui/Skeleton/index.d.ts +2 -0
- package/dist/shared/ui/Skeleton/index.js +1 -0
- package/dist/shared/ui/Text/Text.d.ts +87 -0
- package/dist/shared/ui/Text/Text.js +1 -0
- package/dist/shared/ui/Text/Text.slots.d.ts +7 -0
- package/dist/shared/ui/Text/Text.slots.js +1 -0
- package/dist/shared/ui/Text/Text.styles.js +1 -0
- package/dist/shared/ui/Text/index.d.ts +2 -0
- package/dist/shared/ui/Text/index.js +1 -0
- package/dist/shared/ui/TokenLogo/TokenLogo.d.ts +41 -0
- package/dist/shared/ui/TokenLogo/TokenLogo.js +1 -0
- package/dist/shared/ui/TokenLogo/index.d.ts +2 -0
- package/dist/shared/ui/TokenLogo/index.js +1 -0
- package/dist/shared/ui/TokenLogo/types.d.ts +64 -0
- package/dist/shared/ui/Tooltip/Tooltip.d.ts +171 -0
- package/dist/shared/ui/Tooltip/Tooltip.js +1 -0
- package/dist/shared/ui/Tooltip/Tooltip.slots.d.ts +11 -0
- package/dist/shared/ui/Tooltip/Tooltip.slots.js +1 -0
- package/dist/shared/ui/Tooltip/Tooltip.styles.js +1 -0
- package/dist/shared/ui/Tooltip/index.d.ts +2 -0
- package/dist/shared/ui/Tooltip/index.js +1 -0
- package/dist/shared/ui/WalletRow/WalletRow.d.ts +55 -0
- package/dist/shared/ui/WalletRow/WalletRow.js +1 -0
- package/dist/shared/ui/WalletRow/WalletRow.slots.d.ts +7 -0
- package/dist/shared/ui/WalletRow/WalletRow.slots.js +1 -0
- package/dist/shared/ui/WalletRow/WalletRow.styles.js +1 -0
- package/dist/shared/ui/WalletRow/index.d.ts +2 -0
- package/dist/shared/ui/WalletRow/index.js +1 -0
- package/dist/shared/utils/explorers.js +1 -0
- package/dist/shared/utils/joinClassNames.js +1 -0
- package/dist/shared/utils/logos/api.d.ts +54 -0
- package/dist/shared/utils/logos/api.js +1 -0
- package/dist/shared/utils/logos/chains.d.ts +32 -0
- package/dist/shared/utils/logos/chains.js +1 -0
- package/dist/shared/utils/logos/conventionUrls.js +1 -0
- package/dist/shared/utils/logos/index.js +1 -0
- package/dist/shared/utils/logos/resolveLogoSrc.js +1 -0
- package/dist/shared/utils/logos/types.d.ts +62 -0
- package/dist/shared/utils/mergeClassName.js +1 -0
- package/dist/shared/utils/mergeStyle.js +1 -0
- package/dist/shared/wallet/resolveSupportedChainIds.js +1 -0
- package/dist/shared/wallet/resolveSupportedChains.js +1 -0
- package/dist/shared/wallet/types.d.ts +103 -0
- package/dist/shared/wallet/useWalletState.d.ts +21 -0
- package/dist/shared/wallet/useWalletState.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/AmountEntry.d.ts +59 -0
- package/dist/shared/widgets/amount-entry/compound/AmountEntry.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/AmountEntry.slots.d.ts +15 -0
- package/dist/shared/widgets/amount-entry/compound/AmountEntry.slots.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/AmountEntry.styles.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Flow.d.ts +14 -0
- package/dist/shared/widgets/amount-entry/compound/components/Flow.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Footer.d.ts +22 -0
- package/dist/shared/widgets/amount-entry/compound/components/Footer.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Header.d.ts +15 -0
- package/dist/shared/widgets/amount-entry/compound/components/Header.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/Hero.d.ts +22 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/Hero.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/StaticBand.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/SwapBackdrop.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/index.d.ts +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/index.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/transitions.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/useSwapState.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Hero/utils.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/components/Pills.d.ts +22 -0
- package/dist/shared/widgets/amount-entry/compound/components/Pills.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/context.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/index.d.ts +3 -0
- package/dist/shared/widgets/amount-entry/compound/index.js +1 -0
- package/dist/shared/widgets/amount-entry/compound/types.d.ts +224 -0
- package/dist/shared/widgets/asset-descriptor.d.ts +27 -0
- package/dist/shared/widgets/asset-descriptor.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/AssetPicker.d.ts +51 -0
- package/dist/shared/widgets/asset-picker/compound/AssetPicker.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/AssetPicker.slots.d.ts +11 -0
- package/dist/shared/widgets/asset-picker/compound/AssetPicker.slots.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/AssetPicker.styles.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/components/Asset.d.ts +30 -0
- package/dist/shared/widgets/asset-picker/compound/components/Asset.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/components/Footer.d.ts +16 -0
- package/dist/shared/widgets/asset-picker/compound/components/Footer.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/components/Header.d.ts +19 -0
- package/dist/shared/widgets/asset-picker/compound/components/Header.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/components/List.d.ts +22 -0
- package/dist/shared/widgets/asset-picker/compound/components/List.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/context.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/index.d.ts +3 -0
- package/dist/shared/widgets/asset-picker/compound/index.js +1 -0
- package/dist/shared/widgets/asset-picker/compound/types.d.ts +212 -0
- package/dist/shared/widgets/confirm-transfer/compound/ConfirmTransfer.d.ts +64 -0
- package/dist/shared/widgets/confirm-transfer/compound/ConfirmTransfer.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/ConfirmTransfer.slots.d.ts +16 -0
- package/dist/shared/widgets/confirm-transfer/compound/ConfirmTransfer.slots.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/ConfirmTransfer.styles.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Amounts.d.ts +15 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Amounts.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Breakdown.d.ts +17 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Breakdown.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Disclaimer.d.ts +15 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Disclaimer.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Footer.d.ts +26 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Footer.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Header.d.ts +13 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Header.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Hero.d.ts +16 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Hero.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Meta.d.ts +16 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/Meta.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/QuoteTimer.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/components/splitAmount.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/context.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/index.d.ts +3 -0
- package/dist/shared/widgets/confirm-transfer/compound/index.js +1 -0
- package/dist/shared/widgets/confirm-transfer/compound/types.d.ts +338 -0
- package/dist/shared/widgets/error-state/compound/ErrorState.d.ts +96 -0
- package/dist/shared/widgets/error-state/compound/ErrorState.js +1 -0
- package/dist/shared/widgets/error-state/compound/ErrorState.slots.d.ts +18 -0
- package/dist/shared/widgets/error-state/compound/ErrorState.slots.js +1 -0
- package/dist/shared/widgets/error-state/compound/ErrorState.styles.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/Actions.d.ts +17 -0
- package/dist/shared/widgets/error-state/compound/components/Actions.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/AssetValue.d.ts +20 -0
- package/dist/shared/widgets/error-state/compound/components/AssetValue.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/Detail.d.ts +14 -0
- package/dist/shared/widgets/error-state/compound/components/Detail.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/Details.d.ts +12 -0
- package/dist/shared/widgets/error-state/compound/components/Details.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/DisclosureChevron.d.ts +11 -0
- package/dist/shared/widgets/error-state/compound/components/DisclosureChevron.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/Header.d.ts +13 -0
- package/dist/shared/widgets/error-state/compound/components/Header.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/HelpInfo.d.ts +10 -0
- package/dist/shared/widgets/error-state/compound/components/HelpInfo.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/Hero.d.ts +9 -0
- package/dist/shared/widgets/error-state/compound/components/Hero.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/MoreDetails.d.ts +18 -0
- package/dist/shared/widgets/error-state/compound/components/MoreDetails.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/Rows.d.ts +57 -0
- package/dist/shared/widgets/error-state/compound/components/Rows.js +1 -0
- package/dist/shared/widgets/error-state/compound/components/StatusValue.d.ts +14 -0
- package/dist/shared/widgets/error-state/compound/components/StatusValue.js +1 -0
- package/dist/shared/widgets/error-state/compound/context.js +1 -0
- package/dist/shared/widgets/error-state/compound/index.d.ts +3 -0
- package/dist/shared/widgets/error-state/compound/index.js +1 -0
- package/dist/shared/widgets/error-state/compound/types.d.ts +291 -0
- package/dist/shared/widgets/processing-state/compound/ProcessingState.d.ts +77 -0
- package/dist/shared/widgets/processing-state/compound/ProcessingState.js +1 -0
- package/dist/shared/widgets/processing-state/compound/ProcessingState.slots.d.ts +15 -0
- package/dist/shared/widgets/processing-state/compound/ProcessingState.slots.js +1 -0
- package/dist/shared/widgets/processing-state/compound/ProcessingState.styles.js +1 -0
- package/dist/shared/widgets/processing-state/compound/components/Actions.d.ts +17 -0
- package/dist/shared/widgets/processing-state/compound/components/Actions.js +1 -0
- package/dist/shared/widgets/processing-state/compound/components/Detail.d.ts +14 -0
- package/dist/shared/widgets/processing-state/compound/components/Detail.js +1 -0
- package/dist/shared/widgets/processing-state/compound/components/Details.d.ts +12 -0
- package/dist/shared/widgets/processing-state/compound/components/Details.js +1 -0
- package/dist/shared/widgets/processing-state/compound/components/Header.d.ts +15 -0
- package/dist/shared/widgets/processing-state/compound/components/Header.js +1 -0
- package/dist/shared/widgets/processing-state/compound/components/Hero.d.ts +16 -0
- package/dist/shared/widgets/processing-state/compound/components/Hero.js +1 -0
- package/dist/shared/widgets/processing-state/compound/components/Rows.d.ts +36 -0
- package/dist/shared/widgets/processing-state/compound/components/Rows.js +1 -0
- package/dist/shared/widgets/processing-state/compound/components/StatusPill.d.ts +13 -0
- package/dist/shared/widgets/processing-state/compound/components/StatusPill.js +1 -0
- package/dist/shared/widgets/processing-state/compound/context.js +1 -0
- package/dist/shared/widgets/processing-state/compound/index.d.ts +3 -0
- package/dist/shared/widgets/processing-state/compound/index.js +1 -0
- package/dist/shared/widgets/processing-state/compound/types.d.ts +216 -0
- package/dist/shared/widgets/success-state/compound/SuccessState.d.ts +105 -0
- package/dist/shared/widgets/success-state/compound/SuccessState.js +1 -0
- package/dist/shared/widgets/success-state/compound/SuccessState.slots.d.ts +21 -0
- package/dist/shared/widgets/success-state/compound/SuccessState.slots.js +1 -0
- package/dist/shared/widgets/success-state/compound/SuccessState.styles.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/Actions.d.ts +18 -0
- package/dist/shared/widgets/success-state/compound/components/Actions.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/AssetValue.d.ts +18 -0
- package/dist/shared/widgets/success-state/compound/components/AssetValue.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/Detail.d.ts +18 -0
- package/dist/shared/widgets/success-state/compound/components/Detail.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/Details.d.ts +16 -0
- package/dist/shared/widgets/success-state/compound/components/Details.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/Header.d.ts +13 -0
- package/dist/shared/widgets/success-state/compound/components/Header.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/Headline.d.ts +16 -0
- package/dist/shared/widgets/success-state/compound/components/Headline.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/Hero.d.ts +10 -0
- package/dist/shared/widgets/success-state/compound/components/Hero.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/MoreDetails.d.ts +19 -0
- package/dist/shared/widgets/success-state/compound/components/MoreDetails.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/RouteValue.d.ts +15 -0
- package/dist/shared/widgets/success-state/compound/components/RouteValue.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/Rows.d.ts +69 -0
- package/dist/shared/widgets/success-state/compound/components/Rows.js +1 -0
- package/dist/shared/widgets/success-state/compound/components/StatusPill.d.ts +13 -0
- package/dist/shared/widgets/success-state/compound/components/StatusPill.js +1 -0
- package/dist/shared/widgets/success-state/compound/context.js +1 -0
- package/dist/shared/widgets/success-state/compound/index.d.ts +3 -0
- package/dist/shared/widgets/success-state/compound/index.js +1 -0
- package/dist/shared/widgets/success-state/compound/types.d.ts +307 -0
- package/dist/storage/adapters.d.ts +29 -0
- package/dist/storage/adapters.js +1 -0
- package/dist/storage/context.d.ts +62 -0
- package/dist/storage/context.js +1 -0
- package/dist/storage/createKitStorage.d.ts +45 -0
- package/dist/storage/createKitStorage.js +1 -0
- package/dist/storage/index.d.ts +4 -0
- package/dist/storage/index.js +1 -0
- package/dist/storage/types.d.ts +26 -0
- package/dist/stridge/StridgeContext.d.ts +29 -0
- package/dist/stridge/StridgeContext.js +1 -0
- package/dist/stridge/StridgeProvider.d.ts +158 -0
- package/dist/stridge/StridgeProvider.js +1 -0
- package/dist/stridge/stubs.js +1 -0
- package/dist/styles/index.css +3494 -0
- package/dist/types.d.ts +15 -0
- package/dist/types.js +1 -0
- package/dist/ui/index.d.ts +48 -0
- package/dist/ui/index.js +1 -0
- package/dist/utils/src/use-copy-to-clipboard.js +1 -0
- package/dist/wallet/index.d.ts +3 -0
- package/dist/wallet/index.js +1 -0
- package/dist/withdraw/compound/index.d.ts +22 -0
- package/dist/withdraw/compound/index.js +1 -0
- package/dist/withdraw/dialog/index.d.ts +2 -0
- package/dist/withdraw/dialog/index.js +1 -0
- package/package.json +156 -0
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
import { DialogShellControls } from "../../../dialog/DialogShell.js";
|
|
2
|
+
import { AssetDescriptor } from "../../asset-descriptor.js";
|
|
3
|
+
import { ComponentProps, ReactNode } from "react";
|
|
4
|
+
|
|
5
|
+
//#region src/shared/widgets/amount-entry/compound/types.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* A token rendered inside the AmountEntry FlowPill or surfaced through the widget's context.
|
|
8
|
+
* Used by both the "send" (source) and "receive" (destination) sides of the flow. Aliased to the
|
|
9
|
+
* kit-wide {@link AssetDescriptor} so the shape stays in sync across every "asset to display"
|
|
10
|
+
* prop the kit's widgets accept.
|
|
11
|
+
*/
|
|
12
|
+
type AmountEntryToken = AssetDescriptor;
|
|
13
|
+
/**
|
|
14
|
+
* A percent-preset chip rendered inside `AmountEntry.Pills`. The value
|
|
15
|
+
* is opaque to the kit — typically `0.25 | 0.5 | 0.75 | 1` but any
|
|
16
|
+
* stable id works for the host's controlled selection state.
|
|
17
|
+
*/
|
|
18
|
+
interface AmountEntryPercentPreset {
|
|
19
|
+
/** Stable id used as the `activeValue` discriminator and React key. */
|
|
20
|
+
value: string;
|
|
21
|
+
/** Rendered label inside the chip (e.g. `"25%"`, `"Max"`). */
|
|
22
|
+
label: string;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Props for `<AmountEntry.Dialog>` — the dialog form of the AmountEntry
|
|
26
|
+
* widget. Combines the widget root props with the shared dialog shell
|
|
27
|
+
* controls (`open` / `defaultOpen` / `onOpenChange` / `trigger`).
|
|
28
|
+
*/
|
|
29
|
+
type AmountEntryDialogProps = AmountEntryProps & DialogShellControls;
|
|
30
|
+
/**
|
|
31
|
+
* Public props accepted by the {@link AmountEntry} root.
|
|
32
|
+
*/
|
|
33
|
+
interface AmountEntryProps {
|
|
34
|
+
/**
|
|
35
|
+
* The amount the user has entered, as a raw number. `null` is the
|
|
36
|
+
* empty state — the input renders empty so the host can drive
|
|
37
|
+
* "amount cleared" without inventing a sentinel like `NaN`.
|
|
38
|
+
*/
|
|
39
|
+
amount: number | null;
|
|
40
|
+
/**
|
|
41
|
+
* Source token rendered on the left side of the FlowPill. The user
|
|
42
|
+
* is sending this token.
|
|
43
|
+
*/
|
|
44
|
+
sendToken: AmountEntryToken;
|
|
45
|
+
/**
|
|
46
|
+
* Destination token rendered on the right side of the FlowPill, and
|
|
47
|
+
* surfaced as the title fallback (`Deposit ${symbol}` — appends ` to ${brandName}`
|
|
48
|
+
* when `<KitProvider brandName="…">` is configured).
|
|
49
|
+
*/
|
|
50
|
+
receiveToken: AmountEntryToken;
|
|
51
|
+
/**
|
|
52
|
+
* Locale used to format the displayed amount when the input isn't
|
|
53
|
+
* focused. Defaults to the user's runtime locale.
|
|
54
|
+
*/
|
|
55
|
+
locale?: Intl.LocalesArgument;
|
|
56
|
+
/**
|
|
57
|
+
* Display formatting options applied to the amount. Defaults to locale
|
|
58
|
+
* grouping with up to 8 fraction digits; pass `useGrouping: false`
|
|
59
|
+
* for raw crypto-style amounts.
|
|
60
|
+
*/
|
|
61
|
+
format?: Intl.NumberFormatOptions;
|
|
62
|
+
/**
|
|
63
|
+
* Minimum allowed value. Defaults to `0` so the input can't go
|
|
64
|
+
* negative — overriding to `undefined` removes the floor.
|
|
65
|
+
*/
|
|
66
|
+
min?: number;
|
|
67
|
+
/** Optional maximum value (e.g. the user's balance). */
|
|
68
|
+
max?: number;
|
|
69
|
+
/**
|
|
70
|
+
* Fired as the user types or when a parent updates the amount via
|
|
71
|
+
* the percent presets. The kit forwards the parsed numeric value
|
|
72
|
+
* (`null` when the field is cleared).
|
|
73
|
+
*/
|
|
74
|
+
onAmountChange?: (next: number | null) => void;
|
|
75
|
+
/**
|
|
76
|
+
* Optional override for the `Header` title. Defaults to
|
|
77
|
+
* `"Deposit {symbol}"` (filled from `receiveToken.symbol`).
|
|
78
|
+
*/
|
|
79
|
+
headerTitle?: string;
|
|
80
|
+
/**
|
|
81
|
+
* Optional back-button callback for the `Header`. When undefined the
|
|
82
|
+
* chevron is hidden.
|
|
83
|
+
*/
|
|
84
|
+
onBack?: () => void;
|
|
85
|
+
/**
|
|
86
|
+
* Currency-symbol glyph rendered before the hero amount digits.
|
|
87
|
+
* Defaults to `"$"`.
|
|
88
|
+
*/
|
|
89
|
+
currencySymbol?: string;
|
|
90
|
+
/**
|
|
91
|
+
* Sub-line slot rendered below the hero amount. When omitted, a
|
|
92
|
+
* default sub-line composed from `subLineAmount` (or the receive
|
|
93
|
+
* token's symbol) is rendered.
|
|
94
|
+
*/
|
|
95
|
+
subLine?: ReactNode;
|
|
96
|
+
/**
|
|
97
|
+
* Pre-formatted converted amount used in the default sub-line. When
|
|
98
|
+
* omitted, the hero falls back to `${amount} ${receiveToken.symbol}`.
|
|
99
|
+
*/
|
|
100
|
+
subLineAmount?: string;
|
|
101
|
+
/**
|
|
102
|
+
* Preset chips rendered inside `AmountEntry.Pills`. Defaults to an
|
|
103
|
+
* empty list — pass `25% / 50% / 75% / Max` (or whatever the host
|
|
104
|
+
* needs) to populate the row.
|
|
105
|
+
*/
|
|
106
|
+
presets?: ReadonlyArray<AmountEntryPercentPreset>;
|
|
107
|
+
/**
|
|
108
|
+
* Currently-active preset id. When `undefined`, no chip is marked
|
|
109
|
+
* active.
|
|
110
|
+
*/
|
|
111
|
+
activePreset?: string;
|
|
112
|
+
/**
|
|
113
|
+
* Fired when a preset chip is clicked. When undefined the chips
|
|
114
|
+
* render inert.
|
|
115
|
+
*/
|
|
116
|
+
onPresetSelect?: (value: string) => void;
|
|
117
|
+
/**
|
|
118
|
+
* Optional override for the bridge glyph between Send and Receive.
|
|
119
|
+
* Defaults to a 16×16 chevron-right.
|
|
120
|
+
*/
|
|
121
|
+
bridge?: ReactNode;
|
|
122
|
+
/**
|
|
123
|
+
* Footer CTA label. Defaults to `"Continue"`.
|
|
124
|
+
*/
|
|
125
|
+
footerLabel?: string;
|
|
126
|
+
/**
|
|
127
|
+
* Footer CTA click handler. When undefined the CTA renders inert.
|
|
128
|
+
*/
|
|
129
|
+
onContinue?: () => void;
|
|
130
|
+
/** Compound parts; see `AmountEntry.Header`, `AmountEntry.Hero`, etc. */
|
|
131
|
+
children?: ReactNode;
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Body slot part props. Forwards every native `<div>` prop through to the
|
|
135
|
+
* underlying `Card.Body`, which becomes the scrollable region when the
|
|
136
|
+
* widget is mounted inside `Dialog.Content`.
|
|
137
|
+
*/
|
|
138
|
+
type AmountEntryBodyProps = ComponentProps<"div">;
|
|
139
|
+
/**
|
|
140
|
+
* Header part props.
|
|
141
|
+
*/
|
|
142
|
+
interface AmountEntryHeaderProps {
|
|
143
|
+
/**
|
|
144
|
+
* Optional override for the title rendered in this slot. Defaults to
|
|
145
|
+
* the `headerTitle` set on the {@link AmountEntry} root, falling back
|
|
146
|
+
* to `"Deposit {symbol}"` (filled from the receive token in context).
|
|
147
|
+
*/
|
|
148
|
+
title?: string;
|
|
149
|
+
/**
|
|
150
|
+
* Optional override for the back-button callback. Defaults to the
|
|
151
|
+
* `onBack` set on the {@link AmountEntry} root. Pass `null` to force
|
|
152
|
+
* the chevron hidden even when the root supplies a callback.
|
|
153
|
+
*/
|
|
154
|
+
onBack?: (() => void) | null;
|
|
155
|
+
}
|
|
156
|
+
/**
|
|
157
|
+
* Hero (large fiat amount block) part props.
|
|
158
|
+
*/
|
|
159
|
+
interface AmountEntryHeroProps {
|
|
160
|
+
/**
|
|
161
|
+
* Optional override for the currency-symbol glyph. Defaults to the
|
|
162
|
+
* `currencySymbol` set on the {@link AmountEntry} root, falling back
|
|
163
|
+
* to `"$"`.
|
|
164
|
+
*/
|
|
165
|
+
currencySymbol?: string;
|
|
166
|
+
/**
|
|
167
|
+
* Optional override for the sub-line slot. Defaults to the `subLine`
|
|
168
|
+
* set on the {@link AmountEntry} root.
|
|
169
|
+
*/
|
|
170
|
+
subLine?: ReactNode;
|
|
171
|
+
/**
|
|
172
|
+
* Optional override for the pre-formatted converted amount. Defaults
|
|
173
|
+
* to the `subLineAmount` set on the {@link AmountEntry} root.
|
|
174
|
+
*/
|
|
175
|
+
subLineAmount?: string;
|
|
176
|
+
}
|
|
177
|
+
/**
|
|
178
|
+
* Pills (percent-preset row) part props.
|
|
179
|
+
*/
|
|
180
|
+
interface AmountEntryPillsProps {
|
|
181
|
+
/**
|
|
182
|
+
* Optional override for the rendered preset chips. Defaults to the
|
|
183
|
+
* `presets` set on the {@link AmountEntry} root.
|
|
184
|
+
*/
|
|
185
|
+
presets?: ReadonlyArray<AmountEntryPercentPreset>;
|
|
186
|
+
/**
|
|
187
|
+
* Optional override for the active chip id. Defaults to the
|
|
188
|
+
* `activePreset` set on the {@link AmountEntry} root.
|
|
189
|
+
*/
|
|
190
|
+
activeValue?: string;
|
|
191
|
+
/**
|
|
192
|
+
* Optional override for the chip-click handler. Defaults to the
|
|
193
|
+
* `onPresetSelect` set on the {@link AmountEntry} root.
|
|
194
|
+
*/
|
|
195
|
+
onSelect?: (value: string) => void;
|
|
196
|
+
}
|
|
197
|
+
/**
|
|
198
|
+
* Flow (Send → Receive pill) part props.
|
|
199
|
+
*/
|
|
200
|
+
interface AmountEntryFlowProps {
|
|
201
|
+
/**
|
|
202
|
+
* Optional override for the bridge glyph between Send and Receive.
|
|
203
|
+
* Defaults to the `bridge` set on the {@link AmountEntry} root,
|
|
204
|
+
* falling back to a 16×16 chevron-right.
|
|
205
|
+
*/
|
|
206
|
+
bridge?: ReactNode;
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Footer part props — owns the full-width primary Continue CTA.
|
|
210
|
+
*/
|
|
211
|
+
interface AmountEntryFooterProps {
|
|
212
|
+
/**
|
|
213
|
+
* Optional override for the CTA label. Defaults to the `footerLabel`
|
|
214
|
+
* set on the {@link AmountEntry} root, falling back to `"Continue"`.
|
|
215
|
+
*/
|
|
216
|
+
label?: string;
|
|
217
|
+
/**
|
|
218
|
+
* Optional override for the CTA click handler. Defaults to the
|
|
219
|
+
* `onContinue` set on the {@link AmountEntry} root.
|
|
220
|
+
*/
|
|
221
|
+
onContinue?: () => void;
|
|
222
|
+
}
|
|
223
|
+
//#endregion
|
|
224
|
+
export { AmountEntryBodyProps, AmountEntryDialogProps, AmountEntryFlowProps, AmountEntryFooterProps, AmountEntryHeaderProps, AmountEntryHeroProps, AmountEntryPercentPreset, AmountEntryPillsProps, AmountEntryProps, AmountEntryToken };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
//#region src/shared/widgets/asset-descriptor.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* Canonical view-model for any "asset to display" prop the kit's widgets accept. Deposit and
|
|
4
|
+
* withdraw flows both build this shape in 8+ places (`creditedAsset`, `sendToken`, `receiveAsset`,
|
|
5
|
+
* `sourceAsset`, `receiveChain`, …) when projecting driver payloads into compound props; this
|
|
6
|
+
* type plus the `toAssetDescriptor` mapper collapse those into one funnel.
|
|
7
|
+
*
|
|
8
|
+
* Every compound that takes an asset prop (`AmountEntryToken`, `WithdrawFormAsset`,
|
|
9
|
+
* `ErrorStateAsset`, `ProcessingStateAsset`, `SuccessStateAsset`, …) aliases or extends this
|
|
10
|
+
* type so drift between flows becomes a compile error.
|
|
11
|
+
*/
|
|
12
|
+
interface AssetDescriptor {
|
|
13
|
+
/** Symbol shown as the row's primary label (e.g. `"USDC"`). */
|
|
14
|
+
symbol: string;
|
|
15
|
+
/** Optional longer caption rendered alongside the symbol (e.g. `"You send"`, `"Polygon"`). */
|
|
16
|
+
label?: string;
|
|
17
|
+
/** EIP-155 chain id used to resolve the asset's logo. */
|
|
18
|
+
chainId?: number;
|
|
19
|
+
/** ERC-20 contract address on `chainId`. Omit for chain-native tokens. */
|
|
20
|
+
address?: string;
|
|
21
|
+
/** `true` for chain-native tokens (ETH, MATIC, …) and for chain-row entries. */
|
|
22
|
+
isNative?: boolean;
|
|
23
|
+
/** Logo URL — final URL fallback before the kit's gradient + letter visual. */
|
|
24
|
+
logoUrl?: string;
|
|
25
|
+
}
|
|
26
|
+
//#endregion
|
|
27
|
+
export { AssetDescriptor };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function e(e){if(!e)return;let t=typeof e.chainId==`number`?e.chainId:e.eip155Id===void 0?void 0:typeof e.eip155Id==`number`?e.eip155Id:Number(e.eip155Id),n=e.logoUrl??e.assetLogoUrl;return{symbol:e.symbol,...e.label===void 0?{}:{label:e.label},...t!==void 0&&!Number.isNaN(t)?{chainId:t}:{},...e.address===void 0?{}:{address:e.address},...e.isNative===void 0?{}:{isNative:e.isNative},...n===void 0?{}:{logoUrl:n}}}export{e as toAssetDescriptor};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { AssetPickerAssetProps, AssetPickerBodyProps, AssetPickerDialogProps, AssetPickerFooterProps, AssetPickerHeaderProps, AssetPickerListProps, AssetPickerProps } from "./types.js";
|
|
2
|
+
import { AssetPickerAsset } from "./components/Asset.js";
|
|
3
|
+
import { AssetPickerFooter } from "./components/Footer.js";
|
|
4
|
+
import { AssetPickerHeader } from "./components/Header.js";
|
|
5
|
+
import { AssetPickerList } from "./components/List.js";
|
|
6
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
7
|
+
|
|
8
|
+
//#region src/shared/widgets/asset-picker/compound/AssetPicker.d.ts
|
|
9
|
+
/**
|
|
10
|
+
* Root of the AssetPicker compound. Renders the modal-frame card surface and provides shared state
|
|
11
|
+
* (destination token, asset list, selection, footer wiring) to every compound part rendered inside it.
|
|
12
|
+
*
|
|
13
|
+
* Parts:
|
|
14
|
+
* - {@link AssetPicker.Header}
|
|
15
|
+
* - {@link AssetPicker.Body}
|
|
16
|
+
* - {@link AssetPicker.List}
|
|
17
|
+
* - {@link AssetPicker.Asset}
|
|
18
|
+
* - {@link AssetPicker.Footer}
|
|
19
|
+
*
|
|
20
|
+
* Dialog form: {@link AssetPicker.Dialog} pre-composes the widget into
|
|
21
|
+
* a `Dialog.Root + Dialog.Trigger + Dialog.Content` shell — the
|
|
22
|
+
* production-recommended entry point. Use the bare `AssetPicker` form
|
|
23
|
+
* when you want the widget mounted inline.
|
|
24
|
+
*/
|
|
25
|
+
declare function AssetPicker(props: AssetPickerProps): _$react_jsx_runtime0.JSX.Element;
|
|
26
|
+
declare function AssetPickerBody(props: AssetPickerBodyProps): _$react_jsx_runtime0.JSX.Element;
|
|
27
|
+
declare function AssetPickerDialog({
|
|
28
|
+
open,
|
|
29
|
+
defaultOpen,
|
|
30
|
+
onOpenChange,
|
|
31
|
+
trigger,
|
|
32
|
+
children,
|
|
33
|
+
...rootProps
|
|
34
|
+
}: AssetPickerDialogProps): _$react_jsx_runtime0.JSX.Element;
|
|
35
|
+
declare namespace AssetPicker {
|
|
36
|
+
type Props = AssetPickerProps;
|
|
37
|
+
type HeaderProps = AssetPickerHeaderProps;
|
|
38
|
+
type BodyProps = AssetPickerBodyProps;
|
|
39
|
+
type ListProps = AssetPickerListProps;
|
|
40
|
+
type AssetProps = AssetPickerAssetProps;
|
|
41
|
+
type FooterProps = AssetPickerFooterProps;
|
|
42
|
+
type DialogProps = AssetPickerDialogProps;
|
|
43
|
+
const Header: typeof AssetPickerHeader;
|
|
44
|
+
const Body: typeof AssetPickerBody;
|
|
45
|
+
const List: typeof AssetPickerList;
|
|
46
|
+
const Asset: typeof AssetPickerAsset;
|
|
47
|
+
const Footer: typeof AssetPickerFooter;
|
|
48
|
+
const Dialog: typeof AssetPickerDialog;
|
|
49
|
+
}
|
|
50
|
+
//#endregion
|
|
51
|
+
export { AssetPicker };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{DialogShell as e}from"../../../dialog/DialogShell.js";import{Card as t}from"../../../ui/Card/Card.js";import{Tooltip as n}from"../../../ui/Tooltip/Tooltip.js";import"../../../ui/Tooltip/index.js";import"../../../../ui/index.js";import{Frame as r}from"../../../dialog/Frame.js";import{ASSET_PICKER_SLOTS as i}from"./AssetPicker.slots.js";import{styles as a}from"./AssetPicker.styles.js";import{AssetPickerContext as o}from"./context.js";import{AssetPickerAsset as s}from"./components/Asset.js";import{AssetPickerFooter as c}from"./components/Footer.js";import{AssetPickerHeader as l}from"./components/Header.js";import{AssetPickerList as u}from"./components/List.js";import{useMemo as d}from"react";import{jsx as f}from"react/jsx-runtime";import*as p from"@stylexjs/stylex";const m=[];function h(e){let{token:t,selectedId:s,onSelect:c,assets:l=m,headerTitle:u,onBack:h,footerLabel:g,onContinue:_,children:v}=e,y=d(()=>({token:t,selectedId:s,onSelect:c,assets:l,headerTitle:u,onBack:h,footerLabel:g,onContinue:_}),[t,s,c,l,u,h,g,_]);return f(o.Provider,{value:y,children:f(n.Provider,{children:f(r,{"data-stridge-slot":i.root,...p.props(a.root),children:v})})})}function g(e){return f(t.Body,{"data-stridge-slot":i.body,...e})}function _({open:t,defaultOpen:n,onOpenChange:r,trigger:i,children:a,...o}){return f(e,{open:t,defaultOpen:n,onOpenChange:r,trigger:i,children:f(h,{...o,children:a})})}(function(e){e.Header=l,e.Body=g,e.List=u,e.Asset=s,e.Footer=c,e.Dialog=_})(h||={});export{h as AssetPicker};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
//#region src/shared/widgets/asset-picker/compound/AssetPicker.slots.d.ts
|
|
2
|
+
declare const ASSET_PICKER_SLOTS: {
|
|
3
|
+
readonly root: "asset-picker";
|
|
4
|
+
readonly header: "asset-picker-header";
|
|
5
|
+
readonly body: "asset-picker-body";
|
|
6
|
+
readonly footer: "asset-picker-footer";
|
|
7
|
+
readonly list: "asset-picker-list";
|
|
8
|
+
};
|
|
9
|
+
type AssetPickerSlot = (typeof ASSET_PICKER_SLOTS)[keyof typeof ASSET_PICKER_SLOTS];
|
|
10
|
+
//#endregion
|
|
11
|
+
export { ASSET_PICKER_SLOTS, AssetPickerSlot };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e={root:`asset-picker`,header:`asset-picker-header`,body:`asset-picker-body`,footer:`asset-picker-footer`,list:`asset-picker-list`};export{e as ASSET_PICKER_SLOTS};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e={root:{"AssetPicker__styles.root":`AssetPicker__styles.root`,"position-kVAEAm":`x1n2onr6`,"width-kzqmXN":`xh8yej3`,"maxWidth-ks0D6T":`x17fpy1y`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:5`},header:{"AssetPicker__styles.header":`AssetPicker__styles.header`,"gap-kOIVth":`x1v2ro7d`,"paddingTop-kLKAdn":`xyamay9`,"paddingInlineEnd-kwRFfy":`x1x5flf6`,"paddingBottom-kGO01o":`x1l90r2v`,"paddingInlineStart-kZCmMZ":`xf7dkkf`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:12`},headerTitle:{"AssetPicker__styles.headerTitle":`AssetPicker__styles.headerTitle`,"flexGrow-kzQI83":`x1iyjqo2`,"margin-kogj98":`x1ghz6dp`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:19`},backIcon:{"AssetPicker__styles.backIcon":`AssetPicker__styles.backIcon`,"width-kzqmXN":`x6jxa94`,"height-kZKoxP":`x1v9usgg`,"flexShrink-kmuXW":`x2lah0s`,"color-kMwMTN":`xzn0pkc`,"strokeWidth-kfJifR":`xhxwl1`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:23`},closeIcon:{"AssetPicker__styles.closeIcon":`AssetPicker__styles.closeIcon`,"width-kzqmXN":`xsmyaan`,"height-kZKoxP":`x1kpxq89`,"flexShrink-kmuXW":`x2lah0s`,"color-kMwMTN":`xzn0pkc`,"strokeWidth-kfJifR":`xhr4kjn`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:30`},list:{"AssetPicker__styles.list":`AssetPicker__styles.list`,"display-k1xSpc":`x78zum5`,"flexDirection-kXwgrk":`xdt5ytf`,"gap-kOIVth":`x167g77z`,"paddingTop-kLKAdn":`x109j2v6`,"paddingInlineEnd-kwRFfy":`x1x5flf6`,"paddingInlineStart-kZCmMZ":`xwn43p0`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:38`},assetRow:{"AssetPicker__styles.assetRow":`AssetPicker__styles.assetRow`,"gap-kOIVth":`x1af02g3`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:51`},textBlock:{"AssetPicker__styles.textBlock":`AssetPicker__styles.textBlock`,"display-k1xSpc":`x78zum5`,"flexDirection-kXwgrk":`xdt5ytf`,"flexBasis-kCS8Yb":`x1r8uery`,"flexGrow-kzQI83":`x1iyjqo2`,"flexShrink-kmuXW":`xs83m0k`,"minWidth-k7Eaqz":`xeuugli`,"gap-kOIVth":`x195vfkc`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:55`},fiat:{"AssetPicker__styles.fiat":`AssetPicker__styles.fiat`,"flexShrink-kmuXW":`x2lah0s`,"whiteSpace-khDVqt":`xuxw1ft`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:65`},lowBalanceBadge:{"AssetPicker__styles.lowBalanceBadge":`AssetPicker__styles.lowBalanceBadge`,"flexShrink-kmuXW":`x2lah0s`,"backgroundColor-kWkggS":`xp5aqsh`,"borderColor-kVAM5u":`x1bue7yx`,"color-kMwMTN":`x137ha3m`,"fontSize-kGuDYH":`x1j6dyjg`,"fontWeight-k63SB2":`xk50ysn`,"lineHeight-kLWn49":`x1xxsxie`,"letterSpacing-kb6lSQ":`x1ixy4ik`,"minHeight-kAzted":`xj9xw9b`,"paddingInlineStart-kZCmMZ":`x7coems`,"paddingInlineEnd-kwRFfy":`xrw5ot4`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:78`},footer:{"AssetPicker__styles.footer":`AssetPicker__styles.footer`,"display-k1xSpc":`x78zum5`,"flexDirection-kXwgrk":`xdt5ytf`,"paddingTop-kLKAdn":`xyamay9`,"paddingInlineEnd-kwRFfy":`x1x5flf6`,"paddingBottom-kGO01o":`x1t4gjm`,"paddingInlineStart-kZCmMZ":`xwn43p0`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:92`},cta:{"AssetPicker__styles.cta":`AssetPicker__styles.cta`,"width-kzqmXN":`xh8yej3`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:100`},ctaInteractive:{"AssetPicker__styles.ctaInteractive":`AssetPicker__styles.ctaInteractive`,"cursor-kkrTdU":`x1ypdohk`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:103`},ctaInert:{"AssetPicker__styles.ctaInert":`AssetPicker__styles.ctaInert`,"cursor-kkrTdU":`xt0e3qv`,$$css:`@stridge/kit:src/shared/widgets/asset-picker/compound/AssetPicker.styles.ts:106`}};export{e as styles};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { AssetPickerAssetProps } from "../types.js";
|
|
2
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
3
|
+
|
|
4
|
+
//#region src/shared/widgets/asset-picker/compound/components/Asset.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* A single row inside `AssetPicker.List`, laid out as:
|
|
7
|
+
*
|
|
8
|
+
* [icon + chain badge] [symbol] [low balance?] [fiat]
|
|
9
|
+
* [balance]
|
|
10
|
+
*
|
|
11
|
+
* Selection state is read from context, so consumers only manage a single `selectedId` on the root rather than
|
|
12
|
+
* threading `isSelected` onto each row.
|
|
13
|
+
*/
|
|
14
|
+
declare function AssetPickerAsset({
|
|
15
|
+
id,
|
|
16
|
+
symbol,
|
|
17
|
+
chain,
|
|
18
|
+
balanceFormatted,
|
|
19
|
+
fiatFormatted,
|
|
20
|
+
lowBalance,
|
|
21
|
+
disabled,
|
|
22
|
+
chainId,
|
|
23
|
+
contractAddress,
|
|
24
|
+
isNative,
|
|
25
|
+
logoUrl,
|
|
26
|
+
chainLogoUrl,
|
|
27
|
+
pinnedLogoUrl
|
|
28
|
+
}: AssetPickerAssetProps): _$react_jsx_runtime0.JSX.Element;
|
|
29
|
+
//#endregion
|
|
30
|
+
export { AssetPickerAsset };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{useLingui as e}from"../../../../i18n/useLingui.js";import"../../../../../i18n/index.js";import{Badge as t}from"../../../../ui/Badge/Badge.js";import"../../../../ui/Badge/index.js";import{SelectableTile as n}from"../../../../ui/SelectableTile/SelectableTile.js";import"../../../../ui/SelectableTile/index.js";import{text as r}from"../../../../ui/Text/Text.js";import{TokenLogo as i}from"../../../../ui/TokenLogo/TokenLogo.js";import"../../../../ui/TokenLogo/index.js";import"../../../../../ui/index.js";import{styles as a}from"../AssetPicker.styles.js";import{useAssetPickerContext as o}from"../context.js";import{jsx as s,jsxs as c}from"react/jsx-runtime";import*as l from"@stylexjs/stylex";function u({id:u,symbol:d,chain:f,balanceFormatted:p,fiatFormatted:m,lowBalance:h=!1,disabled:g=!1,chainId:_,contractAddress:v,isNative:y,logoUrl:b,chainLogoUrl:x,pinnedLogoUrl:S}){let C=o(`AssetPicker.Asset`),{_:w}=e();return c(n,{shape:`card`,value:u,selected:C.selectedId===u,disabled:g,"aria-label":`${d} on ${f}`,"data-asset-id":u,"data-chain":f,...l.props(a.assetRow),children:[s(i,{size:36,symbol:d,..._===void 0?{}:{chainId:_},...v===void 0?{}:{address:v},...y===void 0?{}:{isNative:y},...b===void 0?{}:{logoUrl:b},...x===void 0?{}:{chainLogoUrl:x},...S===void 0?{}:{pinnedLogoUrl:S}}),c(`span`,{...l.props(a.textBlock),children:[s(r.span,{size:`callout`,fontWeight:`semibold`,leading:`tight`,tracking:`tight`,truncate:!0,children:d}),s(r.span,{size:`meta`,fontWeight:`medium`,leading:`tight`,color:`subdued`,truncate:!0,children:p})]}),h?s(t,{variant:`outline`,color:`secondary`,size:`sm`,roundness:`lg`,...l.props(a.lowBalanceBadge),children:w({id:`Wqz0SO`,message:`Low Balance`})}):null,s(r.span,{size:`callout`,fontWeight:`semibold`,leading:`tight`,tracking:`tight`,...l.props(a.fiat),children:m})]})}export{u as AssetPickerAsset};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { AssetPickerFooterProps } from "../types.js";
|
|
2
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
3
|
+
|
|
4
|
+
//#region src/shared/widgets/asset-picker/compound/components/Footer.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* Footer row at the bottom of the modal, rendering the full-width Continue CTA.
|
|
7
|
+
*
|
|
8
|
+
* Reads the label and click handler from the {@link AssetPicker} root by
|
|
9
|
+
* default; pass `label` / `onContinue` to override per-instance.
|
|
10
|
+
*/
|
|
11
|
+
declare function AssetPickerFooter({
|
|
12
|
+
label,
|
|
13
|
+
onContinue
|
|
14
|
+
}?: AssetPickerFooterProps): _$react_jsx_runtime0.JSX.Element;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { AssetPickerFooter };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{useLingui as e}from"../../../../i18n/useLingui.js";import"../../../../../i18n/index.js";import{Button as t}from"../../../../ui/Button/Button.js";import"../../../../ui/Button/index.js";import{ASSET_PICKER_SLOTS as n}from"../AssetPicker.slots.js";import{styles as r}from"../AssetPicker.styles.js";import{useAssetPickerContext as i}from"../context.js";import{jsx as a}from"react/jsx-runtime";import*as o from"@stylexjs/stylex";function s({label:s,onContinue:c}={}){let l=i(`AssetPicker.Footer`),{_:u}=e(),d=c??l.onContinue,f=s??l.footerLabel??u({id:`xGVfLh`,message:`Continue`}),p=typeof d==`function`;return a(`div`,{"data-stridge-slot":n.footer,...o.props(r.footer),children:a(t,{size:`cta`,onClick:p?d:void 0,...o.props(r.cta,p?r.ctaInteractive:r.ctaInert),children:f})})}export{s as AssetPickerFooter};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { AssetPickerHeaderProps } from "../types.js";
|
|
2
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
3
|
+
|
|
4
|
+
//#region src/shared/widgets/asset-picker/compound/components/Header.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* Header row with back chevron and title. `Dialog.CloseButton` renders
|
|
7
|
+
* as the trailing flex child only when the widget is mounted inside
|
|
8
|
+
* `Dialog.Content`; card-mode shows just `[back, title]`.
|
|
9
|
+
*
|
|
10
|
+
* Reads the title and back callback from the {@link AssetPicker} root by
|
|
11
|
+
* default; pass `title` / `onBack` to override per-instance, or `onBack:
|
|
12
|
+
* null` to force the chevron hidden even when the root supplies one.
|
|
13
|
+
*/
|
|
14
|
+
declare function AssetPickerHeader({
|
|
15
|
+
title,
|
|
16
|
+
onBack
|
|
17
|
+
}?: AssetPickerHeaderProps): _$react_jsx_runtime0.JSX.Element;
|
|
18
|
+
//#endregion
|
|
19
|
+
export { AssetPickerHeader };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{useLingui as e}from"../../../../i18n/useLingui.js";import"../../../../../i18n/index.js";import{ChevronLeftIcon as t}from"../../../../icons/ChevronLeftIcon.js";import"../../../../../icons/index.js";import{IconButton as n}from"../../../../ui/IconButton/IconButton.js";import{Dialog as r}from"../../../../ui/Dialog/Dialog.js";import"../../../../ui/Dialog/index.js";import{Card as i}from"../../../../ui/Card/Card.js";import{text as a}from"../../../../ui/Text/Text.js";import"../../../../../ui/index.js";import{ASSET_PICKER_SLOTS as o}from"../AssetPicker.slots.js";import{styles as s}from"../AssetPicker.styles.js";import{useAssetPickerContext as c}from"../context.js";import{jsx as l,jsxs as u}from"react/jsx-runtime";import*as d from"@stylexjs/stylex";function f({title:f,onBack:p}={}){let m=c(`AssetPicker.Header`),{_:h}=e(),g=m.token?.symbol??`USDC`,_=f??m.headerTitle??h({id:`oFmN8a`,message:`Deposit {symbol}`,values:{symbol:g}}),v=p===null?void 0:p??m.onBack;return u(i.Header,{"data-stridge-slot":o.header,...d.props(s.header),children:[typeof v==`function`?l(n,{"aria-label":h({id:`iH8pgl`,message:`Back`}),onClick:v,children:l(t,{"aria-hidden":!0,...d.props(s.backIcon)})}):null,l(a.span,{size:`base`,fontWeight:`semibold`,leading:`tight`,tracking:`tight`,truncate:!0,...d.props(s.headerTitle),children:_}),l(r.CloseButton,{})]})}export{f as AssetPickerHeader};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { AssetPickerListProps } from "../types.js";
|
|
2
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
3
|
+
|
|
4
|
+
//#region src/shared/widgets/asset-picker/compound/components/List.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* Vertical stack of `AssetPicker.Asset` rows. Single-select wired through
|
|
7
|
+
* `SelectableTileGroup` — Up / Down walks the rows, Home / End jumps to
|
|
8
|
+
* the ends, and clicking (or pressing Enter / Space on) a row sets the
|
|
9
|
+
* group's value. The picker context's `selectedId` is the controlled
|
|
10
|
+
* value; the row click is dispatched via `onValueChange` rather than a
|
|
11
|
+
* per-row handler.
|
|
12
|
+
*
|
|
13
|
+
* By default renders one `AssetPicker.Asset` per entry on the
|
|
14
|
+
* {@link AssetPicker} root's `assets` prop. Pass `children` to opt out of
|
|
15
|
+
* the default rendering and supply a bespoke list.
|
|
16
|
+
*/
|
|
17
|
+
declare function AssetPickerList({
|
|
18
|
+
assets,
|
|
19
|
+
children
|
|
20
|
+
}?: AssetPickerListProps): _$react_jsx_runtime0.JSX.Element;
|
|
21
|
+
//#endregion
|
|
22
|
+
export { AssetPickerList };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{useLingui as e}from"../../../../i18n/useLingui.js";import"../../../../../i18n/index.js";import{SelectableTileGroup as t}from"../../../../ui/SelectableTile/SelectableTileGroup.js";import"../../../../ui/SelectableTile/index.js";import{ASSET_PICKER_SLOTS as n}from"../AssetPicker.slots.js";import{styles as r}from"../AssetPicker.styles.js";import{useAssetPickerContext as i}from"../context.js";import{AssetPickerAsset as a}from"./Asset.js";import{jsx as o}from"react/jsx-runtime";import*as s from"@stylexjs/stylex";function c({assets:c,children:l}={}){let u=i(`AssetPicker.List`),{_:d}=e(),f=u.selectedId?[u.selectedId]:[],p=c??u.assets;return o(t,{"data-stridge-slot":n.list,"aria-label":d({id:`GX8GKD`,message:`Assets`}),value:f,onValueChange:e=>{let t=e[0];t&&u.onSelect&&u.onSelect(t)},...s.props(r.list),children:l??p.map(e=>o(a,{...e},e.id))})}export{c as AssetPickerList};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{createContext as e,use as t}from"react";const n=e(null);function r(e){let r=t(n);if(!r)throw Error(`${e} must be rendered inside <AssetPicker>.`);return r}export{n as AssetPickerContext,r as useAssetPickerContext};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { AssetOption, AssetPickerAssetProps, AssetPickerBodyProps, AssetPickerDialogProps, AssetPickerFooterProps, AssetPickerHeaderProps, AssetPickerListProps, AssetPickerProps, AssetPickerToken } from "./types.js";
|
|
2
|
+
import { AssetPicker } from "./AssetPicker.js";
|
|
3
|
+
import { ASSET_PICKER_SLOTS, AssetPickerSlot } from "./AssetPicker.slots.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./AssetPicker.slots.js";import"./AssetPicker.js";
|