@swype-org/react-sdk 0.1.207 → 0.2.1-betatest
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.cjs +677 -19
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +98 -3
- package/dist/index.d.ts +98 -3
- package/dist/index.js +675 -21
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -207,8 +207,22 @@ interface UserConfig {
|
|
|
207
207
|
}
|
|
208
208
|
/** Theme mode */
|
|
209
209
|
type ThemeMode = 'light' | 'dark';
|
|
210
|
+
/** Relay deposit step returned by the guest quote endpoint */
|
|
211
|
+
interface RelayDepositStep {
|
|
212
|
+
to: string;
|
|
213
|
+
data: string;
|
|
214
|
+
value: string;
|
|
215
|
+
chainId: number;
|
|
216
|
+
}
|
|
217
|
+
/** Guest quote response from the API */
|
|
218
|
+
interface GuestQuote {
|
|
219
|
+
requestId: string;
|
|
220
|
+
estimatedFeeUsd: string;
|
|
221
|
+
estimatedOutput: string;
|
|
222
|
+
steps: RelayDepositStep[];
|
|
223
|
+
}
|
|
210
224
|
/** Steps in the payment flow */
|
|
211
|
-
type PaymentStep = 'login' | 'otp-verify' | 'create-passkey' | 'verify-passkey' | 'wallet-picker' | 'open-wallet' | 'setup-status' | 'setup' | 'confirm-sign' | 'deposit' | 'low-balance' | 'processing' | 'select-source' | 'token-picker' | 'success';
|
|
225
|
+
type PaymentStep = 'guest-deposit' | 'guest-connecting' | 'guest-signing' | 'login' | 'otp-verify' | 'create-passkey' | 'verify-passkey' | 'wallet-picker' | 'open-wallet' | 'setup-status' | 'setup' | 'confirm-sign' | 'deposit' | 'low-balance' | 'processing' | 'select-source' | 'token-picker' | 'success' | 'offer-setup' | 'setup-complete';
|
|
212
226
|
/** User-selected advanced settings for chain/asset override */
|
|
213
227
|
interface AdvancedSettings {
|
|
214
228
|
/** Override asset (e.g. 'USDC', 'USDT'). Null = let backend decide. */
|
|
@@ -380,16 +394,55 @@ declare function updateUserConfigBySession(apiBaseUrl: string, sessionId: string
|
|
|
380
394
|
defaultAllowance: number;
|
|
381
395
|
}): Promise<void>;
|
|
382
396
|
declare function reportActionCompletion(apiBaseUrl: string, actionId: string, result: Record<string, unknown>): Promise<AuthorizationSessionDetail>;
|
|
397
|
+
interface GuestQuoteParams {
|
|
398
|
+
merchantAuthorization: MerchantAuthorization;
|
|
399
|
+
sourceAddress: string;
|
|
400
|
+
sourceChainId: number;
|
|
401
|
+
sourceToken: string;
|
|
402
|
+
destinationChainId: number;
|
|
403
|
+
destinationAddress: string;
|
|
404
|
+
destinationToken: string;
|
|
405
|
+
amount: string;
|
|
406
|
+
}
|
|
407
|
+
declare function fetchGuestQuote(apiBaseUrl: string, params: GuestQuoteParams): Promise<GuestQuote>;
|
|
408
|
+
interface CreateGuestTransferParams {
|
|
409
|
+
id: string;
|
|
410
|
+
merchantAuthorization: MerchantAuthorization;
|
|
411
|
+
requestId: string;
|
|
412
|
+
originTxHash: string;
|
|
413
|
+
sourceChainId: number;
|
|
414
|
+
sourceAddress: string;
|
|
415
|
+
destinationChainId: number;
|
|
416
|
+
destinationAddress: string;
|
|
417
|
+
destinationToken: string;
|
|
418
|
+
amount: {
|
|
419
|
+
amount: number;
|
|
420
|
+
currency: string;
|
|
421
|
+
};
|
|
422
|
+
}
|
|
423
|
+
declare function createGuestTransfer(apiBaseUrl: string, params: CreateGuestTransferParams): Promise<{
|
|
424
|
+
id: string;
|
|
425
|
+
status: string;
|
|
426
|
+
}>;
|
|
427
|
+
declare function fetchGuestTransfer(apiBaseUrl: string, transferId: string): Promise<{
|
|
428
|
+
id: string;
|
|
429
|
+
status: string;
|
|
430
|
+
}>;
|
|
383
431
|
|
|
384
432
|
type api_CreateAccountParams = CreateAccountParams;
|
|
433
|
+
type api_CreateGuestTransferParams = CreateGuestTransferParams;
|
|
385
434
|
type api_CreateTransferParams = CreateTransferParams;
|
|
435
|
+
type api_GuestQuoteParams = GuestQuoteParams;
|
|
386
436
|
declare const api_createAccount: typeof createAccount;
|
|
387
437
|
declare const api_createAccountAuthorizationSession: typeof createAccountAuthorizationSession;
|
|
438
|
+
declare const api_createGuestTransfer: typeof createGuestTransfer;
|
|
388
439
|
declare const api_createTransfer: typeof createTransfer;
|
|
389
440
|
declare const api_fetchAccount: typeof fetchAccount;
|
|
390
441
|
declare const api_fetchAccounts: typeof fetchAccounts;
|
|
391
442
|
declare const api_fetchAuthorizationSession: typeof fetchAuthorizationSession;
|
|
392
443
|
declare const api_fetchChains: typeof fetchChains;
|
|
444
|
+
declare const api_fetchGuestQuote: typeof fetchGuestQuote;
|
|
445
|
+
declare const api_fetchGuestTransfer: typeof fetchGuestTransfer;
|
|
393
446
|
declare const api_fetchMerchantPublicKey: typeof fetchMerchantPublicKey;
|
|
394
447
|
declare const api_fetchProviders: typeof fetchProviders;
|
|
395
448
|
declare const api_fetchTransfer: typeof fetchTransfer;
|
|
@@ -401,7 +454,7 @@ declare const api_signTransfer: typeof signTransfer;
|
|
|
401
454
|
declare const api_updateUserConfig: typeof updateUserConfig;
|
|
402
455
|
declare const api_updateUserConfigBySession: typeof updateUserConfigBySession;
|
|
403
456
|
declare namespace api {
|
|
404
|
-
export { type api_CreateAccountParams as CreateAccountParams, type api_CreateTransferParams as CreateTransferParams, api_createAccount as createAccount, api_createAccountAuthorizationSession as createAccountAuthorizationSession, api_createTransfer as createTransfer, api_fetchAccount as fetchAccount, api_fetchAccounts as fetchAccounts, api_fetchAuthorizationSession as fetchAuthorizationSession, api_fetchChains as fetchChains, api_fetchMerchantPublicKey as fetchMerchantPublicKey, api_fetchProviders as fetchProviders, api_fetchTransfer as fetchTransfer, api_fetchUserConfig as fetchUserConfig, api_registerPasskey as registerPasskey, api_reportActionCompletion as reportActionCompletion, api_reportPasskeyActivity as reportPasskeyActivity, api_signTransfer as signTransfer, api_updateUserConfig as updateUserConfig, api_updateUserConfigBySession as updateUserConfigBySession };
|
|
457
|
+
export { type api_CreateAccountParams as CreateAccountParams, type api_CreateGuestTransferParams as CreateGuestTransferParams, type api_CreateTransferParams as CreateTransferParams, type api_GuestQuoteParams as GuestQuoteParams, api_createAccount as createAccount, api_createAccountAuthorizationSession as createAccountAuthorizationSession, api_createGuestTransfer as createGuestTransfer, api_createTransfer as createTransfer, api_fetchAccount as fetchAccount, api_fetchAccounts as fetchAccounts, api_fetchAuthorizationSession as fetchAuthorizationSession, api_fetchChains as fetchChains, api_fetchGuestQuote as fetchGuestQuote, api_fetchGuestTransfer as fetchGuestTransfer, api_fetchMerchantPublicKey as fetchMerchantPublicKey, api_fetchProviders as fetchProviders, api_fetchTransfer as fetchTransfer, api_fetchUserConfig as fetchUserConfig, api_registerPasskey as registerPasskey, api_reportActionCompletion as reportActionCompletion, api_reportPasskeyActivity as reportPasskeyActivity, api_signTransfer as signTransfer, api_updateUserConfig as updateUserConfig, api_updateUserConfigBySession as updateUserConfigBySession };
|
|
405
458
|
}
|
|
406
459
|
|
|
407
460
|
interface SwypePaymentProps {
|
|
@@ -415,6 +468,12 @@ interface SwypePaymentProps {
|
|
|
415
468
|
onBack?: () => void;
|
|
416
469
|
onDismiss?: () => void;
|
|
417
470
|
autoCloseSeconds?: number;
|
|
471
|
+
/** EVM numeric chain ID for the source chain (guest flow). */
|
|
472
|
+
sourceChainId?: number;
|
|
473
|
+
/** Source token contract address (guest flow). */
|
|
474
|
+
sourceToken?: string;
|
|
475
|
+
/** Destination EVM numeric chain ID (guest flow). */
|
|
476
|
+
destinationChainId?: number;
|
|
418
477
|
}
|
|
419
478
|
declare function SwypePayment(props: SwypePaymentProps): react_jsx_runtime.JSX.Element;
|
|
420
479
|
|
|
@@ -812,6 +871,42 @@ interface TokenPickerScreenProps {
|
|
|
812
871
|
}
|
|
813
872
|
declare function TokenPickerScreen({ account, chains, onSelectAuthorized, onAuthorizeToken, onBack, onLogout, depositAmount, selectedTokenSymbol, selectedWalletId, }: TokenPickerScreenProps): react_jsx_runtime.JSX.Element;
|
|
814
873
|
|
|
874
|
+
interface GuestDepositScreenProps {
|
|
875
|
+
amount: number;
|
|
876
|
+
currency: string;
|
|
877
|
+
merchantName?: string;
|
|
878
|
+
onConfirm: () => void;
|
|
879
|
+
onSignIn: () => void;
|
|
880
|
+
onBack?: () => void;
|
|
881
|
+
loading?: boolean;
|
|
882
|
+
error?: string | null;
|
|
883
|
+
}
|
|
884
|
+
declare function GuestDepositScreen({ amount, currency, merchantName, onConfirm, onSignIn, onBack, loading, error, }: GuestDepositScreenProps): react_jsx_runtime.JSX.Element;
|
|
885
|
+
|
|
886
|
+
type GuestWalletPhase = 'connecting' | 'fetching-quote' | 'approving' | 'signing' | 'submitting';
|
|
887
|
+
interface GuestWalletScreenProps {
|
|
888
|
+
phase: GuestWalletPhase;
|
|
889
|
+
amount: number;
|
|
890
|
+
currency: string;
|
|
891
|
+
onBack?: () => void;
|
|
892
|
+
error?: string | null;
|
|
893
|
+
onRetry?: () => void;
|
|
894
|
+
}
|
|
895
|
+
declare function GuestWalletScreen({ phase, amount, currency, onBack, error, onRetry, }: GuestWalletScreenProps): react_jsx_runtime.JSX.Element;
|
|
896
|
+
|
|
897
|
+
interface OfferSetupScreenProps {
|
|
898
|
+
amount: number;
|
|
899
|
+
currency: string;
|
|
900
|
+
onSetup: () => void;
|
|
901
|
+
onDone: () => void;
|
|
902
|
+
}
|
|
903
|
+
declare function OfferSetupScreen({ amount, currency, onSetup, onDone, }: OfferSetupScreenProps): react_jsx_runtime.JSX.Element;
|
|
904
|
+
|
|
905
|
+
interface SetupCompleteScreenProps {
|
|
906
|
+
onDone: () => void;
|
|
907
|
+
}
|
|
908
|
+
declare function SetupCompleteScreen({ onDone }: SetupCompleteScreenProps): react_jsx_runtime.JSX.Element;
|
|
909
|
+
|
|
815
910
|
type FlowPhase = 'link' | 'deposit';
|
|
816
911
|
|
|
817
912
|
declare function FlowPhaseProvider({ phase, children, }: {
|
|
@@ -823,4 +918,4 @@ declare const SWYPE_LOGO: string;
|
|
|
823
918
|
/** @deprecated Use SWYPE_LOGO instead. Kept for backward compatibility. */
|
|
824
919
|
declare const SWYPE_MASCOT: string;
|
|
825
920
|
|
|
826
|
-
export { type Account, type ActionExecutionResult, type AdvancedSettings, AdvancedSourceScreen, type Amount, type AuthorizationAction, type AuthorizationSession, type AuthorizationSessionDetail, type Chain, type Destination, type ErrorResponse, type FlowPhase, FlowPhaseProvider, IconCircle, InfoBanner, type ListResponse, type MerchantAuthorization, type MerchantPublicKey, OutlineButton, PasskeyIframeBlockedError, PasskeyScreen, type PaymentStep, PoweredByFooter, PrimaryButton, type Provider, SWYPE_LOGO, SWYPE_MASCOT, ScreenHeader, ScreenLayout, SelectSourceScreen, SettingsMenu, SetupScreen, type SourceOption, type SourceSelection, type SourceType, Spinner, type StepItem, StepList, SwypeLoadingScreen, SwypePayment, type SwypePaymentProps, SwypeProvider, type SwypeProviderProps, type ThemeMode, type ThemeTokens, type TokenBalance, TokenPickerScreen, type Transfer, type TransferDestination, type UserConfig, type Wallet, type WalletSource, type WalletToken, buildPasskeyPopupOptions, createPasskeyCredential, createPasskeyViaPopup, darkTheme, deviceHasPasskey, findDevicePasskey, findDevicePasskeyViaPopup, getTheme, lightTheme, resolvePasskeyRpId, api as swypeApi, useAuthorizationExecutor, useSwypeConfig, useSwypeDepositAmount, useTransferPolling, useTransferSigning };
|
|
921
|
+
export { type Account, type ActionExecutionResult, type AdvancedSettings, AdvancedSourceScreen, type Amount, type AuthorizationAction, type AuthorizationSession, type AuthorizationSessionDetail, type Chain, type Destination, type ErrorResponse, type FlowPhase, FlowPhaseProvider, GuestDepositScreen, type GuestQuote, GuestWalletScreen, IconCircle, InfoBanner, type ListResponse, type MerchantAuthorization, type MerchantPublicKey, OfferSetupScreen, OutlineButton, PasskeyIframeBlockedError, PasskeyScreen, type PaymentStep, PoweredByFooter, PrimaryButton, type Provider, type RelayDepositStep, SWYPE_LOGO, SWYPE_MASCOT, ScreenHeader, ScreenLayout, SelectSourceScreen, SettingsMenu, SetupCompleteScreen, SetupScreen, type SourceOption, type SourceSelection, type SourceType, Spinner, type StepItem, StepList, SwypeLoadingScreen, SwypePayment, type SwypePaymentProps, SwypeProvider, type SwypeProviderProps, type ThemeMode, type ThemeTokens, type TokenBalance, TokenPickerScreen, type Transfer, type TransferDestination, type UserConfig, type Wallet, type WalletSource, type WalletToken, buildPasskeyPopupOptions, createPasskeyCredential, createPasskeyViaPopup, darkTheme, deviceHasPasskey, findDevicePasskey, findDevicePasskeyViaPopup, getTheme, lightTheme, resolvePasskeyRpId, api as swypeApi, useAuthorizationExecutor, useSwypeConfig, useSwypeDepositAmount, useTransferPolling, useTransferSigning };
|
package/dist/index.d.ts
CHANGED
|
@@ -207,8 +207,22 @@ interface UserConfig {
|
|
|
207
207
|
}
|
|
208
208
|
/** Theme mode */
|
|
209
209
|
type ThemeMode = 'light' | 'dark';
|
|
210
|
+
/** Relay deposit step returned by the guest quote endpoint */
|
|
211
|
+
interface RelayDepositStep {
|
|
212
|
+
to: string;
|
|
213
|
+
data: string;
|
|
214
|
+
value: string;
|
|
215
|
+
chainId: number;
|
|
216
|
+
}
|
|
217
|
+
/** Guest quote response from the API */
|
|
218
|
+
interface GuestQuote {
|
|
219
|
+
requestId: string;
|
|
220
|
+
estimatedFeeUsd: string;
|
|
221
|
+
estimatedOutput: string;
|
|
222
|
+
steps: RelayDepositStep[];
|
|
223
|
+
}
|
|
210
224
|
/** Steps in the payment flow */
|
|
211
|
-
type PaymentStep = 'login' | 'otp-verify' | 'create-passkey' | 'verify-passkey' | 'wallet-picker' | 'open-wallet' | 'setup-status' | 'setup' | 'confirm-sign' | 'deposit' | 'low-balance' | 'processing' | 'select-source' | 'token-picker' | 'success';
|
|
225
|
+
type PaymentStep = 'guest-deposit' | 'guest-connecting' | 'guest-signing' | 'login' | 'otp-verify' | 'create-passkey' | 'verify-passkey' | 'wallet-picker' | 'open-wallet' | 'setup-status' | 'setup' | 'confirm-sign' | 'deposit' | 'low-balance' | 'processing' | 'select-source' | 'token-picker' | 'success' | 'offer-setup' | 'setup-complete';
|
|
212
226
|
/** User-selected advanced settings for chain/asset override */
|
|
213
227
|
interface AdvancedSettings {
|
|
214
228
|
/** Override asset (e.g. 'USDC', 'USDT'). Null = let backend decide. */
|
|
@@ -380,16 +394,55 @@ declare function updateUserConfigBySession(apiBaseUrl: string, sessionId: string
|
|
|
380
394
|
defaultAllowance: number;
|
|
381
395
|
}): Promise<void>;
|
|
382
396
|
declare function reportActionCompletion(apiBaseUrl: string, actionId: string, result: Record<string, unknown>): Promise<AuthorizationSessionDetail>;
|
|
397
|
+
interface GuestQuoteParams {
|
|
398
|
+
merchantAuthorization: MerchantAuthorization;
|
|
399
|
+
sourceAddress: string;
|
|
400
|
+
sourceChainId: number;
|
|
401
|
+
sourceToken: string;
|
|
402
|
+
destinationChainId: number;
|
|
403
|
+
destinationAddress: string;
|
|
404
|
+
destinationToken: string;
|
|
405
|
+
amount: string;
|
|
406
|
+
}
|
|
407
|
+
declare function fetchGuestQuote(apiBaseUrl: string, params: GuestQuoteParams): Promise<GuestQuote>;
|
|
408
|
+
interface CreateGuestTransferParams {
|
|
409
|
+
id: string;
|
|
410
|
+
merchantAuthorization: MerchantAuthorization;
|
|
411
|
+
requestId: string;
|
|
412
|
+
originTxHash: string;
|
|
413
|
+
sourceChainId: number;
|
|
414
|
+
sourceAddress: string;
|
|
415
|
+
destinationChainId: number;
|
|
416
|
+
destinationAddress: string;
|
|
417
|
+
destinationToken: string;
|
|
418
|
+
amount: {
|
|
419
|
+
amount: number;
|
|
420
|
+
currency: string;
|
|
421
|
+
};
|
|
422
|
+
}
|
|
423
|
+
declare function createGuestTransfer(apiBaseUrl: string, params: CreateGuestTransferParams): Promise<{
|
|
424
|
+
id: string;
|
|
425
|
+
status: string;
|
|
426
|
+
}>;
|
|
427
|
+
declare function fetchGuestTransfer(apiBaseUrl: string, transferId: string): Promise<{
|
|
428
|
+
id: string;
|
|
429
|
+
status: string;
|
|
430
|
+
}>;
|
|
383
431
|
|
|
384
432
|
type api_CreateAccountParams = CreateAccountParams;
|
|
433
|
+
type api_CreateGuestTransferParams = CreateGuestTransferParams;
|
|
385
434
|
type api_CreateTransferParams = CreateTransferParams;
|
|
435
|
+
type api_GuestQuoteParams = GuestQuoteParams;
|
|
386
436
|
declare const api_createAccount: typeof createAccount;
|
|
387
437
|
declare const api_createAccountAuthorizationSession: typeof createAccountAuthorizationSession;
|
|
438
|
+
declare const api_createGuestTransfer: typeof createGuestTransfer;
|
|
388
439
|
declare const api_createTransfer: typeof createTransfer;
|
|
389
440
|
declare const api_fetchAccount: typeof fetchAccount;
|
|
390
441
|
declare const api_fetchAccounts: typeof fetchAccounts;
|
|
391
442
|
declare const api_fetchAuthorizationSession: typeof fetchAuthorizationSession;
|
|
392
443
|
declare const api_fetchChains: typeof fetchChains;
|
|
444
|
+
declare const api_fetchGuestQuote: typeof fetchGuestQuote;
|
|
445
|
+
declare const api_fetchGuestTransfer: typeof fetchGuestTransfer;
|
|
393
446
|
declare const api_fetchMerchantPublicKey: typeof fetchMerchantPublicKey;
|
|
394
447
|
declare const api_fetchProviders: typeof fetchProviders;
|
|
395
448
|
declare const api_fetchTransfer: typeof fetchTransfer;
|
|
@@ -401,7 +454,7 @@ declare const api_signTransfer: typeof signTransfer;
|
|
|
401
454
|
declare const api_updateUserConfig: typeof updateUserConfig;
|
|
402
455
|
declare const api_updateUserConfigBySession: typeof updateUserConfigBySession;
|
|
403
456
|
declare namespace api {
|
|
404
|
-
export { type api_CreateAccountParams as CreateAccountParams, type api_CreateTransferParams as CreateTransferParams, api_createAccount as createAccount, api_createAccountAuthorizationSession as createAccountAuthorizationSession, api_createTransfer as createTransfer, api_fetchAccount as fetchAccount, api_fetchAccounts as fetchAccounts, api_fetchAuthorizationSession as fetchAuthorizationSession, api_fetchChains as fetchChains, api_fetchMerchantPublicKey as fetchMerchantPublicKey, api_fetchProviders as fetchProviders, api_fetchTransfer as fetchTransfer, api_fetchUserConfig as fetchUserConfig, api_registerPasskey as registerPasskey, api_reportActionCompletion as reportActionCompletion, api_reportPasskeyActivity as reportPasskeyActivity, api_signTransfer as signTransfer, api_updateUserConfig as updateUserConfig, api_updateUserConfigBySession as updateUserConfigBySession };
|
|
457
|
+
export { type api_CreateAccountParams as CreateAccountParams, type api_CreateGuestTransferParams as CreateGuestTransferParams, type api_CreateTransferParams as CreateTransferParams, type api_GuestQuoteParams as GuestQuoteParams, api_createAccount as createAccount, api_createAccountAuthorizationSession as createAccountAuthorizationSession, api_createGuestTransfer as createGuestTransfer, api_createTransfer as createTransfer, api_fetchAccount as fetchAccount, api_fetchAccounts as fetchAccounts, api_fetchAuthorizationSession as fetchAuthorizationSession, api_fetchChains as fetchChains, api_fetchGuestQuote as fetchGuestQuote, api_fetchGuestTransfer as fetchGuestTransfer, api_fetchMerchantPublicKey as fetchMerchantPublicKey, api_fetchProviders as fetchProviders, api_fetchTransfer as fetchTransfer, api_fetchUserConfig as fetchUserConfig, api_registerPasskey as registerPasskey, api_reportActionCompletion as reportActionCompletion, api_reportPasskeyActivity as reportPasskeyActivity, api_signTransfer as signTransfer, api_updateUserConfig as updateUserConfig, api_updateUserConfigBySession as updateUserConfigBySession };
|
|
405
458
|
}
|
|
406
459
|
|
|
407
460
|
interface SwypePaymentProps {
|
|
@@ -415,6 +468,12 @@ interface SwypePaymentProps {
|
|
|
415
468
|
onBack?: () => void;
|
|
416
469
|
onDismiss?: () => void;
|
|
417
470
|
autoCloseSeconds?: number;
|
|
471
|
+
/** EVM numeric chain ID for the source chain (guest flow). */
|
|
472
|
+
sourceChainId?: number;
|
|
473
|
+
/** Source token contract address (guest flow). */
|
|
474
|
+
sourceToken?: string;
|
|
475
|
+
/** Destination EVM numeric chain ID (guest flow). */
|
|
476
|
+
destinationChainId?: number;
|
|
418
477
|
}
|
|
419
478
|
declare function SwypePayment(props: SwypePaymentProps): react_jsx_runtime.JSX.Element;
|
|
420
479
|
|
|
@@ -812,6 +871,42 @@ interface TokenPickerScreenProps {
|
|
|
812
871
|
}
|
|
813
872
|
declare function TokenPickerScreen({ account, chains, onSelectAuthorized, onAuthorizeToken, onBack, onLogout, depositAmount, selectedTokenSymbol, selectedWalletId, }: TokenPickerScreenProps): react_jsx_runtime.JSX.Element;
|
|
814
873
|
|
|
874
|
+
interface GuestDepositScreenProps {
|
|
875
|
+
amount: number;
|
|
876
|
+
currency: string;
|
|
877
|
+
merchantName?: string;
|
|
878
|
+
onConfirm: () => void;
|
|
879
|
+
onSignIn: () => void;
|
|
880
|
+
onBack?: () => void;
|
|
881
|
+
loading?: boolean;
|
|
882
|
+
error?: string | null;
|
|
883
|
+
}
|
|
884
|
+
declare function GuestDepositScreen({ amount, currency, merchantName, onConfirm, onSignIn, onBack, loading, error, }: GuestDepositScreenProps): react_jsx_runtime.JSX.Element;
|
|
885
|
+
|
|
886
|
+
type GuestWalletPhase = 'connecting' | 'fetching-quote' | 'approving' | 'signing' | 'submitting';
|
|
887
|
+
interface GuestWalletScreenProps {
|
|
888
|
+
phase: GuestWalletPhase;
|
|
889
|
+
amount: number;
|
|
890
|
+
currency: string;
|
|
891
|
+
onBack?: () => void;
|
|
892
|
+
error?: string | null;
|
|
893
|
+
onRetry?: () => void;
|
|
894
|
+
}
|
|
895
|
+
declare function GuestWalletScreen({ phase, amount, currency, onBack, error, onRetry, }: GuestWalletScreenProps): react_jsx_runtime.JSX.Element;
|
|
896
|
+
|
|
897
|
+
interface OfferSetupScreenProps {
|
|
898
|
+
amount: number;
|
|
899
|
+
currency: string;
|
|
900
|
+
onSetup: () => void;
|
|
901
|
+
onDone: () => void;
|
|
902
|
+
}
|
|
903
|
+
declare function OfferSetupScreen({ amount, currency, onSetup, onDone, }: OfferSetupScreenProps): react_jsx_runtime.JSX.Element;
|
|
904
|
+
|
|
905
|
+
interface SetupCompleteScreenProps {
|
|
906
|
+
onDone: () => void;
|
|
907
|
+
}
|
|
908
|
+
declare function SetupCompleteScreen({ onDone }: SetupCompleteScreenProps): react_jsx_runtime.JSX.Element;
|
|
909
|
+
|
|
815
910
|
type FlowPhase = 'link' | 'deposit';
|
|
816
911
|
|
|
817
912
|
declare function FlowPhaseProvider({ phase, children, }: {
|
|
@@ -823,4 +918,4 @@ declare const SWYPE_LOGO: string;
|
|
|
823
918
|
/** @deprecated Use SWYPE_LOGO instead. Kept for backward compatibility. */
|
|
824
919
|
declare const SWYPE_MASCOT: string;
|
|
825
920
|
|
|
826
|
-
export { type Account, type ActionExecutionResult, type AdvancedSettings, AdvancedSourceScreen, type Amount, type AuthorizationAction, type AuthorizationSession, type AuthorizationSessionDetail, type Chain, type Destination, type ErrorResponse, type FlowPhase, FlowPhaseProvider, IconCircle, InfoBanner, type ListResponse, type MerchantAuthorization, type MerchantPublicKey, OutlineButton, PasskeyIframeBlockedError, PasskeyScreen, type PaymentStep, PoweredByFooter, PrimaryButton, type Provider, SWYPE_LOGO, SWYPE_MASCOT, ScreenHeader, ScreenLayout, SelectSourceScreen, SettingsMenu, SetupScreen, type SourceOption, type SourceSelection, type SourceType, Spinner, type StepItem, StepList, SwypeLoadingScreen, SwypePayment, type SwypePaymentProps, SwypeProvider, type SwypeProviderProps, type ThemeMode, type ThemeTokens, type TokenBalance, TokenPickerScreen, type Transfer, type TransferDestination, type UserConfig, type Wallet, type WalletSource, type WalletToken, buildPasskeyPopupOptions, createPasskeyCredential, createPasskeyViaPopup, darkTheme, deviceHasPasskey, findDevicePasskey, findDevicePasskeyViaPopup, getTheme, lightTheme, resolvePasskeyRpId, api as swypeApi, useAuthorizationExecutor, useSwypeConfig, useSwypeDepositAmount, useTransferPolling, useTransferSigning };
|
|
921
|
+
export { type Account, type ActionExecutionResult, type AdvancedSettings, AdvancedSourceScreen, type Amount, type AuthorizationAction, type AuthorizationSession, type AuthorizationSessionDetail, type Chain, type Destination, type ErrorResponse, type FlowPhase, FlowPhaseProvider, GuestDepositScreen, type GuestQuote, GuestWalletScreen, IconCircle, InfoBanner, type ListResponse, type MerchantAuthorization, type MerchantPublicKey, OfferSetupScreen, OutlineButton, PasskeyIframeBlockedError, PasskeyScreen, type PaymentStep, PoweredByFooter, PrimaryButton, type Provider, type RelayDepositStep, SWYPE_LOGO, SWYPE_MASCOT, ScreenHeader, ScreenLayout, SelectSourceScreen, SettingsMenu, SetupCompleteScreen, SetupScreen, type SourceOption, type SourceSelection, type SourceType, Spinner, type StepItem, StepList, SwypeLoadingScreen, SwypePayment, type SwypePaymentProps, SwypeProvider, type SwypeProviderProps, type ThemeMode, type ThemeTokens, type TokenBalance, TokenPickerScreen, type Transfer, type TransferDestination, type UserConfig, type Wallet, type WalletSource, type WalletToken, buildPasskeyPopupOptions, createPasskeyCredential, createPasskeyViaPopup, darkTheme, deviceHasPasskey, findDevicePasskey, findDevicePasskeyViaPopup, getTheme, lightTheme, resolvePasskeyRpId, api as swypeApi, useAuthorizationExecutor, useSwypeConfig, useSwypeDepositAmount, useTransferPolling, useTransferSigning };
|