Skip to content

Commit

Permalink
Merge branch 'develop' into feat/new-counter-over-the-fox
Browse files Browse the repository at this point in the history
  • Loading branch information
matteoscurati authored Jun 10, 2024
2 parents 6acd40d + 1fe9fd7 commit 7e13ad5
Show file tree
Hide file tree
Showing 198 changed files with 2,098 additions and 14,249 deletions.
143 changes: 1 addition & 142 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ workflows:
- validate-lavamoat-policy-webapp:
matrix:
parameters:
build-type: [main, beta, flask, mmi, desktop]
build-type: [main, beta, flask, mmi]
requires:
- prep-deps
- prep-build-mmi:
Expand All @@ -121,12 +121,6 @@ workflows:
- prep-build-mv2:
requires:
- prep-deps
- prep-build-desktop:
filters:
branches:
only: develop
requires:
- prep-deps
- prep-build-flask:
requires:
- prep-deps
Expand All @@ -139,9 +133,6 @@ workflows:
- prep-build-test-mv2:
requires:
- prep-deps
- prep-build-multichain-test:
requires:
- prep-deps
- prep-build-confirmation-redesign-test:
requires:
- prep-deps
Expand Down Expand Up @@ -180,9 +171,6 @@ workflows:
- test-e2e-chrome:
requires:
- prep-build-test
- test-e2e-chrome-multichain:
requires:
- prep-build-multichain-test
- test-e2e-chrome-confirmation-redesign:
requires:
- prep-build-confirmation-redesign-test
Expand Down Expand Up @@ -251,12 +239,6 @@ workflows:
- validate-source-maps-beta:
requires:
- trigger-beta-build
- validate-source-maps-desktop:
filters:
branches:
only: develop
requires:
- prep-build-desktop
- validate-source-maps-mmi:
requires:
- prep-build-mmi
Expand All @@ -270,13 +252,6 @@ workflows:
requires:
- prep-deps
- prep-build-mv2
- test-mozilla-lint-desktop:
filters:
branches:
only: develop
requires:
- prep-deps
- prep-build-desktop
- test-mozilla-lint-flask-mv2:
requires:
- prep-deps
Expand All @@ -298,14 +273,11 @@ workflows:
- upload-and-validate-coverage
- validate-source-maps
- validate-source-maps-beta
- validate-source-maps-desktop
- validate-source-maps-flask
- validate-source-maps-mmi
- test-mozilla-lint-mv2
- test-mozilla-lint-desktop
- test-mozilla-lint-flask-mv2
- test-e2e-chrome
- test-e2e-chrome-multichain
- test-e2e-chrome-multiple-providers
- test-e2e-chrome-confirmation-redesign
- test-e2e-firefox-confirmation-redesign
Expand All @@ -331,7 +303,6 @@ workflows:
- prep-build
- prep-build-mv2
- trigger-beta-build
- prep-build-desktop
- prep-build-mmi
- prep-build-flask
- prep-build-flask-mv2
Expand All @@ -349,7 +320,6 @@ workflows:
- prep-deps
- prep-build
- prep-build-mv2
- prep-build-desktop
- prep-build-mmi
- prep-build-flask
- prep-build-flask-mv2
Expand Down Expand Up @@ -611,31 +581,6 @@ jobs:
- dist-mv2
- builds-mv2

prep-build-desktop:
executor: node-browsers-medium-plus
steps:
- run: *shallow-git-clone
- run: sudo corepack enable
- attach_workspace:
at: .
- run:
name: build:dist
command: yarn build --build-type desktop dist
- run:
name: build:debug
command: find dist/ -type f -exec md5sum {} \; | sort -k 2
- run:
name: Move desktop build to 'dist-desktop' to avoid conflict with production build
command: mv ./dist ./dist-desktop
- run:
name: Move desktop zips to 'builds-desktop' to avoid conflict with production build
command: mv ./builds ./builds-desktop
- persist_to_workspace:
root: .
paths:
- dist-desktop
- builds-desktop

prep-build-mmi:
executor: node-browsers-medium-plus
steps:
Expand Down Expand Up @@ -905,28 +850,6 @@ jobs:
- dist-test-mv2
- builds-test-mv2

prep-build-multichain-test:
executor: node-browsers-medium-plus
steps:
- run: *shallow-git-clone
- run: sudo corepack enable
- attach_workspace:
at: .
- run:
name: Build extension for testing
command: MULTICHAIN=1 yarn build:test
- run:
name: Move test build to 'dist-test' to avoid conflict with production build
command: mv ./dist ./dist-test-multichain
- run:
name: Move test zips to 'builds-test' to avoid conflict with production build
command: mv ./builds ./builds-test-multichain
- persist_to_workspace:
root: .
paths:
- dist-test-multichain
- builds-test-multichain

prep-build-confirmation-redesign-test:
executor: node-browsers-medium-plus
steps:
Expand Down Expand Up @@ -1140,36 +1063,6 @@ jobs:
- store_test_results:
path: test/test-results/e2e

test-e2e-chrome-multichain:
executor: node-browsers-medium-plus
parallelism: 20
steps:
- run: *shallow-git-clone
- run: sudo corepack enable
- attach_workspace:
at: .
- run:
name: Move test build to dist
command: mv ./dist-test-multichain ./dist
- run:
name: Move test zips to builds
command: mv ./builds-test-multichain ./builds
- run:
name: test:e2e:chrome-multichain
command: |
if .circleci/scripts/test-run-e2e.sh
then
timeout 20m yarn test:e2e:chrome --retries 1
fi
no_output_timeout: 5m
environment:
MULTICHAIN: 1
- store_artifacts:
path: test-artifacts
destination: test-artifacts
- store_test_results:
path: test/test-results/e2e

test-e2e-chrome-confirmation-redesign:
executor: node-browsers-medium-plus
parallelism: 20
Expand Down Expand Up @@ -1797,23 +1690,6 @@ jobs:
command: |
.circleci/scripts/validate-source-maps-beta.sh
validate-source-maps-desktop:
executor: node-browsers-small
steps:
- run: *shallow-git-clone
- run: sudo corepack enable
- attach_workspace:
at: .
- run:
name: Move desktop build to dist
command: mv ./dist-desktop ./dist
- run:
name: Move desktop zips to builds
command: mv ./builds-desktop ./builds
- run:
name: Validate source maps
command: yarn validate-source-maps

validate-source-maps-mmi:
executor: node-browsers-small
steps:
Expand Down Expand Up @@ -1899,23 +1775,6 @@ jobs:
name: test:mozilla-lint
command: yarn mozilla-lint

test-mozilla-lint-desktop:
executor: node-browsers-medium
steps:
- run: *shallow-git-clone
- run: sudo corepack enable
- attach_workspace:
at: .
- run:
name: Move desktop build to dist
command: mv ./dist-desktop ./dist
- run:
name: Move desktop zips to builds
command: mv ./builds-desktop ./builds
- run:
name: test:mozilla-lint
command: yarn mozilla-lint

test-mozilla-lint-flask-mv2:
executor: node-browsers-medium
steps:
Expand Down
5 changes: 3 additions & 2 deletions .devcontainer/download-builds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,12 @@ async function getBuilds(branch: string, jobNames: string[]) {

console.log(`jobName: ${jobName}, jobId: ${jobId}`);

// Using the CircleCI API version 1.1 here, because this endpoint recently started requiring Authorization in v2
const response = await fetch(
`https://circleci.com/api/v2/project/gh/MetaMask/metamask-extension/${jobId}/artifacts`,
`https://circleci.com/api/v1.1/project/gh/MetaMask/metamask-extension/${jobId}/artifacts`,
);

const artifacts = (await response.json()).items;
const artifacts = await response.json();

if (!artifacts || artifacts.length === 0) {
return [];
Expand Down
33 changes: 0 additions & 33 deletions .github/workflows/trigger-metamask-desktop-ci.yml

This file was deleted.

10 changes: 2 additions & 8 deletions .github/workflows/update-lavamoat-policies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ jobs:
matrix:
# Ensure this is synchronized with the list below in the "commit-updated-policies" job
# and with the build type list in `builds.yml`
build-type: [main, beta, flask, mmi, desktop]
build-type: [main, beta, flask, mmi]
name: Update LavaMoat ${{ matrix.build-type }} application policy
runs-on: ubuntu-latest
needs:
Expand Down Expand Up @@ -184,7 +184,7 @@ jobs:
path: lavamoat/build-system
key: cache-build-${{ needs.prepare.outputs.COMMIT_SHA }}
fail-on-cache-miss: true
# One restore step per build type: [main, beta, flask, mmi, desktop]
# One restore step per build type: [main, beta, flask, mmi]
# Ensure this is synchronized with the list above in the "update-lavamoat-webapp-policy" job
# and with the build type list in `builds.yml`
- name: Restore main application policy
Expand All @@ -211,12 +211,6 @@ jobs:
path: lavamoat/browserify/mmi
key: cache-mmi-${{ needs.prepare.outputs.COMMIT_SHA }}
fail-on-cache-miss: true
- name: Restore desktop application policy
uses: actions/cache/restore@v3
with:
path: lavamoat/browserify/desktop
key: cache-desktop-${{ needs.prepare.outputs.COMMIT_SHA }}
fail-on-cache-miss: true
- name: Check whether there are policy changes
id: policy-changes
run: |
Expand Down
4 changes: 0 additions & 4 deletions .storybook/3.COLORS.stories.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -101,21 +101,17 @@ var(--color-error-inverse)

/** Warning */
var(--color-warning-default)
var(--color-warning-alternative) [DEPRECATED]
var(--color-warning-muted)
var(--color-warning-inverse)
var(--color-warning-disabled) [DEPRECATED]

/** Success */
var(--color-success-default)
var(--color-success-alternative) [DEPRECATED]
var(--color-success-muted)
var(--color-success-inverse)
var(--color-success-disabled) [DEPRECATED]

/** Info */
var(--color-info-default)
var(--color-info-alternative) [DEPRECATED]
var(--color-info-muted)
var(--color-info-inverse)
var(--color-info-disabled) [DEPRECATED]
Expand Down
10 changes: 5 additions & 5 deletions .storybook/4.SHADOW.stories.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ As well as the neutral colors for shadow 2 other colors exist that are used for
style={{
height: 100,
backgroundColor: 'var(--color-background-default)',
boxShadow: 'var(--shadow-size-lg) var(--color-shadow-default',
boxShadow: 'var(--shadow-size-lg) var(--color-shadow-default)',
borderRadius: '4px',
display: 'grid',
alignContent: 'center',
Expand All @@ -115,7 +115,7 @@ As well as the neutral colors for shadow 2 other colors exist that are used for
style={{
height: 100,
backgroundColor: 'var(--color-primary-default)',
boxShadow: 'var(--shadow-size-lg) var(--color-primary-shadow',
boxShadow: 'var(--shadow-size-lg) var(--color-primary-shadow)',
borderRadius: '4px',
display: 'grid',
alignContent: 'center',
Expand All @@ -129,7 +129,7 @@ As well as the neutral colors for shadow 2 other colors exist that are used for
style={{
height: 100,
backgroundColor: 'var(--color-error-default)',
boxShadow: 'var(--shadow-size-lg) var(--color-error-shadow',
boxShadow: 'var(--shadow-size-lg) var(--color-error-shadow)',
borderRadius: '4px',
display: 'grid',
alignContent: 'center',
Expand Down Expand Up @@ -232,7 +232,7 @@ Using both size and color tokens, different shadows can be applied to components
justifyContent: 'center',
height: 100,
textAlign: 'center',
boxShadow: 'var(--component-button-primary-shadow)',
boxShadow: 'var(--shadow-size-sm) var(--color-primary-shadow)',
backgroundColor: 'var(--color-primary-default)',
color: 'var(--color-primary-inverse)',
}}
Expand All @@ -247,7 +247,7 @@ Using both size and color tokens, different shadows can be applied to components
justifyContent: 'center',
height: 100,
textAlign: 'center',
boxShadow: 'var(--component-button-danger-shadow)',
boxShadow: 'var(--shadow-size-sm) var(--color-error-shadow)',
backgroundColor: 'var(--color-error-default)',
color: 'var(--color-error-inverse)',
}}
Expand Down
Loading

0 comments on commit 7e13ad5

Please sign in to comment.