@xchainjs/xchain-mayachain-query 2.0.2 → 2.0.4
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/lib/index.esm.js +4 -1
- package/lib/index.js +5 -0
- package/lib/utils/const.d.ts +2 -0
- package/package.json +8 -8
package/lib/index.esm.js
CHANGED
|
@@ -144,6 +144,7 @@ const DashAsset = assetFromStringEx('DASH.DASH');
|
|
|
144
144
|
const KujiraAsset = assetFromStringEx('KUJI.KUJI');
|
|
145
145
|
const ArbAsset = assetFromStringEx('ARB.ETH');
|
|
146
146
|
const XdrAsset = assetFromStringEx('XRD.XRD');
|
|
147
|
+
const ZecAsset = assetFromStringEx('ZEC.ZEC');
|
|
147
148
|
const BtcChain = 'BTC';
|
|
148
149
|
const EthChain = 'ETH';
|
|
149
150
|
const MayaChain = 'MAYA';
|
|
@@ -152,6 +153,7 @@ const DashChain = 'DASH';
|
|
|
152
153
|
const KujiraChain = 'KUJI';
|
|
153
154
|
const ArbChain = 'ARB';
|
|
154
155
|
const XdrChain = 'XRD';
|
|
156
|
+
const ZecChain = 'ZEC';
|
|
155
157
|
const DEFAULT_MAYACHAIN_DECIMALS = 8;
|
|
156
158
|
|
|
157
159
|
const isCacaoAsset = (asset) => assetToString(asset) === assetToString(CacaoAsset);
|
|
@@ -422,6 +424,7 @@ class MayachainQuery {
|
|
|
422
424
|
[MayaChain]: new AssetCryptoAmount(baseAmount(0, 10), CacaoAsset),
|
|
423
425
|
[ArbChain]: new AssetCryptoAmount(baseAmount(0, 18), ArbAsset),
|
|
424
426
|
[XdrChain]: new AssetCryptoAmount(baseAmount(0, 18), XdrAsset),
|
|
427
|
+
[ZecChain]: new AssetCryptoAmount(baseAmount(1000, 8), ZecAsset),
|
|
425
428
|
};
|
|
426
429
|
}
|
|
427
430
|
/**
|
|
@@ -650,4 +653,4 @@ class MayachainQuery {
|
|
|
650
653
|
}
|
|
651
654
|
}
|
|
652
655
|
|
|
653
|
-
export { ArbAsset, ArbChain, BtcAsset, BtcChain, CacaoAsset, DEFAULT_MAYACHAIN_DECIMALS, DashAsset, DashChain, EthAsset, EthChain, KujiraAsset, KujiraChain, MayaChain, MayachainCache, MayachainQuery, Mayanode, RuneAsset, ThorChain, XdrAsset, XdrChain, getBaseAmountWithDiffDecimals, getCryptoAmountWithNotation, isCacaoAsset };
|
|
656
|
+
export { ArbAsset, ArbChain, BtcAsset, BtcChain, CacaoAsset, DEFAULT_MAYACHAIN_DECIMALS, DashAsset, DashChain, EthAsset, EthChain, KujiraAsset, KujiraChain, MayaChain, MayachainCache, MayachainQuery, Mayanode, RuneAsset, ThorChain, XdrAsset, XdrChain, ZecAsset, ZecChain, getBaseAmountWithDiffDecimals, getCryptoAmountWithNotation, isCacaoAsset };
|
package/lib/index.js
CHANGED
|
@@ -151,6 +151,7 @@ const DashAsset = xchainUtil.assetFromStringEx('DASH.DASH');
|
|
|
151
151
|
const KujiraAsset = xchainUtil.assetFromStringEx('KUJI.KUJI');
|
|
152
152
|
const ArbAsset = xchainUtil.assetFromStringEx('ARB.ETH');
|
|
153
153
|
const XdrAsset = xchainUtil.assetFromStringEx('XRD.XRD');
|
|
154
|
+
const ZecAsset = xchainUtil.assetFromStringEx('ZEC.ZEC');
|
|
154
155
|
const BtcChain = 'BTC';
|
|
155
156
|
const EthChain = 'ETH';
|
|
156
157
|
const MayaChain = 'MAYA';
|
|
@@ -159,6 +160,7 @@ const DashChain = 'DASH';
|
|
|
159
160
|
const KujiraChain = 'KUJI';
|
|
160
161
|
const ArbChain = 'ARB';
|
|
161
162
|
const XdrChain = 'XRD';
|
|
163
|
+
const ZecChain = 'ZEC';
|
|
162
164
|
const DEFAULT_MAYACHAIN_DECIMALS = 8;
|
|
163
165
|
|
|
164
166
|
const isCacaoAsset = (asset) => xchainUtil.assetToString(asset) === xchainUtil.assetToString(CacaoAsset);
|
|
@@ -429,6 +431,7 @@ class MayachainQuery {
|
|
|
429
431
|
[MayaChain]: new xchainUtil.AssetCryptoAmount(xchainUtil.baseAmount(0, 10), CacaoAsset),
|
|
430
432
|
[ArbChain]: new xchainUtil.AssetCryptoAmount(xchainUtil.baseAmount(0, 18), ArbAsset),
|
|
431
433
|
[XdrChain]: new xchainUtil.AssetCryptoAmount(xchainUtil.baseAmount(0, 18), XdrAsset),
|
|
434
|
+
[ZecChain]: new xchainUtil.AssetCryptoAmount(xchainUtil.baseAmount(1000, 8), ZecAsset),
|
|
432
435
|
};
|
|
433
436
|
}
|
|
434
437
|
/**
|
|
@@ -677,6 +680,8 @@ exports.RuneAsset = RuneAsset;
|
|
|
677
680
|
exports.ThorChain = ThorChain;
|
|
678
681
|
exports.XdrAsset = XdrAsset;
|
|
679
682
|
exports.XdrChain = XdrChain;
|
|
683
|
+
exports.ZecAsset = ZecAsset;
|
|
684
|
+
exports.ZecChain = ZecChain;
|
|
680
685
|
exports.getBaseAmountWithDiffDecimals = getBaseAmountWithDiffDecimals;
|
|
681
686
|
exports.getCryptoAmountWithNotation = getCryptoAmountWithNotation;
|
|
682
687
|
exports.isCacaoAsset = isCacaoAsset;
|
package/lib/utils/const.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ export declare const DashAsset: Asset;
|
|
|
7
7
|
export declare const KujiraAsset: Asset;
|
|
8
8
|
export declare const ArbAsset: Asset;
|
|
9
9
|
export declare const XdrAsset: Asset;
|
|
10
|
+
export declare const ZecAsset: Asset;
|
|
10
11
|
export declare const BtcChain = "BTC";
|
|
11
12
|
export declare const EthChain = "ETH";
|
|
12
13
|
export declare const MayaChain = "MAYA";
|
|
@@ -15,4 +16,5 @@ export declare const DashChain = "DASH";
|
|
|
15
16
|
export declare const KujiraChain = "KUJI";
|
|
16
17
|
export declare const ArbChain = "ARB";
|
|
17
18
|
export declare const XdrChain = "XRD";
|
|
19
|
+
export declare const ZecChain = "ZEC";
|
|
18
20
|
export declare const DEFAULT_MAYACHAIN_DECIMALS = 8;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xchainjs/xchain-mayachain-query",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.4",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Mayachain query module that is responsible for estimating swap calculations and add/remove liquidity for thorchain",
|
|
6
6
|
"keywords": [
|
|
@@ -33,17 +33,17 @@
|
|
|
33
33
|
"postversion": "git push --follow-tags"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@xchainjs/xchain-client": "2.0.
|
|
37
|
-
"@xchainjs/xchain-mayamidgard": "1.0.
|
|
38
|
-
"@xchainjs/xchain-mayamidgard-query": "1.0.
|
|
39
|
-
"@xchainjs/xchain-mayanode": "1.0.
|
|
40
|
-
"@xchainjs/xchain-util": "2.0.
|
|
36
|
+
"@xchainjs/xchain-client": "2.0.2",
|
|
37
|
+
"@xchainjs/xchain-mayamidgard": "1.0.1",
|
|
38
|
+
"@xchainjs/xchain-mayamidgard-query": "1.0.3",
|
|
39
|
+
"@xchainjs/xchain-mayanode": "1.0.1",
|
|
40
|
+
"@xchainjs/xchain-util": "2.0.1",
|
|
41
41
|
"axios": "1.8.4",
|
|
42
42
|
"axios-retry": "3.2.5",
|
|
43
|
-
"bignumber.js": "9.0.0"
|
|
43
|
+
"bignumber.js": "^9.0.0"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
|
-
"axios-mock-adapter": "1.
|
|
46
|
+
"axios-mock-adapter": "2.1.0"
|
|
47
47
|
},
|
|
48
48
|
"publishConfig": {
|
|
49
49
|
"access": "public",
|