refactor: per-wallet delete with monochrome styling
All checks were successful
check / check (push) Successful in 23s

- Replace 'Danger Zone' section with per-wallet [delete] links in wallet list
- Each wallet shows a [delete] text link (dashed underline, monochrome)
- Clicking opens confirmation modal for that specific wallet
- Remove all red-500 styling, use standard monochrome border-border/text-fg
- Confirmation modal uses bg-well border-dashed border-border
- No longer assumes 'selected wallet' — operates on specific wallet index
- Password verification retained for delete confirmation
This commit is contained in:
2026-02-27 12:46:03 -08:00
parent d5849c831b
commit abaff61cc8
2 changed files with 50 additions and 51 deletions

View File

@@ -708,9 +708,7 @@
<div class="bg-well p-3 mx-1 mb-3">
<h3 class="font-bold mb-1">Wallets</h3>
<p class="text-xs text-muted mb-2">
Add a new wallet from a recovery phrase or private key.
</p>
<div id="settings-wallet-list" class="mb-2"></div>
<button
id="btn-main-add-wallet"
class="border border-border px-2 py-1 hover:bg-fg hover:text-bg cursor-pointer"
@@ -844,35 +842,15 @@
<div id="settings-denied-sites"></div>
</div>
<div
class="bg-well p-3 mx-1 mb-3 border border-dashed border-red-500"
>
<h3 class="font-bold mb-1 text-red-500">Danger Zone</h3>
<p class="text-xs text-muted mb-2">
Permanently delete the currently selected wallet. This
cannot be undone. Make sure you have backed up your
recovery phrase before proceeding.
</p>
<button
id="btn-delete-wallet"
class="border border-red-500 text-red-500 px-2 py-1 hover:bg-red-500 hover:text-bg cursor-pointer"
>
Delete Wallet
</button>
</div>
<div
id="delete-wallet-confirm"
class="hidden bg-well p-3 mx-1 mb-3 border border-dashed border-red-500"
class="hidden bg-well p-3 mx-1 mb-3 border border-dashed border-border"
>
<h3 class="font-bold mb-1 text-red-500">
Confirm Deletion
</h3>
<h3 class="font-bold mb-1">Confirm Deletion</h3>
<p class="text-xs text-muted mb-2">
Deleting <strong id="delete-wallet-name"></strong> is
permanent. Any funds on this wallet will be
unrecoverable if you have not backed up your recovery
phrase.
Delete <strong id="delete-wallet-name"></strong>? This
is permanent. Any funds will be unrecoverable without
your recovery phrase.
</p>
<p class="text-xs mb-2">Enter your password to confirm:</p>
<input
@@ -884,9 +862,9 @@
<div class="flex gap-2">
<button
id="btn-delete-wallet-confirm"
class="border border-red-500 text-red-500 px-2 py-1 hover:bg-red-500 hover:text-bg cursor-pointer"
class="border border-border text-fg px-2 py-1 hover:bg-fg hover:text-bg cursor-pointer"
>
Delete permanently
Delete
</button>
<button
id="btn-delete-wallet-cancel"