@fuel-ts/account 0.94.6 → 0.94.8

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.js CHANGED
@@ -1679,6 +1679,7 @@ function assembleReceiptByType(receipt) {
1679
1679
  len: (0, import_math4.bn)(receipt.len),
1680
1680
  digest: hexOrZero(receipt.digest),
1681
1681
  pc: (0, import_math4.bn)(receipt.pc),
1682
+ data: hexOrZero(receipt.data),
1682
1683
  is: (0, import_math4.bn)(receipt.is)
1683
1684
  };
1684
1685
  return returnDataReceipt;
@@ -1727,6 +1728,7 @@ function assembleReceiptByType(receipt) {
1727
1728
  len: (0, import_math4.bn)(receipt.len),
1728
1729
  digest: hexOrZero(receipt.digest),
1729
1730
  pc: (0, import_math4.bn)(receipt.pc),
1731
+ data: hexOrZero(receipt.data),
1730
1732
  is: (0, import_math4.bn)(receipt.is)
1731
1733
  };
1732
1734
  return logDataReceipt;
@@ -1770,6 +1772,7 @@ function assembleReceiptByType(receipt) {
1770
1772
  const amount = (0, import_math4.bn)(receipt.amount);
1771
1773
  const data = receipt.data ? (0, import_utils5.arrayify)(receipt.data) : Uint8Array.from([]);
1772
1774
  const digest = hexOrZero(receipt.digest);
1775
+ const len = (0, import_math4.bn)(receipt.len).toNumber();
1773
1776
  const messageId = import_transactions3.InputMessageCoder.getMessageId({
1774
1777
  sender,
1775
1778
  recipient,
@@ -1783,6 +1786,7 @@ function assembleReceiptByType(receipt) {
1783
1786
  recipient,
1784
1787
  amount,
1785
1788
  nonce,
1789
+ len,
1786
1790
  data,
1787
1791
  digest,
1788
1792
  messageId
@@ -4126,25 +4130,7 @@ function getOperations({
4126
4130
 
4127
4131
  // src/providers/transaction-summary/receipt.ts
4128
4132
  var import_transactions18 = require("@fuel-ts/transactions");
4129
- var processGqlReceipt = (gqlReceipt) => {
4130
- const receipt = assembleReceiptByType(gqlReceipt);
4131
- switch (receipt.type) {
4132
- case import_transactions18.ReceiptType.ReturnData: {
4133
- return {
4134
- ...receipt,
4135
- data: gqlReceipt.data || "0x"
4136
- };
4137
- }
4138
- case import_transactions18.ReceiptType.LogData: {
4139
- return {
4140
- ...receipt,
4141
- data: gqlReceipt.data || "0x"
4142
- };
4143
- }
4144
- default:
4145
- return receipt;
4146
- }
4147
- };
4133
+ var processGqlReceipt = (gqlReceipt) => assembleReceiptByType(gqlReceipt);
4148
4134
  var extractMintedAssetsFromReceipts = (receipts) => {
4149
4135
  const mintedAssets = [];
4150
4136
  receipts.forEach((receipt) => {
@@ -6339,7 +6325,7 @@ var rawAssets = [
6339
6325
  chainId: CHAIN_IDS.fuel.mainnet,
6340
6326
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6341
6327
  assetId: "0xa38a5a8beeb08d95744bc7f58528073f4052b254def59eba20c99c202b5acaa3",
6342
- decimals: 18
6328
+ decimals: 9
6343
6329
  }
6344
6330
  ]
6345
6331
  },
@@ -6359,7 +6345,7 @@ var rawAssets = [
6359
6345
  chainId: CHAIN_IDS.fuel.mainnet,
6360
6346
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6361
6347
  assetId: "0x239ed6e12b7ce4089ee245244e3bf906999a6429c2a9a445a1e1faf56914a4ab",
6362
- decimals: 18
6348
+ decimals: 9
6363
6349
  }
6364
6350
  ]
6365
6351
  },
@@ -6379,7 +6365,7 @@ var rawAssets = [
6379
6365
  chainId: CHAIN_IDS.fuel.mainnet,
6380
6366
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6381
6367
  assetId: "0xbae80f7fb8aa6b90d9b01ef726ec847cc4f59419c4d5f2ea88fec785d1b0e849",
6382
- decimals: 18
6368
+ decimals: 9
6383
6369
  }
6384
6370
  ]
6385
6371
  },
@@ -6399,7 +6385,7 @@ var rawAssets = [
6399
6385
  chainId: CHAIN_IDS.fuel.mainnet,
6400
6386
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6401
6387
  assetId: "0xf3f9a0ed0ce8eac5f89d6b83e41b3848212d5b5f56108c54a205bb228ca30c16",
6402
- decimals: 18
6388
+ decimals: 9
6403
6389
  }
6404
6390
  ]
6405
6391
  },
@@ -6419,7 +6405,7 @@ var rawAssets = [
6419
6405
  chainId: CHAIN_IDS.fuel.mainnet,
6420
6406
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6421
6407
  assetId: "0x7843c74bef935e837f2bcf67b5d64ecb46dd53ff86375530b0caf3699e8ffafe",
6422
- decimals: 18
6408
+ decimals: 9
6423
6409
  }
6424
6410
  ]
6425
6411
  },
@@ -6439,7 +6425,7 @@ var rawAssets = [
6439
6425
  chainId: CHAIN_IDS.fuel.mainnet,
6440
6426
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6441
6427
  assetId: "0x962792286fbc9b1d5860b4551362a12249362c21594c77abf4b3fe2bbe8d977a",
6442
- decimals: 18
6428
+ decimals: 9
6443
6429
  }
6444
6430
  ]
6445
6431
  },
@@ -6459,7 +6445,7 @@ var rawAssets = [
6459
6445
  chainId: CHAIN_IDS.fuel.mainnet,
6460
6446
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6461
6447
  assetId: "0x05fc623e57bd7bc1258efa8e4f62b05af5471d73df6f2c2dc11ecc81134c4f36",
6462
- decimals: 18
6448
+ decimals: 9
6463
6449
  }
6464
6450
  ]
6465
6451
  },
@@ -6479,7 +6465,7 @@ var rawAssets = [
6479
6465
  chainId: CHAIN_IDS.fuel.mainnet,
6480
6466
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6481
6467
  assetId: "0xaf3111a248ff7a3238cdeea845bb2d43cf3835f1f6b8c9d28360728b55b9ce5b",
6482
- decimals: 18
6468
+ decimals: 9
6483
6469
  }
6484
6470
  ]
6485
6471
  },
@@ -6499,7 +6485,7 @@ var rawAssets = [
6499
6485
  chainId: CHAIN_IDS.fuel.mainnet,
6500
6486
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6501
6487
  assetId: "0xafd219f513317b1750783c6581f55530d6cf189a5863fd18bd1b3ffcec1714b4",
6502
- decimals: 18
6488
+ decimals: 9
6503
6489
  }
6504
6490
  ]
6505
6491
  },
@@ -6519,7 +6505,7 @@ var rawAssets = [
6519
6505
  chainId: CHAIN_IDS.fuel.mainnet,
6520
6506
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6521
6507
  assetId: "0x89cb9401e55d49c3269654dd1cdfb0e80e57823a4a7db98ba8fc5953b120fef4",
6522
- decimals: 18
6508
+ decimals: 9
6523
6509
  }
6524
6510
  ]
6525
6511
  },
@@ -6579,7 +6565,7 @@ var rawAssets = [
6579
6565
  chainId: CHAIN_IDS.fuel.mainnet,
6580
6566
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6581
6567
  assetId: "0x1186afea9affb88809c210e13e2330b5258c2cef04bb8fff5eff372b7bd3f40f",
6582
- decimals: 18
6568
+ decimals: 9
6583
6569
  }
6584
6570
  ]
6585
6571
  },
@@ -6599,7 +6585,7 @@ var rawAssets = [
6599
6585
  chainId: CHAIN_IDS.fuel.mainnet,
6600
6586
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6601
6587
  assetId: "0x7a4f087c957d30218223c2baaaa365355c9ca81b6ea49004cfb1590a5399216f",
6602
- decimals: 18
6588
+ decimals: 9
6603
6589
  }
6604
6590
  ]
6605
6591
  },
@@ -6619,7 +6605,7 @@ var rawAssets = [
6619
6605
  chainId: CHAIN_IDS.fuel.mainnet,
6620
6606
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6621
6607
  assetId: "0x642a5db59ec323c2f846d4d4cf3e58d78aff64accf4f8f6455ba0aa3ef000a3b",
6622
- decimals: 18
6608
+ decimals: 9
6623
6609
  }
6624
6610
  ]
6625
6611
  },
@@ -6639,7 +6625,7 @@ var rawAssets = [
6639
6625
  chainId: CHAIN_IDS.fuel.mainnet,
6640
6626
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6641
6627
  assetId: "0x9e46f919fbf978f3cad7cd34cca982d5613af63ff8aab6c379e4faa179552958",
6642
- decimals: 18
6628
+ decimals: 9
6643
6629
  }
6644
6630
  ]
6645
6631
  },
@@ -6694,25 +6680,12 @@ var rawAssets = [
6694
6680
  address: "0x4c9edd5852cd905f086c759e8383e09bff1e68b3",
6695
6681
  decimals: 18
6696
6682
  },
6697
- {
6698
- type: "ethereum",
6699
- chainId: CHAIN_IDS.eth.sepolia,
6700
- address: "0xc6387efad0f184a90b34f397c3d6fd63135ef790",
6701
- decimals: 18
6702
- },
6703
6683
  {
6704
6684
  type: "fuel",
6705
6685
  chainId: CHAIN_IDS.fuel.mainnet,
6706
6686
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6707
6687
  assetId: "0xb6133b2ef9f6153eb869125d23dcf20d1e735331b5e41b15a6a7a6cec70e8651",
6708
- decimals: 18
6709
- },
6710
- {
6711
- type: "fuel",
6712
- chainId: CHAIN_IDS.fuel.testnet,
6713
- contractId: "0xC6387efAD0F184a90B34f397C3d6Fd63135ef790",
6714
- assetId: "0xf5c6d72d0f2c782fa47d8e228c198a08654e9fc66ca60ad85902b1d09046a7ab",
6715
- decimals: 18
6688
+ decimals: 9
6716
6689
  }
6717
6690
  ]
6718
6691
  },
@@ -6727,25 +6700,12 @@ var rawAssets = [
6727
6700
  address: "0x9d39a5de30e57443bff2a8307a4256c8797a3497",
6728
6701
  decimals: 18
6729
6702
  },
6730
- {
6731
- type: "ethereum",
6732
- chainId: CHAIN_IDS.eth.sepolia,
6733
- address: "0xb8f4f4eafc1d2a3c0a4d519bbf1114c311cc9b1b",
6734
- decimals: 18
6735
- },
6736
6703
  {
6737
6704
  type: "fuel",
6738
6705
  chainId: CHAIN_IDS.fuel.mainnet,
6739
6706
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6740
6707
  assetId: "0xd05563025104fc36496c15c7021ad6b31034b0e89a356f4f818045d1f48808bc",
6741
- decimals: 18
6742
- },
6743
- {
6744
- type: "fuel",
6745
- chainId: CHAIN_IDS.fuel.testnet,
6746
- contractId: "0xC6387efAD0F184a90B34f397C3d6Fd63135ef790",
6747
- assetId: "0xa86e37d385c08beddbb02c8260f9ec535d484c8ea908fc19d4e6dc8d5141fb2e",
6748
- decimals: 18
6708
+ decimals: 9
6749
6709
  }
6750
6710
  ]
6751
6711
  },
@@ -6765,7 +6725,7 @@ var rawAssets = [
6765
6725
  chainId: CHAIN_IDS.fuel.mainnet,
6766
6726
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6767
6727
  assetId: "0x78d4522ec607f6e8efb66ea49439d1ee48623cf763f9688a8eada025def033d9",
6768
- decimals: 18
6728
+ decimals: 9
6769
6729
  }
6770
6730
  ]
6771
6731
  },
@@ -6780,25 +6740,12 @@ var rawAssets = [
6780
6740
  address: "0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0",
6781
6741
  decimals: 18
6782
6742
  },
6783
- {
6784
- type: "ethereum",
6785
- chainId: CHAIN_IDS.eth.sepolia,
6786
- address: "0xB82381A3fBD3FaFA77B3a7bE693342618240067b",
6787
- decimals: 18
6788
- },
6789
6743
  {
6790
6744
  type: "fuel",
6791
6745
  chainId: CHAIN_IDS.fuel.mainnet,
6792
6746
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6793
6747
  assetId: "0x1a7815cc9f75db5c24a5b0814bfb706bb9fe485333e98254015de8f48f84c67b",
6794
- decimals: 18
6795
- },
6796
- {
6797
- type: "fuel",
6798
- chainId: CHAIN_IDS.fuel.testnet,
6799
- contractId: "0xC6387efAD0F184a90B34f397C3d6Fd63135ef790",
6800
- assetId: "0x4c467e3fd4f32179e1aad3b92ebbdaa6ff6aeda5b8da5f8e64e96405eb52a7f5",
6801
- decimals: 18
6748
+ decimals: 9
6802
6749
  }
6803
6750
  ]
6804
6751
  },
@@ -6818,7 +6765,7 @@ var rawAssets = [
6818
6765
  chainId: CHAIN_IDS.fuel.mainnet,
6819
6766
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6820
6767
  assetId: "0x91b3559edb2619cde8ffb2aa7b3c3be97efd794ea46700db7092abeee62281b0",
6821
- decimals: 18
6768
+ decimals: 9
6822
6769
  }
6823
6770
  ]
6824
6771
  },
@@ -6838,7 +6785,7 @@ var rawAssets = [
6838
6785
  chainId: CHAIN_IDS.fuel.mainnet,
6839
6786
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6840
6787
  assetId: "0x1493d4ec82124de8f9b625682de69dcccda79e882b89a55a8c737b12de67bd68",
6841
- decimals: 18
6788
+ decimals: 9
6842
6789
  }
6843
6790
  ]
6844
6791
  },
@@ -6858,7 +6805,7 @@ var rawAssets = [
6858
6805
  chainId: CHAIN_IDS.fuel.mainnet,
6859
6806
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6860
6807
  assetId: "0xf2fc648c23a5db24610a1cf696acc4f0f6d9a7d6028dd9944964ab23f6e35995",
6861
- decimals: 18
6808
+ decimals: 9
6862
6809
  }
6863
6810
  ]
6864
6811
  },
@@ -6878,7 +6825,7 @@ var rawAssets = [
6878
6825
  chainId: CHAIN_IDS.fuel.mainnet,
6879
6826
  contractId: "0x4ea6ccef1215d9479f1024dff70fc055ca538215d2c8c348beddffd54583d0e8",
6880
6827
  assetId: "0x4fc8ac9f101df07e2c2dec4a53c8c42c439bdbe5e36ea2d863a61ff60afafc30",
6881
- decimals: 18
6828
+ decimals: 9
6882
6829
  }
6883
6830
  ]
6884
6831
  }
@@ -11218,6 +11165,7 @@ var FuelConnector = class extends import_events2.EventEmitter {
11218
11165
  metadata = {};
11219
11166
  connected = false;
11220
11167
  installed = false;
11168
+ external = true;
11221
11169
  events = FuelConnectorEventTypes;
11222
11170
  /**
11223
11171
  * Should return true if the connector is loaded