1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-22 09:57:02 +01:00

Merge pull request #20539 from MetaMask/Version-v11.0.0

Version v11.0.0
This commit is contained in:
Mark Stacey 2023-09-05 16:36:17 -02:30 committed by GitHub
commit 75c213a551
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
64 changed files with 1634 additions and 347 deletions

View File

@ -146,8 +146,14 @@ workflows:
- prep-build-test
- test-e2e-chrome-snaps:
requires:
- prep-build-test-flask
- prep-build-test
- test-e2e-firefox-snaps:
requires:
- prep-build-test
- test-e2e-chrome-snaps-flask:
requires:
- prep-build-test-flask
- test-e2e-firefox-snaps-flask:
requires:
- prep-build-test-flask
- test-e2e-chrome-mv3:
@ -770,6 +776,80 @@ jobs:
destination: test-artifacts
test-e2e-firefox-snaps:
executor: node-browsers
parallelism: 4
steps:
- run: *shallow-git-clone
- run:
name: Install Firefox
command: ./.circleci/scripts/firefox-install.sh
- attach_workspace:
at: .
- run:
name: Move test build to dist
command: mv ./dist-test ./dist
- run:
name: Move test zips to builds
command: mv ./builds-test ./builds
- run:
name: test:e2e:firefox:snaps
command: |
if .circleci/scripts/test-run-e2e.sh
then
yarn test:e2e:firefox:snaps --retries 2 --debug --build-type=main
fi
no_output_timeout: 20m
- run:
name: Merge JUnit report
command: |
if [ "$(ls -A test/test-results/e2e)" ]; then
yarn test:e2e:report
fi
when: always
- store_artifacts:
path: test-artifacts
destination: test-artifacts
- store_test_results:
path: test/test-results/e2e.xml
test-e2e-chrome-snaps:
executor: node-browsers
parallelism: 4
steps:
- run: *shallow-git-clone
- run:
name: Re-Install Chrome
command: ./.circleci/scripts/chrome-install.sh
- attach_workspace:
at: .
- run:
name: Move test build to dist
command: mv ./dist-test ./dist
- run:
name: Move test zips to builds
command: mv ./builds-test ./builds
- run:
name: test:e2e:chrome:snaps
command: |
if .circleci/scripts/test-run-e2e.sh
then
yarn test:e2e:chrome:snaps --retries 2 --debug --build-type=main
fi
no_output_timeout: 20m
- run:
name: Merge JUnit report
command: |
if [ "$(ls -A test/test-results/e2e)" ]; then
yarn test:e2e:report
fi
when: always
- store_artifacts:
path: test-artifacts
destination: test-artifacts
- store_test_results:
path: test/test-results/e2e.xml
test-e2e-firefox-snaps-flask:
executor: node-browsers
parallelism: 4
steps:
@ -806,7 +886,7 @@ jobs:
- store_test_results:
path: test/test-results/e2e.xml
test-e2e-chrome-snaps:
test-e2e-chrome-snaps-flask:
executor: node-browsers
parallelism: 4
steps:

View File

@ -6,6 +6,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]
## [11.0.0]
### Added
- [FLASK] Added snaps lifecycle hooks ([#20230](https://github.com/MetaMask/metamask-extension/pull/20230))
### Changed
- [FLASK] Unblock `personal_sign` for snaps ([#19998](https://github.com/MetaMask/metamask-extension/pull/19998))
- [FLASK] Allow disabling markdown in snaps UI ([#20069](https://github.com/MetaMask/metamask-extension/pull/20069))
### Fixed
- [FLASK] Fix regression in transaction confirmation tabs ([#20267](https://github.com/MetaMask/metamask-extension/pull/20267))
## [10.35.1]
### Changed
- Store default gas settings by network ([#20576](https://github.com/MetaMask/metamask-extension/pull/20576), [#20632](https://github.com/MetaMask/metamask-extension/pull/20632))
@ -3960,7 +3971,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Uncategorized
- Added the ability to restore accounts from seed words.
[Unreleased]: https://github.com/MetaMask/metamask-extension/compare/v10.35.1...HEAD
[Unreleased]: https://github.com/MetaMask/metamask-extension/compare/v11.0.0...HEAD
[11.0.0]: https://github.com/MetaMask/metamask-extension/compare/v10.35.1...v11.0.0
[10.35.1]: https://github.com/MetaMask/metamask-extension/compare/v10.35.0...v10.35.1
[10.35.0]: https://github.com/MetaMask/metamask-extension/compare/v10.34.5...v10.35.0
[10.34.5]: https://github.com/MetaMask/metamask-extension/compare/v10.34.4...v10.34.5

View File

@ -1555,7 +1555,7 @@
"message": "Export private key"
},
"extendWalletWithSnaps": {
"message": "Extend the wallet experience."
"message": "Customize your wallet experience."
},
"externalExtension": {
"message": "External extension"
@ -2838,7 +2838,7 @@
"message": "👓 We are making transactions easier to read."
},
"notificationsEmptyText": {
"message": "Nothing to see here."
"message": "This is where you can find notifications from your installed snaps."
},
"notificationsHeader": {
"message": "Notifications"
@ -2850,6 +2850,21 @@
"notificationsMarkAllAsRead": {
"message": "Mark all as read"
},
"notificationsOpenBetaSnapsActionText": {
"message": "Learn more"
},
"notificationsOpenBetaSnapsDescriptionOne": {
"message": "🎉 We're excited to announce the Open Beta of MetaMask Snaps!"
},
"notificationsOpenBetaSnapsDescriptionThree": {
"message": "Personalize your wallet with snaps built by the developer community!"
},
"notificationsOpenBetaSnapsDescriptionTwo": {
"message": "Snaps help you do more with MetaMask — like connect to more networks, see transaction insights, and get custom notifications."
},
"notificationsOpenBetaSnapsTitle": {
"message": "Introducing MetaMask Snaps"
},
"numberOfNewTokensDetectedPlural": {
"message": "$1 new tokens found in this account",
"description": "$1 is the number of new tokens detected"
@ -3167,6 +3182,14 @@
"message": "Allow the snap to derive arbitrary keys unique to this snap, without exposing them. These keys are separate from your MetaMask account(s) and not related to your private keys or Secret Recovery Phrase. Other snaps cannot access this information.",
"description": "An extended description for the `snap_getEntropy` permission"
},
"permission_lifecycleHooks": {
"message": "Use lifecycle hooks.",
"description": "The description for the `endowment:lifecycle-hooks` permission"
},
"permission_lifecycleHooksDescription": {
"message": "Allow the snap to use lifecycle hooks to run code at specific times during its lifecycle.",
"description": "An extended description for the `endowment:lifecycle-hooks` permission"
},
"permission_longRunning": {
"message": "Run indefinitely.",
"description": "The description for the `endowment:long-running` permission"
@ -4042,7 +4065,7 @@
"message": "The snap didn't return any insight"
},
"snapsPrivacyWarningFirstMessage": {
"message": "You acknowledge that the snap that you are about to install is a Third Party Service as defined in the Consensys $1. Your use of Third Party Services is governed by separate terms and conditions set forth by the Third Party Service provider. You access, rely upon or use the Third Party Service at your own risk. Consensys disclaims all responsibility and liability for any losses on account of your use of Third Party Services.",
"message": "You acknowledge that any Snap that you install is a Third Party Service, unless otherwise identified, as defined in the Consensys $1. Your use of Third Party Services is governed by separate terms and conditions set forth by the Third Party Service provider. Consensys does not recommend the use of any Snap by any particular person for any particular reason. You access, rely upon or use the Third Party Service at your own risk. Consensys disclaims all responsibility and liability for any losses on account of your use of Third Party Services.",
"description": "First part of a message in popup modal displayed when installing a snap for the first time. $1 is terms of use link."
},
"snapsPrivacyWarningSecondMessage": {
@ -4050,7 +4073,7 @@
"description": "Second part of a message in popup modal displayed when installing a snap for the first time."
},
"snapsPrivacyWarningThirdMessage": {
"message": "Consensys has no access to information you share with these third parties.",
"message": "Consensys has no access to information you share with Third Party Services.",
"description": "Third part of a message in popup modal displayed when installing a snap for the first time."
},
"snapsSettingsDescription": {

View File

@ -0,0 +1,93 @@
<svg width="296" height="114" viewBox="0 0 296 114" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_1357_4712)">
<rect width="296" height="114" rx="8" fill="#F2F4F6"/>
<g opacity="0.8" filter="url(#filter0_f_1357_4712)">
<path d="M277.679 215.325L152.424 402.875L598.645 423.026L583.771 -53.5996L277.679 215.325Z" fill="#E27625" stroke="#E27625" stroke-width="7.65217" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M-293.003 -294.625L-225.679 26.2251L-268.735 58.0001L-204.542 106.05L-253.078 143.25L-189.668 200.6L-229.593 229.275L-138 335.45L277.69 215.325L572.039 -31.1249L-192.799 -593L-293.003 -294.625Z" fill="#763E1A" stroke="#763E1A" stroke-width="7.65217" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<rect width="328" height="136" fill="url(#paint0_linear_1357_4712)"/>
<g clip-path="url(#clip1_1357_4712)">
<path opacity="0.5" d="M253.868 140.582C247.795 152.08 232.314 157.285 212.081 156.317C191.864 155.35 166.98 148.219 142.228 135.146C117.475 122.072 97.5563 105.54 85.3601 89.3881C73.1534 73.2222 68.725 57.5013 74.7978 46.0034C80.8706 34.5055 96.3515 29.3 116.585 30.2679C136.802 31.235 161.685 38.3657 186.438 51.4392C211.191 64.5128 231.109 81.045 243.306 97.197C255.512 113.363 259.941 129.084 253.868 140.582Z" fill="url(#paint1_radial_1357_4712)" fill-opacity="0.75" stroke="white" stroke-width="0.394925"/>
<path opacity="0.5" d="M226.842 122.668C219.528 136.517 203.475 144.122 183.364 145.168C163.258 146.215 139.14 140.701 115.784 128.365C92.428 116.029 74.2766 99.2183 63.8055 82.0222C53.3314 64.8213 50.5624 47.2762 57.8772 33.4267C65.192 19.5773 81.244 11.9728 101.356 10.9262C121.462 9.87988 145.58 15.394 168.936 27.7298C192.292 40.0655 210.443 56.8763 220.914 74.0724C231.388 91.2733 234.157 108.818 226.842 122.668Z" fill="url(#paint2_radial_1357_4712)" fill-opacity="0.5" stroke="white" stroke-width="0.474924"/>
<path opacity="0.5" d="M249.145 25.0877C251.823 29.726 251.557 35.808 248.719 42.8719C245.882 49.933 240.487 57.9416 232.969 66.3966C217.933 83.305 194.434 101.965 166.034 118.362C137.633 134.759 109.724 145.78 87.5628 150.347C76.4812 152.631 66.8482 153.298 59.3146 152.225C51.778 151.151 46.3779 148.34 43.7 143.702C41.0221 139.063 41.2881 132.981 44.1262 125.918C46.9632 118.856 52.3579 110.848 59.8766 102.393C74.9125 85.4844 98.4117 66.8245 126.812 50.4277C155.212 34.0308 183.122 23.0099 205.283 18.4427C216.364 16.1588 225.997 15.4911 233.531 16.5648C241.067 17.6389 246.468 20.4495 249.145 25.0877Z" fill="url(#paint3_radial_1357_4712)" fill-opacity="0.5" stroke="white" stroke-width="0.394925"/>
<path opacity="0.5" d="M269.805 75.1055C270.009 76.9384 269.375 78.8376 267.946 80.7825C266.517 82.7285 264.301 84.708 261.368 86.6911C255.502 90.6569 246.803 94.6129 235.908 98.3353C214.121 105.779 183.592 112.274 149.489 116.053C115.385 119.833 84.1756 120.179 61.2872 117.685C49.8413 116.439 40.4873 114.483 33.8953 111.898C30.5991 110.605 28.0036 109.159 26.1832 107.573C24.3638 105.988 23.3294 104.274 23.1263 102.441C22.9232 100.608 23.5571 98.7086 24.9854 96.7637C26.4144 94.8177 28.6303 92.8381 31.5635 90.8551C37.4296 86.8893 46.1285 82.9333 57.0237 79.2109C78.811 71.7672 109.339 65.2719 143.443 61.4928C177.546 57.7137 208.756 57.3677 231.645 59.8607C243.09 61.1074 252.444 63.0629 259.036 65.6482C262.333 66.941 264.928 68.3873 266.749 69.9733C268.568 71.5583 269.602 73.2726 269.805 75.1055Z" fill="url(#paint4_radial_1357_4712)" stroke="white" stroke-width="0.394925"/>
<rect x="35.9463" y="72.946" width="20.1589" height="20.1589" rx="10.0794" fill="#0376C9" fill-opacity="0.58"/>
<path d="M50.5298 79.1965L46.6773 77.1627C46.2718 76.9461 45.7802 76.9461 45.3747 77.1627L41.5222 79.1965C41.2395 79.3469 41.0675 79.6357 41.0675 79.9666C41.0675 80.2916 41.2395 80.5864 41.5222 80.7368L45.3747 82.7706C45.5775 82.8789 45.8048 82.9331 46.026 82.9331C46.2472 82.9331 46.4745 82.8789 46.6773 82.7706L50.5298 80.7368C50.8124 80.5864 50.9845 80.2976 50.9845 79.9666C50.9845 79.6357 50.8124 79.3469 50.5298 79.1965Z" fill="white"/>
<path d="M44.8689 83.309L41.3675 81.4499C41.0905 81.3167 40.6775 81.4203 40.419 81.5777C40.1544 81.7412 40.0005 82.0136 40.0005 82.3162V85.6516C40.0005 86.2266 40.3267 86.7825 40.8498 87.0428L44.4381 88.9586C44.5611 89.0191 44.6966 89.0494 44.832 89.0494C44.992 89.0494 45.152 89.007 45.2936 88.9222C45.5582 88.7649 45.7121 88.3029 45.7121 88.0002V84.6649C45.7182 84.0838 45.392 83.5632 44.8689 83.309Z" fill="white"/>
<path d="M51.633 81.5801C51.3683 81.4228 50.9528 81.3107 50.682 81.4499L47.1892 83.3108C46.666 83.571 46.3398 84.0854 46.3398 84.6663V88.0005C46.3398 88.3031 46.4937 88.7669 46.7584 88.9242C46.8999 89.0089 47.0599 89.0513 47.22 89.0513C47.3554 89.0513 47.4908 89.021 47.6139 88.9605L51.2021 87.0428C51.7253 86.7826 52.0515 86.2336 52.0515 85.6526V82.3184C52.0515 82.0158 51.8976 81.7435 51.633 81.5801Z" fill="white"/>
<rect x="35.9463" y="72.946" width="20.1589" height="20.1589" rx="10.0794" stroke="#ADD5F3" stroke-width="0.5"/>
<rect x="158.946" y="15.946" width="20.1589" height="20.1589" rx="10.0794" fill="#0376C9" fill-opacity="0.58"/>
<path d="M173.53 22.1965L169.677 20.1627C169.272 19.9461 168.78 19.9461 168.375 20.1627L164.522 22.1965C164.24 22.3469 164.068 22.6357 164.068 22.9666C164.068 23.2916 164.24 23.5864 164.522 23.7368L168.375 25.7706C168.577 25.8789 168.805 25.9331 169.026 25.9331C169.247 25.9331 169.475 25.8789 169.677 25.7706L173.53 23.7368C173.812 23.5864 173.984 23.2976 173.984 22.9666C173.984 22.6357 173.812 22.3469 173.53 22.1965Z" fill="white"/>
<path d="M167.869 26.309L164.368 24.4499C164.091 24.3167 163.678 24.4203 163.419 24.5777C163.154 24.7412 163 25.0136 163 25.3162V28.6516C163 29.2266 163.327 29.7825 163.85 30.0428L167.438 31.9586C167.561 32.0191 167.697 32.0494 167.832 32.0494C167.992 32.0494 168.152 32.007 168.294 31.9222C168.558 31.7649 168.712 31.3029 168.712 31.0002V27.6649C168.718 27.0838 168.392 26.5632 167.869 26.309Z" fill="white"/>
<path d="M174.633 24.5801C174.368 24.4228 173.953 24.3107 173.682 24.4499L170.189 26.3108C169.666 26.571 169.34 27.0854 169.34 27.6663V31.0005C169.34 31.3031 169.494 31.7669 169.758 31.9242C169.9 32.0089 170.06 32.0513 170.22 32.0513C170.355 32.0513 170.491 32.021 170.614 31.9605L174.202 30.0428C174.725 29.7826 175.052 29.2336 175.052 28.6526V25.3184C175.052 25.0158 174.898 24.7435 174.633 24.5801Z" fill="white"/>
<rect x="158.946" y="15.946" width="20.1589" height="20.1589" rx="10.0794" stroke="#D1E8FA" stroke-width="0.5"/>
<rect x="66.9463" y="6.94604" width="20.1589" height="20.1589" rx="10.0794" fill="#0376C9" fill-opacity="0.58"/>
<path d="M81.5298 13.1965L77.6773 11.1627C77.2718 10.9461 76.7802 10.9461 76.3747 11.1627L72.5222 13.1965C72.2395 13.3469 72.0675 13.6357 72.0675 13.9666C72.0675 14.2916 72.2395 14.5864 72.5222 14.7368L76.3747 16.7706C76.5775 16.8789 76.8048 16.9331 77.026 16.9331C77.2472 16.9331 77.4745 16.8789 77.6773 16.7706L81.5298 14.7368C81.8124 14.5864 81.9845 14.2976 81.9845 13.9666C81.9845 13.6357 81.8124 13.3469 81.5298 13.1965Z" fill="white"/>
<path d="M75.8689 17.309L72.3675 15.4499C72.0905 15.3167 71.6775 15.4203 71.419 15.5777C71.1544 15.7412 71.0005 16.0136 71.0005 16.3162V19.6516C71.0005 20.2266 71.3267 20.7825 71.8498 21.0428L75.4381 22.9586C75.5611 23.0191 75.6966 23.0494 75.832 23.0494C75.992 23.0494 76.152 23.007 76.2936 22.9222C76.5582 22.7649 76.7121 22.3029 76.7121 22.0002V18.6649C76.7182 18.0838 76.392 17.5632 75.8689 17.309Z" fill="white"/>
<path d="M82.633 15.5801C82.3683 15.4228 81.9528 15.3107 81.682 15.4499L78.1892 17.3108C77.666 17.571 77.3398 18.0854 77.3398 18.6663V22.0005C77.3398 22.3031 77.4937 22.7669 77.7584 22.9242C77.8999 23.0089 78.0599 23.0513 78.22 23.0513C78.3554 23.0513 78.4908 23.021 78.6139 22.9605L82.2021 21.0428C82.7253 20.7826 83.0515 20.2336 83.0515 19.6526V16.3184C83.0515 16.0158 82.8976 15.7435 82.633 15.5801Z" fill="white"/>
<rect x="66.9463" y="6.94604" width="20.1589" height="20.1589" rx="10.0794" stroke="#D1E8FA" stroke-width="0.5"/>
<rect x="228.946" y="7.94604" width="20.1589" height="20.1589" rx="10.0794" fill="#0376C9" fill-opacity="0.58"/>
<path d="M243.53 14.1965L239.677 12.1627C239.272 11.9461 238.78 11.9461 238.375 12.1627L234.522 14.1965C234.24 14.3469 234.068 14.6357 234.068 14.9666C234.068 15.2916 234.24 15.5864 234.522 15.7368L238.375 17.7706C238.577 17.8789 238.805 17.9331 239.026 17.9331C239.247 17.9331 239.475 17.8789 239.677 17.7706L243.53 15.7368C243.812 15.5864 243.984 15.2976 243.984 14.9666C243.984 14.6357 243.812 14.3469 243.53 14.1965Z" fill="white"/>
<path d="M237.869 18.309L234.368 16.4499C234.091 16.3167 233.678 16.4203 233.419 16.5777C233.154 16.7412 233 17.0136 233 17.3162V20.6516C233 21.2266 233.327 21.7825 233.85 22.0428L237.438 23.9586C237.561 24.0191 237.697 24.0494 237.832 24.0494C237.992 24.0494 238.152 24.007 238.294 23.9222C238.558 23.7649 238.712 23.3029 238.712 23.0002V19.6649C238.718 19.0838 238.392 18.5632 237.869 18.309Z" fill="white"/>
<path d="M244.633 16.5801C244.368 16.4228 243.953 16.3107 243.682 16.4499L240.189 18.3108C239.666 18.571 239.34 19.0854 239.34 19.6663V23.0005C239.34 23.3031 239.494 23.7669 239.758 23.9242C239.9 24.0089 240.06 24.0513 240.22 24.0513C240.355 24.0513 240.491 24.021 240.614 23.9605L244.202 22.0428C244.725 21.7826 245.052 21.2336 245.052 20.6526V17.3184C245.052 17.0158 244.898 16.7435 244.633 16.5801Z" fill="white"/>
<rect x="228.946" y="7.94604" width="20.1589" height="20.1589" rx="10.0794" stroke="#D1E8FA" stroke-width="0.5"/>
<rect x="234.095" y="84.0952" width="19.8607" height="19.8607" rx="9.93033" fill="#0376C9" fill-opacity="0.58"/>
<path d="M248.53 90.1965L244.677 88.1627C244.272 87.9461 243.78 87.9461 243.375 88.1627L239.522 90.1965C239.24 90.3469 239.068 90.6357 239.068 90.9666C239.068 91.2916 239.24 91.5864 239.522 91.7368L243.375 93.7706C243.577 93.8789 243.805 93.9331 244.026 93.9331C244.247 93.9331 244.475 93.8789 244.677 93.7706L248.53 91.7368C248.812 91.5864 248.984 91.2976 248.984 90.9666C248.984 90.6357 248.812 90.3469 248.53 90.1965Z" fill="white"/>
<path d="M242.869 94.309L239.368 92.4499C239.091 92.3167 238.678 92.4203 238.419 92.5777C238.154 92.7412 238 93.0136 238 93.3162V96.6516C238 97.2266 238.327 97.7825 238.85 98.0428L242.438 99.9586C242.561 100.019 242.697 100.049 242.832 100.049C242.992 100.049 243.152 100.007 243.294 99.9222C243.558 99.7649 243.712 99.3029 243.712 99.0002V95.6649C243.718 95.0838 243.392 94.5632 242.869 94.309Z" fill="white"/>
<path d="M249.633 92.5801C249.368 92.4228 248.953 92.3107 248.682 92.4499L245.189 94.3108C244.666 94.571 244.34 95.0854 244.34 95.6663V99.0005C244.34 99.3031 244.494 99.7669 244.758 99.9242C244.9 100.009 245.06 100.051 245.22 100.051C245.355 100.051 245.491 100.021 245.614 99.9605L249.202 98.0428C249.725 97.7826 250.052 97.2336 250.052 96.6526V93.3184C250.052 93.0158 249.898 92.7435 249.633 92.5801Z" fill="white"/>
<rect x="234.095" y="84.0952" width="19.8607" height="19.8607" rx="9.93033" stroke="#ADD5F3" stroke-width="0.79823"/>
</g>
<path d="M203.089 37L155.379 72.0625L164.251 51.399L203.089 37Z" fill="#E17726" stroke="#E17726" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M93.04 37L140.325 72.3898L131.878 51.399L93.04 37Z" fill="#E27625" stroke="#E27625" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M121.401 85.7603L113.851 97.0738L140.749 98.2893L139.853 69.5381L121.401 85.7603Z" fill="#E27625" stroke="#E27625" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M174.728 85.7602L155.993 69.2107L155.379 98.2892L182.278 97.0737L174.728 85.7602Z" fill="#E27625" stroke="#E27625" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M138.249 111.987L124.752 108.06L134.285 103.712L138.249 111.987Z" fill="#233447" stroke="#233447" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M157.881 111.987L161.845 103.712L171.425 108.06L157.881 111.987Z" fill="#233447" stroke="#233447" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M182.278 97.0737L155.379 98.2892L157.881 111.987L161.845 103.712L171.424 108.06L182.278 97.0737Z" fill="#CC6228" stroke="#CC6228" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M124.752 108.06L134.285 103.712L138.249 111.987L140.75 98.2892L113.851 97.0737L124.752 108.06Z" fill="#CC6228" stroke="#CC6228" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M113.851 97.0737L125.13 118.906L124.752 108.06L113.851 97.0737Z" fill="#E27525" stroke="#E27525" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M171.424 108.06L170.999 118.906L182.278 97.0737L171.424 108.06Z" fill="#E27525" stroke="#E27525" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M140.75 98.2893L138.249 111.987L141.41 128.163L142.118 106.845L140.75 98.2893Z" fill="#E27525" stroke="#E27525" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M155.378 98.2893L154.057 106.798L154.718 128.163L157.88 111.987L155.378 98.2893Z" fill="#E27525" stroke="#E27525" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M157.881 111.987L154.719 128.163L156.984 129.752L171 118.906L171.425 108.06L157.881 111.987Z" fill="#F5841F" stroke="#F5841F" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M124.752 108.06L125.13 118.906L139.146 129.752L141.411 128.163L138.249 111.987L124.752 108.06Z" fill="#F5841F" stroke="#F5841F" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M205.118 74.3533L209.129 54.9988L203.089 37L156.983 70.8938L174.727 85.7603L199.786 93.0065L205.307 86.6018L202.9 84.872L206.723 81.4125L203.797 79.1685L207.619 76.27L205.118 74.3533Z" fill="#763E1A" stroke="#763E1A" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M87 54.9988L91.0584 74.3533L88.4629 76.27L92.3326 79.1685L89.4067 81.4125L93.2292 84.872L90.8225 86.6018L96.3438 93.0065L121.402 85.7603L139.146 70.8938L93.0404 37L87 54.9988Z" fill="#763E1A" stroke="#763E1A" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M199.785 93.0065L174.727 85.7603L182.278 97.0738L170.999 118.906L185.911 118.719H208.185L199.785 93.0065Z" fill="#F5841F" stroke="#F5841F" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M121.402 85.7603L96.344 93.0065L87.9912 118.719H110.218L125.13 118.906L113.852 97.0738L121.402 85.7603Z" fill="#F5841F" stroke="#F5841F" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M155.379 98.2894L156.983 70.8939L164.25 51.3992H131.877L139.145 70.8939L140.749 98.2894L141.363 106.891L141.41 128.163H154.718L154.765 106.891L155.379 98.2894Z" fill="#F5841F" stroke="#F5841F" stroke-width="1.62609" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<defs>
<filter id="filter0_f_1357_4712" x="-552.83" y="-852.827" width="2545.64" height="2379.65" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
<feGaussianBlur stdDeviation="128" result="effect1_foregroundBlur_1357_4712"/>
</filter>
<linearGradient id="paint0_linear_1357_4712" x1="164" y1="0" x2="164" y2="136" gradientUnits="userSpaceOnUse">
<stop stop-color="#D2E9FF"/>
<stop offset="1" stop-color="#2F93DC"/>
</linearGradient>
<radialGradient id="paint1_radial_1357_4712" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(164.333 93.2925) rotate(117.841) scale(47.5298 101.454)">
<stop stop-color="white" stop-opacity="0"/>
<stop offset="1" stop-color="#EBEBEB"/>
</radialGradient>
<radialGradient id="paint2_radial_1357_4712" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(142.36 78.0473) rotate(117.841) scale(57.142 95.7796)">
<stop stop-color="white" stop-opacity="0"/>
<stop offset="1" stop-color="#EBEBEB"/>
</radialGradient>
<radialGradient id="paint3_radial_1357_4712" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(146.423 84.3947) rotate(60) scale(39.4193 118.811)">
<stop stop-color="white" stop-opacity="0"/>
<stop offset="1" stop-color="#EBEBEB"/>
</radialGradient>
<radialGradient id="paint4_radial_1357_4712" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(146.466 88.7731) rotate(83.6767) scale(27.6448 124.292)">
<stop stop-color="white" stop-opacity="0"/>
<stop offset="1" stop-color="#EBEBEB"/>
</radialGradient>
<clipPath id="clip0_1357_4712">
<rect width="296" height="114" rx="8" fill="white"/>
</clipPath>
<clipPath id="clip1_1357_4712">
<rect width="262.027" height="130.9" fill="white" transform="translate(11 5)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 16 KiB

View File

@ -821,6 +821,13 @@ export function setupController(
});
}
///: END:ONLY_INCLUDE_IN
///: BEGIN:ONLY_INCLUDE_IN(snaps)
// Updates the snaps registry and check for newly blocked snaps to block if the user has at least one snap installed.
if (Object.keys(controller.snapController.state.snaps).length > 0) {
controller.snapController.updateBlockedSnaps();
}
///: END:ONLY_INCLUDE_IN
}
//

View File

@ -1,7 +1,8 @@
import log from 'loglevel';
/**
* Returns a middleware that logs RPC activity
* Returns a middleware that logs RPC activity. Logging is detailed in
* development builds, but more limited in production builds.
*
* @param {{ origin: string }} opts - The middleware options
* @returns {Function}
@ -14,12 +15,20 @@ export default function createLoggerMiddleware(opts) {
) {
next((/** @type {Function} */ cb) => {
if (res.error) {
log.error('Error in RPC response:\n', res);
log.debug('Error in RPC response:\n', res);
}
if (req.isMetamaskInternal) {
return;
}
log.info(`RPC (${opts.origin}):`, req, '->', res);
if (process.env.METAMASK_DEBUG) {
log.info(`RPC (${opts.origin}):`, req, '->', res);
} else {
log.info(
`RPC (${opts.origin}): ${req.method} -> ${
res.error ? 'error' : 'success'
}`,
);
}
cb();
});
};

View File

@ -65,7 +65,9 @@ export function createMethodMiddleware(hooks) {
selectHooks(hooks, hookNames),
);
} catch (error) {
console.error(error);
if (process.env.METAMASK_DEBUG) {
console.error(error);
}
return end(error);
}
}
@ -101,7 +103,9 @@ export function createSnapMethodMiddleware(isSnap, hooks) {
selectHooks(hooks, hookNames),
);
} catch (error) {
console.error(error);
if (process.env.METAMASK_DEBUG) {
console.error(error);
}
return end(error);
}
}

View File

@ -82,6 +82,9 @@ export const SENTRY_BACKGROUND_STATE = {
CachedBalancesController: {
cachedBalances: false,
},
CronjobController: {
jobs: false,
},
CurrencyController: {
conversionDate: true,
conversionRate: true,
@ -146,6 +149,9 @@ export const SENTRY_BACKGROUND_STATE = {
allNfts: false,
ignoredNfts: false,
},
NotificationController: {
notifications: false,
},
OnboardingController: {
completedOnboarding: true,
firstTimeFlowType: true,
@ -213,6 +219,15 @@ export const SENTRY_BACKGROUND_STATE = {
userOptIn: true,
},
},
SnapController: {
snapErrors: false,
snapStates: false,
snaps: false,
},
SnapsRegistry: {
database: false,
lastUpdated: false,
},
SubjectMetadataController: {
subjectMetadata: false,
},

View File

@ -5,11 +5,16 @@ import { storeAsStream } from '@metamask/obs-store/dist/asStream';
import { JsonRpcEngine } from 'json-rpc-engine';
import { createEngineStream } from 'json-rpc-middleware-stream';
import { providerAsMiddleware } from '@metamask/eth-json-rpc-middleware';
import { debounce } from 'lodash';
import {
KeyringController,
keyringBuilderFactory,
} from '@metamask/eth-keyring-controller';
import {
debounce,
///: BEGIN:ONLY_INCLUDE_IN(snaps)
throttle,
///: END:ONLY_INCLUDE_IN
} from 'lodash';
import createFilterMiddleware from 'eth-json-rpc-filters';
import createSubscriptionManager from 'eth-json-rpc-filters/subscriptionManager';
import { errorCodes as rpcErrorCodes, EthereumRpcError } from 'eth-rpc-errors';
@ -923,10 +928,10 @@ export default class MetamaskController extends EventEmitter {
}),
setupSnapProvider: this.setupSnapProvider.bind(this),
};
this.snapExecutionService =
this.opts.overrides?.createSnapExecutionService?.(
snapExecutionServiceArgs,
) || new IframeExecutionService(snapExecutionServiceArgs);
this.snapExecutionService = new IframeExecutionService(
snapExecutionServiceArgs,
);
const snapControllerMessenger = this.controllerMessenger.getRestricted({
name: 'SnapController',
@ -934,6 +939,8 @@ export default class MetamaskController extends EventEmitter {
'ExecutionService:unhandledError',
'ExecutionService:outboundRequest',
'ExecutionService:outboundResponse',
'SnapController:snapInstalled',
'SnapController:snapUpdated',
],
allowedActions: [
`${this.permissionController.name}:getEndowments`,
@ -957,6 +964,7 @@ export default class MetamaskController extends EventEmitter {
'ExecutionService:handleRpcRequest',
'SnapsRegistry:get',
'SnapsRegistry:getMetadata',
'SnapsRegistry:update',
],
});
@ -1057,8 +1065,8 @@ export default class MetamaskController extends EventEmitter {
refetchOnAllowlistMiss: requireAllowlist,
failOnUnavailableRegistry: requireAllowlist,
url: {
registry: 'https://acl.execution.metamask.io/latest/registry.json',
signature: 'https://acl.execution.metamask.io/latest/signature.json',
registry: 'https://acl.execution.consensys.io/latest/registry.json',
signature: 'https://acl.execution.consensys.io/latest/signature.json',
},
publicKey:
'0x025b65308f0f0fb8bc7f7ff87bfc296e0330eee5d3c1d1ee4a048b2fd6a86fa0a6',
@ -1780,6 +1788,41 @@ export default class MetamaskController extends EventEmitter {
///: BEGIN:ONLY_INCLUDE_IN(snaps)
/**
* Tracks snaps export usage. Note: This function is throttled to 1 call per 60 seconds.
*
* @param {string} snapId - The ID of the snap the handler is being triggered on.
* @param {string} handler - The handler to trigger on the snap for the request.
*/
_trackSnapExportUsage = throttle(
(snapId, handler) =>
this.metaMetricsController.trackEvent({
event: MetaMetricsEventName.SnapExportUsed,
category: MetaMetricsEventCategory.Snaps,
properties: {
snap_id: snapId,
export: handler,
},
}),
SECOND * 60,
);
/**
* Passes a JSON-RPC request object to the SnapController for execution.
*
* @param {object} args - A bag of options.
* @param {string} args.snapId - The ID of the recipient snap.
* @param {string} args.origin - The origin of the RPC request.
* @param {string} args.handler - The handler to trigger on the snap for the request.
* @param {object} args.request - The JSON-RPC request object.
* @returns The result of the JSON-RPC request.
*/
handleSnapRequest(args) {
this._trackSnapExportUsage(args.snapId, args.handler);
return this.controllerMessenger.call('SnapController:handleRequest', args);
}
/**
* Constructor helper for getting Snap permission specifications.
*/
@ -1801,10 +1844,7 @@ export default class MetamaskController extends EventEmitter {
this.controllerMessenger,
'SnapController:get',
),
handleSnapRpcRequest: this.controllerMessenger.call.bind(
this.controllerMessenger,
'SnapController:handleRequest',
),
handleSnapRpcRequest: this.handleSnapRequest.bind(this),
getSnapState: this.controllerMessenger.call.bind(
this.controllerMessenger,
'SnapController:getSnapState',
@ -1956,7 +1996,7 @@ export default class MetamaskController extends EventEmitter {
`${this.snapController.name}:snapInstalled`,
(truncatedSnap) => {
this.metaMetricsController.trackEvent({
event: 'Snap Installed',
event: MetaMetricsEventName.SnapInstalled,
category: MetaMetricsEventCategory.Snaps,
properties: {
snap_id: truncatedSnap.id,
@ -1970,7 +2010,7 @@ export default class MetamaskController extends EventEmitter {
`${this.snapController.name}:snapUpdated`,
(newSnap, oldVersion) => {
this.metaMetricsController.trackEvent({
event: 'Snap Updated',
event: MetaMetricsEventName.SnapUpdated,
category: MetaMetricsEventCategory.Snaps,
properties: {
snap_id: newSnap.id,
@ -2013,6 +2053,15 @@ export default class MetamaskController extends EventEmitter {
}, []);
this.dismissNotifications(notificationIds);
this.metaMetricsController.trackEvent({
event: MetaMetricsEventName.SnapUninstalled,
category: MetaMetricsEventCategory.Snaps,
properties: {
snap_id: truncatedSnap.id,
version: truncatedSnap.version,
},
});
},
);
@ -2093,9 +2142,21 @@ export default class MetamaskController extends EventEmitter {
const { vault } = this.keyringController.store.getState();
const isInitialized = Boolean(vault);
const flatState = this.memStore.getFlatState();
return {
isInitialized,
...this.memStore.getFlatState(),
...flatState,
///: BEGIN:ONLY_INCLUDE_IN(snaps)
// Snap state and source code is stripped out to prevent piping to the MetaMask UI.
snapStates: {},
snaps: Object.values(flatState.snaps ?? {}).reduce((acc, snap) => {
// eslint-disable-next-line no-unused-vars
const { sourceCode, ...rest } = snap;
acc[snap.id] = rest;
return acc;
}, {}),
///: END:ONLY_INCLUDE_IN
};
}
@ -2535,10 +2596,7 @@ export default class MetamaskController extends EventEmitter {
this.controllerMessenger,
'SnapController:remove',
),
handleSnapRequest: this.controllerMessenger.call.bind(
this.controllerMessenger,
'SnapController:handleRequest',
),
handleSnapRequest: this.handleSnapRequest.bind(this),
revokeDynamicSnapPermissions: this.controllerMessenger.call.bind(
this.controllerMessenger,
'SnapController:revokeDynamicPermissions',

View File

@ -16,12 +16,16 @@ buildTypes:
main:
features:
- build-main
- snaps
# Additional env variables that are specific to this build
env:
- INFURA_PROD_PROJECT_ID
- SEGMENT_PROD_WRITE_KEY
- INFURA_ENV_KEY_REF: INFURA_PROD_PROJECT_ID
- SEGMENT_WRITE_KEY_REF: SEGMENT_PROD_WRITE_KEY
- ALLOW_LOCAL_SNAPS: false
- REQUIRE_SNAPS_ALLOWLIST: true
- IFRAME_EXECUTION_ENVIRONMENT_URL: https://execution.consensys.io/1.0.2/index.html
# Main build uses the default browser manifest
manifestOverrides: false
@ -52,7 +56,7 @@ buildTypes:
- SEGMENT_FLASK_WRITE_KEY
- ALLOW_LOCAL_SNAPS: true
- REQUIRE_SNAPS_ALLOWLIST: false
- IFRAME_EXECUTION_ENVIRONMENT_URL: https://execution.metamask.io/0.38.1-flask.1/index.html
- IFRAME_EXECUTION_ENVIRONMENT_URL: https://execution.consensys.io/0.38.1-flask.1/index.html
- SUPPORT_LINK: https://metamask-flask.zendesk.com/hc
- SUPPORT_REQUEST_LINK: https://metamask-flask.zendesk.com/hc/en-us/requests/new
- INFURA_ENV_KEY_REF: INFURA_FLASK_PROJECT_ID
@ -71,7 +75,7 @@ buildTypes:
- SEGMENT_FLASK_WRITE_KEY
- ALLOW_LOCAL_SNAPS: true
- REQUIRE_SNAPS_ALLOWLIST: false
- IFRAME_EXECUTION_ENVIRONMENT_URL: https://execution.metamask.io/0.38.1-flask.1/index.html
- IFRAME_EXECUTION_ENVIRONMENT_URL: https://execution.consensys.io/0.38.1-flask.1/index.html
- SUPPORT_LINK: https://metamask-flask.zendesk.com/hc
- SUPPORT_REQUEST_LINK: https://metamask-flask.zendesk.com/hc/en-us/requests/new
- INFURA_ENV_KEY_REF: INFURA_FLASK_PROJECT_ID

View File

@ -1527,29 +1527,6 @@
"jest-canvas-mock>moo-color>color-name": true
}
},
"@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@metamask/utils": true,
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/scure-bip39": true
}
},
"@metamask/key-tree>@metamask/utils": {
"globals": {
"TextDecoder": true,
"TextEncoder": true
},
"packages": {
"@metamask/key-tree>@noble/hashes": true,
"browserify>buffer": true,
"nock>debug": true,
"semver": true,
"superstruct": true
}
},
"@metamask/key-tree>@noble/ed25519": {
"globals": {
"crypto": true
@ -1742,9 +1719,9 @@
"@metamask/rpc-methods": {
"packages": {
"@metamask/browser-passworder": true,
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/permission-controller": true,
"@metamask/rpc-methods>@metamask/key-tree": true,
"@metamask/rpc-methods>@metamask/utils": true,
"@metamask/rpc-methods>nanoid": true,
"@metamask/snaps-ui": true,
@ -1758,6 +1735,16 @@
"crypto.getRandomValues": true
}
},
"@metamask/rpc-methods>@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/rpc-methods>@metamask/utils": true,
"@metamask/scure-bip39": true
}
},
"@metamask/rpc-methods>@metamask/utils": {
"globals": {
"TextDecoder": true,
@ -1925,9 +1912,9 @@
"document.createElement": true
},
"packages": {
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/snaps-utils>@metamask/key-tree": true,
"@metamask/snaps-utils>@metamask/utils": true,
"@metamask/snaps-utils>cron-parser": true,
"@metamask/snaps-utils>fast-json-stable-stringify": true,
@ -1937,6 +1924,16 @@
"superstruct": true
}
},
"@metamask/snaps-utils>@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/scure-bip39": true,
"@metamask/snaps-utils>@metamask/utils": true
}
},
"@metamask/snaps-utils>@metamask/utils": {
"globals": {
"TextDecoder": true,
@ -4594,7 +4591,6 @@
},
"packages": {
"browserify>process": true,
"browserify>util": true,
"semver>lru-cache": true
}
},

View File

@ -1978,6 +1978,9 @@
"@metamask/snaps-utils>rfdc": true,
"@metamask/snaps-utils>validate-npm-package-name": true,
"browserify>buffer": true,
"browserify>path-browserify": true,
"browserify>process": true,
"chalk": true,
"semver": true,
"superstruct": true
}
@ -2150,13 +2153,47 @@
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/permission-controller": true,
"@metamask/snaps-controllers-flask>@metamask/snaps-utils": true,
"@metamask/snaps-controllers-flask>@metamask/snaps-utils>@metamask/snaps-ui": true,
"@metamask/snaps-controllers-flask>@metamask/rpc-methods>@metamask/snaps-ui": true,
"@metamask/snaps-controllers-flask>@metamask/rpc-methods>@metamask/snaps-utils": true,
"@metamask/snaps-controllers-flask>@metamask/utils": true,
"eth-rpc-errors": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/rpc-methods>@metamask/snaps-ui": {
"packages": {
"@metamask/snaps-controllers-flask>@metamask/utils": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/rpc-methods>@metamask/snaps-utils": {
"globals": {
"TextDecoder": true,
"URL": true,
"console.error": true,
"console.log": true,
"console.warn": true,
"document.body.appendChild": true,
"document.createElement": true
},
"packages": {
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/snaps-controllers-flask>@metamask/utils": true,
"@metamask/snaps-utils-flask>is-svg": true,
"@metamask/snaps-utils>cron-parser": true,
"@metamask/snaps-utils>fast-json-stable-stringify": true,
"@metamask/snaps-utils>rfdc": true,
"@metamask/snaps-utils>validate-npm-package-name": true,
"browserify>buffer": true,
"browserify>path-browserify": true,
"browserify>process": true,
"chalk": true,
"semver": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/snaps-utils": {
"globals": {
"TextDecoder": true,
@ -2178,16 +2215,13 @@
"@metamask/snaps-utils>rfdc": true,
"@metamask/snaps-utils>validate-npm-package-name": true,
"browserify>buffer": true,
"browserify>path-browserify": true,
"browserify>process": true,
"chalk": true,
"semver": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/snaps-utils>@metamask/snaps-ui": {
"packages": {
"@metamask/snaps-controllers-flask>@metamask/utils": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/utils": {
"globals": {
"TextDecoder": true,
@ -2394,6 +2428,9 @@
"@metamask/snaps-utils>rfdc": true,
"@metamask/snaps-utils>validate-npm-package-name": true,
"browserify>buffer": true,
"browserify>path-browserify": true,
"browserify>process": true,
"chalk": true,
"semver": true,
"superstruct": true
}
@ -3564,6 +3601,22 @@
"document.createElement": true
}
},
"chalk": {
"packages": {
"chalk>ansi-styles": true,
"chalk>supports-color": true
}
},
"chalk>ansi-styles": {
"packages": {
"chalk>ansi-styles>color-convert": true
}
},
"chalk>ansi-styles>color-convert": {
"packages": {
"jest-canvas-mock>moo-color>color-name": true
}
},
"classnames": {
"globals": {
"classNames": "write",
@ -5221,7 +5274,6 @@
},
"packages": {
"browserify>process": true,
"browserify>util": true,
"semver>lru-cache": true
}
},

View File

@ -1978,6 +1978,9 @@
"@metamask/snaps-utils>rfdc": true,
"@metamask/snaps-utils>validate-npm-package-name": true,
"browserify>buffer": true,
"browserify>path-browserify": true,
"browserify>process": true,
"chalk": true,
"semver": true,
"superstruct": true
}
@ -2150,13 +2153,47 @@
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/permission-controller": true,
"@metamask/snaps-controllers-flask>@metamask/snaps-utils": true,
"@metamask/snaps-controllers-flask>@metamask/snaps-utils>@metamask/snaps-ui": true,
"@metamask/snaps-controllers-flask>@metamask/rpc-methods>@metamask/snaps-ui": true,
"@metamask/snaps-controllers-flask>@metamask/rpc-methods>@metamask/snaps-utils": true,
"@metamask/snaps-controllers-flask>@metamask/utils": true,
"eth-rpc-errors": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/rpc-methods>@metamask/snaps-ui": {
"packages": {
"@metamask/snaps-controllers-flask>@metamask/utils": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/rpc-methods>@metamask/snaps-utils": {
"globals": {
"TextDecoder": true,
"URL": true,
"console.error": true,
"console.log": true,
"console.warn": true,
"document.body.appendChild": true,
"document.createElement": true
},
"packages": {
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/snaps-controllers-flask>@metamask/utils": true,
"@metamask/snaps-utils-flask>is-svg": true,
"@metamask/snaps-utils>cron-parser": true,
"@metamask/snaps-utils>fast-json-stable-stringify": true,
"@metamask/snaps-utils>rfdc": true,
"@metamask/snaps-utils>validate-npm-package-name": true,
"browserify>buffer": true,
"browserify>path-browserify": true,
"browserify>process": true,
"chalk": true,
"semver": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/snaps-utils": {
"globals": {
"TextDecoder": true,
@ -2178,16 +2215,13 @@
"@metamask/snaps-utils>rfdc": true,
"@metamask/snaps-utils>validate-npm-package-name": true,
"browserify>buffer": true,
"browserify>path-browserify": true,
"browserify>process": true,
"chalk": true,
"semver": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/snaps-utils>@metamask/snaps-ui": {
"packages": {
"@metamask/snaps-controllers-flask>@metamask/utils": true,
"superstruct": true
}
},
"@metamask/snaps-controllers-flask>@metamask/utils": {
"globals": {
"TextDecoder": true,
@ -2394,6 +2428,9 @@
"@metamask/snaps-utils>rfdc": true,
"@metamask/snaps-utils>validate-npm-package-name": true,
"browserify>buffer": true,
"browserify>path-browserify": true,
"browserify>process": true,
"chalk": true,
"semver": true,
"superstruct": true
}
@ -3564,6 +3601,22 @@
"document.createElement": true
}
},
"chalk": {
"packages": {
"chalk>ansi-styles": true,
"chalk>supports-color": true
}
},
"chalk>ansi-styles": {
"packages": {
"chalk>ansi-styles>color-convert": true
}
},
"chalk>ansi-styles>color-convert": {
"packages": {
"jest-canvas-mock>moo-color>color-name": true
}
},
"classnames": {
"globals": {
"classNames": "write",
@ -5221,7 +5274,6 @@
},
"packages": {
"browserify>process": true,
"browserify>util": true,
"semver>lru-cache": true
}
},

View File

@ -1527,29 +1527,6 @@
"jest-canvas-mock>moo-color>color-name": true
}
},
"@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@metamask/utils": true,
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/scure-bip39": true
}
},
"@metamask/key-tree>@metamask/utils": {
"globals": {
"TextDecoder": true,
"TextEncoder": true
},
"packages": {
"@metamask/key-tree>@noble/hashes": true,
"browserify>buffer": true,
"nock>debug": true,
"semver": true,
"superstruct": true
}
},
"@metamask/key-tree>@noble/ed25519": {
"globals": {
"crypto": true
@ -1683,6 +1660,13 @@
"browserify>events": true
}
},
"@metamask/notification-controller": {
"packages": {
"@metamask/base-controller": true,
"@metamask/notification-controller>nanoid": true,
"@metamask/utils": true
}
},
"@metamask/notification-controller>nanoid": {
"globals": {
"crypto.getRandomValues": true
@ -1739,12 +1723,77 @@
"eslint>optionator>fast-levenshtein": true
}
},
"@metamask/post-message-stream": {
"globals": {
"MessageEvent.prototype": true,
"WorkerGlobalScope": true,
"addEventListener": true,
"browser": true,
"chrome": true,
"location.origin": true,
"postMessage": true,
"removeEventListener": true
},
"packages": {
"@metamask/post-message-stream>readable-stream": true,
"@metamask/utils": true
}
},
"@metamask/post-message-stream>readable-stream": {
"packages": {
"@metamask/post-message-stream>readable-stream>process-nextick-args": true,
"@metamask/post-message-stream>readable-stream>safe-buffer": true,
"@metamask/post-message-stream>readable-stream>string_decoder": true,
"browserify>browser-resolve": true,
"browserify>events": true,
"browserify>process": true,
"browserify>timers-browserify": true,
"pumpify>inherits": true,
"readable-stream>core-util-is": true,
"readable-stream>isarray": true,
"readable-stream>util-deprecate": true
}
},
"@metamask/post-message-stream>readable-stream>process-nextick-args": {
"packages": {
"browserify>process": true
}
},
"@metamask/post-message-stream>readable-stream>safe-buffer": {
"packages": {
"browserify>buffer": true
}
},
"@metamask/post-message-stream>readable-stream>string_decoder": {
"packages": {
"@metamask/post-message-stream>readable-stream>safe-buffer": true
}
},
"@metamask/providers>@metamask/object-multiplex": {
"globals": {
"console.warn": true
},
"packages": {
"end-of-stream": true,
"pump>once": true,
"readable-stream": true
}
},
"@metamask/rate-limit-controller": {
"globals": {
"setTimeout": true
},
"packages": {
"@metamask/base-controller": true,
"eth-rpc-errors": true
}
},
"@metamask/rpc-methods": {
"packages": {
"@metamask/browser-passworder": true,
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/permission-controller": true,
"@metamask/rpc-methods>@metamask/key-tree": true,
"@metamask/rpc-methods>@metamask/utils": true,
"@metamask/rpc-methods>nanoid": true,
"@metamask/snaps-ui": true,
@ -1758,6 +1807,16 @@
"crypto.getRandomValues": true
}
},
"@metamask/rpc-methods>@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/rpc-methods>@metamask/utils": true,
"@metamask/scure-bip39": true
}
},
"@metamask/rpc-methods>@metamask/utils": {
"globals": {
"TextDecoder": true,
@ -1885,16 +1944,203 @@
"setTimeout": true
}
},
"@metamask/snaps-controllers": {
"globals": {
"URL": true,
"chrome.offscreen.createDocument": true,
"chrome.offscreen.hasDocument": true,
"clearTimeout": true,
"document.getElementById": true,
"fetch.bind": true,
"setTimeout": true
},
"packages": {
"@metamask/base-controller": true,
"@metamask/permission-controller": true,
"@metamask/post-message-stream": true,
"@metamask/providers>@metamask/object-multiplex": true,
"@metamask/rpc-methods": true,
"@metamask/snaps-controllers>@metamask/utils": true,
"@metamask/snaps-controllers>@xstate/fsm": true,
"@metamask/snaps-controllers>concat-stream": true,
"@metamask/snaps-controllers>gunzip-maybe": true,
"@metamask/snaps-controllers>nanoid": true,
"@metamask/snaps-controllers>readable-web-to-node-stream": true,
"@metamask/snaps-controllers>tar-stream": true,
"@metamask/snaps-utils": true,
"@metamask/snaps-utils>@metamask/snaps-registry": true,
"eth-rpc-errors": true,
"json-rpc-engine": true,
"json-rpc-middleware-stream": true,
"pump": true
}
},
"@metamask/snaps-controllers-flask>nanoid": {
"globals": {
"crypto.getRandomValues": true
}
},
"@metamask/snaps-controllers>@metamask/utils": {
"globals": {
"TextDecoder": true,
"TextEncoder": true
},
"packages": {
"@metamask/key-tree>@noble/hashes": true,
"browserify>buffer": true,
"nock>debug": true,
"semver": true,
"superstruct": true
}
},
"@metamask/snaps-controllers>concat-stream": {
"packages": {
"@metamask/snaps-controllers>concat-stream>readable-stream": true,
"browserify>buffer": true,
"browserify>concat-stream>typedarray": true,
"pumpify>inherits": true,
"terser>source-map-support>buffer-from": true
}
},
"@metamask/snaps-controllers>concat-stream>readable-stream": {
"packages": {
"browserify>browser-resolve": true,
"browserify>buffer": true,
"browserify>events": true,
"browserify>process": true,
"browserify>string_decoder": true,
"pumpify>inherits": true,
"readable-stream>util-deprecate": true
}
},
"@metamask/snaps-controllers>gunzip-maybe": {
"packages": {
"@metamask/snaps-controllers>gunzip-maybe>browserify-zlib": true,
"@metamask/snaps-controllers>gunzip-maybe>is-deflate": true,
"@metamask/snaps-controllers>gunzip-maybe>is-gzip": true,
"@metamask/snaps-controllers>gunzip-maybe>peek-stream": true,
"@metamask/snaps-controllers>gunzip-maybe>pumpify": true,
"@metamask/snaps-controllers>gunzip-maybe>through2": true
}
},
"@metamask/snaps-controllers>gunzip-maybe>browserify-zlib": {
"packages": {
"@metamask/snaps-controllers>gunzip-maybe>browserify-zlib>pako": true,
"browserify>assert": true,
"browserify>buffer": true,
"browserify>process": true,
"browserify>util": true,
"readable-stream": true
}
},
"@metamask/snaps-controllers>gunzip-maybe>peek-stream": {
"packages": {
"@metamask/snaps-controllers>gunzip-maybe>peek-stream>duplexify": true,
"@metamask/snaps-controllers>gunzip-maybe>peek-stream>through2": true,
"browserify>buffer": true,
"terser>source-map-support>buffer-from": true
}
},
"@metamask/snaps-controllers>gunzip-maybe>peek-stream>duplexify": {
"packages": {
"browserify>buffer": true,
"browserify>process": true,
"duplexify>stream-shift": true,
"end-of-stream": true,
"pumpify>inherits": true,
"readable-stream": true
}
},
"@metamask/snaps-controllers>gunzip-maybe>peek-stream>through2": {
"packages": {
"browserify>process": true,
"browserify>util": true,
"readable-stream": true,
"watchify>xtend": true
}
},
"@metamask/snaps-controllers>gunzip-maybe>pumpify": {
"packages": {
"@metamask/snaps-controllers>gunzip-maybe>pumpify>duplexify": true,
"@metamask/snaps-controllers>gunzip-maybe>pumpify>pump": true,
"pumpify>inherits": true
}
},
"@metamask/snaps-controllers>gunzip-maybe>pumpify>duplexify": {
"packages": {
"browserify>buffer": true,
"browserify>process": true,
"duplexify>stream-shift": true,
"end-of-stream": true,
"pumpify>inherits": true,
"readable-stream": true
}
},
"@metamask/snaps-controllers>gunzip-maybe>pumpify>pump": {
"packages": {
"browserify>browser-resolve": true,
"end-of-stream": true,
"pump>once": true
}
},
"@metamask/snaps-controllers>gunzip-maybe>through2": {
"packages": {
"browserify>process": true,
"browserify>util": true,
"readable-stream": true,
"watchify>xtend": true
}
},
"@metamask/snaps-controllers>nanoid": {
"globals": {
"crypto.getRandomValues": true
}
},
"@metamask/snaps-controllers>readable-web-to-node-stream": {
"packages": {
"@metamask/snaps-controllers>readable-web-to-node-stream>readable-stream": true
}
},
"@metamask/snaps-controllers>readable-web-to-node-stream>readable-stream": {
"packages": {
"browserify>browser-resolve": true,
"browserify>buffer": true,
"browserify>events": true,
"browserify>process": true,
"browserify>string_decoder": true,
"pumpify>inherits": true,
"readable-stream>util-deprecate": true
}
},
"@metamask/snaps-controllers>tar-stream": {
"packages": {
"@metamask/snaps-controllers>tar-stream>fs-constants": true,
"@metamask/snaps-controllers>tar-stream>readable-stream": true,
"browserify>buffer": true,
"browserify>process": true,
"browserify>string_decoder": true,
"browserify>util": true,
"end-of-stream": true,
"madge>ora>bl": true,
"pumpify>inherits": true
}
},
"@metamask/snaps-controllers>tar-stream>fs-constants": {
"packages": {
"browserify>constants-browserify": true
}
},
"@metamask/snaps-controllers>tar-stream>readable-stream": {
"packages": {
"browserify>browser-resolve": true,
"browserify>buffer": true,
"browserify>events": true,
"browserify>process": true,
"browserify>string_decoder": true,
"pumpify>inherits": true,
"readable-stream>util-deprecate": true
}
},
"@metamask/snaps-ui": {
"packages": {
"@metamask/snaps-ui>@metamask/utils": true,
@ -1925,9 +2171,9 @@
"document.createElement": true
},
"packages": {
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/snaps-utils>@metamask/key-tree": true,
"@metamask/snaps-utils>@metamask/utils": true,
"@metamask/snaps-utils>cron-parser": true,
"@metamask/snaps-utils>fast-json-stable-stringify": true,
@ -1937,6 +2183,36 @@
"superstruct": true
}
},
"@metamask/snaps-utils>@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/scure-bip39": true,
"@metamask/snaps-utils>@metamask/utils": true
}
},
"@metamask/snaps-utils>@metamask/snaps-registry": {
"packages": {
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/snaps-utils>@metamask/snaps-registry>@metamask/utils": true,
"superstruct": true
}
},
"@metamask/snaps-utils>@metamask/snaps-registry>@metamask/utils": {
"globals": {
"TextDecoder": true,
"TextEncoder": true
},
"packages": {
"@metamask/key-tree>@noble/hashes": true,
"browserify>buffer": true,
"nock>debug": true,
"semver": true,
"superstruct": true
}
},
"@metamask/snaps-utils>@metamask/utils": {
"globals": {
"TextDecoder": true,
@ -4062,6 +4338,24 @@
"Intl": true
}
},
"madge>ora>bl": {
"packages": {
"browserify>buffer": true,
"madge>ora>bl>readable-stream": true,
"pumpify>inherits": true
}
},
"madge>ora>bl>readable-stream": {
"packages": {
"browserify>browser-resolve": true,
"browserify>buffer": true,
"browserify>events": true,
"browserify>process": true,
"browserify>string_decoder": true,
"pumpify>inherits": true,
"readable-stream>util-deprecate": true
}
},
"nanoid": {
"globals": {
"crypto": true,
@ -4328,6 +4622,115 @@
"proxyquire>fill-keys>is-object": true
}
},
"react-markdown": {
"globals": {
"console.warn": true
},
"packages": {
"prop-types": true,
"react": true,
"react-markdown>comma-separated-tokens": true,
"react-markdown>property-information": true,
"react-markdown>react-is": true,
"react-markdown>remark-parse": true,
"react-markdown>remark-rehype": true,
"react-markdown>space-separated-tokens": true,
"react-markdown>style-to-object": true,
"react-markdown>unified": true,
"react-markdown>unist-util-visit": true,
"react-markdown>vfile": true
}
},
"react-markdown>property-information": {
"packages": {
"watchify>xtend": true
}
},
"react-markdown>react-is": {
"globals": {
"console": true
}
},
"react-markdown>remark-parse": {
"packages": {
"react-markdown>remark-parse>mdast-util-from-markdown": true
}
},
"react-markdown>remark-parse>mdast-util-from-markdown": {
"packages": {
"react-markdown>remark-parse>mdast-util-from-markdown>mdast-util-to-string": true,
"react-markdown>remark-parse>mdast-util-from-markdown>micromark": true,
"react-markdown>remark-parse>mdast-util-from-markdown>unist-util-stringify-position": true,
"react-syntax-highlighter>refractor>parse-entities": true
}
},
"react-markdown>remark-parse>mdast-util-from-markdown>micromark": {
"packages": {
"react-syntax-highlighter>refractor>parse-entities": true
}
},
"react-markdown>remark-rehype": {
"packages": {
"react-markdown>remark-rehype>mdast-util-to-hast": true
}
},
"react-markdown>remark-rehype>mdast-util-to-hast": {
"globals": {
"console.warn": true
},
"packages": {
"react-markdown>remark-rehype>mdast-util-to-hast>mdast-util-definitions": true,
"react-markdown>remark-rehype>mdast-util-to-hast>mdurl": true,
"react-markdown>remark-rehype>mdast-util-to-hast>unist-builder": true,
"react-markdown>remark-rehype>mdast-util-to-hast>unist-util-generated": true,
"react-markdown>remark-rehype>mdast-util-to-hast>unist-util-position": true,
"react-markdown>unist-util-visit": true
}
},
"react-markdown>remark-rehype>mdast-util-to-hast>mdast-util-definitions": {
"packages": {
"react-markdown>unist-util-visit": true
}
},
"react-markdown>style-to-object": {
"packages": {
"react-markdown>style-to-object>inline-style-parser": true
}
},
"react-markdown>unified": {
"packages": {
"mocha>yargs-unparser>is-plain-obj": true,
"react-markdown>unified>bail": true,
"react-markdown>unified>extend": true,
"react-markdown>unified>is-buffer": true,
"react-markdown>unified>trough": true,
"react-markdown>vfile": true
}
},
"react-markdown>unist-util-visit": {
"packages": {
"react-markdown>unist-util-visit>unist-util-visit-parents": true
}
},
"react-markdown>unist-util-visit>unist-util-visit-parents": {
"packages": {
"react-markdown>unist-util-visit>unist-util-is": true
}
},
"react-markdown>vfile": {
"packages": {
"browserify>path-browserify": true,
"browserify>process": true,
"react-markdown>vfile>is-buffer": true,
"react-markdown>vfile>vfile-message": true,
"vinyl>replace-ext": true
}
},
"react-markdown>vfile>vfile-message": {
"packages": {
"react-markdown>vfile>unist-util-stringify-position": true
}
},
"react-popper": {
"globals": {
"document": true
@ -4482,6 +4885,11 @@
"react": true
}
},
"react-syntax-highlighter>refractor>parse-entities": {
"globals": {
"document.createElement": true
}
},
"react-tippy": {
"globals": {
"Element": true,
@ -4594,7 +5002,6 @@
},
"packages": {
"browserify>process": true,
"browserify>util": true,
"semver>lru-cache": true
}
},
@ -4646,6 +5053,11 @@
"define": true
}
},
"terser>source-map-support>buffer-from": {
"packages": {
"browserify>buffer": true
}
},
"uuid": {
"globals": {
"crypto": true,
@ -4657,6 +5069,11 @@
"browserify>buffer": true
}
},
"vinyl>replace-ext": {
"packages": {
"browserify>path-browserify": true
}
},
"wait-on>rxjs>tslib": {
"globals": {
"define": true

View File

@ -1755,29 +1755,6 @@
"jest-canvas-mock>moo-color>color-name": true
}
},
"@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@metamask/utils": true,
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/scure-bip39": true
}
},
"@metamask/key-tree>@metamask/utils": {
"globals": {
"TextDecoder": true,
"TextEncoder": true
},
"packages": {
"@metamask/key-tree>@noble/hashes": true,
"browserify>buffer": true,
"nock>debug": true,
"semver": true,
"superstruct": true
}
},
"@metamask/key-tree>@noble/ed25519": {
"globals": {
"crypto": true
@ -1970,9 +1947,9 @@
"@metamask/rpc-methods": {
"packages": {
"@metamask/browser-passworder": true,
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/permission-controller": true,
"@metamask/rpc-methods>@metamask/key-tree": true,
"@metamask/rpc-methods>@metamask/utils": true,
"@metamask/rpc-methods>nanoid": true,
"@metamask/snaps-ui": true,
@ -1986,6 +1963,16 @@
"crypto.getRandomValues": true
}
},
"@metamask/rpc-methods>@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/rpc-methods>@metamask/utils": true,
"@metamask/scure-bip39": true
}
},
"@metamask/rpc-methods>@metamask/utils": {
"globals": {
"TextDecoder": true,
@ -2153,9 +2140,9 @@
"document.createElement": true
},
"packages": {
"@metamask/key-tree": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/snaps-utils>@metamask/key-tree": true,
"@metamask/snaps-utils>@metamask/utils": true,
"@metamask/snaps-utils>cron-parser": true,
"@metamask/snaps-utils>fast-json-stable-stringify": true,
@ -2165,6 +2152,16 @@
"superstruct": true
}
},
"@metamask/snaps-utils>@metamask/key-tree": {
"packages": {
"@metamask/key-tree>@noble/ed25519": true,
"@metamask/key-tree>@noble/hashes": true,
"@metamask/key-tree>@noble/secp256k1": true,
"@metamask/key-tree>@scure/base": true,
"@metamask/scure-bip39": true,
"@metamask/snaps-utils>@metamask/utils": true
}
},
"@metamask/snaps-utils>@metamask/utils": {
"globals": {
"TextDecoder": true,
@ -4822,7 +4819,6 @@
},
"packages": {
"browserify>process": true,
"browserify>util": true,
"semver>lru-cache": true
}
},

View File

@ -7649,9 +7649,6 @@
}
},
"semver": {
"builtin": {
"util.inspect": true
},
"globals": {
"console.error": true,
"process": true

View File

@ -1,6 +1,6 @@
{
"name": "metamask-crx",
"version": "10.35.1",
"version": "11.0.0",
"private": true,
"repository": {
"type": "git",
@ -244,7 +244,7 @@
"@metamask/etherscan-link": "^2.2.0",
"@metamask/gas-fee-controller": "^6.0.1",
"@metamask/jazzicon": "^2.0.0",
"@metamask/key-tree": "^7.0.0",
"@metamask/key-tree": "^9.0.0",
"@metamask/logo": "^3.1.1",
"@metamask/message-manager": "^7.0.2",
"@metamask/metamask-eth-abis": "^3.0.0",
@ -257,19 +257,19 @@
"@metamask/ppom-validator": "^0.0.1",
"@metamask/providers": "^11.1.0",
"@metamask/rate-limit-controller": "^3.0.0",
"@metamask/rpc-methods": "^1.0.0-prerelease.1",
"@metamask/rpc-methods-flask": "npm:@metamask/rpc-methods@0.36.1-flask.1",
"@metamask/rpc-methods": "^1.0.2",
"@metamask/rpc-methods-flask": "npm:@metamask/rpc-methods@0.37.2-flask.1",
"@metamask/safe-event-emitter": "^2.0.0",
"@metamask/scure-bip39": "^2.0.3",
"@metamask/signature-controller": "^4.0.1",
"@metamask/slip44": "^3.0.0",
"@metamask/smart-transactions-controller": "^3.1.0",
"@metamask/snaps-controllers": "^1.0.0-prerelease.1",
"@metamask/snaps-controllers-flask": "npm:@metamask/snaps-controllers@0.36.1-flask.1",
"@metamask/snaps-ui": "^1.0.0-prerelease.1",
"@metamask/snaps-ui-flask": "npm:@metamask/snaps-ui@0.36.1-flask.1",
"@metamask/snaps-utils": "^1.0.0-prerelease.1",
"@metamask/snaps-utils-flask": "npm:@metamask/snaps-utils@0.36.1-flask.1",
"@metamask/snaps-controllers": "^1.0.2",
"@metamask/snaps-controllers-flask": "npm:@metamask/snaps-controllers@0.38.0-flask.1",
"@metamask/snaps-ui": "^1.0.2",
"@metamask/snaps-ui-flask": "npm:@metamask/snaps-ui@0.37.3-flask.1",
"@metamask/snaps-utils": "^1.0.2",
"@metamask/snaps-utils-flask": "npm:@metamask/snaps-utils@0.38.0-flask.1",
"@metamask/subject-metadata-controller": "^2.0.0",
"@metamask/utils": "^5.0.0",
"@ngraveio/bc-ur": "^1.1.6",

View File

@ -599,6 +599,12 @@ export enum MetaMetricsEventName {
ActivityScreenOpened = 'Activity Screen Opened',
WhatsNewViewed = `What's New Viewed`,
WhatsNewClicked = `What's New Link Clicked`,
///: BEGIN:ONLY_INCLUDE_IN(snaps)
SnapInstalled = 'Snap Installed',
SnapUninstalled = 'Snap Uninstalled',
SnapUpdated = 'Snap Updated',
SnapExportUsed = 'Snap Export Used',
///: END:ONLY_INCLUDE_IN
}
export enum MetaMetricsEventAccountType {

View File

@ -9,10 +9,12 @@ import {
describe('EndowmentPermissions', () => {
it('has the expected permission keys', () => {
// Since long-running is fenced out this causes problems with the test, we re-add it here.
// Since some permissions are fenced out, this causes problems with the
// test, so we re-add them here.
expect(Object.keys(EndowmentPermissions).sort()).toStrictEqual(
[
'endowment:long-running',
'endowment:lifecycle-hooks',
...Object.keys(endowmentPermissionBuilders).filter(
(targetName) =>
!Object.keys(ExcludedSnapEndowments).includes(targetName),

View File

@ -58,7 +58,7 @@ export const SNAPS_DERIVATION_PATHS: SnapsDerivationPath[] = [
{
path: ['m', `44'`, `1'`],
curve: 'secp256k1',
name: 'Test BIP-32 Path (secp256k1)',
name: 'Testnet',
},
{
path: ['m', `44'`, `0'`],
@ -115,11 +115,21 @@ export const SNAPS_DERIVATION_PATHS: SnapsDerivationPath[] = [
curve: 'secp256k1',
name: 'Bitcoin Cash',
},
{
path: ['m', `44'`, `637'`],
curve: 'ed25519',
name: 'Aptos',
},
{
path: ['m', `44'`, `714'`],
curve: 'secp256k1',
name: 'Binance (BNB)',
},
{
path: ['m', `44'`, `784'`],
curve: 'ed25519',
name: 'Sui',
},
{
path: ['m', `44'`, `931'`],
curve: 'secp256k1',
@ -148,7 +158,27 @@ export const SNAPS_DERIVATION_PATHS: SnapsDerivationPath[] = [
{
path: ['m', `44'`, `1'`, `0'`],
curve: 'ed25519',
name: 'NEAR Protocol Testnet',
name: 'Testnet',
},
{
path: ['m', `44'`, `472'`],
curve: 'ed25519',
name: 'Arweave',
},
{
path: ['m', `44'`, `12586'`],
curve: 'secp256k1',
name: 'Mina',
},
{
path: ['m', `44'`, `1729'`, `0'`, `0'`],
curve: 'ed25519',
name: 'Tezos',
},
{
path: ['m', `1789'`, `0'`],
curve: 'ed25519',
name: 'Vega',
},
];
///: END:ONLY_INCLUDE_IN

View File

@ -7,6 +7,7 @@ export const EndowmentPermissions = Object.freeze({
'endowment:webassembly': 'endowment:webassembly',
///: BEGIN:ONLY_INCLUDE_IN(build-flask)
'endowment:long-running': 'endowment:long-running',
'endowment:lifecycle-hooks': 'endowment:lifecycle-hooks',
///: END:ONLY_INCLUDE_IN
} as const);
@ -18,7 +19,7 @@ export const ExcludedSnapPermissions = Object.freeze({
'This permission is still in development and therefore not available.',
///: END:ONLY_INCLUDE_IN
eth_accounts:
'eth_accounts is disabled. For more information please see https://github.com/MetaMask/snaps-monorepo/issues/990.',
'eth_accounts is disabled. For more information please see https://github.com/MetaMask/snaps/issues/990.',
});
export const ExcludedSnapEndowments = Object.freeze({
@ -26,7 +27,9 @@ export const ExcludedSnapEndowments = Object.freeze({
'endowment:keyring':
'This endowment is still in development therefore not available.',
'endowment:long-running':
'endowment:long-running is deprecated. For more information please see https://github.com/MetaMask/snaps-monorepo/issues/945.',
'endowment:long-running is deprecated. For more information please see https://github.com/MetaMask/snaps/issues/945.',
'endowment:lifecycle-hooks':
'This endowment is experimental and therefore not available.',
///: END:ONLY_INCLUDE_IN
});

View File

@ -1,2 +1,2 @@
export const TERMS_OF_USE_LINK = 'https://consensys.net/terms-of-use/';
export const TERMS_OF_USE_LINK = 'https://consensys.io/terms-of-use/';
export const TERMS_OF_USE_LAST_UPDATED = '2023-03-25';

View File

@ -65,6 +65,7 @@ function documentElementCheck() {
*/
function blockedDomainCheck() {
const blockedDomains = [
'execution.consensys.io',
'execution.metamask.io',
'uscourts.gov',
'dropbox.com',

View File

@ -1,4 +1,7 @@
// Messages and descriptions for these locale keys are in app/_locales/en/messages.json
export const NOTIFICATION_OPEN_BETA_SNAPS = 26;
export const UI_NOTIFICATIONS = {
1: {
id: 1,
@ -125,6 +128,14 @@ export const UI_NOTIFICATIONS = {
id: 24,
date: null,
},
[NOTIFICATION_OPEN_BETA_SNAPS]: {
id: Number(NOTIFICATION_OPEN_BETA_SNAPS),
date: null,
image: {
src: 'images/introducing-snaps.svg',
width: '100%',
},
},
};
export const getTranslatedUINotifications = (t, locale) => {
@ -346,5 +357,20 @@ export const getTranslatedUINotifications = (t, locale) => {
)
: '',
},
[NOTIFICATION_OPEN_BETA_SNAPS]: {
...UI_NOTIFICATIONS[NOTIFICATION_OPEN_BETA_SNAPS],
title: t('notificationsOpenBetaSnapsTitle'),
description: [
t('notificationsOpenBetaSnapsDescriptionOne'),
t('notificationsOpenBetaSnapsDescriptionTwo'),
t('notificationsOpenBetaSnapsDescriptionThree'),
],
actionText: t('notificationsOpenBetaSnapsActionText'),
date: UI_NOTIFICATIONS[NOTIFICATION_OPEN_BETA_SNAPS].date
? new Intl.DateTimeFormat(formattedLocale).format(
new Date(UI_NOTIFICATIONS[NOTIFICATION_OPEN_BETA_SNAPS].date),
)
: '',
},
};
};

View File

@ -4,6 +4,7 @@ const yargs = require('yargs/yargs');
const { hideBin } = require('yargs/helpers');
const { runInShell } = require('../../development/lib/run-command');
const { exitWithError } = require('../../development/lib/exit-with-error');
const { loadBuildTypesConfig } = require('../../development/lib/build-type');
const getTestPathsForTestDir = async (testDir) => {
const testFilenames = await fs.readdir(testDir, { withFileTypes: true });
@ -60,6 +61,11 @@ async function main() {
description: `run mv3 specific e2e tests`,
type: 'boolean',
})
.option('build-type', {
description: `Sets the build-type to test for. This may filter out tests.`,
type: 'string',
choices: Object.keys(loadBuildTypesConfig().buildTypes),
})
.option('retries', {
description:
'Set how many times the test should be retried upon failure.',
@ -69,13 +75,25 @@ async function main() {
.strict()
.help('help');
const { browser, debug, retries, snaps, mv3 } = argv;
const { browser, debug, retries, snaps, mv3, buildType } = argv;
let testPaths;
if (snaps) {
const testDir = path.join(__dirname, 'snaps');
testPaths = await getTestPathsForTestDir(testDir);
if (buildType && buildType !== 'flask') {
// These tests should only be ran on Flask for now
const filteredTests = [
'test-snap-manageAccount.spec.js',
'test-snap-rpc.spec.js',
'test-snap-lifecycle.spec.js',
];
testPaths = testPaths.filter((p) =>
filteredTests.every((filteredTest) => !p.endsWith(filteredTest)),
);
}
} else {
const testDir = path.join(__dirname, 'tests');
testPaths = [

View File

@ -1,5 +1,6 @@
module.exports = {
TEST_SNAPS_WEBSITE_URL: 'https://metamask.github.io/test-snaps/5.5.0/',
TEST_SNAPS_WEBSITE_URL:
'https://metamask.github.io/snaps/test-snaps/0.38.0-flask.1/',
TEST_SNAPS_SIMPLE_KEYRING_WEBSITE_URL:
'https://metamask.github.io/snap-simple-keyring/latest/',
'https://metamask.github.io/snap-simple-keyring/0.1.4/',
};

View File

@ -31,10 +31,10 @@ describe('Test Snap bip-32', function () {
await driver.delay(1000);
// find and scroll to the bip32 test and connect
const snapButton1 = await driver.findElement('#connectBip32');
const snapButton1 = await driver.findElement('#connectbip32');
await driver.scrollToElement(snapButton1);
await driver.delay(1000);
await driver.clickElement('#connectBip32');
await driver.clickElement('#connectbip32');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -84,7 +84,7 @@ describe('Test Snap bip-32', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectBip32',
css: '#connectbip32',
text: 'Reconnect to BIP-32 Snap',
});

View File

@ -32,10 +32,10 @@ describe('Test Snap bip-44', function () {
await driver.delay(1000);
// find and scroll to the bip44 test and connect
const snapButton1 = await driver.findElement('#connectBip44Snap');
const snapButton1 = await driver.findElement('#connectbip44');
await driver.scrollToElement(snapButton1);
await driver.delay(1000);
await driver.clickElement('#connectBip44Snap');
await driver.clickElement('#connectbip44');
await driver.delay(1000);
// switch to metamask extension and click connect and approve
@ -53,6 +53,9 @@ describe('Test Snap bip-44', function () {
tag: 'button',
});
await driver.waitForSelector({ text: 'Install' });
await driver.clickElementSafe('[data-testid="snap-install-scroll"]');
await driver.clickElement({
text: 'Install',
tag: 'button',
@ -61,6 +64,7 @@ describe('Test Snap bip-44', function () {
// deal with permissions popover
await driver.delay(500);
await driver.clickElement('#key-access-bip44-1-0');
await driver.clickElement('#key-access-bip44-3-1');
await driver.clickElement({
text: 'Confirm',
tag: 'button',
@ -76,7 +80,7 @@ describe('Test Snap bip-44', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectBip44Snap',
css: '#connectbip44',
text: 'Reconnect to BIP-44 Snap',
});

View File

@ -31,10 +31,10 @@ describe('Test Snap Cronjob', function () {
// navigate to test snaps page and connect
await driver.openNewPage(TEST_SNAPS_WEBSITE_URL);
await driver.delay(1000);
const snapButton = await driver.findElement('#connectCronjobSnap');
const snapButton = await driver.findElement('#connectcronjobs');
await driver.scrollToElement(snapButton);
await driver.delay(1000);
await driver.clickElement('#connectCronjobSnap');
await driver.clickElement('#connectcronjobs');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -71,8 +71,8 @@ describe('Test Snap Cronjob', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectCronjobSnap',
text: 'Reconnect to Cronjob Snap',
css: '#connectcronjobs',
text: 'Reconnect to Cronjobs Snap',
});
// switch to dialog popup, wait for a maximum of 65 seconds
@ -86,7 +86,10 @@ describe('Test Snap Cronjob', function () {
// look for the dialog popup to verify cronjob fired
const error = await driver.findElement('.snap-delineator__content');
const text = await error.getText();
assert.equal(text.includes(`Cronjob\nfired`), true);
assert.equal(
text.includes(`Cronjob\nThis dialog was triggered by a cronjob.`),
true,
);
// try to click on the Ok button and pass test if it works
await driver.clickElement({

View File

@ -31,10 +31,10 @@ describe('Test Snap Dialog', function () {
// navigate to test snaps page and connect to dialog snap
await driver.openNewPage(TEST_SNAPS_WEBSITE_URL);
await driver.delay(1000);
const dialogButton = await driver.findElement('#connectDialogSnap');
const dialogButton = await driver.findElement('#connectdialogs');
await driver.scrollToElement(dialogButton);
await driver.delay(1000);
await driver.clickElement('#connectDialogSnap');
await driver.clickElement('#connectdialogs');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -71,8 +71,8 @@ describe('Test Snap Dialog', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectDialogSnap',
text: 'Reconnect to Dialog Snap',
css: '#connectdialogs',
text: 'Reconnect to Dialogs Snap',
});
// click on alert dialog
@ -91,7 +91,10 @@ describe('Test Snap Dialog', function () {
let result = await driver.findElement('.snap-ui-renderer__panel');
await driver.scrollToElement(result);
await driver.delay(500);
assert.equal(await result.getText(), 'Alert Dialog\nText here');
assert.equal(
await result.getText(),
'Alert Dialog\nThis is an alert dialog. It has a single button: "OK".',
);
// click ok button
await driver.clickElement({
@ -109,7 +112,7 @@ describe('Test Snap Dialog', function () {
assert.equal(await result.getText(), 'null');
// click conf button
await driver.clickElement('#sendConfButton');
await driver.clickElement('#sendConfirmationButton');
await driver.delay(500);
// switch to dialog popup
@ -136,7 +139,7 @@ describe('Test Snap Dialog', function () {
assert.equal(await result.getText(), 'false');
// click conf button again
await driver.clickElement('#sendConfButton');
await driver.clickElement('#sendConfirmationButton');
await driver.delay(500);
// switch to dialog popup

View File

@ -31,10 +31,10 @@ describe('Test Snap Error', function () {
// navigate to test snaps page and connect
await driver.openNewPage(TEST_SNAPS_WEBSITE_URL);
await driver.delay(1000);
const snapButton = await driver.findElement('#connectErrorSnap');
const snapButton = await driver.findElement('#connecterrors');
await driver.scrollToElement(snapButton);
await driver.delay(1000);
await driver.clickElement('#connectErrorSnap');
await driver.clickElement('#connecterrors');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -72,8 +72,8 @@ describe('Test Snap Error', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectErrorSnap',
text: 'Reconnect to Error Snap',
css: '#connecterrors',
text: 'Reconnect to Errors Snap',
});
// find and click on send error
@ -90,7 +90,7 @@ describe('Test Snap Error', function () {
const text = await error.getText();
assert.equal(
text.includes(
"Snap Error: 'random error inside'. Error Code: '-32603'",
"Snap Error: 'Random error inside a promise.'. Error Code: '-32603'",
),
true,
);

View File

@ -30,10 +30,12 @@ describe('Test Snap ethereum_provider', function () {
// navigate to test snaps page and connect
await driver.driver.get(TEST_SNAPS_WEBSITE_URL);
await driver.delay(1000);
const snapButton = await driver.findElement('#connectEthproviderSnap');
const snapButton = await driver.findElement(
'#connectethereum-provider',
);
await driver.scrollToElement(snapButton);
await driver.delay(1000);
await driver.clickElement('#connectEthproviderSnap');
await driver.clickElement('#connectethereum-provider');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -65,16 +67,16 @@ describe('Test Snap ethereum_provider', function () {
tag: 'button',
});
// click send inputs on test snap page
// switch to test snap page
await driver.switchToWindowWithTitle('Test Snaps', windowHandles);
// wait for npm installation success
await driver.waitForSelector({
css: '#connectEthproviderSnap',
text: 'Reconnect to ethereum-provider Snap',
css: '#connectethereum-provider',
text: 'Reconnect to Ethereum Provider Snap',
});
// find and click on send test
// find and click on send get version
const snapButton2 = await driver.findElement('#sendEthprovider');
await driver.scrollToElement(snapButton2);
await driver.delay(500);
@ -83,7 +85,44 @@ describe('Test Snap ethereum_provider', function () {
// check the results of the message signature using waitForSelector
await driver.waitForSelector({
css: '#ethproviderResult',
text: 'true',
text: '"1337"',
});
// find and click on send get version
const snapButton3 = await driver.findElement(
'#sendEthproviderAccounts',
);
await driver.scrollToElement(snapButton3);
await driver.delay(500);
await driver.clickElement('#sendEthproviderAccounts');
// switch to metamask window and click through confirmations
const windowHandles2 = await driver.waitUntilXWindowHandles(
2,
1000,
10000,
);
await driver.switchToWindowWithTitle(
'MetaMask Notification',
windowHandles2,
);
await driver.clickElement({
text: 'Next',
tag: 'button',
});
await driver.delay(500);
await driver.clickElement({
text: 'Connect',
tag: 'button',
});
// switch to test snap page
await driver.switchToWindowWithTitle('Test Snaps', windowHandles);
// check the results of the message signature using waitForSelector
await driver.waitForSelector({
css: '#ethproviderResult',
text: '"0x5cfe73b6021e818b776b421b1c4db2474086a7e1"',
});
},
);

View File

@ -53,6 +53,8 @@ describe('Test Snap getEntropy', function () {
await driver.waitForSelector({ text: 'Install' });
await driver.clickElementSafe('[data-testid="snap-install-scroll"]');
await driver.clickElement({
text: 'Install',
tag: 'button',
@ -71,7 +73,7 @@ describe('Test Snap getEntropy', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectGetEntropySnap',
text: 'Reconnect to getEntropy Snap',
text: 'Reconnect to Get Entropy Snap',
});
// find and click on send test
@ -100,7 +102,7 @@ describe('Test Snap getEntropy', function () {
// check the results of the message signature using waitForSelector
await driver.waitForSelector({
css: '#entropySignResult',
text: '"0xb9c20d675976e12c8bb53c3fd8fdff2dee11ad2b132eb453b5a8f35b0553c52d3bcac0fd3324d22ff0c53b3445ef48c119ba6435bc9bfb03234806719599aa6f6245593238c734bcf9d94d2873cacdd65a3176be3ae7e5b84f95fdd4487a395f"',
text: '"0x9341785782b512c86235612365f1076b16731ed9473beb4d0804c30b7fcc3a055aa7103b02dc64014d923220712dfbef023ddcf6327b313ea2dfd4d83dc5a53e1c5e7f4e10bce49830eded302294054df8a7a46e5b6cb3e50eec564ecba17941"',
});
},
);

View File

@ -30,10 +30,10 @@ describe('Test Snap Installed', function () {
// navigate to test snaps page and connect
await driver.openNewPage(TEST_SNAPS_WEBSITE_URL);
await driver.delay(1000);
const confirmButton = await driver.findElement('#connectDialogSnap');
const confirmButton = await driver.findElement('#connectdialogs');
await driver.scrollToElement(confirmButton);
await driver.delay(500);
await driver.clickElement('#connectDialogSnap');
await driver.clickElement('#connectdialogs');
await driver.delay(500);
// switch to metamask extension and click connect
@ -70,14 +70,14 @@ describe('Test Snap Installed', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectDialogSnap',
text: 'Reconnect to Dialog Snap',
css: '#connectdialogs',
text: 'Reconnect to Dialogs Snap',
});
const errorButton = await driver.findElement('#connectErrorSnap');
const errorButton = await driver.findElement('#connecterrors');
await driver.scrollToElement(errorButton);
await driver.delay(500);
await driver.clickElement('#connectErrorSnap');
await driver.clickElement('#connecterrors');
// switch to metamask extension and click connect
windowHandles = await driver.waitUntilXWindowHandles(3, 1000, 10000);
@ -109,7 +109,7 @@ describe('Test Snap Installed', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#installedSnapsResult',
text: 'npm:@metamask/test-snap-dialog, npm:@metamask/test-snap-error',
text: 'npm:@metamask/dialog-example-snap, npm:@metamask/error-example-snap',
});
},
);

View File

@ -0,0 +1,97 @@
const { strict: assert } = require('assert');
const { withFixtures } = require('../helpers');
const FixtureBuilder = require('../fixture-builder');
const { TEST_SNAPS_WEBSITE_URL } = require('./enums');
describe('Test Snap Lifecycle Hooks', function () {
it('can run lifecycle hook on connect', async function () {
const ganacheOptions = {
accounts: [
{
secretKey:
'0x7C9529A67102755B7E6102D6D950AC5D5863C98713805CEC576B945B15B71EAC',
balance: 25000000000000000000,
},
],
};
await withFixtures(
{
fixtures: new FixtureBuilder().build(),
ganacheOptions,
failOnConsoleError: false,
title: this.test.title,
},
async ({ driver }) => {
await driver.navigate();
// enter pw into extension
await driver.fill('#password', 'correct horse battery staple');
await driver.press('#password', driver.Key.ENTER);
// navigate to test snaps page and connect
await driver.openNewPage(TEST_SNAPS_WEBSITE_URL);
await driver.delay(1000);
const snapButton = await driver.findElement('#connectlifecycle-hooks');
await driver.scrollToElement(snapButton);
await driver.delay(1000);
await driver.clickElement('#connectlifecycle-hooks');
await driver.delay(1000);
// switch to metamask extension and click connect
let windowHandles = await driver.waitUntilXWindowHandles(
3,
1000,
10000,
);
await driver.switchToWindowWithTitle(
'MetaMask Notification',
windowHandles,
);
await driver.clickElement({
text: 'Connect',
tag: 'button',
});
await driver.waitForSelector({ text: 'Install' });
await driver.clickElement({
text: 'Install',
tag: 'button',
});
await driver.waitForSelector({ text: 'OK' });
await driver.clickElement({
text: 'OK',
tag: 'button',
});
// click send inputs on test snap page
await driver.switchToWindowWithTitle('Test Snaps', windowHandles);
// wait for npm installation success
await driver.waitForSelector({
css: '#connectlifecycle-hooks',
text: 'Reconnect to Lifecycle Hooks Snap',
});
// switch to dialog popup
windowHandles = await driver.waitUntilXWindowHandles(3, 1000, 10000);
await driver.switchToWindowWithTitle(
'MetaMask Notification',
windowHandles,
);
await driver.delay(500);
// check dialog contents
const result = await driver.findElement('.snap-ui-renderer__panel');
await driver.scrollToElement(result);
await driver.delay(500);
assert.equal(
await result.getText(),
'Installation successful\nThe snap was installed successfully, and the "onInstall" handler was called.',
);
},
);
});
});

View File

@ -52,11 +52,7 @@ describe('Test Snap Account', function () {
tag: 'button',
});
try {
await driver.clickElement('[data-testid="snap-install-scroll"]');
} catch (_) {
console.log('Missing scroll');
}
await driver.clickElementSafe('[data-testid="snap-install-scroll"]');
await driver.waitForSelector({ text: 'Install' });

View File

@ -33,10 +33,10 @@ describe('Test Snap Management', function () {
await driver.delay(1000);
// find and scroll to the correct card and click first
const snapButton = await driver.findElement('#connectNotification');
const snapButton = await driver.findElement('#connectnotifications');
await driver.scrollToElement(snapButton);
await driver.delay(1000);
await driver.clickElement('#connectNotification');
await driver.clickElement('#connectnotifications');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -91,7 +91,7 @@ describe('Test Snap Management', function () {
// try to disable the snap
await driver.clickElement({
text: 'Notification Test Snap',
text: 'Notifications Example Snap',
tag: 'p',
});
await driver.clickElement('.toggle-button > div');
@ -138,7 +138,7 @@ describe('Test Snap Management', function () {
// try to remove snap
await driver.clickElement({
text: 'Remove Notification Test Snap',
text: 'Remove Notifications Example Snap',
tag: 'p',
});
await driver.delay(1000);

View File

@ -34,10 +34,10 @@ describe('Test Snap manageState', function () {
await driver.delay(1000);
// find and scroll to the connect button and click it
const snapButton1 = await driver.findElement('#connectManageState');
const snapButton1 = await driver.findElement('#connectmanage-state');
await driver.scrollToElement(snapButton1);
await driver.delay(1000);
await driver.clickElement('#connectManageState');
await driver.clickElement('#connectmanage-state');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -74,7 +74,7 @@ describe('Test Snap manageState', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectManageState',
css: '#connectmanage-state',
text: 'Reconnect to Manage State Snap',
});
@ -101,7 +101,7 @@ describe('Test Snap manageState', function () {
);
assert.equal(
await retrieveManageStateResult.getText(),
'{ "testState": [ "23" ] }',
'{ "items": [ "23" ] }',
);
// click clear results
@ -121,7 +121,7 @@ describe('Test Snap manageState', function () {
);
assert.equal(
await retrieveManageStateResult2.getText(),
'{ "testState": [] }',
'{ "items": [] }',
);
},
);

View File

@ -1,4 +1,3 @@
const { strict: assert } = require('assert');
const { withFixtures } = require('../helpers');
const FixtureBuilder = require('../fixture-builder');
const { TEST_SNAPS_WEBSITE_URL } = require('./enums');
@ -31,16 +30,14 @@ describe('Test Snap networkAccess', function () {
// navigate to test snaps page and connect to dialog snap
await driver.openNewPage(TEST_SNAPS_WEBSITE_URL);
await driver.delay(1000);
const dialogButton = await driver.findElement(
'#connectNetworkAccessSnap',
);
const dialogButton = await driver.findElement('#connectnetwork-access');
await driver.scrollToElement(dialogButton);
await driver.delay(1000);
await driver.clickElement('#connectNetworkAccessSnap');
await driver.clickElement('#connectnetwork-access');
await driver.delay(1000);
// switch to metamask extension and click connect
let windowHandles = await driver.waitUntilXWindowHandles(
const windowHandles = await driver.waitUntilXWindowHandles(
3,
1000,
10000,
@ -73,32 +70,18 @@ describe('Test Snap networkAccess', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectNetworkAccessSnap',
text: 'Reconnect to networkAccess Snap',
css: '#connectnetwork-access',
text: 'Reconnect to Network Access Snap',
});
// click on alert dialog
await driver.clickElement('#sendNetworkAccessTest');
await driver.delay(500);
// switch to dialog popup
windowHandles = await driver.waitUntilXWindowHandles(3, 1000, 10000);
await driver.switchToWindowWithTitle(
'MetaMask Notification',
windowHandles,
);
await driver.delay(500);
// check dialog contents
const result = await driver.findElement('.snap-ui-renderer__panel');
await driver.scrollToElement(result);
await driver.delay(500);
assert.equal(await result.getText(), 'FETCHED_SUCCESSFULLY');
// click ok button
await driver.clickElement({
text: 'OK',
tag: 'button',
// check for result correctness
await driver.waitForSelector({
css: '#networkAccessResult',
text: '"hello": "world"',
});
},
);

View File

@ -33,10 +33,10 @@ describe('Test Snap Notification', function () {
await driver.delay(1000);
// find and scroll down to snapId5 and connect
const snapButton = await driver.findElement('#connectNotification');
const snapButton = await driver.findElement('#connectnotifications');
await driver.scrollToElement(snapButton);
await driver.delay(1000);
await driver.clickElement('#connectNotification');
await driver.clickElement('#connectnotifications');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -74,8 +74,8 @@ describe('Test Snap Notification', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectNotification',
text: 'Reconnect to Notification Snap',
css: '#connectnotifications',
text: 'Reconnect to Notifications Snap',
});
await driver.clickElement('#sendInAppNotification');
@ -102,8 +102,8 @@ describe('Test Snap Notification', function () {
// try to click on the notification item (via xpath)
await driver.clickElement({
text: 'Notifications',
tag: 'span',
text: 'Notifications 1',
css: '.menu-item',
});
await driver.delay(500);
@ -113,7 +113,7 @@ describe('Test Snap Notification', function () {
);
assert.equal(
await notificationResultMessage.getText(),
'TEST INAPP NOTIFICATION',
'Hello from within MetaMask!',
);
},
);

View File

@ -32,10 +32,10 @@ describe('Test Snap RPC', function () {
await driver.delay(1000);
// find and scroll to the bip32 test and connect
const snapButton1 = await driver.findElement('#connectBip32');
const snapButton1 = await driver.findElement('#connectbip32');
await driver.scrollToElement(snapButton1);
await driver.delay(1000);
await driver.clickElement('#connectBip32');
await driver.clickElement('#connectbip32');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -84,10 +84,10 @@ describe('Test Snap RPC', function () {
// switch back to test-snaps window
await driver.switchToWindowWithTitle('Test Snaps', windowHandles);
const snapButton2 = await driver.findElement('#connectRpcSnap');
const snapButton2 = await driver.findElement('#connectjson-rpc');
await driver.scrollToElement(snapButton2);
await driver.delay(1000);
await driver.clickElement('#connectRpcSnap');
await driver.clickElement('#connectjson-rpc');
await driver.delay(1000);
windowHandles = await driver.waitUntilXWindowHandles(2, 1000, 10000);
@ -118,8 +118,8 @@ describe('Test Snap RPC', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectRpcSnap',
text: 'Reconnect to RPC Snap',
css: '#connectjson-rpc',
text: 'Reconnect to JSON-RPC Snap',
});
// click send inputs on test snap page

View File

@ -32,10 +32,12 @@ describe('Test Snap TxInsights', function () {
await driver.delay(1000);
// find and scroll to the bip32 test and connect
const snapButton1 = await driver.findElement('#connectInsightsSnap');
const snapButton1 = await driver.findElement(
'#connecttransaction-insights',
);
await driver.scrollToElement(snapButton1);
await driver.delay(1000);
await driver.clickElement('#connectInsightsSnap');
await driver.clickElement('#connecttransaction-insights');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -102,7 +104,7 @@ describe('Test Snap TxInsights', function () {
);
await driver.delay(1000);
await driver.clickElement({
text: 'TxInsightsTest',
text: 'Insights Example Snap',
tag: 'button',
});
@ -111,7 +113,10 @@ describe('Test Snap TxInsights', function () {
const txInsightsResult = await driver.findElement(
'.snap-ui-renderer__content',
);
assert.equal(await txInsightsResult.getText(), 'Test: Successful');
assert.equal(
await txInsightsResult.getText(),
'Transaction type:\nERC-20',
);
},
);
});

View File

@ -127,7 +127,7 @@ describe('Test Snap update', function () {
// look for the correct version text
await driver.waitForSelector({
css: '#updateSnapVersion',
text: '"5.1.2"',
text: '"0.35.2-flask.1"',
});
},
);

View File

@ -30,10 +30,10 @@ describe('Test Snap WASM', function () {
// navigate to test snaps page and connect
await driver.openNewPage(TEST_SNAPS_WEBSITE_URL);
await driver.delay(1000);
const snapButton = await driver.findElement('#connectWasmSnap');
const snapButton = await driver.findElement('#connectwasm');
await driver.scrollToElement(snapButton);
await driver.delay(1000);
await driver.clickElement('#connectWasmSnap');
await driver.clickElement('#connectwasm');
await driver.delay(1000);
// switch to metamask extension and click connect
@ -71,7 +71,7 @@ describe('Test Snap WASM', function () {
// wait for npm installation success
await driver.waitForSelector({
css: '#connectWasmSnap',
css: '#connectwasm',
text: 'Reconnect to WebAssembly Snap',
});

View File

@ -43,6 +43,7 @@
},
"BackupController": "undefined",
"CachedBalancesController": { "cachedBalances": "object" },
"CronjobController": { "jobs": "object" },
"CurrencyController": {
"conversionDate": "number",
"conversionRate": 1700,
@ -111,6 +112,7 @@
"allNfts": "object",
"ignoredNfts": "object"
},
"NotificationController": { "notifications": "object" },
"OnboardingController": {
"seedPhraseBackedUp": true,
"firstTimeFlowType": "import",
@ -170,6 +172,12 @@
"smartTransactions": "object"
}
},
"SnapController": {
"snapErrors": "object",
"snaps": "object",
"snapStates": "object"
},
"SnapsRegistry": { "database": "object", "lastUpdated": "object" },
"SubjectMetadataController": { "subjectMetadata": "object" },
"SwapsController": {
"swapsState": {

View File

@ -146,6 +146,13 @@
"allNftContracts": "object",
"allNfts": "object",
"ignoredNfts": "object",
"snapErrors": "object",
"snaps": "object",
"snapStates": "object",
"jobs": "object",
"database": "object",
"lastUpdated": "object",
"notifications": "object",
"accounts": "object",
"currentNetworkTxList": "object",
"unapprovedDecryptMsgs": "object",

View File

@ -249,6 +249,18 @@ class Driver {
await element.click();
}
async clickElementSafe(rawLocator) {
// for instances where an element such as a scroll button does not
// show up because of render differences, proceed to the next step
// without causing a test failure, but provide a console log of why.
try {
const element = await this.findClickableElement(rawLocator);
await element.click();
} catch (e) {
console.log(`Element ${rawLocator} not found (${e})`);
}
}
async clickPoint(rawLocator, x, y) {
const element = await this.findElement(rawLocator);
await this.driver

View File

@ -1,4 +1,4 @@
process.env.METAMASK_ENVIRONMENT = 'test';
process.env.SUPPORT_LINK = 'https://support.metamask.io';
process.env.IFRAME_EXECUTION_ENVIRONMENT_URL =
'https://execution.metamask.io/0.36.1-flask.1/index.html';
'https://execution.consensys.io/0.36.1-flask.1/index.html';

View File

@ -111,7 +111,7 @@ export default class ConfirmPageContainerContent extends Component {
} = this.props;
return (
<Tabs>
<Tabs defaultActiveTabKey="details">
<Tab
className="confirm-page-container-content__tab"
name={t('details')}

View File

@ -3,6 +3,9 @@ import PropTypes from 'prop-types';
import classnames from 'classnames';
import { ObjectInspector } from 'react-inspector';
import { ethErrors, serializeError } from 'eth-rpc-errors';
///: BEGIN:ONLY_INCLUDE_IN(snaps)
import { SubjectType } from '@metamask/permission-controller';
///: END:ONLY_INCLUDE_IN
import LedgerInstructionField from '../ledger-instruction-field';
import { MESSAGE_TYPE } from '../../../../shared/constants/app';
import {
@ -39,6 +42,9 @@ import { Text } from '../../component-library/text/deprecated';
import Box from '../../ui/box/box';
///: END:ONLY_INCLUDE_IN
import SignatureRequestHeader from '../signature-request-header';
///: BEGIN:ONLY_INCLUDE_IN(snaps)
import SnapLegacyAuthorshipHeader from '../snaps/snap-legacy-authorship-header';
///: END:ONLY_INCLUDE_IN
import SignatureRequestOriginalWarning from './signature-request-original-warning';
export default class SignatureRequestOriginal extends Component {
@ -172,16 +178,31 @@ export default class SignatureRequestOriginal extends Component {
}
<div className="request-signature__origin">
<SiteOrigin
title={txData.msgParams.origin}
siteOrigin={txData.msgParams.origin}
iconSrc={targetSubjectMetadata?.iconUrl}
iconName={
getURLHostName(targetSubjectMetadata?.origin) ||
targetSubjectMetadata?.origin
}
chip
/>
{
// Use legacy authorship header for snaps
///: BEGIN:ONLY_INCLUDE_IN(snaps)
targetSubjectMetadata?.subjectType === SubjectType.Snap ? (
<SnapLegacyAuthorshipHeader
snapId={targetSubjectMetadata.origin}
marginLeft={4}
marginRight={4}
/>
) : (
///: END:ONLY_INCLUDE_IN
<SiteOrigin
title={txData.msgParams.origin}
siteOrigin={txData.msgParams.origin}
iconSrc={targetSubjectMetadata?.iconUrl}
iconName={
getURLHostName(targetSubjectMetadata?.origin) ||
targetSubjectMetadata?.origin
}
chip
/>
///: BEGIN:ONLY_INCLUDE_IN(snaps)
)
///: END:ONLY_INCLUDE_IN
}
</div>
<Typography

View File

@ -0,0 +1 @@
export { default } from './snap-legacy-authorship-header';

View File

@ -0,0 +1,91 @@
import React from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import { useSelector } from 'react-redux';
import {
BackgroundColor,
TextColor,
TextVariant,
AlignItems,
FontWeight,
Display,
FlexDirection,
BlockSize,
BorderColor,
BorderRadius,
} from '../../../../helpers/constants/design-system';
import {
getSnapName,
removeSnapIdPrefix,
} from '../../../../helpers/utils/util';
import { Box, Text } from '../../../component-library';
import { getTargetSubjectMetadata } from '../../../../selectors';
import SnapAvatar from '../snap-avatar';
const SnapLegacyAuthorshipHeader = ({
snapId,
className,
marginLeft,
marginRight,
}) => {
const packageName = snapId && removeSnapIdPrefix(snapId);
const subjectMetadata = useSelector((state) =>
getTargetSubjectMetadata(state, snapId),
);
const friendlyName = snapId && getSnapName(snapId, subjectMetadata);
return (
<Box
className={classnames('snap-legacy-authorship-header', className)}
backgroundColor={BackgroundColor.backgroundDefault}
width={BlockSize.Full}
alignItems={AlignItems.center}
display={Display.Flex}
padding={2}
borderColor={BorderColor.borderDefault}
borderRadius={BorderRadius.pill}
marginLeft={marginLeft}
marginRight={marginRight}
>
<Box>
<SnapAvatar snapId={snapId} />
</Box>
<Box
marginLeft={4}
marginRight={4}
display={Display.Flex}
flexDirection={FlexDirection.Column}
style={{ overflow: 'hidden' }}
>
<Text ellipsis fontWeight={FontWeight.Medium}>
{friendlyName}
</Text>
<Text
ellipsis
variant={TextVariant.bodySm}
color={TextColor.textAlternative}
>
{packageName}
</Text>
</Box>
</Box>
);
};
SnapLegacyAuthorshipHeader.propTypes = {
/**
* The id of the snap
*/
snapId: PropTypes.string,
/**
* The className of the SnapLegacyAuthorshipHeader
*/
className: PropTypes.string,
marginLeft: PropTypes.number,
marginRight: PropTypes.number,
};
export default SnapLegacyAuthorshipHeader;

View File

@ -0,0 +1,21 @@
import React from 'react';
import SnapLegacyAuthorshipHeader from './snap-legacy-authorship-header';
export default {
title: 'Components/App/Snaps/SnapLegacyAuthorshipHeader',
component: SnapLegacyAuthorshipHeader,
argTypes: {
snapId: {
control: 'text',
},
},
};
export const DefaultStory = (args) => <SnapLegacyAuthorshipHeader {...args} />;
DefaultStory.storyName = 'Default';
DefaultStory.args = {
snapId: 'npm:@metamask/test-snap-bip44',
};

View File

@ -21,7 +21,7 @@ describe('Snap Privacy Warning Popover', () => {
).toBeInTheDocument();
expect(
screen.getByText(
'Consensys has no access to information you share with these third parties.',
'Consensys has no access to information you share with Third Party Services.',
),
).toBeInTheDocument();
expect(

View File

@ -16,7 +16,11 @@ const Paragraph = (props) => (
/>
);
export const SnapUIMarkdown = ({ children }) => {
export const SnapUIMarkdown = ({ children, markdown }) => {
if (markdown === false) {
return <Paragraph>{children}</Paragraph>;
}
return (
<ReactMarkdown
allowedElements={['p', 'strong', 'em']}
@ -29,4 +33,5 @@ export const SnapUIMarkdown = ({ children }) => {
SnapUIMarkdown.propTypes = {
children: PropTypes.string,
markdown: PropTypes.bool,
};

View File

@ -46,6 +46,9 @@ export const UI_MAPPING = {
text: (props) => ({
element: 'SnapUIMarkdown',
children: props.value,
props: {
markdown: props.markdown,
},
}),
spinner: () => ({
element: 'Spinner',

View File

@ -16,7 +16,10 @@ import {
} from '../../component-library';
import { Text } from '../../component-library/text/deprecated';
import { updateViewedNotifications } from '../../../store/actions';
import { getTranslatedUINotifications } from '../../../../shared/notifications';
import {
NOTIFICATION_OPEN_BETA_SNAPS,
getTranslatedUINotifications,
} from '../../../../shared/notifications';
import { getSortedAnnouncementsToShow } from '../../../selectors';
import {
BUILD_QUOTE_ROUTE,
@ -106,6 +109,12 @@ function getActionFunctionById(id, history) {
24: () => {
updateViewedNotifications({ 24: true });
},
[NOTIFICATION_OPEN_BETA_SNAPS]: () => {
updateViewedNotifications({ [NOTIFICATION_OPEN_BETA_SNAPS]: true });
global.platform.openTab({
url: 'https://metamask.io/snaps/',
});
},
};
return actionFunctions[id];
@ -368,6 +377,7 @@ export default function WhatsNewPopup({
21: renderFirstNotification,
22: renderFirstNotification,
24: renderFirstNotification,
[NOTIFICATION_OPEN_BETA_SNAPS]: renderFirstNotification,
};
return (

View File

@ -203,7 +203,7 @@ export const GlobalMenu = ({ closeMenu, anchorElement }) => {
history.push(NOTIFICATIONS_ROUTE);
}}
>
<Text as="span">{t('notifications')}</Text>
{t('notifications')}
{unreadNotificationsCount > 0 && (
<Text
as="span"

View File

@ -389,6 +389,12 @@ export const PERMISSION_DESCRIPTIONS = deepFreeze({
return results;
},
[EndowmentPermissions['endowment:lifecycle-hooks']]: ({ t }) => ({
label: t('permission_lifecycleHooks'),
description: t('permission_lifecycleHooksDescription'),
leftIcon: IconName.Hierarchy,
weight: 3,
}),
///: END:ONLY_INCLUDE_IN
///: BEGIN:ONLY_INCLUDE_IN(keyring-snaps)
[RestrictedMethods.snap_manageAccounts]: ({ t }) => ({

View File

@ -4,6 +4,7 @@ import { useDispatch, useSelector } from 'react-redux';
import { useHistory, withRouter } from 'react-router-dom';
import log from 'loglevel';
import { cloneDeep } from 'lodash';
import { SubjectType } from '@metamask/permission-controller';
import * as actions from '../../store/actions';
import txHelper from '../../helpers/utils/tx-helper';
import SignatureRequest from '../../components/app/signature-request';
@ -16,13 +17,14 @@ import {
///: BEGIN:ONLY_INCLUDE_IN(build-mmi)
getSelectedAccount,
///: END:ONLY_INCLUDE_IN
getTargetSubjectMetadata,
} from '../../selectors';
import { MESSAGE_TYPE } from '../../../shared/constants/app';
import { TransactionStatus } from '../../../shared/constants/transaction';
import { getSendTo } from '../../ducks/send';
import { getProviderConfig } from '../../ducks/metamask/metamask';
const signatureSelect = (txData) => {
const signatureSelect = (txData, targetSubjectMetadata) => {
const {
type,
msgParams: { version, siwe },
@ -36,7 +38,7 @@ const signatureSelect = (txData) => {
return SignatureRequest;
}
if (siwe?.isSIWEMessage) {
if (siwe?.isSIWEMessage && targetSubjectMetadata !== SubjectType.Snap) {
return SignatureRequestSIWE;
}
@ -167,11 +169,16 @@ const ConfirmTxScreen = ({ match }) => {
const txData = getTxData() || {};
const { msgParams } = txData;
const targetSubjectMetadata = useSelector((state) =>
getTargetSubjectMetadata(state, msgParams?.origin),
);
if (!msgParams) {
return <Loading />;
}
const SigComponent = signatureSelect(txData);
const SigComponent = signatureSelect(txData, targetSubjectMetadata);
return (
<SigComponent

View File

@ -65,9 +65,9 @@ export default class ConnectedAccounts extends PureComponent {
onClose={() => history.push(mostRecentOverviewPage)}
footerClassName="connected-accounts__footer"
footer={
connectedAccounts.length ? (
permissions?.length > 0 && (
<ConnectedAccountsPermissions permissions={permissions} />
) : null
)
}
>
<ConnectedAccountsList

View File

@ -66,7 +66,11 @@ describe('Notifications', () => {
const { getByText, getByRole } = render(mockStore);
expect(getByText('Nothing to see here.')).toBeDefined();
expect(
getByText(
'This is where you can find notifications from your installed snaps.',
),
).toBeDefined();
expect(getByRole('button', { name: 'Mark all as read' })).toBeDisabled();
});
});

View File

@ -93,6 +93,7 @@ import {
hexToDecimal,
} from '../../shared/modules/conversion.utils';
import { BackgroundColor } from '../helpers/constants/design-system';
import { NOTIFICATION_OPEN_BETA_SNAPS } from '../../shared/notifications';
///: BEGIN:ONLY_INCLUDE_IN(snaps)
import { SNAPS_VIEW_ROUTE } from '../helpers/constants/routes';
import { getPermissionSubjects } from './permissions';
@ -1032,6 +1033,7 @@ function getAllowedAnnouncementIds(state) {
21: isSwapsChain,
22: true,
24: state.metamask.hadAdvancedGasFeesSetPriorToMigration92_3 === true,
[NOTIFICATION_OPEN_BETA_SNAPS]: true,
};
}

205
yarn.lock
View File

@ -4352,7 +4352,7 @@ __metadata:
languageName: node
linkType: hard
"@metamask/key-tree@npm:^7.0.0, @metamask/key-tree@npm:^7.1.1":
"@metamask/key-tree@npm:^7.1.1":
version: 7.1.1
resolution: "@metamask/key-tree@npm:7.1.1"
dependencies:
@ -4366,6 +4366,20 @@ __metadata:
languageName: node
linkType: hard
"@metamask/key-tree@npm:^9.0.0":
version: 9.0.0
resolution: "@metamask/key-tree@npm:9.0.0"
dependencies:
"@metamask/scure-bip39": ^2.1.0
"@metamask/utils": ^6.0.1
"@noble/ed25519": ^1.6.0
"@noble/hashes": ^1.0.0
"@noble/secp256k1": ^1.5.5
"@scure/base": ^1.0.0
checksum: 5c81f07351ca59b37570d52edcc80d60424630b2a8403ed7149c3343c264878ac5d3fc0584a61635ea7ddda4a789295ded1247846606dc529d8e2fd42f6fc61a
languageName: node
linkType: hard
"@metamask/keyring-api@npm:^0.1.3":
version: 0.1.3
resolution: "@metamask/keyring-api@npm:0.1.3"
@ -4669,20 +4683,20 @@ __metadata:
languageName: node
linkType: hard
"@metamask/rpc-methods-flask@npm:@metamask/rpc-methods@0.36.1-flask.1, @metamask/rpc-methods@npm:^0.36.1-flask.1":
version: 0.36.1-flask.1
resolution: "@metamask/rpc-methods@npm:0.36.1-flask.1"
"@metamask/rpc-methods-flask@npm:@metamask/rpc-methods@0.37.2-flask.1, @metamask/rpc-methods@npm:^0.37.2-flask.1":
version: 0.37.2-flask.1
resolution: "@metamask/rpc-methods@npm:0.37.2-flask.1"
dependencies:
"@metamask/key-tree": ^7.1.1
"@metamask/key-tree": ^9.0.0
"@metamask/permission-controller": ^4.0.0
"@metamask/snaps-ui": ^0.36.1-flask.1
"@metamask/snaps-utils": ^0.36.1-flask.1
"@metamask/snaps-ui": ^0.37.2-flask.1
"@metamask/snaps-utils": ^0.37.2-flask.1
"@metamask/types": ^1.1.0
"@metamask/utils": ^6.0.1
"@noble/hashes": ^1.3.1
eth-rpc-errors: ^4.0.3
superstruct: ^1.0.3
checksum: 1172d2783285656478ba14fc9dbebfd7ad4150826f5eddd737a6cae376cf0e1d69e7b53570c9be45d95a14cc0533269ab4f2c8c4f28e3d867cfd06d68b5a2aac
checksum: f5b955c3a7b7c042c27aa5d9464ea5d9135104c20af3315ea00d8941c5c6379c12c82c0988bc5c21409f4dd8b740bb93b387e2ee115c914b434e28101cd9d877
languageName: node
linkType: hard
@ -4704,22 +4718,22 @@ __metadata:
languageName: node
linkType: hard
"@metamask/rpc-methods@npm:^1.0.0-prerelease.1":
version: 1.0.0-prerelease.1
resolution: "@metamask/rpc-methods@npm:1.0.0-prerelease.1"
"@metamask/rpc-methods@npm:^1.0.2":
version: 1.0.2
resolution: "@metamask/rpc-methods@npm:1.0.2"
dependencies:
"@metamask/browser-passworder": ^4.0.2
"@metamask/key-tree": ^7.1.1
"@metamask/permission-controller": ^4.0.0
"@metamask/snaps-ui": ^1.0.0-prerelease.1
"@metamask/snaps-utils": ^1.0.0-prerelease.1
"@metamask/snaps-ui": ^1.0.2
"@metamask/snaps-utils": ^1.0.2
"@metamask/types": ^1.1.0
"@metamask/utils": ^6.0.1
"@noble/hashes": ^1.1.3
eth-rpc-errors: ^4.0.2
nanoid: ^3.1.31
superstruct: ^1.0.3
checksum: 6c97446d41d77c11182a065d39e4030781fbbb67d941b2f85c739784f9ddef601fec1485567fa18d505ea8e50c825cbd6ccddafd5bc9939f2b8922d7009cf321
checksum: b5de7ea63726cf3dc2324e8bc462d95de67bbf15f34849a2fdcb321efa21f255644b83e79ae1b1305a5b4ac0d7fb8fd110b917d08541326ba3d4dab3dbc1e594
languageName: node
linkType: hard
@ -4811,19 +4825,19 @@ __metadata:
languageName: node
linkType: hard
"@metamask/snaps-controllers-flask@npm:@metamask/snaps-controllers@0.36.1-flask.1":
version: 0.36.1-flask.1
resolution: "@metamask/snaps-controllers@npm:0.36.1-flask.1"
"@metamask/snaps-controllers-flask@npm:@metamask/snaps-controllers@0.38.0-flask.1":
version: 0.38.0-flask.1
resolution: "@metamask/snaps-controllers@npm:0.38.0-flask.1"
dependencies:
"@metamask/approval-controller": ^3.0.0
"@metamask/base-controller": ^3.0.0
"@metamask/object-multiplex": ^1.2.0
"@metamask/permission-controller": ^4.0.0
"@metamask/post-message-stream": ^6.1.2
"@metamask/rpc-methods": ^0.36.1-flask.1
"@metamask/snaps-execution-environments": ^0.36.1-flask.1
"@metamask/rpc-methods": ^0.37.2-flask.1
"@metamask/snaps-execution-environments": ^0.38.0-flask.1
"@metamask/snaps-registry": ^1.2.1
"@metamask/snaps-utils": ^0.36.1-flask.1
"@metamask/snaps-utils": ^0.38.0-flask.1
"@metamask/utils": ^6.0.1
"@xstate/fsm": ^2.0.0
concat-stream: ^2.0.0
@ -4837,7 +4851,7 @@ __metadata:
pump: ^3.0.0
readable-web-to-node-stream: ^3.0.2
tar-stream: ^2.2.0
checksum: 9e7f9fa7a5989d4afda7cb6c8c7071059c2b48a2f3c6548eba0aca4ccf0103c3aa59167b1a31f905b9e8cbf79f41b9344945dd35719934083a18a85225985766
checksum: 538d2fc5295f094d5852c8385b99c60daf3874628f6627926b10412a309d86a7ee3e5bcb61f8c3fdd40b403d6ea08795aa2d338271924c36c6204d65adfcacd6
languageName: node
linkType: hard
@ -4871,19 +4885,19 @@ __metadata:
languageName: node
linkType: hard
"@metamask/snaps-controllers@npm:^1.0.0-prerelease.1":
version: 1.0.0-prerelease.1
resolution: "@metamask/snaps-controllers@npm:1.0.0-prerelease.1"
"@metamask/snaps-controllers@npm:^1.0.2":
version: 1.0.2
resolution: "@metamask/snaps-controllers@npm:1.0.2"
dependencies:
"@metamask/approval-controller": ^3.0.0
"@metamask/base-controller": ^3.0.0
"@metamask/object-multiplex": ^1.2.0
"@metamask/permission-controller": ^4.0.0
"@metamask/post-message-stream": ^6.1.2
"@metamask/rpc-methods": ^1.0.0-prerelease.1
"@metamask/snaps-execution-environments": ^1.0.0-prerelease.1
"@metamask/rpc-methods": ^1.0.2
"@metamask/snaps-execution-environments": ^1.0.2
"@metamask/snaps-registry": ^1.2.1
"@metamask/snaps-utils": ^1.0.0-prerelease.1
"@metamask/snaps-utils": ^1.0.2
"@metamask/utils": ^6.0.1
"@xstate/fsm": ^2.0.0
concat-stream: ^2.0.0
@ -4897,7 +4911,7 @@ __metadata:
pump: ^3.0.0
readable-web-to-node-stream: ^3.0.2
tar-stream: ^2.2.0
checksum: 695fd90ad0f8bf2befd813e4ca8568b496575d581e94cac608a6daea55be57f508c5615d05e974d2de459a74cd6f84fb5ab7eb763e56e50b28484989e3e04ca6
checksum: 3a85ab7379f8034909efe53be6afb17d0f6804fc6628a63e22117e504aea2a42d1036a96432efd13bd6987e289b9e623e682306e5bd30ee2e207cb531cc627e9
languageName: node
linkType: hard
@ -4922,15 +4936,15 @@ __metadata:
languageName: node
linkType: hard
"@metamask/snaps-execution-environments@npm:^0.36.1-flask.1":
version: 0.36.1-flask.1
resolution: "@metamask/snaps-execution-environments@npm:0.36.1-flask.1"
"@metamask/snaps-execution-environments@npm:^0.38.0-flask.1":
version: 0.38.0-flask.1
resolution: "@metamask/snaps-execution-environments@npm:0.38.0-flask.1"
dependencies:
"@metamask/object-multiplex": ^1.2.0
"@metamask/post-message-stream": ^6.1.2
"@metamask/providers": ^11.0.0
"@metamask/rpc-methods": ^0.36.1-flask.1
"@metamask/snaps-utils": ^0.36.1-flask.1
"@metamask/rpc-methods": ^0.37.2-flask.1
"@metamask/snaps-utils": ^0.38.0-flask.1
"@metamask/utils": ^6.0.1
eth-rpc-errors: ^4.0.3
json-rpc-engine: ^6.1.0
@ -4939,19 +4953,19 @@ __metadata:
ses: ^0.18.1
stream-browserify: ^3.0.0
superstruct: ^1.0.3
checksum: 1863a37df13f8c0684a5b5d281e53294869a75daa4c4b8429593aee29bff6bf4aad4365eee19a1a1e20cfa47557dc12c4e266dae74c5ab0e951a6917cf9af6e6
checksum: 725163d03c3c17d0a67ad5829adf69da8bcd2d3890efd984ff5954a19aeeeb4e024a96810d9ae9d5f095f1e39965376f62d41637ff61c59519f46c093f05b0f9
languageName: node
linkType: hard
"@metamask/snaps-execution-environments@npm:^1.0.0-prerelease.1":
version: 1.0.0-prerelease.1
resolution: "@metamask/snaps-execution-environments@npm:1.0.0-prerelease.1"
"@metamask/snaps-execution-environments@npm:^1.0.2":
version: 1.0.2
resolution: "@metamask/snaps-execution-environments@npm:1.0.2"
dependencies:
"@metamask/object-multiplex": ^1.2.0
"@metamask/post-message-stream": ^6.1.1
"@metamask/providers": ^10.2.0
"@metamask/rpc-methods": ^1.0.0-prerelease.1
"@metamask/snaps-utils": ^1.0.0-prerelease.1
"@metamask/rpc-methods": ^1.0.2
"@metamask/snaps-utils": ^1.0.2
"@metamask/utils": ^6.0.1
eth-rpc-errors: ^4.0.3
json-rpc-engine: ^6.1.0
@ -4959,7 +4973,7 @@ __metadata:
ses: ^0.18.1
stream-browserify: ^3.0.0
superstruct: ^1.0.3
checksum: f52a005f1355bb994ad5437a59efe69d9d873f4ed1624f428e54efeaf9728fccaa87a2801f8c80c8ecf76acc55792da0093c54b94676d3076fae0e4745bf7f96
checksum: a0197b68598e3562f47e8b5174cc67bbeeeff87e7f06a034a9be94e4f8ab40c943d1862c123b3ad2e2ef8f4dfd4f96f59beb139cfb3fd64eca67dbbcf9199efa
languageName: node
linkType: hard
@ -4974,13 +4988,13 @@ __metadata:
languageName: node
linkType: hard
"@metamask/snaps-ui-flask@npm:@metamask/snaps-ui@0.36.1-flask.1, @metamask/snaps-ui@npm:^0.36.1-flask.1":
version: 0.36.1-flask.1
resolution: "@metamask/snaps-ui@npm:0.36.1-flask.1"
"@metamask/snaps-ui-flask@npm:@metamask/snaps-ui@0.37.3-flask.1, @metamask/snaps-ui@npm:^0.37.3-flask.1":
version: 0.37.3-flask.1
resolution: "@metamask/snaps-ui@npm:0.37.3-flask.1"
dependencies:
"@metamask/utils": ^6.0.1
superstruct: ^1.0.3
checksum: 85c8426003008836e3461a6287e0199ccc083f9e84053862a2e12a7763141c1a71bfdf9c2b46607a0ae14fdcd93cff22cbee3adf5fcef9364413c91acbeb812d
checksum: 0b93f6edeca18afc799f16be8b4e4d758800ea0d68298c70492dc85f74ec9f79c2aa32749f6725bb83a4896fdb1ec95a7d19a10a617484e0a7574ddad7969bd3
languageName: node
linkType: hard
@ -4994,42 +5008,53 @@ __metadata:
languageName: node
linkType: hard
"@metamask/snaps-ui@npm:^1.0.0-prerelease.1":
version: 1.0.0-prerelease.1
resolution: "@metamask/snaps-ui@npm:1.0.0-prerelease.1"
"@metamask/snaps-ui@npm:^0.37.2-flask.1":
version: 0.37.2-flask.1
resolution: "@metamask/snaps-ui@npm:0.37.2-flask.1"
dependencies:
"@metamask/utils": ^6.0.1
superstruct: ^1.0.3
checksum: 58ab96cff1512e3a2ed607277f18c2a17a8c2dfe2e75df4705654cbfbcfcbfb5a7da6975fa81aaf0b58166e9d56cd36e44f4ddc50e10d51a8c1d75c826cd8b17
checksum: a52a887411d689a7a0b017b3741c76819567416c7943ca3c71f5b5f8b623605689f370f70caa8a22531d711d10738c913b0d561fcda09a92c38e288d115e6bac
languageName: node
linkType: hard
"@metamask/snaps-utils-flask@npm:@metamask/snaps-utils@0.36.1-flask.1, @metamask/snaps-utils@npm:^0.36.1-flask.1":
version: 0.36.1-flask.1
resolution: "@metamask/snaps-utils@npm:0.36.1-flask.1"
"@metamask/snaps-ui@npm:^1.0.2":
version: 1.0.2
resolution: "@metamask/snaps-ui@npm:1.0.2"
dependencies:
"@metamask/utils": ^6.0.1
superstruct: ^1.0.3
checksum: eb3d8806803d7e5e7677550eb0eaec4102f8b1b2aad660b408ebb8d3c532666a422176b2ff7c490bfb427c9378449976f16b19c9c5330759dff5283db9fe7224
languageName: node
linkType: hard
"@metamask/snaps-utils-flask@npm:@metamask/snaps-utils@0.38.0-flask.1, @metamask/snaps-utils@npm:^0.38.0-flask.1":
version: 0.38.0-flask.1
resolution: "@metamask/snaps-utils@npm:0.38.0-flask.1"
dependencies:
"@babel/core": ^7.20.12
"@babel/types": ^7.18.7
"@metamask/base-controller": ^3.0.0
"@metamask/key-tree": ^7.1.1
"@metamask/key-tree": ^9.0.0
"@metamask/permission-controller": ^4.0.0
"@metamask/providers": ^11.0.0
"@metamask/snaps-registry": ^1.2.1
"@metamask/snaps-ui": ^0.36.1-flask.1
"@metamask/snaps-ui": ^0.37.3-flask.1
"@metamask/utils": ^6.0.1
"@noble/hashes": ^1.3.1
"@scure/base": ^1.1.1
chalk: ^4.1.2
cron-parser: ^4.5.0
eth-rpc-errors: ^4.0.3
fast-deep-equal: ^3.1.3
fast-json-stable-stringify: ^2.1.0
is-svg: ^4.4.0
rfdc: ^1.3.0
semver: ^7.3.7
semver: ^7.5.4
ses: ^0.18.1
superstruct: ^1.0.3
validate-npm-package-name: ^5.0.0
checksum: 9d7d1d77ac03c58c51221a551b4718add396e5591c33dcb0c6799d0ba69ae775bb8c2f55b2bb1642842d13fd7b979437f34d4cabf6ec69832bff050ee6bb46d3
checksum: 9b79feabcf3a99f0faa53c87711e0de155807d49dd3a9117933b9636d529fa3f3449bd563535f056fc7cbb3eaffcd9e9703b02985bdb6cfdc090d096d76dad8e
languageName: node
linkType: hard
@ -5062,9 +5087,39 @@ __metadata:
languageName: node
linkType: hard
"@metamask/snaps-utils@npm:^1.0.0-prerelease.1":
version: 1.0.0-prerelease.1
resolution: "@metamask/snaps-utils@npm:1.0.0-prerelease.1"
"@metamask/snaps-utils@npm:^0.37.2-flask.1":
version: 0.37.2-flask.1
resolution: "@metamask/snaps-utils@npm:0.37.2-flask.1"
dependencies:
"@babel/core": ^7.20.12
"@babel/types": ^7.18.7
"@metamask/base-controller": ^3.0.0
"@metamask/key-tree": ^9.0.0
"@metamask/permission-controller": ^4.0.0
"@metamask/providers": ^11.0.0
"@metamask/snaps-registry": ^1.2.1
"@metamask/snaps-ui": ^0.37.2-flask.1
"@metamask/utils": ^6.0.1
"@noble/hashes": ^1.3.1
"@scure/base": ^1.1.1
chalk: ^4.1.2
cron-parser: ^4.5.0
eth-rpc-errors: ^4.0.3
fast-deep-equal: ^3.1.3
fast-json-stable-stringify: ^2.1.0
is-svg: ^4.4.0
rfdc: ^1.3.0
semver: ^7.3.7
ses: ^0.18.1
superstruct: ^1.0.3
validate-npm-package-name: ^5.0.0
checksum: eeb31013a8af39b5488fdb8a6a72e11c54274e423e0f2560fd5cf4ea0278e278aff60be070c1e5b847d84220f15338e01c4725ce7ebb5f3fc614553ae4235f44
languageName: node
linkType: hard
"@metamask/snaps-utils@npm:^1.0.2":
version: 1.0.2
resolution: "@metamask/snaps-utils@npm:1.0.2"
dependencies:
"@babel/core": ^7.18.6
"@babel/types": ^7.18.7
@ -5073,7 +5128,7 @@ __metadata:
"@metamask/permission-controller": ^4.0.0
"@metamask/providers": ^10.2.1
"@metamask/snaps-registry": ^1.2.1
"@metamask/snaps-ui": ^1.0.0-prerelease.1
"@metamask/snaps-ui": ^1.0.2
"@metamask/utils": ^6.0.1
"@noble/hashes": ^1.1.3
"@scure/base": ^1.1.1
@ -5082,11 +5137,11 @@ __metadata:
fast-deep-equal: ^3.1.3
fast-json-stable-stringify: ^2.1.0
rfdc: ^1.3.0
semver: ^7.3.7
ses: ^0.18.1
semver: ^7.5.4
ses: ^0.18.7
superstruct: ^1.0.3
validate-npm-package-name: ^5.0.0
checksum: cd16003c748c60c0db33eaf16189a210e7165abc5e6e913d164c2b20ce6b5bb27df5471fac5913b6ba07f7aff845f37c404fa13c4015448a75cb531418e8442f
checksum: e207652c0ba61970f7a298325a75edbd330fc8f62f2a23a6429dd2448db66b59414794e77389b72d007d5b18c21e6331dcb815d2bbe91851843d8ee0902600d9
languageName: node
linkType: hard
@ -24673,7 +24728,7 @@ __metadata:
"@metamask/forwarder": ^1.1.0
"@metamask/gas-fee-controller": ^6.0.1
"@metamask/jazzicon": ^2.0.0
"@metamask/key-tree": ^7.0.0
"@metamask/key-tree": ^9.0.0
"@metamask/logo": ^3.1.1
"@metamask/message-manager": ^7.0.2
"@metamask/metamask-eth-abis": ^3.0.0
@ -24687,19 +24742,19 @@ __metadata:
"@metamask/ppom-validator": ^0.0.1
"@metamask/providers": ^11.1.0
"@metamask/rate-limit-controller": ^3.0.0
"@metamask/rpc-methods": ^1.0.0-prerelease.1
"@metamask/rpc-methods-flask": "npm:@metamask/rpc-methods@0.36.1-flask.1"
"@metamask/rpc-methods": ^1.0.2
"@metamask/rpc-methods-flask": "npm:@metamask/rpc-methods@0.37.2-flask.1"
"@metamask/safe-event-emitter": ^2.0.0
"@metamask/scure-bip39": ^2.0.3
"@metamask/signature-controller": ^4.0.1
"@metamask/slip44": ^3.0.0
"@metamask/smart-transactions-controller": ^3.1.0
"@metamask/snaps-controllers": ^1.0.0-prerelease.1
"@metamask/snaps-controllers-flask": "npm:@metamask/snaps-controllers@0.36.1-flask.1"
"@metamask/snaps-ui": ^1.0.0-prerelease.1
"@metamask/snaps-ui-flask": "npm:@metamask/snaps-ui@0.36.1-flask.1"
"@metamask/snaps-utils": ^1.0.0-prerelease.1
"@metamask/snaps-utils-flask": "npm:@metamask/snaps-utils@0.36.1-flask.1"
"@metamask/snaps-controllers": ^1.0.2
"@metamask/snaps-controllers-flask": "npm:@metamask/snaps-controllers@0.38.0-flask.1"
"@metamask/snaps-ui": ^1.0.2
"@metamask/snaps-ui-flask": "npm:@metamask/snaps-ui@0.37.3-flask.1"
"@metamask/snaps-utils": ^1.0.2
"@metamask/snaps-utils-flask": "npm:@metamask/snaps-utils@0.38.0-flask.1"
"@metamask/subject-metadata-controller": ^2.0.0
"@metamask/test-dapp": ^7.0.1
"@metamask/utils": ^5.0.0
@ -31341,14 +31396,14 @@ __metadata:
languageName: node
linkType: hard
"semver@npm:^7.0.0, semver@npm:^7.3.2, semver@npm:^7.3.5, semver@npm:^7.3.7, semver@npm:^7.3.8":
version: 7.5.0
resolution: "semver@npm:7.5.0"
"semver@npm:^7.0.0, semver@npm:^7.3.2, semver@npm:^7.3.5, semver@npm:^7.3.7, semver@npm:^7.3.8, semver@npm:^7.5.4":
version: 7.5.4
resolution: "semver@npm:7.5.4"
dependencies:
lru-cache: ^6.0.0
bin:
semver: bin/semver.js
checksum: 2d266937756689a76f124ffb4c1ea3e1bbb2b263219f90ada8a11aebebe1280b13bb76cca2ca96bdee3dbc554cbc0b24752eb895b2a51577aa644427e9229f2b
checksum: 12d8ad952fa353b0995bf180cdac205a4068b759a140e5d3c608317098b3575ac2f1e09182206bf2eb26120e1c0ed8fb92c48c592f6099680de56bb071423ca3
languageName: node
linkType: hard