@funkit/connect 8.3.0 → 8.3.1-next.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 (64) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/dist/__generated__/default_configs.d.ts +63 -0
  3. package/dist/atoms/activeCheckout.d.ts +183 -0
  4. package/dist/atoms/activeWithdrawal.d.ts +21 -0
  5. package/dist/atoms/bridgeProviders/acrossAdapter.d.ts +109 -0
  6. package/dist/atoms/bridgeProviders/index.d.ts +25 -0
  7. package/dist/atoms/bridgeProviders/registry.d.ts +12 -0
  8. package/dist/atoms/bridgeProviders/relayAdapter.d.ts +60 -0
  9. package/dist/atoms/bridgeProviders/types.d.ts +182 -0
  10. package/dist/atoms/checkoutProgress.d.ts +22 -0
  11. package/dist/atoms/directExecution.d.ts +70 -0
  12. package/dist/atoms/funkitCheckout.d.ts +18 -0
  13. package/dist/atoms/funkitProvider/index.d.ts +24 -0
  14. package/dist/atoms/generalWallet.d.ts +45 -0
  15. package/dist/atoms/i18n.d.ts +6 -0
  16. package/dist/atoms/modalState.d.ts +30 -0
  17. package/dist/atoms/quote.d.ts +98 -0
  18. package/dist/atoms/stepTransition.d.ts +6 -0
  19. package/dist/atoms/store.d.ts +1 -0
  20. package/dist/atoms/track/index.d.ts +10 -0
  21. package/dist/atoms/utils.d.ts +2 -0
  22. package/dist/atoms/wagmi.d.ts +4 -0
  23. package/dist/atoms/walletClient.d.ts +15391 -0
  24. package/dist/chunk-5JRQC2VM.js +300 -0
  25. package/dist/chunk-CUWQELX3.js +209 -0
  26. package/dist/chunk-FBCU3TQA.js +204 -0
  27. package/dist/chunk-MGQZMUZ2.js +288 -0
  28. package/dist/chunk-OTMBU2BL.js +204 -0
  29. package/dist/chunk-VWSYBHAK.js +209 -0
  30. package/dist/clients/fanatics.css +1 -1
  31. package/dist/components/FunPaymentMethodItem/FunPaymentMethodItemSkeleton.d.ts +2 -0
  32. package/dist/components/Icons/AcrossIcon.d.ts +4 -0
  33. package/dist/domains/across.d.ts +29 -0
  34. package/dist/domains/track.d.ts +14 -0
  35. package/dist/hooks/queries/useFops.d.ts +15 -0
  36. package/dist/hooks/useUsableWalletAssetsForCheckout.d.ts +2 -0
  37. package/dist/index.css +7 -7
  38. package/dist/index.js +78 -56
  39. package/dist/modals/CheckoutModal/SelectAsset.d.ts +14 -0
  40. package/dist/modals/CheckoutModal/SourceChange/ConnectedSource.d.ts +11 -0
  41. package/dist/modals/CheckoutModal/SwappedIframe/SwappedIframe.d.ts +16 -0
  42. package/dist/modals/CheckoutModal/SwappedIframe/index.d.ts +1 -0
  43. package/dist/providers/FunkitCheckoutContext/types.d.ts +1 -0
  44. package/dist/utils/lighter.d.ts +0 -2
  45. package/dist/wallets/walletConnectors/chunk-3ZWIUCOI.js +96 -0
  46. package/dist/wallets/walletConnectors/chunk-4SC3PZVM.js +70 -0
  47. package/dist/wallets/walletConnectors/chunk-5AV2NSL3.js +98 -0
  48. package/dist/wallets/walletConnectors/chunk-5FWURLPF.js +218 -0
  49. package/dist/wallets/walletConnectors/chunk-6677RKVT.js +69 -0
  50. package/dist/wallets/walletConnectors/chunk-75A4Q5E5.js +92 -0
  51. package/dist/wallets/walletConnectors/chunk-ENLR4LXN.js +94 -0
  52. package/dist/wallets/walletConnectors/chunk-FT5BX7TL.js +103 -0
  53. package/dist/wallets/walletConnectors/chunk-GEMN6DM5.js +106 -0
  54. package/dist/wallets/walletConnectors/chunk-GXTI2PZD.js +100 -0
  55. package/dist/wallets/walletConnectors/chunk-LGT6IAXI.js +93 -0
  56. package/dist/wallets/walletConnectors/chunk-N7475PGA.js +110 -0
  57. package/dist/wallets/walletConnectors/chunk-O6YFVGVQ.js +99 -0
  58. package/dist/wallets/walletConnectors/chunk-OCM5YHT5.js +92 -0
  59. package/dist/wallets/walletConnectors/chunk-PRGCIJ7Y.js +87 -0
  60. package/dist/wallets/walletConnectors/chunk-RNIMZDHW.js +95 -0
  61. package/dist/wallets/walletConnectors/chunk-TLOROKED.js +96 -0
  62. package/dist/wallets/walletConnectors/chunk-WNQ3NPHX.js +66 -0
  63. package/dist/wallets/walletConnectors/index.js +6 -6
  64. package/package.json +3 -3
@@ -0,0 +1,70 @@
1
+ "use client";
2
+ import {
3
+ getInjectedConnector,
4
+ hasInjectedProvider
5
+ } from "./chunk-ARYAYQ7Z.js";
6
+ import {
7
+ getWalletConnectConnector
8
+ } from "./chunk-23WIEY36.js";
9
+
10
+ // src/wallets/walletConnectors/rainbowWallet/rainbowWallet.ts
11
+ import { isAndroid, isIOS } from "@funkit/utils";
12
+ var rainbowWallet = ({
13
+ projectId,
14
+ walletConnectParameters
15
+ }) => {
16
+ const isRainbowInjected = hasInjectedProvider({ flag: "isRainbow" });
17
+ const shouldUseWalletConnect = !isRainbowInjected;
18
+ const getUri = (uri) => {
19
+ return isAndroid() ? uri : isIOS() ? `rainbow://wc?uri=${encodeURIComponent(uri)}&connector=rainbowkit` : `https://rnbwapp.com/wc?uri=${encodeURIComponent(
20
+ uri
21
+ )}&connector=rainbowkit`;
22
+ };
23
+ return {
24
+ id: "rainbow",
25
+ name: "Rainbow",
26
+ rdns: "me.rainbow",
27
+ iconUrl: async () => (await import("./rainbowWallet-MFJQCICF.js")).default,
28
+ iconBackground: "#0c2f78",
29
+ installed: !shouldUseWalletConnect ? isRainbowInjected : void 0,
30
+ downloadUrls: {
31
+ android: "https://play.google.com/store/apps/details?id=me.rainbow&referrer=utm_source%3Drainbowkit&utm_source=rainbowkit",
32
+ ios: "https://apps.apple.com/app/apple-store/id1457119021?pt=119997837&ct=rainbowkit&mt=8",
33
+ mobile: "https://rainbow.download?utm_source=rainbowkit",
34
+ qrCode: "https://rainbow.download?utm_source=rainbowkit&utm_medium=qrcode",
35
+ browserExtension: "https://rainbow.me/extension?utm_source=rainbowkit"
36
+ },
37
+ mobile: { getUri: shouldUseWalletConnect ? getUri : void 0 },
38
+ qrCode: shouldUseWalletConnect ? {
39
+ getUri,
40
+ instructions: {
41
+ learnMoreUrl: "https://learn.rainbow.me/connect-to-a-website-or-app?utm_source=rainbowkit&utm_medium=connector&utm_campaign=learnmore",
42
+ steps: [
43
+ {
44
+ description: "wallet_connectors.rainbow.qr_code.step1.description",
45
+ step: "install",
46
+ title: "wallet_connectors.rainbow.qr_code.step1.title"
47
+ },
48
+ {
49
+ description: "wallet_connectors.rainbow.qr_code.step2.description",
50
+ step: "create",
51
+ title: "wallet_connectors.rainbow.qr_code.step2.title"
52
+ },
53
+ {
54
+ description: "wallet_connectors.rainbow.qr_code.step3.description",
55
+ step: "scan",
56
+ title: "wallet_connectors.rainbow.qr_code.step3.title"
57
+ }
58
+ ]
59
+ }
60
+ } : void 0,
61
+ createConnector: shouldUseWalletConnect ? getWalletConnectConnector({
62
+ projectId,
63
+ walletConnectParameters
64
+ }) : getInjectedConnector({ flag: "isRainbow" })
65
+ };
66
+ };
67
+
68
+ export {
69
+ rainbowWallet
70
+ };
@@ -0,0 +1,98 @@
1
+ "use client";
2
+ import {
3
+ getInjectedConnector,
4
+ hasInjectedProvider
5
+ } from "./chunk-ARYAYQ7Z.js";
6
+ import {
7
+ getWalletConnectConnector
8
+ } from "./chunk-23WIEY36.js";
9
+
10
+ // src/wallets/walletConnectors/bybitWallet/bybitWallet.ts
11
+ var bybitWallet = ({
12
+ projectId,
13
+ walletConnectParameters
14
+ }) => {
15
+ const isBybitInjected = hasInjectedProvider({
16
+ namespace: "bybitWallet"
17
+ });
18
+ const shouldUseWalletConnect = !isBybitInjected;
19
+ const getUri = (uri) => {
20
+ return `bybitapp://open/route?targetUrl=by://web3/walletconnect/wc?uri=${encodeURIComponent(
21
+ uri
22
+ )}`;
23
+ };
24
+ return {
25
+ id: "bybit",
26
+ name: "Bybit Wallet",
27
+ rdns: "com.bybit",
28
+ iconUrl: async () => (await import("./bybitWallet-GOPAS32Q.js")).default,
29
+ installed: !shouldUseWalletConnect ? isBybitInjected : void 0,
30
+ iconBackground: "#000000",
31
+ downloadUrls: {
32
+ chrome: "https://chromewebstore.google.com/detail/bybit-wallet/pdliaogehgdbhbnmkklieghmmjkpigpa",
33
+ browserExtension: "https://www.bybit.com/en/web3",
34
+ android: "https://play.google.com/store/apps/details?id=com.bybit.app",
35
+ ios: "https://apps.apple.com/us/app/bybit-buy-trade-crypto/id1488296980",
36
+ mobile: "https://www.bybit.com/en/web3",
37
+ qrCode: "https://www.bybit.com/en/web3"
38
+ },
39
+ mobile: {
40
+ getUri: shouldUseWalletConnect ? getUri : void 0
41
+ },
42
+ qrCode: shouldUseWalletConnect ? {
43
+ getUri: (uri) => uri,
44
+ instructions: {
45
+ learnMoreUrl: "https://www.bybit.com/en/web3",
46
+ steps: [
47
+ {
48
+ description: "wallet_connectors.bybit.qr_code.step1.description",
49
+ step: "install",
50
+ title: "wallet_connectors.bybit.qr_code.step1.title"
51
+ },
52
+ {
53
+ description: "wallet_connectors.bybit.qr_code.step2.description",
54
+ step: "create",
55
+ title: "wallet_connectors.bybit.qr_code.step2.title"
56
+ },
57
+ {
58
+ description: "wallet_connectors.bybit.qr_code.step3.description",
59
+ step: "scan",
60
+ title: "wallet_connectors.bybit.qr_code.step3.title"
61
+ }
62
+ ]
63
+ }
64
+ } : void 0,
65
+ extension: {
66
+ instructions: {
67
+ learnMoreUrl: "https://www.bybit.com/en/web3",
68
+ steps: [
69
+ {
70
+ description: "wallet_connectors.bybit.extension.step1.description",
71
+ step: "install",
72
+ title: "wallet_connectors.bybit.extension.step1.title"
73
+ },
74
+ {
75
+ description: "wallet_connectors.bybit.extension.step2.description",
76
+ step: "create",
77
+ title: "wallet_connectors.bybit.extension.step2.title"
78
+ },
79
+ {
80
+ description: "wallet_connectors.bybit.extension.step3.description",
81
+ step: "refresh",
82
+ title: "wallet_connectors.bybit.extension.step3.title"
83
+ }
84
+ ]
85
+ }
86
+ },
87
+ createConnector: shouldUseWalletConnect ? getWalletConnectConnector({
88
+ projectId,
89
+ walletConnectParameters
90
+ }) : getInjectedConnector({
91
+ namespace: "bybitWallet"
92
+ })
93
+ };
94
+ };
95
+
96
+ export {
97
+ bybitWallet
98
+ };
@@ -0,0 +1,218 @@
1
+ "use client";
2
+ import {
3
+ getInjectedConnector,
4
+ hasInjectedProvider
5
+ } from "./chunk-ARYAYQ7Z.js";
6
+ import {
7
+ getWalletConnectConnector
8
+ } from "./chunk-23WIEY36.js";
9
+
10
+ // src/wallets/walletConnectors/metaMaskWallet/metaMaskWallet.ts
11
+ import { isAndroid, isIOS } from "@funkit/utils";
12
+ function isMetaMask(ethereum) {
13
+ if (!ethereum?.isMetaMask) {
14
+ return false;
15
+ }
16
+ if (ethereum.isBraveWallet && !ethereum._events && !ethereum._state) {
17
+ return false;
18
+ }
19
+ if (ethereum.isApexWallet) {
20
+ return false;
21
+ }
22
+ if (ethereum.isAvalanche) {
23
+ return false;
24
+ }
25
+ if (ethereum.isBackpack) {
26
+ return false;
27
+ }
28
+ if (ethereum.isBifrost) {
29
+ return false;
30
+ }
31
+ if (ethereum.isBitKeep) {
32
+ return false;
33
+ }
34
+ if (ethereum.isBitski) {
35
+ return false;
36
+ }
37
+ if (ethereum.isBlockWallet) {
38
+ return false;
39
+ }
40
+ if (ethereum.isCoinbaseWallet) {
41
+ return false;
42
+ }
43
+ if (ethereum.isDawn) {
44
+ return false;
45
+ }
46
+ if (ethereum.isEnkrypt) {
47
+ return false;
48
+ }
49
+ if (ethereum.isExodus) {
50
+ return false;
51
+ }
52
+ if (ethereum.isFrame) {
53
+ return false;
54
+ }
55
+ if (ethereum.isFrontier) {
56
+ return false;
57
+ }
58
+ if (ethereum.isGamestop) {
59
+ return false;
60
+ }
61
+ if (ethereum.isHyperPay) {
62
+ return false;
63
+ }
64
+ if (ethereum.isImToken) {
65
+ return false;
66
+ }
67
+ if (ethereum.isKuCoinWallet) {
68
+ return false;
69
+ }
70
+ if (ethereum.isMathWallet) {
71
+ return false;
72
+ }
73
+ if (ethereum.isNestWallet) {
74
+ return false;
75
+ }
76
+ if (ethereum.isOkxWallet || ethereum.isOKExWallet) {
77
+ return false;
78
+ }
79
+ if (ethereum.isOneInchIOSWallet || ethereum.isOneInchAndroidWallet) {
80
+ return false;
81
+ }
82
+ if (ethereum.isOpera) {
83
+ return false;
84
+ }
85
+ if (ethereum.isPhantom) {
86
+ return false;
87
+ }
88
+ if (ethereum.isPortal) {
89
+ return false;
90
+ }
91
+ if (ethereum.isRabby) {
92
+ return false;
93
+ }
94
+ if (ethereum.isRainbow) {
95
+ return false;
96
+ }
97
+ if (ethereum.isStatus) {
98
+ return false;
99
+ }
100
+ if (ethereum.isTalisman) {
101
+ return false;
102
+ }
103
+ if (ethereum.isTally) {
104
+ return false;
105
+ }
106
+ if (ethereum.isTokenPocket) {
107
+ return false;
108
+ }
109
+ if (ethereum.isTokenary) {
110
+ return false;
111
+ }
112
+ if (ethereum.isTrust || ethereum.isTrustWallet) {
113
+ return false;
114
+ }
115
+ if (ethereum.isXDEFI) {
116
+ return false;
117
+ }
118
+ if (ethereum.isZeal) {
119
+ return false;
120
+ }
121
+ if (ethereum.isZerion) {
122
+ return false;
123
+ }
124
+ return true;
125
+ }
126
+ var metaMaskWallet = ({
127
+ projectId,
128
+ walletConnectParameters
129
+ }) => {
130
+ const isMetaMaskInjected = hasInjectedProvider({ flag: "isMetaMask" });
131
+ const shouldUseWalletConnect = !isMetaMaskInjected;
132
+ const getUri = (uri) => {
133
+ return isAndroid() ? uri : isIOS() ? (
134
+ // currently broken in MetaMask v6.5.0 https://github.com/MetaMask/metamask-mobile/issues/6457
135
+ `metamask://wc?uri=${encodeURIComponent(uri)}`
136
+ ) : `https://metamask.app.link/wc?uri=${encodeURIComponent(uri)}`;
137
+ };
138
+ return {
139
+ id: "metaMask",
140
+ name: "MetaMask",
141
+ rdns: "io.metamask",
142
+ iconUrl: async () => (await import("./metaMaskWallet-RMHEKBDR.js")).default,
143
+ iconAccent: "#f6851a",
144
+ iconBackground: "#fff",
145
+ installed: !shouldUseWalletConnect ? isMetaMaskInjected : void 0,
146
+ downloadUrls: {
147
+ android: "https://play.google.com/store/apps/details?id=io.metamask",
148
+ ios: "https://apps.apple.com/us/app/metamask/id1438144202",
149
+ mobile: "https://metamask.io/download",
150
+ qrCode: "https://metamask.io/download",
151
+ chrome: "https://chrome.google.com/webstore/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn",
152
+ edge: "https://microsoftedge.microsoft.com/addons/detail/metamask/ejbalbakoplchlghecdalmeeeajnimhm",
153
+ firefox: "https://addons.mozilla.org/firefox/addon/ether-metamask",
154
+ opera: "https://addons.opera.com/extensions/details/metamask-10",
155
+ browserExtension: "https://metamask.io/download"
156
+ },
157
+ mobile: {
158
+ getUri: shouldUseWalletConnect ? getUri : void 0
159
+ },
160
+ qrCode: shouldUseWalletConnect ? {
161
+ getUri,
162
+ instructions: {
163
+ learnMoreUrl: "https://metamask.io/faqs/",
164
+ steps: [
165
+ {
166
+ description: "wallet_connectors.metamask.qr_code.step1.description",
167
+ step: "install",
168
+ title: "wallet_connectors.metamask.qr_code.step1.title"
169
+ },
170
+ {
171
+ description: "wallet_connectors.metamask.qr_code.step2.description",
172
+ step: "create",
173
+ title: "wallet_connectors.metamask.qr_code.step2.title"
174
+ },
175
+ {
176
+ description: "wallet_connectors.metamask.qr_code.step3.description",
177
+ step: "refresh",
178
+ title: "wallet_connectors.metamask.qr_code.step3.title"
179
+ }
180
+ ]
181
+ }
182
+ } : void 0,
183
+ extension: {
184
+ instructions: {
185
+ learnMoreUrl: "https://metamask.io/faqs/",
186
+ steps: [
187
+ {
188
+ description: "wallet_connectors.metamask.extension.step1.description",
189
+ step: "install",
190
+ title: "wallet_connectors.metamask.extension.step1.title"
191
+ },
192
+ {
193
+ description: "wallet_connectors.metamask.extension.step2.description",
194
+ step: "create",
195
+ title: "wallet_connectors.metamask.extension.step2.title"
196
+ },
197
+ {
198
+ description: "wallet_connectors.metamask.extension.step3.description",
199
+ step: "refresh",
200
+ title: "wallet_connectors.metamask.extension.step3.title"
201
+ }
202
+ ]
203
+ }
204
+ },
205
+ createConnector: shouldUseWalletConnect ? getWalletConnectConnector({
206
+ projectId,
207
+ walletConnectParameters
208
+ }) : getInjectedConnector({
209
+ target: typeof window !== "undefined" ? window.ethereum?.providers?.find(
210
+ isMetaMask
211
+ ) ?? window.ethereum : void 0
212
+ })
213
+ };
214
+ };
215
+
216
+ export {
217
+ metaMaskWallet
218
+ };
@@ -0,0 +1,69 @@
1
+ "use client";
2
+ import {
3
+ getInjectedConnector,
4
+ hasInjectedProvider
5
+ } from "./chunk-ARYAYQ7Z.js";
6
+ import {
7
+ getWalletConnectConnector
8
+ } from "./chunk-23WIEY36.js";
9
+
10
+ // src/wallets/walletConnectors/bifrostWallet/bifrostWallet.ts
11
+ import { isAndroid } from "@funkit/utils";
12
+ var bifrostWallet = ({
13
+ projectId,
14
+ walletConnectParameters
15
+ }) => {
16
+ const isBifrostInjected = hasInjectedProvider({ flag: "isBifrost" });
17
+ const shouldUseWalletConnect = !isBifrostInjected;
18
+ const getUri = (uri) => {
19
+ return isAndroid() ? uri : `https://app.bifrostwallet.com/wc?uri=${encodeURIComponent(uri)}`;
20
+ };
21
+ return {
22
+ id: "bifrostWallet",
23
+ name: "Bifrost Wallet",
24
+ iconUrl: async () => (await import("./bifrostWallet-5NQVDZ5P.js")).default,
25
+ iconBackground: "#fff",
26
+ installed: !shouldUseWalletConnect ? isBifrostInjected : void 0,
27
+ downloadUrls: {
28
+ android: "https://play.google.com/store/apps/details?id=com.bifrostwallet.app",
29
+ ios: "https://apps.apple.com/us/app/bifrost-wallet/id1577198351",
30
+ qrCode: "https://bifrostwallet.com/#download-app"
31
+ },
32
+ mobile: {
33
+ getUri: shouldUseWalletConnect ? getUri : void 0
34
+ },
35
+ qrCode: shouldUseWalletConnect ? {
36
+ getUri: (uri) => uri,
37
+ instructions: {
38
+ learnMoreUrl: "https://support.bifrostwallet.com/en/articles/6886814-how-to-use-walletconnect",
39
+ steps: [
40
+ {
41
+ description: "wallet_connectors.bifrost.qr_code.step1.description",
42
+ step: "install",
43
+ title: "wallet_connectors.bifrost.qr_code.step1.title"
44
+ },
45
+ {
46
+ description: "wallet_connectors.bifrost.qr_code.step2.description",
47
+ step: "create",
48
+ title: "wallet_connectors.bifrost.qr_code.step2.title"
49
+ },
50
+ {
51
+ description: "wallet_connectors.bifrost.qr_code.step3.description",
52
+ step: "scan",
53
+ title: "wallet_connectors.bifrost.qr_code.step3.title"
54
+ }
55
+ ]
56
+ }
57
+ } : void 0,
58
+ createConnector: shouldUseWalletConnect ? getWalletConnectConnector({
59
+ projectId,
60
+ walletConnectParameters
61
+ }) : getInjectedConnector({
62
+ flag: "isBifrost"
63
+ })
64
+ };
65
+ };
66
+
67
+ export {
68
+ bifrostWallet
69
+ };
@@ -0,0 +1,92 @@
1
+ "use client";
2
+ import {
3
+ getInjectedConnector,
4
+ hasInjectedProvider
5
+ } from "./chunk-ARYAYQ7Z.js";
6
+ import {
7
+ getWalletConnectConnector
8
+ } from "./chunk-23WIEY36.js";
9
+
10
+ // src/wallets/walletConnectors/gateWallet/gateWallet.ts
11
+ import { isAndroid } from "@funkit/utils";
12
+ var gateWallet = ({
13
+ projectId,
14
+ walletConnectParameters
15
+ }) => {
16
+ const isGateInjected = hasInjectedProvider({ namespace: "gatewallet" });
17
+ const shouldUseWalletConnect = !isGateInjected;
18
+ return {
19
+ id: "gate",
20
+ name: "Gate Wallet",
21
+ rdns: "io.gate.wallet",
22
+ iconUrl: async () => (await import("./gateWallet-CJNGQQCV.js")).default,
23
+ iconAccent: "#fff",
24
+ iconBackground: "#fff",
25
+ downloadUrls: {
26
+ android: "https://play.google.com/store/apps/details?id=com.gateio.gateio",
27
+ ios: "https://apps.apple.com/us/app/gate-io-buy-bitcoin-crypto/id1294998195",
28
+ mobile: "https://www.gate.io/mobileapp",
29
+ qrCode: "https://www.gate.io/web3",
30
+ chrome: "https://chromewebstore.google.com/detail/gate-wallet/cpmkedoipcpimgecpmgpldfpohjplkpp",
31
+ browserExtension: "https://www.gate.io/web3"
32
+ },
33
+ mobile: {
34
+ getUri: shouldUseWalletConnect ? (uri) => {
35
+ return isAndroid() ? uri : `gtweb3wallet://wc?uri=${encodeURIComponent(uri)}`;
36
+ } : void 0
37
+ },
38
+ qrCode: shouldUseWalletConnect ? {
39
+ getUri: (uri) => uri,
40
+ instructions: {
41
+ learnMoreUrl: "https://www.gate.io/learn",
42
+ steps: [
43
+ {
44
+ description: "wallet_connectors.gate.qr_code.step1.description",
45
+ step: "install",
46
+ title: "wallet_connectors.gate.qr_code.step1.title"
47
+ },
48
+ {
49
+ description: "wallet_connectors.gate.qr_code.step2.description",
50
+ step: "create",
51
+ title: "wallet_connectors.gate.qr_code.step2.title"
52
+ },
53
+ {
54
+ description: "wallet_connectors.gate.qr_code.step3.description",
55
+ step: "scan",
56
+ title: "wallet_connectors.gate.qr_code.step3.title"
57
+ }
58
+ ]
59
+ }
60
+ } : void 0,
61
+ extension: {
62
+ instructions: {
63
+ learnMoreUrl: "https://www.gate.io/learn",
64
+ steps: [
65
+ {
66
+ description: "wallet_connectors.gate.extension.step1.description",
67
+ step: "install",
68
+ title: "wallet_connectors.gate.extension.step1.title"
69
+ },
70
+ {
71
+ description: "wallet_connectors.gate.extension.step2.description",
72
+ step: "create",
73
+ title: "wallet_connectors.gate.extension.step2.title"
74
+ },
75
+ {
76
+ description: "wallet_connectors.gate.extension.step3.description",
77
+ step: "refresh",
78
+ title: "wallet_connectors.gate.extension.step3.title"
79
+ }
80
+ ]
81
+ }
82
+ },
83
+ createConnector: shouldUseWalletConnect ? getWalletConnectConnector({
84
+ projectId,
85
+ walletConnectParameters
86
+ }) : getInjectedConnector({ namespace: "gatewallet" })
87
+ };
88
+ };
89
+
90
+ export {
91
+ gateWallet
92
+ };
@@ -0,0 +1,94 @@
1
+ "use client";
2
+ import {
3
+ getInjectedConnector,
4
+ hasInjectedProvider
5
+ } from "./chunk-ARYAYQ7Z.js";
6
+ import {
7
+ getWalletConnectConnector
8
+ } from "./chunk-23WIEY36.js";
9
+
10
+ // src/wallets/walletConnectors/okxWallet/okxWallet.ts
11
+ import { isAndroid } from "@funkit/utils";
12
+ var okxWallet = ({
13
+ projectId,
14
+ walletConnectParameters
15
+ }) => {
16
+ const isOKXInjected = hasInjectedProvider({ namespace: "okxwallet" });
17
+ const shouldUseWalletConnect = !isOKXInjected;
18
+ return {
19
+ id: "okx",
20
+ name: "OKX Wallet",
21
+ rdns: "com.okex.wallet",
22
+ iconUrl: async () => (await import("./okxWallet-GJMKZIND.js")).default,
23
+ iconAccent: "#000",
24
+ iconBackground: "#000",
25
+ downloadUrls: {
26
+ android: "https://play.google.com/store/apps/details?id=com.okinc.okex.gp",
27
+ ios: "https://itunes.apple.com/app/id1327268470?mt=8",
28
+ mobile: "https://okx.com/download",
29
+ qrCode: "https://okx.com/download",
30
+ chrome: "https://chrome.google.com/webstore/detail/okx-wallet/mcohilncbfahbmgdjkbpemcciiolgcge",
31
+ edge: "https://microsoftedge.microsoft.com/addons/detail/okx-wallet/pbpjkcldjiffchgbbndmhojiacbgflha",
32
+ firefox: "https://addons.mozilla.org/firefox/addon/okexwallet/",
33
+ browserExtension: "https://okx.com/download"
34
+ },
35
+ mobile: {
36
+ getUri: shouldUseWalletConnect ? (uri) => {
37
+ return isAndroid() ? uri : `okex://main/wc?uri=${encodeURIComponent(uri)}`;
38
+ } : void 0
39
+ },
40
+ qrCode: shouldUseWalletConnect ? {
41
+ getUri: (uri) => uri,
42
+ instructions: {
43
+ learnMoreUrl: "https://okx.com/web3/",
44
+ steps: [
45
+ {
46
+ description: "wallet_connectors.okx.qr_code.step1.description",
47
+ step: "install",
48
+ title: "wallet_connectors.okx.qr_code.step1.title"
49
+ },
50
+ {
51
+ description: "wallet_connectors.okx.qr_code.step2.description",
52
+ step: "create",
53
+ title: "wallet_connectors.okx.qr_code.step2.title"
54
+ },
55
+ {
56
+ description: "wallet_connectors.okx.qr_code.step3.description",
57
+ step: "scan",
58
+ title: "wallet_connectors.okx.qr_code.step3.title"
59
+ }
60
+ ]
61
+ }
62
+ } : void 0,
63
+ extension: {
64
+ instructions: {
65
+ learnMoreUrl: "https://okx.com/web3/",
66
+ steps: [
67
+ {
68
+ description: "wallet_connectors.okx.extension.step1.description",
69
+ step: "install",
70
+ title: "wallet_connectors.okx.extension.step1.title"
71
+ },
72
+ {
73
+ description: "wallet_connectors.okx.extension.step2.description",
74
+ step: "create",
75
+ title: "wallet_connectors.okx.extension.step2.title"
76
+ },
77
+ {
78
+ description: "wallet_connectors.okx.extension.step3.description",
79
+ step: "refresh",
80
+ title: "wallet_connectors.okx.extension.step3.title"
81
+ }
82
+ ]
83
+ }
84
+ },
85
+ createConnector: shouldUseWalletConnect ? getWalletConnectConnector({
86
+ projectId,
87
+ walletConnectParameters
88
+ }) : getInjectedConnector({ namespace: "okxwallet" })
89
+ };
90
+ };
91
+
92
+ export {
93
+ okxWallet
94
+ };