From ca78da2e075118ad3ac1100df64d899142be6508 Mon Sep 17 00:00:00 2001 From: user Date: Sat, 28 Feb 2026 01:19:36 -0800 Subject: [PATCH 1/9] feat: add export private key from address detail view Adds an 'Export Private Key' button to the address detail view. Clicking it opens a password confirmation screen; after verification, the derived private key is displayed in a copyable field with a security warning. The key is cleared when navigating away. Closes #19 --- src/popup/index.html | 53 ++++++++++++++++++++++++++++ src/popup/views/addressDetail.js | 60 ++++++++++++++++++++++++++++++++ 2 files changed, 113 insertions(+) diff --git a/src/popup/index.html b/src/popup/index.html index 74dfb69..d20503d 100644 --- a/src/popup/index.html +++ b/src/popup/index.html @@ -307,6 +307,16 @@ + +
+ +
+
@@ -318,6 +328,49 @@
+ + + - -
- -
-
@@ -326,6 +316,13 @@
Loading...
+
+ Export private key +
diff --git a/src/popup/views/helpers.js b/src/popup/views/helpers.js index e5b71d0..8fdfe65 100644 --- a/src/popup/views/helpers.js +++ b/src/popup/views/helpers.js @@ -31,6 +31,7 @@ const VIEWS = [ "approve-site", "approve-tx", "approve-sign", + "export-privkey", ]; function $(id) { From 91c3b4e394f9da50b0b375c5ffb83340cd4fec8f Mon Sep 17 00:00:00 2001 From: user Date: Sat, 28 Feb 2026 04:27:56 -0800 Subject: [PATCH 3/9] refactor: move Export Private Key into overflow menu MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace the muted text link at the bottom of AddressDetail with a '···' overflow/more button in the action button row. Clicking it opens a dropdown with 'Export Private Key' as an option. Clicking outside closes the dropdown. The pattern is reusable for future secondary actions. --- src/popup/index.html | 27 ++++++++++++++++++++------- src/popup/views/addressDetail.js | 15 +++++++++++++++ 2 files changed, 35 insertions(+), 7 deletions(-) diff --git a/src/popup/index.html b/src/popup/index.html index 2f4861f..c88a963 100644 --- a/src/popup/index.html +++ b/src/popup/index.html @@ -305,6 +305,26 @@ > + Token +
+ + +
@@ -316,13 +336,6 @@
Loading...
-
- Export private key -
diff --git a/src/popup/views/addressDetail.js b/src/popup/views/addressDetail.js index e2d1d18..71eb3d2 100644 --- a/src/popup/views/addressDetail.js +++ b/src/popup/views/addressDetail.js @@ -264,7 +264,22 @@ function init(_ctx) { $("btn-add-token").addEventListener("click", ctx.showAddTokenView); + // More menu dropdown + const moreBtn = $("btn-more-menu"); + const moreDropdown = $("more-menu-dropdown"); + moreBtn.addEventListener("click", (e) => { + e.stopPropagation(); + moreDropdown.classList.toggle("hidden"); + }); + document.addEventListener("click", () => { + moreDropdown.classList.add("hidden"); + }); + moreDropdown.addEventListener("click", (e) => { + e.stopPropagation(); + }); + $("btn-export-privkey").addEventListener("click", () => { + moreDropdown.classList.add("hidden"); const wallet = state.wallets[state.selectedWallet]; const addr = wallet.addresses[state.selectedAddress]; const title = addressTitle(addr.address, state.wallets); From 68bd909345c0c67ce127e7ef098439d766a1cc9d Mon Sep 17 00:00:00 2001 From: user Date: Sat, 28 Feb 2026 04:39:45 -0800 Subject: [PATCH 4/9] fix: make overflow menu auto-width to prevent text wrapping --- src/popup/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/popup/index.html b/src/popup/index.html index c88a963..dee853c 100644 --- a/src/popup/index.html +++ b/src/popup/index.html @@ -315,7 +315,7 @@