@chainflip/utils 0.5.1 → 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/dist/chainflip.cjs
CHANGED
|
@@ -22,8 +22,10 @@ var chainflip_exports = {};
|
|
|
22
22
|
__export(chainflip_exports, {
|
|
23
23
|
addressTypes: () => addressTypes,
|
|
24
24
|
assetConstants: () => assetConstants,
|
|
25
|
+
assetContractId: () => assetContractId,
|
|
25
26
|
baseChainflipAssets: () => baseChainflipAssets,
|
|
26
27
|
chainConstants: () => chainConstants,
|
|
28
|
+
chainContractId: () => chainContractId,
|
|
27
29
|
chainflipAssets: () => chainflipAssets,
|
|
28
30
|
chainflipChains: () => chainflipChains,
|
|
29
31
|
chainflipEvmChains: () => chainflipEvmChains,
|
|
@@ -153,12 +155,33 @@ var internalAssetToRpcAsset = {
|
|
|
153
155
|
Sol: { chain: "Solana", asset: "SOL" },
|
|
154
156
|
SolUsdc: { chain: "Solana", asset: "USDC" }
|
|
155
157
|
};
|
|
158
|
+
var chainContractId = {
|
|
159
|
+
Ethereum: 1,
|
|
160
|
+
Polkadot: 2,
|
|
161
|
+
Bitcoin: 3,
|
|
162
|
+
Arbitrum: 4,
|
|
163
|
+
Solana: 5
|
|
164
|
+
};
|
|
165
|
+
var assetContractId = {
|
|
166
|
+
Eth: 1,
|
|
167
|
+
Flip: 2,
|
|
168
|
+
Usdc: 3,
|
|
169
|
+
Usdt: 8,
|
|
170
|
+
Dot: 4,
|
|
171
|
+
Btc: 5,
|
|
172
|
+
ArbEth: 6,
|
|
173
|
+
ArbUsdc: 7,
|
|
174
|
+
Sol: 9,
|
|
175
|
+
SolUsdc: 10
|
|
176
|
+
};
|
|
156
177
|
// Annotate the CommonJS export names for ESM import in node:
|
|
157
178
|
0 && (module.exports = {
|
|
158
179
|
addressTypes,
|
|
159
180
|
assetConstants,
|
|
181
|
+
assetContractId,
|
|
160
182
|
baseChainflipAssets,
|
|
161
183
|
chainConstants,
|
|
184
|
+
chainContractId,
|
|
162
185
|
chainflipAssets,
|
|
163
186
|
chainflipChains,
|
|
164
187
|
chainflipEvmChains,
|
package/dist/chainflip.d.cts
CHANGED
|
@@ -116,5 +116,7 @@ declare const chainConstants: {
|
|
|
116
116
|
};
|
|
117
117
|
};
|
|
118
118
|
declare const internalAssetToRpcAsset: Record<ChainflipAsset, AssetAndChain>;
|
|
119
|
+
declare const chainContractId: Record<ChainflipChain, number>;
|
|
120
|
+
declare const assetContractId: Record<ChainflipAsset, number>;
|
|
119
121
|
|
|
120
|
-
export { type AddressType, type AssetOfChain, type BaseChainAssetMap, type BaseChainflipAsset, type ChainAssetMap, type ChainflipAsset, type ChainflipChain, type ChainflipEvmChain, type ChainflipNetwork, addressTypes, assetConstants, baseChainflipAssets, chainConstants, chainflipAssets, chainflipChains, chainflipEvmChains, chainflipNetworks, internalAssetToRpcAsset, readAssetValue, rpcAssets };
|
|
122
|
+
export { type AddressType, type AssetOfChain, type BaseChainAssetMap, type BaseChainflipAsset, type ChainAssetMap, type ChainflipAsset, type ChainflipChain, type ChainflipEvmChain, type ChainflipNetwork, addressTypes, assetConstants, assetContractId, baseChainflipAssets, chainConstants, chainContractId, chainflipAssets, chainflipChains, chainflipEvmChains, chainflipNetworks, internalAssetToRpcAsset, readAssetValue, rpcAssets };
|
package/dist/chainflip.d.ts
CHANGED
|
@@ -116,5 +116,7 @@ declare const chainConstants: {
|
|
|
116
116
|
};
|
|
117
117
|
};
|
|
118
118
|
declare const internalAssetToRpcAsset: Record<ChainflipAsset, AssetAndChain>;
|
|
119
|
+
declare const chainContractId: Record<ChainflipChain, number>;
|
|
120
|
+
declare const assetContractId: Record<ChainflipAsset, number>;
|
|
119
121
|
|
|
120
|
-
export { type AddressType, type AssetOfChain, type BaseChainAssetMap, type BaseChainflipAsset, type ChainAssetMap, type ChainflipAsset, type ChainflipChain, type ChainflipEvmChain, type ChainflipNetwork, addressTypes, assetConstants, baseChainflipAssets, chainConstants, chainflipAssets, chainflipChains, chainflipEvmChains, chainflipNetworks, internalAssetToRpcAsset, readAssetValue, rpcAssets };
|
|
122
|
+
export { type AddressType, type AssetOfChain, type BaseChainAssetMap, type BaseChainflipAsset, type ChainAssetMap, type ChainflipAsset, type ChainflipChain, type ChainflipEvmChain, type ChainflipNetwork, addressTypes, assetConstants, assetContractId, baseChainflipAssets, chainConstants, chainContractId, chainflipAssets, chainflipChains, chainflipEvmChains, chainflipNetworks, internalAssetToRpcAsset, readAssetValue, rpcAssets };
|
package/dist/chainflip.js
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
addressTypes,
|
|
3
3
|
assetConstants,
|
|
4
|
+
assetContractId,
|
|
4
5
|
baseChainflipAssets,
|
|
5
6
|
chainConstants,
|
|
7
|
+
chainContractId,
|
|
6
8
|
chainflipAssets,
|
|
7
9
|
chainflipChains,
|
|
8
10
|
chainflipEvmChains,
|
|
@@ -10,12 +12,14 @@ import {
|
|
|
10
12
|
internalAssetToRpcAsset,
|
|
11
13
|
readAssetValue,
|
|
12
14
|
rpcAssets
|
|
13
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-YOAHWTE7.js";
|
|
14
16
|
export {
|
|
15
17
|
addressTypes,
|
|
16
18
|
assetConstants,
|
|
19
|
+
assetContractId,
|
|
17
20
|
baseChainflipAssets,
|
|
18
21
|
chainConstants,
|
|
22
|
+
chainContractId,
|
|
19
23
|
chainflipAssets,
|
|
20
24
|
chainflipChains,
|
|
21
25
|
chainflipEvmChains,
|
|
@@ -119,6 +119,25 @@ var internalAssetToRpcAsset = {
|
|
|
119
119
|
Sol: { chain: "Solana", asset: "SOL" },
|
|
120
120
|
SolUsdc: { chain: "Solana", asset: "USDC" }
|
|
121
121
|
};
|
|
122
|
+
var chainContractId = {
|
|
123
|
+
Ethereum: 1,
|
|
124
|
+
Polkadot: 2,
|
|
125
|
+
Bitcoin: 3,
|
|
126
|
+
Arbitrum: 4,
|
|
127
|
+
Solana: 5
|
|
128
|
+
};
|
|
129
|
+
var assetContractId = {
|
|
130
|
+
Eth: 1,
|
|
131
|
+
Flip: 2,
|
|
132
|
+
Usdc: 3,
|
|
133
|
+
Usdt: 8,
|
|
134
|
+
Dot: 4,
|
|
135
|
+
Btc: 5,
|
|
136
|
+
ArbEth: 6,
|
|
137
|
+
ArbUsdc: 7,
|
|
138
|
+
Sol: 9,
|
|
139
|
+
SolUsdc: 10
|
|
140
|
+
};
|
|
122
141
|
|
|
123
142
|
export {
|
|
124
143
|
chainflipAssets,
|
|
@@ -131,5 +150,7 @@ export {
|
|
|
131
150
|
readAssetValue,
|
|
132
151
|
assetConstants,
|
|
133
152
|
chainConstants,
|
|
134
|
-
internalAssetToRpcAsset
|
|
153
|
+
internalAssetToRpcAsset,
|
|
154
|
+
chainContractId,
|
|
155
|
+
assetContractId
|
|
135
156
|
};
|
package/dist/tickMath.js
CHANGED