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

15274 Commits

Author SHA1 Message Date
Erik Marks
a8c1756816
Remove 3box feature and delete ThreeBoxController (#14571)
* Remove 3box feature and delete ThreeBoxController

Lint locale messages

lavamoat policy updates

* Restore 3Box user trait with value `false`

The 3Box user trait has been restored and hard-coded as `false`. This
ensures that users don't get stuck in our metrics as having this trait.

A deprecation comment has been left in various places for this trait.

* Remove unused state

* Remove additional 3box-related things

* Run `yarn-deduplicate`

* Restore migration that was lost while rebasing

* Remove obsolete override

* Remove additional unused resolutions/dependencies

* Update LavaMoat policies

* Remove obsolete security advisory ignore entries

* Remove 3Box fixture builder method

* Update unit tests

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2022-10-31 13:50:50 -02:30
Peter Yinusa
88a6f3787c
[E2E] Restore tests (#16298)
* add restore test

* rename spec
2022-10-31 09:48:04 +00:00
Jyoti Puri
17af3bb11e
Making permission and approval controller methods idempotent (#15848) 2022-10-31 11:22:31 +05:30
Daniel
802a20449a
Exclude E2E tests for swaps until they are stabilised (#16303) 2022-10-28 20:34:10 +02:00
Daniel
2f84010629
Add e2e tests for Swaps notifications (#16202) 2022-10-28 16:09:46 +02:00
Peter Yinusa
0b4532ec1b
E2e test fixtures (#16061)
* remove state.json files

* move file

* Update Readme

* Create fixture builder

* load test fixture

* remove redundant method

* update snap tests

* update stats tests

* update extension tests

* update extension tests

* Update fixture data

* snap test dapp connection

* Update fixture data

* add onboarding fixture

* use onboarding fixture

* reuse import account vault

* remove unnecessary use of class

* use fixture builder in new tests

* switch to function

* update default fixture

* update default fixture

* update test

* update 1559 test fixttures

* update 1559 test fixtures

* update 1559 test fixtures

* dismiss 3box whats new

* remove redundant code

* move docs

* remove unused code

* token detection

* use default timeout

* remove redundant code

* Update fixture builder

hide `Protect your funds` dialog
remove browser environment
remove default network details
hide dismiss seed backup reminder
recursively merges fixture data

* add token to tokencontroller

* remove network details

* add missing identities to preference controller

* remove duplicate properties

* update bip-32 to use fixturebuilder

* alphabetise snap permissions

* update get snaps to use fixturebuilder

* Update test-snap-bip-32.spec.js

wait for window

* add popular network state

* update test

* lint
2022-10-28 09:42:12 +01:00
Frederik Bolding
012e9fab9d
Improve transaction confirmation page performance (#16205)
* Reduce the amount of calls to insight snaps

* Add dep

* Update LavaMoat policies

* Fix selectors and revert changes to hook

* Remove dep

* Revert "Update LavaMoat policies"

This reverts commit 7469c94e0e7c52eb877766a96005cc559c9d8d20.
2022-10-28 10:37:33 +02:00
seaona
d452613f71
[MV3] Fix e2e encrypt-decrypt test for MV3 test build (#16264)
* Fix e2e encrypt-decrypt test for mv3 build

* Remove unnecessary await~
2022-10-27 14:46:07 +02:00
seaona
f03b3a872c
Fix e2e incremental-secuirty test for mv3 build (#16265) 2022-10-27 14:16:50 +02:00
ryanml
6c84e9604c
Enable "Add Popular Network" feature by default for all users (#16172)
* Enable "Add Popular Network" feature by default

* Fixing e2e tests

* Attempt to fix e2e tests

* Revert "Attempt to fix e2e tests"

This reverts commit d88e8944b8df8f7c3075753f8d8b3480439f8e30.

* Get e2e tests passing

Co-authored-by: Dan J Miller <danjm.com@gmail.com>
2022-10-27 07:55:30 -02:30
seaona
c519d3ef91
[e2e] Fix Dapp interactions flaky test on chrome (#16282) 2022-10-26 18:19:15 +04:00
Guillaume Roux
cf265ed7ef
[FLASK] Allow snaps insights to show on regular EOA transactions (#16093) 2022-10-26 11:09:32 +02:00
George Marshall
29a33b4692
TextFieldBase updates after design reveiw (#16201)
* Setting truncate to true by default

* Updating readOnly to not have a focus state

* Updating focus state to be browser outline default

* Removing default args so storybook doesn't become out of sync with default props

* Updating outline CSS
2022-10-25 15:23:48 -07:00
George Marshall
da4e6d3e37
Adding TextField component (#16105)
* Adding TextField component

* Fixing lint issues

* More linting fixes

* Adding more tests

* Adding reference to TextFieldBase props

* Adding reminder todo comment to styles

* Using short hand syntax for conditionally firing event props and removing some css and unused classsNames in favor of box props

* Fixing up my sloppy code

* Removing text base docs update

* More clean up

* Adding more stories and docs

* Adding new stories to mdx docs
2022-10-25 15:23:18 -07:00
ryanml
c88efadf1e
Remove ETH badge from NetworkAccountBalanceHeader when on non-ETH net… (#16102)
* Remove ETH badge from NetworkAccountBalanceHeader when on non-ETH networks

* Network specific icons, or fallback, in the network-account-balance-header

* Update snapshots

* Code cleanup

Co-authored-by: Dan Miller <danjm.com@gmail.com>
2022-10-25 17:03:45 +02:00
Jyoti Puri
68642ee47a
Updating controller dependency (#16033)
* Updating controller dependency

* fix

* fix

* fix

* fix

* fixes

* Lavamoat auto

* Update URLs for phishing detection testcase

* update lavamoat files

* call phishingController.test synchronously again

* bump @metamask/controllers to v32.0.1

* lint

* update policy files

* bump controllers version again

* modify update phishing list strategy

* revert back to use isOutOfDate, but without blocking substream

* possible way to fix e2e tests?

* enable testing

* Remove promise return from setupController in background.js, as it is no longer used

* Ensure updatePhishingLists is called in MM contrller constructer, so that phishing lists are updated right away

Co-authored-by: seaona <mariona@gmx.es>
Co-authored-by: Alex <adonesky@gmail.com>
Co-authored-by: Dan Miller <danjm.com@gmail.com>
2022-10-25 02:24:02 -02:30
Dan J Miller
1526b14157
Fix inputs that should allow decimals (#16254)
* Fix inputs that should allow decimals

* Update e2e test to cover inputting of decimals in advanced fields

* Update e2e test to cover inputting of decimals in advanced fields

* Fix e2e tests
2022-10-25 00:25:31 -02:30
Peter Yinusa
65e3047a74
Chromedriver v106 (#16213)
* update chromedriver

* update chrome binary in ci
2022-10-24 14:36:08 +01:00
Frederik Bolding
863cda6c88
[FLASK] Clear snap state on restore (#16228)
* Clear snap state on restore

* Fix lint
2022-10-24 14:08:08 +02:00
Frederik Bolding
359f782e7e
[FLASK] Fix flaky BIP-32 E2E test (#16255) 2022-10-24 13:49:41 +02:00
Thomas Huang
8075a39567
Continue converting tests from enzyme to @testing-library/react (#16175)
* Add transaction activity log component

* Remove duplicate tx activity log snapshot.

* Convert tx breakdown row to tlr.

* Convert tx status component to tlr.

* Convert User Preferenced Currency Display test to tlr.

* Consolidate and convert user-preferenced-currency-input.test.js to tlr.

* Consolidate and convert user-preferenced-token-input test to tlr.
2022-10-20 11:20:49 -07:00
Garrett Bear
4581a3ac77
Fix/16207/text component storybook (#16214) 2022-10-19 13:09:38 -05:00
Michele Esposito
c00749dcf7
ci: fix stats-module-load-init step (#16196) 2022-10-18 17:47:13 -05:00
Dan J Miller
8b2e137683
Ensure that portfolio tooltip does not show if new custom network popup is shown (#16090)
Co-authored-by: Jyoti Puri <jyotipuri@gmail.com>
2022-10-14 16:46:37 +02:00
Dan J Miller
928e9b96e2
Sort add network list alphabetically (#16089)
Co-authored-by: ryanml <ryanlanese@gmail.com>
2022-10-14 16:17:14 +02:00
Frederik Bolding
6ba9f65b4c
[FLASK] Add E2E for wallet_getSnaps (#16169)
* Add E2E for wallet_getSnaps

* Fix lint
2022-10-14 15:34:27 +02:00
Bowen Sanders
1b4f1344b1
[FLASK] Create E2E Test for BIP-32 test-snap (#16037)
* new test and changed ui

* added bip32 test

* fixed linting and other errors

* changed description

* Bump test-snaps to latest and fix tests

* Fix error e2e

* Fix confirm e2e

* Remove balance

Co-authored-by: Frederik Bolding <frederik.bolding@gmail.com>
2022-10-14 14:33:36 +02:00
Garrett Bear
91df7122f2
Feat/15089/add button link (#16115)
* 15089: add button link component
2022-10-13 15:39:22 -07:00
Daniel
c09e685bce
Keep imported tokens in the Assets list (#16167)
* Don't add a token if it's already added

* Pass tokens directly

* Add toLowerCase
2022-10-13 14:46:23 -05:00
George Marshall
7eb93ff74b
Update to text-field-base docs (#16170) 2022-10-13 06:32:52 -07:00
Michele Esposito
41e3ab189c
chore: add build stats history json file (#16168) 2022-10-13 11:59:22 +02:00
Nidhi Kumari
9372ce0ec7
added AvatarFavicon component (#16135)
* added AvatarFavicon component

* updated AvatarFavicon Readme

* updated avatar favicon component

* added fallback props to avatar favicon

* updated test for avatar favicon

* updated avatar favicon component

* updated typo
2022-10-12 16:22:21 -07:00
Garrett Bear
47f7096d35
16083: Fix deposit eth popover layout (#16100)
* 16083: Fix deposit eth popover layout

* adding responsive padding updates

* classname fix

* Add custom classname option
2022-10-12 16:07:28 -07:00
Nidhi Kumari
0fe3633e4d
Added AvatarBadge component (#15676)
* avatar badge component added

* resolved conflicts

* added badge prop

* updated avatar badge children/badge props

* updated badge token size to be 16px

* added AvatarBadge Test component

* added avatar badge test

* updated avatarBadge props

* added Readme and test files to AvatarWithBadge Component

* resolved conflicts

* removed unused change

* updated badge and badge props

* updated avatar badge stories

* updated constants for avatar badge

* updated avatar badge test

* replaced avatar-badge with avatar-with-badge

* updated avatar badge tests

* updated test for badgeProps
2022-10-12 23:49:12 +05:30
Nidhi Kumari
6781171d06
Added Tag Component (#15947)
* updated tag component and stashed storyshot update

* updated styling for tags

* updated test component for tag

* updated tag styles as per figma

* updated borderRadius prop for tag

* removed unused import

* updated Tag component with labelProps

* updated README

* updated Typography with Tag
2022-10-12 23:05:51 +05:30
Thomas Huang
7149da8d3d
Continue converting tests from enzyme to @testing-library/react (#16032) 2022-10-11 12:54:50 -05:00
Elliot Winkler
33522a7b46
Fix @keystonehq/bc-ur-registry patch (#16155)
We use the `@keystonehq/bc-ur-registry` package for integration with
Keystone devices. This package is peculiar as it not only ships with
JavaScript files but also original TypeScript files. When we started
adding support for TypeScript into the build system, we realized that
the TypeScript files were apparently developed using a different
TypeScript config than we use and therefore resulted in errors in our
build process. So we added a patch which removed these TypeScript files
so that we would fall back to using the compiled JavaScript files. This
removed type information but fixed our build system.

Since then, we've bumped this package and the files we removed have
changed, so the patch is no longer valid. This commit recreates the
patch so that we no longer get warnings from `patch-package`.
2022-10-11 11:27:29 -06:00
Frederik Bolding
d640c9a924
[FLASK] snaps-monorepo@0.22.2 (#16161)
* snaps-monorepo@0.22.2

* Update LavaMoat policies

* Fix eth_accounts permission for Snaps

* Update iframe execution environment

* Dedupe yarn.lock and rerun LavaMoat policy gen

* Add policy override for nanoid
2022-10-11 18:56:34 +02:00
ryanml
385e929864
Fixing forgot password action after wallet creation (#16156) 2022-10-11 08:05:03 -07:00
Jyoti Puri
6995174cbc
MV3 Segment Fix (#16020) 2022-10-11 20:34:32 +05:30
ryanml
d4de8eae9e
Show fiat conversion by default on custom networks (#16132) 2022-10-11 07:56:15 -07:00
ryanml
3a5616e807
Remove docs.google.com from blocked domains list (#16154) 2022-10-11 07:56:03 -07:00
Niranjana Binoy
d4c39006a2
Data from TokenListController gets cleared when the service worker restarts (#16109) 2022-10-11 10:21:31 -04:00
Jyoti Puri
b34d24937d
Update provider (#16131) 2022-10-11 14:18:55 +05:30
Alex Donesky
20986e17b7
Persist state in metaRPCHandler so that we are sure state is persisted before sending back response to actions (#15978)
* persist state in metaRPCHandler so that we are sure state is persisted before sending back response to actions
2022-10-10 17:10:44 -05:00
seaona
321e5abab5
e2e test for gas API fallback (#16137) 2022-10-10 14:59:58 -07:00
Garrett Bear
9125ecf0d6
add box height and width responsive sizes (#16111)
* add box height and width responsive sizes

* add Object.values() to valid sizes
2022-10-10 10:59:06 -07:00
Mark Stacey
f6f8edfd15
Update eth-json-rpc-middleware to v9.0.1 (#16096)
This update includes fixes for our `block-ref` and `retry-on-empty`
middleware.

The `block-ref` middleware resolves the block reference `latest` to a
specific block number, the latest one we are aware of. This is meant to
protect against situations where the network gives inconsistent answers
for what the latest block number is due to some nodes being out-of-sync
with each other (this was a frequent problem years ago with Infura).

It was broken in that the `latest` resolution was failing, and we were
submitting an additional redundant request to Infura for each request.

The `retry-on-empty` middleware is meant to retry certain methods
when they return an empty response. This was also meant to deal with
network synchronization issues that were more common years ago. This
middleware works by making a "child" request over and over until either
a retry limit is reached, or a non-empty response is received.

It was broken in that the final response recieved was thrown away, so
it's as though the middleware was not used. Except that it did result
in additional redundant network requests.

As a result of this update we should see that the extension is more
resilient to certain network synchronization issues. But this is
difficult to test, and these issues may not happen in production
anymore today.

We should see a reduction in requests to Infura as well. This should
be easier to test.
2022-10-10 13:16:58 -02:30
seaona
1b3dc0db54
[MV3] Add e2e chrome test job for MV3 build (#15991)
* Add filter tag

* Fix tag

* test tag

* fix

* Changed tag

* Add test-e2e-chrome

* Filter by branch instead of tag

* Move tests to correct mv3 folder

* Remove ignore from e2e regular chrome job

* Remove filter, so it's run on all PRs

* Handling red X for MV3 e2e failures

Co-authored-by: Mark Stacey <markjstacey@gmail.com>

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2022-10-10 14:33:13 +02:00
PeterYinusa
dc775b598e
add decrypt e2e (#16122) 2022-10-10 12:43:18 +01:00