@metamask/transaction-controller 40.1.0 → 41.1.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.
Files changed (67) hide show
  1. package/CHANGELOG.md +50 -1
  2. package/README.md +4 -0
  3. package/dist/TransactionController.cjs +116 -227
  4. package/dist/TransactionController.cjs.map +1 -1
  5. package/dist/TransactionController.d.cts +34 -52
  6. package/dist/TransactionController.d.cts.map +1 -1
  7. package/dist/TransactionController.d.mts +34 -52
  8. package/dist/TransactionController.d.mts.map +1 -1
  9. package/dist/TransactionController.mjs +119 -232
  10. package/dist/TransactionController.mjs.map +1 -1
  11. package/dist/gas-flows/OracleLayer1GasFeeFlow.mjs +1 -2
  12. package/dist/gas-flows/OracleLayer1GasFeeFlow.mjs.map +1 -1
  13. package/dist/helpers/EtherscanRemoteTransactionSource.cjs +13 -12
  14. package/dist/helpers/EtherscanRemoteTransactionSource.cjs.map +1 -1
  15. package/dist/helpers/EtherscanRemoteTransactionSource.d.cts.map +1 -1
  16. package/dist/helpers/EtherscanRemoteTransactionSource.d.mts.map +1 -1
  17. package/dist/helpers/EtherscanRemoteTransactionSource.mjs +13 -12
  18. package/dist/helpers/EtherscanRemoteTransactionSource.mjs.map +1 -1
  19. package/dist/helpers/GasFeePoller.cjs +6 -4
  20. package/dist/helpers/GasFeePoller.cjs.map +1 -1
  21. package/dist/helpers/GasFeePoller.d.cts +1 -1
  22. package/dist/helpers/GasFeePoller.d.cts.map +1 -1
  23. package/dist/helpers/GasFeePoller.d.mts +1 -1
  24. package/dist/helpers/GasFeePoller.d.mts.map +1 -1
  25. package/dist/helpers/GasFeePoller.mjs +6 -4
  26. package/dist/helpers/GasFeePoller.mjs.map +1 -1
  27. package/dist/helpers/IncomingTransactionHelper.cjs +20 -11
  28. package/dist/helpers/IncomingTransactionHelper.cjs.map +1 -1
  29. package/dist/helpers/IncomingTransactionHelper.d.cts.map +1 -1
  30. package/dist/helpers/IncomingTransactionHelper.d.mts.map +1 -1
  31. package/dist/helpers/IncomingTransactionHelper.mjs +21 -12
  32. package/dist/helpers/IncomingTransactionHelper.mjs.map +1 -1
  33. package/dist/helpers/MethodDataHelper.cjs +80 -0
  34. package/dist/helpers/MethodDataHelper.cjs.map +1 -0
  35. package/dist/helpers/MethodDataHelper.d.cts +14 -0
  36. package/dist/helpers/MethodDataHelper.d.cts.map +1 -0
  37. package/dist/helpers/MethodDataHelper.d.mts +14 -0
  38. package/dist/helpers/MethodDataHelper.d.mts.map +1 -0
  39. package/dist/helpers/MethodDataHelper.mjs +73 -0
  40. package/dist/helpers/MethodDataHelper.mjs.map +1 -0
  41. package/dist/helpers/MultichainTrackingHelper.cjs +87 -104
  42. package/dist/helpers/MultichainTrackingHelper.cjs.map +1 -1
  43. package/dist/helpers/MultichainTrackingHelper.d.cts +16 -22
  44. package/dist/helpers/MultichainTrackingHelper.d.cts.map +1 -1
  45. package/dist/helpers/MultichainTrackingHelper.d.mts +16 -22
  46. package/dist/helpers/MultichainTrackingHelper.d.mts.map +1 -1
  47. package/dist/helpers/MultichainTrackingHelper.mjs +88 -109
  48. package/dist/helpers/MultichainTrackingHelper.mjs.map +1 -1
  49. package/dist/helpers/PendingTransactionTracker.cjs +26 -22
  50. package/dist/helpers/PendingTransactionTracker.cjs.map +1 -1
  51. package/dist/helpers/PendingTransactionTracker.d.cts.map +1 -1
  52. package/dist/helpers/PendingTransactionTracker.d.mts.map +1 -1
  53. package/dist/helpers/PendingTransactionTracker.mjs +26 -22
  54. package/dist/helpers/PendingTransactionTracker.mjs.map +1 -1
  55. package/dist/types.cjs.map +1 -1
  56. package/dist/types.d.cts +7 -3
  57. package/dist/types.d.cts.map +1 -1
  58. package/dist/types.d.mts +7 -3
  59. package/dist/types.d.mts.map +1 -1
  60. package/dist/types.mjs.map +1 -1
  61. package/dist/utils/etherscan.cjs +2 -1
  62. package/dist/utils/etherscan.cjs.map +1 -1
  63. package/dist/utils/etherscan.d.cts.map +1 -1
  64. package/dist/utils/etherscan.d.mts.map +1 -1
  65. package/dist/utils/etherscan.mjs +3 -2
  66. package/dist/utils/etherscan.mjs.map +1 -1
  67. package/package.json +8 -6
package/CHANGELOG.md CHANGED
@@ -7,6 +7,53 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [41.1.0]
11
+
12
+ ### Added
13
+
14
+ - Add optional `destinationChainId` property to `TransactionMeta` to facilitate Bridge transactions ([#4988](https://github.com/MetaMask/core/pull/4988))
15
+
16
+ ### Changed
17
+
18
+ - Bump `@metamask/controller-utils` from `^11.4.3` to `^11.4.4` ([#5012](https://github.com/MetaMask/core/pull/5012))
19
+
20
+ ### Fixed
21
+
22
+ - Make implicit peer dependencies explicit ([#4974](https://github.com/MetaMask/core/pull/4974))
23
+ - Add the following packages as peer dependencies of this package to satisfy peer dependency requirements from other dependencies:
24
+ - `@babel/runtime` `^7.0.0` (required by `@metamask/ethjs-provider-http`)
25
+ - `@metamask/eth-block-tracker` `>=9` (required by `@metamask/nonce-tracker`)
26
+ - These dependencies really should be present in projects that consume this package (e.g. MetaMask clients), and this change ensures that they now are.
27
+ - Furthermore, we are assuming that clients already use these dependencies, since otherwise it would be impossible to consume this package in its entirety or even create a working build. Hence, the addition of these peer dependencies is really a formality and should not be breaking.
28
+ - Correct ESM-compatible build so that imports of the following packages that re-export other modules via `export *` are no longer corrupted: ([#5011](https://github.com/MetaMask/core/pull/5011))
29
+ - `@ethereumjs/common`
30
+ - `@ethereumjs/util`
31
+ - `@metamask/eth-query`
32
+ - `bn.js`
33
+ - `fast-json-patch`
34
+ - `lodash`
35
+
36
+ ## [41.0.0]
37
+
38
+ ### Added
39
+
40
+ - **BREAKING:** Remove global network usage ([#4920](https://github.com/MetaMask/core/pull/4920))
41
+ - Add required `networkClientId` argument to `handleMethodData` method.
42
+
43
+ ### Changed
44
+
45
+ - **BREAKING:** Remove global network usage ([#4920](https://github.com/MetaMask/core/pull/4920))
46
+ - Require `networkClientId` option in `addTransaction` method.
47
+ - Require `networkClientId` property in `TransactionMeta` type.
48
+ - Change `wipeTransactions` method arguments to optional object containing `address` and `chainId` properties.
49
+ - Require `networkClientId` argument in `estimateGas`, `estimateGasBuffered` and `getNonceLock` methods.
50
+
51
+ ### Removed
52
+
53
+ - **BREAKING:** Remove global network usage ([#4920](https://github.com/MetaMask/core/pull/4920))
54
+ - Remove the `blockTracker`, `isMultichainEnabled`, `onNetworkStateChange` and `provider` constructor options.
55
+ - Remove `filterToCurrentNetwork` option from `getTransactions` method.
56
+
10
57
  ## [40.1.0]
11
58
 
12
59
  ### Added
@@ -1142,7 +1189,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1142
1189
 
1143
1190
  All changes listed after this point were applied to this package following the monorepo conversion.
1144
1191
 
1145
- [Unreleased]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@40.1.0...HEAD
1192
+ [Unreleased]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@41.1.0...HEAD
1193
+ [41.1.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@41.0.0...@metamask/transaction-controller@41.1.0
1194
+ [41.0.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@40.1.0...@metamask/transaction-controller@41.0.0
1146
1195
  [40.1.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@40.0.0...@metamask/transaction-controller@40.1.0
1147
1196
  [40.0.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@39.1.0...@metamask/transaction-controller@40.0.0
1148
1197
  [39.1.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@39.0.0...@metamask/transaction-controller@39.1.0
package/README.md CHANGED
@@ -10,6 +10,10 @@ or
10
10
 
11
11
  `npm install @metamask/transaction-controller`
12
12
 
13
+ ## Compatibility
14
+
15
+ This package relies implicitly upon the `EventEmitter` module. This module is available natively in Node.js, but when using this package for the browser, make sure to use a polyfill such as `events`.
16
+
13
17
  ## Contributing
14
18
 
15
19
  This package is part of a monorepo. Instructions for contributing can be found in the [monorepo README](https://github.com/MetaMask/core#readme).