@funkit/connect 12.14.0 → 12.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/dist/clients/axiom.d.ts +12 -0
  3. package/dist/clients/axiom.js +27 -0
  4. package/dist/clients/{chunk-YMBIRJQF.js → chunk-6IH7AWFA.js} +1 -1
  5. package/dist/clients/{chunk-P6UM36G5.js → chunk-7JYLS7IF.js} +32 -0
  6. package/dist/clients/{chunk-ZOQQL2QX.js → chunk-BKK2BFIP.js} +1 -1
  7. package/dist/clients/{chunk-I75AI3N7.js → chunk-C3BTAVJA.js} +6 -6
  8. package/dist/clients/{chunk-R6E3NH5A.js → chunk-FLREOB24.js} +1 -1
  9. package/dist/clients/{chunk-U33QNTIA.js → chunk-IUVVGGP4.js} +66 -5
  10. package/dist/clients/{chunk-5GX6G7JR.js → chunk-OB5GKTP2.js} +1 -1
  11. package/dist/clients/{chunk-I5GSXPFE.js → chunk-TKEBGMVW.js} +1 -7
  12. package/dist/clients/fanatics.js +2 -2
  13. package/dist/clients/internal/nado/withdrawalCallback.js +4 -4
  14. package/dist/clients/internal/nado/withdrawalErrors.js +2 -2
  15. package/dist/clients/internal/nado/withdrawalForm.js +3 -3
  16. package/dist/clients/internal/nado/withdrawalStatus.js +3 -3
  17. package/dist/clients/lighter.css +46 -0
  18. package/dist/clients/lighter.js +3 -3
  19. package/dist/clients/mallard.js +2 -2
  20. package/dist/clients/nado.js +4 -4
  21. package/dist/clients/polymarket/createPolymarketDepositConfig.d.ts +5 -5
  22. package/dist/clients/polymarket/createPolymarketDepositConfig.js +3 -3
  23. package/dist/clients/polymarket/index.js +3 -3
  24. package/dist/clients/polymarket/polymarket.js +2 -2
  25. package/dist/components/TokenSwapWidget/AmountUnitToggle/AmountUnitToggle.d.ts +2 -1
  26. package/dist/components/TokenSwapWidget/TokenSwapCard/TokenSwapCard.d.ts +17 -6
  27. package/dist/components/TokenSwapWidget/TokenSwapWidget.d.ts +9 -7
  28. package/dist/consts/customers.d.ts +2 -2
  29. package/dist/domains/clientMetadata.d.ts +4 -3
  30. package/dist/hooks/track/CheckoutModalEvent.d.ts +1 -0
  31. package/dist/hooks/track/analytics/events.d.ts +1 -1
  32. package/dist/hooks/track/analytics/useTrackExecutionProgressEvents.d.ts +17 -2
  33. package/dist/index.css +46 -0
  34. package/dist/index.js +1905 -1418
  35. package/dist/modals/CheckoutModal/Convert/ConvertStep.d.ts +6 -0
  36. package/dist/modals/CheckoutModal/FunCheckoutStep.d.ts +1 -0
  37. package/dist/modals/CheckoutModal/HeaderTabs/CheckoutHeaderTabs.d.ts +12 -0
  38. package/dist/modals/CheckoutModal/HeaderTabs/headerTabs.d.ts +8 -0
  39. package/dist/modals/CheckoutModal/HeaderTabs/useCheckoutHeaderTabsState.d.ts +4 -0
  40. package/dist/modals/CheckoutModal/stepTransition.d.ts +3 -0
  41. package/dist/modals/PolymarketPerpsTransfer/usePerpsHeaderTabsState.d.ts +1 -21
  42. package/dist/providers/FunkitCheckoutContext/types.d.ts +40 -0
  43. package/dist/shadow-css.js +1 -1
  44. package/dist/wallets/walletConnectors/bifrostWallet/bifrostWallet.js +2 -2
  45. package/dist/wallets/walletConnectors/bitgetWallet/bitgetWallet.js +2 -2
  46. package/dist/wallets/walletConnectors/bybitWallet/bybitWallet.js +2 -2
  47. package/dist/wallets/walletConnectors/clvWallet/clvWallet.js +2 -2
  48. package/dist/wallets/walletConnectors/coin98Wallet/coin98Wallet.js +2 -2
  49. package/dist/wallets/walletConnectors/coreWallet/coreWallet.js +2 -2
  50. package/dist/wallets/walletConnectors/foxWallet/foxWallet.js +2 -2
  51. package/dist/wallets/walletConnectors/frontierWallet/frontierWallet.js +2 -2
  52. package/dist/wallets/walletConnectors/gateWallet/gateWallet.js +2 -2
  53. package/dist/wallets/walletConnectors/index.js +58 -58
  54. package/dist/wallets/walletConnectors/metaMaskWallet/metaMaskWallet.js +2 -2
  55. package/dist/wallets/walletConnectors/okxWallet/okxWallet.js +2 -2
  56. package/dist/wallets/walletConnectors/rainbowWallet/rainbowWallet.js +2 -2
  57. package/dist/wallets/walletConnectors/roninWallet/roninWallet.js +2 -2
  58. package/dist/wallets/walletConnectors/safepalWallet/safepalWallet.js +2 -2
  59. package/dist/wallets/walletConnectors/subWallet/subWallet.js +2 -2
  60. package/dist/wallets/walletConnectors/tokenPocketWallet/tokenPocketWallet.js +2 -2
  61. package/dist/wallets/walletConnectors/trustWallet/trustWallet.js +2 -2
  62. package/dist/wallets/walletConnectors/zerionWallet/zerionWallet.js +2 -2
  63. package/package.json +5 -5
  64. package/dist/modals/PolymarketPerpsTransfer/PerpsHeaderTabs.d.ts +0 -29
  65. package/dist/wallets/walletConnectors/{chunk-CU5J53XR.js → chunk-53MYTA42.js} +3 -3
  66. package/dist/wallets/walletConnectors/{chunk-ZSSSLFQF.js → chunk-65ULY6OC.js} +3 -3
  67. package/dist/wallets/walletConnectors/{chunk-XODA5ESL.js → chunk-A5POD5SV.js} +3 -3
  68. package/dist/wallets/walletConnectors/{chunk-RXRYHMRI.js → chunk-ANODOMIN.js} +3 -3
  69. package/dist/wallets/walletConnectors/{chunk-IWOMSW64.js → chunk-ASTCNVJC.js} +3 -3
  70. package/dist/wallets/walletConnectors/{chunk-U52QO5HF.js → chunk-F45CUFRR.js} +3 -3
  71. package/dist/wallets/walletConnectors/{chunk-YRMBR6NA.js → chunk-FYPQ3HP4.js} +3 -3
  72. package/dist/wallets/walletConnectors/{chunk-BBDNB5TQ.js → chunk-IWPW26AL.js} +3 -3
  73. package/dist/wallets/walletConnectors/{chunk-4FHNLTR3.js → chunk-JJBLW4IU.js} +3 -3
  74. package/dist/wallets/walletConnectors/{chunk-NXWG6FG2.js → chunk-KE4CWI3A.js} +3 -3
  75. package/dist/wallets/walletConnectors/{chunk-BBB2J3US.js → chunk-MWB6LFSG.js} +3 -3
  76. package/dist/wallets/walletConnectors/{chunk-34B7OJNT.js → chunk-OVDCDVFX.js} +3 -3
  77. package/dist/wallets/walletConnectors/{chunk-SR5CZR3L.js → chunk-PPQ6L4K2.js} +3 -3
  78. package/dist/wallets/walletConnectors/{chunk-IA5432IR.js → chunk-RJF2YEZ5.js} +3 -3
  79. package/dist/wallets/walletConnectors/{chunk-RFCZYLNR.js → chunk-RQYEGJKL.js} +3 -3
  80. package/dist/wallets/walletConnectors/{chunk-TRZDAXCQ.js → chunk-TIHTQ3OB.js} +3 -3
  81. package/dist/wallets/walletConnectors/{chunk-ALGPGI6V.js → chunk-TM7UBV3Q.js} +3 -3
  82. package/dist/wallets/walletConnectors/{chunk-HOCKAU5H.js → chunk-USLZMUJ3.js} +3 -3
package/CHANGELOG.md CHANGED
@@ -1,5 +1,35 @@
1
1
  # @funkit/connect
2
2
 
3
+ ## 12.15.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 63d3fd1: Add a client checkout config with Deposit and Convert tabs; Convert is preview only.
8
+
9
+ ### Patch Changes
10
+
11
+ - b53014e: Generalized the checkout header tabs pattern.
12
+ - af9f95c: Checkout header tabs choose per tab whether the header behind them is filled; no visual change for existing clients.
13
+ - dddc8d2: Asset selection tags only the selected destination token as Native when a checkout offers several destination tokens.
14
+ - dabbef7: Ethereal and HyENA checkouts no longer have customer-specific behavior.
15
+ - ba38eb9: The token swap widget can show a Deposit prompt when there are no funds to swap.
16
+ - 14467f5: Hide Robinhood chain stock token balances for customers that cannot pay with them.
17
+ - Updated dependencies [dabbef7]
18
+ - Updated dependencies [eda0f63]
19
+ - Updated dependencies [20f085d]
20
+ - Updated dependencies [d786575]
21
+ - Updated dependencies [6a11ead]
22
+ - Updated dependencies [180c23e]
23
+ - Updated dependencies [619c66f]
24
+ - Updated dependencies [9fade05]
25
+ - Updated dependencies [ecd661d]
26
+ - Updated dependencies [33c894c]
27
+ - Updated dependencies [66126c1]
28
+ - Updated dependencies [5bc0d0b]
29
+ - Updated dependencies [724d43b]
30
+ - @funkit/api-base@9.0.0
31
+ - @funkit/connect-core@9.0.0
32
+
3
33
  ## 12.14.0
4
34
 
5
35
  ### Minor Changes
@@ -0,0 +1,12 @@
1
+ import type { FunkitCheckoutConfig } from '../providers/FunkitCheckoutContext/types';
2
+ export interface CreateAxiomDepositConfigParams {
3
+ /** The checkout config the Deposit tab runs. */
4
+ checkoutConfig: FunkitCheckoutConfig;
5
+ }
6
+ /**
7
+ * Adds Axiom's Deposit | Convert header tabs to a checkout config.
8
+ *
9
+ * Convert is in development: it shows an empty swap screen, and this
10
+ * function's params will grow as source wallets and balances are wired in.
11
+ */
12
+ export declare function createAxiomDepositConfig({ checkoutConfig, }: CreateAxiomDepositConfigParams): FunkitCheckoutConfig;
@@ -0,0 +1,27 @@
1
+ "use client";
2
+
3
+ // src/clients/axiom.tsx
4
+ function createAxiomDepositConfig({
5
+ checkoutConfig
6
+ }) {
7
+ return {
8
+ ...checkoutConfig,
9
+ headerTabs: ({ t }) => ({
10
+ tabs: [
11
+ {
12
+ id: "deposit",
13
+ label: t("common.deposit"),
14
+ step: "source_change" /* SOURCE_CHANGE */
15
+ },
16
+ {
17
+ id: "convert",
18
+ label: t("convert.title"),
19
+ step: "convert" /* CONVERT */
20
+ }
21
+ ]
22
+ })
23
+ };
24
+ }
25
+ export {
26
+ createAxiomDepositConfig
27
+ };
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  useFunkitTranslation
4
- } from "./chunk-5GX6G7JR.js";
4
+ } from "./chunk-OB5GKTP2.js";
5
5
 
6
6
  // src/providers/FunkitConfigContext.tsx
7
7
  import {
@@ -688,6 +688,7 @@ var en_default = {
688
688
  pending: "Transfer pending"
689
689
  },
690
690
  tokenSwap: {
691
+ noFundsAvailable: "You have no funds available",
691
692
  from: "From",
692
693
  to: "To",
693
694
  switchDirection: "Switch direction",
@@ -695,6 +696,9 @@ var en_default = {
695
696
  selectToken: "Select token, {{symbol}} selected",
696
697
  balance: "Balance: {{amount}}"
697
698
  },
699
+ convert: {
700
+ title: "Convert"
701
+ },
698
702
  errorFallback: {
699
703
  title: "Something went wrong",
700
704
  description: "Close this window and try again.",
@@ -1302,6 +1306,7 @@ var es_default = {
1302
1306
  pending: "Transferencia pendiente"
1303
1307
  },
1304
1308
  tokenSwap: {
1309
+ noFundsAvailable: "No tienes fondos disponibles",
1305
1310
  from: "Desde",
1306
1311
  to: "A",
1307
1312
  switchDirection: "Cambiar direcci\xF3n",
@@ -1309,6 +1314,9 @@ var es_default = {
1309
1314
  selectToken: "Seleccionar token, {{symbol}} seleccionado",
1310
1315
  balance: "Saldo: {{amount}}"
1311
1316
  },
1317
+ convert: {
1318
+ title: "Convertir"
1319
+ },
1312
1320
  errorFallback: {
1313
1321
  title: "Algo sali\xF3 mal",
1314
1322
  description: "Cierra esta ventana e int\xE9ntalo de nuevo.",
@@ -1916,6 +1924,7 @@ var fr_default = {
1916
1924
  pending: "Transfert en attente"
1917
1925
  },
1918
1926
  tokenSwap: {
1927
+ noFundsAvailable: "Vous n\u2019avez pas de fonds disponibles",
1919
1928
  from: "De",
1920
1929
  to: "Vers",
1921
1930
  switchDirection: "Inverser le sens",
@@ -1923,6 +1932,9 @@ var fr_default = {
1923
1932
  selectToken: "S\xE9lectionner un jeton, {{symbol}} s\xE9lectionn\xE9",
1924
1933
  balance: "Solde : {{amount}}"
1925
1934
  },
1935
+ convert: {
1936
+ title: "Convertir"
1937
+ },
1926
1938
  errorFallback: {
1927
1939
  title: "Un probl\xE8me est survenu",
1928
1940
  description: "Fermez cette fen\xEAtre et r\xE9essayez.",
@@ -2530,6 +2542,7 @@ var ja_default = {
2530
2542
  pending: "\u9001\u91D1\u4FDD\u7559\u4E2D"
2531
2543
  },
2532
2544
  tokenSwap: {
2545
+ noFundsAvailable: "\u5229\u7528\u53EF\u80FD\u306A\u8CC7\u91D1\u304C\u3042\u308A\u307E\u305B\u3093",
2533
2546
  from: "\u9001\u4FE1\u5143",
2534
2547
  to: "\u9001\u4FE1\u5148",
2535
2548
  switchDirection: "\u65B9\u5411\u3092\u5207\u308A\u66FF\u3048\u308B",
@@ -2537,6 +2550,9 @@ var ja_default = {
2537
2550
  selectToken: "\u30C8\u30FC\u30AF\u30F3\u3092\u9078\u629E\uFF08{{symbol}}\u3092\u9078\u629E\u4E2D\uFF09",
2538
2551
  balance: "\u6B8B\u9AD8\uFF1A{{amount}}"
2539
2552
  },
2553
+ convert: {
2554
+ title: "\u5909\u63DB"
2555
+ },
2540
2556
  errorFallback: {
2541
2557
  title: "\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F",
2542
2558
  description: "\u3053\u306E\u30A6\u30A3\u30F3\u30C9\u30A6\u3092\u9589\u3058\u3066\u3001\u3082\u3046\u4E00\u5EA6\u304A\u8A66\u3057\u304F\u3060\u3055\u3044\u3002",
@@ -3144,6 +3160,7 @@ var ko_default = {
3144
3160
  pending: "\uC774\uCCB4 \uB300\uAE30 \uC911"
3145
3161
  },
3146
3162
  tokenSwap: {
3163
+ noFundsAvailable: "\uC0AC\uC6A9 \uAC00\uB2A5\uD55C \uC790\uAE08\uC774 \uC5C6\uC2B5\uB2C8\uB2E4",
3147
3164
  from: "\uBCF4\uB0B4\uB294 \uC790\uC0B0",
3148
3165
  to: "\uBC1B\uB294 \uC790\uC0B0",
3149
3166
  switchDirection: "\uBC29\uD5A5 \uC804\uD658",
@@ -3151,6 +3168,9 @@ var ko_default = {
3151
3168
  selectToken: "\uD1A0\uD070 \uC120\uD0DD, {{symbol}} \uC120\uD0DD\uB428",
3152
3169
  balance: "\uC794\uC561: {{amount}}"
3153
3170
  },
3171
+ convert: {
3172
+ title: "\uC804\uD658"
3173
+ },
3154
3174
  errorFallback: {
3155
3175
  title: "\uBB38\uC81C\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4",
3156
3176
  description: "\uC774 \uCC3D\uC744 \uB2EB\uACE0 \uB2E4\uC2DC \uC2DC\uB3C4\uD574 \uC8FC\uC138\uC694.",
@@ -3758,6 +3778,7 @@ var ru_default = {
3758
3778
  pending: "\u041F\u0435\u0440\u0435\u0432\u043E\u0434 \u0432 \u043E\u0431\u0440\u0430\u0431\u043E\u0442\u043A\u0435"
3759
3779
  },
3760
3780
  tokenSwap: {
3781
+ noFundsAvailable: "\u0423 \u0432\u0430\u0441 \u043D\u0435\u0442 \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u044B\u0445 \u0441\u0440\u0435\u0434\u0441\u0442\u0432",
3761
3782
  from: "\u0418\u0437",
3762
3783
  to: "\u0412",
3763
3784
  switchDirection: "\u0418\u0437\u043C\u0435\u043D\u0438\u0442\u044C \u043D\u0430\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u0438\u0435",
@@ -3765,6 +3786,9 @@ var ru_default = {
3765
3786
  selectToken: "\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0442\u043E\u043A\u0435\u043D, \u0432\u044B\u0431\u0440\u0430\u043D {{symbol}}",
3766
3787
  balance: "\u0411\u0430\u043B\u0430\u043D\u0441: {{amount}}"
3767
3788
  },
3789
+ convert: {
3790
+ title: "\u041A\u043E\u043D\u0432\u0435\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C"
3791
+ },
3768
3792
  errorFallback: {
3769
3793
  title: "\u0427\u0442\u043E-\u0442\u043E \u043F\u043E\u0448\u043B\u043E \u043D\u0435 \u0442\u0430\u043A",
3770
3794
  description: "\u0417\u0430\u043A\u0440\u043E\u0439\u0442\u0435 \u044D\u0442\u043E \u043E\u043A\u043D\u043E \u0438 \u043F\u043E\u043F\u0440\u043E\u0431\u0443\u0439\u0442\u0435 \u0441\u043D\u043E\u0432\u0430.",
@@ -4372,6 +4396,7 @@ var tr_default = {
4372
4396
  pending: "Transfer beklemede"
4373
4397
  },
4374
4398
  tokenSwap: {
4399
+ noFundsAvailable: "Kullan\u0131labilir bakiyeniz yok",
4375
4400
  from: "Kaynak",
4376
4401
  to: "Hedef",
4377
4402
  switchDirection: "Y\xF6n\xFC de\u011Fi\u015Ftir",
@@ -4379,6 +4404,9 @@ var tr_default = {
4379
4404
  selectToken: "Token se\xE7, {{symbol}} se\xE7ili",
4380
4405
  balance: "Bakiye: {{amount}}"
4381
4406
  },
4407
+ convert: {
4408
+ title: "D\xF6n\xFC\u015Ft\xFCr"
4409
+ },
4382
4410
  errorFallback: {
4383
4411
  title: "Bir \u015Feyler yanl\u0131\u015F gitti",
4384
4412
  description: "Bu pencereyi kapat\u0131p tekrar deneyin.",
@@ -4986,6 +5014,7 @@ var zh_default = {
4986
5014
  pending: "\u8F6C\u8D26\u5904\u7406\u4E2D"
4987
5015
  },
4988
5016
  tokenSwap: {
5017
+ noFundsAvailable: "\u60A8\u6CA1\u6709\u53EF\u7528\u8D44\u91D1",
4989
5018
  from: "\u4ECE",
4990
5019
  to: "\u81F3",
4991
5020
  switchDirection: "\u5207\u6362\u65B9\u5411",
@@ -4993,6 +5022,9 @@ var zh_default = {
4993
5022
  selectToken: "\u9009\u62E9\u4EE3\u5E01\uFF0C\u5DF2\u9009 {{symbol}}",
4994
5023
  balance: "\u4F59\u989D\uFF1A{{amount}}"
4995
5024
  },
5025
+ convert: {
5026
+ title: "\u5151\u6362"
5027
+ },
4996
5028
  errorFallback: {
4997
5029
  title: "\u51FA\u73B0\u95EE\u9898",
4998
5030
  description: "\u8BF7\u5173\u95ED\u6B64\u7A97\u53E3\u540E\u91CD\u8BD5\u3002",
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  i18n_default
4
- } from "./chunk-P6UM36G5.js";
4
+ } from "./chunk-7JYLS7IF.js";
5
5
 
6
6
  // src/clients/internal/nado/withdrawalErrors.ts
7
7
  import {
@@ -1,11 +1,11 @@
1
1
  "use client";
2
- import {
3
- isExpectedNadoWithdrawalFailure,
4
- toNadoWithdrawalErrorMessage
5
- } from "./chunk-ZOQQL2QX.js";
6
2
  import {
7
3
  toWithdrawalAmountBaseUnit
8
4
  } from "./chunk-4DBUYTEE.js";
5
+ import {
6
+ isExpectedNadoWithdrawalFailure,
7
+ toNadoWithdrawalErrorMessage
8
+ } from "./chunk-BKK2BFIP.js";
9
9
  import {
10
10
  getAccount,
11
11
  signTypedData,
@@ -13,10 +13,10 @@ import {
13
13
  } from "./chunk-OODIKHYE.js";
14
14
  import {
15
15
  i18n_default
16
- } from "./chunk-P6UM36G5.js";
16
+ } from "./chunk-7JYLS7IF.js";
17
17
  import {
18
18
  generateClientMetadataForTokenTransfer
19
- } from "./chunk-I5GSXPFE.js";
19
+ } from "./chunk-TKEBGMVW.js";
20
20
  import {
21
21
  logger
22
22
  } from "./chunk-AHYOV7AV.js";
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  generateClientMetadataForTokenTransfer
4
- } from "./chunk-I5GSXPFE.js";
4
+ } from "./chunk-TKEBGMVW.js";
5
5
  import {
6
6
  logger
7
7
  } from "./chunk-AHYOV7AV.js";
@@ -10,14 +10,31 @@ import {
10
10
  VAULT_DEPOSITOR_ABI,
11
11
  VAULT_DEPOSITOR_POLYGON,
12
12
  createPerpsGenerateActionParams
13
- } from "./chunk-R6E3NH5A.js";
13
+ } from "./chunk-FLREOB24.js";
14
14
  import {
15
15
  logger
16
16
  } from "./chunk-AHYOV7AV.js";
17
17
 
18
18
  // src/clients/polymarket/createPolymarketDepositConfig.ts
19
- import { encodeFunctionData, erc20Abi, getAddress, maxUint256 } from "viem";
19
+ import { encodeFunctionData, erc20Abi, getAddress as getAddress2, maxUint256 } from "viem";
20
+ import { polygon as polygon2 } from "viem/chains";
21
+
22
+ // src/domains/polymarketPerps.ts
23
+ import { getAddress } from "viem";
20
24
  import { polygon } from "viem/chains";
25
+ function polymarketAccountCandidate(routingId, recipient) {
26
+ return {
27
+ tokenAddress: POLYGON_USDCE,
28
+ tokenChainId: polygon.id.toString(),
29
+ tokenSymbol: PUSD_TOKEN.symbol,
30
+ iconSrc: PUSD_TOKEN.iconSrc,
31
+ dynamicRoutingId: routingId,
32
+ // Checksum: integrator addresses aren't guaranteed EIP-55.
33
+ customRecipient: getAddress(recipient)
34
+ };
35
+ }
36
+
37
+ // src/clients/polymarket/createPolymarketDepositConfig.ts
21
38
  function createPredictionsGenerateActionParams(config) {
22
39
  const { recipientAddress } = config;
23
40
  return async () => {
@@ -93,10 +110,10 @@ function createPolymarketDepositConfig({
93
110
  requestedDefaultAccount: defaultAccount,
94
111
  resolvedDefaultAccount
95
112
  });
96
- const predictionsRecipient = getAddress(predictions.address);
97
- const perpsRecipient = getAddress(perps.address);
113
+ const predictionsRecipient = getAddress2(predictions.address);
114
+ const perpsRecipient = getAddress2(perps.address);
98
115
  return {
99
- targetChain: polygon.id.toString(),
116
+ targetChain: polygon2.id.toString(),
100
117
  targetAsset: POLYGON_USDCE,
101
118
  targetAssetAmount: 0,
102
119
  targetAssetTicker: PUSD_TOKEN.symbol,
@@ -142,6 +159,50 @@ function createPolymarketDepositConfig({
142
159
  access: resolvedAccess,
143
160
  initialDirection: transferDefaults?.direction,
144
161
  initialAmountUsd: transferDefaults?.amountUsd
162
+ },
163
+ headerTabs: ({ config, t }) => {
164
+ const perpsTransfer = config.polymarketPerpsTransfer;
165
+ if (!perpsTransfer) {
166
+ return void 0;
167
+ }
168
+ const tabAccess = perpsTransfer.access ?? FULL_DEPOSIT_ACCESS;
169
+ const isPerps = config.dynamicRoutingId === POLYMARKET_PERPS_ROUTING_ID;
170
+ return {
171
+ // Predictions and Perps share the deposit screen; the live routing id
172
+ // says which one the checkout is on.
173
+ resolveSharedTab: () => isPerps ? "perps" : "predictions",
174
+ tabs: [
175
+ {
176
+ id: "predictions",
177
+ label: t("perpsTransfer.predictions"),
178
+ disabled: !tabAccess.predictions,
179
+ disabledTooltip: t("perpsTransfer.unavailableInLocation"),
180
+ step: "source_change" /* SOURCE_CHANGE */,
181
+ headerBackground: "offBackground",
182
+ dynamicTargetAsset: polymarketAccountCandidate(
183
+ POLYMARKET_PREDICTIONS_ROUTING_ID,
184
+ perpsTransfer.predictions.address
185
+ )
186
+ },
187
+ {
188
+ id: "perps",
189
+ label: t("perpsTransfer.perps"),
190
+ disabled: !tabAccess.perps,
191
+ disabledTooltip: t("perpsTransfer.unavailableInLocation"),
192
+ step: "source_change" /* SOURCE_CHANGE */,
193
+ headerBackground: "offBackground",
194
+ dynamicTargetAsset: polymarketAccountCandidate(
195
+ POLYMARKET_PERPS_ROUTING_ID,
196
+ perpsTransfer.perps.address
197
+ )
198
+ },
199
+ {
200
+ id: "transfer",
201
+ label: t("perpsTransfer.title"),
202
+ step: "perps_transfer" /* PERPS_TRANSFER */
203
+ }
204
+ ]
205
+ };
145
206
  }
146
207
  };
147
208
  }
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  i18n_default
4
- } from "./chunk-P6UM36G5.js";
4
+ } from "./chunk-7JYLS7IF.js";
5
5
 
6
6
  // src/hooks/useFunkitTranslation.ts
7
7
  import { useTranslation } from "react-i18next";
@@ -5,10 +5,7 @@ import { PaymentMethod } from "@funkit/connect-core";
5
5
  import { exhaustiveCheck, formatAddress } from "@funkit/utils";
6
6
 
7
7
  // src/consts/bluvo.tsx
8
- import {
9
- ETHEREAL_API_KEY,
10
- FormOfPaymentType
11
- } from "@funkit/api-base";
8
+ import { FormOfPaymentType } from "@funkit/api-base";
12
9
  import React3 from "react";
13
10
 
14
11
  // src/components/Icons/BybitIcon.tsx
@@ -76,9 +73,6 @@ var CoinbaseIcon = ({ size = 24 }) => {
76
73
  };
77
74
 
78
75
  // src/consts/bluvo.tsx
79
- var BLUVO_MIN_DEPOSIT_BY_CUSTOMER = {
80
- [ETHEREAL_API_KEY]: 15
81
- };
82
76
  var BLUVO_EXCHANGES = {
83
77
  coinbase: {
84
78
  icon: (size) => /* @__PURE__ */ React3.createElement(CoinbaseIcon, { size }),
@@ -10,8 +10,8 @@ import {
10
10
  } from "./chunk-RQALGV5U.js";
11
11
  import {
12
12
  useFunkitTranslation
13
- } from "./chunk-5GX6G7JR.js";
14
- import "./chunk-P6UM36G5.js";
13
+ } from "./chunk-OB5GKTP2.js";
14
+ import "./chunk-7JYLS7IF.js";
15
15
  import "./chunk-AHYOV7AV.js";
16
16
 
17
17
  // src/clients/fanatics.tsx
@@ -1,12 +1,12 @@
1
1
  "use client";
2
2
  import {
3
3
  createNadoWithdrawalCallback
4
- } from "../../chunk-I75AI3N7.js";
5
- import "../../chunk-ZOQQL2QX.js";
4
+ } from "../../chunk-C3BTAVJA.js";
6
5
  import "../../chunk-4DBUYTEE.js";
6
+ import "../../chunk-BKK2BFIP.js";
7
7
  import "../../chunk-OODIKHYE.js";
8
- import "../../chunk-P6UM36G5.js";
9
- import "../../chunk-I5GSXPFE.js";
8
+ import "../../chunk-7JYLS7IF.js";
9
+ import "../../chunk-TKEBGMVW.js";
10
10
  import "../../chunk-AHYOV7AV.js";
11
11
  export {
12
12
  createNadoWithdrawalCallback
@@ -2,8 +2,8 @@
2
2
  import {
3
3
  isExpectedNadoWithdrawalFailure,
4
4
  toNadoWithdrawalErrorMessage
5
- } from "../../chunk-ZOQQL2QX.js";
6
- import "../../chunk-P6UM36G5.js";
5
+ } from "../../chunk-BKK2BFIP.js";
6
+ import "../../chunk-7JYLS7IF.js";
7
7
  export {
8
8
  isExpectedNadoWithdrawalFailure,
9
9
  toNadoWithdrawalErrorMessage
@@ -8,13 +8,13 @@ import {
8
8
  import "../../chunk-6EU6CXNH.js";
9
9
  import {
10
10
  useFunkitConfig
11
- } from "../../chunk-YMBIRJQF.js";
11
+ } from "../../chunk-6IH7AWFA.js";
12
12
  import {
13
13
  useFunkitTranslation
14
- } from "../../chunk-5GX6G7JR.js";
14
+ } from "../../chunk-OB5GKTP2.js";
15
15
  import "../../chunk-4DBUYTEE.js";
16
16
  import "../../chunk-2W2P3OS6.js";
17
- import "../../chunk-P6UM36G5.js";
17
+ import "../../chunk-7JYLS7IF.js";
18
18
  import {
19
19
  logger
20
20
  } from "../../chunk-AHYOV7AV.js";
@@ -1,12 +1,12 @@
1
1
  "use client";
2
2
  import {
3
3
  useFunkitConfig
4
- } from "../../chunk-YMBIRJQF.js";
5
- import "../../chunk-5GX6G7JR.js";
4
+ } from "../../chunk-6IH7AWFA.js";
5
+ import "../../chunk-OB5GKTP2.js";
6
6
  import {
7
7
  useAccount
8
8
  } from "../../chunk-2W2P3OS6.js";
9
- import "../../chunk-P6UM36G5.js";
9
+ import "../../chunk-7JYLS7IF.js";
10
10
  import {
11
11
  logger
12
12
  } from "../../chunk-AHYOV7AV.js";
@@ -17277,6 +17277,52 @@
17277
17277
  opacity: 1;
17278
17278
  }
17279
17279
 
17280
+ /* vanilla-extract-css-ns:src/components/LargeAmountInput/LargeAmountInput.css.ts.vanilla.css?source=LmxpcTY5dTAgewogIGFwcGVhcmFuY2U6IG5vbmU7CiAgLXdlYmtpdC1hcHBlYXJhbmNlOiBub25lOwogIGJvcmRlcjogbm9uZTsKICBvdXRsaW5lOiBub25lOwogIGJhY2tncm91bmQ6IHRyYW5zcGFyZW50OwogIHBhZGRpbmc6IDA7CiAgbWFyZ2luOiAwOwogIHdpZHRoOiAxMDAlOwogIG1pbi13aWR0aDogMDsKICBmb250LWZhbWlseTogaW5oZXJpdDsKICBmb250LXNpemU6IGluaGVyaXQgIWltcG9ydGFudDsKICBsaW5lLWhlaWdodDogaW5oZXJpdDsKICBmb250LXdlaWdodDogaW5oZXJpdDsKICBjb2xvcjogdmFyKC0tcmstY29sb3JzLXByaW1hcnlUZXh0KTsKICBjYXJldC1jb2xvcjogdmFyKC0tcmstY29sb3JzLXByaW1hcnlUZXh0KTsKfQoubGlxNjl1MDo6cGxhY2Vob2xkZXIgewogIGNvbG9yOiB2YXIoLS1yay1jb2xvcnMtc2Vjb25kYXJ5VGV4dCk7CiAgb3BhY2l0eTogMTsKfQoubGlxNjl1MDpyZWFkLW9ubHkgewogIGN1cnNvcjogZGVmYXVsdDsKfQ */
17281
+ [data-rk] .liq69u0 {
17282
+ -moz-appearance: none;
17283
+ appearance: none;
17284
+ -webkit-appearance: none;
17285
+ border: none;
17286
+ outline: none;
17287
+ background: transparent;
17288
+ padding: 0;
17289
+ margin: 0;
17290
+ width: 100%;
17291
+ min-width: 0;
17292
+ font-family: inherit;
17293
+ font-size: inherit !important;
17294
+ line-height: inherit;
17295
+ font-weight: inherit;
17296
+ color: var(--rk-colors-primaryText);
17297
+ caret-color: var(--rk-colors-primaryText);
17298
+ }
17299
+ [data-rk] .liq69u0::-moz-placeholder {
17300
+ color: var(--rk-colors-secondaryText);
17301
+ opacity: 1;
17302
+ }
17303
+ [data-rk] .liq69u0::placeholder {
17304
+ color: var(--rk-colors-secondaryText);
17305
+ opacity: 1;
17306
+ }
17307
+ [data-rk] .liq69u0:-moz-read-only {
17308
+ cursor: default;
17309
+ }
17310
+ [data-rk] .liq69u0:read-only {
17311
+ cursor: default;
17312
+ }
17313
+
17314
+ /* vanilla-extract-css-ns:src/components/TokenSwapWidget/TokenSwapWidget.css.ts.vanilla.css?source=LnhpOWM3ajAgewogIHBvc2l0aW9uOiBhYnNvbHV0ZTsKICB0b3A6IDUwJTsKICBsZWZ0OiA1MCU7CiAgdHJhbnNmb3JtOiB0cmFuc2xhdGUoLTUwJSwgLTUwJSk7CiAgei1pbmRleDogMTsKICBwYWRkaW5nOiA0cHg7CiAgYm9yZGVyLXJhZGl1czogNTAlOwogIGJhY2tncm91bmQ6IHZhcigtLXJrLWNvbG9ycy1tb2RhbEJhY2tncm91bmQpOwp9 */
17315
+ [data-rk] .xi9c7j0 {
17316
+ position: absolute;
17317
+ top: 50%;
17318
+ left: 50%;
17319
+ transform: translate(-50%, -50%);
17320
+ z-index: 1;
17321
+ padding: 4px;
17322
+ border-radius: 50%;
17323
+ background: var(--rk-colors-modalBackground);
17324
+ }
17325
+
17280
17326
  /* vanilla-extract-css-ns:src/components/FunSelectBrokerage/FunBrokerageItem.css.ts.vanilla.css?source=LmFuMzR5OTAgewogIGRpc3BsYXk6IGZsZXg7CiAganVzdGlmeS1jb250ZW50OiBzcGFjZS1iZXR3ZWVuOwogIGFsaWduLWl0ZW1zOiBjZW50ZXI7CiAgZmxleDogMTsKfQ */
17281
17327
  [data-rk] .an34y90 {
17282
17328
  display: flex;
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-6EU6CXNH.js";
6
6
  import {
7
7
  useFunkitConfig
8
- } from "./chunk-YMBIRJQF.js";
8
+ } from "./chunk-6IH7AWFA.js";
9
9
  import {
10
10
  AsyncImage,
11
11
  Box,
@@ -13,10 +13,10 @@ import {
13
13
  } from "./chunk-RQALGV5U.js";
14
14
  import {
15
15
  useFunkitTranslation
16
- } from "./chunk-5GX6G7JR.js";
16
+ } from "./chunk-OB5GKTP2.js";
17
17
  import "./chunk-OODIKHYE.js";
18
18
  import "./chunk-2W2P3OS6.js";
19
- import "./chunk-P6UM36G5.js";
19
+ import "./chunk-7JYLS7IF.js";
20
20
  import {
21
21
  logger
22
22
  } from "./chunk-AHYOV7AV.js";
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  useFunkitTranslation
4
- } from "./chunk-5GX6G7JR.js";
4
+ } from "./chunk-OB5GKTP2.js";
5
5
  import {
6
6
  getAccount,
7
7
  sendTransaction,
@@ -14,7 +14,7 @@ import {
14
14
  useAccount,
15
15
  useConfig
16
16
  } from "./chunk-2W2P3OS6.js";
17
- import "./chunk-P6UM36G5.js";
17
+ import "./chunk-7JYLS7IF.js";
18
18
  import {
19
19
  logger
20
20
  } from "./chunk-AHYOV7AV.js";
@@ -1,9 +1,9 @@
1
1
  "use client";
2
2
  import {
3
3
  createNadoWithdrawalCallback
4
- } from "./chunk-I75AI3N7.js";
5
- import "./chunk-ZOQQL2QX.js";
4
+ } from "./chunk-C3BTAVJA.js";
6
5
  import "./chunk-4DBUYTEE.js";
6
+ import "./chunk-BKK2BFIP.js";
7
7
  import "./chunk-OODIKHYE.js";
8
8
  import {
9
9
  useAccount,
@@ -11,8 +11,8 @@ import {
11
11
  } from "./chunk-2W2P3OS6.js";
12
12
  import {
13
13
  i18n_default
14
- } from "./chunk-P6UM36G5.js";
15
- import "./chunk-I5GSXPFE.js";
14
+ } from "./chunk-7JYLS7IF.js";
15
+ import "./chunk-TKEBGMVW.js";
16
16
  import {
17
17
  logger
18
18
  } from "./chunk-AHYOV7AV.js";
@@ -76,10 +76,10 @@ export interface CreatePolymarketDepositConfigParams {
76
76
  }
77
77
  /**
78
78
  * Builds the entire Polymarket deposit checkout config from the two accounts.
79
- * Because `polymarketPerpsTransfer` is set, the checkout modal enters its
80
- * perps header-tabs state (Predictions | Perps | Transfer) on the deposit and
81
- * transfer screens — the tabs switch `dynamicRoutingId` or open the transfer
82
- * step; modal title, min deposit, recipient and on-chain deposit actions are
83
- * derived per account. Supersedes the "Deposit to" dropdown.
79
+ * Its `headerTabs` show Predictions | Perps | Transfer on the deposit and
80
+ * transfer screens while `polymarketPerpsTransfer` is set — the tabs switch
81
+ * `dynamicRoutingId` or open the transfer step; modal title, min deposit,
82
+ * recipient and on-chain deposit actions are derived per account. Supersedes
83
+ * the "Deposit to" dropdown.
84
84
  */
85
85
  export declare function createPolymarketDepositConfig({ predictions, perps, modalTitleMeta, modalTitles, defaultAccount, pendingTransfers, access, transferDefaults, }: CreatePolymarketDepositConfigParams): FunkitCheckoutConfig;
@@ -2,12 +2,12 @@
2
2
  import {
3
3
  createPolymarketDepositConfig,
4
4
  createPredictionsGenerateActionParams
5
- } from "../chunk-U33QNTIA.js";
5
+ } from "../chunk-IUVVGGP4.js";
6
6
  import {
7
7
  POLYMARKET_PERPS_ROUTING_ID,
8
8
  POLYMARKET_PREDICTIONS_ROUTING_ID
9
- } from "../chunk-R6E3NH5A.js";
10
- import "../chunk-I5GSXPFE.js";
9
+ } from "../chunk-FLREOB24.js";
10
+ import "../chunk-TKEBGMVW.js";
11
11
  import "../chunk-AHYOV7AV.js";
12
12
  export {
13
13
  POLYMARKET_PERPS_ROUTING_ID,
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  createPolymarketDepositConfig,
4
4
  createPredictionsGenerateActionParams
5
- } from "../chunk-U33QNTIA.js";
5
+ } from "../chunk-IUVVGGP4.js";
6
6
  import {
7
7
  AMOUNT_PLACEHOLDER,
8
8
  COLLATERAL_ONRAMP_ABI,
@@ -15,8 +15,8 @@ import {
15
15
  VAULT_DEPOSITOR_POLYGON,
16
16
  createPerpsGenerateActionParams,
17
17
  createPolymarketWithdrawalConfig
18
- } from "../chunk-R6E3NH5A.js";
19
- import "../chunk-I5GSXPFE.js";
18
+ } from "../chunk-FLREOB24.js";
19
+ import "../chunk-TKEBGMVW.js";
20
20
  import "../chunk-AHYOV7AV.js";
21
21
  export {
22
22
  AMOUNT_PLACEHOLDER,
@@ -9,8 +9,8 @@ import {
9
9
  VAULT_DEPOSITOR_POLYGON,
10
10
  createPerpsGenerateActionParams,
11
11
  createPolymarketWithdrawalConfig
12
- } from "../chunk-R6E3NH5A.js";
13
- import "../chunk-I5GSXPFE.js";
12
+ } from "../chunk-FLREOB24.js";
13
+ import "../chunk-TKEBGMVW.js";
14
14
  import "../chunk-AHYOV7AV.js";
15
15
  export {
16
16
  AMOUNT_PLACEHOLDER,