@web3jskit/walletkit 0.5.2 → 0.6.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.
- package/README.md +1 -4
- package/README.zh.md +1 -4
- package/dist/assets/fonts/manrope-latin-ext.woff2 +0 -0
- package/dist/assets/fonts/manrope-latin.woff2 +0 -0
- package/dist/assets/fonts/manrope-vietnamese.woff2 +0 -0
- package/dist/base.css +65 -0
- package/dist/btcConnector-BDtO-SY1.js +1 -0
- package/dist/{btcConnector-D9c29Oxw.mjs → btcConnector-CcZ3Vta3.mjs} +4 -3
- package/dist/{btcConnector-CDgcyxQ3.mjs → btcConnector-DMgc1GYB.mjs} +16 -15
- package/dist/btcConnector-DfFAwTZX.js +1 -0
- package/dist/components/ConnectModal/index.d.ts.map +1 -1
- package/dist/components/Modal/index.d.ts +3 -1
- package/dist/components/Modal/index.d.ts.map +1 -1
- package/dist/components/WalletItem/index.d.ts +3 -0
- package/dist/components/WalletItem/index.d.ts.map +1 -1
- package/dist/components/WalletKitProvider/ChainProvider.d.ts +1 -2
- package/dist/components/WalletKitProvider/ChainProvider.d.ts.map +1 -1
- package/dist/components/WalletKitProvider/connectorInitialization.d.ts +12 -0
- package/dist/components/WalletKitProvider/connectorInitialization.d.ts.map +1 -0
- package/dist/components/WalletKitProvider/index.d.ts +1 -1
- package/dist/components/WalletKitProvider/index.d.ts.map +1 -1
- package/dist/config/iconDatabase.d.ts +0 -1
- package/dist/config/iconDatabase.d.ts.map +1 -1
- package/dist/config/walletConfig.d.ts +0 -1
- package/dist/config/walletConfig.d.ts.map +1 -1
- package/dist/core/connectors/Bitget_Wallet/tronConnector.d.ts +13 -0
- package/dist/core/connectors/Bitget_Wallet/tronConnector.d.ts.map +1 -0
- package/dist/core/connectors/_sol/discoverWallets.d.ts +4 -0
- package/dist/core/connectors/_sol/discoverWallets.d.ts.map +1 -0
- package/dist/core/connectors/_sol/discoveredSolConnector.d.ts +12 -0
- package/dist/core/connectors/_sol/discoveredSolConnector.d.ts.map +1 -0
- package/dist/core/connectors/_sol/wrapStandardSolWallet.d.ts +15 -0
- package/dist/core/connectors/_sol/wrapStandardSolWallet.d.ts.map +1 -0
- package/dist/core/connectors/_tron/discoverWallets.d.ts +6 -0
- package/dist/core/connectors/_tron/discoverWallets.d.ts.map +1 -0
- package/dist/core/connectors/_tron/discoveredTronConnector.d.ts +13 -0
- package/dist/core/connectors/_tron/discoveredTronConnector.d.ts.map +1 -0
- package/dist/core/connectors/_tron/tronConnector.d.ts.map +1 -1
- package/dist/core/connectors/_tron/wrapTip6963TronProvider.d.ts +2 -0
- package/dist/core/connectors/_tron/wrapTip6963TronProvider.d.ts.map +1 -0
- package/dist/core/connectors/connectorLoader.d.ts +3 -0
- package/dist/core/connectors/connectorLoader.d.ts.map +1 -0
- package/dist/core/connectors/createConnectors.d.ts +5 -1
- package/dist/core/connectors/createConnectors.d.ts.map +1 -1
- package/dist/core/connectors/publicConnectorApi.d.ts +7 -0
- package/dist/core/connectors/publicConnectorApi.d.ts.map +1 -0
- package/dist/core/utils/sortConnectModalWallets.d.ts +14 -0
- package/dist/core/utils/sortConnectModalWallets.d.ts.map +1 -0
- package/dist/core/utils/util.d.ts +7 -0
- package/dist/core/utils/util.d.ts.map +1 -1
- package/dist/core/utils/walletName.d.ts +5 -0
- package/dist/core/utils/walletName.d.ts.map +1 -0
- package/dist/createConnectors-C9LH3IR3.mjs +1400 -0
- package/dist/createConnectors-CJ8mKxGL.js +4 -0
- package/dist/createConnectors-Cv_QLnqK.js +71 -0
- package/dist/createConnectors-motkSfb8.mjs +700 -0
- package/dist/{deepLinkConnector-BV1AtJUd.mjs → deepLinkConnector-BXnwTb3R.mjs} +1 -1
- package/dist/{deepLinkConnector-D2bdmDbP.mjs → deepLinkConnector-BYTD1fC1.mjs} +1 -1
- package/dist/deepLinkConnector-BdJyNgRZ.js +1 -0
- package/dist/{deepLinkConnector-De3WEuvS.mjs → deepLinkConnector-Bu6KKcGy.mjs} +1 -1
- package/dist/deepLinkConnector-Bw-eQd5I.js +1 -0
- package/dist/{deepLinkConnector-Cl2lfNcv.mjs → deepLinkConnector-C2hzBr3K.mjs} +1 -1
- package/dist/deepLinkConnector-CAwqVe4F.js +1 -0
- package/dist/deepLinkConnector-CuHi9EXY.js +1 -0
- package/dist/deepLinkConnector-Cvnq6T2g.js +1 -0
- package/dist/deepLinkConnector-DIFgHqiu.js +1 -0
- package/dist/deepLinkConnector-DNwi0QPz.js +1 -0
- package/dist/{deepLinkConnector-Cp3wn9oq.mjs → deepLinkConnector-DZhNx2B3.mjs} +1 -1
- package/dist/{deepLinkConnector-ClxWpKnx.mjs → deepLinkConnector-DjjZRYdu.mjs} +1 -1
- package/dist/{deepLinkConnector-Cy9w-E2m.mjs → deepLinkConnector-DkxVqLoI.mjs} +6 -5
- package/dist/hooks/useWalletKit.d.ts +0 -2
- package/dist/hooks/useWalletKit.d.ts.map +1 -1
- package/dist/index-AJZEVNvC.js +44 -0
- package/dist/index-B2ReClHJ.js +1 -0
- package/dist/index-CwrzsL2T.mjs +6179 -0
- package/dist/index-D5CDP-Ja.mjs +79 -0
- package/dist/index-DBdIuPfj.js +3 -0
- package/dist/index-DcNXEbdu.mjs +94 -0
- package/dist/index-Dh0IhC3B.mjs +168 -0
- package/dist/index-Dqp1KqTh.js +1 -0
- package/dist/index-Ds_3MsPA.js +1 -0
- package/dist/index-bCuJkrSE.mjs +152 -0
- package/dist/index.css +1 -0
- package/dist/index.d.ts +1 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.esm.js +19 -20
- package/dist/index.js +1 -1
- package/dist/index.umd.js +12765 -55583
- package/dist/index2.css +1 -0
- package/dist/index3.css +1 -0
- package/dist/silentConnect-CZY4_0a5.js +1 -0
- package/dist/silentConnect-ScWCxMaM.mjs +11 -0
- package/dist/stores/helperStore.d.ts +0 -2
- package/dist/stores/helperStore.d.ts.map +1 -1
- package/dist/style.css +90 -87
- package/dist/tronConnector-Bx-nhNWr.mjs +14 -0
- package/dist/tronConnector-CXH3d_my.js +1 -0
- package/dist/tronConnector-DGnNuwqC.js +1 -0
- package/dist/tronConnector-P87k0GEa.mjs +21 -0
- package/dist/walletName-BwayBopz.mjs +8 -0
- package/dist/walletName-mwS8Jhxj.js +1 -0
- package/package.json +11 -4
- package/dist/btcConnector-Ca_Ne7hH.js +0 -1
- package/dist/btcConnector-PnjTRzcQ.js +0 -1
- package/dist/core/connectors/Bitget_Wallet/solConnector.d.ts +0 -13
- package/dist/core/connectors/Bitget_Wallet/solConnector.d.ts.map +0 -1
- package/dist/core/connectors/GelWallet/evmConnector.d.ts +0 -27
- package/dist/core/connectors/GelWallet/evmConnector.d.ts.map +0 -1
- package/dist/core/connectors/GelWallet/solConnector.d.ts +0 -15
- package/dist/core/connectors/GelWallet/solConnector.d.ts.map +0 -1
- package/dist/core/connectors/GelWallet/tronConnector.d.ts +0 -8
- package/dist/core/connectors/GelWallet/tronConnector.d.ts.map +0 -1
- package/dist/core/connectors/OKX_Wallet/solConnector.d.ts +0 -12
- package/dist/core/connectors/OKX_Wallet/solConnector.d.ts.map +0 -1
- package/dist/core/connectors/Phantom/solConnector.d.ts +0 -12
- package/dist/core/connectors/Phantom/solConnector.d.ts.map +0 -1
- package/dist/core/connectors/TronLink/tronConnector.d.ts +0 -13
- package/dist/core/connectors/TronLink/tronConnector.d.ts.map +0 -1
- package/dist/core/connectors/_gelwallet/gelWalletConnector.d.ts +0 -26
- package/dist/core/connectors/_gelwallet/gelWalletConnector.d.ts.map +0 -1
- package/dist/dapp.es-BPGP9PnL.mjs +0 -15917
- package/dist/dapp.es-sLnregcu.js +0 -103
- package/dist/deepLinkConnector-2xq1YA07.js +0 -1
- package/dist/deepLinkConnector-B_fjG32i.js +0 -1
- package/dist/deepLinkConnector-BjV3gwrJ.js +0 -1
- package/dist/deepLinkConnector-BrFUCtcT.js +0 -1
- package/dist/deepLinkConnector-COLT9UtB.js +0 -1
- package/dist/deepLinkConnector-DvpJaC8p.js +0 -1
- package/dist/deepLinkConnector-Dypz-oTG.js +0 -1
- package/dist/evmConnector-CDZHCMDp.mjs +0 -163
- package/dist/evmConnector-CsLHlVqx.js +0 -1
- package/dist/gelWalletConnector-D-BogX91.mjs +0 -76
- package/dist/gelWalletConnector-DmGJoazT.js +0 -1
- package/dist/index-9qmfDVzH-C-zsxX98.mjs +0 -25638
- package/dist/index-9qmfDVzH-C6VVZD9P.js +0 -28
- package/dist/index-B3LF1VeP-58KzZv6u.js +0 -1
- package/dist/index-B3LF1VeP-IR-fSZI0.mjs +0 -120
- package/dist/index-BZdLbTeL.js +0 -138
- package/dist/index-CCHY2zSF-OxZZmzOg.mjs +0 -45
- package/dist/index-CCHY2zSF-ocS_tvXl.js +0 -1
- package/dist/index-CqeMS3Gf-C4g86ca5.js +0 -1
- package/dist/index-CqeMS3Gf-DXS8RsUh.mjs +0 -67
- package/dist/index-DGMGsMkJ-BTPPfxmS.js +0 -1
- package/dist/index-DGMGsMkJ-CHecRdpD.mjs +0 -27
- package/dist/index-Dm84KVCU.mjs +0 -9267
- package/dist/index-yUF_S07V-Cm9-qVkc.js +0 -1
- package/dist/index-yUF_S07V-DHeRsyE0.mjs +0 -48
- package/dist/solConnector-2sU1qHsq.mjs +0 -11
- package/dist/solConnector-BEPYycHF.js +0 -1
- package/dist/solConnector-CVS5qwwy.js +0 -1
- package/dist/solConnector-CWIPltdg.mjs +0 -11
- package/dist/solConnector-CXejjI9x.mjs +0 -41
- package/dist/solConnector-CnQAb35I.mjs +0 -11
- package/dist/solConnector-DU5bMwKt.js +0 -1
- package/dist/solConnector-xJ3YPYMj.js +0 -1
- package/dist/tronConnector-CUnp7Df4.js +0 -1
- package/dist/tronConnector-CaEipTWV.mjs +0 -21
- package/dist/tronConnector-CpIX5IxL.mjs +0 -13
- package/dist/tronConnector-DMLqqMae.mjs +0 -35
- package/dist/tronConnector-DesDymhW.js +0 -1
- package/dist/tronConnector-tU0iwxHV.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./dapp.es-sLnregcu.js");var c=Object.defineProperty,u=(t,e,s)=>e in t?c(t,e,{enumerable:!0,configurable:!0,writable:!0,value:s}):t[e]=s,n=(t,e,s)=>u(t,typeof e!="symbol"?e+"":e,s);class d{constructor(e){n(this,"web3Kit"),n(this,"connect",async()=>this.request({method:"endless_connect",params:{}})),n(this,"disconnect",async()=>this.request({method:"endless_disconnect",params:{}})),n(this,"signMessage",async s=>{const{message:a,display:i="utf8",session:r}=s;return this.request({method:"endless_signMessage",params:{message:a,display:i,session:r}})}),n(this,"signAndSubmitTransaction",async s=>{const{transaction:a,session:i}=s;return this.request({method:"endless_signAndSubmitTransaction",params:{transaction:a,session:i}})}),n(this,"signTransaction",async s=>{const{transaction:a}=s;return this.request({method:"endless_signTransaction",params:a})}),this.web3Kit=e}async request({method:e,params:s}){return this.web3Kit.request({chainType:o.ChainType.ENDLESS,methodName:e,params:s})}}exports.EndlessProvider=d;
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import { C as o } from "./dapp.es-BPGP9PnL.mjs";
|
|
2
|
-
var c = Object.defineProperty, m = (t, e, s) => e in t ? c(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s, n = (t, e, s) => m(t, typeof e != "symbol" ? e + "" : e, s);
|
|
3
|
-
class u {
|
|
4
|
-
constructor(e) {
|
|
5
|
-
n(this, "web3Kit"), n(this, "connect", async () => this.request({
|
|
6
|
-
method: "endless_connect",
|
|
7
|
-
params: {}
|
|
8
|
-
})), n(this, "disconnect", async () => this.request({
|
|
9
|
-
method: "endless_disconnect",
|
|
10
|
-
params: {}
|
|
11
|
-
})), n(this, "signMessage", async (s) => {
|
|
12
|
-
const { message: a, display: i = "utf8", session: r } = s;
|
|
13
|
-
return this.request({
|
|
14
|
-
method: "endless_signMessage",
|
|
15
|
-
params: {
|
|
16
|
-
message: a,
|
|
17
|
-
display: i,
|
|
18
|
-
session: r
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
}), n(this, "signAndSubmitTransaction", async (s) => {
|
|
22
|
-
const { transaction: a, session: i } = s;
|
|
23
|
-
return this.request({
|
|
24
|
-
method: "endless_signAndSubmitTransaction",
|
|
25
|
-
params: {
|
|
26
|
-
transaction: a,
|
|
27
|
-
session: i
|
|
28
|
-
}
|
|
29
|
-
});
|
|
30
|
-
}), n(this, "signTransaction", async (s) => {
|
|
31
|
-
const { transaction: a } = s;
|
|
32
|
-
return this.request({
|
|
33
|
-
method: "endless_signTransaction",
|
|
34
|
-
params: a
|
|
35
|
-
});
|
|
36
|
-
}), this.web3Kit = e;
|
|
37
|
-
}
|
|
38
|
-
async request({ method: e, params: s }) {
|
|
39
|
-
return this.web3Kit.request({
|
|
40
|
-
chainType: o.ENDLESS,
|
|
41
|
-
methodName: e,
|
|
42
|
-
params: s
|
|
43
|
-
});
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
export {
|
|
47
|
-
u as EndlessProvider
|
|
48
|
-
};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { S as a, C as e } from "./index-Dm84KVCU.mjs";
|
|
2
|
-
class p extends a {
|
|
3
|
-
constructor(n) {
|
|
4
|
-
var t;
|
|
5
|
-
const o = (t = window.bitkeep) == null ? void 0 : t.solana;
|
|
6
|
-
super(n, o), this.sendTransaction = async (r, s = {}) => await (await this.getProvider()).signSendTransaction(r, s), this.connectorType = o ? e.Installed : e.More;
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
export {
|
|
10
|
-
p as default
|
|
11
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-BZdLbTeL.js");class s extends e.SolConnector{constructor(o){var n;const t=(n=window.bitkeep)==null?void 0:n.solana;super(o,t),this.sendTransaction=async(r,i={})=>await(await this.getProvider()).signSendTransaction(r,i),this.connectorType=t?e.ConnectorType.Installed:e.ConnectorType.More}}exports.default=s;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-BZdLbTeL.js");class r extends e.SolConnector{constructor(n){var t;const o=(t=window.okxwallet)==null?void 0:t.solana;super(n,o),this.connectorType=o?e.ConnectorType.Installed:e.ConnectorType.More}}exports.default=r;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { S as r, C as t } from "./index-Dm84KVCU.mjs";
|
|
2
|
-
class a extends r {
|
|
3
|
-
constructor(n) {
|
|
4
|
-
var e;
|
|
5
|
-
const o = (e = window.okxwallet) == null ? void 0 : e.solana;
|
|
6
|
-
super(n, o), this.connectorType = o ? t.Installed : t.More;
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
export {
|
|
10
|
-
a as default
|
|
11
|
-
};
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { G as i } from "./gelWalletConnector-D-BogX91.mjs";
|
|
2
|
-
import { a as r, r as o } from "./index-Dm84KVCU.mjs";
|
|
3
|
-
class h extends i {
|
|
4
|
-
constructor(n) {
|
|
5
|
-
super(n, r.SOL), this.connect = async () => {
|
|
6
|
-
try {
|
|
7
|
-
const t = await this.getProvider();
|
|
8
|
-
this.addEventListener(), this.beforeConnecting();
|
|
9
|
-
const e = await t.connect(), s = o(e, t);
|
|
10
|
-
if (!s)
|
|
11
|
-
throw new Error("Failed to resolve Solana wallet address");
|
|
12
|
-
return this.connectSuccess(s), s;
|
|
13
|
-
} catch (t) {
|
|
14
|
-
throw this.removeEventListener(), this.connectError(), t;
|
|
15
|
-
}
|
|
16
|
-
}, this.reconnection = async () => {
|
|
17
|
-
await this.connect();
|
|
18
|
-
}, this.disconnect = async () => {
|
|
19
|
-
try {
|
|
20
|
-
await (await this.getProvider()).disconnect(), this.__onDisconnect();
|
|
21
|
-
} catch (t) {
|
|
22
|
-
console.error(t);
|
|
23
|
-
}
|
|
24
|
-
}, this.switchNetwork = async (t) => {
|
|
25
|
-
const e = {
|
|
26
|
-
chainType: r.SOL,
|
|
27
|
-
methodName: "switchNet",
|
|
28
|
-
params: {
|
|
29
|
-
chainId: t
|
|
30
|
-
}
|
|
31
|
-
};
|
|
32
|
-
window.Web3Kit._instance.request(e);
|
|
33
|
-
}, this.signMessage = async (t) => {
|
|
34
|
-
const e = await this.getProvider(), s = new TextEncoder().encode(t);
|
|
35
|
-
return await e.signMessage(s, "utf8");
|
|
36
|
-
}, this.signTransaction = async (t) => await (await this.getProvider()).signTransaction(t), this.signAllTransactions = async (t) => await (await this.getProvider()).signAllTransactions(t), this.sendTransaction = async (t, e = {}) => await (await this.getProvider()).signAndSendTransaction(t, e);
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
export {
|
|
40
|
-
h as default
|
|
41
|
-
};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { S as r, C as n } from "./index-Dm84KVCU.mjs";
|
|
2
|
-
class c extends r {
|
|
3
|
-
constructor(t) {
|
|
4
|
-
var e;
|
|
5
|
-
const o = (e = window.phantom) == null ? void 0 : e.solana;
|
|
6
|
-
super(t, o), this.connectorType = o && !o.isBitKeep ? n.Installed : n.More;
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
export {
|
|
10
|
-
c as default
|
|
11
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./gelWalletConnector-DmGJoazT.js"),r=require("./index-BZdLbTeL.js");class o extends i.GelWalletConnector{constructor(s){super(s,r.ChainType.SOL),this.connect=async()=>{try{const e=await this.getProvider();this.addEventListener(),this.beforeConnecting();const t=await e.connect(),n=r.resolveSolAddress(t,e);if(!n)throw new Error("Failed to resolve Solana wallet address");return this.connectSuccess(n),n}catch(e){throw this.removeEventListener(),this.connectError(),e}},this.reconnection=async()=>{await this.connect()},this.disconnect=async()=>{try{await(await this.getProvider()).disconnect(),this.__onDisconnect()}catch(e){console.error(e)}},this.switchNetwork=async e=>{const t={chainType:r.ChainType.SOL,methodName:"switchNet",params:{chainId:e}};window.Web3Kit._instance.request(t)},this.signMessage=async e=>{const t=await this.getProvider(),n=new TextEncoder().encode(e);return await t.signMessage(n,"utf8")},this.signTransaction=async e=>await(await this.getProvider()).signTransaction(e),this.signAllTransactions=async e=>await(await this.getProvider()).signAllTransactions(e),this.sendTransaction=async(e,t={})=>await(await this.getProvider()).signAndSendTransaction(e,t)}}exports.default=o;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index-BZdLbTeL.js");class r extends o.SolConnector{constructor(t){var n;const e=(n=window.phantom)==null?void 0:n.solana;super(t,e),this.connectorType=e&&!e.isBitKeep?o.ConnectorType.Installed:o.ConnectorType.More}}exports.default=r;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index-BZdLbTeL.js");var r=(e=>(e.mainnet="0x2b6653dc",e.nile="0xcd8690dc",e.shasta="0x94a9059e",e))(r||{});class l extends n.TronConnector{constructor(c){var o,t;const i=(o=window.okxwallet)==null?void 0:o.tronLink;super(c,(t=window.okxwallet)==null?void 0:t.tronLink),this.connectorType=i?n.ConnectorType.Installed:n.ConnectorType.More}}exports.ChainIds=r;exports.default=l;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { T as i, C as o } from "./index-Dm84KVCU.mjs";
|
|
2
|
-
var a = /* @__PURE__ */ ((t) => (t.mainnet = "0x2b6653dc", t.nile = "0xcd8690dc", t.shasta = "0x94a9059e", t))(a || {});
|
|
3
|
-
class h extends i {
|
|
4
|
-
constructor(s) {
|
|
5
|
-
const n = window.tronLink ?? window.tronWeb;
|
|
6
|
-
super(s, n), this.connect = async () => {
|
|
7
|
-
try {
|
|
8
|
-
const e = await this.getProvider();
|
|
9
|
-
this.addEventListener(), this.beforeConnecting();
|
|
10
|
-
const r = await e.request({ method: "tron_requestAccounts" }), c = r[0];
|
|
11
|
-
return this.connectSuccess(r[0]), c;
|
|
12
|
-
} catch (e) {
|
|
13
|
-
throw this.removeEventListener(), this.connectError(), e;
|
|
14
|
-
}
|
|
15
|
-
}, this.connectorType = n && window.tronLink ? o.Installed : o.More;
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
export {
|
|
19
|
-
a as ChainIds,
|
|
20
|
-
h as default
|
|
21
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { T as a, C as e } from "./index-Dm84KVCU.mjs";
|
|
2
|
-
var s = /* @__PURE__ */ ((o) => (o.mainnet = "0x2b6653dc", o.nile = "0xcd8690dc", o.shasta = "0x94a9059e", o))(s || {});
|
|
3
|
-
class i extends a {
|
|
4
|
-
constructor(t) {
|
|
5
|
-
var n, r;
|
|
6
|
-
const c = (n = window.okxwallet) == null ? void 0 : n.tronLink;
|
|
7
|
-
super(t, (r = window.okxwallet) == null ? void 0 : r.tronLink), this.connectorType = c ? e.Installed : e.More;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
export {
|
|
11
|
-
s as ChainIds,
|
|
12
|
-
i as default
|
|
13
|
-
};
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { T as u, C as f } from "./index-Dm84KVCU.mjs";
|
|
2
|
-
class p extends u {
|
|
3
|
-
constructor(l) {
|
|
4
|
-
super(l), this.getProvider = async () => {
|
|
5
|
-
var o;
|
|
6
|
-
if (this.provider) return this.provider;
|
|
7
|
-
const t = await import("./dapp.es-BPGP9PnL.mjs").then((e) => e.b), n = (t == null ? void 0 : t.GelWallet) ?? (t == null ? void 0 : t.Web3Kit) ?? (t == null ? void 0 : t.default);
|
|
8
|
-
if (!n) throw new Error("GelWallet SDK not found in @web3jskit/dapp");
|
|
9
|
-
if (!((o = window.Web3Kit) != null && o._instance)) {
|
|
10
|
-
typeof n.config == "function" && n.config({
|
|
11
|
-
hideEvokingButton: !1,
|
|
12
|
-
takeover: {
|
|
13
|
-
ethereum: !0,
|
|
14
|
-
solana: !0,
|
|
15
|
-
tronLink: !0
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
|
-
const e = new n();
|
|
19
|
-
window.Web3Kit = window.Web3Kit || {}, window.Web3Kit._instance = e;
|
|
20
|
-
}
|
|
21
|
-
const w = await new Promise((e) => {
|
|
22
|
-
const i = () => {
|
|
23
|
-
var s, a, c;
|
|
24
|
-
const r = (c = (a = (s = window.Web3Kit) == null ? void 0 : s._instance) == null ? void 0 : a.provider) == null ? void 0 : c.tronLink;
|
|
25
|
-
r ? e(r) : setTimeout(i, 100);
|
|
26
|
-
};
|
|
27
|
-
i();
|
|
28
|
-
});
|
|
29
|
-
return this.provider = w, this.provider;
|
|
30
|
-
}, this.connectorType = f.Run;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
export {
|
|
34
|
-
p as default
|
|
35
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index-BZdLbTeL.js");var c=(e=>(e.mainnet="0x2b6653dc",e.nile="0xcd8690dc",e.shasta="0x94a9059e",e))(c||{});class d extends n.TronConnector{constructor(s){const r=window.tronLink??window.tronWeb;super(s,r),this.connect=async()=>{try{const t=await this.getProvider();this.addEventListener(),this.beforeConnecting();const o=await t.request({method:"tron_requestAccounts"}),i=o[0];return this.connectSuccess(o[0]),i}catch(t){throw this.removeEventListener(),this.connectError(),t}},this.connectorType=r&&window.tronLink?n.ConnectorType.Installed:n.ConnectorType.More}}exports.ChainIds=c;exports.default=d;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./index-BZdLbTeL.js");class w extends l.TronConnector{constructor(u){super(u),this.getProvider=async()=>{var i;if(this.provider)return this.provider;const e=await Promise.resolve().then(()=>require("./dapp.es-sLnregcu.js")).then(t=>t.dapp_es),n=(e==null?void 0:e.GelWallet)??(e==null?void 0:e.Web3Kit)??(e==null?void 0:e.default);if(!n)throw new Error("GelWallet SDK not found in @web3jskit/dapp");if(!((i=window.Web3Kit)!=null&&i._instance)){typeof n.config=="function"&&n.config({hideEvokingButton:!1,takeover:{ethereum:!0,solana:!0,tronLink:!0}});const t=new n;window.Web3Kit=window.Web3Kit||{},window.Web3Kit._instance=t}const d=await new Promise(t=>{const o=()=>{var s,c,a;const r=(a=(c=(s=window.Web3Kit)==null?void 0:s._instance)==null?void 0:c.provider)==null?void 0:a.tronLink;r?t(r):setTimeout(o,100)};o()});return this.provider=d,this.provider},this.connectorType=l.ConnectorType.Run}}exports.default=w;
|