1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-10-22 19:26:13 +02:00
Commit Graph

913 Commits

Author SHA1 Message Date
Vinicius Stevam
e07ec9dcf3
identify desktop is paired in the metrics event (#17892) 2023-03-02 14:55:27 -06:00
ryanml
6b15d0bae7
Fix incorrect balance in signature request header (#17829)
* Fix incorrect balance in signature request header

* Fix unit tests

* Fix tests and increase unit test coverage

* actually fix unit tests

---------

Co-authored-by: Dan Miller <danjm.com@gmail.com>
2023-03-02 05:40:07 -07:00
Alaa Hadad
5998ae21aa
Buy crypto by redirecting to onramp experience on pdapp instead of deposit popover (#17689)
* feat: disable deposit popover and replace it with global redirect to onramp on pdapp

* feat: remove legacy code for hardcoded onramp providers

* fix: remove unused visuals and components related to legacy code of deposit popover

* fix: remove unused messages

* feat: use a custom hook for all onramps related methods and variables

* fix: modify the custom hook implementation to include test networks

* fix: remove deprecated file buy-url

* fix: remove references for deleted deposit logos

* fix: network-controller failing unit test

* fix: snapshot loading-swaps-quotes-stories-metadata.test.js.snap

* fix: storybook tests

* fix: remove unused constatns related to buyable onramp chains

* fix: remove unused variables and fix eslint

* adding unit test for useRamps custom hook

* feat: add comment on the proper usage of useRamps within confirm-page-container component

* fix: add unit tests for buy button in token-overview page

* fix: add unit test for open the buy crypto URL for a buyable chain ID in token page

* feat: add unit test coverage for eth-overview page

* fix: update locales
2023-03-01 12:45:27 +04:00
David Walsh
eb380f92ef
UX: Icon: Remove unwanted aria label (#17903) 2023-02-27 10:43:06 -06:00
David Walsh
5561987fed
UX: Icon: Stop using fa-times (#17811) 2023-02-27 10:42:02 -06:00
Frederik Bolding
64bfe6f307
Fix a bug where non-address types would be rendered as addresses in EIP-712 (#17846)
* Fix EIP-712 rendering logic

* Fix tests

* Fix tests and story

* Fix lint

* Fix import

* Fix stories
2023-02-27 17:32:51 +01:00
Filip Sekulic
932282e638
What's new - OpenSea security provider (#16831) 2023-02-27 10:20:22 -06:00
David Walsh
e20c70efd5
UX: Update Settings Icon (#17561)
* UX: Update Settings Icon

* Remove font-awesome usage

* Remove from files to convert

* Fix lint
2023-02-26 20:42:03 -06:00
Niranjana Binoy
bc19856d5d
Transaction-list-item-details pop up to display the correct token information on token approve item (#17422) 2023-02-24 14:21:55 -05:00
Nidhi Kumari
9f17e2f94b
UX Icon: updated fa-exclamation-circle (#17879) 2023-02-24 12:52:11 -06:00
David Walsh
e3380ba3ae
UX: Icon: Remove fa-exclamation-triangle usages (#17691)
* UX: Icon: WIP: Remove fa-exclamation-triangle usages

* Swap the rest of the icons

* Fix color import

* Update ui/pages/onboarding-flow/secure-your-wallet/skip-srp-backup-popover.stories.js

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>

* Update ui/pages/onboarding-flow/secure-your-wallet/skip-srp-backup-popover.stories.js

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>

* Update ui/pages/onboarding-flow/secure-your-wallet/skip-srp-backup-popover.stories.js

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>

* Update ui/pages/onboarding-flow/secure-your-wallet/skip-srp-backup-popover.js

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>

* Update ui/components/app/add-network/add-network.js

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>

* Update ui/components/ui/review-spending-cap/review-spending-cap.js

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>

* Fix lint

* Fix alignment and sizes

* Use IconColor

* Update ui/components/app/custom-spending-cap/custom-spending-cap-tooltip.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/components/app/confirmation-warning-modal/confirmation-warning-modal.js

Co-authored-by: Danica Shen <zhaodanica@gmail.com>

* Update ui/components/app/signature-request-original/signature-request-original-warning/signature-request-original-warning.js

Co-authored-by: Danica Shen <zhaodanica@gmail.com>

* Update ui/components/ui/review-spending-cap/review-spending-cap.js

Co-authored-by: Danica Shen <zhaodanica@gmail.com>

* Update ui/pages/onboarding-flow/secure-your-wallet/skip-srp-backup-popover.js

Co-authored-by: Danica Shen <zhaodanica@gmail.com>

* Fix imports

* Use IconColor

---------

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>
Co-authored-by: George Marshall <george.marshall@consensys.net>
Co-authored-by: Danica Shen <zhaodanica@gmail.com>
2023-02-23 15:20:07 -06:00
David Walsh
09a170bfe2
UX: Icons: Remove icon-import (#17816)
* UX: Icons: Remove icon-import

* Add new icon
2023-02-23 15:19:23 -06:00
David Walsh
6cc46454c2
UX: Remove legacy metametrics modal (#17817)
* UX: Remove legacy metametrics modal

* Remove old localizations

* Remove dead image
2023-02-23 13:58:09 -06:00
João Tavares
bde74756d3
Add extension desktop UI (#17748)
* feat: add desktop enable button component

This component will be added
to the experimental page. Users
will then be able to initialize
a desktop connection

* feat: add desktop pairing page

* feat: add desktop deep-linking shared lib

* test: add initial entries to render helper

Allow specifying initialEntries for
MemoryRouter. This change will allow
testing pages that use the useParam
hook.

* feat: add desktop error page

Error page for any desktop pairing
related issue

* feat: add desktop routes to route component

* feat: add enable desktop button to experimental tab

* feat: add desktop icon when paired in dev mode

* feat: disable ledger live control when desktop enabled

* feat: register desktop error actions on ui init

* fix: add missing code fencing

* chore: remove enable desktop rpc middleware

Now that we are adding the UI
there's no need for this rpc middleware
(as it was used to test desktop background
code)

* fix: display experimental tab for desktop
2023-02-23 16:39:48 +00:00
Vladimir Saric
4c598b330e
Display the address icon for the contract requesting spending cap instead of the dapp/url icon (#17858) 2023-02-23 15:54:04 +01:00
David Walsh
09c60e2038
UX: Icons: Remove IconCheck and fa-check (#17787)
* UX: Icons: Remove IconCheck and fa-check

* update jest snapshots

* Update story

* Remove dead CSS

* Update ui/components/app/account-menu/account-menu.component.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/components/app/dropdowns/network-dropdown.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/components/app/modals/metametrics-opt-in-modal/metametrics-opt-in-modal.component.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/pages/settings/networks-tab/networks-list-item/networks-list-item.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/pages/settings/networks-tab/networks-list-item/networks-list-item.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/pages/permissions-connect/redirect/permissions-redirect.component.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/pages/send/send-content/add-recipient/domain-input.component.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/pages/onboarding-flow/metametrics/metametrics.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/components/app/modals/transaction-confirmed/transaction-confirmed.component.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Update ui/components/app/modals/metametrics-opt-in-modal/metametrics-opt-in-modal.component.js

Co-authored-by: George Marshall <george.marshall@consensys.net>

* Fix jest snapshots

* Update sizes of network andd account menu checks

* Fix ICON_SIZES in account menu

* Improvements

* Use IconColor

* Use IconColor

* Lint

* Update snapshots

---------

Co-authored-by: George Marshall <george.marshall@consensys.net>
2023-02-23 07:19:28 -06:00
Filip Sekulic
2acd51af2e
Open sea security provider warning message (#17662)
* Warning message for the OpenSea security provider

* Updated snapshots

* Removed flask usage

* Covered more test cases

* Code refactor

* Fixed errors

* Code refactor

* Fixed few issues

* Covered more code with tests
2023-02-23 08:38:09 -03:00
Nidhi Kumari
3437d7161f
UX Icon: updated fas-question icon (#17828)
* updated fas-question icon

* removed as property from Box

* fallback prop for heading
2023-02-22 16:45:07 -06:00
George Marshall
72af5626de
Updating Icon html element to span (#17790) 2023-02-22 14:42:50 -08:00
David Walsh
eba4275467
Fix #17825 - Prevent timing conflict with NFT toast messages (#17861) 2023-02-22 11:14:47 -06:00
David Walsh
1b382e9f2d
Remove CancelTransaction modal (#17819)
* Remove CancelTransaction modal

* Remove old locales

* Remove dead test
2023-02-21 11:19:37 -06:00
David Walsh
1f9b5a2293
UX: Icons: Stop using FA in TransactionActivityLog (#17667) 2023-02-21 09:49:31 -06:00
David Walsh
2cfd0f9bbd
Ux: Icon: Improve alignment of asset list chevron (#17791)
* Ux: Icon: Improve alignment of asset list chevron

* Update jest snapshot
2023-02-21 09:49:16 -06:00
David Walsh
24e0a9030b
UX: Move Portfolio link to its own button (#17722) 2023-02-21 09:32:08 -06:00
David Walsh
3fa167e673
UX: Icons: Fix alignment of settings icons in full screen (#17783) 2023-02-17 09:17:34 -06:00
George Marshall
30bc9a923e
Part of 17670: Replace Typography with Text approve-content-card (#17753)
* Updating Typography to Text approve-content-card

* Adding h6 tags

* Update ui/components/app/approve-content-card/approve-content-card.js

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>

---------

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>
2023-02-16 18:33:35 -08:00
Nidhi Kumari
33cc8d587a
NFT: Replaced all the instances of collectibles with NFTs (#17741)
* replaced all the instances of collectibles with nfts

* updated actions

* updated e2e seeder

* updated confirm Approve test

* updated test dapp change

* updated test dapp change

* nit fix

* nit fix

* updated casing and snapshots

* updated casinG

* added migrations

* updated ,igration

* updated 078.test

* updated tests for 078 migration

* updated migration

* updated 078 index.js
2023-02-17 00:53:29 +05:30
David Walsh
74ef8e4fa4
UX: Icon: Remove Plus icon (#17666) 2023-02-16 07:26:26 -06:00
David Walsh
4dcb639652
UX: Icons: Remove usage of chevron fa- icons (#17668) 2023-02-16 07:26:14 -06:00
David Walsh
8c233b2a82
UX: Icons: Stop using fa-address-book (#17761)
* UX: Icons: Stop using fa-address-book

* Remove locale string

* Fix positioning
2023-02-16 07:26:00 -06:00
Monte Lai
cdc1bce688
SRP hold to reveal (#17232)
* refactor class to functional component

* update messages

* fix: use classnames

* feat: add hold to reveal modal

* feat: add new zendesk url for secret recovery phrase and noncustodial wallet

* update: clipboard to clear copied text after delay

* fix: remove save to csv

* feat: update styles for reveal seed page

* fix: update reveal seed snapshot

* add test to check for modal

* fix: lint

* fix: unused messages locale

* fix: use new banner component

* fix: use new button from design system

* fix: update snapshot

* fix: lint

* revert text

* fix: lint

* fix: remove --copy-only

* fix: marginBottom prop value

* fix: iconName and prop error

* --made the QR code slightly smaller so it's less likely to have a scrollbar
--updated the snapshots

* fix: error message not displaying

* SRP hold to reveal using more DS components (#17583)

* Updating to add DS components and remove CSS

* Fixing rendered html and removing some unneeded props

* fix: set block to true

---------

Co-authored-by: Monte <monte.lai@consensys.net>

* fix: add descriptions to messages

* Update ui/components/ui/export-text-container/export-text-container.component.js

fix: lint

Co-authored-by: HowardBraham <HowardBraham@users.noreply.github.com>

* fix: remove using displayWarning in requestRevealSeedWords

* fix: update test to remove displayError

* fix: update design system enums

* fix: messages descriptions

* fix: banner to banneralert

* fix: update preview

* add additional tests

* fix: use jest instead of sinon

* add test if long press isn't completed

* add test if password is wrong

---------

Co-authored-by: Howard Braham <howrad@gmail.com>
Co-authored-by: George Marshall <george.marshall@consensys.net>
2023-02-15 10:07:33 -08:00
David Walsh
9e9f9126cc
UX: Icons: Use proper send icon on wallet and token overview pages (#17720) 2023-02-15 10:26:21 -06:00
David Walsh
fca2a3f97f
UX: Update three-dot icon for settings (#17558) 2023-02-15 08:39:46 -06:00
David Walsh
7774ee6e2f
UX: Replace all fa-bell instances with Notification icon (#17524)
* UX: Replace all fa-bell instances with Notification icon

* Fix flask comment fencing

* Fix import error
2023-02-10 19:33:11 -06:00
David Walsh
c61576e33c
UX: Icons: Remove legacy connect icon (#17673) 2023-02-10 19:32:52 -06:00
amerkadicE
1ecf241a9f
Rename reset account settings (#17457)
* Rename reset account settings

Fix snapshot

Update snapshots

Fix e2e tests

Fix e2e tests

* Rename reset-account e2e test to clear-activity e2e test
2023-02-10 22:50:12 +01:00
David Walsh
50937dcfde
NFTs: Hide detail when no thumbnail available (#17693) 2023-02-10 08:05:51 -06:00
David Walsh
10be6fcfeb
UX: Update block explorer icon (#17562)
* UX: Update block explorer icon

* Removing unneeded CSS and some HTML bloat

* Removing unneeded className

* Removing unneeded CSS and reducing HTML bloat for ContractTokenValues

---------

Co-authored-by: georgewrmarshall <george.marshall@consensys.net>
2023-02-09 10:21:51 -06:00
Jyoti Puri
61a7850afc
Sanitising string on signature request pages (#17571) 2023-02-09 04:35:52 +05:30
Nidhi Kumari
3be1fc6d0c
converted collectibles files to nfts (#17658)
* converted collectibles files to nfts

* updated relative import for scss

* updated scss for pages
2023-02-08 20:04:56 +05:30
Maarten Zuidhoorn
ff85b040cb
Sort permissions based on weight (#17660) 2023-02-08 15:28:48 +01:00
Ariella Vu
b5c1de900d
Refactor ConfirmTransaction to Functional Component (#17473)
* ConfirmTransaction: rm unused metricEvent context

* ConfirmTransaction: rm unused mapToProps props:
- unapprovedTxs
- id

* ConfirmTransaction: convert to FC

* ConfirmTransaction: use const ORIGIN_METAMASK

* ConfirmTransaction: rm mapStateToProps

* ConfirmTransaction: mv confirm-transaction ducks

* ConfirmTransaction: mv getContractMethodData duck

* ConfirmTransaction: rm container file

* ConfirmTransaction: use ORIGIN_METAMASK const

* ConfirmationTransaction: add tests

* ConfirmTransaction: update jest mock after merge

* tests: update snapshot after mock-state updates
2023-02-08 18:00:25 +07:00
Thomas Huang
14efbf1eea
Collectible Unit Tests (#17632)
* Add ipfs gateway and collectible state to mock-state.json

* Add collectible-default-image test with snapshot and testids

* Add Collectible Details test, snapshot, and test-ids

* Add Collectible Options tests and test-ids

* Add Collectible Items test and test-ids.

* Add more tests to Add Collectible component

* Update Security Tab snapshot with ipfs gateway state value

* Add data-testid to Menu component for menu background

* Lint

* Bump coverage targets

* Remove commented import

---------

Co-authored-by: David Walsh <davidwalsh83@gmail.com>
2023-02-07 12:06:37 -06:00
David Walsh
02d608d20c
UX: Fix token image not displaying in asset listing (#17575) 2023-02-06 08:31:19 -06:00
Maarten Zuidhoorn
8cda817f5c
Add hardcoded list of human-readable snap names (#17595)
* Add hardcoded list of human-readable snap names

* Make the text properly bold

* Small style fixes to approval screen

* Run yarn lint:fix

* Update snapshots
2023-02-06 11:05:57 +01:00
David Walsh
678ad6397b
Change COLORS reference to Color (#17599)
* Change COLORS reference to Color

* Fix lint
2023-02-03 17:47:45 -06:00
David Walsh
330cba61de
UX: Remove the IconCopy and IconCopied Components and their usages (#17530) 2023-02-03 16:06:14 -06:00
David Walsh
710b1a3fbf
UX: Update support icon (#17560) 2023-02-03 16:05:51 -06:00
Brad Decker
31897b542d
Convert actions.js to typescript (#17446) 2023-02-03 11:56:44 -06:00
Niranjana Binoy
769efc9fe3
Disable fiat conversion in Approve Screen when Show balance and token price checker is OFF (#17443) 2023-02-03 12:13:19 -05:00
Nidhi Kumari
41d3dcc8a3
updated tag icon (#17540) 2023-02-02 17:13:49 -08:00
Brad Decker
02b2d7fa42
Dead and redundant code removal (#17512) 2023-02-02 16:00:05 -06:00
Danica Shen
794f3039f1
feature: migrate design-system.ts (#17518) 2023-02-02 20:15:26 +00:00
Nidhi Kumari
b123458a26
updated CollectibleDetail Storybook Coverage (#17351)
* updated CollectibleDetail Storybook Coverage

* updated tooltip for collectible details

* updated color of icon

* fixed lint error

* fix lint error
2023-02-02 23:56:36 +05:30
Vladimir Saric
308151cd49
Display a warning and gas fee component for token allowance and NFT flow when transaction is expected to fail (#17437)
Co-authored-by: Pedro Figueiredo <pedro.figueiredo@consensys.net>
Co-authored-by: Dan J Miller <danjm.com@gmail.com>
Co-authored-by: Brad Decker <bhdecker84@gmail.com>
2023-02-01 17:14:09 -06:00
Brad Decker
0885c6cd1f
prefer locale slice for locale state (#17499) 2023-02-01 11:53:35 -06:00
David Walsh
03d8ee5eae
Onboarding V2: Remove old onboarding flow (#17081) 2023-02-01 09:28:09 -06:00
Jyoti Puri
8fd65a698e
Fix build (#17538) 2023-02-01 19:07:15 +05:30
Jyoti Puri
26222a9b27
Refactoring confirm-transaction-base component (#17484) 2023-02-01 11:24:41 +05:30
ryanml
5e863a297f
Adjust 'Confirm' button color on setApprovalForAll revocations (#17506) 2023-01-31 18:22:33 -07:00
David Walsh
145cf1ec01
UX - Update all copy icons (#17445) 2023-01-31 11:00:26 -06:00
Vladimir Saric
8aa3263b82
Added navigation between multiple sign prompts and reject all sign prompts (#17093)
* Fixed navigation through multiple unapproved transactions for ERC20 tokens

* Fixed tx details activity-log currency

* Fixed e2e test failure

* Added navigation between multiple sign prompts and reject all sign prompts

* Resolving conflicts

* Creating SignatureRequestNavigation component and extracting the UI rendering part into a single component

* Fixing e2e tests and updating snapshot

* Using single component for navigation which shows both messages and transactions requests

* Fixing test-unit-jest-main

* Added more unit tests

* Fixing test-storybook

* Fixing test-storybook

---------

Co-authored-by: Filip Sekulic <filip.sekulic@consensys.net>
2023-01-31 16:29:23 +01:00
David Walsh
18a1beb3dd
Update overview icons for buy, send, and swap (#17492) 2023-01-31 08:47:43 -06:00
David Walsh
edb2c9ea00
Fix #17441 - Update all MenuItem instances to use new icons (#17468) 2023-01-31 08:47:00 -06:00
David Walsh
ff843c1b10
Fix #17393 - Fix NFT collection header image (#17394) 2023-01-31 08:46:40 -06:00
Danica Shen
c23bd4925b
feature: convert level 32 files to typescript (#17390) 2023-01-27 18:28:03 +00:00
Dan J Miller
7a77c82514
Use network provider state, instead of CurrencyRateController state, to select 'nativeCurrency' (#17450)
* Use network provider state, instead of CurrencyRateController state, select 'nativeCurrency'

* Fix unit tests

* Lint fix

* Only use the network provider ticket for the native currency when useCurrencyRateCheck is false

* Fix unit test

* Fix tests for real
2023-01-27 13:47:47 -03:30
David Walsh
6ee2d07706
Fix #17362 - Ensure NFT icons are correct (#17440)
* Fix #17362 - Ensure NFT icons are correct

* Update trash icon
2023-01-27 08:32:03 -06:00
amerkadicE
ab329e5186
Refactor confirm page container component from class to functional component (#16907) 2023-01-26 11:07:17 -06:00
David Walsh
29d4799f46
Fix #17388 - Remove dismiss button from NFT notification (#17389) 2023-01-25 13:28:15 -06:00
Garrett Bear
23133a2735
fix icon names (#17391) 2023-01-25 23:41:13 +05:30
Alex Donesky
3d87f65d9b
Fix broken NFT import and auto-detect flows (#17384)
* Fix broken NFT import and auto-detect flows
2023-01-25 10:33:06 -06:00
Brad Decker
073718d965
Convert ui/helpers/constants/common to typescript (#17348) 2023-01-25 09:47:02 -06:00
Niranjana Binoy
129a06cc12
Copy update on Transaction breakdown for ApproveToken (#17296) 2023-01-25 10:15:58 -05:00
ryanml
47f6d46bb3
Add alt text for NFT images (#17284) 2023-01-25 08:08:35 -06:00
Nidhi Kumari
8a6bf4d1c9
Nit fixes for story-test integration (#17344)
* nit fix for story-test integration

* updated package.jsson
2023-01-25 09:24:13 +05:30
Garrett Bear
0bf6aeb5f5
icon audit, remove xxs icon size (#17089)
* icon audit, remove xxs icon size

* update icon file names and snapshots

* remove unused icon- code and fix icons with slash issue

* close icon fix

* remove icons id

* update snapshot

* font awesome icon list

* remove font awesome

* fix linting issue
2023-01-24 09:39:46 -08:00
amerkadicE
dd09245ff6
Fix/use etherjs specific imports (#15461)
* replace ethers with submodules

Co-authored-by: Alex <adonesky@gmail.com>
2023-01-24 08:10:36 -06:00
David Walsh
cf10b2a1a0
Fix #17300, #16843 - Use proper source for image of IPFS NFTs (#17302) 2023-01-23 16:04:11 -06:00
Brad Decker
b4c5837760
Remove usages of Conversion util in components folder in favor of Numeric (#17333)
Co-authored-by: Danica Shen <zhaodanica@gmail.com>
2023-01-23 13:30:43 -06:00
Frederik Bolding
ef69e2ae48
[FLASK] Update onboarding text to fit new panel (#17345)
* Update Flask onboarding text to fit new panel

* Fix lint
2023-01-23 18:43:35 +01:00
Nidhi Kumari
213240349d
Updated Icons in Title of NFTs (#17205)
* icon update for nft

* updated icon for previously owned icon

* removed isPreviouslyOwned condition
2023-01-23 22:38:35 +05:30
Vladimir Saric
f988dc1c5e
Enable the Token Allowance flow by default for all users (#16740) 2023-01-23 21:49:55 +05:30
Brad Decker
af83e120dc
Convert app//scripts/lib/util.js to typescript (#17330) 2023-01-23 10:18:22 -06:00
aleksandar-mihajlovic
16851c83ef
Added fix for overlaping text in mozzila in activity tab (#17235) 2023-01-23 09:48:14 -06:00
Jyoti Puri
3e523e2382
Use PageContainerFooter to render footer on all confirmation pages (#17316) 2023-01-23 20:52:12 +05:30
Nidhi Kumari
180eabea06
Added toaster for removed NFTs (#17297)
* added notification for remove nfts

* reverted names for tabs

* updated default key

* updated snapshot

* updated remove nft toast to danger
2023-01-23 17:23:44 +05:30
Nidhi Kumari
c5368c152b
Added storybook check to CI (#17092)
* added storybook test runner

* added test runner in ci

* updated test for ci and fixed lint error

* updated lavamoat policy

* updated test command

* updated playwright

* changed command to storybook;ci

* updated command

* updated instance for test-storybook

* updated playwright

* added playwright step

* replaced concurrently with start-server-and-test

* updated the static storybook directory

* replaced first with last

* updated lock file

* replaced first with last

* updated test-storybook with maxworkers

* updated .depchechrc

* updated yml

* removed id from banner base

* replaced broken stories with .stories-to-do.js extesnsion

* updated token allowance story

* removed duplicacies from yarn

* fixed lavamoat

* removed filename comment

* updated links for docs

* fixed file extension for stories

* updated path for stories.json

* updated stories.json path

* yarn updated

* updated stories

* updated yarn

* updated wait on
2023-01-21 00:57:46 +05:30
Brad Decker
92f6ea6f6b
Relocate conversion utils to shared/modules/conversion.utils.js (#17319) 2023-01-20 11:04:37 -06:00
ryanml
a19a5d60d3
Convert shared/constants/hardware-wallets.js -> Typescript (#17310) 2023-01-20 09:14:40 -06:00
Ariella Vu
c744f2d0cf
TransactionDecoding: rm unwanted cursor: pointer (#17318) 2023-01-20 21:37:50 +07:00
Ariella Vu
149b5721ad
Fix transaction decoding data types string and bool (#17299)
* TransactionDecoding: support string type
- fixes #16951
- fixes #16952 (string cut off)

* TransactionDecoding: support bool type
2023-01-20 20:31:26 +07:00
Danica Shen
8f915807e4
fix(mme-14830): fix consistent tab when switching languages (#17155) 2023-01-19 15:05:42 +00:00
ryanml
63a3de6768
Various NFT UI fixes (#17153)
* Various NFT UI fixes

* Addressing review feedback

* Using ButtonIcon component for copy icon

* Using button for collectible item
2023-01-18 15:39:15 -07:00
Thomas Huang
d99854baac
Convert signature request component to tlr. (#17268) 2023-01-18 11:34:28 -08:00
Brad Decker
5f6d2ba6b0
Convert Transaction constants to typescript (#17149) 2023-01-18 08:47:29 -06:00
David Walsh
37174d749c
Fix #17162 - Add NFT disclaimer to details page (#17266) 2023-01-18 08:37:16 -06:00
Niranjana Binoy
20cbe44d63
Moving transaction-alerts component from /ui/pages/confirm-transaction folder to ui/component/app folder (#17272) 2023-01-18 09:30:26 -05:00
Vladimir Saric
c82c967c46
Fixing error when user input some letter in token allowance flow (#17117)
* Fixing error when user input some letter in token allowance flow

* Rename the regex variable name and added a brief comment above its definition

Co-authored-by: Pedro Figueiredo <pedro.figueiredo@consensys.net>
2023-01-18 10:53:10 +01:00
ryanml
a276208891
Fixing broken stories (#17227) 2023-01-17 18:42:02 -07:00
Thomas Huang
4c3c4eebac
Final conversion of tests from enzyme to @testing-library/react (#16862)
* Add transaction activity log component

* Remove duplicate tx activity log snapshot.

* Convert Advanced Tab to tlr.

* Lint fix

* Change ENS to DNS in mock state data.

* Add test ids for speedup, cancel, rety buttons.

* Convert TransactionListItemDetails component to RTL.

* Convert PageContainerHeader component to RTL.

* Convert TokenInput component to RTL.

* Convert UnitInput component to RTL.

* Convert withModalProps to RTL.

* Convert i18n-helper to RTL.

* Convert ConfirmSeedPhrase component to TLR.

* Convert AddRecipient component to RTL.

* Set process.env metamask build type to 'main' for test

Co-authored-by: Brad Decker <bhdecker84@gmail.com>
Co-authored-by: Pedro Figueiredo <pedro.figueiredo@consensys.net>
2023-01-17 07:51:35 -08:00
Niranjana Binoy
a0bb4a6c5a
Toggle option to enable/disable balance and Token rate checking for using third-party API (#16772) 2023-01-17 10:23:04 -05:00
David Walsh
554939cc66
Fix #17142 - Ensure toggle arrow is visible in dark mode (#17204) 2023-01-17 09:19:26 -06:00
ryanml
c77629f8aa
Removing erroneous blank lines in ui/components (#17225) 2023-01-17 05:52:04 -07:00
Vladimir Saric
3c38ff3899
Validating or restricting the number of digits on token allowance flow (#17234)
* Validating or restricting the number of digits after the decimal point that the user can enter and styles for Max button and description with error message

* Use better solution for validation the number of digits on token allowance flow
2023-01-16 14:11:46 -03:30
ryanml
214afe1992
Remove 'Verify contract details' link on Sig Req screen when 'verifyingContract' is absent (#17128)
* Remove 'Verify contract details' link on Sig Req screen when 'verifyingContract' is not provided

* Adding tests
2023-01-13 12:28:52 -07:00
Filip Sekulic
e70b6dc29e
13/12 (#16948) 2023-01-13 20:11:07 +05:30
Victor Naumik
7df712b888
Display primaryType in signTyped instead of 'Message' string (#17077)
* fix: Display primaryType in signTyped instead of 'Message' string

* fix: added #17077 to changelog

* fix: remove unused signatureRequest1 message to fix test-lint failure

* Update CHANGELOG.md

Co-authored-by: Dan J Miller <danjm.com@gmail.com>

* test: add assertion for the primaryType to signature-request component test

Co-authored-by: Brad Decker <bhdecker84@gmail.com>
Co-authored-by: Dan J Miller <danjm.com@gmail.com>
2023-01-12 15:52:02 +01:00
Filip Sekulic
fc83a1b631
Fixed navigation through multiple unapproved transactions for ERC20 tokens (#16822) 2023-01-11 09:01:50 -06:00
George Marshall
b653b4f934
Fixing some incorrect CSS color vars (#17033)
* Fixing some incorrect css vars

* Static hex value fix

Co-authored-by: Brad Decker <bhdecker84@gmail.com>
2023-01-09 11:58:34 -08:00
Alaa Hadad
174d3dbcf0
soft disable onramp provider wyre (#17102) 2023-01-09 13:44:13 -03:30
Adnan Sahovic
fbbc1df853
Display large and small numbers as decimals instead of scientific notation on token allowance confirmation screens (#16676)
Co-authored-by: VSaric <vladimir.saric@consensys.net>
Co-authored-by: Vladimir Saric <92527393+VSaric@users.noreply.github.com>
2023-01-05 08:58:16 -06:00
Vladimir Saric
4d12c36cf8
Align custom spending cap Max button in approve screen for multiple languages (#16927)
* Align custom spending cap Max button in approve screen for multiple languages

* Modify some css styles and adding Box props

* Using ButtonLink component instead of <button/>

Co-authored-by: Brad Decker <bhdecker84@gmail.com>
2023-01-04 22:31:52 +05:30
Vladimir Saric
23653f4c08
Added unit tests and story for SignatureRequestData component (#16759) 2023-01-04 09:31:23 -06:00
Frederik Bolding
05d50eee73
Improve SignatureRequest performance (#17052)
* Improve SignatureRequestData performance

* Memoize more selectors
2022-12-22 16:37:51 -03:30
HowardBraham
b9d9112b97
Prevent account name collisions (#16752)
* dealt with most of the problems in the Create Account dialog

* Fixed "newAccountNumberName" localizations

* In another language, don't allow accounts named, for instance, Cuenta 3

* Editing an account name later now follows the same rules

* Fixing lint errors

* Responding to the review by @adonesky1

* Worked with @montelaidev to alter the RegExp, in order to catch spaces before and after the account name

* Fixed line breaks for eslint
2022-12-22 11:27:31 -06:00
Alex Donesky
1a842aabb6
Replace eth-optimism/contracts package with local snippet of gas price ABI and address (#16891) 2022-12-20 14:05:07 -06:00
amerkadicE
362497ed64
Track when token balance is changed to update value on approval screen (#16964)
* Track when token balance is changed to update value on approval screen

* Code refactor

* Fix unit test

* Fix sign approval balance

* Refactor code
2022-12-20 09:24:28 -03:30
Frederik Bolding
7e7a0f1f72
[FLASK] Use custom UI for transaction insights (#16912)
* Allow custom UI for transaction insights

* Fix margin

* Small fixes to CSS and selectors

* Rename property

* Fix E2E locally

* Bump test-snaps

* Bump test-snaps
2022-12-20 11:44:49 +01:00
Guillaume Roux
85f260c22d
[FLASK] Use custom UI for dialogs (#16973)
* update dialog templates to use custom UI

* add TODO comments

* Fix showDialog hook and destructuring

* Regen LavaMoat policies

* Re-add legacy snap confirmation for now

* Fix circular dependency issue

* Revert change to token-util

* Fix lint

Co-authored-by: Frederik Bolding <frederik.bolding@gmail.com>
2022-12-20 11:44:22 +01:00
Olusegun Akintayo
13de51e748
Security and Privacy Settings Re-org (#16756) 2022-12-19 18:46:36 +01:00
Dan J Miller
074c2934fe
remove warning on revoke approval for all nfts (#16953)
Co-authored-by: EresDev <eresdev@hotmail.com>
2022-12-16 22:37:18 +05:30
Ariella Vu
462e5faab5
Fix token balance precision on confirm token approval page from soon-to-be-deprecated token allowance flow (#16934)
* ConfirmToken: fix token balance onboarding v1
this UI/UX should be deprecated following PR#16740, maybe v10.25

* TokenApproval: use precision for token balance

* EditApproval: calc utilizing existing util
2022-12-16 22:20:05 +07:00
legobeat
1acb1b2e5d
Refactor password validation (#16902)
* ui: add common constant PASSWORD_MIN_LENGTH=8

* ui: simplify password validation logic

* ui: getPasswordStrengthLabel using t from context

Co-authored-by: Alex Donesky <adonesky@gmail.com>
2022-12-15 20:56:27 +00:00
Dan J Miller
0792e4ebbc
Recipient name passed to confirm-page-container component should be u… (#16961)
* Recipient name passed to confirm-page-container component should be used if pet name exists for the to address

* Ensure recipient edit/add popup is shown for non-owned accounts

* Ensure contract name is rendered if it exists for recipient address

* Ensure that shortened address is last fallback after account, addressbook, token and ens names
2022-12-15 13:03:59 -03:30
Frederik Bolding
659063b335
[FLASK] Allow Snaps UI to use Markdown for text formatting (#16911)
* Allow Snaps UI to use Markdown for text formatting

* Fix yarn audit and dedupe errors

* Update LavaMoat policies

* Fix lint

* Add paragraph wrapper component

* Fix lint
2022-12-13 15:37:20 +01:00
Frederik Bolding
c75d2dce55
[FLASK] Implement Snaps UI Renderer (#16605)
* Start implementation of Snaps UI Renderer

* Add snap name and fix some design issues

* Fix lint

* Add some types

* More fixes

* Actually install snaps-ui

* Use JS instead of TS

* Remove unused deps

* Remove dep

* Update LavaMoat policies

* Fix style lint

* Add story

* Small tweaks after rebase

* Remove spacer and add test

* Fix lint

* Remove console.log

* Add error message

* Remove edge-case that doesnt exist anymore

* Update yarn.lock

* Update policy
2022-12-09 13:05:31 +01:00
Bowen Sanders
7e7be2769d
[FLASK] Create E2E test for tx-insights (#16785)
* Created an E2E test for tx-insights.

Co-authored-by: Guillaume Roux <guillaumeroux123@gmail.com>
2022-12-08 12:15:59 -08:00
Jyoti Puri
8125473dc5
Removing flag for EIP1559 V2 support (#16446) 2022-12-09 00:07:06 +05:30
David Walsh
7d3b1d08da
NFTs: Update COLLECTIBLES_V1 to NFTS_V1 (#16851) 2022-12-08 11:37:47 -06:00
David Walsh
43c278d813
Privacy - Show default selected network after a custom network has been added during onboarding (#16789)
* Privacy - Allow users to set a custom RPC from the onboarding process (#16767)

* Privacy - Allow adding custom IPFS from onboarding (#16782)

* Privacy - Show default selected network after a custom network has been added during onboarding

* WIP: Show dropdown list of networks

* Add network switcher to the onboarding advanced privacy screen

* Fix duplicate imports

* Provide default for networks

* Update ui/helpers/utils/ipfs.js

Co-authored-by: legobeat <109787230+legobeat@users.noreply.github.com>

* Fix lint

* Remove unwanted changes

* Fix lint

Co-authored-by: legobeat <109787230+legobeat@users.noreply.github.com>
2022-12-08 10:42:23 -06:00
ryanml
a759d427f0
Remove new address alert (#14811)
* Removing new address alert

* remove unused copy

* fix broken e2e test

* rework layout nesting

* satisfy lint

* change layout to fix firefox tests

* change selector specificity on e2e test

* revert test change after fix has been merged from develop

* fix linting

Co-authored-by: Brad Decker <bhdecker84@gmail.com>
Co-authored-by: Pedro Figueiredo <pedro.figueiredo@consensys.net>
2022-12-08 14:20:24 +00:00
Filip Sekulic
ddcaaf3e8d
Allow transactions with gas price or priority fee 0 (#16651) 2022-12-07 09:10:10 -06:00
amerkadicE
8885c54f13
NFT setApprovalForAll warning popover (#16195)
* NFT setApprovalForAll  warning popover
2022-12-06 14:24:07 -06:00
Vladimir Saric
40cba69128
Removed Confirm and Cancel events as they are not triggered anymore (#16777) 2022-12-03 09:59:55 -06:00
Alex Donesky
f162c58f5a
Allow adding networks with the same chainId as a preloaded/default network via wallet_AddEthereumChain API (#16733)
* allow adding networks with the same chainId as an existing network via API

Co-authored-by: Kurush Dubash <kurush@alchemyapi.io>
2022-12-02 21:14:27 -06:00
Alex Donesky
05ab94fd1c
Add security & privacy "What's New" message (#16783) 2022-12-02 17:59:41 -06:00
amerkadicE
702cab5fa7
Add user guidance on signature request screen (#16600) 2022-12-02 08:12:43 -06:00
Erik Marks
a861cc6dae
[FLASK] Add snap alerts and prompts via snap_dialog RPC method (#16048)
Co-authored-by: Guillaume Roux <guillaumeroux123@gmail.com>
Co-authored-by: Frederik Bolding <frederik.bolding@gmail.com>
2022-12-01 16:46:06 +01:00
Frederik Bolding
025ee2cb48
[FLASK] Expose transaction origin to transaction insight snaps (#16671)
* Expose transaction origin to transaction insight snaps

* Support multiple icons for each label for a permission

* Add transaction insight origin permission

* Fix fencing

* Fix import and permission crash

* Use function properly for connected accounts
2022-12-01 14:38:56 +01:00
amerkadicE
80e4a1fef4
Update signature request screens (#15776)
Fix e2e test

Update siteicon for v4 signature type

Code refactor

Code refactor

Remove origin and address in signatrue request

Update e2e tests

Use getNetworkName function

Move header component inline jsx

Update snaps
2022-11-30 19:11:36 +01:00
amerkadicE
dd0844e200
Add signature request warning modal (#16225)
* Add signature request warning modal

Fix e2e tests

Fix e2e tests

Remove warning message from eth sign request

Remove unused locales

Fix e2e test

Fix e2e test

* Run pipeline

* Fix locales:
?

* Add unit tests
2022-11-30 16:34:50 +01:00
Bowen Sanders
0e1c385cd0
[FLASK] Create E2E test for snap management (#16628)
* added management test

* added id and dismiss alert function

* changed xwindow handling

* fixed linting
2022-11-30 14:12:09 +01:00
amerkadicE
505517e8c7
Fix: multiple reject on the signature request screen (#16199)
Co-authored-by: Brad Decker <bhdecker84@gmail.com>
2022-11-30 08:13:14 +01:00
Maarten Zuidhoorn
c341abaea6
Use Webpack 5 for Storybook (#16678)
* Fix storybook

* Update policies

* Bump all Storybook dependencies to the latest version

* Add Storybook dependencies to depcheck ignore list

* Update policy-override.json

* Fix SectionShape circular dependency

* Change policy override for eslint-scope

* Fix some Webpack build issues

* Add missing dependency

Co-authored-by: Frederik Bolding <frederik.bolding@gmail.com>
2022-11-29 19:23:36 +01:00
dragana8
2680340e27
Unable to proceed with tx bc of inaccurate/overly aggressive "Insufficient funds for gas" warning #13087 (#14634)
Co-authored-by: VSaric <vladimir.saric@consensys.net>
2022-11-28 10:41:42 -06:00
legobeat
0e573e1e24
fix infura rpc detection (#16585) 2022-11-23 21:30:45 +00:00
Frederik Bolding
de955f3faa
[FLASK] snaps-monorepo@0.24.1 (#16525)
* snaps-monorepo@0.24.0

* Fix imports and regen LavaMoat policies

* Bump iframe-execution-environment

* Fix tests

* Add permissions

* Bump patch

* Bump test-snaps

* [FLASK] Fix update e2e test to catch snaps with caveats (#16546)

* changed snap to update to bip32

* small changes to test

* Fix lint

* Fix E2E

* Update copy

* Update icon

Co-authored-by: Bowen Sanders <bowensanders@gmail.com>
2022-11-22 13:07:08 +01:00
Filip Sekulic
c87a4f5968
Replace the address in SignTypedData_v4 signatures with a 'Verify contract details' link (#16191) 2022-11-21 11:19:49 -06:00
David Walsh
3d14e0b3f0
BETA - Update to sentence case (#16590) 2022-11-21 08:44:46 -06:00