1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-10-23 03:36:18 +02:00
Commit Graph

3147 Commits

Author SHA1 Message Date
Dan J Miller
18179fd345 Add delete to custom RPC form (#6718, #6650) 2019-06-17 11:35:47 -02:30
Kirill Goncharov
a47370057e Fix styles on 'import account' page, update help link (#6700)
* Fix styles on 'import account' page, update help link

* Update changelog
2019-06-17 08:37:34 -02:30
Thomas Huang
6fb0d4af27 Wrap smaller custom block explorer url text (#6714) 2019-06-17 08:32:12 -02:30
Chi Kei Chan
9a1a207ffa
MetaMorph - Spacing and Typeface on Extension Main view (#6584)
* wip

* Style Update: Mobile App Header

* wip

* Style Update: mobile menu-bar

* Style Update: Primary and Secondary balance on mobile main view

* Style Update: Spacing for transaction-list and transaction-list-item

* Address PR Comments

* Fix full-width view

* line-height fixes
2019-06-12 19:56:04 -07:00
Esteban Miño
71390db4a3
Feature: sync with mobile v2 (#6673)
* handle two steps

* generate new qr each 30 secs

* handle change of channel cipher without changing qr code

* fix typo
2019-06-12 10:54:45 -04:00
Jenny Pollack
9180e39b08 Revert "fixed #5524"
This reverts commit c8cb4ba370.
2019-06-06 19:20:33 +02:00
Mathew Kamkar
79d2eaffac
lint cleanup 2019-05-24 22:16:56 -07:00
Mathew Kamkar
c7266067ce
Enable Ledger hardware wallet support on Firefox
Firefox 67 support U2F by default
2019-05-24 21:42:48 -07:00
Dan J Miller
5e2fd8ae86
Ensures that transactions cannot be confirmed if gas limit is below 21000. (#6625) 2019-05-23 11:26:40 -02:30
Whymarrh Whitby
5f307040f2 Remove unused fn arguments in AmountMaxButton 2019-05-20 15:06:28 -02:30
Dan J Miller
3254738360 MetaMetrics documentation (#6624) 2019-05-20 15:02:26 -02:30
Etienne Dusseault
0e9c8fb5cc Improved UX for sweeping accounts (#6488)
* Changed max button to checkbox, disabled input if max mode is on, recalculate price according to gas fee if max mode is on

* Disabled insufficient funds message in the modal if max mode is on, displays proper amounts in modal when max mode is on, sets the send amount according to custom gas price after gas modal save, resets the send amount after resetting custom gas price

* Disabled max mode checkbox if gas buttons are loading, refactored gas-modal-page-container

* Implemented new max button & max mode message. Moved insufficient funds error to underneath the send amount field

* Fixed existing integration test to pass, created new tests to ensure send amount field is disabled when max button is clicked and the amount changes when the gas price is changed. Refactored some components
2019-05-20 14:08:08 -02:30
Thomas Huang
cb584a6ce5
Merge pull request #6606 from industral/issue-5524
Improve ENS Address Input
2019-05-15 13:57:24 -07:00
Bruno Barbieri
1d2cf52b64 Fixes bugs in 6.5.1 (#6613)
* fix bg error

* fix ui exception
2019-05-15 10:53:09 +02:00
Alex Ivasyuv
c8cb4ba370 fixed #5524 2019-05-14 22:00:53 +03:00
Whymarrh Whitby
28c4001f52 Update auto-logout to recognize idle time in background (#6593)
* Fix wording of autoLogoutTimeLimitDescription

* AppStateController and update auto-logout functionality
2019-05-13 13:46:09 -02:30
Whymarrh Whitby
0cdce533e2 Fix RPC URL message key casing (#6595) 2019-05-10 11:54:52 -02:30
Dan J Miller
13be683701
New settings custom rpc form (#6490)
* Add networks tab to settings, with header.

* Adds network list to settings network tab.

* Adds form to settings networks tab and connects it to network list.

* Network tab: form adding and editing working

* Settings network form properly handles input errors

* Add translations for settings network form

* Clean up styles of settings network tab.

* Add popup-view styles and behaviour to settings network tab.

* Fix save button on settings network form

* Adds 'Add Network' button and addMode to settings networks tab

* Lint fix for settings networks tab addition

* Fix navigation in settings networks tab.

* Editing an rpcurl in networks tab does not create new network, just changes rpc of old

* Fix layout of settings tabs other than network

* Networks dropdown 'Custom Rpc' item links to networks tab in settings.

* Update settings sidebar networks subheader.

* Make networks tab buttons width consistent with input widths in extension view.

* Fix settings screen subheader height in popup view

* Fix height of add networks button in popup view

* Add optional label to chainId and symbol form labels in networks setting tab

* Style fixes for networks tab headers

* Add ability to customize block explorer used by custom rpc

* Stylistic improvements+fixes to custom rpc form.

* Hide cancel button.

* Highlight and show network form of provider by default.

* Standardize network subheader name to 'Networks'

* Update e2e tests for new settings network form

* Update unit tests for new rpcPrefs prop

* Extract blockexplorer url construction into method.

* Fix broken styles on non-network tabs in popup mode

* Fix block explorer url links for cases when provider in state has not been updated.

* Fix vertical spacing of network form

* Don't allow click of save button on network form if nothing has changed

* Ensure add network button is shown in popup view

* Lint fix for networks tab

* Fix block explorer url preference setting.

* Fix e2e tests for custom blockexplorer in account details modal changes.

* Update integration test states to include frequentRpcList property

* Fix some capitalizations in en/messages.json

* Remove some console.logs added during custom rpc form work

* Fix external account link text and url for modal and dropdown.

* Documentation, url validation, proptype required additions and lint fixes on network tab and form.
2019-05-09 14:57:14 -02:30
Whymarrh Whitby
094e4cf555 Check for unused function arguments (#6583)
* eslint: Check for unused function arguments

* eslint: Ignore unused '_' in argument list

Also allow any number of '_' e.g., '__' or '___' which is to be used sparingly

* Remove and rename unused arguments
2019-05-08 15:51:33 -04:00
Chi Kei Chan
56ed189aeb
Auto logout after specific time (#6558)
* Add i18n strings

* Finish Auto timeout

* Fix linter

* Fix copies

* Add unit test to Advanced Tab component

* Add back actions and container

* Add basic test to ensure container completeness

* No zero, fix linters

* restrict negative in input
2019-05-08 11:57:21 -07:00
Chi Kei Chan
0497d209b2
Remove KNOWN_ADDRESS_ERROR from error objects (#6578)
* Remove KNOWN_ADDRESS_ERROR from error objects

* Update test comments
2019-05-08 10:34:56 -07:00
Whymarrh Whitby
d730da8caa Use metricsEvent in AmountMaxButton component 2019-05-07 13:48:50 -02:30
Chi Kei Chan
581128503c Allow dragging seed phrase during Confirm Seed Phrase (#6557)
* Add basic drag and drop functionality

* Refactor seed phrase data structure

* Insert to list when drop

* Save before refactor

* Finish DND

* Fix linter

* update package-lock.json

* Address styling feedbacks

* Add box shadow on hover

* Finish adding unit tests

* Remove describe.only
2019-05-07 12:33:26 -02:30
Whymarrh Whitby
a58e549c3f Skip null and undefined keys when translating via context (#6543)
* i18n: Don't translate null or undefined keys

* Add JSDoc for I18nProvider#t context fn
2019-05-06 15:04:16 -02:30
Whymarrh Whitby
6aa889280d Add suffix to title text only when it exists (#6546) 2019-05-06 10:55:18 -02:30
kumavis
2845398c3d Refactor ProviderApprovalController to use rpc and publicConfigStore (#6410)
* Ensure home screen does not render if there are unapproved txs (#6501)

* Ensure that the confirm screen renders before the home screen if there are unapproved txs.

* Only render confirm screen before home screen on mount.

* inpage - revert _metamask api to isEnabled isApproved isUnlocked
2019-05-03 13:32:05 -04:00
Whymarrh Whitby
e6b9b5c5a9 Use tOrKey for actionKey in ConfirmTransactionBase 2019-05-01 00:23:19 -02:30
Whymarrh Whitby
12cfe8e543 Fix binding of this for I18nProvider#tOrKey 2019-05-01 00:23:19 -02:30
Dan J Miller
4fea9d0cc2
Send metrics event from backend for on chain transaction failures (#6500)
* Send metrics event from backend for on chain transaction failures

* Passes state object to backEndMetaMetricsEvent, and adds getMetaMetricState selector
2019-04-29 03:48:40 -02:30
Chi Kei Chan
0095889408 Add subheader to all settings subviews (#6502)
* Add subheader to all settings subviews

* add margin right to subheader
2019-04-29 03:48:03 -02:30
Dan J Miller
39b7145423
Ensure home screen does not render if there are unapproved txs (#6501)
* Ensure that the confirm screen renders before the home screen if there are unapproved txs.

* Only render confirm screen before home screen on mount.
2019-04-27 06:59:55 -02:30
Thomas Huang
608796398e Revert "Adds 4byte registry fallback to getMethodData() (#6435)"
This reverts commit 09f2a2a547.
2019-04-26 10:05:38 -07:00
Chi Kei Chan
13605c2b5e
Always show private network when RPC is not whitelisted (#6495) 2019-04-25 13:54:35 -07:00
Chi Kei Chan
429bb5e7aa
Fix button colors on mobile (#6493) 2019-04-24 20:01:41 -07:00
Chi Kei Chan
ec712d5d8f
Set max-width on network dropdown and ellipsis long network name (#6494) 2019-04-24 20:01:24 -07:00
Thomas Huang
4fa9576cc1
Merge pull request #6481 from MetaMask/address-prop-types-errors
Address prop types errors
2019-04-18 08:22:45 -06:00
Chi Kei Chan
3519e90ffd Make height consistent on all row in send-content (#6480)
* Update all send-content row to 54px height

* Remove header subtitle

* Remove tests that check for send screen subheader
2019-04-18 00:41:04 -02:30
Thomas Huang
ed23801490
Merge pull request #6477 from MetaMask/metrics-screen-button-type
Update button type on metrics opt-in screen.
2019-04-17 18:26:43 -06:00
Dan Miller
cca73f33f3 Update button type on metrics opt-in screen. 2019-04-17 21:44:39 -02:30
Dan Miller
8a82e629bf Ensure future tokens add decimals as numbers while supporting numbers and strings in send-asset-row 2019-04-17 21:26:25 -02:30
Dan Miller
8c075b7158 getSeletedAsset to only return symbol strings, not token objects 2019-04-17 20:59:45 -02:30
Thomas Huang
1ba7afe34b
Merge pull request #6475 from chikeichan/send-asset
Fix PropTypes validation in send-asset-row
2019-04-17 16:15:56 -06:00
Chi Kei Chan
ed28ca60e0 Fix PropTypes validation in send-asset-row 2019-04-17 13:50:47 -07:00
Chi Kei Chan
d8b536982e
Update confirm to use btn-primary (#6473)
* Update confirm to use btn-primary

* Remove console

* Fix e2e test
2019-04-17 13:34:47 -07:00
Chi Kei Chan
931aaeb700 Add token selection to the send screen (#6445)
* Move send to pages/

* Fix unit tests

* Finish UI

* Integrate asset dropdown to send actions

* Remove console.log

* Hide asset change during edit

* Enable switch from send token to seand eth

* Enable switching from token to eth when editing

* Fix linter

* Fixing test

* Fix unit tests

* Fix linter

* Fix react warning; remove console.log

* fix flat test

* Add metrics

* Address code review comments

* Consistent spacing between send screen form rows.

* Reduce height of gas buttons on send screen.

* Make send screen gas button height dependent on size of contents.
2019-04-17 16:45:13 -02:30
Thomas Huang
83f3e8ab98
Merge pull request #6468 from chikeichan/network-indicator-style-fix
Fix switcher height when Custom RPC is selected or loading
2019-04-17 12:42:49 -05:00
Paul Bouchon
0db0a187c8 feature: add Goerli support (#6459) 2019-04-17 15:04:49 -02:30
Chi Kei Chan
597c490928 Fix switcher height when Custom RPC is selected or when network is loading 2019-04-16 23:47:11 -07:00
Thomas Huang
00133d31b1
Merge pull request #6444 from MetaMask/localhost-network-dropdown
Fixes #6321 & #6421 - Add Localhost 8545 for network dropdown names
2019-04-16 14:39:00 -05:00
Dan J Miller
09f2a2a547
Adds 4byte registry fallback to getMethodData() (#6435)
* Get contract method data from 4byte if we can't get it from eth-method-registry

* Clarify token method name fallback code in getMethodData

* Bugfix: don't attempt to translate falsy actionKeys in confirm-transaction-base.component.js

* Rewrite getMethodFrom4Byte with async-await

* Call four byte and method-registry requests in parallel in getMethodData()
2019-04-16 17:07:47 -02:30
Chi Kei Chan
92c03bdff2 Update buttons & colors to match design system (#6446)
* Refactoring button styles

* renaming buttons

* Add Link and Button styles

* Update new btn styles and storybook

* Fix tests

* Change font weight; Update storybook

* Fix linter
2019-04-16 17:05:22 -02:30
Whymarrh Whitby
c4a3d4ea82 Remove unneeded array cloning in getSendToAccounts selector
The use of `Object.entries` here to map the accounts into a new array effectively
produces a shallow clone of the array without guaranteeing the order of the original
array (as object iteration order is implementation-specific and variable). From MDN [1]:

> The **`Object.entries()`** method returns an array of a given object's own enumerable
> string-keyed property `[key, value]` pairs, in the same order as that provided by a
> `for...in` loop

And also:

> The ordering of the properties is the same as that given by looping over the
> property values of the object manually.

Both of which suggest that the iteration order is the same as `for...in`, which is to
say that it's not specified. [2] [3]

This changeset removes the cloning, keeping the shallow clone created the line before
which preserves the order of the items in the array.

  [1]:https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/entries
  [2]:https://stackoverflow.com/a/5525820/1267663
  [3]:https://stackoverflow.com/a/30919039/1267663
2019-04-11 21:50:06 -02:30
Sneh Koul
2786932576 repeated getSelectedAddress() func send.selectors.js removed (#6056) 2019-04-11 15:20:03 -02:30
Thomas Huang
d7a2ea9a2b Add Localhost 8545 for network dropdown names 2019-04-10 16:34:13 -05:00
Dan Miller
c80b295ccc Only pass english function names to functionType metric 2019-04-08 13:31:11 -02:30
Dan Miller
5d948360c0 Distinguish between token and eth selected in home screen send button metrics event. 2019-04-08 11:06:13 -02:30
Dan Miller
5454266d7c Metrics tracking gas changed - slow, average, fast, custom - on edit screen.- 2019-04-08 11:06:05 -02:30
Dan Miller
4963ed65c0 Track seed phrase validation errors with MetaMetrics 2019-04-05 01:32:18 -02:30
kumavis
cf4eac3f2c
Merge pull request #6397 from MetaMask/wyre-deposit-modal
Change coinbase to wyre
2019-04-04 10:16:26 +08:00
Thomas Huang
6a80ff2718 Change coinbase to wyre 2019-04-03 16:45:43 -05:00
Dan J Miller
95a2480074 Fix display of gas chart on Ethereum networks (#6389) 2019-04-03 13:31:43 -02:30
Thomas Huang
a46ec83c9b Remove NoticeController (#6382) 2019-04-01 22:33:54 -02:30
Whymarrh Whitby
4055dc3475
Remove unused account-dropdowns components (#6363) 2019-04-01 14:25:33 -02:30
Thomas Huang
87f393eb31
Merge pull request #6375 from MetaMask/Version-6.3.1
Version 6.3.1
2019-03-29 13:27:16 -05:00
Dan Miller
05fd704fef Check token name constants against the lower case methodData name in conf tx switch container. 2019-03-29 15:23:55 -02:30
Dan Miller
8458873a20 Ensure correct confirm screen in case of smartcontract check fail 2019-03-29 15:23:55 -02:30
Chi Kei Chan
adcf03eacc About tab copy changes; Update route for Info & Help in account menu (#6356) 2019-03-29 13:54:03 -02:30
Dan J Miller
1d14646a4c Revert to providing inline defaults in getHexGasTotal and increaseLastGasPrice (#6361) 2019-03-29 12:47:58 -02:30
Dan J Miller
19c2b298f1
Further e2e fixes in wake of #6364 and #6367 (#6374)
* getMethodData() default to abi decoded method if registry lookup errors

* Update e2e tests to work with getMethodData() fallback changes

* Remove indeterminency in gas input key entering in send token e2e test.
2019-03-29 12:18:08 -02:30
kumavis
c3a605f27a
Merge pull request #6328 from MetaMask/clearNotices
Clear notices
2019-03-29 14:23:02 +08:00
kumavis
133ed80aee
Merge pull request #6372 from MetaMask/addAddressIfNew
prevent add duplicates when address is not new
2019-03-29 13:48:15 +08:00
kumavis
0961449ca0 send-footer.utils.js - addressIsNew - improve readability 2019-03-29 13:34:49 +08:00
kumavis
02585c0bd0 lint fix 2019-03-29 12:51:54 +08:00
kumavis
edec6cb81d actions - setCompletedOnboarding - make async with pify 2019-03-29 12:40:04 +08:00
kumavis
781a39c039 Merge branch 'develop' into clearNotices 2019-03-29 11:54:12 +08:00
kumavis
38b85adbe0 Merge branch 'develop' of https://github.com/vimalsagar/metamask-extension into vimalsagar-develop 2019-03-29 10:20:19 +08:00
Jenny Pollack
356ef794f2 prevent add duplicates when address is not new 2019-03-28 19:18:53 -07:00
kumavis
b004b182bf
depoit-ether-modal - make buyEth args more explicit 2019-03-29 10:10:05 +08:00
Dan Miller
31d8b279e4 Defaults to the args list in increaseLastGasPrice and getHexGasTotal 2019-03-27 17:01:25 -02:30
Dan Miller
0346089caa getHexGasTotal and increaseLastGasPrice now gracefully handle null and undefined values 2019-03-27 15:57:44 -02:30
Chi Kei Chan
8108eac705
Open retore-vault route from popup (#6353) 2019-03-26 23:35:29 -07:00
Dan J Miller
ef4894b9a0
Don't include tx value in calculation of balance sufficiency for cancel button disabling. (#6346) 2019-03-26 12:17:36 -02:30
Dan J Miller
2f13a97d00
Cancel error rebased (#6341)
* Check balance before showing cancel

* Fix linter

* Use existing helper methods for calculating increased cancel price

* Add tooltip for disabled button

* Lint fix for cancelError branch.

* Disabling of cancel button should account for value of tx.
2019-03-25 13:55:23 -02:30
Dan J Miller
69f7968c70
Close transaction on close of notification window (#6340) 2019-03-25 13:49:23 -02:30
Dan J Miller
961ad267df
New settings page rebased (#6333)
* New setting tab

* Add InfoTab

* Add Advanced tab

* Add Security Tab

* Finish mobile view

* Make new setting page responsive

* Fix linter

* Fix y scrolling

* Update link in network dropdown

* Fix e2e tests

* Remove duplicate translation key

* Resolve merge conflict

* Only change settings header in popup view.

* Place mobile-sync button in advanced-tab of settings
2019-03-25 13:43:23 -02:30
Dan J Miller
4ff9126ff2
Replaces the coinbase link in the deposit modal with one for wyre (#6302) 2019-03-22 12:32:07 -02:30
Dan J Miller
174ec2d596
Fix oversized loading overlay on gas customization modal. (#6326) 2019-03-22 12:20:37 -02:30
Dan J Miller
2b992d2946
Fix gas fee in the submitted step of the transaction details activity log. (#6301) 2019-03-22 12:20:25 -02:30
Dan J Miller
468bc96bdf
Hide gas price chart and prevent api call when not on ethereum networks. (#6300)
Add missing translations in gas customization modal
2019-03-22 12:20:12 -02:30
Chi Kei Chan
31175625b4 Folder restructure (#6304)
* Remove ui/app/keychains/

* Remove ui/app/img/ (unused images)

* Move conversion-util to helpers/utils/

* Move token-util to helpers/utils/

* Move /helpers/*.js inside /helpers/utils/

* Move util tests inside /helpers/utils/

* Renameand move confirm-transaction/util.js to helpers/utils/

* Move higher-order-components to helpers/higher-order-components/

* Move infura-conversion.json to helpers/constants/

* Move all utility functions to helpers/utils/

* Move pages directory to top-level

* Move all constants to helpers/constants/

* Move metametrics inside helpers/

* Move app and root inside pages/

* Move routes inside helpers/

* Re-organize ducks/

* Move reducers to ducks/

* Move selectors inside selectors/

* Move test out of test folder

* Move action, reducer, store inside store/

* Move ui components inside ui/

* Move UI components inside ui/

* Move connected components inside components/app/

* Move i18n-helper inside helpers/

* Fix unit tests

* Fix unit test

* Move pages components

* Rename routes component

* Move reducers to ducks/index

* Fix bad path in unit test
2019-03-21 20:33:30 -02:30
Bruno Barbieri
7287133e15 Enable mobile sync (#6332)
* enable mobile sync

* remove mobile sync as a preference

* Fix typo
2019-03-21 12:43:10 -07:00
fixanoid
e1af6312ce Fixing spelling of Ethereum in MetaMetrics copy (#6329) 2019-03-21 12:27:26 -02:30
Thomas Huang
c43374a553 Clear notices when setCompletedOnboarding is called 2019-03-20 20:26:48 -05:00
Whymarrh Whitby
29a0b34786 Allow seed phrases with a trailing newline 2019-03-13 10:00:42 -02:30
Thomas Huang
7981b1bf23
Merge pull request #6281 from MetaMask/fix-browser-back-on-reveal-seed
Fixes the use of the browser back button on the reveal seed screen
2019-03-12 11:31:19 -05:00
kumavis
d288e59a9b ui - add missing PropTypes (#6287) 2019-03-12 12:09:55 -02:30
kumavis
48047f8194 mascara - remove from project (#6283) 2019-03-12 11:17:21 -02:30
Dan Miller
17911dddff Fixes the use of the browser back button on the reveal seed screen 2019-03-11 16:52:26 -02:30
Thomas Huang
ef7ac90bca Remove line rather than comment out 2019-03-11 13:36:36 -05:00
Thomas Huang
22c4fe0469 No longer check network when validating checksum addresses 2019-03-11 13:00:03 -05:00