-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I5849 incremental account security #6874
Conversation
b3a499e
to
e6bcbc9
Compare
|
||
if (!seedPhrase) { | ||
history.push(DEFAULT_ROUTE) | ||
console.log('!!!444!!!') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
!!!444!!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple more a few lines above as well
hideSeedPhraseBackupAfterOnboarding, | ||
HIDE_SEED_PHRASE_BACKUP_AFTER_ONBOARDING: 'HIDE_SEED_PHRASE_BACKUP_AFTER_ONBOARDING', | ||
|
||
verifySeedPhrase, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably better to move this function somewhere else, since it's not really an action. It feels wrong to export it from here.
Then again, it'd be a lot of work to move it without creating an additional background connection. We'd probably want to create a module for all of the background interactions. Maybe that can be a future change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few comments scattered throughout, generally LGTM.
Comments specifically on the tests:
We might be able to reference files directly from the node_modules/
directory directly instead of adding them to the test/
directory. That is,
Current Path | node_modules |
---|---|
test/e2e/send-eth-with-private-key-test/buffer.js |
node_modules/buffer/index.js |
test/e2e/send-eth-with-private-key-test/ethereumjs-tx.js |
node_modules/ethereumjs-tx/es5/index.js |
I think that should work fine? We could also symlink them?
*/ | ||
|
||
/** | ||
* Background controller responsible for maintaining |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* Background controller responsible for maintaining | |
* Controller responsible for maintaining |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the "Background" distinction here might not be needed
@@ -0,0 +1,17 @@ | |||
<html> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<html> | |
<html lang="en"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also we should make sure we have a doctype: <!doctype html>
as the line above this one
@@ -0,0 +1,28 @@ | |||
/* eslint-disable */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we be more specific about what we're disabling? If all we need it to add globals, we can do that too:[1]
/* eslint-disable */ | |
/* global ethereumjs, Web3 */ |
@@ -0,0 +1,2 @@ | |||
/* eslint-disable */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this file?
@@ -0,0 +1,14 @@ | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: extra newline
@@ -0,0 +1,24 @@ | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: extra newline
Using the |
"Remind me later" optionWhat's the logic behind the "remind me later" option introduced in this implementation? How much time passes until MM asks me again? Not against doing this, but in our discussions, I believe we decided that we were not going to give the option to dismiss this message at all to encourage better security behavior cc @bdresser @omnat Component scaling for full-screenRegarding scaling this component for full-screen mode, let's right align the buttons, reduce their width to ~130px. Specs in [figma] also see gif for example of how this could scale.(https://www.figma.com/file/coqVvQFBBWGtcechEkloSE/Incremental-Account-Security-Desktop?node-id=2%3A289) In full-screen mode, let's float the notification bottom and right to the page (z-index above all other elements on the page). Button statesCreated a pen where you can pull state colors from https://codepen.io/cjeria/pen/mNmEYj BehaviorAs far as behavior goes, it works great! Additional question: |
5c06b18
to
c7dad0d
Compare
…ned tx with stand alone localhost provider
…test/ethereumjs-tx.js
c7dad0d
to
f3a2d45
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few small comments
.gitattributes
Outdated
@@ -4,3 +4,6 @@ CHANGELOG.md merge=union | |||
# we're using the dependencies we expect to be using | |||
package-lock.json linguist-generated=false | |||
yarn.lock linguist-generated=false | |||
|
|||
/home/danjm/kyokan/metamask-extension/test/e2e/send-eth-with-private-key-test/ethereumjs-tx.js linguist-vendored |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/home/danjm/kyokan/metamask-extension/test/e2e/send-eth-with-private-key-test/ethereumjs-tx.js linguist-vendored | |
test/e2e/send-eth-with-private-key-test/ethereumjs-tx.js linguist-vendored linguist-generated |
.gitattributes
Outdated
@@ -4,3 +4,6 @@ CHANGELOG.md merge=union | |||
# we're using the dependencies we expect to be using | |||
package-lock.json linguist-generated=false | |||
yarn.lock linguist-generated=false | |||
|
|||
/home/danjm/kyokan/metamask-extension/test/e2e/send-eth-with-private-key-test/ethereumjs-tx.js linguist-vendored | |||
/home/danjm/kyokan/metamask-extension/test/e2e/send-eth-with-private-key-test/ethereumjs-tx.js linguist-generated=true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/home/danjm/kyokan/metamask-extension/test/e2e/send-eth-with-private-key-test/ethereumjs-tx.js linguist-generated=true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's Get This Merged™
Resolves #5849
This PR adds the following functionality:
Full demo visible here: https://streamable.com/5klzz