From 3f363a42b15c7fd7338b0ad35d7a32fb96621aee Mon Sep 17 00:00:00 2001 From: Alexander Georgievskiy Date: Wed, 8 Feb 2017 00:46:57 +0300 Subject: Add MultBit HD BIP32 hint --- src/index.html | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/index.html b/src/index.html index 964746e..d2def05 100644 --- a/src/index.html +++ b/src/index.html @@ -393,7 +393,7 @@
- +

Use path m/44'/0'/0'. @@ -403,6 +403,13 @@ Can be used with: blockchain.info

+

+ Use path m/0'/0. +

+

+ Can be used with: + MultiBit HD +

-- cgit v1.2.3 From b4fd763cebfb7f9497e12ca09b6271e1b39ac145 Mon Sep 17 00:00:00 2001 From: Alexander Georgievskiy Date: Tue, 7 Feb 2017 22:51:24 +0000 Subject: Add client select --- src/index.html | 8 ++++++++ src/js/index.js | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 57 insertions(+) (limited to 'src') diff --git a/src/index.html b/src/index.html index d2def05..1c2ffcf 100644 --- a/src/index.html +++ b/src/index.html @@ -253,6 +253,14 @@ +
+ +
+ +
+
diff --git a/src/js/index.js b/src/js/index.js index c3c0a4a..f593b3a 100644 --- a/src/js/index.js +++ b/src/js/index.js @@ -23,7 +23,9 @@ var DOM = {}; DOM.network = $(".network"); + DOM.client = $(".client"); DOM.phraseNetwork = $("#network-phrase"); + DOM.phraseClient = $("#client-phrase"); DOM.useEntropy = $(".use-entropy"); DOM.entropyContainer = $(".entropy-container"); DOM.entropy = $(".entropy"); @@ -77,6 +79,7 @@ function init() { // Events DOM.network.on("change", networkChanged); + DOM.client.on("change", clientChanged); DOM.useEntropy.on("change", setEntropyVisibility); DOM.entropy.on("input", delayedEntropyChanged); DOM.entropyMnemonicLength.on("change", entropyChanged); @@ -102,6 +105,7 @@ hidePending(); hideValidationError(); populateNetworkSelect(); + populateClientSelect(); } // Event handlers @@ -116,6 +120,17 @@ rootKeyChanged(); } } + + function clientChanged(e) { + var clientIndex = e.target.value; + clients[clientIndex].onSelect(); + if (seed != null) { + phraseChanged(); + } + else { + rootKeyChanged(); + } + } function setEntropyVisibility() { if (isUsingOwnEntropy()) { @@ -701,6 +716,16 @@ DOM.phraseNetwork.append(option); } } + + function populateClientSelect() { + for (var i=0; i"); + option.attr("value", i); + option.text(client.name); + DOM.phraseClient.append(option); + } + } function getLanguage() { var defaultLanguage = "english"; @@ -1124,6 +1149,30 @@ }, }, ] + + var clients = [ + { + name: "Bitcoin Core", + onSelect: function() { + DOM.bip32path.val("m/0'/0'"); + DOM.hardenedAddresses.prop('checked', true); + }, + }, + { + name: "blockchain.info", + onSelect: function() { + DOM.bip32path.val("m/44'/0'/0'"); + DOM.hardenedAddresses.prop('checked', false); + }, + }, + { + name: "MultiBit HD", + onSelect: function() { + DOM.bip32path.val("m/0'/0"); + DOM.hardenedAddresses.prop('checked', false); + }, + } + ] init(); -- cgit v1.2.3