Skip to content

bearstart: port the native shell's branded start page into the Gecko build#79

Merged
mdheller merged 1 commit into
mainfrom
bearstart-newtab
Jul 23, 2026
Merged

bearstart: port the native shell's branded start page into the Gecko build#79
mdheller merged 1 commit into
mainfrom
bearstart-newtab

Conversation

@mdheller

Copy link
Copy Markdown
Contributor

Closes the identity gap: the WKWebView shim opened on a branded page (bear wordmark, trust pills, sovereign search, shortcut tiles, green tokens) while the production Gecko build opened on an anonymous gutted about:newtab. This ports that page into the real build as new-tab + homepage on all three platforms.

Mechanism

  • Page + self-hosted DM Sans (variable woff2, zero network) live in settings/start/; bearbrowser-patches.py packages them into browser omni.ja at browser/bearstart/ via FINAL_TARGET_FILES — the proven bearblocker mechanism, so resource:///bearstart/bearbrowser-start.html resolves identically everywhere with no package-manifest entries.
  • New tab: there is no pref for the new-tab URL in modern Firefox — the supported mechanism is AboutNewTab.newTabURL from privileged autoconfig JS. Appended to the generated bearbrowser.cfg on Linux/Windows (overlay script); injected as a minimal cfg post-package on macOS (which doesn't emit the cfg — see the nightly-dmg manifest-relax step). Needs general.config.sandbox_enabled=false; the cfg is our own baked-in file, same trust level as the binary (LibreWolf ships identically). Override is try/caught so it can never break startup.
  • Homepage: fixed a dead pref — it pointed at the old native shell's absolute /Applications file path (macOS-only, no longer exists). Now the resource URL. Also removed browser.newtab.url, which Firefox deleted years ago.
  • Search: sovereign endpoints only, straight from the shim — search-api JSON rendered inline with a provenance receipt line, SearXNG HTML fallback, URL-vs-query detection.

Verification

Not buildable in PR CI (nightly lanes trigger on main / dispatch). After merge: dispatch nightly-linux or nightly-dmg and check (1) new tab opens the bear page, (2) homepage same, (3) DM Sans renders (no network fetch), (4) search falls back to searx.socioprophet.ai.

Known follow-up (found during this audit)

apply-bearbrowser-branding.sh only copies branding/bearbrowser.svg over librewolf SVGs — no .icns/.ico/.png generation — so the packaged apps still wear default LibreWolf/Firefox raster icons. Separate PR.

…build

The WKWebView shim had a real identity — bear wordmark, trust pills, sovereign
search with inline federated results, shortcut tiles, green token system. The
production Gecko build opened on an anonymous gutted about:newtab. This ports
that page in as the new-tab + home page on all three platforms:

- settings/start/bearbrowser-start.html: the page, with DM Sans self-hosted
  (variable woff2, zero network fetches) instead of the mac-only SF Pro stack
- packaged into browser omni.ja at browser/bearstart/ via FINAL_TARGET_FILES
  (same mechanism as bearblocker) -> resource:///bearstart/... works
  identically on Linux/Windows/macOS, no package-manifest entries needed
- new tab: AboutNewTab.newTabURL override via autoconfig JS (there is no pref
  for this) — appended to bearbrowser.cfg on Linux/Windows by the overlay
  script; injected as a minimal cfg post-package on macOS. Requires
  general.config.sandbox_enabled=false (our own baked-in file, same trust as
  the binary; LibreWolf ships its cfg the same way)
- homepage: fixed the DEAD pref value — it pointed at the old native shell's
  absolute /Applications path (macOS-only, gone). Now the resource URL. Also
  dropped browser.newtab.url, removed from Firefox years ago
- search: sovereign endpoints only (search-api JSON inline w/ receipt line,
  SearXNG HTML fallback), straight from the shim
@mdheller
mdheller merged commit c9c724c into main Jul 23, 2026
17 checks passed
@mdheller
mdheller deleted the bearstart-newtab branch July 23, 2026 12:17
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