1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-21 17:37:01 +01:00

Migrate to new controller packages (#16547)

* Migrate to new controller packages

`@metamask/controllers` is deprecated, and most of the controllers that
lived here are now located in their own package ([1]). This commit
replaces `@metamask/controllers` in `package.json` with references to
these packages and updates `import` lines to match.

[1]: https://github.com/MetaMask/controllers/pull/831

* Support GitHub registry for draft PRs (#16549)

* Add additional allowed host to lockfile linter

* Update LavaMoat policies

* Add policy exception for nanoid

* Add additional nanoid overrides

* Update LavaMoat policies again

* Bump controller packages

* Update lavamoat

* Bump controller packages

* Update packages to v1.0.0

* Expand gitignore comment

* Unpin controller dependencies, using ^ range instead

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
This commit is contained in:
Elliot Winkler 2022-11-24 12:59:07 -07:00 committed by GitHub
parent 5666d0a71c
commit 51cffa15dd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
26 changed files with 1739 additions and 2610 deletions

View File

@ -14,6 +14,9 @@ executors:
docker:
- image: koalaman/shellcheck-alpine@sha256:dfaf08fab58c158549d3be64fb101c626abc5f16f341b569092577ae207db199
orbs:
gh: circleci/github-cli@2.0
workflows:
test_and_release:
jobs:
@ -206,6 +209,27 @@ jobs:
- checkout
- restore_cache:
key: dependency-cache-v1-{{ checksum "yarn.lock" }}
- gh/install
- run:
name: Set IS_DRAFT environment variable
command: |
PR_NUMBER="${CIRCLE_PULL_REQUEST##*/}"
if [ -n "$PR_NUMBER" ]
then
echo "IS_DRAFT=$(gh pr view --json isDraft --jq '.isDraft' "$PR_NUMBER")" >> "$BASH_ENV"
source "$BASH_ENV"
else
echo "Not a PR; skipping"
fi
- run:
name: Setup registry config for using package previews on draft PRs
command: |
if [[ $IS_DRAFT == 'true' ]]
then
printf '%s\n\n%s' '@metamask:registry=https://npm.pkg.github.com' "//npm.pkg.github.com/:_authToken=${GITHUB_PACKAGE_READ_TOKEN}" > .npmrc
else
echo "Not draft; skipping GitHub registry setup"
fi
- run:
name: Install deps
command: |

6
.gitignore vendored
View File

@ -55,4 +55,8 @@ notes.txt
tsout/
# Test results
test-results/
test-results/
# This file is used to authenticate with the GitHub Package registry, to
# enable the use of @metamask preview builds.
.npmrc

View File

@ -3,12 +3,12 @@ import sinon from 'sinon';
import nock from 'nock';
import { ObservableStore } from '@metamask/obs-store';
import BigNumber from 'bignumber.js';
import { ControllerMessenger } from '@metamask/base-controller';
import {
ControllerMessenger,
TokenListController,
TokensController,
AssetsContractController,
} from '@metamask/controllers';
} from '@metamask/assets-controllers';
import { NETWORK_TYPES } from '../../../shared/constants/network';
import { toChecksumHexAddress } from '../../../shared/modules/hexstring-utils';
import DetectTokensController from './detect-tokens';

View File

@ -1,4 +1,4 @@
import { CaveatMutatorOperation } from '@metamask/controllers';
import { CaveatMutatorOperation } from '@metamask/permission-controller';
import { CaveatTypes } from '../../../../shared/constants/permissions';
/**

View File

@ -1,4 +1,4 @@
import { CaveatMutatorOperation } from '@metamask/controllers';
import { CaveatMutatorOperation } from '@metamask/permission-controller';
import { CaveatTypes } from '../../../../shared/constants/permissions';
import { CaveatMutatorFactories } from './caveat-mutators';

View File

@ -1,4 +1,7 @@
import { constructPermission, PermissionType } from '@metamask/controllers';
import {
constructPermission,
PermissionType,
} from '@metamask/permission-controller';
///: BEGIN:ONLY_INCLUDE_IN(flask)
import { endowmentCaveatSpecifications as snapsEndowmentCaveatSpecifications } from '@metamask/snaps-controllers';
import { caveatSpecifications as snapsCaveatsSpecifications } from '@metamask/rpc-methods';

View File

@ -1,9 +1,7 @@
import { strict as assert } from 'assert';
import sinon from 'sinon';
import {
ControllerMessenger,
TokenListController,
} from '@metamask/controllers';
import { ControllerMessenger } from '@metamask/base-controller';
import { TokenListController } from '@metamask/assets-controllers';
import { CHAIN_IDS } from '../../../shared/constants/network';
import PreferencesController from './preferences';
import NetworkController from './network';

View File

@ -1,8 +1,8 @@
import { ObservableStore } from '@metamask/obs-store';
import { getPersistentState } from '@metamask/controllers';
import { getPersistentState } from '@metamask/base-controller';
/**
* @typedef {import('@metamask/controllers').ControllerMessenger} ControllerMessenger
* @typedef {import('@metamask/base-controller').ControllerMessenger} ControllerMessenger
*/
/**
@ -13,7 +13,7 @@ export default class ComposableObservableStore extends ObservableStore {
/**
* Describes which stores are being composed. The key is the name of the
* store, and the value is either an ObserableStore, or a controller that
* extends one of the two base controllers in the `@metamask/controllers`
* extends one of the two base controllers in the `@metamask/base-controller`
* package.
*
* @type {Record<string, object>}
@ -46,7 +46,7 @@ export default class ComposableObservableStore extends ObservableStore {
* @param {Record<string, object>} config - Describes which stores are being
* composed. The key is the name of the store, and the value is either an
* ObserableStore, or a controller that extends one of the two base
* controllers in the `@metamask/controllers` package.
* controllers in the `@metamask/base-controller` package.
*/
updateStructure(config) {
this.config = config;

View File

@ -3,7 +3,7 @@ import {
BaseController,
BaseControllerV2,
ControllerMessenger,
} from '@metamask/controllers';
} from '@metamask/base-controller';
import ComposableObservableStore from './ComposableObservableStore';
class OldExampleController extends BaseController {

View File

@ -1,7 +1,7 @@
///: BEGIN:ONLY_INCLUDE_IN(flask)
import { handlers as permittedSnapMethods } from '@metamask/rpc-methods/dist/permitted';
///: END:ONLY_INCLUDE_IN
import { permissionRpcMethods } from '@metamask/controllers';
import { permissionRpcMethods } from '@metamask/permission-controller';
import { selectHooks } from '@metamask/rpc-methods/dist/utils';
import { ethErrors } from 'eth-rpc-errors';
import { flatten } from 'lodash';

View File

@ -2,10 +2,8 @@ import { strict as assert } from 'assert';
import sinon from 'sinon';
import proxyquire from 'proxyquire';
import {
ApprovalRequestNotFoundError,
PermissionsRequestNotFoundError,
} from '@metamask/controllers';
import { ApprovalRequestNotFoundError } from '@metamask/approval-controller';
import { PermissionsRequestNotFoundError } from '@metamask/permission-controller';
import { ORIGIN_METAMASK } from '../../shared/constants/app';
const Ganache = require('../../test/e2e/ganache');

View File

@ -23,29 +23,33 @@ import { MetaMaskKeyring as QRHardwareKeyring } from '@keystonehq/metamask-airga
import EthQuery from 'eth-query';
import nanoid from 'nanoid';
import { captureException } from '@sentry/browser';
import { AddressBookController } from '@metamask/address-book-controller';
import {
AddressBookController,
ApprovalController,
ControllerMessenger,
ApprovalRequestNotFoundError,
} from '@metamask/approval-controller';
import { ControllerMessenger } from '@metamask/base-controller';
import {
CurrencyRateController,
PhishingController,
AnnouncementController,
GasFeeController,
TokenListController,
TokensController,
TokenRatesController,
NftController,
AssetsContractController,
NftDetectionController,
} from '@metamask/assets-controllers';
import { PhishingController } from '@metamask/phishing-controller';
import { AnnouncementController } from '@metamask/announcement-controller';
import { GasFeeController } from '@metamask/gas-fee-controller';
import {
PermissionController,
SubjectMetadataController,
PermissionsRequestNotFoundError,
ApprovalRequestNotFoundError,
///: BEGIN:ONLY_INCLUDE_IN(flask)
RateLimitController,
NotificationController,
///: END:ONLY_INCLUDE_IN
} from '@metamask/controllers';
} from '@metamask/permission-controller';
import { SubjectMetadataController } from '@metamask/subject-metadata-controller';
///: BEGIN:ONLY_INCLUDE_IN(flask)
import { RateLimitController } from '@metamask/rate-limit-controller';
import { NotificationController } from '@metamask/notification-controller';
///: END:ONLY_INCLUDE_IN
import SmartTransactionsController from '@metamask/smart-transactions-controller';
///: BEGIN:ONLY_INCLUDE_IN(flask)
import {
@ -167,7 +171,7 @@ export const METAMASK_CONTROLLER_EVENTS = {
// Fired after state changes that impact the extension badge (unapproved msg count)
// The process of updating the badge happens in app/scripts/background.js.
UPDATE_BADGE: 'updateBadge',
// TODO: Add this and similar enums to @metamask/controllers and export them
// TODO: Add this and similar enums to the `controllers` repo and export them
APPROVAL_STATE_CHANGE: 'ApprovalController:stateChange',
};
@ -1276,8 +1280,8 @@ export default class MetamaskController extends EventEmitter {
* changes.
*
* Some of the subscriptions in this method are ControllerMessenger selector
* event subscriptions. See the relevant @metamask/controllers documentation
* for more information.
* event subscriptions. See the relevant documentation for
* `@metamask/base-controller` for more information.
*
* Note that account-related notifications emitted when the extension
* becomes unlocked are handled in MetaMaskController._onUnlock.

View File

@ -1,5 +1,5 @@
import { cloneDeep } from 'lodash';
import { util } from '@metamask/controllers';
import { normalizeEnsName } from '@metamask/controller-utils';
const version = 37;
@ -38,7 +38,7 @@ function transformState(state) {
for (const address in ab) {
if (ab[address].chainId === id) {
ab[address].isEns = false;
if (util.normalizeEnsName(ab[address].name)) {
if (normalizeEnsName(ab[address].name)) {
ab[address].isEns = true;
}
newAddressBook[id][address] = ab[address];

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -87,6 +87,21 @@
"crypto.getRandomValues": true
}
},
"@metamask/approval-controller>nanoid": {
"globals": {
"crypto.getRandomValues": true
}
},
"@metamask/permission-controller>nanoid": {
"globals": {
"crypto.getRandomValues": true
}
},
"@metamask/notification-controller>nanoid": {
"globals": {
"crypto.getRandomValues": true
}
},
"@metamask/snaps-controllers>nanoid": {
"globals": {
"crypto.getRandomValues": true
@ -97,6 +112,11 @@
"crypto.getRandomValues": true
}
},
"@metamask/rpc-methods>@metamask/controllers>nanoid": {
"globals": {
"crypto.getRandomValues": true
}
},
"@metamask/controllers>nanoid": {
"globals": {
"crypto.getRandomValues": true

View File

@ -1813,7 +1813,6 @@
},
"packages": {
"chokidar>braces": true,
"chokidar>fsevents": true,
"chokidar>glob-parent": true,
"chokidar>is-binary-path": true,
"chokidar>normalize-path": true,
@ -1840,12 +1839,6 @@
"chokidar>braces>fill-range>to-regex-range>is-number": true
}
},
"chokidar>fsevents": {
"globals": {
"process.platform": true
},
"native": true
},
"chokidar>glob-parent": {
"builtin": {
"os.platform": true,
@ -4191,7 +4184,6 @@
"gulp-watch>chokidar>anymatch": true,
"gulp-watch>chokidar>async-each": true,
"gulp-watch>chokidar>braces": true,
"gulp-watch>chokidar>fsevents": true,
"gulp-watch>chokidar>is-binary-path": true,
"gulp-watch>chokidar>normalize-path": true,
"gulp-watch>chokidar>readdirp": true,
@ -4340,389 +4332,6 @@
"webpack>micromatch>braces>fill-range>repeat-string": true
}
},
"gulp-watch>chokidar>fsevents": {
"builtin": {
"events.EventEmitter": true,
"fs.stat": true,
"path.join": true,
"util.inherits": true
},
"globals": {
"__dirname": true,
"process.nextTick": true,
"process.platform": true,
"setImmediate": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp": {
"builtin": {
"events.EventEmitter": true,
"fs.existsSync": true,
"fs.readFileSync": true,
"fs.renameSync": true,
"path.dirname": true,
"path.existsSync": true,
"path.join": true,
"path.resolve": true,
"url.parse": true,
"url.resolve": true,
"util.inherits": true
},
"globals": {
"__dirname": true,
"console.log": true,
"process.arch": true,
"process.cwd": true,
"process.env": true,
"process.platform": true,
"process.version.substr": true,
"process.versions": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>detect-libc": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>semver": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>detect-libc": {
"builtin": {
"child_process.spawnSync": true,
"fs.readdirSync": true,
"os.platform": true
},
"globals": {
"process.env": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt": {
"builtin": {
"path": true,
"stream.Stream": true,
"url": true
},
"globals": {
"console": true,
"process.argv": true,
"process.env.DEBUG_NOPT": true,
"process.env.NOPT_DEBUG": true,
"process.platform": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt>abbrev": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt>osenv": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt>osenv": {
"builtin": {
"child_process.exec": true,
"path": true
},
"globals": {
"process.env.COMPUTERNAME": true,
"process.env.ComSpec": true,
"process.env.EDITOR": true,
"process.env.HOSTNAME": true,
"process.env.PATH": true,
"process.env.PROMPT": true,
"process.env.PS1": true,
"process.env.Path": true,
"process.env.SHELL": true,
"process.env.USER": true,
"process.env.USERDOMAIN": true,
"process.env.USERNAME": true,
"process.env.VISUAL": true,
"process.env.path": true,
"process.nextTick": true,
"process.platform": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt>osenv>os-homedir": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt>osenv>os-tmpdir": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt>osenv>os-homedir": {
"builtin": {
"os.homedir": true
},
"globals": {
"process.env": true,
"process.getuid": true,
"process.platform": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>nopt>osenv>os-tmpdir": {
"globals": {
"process.env.SystemRoot": true,
"process.env.TEMP": true,
"process.env.TMP": true,
"process.env.TMPDIR": true,
"process.env.windir": true,
"process.platform": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog": {
"builtin": {
"events.EventEmitter": true,
"util": true
},
"globals": {
"process.nextTick": true,
"process.stderr": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>console-control-strings": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>set-blocking": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet": {
"builtin": {
"events.EventEmitter": true,
"util.inherits": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>delegates": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream": {
"builtin": {
"events.EventEmitter": true,
"stream": true,
"util": true
},
"globals": {
"process.browser": true,
"process.env.READABLE_STREAM": true,
"process.stderr": true,
"process.stdout": true,
"process.version.slice": true,
"setImmediate": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>core-util-is": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>isarray": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>process-nextick-args": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>string_decoder": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>util-deprecate": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>inherits": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>tar>safe-buffer": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>core-util-is": {
"globals": {
"Buffer.isBuffer": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>process-nextick-args": {
"globals": {
"process": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>string_decoder": {
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>tar>safe-buffer": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>util-deprecate": {
"builtin": {
"util.deprecate": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge": {
"builtin": {
"util.format": true
},
"globals": {
"clearInterval": true,
"process": true,
"setImmediate": true,
"setInterval": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>console-control-strings": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>aproba": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>has-unicode": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>object-assign": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>signal-exit": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>strip-ansi": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>wide-align": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>has-unicode": {
"builtin": {
"os.type": true
},
"globals": {
"process.env.LANG": true,
"process.env.LC_ALL": true,
"process.env.LC_CTYPE": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>signal-exit": {
"builtin": {
"assert.equal": true,
"events": true
},
"globals": {
"process": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width": {
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width>code-point-at": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width>is-fullwidth-code-point": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>strip-ansi": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width>is-fullwidth-code-point": {
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width>is-fullwidth-code-point>number-is-nan": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>strip-ansi": {
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>strip-ansi>ansi-regex": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>wide-align": {
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>npmlog>set-blocking": {
"globals": {
"process.stderr": true,
"process.stdout": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf": {
"builtin": {
"assert": true,
"fs": true,
"path.join": true
},
"globals": {
"process.platform": true,
"setTimeout": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob": {
"builtin": {
"assert": true,
"events.EventEmitter": true,
"fs.lstat": true,
"fs.lstatSync": true,
"fs.readdir": true,
"fs.readdirSync": true,
"fs.stat": true,
"fs.statSync": true,
"path.join": true,
"path.resolve": true,
"util": true
},
"globals": {
"console.error": true,
"process.cwd": true,
"process.nextTick": true,
"process.platform": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>fs.realpath": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>inflight": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>inherits": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>once": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>path-is-absolute": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>fs.realpath": {
"builtin": {
"fs.lstat": true,
"fs.lstatSync": true,
"fs.readlink": true,
"fs.readlinkSync": true,
"fs.realpath": true,
"fs.realpathSync": true,
"fs.stat": true,
"fs.statSync": true,
"path.normalize": true,
"path.resolve": true
},
"globals": {
"console.error": true,
"console.trace": true,
"process.env.NODE_DEBUG": true,
"process.nextTick": true,
"process.noDeprecation": true,
"process.platform": true,
"process.throwDeprecation": true,
"process.traceDeprecation": true,
"process.version": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>inflight": {
"globals": {
"process.nextTick": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>once": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>once>wrappy": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>inherits": {
"builtin": {
"util.inherits": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch": {
"builtin": {
"path": true
},
"globals": {
"console.error": true
},
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch>brace-expansion": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch>brace-expansion": {
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch>brace-expansion>balanced-match": true,
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch>brace-expansion>concat-map": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>once": {
"packages": {
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>once>wrappy": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>rimraf>glob>path-is-absolute": {
"globals": {
"process.platform": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>semver": {
"globals": {
"console": true,
"process": true
}
},
"gulp-watch>chokidar>fsevents>node-pre-gyp>tar>safe-buffer": {
"builtin": {
"buffer": true
}
},
"gulp-watch>chokidar>is-binary-path": {
"builtin": {
"path.extname": true
@ -5223,7 +4832,6 @@
"gulp-watch>path-is-absolute": true,
"gulp>glob-watcher>anymatch": true,
"gulp>glob-watcher>chokidar>braces": true,
"gulp>glob-watcher>chokidar>fsevents": true,
"gulp>glob-watcher>chokidar>is-binary-path": true,
"gulp>glob-watcher>chokidar>normalize-path": true,
"gulp>glob-watcher>chokidar>readdirp": true,
@ -5272,389 +4880,6 @@
"webpack>micromatch>braces>fill-range>repeat-string": true
}
},
"gulp>glob-watcher>chokidar>fsevents": {
"builtin": {
"events.EventEmitter": true,
"fs.stat": true,
"path.join": true,
"util.inherits": true
},
"globals": {
"__dirname": true,
"process.nextTick": true,
"process.platform": true,
"setImmediate": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp": {
"builtin": {
"events.EventEmitter": true,
"fs.existsSync": true,
"fs.readFileSync": true,
"fs.renameSync": true,
"path.dirname": true,
"path.existsSync": true,
"path.join": true,
"path.resolve": true,
"url.parse": true,
"url.resolve": true,
"util.inherits": true
},
"globals": {
"__dirname": true,
"console.log": true,
"process.arch": true,
"process.cwd": true,
"process.env": true,
"process.platform": true,
"process.version.substr": true,
"process.versions": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>detect-libc": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>semver": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>detect-libc": {
"builtin": {
"child_process.spawnSync": true,
"fs.readdirSync": true,
"os.platform": true
},
"globals": {
"process.env": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt": {
"builtin": {
"path": true,
"stream.Stream": true,
"url": true
},
"globals": {
"console": true,
"process.argv": true,
"process.env.DEBUG_NOPT": true,
"process.env.NOPT_DEBUG": true,
"process.platform": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt>abbrev": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt>osenv": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt>osenv": {
"builtin": {
"child_process.exec": true,
"path": true
},
"globals": {
"process.env.COMPUTERNAME": true,
"process.env.ComSpec": true,
"process.env.EDITOR": true,
"process.env.HOSTNAME": true,
"process.env.PATH": true,
"process.env.PROMPT": true,
"process.env.PS1": true,
"process.env.Path": true,
"process.env.SHELL": true,
"process.env.USER": true,
"process.env.USERDOMAIN": true,
"process.env.USERNAME": true,
"process.env.VISUAL": true,
"process.env.path": true,
"process.nextTick": true,
"process.platform": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt>osenv>os-homedir": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt>osenv>os-tmpdir": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt>osenv>os-homedir": {
"builtin": {
"os.homedir": true
},
"globals": {
"process.env": true,
"process.getuid": true,
"process.platform": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>nopt>osenv>os-tmpdir": {
"globals": {
"process.env.SystemRoot": true,
"process.env.TEMP": true,
"process.env.TMP": true,
"process.env.TMPDIR": true,
"process.env.windir": true,
"process.platform": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog": {
"builtin": {
"events.EventEmitter": true,
"util": true
},
"globals": {
"process.nextTick": true,
"process.stderr": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>console-control-strings": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>set-blocking": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet": {
"builtin": {
"events.EventEmitter": true,
"util.inherits": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>delegates": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream": {
"builtin": {
"events.EventEmitter": true,
"stream": true,
"util": true
},
"globals": {
"process.browser": true,
"process.env.READABLE_STREAM": true,
"process.stderr": true,
"process.stdout": true,
"process.version.slice": true,
"setImmediate": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>core-util-is": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>isarray": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>process-nextick-args": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>string_decoder": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>util-deprecate": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>inherits": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>tar>safe-buffer": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>core-util-is": {
"globals": {
"Buffer.isBuffer": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>process-nextick-args": {
"globals": {
"process": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>string_decoder": {
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>tar>safe-buffer": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>are-we-there-yet>readable-stream>util-deprecate": {
"builtin": {
"util.deprecate": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge": {
"builtin": {
"util.format": true
},
"globals": {
"clearInterval": true,
"process": true,
"setImmediate": true,
"setInterval": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>console-control-strings": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>aproba": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>has-unicode": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>object-assign": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>signal-exit": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>strip-ansi": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>wide-align": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>has-unicode": {
"builtin": {
"os.type": true
},
"globals": {
"process.env.LANG": true,
"process.env.LC_ALL": true,
"process.env.LC_CTYPE": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>signal-exit": {
"builtin": {
"assert.equal": true,
"events": true
},
"globals": {
"process": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width": {
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width>code-point-at": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width>is-fullwidth-code-point": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>strip-ansi": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width>is-fullwidth-code-point": {
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width>is-fullwidth-code-point>number-is-nan": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>strip-ansi": {
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>strip-ansi>ansi-regex": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>wide-align": {
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>gauge>string-width": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>npmlog>set-blocking": {
"globals": {
"process.stderr": true,
"process.stdout": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf": {
"builtin": {
"assert": true,
"fs": true,
"path.join": true
},
"globals": {
"process.platform": true,
"setTimeout": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob": {
"builtin": {
"assert": true,
"events.EventEmitter": true,
"fs.lstat": true,
"fs.lstatSync": true,
"fs.readdir": true,
"fs.readdirSync": true,
"fs.stat": true,
"fs.statSync": true,
"path.join": true,
"path.resolve": true,
"util": true
},
"globals": {
"console.error": true,
"process.cwd": true,
"process.nextTick": true,
"process.platform": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>fs.realpath": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>inflight": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>inherits": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>once": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>path-is-absolute": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>fs.realpath": {
"builtin": {
"fs.lstat": true,
"fs.lstatSync": true,
"fs.readlink": true,
"fs.readlinkSync": true,
"fs.realpath": true,
"fs.realpathSync": true,
"fs.stat": true,
"fs.statSync": true,
"path.normalize": true,
"path.resolve": true
},
"globals": {
"console.error": true,
"console.trace": true,
"process.env.NODE_DEBUG": true,
"process.nextTick": true,
"process.noDeprecation": true,
"process.platform": true,
"process.throwDeprecation": true,
"process.traceDeprecation": true,
"process.version": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>inflight": {
"globals": {
"process.nextTick": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>once": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>once>wrappy": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>inherits": {
"builtin": {
"util.inherits": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch": {
"builtin": {
"path": true
},
"globals": {
"console.error": true
},
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch>brace-expansion": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch>brace-expansion": {
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch>brace-expansion>balanced-match": true,
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>minimatch>brace-expansion>concat-map": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>once": {
"packages": {
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>once>wrappy": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>rimraf>glob>path-is-absolute": {
"globals": {
"process.platform": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>semver": {
"globals": {
"console": true,
"process": true
}
},
"gulp>glob-watcher>chokidar>fsevents>node-pre-gyp>tar>safe-buffer": {
"builtin": {
"buffer": true
}
},
"gulp>glob-watcher>chokidar>is-binary-path": {
"builtin": {
"path.extname": true

View File

@ -51,7 +51,7 @@
"lint:changelog:rc": "auto-changelog validate --rc",
"lint:eslint": "eslint . --ext js,ts,tsx,snap --cache",
"lint:eslint:fix": "yarn lint:eslint --fix",
"lint:lockfile": "lockfile-lint --path yarn.lock --allowed-hosts npm yarn github.com codeload.github.com --empty-hostname false --allowed-schemes \"https:\" \"git+https:\"",
"lint:lockfile": "lockfile-lint --path yarn.lock --allowed-hosts npm yarn github.com codeload.github.com npm.pkg.github.com --empty-hostname false --allowed-schemes \"https:\" \"git+https:\"",
"lint:shellcheck": "./development/shellcheck.sh",
"lint:styles": "stylelint '*/**/*.scss'",
"lint:styles:fix": "yarn lint:styles --fix",
@ -109,24 +109,35 @@
"@keystonehq/bc-ur-registry-eth": "^0.12.1",
"@keystonehq/metamask-airgapped-keyring": "^0.6.1",
"@material-ui/core": "^4.11.0",
"@metamask/address-book-controller": "^1.0.0",
"@metamask/announcement-controller": "^1.0.0",
"@metamask/approval-controller": "^1.0.0",
"@metamask/assets-controllers": "^1.0.0",
"@metamask/base-controller": "^1.0.0",
"@metamask/contract-metadata": "^1.31.0",
"@metamask/controllers": "^33.0.0",
"@metamask/controller-utils": "^1.0.0",
"@metamask/design-tokens": "^1.9.0",
"@metamask/eth-json-rpc-infura": "^7.0.0",
"@metamask/eth-ledger-bridge-keyring": "^0.13.0",
"@metamask/eth-token-tracker": "^4.0.0",
"@metamask/etherscan-link": "^2.2.0",
"@metamask/gas-fee-controller": "^1.0.0",
"@metamask/jazzicon": "^2.0.0",
"@metamask/logo": "^3.1.1",
"@metamask/metamask-eth-abis": "^3.0.0",
"@metamask/notification-controller": "^1.0.0",
"@metamask/obs-store": "^5.0.0",
"@metamask/permission-controller": "^1.0.0",
"@metamask/phishing-controller": "^1.0.0",
"@metamask/post-message-stream": "^6.0.0",
"@metamask/providers": "^10.0.0",
"@metamask/rate-limit-controller": "^1.0.0",
"@metamask/rpc-methods": "^0.24.1",
"@metamask/slip44": "^2.1.0",
"@metamask/smart-transactions-controller": "^3.0.0",
"@metamask/snaps-controllers": "^0.24.1",
"@metamask/snaps-utils": "^0.24.1",
"@metamask/subject-metadata-controller": "^1.0.0",
"@ngraveio/bc-ur": "^1.1.6",
"@popperjs/core": "^2.4.0",
"@reduxjs/toolkit": "^1.6.2",
@ -454,7 +465,8 @@
"web3>web3-core>web3-core-requestmanager>web3-providers-ws>websocket>es5-ext": false,
"web3>web3-core>web3-core-requestmanager>web3-providers-ws>websocket>utf-8-validate": false,
"web3>web3-shh": false,
"@keystonehq/metamask-airgapped-keyring>@keystonehq/base-eth-keyring>hdkey>secp256k1": false
"@keystonehq/metamask-airgapped-keyring>@keystonehq/base-eth-keyring>hdkey>secp256k1": false,
"@metamask/base-controller>simple-git-hooks": false
}
}
}

View File

@ -27,6 +27,9 @@ export const GAS_LIMITS = {
* These are already declared in @metamask/controllers but importing them from
* that module and re-exporting causes the UI bundle size to expand beyond 4MB
*
* (TODO: This comment was added before @metamask/controllers was split up
* revisit now that @metamask/gas-fee-controller is available)
*
* @type {GasEstimateTypes}
*/
export const GAS_ESTIMATE_TYPES = {

View File

@ -133,16 +133,16 @@ import {
* import('../../../shared/constants/transaction').TransactionTypeString
* )} TransactionTypeString
* @typedef {(
* import('@metamask/controllers').LegacyGasPriceEstimate
* import('@metamask/gas-fee-controller').LegacyGasPriceEstimate
* )} LegacyGasPriceEstimate
* @typedef {(
* import('@metamask/controllers').GasFeeEstimates
* import('@metamask/gas-fee-controller').GasFeeEstimates
* )} GasFeeEstimates
* @typedef {(
* import('@metamask/controllers').EthGasPriceEstimate
* import('@metamask/gas-fee-controller').EthGasPriceEstimate
* )} EthGasPriceEstimate
* @typedef {(
* import('@metamask/controllers').GasEstimateType
* import('@metamask/gas-fee-controller').GasEstimateType
* )} GasEstimateType
* @typedef {(
* import('redux').AnyAction

View File

@ -3,7 +3,7 @@ import abi from 'human-standard-token-abi';
import BigNumber from 'bignumber.js';
import * as ethUtil from 'ethereumjs-util';
import { DateTime } from 'luxon';
import { getFormattedIpfsUrl } from '@metamask/controllers/dist/util';
import { getFormattedIpfsUrl } from '@metamask/assets-controllers';
import slip44 from '@metamask/slip44';
import { CHAIN_IDS } from '../../../shared/constants/network';
import {

View File

@ -13,10 +13,10 @@ import { useSafeGasEstimatePolling } from './useSafeGasEstimatePolling';
* @typedef {object} GasEstimates
* @property {GasEstimateTypes} gasEstimateType - The type of estimate provided
* @property {import(
* '@metamask/controllers'
* '@metamask/gas-fee-controller'
* ).GasFeeState['gasFeeEstimates']} gasFeeEstimates - The estimate object
* @property {import(
* '@metamask/controllers'
* '@metamask/gas-fee-controller'
* ).GasFeeState['estimatedGasFeeTimeBounds']} [estimatedGasFeeTimeBounds] -
* estimated time boundaries for fee-market type estimates
* @property {boolean} isGasEstimateLoading - indicates whether the gas

View File

@ -2,7 +2,7 @@ import { useMemo } from 'react';
import { shallowEqual, useSelector } from 'react-redux';
import BigNumber from 'bignumber.js';
import { isEqual, uniqBy } from 'lodash';
import { formatIconUrlWithProxy } from '@metamask/controllers';
import { formatIconUrlWithProxy } from '@metamask/assets-controllers';
import { getTokenFiatAmount } from '../helpers/utils/token-util';
import {
getTokenExchangeRates,

View File

@ -1,7 +1,7 @@
import React, { useContext, useState } from 'react';
import { useHistory } from 'react-router-dom';
import { useDispatch, useSelector } from 'react-redux';
import { util } from '@metamask/controllers';
import { isValidHexAddress } from '@metamask/controller-utils';
import { useI18nContext } from '../../hooks/useI18nContext';
import { DEFAULT_ROUTE } from '../../helpers/constants/routes';
import {
@ -94,12 +94,12 @@ export default function AddCollectible() {
};
const validateAndSetAddress = (val) => {
setDisabled(!util.isValidHexAddress(val) || !tokenId);
setDisabled(!isValidHexAddress(val) || !tokenId);
setAddress(val);
};
const validateAndSetTokenId = (val) => {
setDisabled(!util.isValidHexAddress(address) || !val || isNaN(Number(val)));
setDisabled(!isValidHexAddress(address) || !val || isNaN(Number(val)));
setTokenId(val);
};

221
yarn.lock
View File

@ -2761,6 +2761,59 @@
resolved "https://registry.yarnpkg.com/@mdx-js/util/-/util-1.6.22.tgz#219dfd89ae5b97a8801f015323ffa4b62f45718b"
integrity sha512-H1rQc1ZOHANWBvPcW+JpGwr+juXSxM8Q8YCkm3GhZd8REu1fHR3z99CErO1p9pkcfcxZnMdIZdIsXkOHY0NilA==
"@metamask/address-book-controller@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/address-book-controller/-/address-book-controller-1.0.0.tgz#b9899164384672a0e85ddee49b7809dcf5083182"
integrity sha512-LNDbSPxfFQPnUYAFE2JDTeeuvAwCcw07aqCvvePUGYVG4NJ1GXurcyhcTkMNr3RRuJIKni8YlvDo3H7X+fWVtg==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/controller-utils" "~1.0.0"
"@metamask/announcement-controller@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/announcement-controller/-/announcement-controller-1.0.0.tgz#4173ee68bfd10f8b2078b75f9f59665c7414c245"
integrity sha512-9noNDpQ2x19VQkF5/TuBaPZFXw/lf73w/8rzZSItR5w91oIr7mvLC4gNQlXxC5S6thcrjEo+aY7vnw3IAFvRXQ==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/approval-controller@^1.0.0", "@metamask/approval-controller@~1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/approval-controller/-/approval-controller-1.0.0.tgz#2dc8144f89756b955250b183f07ba08e223aa441"
integrity sha512-iP7SrvvSC6JQ78j6Yy4whs839xq15OAB81Q+UJ6tOqGaT9BpN/PBHeP8x5c1Ov3pCQkBi9Y+n5VlfJz5dGS7+Q==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/controller-utils" "~1.0.0"
eth-rpc-errors "^4.0.0"
immer "^9.0.6"
nanoid "^3.1.31"
"@metamask/assets-controllers@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/assets-controllers/-/assets-controllers-1.0.0.tgz#10ee4e0bd005a2d26b78562641250a153cba5618"
integrity sha512-QUTtp4xJrh6sSkAByh0c7U7x2n50zU5wF++tkutsVyoQGwSurX8ZQwvf8W3l+3ARzHxy/l+Zc3JFhysJ9dn2Xw==
dependencies:
"@ethersproject/abi" "^5.7.0"
"@ethersproject/bignumber" "^5.7.0"
"@ethersproject/contracts" "^5.7.0"
"@ethersproject/providers" "^5.7.0"
"@metamask/base-controller" "~1.0.0"
"@metamask/contract-metadata" "^1.35.0"
"@metamask/controller-utils" "~1.0.0"
"@metamask/metamask-eth-abis" "3.0.0"
"@metamask/network-controller" "~1.0.0"
"@metamask/preferences-controller" "~1.0.0"
"@types/uuid" "^8.3.0"
abort-controller "^3.0.0"
async-mutex "^0.2.6"
babel-runtime "^6.26.0"
eth-query "^2.1.2"
eth-rpc-errors "^4.0.0"
ethereumjs-util "^7.0.10"
immer "^9.0.6"
multiformats "^9.5.2"
single-call-balance-checker-abi "^1.0.0"
uuid "^8.3.2"
"@metamask/auto-changelog@^2.1.0":
version "2.6.1"
resolved "https://registry.yarnpkg.com/@metamask/auto-changelog/-/auto-changelog-2.6.1.tgz#5a6291df6c1592f010bd54f1a97814a4570b1eaf"
@ -2771,6 +2824,14 @@
semver "^7.3.5"
yargs "^17.0.1"
"@metamask/base-controller@^1.0.0", "@metamask/base-controller@~1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/base-controller/-/base-controller-1.0.0.tgz#9de86efafdf88b46f6d3710f8708a9515fd8ecf6"
integrity sha512-bZnv/P3Zb247vVS4HT3lvlNdi0JNT5mt3dWBtWj6c9C/AVR9LDeTUz7nIPxzvm9lwDZktYgp+GXDDr/LfDKkAQ==
dependencies:
"@metamask/controller-utils" "~1.0.0"
immer "^9.0.6"
"@metamask/bip39@^4.0.0":
version "4.0.0"
resolved "https://registry.yarnpkg.com/@metamask/bip39/-/bip39-4.0.0.tgz#1cb867a8454e3d45d065107b4e070d58bdb64aac"
@ -2796,6 +2857,18 @@
resolved "https://registry.yarnpkg.com/@metamask/contract-metadata/-/contract-metadata-1.36.0.tgz#8e277190195e9c26733752457d2004d149fd7e0e"
integrity sha512-weTsrXfDQHOgYaiI5giMcOAsD3ChcwnoryasT7xmAfLSKIbKP3RTTUu63VWYBoFCBZugHrhKD6z+N+nm8qAWBQ==
"@metamask/controller-utils@^1.0.0", "@metamask/controller-utils@~1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/controller-utils/-/controller-utils-1.0.0.tgz#2e2261b65c3f38ba0c5b893743fca8cce764339c"
integrity sha512-LXIpnmF/C5/vCBX0u2DiUWA55utZy54guUV+A8qUYmz8PvZrXfK7mdq1zlk8z0aq+aO0rHHfSVbTNacEE3TlAQ==
dependencies:
eth-ens-namehash "^2.0.8"
eth-rpc-errors "^4.0.0"
ethereumjs-util "^7.0.10"
ethjs-unit "^0.1.6"
fast-deep-equal "^3.1.3"
isomorphic-fetch "^3.0.0"
"@metamask/controllers@^32.0.2":
version "32.0.2"
resolved "https://registry.yarnpkg.com/@metamask/controllers/-/controllers-32.0.2.tgz#4841e4b8622c0e9a2cc948ef5f7e8a00473055e8"
@ -2839,49 +2912,6 @@
web3 "^0.20.7"
web3-provider-engine "^16.0.3"
"@metamask/controllers@^33.0.0":
version "33.0.0"
resolved "https://registry.yarnpkg.com/@metamask/controllers/-/controllers-33.0.0.tgz#908c05f6bee741c0beecd9d85d50c304afa38f2b"
integrity sha512-ImnoLztyyE9qswPAv6zk7d40d5FTMPiJYqAjjnJz+hEYhhGPGYI87+2OF/i+kVLv3gatyBQzNxvE1qtQSDWJsg==
dependencies:
"@ethereumjs/common" "^2.3.1"
"@ethereumjs/tx" "^3.2.1"
"@ethersproject/abi" "^5.7.0"
"@ethersproject/contracts" "^5.7.0"
"@ethersproject/providers" "^5.7.0"
"@keystonehq/metamask-airgapped-keyring" "^0.6.1"
"@metamask/contract-metadata" "^1.35.0"
"@metamask/metamask-eth-abis" "3.0.0"
"@metamask/types" "^1.1.0"
"@types/uuid" "^8.3.0"
abort-controller "^3.0.0"
async-mutex "^0.2.6"
babel-runtime "^6.26.0"
deep-freeze-strict "^1.1.1"
eth-ens-namehash "^2.0.8"
eth-json-rpc-infura "^5.1.0"
eth-keyring-controller "^7.0.2"
eth-method-registry "1.1.0"
eth-phishing-detect "^1.2.0"
eth-query "^2.1.2"
eth-rpc-errors "^4.0.0"
eth-sig-util "^3.0.0"
ethereumjs-util "^7.0.10"
ethereumjs-wallet "^1.0.1"
ethjs-unit "^0.1.6"
fast-deep-equal "^3.1.3"
immer "^9.0.6"
isomorphic-fetch "^3.0.0"
json-rpc-engine "^6.1.0"
jsonschema "^1.2.4"
multiformats "^9.5.2"
nanoid "^3.1.31"
punycode "^2.1.1"
single-call-balance-checker-abi "^1.0.0"
uuid "^8.3.2"
web3 "^0.20.7"
web3-provider-engine "^16.0.3"
"@metamask/design-tokens@^1.6.0", "@metamask/design-tokens@^1.9.0":
version "1.11.0"
resolved "https://registry.yarnpkg.com/@metamask/design-tokens/-/design-tokens-1.11.0.tgz#c45d2951c976b9c906fd2a43323446248dbc1a09"
@ -2990,6 +3020,22 @@
resolved "https://registry.yarnpkg.com/@metamask/forwarder/-/forwarder-1.1.0.tgz#13829d8244bbf19ea658c0b20d21a77b67de0bdd"
integrity sha512-Hggj4y0QIjDzKGTXzarhEPIQyFSB2bi2y6YLJNwaT4JmP30UB5Cj6gqoY0M4pj3QT57fzp0BUuGp7F/AUe28tw==
"@metamask/gas-fee-controller@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/gas-fee-controller/-/gas-fee-controller-1.0.0.tgz#d0922ce83c69ac7adaf1b5957d206190283efba7"
integrity sha512-qzpS4lCzBDhWWwq+YmDXwGQdhNrXvsX3ltQYPI5RGPn5x3WYgyhvULdaP+nzk/wxH2sshPNNyyUmP6DhE+aYHQ==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/controller-utils" "~1.0.0"
"@metamask/network-controller" "~1.0.0"
"@types/uuid" "^8.3.0"
babel-runtime "^6.26.0"
eth-query "^2.1.2"
ethereumjs-util "^7.0.10"
ethjs-unit "^0.1.6"
immer "^9.0.6"
uuid "^8.3.2"
"@metamask/jazzicon@^2.0.0":
version "2.0.0"
resolved "https://registry.yarnpkg.com/@metamask/jazzicon/-/jazzicon-2.0.0.tgz#5615528e91c0fc5c9d79202d1f0954a7922525a0"
@ -3023,6 +3069,30 @@
resolved "https://registry.yarnpkg.com/@metamask/metamask-eth-abis/-/metamask-eth-abis-3.0.0.tgz#eccc0746b3ab1ab63000444403819c16e88b5272"
integrity sha512-YtIl4e1VzqwwHGafuLIVPqbcWWWqQ0Ezo8/Ci5m5OGllqE2oTTx9iVHdUmXNkgCVD37SBfwn/fm/S1IGkM8BQA==
"@metamask/network-controller@~1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/network-controller/-/network-controller-1.0.0.tgz#35180bdc56c918719eaa1e00455faa55ecf87824"
integrity sha512-i/7IMqFqbnfZZY8jVs/ptG0aaU8Po01/7kQ5aZgWR+sk7FxdOzs6rYD78qm5f6bU2PNBDSTN3TyN29n50ksmIA==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/controller-utils" "~1.0.0"
async-mutex "^0.2.6"
babel-runtime "^6.26.0"
eth-json-rpc-infura "^5.1.0"
eth-query "^2.1.2"
immer "^9.0.6"
web3-provider-engine "^16.0.3"
"@metamask/notification-controller@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/notification-controller/-/notification-controller-1.0.0.tgz#46ffce7098c8965006796ed0b024224f478f3e4a"
integrity sha512-M6LDHq1Lm4mLvr/2QkRS0pClntGqT740BPpa8Veu/LkB0Q/A2mU7Xg/yIW5Q+K5bc6VVVPQouYib8pGrN4ZU5A==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/controller-utils" "~1.0.0"
immer "^9.0.6"
nanoid "^3.1.31"
"@metamask/object-multiplex@^1.1.0", "@metamask/object-multiplex@^1.2.0":
version "1.2.0"
resolved "https://registry.yarnpkg.com/@metamask/object-multiplex/-/object-multiplex-1.2.0.tgz#38fc15c142f61939391e1b9a8eed679696c7e4f4"
@ -3049,6 +3119,34 @@
"@metamask/safe-event-emitter" "^2.0.0"
through2 "^2.0.3"
"@metamask/permission-controller@^1.0.0", "@metamask/permission-controller@~1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/permission-controller/-/permission-controller-1.0.0.tgz#5f357b34bc98623b0109fda0e5a83aaece872336"
integrity sha512-cZqdHw77PWXMxrNLU2gTgMTf3895VlUBfbld8bw2fRkYqybuVyT/risR3Md1ciMWhMek5qMUwD/pk8M+jSkAJw==
dependencies:
"@metamask/approval-controller" "~1.0.0"
"@metamask/base-controller" "~1.0.0"
"@metamask/controller-utils" "~1.0.0"
"@metamask/types" "^1.1.0"
"@types/deep-freeze-strict" "^1.1.0"
deep-freeze-strict "^1.1.1"
eth-rpc-errors "^4.0.0"
immer "^9.0.6"
json-rpc-engine "^6.1.0"
nanoid "^3.1.31"
"@metamask/phishing-controller@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/phishing-controller/-/phishing-controller-1.0.0.tgz#119721e4e0c0e2926445cdc3ae46a8afafadd174"
integrity sha512-47dIlhdVfWcp2cJ2thVs9SsIxyscWFte4RJ/zLk4m/GpP4LaPZB5zcoAHBKWjDkSHlQyO9AScVnDGfurs1ziHA==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/controller-utils" "~1.0.0"
"@types/punycode" "^2.1.0"
eth-phishing-detect "^1.2.0"
isomorphic-fetch "^3.0.0"
punycode "^2.1.1"
"@metamask/phishing-warning@^1.2.1":
version "1.2.1"
resolved "https://registry.yarnpkg.com/@metamask/phishing-warning/-/phishing-warning-1.2.1.tgz#75554f8653a32c8d101c5b315707dd7990daf156"
@ -3077,6 +3175,14 @@
"@metamask/utils" "^2.0.0"
readable-stream "2.3.3"
"@metamask/preferences-controller@~1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/preferences-controller/-/preferences-controller-1.0.0.tgz#39c246d78a892712bfc0b82f9eb3ecc4053950ef"
integrity sha512-Kg/HslnPqtSkPOeDLDApBDBl6128LxO3aEYBxGiNWRJpzPWZvgAuwGufPkvKABuw5JnYq4L/MJWv4w+cpOfqTg==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/controller-utils" "~1.0.0"
"@metamask/providers@^10.0.0", "@metamask/providers@^10.2.0":
version "10.2.0"
resolved "https://registry.yarnpkg.com/@metamask/providers/-/providers-10.2.0.tgz#8131de667db0c55a61a150438c2a7f17b2d53615"
@ -3095,6 +3201,15 @@
pump "^3.0.0"
webextension-polyfill-ts "^0.25.0"
"@metamask/rate-limit-controller@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/rate-limit-controller/-/rate-limit-controller-1.0.0.tgz#06dd16c07e827965683060f93d9229c4d0751efd"
integrity sha512-2ngqwufeZnMfOBDCUr0+a8vTLqTpgAIdlV5Gwk4YYaE3m3QsBK+uelZGMTV1b7mvYtf4KjARzij9zaACHseH3g==
dependencies:
"@metamask/base-controller" "~1.0.0"
eth-rpc-errors "^4.0.0"
immer "^9.0.6"
"@metamask/rpc-methods@^0.24.1":
version "0.24.1"
resolved "https://registry.yarnpkg.com/@metamask/rpc-methods/-/rpc-methods-0.24.1.tgz#77bb9d3c0960a53b04aeec5e97967a7581a341f7"
@ -3208,6 +3323,16 @@
ses "^0.17.0"
superstruct "^0.16.7"
"@metamask/subject-metadata-controller@^1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@metamask/subject-metadata-controller/-/subject-metadata-controller-1.0.0.tgz#a3f3390995c3541981aa4fe6cfcad0d69122f358"
integrity sha512-ED6teocVxVQO7ykourRp+USHNg7LsxATBYgquFPkGgyIJAbOVMvHAuWFijhA1SiiuV51M3ehMl9oX3/f6Y7Tkg==
dependencies:
"@metamask/base-controller" "~1.0.0"
"@metamask/permission-controller" "~1.0.0"
"@metamask/types" "^1.1.0"
immer "^9.0.6"
"@metamask/test-dapp@^5.2.1":
version "5.2.1"
resolved "https://registry.yarnpkg.com/@metamask/test-dapp/-/test-dapp-5.2.1.tgz#a7591393eec6d15f5e4bddee567018444db372ff"
@ -4841,6 +4966,11 @@
dependencies:
"@types/ms" "*"
"@types/deep-freeze-strict@^1.1.0":
version "1.1.0"
resolved "https://registry.yarnpkg.com/@types/deep-freeze-strict/-/deep-freeze-strict-1.1.0.tgz#447a6a2576191344aa42310131dd3df5c41492c4"
integrity sha512-fILflsS66kGQ4iIBzYoxuQCWK1wQdy/ooguTofUk0KSxA+G5ZzH8WdU8mf6IU+5cMBW+j9u+eh+7kv63R3O9Tw==
"@types/end-of-stream@^1.4.1":
version "1.4.1"
resolved "https://registry.yarnpkg.com/@types/end-of-stream/-/end-of-stream-1.4.1.tgz#9a401b642bcb0e4a8f0b70326725fbbb0216eb10"
@ -5188,6 +5318,11 @@
dependencies:
"@types/node" "*"
"@types/punycode@^2.1.0":
version "2.1.0"
resolved "https://registry.yarnpkg.com/@types/punycode/-/punycode-2.1.0.tgz#89e4f3d09b3f92e87a80505af19be7e0c31d4e83"
integrity sha512-PG5aLpW6PJOeV2fHRslP4IOMWn+G+Uq8CfnyJ+PDS8ndCbU+soO+fB3NKCKo0p/Jh2Y4aPaiQZsrOXFdzpcA6g==
"@types/qs@^6.9.5":
version "6.9.7"
resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.7.tgz#63bb7d067db107cc1e457c303bc25d511febf6cb"