@pollar/react 0.12.1-rc.19 → 0.12.1-rc.22

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/dist/index.d.mts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { WalletChain, pollarPaths, WalletBalanceRecord, TransactionState, WalletId, PollarLanguage, PendingConfirmation, StellarNetwork, SwapQuoteParams, SwapDestinationChain, BridgeChain, BridgeTransfer, EarnProviderId, CardFundingChain, CardFunding, PollarClient, PollarClientConfig, PollarAdapters, OnStorageDegrade, WalletInfo, CosignCustody, PollarLoginOptions, SessionsState, CosignState, RecoveryState, CustodyMigrationState, TxBuildBody, BuildOutcome, SubmitOutcome, SignOutcome, SendPaymentParams, WalletBalanceState, EnabledAssetsState, TrustlineOutcome, TxHistoryState, SwapVenue, SwapToken, SwapQuote, SolanaSwapVenue, SolanaSwapQuoteParams, SolanaSwapQuote, SolanaSwapOptions, SwapStatus, EarnOpportunity, EarnPositionParams, EarnPosition, EarnTxParams, SolanaEarnProviderId, SolanaEarnOpportunity, SolanaEarnPosition, SolanaEarnTxParams, PollarAdapter, AuthEntryAdapterStep, AuthEntryAdapterOutcome, PasskeyCeremony, PasskeySigner, RecoveryPasskeyCeremony, CosignRequest, CosignVerification, CosignQuorumReport, CosignDevicesContent, KycStatus as KycStatus$1, RampQuoteRejection, RampQuoteRequirement, RampWalletStep, RampQuote, AuthState, KycProvider, KycStartResponse, RampDirection, RampFiat, RampAsset, RampField, RampOrder, EnabledAssetRecord, BridgeQuote, DistributionRulesState, DistributionRule } from '@pollar/core';
2
+ import { WalletChain, pollarPaths, WalletBalanceRecord, TransactionState, WalletId, PollarLanguage, PendingConfirmation, StellarNetwork, SwapQuoteParams, SwapDestinationChain, BridgeChain, BridgeTransfer, EarnProviderId, CardFundingChain, CardFunding, PollarClient, PollarClientConfig, PollarAdapters, OnStorageDegrade, WalletInfo, CosignCustody, PollarLoginOptions, SessionsState, CosignState, RecoveryState, CustodyMigrationState, TxBuildBody, BuildOutcome, SubmitOutcome, SignOutcome, SendPaymentParams, WalletBalanceState, EnabledAssetsState, TrustlineOutcome, TxHistoryState, SwapVenue, SwapToken, SwapQuote, SolanaSwapVenue, SolanaSwapQuoteParams, SolanaSwapQuote, SolanaSwapOptions, SwapStatus, EarnOpportunity, EarnPositionParams, EarnPosition, EarnTxParams, SolanaEarnProviderId, SolanaEarnOpportunity, SolanaEarnPosition, SolanaEarnTxParams, PollarAdapter, AuthEntryAdapterStep, AuthEntryAdapterOutcome, PasskeyCeremony, PasskeySigner, RecoveryPasskeyCeremony, CosignRequest, CosignVerification, CosignQuorumReport, CosignDevicesContent, KycStatus as KycStatus$1, RampQuoteRejection, RampQuoteRequirement, RampWalletStep, RampQuote, AuthState, KycProvider, KycStartResponse, RampDirection, RampFiat, RampAsset, RampField, RampOrder, PollarSupportContact, EnabledAssetRecord, BridgeQuote, DistributionRulesState, DistributionRule } from '@pollar/core';
3
3
  export { AuthProviderContext, PollarAuthProvider, SessionsState } from '@pollar/core';
4
4
  import { CSSProperties, ReactNode } from 'react';
5
5
 
@@ -212,6 +212,51 @@ interface SendModalProps {
212
212
  }
213
213
  declare function SendModal({ onClose, initial }: SendModalProps): react_jsx_runtime.JSX.Element;
214
214
 
215
+ /** One end of the flow: a wallet, an account or a contract, and what it sends or gets. */
216
+ interface TxParty {
217
+ chain?: WalletChain;
218
+ asset?: string;
219
+ amount?: string;
220
+ /** The amount is a floor: a swap delivers at least it. */
221
+ minimum?: boolean;
222
+ address?: string;
223
+ label?: string;
224
+ /** One of the user's own wallets. */
225
+ self?: boolean;
226
+ }
227
+ interface TxDetailRow {
228
+ label: string;
229
+ value: string;
230
+ /** What the copy button copies; the row has none when absent. */
231
+ copyValue?: string;
232
+ /** Opens this page: the value is a link (an explorer on another chain). */
233
+ href?: string;
234
+ mono?: boolean;
235
+ }
236
+ interface TxReviewData {
237
+ /** The action in plain words: what a user without crypto background reads first. */
238
+ title: string;
239
+ kind: 'send' | 'bridge' | 'approve' | 'swap' | 'payment' | 'create_account' | 'activate_wallet' | 'add_asset' | 'deposit' | 'withdraw' | 'sign_in' | 'other';
240
+ /** One line under the title that says what the action is for, when the title alone does not. */
241
+ lead?: string;
242
+ from?: TxParty;
243
+ to?: TxParty;
244
+ /**
245
+ * Who pays the network fee: after the signature, as the platform reported it;
246
+ * before, only when the transaction itself makes the app pay (`appPaysFee`).
247
+ */
248
+ fee?: {
249
+ sponsored: boolean;
250
+ free?: boolean;
251
+ };
252
+ rows: TxDetailRow[];
253
+ raw?: string;
254
+ hash?: {
255
+ value: string;
256
+ explorerUrl: string | null;
257
+ };
258
+ }
259
+
215
260
  /** The chain a swap runs on; the modal shows a selector when the app offers both. */
216
261
  type SwapChain = 'STELLAR' | 'SOLANA';
217
262
  interface SwapAssetOption {
@@ -271,6 +316,8 @@ interface SwapModalTemplateProps {
271
316
  settlement?: SwapSettlementView | null;
272
317
  /** The signature waiting for the user's yes, answered in the transaction step. */
273
318
  confirmation?: PendingConfirmation | null | undefined;
319
+ /** What the transaction step reviews when the transaction carries no build of its own to read it from. */
320
+ review?: TxReviewData | null | undefined;
274
321
  /** The app's network, for the details of a confirmation. */
275
322
  network?: StellarNetwork | undefined;
276
323
  provider: string;
@@ -311,7 +358,7 @@ interface SwapModalTemplateProps {
311
358
  onRetry: () => void;
312
359
  onDone: () => void;
313
360
  }
314
- declare function SwapModalTemplate({ theme, accentColor, styleOverrides, step, txTitle, sellOptions, buyOptions, selectedSell, selectedBuy, amount, chains, chain, destinations, destination, usdcAcross, settlement, confirmation, network, provider, providers, quote, quoteLoading, quoteError, formError, isLoadingData, smartUnsupported, configLoading, swapUnavailable, buyNeedsTrustline, transaction, showXdr, copied, explorerUrl, walletType, showBack, isInProgress, language: languageProp, onClose, onBack, onRefresh, onSelectSell, onSelectBuy, onAddCustomToken, onReverse, onMax, onAmountChange, onChainChange, onDestinationChange, onProviderChange, onSwap, onToggleXdr, onCopyHash, onRetry, onDone, }: SwapModalTemplateProps): react_jsx_runtime.JSX.Element;
361
+ declare function SwapModalTemplate({ theme, accentColor, styleOverrides, step, txTitle, sellOptions, buyOptions, selectedSell, selectedBuy, amount, chains, chain, destinations, destination, usdcAcross, settlement, confirmation, review, network, provider, providers, quote, quoteLoading, quoteError, formError, isLoadingData, smartUnsupported, configLoading, swapUnavailable, buyNeedsTrustline, transaction, showXdr, copied, explorerUrl, walletType, showBack, isInProgress, language: languageProp, onClose, onBack, onRefresh, onSelectSell, onSelectBuy, onAddCustomToken, onReverse, onMax, onAmountChange, onChainChange, onDestinationChange, onProviderChange, onSwap, onToggleXdr, onCopyHash, onRetry, onDone, }: SwapModalTemplateProps): react_jsx_runtime.JSX.Element;
315
362
 
316
363
  /** Where the swap modal opens: a starting point the user can change. An option the app does not offer is left out. */
317
364
  interface SwapModalOptions {
@@ -928,8 +975,24 @@ interface KycModalProps {
928
975
  onApproved?: () => void;
929
976
  /** Language of the modal, as a BCP 47 tag. A language pinned in the dashboard wins over it. */
930
977
  language?: string | undefined;
978
+ /** Render the card in the page instead of over a backdrop, without its close buttons. */
979
+ inline?: boolean;
980
+ }
981
+ declare function KycModal({ onClose, country, level, onApproved, corridorId, cardProviderId, providerId, language: languageProp, inline, }: KycModalProps): react_jsx_runtime.JSX.Element;
982
+
983
+ interface KycFlowProps {
984
+ /** Called once every step is complete; the flow then renders nothing. */
985
+ onApproved?: () => void;
986
+ country?: string;
987
+ level?: 'basic' | 'intermediate' | 'enhanced';
931
988
  }
932
- declare function KycModal({ onClose, country, level, onApproved, corridorId, cardProviderId, providerId, language: languageProp, }: KycModalProps): react_jsx_runtime.JSX.Element;
989
+ /**
990
+ * The app's own KYC, step by step, in the host's page instead of modals: for a
991
+ * page made for verifying, like a KYC link's. Each pending step shows as a card
992
+ * where it is placed (the vendor's verification, or a form) and the next one
993
+ * replaces it as soon as it is done. Signed-in users only.
994
+ */
995
+ declare function KycFlow({ onApproved, country, level }: KycFlowProps): react_jsx_runtime.JSX.Element;
933
996
 
934
997
  interface RequirementFormModalProps {
935
998
  formId: string;
@@ -943,9 +1006,11 @@ interface RequirementFormModalProps {
943
1006
  onSubmitted: () => void;
944
1007
  /** Language of the modal, as a BCP 47 tag. A language pinned in the dashboard wins over it. */
945
1008
  language?: string | undefined;
1009
+ /** Render the card in the page instead of over a backdrop, without its close buttons. */
1010
+ inline?: boolean;
946
1011
  }
947
1012
  /** One FORM requirement step: the form a route asks for, prefilled with the user's previous answers. */
948
- declare function RequirementFormModal({ formId, progress, onClose, onSubmitted, language: languageProp, }: RequirementFormModalProps): react_jsx_runtime.JSX.Element;
1013
+ declare function RequirementFormModal({ formId, progress, onClose, onSubmitted, language: languageProp, inline, }: RequirementFormModalProps): react_jsx_runtime.JSX.Element;
949
1014
 
950
1015
  interface RegistryCheckModalProps {
951
1016
  optionId: string;
@@ -1165,8 +1230,10 @@ interface KycModalTemplateProps {
1165
1230
  onClose: () => void;
1166
1231
  /** Defaults to the user's device; the modal passes the resolved one. */
1167
1232
  language?: PollarLanguage | undefined;
1233
+ /** In the host's page rather than over a backdrop: a region, with no close buttons. */
1234
+ inline?: boolean;
1168
1235
  }
1169
- declare function KycModalTemplate({ theme, accentColor, styleOverrides, step, providers, selectedProvider, session, kycStatus, reviewReason, processing, isLoading, startingProviderId, directOpen, error, onSelectProvider, onDoneVerifying, onStartAgain, onRefresh, onClose, language, }: KycModalTemplateProps): react_jsx_runtime.JSX.Element;
1236
+ declare function KycModalTemplate({ theme, accentColor, styleOverrides, step, providers, selectedProvider, session, kycStatus, reviewReason, processing, isLoading, startingProviderId, directOpen, error, onSelectProvider, onDoneVerifying, onStartAgain, onRefresh, onClose, language, inline, }: KycModalTemplateProps): react_jsx_runtime.JSX.Element;
1170
1237
 
1171
1238
  type RampStep = 'input' | 'loading_quote' | 'select_route' | 'contact' | 'status' | 'error';
1172
1239
  interface RampWidgetTemplateProps {
@@ -1257,6 +1324,8 @@ interface RampWidgetTemplateProps {
1257
1324
  onSetUpRecovery?: (() => void) | undefined;
1258
1325
  /** Whether the wallet still has no way to be recovered; null while its state is unread. */
1259
1326
  recoveryMissing?: boolean | null;
1327
+ /** The app's support contact, linked when an order asks the user to contact support. */
1328
+ support?: PollarSupportContact | null;
1260
1329
  /** Reading the order keeps failing and polling is retrying. */
1261
1330
  pollTrouble?: boolean;
1262
1331
  /** The fiat payment the user says they made is being checked. */
@@ -1279,7 +1348,7 @@ interface RampWidgetTemplateProps {
1279
1348
  /** A leg's signature waiting for the user's yes, answered in the status view. */
1280
1349
  confirmation?: PendingConfirmation | null | undefined;
1281
1350
  }
1282
- declare function RampWidgetTemplate({ theme, accentColor, styleOverrides, network, step, flowSteps, flowStepIndex, direction, routesLoading, countries, country, fiats, fiat, assets, asset, amount, sellAvailable, quotes, rejected, startingQuoteId, fields, fieldValues, order, pendingOrders, isLoading, refreshing, signing, errorMsg, notice, onDirectionChange, onCountryChange, onFiatChange, onAssetChange, onAmountChange, onFindRoute, quoting, routeChoice, chosenQuote, onRouteChoice, onContinue, onSelectQuote, onVerifyRoute, trustingAsset, onTrustAsset, walletBusy, custodyChoice, onWalletStep, noChains, retrying, onRetryOrder, onRequote, onSetUpRecovery, recoveryMissing, checkingPayment, onCheckPayment, pollTrouble, onFieldChange, onContactContinue, onSign, onApprove, onResumeOrder, onNewOrder, onBack, onStepSelect, onRetry, onRefresh, onClose, language: languageProp, confirmation, }: RampWidgetTemplateProps): react_jsx_runtime.JSX.Element;
1351
+ declare function RampWidgetTemplate({ theme, accentColor, styleOverrides, network, step, flowSteps, flowStepIndex, direction, routesLoading, countries, country, fiats, fiat, assets, asset, amount, sellAvailable, quotes, rejected, startingQuoteId, fields, fieldValues, order, pendingOrders, isLoading, refreshing, signing, errorMsg, notice, onDirectionChange, onCountryChange, onFiatChange, onAssetChange, onAmountChange, onFindRoute, quoting, routeChoice, chosenQuote, onRouteChoice, onContinue, onSelectQuote, onVerifyRoute, trustingAsset, onTrustAsset, walletBusy, custodyChoice, onWalletStep, noChains, retrying, onRetryOrder, onRequote, onSetUpRecovery, recoveryMissing, support, checkingPayment, onCheckPayment, pollTrouble, onFieldChange, onContactContinue, onSign, onApprove, onResumeOrder, onNewOrder, onBack, onStepSelect, onRetry, onRefresh, onClose, language: languageProp, confirmation, }: RampWidgetTemplateProps): react_jsx_runtime.JSX.Element;
1283
1352
 
1284
1353
  interface TransactionModalTemplateProps {
1285
1354
  theme: string;
@@ -1305,51 +1374,6 @@ interface TransactionModalTemplateProps {
1305
1374
  }
1306
1375
  declare function TransactionModalTemplate({ theme, accentColor, styleOverrides, transaction, showXdr, copied, explorerUrl, walletType, onClose, onSignAndSend, onToggleXdr, onCopyHash, onRetry, language: languageProp, confirmation, network, }: TransactionModalTemplateProps): react_jsx_runtime.JSX.Element;
1307
1376
 
1308
- /** One end of the flow: a wallet, an account or a contract, and what it sends or gets. */
1309
- interface TxParty {
1310
- chain?: WalletChain;
1311
- asset?: string;
1312
- amount?: string;
1313
- /** The amount is a floor: a swap delivers at least it. */
1314
- minimum?: boolean;
1315
- address?: string;
1316
- label?: string;
1317
- /** One of the user's own wallets. */
1318
- self?: boolean;
1319
- }
1320
- interface TxDetailRow {
1321
- label: string;
1322
- value: string;
1323
- /** What the copy button copies; the row has none when absent. */
1324
- copyValue?: string;
1325
- /** Opens this page: the value is a link (an explorer on another chain). */
1326
- href?: string;
1327
- mono?: boolean;
1328
- }
1329
- interface TxReviewData {
1330
- /** The action in plain words: what a user without crypto background reads first. */
1331
- title: string;
1332
- kind: 'send' | 'bridge' | 'approve' | 'swap' | 'payment' | 'create_account' | 'activate_wallet' | 'add_asset' | 'deposit' | 'withdraw' | 'sign_in' | 'other';
1333
- /** One line under the title that says what the action is for, when the title alone does not. */
1334
- lead?: string;
1335
- from?: TxParty;
1336
- to?: TxParty;
1337
- /**
1338
- * Who pays the network fee: after the signature, as the platform reported it;
1339
- * before, only when the transaction itself makes the app pay (`appPaysFee`).
1340
- */
1341
- fee?: {
1342
- sponsored: boolean;
1343
- free?: boolean;
1344
- };
1345
- rows: TxDetailRow[];
1346
- raw?: string;
1347
- hash?: {
1348
- value: string;
1349
- explorerUrl: string | null;
1350
- };
1351
- }
1352
-
1353
1377
  interface TxStatusViewProps {
1354
1378
  transaction: TransactionState;
1355
1379
  /** Whether the details (addresses, network, fee, raw transaction, hash) are unfolded. */
@@ -1729,4 +1753,4 @@ interface DistributionRulesModalTemplateProps {
1729
1753
  }
1730
1754
  declare function DistributionRulesModalTemplate({ theme, accentColor, styleOverrides, state, claimingId, claimErrors, claimedIds, language: languageProp, onRefresh, onClaim, onClose, }: DistributionRulesModalTemplateProps): react_jsx_runtime.JSX.Element;
1731
1755
 
1732
- export { type AuthModalProps, BridgeModal, type BridgeModalOptions, type BridgeModalStep, BridgeModalTemplate, type BridgeModalTemplateProps, CardModal, type CardModalOptions, ChainSelect, type ChainSelectProps, CosignModal, CosignModalTemplate, type CosignModalTemplateProps, CustodyMigrationModal, CustodyMigrationModalTemplate, type CustodyMigrationModalTemplateProps, type CustomTrustlineModalTemplateProps, DistributionRulesModal, DistributionRulesModalTemplate, EarnModal, type EarnModalOptions, type EarnNetwork, EnabledAssetsModal, EnabledAssetsModalTemplate, type EnabledAssetsModalTemplateProps, KycModal, KycModalTemplate, KycStatus, type KycStep, type LoginButtonProps, LoginModalTemplate, type ModalChrome, type ModalStyleOverrides, type ModalVariant, type PollarConfig, PollarProvider, type PollarStyles, ProviderRegistrationModal, type RampModalOptions, type RampStep, RampWidget, RampWidgetTemplate, ReceiveModal, type ReceiveModalOptions, ReceiveModalTemplate, type ReceiveModalTemplateProps, RecoveryModal, RecoveryModalTemplate, type RecoveryModalTemplateProps, type RecoveryView, RegistryCheckModal, RejectedRouteDisplay, RequirementFormModal, RouteDisplay, type SendMemoType, SendModal, type SendModalOptions, SendModalTemplate, type SendModalTemplateProps, SessionsModal, SessionsModalTemplate, type SessionsModalTemplateProps, type SwapAssetOption, SwapModal, type SwapModalOptions, SwapModalTemplate, type SwapModalTemplateProps, TransactionModalTemplate, type TransactionModalTemplateProps, type TxHistoryModalOptions, TxHistoryModalTemplate, TxStatusView, type TxStatusViewProps, type UseChainsResult, type UseCosignResult, WalletBalanceModal, WalletBalanceModalTemplate, type WalletBalanceModalTemplateProps, WalletButton, WalletButtonTemplate, type WalletButtonTemplateProps, addressForChain, browserPasskeyCeremony, browserPasskeySigner, browserRecoveryPasskey, buildModalCssVars, chainsOf, createPollarAdapterHook, modalChrome, readableTextOn, resolveChain, useChains, useCosign, usePollar, walletNotReadyReason };
1756
+ export { type AuthModalProps, BridgeModal, type BridgeModalOptions, type BridgeModalStep, BridgeModalTemplate, type BridgeModalTemplateProps, CardModal, type CardModalOptions, ChainSelect, type ChainSelectProps, CosignModal, CosignModalTemplate, type CosignModalTemplateProps, CustodyMigrationModal, CustodyMigrationModalTemplate, type CustodyMigrationModalTemplateProps, type CustomTrustlineModalTemplateProps, DistributionRulesModal, DistributionRulesModalTemplate, EarnModal, type EarnModalOptions, type EarnNetwork, EnabledAssetsModal, EnabledAssetsModalTemplate, type EnabledAssetsModalTemplateProps, KycFlow, KycModal, KycModalTemplate, KycStatus, type KycStep, type LoginButtonProps, LoginModalTemplate, type ModalChrome, type ModalStyleOverrides, type ModalVariant, type PollarConfig, PollarProvider, type PollarStyles, ProviderRegistrationModal, type RampModalOptions, type RampStep, RampWidget, RampWidgetTemplate, ReceiveModal, type ReceiveModalOptions, ReceiveModalTemplate, type ReceiveModalTemplateProps, RecoveryModal, RecoveryModalTemplate, type RecoveryModalTemplateProps, type RecoveryView, RegistryCheckModal, RejectedRouteDisplay, RequirementFormModal, RouteDisplay, type SendMemoType, SendModal, type SendModalOptions, SendModalTemplate, type SendModalTemplateProps, SessionsModal, SessionsModalTemplate, type SessionsModalTemplateProps, type SwapAssetOption, SwapModal, type SwapModalOptions, SwapModalTemplate, type SwapModalTemplateProps, TransactionModalTemplate, type TransactionModalTemplateProps, type TxHistoryModalOptions, TxHistoryModalTemplate, TxStatusView, type TxStatusViewProps, type UseChainsResult, type UseCosignResult, WalletBalanceModal, WalletBalanceModalTemplate, type WalletBalanceModalTemplateProps, WalletButton, WalletButtonTemplate, type WalletButtonTemplateProps, addressForChain, browserPasskeyCeremony, browserPasskeySigner, browserRecoveryPasskey, buildModalCssVars, chainsOf, createPollarAdapterHook, modalChrome, readableTextOn, resolveChain, useChains, useCosign, usePollar, walletNotReadyReason };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { WalletChain, pollarPaths, WalletBalanceRecord, TransactionState, WalletId, PollarLanguage, PendingConfirmation, StellarNetwork, SwapQuoteParams, SwapDestinationChain, BridgeChain, BridgeTransfer, EarnProviderId, CardFundingChain, CardFunding, PollarClient, PollarClientConfig, PollarAdapters, OnStorageDegrade, WalletInfo, CosignCustody, PollarLoginOptions, SessionsState, CosignState, RecoveryState, CustodyMigrationState, TxBuildBody, BuildOutcome, SubmitOutcome, SignOutcome, SendPaymentParams, WalletBalanceState, EnabledAssetsState, TrustlineOutcome, TxHistoryState, SwapVenue, SwapToken, SwapQuote, SolanaSwapVenue, SolanaSwapQuoteParams, SolanaSwapQuote, SolanaSwapOptions, SwapStatus, EarnOpportunity, EarnPositionParams, EarnPosition, EarnTxParams, SolanaEarnProviderId, SolanaEarnOpportunity, SolanaEarnPosition, SolanaEarnTxParams, PollarAdapter, AuthEntryAdapterStep, AuthEntryAdapterOutcome, PasskeyCeremony, PasskeySigner, RecoveryPasskeyCeremony, CosignRequest, CosignVerification, CosignQuorumReport, CosignDevicesContent, KycStatus as KycStatus$1, RampQuoteRejection, RampQuoteRequirement, RampWalletStep, RampQuote, AuthState, KycProvider, KycStartResponse, RampDirection, RampFiat, RampAsset, RampField, RampOrder, EnabledAssetRecord, BridgeQuote, DistributionRulesState, DistributionRule } from '@pollar/core';
2
+ import { WalletChain, pollarPaths, WalletBalanceRecord, TransactionState, WalletId, PollarLanguage, PendingConfirmation, StellarNetwork, SwapQuoteParams, SwapDestinationChain, BridgeChain, BridgeTransfer, EarnProviderId, CardFundingChain, CardFunding, PollarClient, PollarClientConfig, PollarAdapters, OnStorageDegrade, WalletInfo, CosignCustody, PollarLoginOptions, SessionsState, CosignState, RecoveryState, CustodyMigrationState, TxBuildBody, BuildOutcome, SubmitOutcome, SignOutcome, SendPaymentParams, WalletBalanceState, EnabledAssetsState, TrustlineOutcome, TxHistoryState, SwapVenue, SwapToken, SwapQuote, SolanaSwapVenue, SolanaSwapQuoteParams, SolanaSwapQuote, SolanaSwapOptions, SwapStatus, EarnOpportunity, EarnPositionParams, EarnPosition, EarnTxParams, SolanaEarnProviderId, SolanaEarnOpportunity, SolanaEarnPosition, SolanaEarnTxParams, PollarAdapter, AuthEntryAdapterStep, AuthEntryAdapterOutcome, PasskeyCeremony, PasskeySigner, RecoveryPasskeyCeremony, CosignRequest, CosignVerification, CosignQuorumReport, CosignDevicesContent, KycStatus as KycStatus$1, RampQuoteRejection, RampQuoteRequirement, RampWalletStep, RampQuote, AuthState, KycProvider, KycStartResponse, RampDirection, RampFiat, RampAsset, RampField, RampOrder, PollarSupportContact, EnabledAssetRecord, BridgeQuote, DistributionRulesState, DistributionRule } from '@pollar/core';
3
3
  export { AuthProviderContext, PollarAuthProvider, SessionsState } from '@pollar/core';
4
4
  import { CSSProperties, ReactNode } from 'react';
5
5
 
@@ -212,6 +212,51 @@ interface SendModalProps {
212
212
  }
213
213
  declare function SendModal({ onClose, initial }: SendModalProps): react_jsx_runtime.JSX.Element;
214
214
 
215
+ /** One end of the flow: a wallet, an account or a contract, and what it sends or gets. */
216
+ interface TxParty {
217
+ chain?: WalletChain;
218
+ asset?: string;
219
+ amount?: string;
220
+ /** The amount is a floor: a swap delivers at least it. */
221
+ minimum?: boolean;
222
+ address?: string;
223
+ label?: string;
224
+ /** One of the user's own wallets. */
225
+ self?: boolean;
226
+ }
227
+ interface TxDetailRow {
228
+ label: string;
229
+ value: string;
230
+ /** What the copy button copies; the row has none when absent. */
231
+ copyValue?: string;
232
+ /** Opens this page: the value is a link (an explorer on another chain). */
233
+ href?: string;
234
+ mono?: boolean;
235
+ }
236
+ interface TxReviewData {
237
+ /** The action in plain words: what a user without crypto background reads first. */
238
+ title: string;
239
+ kind: 'send' | 'bridge' | 'approve' | 'swap' | 'payment' | 'create_account' | 'activate_wallet' | 'add_asset' | 'deposit' | 'withdraw' | 'sign_in' | 'other';
240
+ /** One line under the title that says what the action is for, when the title alone does not. */
241
+ lead?: string;
242
+ from?: TxParty;
243
+ to?: TxParty;
244
+ /**
245
+ * Who pays the network fee: after the signature, as the platform reported it;
246
+ * before, only when the transaction itself makes the app pay (`appPaysFee`).
247
+ */
248
+ fee?: {
249
+ sponsored: boolean;
250
+ free?: boolean;
251
+ };
252
+ rows: TxDetailRow[];
253
+ raw?: string;
254
+ hash?: {
255
+ value: string;
256
+ explorerUrl: string | null;
257
+ };
258
+ }
259
+
215
260
  /** The chain a swap runs on; the modal shows a selector when the app offers both. */
216
261
  type SwapChain = 'STELLAR' | 'SOLANA';
217
262
  interface SwapAssetOption {
@@ -271,6 +316,8 @@ interface SwapModalTemplateProps {
271
316
  settlement?: SwapSettlementView | null;
272
317
  /** The signature waiting for the user's yes, answered in the transaction step. */
273
318
  confirmation?: PendingConfirmation | null | undefined;
319
+ /** What the transaction step reviews when the transaction carries no build of its own to read it from. */
320
+ review?: TxReviewData | null | undefined;
274
321
  /** The app's network, for the details of a confirmation. */
275
322
  network?: StellarNetwork | undefined;
276
323
  provider: string;
@@ -311,7 +358,7 @@ interface SwapModalTemplateProps {
311
358
  onRetry: () => void;
312
359
  onDone: () => void;
313
360
  }
314
- declare function SwapModalTemplate({ theme, accentColor, styleOverrides, step, txTitle, sellOptions, buyOptions, selectedSell, selectedBuy, amount, chains, chain, destinations, destination, usdcAcross, settlement, confirmation, network, provider, providers, quote, quoteLoading, quoteError, formError, isLoadingData, smartUnsupported, configLoading, swapUnavailable, buyNeedsTrustline, transaction, showXdr, copied, explorerUrl, walletType, showBack, isInProgress, language: languageProp, onClose, onBack, onRefresh, onSelectSell, onSelectBuy, onAddCustomToken, onReverse, onMax, onAmountChange, onChainChange, onDestinationChange, onProviderChange, onSwap, onToggleXdr, onCopyHash, onRetry, onDone, }: SwapModalTemplateProps): react_jsx_runtime.JSX.Element;
361
+ declare function SwapModalTemplate({ theme, accentColor, styleOverrides, step, txTitle, sellOptions, buyOptions, selectedSell, selectedBuy, amount, chains, chain, destinations, destination, usdcAcross, settlement, confirmation, review, network, provider, providers, quote, quoteLoading, quoteError, formError, isLoadingData, smartUnsupported, configLoading, swapUnavailable, buyNeedsTrustline, transaction, showXdr, copied, explorerUrl, walletType, showBack, isInProgress, language: languageProp, onClose, onBack, onRefresh, onSelectSell, onSelectBuy, onAddCustomToken, onReverse, onMax, onAmountChange, onChainChange, onDestinationChange, onProviderChange, onSwap, onToggleXdr, onCopyHash, onRetry, onDone, }: SwapModalTemplateProps): react_jsx_runtime.JSX.Element;
315
362
 
316
363
  /** Where the swap modal opens: a starting point the user can change. An option the app does not offer is left out. */
317
364
  interface SwapModalOptions {
@@ -928,8 +975,24 @@ interface KycModalProps {
928
975
  onApproved?: () => void;
929
976
  /** Language of the modal, as a BCP 47 tag. A language pinned in the dashboard wins over it. */
930
977
  language?: string | undefined;
978
+ /** Render the card in the page instead of over a backdrop, without its close buttons. */
979
+ inline?: boolean;
980
+ }
981
+ declare function KycModal({ onClose, country, level, onApproved, corridorId, cardProviderId, providerId, language: languageProp, inline, }: KycModalProps): react_jsx_runtime.JSX.Element;
982
+
983
+ interface KycFlowProps {
984
+ /** Called once every step is complete; the flow then renders nothing. */
985
+ onApproved?: () => void;
986
+ country?: string;
987
+ level?: 'basic' | 'intermediate' | 'enhanced';
931
988
  }
932
- declare function KycModal({ onClose, country, level, onApproved, corridorId, cardProviderId, providerId, language: languageProp, }: KycModalProps): react_jsx_runtime.JSX.Element;
989
+ /**
990
+ * The app's own KYC, step by step, in the host's page instead of modals: for a
991
+ * page made for verifying, like a KYC link's. Each pending step shows as a card
992
+ * where it is placed (the vendor's verification, or a form) and the next one
993
+ * replaces it as soon as it is done. Signed-in users only.
994
+ */
995
+ declare function KycFlow({ onApproved, country, level }: KycFlowProps): react_jsx_runtime.JSX.Element;
933
996
 
934
997
  interface RequirementFormModalProps {
935
998
  formId: string;
@@ -943,9 +1006,11 @@ interface RequirementFormModalProps {
943
1006
  onSubmitted: () => void;
944
1007
  /** Language of the modal, as a BCP 47 tag. A language pinned in the dashboard wins over it. */
945
1008
  language?: string | undefined;
1009
+ /** Render the card in the page instead of over a backdrop, without its close buttons. */
1010
+ inline?: boolean;
946
1011
  }
947
1012
  /** One FORM requirement step: the form a route asks for, prefilled with the user's previous answers. */
948
- declare function RequirementFormModal({ formId, progress, onClose, onSubmitted, language: languageProp, }: RequirementFormModalProps): react_jsx_runtime.JSX.Element;
1013
+ declare function RequirementFormModal({ formId, progress, onClose, onSubmitted, language: languageProp, inline, }: RequirementFormModalProps): react_jsx_runtime.JSX.Element;
949
1014
 
950
1015
  interface RegistryCheckModalProps {
951
1016
  optionId: string;
@@ -1165,8 +1230,10 @@ interface KycModalTemplateProps {
1165
1230
  onClose: () => void;
1166
1231
  /** Defaults to the user's device; the modal passes the resolved one. */
1167
1232
  language?: PollarLanguage | undefined;
1233
+ /** In the host's page rather than over a backdrop: a region, with no close buttons. */
1234
+ inline?: boolean;
1168
1235
  }
1169
- declare function KycModalTemplate({ theme, accentColor, styleOverrides, step, providers, selectedProvider, session, kycStatus, reviewReason, processing, isLoading, startingProviderId, directOpen, error, onSelectProvider, onDoneVerifying, onStartAgain, onRefresh, onClose, language, }: KycModalTemplateProps): react_jsx_runtime.JSX.Element;
1236
+ declare function KycModalTemplate({ theme, accentColor, styleOverrides, step, providers, selectedProvider, session, kycStatus, reviewReason, processing, isLoading, startingProviderId, directOpen, error, onSelectProvider, onDoneVerifying, onStartAgain, onRefresh, onClose, language, inline, }: KycModalTemplateProps): react_jsx_runtime.JSX.Element;
1170
1237
 
1171
1238
  type RampStep = 'input' | 'loading_quote' | 'select_route' | 'contact' | 'status' | 'error';
1172
1239
  interface RampWidgetTemplateProps {
@@ -1257,6 +1324,8 @@ interface RampWidgetTemplateProps {
1257
1324
  onSetUpRecovery?: (() => void) | undefined;
1258
1325
  /** Whether the wallet still has no way to be recovered; null while its state is unread. */
1259
1326
  recoveryMissing?: boolean | null;
1327
+ /** The app's support contact, linked when an order asks the user to contact support. */
1328
+ support?: PollarSupportContact | null;
1260
1329
  /** Reading the order keeps failing and polling is retrying. */
1261
1330
  pollTrouble?: boolean;
1262
1331
  /** The fiat payment the user says they made is being checked. */
@@ -1279,7 +1348,7 @@ interface RampWidgetTemplateProps {
1279
1348
  /** A leg's signature waiting for the user's yes, answered in the status view. */
1280
1349
  confirmation?: PendingConfirmation | null | undefined;
1281
1350
  }
1282
- declare function RampWidgetTemplate({ theme, accentColor, styleOverrides, network, step, flowSteps, flowStepIndex, direction, routesLoading, countries, country, fiats, fiat, assets, asset, amount, sellAvailable, quotes, rejected, startingQuoteId, fields, fieldValues, order, pendingOrders, isLoading, refreshing, signing, errorMsg, notice, onDirectionChange, onCountryChange, onFiatChange, onAssetChange, onAmountChange, onFindRoute, quoting, routeChoice, chosenQuote, onRouteChoice, onContinue, onSelectQuote, onVerifyRoute, trustingAsset, onTrustAsset, walletBusy, custodyChoice, onWalletStep, noChains, retrying, onRetryOrder, onRequote, onSetUpRecovery, recoveryMissing, checkingPayment, onCheckPayment, pollTrouble, onFieldChange, onContactContinue, onSign, onApprove, onResumeOrder, onNewOrder, onBack, onStepSelect, onRetry, onRefresh, onClose, language: languageProp, confirmation, }: RampWidgetTemplateProps): react_jsx_runtime.JSX.Element;
1351
+ declare function RampWidgetTemplate({ theme, accentColor, styleOverrides, network, step, flowSteps, flowStepIndex, direction, routesLoading, countries, country, fiats, fiat, assets, asset, amount, sellAvailable, quotes, rejected, startingQuoteId, fields, fieldValues, order, pendingOrders, isLoading, refreshing, signing, errorMsg, notice, onDirectionChange, onCountryChange, onFiatChange, onAssetChange, onAmountChange, onFindRoute, quoting, routeChoice, chosenQuote, onRouteChoice, onContinue, onSelectQuote, onVerifyRoute, trustingAsset, onTrustAsset, walletBusy, custodyChoice, onWalletStep, noChains, retrying, onRetryOrder, onRequote, onSetUpRecovery, recoveryMissing, support, checkingPayment, onCheckPayment, pollTrouble, onFieldChange, onContactContinue, onSign, onApprove, onResumeOrder, onNewOrder, onBack, onStepSelect, onRetry, onRefresh, onClose, language: languageProp, confirmation, }: RampWidgetTemplateProps): react_jsx_runtime.JSX.Element;
1283
1352
 
1284
1353
  interface TransactionModalTemplateProps {
1285
1354
  theme: string;
@@ -1305,51 +1374,6 @@ interface TransactionModalTemplateProps {
1305
1374
  }
1306
1375
  declare function TransactionModalTemplate({ theme, accentColor, styleOverrides, transaction, showXdr, copied, explorerUrl, walletType, onClose, onSignAndSend, onToggleXdr, onCopyHash, onRetry, language: languageProp, confirmation, network, }: TransactionModalTemplateProps): react_jsx_runtime.JSX.Element;
1307
1376
 
1308
- /** One end of the flow: a wallet, an account or a contract, and what it sends or gets. */
1309
- interface TxParty {
1310
- chain?: WalletChain;
1311
- asset?: string;
1312
- amount?: string;
1313
- /** The amount is a floor: a swap delivers at least it. */
1314
- minimum?: boolean;
1315
- address?: string;
1316
- label?: string;
1317
- /** One of the user's own wallets. */
1318
- self?: boolean;
1319
- }
1320
- interface TxDetailRow {
1321
- label: string;
1322
- value: string;
1323
- /** What the copy button copies; the row has none when absent. */
1324
- copyValue?: string;
1325
- /** Opens this page: the value is a link (an explorer on another chain). */
1326
- href?: string;
1327
- mono?: boolean;
1328
- }
1329
- interface TxReviewData {
1330
- /** The action in plain words: what a user without crypto background reads first. */
1331
- title: string;
1332
- kind: 'send' | 'bridge' | 'approve' | 'swap' | 'payment' | 'create_account' | 'activate_wallet' | 'add_asset' | 'deposit' | 'withdraw' | 'sign_in' | 'other';
1333
- /** One line under the title that says what the action is for, when the title alone does not. */
1334
- lead?: string;
1335
- from?: TxParty;
1336
- to?: TxParty;
1337
- /**
1338
- * Who pays the network fee: after the signature, as the platform reported it;
1339
- * before, only when the transaction itself makes the app pay (`appPaysFee`).
1340
- */
1341
- fee?: {
1342
- sponsored: boolean;
1343
- free?: boolean;
1344
- };
1345
- rows: TxDetailRow[];
1346
- raw?: string;
1347
- hash?: {
1348
- value: string;
1349
- explorerUrl: string | null;
1350
- };
1351
- }
1352
-
1353
1377
  interface TxStatusViewProps {
1354
1378
  transaction: TransactionState;
1355
1379
  /** Whether the details (addresses, network, fee, raw transaction, hash) are unfolded. */
@@ -1729,4 +1753,4 @@ interface DistributionRulesModalTemplateProps {
1729
1753
  }
1730
1754
  declare function DistributionRulesModalTemplate({ theme, accentColor, styleOverrides, state, claimingId, claimErrors, claimedIds, language: languageProp, onRefresh, onClaim, onClose, }: DistributionRulesModalTemplateProps): react_jsx_runtime.JSX.Element;
1731
1755
 
1732
- export { type AuthModalProps, BridgeModal, type BridgeModalOptions, type BridgeModalStep, BridgeModalTemplate, type BridgeModalTemplateProps, CardModal, type CardModalOptions, ChainSelect, type ChainSelectProps, CosignModal, CosignModalTemplate, type CosignModalTemplateProps, CustodyMigrationModal, CustodyMigrationModalTemplate, type CustodyMigrationModalTemplateProps, type CustomTrustlineModalTemplateProps, DistributionRulesModal, DistributionRulesModalTemplate, EarnModal, type EarnModalOptions, type EarnNetwork, EnabledAssetsModal, EnabledAssetsModalTemplate, type EnabledAssetsModalTemplateProps, KycModal, KycModalTemplate, KycStatus, type KycStep, type LoginButtonProps, LoginModalTemplate, type ModalChrome, type ModalStyleOverrides, type ModalVariant, type PollarConfig, PollarProvider, type PollarStyles, ProviderRegistrationModal, type RampModalOptions, type RampStep, RampWidget, RampWidgetTemplate, ReceiveModal, type ReceiveModalOptions, ReceiveModalTemplate, type ReceiveModalTemplateProps, RecoveryModal, RecoveryModalTemplate, type RecoveryModalTemplateProps, type RecoveryView, RegistryCheckModal, RejectedRouteDisplay, RequirementFormModal, RouteDisplay, type SendMemoType, SendModal, type SendModalOptions, SendModalTemplate, type SendModalTemplateProps, SessionsModal, SessionsModalTemplate, type SessionsModalTemplateProps, type SwapAssetOption, SwapModal, type SwapModalOptions, SwapModalTemplate, type SwapModalTemplateProps, TransactionModalTemplate, type TransactionModalTemplateProps, type TxHistoryModalOptions, TxHistoryModalTemplate, TxStatusView, type TxStatusViewProps, type UseChainsResult, type UseCosignResult, WalletBalanceModal, WalletBalanceModalTemplate, type WalletBalanceModalTemplateProps, WalletButton, WalletButtonTemplate, type WalletButtonTemplateProps, addressForChain, browserPasskeyCeremony, browserPasskeySigner, browserRecoveryPasskey, buildModalCssVars, chainsOf, createPollarAdapterHook, modalChrome, readableTextOn, resolveChain, useChains, useCosign, usePollar, walletNotReadyReason };
1756
+ export { type AuthModalProps, BridgeModal, type BridgeModalOptions, type BridgeModalStep, BridgeModalTemplate, type BridgeModalTemplateProps, CardModal, type CardModalOptions, ChainSelect, type ChainSelectProps, CosignModal, CosignModalTemplate, type CosignModalTemplateProps, CustodyMigrationModal, CustodyMigrationModalTemplate, type CustodyMigrationModalTemplateProps, type CustomTrustlineModalTemplateProps, DistributionRulesModal, DistributionRulesModalTemplate, EarnModal, type EarnModalOptions, type EarnNetwork, EnabledAssetsModal, EnabledAssetsModalTemplate, type EnabledAssetsModalTemplateProps, KycFlow, KycModal, KycModalTemplate, KycStatus, type KycStep, type LoginButtonProps, LoginModalTemplate, type ModalChrome, type ModalStyleOverrides, type ModalVariant, type PollarConfig, PollarProvider, type PollarStyles, ProviderRegistrationModal, type RampModalOptions, type RampStep, RampWidget, RampWidgetTemplate, ReceiveModal, type ReceiveModalOptions, ReceiveModalTemplate, type ReceiveModalTemplateProps, RecoveryModal, RecoveryModalTemplate, type RecoveryModalTemplateProps, type RecoveryView, RegistryCheckModal, RejectedRouteDisplay, RequirementFormModal, RouteDisplay, type SendMemoType, SendModal, type SendModalOptions, SendModalTemplate, type SendModalTemplateProps, SessionsModal, SessionsModalTemplate, type SessionsModalTemplateProps, type SwapAssetOption, SwapModal, type SwapModalOptions, SwapModalTemplate, type SwapModalTemplateProps, TransactionModalTemplate, type TransactionModalTemplateProps, type TxHistoryModalOptions, TxHistoryModalTemplate, TxStatusView, type TxStatusViewProps, type UseChainsResult, type UseCosignResult, WalletBalanceModal, WalletBalanceModalTemplate, type WalletBalanceModalTemplateProps, WalletButton, WalletButtonTemplate, type WalletButtonTemplateProps, addressForChain, browserPasskeyCeremony, browserPasskeySigner, browserRecoveryPasskey, buildModalCssVars, chainsOf, createPollarAdapterHook, modalChrome, readableTextOn, resolveChain, useChains, useCosign, usePollar, walletNotReadyReason };