Skip to content

Popup UI overhaul: tabbed IA, pubkey/npub/DID switcher, in-popup export/reset, and inline validation - #40

Merged
jjohare merged 2 commits into
mainfrom
ui/popup-overhaul
Nov 28, 2026
Merged

jjohare merged 2 commits into
mainfrom
ui/popup-overhaul

Conversation

@jjohare

@jjohare jjohare commented Nov 28, 2026

Copy link
Copy Markdown
Collaborator

Summary

Overhauls the main extension popup (popup/popup.html, popup/popup.css, popup/popup.js) to resolve vertical crowding, eliminate blocking browser dialogs, fix form state bugs, and improve accessibility.

Key Improvements

  • Main screen IA & zero nested scrolling:
    • Top bar with an open-padlock Unlocked pill (fixes the closed-padlock icon contradiction) and a dedicated header Lock button.
    • Active-tab site strip showing whether the current web page's origin is trusted, with a one-click Revoke button.
    • Segmented tab bar (Identity | Sites (N) | Settings) with keyboard arrow navigation (ArrowLeft/ArrowRight), separating identity, trusted sites (with inline bulk Remove all), and settings/danger zone cleanly.
  • Compact Identity card with npub / did:nostr / hex switcher:
    • Surfaces NIP-19 npub (via existing hexToNpub), did:nostr, and hex with one-click copy for whichever format is active.
  • No more alert(), confirm(), or prompt():
    • Dedicated Export backup key screen with masked-by-default secret display, Reveal/Hide toggle, nsec/hex switcher, and Copy button.
    • Dedicated Delete key & start over confirmation screen linking to Export first, with a default-checked option to also clear trusted sites and sidechain settings so old permissions don't leak to a new identity.
    • Dedicated in-popup Passkey-derived identity confirmation step before launching the WebAuthn window.
    • Inline field-level error banners (role="alert") and live passphrase/key validation checklists across Generate, Import, and Unlock.
  • Passkey & Form UX fixes:
    • Added Remove action for wrapped passkey unlock (previously only Replace was offered).
    • Wrapped Generate, Import, and Unlock in <form> for Enter-to-submit and added Show/Hide toggles on all passphrase and private-key inputs.
    • Fixed stuck disabled Importing… button on handleImport (missing finally), cleared stale secrets on Import open/cancel, awaited getPasskeyConfig() before showing #unlockScreen (eliminating flash of passphrase inputs on derived passkeys), and synced chrome.storage.onChanged for lock/unlock and settings changes.
  • Accessibility & visual polish:
    • Fixed WCAG AA label contrast (--text-faint → --text-muted), added missing labels/aria-labelledby attributes, replaced <a href="#"> action links with <button type="button">, added responsive body.own-window sizing, and respected prefers-reduced-motion.

Testing

  • npm run build
  • npm test (251/251 passing, including new test/popup-helpers.test.js)
  • npm run lint + npx eslint popup/

@jjohare jjohare changed the title Popup UI overhaul: tabbed IA, npub/DID/hex switcher, in-popup export/reset, and inline validation Popup UI overhaul: tabbed IA, pubkey/npub/DID switcher, in-popup export/reset, and inline validation Nov 28, 2026
@jjohare
jjohare merged commit dc76d46 into main Nov 28, 2026
2 checks passed
@jjohare
jjohare deleted the ui/popup-overhaul branch November 28, 2026 20:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant