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

1085 Commits

Author SHA1 Message Date
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
David Walsh
24551b7e9c
Fix #17138 - Allow ActionMessage to be autohidden after a given number of milliseconds (#17269) 2023-01-20 09:33:36 -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
Michal
32a2411cf5
Remove textarea caret dep (#17105)
remove dependency for mascot head movement
2023-01-16 13:07:59 +00:00
Nidhi Kumari
1df72c6e4e
Added padding/margin inline support to the Box component (#17134)
* added tests and css for more padding/margin support

* updated README

* fixed spacings

* fixed spacings
2023-01-14 10:54:25 +05:30
Garrett Bear
1265731344
Feat/16637/button housekeeping (#16872)
* button housekeeping

* add iconsearch

* fix description

* readme update

* update disabled classnames

* buttonlink disabled class

* add disabled proptypes

* add constant exports

* update disabled style classes

* update snapshot for box pill classname

* add buttonTextProps

* update primarybutton background color to use box props

* update button secondary and link to use box props

* update tests
2023-01-13 13:58:09 -08:00
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
Garrett Bear
01c0d7823d
Feat/15085/banner base component (#16828)
* add banner base component

banner base wip

remove base avatar

banner base

* add banner base

* Update ui/components/component-library/banner-base/banner-base.stories.js

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

* Update ui/components/component-library/banner-base/banner-base.js

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

* named export org fix

* Update ui/components/component-library/banner-base/README.mdx

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

* updated changes to banner base

* banner base updates

* fix description/children

* move banner base down

* Update ui/components/component-library/banner-base/README.mdx

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

* Update ui/components/component-library/banner-base/README.mdx

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

* Update ui/components/component-library/banner-base/banner-base.js

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

* Update ui/components/component-library/banner-base/banner-base.js

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

* Update ui/components/component-library/banner-base/banner-base.test.js

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

* Update ui/components/component-library/banner-base/banner-base.js

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

* fix linting

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>
Co-authored-by: George Marshall <george.marshall@consensys.net>
2023-01-11 09:42:18 -08:00
Nidhi Kumari
6e900fb0e3
housekeeping for Avatar Favicon (#16931)
* housekeeping for avatar favicon

* added test for custom className

* fixed lint errors

* updated avatar favicon in tag url

* updated import

* updated readme and fixed label

* updated tag url snapshot

* updated snapshot for favicon
2023-01-11 21:41:06 +05:30
Filip Sekulic
fc83a1b631
Fixed navigation through multiple unapproved transactions for ERC20 tokens (#16822) 2023-01-11 09:01:50 -06:00
Garrett Bear
e236792a90
add width docs to box component (#17007)
* add width docs to box component
2023-01-09 22:30:29 -08:00
Nidhi Kumari
56a3afaace
avatar account housekeeping (#16930)
* avatar account housekeeping

* avatar number to the diametere

* fixed lint errors

* converting blockie to number

* updated README

* updated constants for avatar account
2023-01-09 16:38:43 -08: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
Nidhi Kumari
be227705d0
added padding/margin inline, inline-start and inline-end support to Box Component (#17085)
* added padding/margin inline-start and inline-end support

* updated story for margin
2023-01-06 12:10:28 +05:30
Nidhi Kumari
a1c5224997
housekeeping for picker-network (#16982)
* updated test in picker-network

* fixed import order in README

* fixed global import path

* fixed formatting
2023-01-05 15:30:42 -08:00
Nidhi Kumari
c9ddee9155
updated colors for typography component (#17009)
* updated colors for typography

* updated valid colors
2023-01-05 13:04:48 -08:00
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
Nidhi Kumari
f8881a01db
AvatarWithBadge Housekeeping (#16985)
* updated classnames

* updated readme and tests for avatar with badge

* updated constants in root

* replacing BADGE_POSITIONS with AVATAR_WITH_BADGE_BADGE_POSITIONS
2022-12-22 00:36:40 +05:30
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
George Marshall
09d29ef00d
Renaming broken stories to clean up console (#16905)
* Renaming broken stories. Fixing deprecated default arg syntax for stories using defaultValue

* Fixing imports
2022-12-15 14:46:30 -08: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
Garrett Bear
4ba081a096
add text directions (#16901)
* add text directions

* add text direction test

Co-authored-by: Nidhi Kumari <nidhi.kumari@consensys.net>
2022-12-15 10:49:47 -08:00
Nidhi Kumari
88af4b3c36
Avatar Token HouseKeeping (#16662)
* Avatar Token HouseKeeping

* updated props

* fixed indentation and avatar size

* fixed lint issues

* updated sizes

* fixed alignment of avatar token halo stories

* updated story for src

* updated avatar token

* updated README

* updated Readme
2022-12-15 22:59:24 +05:30
Nidhi Kumari
4fcbaae32f
housekeeping for avatar network (#16663)
* added housekeeping for avatar network

* fixed alt

* updated story in Readme

* fixed indentation and added network src

* updated SIZES for avatar network

* updated snapshot

* updated docs and props

* updated name of avatar

* removed comments

* updated avatar network component

* updated readme

* updated story for badge

* added constants to the root
2022-12-15 22:58:42 +05:30
Nidhi Kumari
df73d1887d
added goerli and sepolia inverse colors (#16928)
* added goerli and sepolia inverse colors

* updated story

* removed duplication of args

* updated colors in root
2022-12-15 22:58:30 +05:30
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
Jyoti Puri
dc5a9f967d
ButtonIcon: fix react component proptype (#16942) 2022-12-13 15:23:39 -06:00
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
David Walsh
dcffa4c7bc
Fix #16804 - Onboarding - Prevent odd behavior with clicks and show/hide password (#16878) 2022-12-12 08:36:02 -06: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
Nidhi Kumari
52304d7910
housekeeping for tag url (#16723)
* housekeeping for tag url

* updated docs for tag url

* updated docs for tag url

* updated tag url component

* updated stories

* updated label

* Some small updates

* Updating test to catch failed propType

Co-authored-by: georgewrmarshall <george.marshall@consensys.net>
2022-12-08 23:57:00 +05:30
Garrett Bear
c9560b75f2
add avatar icon component (#16755)
* add avatar icon component

* add avatar icon severities

* avatar icon docs

* update tests and remove stylesheet

* aria label

* remove aria label

* update test

* remove aria label

* iconName prop type string

* Update ui/components/component-library/avatar-icon/README.mdx

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

* Update ui/components/component-library/avatar-icon/README.mdx

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

* Update ui/components/component-library/avatar-icon/avatar-icon.js

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

* Update ui/components/component-library/avatar-icon/avatar-icon.stories.js

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

* marginSizeControlOptions

Co-authored-by: George Marshall <george.marshall@consensys.net>
2022-12-08 10:25:19 -08:00
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
George Marshall
5592bc5fff
TextField house keeping 🧹 (#16668)
* TextField house keeping updates

* ButtonIcon prop name update and uncontrolled fix

* Updating snapshot
2022-12-06 11:52:03 -08:00
George Marshall
971f153e65
TextFieldBase house keeping 🧹 (#16667)
* TextFieldBase house keeping updates

* Fixing story

* Updating custom input story

* Updating ButtonIcon props and lint issues

* Updating snapshots
2022-12-06 11:51:48 -08:00
Thomas Huang
8fde322907
Continue converting tests from enzyme to @testing-library/react (#16753) 2022-12-06 10:49:08 -06:00
Sailer43
1e173afc95
Fixed NumericInput Storybook Components (#16734) (#16737)
Co-authored-by: Brad Decker <bhdecker84@gmail.com>
Fixed https://github.com/MetaMask/metamask-extension/issues/16703
Fixes https://github.com/MetaMask/metamask-extension/issues/16703
2022-12-06 10:48:55 -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
George Marshall
3deb8734ac
TextFieldSearch house keeping updates (#16669) 2022-12-01 13:48:53 -08:00
Garrett Bear
6689f8b71d
Feat/16634/buttonicon housekeeping (#16666)
* rename iconName prop

* pixel update

* updates to iconProps

* arialabel to stories
2022-12-01 09:26:31 -08:00
Garrett Bear
1007930078
Feat/16187/text housekeeping (#16589)
* text housekeeping

* update testing

* Text constant

* TEXT const to story

* format text sizes

* add associated constants to text component

* add all exports to global index.js

* update snapshot

* update text component variants

* Update ui/components/component-library/text/README.mdx

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

* update rearrangements

* update text in tests

Co-authored-by: George Marshall <george.marshall@consensys.net>
2022-12-01 09:26:19 -08: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
George Marshall
9a434aed5e
Label house keeping updates (#16680) 2022-11-29 13:01:05 -08:00
George Marshall
a76c8ecfa1
HelpText house keeping updates (#16681) 2022-11-29 13:00:51 -08: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
George Marshall
ab808b670a
Icon house keeping updates (#16621) 2022-11-23 09:58:43 -08:00
Nidhi Kumari
67bfd446fc
avatar base component housekeeping (#16583)
* replace base avatar with avatar base component

* updated tests

* updated description for props

* updated docs and background colors

* updated snapshot

* replaced size with avatar size constant

* added tests and fixed indentation

* fixed indentation in readme
2022-11-23 22:12:43 +05:30
Nidhi Kumari
fc0036d5b1
fixed console warning for labelProps (#16629) 2022-11-22 13:04:51 -08:00
George Marshall
5ee7da6afe
Adding FormTextField component (#16497)
* Adding FormTextField component

* Adding to index.js

* Adding id, label and helptext stories

* Removing unneeded htmlFor and fixing accessibility on helpText story

* Fixing issues with review suggestions

* Fixing lint issue

* Adding snapshot test
2022-11-22 13:04:27 -08:00
Garrett Bear
e9508b4f7f
Fix/16620/button href prop (#16633)
* fix button href prop passed

* improve test
2022-11-22 12:25:49 -08: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
David Walsh
9530797a7a
Create constants for all keyring types (#16575) 2022-11-21 08:23:35 -06:00
Nidhi Kumari
ad4db57a4a
updated responsive props for border radius (#16510)
* updated responsive props for border radius

* updated responsive prop

* added responsive border radius story

* fixed box structure in story

* fixed console issue

* updated display constants

* updated constants
2022-11-18 13:43:38 -08:00
Garrett Bear
e11203c2cd
Feat/16507/button link housekeeping (#16518) 2022-11-18 12:36:33 -08:00
Nidhi Kumari
af09521a69
updated background color for picker network (#16466)
* updated background color for picker network

* updated color for pressed state

* fixed linting error

* updated snapshots

* removed borderstyle

* update color

* updated snapshot

* added truncate to the text

* updated snapshot
2022-11-18 22:29:25 +05:30
George Marshall
3af83f8f98
Adding static icon names to test env file (#16078)
* Storing the icon name env var as a string and parsing to use with components

* Moving icon env vars to jest specific env.js file

* Updating snapshots
2022-11-18 22:28:38 +05:30
George Marshall
45ad946697
Removing storybook tests (#16577) 2022-11-18 07:32:20 -08:00
Nidhi Kumari
e6070df4b4
Updated Text style in Tag Url (#16570)
* fixed truncate in tag url

* updated snapshot testing

Co-authored-by: Garrett Bear <gwhisten@gmail.com>
2022-11-18 18:18:54 +05:30
George Marshall
4c809a339d
Updating network colors with design tokens (#16543)
* Updating network colors with design tokens

* Style update to flask page
2022-11-17 15:30:04 -08:00
George Marshall
653031b909
Updating all background-default hovers colors (#16519) 2022-11-17 12:53:51 -08:00
George Marshall
23b412c13f
Component library adding global index and other housekeeping (#16441)
* Adding global index.js file

* Removing style prop from button base

* Fixing comment on generate-icon-names.js file

* Re-ordering sass imports to atomic structure

* Updating component paths code examples of MDX docs
2022-11-16 14:15:08 -08:00
David Walsh
4ce6487160
BETA - Add beta banner to all screens (#16307)
* Add beta home banner to home screen

* Move the beta home notification to the app-header

* Updates to formatting

* Add beta home banner to home screen

* Move the beta home notification to the app-header

* Updates to formatting

* Update ui/components/app/app-header/index.scss

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

* Update ui/components/app/app-header/index.scss

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

* Update ui/components/app/app-header/index.scss

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

* Move banner to top of page

* Move to own folder, update styles

* Swith to BOX component

* Address feedback

* Add tests

* Update name of component

* Fix tests

* Fix proptype errors

* Fixups

* Remove unrelated changes

* Remove unwanted string changes

* Update beta component name and text

* Update mock data

Co-authored-by: George Marshall <george.marshall@consensys.net>
2022-11-16 11:41:15 -06:00
David Walsh
5fc186bbb4
Beta: Update long logo to new imagery (#16505) 2022-11-16 11:39:43 -06:00
Garrett Bear
d4bf8adaf8
button secondary housekeeping (#16495)
* button secondary housekeeping

* add snapshot

* add export constants
2022-11-15 12:48:24 -08:00
Adnan Sahovic
f9ed4a560b
Added "What's New" Notification for Improved token allowance experience (#16465) 2022-11-15 13:17:28 -06:00
Mark Stacey
4f66dc948f
Update @metamask/controllers to v33 (#16493)
The controllers package has been updated to v33. The only breaking
change in this release was to rename the term "collectible" to "NFT"
wherever it appeared in the API.

Changes in this PR have been kept minimal; additional renaming can be
done in separate PRs. This PR only updates the controller names,
controller state, controller methods, and any direct references to
these things. NFTs are still called "collectibles" in most places.
2022-11-15 15:19:42 -03:30
George Marshall
be5d70623e
Adding some propType fixes to TextFieldBase (#16508)
* Adding some propType fixes

* lint fixes
2022-11-15 10:06:59 -08:00
George Marshall
6907c4a565
Adding TextFieldSearch component (#16296)
* Adding TextFieldSearch component

* Updating docs and stories

* Moving controlled test into testing utils

* Fixing spelling in prop types af => of
2022-11-15 08:49:02 -08:00
Dan J Miller
0a5c46b156
Prevent user from editing a contract interaction created by a dapp (#16498)
* Prevent user from editing a contract interaction created by a dapp

* Code cleanup

* Fix e2e test selector

* Fix e2e test

* Fix e2e test

* Update snapshot
2022-11-15 12:28:39 -03:30
Brad Decker
c9527e745f
upgrade gulp-autoprefixer (#16439) 2022-11-15 08:40:56 -06:00
Garrett Bear
dcf79b0c99
Feat/16185/button primary housekeeping (#16457)
* ButtonPrimary housekeeping

* use sizes

* update test and danger type
2022-11-14 13:41:03 -08:00
Nidhi Kumari
780728daa8
added 50% border radius support to the Box component (#16486)
* added 50% border radius support to the Box component

* added height and width

* fixed lint issue
2022-11-14 13:40:45 -08:00
Adnan Sahovic
bf1db006fd
Added a 'Verify contract details' link to SetApprovalForAll confirmation screens (#15756) 2022-11-14 13:28:27 -06:00
Frederik Bolding
8f30e03613
[FLASK] Fix an issue with updating snaps that have caveat permissions (#16473) 2022-11-14 11:50:17 +01:00
George Marshall
9821c59e11
TextField component updates (#16424)
* Updating showClearButton prop name and making component dumber

* Docs update

* Adding missing proptype

* Fixing casing on tests

* Replacing clear button placeholder with ButtonIcon and docs update

* Fixing linting issues

* Adding note about controlled only for showClearButton to work and fixing some tests

* Updating test to include controlled testing setup function for clearButton tests
2022-11-10 11:13:15 -08:00
Vladimir Saric
42be5a07d7
Replaced addresses by the address component on SignTypedData v4 signatures (#16018)
* Replaced addresses by the address component on SignTypedData v4 signatures

* Fixing signature-request e2e tests

* Modified scss file for signature-request message

* Using address component for rendering the addresses and bold label where hex address is not valid

* Modify the address component

* Added proper BEM syntax for class names and used Box and Typography

* FIxing e2e tests

* Commited requested changes from George and added storybook

* Review requested changes

* Created new component for rendering data in signature-request-message.js

* Fixing proper usage for getAccountName and getMetadataContractName selectors

* Fixing e2e tests
2022-11-10 06:58:34 -03:30
Nidhi Kumari
4a247a95cb
Added Tag Url Component (#16159)
* added tag url file structure

* added tag url component

* updated args in tag url

* updated avatar favicon and button link in Tag url

* updated Text component in Tag URL

* added tests to the tag url component

* fixed typos

* replaced buttonbase with button link

* added lock icon to the tag-url component

* updated typo

* renamed style and prop names

* updated prop name and  tests

* fixed name for tag in readme

* fixed test statements

* updated prop names

* updated story

* fixed typo in test file

* updated lock icon rendering and icon color

* updated lock icon prop

* updated README

* updated tests for tag url

* added snapshot testing

* updated Readme for tag url

* updated label as per src

Co-authored-by: Garrett Bear <gwhisten@gmail.com>
2022-11-10 09:15:09 +05:30
George Marshall
67e0b60dcf
Update TextFieldBase to include InputComponent prop (#16422)
* Update TextFieldBase to include InputComponent

* Updating docs

* Adding test

* Update to docs

* Lint fixes

* Small doc fixe to remove some unneded spaces
2022-11-09 16:33:20 -08:00
Nidhi Kumari
ce9af8aac3
Added Picker Network Component (#16340)
* added file structure for picker-network

* updated accessory prop with props

* added tests and documentation to picker network

* updated picker network classnames

* updated custom tests for picker network

* updated css in picker network

* updated readme and stories

* added snapshot testing

* changed behaviour to button

* updated snapshot for button

* updated label as per src
2022-11-09 16:31:51 -08:00
Garrett Bear
03af17747b
Feat/15088/add button icon (#16277)
* 15088: add button icon

* button icon story updates

* add primary type

* update button icon docs

* add test

* button icon updates

* button icon and test updates

* button icon border radius and test update

* remove padding prop

* button icon updates

* Update ui/components/component-library/button-icon/button-icon.stories.js

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

* Update ui/components/component-library/button-icon/button-icon.stories.js

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

* Update ui/components/component-library/button-icon/button-icon.stories.js

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

* add aria label for storybook demo

Co-authored-by: George Marshall <george.marshall@consensys.net>
2022-11-09 13:57:21 -08:00
Garrett Bear
a28d727caf
Feat/16290/add button component (#16305)
* add button component

* add all button props

* update tests

* add button type prop

* fix base button size const

* add href prop to button base

* Update ui/components/component-library/button/README.mdx

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

* Update ui/components/component-library/button/README.mdx

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

* update tests

* Update ui/components/component-library/button-primary/button-primary.js

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

* Update ui/components/component-library/button/README.mdx

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

* Update ui/components/component-library/button/button.stories.js

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

* Update ui/components/component-library/button/button.js

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

* Update ui/components/component-library/button/button.stories.js

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

* update button props on readme

* linting issue fix

Co-authored-by: George Marshall <george.marshall@consensys.net>
2022-11-09 13:55:13 -08:00
Thomas Huang
25bb6ef861
Continue converting tests from enzyme to @testing-library/react (#16401) 2022-11-09 11:20:10 -06:00
David Walsh
f05acf8133
BETA - Update logo imagery (#16304)
* BETA - Update logo imagery

* Restore basic metamask rotating fox

* Adding story and updating colors

* Add beta to following logo

* New, square images

* Add 512 icon

Co-authored-by: georgewrmarshall <george.marshall@consensys.net>
2022-11-09 10:58:47 -06:00
Adnan Sahovic
328626debe
Warning on a Send transaction request (#16220) 2022-11-09 09:36:21 -06:00
Guillaume Roux
d154cc78e4
[FLASK] Catch and display errors in snaps insight (#16416)
* snaps insight error catching and error state

* revert confirm-transaction-base changes

* display empty state if data is null

* add loading state

* reset errors and loading state on call

* update hasNoData

* update length check in component
2022-11-09 14:20:57 +01:00
amerkadicE
d4ffc3a587
Update address component on transaction data screen (#15888)
* Update address component on transaction data screen

E2E test fix

Fix tests

* Metadata accounts

* Remove test resulsts

Co-authored-by: Brad Decker <bhdecker84@gmail.com>
2022-11-08 09:34:21 +01:00
George Marshall
ec11ff66ee
HelpText propType fix (#16402) 2022-11-07 14:34:18 -08:00
Filip Sekulic
17c1fef9be
Token allowance screen updated (#16157) 2022-11-07 12:21:38 -06:00
Thomas Huang
646dbaaff2
Continue converting tests from enzyme to @testing-library/react (#16373)
* Add transaction activity log component

* Remove duplicate tx activity log snapshot.

* Convert Identicon test to tlr.

* Convert Metafoxlogo test to tlr.

* Convert Reveal Seed Phrase test to tlr.

* Consolidate and convert Send Footer test to tlr.

* Convert Settings test to tlr.

* Consolidate and convert security tab test to tlr.

* Convert null selectedOption to empty string, and add test id to Dropdown component.

* Add Send state to mock-state

* Lint mock-state.json
2022-11-04 13:56:24 -07:00
Nicholas Ellul
300919cfcc
Fix the rendering of certain domain names in connected-sites list (#16074)
* Fix rendering origins in connected-sites list
2022-11-04 09:26:51 -04:00
Nidhi Kumari
58da1d8075
tag component housekeeping (#16355)
* tag component housekeeping

* added snapshot testing
2022-11-04 01:48:16 +05:30
Garrett Bear
8bdf820c70
button base housekeeping (#16336)
* button base housekeeping

* add pixel size to description

* snapshot update
2022-11-03 11:41:16 -07:00
George Marshall
cda3e3e4c0
Adding Label component (#16203)
* Adding Label component

* doc fixes

* Adding label wrapping input
2022-11-03 10:09:54 -07:00
George Marshall
3d37ad3b6e
Adding HelpText component (#16293)
* Adding initial HelpText component
2022-11-03 10:09:09 -07:00
Thomas Huang
129ba1290e
Continue converting tests from enzyme to @testing-library/react (#16249) 2022-11-03 08:40:20 -05: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
Guillaume Roux
cf265ed7ef
[FLASK] Allow snaps insights to show on regular EOA transactions (#16093) 2022-10-26 11:09:32 +02:00