1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00
Commit Graph

1006 Commits

Author SHA1 Message Date
Dan J Miller
9c0e34b264
EIP-1559 - Ensure gas limit is of minimum value () 2021-07-31 08:02:14 -05:00
David Walsh
39823b3800
EIP-1559 - Implement speedup and cancel buttons () 2021-07-31 08:01:29 -05:00
Alex Donesky
8a42258e10
Remove the SHOW_EIP_1559_UI environment variable, replace with network detection where appropriate ()
Fixing up tests and add back old custom gas modal for non-eip1559 compliant networks

Remove unnecessary props from send-gas-row.component

fix breaking test

Fix primary and secondary title overrides

fix rebase issue

Fix rebase conflict

Co-authored-by: David Walsh <davidwalsh83@gmail.com>
2021-07-30 22:59:21 -02:30
Brad Decker
e0953d9f68
Update send and confirm state management, and tx controller gas defaults, for EIP1559 ()
wip

Documentation improvements for send slice support of EIP1559

Remove console.log in send duck

Property lookup safety improvement in selectors/confirm-transaction

Add code accidentally removed in rebase

Update addTxGasDefaults and _getDefaultGasFees to work with new estimate types, and ensure we correctly handle gas price estimates when on EIP1559 networks ()

* Fix typo

Remove console.log in send duck

* Update addTxGasDefaults and _getDefaultGasFees to work correctly with all new gas fee estimate types

* Don't show gas timing support when not on eip1559 compatible network

* Hide gas timing component on transaction screen when on a non-1559 network

* Improve comments, tests and edge case handling

* Ensure eip1559 fees are applied and updated correctly when eip1559 estimate api fails

* Lint fix

Co-authored-by: Brad Decker <git@braddecker.dev>

Remove console.log

Handle possible gasEstimateType undefined

Remove unnecessary nonce field position change in confirm-page-container-content__details
2021-07-30 22:15:18 -02:30
Dan J Miller
f1140087b7
Adds insufficient gas error to edit-gas-display () 2021-07-30 20:16:31 -02:30
Dan J Miller
a1f8a65519
Ensure correct conversion of data before calling getGasFeeTimeEstimate () 2021-07-30 19:41:55 -02:30
Daniel
fa703173a0
Fix Jest unit tests ()
* Fix Jest unit tests

* Provider correct getGasFeeTimeEstimate call to Gas Timing

* Fix tests for correct getGasFeeTimeEstimate method name

* Rename instances to getGasFeeTimeEstimate

Co-authored-by: David Walsh <davidwalsh83@gmail.com>
Co-authored-by: Dan Miller <danjm.com@gmail.com>
2021-07-30 15:10:41 -02:30
David Walsh
e283c03c4e
EIP-1559 - Improve gas timing logic to show more accurate verbiage () 2021-07-30 08:00:02 -05:00
Daniel
714170c7b8
EIP-1559 and Rinkeby Testnet support in Swaps () 2021-07-30 13:35:30 +02:00
David Walsh
cbfde8a080
EIP-1559 - Fix duplicated networkSupports1559 variables () 2021-07-30 05:11:27 -05:00
Alex Donesky
583c115663
remove estimation appearance from edit-gas-popover on non-1559 networks () 2021-07-29 18:29:36 -05:00
David Walsh
990a278177
EIP-1559 - Only show radio group and gas timing when network supports 1559 () 2021-07-29 13:13:14 -05:00
David Walsh
15cbe4e9a0
EIP-1559 - Allow decimals for maxFeePerGas and maxPriorityFeePerGas () 2021-07-29 10:59:14 -05:00
David Walsh
0849738003
EIP-1559 - Don't hide advanced form when radio button is chosen () 2021-07-29 10:14:48 -05:00
David Walsh
6d1fb911dc
EIP-1559 - Fix education links () 2021-07-29 09:18:13 -05:00
Dan J Miller
aaa15cbe03
Add support for EIP1559 transactions to transaction breakdown ()
* Add support for EIP1559 transactions to transaction breakdown

* Use userPreferencedCurrencyDisplay for effective gas price in transaction breakdown

* Hide eip1559 gas properties in transaction breakdown on non-1559 networks

* Add comment explaining gasPrice and effectiveGasPrice usage in transaction breakdown container.
2021-07-28 15:00:34 -02:30
ryanml
52bac60a22
Fixing confirmation layout when dapp has suggested a price (EIP-1559) () 2021-07-28 11:29:55 -05:00
Dan J Miller
9a81b826c5
Only show dapp suggested gas fee warning if user has not edited the fee () 2021-07-27 20:01:53 -02:30
David Walsh
604524f94d
EIP-1559 - Restore custom values in Edit Gas Popover ()
* EIP-1559 - Restore custom values in Edit Gas Popover

* Provide method to tell which radio button the user may have selected

* Use lodash's findKey

* Add case for legacy gas

* Use gas instead of gasLimit

* Remove unnecessary deletion and todo
2021-07-27 17:12:56 +02:00
Daniel
709369dc14
Fix default tooltip color () 2021-07-27 15:20:01 +02:00
Dan J Miller
f4d294714a
Ensure origin shows in gas popover dapp suggested gas fee warning () 2021-07-26 21:13:05 -02:30
David Walsh
fab9cfde03
EIP-1559 - Provide data wiring for Gas Timing component () 2021-07-26 10:35:51 -05:00
David Walsh
a2be02dfeb
EIP-1559 - Show gas estimate updating animation in transaction detail () 2021-07-26 10:24:44 -05:00
David Walsh
6986e76adc
EIP-1559 - Show advanced form controls by default when user has selected custom values or there are gas warnings/errors () 2021-07-26 09:17:23 -05:00
David Walsh
cd4521fb12
EIP-1559 - Allow wrapping for dapp suggested origin () 2021-07-24 15:40:51 -05:00
David Walsh
4e87069af3
EIP-1559 - Prevent Max Fee and Max Amount from wrapping on confirmation screen () 2021-07-23 08:39:10 -05:00
ryanml
8cb1557f1c
Adding method to capture one-time Sentry exceptions () 2021-07-22 16:13:40 -07:00
ryanml
a96af9e5fc
No longer deconstructing account menu ref if it isn't rendered () 2021-07-22 11:42:44 -07:00
David Walsh
c1d96676b5
EIP-1559 - Implement new verbiage for transaction detail subtext () 2021-07-22 11:33:34 -05:00
David Walsh
286fd397f8
EIP-1559 - Maintain changed form values and unselect radio buttons when user customizes form value () 2021-07-22 11:32:59 -05:00
David Walsh
6d92759853
EIP-1559 - Implement form validation for EIP-1559 ()
* Restructure advanced gas form errors

* Use shared constant for gas errors

* Add validation for fields too low

* Add warnings for high max fee and max priority fee

* Fix lint

* Fix priority fee high warning string
2021-07-20 14:34:32 -05:00
David Walsh
e0ba3eb6fc
Fix actionable message icon size () 2021-07-16 21:36:35 -05:00
ryanml
e60e371105
Improve handling for block explorer url host extraction () 2021-07-16 11:52:41 -07:00
Dan J Miller
6f0e54aa26
Implement modern design for error messages () 2021-07-16 13:06:48 -05:00
David Walsh
493448c96e
EIP-1559 - Don't show submit button when in education mode, don't duplicate title () 2021-07-16 11:19:09 -05:00
Brad Decker
dc25a24de3
rely upon gas fee controller for gas price estimates () 2021-07-16 11:06:32 -05:00
David Walsh
d8984d3cf3
EIP-1559 - Provide Updated UI for Dapp-Suggested Gas fees () 2021-07-16 10:00:03 -05:00
Brad Decker
4aab4887d5
add MODIFY_IN_PLACE as mode prop on edit-gas-popover ()
This is necessary for the submit method to call the right background process
2021-07-15 12:31:51 -05:00
David Walsh
8e5ebfb05a
EIP-1559 - Disable gas form submission if estimates are loading state () 2021-07-15 12:24:03 -05:00
David Walsh
1665617378
Create different label for Gas Price with GWEI included () 2021-07-15 12:23:54 -05:00
David Walsh
c241d3150c
EIP-1559 - Provide tooltip text for all advanced gas controls () 2021-07-15 12:23:37 -05:00
David Walsh
c1064e0c50
EIP-1559 - Only show education link if on 1559-compatible network () 2021-07-15 12:22:55 -05:00
David Walsh
a294f02b1d
EIP-1559 - Elevate gas properties to the Popover, disable submission if errors () 2021-07-14 11:45:37 -05:00
David Walsh
91e744a705
EIP-1559 - Provide edit button for transaction screens to update gas () 2021-07-14 08:42:10 -05:00
ryanml
bbef49158d
Various UI fixes () 2021-07-13 19:06:12 -07:00
David Walsh
97d9cdff80
Provide EIP 1559 fields in transaction history () 2021-07-13 08:42:36 -05:00
Brad Decker
9416d1ca71
provide skeleton for submitting gas form () 2021-07-12 14:35:54 -05:00
David Walsh
1da7beed13
Provide Estimate Data to EditGasDisplay () 2021-07-12 11:16:03 -05:00
Brad Decker
36ab817858
add edit button support to transaction-detail-item () 2021-07-09 13:08:15 -05:00
Brad Decker
68dfc98f40
wire up gasFeeController () 2021-07-08 15:23:00 -05:00
Brad Decker
64adfe7b11
update speedup and cancel to make room for EIP-1559 ()
* prepare for EIP1559 gas fields in speedup/cancel

* Update ui/components/app/gas-customization/gas-modal-page-container/gas-modal-page-container.container.js
2021-07-08 13:48:23 -05:00
Alex Donesky
0ca0f1784e
Add recovery-phrase views for new onboarding flow ()
* add recovery-phrase views for new onboarding flow

* black => ui-black

* minor syntax improvement
2021-07-07 19:10:12 -05:00
Alex Donesky
b1e2005a73
Add form-field component and new account view ()
* add generic form-field component

* swap in new form-field component for advanced-gas-controls-row

* add new create password view for redesigned onboarding flow

* make text additions translatable
2021-07-06 17:19:11 -05:00
ryanml
68ad9c619f
Adding copy icon to home screen account address ()
* Adding copy icon to home screen account address

Fixes 

* Using margin-inline-start
2021-07-06 11:17:13 -07:00
Brad Decker
da9fb4636b
move conversion utils to shared folder () 2021-07-06 12:48:49 -05:00
ryanml
a835f00ba6
Fixing leading zero when amount input is focused ()
Fixes 
2021-07-06 10:44:46 -07:00
David Walsh
6fa3cce7ab
Create Gas Timing component for EIP-1559 () 2021-07-02 14:12:13 -05:00
David Walsh
afe06adb7a
Add icon to actionable message component () 2021-07-02 14:07:56 -05:00
David Walsh
e097a02607
Provide tooltip for 1559 Gas Price field () 2021-07-02 14:07:34 -05:00
Daniel
8ca0d24f82
Increase Jest unit test coverage for the Swaps feature to ~60% () 2021-07-02 08:48:34 -05:00
David Walsh
310531eeb6
EIP 1559 - Provide a GWEI label for advanced gas control fields () 2021-07-01 09:37:00 -05:00
David Walsh
64644ad380
Implement Dapp Acknowledgement screen for editing gas () 2021-07-01 09:36:48 -05:00
ryanml
43b7eab46a
Fixing invalid minimumGasLimit prop (AdvancedGasInputs) () 2021-06-30 23:41:39 -07:00
Dan J Miller
18464793f5
Fix gas-modal-page-container.container check for custom gas price safety ()
* Fix gas-modal-page-container.container check for custom gas price safety

* Ensure gas price has been fetch before checking for price safety on testnets
2021-06-30 15:56:34 -02:30
Alex Donesky
ad6715511e
make network-display component only clickable when passed a function for onClick () 2021-06-30 13:21:48 -05:00
David Walsh
36d3770b42
EIP-1559 - Implement TransactionDetail for confirmations () 2021-06-30 11:58:18 -05:00
Alex Donesky
352102438f
add ChipWithInput component () 2021-06-28 16:09:48 -05:00
David Walsh
d68f8f27c6
Implements the new EIP1559 UI components () 2021-06-28 09:45:08 -05:00
Daniel
ba3f51d6ed
Add support for fiat on-ramp via Transak () 2021-06-25 08:10:24 -05:00
Dan J Miller
87166afb6b
Use eth_gasPrice result for setting too low warning on custom networks ()
* Use eth_gasPrice result for setting too low warning on custom networks

* Assume CustomPriceSafeForCustomNetwork when there is no custom price set (it will default to recommended)
2021-06-24 14:29:47 -02:30
David Walsh
6fa36cdf51
Provide New UI Components for EIP-1559 Designs () 2021-06-23 18:39:44 -05:00
David Walsh
85de65f470
Prevent propType errors in for TransactionIcon statuses () 2021-06-23 18:39:06 -05:00
Alex Donesky
a4a5580785
Update controllers with conversionRate change with minimal required changes in extension ()
* updating controllers with conversionRate change with minimal required changes in extension

* swapping showFiat selector in places where possible

* adding invalid conversion protection

* lint fixes

* adjusting list-item styling logic
2021-06-23 18:28:49 -05:00
Brad Decker
c30cb7d33a
Refactor send page state management () 2021-06-23 16:35:25 -05:00
Alex Donesky
e10ddbe3a3
add erc-721 token detection and flag to disable sending ()
* add erc-721 token detection and flag to disable sending

* addressing feedback

* remove redundant provider instantiation

* fix issue caused by unprotected destructuring

* add tests and documentation

* move add isERC721 flag to useTokenTracker hook

* Update  and  unit tests

* use memoizedTokens in useTokenTracker

Co-authored-by: Dan Miller <danjm.com@gmail.com>
2021-06-22 12:39:44 -05:00
ryanml
f1f2a01c76
Using fixed positioning for home notifications () 2021-06-21 15:51:09 -07:00
sooyoung
c152a17a85
Changed scss style to see token symbol ()
* Changed scss style to see token symbol

* fix indentations
2021-06-15 11:00:47 -05:00
ryanml
22c2d261b9
Fixing unlocalized strings () 2021-06-12 15:25:24 -07:00
ryanml
2bfc3a093f
Using values from shared/constants/time to represent timing values () 2021-06-10 12:27:03 -07:00
Brad Decker
9e509d0c9d
Relocate send state into send duck from metamask duck () 2021-06-10 12:53:15 -05:00
Brad Decker
b073b04789
move metamask state selectors out of send () 2021-06-08 11:03:59 -05:00
Brad Decker
df9bc52e9f
Add gas constants () 2021-06-08 10:25:48 -05:00
ryanml
9932c40651
Adding periodic reminder modal for backing up recovery phrase ()
* Adding recurring recovery phrase reminder modal

* Refactoring per PR feedback
2021-06-04 23:33:58 -07:00
Dan J Miller
6dae3bbe57
Improve detection of whether a whats new notification was 'seen' () 2021-06-03 13:58:04 -02:30
Shane T
c65ccf60e5
Fix proptype validation in TransactionIcon component () 2021-05-31 21:49:23 -02:30
ryanml
629da90d72
Adding "What's New" notification for Ledger Support Update ()
* Adding "What's New" notification for Ledger Support Update

* Using Typography component
2021-05-26 14:29:19 -07:00
Etienne Dusseault
4c341d83ab
Add Approval Confirmation Screen component to Storybook ()
* add metametrics wrapper

* add history dep

* provide test data and mock react router

* add first confirmaion screen

* figure out a way to mock match.params

* render token approval with data

* fix lockfile

* fix lint

* remove use effect

* lintfix

* add . for src paths

* litfix

* Add knobs to change redux store for confirm-approve component (Storybook) ()

* add knob for domain

* knobify

* remove logs

* remove comment

* lintfix

* fix comments

* add background calls + metriccs event to storybook acctions

* lintfixxxx
2021-05-25 08:20:09 +08:00
David Walsh
3055db5c33
Disable Ledger Live toggle for Firefox users () 2021-05-24 16:11:17 -05:00
ryanml
6640973858
Fixing jest component test output errors ()
* Adding missing required props to component tests

* Removing unused IntroPopup component

* Mocking useLayoutEffect as useEffect in confirm-page-container-header.component.test.js
2021-05-20 11:28:25 -07:00
Niranjana Binoy
2972e78444
Avoid showing "Gas price extremely low" warning in advanced tab for testnets () 2021-05-20 11:32:55 -04:00
Alex Donesky
f19207ca87
use etherscan-link customBlockExplorer methods with customNetwork usage tracking ()
* use etherscan-link customBlockExplorer methods with customNetwork usage tracking

* consolidate blockexplorer events, add domain to metametrics event

* lint fix
2021-05-19 09:51:47 -05:00
ryanml
b7a1c8c302
Adding notification for updated seed phrase wording ()
* Adding notification for updated seed phrase wording

* Updating e2e notification state

* Always displaying image for swaps notification
2021-05-18 15:00:34 -07:00
Niranjana Binoy
9d78c8b873
Hide basic tab in advanced gas modal for speedup and cancel when on testnets () 2021-05-18 12:36:05 -04:00
Brad Decker
d9a2165f69
use safer toChecksum utility () 2021-05-17 16:19:39 -05:00
Brad Decker
9386e3cb03
create safer isValidAddress method () 2021-05-17 14:00:59 -05:00
Dan J Miller
2e11458d29
Improve type checking and handle incorrect category in transaction-icon component ()
* Improve type checking and handle incorrect category in transaction-icon component

* Capture exception for sentry when transaction icon is passed an unrequired category

* Rename ui/components/app/transaction-icon/index.scss -> ui/components/app/transaction-icon/transaction-icon.scss
2021-05-17 12:01:00 -02:30
ryanml
30abcd0fe0
Fixing unlocalized strings ()
* Fixing unlocalized strings

Fixes 

* Removing aggregrate bullet from modal

* Updating bullet point keys
2021-05-14 17:29:26 -07:00
ryanml
9236d3132a
Fixing account search results ordering ()
Removing 'shouldSort: false' from fuse.js' options config

Fixes 
2021-05-14 11:38:56 -07:00
Daniel
7acb33c976
Show a notification about BSC Swaps if a user is on the BSC Mainnet ()
* Add a notification for BSC Swaps

* Add a new logo for BSC sources, update an image for BSC notification

* Mark a BSC notification as seen when a user clicks on “Start swapping”

* Add conditional rendering of notifications

* Remove divider for the last notification

* Remove a divider for the last notification

* Remove !

* Trigger pipeline
2021-05-14 14:47:56 -02:30
Thomas Huang
e920fe15c3
Add isHex check for addresses supplied to icons () 2021-05-12 15:25:37 -07:00
David Walsh
bf76d4e754
Prevent signature request component from canceling hardware wallet signing () 2021-05-07 15:54:20 -05:00
ryanml
f3cc048fea
Removing unused prop from TransactionActivityLog () 2021-05-07 13:21:03 -07:00
ryanml
9e8141eb0e
Fixing alignment issue with bottom notification () 2021-05-03 15:10:45 -07:00
Dan J Miller
a082a2ca75
Whats new popup design fixes ()
* Remove padding on QR code image

* Allow the qr code to be below the description in the whats new popup

* Fix size and position of QR code in whats new notification

* Add right caret to action links in whats new popup

* Clean up placeImageBelowDescription logic

* Fix display of whats-new-popup image

* Improve spacing and sizing of whats new popup in both full screen and popup view

* refactor
2021-05-03 15:09:26 -02:30
David Walsh
6265799634
Anchor the Need Help text to the bottom of the expanded page () 2021-04-29 12:43:33 -05:00
Brad Decker
09d81ac5f2
remove the ui/app and ui/lib folders () 2021-04-28 14:53:59 -05:00