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

1248 Commits

Author SHA1 Message Date
Paul Bouchon
47024fd9a5
feature: integrate gaba/CurrencyRateController (#6570) 2019-05-31 18:14:22 -04:00
Frankie
2b5c7b82a9
transactions/deps - use broken out nonce-tracker module (#6555) 2019-05-21 17:17:09 +02:00
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
Frankie
a34103987a
drop transactions who's nonce is lower then the known network nonce but were not included in a block (#6388)
* transactions/pending - check nonce against the network and mark as dropped if not included in a block

* transactions/pending - unifiy "dropped" txs

* transactions/pending - test - fix for new expected behavior

* fix comment

* transactions/pending - clean up dropped event

* fix spelling

Co-Authored-By: frankiebee <frankie.diamond@gmail.com>

* nit fix

* test/tx-pending - clarify test description
2019-05-16 07:36:53 +02:00
Dan J Miller
c043132b00
Adds e2e test for removing imported accounts. (#6615) 2019-05-15 14:10:11 -02:30
Paul Bouchon
e57ffbed59
feature: integrate gaba/ShapeShiftController (#6569) 2019-05-14 14:38:55 -04:00
Dan J Miller
b81c4e5c98 Set a default value for code in _determineTransactionCategory (#6604)
* Set a default value for code in _determineTransactionCategory

* Adds e2e tests that fail when token txs without gas param are not properly handled.

* Adds unit tests for _determineTransactionCategory

* Base error throwing and simple gas setting in estimateTxGas on transactionCategory
2019-05-14 14:14:07 -04:00
Thomas Huang
08e8fb21dc
Merge pull request #6568 from MetaMask/feature/gaba-phishing-controller
feature: integrate gaba/PhishingController
2019-05-10 13:43:20 -07:00
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
bitpshr
77d3bc252d feature: integrate gaba/PhishingController 2019-05-08 17:56:52 -04:00
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
Thomas Huang
090d4a8367
Merge pull request #6577 from MetaMask/fix-integration-tests
Fix integration tests: completedUiMigration state and fetch + ethquery mocking
2019-05-07 11:14:25 -07:00
Dan Miller
b481497246 Fix fetch and ethquery mocks in integration tests 2019-05-07 15:27:20 -02:30
Whymarrh Whitby
1de7dc9b41 Remove nock#restore call from actions.spec.js
This call was unmocking all of our HTTP requests, allowing further test cases
to hit the network. Calling nock#restore should not be required.
2019-05-07 13:48:50 -02:30
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
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
Paul Bouchon
0db0a187c8 feature: add Goerli support (#6459) 2019-04-17 15:04:49 -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
Sneh Koul
fb22fb12ca Adds e2e test for most web3 methods that dapps use (#6160)
* schema added

* ui for the dapp added and schema.js changed according to the comments in PR

* added tests for all web3 methods

* Update run-all.sh

* Update web3.spec.js to work with new onboarding flow

* changes made according to the comments

* Create stand alone script for web3 e2e tests.

* Lint fixes for web3 e2e tests.
2019-04-16 15:29:11 -02:30
Thomas Huang
a46ec83c9b Remove NoticeController (#6382) 2019-04-01 22:33:54 -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
Whymarrh Whitby
125a95ba71
Merge pull request #6364 from MetaMask/prevent-infura-requests-e2e-tests
Prevent infura requests in e2e tests
2019-03-29 11:27:05 -02:30
Whymarrh Whitby
3113114d51 Split e2e run-all commands onto multiple lines 2019-03-29 11:15:01 -02:30
Dan Miller
5a1545b3e4 Run from-import e2e tests with additional account, to avoid conflict with accounts in earlier test runs 2019-03-29 11:13:39 -02:30
Dan Miller
d927a3c20a Use localhost instead of mainnent/infura for custom rpc tests in e2e tests. 2019-03-29 11:13:39 -02:30
Whymarrh Whitby
99f53f5827 e2e: Update Contract Interaction wording 2019-03-29 11:13:20 -02:30
Whymarrh Whitby
643ddcb7d7 e2e: Skip approving token test 2019-03-29 11:13:09 -02:30
kumavis
ed381f5b2a test - unit - ui - actions - setCompletedOnboarding - fix stub to call callback 2019-03-29 13:10:42 +08:00
kumavis
02585c0bd0 lint fix 2019-03-29 12:51:54 +08:00
kumavis
846038a69c notice-controller - make markAllNoticesRead sync 2019-03-29 12:39:29 +08:00
kumavis
e04f0c877b lib - nodeify - correctly wrap synchronous functions 2019-03-29 12:37:40 +08:00
kumavis
a64855ef49 notices - markAllNoticesRead - use async/await 2019-03-29 12:03:31 +08:00
kumavis
781a39c039 Merge branch 'develop' into clearNotices 2019-03-29 11:54:12 +08:00
Whymarrh Whitby
dfe8287a28 e2e: Remove Privacy mode toggle step 2019-03-28 18:20:37 -02:30
Dan Miller
3aa7693103 Retry transaction list item click in 'adds multiple transactions' tests first click fails. 2019-03-28 16:20:11 -02:30
Dan Miller
10097b6a11 Default to localhost network when running e2e tests 2019-03-28 16:20:11 -02:30
Dan Miller
a44f2bb6eb Use webRequest to cancel all requests to infura in e2e tests. 2019-03-28 16:20:11 -02:30
Thomas Huang
1859de0a28 E2E - Dont close window notifications (#6349)
* Dont close window notifications

* Remove commented out lines in beta spec
2019-03-26 11:54:01 -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
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
Thomas Huang
07c9745258 Remove exclusive test 2019-03-20 21:29:08 -05:00
Thomas Huang
c43374a553 Clear notices when setCompletedOnboarding is called 2019-03-20 20:26:48 -05:00
kumavis
48047f8194 mascara - remove from project (#6283) 2019-03-12 11:17:21 -02:30
Paul Bouchon
daae155ce2 GABA: Integrate AddressBookController (#5847)
* gaba: integrate AddressBookController

* pin gaba version and update lockfile
2019-03-11 18:40:41 -10:00
Dan J Miller
c757366355
Metametrics (#6171)
* Add metametrics provider and util.

* Add backend api and state for participating in metametrics.

* Add frontend action for participating in metametrics.

* Add metametrics opt-in screen.

* Add metametrics events to first time flow.

* Add metametrics events for route changes

* Add metametrics events for send and confirm screens

* Add metametrics events to dropdowns, transactions, log in and out, settings, sig requests and main screen

* Ensures each log in is measured as a new visit by metametrics.

* Ensure metametrics is called with an empty string for dimensions params if specified

* Adds opt in metametrics modal after unlock for existing users

* Adds settings page toggle for opting in and out of MetaMetrics

* Switch metametrics dimensions to page level scope

* Lint, test and translation fixes for metametrics.

* Update design for metametrics opt-in screen

* Complete responsive styling of metametrics-opt-in modal

* Use new chart image on metrics opt in screens

* Incorporate the metametrics opt-in screen into the new onboarding flow

* Update e2e tests to accomodate metametrics changes

* Mock out metametrics network requests in integration tests

* Fix tx-list integration test to support metametrics provider.

* Send number of tokens and accounts data with every metametrics event.

* Update metametrics event descriptor schema and add new events.

* Fix import tos bug and send gas button bug due to metametrics changes.

* Various small fixes on the metametrics branch.

* Add origin custom variable type to metametrics.util

* Fix names of onboarding complete actions (metametrics).

* Fix names of Metrics Options actions (metametrics).

* Clean up code related to metametrics.

* Fix bad merge conflict resolution and improve promise handling in sendMetaMetrics event and confrim tx base

* Don't send a second metrics event if user has gone back during first time flow.

* Collect metametrics on going back from onboarding create/import.

* Add missing custom variable constants for metametrics

* Fix metametrics provider

* Make height of opt-in modal responsive.

* Adjust text content for opt-in modal.

* Update metametrics event names and clean up code in opt-in-modal

* Put phishing warning step next to last in onboarding flow

* Link terms of service on create and import screens of first time flow

* Add subtext to options on the onboarding select action screen.

* Fix styling of bullet points on end of onboarding screen.

* Combine phishing warning and congratulations screens.

* Fix placement of users if unlocking after an incomplete onboarding import flow.

* Fix capitalization in opt-in screen

* Fix last onboarding screen translations

* Add link to 'Learn More' on the last screen of onboarding

* Code clean up: metametrics branch

* Update e2e tests for phishing warning step removal

* e2e tests passing on metametrics branch

* Different tracking urls for metametrics on development and prod
2019-03-05 12:15:01 -03:30
Dan J Miller
cb2698d20e First time flow updates (#6192)
* Action select step of onboarding flow added.

* Update navigation on create and import password screens.

* Adds terms of service checkbox to create and import account screens.

* Add security warning to jazzicon intro step

* Update and streamline unique image to confirm seed steps of first time flow.

* UI touch ups to welcome screen.

* UI touch up on select action page

* Fix first time import flow.

* Add end of flow screen to first time flow

* Replace unique image screen with updated fishing warning screen.

* Update e2e tests for onboarding flow changes.

* Add required translations to onboarding flow.

* Update design of select action screen to emphasize create new wallet option.

* Clean up onboarding flow code.

* Remove notice related code from first-time-flow directory.

* Use updater function argument in new-account.component
2019-02-27 11:16:41 -03:30
Chi Kei Chan
a2320c76fe Show/Hide Fiat on Testnets based on User Preference (#6153) 2019-02-26 15:00:41 -03:30
Whymarrh Whitby
3c73781787 Delete old-ui folder 2019-02-20 14:18:46 -03:30