1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00
metamask-extension/ui
Dan Finlay b52346388b Added new modular private key import system
Now any strategy for importing a private key that can be described as a pure function can be very easily turned into a MetaMask import strategy.

I've created a generic and reusable UI action called `importNewAccount(strategy, args)`.

The `strategy` is a unique identifier defined in `app/scripts/account-import-strategies`, and the `args` will be passed to the member of the `strategies` array whose key matches the strategy string.

Strategies return private key hex strings, and are used by the metamask-controller to create a new keyring, and select that new account, before calling back.

This also implements @frankiebee's idea of showing the imported account when it's been imported (my oversight!).

This commit only moves us to this architecture, keeping feature parity for private key import, but has some untested code for importing geth-style JSON files as well!
2017-01-18 15:20:48 -08:00
..
app Added new modular private key import system 2017-01-18 15:20:48 -08:00
design Move fox logo with filled in eyes into design folder (#433) 2016-07-13 11:19:41 -07:00
lib Merge branch 'master' into dev 2017-01-16 10:55:32 -08:00
.gitignore Moved UI into repo with its own dependency stack 2016-04-13 15:28:44 -07:00
css.js Develop import subviews 2016-11-04 15:32:02 -07:00
example.js Fix camel casing on setSelectedAccount action. 2016-11-21 18:16:59 -08:00
index.html Remove scroll fixing from ui preview 2016-06-30 21:32:50 -07:00
index.js Change actions reference to keyringController to background 2016-10-20 09:58:33 -07:00