Skip to content

Commit 803065b

Browse files
committed
Resolve lint error
2 parents 1affd31 + 22ab42d commit 803065b

48 files changed

Lines changed: 2724 additions & 786 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

docs/data-services.md

Lines changed: 465 additions & 0 deletions
Large diffs are not rendered by default.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@metamask/core-monorepo",
3-
"version": "450.0.0",
3+
"version": "454.0.0",
44
"private": true,
55
"description": "Monorepo for packages shared between MetaMask clients",
66
"repository": {

packages/assets-controllers/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@
8787
"@metamask/network-controller": "^24.0.0",
8888
"@metamask/permission-controller": "^11.0.6",
8989
"@metamask/phishing-controller": "^12.6.0",
90-
"@metamask/preferences-controller": "^18.2.0",
90+
"@metamask/preferences-controller": "^18.4.0",
9191
"@metamask/providers": "^22.1.0",
9292
"@metamask/snaps-controllers": "^12.3.1",
9393
"@metamask/snaps-sdk": "^7.1.0",

packages/bridge-controller/CHANGELOG.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,28 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [34.0.0]
11+
12+
### Added
13+
14+
- **BREAKING** Add a required `gasIncluded` quote request parameter to indicate whether the bridge-api should return gasless swap quotes. The clients need to pass in a Boolean value indicating whether the user is opted in to STX and if their current network has STX support ([#6030](https://github.com/MetaMask/core/pull/6030))
15+
- Add `gasIncluded` to QuoteResponse, which indicates whether the quote includes tx fees (gas-less) ([#6030](https://github.com/MetaMask/core/pull/6030))
16+
- Add `feeData.txFees` to QuoteResponse, which contains data about tx fees taken from either the source or destination asset ([#6030](https://github.com/MetaMask/core/pull/6030))
17+
- Add `includedTxFees` to QuoteMetadata, which clients can display as the included tx fee when displaying a gasless quote ([#6039](https://github.com/MetaMask/core/pull/6039))
18+
- Calculate and return value of `includedTxFees` ([#6039](https://github.com/MetaMask/core/pull/6039))
19+
20+
### Changed
21+
22+
- Consolidate validator and type definitions for `QuoteResponse`, `BridgeAsset` and `PlatformConfigSchema` so new response fields only need to be defined once ([#6030](https://github.com/MetaMask/core/pull/6030))
23+
- Add `txFees` to total sentAmount ([#6039](https://github.com/MetaMask/core/pull/6039))
24+
- When gas is included and is taken from the destination token amount, ignore network fees in `adjustedReturn` calculation ([#6039](https://github.com/MetaMask/core/pull/6039))
25+
26+
### Fixed
27+
28+
- Calculate EVM token exchange rates accurately in `selectExchangeRateByChainIdAndAddress` when the `marketData` conversion rate is in the native currency ([#6030](https://github.com/MetaMask/core/pull/6030))
29+
- Convert `trade.value` to decimal when calculating relayer fee ([#6039](https://github.com/MetaMask/core/pull/6039))
30+
- Revert QuoteResponse ChainId schema to expect a number instead of a string ([#6045](https://github.com/MetaMask/core/pull/6045))
31+
1032
## [33.0.1]
1133

1234
### Fixed
@@ -378,7 +400,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
378400

379401
- Initial release ([#5317](https://github.com/MetaMask/core/pull/5317))
380402

381-
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@33.0.1...HEAD
403+
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@34.0.0...HEAD
404+
[34.0.0]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@33.0.1...@metamask/bridge-controller@34.0.0
382405
[33.0.1]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@33.0.0...@metamask/bridge-controller@33.0.1
383406
[33.0.0]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@32.2.0...@metamask/bridge-controller@33.0.0
384407
[32.2.0]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@32.1.2...@metamask/bridge-controller@32.2.0

packages/bridge-controller/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@metamask/bridge-controller",
3-
"version": "33.0.1",
3+
"version": "34.0.0",
44
"description": "Manages bridge-related quote fetching functionality for MetaMask",
55
"keywords": [
66
"MetaMask",

packages/bridge-controller/src/bridge-controller.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import type { BigNumber } from '@ethersproject/bignumber';
22
import { Contract } from '@ethersproject/contracts';
33
import { Web3Provider } from '@ethersproject/providers';
44
import type { StateMetadata } from '@metamask/base-controller';
5-
import type { ChainId, TraceCallback } from '@metamask/controller-utils';
5+
import type { TraceCallback } from '@metamask/controller-utils';
66
import { abiERC20 } from '@metamask/metamask-eth-abis';
77
import type { NetworkClientId } from '@metamask/network-controller';
88
import { StaticIntervalPollingController } from '@metamask/polling-controller';
@@ -584,7 +584,7 @@ export class BridgeController extends StaticIntervalPollingController<BridgePoll
584584
const l1GasFeePromises = Promise.allSettled(
585585
quotes.map(async (quoteResponse) => {
586586
const { quote, trade, approval } = quoteResponse;
587-
const chainId = numberToHex(quote.srcChainId) as ChainId;
587+
const chainId = numberToHex(quote.srcChainId);
588588

589589
const getTxParams = (txData: TxData) => ({
590590
from: txData.from,

packages/bridge-controller/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,14 @@ export { StatusTypes } from './types';
5353
export {
5454
AssetType,
5555
SortOrder,
56-
ActionTypes,
5756
ChainId,
5857
RequestStatus,
5958
BridgeUserAction,
6059
BridgeBackgroundAction,
61-
FeeType,
6260
} from './types';
6361

62+
export { FeeType, ActionTypes, BridgeAssetSchema } from './utils/validators';
63+
6464
export {
6565
ALLOWED_BRIDGE_CHAIN_IDS,
6666
BridgeClientId,

0 commit comments

Comments
 (0)