@metamask/bridge-controller 47.0.0 → 47.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.
- package/CHANGELOG.md +13 -1
- package/dist/constants/bridge.cjs.map +1 -1
- package/dist/constants/bridge.d.cts +2 -8
- package/dist/constants/bridge.d.cts.map +1 -1
- package/dist/constants/bridge.d.mts +2 -8
- package/dist/constants/bridge.d.mts.map +1 -1
- package/dist/constants/bridge.mjs.map +1 -1
- package/dist/selectors.d.cts +188 -0
- package/dist/selectors.d.cts.map +1 -1
- package/dist/selectors.d.mts +188 -0
- package/dist/selectors.d.mts.map +1 -1
- package/dist/utils/feature-flags.d.cts +4 -0
- package/dist/utils/feature-flags.d.cts.map +1 -1
- package/dist/utils/feature-flags.d.mts +4 -0
- package/dist/utils/feature-flags.d.mts.map +1 -1
- package/dist/utils/validators.cjs +18 -0
- package/dist/utils/validators.cjs.map +1 -1
- package/dist/utils/validators.d.cts +47 -0
- package/dist/utils/validators.d.cts.map +1 -1
- package/dist/utils/validators.d.mts +47 -0
- package/dist/utils/validators.d.mts.map +1 -1
- package/dist/utils/validators.mjs +18 -0
- package/dist/utils/validators.mjs.map +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [47.1.0]
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- Add `bip44DefaultPairs` and `chains[chainId].defaultPairs` to feature flag types and validators ([#6645](https://github.com/MetaMask/core/pull/6645))
|
|
15
|
+
|
|
16
|
+
### Changed
|
|
17
|
+
|
|
18
|
+
- Bump `@metamask/assets-controllers` from `77.0.0` to `77.0.1` ([#6747](https://github.com/MetaMask/core/pull/6747))
|
|
19
|
+
- Bump `@metamask/transaction-controller` from `60.4.0` to `60.5.0` ([#6733](https://github.com/MetaMask/core/pull/6733))
|
|
20
|
+
|
|
10
21
|
## [47.0.0]
|
|
11
22
|
|
|
12
23
|
### Changed
|
|
@@ -650,7 +661,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
650
661
|
|
|
651
662
|
- Initial release ([#5317](https://github.com/MetaMask/core/pull/5317))
|
|
652
663
|
|
|
653
|
-
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@47.
|
|
664
|
+
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@47.1.0...HEAD
|
|
665
|
+
[47.1.0]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@47.0.0...@metamask/bridge-controller@47.1.0
|
|
654
666
|
[47.0.0]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@46.0.0...@metamask/bridge-controller@47.0.0
|
|
655
667
|
[46.0.0]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@45.0.0...@metamask/bridge-controller@46.0.0
|
|
656
668
|
[45.0.0]: https://github.com/MetaMask/core/compare/@metamask/bridge-controller@44.0.1...@metamask/bridge-controller@45.0.0
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bridge.cjs","sourceRoot":"","sources":["../../src/constants/bridge.ts"],"names":[],"mappings":";;;AAAA,wDAAuD;AACvD,uDAA2D;AAG3D,yCAAqC;
|
|
1
|
+
{"version":3,"file":"bridge.cjs","sourceRoot":"","sources":["../../src/constants/bridge.ts"],"names":[],"mappings":";;;AAAA,wDAAuD;AACvD,uDAA2D;AAG3D,yCAAqC;AAMxB,QAAA,wBAAwB,GAAG;IACtC,kBAAS,CAAC,OAAO;IACjB,kBAAS,CAAC,GAAG;IACb,kBAAS,CAAC,OAAO;IACjB,kBAAS,CAAC,UAAU;IACpB,kBAAS,CAAC,SAAS;IACnB,kBAAS,CAAC,QAAQ;IAClB,kBAAS,CAAC,QAAQ;IAClB,kBAAS,CAAC,aAAa;IACvB,kBAAS,CAAC,IAAI;IACd,kBAAS,CAAC,GAAG;IACb,sBAAQ,CAAC,OAAO;IAChB,sBAAQ,CAAC,OAAO;CACR,CAAC;AAIE,QAAA,uBAAuB,GAAG,uCAAuC,CAAC;AAClE,QAAA,wBAAwB,GAAG,mCAAmC,CAAC;AAE5E,IAAY,cAGX;AAHD,WAAY,cAAc;IACxB,yCAAuB,CAAA;IACvB,mCAAiB,CAAA;AACnB,CAAC,EAHW,cAAc,8BAAd,cAAc,QAGzB;AAEY,QAAA,gBAAgB,GAAG,4CAA4C,CAAC;AAChE,QAAA,2BAA2B,GACtC,4CAA4C,CAAC;AAClC,QAAA,4BAA4B,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC,SAAS;AACjD,QAAA,6CAA6C,GAAG,GAAG,CAAC,CAAC,2EAA2E;AAEhI,QAAA,6BAA6B,GAAG,QAAQ,CAAC;AACzC,QAAA,kBAAkB,GAAG,KAAK,CAAC;AAC3B,QAAA,mBAAmB,GAAG,EAAE,GAAG,IAAI,CAAC;AAChC,QAAA,yBAAyB,GAAG,CAAC,CAAC;AAE9B,QAAA,sBAAsB,GAAG,kBAAkB,CAAC;AAE5C,QAAA,2BAA2B,GAA+B;IACrE,cAAc,EAAE,OAAO;IACvB,WAAW,EAAE,2BAAmB;IAChC,eAAe,EAAE,iCAAyB;IAC1C,OAAO,EAAE,KAAK;IACd,MAAM,EAAE,EAAE;CACX,CAAC;AAEW,QAAA,+BAA+B,GAA0B;IACpE,YAAY,EAAE;QACZ,eAAe,EAAE,uBAAW;KAC7B;IACD,qBAAqB,EAAE,IAAI;IAC3B,MAAM,EAAE,EAAE;IACV,iBAAiB,EAAE,IAAI;IACvB,mBAAmB,EAAE,IAAI;IACzB,eAAe,EAAE,IAAI;IACrB,kBAAkB,EAAE,CAAC;IACrB,kBAAkB,EAAE,EAAE;IACtB,wCAAwC,EAAE,GAAG;CAC9C,CAAC;AAEW,QAAA,+BAA+B,GAAwB;IAClE,CAAC,kBAAS,CAAC,OAAO,CAAC,EAAE,mCAA2B;CACjD,CAAC","sourcesContent":["import { AddressZero } from '@ethersproject/constants';\nimport { BtcScope, SolScope } from '@metamask/keyring-api';\nimport type { Hex } from '@metamask/utils';\n\nimport { CHAIN_IDS } from './chains';\nimport type {\n BridgeControllerState,\n FeatureFlagsPlatformConfig,\n} from '../types';\n\nexport const ALLOWED_BRIDGE_CHAIN_IDS = [\n CHAIN_IDS.MAINNET,\n CHAIN_IDS.BSC,\n CHAIN_IDS.POLYGON,\n CHAIN_IDS.ZKSYNC_ERA,\n CHAIN_IDS.AVALANCHE,\n CHAIN_IDS.OPTIMISM,\n CHAIN_IDS.ARBITRUM,\n CHAIN_IDS.LINEA_MAINNET,\n CHAIN_IDS.BASE,\n CHAIN_IDS.SEI,\n SolScope.Mainnet,\n BtcScope.Mainnet,\n] as const;\n\nexport type AllowedBridgeChainIds = (typeof ALLOWED_BRIDGE_CHAIN_IDS)[number];\n\nexport const BRIDGE_DEV_API_BASE_URL = 'https://bridge.dev-api.cx.metamask.io';\nexport const BRIDGE_PROD_API_BASE_URL = 'https://bridge.api.cx.metamask.io';\n\nexport enum BridgeClientId {\n EXTENSION = 'extension',\n MOBILE = 'mobile',\n}\n\nexport const ETH_USDT_ADDRESS = '0xdac17f958d2ee523a2206206994597c13d831ec7';\nexport const METABRIDGE_ETHEREUM_ADDRESS =\n '0x0439e60F02a8900a951603950d8D4527f400C3f1';\nexport const BRIDGE_QUOTE_MAX_ETA_SECONDS = 60 * 60; // 1 hour\nexport const BRIDGE_QUOTE_MAX_RETURN_DIFFERENCE_PERCENTAGE = 0.5; // if a quote returns in x times less return than the best quote, ignore it\n\nexport const BRIDGE_PREFERRED_GAS_ESTIMATE = 'medium';\nexport const BRIDGE_MM_FEE_RATE = 0.875;\nexport const REFRESH_INTERVAL_MS = 30 * 1000;\nexport const DEFAULT_MAX_REFRESH_COUNT = 5;\n\nexport const BRIDGE_CONTROLLER_NAME = 'BridgeController';\n\nexport const DEFAULT_FEATURE_FLAG_CONFIG: FeatureFlagsPlatformConfig = {\n minimumVersion: '0.0.0',\n refreshRate: REFRESH_INTERVAL_MS,\n maxRefreshCount: DEFAULT_MAX_REFRESH_COUNT,\n support: false,\n chains: {},\n};\n\nexport const DEFAULT_BRIDGE_CONTROLLER_STATE: BridgeControllerState = {\n quoteRequest: {\n srcTokenAddress: AddressZero,\n },\n quotesInitialLoadTime: null,\n quotes: [],\n quotesLastFetched: null,\n quotesLoadingStatus: null,\n quoteFetchError: null,\n quotesRefreshCount: 0,\n assetExchangeRates: {},\n minimumBalanceForRentExemptionInLamports: '0',\n};\n\nexport const METABRIDGE_CHAIN_TO_ADDRESS_MAP: Record<Hex, string> = {\n [CHAIN_IDS.MAINNET]: METABRIDGE_ETHEREUM_ADDRESS,\n};\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { BtcScope, SolScope } from "@metamask/keyring-api";
|
|
2
2
|
import type { Hex } from "@metamask/utils";
|
|
3
|
-
import type { BridgeControllerState } from "../types.cjs";
|
|
3
|
+
import type { BridgeControllerState, FeatureFlagsPlatformConfig } from "../types.cjs";
|
|
4
4
|
export declare const ALLOWED_BRIDGE_CHAIN_IDS: readonly ["0x1", "0x38", "0x89", "0x144", "0xa86a", "0xa", "0xa4b1", "0xe708", "0x2105", "0x531", SolScope.Mainnet, BtcScope.Mainnet];
|
|
5
5
|
export type AllowedBridgeChainIds = (typeof ALLOWED_BRIDGE_CHAIN_IDS)[number];
|
|
6
6
|
export declare const BRIDGE_DEV_API_BASE_URL = "https://bridge.dev-api.cx.metamask.io";
|
|
@@ -18,13 +18,7 @@ export declare const BRIDGE_MM_FEE_RATE = 0.875;
|
|
|
18
18
|
export declare const REFRESH_INTERVAL_MS: number;
|
|
19
19
|
export declare const DEFAULT_MAX_REFRESH_COUNT = 5;
|
|
20
20
|
export declare const BRIDGE_CONTROLLER_NAME = "BridgeController";
|
|
21
|
-
export declare const DEFAULT_FEATURE_FLAG_CONFIG:
|
|
22
|
-
minimumVersion: string;
|
|
23
|
-
refreshRate: number;
|
|
24
|
-
maxRefreshCount: number;
|
|
25
|
-
support: boolean;
|
|
26
|
-
chains: {};
|
|
27
|
-
};
|
|
21
|
+
export declare const DEFAULT_FEATURE_FLAG_CONFIG: FeatureFlagsPlatformConfig;
|
|
28
22
|
export declare const DEFAULT_BRIDGE_CONTROLLER_STATE: BridgeControllerState;
|
|
29
23
|
export declare const METABRIDGE_CHAIN_TO_ADDRESS_MAP: Record<Hex, string>;
|
|
30
24
|
//# sourceMappingURL=bridge.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bridge.d.cts","sourceRoot":"","sources":["../../src/constants/bridge.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,8BAA8B;AAC3D,OAAO,KAAK,EAAE,GAAG,EAAE,wBAAwB;AAG3C,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"bridge.d.cts","sourceRoot":"","sources":["../../src/constants/bridge.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,8BAA8B;AAC3D,OAAO,KAAK,EAAE,GAAG,EAAE,wBAAwB;AAG3C,OAAO,KAAK,EACV,qBAAqB,EACrB,0BAA0B,EAC3B,qBAAiB;AAElB,eAAO,MAAM,wBAAwB,uIAa3B,CAAC;AAEX,MAAM,MAAM,qBAAqB,GAAG,CAAC,OAAO,wBAAwB,CAAC,CAAC,MAAM,CAAC,CAAC;AAE9E,eAAO,MAAM,uBAAuB,0CAA0C,CAAC;AAC/E,eAAO,MAAM,wBAAwB,sCAAsC,CAAC;AAE5E,oBAAY,cAAc;IACxB,SAAS,cAAc;IACvB,MAAM,WAAW;CAClB;AAED,eAAO,MAAM,gBAAgB,+CAA+C,CAAC;AAC7E,eAAO,MAAM,2BAA2B,+CACM,CAAC;AAC/C,eAAO,MAAM,4BAA4B,QAAU,CAAC;AACpD,eAAO,MAAM,6CAA6C,MAAM,CAAC;AAEjE,eAAO,MAAM,6BAA6B,WAAW,CAAC;AACtD,eAAO,MAAM,kBAAkB,QAAQ,CAAC;AACxC,eAAO,MAAM,mBAAmB,QAAY,CAAC;AAC7C,eAAO,MAAM,yBAAyB,IAAI,CAAC;AAE3C,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AAEzD,eAAO,MAAM,2BAA2B,EAAE,0BAMzC,CAAC;AAEF,eAAO,MAAM,+BAA+B,EAAE,qBAY7C,CAAC;AAEF,eAAO,MAAM,+BAA+B,EAAE,MAAM,CAAC,GAAG,EAAE,MAAM,CAE/D,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { BtcScope, SolScope } from "@metamask/keyring-api";
|
|
2
2
|
import type { Hex } from "@metamask/utils";
|
|
3
|
-
import type { BridgeControllerState } from "../types.mjs";
|
|
3
|
+
import type { BridgeControllerState, FeatureFlagsPlatformConfig } from "../types.mjs";
|
|
4
4
|
export declare const ALLOWED_BRIDGE_CHAIN_IDS: readonly ["0x1", "0x38", "0x89", "0x144", "0xa86a", "0xa", "0xa4b1", "0xe708", "0x2105", "0x531", SolScope.Mainnet, BtcScope.Mainnet];
|
|
5
5
|
export type AllowedBridgeChainIds = (typeof ALLOWED_BRIDGE_CHAIN_IDS)[number];
|
|
6
6
|
export declare const BRIDGE_DEV_API_BASE_URL = "https://bridge.dev-api.cx.metamask.io";
|
|
@@ -18,13 +18,7 @@ export declare const BRIDGE_MM_FEE_RATE = 0.875;
|
|
|
18
18
|
export declare const REFRESH_INTERVAL_MS: number;
|
|
19
19
|
export declare const DEFAULT_MAX_REFRESH_COUNT = 5;
|
|
20
20
|
export declare const BRIDGE_CONTROLLER_NAME = "BridgeController";
|
|
21
|
-
export declare const DEFAULT_FEATURE_FLAG_CONFIG:
|
|
22
|
-
minimumVersion: string;
|
|
23
|
-
refreshRate: number;
|
|
24
|
-
maxRefreshCount: number;
|
|
25
|
-
support: boolean;
|
|
26
|
-
chains: {};
|
|
27
|
-
};
|
|
21
|
+
export declare const DEFAULT_FEATURE_FLAG_CONFIG: FeatureFlagsPlatformConfig;
|
|
28
22
|
export declare const DEFAULT_BRIDGE_CONTROLLER_STATE: BridgeControllerState;
|
|
29
23
|
export declare const METABRIDGE_CHAIN_TO_ADDRESS_MAP: Record<Hex, string>;
|
|
30
24
|
//# sourceMappingURL=bridge.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bridge.d.mts","sourceRoot":"","sources":["../../src/constants/bridge.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,8BAA8B;AAC3D,OAAO,KAAK,EAAE,GAAG,EAAE,wBAAwB;AAG3C,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"bridge.d.mts","sourceRoot":"","sources":["../../src/constants/bridge.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,8BAA8B;AAC3D,OAAO,KAAK,EAAE,GAAG,EAAE,wBAAwB;AAG3C,OAAO,KAAK,EACV,qBAAqB,EACrB,0BAA0B,EAC3B,qBAAiB;AAElB,eAAO,MAAM,wBAAwB,uIAa3B,CAAC;AAEX,MAAM,MAAM,qBAAqB,GAAG,CAAC,OAAO,wBAAwB,CAAC,CAAC,MAAM,CAAC,CAAC;AAE9E,eAAO,MAAM,uBAAuB,0CAA0C,CAAC;AAC/E,eAAO,MAAM,wBAAwB,sCAAsC,CAAC;AAE5E,oBAAY,cAAc;IACxB,SAAS,cAAc;IACvB,MAAM,WAAW;CAClB;AAED,eAAO,MAAM,gBAAgB,+CAA+C,CAAC;AAC7E,eAAO,MAAM,2BAA2B,+CACM,CAAC;AAC/C,eAAO,MAAM,4BAA4B,QAAU,CAAC;AACpD,eAAO,MAAM,6CAA6C,MAAM,CAAC;AAEjE,eAAO,MAAM,6BAA6B,WAAW,CAAC;AACtD,eAAO,MAAM,kBAAkB,QAAQ,CAAC;AACxC,eAAO,MAAM,mBAAmB,QAAY,CAAC;AAC7C,eAAO,MAAM,yBAAyB,IAAI,CAAC;AAE3C,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AAEzD,eAAO,MAAM,2BAA2B,EAAE,0BAMzC,CAAC;AAEF,eAAO,MAAM,+BAA+B,EAAE,qBAY7C,CAAC;AAEF,eAAO,MAAM,+BAA+B,EAAE,MAAM,CAAC,GAAG,EAAE,MAAM,CAE/D,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bridge.mjs","sourceRoot":"","sources":["../../src/constants/bridge.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,iCAAiC;AACvD,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,8BAA8B;AAG3D,OAAO,EAAE,SAAS,EAAE,qBAAiB;
|
|
1
|
+
{"version":3,"file":"bridge.mjs","sourceRoot":"","sources":["../../src/constants/bridge.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,iCAAiC;AACvD,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,8BAA8B;AAG3D,OAAO,EAAE,SAAS,EAAE,qBAAiB;AAMrC,MAAM,CAAC,MAAM,wBAAwB,GAAG;IACtC,SAAS,CAAC,OAAO;IACjB,SAAS,CAAC,GAAG;IACb,SAAS,CAAC,OAAO;IACjB,SAAS,CAAC,UAAU;IACpB,SAAS,CAAC,SAAS;IACnB,SAAS,CAAC,QAAQ;IAClB,SAAS,CAAC,QAAQ;IAClB,SAAS,CAAC,aAAa;IACvB,SAAS,CAAC,IAAI;IACd,SAAS,CAAC,GAAG;IACb,QAAQ,CAAC,OAAO;IAChB,QAAQ,CAAC,OAAO;CACR,CAAC;AAIX,MAAM,CAAC,MAAM,uBAAuB,GAAG,uCAAuC,CAAC;AAC/E,MAAM,CAAC,MAAM,wBAAwB,GAAG,mCAAmC,CAAC;AAE5E,MAAM,CAAN,IAAY,cAGX;AAHD,WAAY,cAAc;IACxB,yCAAuB,CAAA;IACvB,mCAAiB,CAAA;AACnB,CAAC,EAHW,cAAc,KAAd,cAAc,QAGzB;AAED,MAAM,CAAC,MAAM,gBAAgB,GAAG,4CAA4C,CAAC;AAC7E,MAAM,CAAC,MAAM,2BAA2B,GACtC,4CAA4C,CAAC;AAC/C,MAAM,CAAC,MAAM,4BAA4B,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC,SAAS;AAC9D,MAAM,CAAC,MAAM,6CAA6C,GAAG,GAAG,CAAC,CAAC,2EAA2E;AAE7I,MAAM,CAAC,MAAM,6BAA6B,GAAG,QAAQ,CAAC;AACtD,MAAM,CAAC,MAAM,kBAAkB,GAAG,KAAK,CAAC;AACxC,MAAM,CAAC,MAAM,mBAAmB,GAAG,EAAE,GAAG,IAAI,CAAC;AAC7C,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,CAAC;AAE3C,MAAM,CAAC,MAAM,sBAAsB,GAAG,kBAAkB,CAAC;AAEzD,MAAM,CAAC,MAAM,2BAA2B,GAA+B;IACrE,cAAc,EAAE,OAAO;IACvB,WAAW,EAAE,mBAAmB;IAChC,eAAe,EAAE,yBAAyB;IAC1C,OAAO,EAAE,KAAK;IACd,MAAM,EAAE,EAAE;CACX,CAAC;AAEF,MAAM,CAAC,MAAM,+BAA+B,GAA0B;IACpE,YAAY,EAAE;QACZ,eAAe,EAAE,WAAW;KAC7B;IACD,qBAAqB,EAAE,IAAI;IAC3B,MAAM,EAAE,EAAE;IACV,iBAAiB,EAAE,IAAI;IACvB,mBAAmB,EAAE,IAAI;IACzB,eAAe,EAAE,IAAI;IACrB,kBAAkB,EAAE,CAAC;IACrB,kBAAkB,EAAE,EAAE;IACtB,wCAAwC,EAAE,GAAG;CAC9C,CAAC;AAEF,MAAM,CAAC,MAAM,+BAA+B,GAAwB;IAClE,CAAC,SAAS,CAAC,OAAO,CAAC,EAAE,2BAA2B;CACjD,CAAC","sourcesContent":["import { AddressZero } from '@ethersproject/constants';\nimport { BtcScope, SolScope } from '@metamask/keyring-api';\nimport type { Hex } from '@metamask/utils';\n\nimport { CHAIN_IDS } from './chains';\nimport type {\n BridgeControllerState,\n FeatureFlagsPlatformConfig,\n} from '../types';\n\nexport const ALLOWED_BRIDGE_CHAIN_IDS = [\n CHAIN_IDS.MAINNET,\n CHAIN_IDS.BSC,\n CHAIN_IDS.POLYGON,\n CHAIN_IDS.ZKSYNC_ERA,\n CHAIN_IDS.AVALANCHE,\n CHAIN_IDS.OPTIMISM,\n CHAIN_IDS.ARBITRUM,\n CHAIN_IDS.LINEA_MAINNET,\n CHAIN_IDS.BASE,\n CHAIN_IDS.SEI,\n SolScope.Mainnet,\n BtcScope.Mainnet,\n] as const;\n\nexport type AllowedBridgeChainIds = (typeof ALLOWED_BRIDGE_CHAIN_IDS)[number];\n\nexport const BRIDGE_DEV_API_BASE_URL = 'https://bridge.dev-api.cx.metamask.io';\nexport const BRIDGE_PROD_API_BASE_URL = 'https://bridge.api.cx.metamask.io';\n\nexport enum BridgeClientId {\n EXTENSION = 'extension',\n MOBILE = 'mobile',\n}\n\nexport const ETH_USDT_ADDRESS = '0xdac17f958d2ee523a2206206994597c13d831ec7';\nexport const METABRIDGE_ETHEREUM_ADDRESS =\n '0x0439e60F02a8900a951603950d8D4527f400C3f1';\nexport const BRIDGE_QUOTE_MAX_ETA_SECONDS = 60 * 60; // 1 hour\nexport const BRIDGE_QUOTE_MAX_RETURN_DIFFERENCE_PERCENTAGE = 0.5; // if a quote returns in x times less return than the best quote, ignore it\n\nexport const BRIDGE_PREFERRED_GAS_ESTIMATE = 'medium';\nexport const BRIDGE_MM_FEE_RATE = 0.875;\nexport const REFRESH_INTERVAL_MS = 30 * 1000;\nexport const DEFAULT_MAX_REFRESH_COUNT = 5;\n\nexport const BRIDGE_CONTROLLER_NAME = 'BridgeController';\n\nexport const DEFAULT_FEATURE_FLAG_CONFIG: FeatureFlagsPlatformConfig = {\n minimumVersion: '0.0.0',\n refreshRate: REFRESH_INTERVAL_MS,\n maxRefreshCount: DEFAULT_MAX_REFRESH_COUNT,\n support: false,\n chains: {},\n};\n\nexport const DEFAULT_BRIDGE_CONTROLLER_STATE: BridgeControllerState = {\n quoteRequest: {\n srcTokenAddress: AddressZero,\n },\n quotesInitialLoadTime: null,\n quotes: [],\n quotesLastFetched: null,\n quotesLoadingStatus: null,\n quoteFetchError: null,\n quotesRefreshCount: 0,\n assetExchangeRates: {},\n minimumBalanceForRentExemptionInLamports: '0',\n};\n\nexport const METABRIDGE_CHAIN_TO_ADDRESS_MAP: Record<Hex, string> = {\n [CHAIN_IDS.MAINNET]: METABRIDGE_ETHEREUM_ADDRESS,\n};\n"]}
|
package/dist/selectors.d.cts
CHANGED
|
@@ -60,6 +60,10 @@ export declare const selectBridgeFeatureFlags: ((state: RemoteFeatureFlagControl
|
|
|
60
60
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
61
61
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
62
62
|
noFeeAssets?: string[] | undefined;
|
|
63
|
+
defaultPairs?: {
|
|
64
|
+
standard: Record<string, string>;
|
|
65
|
+
other: Record<string, string>;
|
|
66
|
+
} | undefined;
|
|
63
67
|
}>;
|
|
64
68
|
refreshRate: number;
|
|
65
69
|
minimumVersion: string;
|
|
@@ -73,6 +77,10 @@ export declare const selectBridgeFeatureFlags: ((state: RemoteFeatureFlagControl
|
|
|
73
77
|
bridgeIds?: string[] | undefined;
|
|
74
78
|
noFee?: boolean | undefined;
|
|
75
79
|
} | undefined> | undefined;
|
|
80
|
+
bip44DefaultPairs?: Record<string, {
|
|
81
|
+
standard: Record<string, string>;
|
|
82
|
+
other: Record<string, string>;
|
|
83
|
+
} | undefined> | undefined;
|
|
76
84
|
}) & {
|
|
77
85
|
clearCache: () => void;
|
|
78
86
|
resultsCount: () => number;
|
|
@@ -90,6 +98,10 @@ export declare const selectBridgeFeatureFlags: ((state: RemoteFeatureFlagControl
|
|
|
90
98
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
91
99
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
92
100
|
noFeeAssets?: string[] | undefined;
|
|
101
|
+
defaultPairs?: {
|
|
102
|
+
standard: Record<string, string>;
|
|
103
|
+
other: Record<string, string>;
|
|
104
|
+
} | undefined;
|
|
93
105
|
}>;
|
|
94
106
|
refreshRate: number;
|
|
95
107
|
minimumVersion: string;
|
|
@@ -103,6 +115,10 @@ export declare const selectBridgeFeatureFlags: ((state: RemoteFeatureFlagControl
|
|
|
103
115
|
bridgeIds?: string[] | undefined;
|
|
104
116
|
noFee?: boolean | undefined;
|
|
105
117
|
} | undefined> | undefined;
|
|
118
|
+
bip44DefaultPairs?: Record<string, {
|
|
119
|
+
standard: Record<string, string>;
|
|
120
|
+
other: Record<string, string>;
|
|
121
|
+
} | undefined> | undefined;
|
|
106
122
|
};
|
|
107
123
|
memoizedResultFunc: ((resultFuncArgs_0: any) => {
|
|
108
124
|
support: boolean;
|
|
@@ -116,6 +132,10 @@ export declare const selectBridgeFeatureFlags: ((state: RemoteFeatureFlagControl
|
|
|
116
132
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
117
133
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
118
134
|
noFeeAssets?: string[] | undefined;
|
|
135
|
+
defaultPairs?: {
|
|
136
|
+
standard: Record<string, string>;
|
|
137
|
+
other: Record<string, string>;
|
|
138
|
+
} | undefined;
|
|
119
139
|
}>;
|
|
120
140
|
refreshRate: number;
|
|
121
141
|
minimumVersion: string;
|
|
@@ -129,6 +149,10 @@ export declare const selectBridgeFeatureFlags: ((state: RemoteFeatureFlagControl
|
|
|
129
149
|
bridgeIds?: string[] | undefined;
|
|
130
150
|
noFee?: boolean | undefined;
|
|
131
151
|
} | undefined> | undefined;
|
|
152
|
+
bip44DefaultPairs?: Record<string, {
|
|
153
|
+
standard: Record<string, string>;
|
|
154
|
+
other: Record<string, string>;
|
|
155
|
+
} | undefined> | undefined;
|
|
132
156
|
}) & {
|
|
133
157
|
clearCache: () => void;
|
|
134
158
|
resultsCount: () => number;
|
|
@@ -146,6 +170,10 @@ export declare const selectBridgeFeatureFlags: ((state: RemoteFeatureFlagControl
|
|
|
146
170
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
147
171
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
148
172
|
noFeeAssets?: string[] | undefined;
|
|
173
|
+
defaultPairs?: {
|
|
174
|
+
standard: Record<string, string>;
|
|
175
|
+
other: Record<string, string>;
|
|
176
|
+
} | undefined;
|
|
149
177
|
}>;
|
|
150
178
|
refreshRate: number;
|
|
151
179
|
minimumVersion: string;
|
|
@@ -159,6 +187,10 @@ export declare const selectBridgeFeatureFlags: ((state: RemoteFeatureFlagControl
|
|
|
159
187
|
bridgeIds?: string[] | undefined;
|
|
160
188
|
noFee?: boolean | undefined;
|
|
161
189
|
} | undefined> | undefined;
|
|
190
|
+
bip44DefaultPairs?: Record<string, {
|
|
191
|
+
standard: Record<string, string>;
|
|
192
|
+
other: Record<string, string>;
|
|
193
|
+
} | undefined> | undefined;
|
|
162
194
|
};
|
|
163
195
|
dependencies: [(state: RemoteFeatureFlagControllerState) => unknown];
|
|
164
196
|
recomputations: () => number;
|
|
@@ -222,6 +254,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
222
254
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
223
255
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
224
256
|
noFeeAssets?: string[] | undefined;
|
|
257
|
+
defaultPairs?: {
|
|
258
|
+
standard: Record<string, string>;
|
|
259
|
+
other: Record<string, string>;
|
|
260
|
+
} | undefined;
|
|
225
261
|
}>;
|
|
226
262
|
refreshRate: number;
|
|
227
263
|
minimumVersion: string;
|
|
@@ -235,6 +271,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
235
271
|
bridgeIds?: string[] | undefined;
|
|
236
272
|
noFee?: boolean | undefined;
|
|
237
273
|
} | undefined> | undefined;
|
|
274
|
+
bip44DefaultPairs?: Record<string, {
|
|
275
|
+
standard: Record<string, string>;
|
|
276
|
+
other: Record<string, string>;
|
|
277
|
+
} | undefined> | undefined;
|
|
238
278
|
}, resultFuncArgs_1: boolean | undefined, resultFuncArgs_2: number) => boolean;
|
|
239
279
|
memoizedResultFunc: ((resultFuncArgs_0: {
|
|
240
280
|
support: boolean;
|
|
@@ -248,6 +288,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
248
288
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
249
289
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
250
290
|
noFeeAssets?: string[] | undefined;
|
|
291
|
+
defaultPairs?: {
|
|
292
|
+
standard: Record<string, string>;
|
|
293
|
+
other: Record<string, string>;
|
|
294
|
+
} | undefined;
|
|
251
295
|
}>;
|
|
252
296
|
refreshRate: number;
|
|
253
297
|
minimumVersion: string;
|
|
@@ -261,6 +305,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
261
305
|
bridgeIds?: string[] | undefined;
|
|
262
306
|
noFee?: boolean | undefined;
|
|
263
307
|
} | undefined> | undefined;
|
|
308
|
+
bip44DefaultPairs?: Record<string, {
|
|
309
|
+
standard: Record<string, string>;
|
|
310
|
+
other: Record<string, string>;
|
|
311
|
+
} | undefined> | undefined;
|
|
264
312
|
}, resultFuncArgs_1: boolean | undefined, resultFuncArgs_2: number) => boolean) & {
|
|
265
313
|
clearCache: () => void;
|
|
266
314
|
resultsCount: () => number;
|
|
@@ -279,6 +327,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
279
327
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
280
328
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
281
329
|
noFeeAssets?: string[] | undefined;
|
|
330
|
+
defaultPairs?: {
|
|
331
|
+
standard: Record<string, string>;
|
|
332
|
+
other: Record<string, string>;
|
|
333
|
+
} | undefined;
|
|
282
334
|
}>;
|
|
283
335
|
refreshRate: number;
|
|
284
336
|
minimumVersion: string;
|
|
@@ -292,6 +344,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
292
344
|
bridgeIds?: string[] | undefined;
|
|
293
345
|
noFee?: boolean | undefined;
|
|
294
346
|
} | undefined> | undefined;
|
|
347
|
+
bip44DefaultPairs?: Record<string, {
|
|
348
|
+
standard: Record<string, string>;
|
|
349
|
+
other: Record<string, string>;
|
|
350
|
+
} | undefined> | undefined;
|
|
295
351
|
}) & {
|
|
296
352
|
clearCache: () => void;
|
|
297
353
|
resultsCount: () => number;
|
|
@@ -309,6 +365,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
309
365
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
310
366
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
311
367
|
noFeeAssets?: string[] | undefined;
|
|
368
|
+
defaultPairs?: {
|
|
369
|
+
standard: Record<string, string>;
|
|
370
|
+
other: Record<string, string>;
|
|
371
|
+
} | undefined;
|
|
312
372
|
}>;
|
|
313
373
|
refreshRate: number;
|
|
314
374
|
minimumVersion: string;
|
|
@@ -322,6 +382,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
322
382
|
bridgeIds?: string[] | undefined;
|
|
323
383
|
noFee?: boolean | undefined;
|
|
324
384
|
} | undefined> | undefined;
|
|
385
|
+
bip44DefaultPairs?: Record<string, {
|
|
386
|
+
standard: Record<string, string>;
|
|
387
|
+
other: Record<string, string>;
|
|
388
|
+
} | undefined> | undefined;
|
|
325
389
|
};
|
|
326
390
|
memoizedResultFunc: ((resultFuncArgs_0: any) => {
|
|
327
391
|
support: boolean;
|
|
@@ -335,6 +399,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
335
399
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
336
400
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
337
401
|
noFeeAssets?: string[] | undefined;
|
|
402
|
+
defaultPairs?: {
|
|
403
|
+
standard: Record<string, string>;
|
|
404
|
+
other: Record<string, string>;
|
|
405
|
+
} | undefined;
|
|
338
406
|
}>;
|
|
339
407
|
refreshRate: number;
|
|
340
408
|
minimumVersion: string;
|
|
@@ -348,6 +416,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
348
416
|
bridgeIds?: string[] | undefined;
|
|
349
417
|
noFee?: boolean | undefined;
|
|
350
418
|
} | undefined> | undefined;
|
|
419
|
+
bip44DefaultPairs?: Record<string, {
|
|
420
|
+
standard: Record<string, string>;
|
|
421
|
+
other: Record<string, string>;
|
|
422
|
+
} | undefined> | undefined;
|
|
351
423
|
}) & {
|
|
352
424
|
clearCache: () => void;
|
|
353
425
|
resultsCount: () => number;
|
|
@@ -365,6 +437,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
365
437
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
366
438
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
367
439
|
noFeeAssets?: string[] | undefined;
|
|
440
|
+
defaultPairs?: {
|
|
441
|
+
standard: Record<string, string>;
|
|
442
|
+
other: Record<string, string>;
|
|
443
|
+
} | undefined;
|
|
368
444
|
}>;
|
|
369
445
|
refreshRate: number;
|
|
370
446
|
minimumVersion: string;
|
|
@@ -378,6 +454,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
378
454
|
bridgeIds?: string[] | undefined;
|
|
379
455
|
noFee?: boolean | undefined;
|
|
380
456
|
} | undefined> | undefined;
|
|
457
|
+
bip44DefaultPairs?: Record<string, {
|
|
458
|
+
standard: Record<string, string>;
|
|
459
|
+
other: Record<string, string>;
|
|
460
|
+
} | undefined> | undefined;
|
|
381
461
|
};
|
|
382
462
|
dependencies: [(state: RemoteFeatureFlagControllerState) => unknown];
|
|
383
463
|
recomputations: () => number;
|
|
@@ -416,6 +496,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
416
496
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
417
497
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
418
498
|
noFeeAssets?: string[] | undefined;
|
|
499
|
+
defaultPairs?: {
|
|
500
|
+
standard: Record<string, string>;
|
|
501
|
+
other: Record<string, string>;
|
|
502
|
+
} | undefined;
|
|
419
503
|
}>;
|
|
420
504
|
refreshRate: number;
|
|
421
505
|
minimumVersion: string;
|
|
@@ -429,6 +513,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
429
513
|
bridgeIds?: string[] | undefined;
|
|
430
514
|
noFee?: boolean | undefined;
|
|
431
515
|
} | undefined> | undefined;
|
|
516
|
+
bip44DefaultPairs?: Record<string, {
|
|
517
|
+
standard: Record<string, string>;
|
|
518
|
+
other: Record<string, string>;
|
|
519
|
+
} | undefined> | undefined;
|
|
432
520
|
}, resultFuncArgs_1: string | number | undefined) => number;
|
|
433
521
|
memoizedResultFunc: ((resultFuncArgs_0: {
|
|
434
522
|
support: boolean;
|
|
@@ -442,6 +530,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
442
530
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
443
531
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
444
532
|
noFeeAssets?: string[] | undefined;
|
|
533
|
+
defaultPairs?: {
|
|
534
|
+
standard: Record<string, string>;
|
|
535
|
+
other: Record<string, string>;
|
|
536
|
+
} | undefined;
|
|
445
537
|
}>;
|
|
446
538
|
refreshRate: number;
|
|
447
539
|
minimumVersion: string;
|
|
@@ -455,6 +547,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
455
547
|
bridgeIds?: string[] | undefined;
|
|
456
548
|
noFee?: boolean | undefined;
|
|
457
549
|
} | undefined> | undefined;
|
|
550
|
+
bip44DefaultPairs?: Record<string, {
|
|
551
|
+
standard: Record<string, string>;
|
|
552
|
+
other: Record<string, string>;
|
|
553
|
+
} | undefined> | undefined;
|
|
458
554
|
}, resultFuncArgs_1: string | number | undefined) => number) & {
|
|
459
555
|
clearCache: () => void;
|
|
460
556
|
resultsCount: () => number;
|
|
@@ -473,6 +569,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
473
569
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
474
570
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
475
571
|
noFeeAssets?: string[] | undefined;
|
|
572
|
+
defaultPairs?: {
|
|
573
|
+
standard: Record<string, string>;
|
|
574
|
+
other: Record<string, string>;
|
|
575
|
+
} | undefined;
|
|
476
576
|
}>;
|
|
477
577
|
refreshRate: number;
|
|
478
578
|
minimumVersion: string;
|
|
@@ -486,6 +586,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
486
586
|
bridgeIds?: string[] | undefined;
|
|
487
587
|
noFee?: boolean | undefined;
|
|
488
588
|
} | undefined> | undefined;
|
|
589
|
+
bip44DefaultPairs?: Record<string, {
|
|
590
|
+
standard: Record<string, string>;
|
|
591
|
+
other: Record<string, string>;
|
|
592
|
+
} | undefined> | undefined;
|
|
489
593
|
}) & {
|
|
490
594
|
clearCache: () => void;
|
|
491
595
|
resultsCount: () => number;
|
|
@@ -503,6 +607,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
503
607
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
504
608
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
505
609
|
noFeeAssets?: string[] | undefined;
|
|
610
|
+
defaultPairs?: {
|
|
611
|
+
standard: Record<string, string>;
|
|
612
|
+
other: Record<string, string>;
|
|
613
|
+
} | undefined;
|
|
506
614
|
}>;
|
|
507
615
|
refreshRate: number;
|
|
508
616
|
minimumVersion: string;
|
|
@@ -516,6 +624,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
516
624
|
bridgeIds?: string[] | undefined;
|
|
517
625
|
noFee?: boolean | undefined;
|
|
518
626
|
} | undefined> | undefined;
|
|
627
|
+
bip44DefaultPairs?: Record<string, {
|
|
628
|
+
standard: Record<string, string>;
|
|
629
|
+
other: Record<string, string>;
|
|
630
|
+
} | undefined> | undefined;
|
|
519
631
|
};
|
|
520
632
|
memoizedResultFunc: ((resultFuncArgs_0: any) => {
|
|
521
633
|
support: boolean;
|
|
@@ -529,6 +641,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
529
641
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
530
642
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
531
643
|
noFeeAssets?: string[] | undefined;
|
|
644
|
+
defaultPairs?: {
|
|
645
|
+
standard: Record<string, string>;
|
|
646
|
+
other: Record<string, string>;
|
|
647
|
+
} | undefined;
|
|
532
648
|
}>;
|
|
533
649
|
refreshRate: number;
|
|
534
650
|
minimumVersion: string;
|
|
@@ -542,6 +658,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
542
658
|
bridgeIds?: string[] | undefined;
|
|
543
659
|
noFee?: boolean | undefined;
|
|
544
660
|
} | undefined> | undefined;
|
|
661
|
+
bip44DefaultPairs?: Record<string, {
|
|
662
|
+
standard: Record<string, string>;
|
|
663
|
+
other: Record<string, string>;
|
|
664
|
+
} | undefined> | undefined;
|
|
545
665
|
}) & {
|
|
546
666
|
clearCache: () => void;
|
|
547
667
|
resultsCount: () => number;
|
|
@@ -559,6 +679,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
559
679
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
560
680
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
561
681
|
noFeeAssets?: string[] | undefined;
|
|
682
|
+
defaultPairs?: {
|
|
683
|
+
standard: Record<string, string>;
|
|
684
|
+
other: Record<string, string>;
|
|
685
|
+
} | undefined;
|
|
562
686
|
}>;
|
|
563
687
|
refreshRate: number;
|
|
564
688
|
minimumVersion: string;
|
|
@@ -572,6 +696,10 @@ export declare const selectIsQuoteExpired: ((state: RemoteFeatureFlagControllerS
|
|
|
572
696
|
bridgeIds?: string[] | undefined;
|
|
573
697
|
noFee?: boolean | undefined;
|
|
574
698
|
} | undefined> | undefined;
|
|
699
|
+
bip44DefaultPairs?: Record<string, {
|
|
700
|
+
standard: Record<string, string>;
|
|
701
|
+
other: Record<string, string>;
|
|
702
|
+
} | undefined> | undefined;
|
|
575
703
|
};
|
|
576
704
|
dependencies: [(state: RemoteFeatureFlagControllerState) => unknown];
|
|
577
705
|
recomputations: () => number;
|
|
@@ -15478,6 +15606,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15478
15606
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15479
15607
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15480
15608
|
noFeeAssets?: string[] | undefined;
|
|
15609
|
+
defaultPairs?: {
|
|
15610
|
+
standard: Record<string, string>;
|
|
15611
|
+
other: Record<string, string>;
|
|
15612
|
+
} | undefined;
|
|
15481
15613
|
}>;
|
|
15482
15614
|
refreshRate: number;
|
|
15483
15615
|
minimumVersion: string;
|
|
@@ -15491,6 +15623,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15491
15623
|
bridgeIds?: string[] | undefined;
|
|
15492
15624
|
noFee?: boolean | undefined;
|
|
15493
15625
|
} | undefined> | undefined;
|
|
15626
|
+
bip44DefaultPairs?: Record<string, {
|
|
15627
|
+
standard: Record<string, string>;
|
|
15628
|
+
other: Record<string, string>;
|
|
15629
|
+
} | undefined> | undefined;
|
|
15494
15630
|
}, resultFuncArgs_1: boolean | undefined, resultFuncArgs_2: number) => boolean;
|
|
15495
15631
|
memoizedResultFunc: ((resultFuncArgs_0: {
|
|
15496
15632
|
support: boolean;
|
|
@@ -15504,6 +15640,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15504
15640
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15505
15641
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15506
15642
|
noFeeAssets?: string[] | undefined;
|
|
15643
|
+
defaultPairs?: {
|
|
15644
|
+
standard: Record<string, string>;
|
|
15645
|
+
other: Record<string, string>;
|
|
15646
|
+
} | undefined;
|
|
15507
15647
|
}>;
|
|
15508
15648
|
refreshRate: number;
|
|
15509
15649
|
minimumVersion: string;
|
|
@@ -15517,6 +15657,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15517
15657
|
bridgeIds?: string[] | undefined;
|
|
15518
15658
|
noFee?: boolean | undefined;
|
|
15519
15659
|
} | undefined> | undefined;
|
|
15660
|
+
bip44DefaultPairs?: Record<string, {
|
|
15661
|
+
standard: Record<string, string>;
|
|
15662
|
+
other: Record<string, string>;
|
|
15663
|
+
} | undefined> | undefined;
|
|
15520
15664
|
}, resultFuncArgs_1: boolean | undefined, resultFuncArgs_2: number) => boolean) & {
|
|
15521
15665
|
clearCache: () => void;
|
|
15522
15666
|
resultsCount: () => number;
|
|
@@ -15535,6 +15679,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15535
15679
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15536
15680
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15537
15681
|
noFeeAssets?: string[] | undefined;
|
|
15682
|
+
defaultPairs?: {
|
|
15683
|
+
standard: Record<string, string>;
|
|
15684
|
+
other: Record<string, string>;
|
|
15685
|
+
} | undefined;
|
|
15538
15686
|
}>;
|
|
15539
15687
|
refreshRate: number;
|
|
15540
15688
|
minimumVersion: string;
|
|
@@ -15548,6 +15696,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15548
15696
|
bridgeIds?: string[] | undefined;
|
|
15549
15697
|
noFee?: boolean | undefined;
|
|
15550
15698
|
} | undefined> | undefined;
|
|
15699
|
+
bip44DefaultPairs?: Record<string, {
|
|
15700
|
+
standard: Record<string, string>;
|
|
15701
|
+
other: Record<string, string>;
|
|
15702
|
+
} | undefined> | undefined;
|
|
15551
15703
|
}) & {
|
|
15552
15704
|
clearCache: () => void;
|
|
15553
15705
|
resultsCount: () => number;
|
|
@@ -15565,6 +15717,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15565
15717
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15566
15718
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15567
15719
|
noFeeAssets?: string[] | undefined;
|
|
15720
|
+
defaultPairs?: {
|
|
15721
|
+
standard: Record<string, string>;
|
|
15722
|
+
other: Record<string, string>;
|
|
15723
|
+
} | undefined;
|
|
15568
15724
|
}>;
|
|
15569
15725
|
refreshRate: number;
|
|
15570
15726
|
minimumVersion: string;
|
|
@@ -15578,6 +15734,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15578
15734
|
bridgeIds?: string[] | undefined;
|
|
15579
15735
|
noFee?: boolean | undefined;
|
|
15580
15736
|
} | undefined> | undefined;
|
|
15737
|
+
bip44DefaultPairs?: Record<string, {
|
|
15738
|
+
standard: Record<string, string>;
|
|
15739
|
+
other: Record<string, string>;
|
|
15740
|
+
} | undefined> | undefined;
|
|
15581
15741
|
};
|
|
15582
15742
|
memoizedResultFunc: ((resultFuncArgs_0: any) => {
|
|
15583
15743
|
support: boolean;
|
|
@@ -15591,6 +15751,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15591
15751
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15592
15752
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15593
15753
|
noFeeAssets?: string[] | undefined;
|
|
15754
|
+
defaultPairs?: {
|
|
15755
|
+
standard: Record<string, string>;
|
|
15756
|
+
other: Record<string, string>;
|
|
15757
|
+
} | undefined;
|
|
15594
15758
|
}>;
|
|
15595
15759
|
refreshRate: number;
|
|
15596
15760
|
minimumVersion: string;
|
|
@@ -15604,6 +15768,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15604
15768
|
bridgeIds?: string[] | undefined;
|
|
15605
15769
|
noFee?: boolean | undefined;
|
|
15606
15770
|
} | undefined> | undefined;
|
|
15771
|
+
bip44DefaultPairs?: Record<string, {
|
|
15772
|
+
standard: Record<string, string>;
|
|
15773
|
+
other: Record<string, string>;
|
|
15774
|
+
} | undefined> | undefined;
|
|
15607
15775
|
}) & {
|
|
15608
15776
|
clearCache: () => void;
|
|
15609
15777
|
resultsCount: () => number;
|
|
@@ -15621,6 +15789,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15621
15789
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15622
15790
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15623
15791
|
noFeeAssets?: string[] | undefined;
|
|
15792
|
+
defaultPairs?: {
|
|
15793
|
+
standard: Record<string, string>;
|
|
15794
|
+
other: Record<string, string>;
|
|
15795
|
+
} | undefined;
|
|
15624
15796
|
}>;
|
|
15625
15797
|
refreshRate: number;
|
|
15626
15798
|
minimumVersion: string;
|
|
@@ -15634,6 +15806,10 @@ export declare const selectBridgeQuotes: ((state: BridgeControllerState & {
|
|
|
15634
15806
|
bridgeIds?: string[] | undefined;
|
|
15635
15807
|
noFee?: boolean | undefined;
|
|
15636
15808
|
} | undefined> | undefined;
|
|
15809
|
+
bip44DefaultPairs?: Record<string, {
|
|
15810
|
+
standard: Record<string, string>;
|
|
15811
|
+
other: Record<string, string>;
|
|
15812
|
+
} | undefined> | undefined;
|
|
15637
15813
|
};
|
|
15638
15814
|
dependencies: [(state: RemoteFeatureFlagControllerState) => unknown];
|
|
15639
15815
|
recomputations: () => number;
|
|
@@ -15680,6 +15856,10 @@ export declare const selectDefaultSlippagePercentage: ((state: BridgeControllerS
|
|
|
15680
15856
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15681
15857
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15682
15858
|
noFeeAssets?: string[] | undefined;
|
|
15859
|
+
defaultPairs?: {
|
|
15860
|
+
standard: Record<string, string>;
|
|
15861
|
+
other: Record<string, string>;
|
|
15862
|
+
} | undefined;
|
|
15683
15863
|
}>, resultFuncArgs_1: string | undefined, resultFuncArgs_2: string | undefined, resultFuncArgs_3: `${string}:${string}` | undefined, resultFuncArgs_4: `${string}:${string}` | undefined) => 2 | 0.5 | undefined;
|
|
15684
15864
|
memoizedResultFunc: ((resultFuncArgs_0: Record<string, {
|
|
15685
15865
|
isActiveSrc: boolean;
|
|
@@ -15691,6 +15871,10 @@ export declare const selectDefaultSlippagePercentage: ((state: BridgeControllerS
|
|
|
15691
15871
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15692
15872
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15693
15873
|
noFeeAssets?: string[] | undefined;
|
|
15874
|
+
defaultPairs?: {
|
|
15875
|
+
standard: Record<string, string>;
|
|
15876
|
+
other: Record<string, string>;
|
|
15877
|
+
} | undefined;
|
|
15694
15878
|
}>, resultFuncArgs_1: string | undefined, resultFuncArgs_2: string | undefined, resultFuncArgs_3: `${string}:${string}` | undefined, resultFuncArgs_4: `${string}:${string}` | undefined) => 2 | 0.5 | undefined) & {
|
|
15695
15879
|
clearCache: () => void;
|
|
15696
15880
|
resultsCount: () => number;
|
|
@@ -15707,6 +15891,10 @@ export declare const selectDefaultSlippagePercentage: ((state: BridgeControllerS
|
|
|
15707
15891
|
isSingleSwapBridgeButtonEnabled?: boolean | undefined;
|
|
15708
15892
|
isGaslessSwapEnabled?: boolean | undefined;
|
|
15709
15893
|
noFeeAssets?: string[] | undefined;
|
|
15894
|
+
defaultPairs?: {
|
|
15895
|
+
standard: Record<string, string>;
|
|
15896
|
+
other: Record<string, string>;
|
|
15897
|
+
} | undefined;
|
|
15710
15898
|
}>, (_: BridgeAppState, slippageParams: Parameters<typeof getDefaultSlippagePercentage>[0]) => string | undefined, (_: BridgeAppState, slippageParams: Parameters<typeof getDefaultSlippagePercentage>[0]) => string | undefined, (_: BridgeAppState, slippageParams: Parameters<typeof getDefaultSlippagePercentage>[0]) => `${string}:${string}` | undefined, (_: BridgeAppState, slippageParams: Parameters<typeof getDefaultSlippagePercentage>[0]) => `${string}:${string}` | undefined];
|
|
15711
15899
|
recomputations: () => number;
|
|
15712
15900
|
resetRecomputations: () => void;
|