@solana/connector 0.1.4 → 0.1.5
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 +236 -0
- package/dist/{chunk-U64YZRJL.mjs → chunk-3STZXVXD.mjs} +254 -53
- package/dist/chunk-3STZXVXD.mjs.map +1 -0
- package/dist/{chunk-RIQH5W7D.js → chunk-I64FD2EH.js} +4 -3
- package/dist/chunk-I64FD2EH.js.map +1 -0
- package/dist/{chunk-CLXM6UEE.js → chunk-JUZVCBAI.js} +91 -85
- package/dist/chunk-JUZVCBAI.js.map +1 -0
- package/dist/{chunk-D6PZY5G6.js → chunk-NQXK7PGX.js} +30 -26
- package/dist/chunk-NQXK7PGX.js.map +1 -0
- package/dist/{chunk-N3Q2J2FG.mjs → chunk-QKVL45F6.mjs} +10 -6
- package/dist/chunk-QKVL45F6.mjs.map +1 -0
- package/dist/{chunk-P5MWBDFG.mjs → chunk-QL3IT3TS.mjs} +4 -3
- package/dist/chunk-QL3IT3TS.mjs.map +1 -0
- package/dist/{chunk-LUZWUZ5N.js → chunk-ULUYX23Q.js} +268 -67
- package/dist/chunk-ULUYX23Q.js.map +1 -0
- package/dist/{chunk-YTCSTE3Q.mjs → chunk-VMSZJPR5.mjs} +10 -4
- package/dist/chunk-VMSZJPR5.mjs.map +1 -0
- package/dist/compat.js +3 -3
- package/dist/compat.mjs +1 -1
- package/dist/headless.d.mts +2 -2
- package/dist/headless.d.ts +2 -2
- package/dist/headless.js +120 -120
- package/dist/headless.mjs +3 -3
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +147 -147
- package/dist/index.mjs +4 -4
- package/dist/react.d.mts +4 -4
- package/dist/react.d.ts +4 -4
- package/dist/react.js +28 -28
- package/dist/react.mjs +2 -2
- package/dist/{wallet-standard-shim-DC_Z7DS-.d.ts → wallet-standard-shim--YcrQNRt.d.ts} +83 -0
- package/dist/{wallet-standard-shim-Cp4vF4oo.d.mts → wallet-standard-shim-Dx7H8Ctf.d.mts} +83 -0
- package/package.json +1 -1
- package/dist/chunk-CLXM6UEE.js.map +0 -1
- package/dist/chunk-D6PZY5G6.js.map +0 -1
- package/dist/chunk-LUZWUZ5N.js.map +0 -1
- package/dist/chunk-N3Q2J2FG.mjs.map +0 -1
- package/dist/chunk-P5MWBDFG.mjs.map +0 -1
- package/dist/chunk-RIQH5W7D.js.map +0 -1
- package/dist/chunk-U64YZRJL.mjs.map +0 -1
- package/dist/chunk-YTCSTE3Q.mjs.map +0 -1
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { EnhancedStorage, EnhancedStorageAdapter, SOLANA_CHAIN_IDS, address, base58ToSignatureBytes, chainIdToClusterId, chainIdToClusterType, clusterToChainId, copySignature, createConfig, createEnhancedStorageAccount, createEnhancedStorageCluster, createEnhancedStorageWallet, createKitSignersFromWallet, createMessageSignerFromWallet, createSignableMessage, createSolanaDevnet, createSolanaLocalnet, createSolanaMainnet, createSolanaTestnet, createTransactionSendingSignerFromWallet, detectMessageModification, formatSignature, freezeSigner, getAllExplorerUrls, getChainIdFromCluster, getChainIdFromClusterId, getChainIdFromClusterType, getChainIdFromConnection, getClusterIdFromChainId, getClusterTypeFromChainId, getClusterTypeFromConnection, getDefaultConfig, getDefaultMobileConfig, getLatestBlockhash, getSolanaExplorerUrl, getSolanaFmUrl, getSolscanUrl, getXrayUrl, isAccountAddress, isKitConnection, isKnownSolanaChain, isLegacyConnection, isSolanaChain, isUnifiedConfig, isWalletName, sendRawTransaction, signatureBytesToBase58, updateSignatureDictionary, validateKnownSolanaChain } from './chunk-
|
|
2
|
-
export { AccountElement, UnifiedProvider as AppProvider, BalanceElement, ClusterElement, ConnectorProvider, DisconnectElement, TokenListElement, TransactionHistoryElement, UnifiedProvider, WalletListElement, useAccount, useBalance, useCluster, useConnector, useConnectorClient, useGillSolanaClient, useGillTransactionSigner, useKitTransactionSigner, useSolanaClient, useTokens, useTransactionPreparer, useTransactionSigner, useTransactions, useWalletInfo } from './chunk-
|
|
3
|
-
export { ClipboardErrorType, ConfigurationError, ConnectionError, ConnectorClient, ConnectorError, ConnectorErrorBoundary, Errors, NetworkError, PUBLIC_RPC_ENDPOINTS, TransactionError, TransactionSignerError, ValidationError, WalletErrorType, copyAddressToClipboard, copySignatureToClipboard, copyToClipboard, createGillTransactionSigner, createKitTransactionSigner, createTransactionSigner, formatAddress, formatNumber, formatSOL, formatTokenAmount, getAddressUrl, getBlockUrl, getChainIdForWalletStandard, getClusterChainId, getClusterExplorerUrl, getClusterName, getClusterRpcUrl, getClusterType, getDefaultRpcUrl, getNetworkDisplayName, getPolyfillStatus, getTokenUrl, getTransactionUrl, getUserFriendlyMessage, getWalletsRegistry, installPolyfills, isClipboardAvailable, isConfigurationError, isConnectionError, isConnectorError, isCryptoAvailable, isDevnet, isDevnetCluster, isLocalCluster, isLocalnet, isMainnet, isMainnetCluster, isNetworkError, isPolyfillInstalled, isTestnet, isTestnetCluster, isTransactionError, isTransactionSignerError, isValidationError, normalizeNetwork, toClusterId, toConnectorError, truncate, withErrorBoundary } from './chunk-
|
|
4
|
-
export { LAMPORTS_PER_SOL, createSolanaClient, getExplorerLink, getPublicSolanaRpcUrl, lamportsToSol, prepareTransaction, solToLamports } from './chunk-
|
|
1
|
+
export { EnhancedStorage, EnhancedStorageAdapter, SOLANA_CHAIN_IDS, address, base58ToSignatureBytes, chainIdToClusterId, chainIdToClusterType, clusterToChainId, copySignature, createConfig, createEnhancedStorageAccount, createEnhancedStorageCluster, createEnhancedStorageWallet, createKitSignersFromWallet, createMessageSignerFromWallet, createSignableMessage, createSolanaDevnet, createSolanaLocalnet, createSolanaMainnet, createSolanaTestnet, createTransactionSendingSignerFromWallet, detectMessageModification, formatSignature, freezeSigner, getAllExplorerUrls, getChainIdFromCluster, getChainIdFromClusterId, getChainIdFromClusterType, getChainIdFromConnection, getClusterIdFromChainId, getClusterTypeFromChainId, getClusterTypeFromConnection, getDefaultConfig, getDefaultMobileConfig, getLatestBlockhash, getSolanaExplorerUrl, getSolanaFmUrl, getSolscanUrl, getXrayUrl, isAccountAddress, isKitConnection, isKnownSolanaChain, isLegacyConnection, isSolanaChain, isUnifiedConfig, isWalletName, sendRawTransaction, signatureBytesToBase58, updateSignatureDictionary, validateKnownSolanaChain } from './chunk-QKVL45F6.mjs';
|
|
2
|
+
export { AccountElement, UnifiedProvider as AppProvider, BalanceElement, ClusterElement, ConnectorProvider, DisconnectElement, TokenListElement, TransactionHistoryElement, UnifiedProvider, WalletListElement, useAccount, useBalance, useCluster, useConnector, useConnectorClient, useGillSolanaClient, useGillTransactionSigner, useKitTransactionSigner, useSolanaClient, useTokens, useTransactionPreparer, useTransactionSigner, useTransactions, useWalletInfo } from './chunk-3STZXVXD.mjs';
|
|
3
|
+
export { ClipboardErrorType, ConfigurationError, ConnectionError, ConnectorClient, ConnectorError, ConnectorErrorBoundary, Errors, NetworkError, PUBLIC_RPC_ENDPOINTS, TransactionError, TransactionSignerError, ValidationError, WalletErrorType, copyAddressToClipboard, copySignatureToClipboard, copyToClipboard, createGillTransactionSigner, createKitTransactionSigner, createTransactionSigner, formatAddress, formatNumber, formatSOL, formatTokenAmount, getAddressUrl, getBlockUrl, getChainIdForWalletStandard, getClusterChainId, getClusterExplorerUrl, getClusterName, getClusterRpcUrl, getClusterType, getDefaultRpcUrl, getNetworkDisplayName, getPolyfillStatus, getTokenUrl, getTransactionUrl, getUserFriendlyMessage, getWalletsRegistry, installPolyfills, isClipboardAvailable, isConfigurationError, isConnectionError, isConnectorError, isCryptoAvailable, isDevnet, isDevnetCluster, isLocalCluster, isLocalnet, isMainnet, isMainnetCluster, isNetworkError, isPolyfillInstalled, isTestnet, isTestnetCluster, isTransactionError, isTransactionSignerError, isValidationError, normalizeNetwork, toClusterId, toConnectorError, truncate, withErrorBoundary } from './chunk-VMSZJPR5.mjs';
|
|
4
|
+
export { LAMPORTS_PER_SOL, createSolanaClient, getExplorerLink, getPublicSolanaRpcUrl, lamportsToSol, prepareTransaction, solToLamports } from './chunk-QL3IT3TS.mjs';
|
|
5
5
|
//# sourceMappingURL=index.mjs.map
|
|
6
6
|
//# sourceMappingURL=index.mjs.map
|
package/dist/react.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { h as UnifiedConfig, d as ConnectorConfig, M as MobileWalletAdapterConfig, i as ClusterType, A as AccountInfo, V as ClipboardResult, Q as SolanaClient } from './wallet-standard-shim-
|
|
2
|
-
export { b as ConnectorErrorBoundary, C as ConnectorProvider, c as ConnectorSnapshot, e as ConnectorState, D as DefaultConfigOptions, E as ExtendedConnectorConfig, U as UnifiedConfigOptions, W as WalletInfo, g as WalletStandardAccount, f as WalletStandardWallet, u as useConnector, a as useConnectorClient, w as withErrorBoundary } from './wallet-standard-shim-
|
|
1
|
+
import { h as UnifiedConfig, d as ConnectorConfig, M as MobileWalletAdapterConfig, i as ClusterType, A as AccountInfo, V as ClipboardResult, Q as SolanaClient } from './wallet-standard-shim-Dx7H8Ctf.mjs';
|
|
2
|
+
export { b as ConnectorErrorBoundary, C as ConnectorProvider, c as ConnectorSnapshot, e as ConnectorState, D as DefaultConfigOptions, E as ExtendedConnectorConfig, U as UnifiedConfigOptions, W as WalletInfo, g as WalletStandardAccount, f as WalletStandardWallet, u as useConnector, a as useConnectorClient, w as withErrorBoundary } from './wallet-standard-shim-Dx7H8Ctf.mjs';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import { ReactNode, ComponentType, PropsWithChildren } from 'react';
|
|
5
5
|
import { SolanaCluster, SolanaClusterId } from '@wallet-ui/core';
|
|
@@ -679,7 +679,7 @@ interface UseTokensOptions {
|
|
|
679
679
|
autoRefresh?: boolean;
|
|
680
680
|
/** Refresh interval in milliseconds */
|
|
681
681
|
refreshInterval?: number;
|
|
682
|
-
/** Fetch metadata (name, symbol, logo)
|
|
682
|
+
/** Fetch metadata (name, symbol, logo) and USD prices */
|
|
683
683
|
fetchMetadata?: boolean;
|
|
684
684
|
/** Include native SOL balance */
|
|
685
685
|
includeNativeSol?: boolean;
|
|
@@ -700,7 +700,7 @@ interface UseTokensReturn {
|
|
|
700
700
|
}
|
|
701
701
|
/**
|
|
702
702
|
* Hook for fetching wallet token holdings.
|
|
703
|
-
* Fetches metadata (name, symbol, icon
|
|
703
|
+
* Fetches metadata (name, symbol, icon) from Solana Token List API and USD prices from CoinGecko.
|
|
704
704
|
*
|
|
705
705
|
* @example Basic usage
|
|
706
706
|
* ```tsx
|
package/dist/react.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { h as UnifiedConfig, d as ConnectorConfig, M as MobileWalletAdapterConfig, i as ClusterType, A as AccountInfo, V as ClipboardResult, Q as SolanaClient } from './wallet-standard-shim
|
|
2
|
-
export { b as ConnectorErrorBoundary, C as ConnectorProvider, c as ConnectorSnapshot, e as ConnectorState, D as DefaultConfigOptions, E as ExtendedConnectorConfig, U as UnifiedConfigOptions, W as WalletInfo, g as WalletStandardAccount, f as WalletStandardWallet, u as useConnector, a as useConnectorClient, w as withErrorBoundary } from './wallet-standard-shim
|
|
1
|
+
import { h as UnifiedConfig, d as ConnectorConfig, M as MobileWalletAdapterConfig, i as ClusterType, A as AccountInfo, V as ClipboardResult, Q as SolanaClient } from './wallet-standard-shim--YcrQNRt.js';
|
|
2
|
+
export { b as ConnectorErrorBoundary, C as ConnectorProvider, c as ConnectorSnapshot, e as ConnectorState, D as DefaultConfigOptions, E as ExtendedConnectorConfig, U as UnifiedConfigOptions, W as WalletInfo, g as WalletStandardAccount, f as WalletStandardWallet, u as useConnector, a as useConnectorClient, w as withErrorBoundary } from './wallet-standard-shim--YcrQNRt.js';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import { ReactNode, ComponentType, PropsWithChildren } from 'react';
|
|
5
5
|
import { SolanaCluster, SolanaClusterId } from '@wallet-ui/core';
|
|
@@ -679,7 +679,7 @@ interface UseTokensOptions {
|
|
|
679
679
|
autoRefresh?: boolean;
|
|
680
680
|
/** Refresh interval in milliseconds */
|
|
681
681
|
refreshInterval?: number;
|
|
682
|
-
/** Fetch metadata (name, symbol, logo)
|
|
682
|
+
/** Fetch metadata (name, symbol, logo) and USD prices */
|
|
683
683
|
fetchMetadata?: boolean;
|
|
684
684
|
/** Include native SOL balance */
|
|
685
685
|
includeNativeSol?: boolean;
|
|
@@ -700,7 +700,7 @@ interface UseTokensReturn {
|
|
|
700
700
|
}
|
|
701
701
|
/**
|
|
702
702
|
* Hook for fetching wallet token holdings.
|
|
703
|
-
* Fetches metadata (name, symbol, icon
|
|
703
|
+
* Fetches metadata (name, symbol, icon) from Solana Token List API and USD prices from CoinGecko.
|
|
704
704
|
*
|
|
705
705
|
* @example Basic usage
|
|
706
706
|
* ```tsx
|
package/dist/react.js
CHANGED
|
@@ -1,113 +1,113 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunkULUYX23Q_js = require('./chunk-ULUYX23Q.js');
|
|
4
|
+
var chunkJUZVCBAI_js = require('./chunk-JUZVCBAI.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
Object.defineProperty(exports, "AccountElement", {
|
|
9
9
|
enumerable: true,
|
|
10
|
-
get: function () { return
|
|
10
|
+
get: function () { return chunkULUYX23Q_js.AccountElement; }
|
|
11
11
|
});
|
|
12
12
|
Object.defineProperty(exports, "AppProvider", {
|
|
13
13
|
enumerable: true,
|
|
14
|
-
get: function () { return
|
|
14
|
+
get: function () { return chunkULUYX23Q_js.UnifiedProvider; }
|
|
15
15
|
});
|
|
16
16
|
Object.defineProperty(exports, "BalanceElement", {
|
|
17
17
|
enumerable: true,
|
|
18
|
-
get: function () { return
|
|
18
|
+
get: function () { return chunkULUYX23Q_js.BalanceElement; }
|
|
19
19
|
});
|
|
20
20
|
Object.defineProperty(exports, "ClusterElement", {
|
|
21
21
|
enumerable: true,
|
|
22
|
-
get: function () { return
|
|
22
|
+
get: function () { return chunkULUYX23Q_js.ClusterElement; }
|
|
23
23
|
});
|
|
24
24
|
Object.defineProperty(exports, "ConnectorProvider", {
|
|
25
25
|
enumerable: true,
|
|
26
|
-
get: function () { return
|
|
26
|
+
get: function () { return chunkULUYX23Q_js.ConnectorProvider; }
|
|
27
27
|
});
|
|
28
28
|
Object.defineProperty(exports, "DisconnectElement", {
|
|
29
29
|
enumerable: true,
|
|
30
|
-
get: function () { return
|
|
30
|
+
get: function () { return chunkULUYX23Q_js.DisconnectElement; }
|
|
31
31
|
});
|
|
32
32
|
Object.defineProperty(exports, "TokenListElement", {
|
|
33
33
|
enumerable: true,
|
|
34
|
-
get: function () { return
|
|
34
|
+
get: function () { return chunkULUYX23Q_js.TokenListElement; }
|
|
35
35
|
});
|
|
36
36
|
Object.defineProperty(exports, "TransactionHistoryElement", {
|
|
37
37
|
enumerable: true,
|
|
38
|
-
get: function () { return
|
|
38
|
+
get: function () { return chunkULUYX23Q_js.TransactionHistoryElement; }
|
|
39
39
|
});
|
|
40
40
|
Object.defineProperty(exports, "UnifiedProvider", {
|
|
41
41
|
enumerable: true,
|
|
42
|
-
get: function () { return
|
|
42
|
+
get: function () { return chunkULUYX23Q_js.UnifiedProvider; }
|
|
43
43
|
});
|
|
44
44
|
Object.defineProperty(exports, "WalletListElement", {
|
|
45
45
|
enumerable: true,
|
|
46
|
-
get: function () { return
|
|
46
|
+
get: function () { return chunkULUYX23Q_js.WalletListElement; }
|
|
47
47
|
});
|
|
48
48
|
Object.defineProperty(exports, "useAccount", {
|
|
49
49
|
enumerable: true,
|
|
50
|
-
get: function () { return
|
|
50
|
+
get: function () { return chunkULUYX23Q_js.useAccount; }
|
|
51
51
|
});
|
|
52
52
|
Object.defineProperty(exports, "useBalance", {
|
|
53
53
|
enumerable: true,
|
|
54
|
-
get: function () { return
|
|
54
|
+
get: function () { return chunkULUYX23Q_js.useBalance; }
|
|
55
55
|
});
|
|
56
56
|
Object.defineProperty(exports, "useCluster", {
|
|
57
57
|
enumerable: true,
|
|
58
|
-
get: function () { return
|
|
58
|
+
get: function () { return chunkULUYX23Q_js.useCluster; }
|
|
59
59
|
});
|
|
60
60
|
Object.defineProperty(exports, "useConnector", {
|
|
61
61
|
enumerable: true,
|
|
62
|
-
get: function () { return
|
|
62
|
+
get: function () { return chunkULUYX23Q_js.useConnector; }
|
|
63
63
|
});
|
|
64
64
|
Object.defineProperty(exports, "useConnectorClient", {
|
|
65
65
|
enumerable: true,
|
|
66
|
-
get: function () { return
|
|
66
|
+
get: function () { return chunkULUYX23Q_js.useConnectorClient; }
|
|
67
67
|
});
|
|
68
68
|
Object.defineProperty(exports, "useGillSolanaClient", {
|
|
69
69
|
enumerable: true,
|
|
70
|
-
get: function () { return
|
|
70
|
+
get: function () { return chunkULUYX23Q_js.useGillSolanaClient; }
|
|
71
71
|
});
|
|
72
72
|
Object.defineProperty(exports, "useGillTransactionSigner", {
|
|
73
73
|
enumerable: true,
|
|
74
|
-
get: function () { return
|
|
74
|
+
get: function () { return chunkULUYX23Q_js.useGillTransactionSigner; }
|
|
75
75
|
});
|
|
76
76
|
Object.defineProperty(exports, "useKitTransactionSigner", {
|
|
77
77
|
enumerable: true,
|
|
78
|
-
get: function () { return
|
|
78
|
+
get: function () { return chunkULUYX23Q_js.useKitTransactionSigner; }
|
|
79
79
|
});
|
|
80
80
|
Object.defineProperty(exports, "useSolanaClient", {
|
|
81
81
|
enumerable: true,
|
|
82
|
-
get: function () { return
|
|
82
|
+
get: function () { return chunkULUYX23Q_js.useSolanaClient; }
|
|
83
83
|
});
|
|
84
84
|
Object.defineProperty(exports, "useTokens", {
|
|
85
85
|
enumerable: true,
|
|
86
|
-
get: function () { return
|
|
86
|
+
get: function () { return chunkULUYX23Q_js.useTokens; }
|
|
87
87
|
});
|
|
88
88
|
Object.defineProperty(exports, "useTransactionPreparer", {
|
|
89
89
|
enumerable: true,
|
|
90
|
-
get: function () { return
|
|
90
|
+
get: function () { return chunkULUYX23Q_js.useTransactionPreparer; }
|
|
91
91
|
});
|
|
92
92
|
Object.defineProperty(exports, "useTransactionSigner", {
|
|
93
93
|
enumerable: true,
|
|
94
|
-
get: function () { return
|
|
94
|
+
get: function () { return chunkULUYX23Q_js.useTransactionSigner; }
|
|
95
95
|
});
|
|
96
96
|
Object.defineProperty(exports, "useTransactions", {
|
|
97
97
|
enumerable: true,
|
|
98
|
-
get: function () { return
|
|
98
|
+
get: function () { return chunkULUYX23Q_js.useTransactions; }
|
|
99
99
|
});
|
|
100
100
|
Object.defineProperty(exports, "useWalletInfo", {
|
|
101
101
|
enumerable: true,
|
|
102
|
-
get: function () { return
|
|
102
|
+
get: function () { return chunkULUYX23Q_js.useWalletInfo; }
|
|
103
103
|
});
|
|
104
104
|
Object.defineProperty(exports, "ConnectorErrorBoundary", {
|
|
105
105
|
enumerable: true,
|
|
106
|
-
get: function () { return
|
|
106
|
+
get: function () { return chunkJUZVCBAI_js.ConnectorErrorBoundary; }
|
|
107
107
|
});
|
|
108
108
|
Object.defineProperty(exports, "withErrorBoundary", {
|
|
109
109
|
enumerable: true,
|
|
110
|
-
get: function () { return
|
|
110
|
+
get: function () { return chunkJUZVCBAI_js.withErrorBoundary; }
|
|
111
111
|
});
|
|
112
112
|
//# sourceMappingURL=react.js.map
|
|
113
113
|
//# sourceMappingURL=react.js.map
|
package/dist/react.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { AccountElement, UnifiedProvider as AppProvider, BalanceElement, ClusterElement, ConnectorProvider, DisconnectElement, TokenListElement, TransactionHistoryElement, UnifiedProvider, WalletListElement, useAccount, useBalance, useCluster, useConnector, useConnectorClient, useGillSolanaClient, useGillTransactionSigner, useKitTransactionSigner, useSolanaClient, useTokens, useTransactionPreparer, useTransactionSigner, useTransactions, useWalletInfo } from './chunk-
|
|
2
|
-
export { ConnectorErrorBoundary, withErrorBoundary } from './chunk-
|
|
1
|
+
export { AccountElement, UnifiedProvider as AppProvider, BalanceElement, ClusterElement, ConnectorProvider, DisconnectElement, TokenListElement, TransactionHistoryElement, UnifiedProvider, WalletListElement, useAccount, useBalance, useCluster, useConnector, useConnectorClient, useGillSolanaClient, useGillTransactionSigner, useKitTransactionSigner, useSolanaClient, useTokens, useTransactionPreparer, useTransactionSigner, useTransactions, useWalletInfo } from './chunk-3STZXVXD.mjs';
|
|
2
|
+
export { ConnectorErrorBoundary, withErrorBoundary } from './chunk-VMSZJPR5.mjs';
|
|
3
3
|
//# sourceMappingURL=react.mjs.map
|
|
4
4
|
//# sourceMappingURL=react.mjs.map
|
|
@@ -116,6 +116,48 @@ interface AccountInfo {
|
|
|
116
116
|
raw: WalletAccount;
|
|
117
117
|
}
|
|
118
118
|
|
|
119
|
+
/**
|
|
120
|
+
* CoinGecko API configuration for price fetching.
|
|
121
|
+
*
|
|
122
|
+
* Rate Limits (as of 2024):
|
|
123
|
+
* - Free tier (no API key): 10-30 requests/minute (varies by endpoint)
|
|
124
|
+
* - Demo tier (free API key): 30 requests/minute
|
|
125
|
+
* - Paid tiers: Higher limits based on plan
|
|
126
|
+
*
|
|
127
|
+
* @see https://docs.coingecko.com/reference/introduction
|
|
128
|
+
*/
|
|
129
|
+
interface CoinGeckoConfig {
|
|
130
|
+
/**
|
|
131
|
+
* CoinGecko API key for higher rate limits.
|
|
132
|
+
* Get a free Demo API key at https://www.coingecko.com/en/api/pricing
|
|
133
|
+
* - Without key: ~10-30 requests/minute (public rate limit)
|
|
134
|
+
* - With Demo key: 30 requests/minute
|
|
135
|
+
*/
|
|
136
|
+
apiKey?: string;
|
|
137
|
+
/**
|
|
138
|
+
* Whether the API key is for the Pro API (api.coingecko.com with x-cg-pro-api-key header)
|
|
139
|
+
* or the Demo API (api.coingecko.com with x-cg-demo-api-key header).
|
|
140
|
+
* @default false (uses Demo API header)
|
|
141
|
+
*/
|
|
142
|
+
isPro?: boolean;
|
|
143
|
+
/**
|
|
144
|
+
* Maximum number of retry attempts when rate limited (429 response).
|
|
145
|
+
* @default 3
|
|
146
|
+
*/
|
|
147
|
+
maxRetries?: number;
|
|
148
|
+
/**
|
|
149
|
+
* Base delay in milliseconds for exponential backoff.
|
|
150
|
+
* Actual delay = baseDelay * 2^attempt + random jitter
|
|
151
|
+
* @default 1000 (1 second)
|
|
152
|
+
*/
|
|
153
|
+
baseDelay?: number;
|
|
154
|
+
/**
|
|
155
|
+
* Maximum total timeout in milliseconds for all retry attempts combined.
|
|
156
|
+
* Prevents blocking the caller for too long.
|
|
157
|
+
* @default 30000 (30 seconds)
|
|
158
|
+
*/
|
|
159
|
+
maxTimeout?: number;
|
|
160
|
+
}
|
|
119
161
|
/**
|
|
120
162
|
* Core connector state
|
|
121
163
|
*/
|
|
@@ -151,6 +193,19 @@ interface ConnectorConfig {
|
|
|
151
193
|
persistSelection?: boolean;
|
|
152
194
|
initialCluster?: SolanaClusterId;
|
|
153
195
|
};
|
|
196
|
+
/**
|
|
197
|
+
* Image proxy URL prefix for token images.
|
|
198
|
+
* When set, token image URLs will be transformed to: `${imageProxy}${encodeURIComponent(originalUrl)}`
|
|
199
|
+
* This prevents direct image fetching which can leak user IPs to untrusted hosts.
|
|
200
|
+
* @example '/_next/image?w=64&q=75&url=' // Next.js Image Optimization
|
|
201
|
+
* @example '/cdn-cgi/image/width=64,quality=75/' // Cloudflare Image Resizing
|
|
202
|
+
*/
|
|
203
|
+
imageProxy?: string;
|
|
204
|
+
/**
|
|
205
|
+
* CoinGecko API configuration for token price fetching.
|
|
206
|
+
* Configure API key for higher rate limits and retry behavior for 429 responses.
|
|
207
|
+
*/
|
|
208
|
+
coingecko?: CoinGeckoConfig;
|
|
154
209
|
}
|
|
155
210
|
/**
|
|
156
211
|
* Health check information for connector diagnostics
|
|
@@ -324,6 +379,10 @@ declare class ConnectorClient {
|
|
|
324
379
|
getHealth(): ConnectorHealth;
|
|
325
380
|
getDebugMetrics(): ConnectorDebugMetrics;
|
|
326
381
|
getDebugState(): ConnectorDebugState;
|
|
382
|
+
/**
|
|
383
|
+
* Get the current connector configuration
|
|
384
|
+
*/
|
|
385
|
+
getConfig(): ConnectorConfig;
|
|
327
386
|
resetDebugMetrics(): void;
|
|
328
387
|
destroy(): void;
|
|
329
388
|
}
|
|
@@ -357,6 +416,20 @@ interface DefaultConfigOptions {
|
|
|
357
416
|
maxRetries?: number;
|
|
358
417
|
/** Custom error handler */
|
|
359
418
|
onError?: (error: Error, errorInfo: React.ErrorInfo) => void;
|
|
419
|
+
/**
|
|
420
|
+
* Image proxy URL prefix for token images.
|
|
421
|
+
* When set, token image URLs will be transformed to: `${imageProxy}${encodeURIComponent(originalUrl)}`
|
|
422
|
+
* This prevents direct image fetching which can leak user IPs to untrusted hosts.
|
|
423
|
+
* @example '/_next/image?w=64&q=75&url=' // Next.js Image Optimization
|
|
424
|
+
* @example '/cdn-cgi/image/width=64,quality=75/' // Cloudflare Image Resizing
|
|
425
|
+
*/
|
|
426
|
+
imageProxy?: string;
|
|
427
|
+
/**
|
|
428
|
+
* CoinGecko API configuration for token price fetching.
|
|
429
|
+
* Configure API key for higher rate limits and retry behavior for 429 responses.
|
|
430
|
+
* @see https://docs.coingecko.com/reference/introduction for rate limit details
|
|
431
|
+
*/
|
|
432
|
+
coingecko?: CoinGeckoConfig;
|
|
360
433
|
}
|
|
361
434
|
/** Extended ConnectorConfig with app metadata */
|
|
362
435
|
interface ExtendedConnectorConfig extends ConnectorConfig {
|
|
@@ -379,6 +452,16 @@ interface ExtendedConnectorConfig extends ConnectorConfig {
|
|
|
379
452
|
/** Custom fallback component */
|
|
380
453
|
fallback?: (error: Error, retry: () => void) => React.ReactNode;
|
|
381
454
|
};
|
|
455
|
+
/**
|
|
456
|
+
* Image proxy URL prefix for token images.
|
|
457
|
+
* When set, token image URLs will be transformed to: `${imageProxy}${encodeURIComponent(originalUrl)}`
|
|
458
|
+
* This prevents direct image fetching which can leak user IPs to untrusted hosts.
|
|
459
|
+
*/
|
|
460
|
+
imageProxy?: string;
|
|
461
|
+
/**
|
|
462
|
+
* CoinGecko API configuration for token price fetching.
|
|
463
|
+
*/
|
|
464
|
+
coingecko?: CoinGeckoConfig;
|
|
382
465
|
}
|
|
383
466
|
/**
|
|
384
467
|
* Creates a default connector configuration with sensible defaults for Solana applications
|
|
@@ -116,6 +116,48 @@ interface AccountInfo {
|
|
|
116
116
|
raw: WalletAccount;
|
|
117
117
|
}
|
|
118
118
|
|
|
119
|
+
/**
|
|
120
|
+
* CoinGecko API configuration for price fetching.
|
|
121
|
+
*
|
|
122
|
+
* Rate Limits (as of 2024):
|
|
123
|
+
* - Free tier (no API key): 10-30 requests/minute (varies by endpoint)
|
|
124
|
+
* - Demo tier (free API key): 30 requests/minute
|
|
125
|
+
* - Paid tiers: Higher limits based on plan
|
|
126
|
+
*
|
|
127
|
+
* @see https://docs.coingecko.com/reference/introduction
|
|
128
|
+
*/
|
|
129
|
+
interface CoinGeckoConfig {
|
|
130
|
+
/**
|
|
131
|
+
* CoinGecko API key for higher rate limits.
|
|
132
|
+
* Get a free Demo API key at https://www.coingecko.com/en/api/pricing
|
|
133
|
+
* - Without key: ~10-30 requests/minute (public rate limit)
|
|
134
|
+
* - With Demo key: 30 requests/minute
|
|
135
|
+
*/
|
|
136
|
+
apiKey?: string;
|
|
137
|
+
/**
|
|
138
|
+
* Whether the API key is for the Pro API (api.coingecko.com with x-cg-pro-api-key header)
|
|
139
|
+
* or the Demo API (api.coingecko.com with x-cg-demo-api-key header).
|
|
140
|
+
* @default false (uses Demo API header)
|
|
141
|
+
*/
|
|
142
|
+
isPro?: boolean;
|
|
143
|
+
/**
|
|
144
|
+
* Maximum number of retry attempts when rate limited (429 response).
|
|
145
|
+
* @default 3
|
|
146
|
+
*/
|
|
147
|
+
maxRetries?: number;
|
|
148
|
+
/**
|
|
149
|
+
* Base delay in milliseconds for exponential backoff.
|
|
150
|
+
* Actual delay = baseDelay * 2^attempt + random jitter
|
|
151
|
+
* @default 1000 (1 second)
|
|
152
|
+
*/
|
|
153
|
+
baseDelay?: number;
|
|
154
|
+
/**
|
|
155
|
+
* Maximum total timeout in milliseconds for all retry attempts combined.
|
|
156
|
+
* Prevents blocking the caller for too long.
|
|
157
|
+
* @default 30000 (30 seconds)
|
|
158
|
+
*/
|
|
159
|
+
maxTimeout?: number;
|
|
160
|
+
}
|
|
119
161
|
/**
|
|
120
162
|
* Core connector state
|
|
121
163
|
*/
|
|
@@ -151,6 +193,19 @@ interface ConnectorConfig {
|
|
|
151
193
|
persistSelection?: boolean;
|
|
152
194
|
initialCluster?: SolanaClusterId;
|
|
153
195
|
};
|
|
196
|
+
/**
|
|
197
|
+
* Image proxy URL prefix for token images.
|
|
198
|
+
* When set, token image URLs will be transformed to: `${imageProxy}${encodeURIComponent(originalUrl)}`
|
|
199
|
+
* This prevents direct image fetching which can leak user IPs to untrusted hosts.
|
|
200
|
+
* @example '/_next/image?w=64&q=75&url=' // Next.js Image Optimization
|
|
201
|
+
* @example '/cdn-cgi/image/width=64,quality=75/' // Cloudflare Image Resizing
|
|
202
|
+
*/
|
|
203
|
+
imageProxy?: string;
|
|
204
|
+
/**
|
|
205
|
+
* CoinGecko API configuration for token price fetching.
|
|
206
|
+
* Configure API key for higher rate limits and retry behavior for 429 responses.
|
|
207
|
+
*/
|
|
208
|
+
coingecko?: CoinGeckoConfig;
|
|
154
209
|
}
|
|
155
210
|
/**
|
|
156
211
|
* Health check information for connector diagnostics
|
|
@@ -324,6 +379,10 @@ declare class ConnectorClient {
|
|
|
324
379
|
getHealth(): ConnectorHealth;
|
|
325
380
|
getDebugMetrics(): ConnectorDebugMetrics;
|
|
326
381
|
getDebugState(): ConnectorDebugState;
|
|
382
|
+
/**
|
|
383
|
+
* Get the current connector configuration
|
|
384
|
+
*/
|
|
385
|
+
getConfig(): ConnectorConfig;
|
|
327
386
|
resetDebugMetrics(): void;
|
|
328
387
|
destroy(): void;
|
|
329
388
|
}
|
|
@@ -357,6 +416,20 @@ interface DefaultConfigOptions {
|
|
|
357
416
|
maxRetries?: number;
|
|
358
417
|
/** Custom error handler */
|
|
359
418
|
onError?: (error: Error, errorInfo: React.ErrorInfo) => void;
|
|
419
|
+
/**
|
|
420
|
+
* Image proxy URL prefix for token images.
|
|
421
|
+
* When set, token image URLs will be transformed to: `${imageProxy}${encodeURIComponent(originalUrl)}`
|
|
422
|
+
* This prevents direct image fetching which can leak user IPs to untrusted hosts.
|
|
423
|
+
* @example '/_next/image?w=64&q=75&url=' // Next.js Image Optimization
|
|
424
|
+
* @example '/cdn-cgi/image/width=64,quality=75/' // Cloudflare Image Resizing
|
|
425
|
+
*/
|
|
426
|
+
imageProxy?: string;
|
|
427
|
+
/**
|
|
428
|
+
* CoinGecko API configuration for token price fetching.
|
|
429
|
+
* Configure API key for higher rate limits and retry behavior for 429 responses.
|
|
430
|
+
* @see https://docs.coingecko.com/reference/introduction for rate limit details
|
|
431
|
+
*/
|
|
432
|
+
coingecko?: CoinGeckoConfig;
|
|
360
433
|
}
|
|
361
434
|
/** Extended ConnectorConfig with app metadata */
|
|
362
435
|
interface ExtendedConnectorConfig extends ConnectorConfig {
|
|
@@ -379,6 +452,16 @@ interface ExtendedConnectorConfig extends ConnectorConfig {
|
|
|
379
452
|
/** Custom fallback component */
|
|
380
453
|
fallback?: (error: Error, retry: () => void) => React.ReactNode;
|
|
381
454
|
};
|
|
455
|
+
/**
|
|
456
|
+
* Image proxy URL prefix for token images.
|
|
457
|
+
* When set, token image URLs will be transformed to: `${imageProxy}${encodeURIComponent(originalUrl)}`
|
|
458
|
+
* This prevents direct image fetching which can leak user IPs to untrusted hosts.
|
|
459
|
+
*/
|
|
460
|
+
imageProxy?: string;
|
|
461
|
+
/**
|
|
462
|
+
* CoinGecko API configuration for token price fetching.
|
|
463
|
+
*/
|
|
464
|
+
coingecko?: CoinGeckoConfig;
|
|
382
465
|
}
|
|
383
466
|
/**
|
|
384
467
|
* Creates a default connector configuration with sensible defaults for Solana applications
|