@funkit/connect 9.18.0 → 9.19.1

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.
Files changed (63) hide show
  1. package/CHANGELOG.md +56 -0
  2. package/dist/{chunk-O35RTEEF.js → chunk-6K4U3Z4Z.js} +3 -0
  3. package/dist/{chunk-C2DLTEP2.js → chunk-NBECXHBY.js} +1 -1
  4. package/dist/{chunk-PPNE44RL.js → chunk-PFIXC5YK.js} +1 -1
  5. package/dist/clients/chunk-TFZV2HO4.js +290 -0
  6. package/dist/clients/chunk-UUHGOBKZ.js +51 -0
  7. package/dist/clients/fanatics.css +4729 -4699
  8. package/dist/clients/fanatics.js +3 -3
  9. package/dist/clients/lighter.css +4729 -4699
  10. package/dist/clients/lighter.js +2 -2
  11. package/dist/clients/polymarket.js +17 -36
  12. package/dist/clients/rolly.d.ts +13 -11
  13. package/dist/clients/rolly.js +17 -17
  14. package/dist/components/Box/Box.d.ts +18 -18
  15. package/dist/components/Dialog/DialogContent.css.d.ts +1 -0
  16. package/dist/components/Icons/CoinsIcon.d.ts +3 -1
  17. package/dist/components/PaddedScrollableArea/PaddedScrollableArea.d.ts +1 -2
  18. package/dist/consts/customers.d.ts +13 -0
  19. package/dist/consts/funkit.d.ts +2 -0
  20. package/dist/consts/polymarket.d.ts +9 -0
  21. package/dist/css/sprinkles.css.d.ts +22 -18
  22. package/dist/domains/checkoutNotifications.d.ts +1 -46
  23. package/dist/domains/paymentMethods.d.ts +10 -20
  24. package/dist/domains/swapped.d.ts +2 -21
  25. package/dist/hooks/queries/useWithdrawalQuote.d.ts +3 -1
  26. package/dist/hooks/queries/useWithdrawalRisk.d.ts +1 -1
  27. package/dist/hooks/statsig/useDynamicConfig.d.ts +2 -5
  28. package/dist/hooks/statsig/useExperiment.d.ts +1 -33
  29. package/dist/hooks/statsig/useFeatureGate.d.ts +1 -4
  30. package/dist/hooks/useCheckoutTransferInit.d.ts +2 -17
  31. package/dist/hooks/useTokenTransfer.d.ts +3 -8
  32. package/dist/hooks/useUDAParams.d.ts +2 -10
  33. package/dist/index.css +4860 -4816
  34. package/dist/index.js +1500 -3305
  35. package/dist/modals/CheckoutModal/InputAmount/QuickOptions.d.ts +1 -0
  36. package/dist/modals/CheckoutModal/InputAmount/state.d.ts +25 -1
  37. package/dist/modals/CheckoutModal/InputAmount/useCheckoutAmountLimits.d.ts +17 -0
  38. package/dist/modals/WithdrawalModal/ErrorMessage.d.ts +7 -1
  39. package/dist/providers/FunkitThemeProvider.d.ts +6 -0
  40. package/dist/providers/ModalSizeContext.d.ts +1 -0
  41. package/dist/providers/SwappedProvider.d.ts +1 -1
  42. package/dist/themes/baseTheme.js +1 -1
  43. package/dist/themes/darkTheme.js +2 -2
  44. package/dist/themes/lightTheme.js +2 -2
  45. package/dist/transports/iframeSwappedTransport.d.ts +1 -1
  46. package/dist/utils/address.d.ts +1 -14
  47. package/dist/utils/consts.d.ts +1 -2
  48. package/dist/utils/datadogBrowserLogsTransport.d.ts +1 -1
  49. package/dist/utils/directExecution.d.ts +1 -34
  50. package/dist/utils/funLogger.d.ts +1 -51
  51. package/dist/utils/getExchangeRate.d.ts +1 -4
  52. package/dist/utils/statsig/checkFeatureGate.d.ts +1 -1
  53. package/dist/utils/swapped.d.ts +5 -43
  54. package/dist/utils/transfer.d.ts +1 -10
  55. package/dist/wallets/walletConnectors/index.js +35 -35
  56. package/package.json +4 -3
  57. package/dist/__generated__/default_configs.d.ts +0 -901
  58. package/dist/__generated__/default_feature_gates.d.ts +0 -20
  59. package/dist/clients/chunk-3QHYYLVM.js +0 -240
  60. package/dist/clients/chunk-JOBMGIG4.js +0 -290
  61. package/dist/interfaces/logTransport.d.ts +0 -51
  62. package/dist/interfaces/swapped-transport.d.ts +0 -78
  63. package/dist/utils/flags/resolver.d.ts +0 -34
@@ -1,5 +1,6 @@
1
1
  import React from 'react';
2
2
  export declare const USD_AMOUNT_OPTIONS_PCT: number[];
3
+ export declare const BITCOIN_LIGHTNING_USD_AMOUNT_OPTIONS: number[];
3
4
  interface QuickOptionsProps {
4
5
  currency?: string;
5
6
  disabled?: boolean;
@@ -1,4 +1,5 @@
1
1
  import type { Dnum } from 'dnum';
2
+ import type { Address } from 'viem';
2
3
  import { type PaymentMethodInfo } from '../../../domains/paymentMethods';
3
4
  import type { QuoteBuilder } from '../../../domains/quoteMode/types';
4
5
  import type { AssetHoldingsItem } from '../../../utils/assets';
@@ -139,6 +140,29 @@ export type AmountInputError = {
139
140
  * Return half the balance and round up to nearest 10, 100, 1000 etc
140
141
  */
141
142
  export declare function calcInitialFiatAmount(balance: number): number;
142
- export declare function initializeState({ checkoutConfig, defaultAmount, fiatCurrency, quoteBuilder, locale, maxUsd, minUsd, paymentMethodInfo, quickOptions, sourceHolding, unitPrice: realUnitPrice, meldEnabled, defaultAssetAmount, defaultIsInputInFiat, isNativeToken, gasPriceWei, gasUnits, }: AmountInputInitOptions): AmountInputState;
143
+ /** Minimal source-token identity needed to resolve the default input mode. */
144
+ export interface SourceTokenRef {
145
+ chainId: string;
146
+ address: Address;
147
+ }
148
+ /**
149
+ * Resolves whether the amount screen should open in fiat (`true`) or token
150
+ * (`false`) entry.
151
+ *
152
+ * Precedence: card and BTC Lightning payments always force fiat (ramps are
153
+ * fiat-denominated, and Lightning's amount input only supports fiat today).
154
+ * Lighter **spot** deposits paid with the same asset open in token entry —
155
+ * perps deposits (and every other customer) keep the legacy fiat default.
156
+ * Legacy behavior: token entry only for vault-style deposits (a finalized
157
+ * token set), fiat otherwise. A value preserved from prior navigation
158
+ * (`defaultIsInputInFiat`) is handled by the caller and wins over this.
159
+ */
160
+ export declare function resolveDefaultIsInputInFiat({ checkoutConfig, paymentMethodInfo, sourceToken, apiKey, }: {
161
+ checkoutConfig: FunkitCheckoutConfig;
162
+ paymentMethodInfo: PaymentMethodInfo;
163
+ sourceToken: SourceTokenRef | null;
164
+ apiKey: string;
165
+ }): boolean;
166
+ export declare function initializeState({ checkoutConfig, defaultAmount, fiatCurrency, quoteBuilder, locale, maxUsd, minUsd, paymentMethodInfo, quickOptions, sourceHolding, unitPrice: realUnitPrice, meldEnabled, apiKey, defaultAssetAmount, defaultIsInputInFiat, isNativeToken, gasPriceWei, gasUnits, }: AmountInputInitOptions): AmountInputState;
143
167
  export declare function reduceState(state: AmountInputState, action: AmountInputAction): AmountInputState;
144
168
  export declare function getDerivedState(state: AmountInputState, targetAssetTicker: string): AmountInputDerivedState;
@@ -0,0 +1,17 @@
1
+ import { PaymentMethod } from '../../../domains/paymentMethods';
2
+ import type { FunkitCheckoutConfig } from '../../../providers/FunkitCheckoutContext';
3
+ export interface CheckoutAmountLimitsUsd {
4
+ minUsd: number | undefined;
5
+ maxUsd: number;
6
+ }
7
+ /**
8
+ * Resolves the min/max USD bounds for the amount input based on the active
9
+ * payment method:
10
+ * - Bitcoin Lightning and brokerage checkouts carry their own floors/ceilings.
11
+ * - Everything else uses the customer-configured min deposit and the global
12
+ * max-checkout dynamic config.
13
+ */
14
+ export declare const useCheckoutAmountLimits: ({ checkoutConfig, paymentMethod, }: {
15
+ checkoutConfig: FunkitCheckoutConfig;
16
+ paymentMethod: PaymentMethod;
17
+ }) => CheckoutAmountLimitsUsd;
@@ -1,4 +1,10 @@
1
1
  import type { TFunction } from 'i18next';
2
2
  import type { ErrorNotification } from '../../components/FunNotification/FunNotification';
3
3
  import type { CheckoutConfirmationError } from '../../domains/checkoutErrors';
4
- export declare function getErrorNotification(quoteErrorObject: Error | null, withdrawalError: CheckoutConfirmationError | null, targetAssetFetchError: Error | null, t: TFunction): ErrorNotification | null;
4
+ export declare function getErrorNotification({ quoteErrorObject, withdrawalError, targetAssetFetchError, riskCheckError, t, }: {
5
+ quoteErrorObject: Error | null;
6
+ withdrawalError: CheckoutConfirmationError | null;
7
+ targetAssetFetchError: Error | null;
8
+ riskCheckError: Error | null;
9
+ t: TFunction;
10
+ }): ErrorNotification | null;
@@ -210,6 +210,7 @@ export declare const useActiveTheme: () => {
210
210
  dropdownGroupHeader: string;
211
211
  header: string;
212
212
  inputAmount: string;
213
+ modalTopbarTitle: string;
213
214
  txStatusDescription: string;
214
215
  txStatusTitle: string;
215
216
  };
@@ -509,6 +510,7 @@ export declare const useActiveTheme: () => {
509
510
  selectBrokerageItemPaddingX: string;
510
511
  selectBrokerageItemPaddingY: string;
511
512
  selectBrokerageListGap: string;
513
+ walletConnectorListGap: string;
512
514
  txBreakdownMarginY: string;
513
515
  txBreakdownPaddingX: string;
514
516
  txSummaryBoxPaddingX: string;
@@ -736,6 +738,7 @@ export declare const useActiveTheme: () => {
736
738
  dropdownGroupHeader: string;
737
739
  header: string;
738
740
  inputAmount: string;
741
+ modalTopbarTitle: string;
739
742
  txStatusDescription: string;
740
743
  txStatusTitle: string;
741
744
  };
@@ -1035,6 +1038,7 @@ export declare const useActiveTheme: () => {
1035
1038
  selectBrokerageItemPaddingX: string;
1036
1039
  selectBrokerageItemPaddingY: string;
1037
1040
  selectBrokerageListGap: string;
1041
+ walletConnectorListGap: string;
1038
1042
  txBreakdownMarginY: string;
1039
1043
  txBreakdownPaddingX: string;
1040
1044
  txSummaryBoxPaddingX: string;
@@ -1260,6 +1264,7 @@ export declare const useActiveTheme: () => {
1260
1264
  dropdownGroupHeader: string;
1261
1265
  header: string;
1262
1266
  inputAmount: string;
1267
+ modalTopbarTitle: string;
1263
1268
  txStatusDescription: string;
1264
1269
  txStatusTitle: string;
1265
1270
  };
@@ -1559,6 +1564,7 @@ export declare const useActiveTheme: () => {
1559
1564
  selectBrokerageItemPaddingX: string;
1560
1565
  selectBrokerageItemPaddingY: string;
1561
1566
  selectBrokerageListGap: string;
1567
+ walletConnectorListGap: string;
1562
1568
  txBreakdownMarginY: string;
1563
1569
  txBreakdownPaddingX: string;
1564
1570
  txSummaryBoxPaddingX: string;
@@ -3,6 +3,7 @@ export declare const ModalSizeOptions: {
3
3
  readonly COMPACT: "compact";
4
4
  readonly MEDIUM: "medium";
5
5
  readonly WIDE: "wide";
6
+ readonly EXTRA_WIDE: "extraWide";
6
7
  };
7
8
  export type ModalSizes = (typeof ModalSizeOptions)[keyof typeof ModalSizeOptions];
8
9
  export declare const ModalSizeContext: React.Context<ModalSizes>;
@@ -1,6 +1,6 @@
1
1
  import { type FormOfPaymentType } from '@funkit/api-base';
2
+ import type { SwappedTransport } from '@funkit/connect-core';
2
3
  import React from 'react';
3
- import type { SwappedTransport } from '../interfaces/swapped-transport';
4
4
  import { type SwappedTheme } from '../utils/swapped';
5
5
  interface SwappedContextValue {
6
6
  iframeUrl: string | null;
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  baseTheme,
4
4
  systemFontStack
5
- } from "../chunk-O35RTEEF.js";
5
+ } from "../chunk-6K4U3Z4Z.js";
6
6
  export {
7
7
  baseTheme,
8
8
  systemFontStack
@@ -1,8 +1,8 @@
1
1
  "use client";
2
2
  import {
3
3
  darkTheme
4
- } from "../chunk-PPNE44RL.js";
5
- import "../chunk-O35RTEEF.js";
4
+ } from "../chunk-PFIXC5YK.js";
5
+ import "../chunk-6K4U3Z4Z.js";
6
6
  export {
7
7
  darkTheme
8
8
  };
@@ -1,8 +1,8 @@
1
1
  "use client";
2
2
  import {
3
3
  lightTheme
4
- } from "../chunk-C2DLTEP2.js";
5
- import "../chunk-O35RTEEF.js";
4
+ } from "../chunk-NBECXHBY.js";
5
+ import "../chunk-6K4U3Z4Z.js";
6
6
  export {
7
7
  lightTheme
8
8
  };
@@ -1,4 +1,4 @@
1
- import type { SwappedTransport } from '../interfaces/swapped-transport';
1
+ import type { SwappedTransport } from '@funkit/connect-core';
2
2
  interface IframeSwappedTransportOptions {
3
3
  /** The embed's content window, or `null` if it isn't mounted/loaded yet. */
4
4
  getContentWindow: () => Window | null;
@@ -1,14 +1 @@
1
- import type { TFunction } from 'i18next';
2
- import type { FunkitTextCustomizationsConfig } from '../providers/FunkitConfigContext';
3
- export declare const getWalletLabel: (t: TFunction, textCustomizations: FunkitTextCustomizationsConfig, walletAddress?: string) => string;
4
- export declare function isWithdrawalAddressSupported(address: string): boolean;
5
- /**
6
- * Check if the recipient address is compatible with selected chain.
7
- * Supports EVM, Solana, and Tron chains for withdrawal.
8
- */
9
- export declare function isAddressCompatibleWithChain(address: string, chainId: number): boolean;
10
- /**
11
- * True for any positive-integer (string-encoded) chain id that isn't a known
12
- * non-EVM chain. Used to gate EVM-only flows (EIP-747, etc.).
13
- */
14
- export declare function isEvmChainId(chainId: string): boolean;
1
+ export { getWalletLabel, isAddressCompatibleWithChain, isEvmChainId, isWithdrawalAddressSupported, } from '@funkit/connect-core';
@@ -1,6 +1,5 @@
1
1
  export declare const MIN_CHECKOUT_AMOUNT_USD = 1;
2
- export declare const MIN_MOONPAY_AMOUNT_USD = 35;
3
- export declare const MAX_MOONPAY_AMOUNT_USD = 10000;
2
+ export declare const MAX_BTC_LIGHTNING_AMOUNT_USD = 10000;
4
3
  export declare const LOW_BALANCE = "Low Balance";
5
4
  export declare const CONTACT_US_LINK = "https://intercom.help/funxyz/en/articles/10732578-contact-us";
6
5
  export declare const DEFAULT_CHECKOUT_HISTORY_DETAIL_TITLE = "Your Purchase";
@@ -1,4 +1,4 @@
1
- import type { LogRecord, LogTransport, TrackingConsent } from '../interfaces/logTransport';
1
+ import type { LogRecord, LogTransport, TrackingConsent } from '@funkit/connect-core';
2
2
  /**
3
3
  * Web `LogTransport` backed by `@datadog/browser-logs`. Owns Datadog
4
4
  * initialization, global-context/consent wiring, and the browser-only emit.
@@ -1,34 +1 @@
1
- import type { DirectExecution } from '@funkit/api-base';
2
- import type { WalletClient } from 'viem';
3
- export declare function getDirectExecutionCreatedTimeMs(directExecution: DirectExecution): number;
4
- export declare function getDirectExecutionUpdatedTimeMs(directExecution: DirectExecution): number;
5
- /**
6
- * Unique key for a DE notification record, stable between synthetic and real record.
7
- *
8
- * When a synthetic deposit-detection DE is replaced by the real DE, the txHash
9
- * changes but triggeringTxHash stays the same. Preferring triggeringTxHash keeps
10
- * the identity stable across that swap, avoiding a flash/remount of the notification.
11
- */
12
- export declare function getDirectExecutionNotificationKey(item: DirectExecution): string;
13
- export declare function getDirectExecutionRunTimeSeconds(directExecution: DirectExecution): number;
14
- /**
15
- * Resolves the completion transaction chain, hash, and explorer URL for a direct execution.
16
- *
17
- * Chain resolution: if LayerZero OFT data is present, use the LZ destination chain;
18
- * otherwise fall back to the DE's toChainId.
19
- *
20
- * Hash resolution: for Lighter L1 deposits (new user flow where toChainId is NOT Lighter),
21
- * the completion explorer should point to Lighter using lighterExecutionStatusResponse.hash.
22
- * For the existing user flow (toChainId IS Lighter), relay already puts the correct
23
- * Lighter hash into listenerInfo.txHashes, so the default path works.
24
- */
25
- export declare function getCompletionTxInfo(directExecution: DirectExecution): {
26
- chainId: string;
27
- txHash: string | undefined;
28
- customRedirectUrl: string | undefined;
29
- };
30
- /**
31
- * Returns a proxied wallet with getCapabilities patched to disable atomic batch support.
32
- * This forces Relay to use sequential transactions instead of batched ones.
33
- */
34
- export declare function disableAtomicBatchIfSupported(wallet: WalletClient, chainId: number): Promise<WalletClient>;
1
+ export { disableAtomicBatchIfSupported, getCompletionTxInfo, getDirectExecutionCreatedTimeMs, getDirectExecutionNotificationKey, getDirectExecutionRunTimeSeconds, getDirectExecutionUpdatedTimeMs, } from '@funkit/connect-core';
@@ -1,53 +1,3 @@
1
- import type { LogTransport } from '../interfaces/logTransport';
2
- declare class FunLogger {
3
- protected apiKey: string | null;
4
- protected isDebugMode: boolean;
5
- protected userId: string | null;
6
- protected userAddress: string | null;
7
- protected userName: string | null;
8
- protected userLoginType: string | null;
9
- protected typeLabel: string | null;
10
- protected sdkVersion: string | null;
11
- protected l2Address: string | null;
12
- private isConfigured;
13
- private logQueue;
14
- private disableLogging;
15
- private readonly transport;
16
- constructor(transport: LogTransport);
17
- private getFunLogEnv;
18
- /** Merge caller data with the logger's resolved context for the transport. */
19
- private buildLogContext;
20
- private processLog;
21
- private onDebug;
22
- private onInfo;
23
- private onWarn;
24
- private onError;
25
- private extractError;
26
- /**========================
27
- * PUBLIC LOGGER FUNCTIONS
28
- *=========================*/
29
- log(title: string, data?: object): void;
30
- info(title: string, data?: object): void;
31
- debug(title: string, data?: object): void;
32
- warn(title: string, data?: object): void;
33
- /**
34
- * @param errorOrData -
35
- * Previously was called "error" but since in the {@link Logger} interface, error is defined as object (which is the same thing as "any"), we treat it as of unknown type here for safety.
36
- * In a lot of places it's actually being used as a "data" prop, which also usually has an `.error` property representing an actual {@link Error} object.
37
- */
38
- error(title: string, errorOrData: unknown, _data?: object): void;
39
- private flushLogQueue;
40
- configure(apiKey: string | null, isDebug: boolean, sdkVersion: string, disableLogging?: boolean): void;
41
- getUserId(): string | null;
42
- getUserAddress(): string | null;
43
- getUserName(): string | null;
44
- getUserLoginType(): string | null;
45
- getTypeLabel(): string | null;
46
- getL2Address(): string | null;
47
- setUserInfo(userId: string, userAddress: string, userName: string, userLoginType: string, typeLabel: string, l2Address?: string): void;
48
- }
49
- /**===============================
50
- * INITIALIZATION
51
- *================================*/
1
+ import { FunLogger } from '@funkit/connect-core';
52
2
  declare const logger: FunLogger;
53
3
  export { logger, FunLogger };
@@ -1,4 +1 @@
1
- /**
2
- * Get the exchange rate for a given currency or return undefined if not found or any of the arguments are undefined
3
- */
4
- export declare const getExchangeRate: (currency: string | undefined, currencyExchangeRates: Record<string, number> | undefined, bipsMarkup?: number) => number | undefined;
1
+ export { getExchangeRate } from '@funkit/connect-core';
@@ -1,4 +1,4 @@
1
- import fallbackFeatureGates from '../../__generated__/default_feature_gates';
1
+ import { defaultFeatureGates as fallbackFeatureGates } from '@funkit/connect-core';
2
2
  type FeatureGateName = keyof typeof fallbackFeatureGates;
3
3
  /**
4
4
  * Synchronous, non-hook variant of {@link useFeatureGate}. Reads the gate
@@ -1,45 +1,7 @@
1
- import { type SavedFormOfPayment, type SwappedFormOfPayment } from '@funkit/api-base';
1
+ import type { SwappedTheme } from '@funkit/connect-core';
2
2
  import type { ThemeVars } from '../css/sprinkles.css';
3
- /**
4
- * Ref: https://www.notion.so/Fun-Parameter-Styling-Guide-312966ea6e398011bbc6c14e976e281d#63dcdd77ea2d488084a980cda4c63d08
5
- */
6
- export interface SwappedTheme {
7
- colors: Record<string, string>;
8
- radii: Record<string, string>;
9
- headerHeight: string;
10
- headerFontWeight: string;
11
- buttonFontWeight: string;
12
- modalBottomBarButtonHeight: string;
13
- iframeBackground: string;
14
- paddingPrimary?: string;
15
- paddingPrimaryX?: string;
16
- paddingPrimaryY?: string;
17
- paddingSecondary: string;
18
- paddingTertiary: string;
19
- baseFont?: string;
20
- secondaryFont?: string;
21
- topbarIconColor?: string;
22
- topbarIconHoverColor?: string;
23
- headerIconWrapperSize?: string;
24
- headerIconSize?: string;
25
- topbarTextFontSize?: string;
26
- contentPadding?: string;
27
- boxPaddingY?: string;
28
- boxPaddingX?: string;
29
- paymentMethodLightLogos?: boolean;
30
- topbarPaddingX?: string;
31
- topbarPaddingY?: string;
32
- }
33
- export declare const SWAPPED_CARD_BRANDS: Record<string, {
34
- displayName: string;
35
- iconImageUrl: string;
36
- }>;
37
- export declare const isSavedFormOfPaymentType: (fop: SwappedFormOfPayment) => fop is SavedFormOfPayment;
38
- export declare const getSavedFormOfPaymentDisplayName: (fop: SavedFormOfPayment) => string;
39
- export declare const getSavedFormOfPaymentIcon: (fop: SavedFormOfPayment) => string | undefined;
40
- export declare const getSwappedIcon: (fop: SwappedFormOfPayment, isDarkMode: boolean) => string;
41
- export declare function getSwappedOrigin(url: string): string | null;
42
- export declare function isSwappedOrigin(origin: string): boolean;
3
+ export { getSavedFormOfPaymentDisplayName, getSavedFormOfPaymentIcon, getSwappedIcon, getSwappedOrigin, isSavedFormOfPaymentType, isSwappedOrigin, SWAPPED_CARD_BRANDS, } from '@funkit/connect-core';
4
+ export type { SwappedTheme };
43
5
  export declare function resolveCssValue(value: string): string;
44
6
  export declare function resolveObjectCssVars<T extends object>(obj: T): T;
45
7
  /**
@@ -47,7 +9,7 @@ export declare function resolveObjectCssVars<T extends object>(obj: T): T;
47
9
  * touch the DOM, so it is safe to share across platforms. The returned values
48
10
  * may still contain `var(...)` / `calc(var(...))` references: web callers must
49
11
  * resolve them with {@link resolveObjectCssVars} before sending to the Swapped
50
- * embed, while RN passes already-concrete values from `useFunkitTheme()`.
12
+ * embed; non-web callers must pass already-concrete values.
51
13
  */
52
14
  export declare function buildSwappedTheme(theme: ThemeVars & {
53
15
  customFontFamily?: {
@@ -59,6 +21,6 @@ export declare function buildSwappedTheme(theme: ThemeVars & {
59
21
  * Maps a *resolved* ThemeVars into Swapped's theme query params. Pure — it does
60
22
  * not touch the DOM. Web callers must pass a theme whose CSS vars are already
61
23
  * resolved (via {@link resolveObjectCssVars}) so colors are concrete hex and the
62
- * leading `#` can be stripped; RN passes concrete values from `useFunkitTheme()`.
24
+ * leading `#` can be stripped; non-web callers must pass concrete values.
63
25
  */
64
26
  export declare function buildSwappedThemeQueryParams(resolvedTheme: ThemeVars): Record<string, string>;
@@ -1,10 +1 @@
1
- import type { CheckoutInitTokenTransferResponse, FunAddress } from '@funkit/api-base';
2
- export declare function getDepositAddressForChain(chainId: number, transferInit: CheckoutInitTokenTransferResponse | undefined): FunAddress | undefined;
3
- export type TransferTokenQrCodeType = 'ethereum' | 'solana' | 'bitcoin' | 'tron';
4
- interface TransferTokenQrCodeUriParams {
5
- depositAddress: FunAddress;
6
- type: TransferTokenQrCodeType;
7
- }
8
- export type QRCodeUri = `ethereum:${FunAddress}` | `solana:${FunAddress}` | `bitcoin:${FunAddress}` | FunAddress;
9
- export declare const getTransferTokenQrCodeUri: (props: TransferTokenQrCodeUriParams) => QRCodeUri;
10
- export {};
1
+ export { getDepositAddressForChain, getTransferTokenQrCodeUri, type QRCodeUri, type TransferTokenQrCodeType, } from '@funkit/connect-core';
@@ -17,21 +17,21 @@ import {
17
17
  import {
18
18
  tokenaryWallet
19
19
  } from "./chunk-VH3THHJY.js";
20
- import {
21
- trustWallet
22
- } from "./chunk-KCRO2AGO.js";
23
20
  import {
24
21
  uniswapWallet
25
22
  } from "./chunk-Z3PPW6NC.js";
26
23
  import {
27
- xdefiWallet
28
- } from "./chunk-JN5I3DNC.js";
24
+ trustWallet
25
+ } from "./chunk-KCRO2AGO.js";
29
26
  import {
30
27
  walletConnectWallet
31
28
  } from "./chunk-3FCWJRI4.js";
32
29
  import {
33
- rabbyWallet
34
- } from "./chunk-RB66PKPA.js";
30
+ xdefiWallet
31
+ } from "./chunk-JN5I3DNC.js";
32
+ import {
33
+ phantomWallet
34
+ } from "./chunk-QY53O7WG.js";
35
35
  import {
36
36
  rainbowWallet
37
37
  } from "./chunk-W2LCLDPX.js";
@@ -54,20 +54,20 @@ import {
54
54
  subWallet
55
55
  } from "./chunk-NR2OGDHQ.js";
56
56
  import {
57
- metaMaskWallet
58
- } from "./chunk-YO2K4MBH.js";
57
+ kresusWallet
58
+ } from "./chunk-RICTB3FA.js";
59
59
  import {
60
60
  mewWallet
61
61
  } from "./chunk-MQM45ADF.js";
62
62
  import {
63
63
  oktoWallet
64
64
  } from "./chunk-YWOVAU6O.js";
65
- import {
66
- okxWallet
67
- } from "./chunk-KI5Y2BBF.js";
68
65
  import {
69
66
  omniWallet
70
67
  } from "./chunk-2CX7LX4J.js";
68
+ import {
69
+ okxWallet
70
+ } from "./chunk-KI5Y2BBF.js";
71
71
  import {
72
72
  oneInchWallet
73
73
  } from "./chunk-QG6ZHI7B.js";
@@ -75,38 +75,41 @@ import {
75
75
  oneKeyWallet
76
76
  } from "./chunk-WVT6BBJH.js";
77
77
  import {
78
- phantomWallet
79
- } from "./chunk-QY53O7WG.js";
80
- import {
81
- foxWallet
82
- } from "./chunk-GUQM4QSL.js";
78
+ rabbyWallet
79
+ } from "./chunk-RB66PKPA.js";
83
80
  import {
84
81
  frontierWallet
85
82
  } from "./chunk-AVDUNQUW.js";
86
- import {
87
- frameWallet
88
- } from "./chunk-BU3ZAT5X.js";
89
83
  import {
90
84
  gateWallet
91
85
  } from "./chunk-JPN6TWIT.js";
92
86
  import {
93
87
  imTokenWallet
94
88
  } from "./chunk-WNAGGFMG.js";
89
+ import {
90
+ foxWallet
91
+ } from "./chunk-GUQM4QSL.js";
92
+ import {
93
+ frameWallet
94
+ } from "./chunk-BU3ZAT5X.js";
95
95
  import {
96
96
  injectedWallet
97
97
  } from "./chunk-T6LGKC3F.js";
98
- import {
99
- kresusWallet
100
- } from "./chunk-RICTB3FA.js";
101
98
  import {
102
99
  ledgerWallet
103
100
  } from "./chunk-RPV27V2Y.js";
104
101
  import {
105
- bybitWallet
106
- } from "./chunk-OX37G4YT.js";
102
+ metaMaskWallet
103
+ } from "./chunk-YO2K4MBH.js";
107
104
  import {
108
105
  clvWallet
109
106
  } from "./chunk-OEEGYENV.js";
107
+ import {
108
+ bybitWallet
109
+ } from "./chunk-OX37G4YT.js";
110
+ import {
111
+ coinbaseWallet
112
+ } from "./chunk-2DLDAZRH.js";
110
113
  import {
111
114
  coin98Wallet
112
115
  } from "./chunk-WAHGI5L7.js";
@@ -114,23 +117,20 @@ import {
114
117
  coreWallet
115
118
  } from "./chunk-4NV5BYRP.js";
116
119
  import {
117
- coinbaseWallet
118
- } from "./chunk-2DLDAZRH.js";
119
- import {
120
- dawnWallet
121
- } from "./chunk-G2PHTVL6.js";
120
+ enkryptWallet
121
+ } from "./chunk-HBQK5RD5.js";
122
122
  import {
123
123
  desigWallet
124
124
  } from "./chunk-FW3WZETT.js";
125
125
  import {
126
- enkryptWallet
127
- } from "./chunk-HBQK5RD5.js";
128
- import {
129
- bifrostWallet
130
- } from "./chunk-IULPZP2Q.js";
126
+ dawnWallet
127
+ } from "./chunk-G2PHTVL6.js";
131
128
  import {
132
129
  argentWallet
133
130
  } from "./chunk-NTMBEOR2.js";
131
+ import {
132
+ bifrostWallet
133
+ } from "./chunk-IULPZP2Q.js";
134
134
  import {
135
135
  bitgetWallet
136
136
  } from "./chunk-TKB2OY6G.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@funkit/connect",
3
- "version": "9.18.0",
3
+ "version": "9.19.1",
4
4
  "description": "Funkit Connect SDK elevates DeFi apps via web2 sign-ins and one-click checkouts.",
5
5
  "files": [
6
6
  "dist",
@@ -110,8 +110,9 @@
110
110
  "ua-parser-js": "^1.0.37",
111
111
  "use-debounce": "^10.0.5",
112
112
  "uuid": "^11.1.1",
113
- "@funkit/api-base": "4.4.1",
114
- "@funkit/chains": "1.2.0",
113
+ "@funkit/api-base": "4.5.0",
114
+ "@funkit/chains": "2.1.0",
115
+ "@funkit/connect-core": "0.3.0",
115
116
  "@funkit/fun-relay": "2.8.0",
116
117
  "@funkit/utils": "3.0.2"
117
118
  },