@fuel-ts/account 0.94.6 → 0.94.7
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/connectors/fuel-connector.d.ts +1 -0
- package/dist/connectors/fuel-connector.d.ts.map +1 -1
- package/dist/index.global.js +450 -381
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +28 -80
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +28 -80
- package/dist/index.mjs.map +1 -1
- package/dist/providers/__generated__/operations.d.ts +1 -0
- package/dist/providers/__generated__/operations.d.ts.map +1 -1
- package/dist/providers/assets/assets.d.ts.map +1 -1
- package/dist/providers/transaction-summary/receipt.d.ts.map +1 -1
- package/dist/providers/utils/receipts.d.ts.map +1 -1
- package/dist/test-utils.global.js +449 -381
- package/dist/test-utils.global.js.map +1 -1
- package/dist/test-utils.js +27 -80
- package/dist/test-utils.js.map +1 -1
- package/dist/test-utils.mjs +27 -80
- package/dist/test-utils.mjs.map +1 -1
- package/package.json +23 -23
package/dist/test-utils.js
CHANGED
@@ -1828,6 +1828,7 @@ function assembleReceiptByType(receipt) {
|
|
1828
1828
|
len: (0, import_math5.bn)(receipt.len),
|
1829
1829
|
digest: hexOrZero(receipt.digest),
|
1830
1830
|
pc: (0, import_math5.bn)(receipt.pc),
|
1831
|
+
data: hexOrZero(receipt.data),
|
1831
1832
|
is: (0, import_math5.bn)(receipt.is)
|
1832
1833
|
};
|
1833
1834
|
return returnDataReceipt;
|
@@ -1876,6 +1877,7 @@ function assembleReceiptByType(receipt) {
|
|
1876
1877
|
len: (0, import_math5.bn)(receipt.len),
|
1877
1878
|
digest: hexOrZero(receipt.digest),
|
1878
1879
|
pc: (0, import_math5.bn)(receipt.pc),
|
1880
|
+
data: hexOrZero(receipt.data),
|
1879
1881
|
is: (0, import_math5.bn)(receipt.is)
|
1880
1882
|
};
|
1881
1883
|
return logDataReceipt;
|
@@ -1919,6 +1921,7 @@ function assembleReceiptByType(receipt) {
|
|
1919
1921
|
const amount = (0, import_math5.bn)(receipt.amount);
|
1920
1922
|
const data = receipt.data ? (0, import_utils7.arrayify)(receipt.data) : Uint8Array.from([]);
|
1921
1923
|
const digest = hexOrZero(receipt.digest);
|
1924
|
+
const len = (0, import_math5.bn)(receipt.len).toNumber();
|
1922
1925
|
const messageId = import_transactions3.InputMessageCoder.getMessageId({
|
1923
1926
|
sender,
|
1924
1927
|
recipient,
|
@@ -1932,6 +1935,7 @@ function assembleReceiptByType(receipt) {
|
|
1932
1935
|
recipient,
|
1933
1936
|
amount,
|
1934
1937
|
nonce,
|
1938
|
+
len,
|
1935
1939
|
data,
|
1936
1940
|
digest,
|
1937
1941
|
messageId
|
@@ -4137,25 +4141,7 @@ function getOperations({
|
|
4137
4141
|
|
4138
4142
|
// src/providers/transaction-summary/receipt.ts
|
4139
4143
|
var import_transactions18 = require("@fuel-ts/transactions");
|
4140
|
-
var processGqlReceipt = (gqlReceipt) =>
|
4141
|
-
const receipt = assembleReceiptByType(gqlReceipt);
|
4142
|
-
switch (receipt.type) {
|
4143
|
-
case import_transactions18.ReceiptType.ReturnData: {
|
4144
|
-
return {
|
4145
|
-
...receipt,
|
4146
|
-
data: gqlReceipt.data || "0x"
|
4147
|
-
};
|
4148
|
-
}
|
4149
|
-
case import_transactions18.ReceiptType.LogData: {
|
4150
|
-
return {
|
4151
|
-
...receipt,
|
4152
|
-
data: gqlReceipt.data || "0x"
|
4153
|
-
};
|
4154
|
-
}
|
4155
|
-
default:
|
4156
|
-
return receipt;
|
4157
|
-
}
|
4158
|
-
};
|
4144
|
+
var processGqlReceipt = (gqlReceipt) => assembleReceiptByType(gqlReceipt);
|
4159
4145
|
var extractMintedAssetsFromReceipts = (receipts) => {
|
4160
4146
|
const mintedAssets = [];
|
4161
4147
|
receipts.forEach((receipt) => {
|
@@ -6176,7 +6162,7 @@ var rawAssets = [
|
|
6176
6162
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6177
6163
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6178
6164
|
assetId: "0xa38a5a8beeb08d95744bc7f58528073f4052b254def59eba20c99c202b5acaa3",
|
6179
|
-
decimals:
|
6165
|
+
decimals: 9
|
6180
6166
|
}
|
6181
6167
|
]
|
6182
6168
|
},
|
@@ -6196,7 +6182,7 @@ var rawAssets = [
|
|
6196
6182
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6197
6183
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6198
6184
|
assetId: "0x239ed6e12b7ce4089ee245244e3bf906999a6429c2a9a445a1e1faf56914a4ab",
|
6199
|
-
decimals:
|
6185
|
+
decimals: 9
|
6200
6186
|
}
|
6201
6187
|
]
|
6202
6188
|
},
|
@@ -6216,7 +6202,7 @@ var rawAssets = [
|
|
6216
6202
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6217
6203
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6218
6204
|
assetId: "0xbae80f7fb8aa6b90d9b01ef726ec847cc4f59419c4d5f2ea88fec785d1b0e849",
|
6219
|
-
decimals:
|
6205
|
+
decimals: 9
|
6220
6206
|
}
|
6221
6207
|
]
|
6222
6208
|
},
|
@@ -6236,7 +6222,7 @@ var rawAssets = [
|
|
6236
6222
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6237
6223
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6238
6224
|
assetId: "0xf3f9a0ed0ce8eac5f89d6b83e41b3848212d5b5f56108c54a205bb228ca30c16",
|
6239
|
-
decimals:
|
6225
|
+
decimals: 9
|
6240
6226
|
}
|
6241
6227
|
]
|
6242
6228
|
},
|
@@ -6256,7 +6242,7 @@ var rawAssets = [
|
|
6256
6242
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6257
6243
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6258
6244
|
assetId: "0x7843c74bef935e837f2bcf67b5d64ecb46dd53ff86375530b0caf3699e8ffafe",
|
6259
|
-
decimals:
|
6245
|
+
decimals: 9
|
6260
6246
|
}
|
6261
6247
|
]
|
6262
6248
|
},
|
@@ -6276,7 +6262,7 @@ var rawAssets = [
|
|
6276
6262
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6277
6263
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6278
6264
|
assetId: "0x962792286fbc9b1d5860b4551362a12249362c21594c77abf4b3fe2bbe8d977a",
|
6279
|
-
decimals:
|
6265
|
+
decimals: 9
|
6280
6266
|
}
|
6281
6267
|
]
|
6282
6268
|
},
|
@@ -6296,7 +6282,7 @@ var rawAssets = [
|
|
6296
6282
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6297
6283
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6298
6284
|
assetId: "0x05fc623e57bd7bc1258efa8e4f62b05af5471d73df6f2c2dc11ecc81134c4f36",
|
6299
|
-
decimals:
|
6285
|
+
decimals: 9
|
6300
6286
|
}
|
6301
6287
|
]
|
6302
6288
|
},
|
@@ -6316,7 +6302,7 @@ var rawAssets = [
|
|
6316
6302
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6317
6303
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6318
6304
|
assetId: "0xaf3111a248ff7a3238cdeea845bb2d43cf3835f1f6b8c9d28360728b55b9ce5b",
|
6319
|
-
decimals:
|
6305
|
+
decimals: 9
|
6320
6306
|
}
|
6321
6307
|
]
|
6322
6308
|
},
|
@@ -6336,7 +6322,7 @@ var rawAssets = [
|
|
6336
6322
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6337
6323
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6338
6324
|
assetId: "0xafd219f513317b1750783c6581f55530d6cf189a5863fd18bd1b3ffcec1714b4",
|
6339
|
-
decimals:
|
6325
|
+
decimals: 9
|
6340
6326
|
}
|
6341
6327
|
]
|
6342
6328
|
},
|
@@ -6356,7 +6342,7 @@ var rawAssets = [
|
|
6356
6342
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6357
6343
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6358
6344
|
assetId: "0x89cb9401e55d49c3269654dd1cdfb0e80e57823a4a7db98ba8fc5953b120fef4",
|
6359
|
-
decimals:
|
6345
|
+
decimals: 9
|
6360
6346
|
}
|
6361
6347
|
]
|
6362
6348
|
},
|
@@ -6416,7 +6402,7 @@ var rawAssets = [
|
|
6416
6402
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6417
6403
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6418
6404
|
assetId: "0x1186afea9affb88809c210e13e2330b5258c2cef04bb8fff5eff372b7bd3f40f",
|
6419
|
-
decimals:
|
6405
|
+
decimals: 9
|
6420
6406
|
}
|
6421
6407
|
]
|
6422
6408
|
},
|
@@ -6436,7 +6422,7 @@ var rawAssets = [
|
|
6436
6422
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6437
6423
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6438
6424
|
assetId: "0x7a4f087c957d30218223c2baaaa365355c9ca81b6ea49004cfb1590a5399216f",
|
6439
|
-
decimals:
|
6425
|
+
decimals: 9
|
6440
6426
|
}
|
6441
6427
|
]
|
6442
6428
|
},
|
@@ -6456,7 +6442,7 @@ var rawAssets = [
|
|
6456
6442
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6457
6443
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6458
6444
|
assetId: "0x642a5db59ec323c2f846d4d4cf3e58d78aff64accf4f8f6455ba0aa3ef000a3b",
|
6459
|
-
decimals:
|
6445
|
+
decimals: 9
|
6460
6446
|
}
|
6461
6447
|
]
|
6462
6448
|
},
|
@@ -6476,7 +6462,7 @@ var rawAssets = [
|
|
6476
6462
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6477
6463
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6478
6464
|
assetId: "0x9e46f919fbf978f3cad7cd34cca982d5613af63ff8aab6c379e4faa179552958",
|
6479
|
-
decimals:
|
6465
|
+
decimals: 9
|
6480
6466
|
}
|
6481
6467
|
]
|
6482
6468
|
},
|
@@ -6531,25 +6517,12 @@ var rawAssets = [
|
|
6531
6517
|
address: "0x4c9edd5852cd905f086c759e8383e09bff1e68b3",
|
6532
6518
|
decimals: 18
|
6533
6519
|
},
|
6534
|
-
{
|
6535
|
-
type: "ethereum",
|
6536
|
-
chainId: CHAIN_IDS.eth.sepolia,
|
6537
|
-
address: "0xc6387efad0f184a90b34f397c3d6fd63135ef790",
|
6538
|
-
decimals: 18
|
6539
|
-
},
|
6540
6520
|
{
|
6541
6521
|
type: "fuel",
|
6542
6522
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6543
6523
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6544
6524
|
assetId: "0xb6133b2ef9f6153eb869125d23dcf20d1e735331b5e41b15a6a7a6cec70e8651",
|
6545
|
-
decimals:
|
6546
|
-
},
|
6547
|
-
{
|
6548
|
-
type: "fuel",
|
6549
|
-
chainId: CHAIN_IDS.fuel.testnet,
|
6550
|
-
contractId: "0xC6387efAD0F184a90B34f397C3d6Fd63135ef790",
|
6551
|
-
assetId: "0xf5c6d72d0f2c782fa47d8e228c198a08654e9fc66ca60ad85902b1d09046a7ab",
|
6552
|
-
decimals: 18
|
6525
|
+
decimals: 9
|
6553
6526
|
}
|
6554
6527
|
]
|
6555
6528
|
},
|
@@ -6564,25 +6537,12 @@ var rawAssets = [
|
|
6564
6537
|
address: "0x9d39a5de30e57443bff2a8307a4256c8797a3497",
|
6565
6538
|
decimals: 18
|
6566
6539
|
},
|
6567
|
-
{
|
6568
|
-
type: "ethereum",
|
6569
|
-
chainId: CHAIN_IDS.eth.sepolia,
|
6570
|
-
address: "0xb8f4f4eafc1d2a3c0a4d519bbf1114c311cc9b1b",
|
6571
|
-
decimals: 18
|
6572
|
-
},
|
6573
6540
|
{
|
6574
6541
|
type: "fuel",
|
6575
6542
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6576
6543
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6577
6544
|
assetId: "0xd05563025104fc36496c15c7021ad6b31034b0e89a356f4f818045d1f48808bc",
|
6578
|
-
decimals:
|
6579
|
-
},
|
6580
|
-
{
|
6581
|
-
type: "fuel",
|
6582
|
-
chainId: CHAIN_IDS.fuel.testnet,
|
6583
|
-
contractId: "0xC6387efAD0F184a90B34f397C3d6Fd63135ef790",
|
6584
|
-
assetId: "0xa86e37d385c08beddbb02c8260f9ec535d484c8ea908fc19d4e6dc8d5141fb2e",
|
6585
|
-
decimals: 18
|
6545
|
+
decimals: 9
|
6586
6546
|
}
|
6587
6547
|
]
|
6588
6548
|
},
|
@@ -6602,7 +6562,7 @@ var rawAssets = [
|
|
6602
6562
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6603
6563
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6604
6564
|
assetId: "0x78d4522ec607f6e8efb66ea49439d1ee48623cf763f9688a8eada025def033d9",
|
6605
|
-
decimals:
|
6565
|
+
decimals: 9
|
6606
6566
|
}
|
6607
6567
|
]
|
6608
6568
|
},
|
@@ -6617,25 +6577,12 @@ var rawAssets = [
|
|
6617
6577
|
address: "0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0",
|
6618
6578
|
decimals: 18
|
6619
6579
|
},
|
6620
|
-
{
|
6621
|
-
type: "ethereum",
|
6622
|
-
chainId: CHAIN_IDS.eth.sepolia,
|
6623
|
-
address: "0xB82381A3fBD3FaFA77B3a7bE693342618240067b",
|
6624
|
-
decimals: 18
|
6625
|
-
},
|
6626
6580
|
{
|
6627
6581
|
type: "fuel",
|
6628
6582
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6629
6583
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6630
6584
|
assetId: "0x1a7815cc9f75db5c24a5b0814bfb706bb9fe485333e98254015de8f48f84c67b",
|
6631
|
-
decimals:
|
6632
|
-
},
|
6633
|
-
{
|
6634
|
-
type: "fuel",
|
6635
|
-
chainId: CHAIN_IDS.fuel.testnet,
|
6636
|
-
contractId: "0xC6387efAD0F184a90B34f397C3d6Fd63135ef790",
|
6637
|
-
assetId: "0x4c467e3fd4f32179e1aad3b92ebbdaa6ff6aeda5b8da5f8e64e96405eb52a7f5",
|
6638
|
-
decimals: 18
|
6585
|
+
decimals: 9
|
6639
6586
|
}
|
6640
6587
|
]
|
6641
6588
|
},
|
@@ -6655,7 +6602,7 @@ var rawAssets = [
|
|
6655
6602
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6656
6603
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6657
6604
|
assetId: "0x91b3559edb2619cde8ffb2aa7b3c3be97efd794ea46700db7092abeee62281b0",
|
6658
|
-
decimals:
|
6605
|
+
decimals: 9
|
6659
6606
|
}
|
6660
6607
|
]
|
6661
6608
|
},
|
@@ -6675,7 +6622,7 @@ var rawAssets = [
|
|
6675
6622
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6676
6623
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6677
6624
|
assetId: "0x1493d4ec82124de8f9b625682de69dcccda79e882b89a55a8c737b12de67bd68",
|
6678
|
-
decimals:
|
6625
|
+
decimals: 9
|
6679
6626
|
}
|
6680
6627
|
]
|
6681
6628
|
},
|
@@ -6695,7 +6642,7 @@ var rawAssets = [
|
|
6695
6642
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6696
6643
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6697
6644
|
assetId: "0xf2fc648c23a5db24610a1cf696acc4f0f6d9a7d6028dd9944964ab23f6e35995",
|
6698
|
-
decimals:
|
6645
|
+
decimals: 9
|
6699
6646
|
}
|
6700
6647
|
]
|
6701
6648
|
},
|
@@ -6715,7 +6662,7 @@ var rawAssets = [
|
|
6715
6662
|
chainId: CHAIN_IDS.fuel.mainnet,
|
6716
6663
|
contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
|
6717
6664
|
assetId: "0x4fc8ac9f101df07e2c2dec4a53c8c42c439bdbe5e36ea2d863a61ff60afafc30",
|
6718
|
-
decimals:
|
6665
|
+
decimals: 9
|
6719
6666
|
}
|
6720
6667
|
]
|
6721
6668
|
}
|