Commit graph

119 commits

Author SHA1 Message Date
Local Dev
65e9a18f33 Theseus: https:// scheme for BCDN + segmented-toggle registry switcher
BCDN pages now show https:// in the address bar (was bare 'host/', briefly bns://).
Rationale: BCNR replaces DNS (name resolution), NOT HTTP. Under the hood the
delivery IS HTTPS for s3/ip/p records; the on-chain h record has no transport
at all, but https:// is the least-surprising display. BCDN/ICANN badge is the
sole source-of-truth for which registry served us; scheme stays a convention.

Registry chip is now a proper segmented control:
- Two-chip toggle (collision candidates): single rounded pill, split in half
  with a divider — active side filled (acid green for BCDN, blue for ICANN),
  inactive side transparent + clickable. Feels like an on/off toggle.
- Single chip (pure ICANN or BCNR-unique TLD): standalone pill in the
  registry's colour. No toggle affordance since there's no alternative.

Same acid-glow-green (#d6ff3d) and blue (#4c9eff) as the collision.html prompt
so the whole registry palette is consistent across chrome + interstitial.
2026-08-02 19:26:47 +02:00
Local Dev
b5712cbcc7 Theseus: 'unsaved changes' confirmation on programmatic navigation
Adds a will-prevent-unload handler on each tab. When a page has a beforeunload
handler that returns non-null (typical for forms with unsaved input, in-browser
editors with a dirty document, etc.), Electron would silently cancel any
navigation attempt. Now we show a native two-button dialog — 'Stay on page' /
'Leave anyway' — matching how mainstream browsers behave.

Works for both user-initiated navigation (link clicks) AND our own programmatic
loads (address bar, chip switcher, in-tab collision prompt). Answers the
operator's ask: 'only if there is unsaved work that can be lost, should a
warning appear' (2026-08-02).
2026-08-02 18:50:58 +02:00
Local Dev
d1aa46c8d2 Theseus: switcher is direct-load (no more soft-mode re-prompt); blur URL on submit
Chip switcher now bypasses navigateTab/loadBns entirely and calls loadURL
directly. Rationale: the user explicitly clicked a registry chip; that IS the
choice. Routing through navigateTab -> loadBns was reaching the collision
decision path in some races and could re-show the soft-mode 'Open with...'
prompt as an unwanted extra step. Direct load guarantees the switch is atomic.

Prov is updated inline using entries.get(host) for the BCDN case (source/records/
category), same shape loadBns would have produced. internalNav flag guards the
programmatic load from the will-navigate handler (redirect chains stay clean).

Also: address bar blurs on Enter so the tabs-event handler can update it to
the actual loaded URL (search keyword no longer sticks in the address bar
after search results load).
2026-08-02 18:40:38 +02:00
Local Dev
c2ba26877f Theseus: download tracker, search split, discover-more tier, UX polish
Bundle of UX + feature work. Split from packaging by intent so the diff
is reviewable; the next Theseus rebuild ships it.

Features
- Download tracker (new): session.on("will-download") → per-item state
  {id, filename, url, mime, total, received, state, savePath, startedAt}
  with updated/done event handlers. New downloadsPop WebContentsView
  loads downloads.html (new file) + downloads-preload.js (new file);
  panel positioned under a new #downloads toolbar button between search
  and Tor. Full IPC: downloads-get, toggle/close/resize-downloads,
  download-open/show/cancel/clear, downloads-clear-all. In-memory only —
  cross-session persistence is a future addition. Button badge shows
  active count + spin/done/err color.

- Search engines split by kind + tier:
  * kind: "search" | "llm" — separate headers in picker + settings
    ("Search with" / "Ask an AI"). Empty sections hidden.
  * tier: "catalog" | "extra" — Settings now has THREE panes behind the
    "+ Add search engine" button: curated catalog, wider discoverable
    bank filtered by a live search input, custom URL form.
  * DEFAULT_ENABLED unchanged (5 major engines).
  * Custom user-added engines carry tier="custom" (never in catalog/extra
    panes).

- 9 tier="extra" engines added (all non-login ?q=): Marginalia, Stract,
  Yep, Presearch, MetaGer, Qwant, Swisscows, Naver, Baidu. Same rot rule
  as LLMs: if one starts bouncing to a login gate, drop it.

Bug fixes
- Loadbar collapses to 0px when idle (was reserving a permanent 2px
  strip below the address bar). .loadbar {height:0} + .loadbar.on
  {height:2px} + 120ms transition.
- Native <select> popup theme sync via :root { color-scheme: dark } +
  @media(prefers-color-scheme: light). nativeTheme.themeSource already
  drives prefers-color-scheme, so the OS popup color follows the app
  theme automatically (fixed light popup on dark app / vice versa).
- .ctl layout flipped to flex-direction: row with flex-wrap so
  anti-fingerprint mode + value fields fit side-by-side.

Settings restructure
- General section: Startup group at the top ("Open previous windows and
  tabs" toggle), then Appearance below with three visual THEME CARDS
  (System / Light / Dark) — small mock-browser previews per theme,
  Firefox-style, active card gets a blue ring. System pipes through to
  nativeTheme.themeSource = "system".
- Search promoted to a top-level sidebar item between General and
  Naming. Search-engine controls moved out of General into Search.
- Search section: enabled list shows only enabled engines, grouped by
  kind, drag-reorder within a kind. "+ Add search engine" opens the
  catalog/extras/custom-URL panel.

Search engine catalog trims (already flagged in prior work)
- Removed ChatGPT / Claude / You.com (login-gated ?q=).
- Removed SearXNG (federated; every single-instance default rots).

Docs
- TheseusNavigator/PENDING.md and GOTCHAS.md born with this work
  (see the HANDOFF.md commit for the convention).
- PENDING.md's own "session: 2026-08-02:theseus-ux-polish" group will be
  emptied after this ship lands.

Preview harness
- _preview.html + _settings-preview.html stubs updated with kind + tier
  + downloads seed + tier="extra" samples so the preview reflects reality.
  Both files are gitignored — local only.

Coordination
- Parallel session's collision-policy work (chrome.html registry chips,
  popover switcher, Naming section, in-tab collision prompt) already
  landed in commits 256079d/42b340f/b0d6375/78dddda. This commit adds
  cleanly on top.
2026-08-02 15:31:47 +02:00
Local Dev
c3f771ac1c Theseus: fix collision blank-page + broken-BCDN-open bugs
Two related bugs both caused by the tab's will-navigate handler racing with
programmatic loads:

Bug A (chip switch BCDN -> ICANN shows blank page, BCDN-priority mode):
  fallbackToWeb() calls webContents.loadURL('https://<host>/') to serve the
  ICANN version. That fired will-navigate, which saw a dotted host, ran
  isBnsHost() -> true, and RE-INVOKED navigateTab() recursively — but the
  transient='icann' override had already been consumed, so the recursive call
  fell back to bcnr-first, canceling the fallback mid-flight. Tab showed blank
  because both loads collided.
  Fix: mark programmatic loads with t.internalNav so will-navigate skips them.

Bug B ('Ask each time' -> Open BCDN doesn't load):
  Was going through a meta-refresh from bns://collision-choose/ to
  bns://<host>/?_collision=bcnr. The meta-refresh bypassed navigateTab, so the
  chrome/prov state was never updated (address bar, badges stayed stale).
  Fix: will-navigate now catches bns://collision-choose/ FIRST, applies the
  remember flag, sets t.collisionOverride, and routes via navigateTab so
  chrome + prov update correctly.
  Removed the serveBns collision-choose handler + the ?_collision URL-param
  path in loadBns (both dead now that will-navigate handles it).

Result:
- Soft-mode 'Open with...' -> Open BCDN loads the BCDN site cleanly.
- Chip switcher flips BCDN <-> ICANN with no blank flash, correct chrome.
2026-08-02 15:21:21 +02:00
Local Dev
bf54c245b7 Theseus: in-tab collision prompt + toggle-style switcher + auto-switch
Three UX fixes based on operator feedback (2026-08-02):

1) 'Open with…' is now a FULL-PAGE in-tab interstitial (was a modal window).
   - loadBns loads collision.html via loadFile with query params instead of
     opening a BrowserWindow.
   - collision.html is navigation-based: buttons redirect to a special
     bns://collision-choose/?host=…&choice=…&remember=…&resturl=… URL.
   - serveBns handles that URL: persists remember=name/tld choice, then returns
     a meta-refresh to the real target. For BCDN it appends ?_collision=bcnr
     one-shot marker; for ICANN it redirects to https://<host><path>.
   - loadBns strips and honors the ?_collision one-shot marker so BCDN
     redirects don't re-trigger the prompt.
   - Old modal path (collisionPromptOnce) removed.

2) Auto-switch from the address-bar chip: clicking BCDN/ICANN chip sets a
   transient per-tab collisionOverride that loadBns consumes ONCE for this
   navigation only, bypassing the soft-mode prompt entirely.

3) Address-bar toggle: chips stay visible during 'resolving' (no more
   flash-and-reappear); active chip is colored (acid green for BCDN, blue for
   ICANN — matching collision.html's palette); inactive is greyed with border,
   clickable to switch. Feels like a proper toggle.

Settings > Registries copy: operator's exact wording adopted (title stays
'Registries', body uses 'BCNR-unique' term for TLDs that only exist on BCNR).
2026-08-02 14:43:31 +02:00
Local Dev
75e468ae39 Theseus UX polish: BCDN/BCNR terminology + soft-mode prompt redesign
Terminology (user-facing labels now match the product/registry distinction):
- BCDN = Bitcoin Cash Domain Names (the product — what you view)
- BCNR = Bitcoin Cash Name Registry (the on-chain system that backs it)
Chrome badge, popover, Settings section and 'Open with…' prompt all show BCDN
for a resolved name. BCNR stays only where the registry itself is the subject.

'Open with…' prompt (collision.html):
- Larger window (640x520, was 480x340)
- Radio-select pattern with explicit Open / Cancel buttons (was auto-fire on click)
- Enter = Open, Esc = Cancel, keyboard-first
- Body copy per operator spec (no product-name-in-parens; blockchain-generic)
- Card titles kept short: 'BCNR / BCDN' + 'ICANN / IANA'

Address-bar chip:
- Says BCDN (not BCNR) for on-chain names; ICANN for web
- Dropped the '·.tld' suffix — TLD is already in the URL bar
- On collision candidates: shows BOTH chips (BCDN | ICANN) with active
  highlighted; clicking the inactive one flips the tab (via collision-switch)

Settings section renamed Naming → Registries. Copy rewritten in the same
BCDN/BCNR frame; policy labels are now 'BCDN first' / 'ICANN first' / 'Ask
each time'.

Passive 'also on BCNR' bar copy updated to BCDN.

Verified: all preload/settings/main/chrome JS + HTML parse; no secrets in
staging.
2026-08-02 13:02:47 +02:00
Local Dev
d0db4ac495 Collision modes (BCNR/ICANN) + root TLD cert + VPS electrum-source indexer
Theseus soft-mode UX: 'Open with...' modal on collision, per-name/per-TLD
overrides, live per-tab switcher in the site-info popover, and a Naming section
in Settings for policy + reset. Backed by an on-chain root TLD certificate
(tlds.bch) that resolver-web.js discovers via fetchBcnrTlds()/isBcnrNativeTld().

Companion pieces:
- Argus/src/indexer/ELECTRUM-SOURCE-README.md — the featherweight VPS variant
  (no BCHN node, no Fulcrum) now live as bns-indexer.service.
- Argus/DESIGN-root-tld-cert.md — clarified: NOT a governance workflow, just
  ordinary key management (single wallet MVP -> 2-of-3 multisig). List gates
  registration / surgical NRPT / soft-mode classifier — never resolution.
- ROADMAP-IDEAS.md — recorded SiaGit/GitHub.sia + user-friendly Sia UI ideas.

Full spec: Argus/DESIGN-collision-modes.md (already tracked).
2026-08-02 11:39:00 +02:00
Local Dev
73f3781825 Theseus: remove the non-functional "Add this site's search" (+) entry
Dropped the OpenSearch "+" item from the engine dropdown and the per-page
OpenSearch scan that fed it (it ran a fetch on every page load). Users add
engines via Settings instead.
2026-08-01 01:37:18 +02:00
Local Dev
48aa007591 Theseus: Firefox-style lock icon, LLM search engines, reliable favicons
- Address-bar security badge + popover lock redesigned to match Firefox's
  padlock (shackle + rounded body + keyhole).
- Added AI/LLM answer engines to the catalog: ChatGPT, Claude, Phind, You.com
  (Perplexity already present) — all accept a URL query. Off by default; enable
  in Settings.
- Favicons now load from DuckDuckGo's icon service (one privacy-respecting host,
  returns an icon for ANY domain) instead of guessing /favicon.ico per site,
  which failed for several engines and fell back to emoji. Verified loading.
2026-08-01 01:26:51 +02:00
Local Dev
e284864d3c Theseus: reorderable engine list + dropdown-or-type manual fingerprint fields
- Search engines can be reordered (▲/▼ per row); order persists in
  settings.engineOrder and drives the toolbar dropdown order.
- Manual anti-fingerprinting values are now dropdown-or-type (datalist):
  timezone (common IANA zones), language (common locales), and a city picker
  for location that fills exact lat/lon — each still accepts free typing.
2026-07-30 23:26:00 +02:00
Local Dev
69c2afca81 Theseus: media-device privacy fix + region/language pickers, AF under Privacy
- Privacy fix: enumerateDevices() leaked speaker (audiooutput) labels + device/
  group IDs even with camera/mic blocked. New "Hide media devices" (default on)
  blanks every device's label/deviceId/groupId and collapses to one per kind,
  matching Firefox — closes the WebRTC device-fingerprinting leak.
- Anti-fingerprinting moved into the Privacy section (own sidebar item removed).
- Location spoof: pick a world region (Europe/Asia/N&S America/Africa/Middle
  East/Australia) → representative coordinates, or Manual for exact lat/lon.
- Language spoof: pick from the top-10 world languages, or Manual for any locale.
2026-07-30 23:11:28 +02:00
Local Dev
0f823ba583 Theseus: Firefox-style search picker (favicons, catalog, scan)
- Custom engine dropdown as a floating overlay view (engine-picker.html) that
  renders REAL favicons per engine — a native <select> can't show images.
- Larger catalog (DuckDuckGo/Google/Brave/Bing/Startpage/Yandex/Ecosia/Mojeek/
  SearXNG/Wikipedia/Perplexity); Settings has a favicon checklist to choose
  which appear in the dropdown (enabledEngines), plus manual add/remove.
- OpenSearch "scan": pages advertising a search engine surface an
  "Add <site>'s search" entry in the dropdown.
- Toolbar search box now just a magnifier button that opens the dropdown
  (no per-engine icon in the bar).
2026-07-30 22:55:52 +02:00
Local Dev
ad34ad3bbe Theseus: per-engine symbols + light-theme cascade fix
- Each search engine shows a symbol in the toolbar dropdown, the placeholder,
  and Settings (🦆 DuckDuckGo, 🦁 Brave, 🔵 Google, 🔎 Bing, 🛡️ Startpage,
  🔴 Yandex); custom engines take an optional symbol (defaults to 🔍).
- Fix: light-theme @media blocks for settings/popover/home were placed before
  the base rules and lost the cascade (sidebar stayed dark) — moved them last.
2026-07-30 22:09:26 +02:00
Local Dev
2757cd8c64 Theseus: light/dark theme, redesigned search box, trimmed engines, WebRTC modes
- Light/dark/system theme (Settings > General) via nativeTheme.themeSource
  driving prefers-color-scheme across chrome, settings, popover, and home.
- Search box redesigned: a magnifier icon opens the engine dropdown, the rest
  is a wider typing field; styled to match the browser (was a raw <select>).
- Trimmed built-in engines to DuckDuckGo/Google/Brave/Bing/Startpage/Yandex;
  custom engines still add/remove via "Add / edit engines…".
- WebRTC: the "WebRTC Network Limiter" extension can't run in Electron
  (chrome.privacy API is unavailable), so its function is now a native
  4-mode WebRTC IP policy in Settings > Privacy.
- Address-bar placeholder: "Ask a search engine or enter web address".
2026-07-30 22:00:01 +02:00
Local Dev
01429990ea Theseus: Firefox-style security panel + search-engine picker
- Security popover redesigned to resemble Firefox's site-info panel:
  lock/shield hero, "Connection secure" status, host, plain-language
  subtitle, and a details grid; the overlay view auto-sizes to content.
- Search-engine picker returned to the toolbar with an "Add / edit engines…"
  entry that opens Settings; added Ecosia, Mojeek, Presearch.
- Custom search engines: add (name + URL template with %s) / remove in
  Settings > General; used by address-bar search.
- Address-bar placeholder: "Ask a search engine or enter web address".
2026-07-30 20:58:45 +02:00
Local Dev
b14aebeb85 Theseus: perf + loading UI, minimal chrome, sidebar settings
- Performance: cache the chain index (was rebuilt on every navigation) and
  warm it at startup — .bch pages open near-instantly after the first.
- Loading indicator: indeterminate bar under the toolbar, per-tab spinner,
  and reload⇄stop button (driven by did-start/stop-loading + BNS resolve).
- Chrome cleanup: removed the bottom status bar and the redundant search
  box; security padlock now always present at the front of the address bar;
  minimal ICANN/BCNR pill at the end; favorites bar shows only on new-tab.
- Search: added Yandex; engine picker moved into Settings > General.
- Settings redesigned with a left sidebar (General / Performance / Privacy /
  Anti-fingerprinting). Anti-fingerprinting now Show/Hide/Spoof/Manual for
  timezone, language, AND location (geolocation coords overridden in-page).
2026-07-30 19:29:32 +02:00
Local Dev
89c80a0103 Theseus navigator UI overhaul, BNS-only indexer, site restructure
Theseus Navigator:
- Firefox-style toolbar: SVG back/fwd/reload/home buttons
- security padlock badge in the address bar opens a floating site-info
  overlay VIEW (on top of the page, never pushes content down)
- Edge-style favorites bar (shown only on the new-tab/home page)
- search-engine picker (DuckDuckGo/Google/Bing/Brave/Startpage)
- Theseus logo moved right, opens Settings; native menu removed
- address bar doubles as search; bottom resolver status line

Argus:
- BNS-only indexer: an electrum endpoint over a bare BCHN node
  (watches just the beacon, caches txs so no txindex needed) + test
- registry lifecycle / portfolio / name-index modules

Site restructure (nav/apps/store/hermes/choose) + runbook notes.
2026-07-30 08:16:55 +02:00
Local Dev
7898e78ff4 Initial commit — Silent Mode baseline (2026-07-29)
Snapshot of the decentralized-web stack at the point of the resolver+Theseus
rebuild deploy. Includes:

- Argus (BNS engine + resolver daemon + Sia gateway)
- AriadneResolver (Windows Inno installer bundle + Android APK sources +
  Firefox extension)
- TheseusNavigator (Electron browser)
- site/ (silentmode.st content, deployed to Sia at bns/silentmode/)
- design docs, roadmap, protocol spec

Secrets excluded via .gitignore: Argus/sia-s3.json, Argus/wallets.json,
Argus/ca/*.key,*.crt. Build outputs, node_modules, and bundled runtimes
also excluded.

Shipped hashes on dl.silentmode.st at this commit:
  AriadneResolver-Setup-0.1.0.exe    5bcb216eef31ea28ed767e4134ab74bd5ac69dfbd365fd249e9e6938e55c986a
  TheseusNavigator-Setup-0.0.1.exe   7c735e88bad2da3347145adba3016c8f626a18b8422289c8c6ba471972e2952b
  TheseusNavigator-0.0.1-portable.exe 008fd84445babeabb401b2bca40ea9466b24b0e6d6c85104da7640c5c5c84521
  ariadne-v0.2.apk                   635c8f04d44ef855a8390b9eeddb8cd2d50622e81cc4e5004e8daffc1bb0425c
2026-07-29 13:54:34 +02:00