@paraspell/assets 11.5.0 → 11.5.1
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/index.cjs +9 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.mjs +9 -2
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -18336,7 +18336,14 @@ var isAssetEqual = function isAssetEqual(asset1, asset2) {
|
|
|
18336
18336
|
var ml2 = asset2.location;
|
|
18337
18337
|
if (ml1 && ml2 && sdkCommon.deepEqual(ml1, ml2)) return true;
|
|
18338
18338
|
if (isForeignAsset(asset1) && isForeignAsset(asset2) && asset1.assetId === asset2.assetId) return true;
|
|
18339
|
-
return asset1.symbol
|
|
18339
|
+
return isSymbolMatch(asset1.symbol, asset2.symbol);
|
|
18340
|
+
};
|
|
18341
|
+
|
|
18342
|
+
var isAssetXcEqual = function isAssetXcEqual(asset1, asset2) {
|
|
18343
|
+
var ml1 = asset1.location;
|
|
18344
|
+
var ml2 = asset2.location;
|
|
18345
|
+
if (ml1 && ml2 && sdkCommon.deepEqual(ml1, ml2)) return true;
|
|
18346
|
+
return isSymbolMatch(asset1.symbol, asset2.symbol);
|
|
18340
18347
|
};
|
|
18341
18348
|
|
|
18342
18349
|
exports.DuplicateAssetError = DuplicateAssetError;
|
|
@@ -18380,6 +18387,7 @@ exports.hasDryRunSupport = hasDryRunSupport;
|
|
|
18380
18387
|
exports.hasSupportForAsset = hasSupportForAsset;
|
|
18381
18388
|
exports.hasXcmPaymentApiSupport = hasXcmPaymentApiSupport;
|
|
18382
18389
|
exports.isAssetEqual = isAssetEqual;
|
|
18390
|
+
exports.isAssetXcEqual = isAssetXcEqual;
|
|
18383
18391
|
exports.isChainEvm = isChainEvm;
|
|
18384
18392
|
exports.isForeignAsset = isForeignAsset;
|
|
18385
18393
|
exports.isOverrideLocationSpecifier = isOverrideLocationSpecifier;
|
package/dist/index.d.ts
CHANGED
|
@@ -203,6 +203,8 @@ declare const getSupportedDestinations: (origin: TChain, currency: TCurrencyCore
|
|
|
203
203
|
|
|
204
204
|
declare const isAssetEqual: (asset1: TAssetInfo, asset2: TAssetInfo) => boolean;
|
|
205
205
|
|
|
206
|
+
declare const isAssetXcEqual: (asset1: TAssetInfo, asset2: TAssetInfo) => boolean;
|
|
207
|
+
|
|
206
208
|
declare const isSymbolMatch: (symbolA: string, symbolB: string) => boolean;
|
|
207
209
|
|
|
208
210
|
/**
|
|
@@ -295,5 +297,5 @@ declare const extractAssetLocation: <T = bigint>(asset: TAsset<T>) => TLocation;
|
|
|
295
297
|
|
|
296
298
|
declare const getAssetLocation: (chain: TChain, currency: TCurrencyInput) => TLocation | null;
|
|
297
299
|
|
|
298
|
-
export { DuplicateAssetError, DuplicateAssetIdError, Foreign, ForeignAbstract, InvalidCurrencyError, Native, Override, assertEdDefined, compareLocations, extractAssetLocation, filterEthCompatibleAssets, findAssetInfo, findAssetInfoById, findAssetInfoByLoc, findAssetInfoBySymbol, findAssetInfoOnDest, findAssetInfoOrThrow, findAssetOnDestOrThrow, findBestMatches, findNativeAssetInfo, findNativeAssetInfoOrThrow, getAllAssetsSymbols, getAssetDecimals, getAssetId, getAssetLocation, getAssets, getAssetsObject, getEdFromAssetOrThrow, getExistentialDeposit, getExistentialDepositOrThrow, getFeeAssets, getNativeAssetSymbol, getNativeAssets, getOtherAssets, getRelayChainSymbol, getSupportedAssets, getSupportedDestinations, hasDryRunSupport, hasSupportForAsset, hasXcmPaymentApiSupport, isAssetEqual, isChainEvm, isForeignAsset, isOverrideLocationSpecifier, isSymbolMatch, isSymbolSpecifier, isTAsset, normalizeLocation, normalizeSymbol };
|
|
300
|
+
export { DuplicateAssetError, DuplicateAssetIdError, Foreign, ForeignAbstract, InvalidCurrencyError, Native, Override, assertEdDefined, compareLocations, extractAssetLocation, filterEthCompatibleAssets, findAssetInfo, findAssetInfoById, findAssetInfoByLoc, findAssetInfoBySymbol, findAssetInfoOnDest, findAssetInfoOrThrow, findAssetOnDestOrThrow, findBestMatches, findNativeAssetInfo, findNativeAssetInfoOrThrow, getAllAssetsSymbols, getAssetDecimals, getAssetId, getAssetLocation, getAssets, getAssetsObject, getEdFromAssetOrThrow, getExistentialDeposit, getExistentialDepositOrThrow, getFeeAssets, getNativeAssetSymbol, getNativeAssets, getOtherAssets, getRelayChainSymbol, getSupportedAssets, getSupportedDestinations, hasDryRunSupport, hasSupportForAsset, hasXcmPaymentApiSupport, isAssetEqual, isAssetXcEqual, isChainEvm, isForeignAsset, isOverrideLocationSpecifier, isSymbolMatch, isSymbolSpecifier, isTAsset, normalizeLocation, normalizeSymbol };
|
|
299
301
|
export type { TAmount, TAsset, TAssetInfo, TAssetJsonMap, TAssetV3, TAssetV4, TAssetWithFee, TAssetWithLocation, TChainAssetsInfo, TCurrency, TCurrencyCore, TCurrencyInput, TCurrencyInputWithAmount, TCurrencySymbol, TCurrencySymbolValue, TForeignAssetInfo, TForeignAssetWithId, TLocationValue, TLocationValueWithOverride, TNativeAssetInfo, TOverrideLocationSpecifier, TSymbolSpecifier, WithAmount, WithComplexAmount };
|
package/dist/index.mjs
CHANGED
|
@@ -18334,7 +18334,14 @@ var isAssetEqual = function isAssetEqual(asset1, asset2) {
|
|
|
18334
18334
|
var ml2 = asset2.location;
|
|
18335
18335
|
if (ml1 && ml2 && deepEqual(ml1, ml2)) return true;
|
|
18336
18336
|
if (isForeignAsset(asset1) && isForeignAsset(asset2) && asset1.assetId === asset2.assetId) return true;
|
|
18337
|
-
return asset1.symbol
|
|
18337
|
+
return isSymbolMatch(asset1.symbol, asset2.symbol);
|
|
18338
18338
|
};
|
|
18339
18339
|
|
|
18340
|
-
|
|
18340
|
+
var isAssetXcEqual = function isAssetXcEqual(asset1, asset2) {
|
|
18341
|
+
var ml1 = asset1.location;
|
|
18342
|
+
var ml2 = asset2.location;
|
|
18343
|
+
if (ml1 && ml2 && deepEqual(ml1, ml2)) return true;
|
|
18344
|
+
return isSymbolMatch(asset1.symbol, asset2.symbol);
|
|
18345
|
+
};
|
|
18346
|
+
|
|
18347
|
+
export { DuplicateAssetError, DuplicateAssetIdError, Foreign, ForeignAbstract, InvalidCurrencyError, Native, Override, assertEdDefined, compareLocations, extractAssetLocation, filterEthCompatibleAssets, findAssetInfo, findAssetInfoById, findAssetInfoByLoc, findAssetInfoBySymbol, findAssetInfoOnDest, findAssetInfoOrThrow, findAssetOnDestOrThrow, findBestMatches, findNativeAssetInfo, findNativeAssetInfoOrThrow, getAllAssetsSymbols, getAssetDecimals, getAssetId, getAssetLocation, getAssets, getAssetsObject, getEdFromAssetOrThrow, getExistentialDeposit, getExistentialDepositOrThrow, getFeeAssets, getNativeAssetSymbol, getNativeAssets, getOtherAssets, getRelayChainSymbol, getSupportedAssets, getSupportedDestinations, hasDryRunSupport, hasSupportForAsset, hasXcmPaymentApiSupport, isAssetEqual, isAssetXcEqual, isChainEvm, isForeignAsset, isOverrideLocationSpecifier, isSymbolMatch, isSymbolSpecifier, isTAsset, normalizeLocation, normalizeSymbol };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@paraspell/assets",
|
|
3
|
-
"version": "11.5.
|
|
3
|
+
"version": "11.5.1",
|
|
4
4
|
"description": "Assets for ParaSpell XCM/XCMP tool for developers",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"dist"
|
|
24
24
|
],
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@paraspell/sdk-common": "11.5.
|
|
26
|
+
"@paraspell/sdk-common": "11.5.1"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"@babel/plugin-syntax-import-attributes": "^7.27.1",
|