@metamask/gas-fee-controller
Advanced tools
Comparing version 10.0.1 to 11.0.0
@@ -9,2 +9,11 @@ # Changelog | ||
## [11.0.0] | ||
### Changed | ||
- **BREAKING:** Bump `@metamask/base-controller` to ^4.0.0 ([#2063](https://github.com/MetaMask/core/pull/2063)) | ||
- This is breaking because the type of the `messenger` has backward-incompatible changes. See the changelog for this package for more. | ||
- Replace `ethjs-unit` ^0.1.6 with `@metamask/ethjs-unit` ^0.2.1 ([#2064](https://github.com/MetaMask/core/pull/2064)) | ||
- Bump `@metamask/controller-utils` to ^6.0.0 ([#2063](https://github.com/MetaMask/core/pull/2063)) | ||
- Bump `@metamask/network-controller` to ^17.0.0 ([#2063](https://github.com/MetaMask/core/pull/2063)) | ||
- Bump `@metamask/polling-controller` to ^2.0.0 ([#2063](https://github.com/MetaMask/core/pull/2063)) | ||
## [10.0.1] | ||
@@ -129,3 +138,4 @@ ### Changed | ||
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@10.0.1...HEAD | ||
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@11.0.0...HEAD | ||
[11.0.0]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@10.0.1...@metamask/gas-fee-controller@11.0.0 | ||
[10.0.1]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@10.0.0...@metamask/gas-fee-controller@10.0.1 | ||
@@ -132,0 +142,0 @@ [10.0.0]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@9.0.0...@metamask/gas-fee-controller@10.0.0 |
@@ -16,3 +16,3 @@ "use strict"; | ||
const controller_utils_1 = require("@metamask/controller-utils"); | ||
const ethjs_unit_1 = require("ethjs-unit"); | ||
const ethjs_unit_1 = require("@metamask/ethjs-unit"); | ||
const fetchBlockFeeHistory_1 = __importDefault(require("./fetchBlockFeeHistory")); | ||
@@ -19,0 +19,0 @@ const calculateGasFeeEstimatesForPriorityLevels_1 = __importDefault(require("./fetchGasEstimatesViaEthFeeHistory/calculateGasFeeEstimatesForPriorityLevels")); |
@@ -7,4 +7,4 @@ "use strict"; | ||
const controller_utils_1 = require("@metamask/controller-utils"); | ||
const ethjs_unit_1 = require("@metamask/ethjs-unit"); | ||
const ethereumjs_util_1 = require("ethereumjs-util"); | ||
const ethjs_unit_1 = require("ethjs-unit"); | ||
const medianOf_1 = __importDefault(require("./medianOf")); | ||
@@ -11,0 +11,0 @@ const PRIORITY_LEVELS = ['low', 'medium', 'high']; |
@@ -24,3 +24,3 @@ "use strict"; | ||
const numberAsWEIHex = (0, controller_utils_1.gweiDecToWEIBN)(n).toString(16); | ||
const numberAsGWEI = (0, controller_utils_1.weiHexToGweiDec)(numberAsWEIHex).toString(10); | ||
const numberAsGWEI = (0, controller_utils_1.weiHexToGweiDec)(numberAsWEIHex); | ||
return numberAsGWEI; | ||
@@ -27,0 +27,0 @@ } |
@@ -1,6 +0,5 @@ | ||
import type { RestrictedControllerMessenger } from '@metamask/base-controller'; | ||
import type { ControllerGetStateAction, ControllerStateChangeEvent, RestrictedControllerMessenger } from '@metamask/base-controller'; | ||
import type { NetworkClientId, NetworkControllerGetEIP1559CompatibilityAction, NetworkControllerGetNetworkClientByIdAction, NetworkControllerGetStateAction, NetworkControllerStateChangeEvent, NetworkState, ProviderProxy } from '@metamask/network-controller'; | ||
import { PollingController } from '@metamask/polling-controller'; | ||
import type { Hex } from '@metamask/utils'; | ||
import type { Patch } from 'immer'; | ||
export declare const LEGACY_GAS_PRICES_API_URL = "https://api.metaswap.codefi.network/gasPrices"; | ||
@@ -143,11 +142,8 @@ export declare type unknownString = 'unknown'; | ||
declare const name = "GasFeeController"; | ||
export declare type GasFeeStateChange = { | ||
type: `${typeof name}:stateChange`; | ||
payload: [GasFeeState, Patch[]]; | ||
}; | ||
export declare type GetGasFeeState = { | ||
type: `${typeof name}:getState`; | ||
handler: () => GasFeeState; | ||
}; | ||
declare type GasFeeMessenger = RestrictedControllerMessenger<typeof name, GetGasFeeState | NetworkControllerGetStateAction | NetworkControllerGetNetworkClientByIdAction | NetworkControllerGetEIP1559CompatibilityAction, GasFeeStateChange | NetworkControllerStateChangeEvent, NetworkControllerGetStateAction['type'] | NetworkControllerGetNetworkClientByIdAction['type'] | NetworkControllerGetEIP1559CompatibilityAction['type'], NetworkControllerStateChangeEvent['type']>; | ||
export declare type GasFeeStateChange = ControllerStateChangeEvent<typeof name, GasFeeState>; | ||
export declare type GetGasFeeState = ControllerGetStateAction<typeof name, GasFeeState>; | ||
export declare type GasFeeControllerActions = GetGasFeeState; | ||
export declare type GasFeeControllerEvents = GasFeeStateChange; | ||
declare type AllowedActions = NetworkControllerGetStateAction | NetworkControllerGetNetworkClientByIdAction | NetworkControllerGetEIP1559CompatibilityAction; | ||
declare type GasFeeMessenger = RestrictedControllerMessenger<typeof name, GasFeeControllerActions | AllowedActions, GasFeeControllerEvents | NetworkControllerStateChangeEvent, AllowedActions['type'], NetworkControllerStateChangeEvent['type']>; | ||
/** | ||
@@ -154,0 +150,0 @@ * Controller that retrieves gas fee estimate data and polls for updated data on a set interval |
{ | ||
"name": "@metamask/gas-fee-controller", | ||
"version": "10.0.1", | ||
"version": "11.0.0", | ||
"description": "Periodically calculates gas fee estimates based on various gas limits as well as other data displayed on transaction confirm screens", | ||
@@ -33,12 +33,11 @@ "keywords": [ | ||
"dependencies": { | ||
"@metamask/base-controller": "^3.2.3", | ||
"@metamask/controller-utils": "^5.0.2", | ||
"@metamask/base-controller": "^4.0.0", | ||
"@metamask/controller-utils": "^6.0.0", | ||
"@metamask/eth-query": "^4.0.0", | ||
"@metamask/network-controller": "^16.0.0", | ||
"@metamask/polling-controller": "^1.0.2", | ||
"@metamask/ethjs-unit": "^0.2.1", | ||
"@metamask/network-controller": "^17.0.0", | ||
"@metamask/polling-controller": "^2.0.0", | ||
"@metamask/utils": "^8.2.0", | ||
"@types/uuid": "^8.3.0", | ||
"ethereumjs-util": "^7.0.10", | ||
"ethjs-unit": "^0.1.6", | ||
"immer": "^9.0.6", | ||
"uuid": "^8.3.2" | ||
@@ -61,3 +60,3 @@ }, | ||
"peerDependencies": { | ||
"@metamask/network-controller": "^16.0.0" | ||
"@metamask/network-controller": "^17.0.0" | ||
}, | ||
@@ -64,0 +63,0 @@ "engines": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
172703
11
2
7520
1438
+ Added@metamask/ethjs-unit@^0.2.1
+ Added@babel/runtime@7.26.0(transitive)
+ Added@metamask/base-controller@4.1.1(transitive)
+ Added@metamask/controller-utils@6.1.08.0.4(transitive)
+ Added@metamask/ethjs-unit@0.2.10.3.0(transitive)
+ Added@metamask/network-controller@17.2.1(transitive)
+ Added@metamask/number-to-bn@1.7.1(transitive)
+ Added@metamask/polling-controller@2.0.0(transitive)
+ Added@types/node@22.10.0(transitive)
+ Addedregenerator-runtime@0.14.1(transitive)
- Removedethjs-unit@^0.1.6
- Removedimmer@^9.0.6
- Removed@metamask/base-controller@3.2.3(transitive)
- Removed@metamask/controller-utils@5.0.2(transitive)
- Removed@metamask/eth-query@3.0.1(transitive)
- Removed@metamask/network-controller@16.0.0(transitive)
- Removed@metamask/polling-controller@1.0.2(transitive)
- Removed@types/node@22.10.1(transitive)
- Removedethjs-unit@0.1.6(transitive)