Bento, the office suite that fits in a file
TypeScript mit-licenseofficeoffice-365office-suiteoffice-toolsoffice365open-sourcepowerpointself-hostedsingle-page-appslidesslideshareslideshowslideshow-galleryslideshow-makerslideshows
The tree is home/, and the identifiers moved while they still could (#364)
nyblnet284f765b5175
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.ymlindex 5322683c..c286f9f9 100644--- a/.github/workflows/ci.yml+++ b/.github/workflows/ci.yml@@ -335,7 +335,7 @@ jobs:# disk, so one poisoned response persisted.run: node scripts/test-blobs.ts- - name: tray/ios bridge rig+ - name: home/ios bridge rig# The iOS host opens ANY self-contained HTML document and treats those# documents as mutually untrusted, so a page-supplied filename reaching# appendingPathComponent was an arbitrary write inside the container —@@ -351,10 +351,10 @@ jobs:# chrome reads by name. A hex value retyped into Swift is a value that can# disagree with the logo while looking almost right, which is the kind of# wrong nothing notices. This fails if any of it drifts.- run: node tray/assets/make-icons.mjs --check+ run: node home/assets/make-icons.mjs --check- - name: tray/ios index rig- # The iOS text extractor is a PORT of tray/webext's, and the two are held+ - name: home/ios index rig+ # The iOS text extractor is a PORT of home/webext's, and the two are held# together by nothing but agreement — so this diffs them, driving the# real library.js against the compiled Swift over generated edge cases# and every document in the tree. A divergence means a deck is findable@@ -364,7 +364,7 @@ jobs:# a Mac. That is the payoff for keeping UIKit out of that file.run: node scripts/test-tray-index.mjs- - name: tray/ios release verifier rig+ - name: home/ios release verifier rig# Starter decks are not bundled; a new document is FETCHED from the# signed release channel and written to disk as an executable page. The# signature and hash checks are what make that acceptable, so this proves@@ -394,7 +394,7 @@ jobs:run: node scripts/test-webext-background.ts- name: WebExtension bridge rig- # tray/webext decides, per save, whether to write in place or hand back+ # home/webext decides, per save, whether to write in place or hand back# to the browser's own picker. Wrong in the permissive direction it# overwrites the open document with no dialog — which it did once. The# decision is pure logic over an options bag, so it is checkable herediff --git a/.gitignore b/.gitignoreindex a6cb7ba5..13863e7c 100644--- a/.gitignore+++ b/.gitignore@@ -46,7 +46,7 @@ scripts/.cache/*.xcuserdatad/# tray: generated by xcodegen and by the slides build. The paths moved when-# tray/BentoTray/ was renamed to tray/ios/, which silently unignored them and+# tray/BentoTray/ was renamed to home/ios/, which silently unignored them and# let a broad `git add` sweep them into an unrelated PR. That happened twice —# an earlier ios/BentoHost/ copy carried a 587KB built shell in main until# 2026-07-27 — so these are matched ANYWHERE, not at a fixed path: a future@@ -54,7 +54,7 @@ scripts/.cache/**/*.xcodeproj/**/Resources/starter.bento.html-# tray/android: Gradle's own state, and the two files that hold local identity.+# home/android: Gradle's own state, and the two files that hold local identity.# Matched by FILENAME for the same reason as the secrets above — `local.properties`# carries an absolute SDK path and `keystore.properties` the release signing# passwords, and neither may become committable by moving a directory.@@ -62,8 +62,8 @@ local.propertieskeystore.properties.gradle/.kotlin/-tray/android/build/-tray/android/*/build/+home/android/build/+home/android/*/build/# per-session git worktrees (docs/PARALLEL-WORK.md §2.1). Inside the repo on# purpose: ~/.zshrc picks the personal gh account by directory, and /tmp getsdiff --git a/docs/DECISIONS.md b/docs/DECISIONS.mdindex 4a198779..e98cad74 100644--- a/docs/DECISIONS.md+++ b/docs/DECISIONS.md@@ -14,6 +14,41 @@ Decision. Why. Pointers.---+## 2026-08-24 — The tree moved to `home/`, and the identifiers moved with it++**Decision.** `tray/` is now `home/`, `applicationId` and+`PRODUCT_BUNDLE_IDENTIFIER` are `page.bento.home`, and the update channel is+`https://bento.page/releases/home/manifest.json`. This supersedes the scope+paragraph and the bundle-identifier bullet in the rename entry above.++**Why the earlier decision was right when it was made, and wrong to keep.** It+was written while `tray/ios` (#315) and the Android work were both open in+`tray/`; moving the tree under them would have turned two mergeable branches+into conflict resolution. That was a real cost and a correct call at the time.+Both landed, and the reason expired.++The bundle-identifier bullet expired differently. Its argument was explicitly+conditional — changing the id "creates a different one that cannot update the+installed copy". There was no installed copy, no App Store Connect record and no+Play listing. Those three facts are what made it free, and all three stop being+true at first publish. **This was the last moment the identifiers could move.**++**What did NOT move, and why the line is there.** Rename what the outside world+sees or what becomes permanent on publish; leave what is internal and guarded:++- **The IndexedDB name stays `bento-tray`** (`home/webext/src/db.js`).+ `scripts/test-webext-background.ts` asserts it — a deliberate guard against+ silently orphaning every stored grant. Nobody outside the extension ever sees+ it, so renaming it would have meant editing a gate to let a cosmetic change+ through.+- **`bento-tray://` (iOS) and `.bento-tray.invalid` (Android)** stay. They are+ per-document origins, settled in their own entries, and invisible.++**The cost, stated.** Every path reference moved: 18 files outside the tree, 35+inside it, plus the Kotlin package `page.bento.tray` → `page.bento.home` and the+`tray-icon`/`tray-logo`/`ic_tray_mark` assets. That churn is what the original+entry warned about, and it was the price of not carrying a dead name forever.+## 2026-08-25 — The tray hosts are called `bento/home`**Decision.** All three hosts are named **`bento/home`** — lowercase, with the@@ -33,16 +68,19 @@ is four independent attempts failing the same way, which is the signal that thepremise was wrong rather than the words: the front door does not need aqualifier, because it is not one thing among several.-**Scope: the PRODUCT is renamed, not the tree.** Directories stay `tray/ios`,-`tray/android`, `tray/webext`, and `tray/bridge.js` keeps its name. Renaming-paths would churn every import, every doc link and every open branch for no-reader's benefit — the name people see is not the name the repo files it under.+**Scope: the PRODUCT is renamed, not the tree.** ~~Directories stay `tray/ios`,+`tray/android`, `tray/webext`, and `tray/bridge.js` keeps its name.~~+**SUPERSEDED 2026-08-24 — see the entry below.** The reasoning held while+branches were open in `tray/`; once they had all landed and nothing was+published, the tree moved to `home/` and the identifiers went with it.**What must NOT change, on any host:**-- **The bundle identifier.** `page.bento.tray` on iOS, and its Android- counterpart. To the OS and the store it IS the app: changing it does not rename- the app, it creates a different one that cannot update the installed copy.+- ~~**The bundle identifier.** `page.bento.tray` on iOS, and its Android+ counterpart.~~ **SUPERSEDED 2026-08-24.** The argument was conditional on an+ installed copy existing — "creates a different one that cannot update the+ installed copy". There were none, and no store record, so it was still free.+ It is `page.bento.home` now, and this is the last moment that was possible.- **`PRODUCT_NAME` / `CFBundleName`** (iOS). They name the executable and thebundle, not the label. `CFBundleDisplayName` is the label, and it is the onlykey the rename touches.diff --git a/tray/README.md b/home/README.mdsimilarity index 96%rename from tray/README.mdrename to home/README.mdindex 234db172..8a56d6d1 100644--- a/tray/README.md+++ b/home/README.md@@ -3,7 +3,7 @@Thin native hosts that run **any self-contained HTML document** and let it**save itself in place**, on platforms where a browser will not.-Three of them, under `tray/<platform>/`:+Three of them, under `home/<platform>/`:| | what it hosts | why it exists ||---|---|---|@@ -16,7 +16,7 @@ Bento-specific — neither ever parses the document, both are couriers. Anysingle-file HTML app that saves itself through the File System Access API worksthe same way.-**The web-side half is ONE file, `tray/bridge.js`,** shared by iOS and Android.+**The web-side half is ONE file, `home/bridge.js`,** shared by iOS and Android.It polyfills the single call Bento tests for, and the interesting part of it isnot the transport but the `FileSystemWritableFileStream` semantics — whosecomments record a bug that wrote users' documents out as zero bytes. A second@@ -78,7 +78,7 @@ doubt, prompt.**Pinned by `scripts/test-savepurpose.ts`.-So `tray/bridge.js` polyfills that — over `UIDocument` on iOS, over the Storage+So `home/bridge.js` polyfills that — over `UIDocument` on iOS, over the StorageAccess Framework on Android, from the one shared file. Two consequences:- **No web-side changes at all.** Every in-place path (⌘S, autosave write-back,@@ -192,7 +192,7 @@ of this bridge did exactly that and prompted on every single save.A host that can do more than the bare contract says so on the page:```js-window.__bentoHost = { name: 'tray/webext', ops: ['claim', 'write', 'backup'] }+window.__bentoHost = { name: 'home/webext', ops: ['claim', 'write', 'backup'] }````kernel/src/save.ts hostCan(op)` reads it, and it is the ONLY thing the kernel@@ -301,10 +301,10 @@ Needs **full Xcode** (Command Line Tools alone is not enough) and XcodeGen:```shbrew install xcodegen-cd tray/ios && xcodegen && open BentoTray.xcodeproj+cd home/ios && xcodegen && open BentoTray.xcodeproj```-Source lives under `tray/<platform>/` — `tray/ios/` and `tray/webext/` today. The design below+Source lives under `home/<platform>/` — `home/ios/` and `home/webext/` today. The design below(the polyfill and its protocol) is platform-neutral; only the transport lookupand the native file layer are not.@@ -419,7 +419,7 @@ way to land a specific orientation for a measurement.`didImportDocumentAt` is **never called for the creation flow** on iOS 26. Thecreation handler fires and the file lands correctly, but the delegate callbackdoes not arrive — so an app that opens the editor from that callback silently-creates files and appears to do nothing. `tray/ios` therefore places new+creates files and appears to do nothing. `home/ios` therefore places newdocuments itself and hands the browser `.none` ("already in its finallocation"), which also puts collision naming under our control: the systemrenames `Untitled.bento.html` to `Untitled.bento 2.html`, reading `.bento.html`@@ -434,7 +434,7 @@ Still to do:Same thesis as iOS, and for the same reason: Chrome on Android does not ship theFile System Access API either, so a deck opened in a browser there can only ever-hand back downloaded copies. `tray/android/` is ~700 lines of Kotlin with one+hand back downloaded copies. `home/android/` is ~700 lines of Kotlin with onedependency, and it keeps both of the decisions the iOS host is built on — thedocument is served through an origin we control, and the app bundles no runtimefor rendering.@@ -443,7 +443,7 @@ for rendering.[savrum](https://github.com/savrum)**, which asked for native wrapper appsbefore either host existed and is the branch this landed on. The Gradle layout,the `keystore.properties` pattern and the device-picker ergonomics come from-there; so did `isElementFullscreenEnabled`, which `tray/ios` used until+there; so did `isElementFullscreenEnabled`, which `home/ios` used untilmeasurement sent it the other way. The architecture changed — a host thatbundles a deck and updates itself over the air is the thing tray exists not tobe — but the question it asked was the right one, and it was asked first.@@ -454,9 +454,9 @@ The two hosts are meant to behave identically from inside the document. Wherethey cannot, it is because the platform forces it — and that is written downhere rather than discovered later.-| behaviour | `tray/ios` | `tray/android` | |+| behaviour | `home/ios` | `home/android` | ||---|---|---|---|-| FSA polyfill | `tray/bridge.js` | `tray/bridge.js` | **one shared file** |+| FSA polyfill | `home/bridge.js` | `home/bridge.js` | **one shared file** || per-document origin | `bento-tray://<sha24>` custom scheme | `https://<sha24>.bento-tray.invalid`, intercepted | same || document served from memory, never parsed | ✓ | ✓ | same || bridge injected at document start | `WKUserScript(.atDocumentStart)` | `addDocumentStartJavaScript` | same |@@ -487,7 +487,7 @@ here rather than discovered later.| finding a document by its contents | ✓ search screen + Spotlight | ✓ search over a folder index | same |One gap left, named rather than quietly left out. (Search was the other, on-whichever host you read this from — `tray/ios` and `tray/android` landed it a day+whichever host you read this from — `home/ios` and `home/android` landed it a dayapart, from opposite directions, each believing the other still lacked it.)**The status bar.** iOS hides it on iPad because nothing else keeps the page off@@ -496,8 +496,8 @@ the whole screen there; the Android equivalent would be to hide it on tabletstablet target, and shipping an untested behaviour is worse than naming anuntested one.-**Search.** All three hosts have it now. `tray/webext` always did; `tray/ios` and-`tray/android` landed it a day apart, from opposite directions — which is why the+**Search.** All three hosts have it now. `home/webext` always did; `home/ios` and+`home/android` landed it a day apart, from opposite directions — which is why theparity table above briefly claimed the gap in both directions at once.A deck is findable by **a phrase on one of its slides** rather than only by what@@ -509,14 +509,14 @@ enforced rather than hoped for:persisted as a URI permission. Both hosts could previously open one file at atime and enumerate nothing.- **the extraction, ported per platform** — `BentoIndex.swift` and- `DocumentIndex.kt`, both from the reference in `tray/doc-index.mjs`: up to 40KB+ `DocumentIndex.kt`, both from the reference in `home/doc-index.mjs`: up to 40KBof prose per document pulled out of the `#bento-doc` block as string values,data URIs stripped first.-- **one shared corpus** — `tray/fixtures/`, 11 cases, run from each host's own+- **one shared corpus** — `home/fixtures/`, 11 cases, run from each host's ownrig (`node scripts/test-doc-index.mjs`, `./gradlew :app:testDebugUnitTest`).The guarantee is deliberately "cannot diverge SILENTLY" rather than "cannotdiverge", which is the weaker promise that fits string scanning — unlike- `tray/bridge.js`, shared outright because a divergence there wrote documents+ `home/bridge.js`, shared outright because a divergence there wrote documentsout as zero bytes.The shape is settled in `docs/DECISIONS.md` (2026-08-16): **native list UI on@@ -598,7 +598,7 @@ sdkmanager "platform-tools" "platforms;android-36" "build-tools;36.0.0"``````sh-cd tray/android && ./gradlew :app:assembleDebug+cd home/android && ./gradlew :app:assembleDebug````ANDROID_HOME` must point at the SDK (`/opt/homebrew/share/android-commandlinetools`@@ -612,15 +612,15 @@ The starter shell and `bridge.js` are staged into assets by the buildbecause a new deck self-updates through the normal signed channel.The launcher icon is **generated from the same mark as iOS**, not redrawn.-`tray/assets/tray-icon.svg` is the source for both; Android needs the rounded+`home/assets/home-icon.svg` is the source for both; Android needs the roundedrectangles re-expressed as path data because vector drawables have no `<rect>`,and doing that by hand produces four opaque `M…A…V…Z` strings nobody will everdiff against the SVG — so a change to the mark would land on iOS and silentlymiss Android.```sh-node tray/assets/make-icons.mjs # regenerate the Android drawables-node tray/assets/make-icons.mjs --check # fail if they drifted (for CI)+node home/assets/make-icons.mjs # regenerate the Android drawables+node home/assets/make-icons.mjs --check # fail if they drifted (for CI)```The tray is drawn at **56 units of the 108 canvas, not the full 72 safe zone**.@@ -631,7 +631,7 @@ off and the navy frame that makes the mark read was never drawn at all.### Document searchGrant a folder once and every Bento document inside it is indexed, so a deck is-findable by **a phrase on one of its slides**. This is what `tray/webext` has+findable by **a phrase on one of its slides**. This is what `home/webext` hasalways had and what neither native host did.- **The grant** is `ACTION_OPEN_DOCUMENT_TREE` plus a persistable permission —@@ -660,7 +660,7 @@ always had and what neither native host did.differently: iOS renders nothing at all — `UIDocumentBrowserViewController` asksthe SYSTEM to thumbnail the file, and the iOS thumbnailer draws the`[data-bento-preview]` block because it runs no JavaScript, which is exactly what-that block exists for. `tray/webext` sets `iframe.srcdoc`. Android has neither a+that block exists for. `home/webext` sets `iframe.srcdoc`. Android has neither asystem HTML thumbnailer nor a browser for a list, so it renders the block itself:**one offscreen WebView, at index time**, into a bitmap cached in `cacheDir`(which Android empties under storage pressure — right for something@@ -703,8 +703,8 @@ So "New" asks which app you want and fetches that app's current signed shell(`Releases.kt`), the same channel a document uses to update itself — which alsomeans a document created here is the version everyone else has, the same day.The shell is cached in `filesDir`, so only the first "New" of a given release-needs a connection. `tray/webext` already worked this way in principle;-`tray/ios` still bundles and should follow.+needs a connection. `home/webext` already worked this way in principle;+`home/ios` still bundles and should follow.This is the **one** request the host makes on its own account — no launch check,no telemetry. `docs/PLATFORM.md` §1 requires no network to open, edit, present or@@ -723,7 +723,7 @@ re-serve but cannot forge, which is what an origin or CDN compromise looks like:dash channel passes the signature AND the digest: every byte authentic, justnot what was asked for. Checked against the app the CALLER requested, neveragainst what the payload says about itself — and an ABSENT field must not read- as a match, which is the hole `tray/webext` had before PR #318.+ as a match, which is the hole `home/webext` had before PR #318.- **A rollback floor**, a per-app high-water mark. A stale but genuine manifestpasses everything, because every byte of it really was signed and really doesmatch; it just hands over an older release. `kernel/src/update.ts` refuses to@@ -762,7 +762,7 @@ Two traps worth keeping:### Grid or list, and a theme you can overrideThe documents screen offers both, with the choice remembered. **Grid is the-default**, matching `tray/webext`, whose home screen has always been a grid of+default**, matching `home/webext`, whose home screen has always been a grid ofthumbnail cards — and it is what makes rendering thumbnails worth the trouble.iOS gets the same choice free from the system document browser.@@ -776,7 +776,7 @@ never enter a document.### Typography and the mark-The system font, deliberately, because that is what `slides` and `tray/webext`+The system font, deliberately, because that is what `slides` and `home/webext`both use (`-apple-system, …, Roboto, …`) — on Android the system font IS Roboto,so the chrome already matches the apps. The brand faces (`Fraunces`,`Instrument Sans`) belong to the marketing site, not to app chrome, and@@ -785,7 +785,7 @@ bundling them would cost a few hundred KB on a 122 KB app.What did transfer: the extension's `-.015em` heading tracking (Android's`letterSpacing` is already in ems, so the number moves across unchanged) and its`font-weight: 600` emphasis — real 600 from API 28, bold below it. The **mark**-in the header is generated from `tray/assets/tray-logo.svg` by the same script+in the header is generated from `home/assets/home-logo.svg` by the same scriptas the launcher icon, so the two cannot drift.### Material 3, dynamic colour, and adaptive layout@@ -829,9 +829,9 @@ because with a detail pane the grid is only part of the width.### What the hand-rolled theme established (superseded by Material, kept for the reasoning)The documents screen is ours to design — unlike iOS, where the root screen is-the system document browser — so it carries the same tokens as `tray/webext`+the system document browser — so it carries the same tokens as `home/webext`rather than framework defaults. Palette, radii and the button variants come-straight from `tray/webext/src/ui.css`, including its dark set: `values/` and+straight from `home/webext/src/ui.css`, including its dark set: `values/` and`values-night/` define the same colour names twice and the `-night` resourcequalifier switches them, so **dark mode needs no library and no runtime branch**.diff --git a/tray/android/app/build.gradle.kts b/home/android/app/build.gradle.ktssimilarity index 94%rename from tray/android/app/build.gradle.ktsrename to home/android/app/build.gradle.ktsindex bfd31eeb..f4262e64 100644--- a/tray/android/app/build.gradle.kts+++ b/home/android/app/build.gradle.kts@@ -15,12 +15,12 @@ val keystoreProps = Properties().apply {}/**- * Stages the one generated thing the app ships: `tray/bridge.js`, the File- * System Access polyfill SHARED with tray/ios. One copy of semantics whose+ * Stages the one generated thing the app ships: `home/bridge.js`, the File+ * System Access polyfill SHARED with home/ios. One copy of semantics whose* comments record a bug that wrote users' documents out as zero bytes; a second* copy would be a second chance to reintroduce it.*- * NO STARTER DECK. It used to stage one here, mirroring tray/ios — and that was+ * NO STARTER DECK. It used to stage one here, mirroring home/ios — and that was* wrong. Starter decks change often and there are three Bento apps with more* coming, so bundling means picking one arbitrarily or shipping several copies* of Bento inside the app, each stale from the moment it is built. Measured@@ -49,11 +49,11 @@ val stageAssets = tasks.register<StageTrayAssets>("stageTrayAssets") {}android {- namespace = "page.bento.tray"+ namespace = "page.bento.home"compileSdk = 36defaultConfig {- applicationId = "page.bento.tray"+ applicationId = "page.bento.home"// 26 covers ~98% of devices and is where the storage APIs this app is// built on behave consistently. Below it, ACTION_OPEN_DOCUMENT exists// but persistable write grants across providers do not.@@ -137,7 +137,7 @@ dependencies {// nothing from Material and would only inherit the inflation requirements.implementation("com.google.android.material:material:1.12.0")- // Test-only. The indexer is held to the shared corpus in tray/fixtures/ by+ // Test-only. The indexer is held to the shared corpus in home/fixtures/ by// a plain JVM test — no emulator, so there is no excuse not to run it.//// Gson rather than org.json: Android's org.json is a STUB in unit testsdiff --git a/tray/android/app/proguard-rules.pro b/home/android/app/proguard-rules.prosimilarity index 100%rename from tray/android/app/proguard-rules.prorename to home/android/app/proguard-rules.prodiff --git a/tray/android/app/src/main/AndroidManifest.xml b/home/android/app/src/main/AndroidManifest.xmlsimilarity index 100%rename from tray/android/app/src/main/AndroidManifest.xmlrename to home/android/app/src/main/AndroidManifest.xmldiff --git a/tray/android/app/src/main/java/page/bento/tray/DocumentIndex.kt b/home/android/app/src/main/java/page/bento/home/DocumentIndex.ktsimilarity index 97%rename from tray/android/app/src/main/java/page/bento/tray/DocumentIndex.ktrename to home/android/app/src/main/java/page/bento/home/DocumentIndex.ktindex 019398ed..6ba541f5 100644--- a/tray/android/app/src/main/java/page/bento/tray/DocumentIndex.kt+++ b/home/android/app/src/main/java/page/bento/home/DocumentIndex.kt@@ -1,13 +1,13 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.home/*** What this app can know about a file it did not write.*- * A PORT, not an original. `tray/doc-index.mjs` is the reference and- * `tray/fixtures/` is the corpus that holds this implementation to it —+ * A PORT, not an original. `home/doc-index.mjs` is the reference and+ * `home/fixtures/` is the corpus that holds this implementation to it —* `DocumentIndexTest` runs that same corpus on the JVM, so it needs no device* and no emulator. If the two ever disagree, this one is wrong.*diff --git a/tray/android/app/src/main/java/page/bento/tray/DocumentsActivity.kt b/home/android/app/src/main/java/page/bento/home/DocumentsActivity.ktsimilarity index 99%rename from tray/android/app/src/main/java/page/bento/tray/DocumentsActivity.ktrename to home/android/app/src/main/java/page/bento/home/DocumentsActivity.ktindex 43950f4f..8cd5e86d 100644--- a/tray/android/app/src/main/java/page/bento/tray/DocumentsActivity.kt+++ b/home/android/app/src/main/java/page/bento/home/DocumentsActivity.kt@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.homeimport android.app.UiModeManagerimport androidx.appcompat.app.AlertDialog@@ -186,7 +186,7 @@ class DocumentsActivity : AppCompatActivity() {* The wordmark, written the way every other Bento surface writes it.** `bento` + a PEACH slash + the app: lowercase, one weight, the slash the- * only thing carrying colour. `tray/webext` does it as+ * only thing carrying colour. `home/webext` does it as* `<b>bento<i>/</i>home</b>` and the slides editor as* `bento<span style="color:#FF9E8A">/</span>slides`; this is the same mark* in a SpannableString.@@ -507,7 +507,7 @@ class DocumentsActivity : AppCompatActivity() {gravity = Gravity.CENTER_VERTICAL}header.addView(ImageView(this).apply {- setImageResource(R.drawable.ic_tray_mark)+ setImageResource(R.drawable.ic_home_mark)// 24dp with a 9dp gap, matching the extension's `.brand`.layoutParams = LinearLayout.LayoutParams(dp(26), dp(26)).also { it.rightMargin = dp(9) }@@ -785,7 +785,7 @@ class DocumentsActivity : AppCompatActivity() {private fun dp(v: Int) = (v * resources.displayMetrics.density).toInt()/** A card: the thumbnail carries the row, which is the point of having- * rendered one. Matches how tray/webext presents a folder. */+ * rendered one. Matches how home/webext presents a folder. */private fun buildCard(parent: ViewGroup): ViewGroup {// GridView cells size to content, so a card's thumbnail needs an// explicit height to hold 16:9.diff --git a/tray/android/app/src/main/java/page/bento/tray/EditorActivity.kt b/home/android/app/src/main/java/page/bento/home/EditorActivity.ktsimilarity index 99%rename from tray/android/app/src/main/java/page/bento/tray/EditorActivity.ktrename to home/android/app/src/main/java/page/bento/home/EditorActivity.ktindex 6438bf85..85d3fc02 100644--- a/tray/android/app/src/main/java/page/bento/tray/EditorActivity.kt+++ b/home/android/app/src/main/java/page/bento/home/EditorActivity.kt@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.homeimport android.app.Activityimport android.app.AlertDialog@@ -39,7 +39,7 @@ import java.security.MessageDigest* Hosts one open document in a WebView and bridges saving to the Storage Access* Framework.*- * This is the Android counterpart of `tray/ios/EditorViewController.swift`, and+ * This is the Android counterpart of `home/ios/EditorViewController.swift`, and* it keeps that file's two load-bearing decisions:** 1. The document is served through an ORIGIN WE CONTROL, never `file://`. A@@ -68,7 +68,7 @@ import java.security.MessageDigestclass EditorActivity : Activity() {companion object {- const val EXTRA_URI = "page.bento.tray.URI"+ const val EXTRA_URI = "page.bento.home.URI"private const val TAG = "BentoTray"private const val REQ_EXPORT = 1private const val REQ_FILE_CHOOSER = 2@@ -105,7 +105,7 @@ class EditorActivity : Activity() {** So this is checked rather than assumed, and when it is false the first save* prompts instead of writing. Silently failing a save is the worst outcome- * available; prompting costs a dialog. `tray/README.md` states the rule for+ * available; prompting costs a dialog. `home/README.md` states the rule for* the whole project: when in doubt, prompt.*/private var canWriteInPlace = false@@ -344,12 +344,12 @@ class EditorActivity : Activity() {* - **`<input type="file">` cannot open at all**, which is how images,* video, audio and fonts get into a deck.*- * `tray/ios` had the same hole (`WKUIDelegate` is required there for the+ * `home/ios` had the same hole (`WKUIDelegate` is required there for the* dialogs; WKWebView does handle file inputs itself) and was fixed in the* same change.** NOTE the omission: `onShowCustomView` is deliberately NOT implemented, so- * element fullscreen is declined — the same answer `tray/ios` gives, for the+ * element fullscreen is declined — the same answer `home/ios` gives, for the* same reasons. A page refused fullscreen falls back to filling its view,* which is the well-trodden mobile path, and the host has already handed it* the whole screen anyway.diff --git a/tray/android/app/src/main/java/page/bento/tray/Library.kt b/home/android/app/src/main/java/page/bento/home/Library.ktsimilarity index 99%rename from tray/android/app/src/main/java/page/bento/tray/Library.ktrename to home/android/app/src/main/java/page/bento/home/Library.ktindex 67470473..565a172e 100644--- a/tray/android/app/src/main/java/page/bento/tray/Library.kt+++ b/home/android/app/src/main/java/page/bento/home/Library.kt@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.homeimport android.content.ContentValuesimport android.content.Context@@ -18,7 +18,7 @@ import android.util.Log* `Recents` is a keyring — the documents you have opened. This is a LIBRARY: a* folder you grant once, walked and indexed, so a document is findable by a* phrase on one of its slides rather than only by what you happened to call the- * file. That is what `tray/webext` has had and neither native host did.+ * file. That is what `home/webext` has had and neither native host did.** The grant is `ACTION_OPEN_DOCUMENT_TREE` plus a persistable permission — the* Android analogue of the extension's `showDirectoryPicker` and of adiff --git a/tray/android/app/src/main/java/page/bento/tray/Recents.kt b/home/android/app/src/main/java/page/bento/home/Recents.ktsimilarity index 99%rename from tray/android/app/src/main/java/page/bento/tray/Recents.ktrename to home/android/app/src/main/java/page/bento/home/Recents.ktindex 82a9e048..7518c126 100644--- a/tray/android/app/src/main/java/page/bento/tray/Recents.kt+++ b/home/android/app/src/main/java/page/bento/home/Recents.kt@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.homeimport android.content.ContentResolverimport android.content.Contextdiff --git a/tray/android/app/src/main/java/page/bento/tray/Releases.kt b/home/android/app/src/main/java/page/bento/home/Releases.ktsimilarity index 98%rename from tray/android/app/src/main/java/page/bento/tray/Releases.ktrename to home/android/app/src/main/java/page/bento/home/Releases.ktindex 5f43b207..b28f5817 100644--- a/tray/android/app/src/main/java/page/bento/tray/Releases.kt+++ b/home/android/app/src/main/java/page/bento/home/Releases.kt@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.homeimport android.content.Contextimport android.util.Log@@ -36,7 +36,7 @@ import java.util.Base64* THIS IS THE ONE THING THE HOST FETCHES. The app makes no other network request* — no update check of its own, no telemetry. `docs/PLATFORM.md` §1 requires no* network to OPEN, EDIT, PRESENT or SAVE, and none of those touch this; creating- * a document from a template is a different act, and `tray/webext` draws the+ * a document from a template is a different act, and `home/webext` draws the* line in the same place. The result is cached, so only the first "New" of a* given release needs a connection.*@@ -45,14 +45,14 @@ import java.util.Base64* unverified download lets a network attacker choose what they create. Both* halves are checked, exactly as `kernel/src/update.ts` does it: the manifest's* ECDSA signature, and then the shell's sha256 as pinned by the signed payload.- * (`tray/webext`'s equivalent does neither — raised separately.)+ * (`home/webext`'s equivalent does neither — raised separately.)*/object Releases {private const val TAG = "BentoTray"/** The apps a new document can be. Mirrors `APPS` in- * `tray/webext/src/library.js`; adding one here is the whole integration,+ * `home/webext/src/library.js`; adding one here is the whole integration,* because nothing else in this app asks which Bento a document is. */data class App(val id: String, val label: String, val blurb: String) {val manifest get() = "https://bento.page/releases/$id/manifest.json"@@ -161,7 +161,7 @@ object Releases {// field is missing and `want` is never null, so the comparison already// refuses it — tidying this to `if (named != null && named != want)`// would silently turn a missing field into a pass, which is the hole- // tray/webext had.+ // home/webext had.val want = app.appIdval named = r.appif (named != want) {diff --git a/tray/android/app/src/main/java/page/bento/tray/Thumbnails.kt b/home/android/app/src/main/java/page/bento/home/Thumbnails.ktsimilarity index 99%rename from tray/android/app/src/main/java/page/bento/tray/Thumbnails.ktrename to home/android/app/src/main/java/page/bento/home/Thumbnails.ktindex b060fa06..2defb863 100644--- a/tray/android/app/src/main/java/page/bento/tray/Thumbnails.kt+++ b/home/android/app/src/main/java/page/bento/home/Thumbnails.kt@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.homeimport android.content.Contextimport android.graphics.Bitmap@@ -30,7 +30,7 @@ import java.security.MessageDigest* to thumbnail the `.bento.html`, and the iOS thumbnailer draws the embedded* `[data-bento-preview]` block because it runs no JavaScript. That block* exists precisely so file managers can do this (`kernel/src/preview.ts`).- * - **tray/webext** sets `iframe.srcdoc = preview`. It is a browser.+ * - **home/webext** sets `iframe.srcdoc = preview`. It is a browser.** Android has neither: no system HTML thumbnailer (`getDocumentThumbnail` asks* the provider, and the downloads provider has nothing for an HTML file), and adiff --git a/tray/android/app/src/main/res/drawable/bg_button_ghost.xml b/home/android/app/src/main/res/drawable/bg_button_ghost.xmlsimilarity index 100%rename from tray/android/app/src/main/res/drawable/bg_button_ghost.xmlrename to home/android/app/src/main/res/drawable/bg_button_ghost.xmldiff --git a/tray/android/app/src/main/res/drawable/bg_button_primary.xml b/home/android/app/src/main/res/drawable/bg_button_primary.xmlsimilarity index 100%rename from tray/android/app/src/main/res/drawable/bg_button_primary.xmlrename to home/android/app/src/main/res/drawable/bg_button_primary.xmldiff --git a/tray/android/app/src/main/res/drawable/bg_field.xml b/home/android/app/src/main/res/drawable/bg_field.xmlsimilarity index 100%rename from tray/android/app/src/main/res/drawable/bg_field.xmlrename to home/android/app/src/main/res/drawable/bg_field.xmldiff --git a/tray/android/app/src/main/res/drawable/bg_row.xml b/home/android/app/src/main/res/drawable/bg_row.xmlsimilarity index 100%rename from tray/android/app/src/main/res/drawable/bg_row.xmlrename to home/android/app/src/main/res/drawable/bg_row.xmldiff --git a/tray/android/app/src/main/res/drawable/bg_thumb.xml b/home/android/app/src/main/res/drawable/bg_thumb.xmlsimilarity index 100%rename from tray/android/app/src/main/res/drawable/bg_thumb.xmlrename to home/android/app/src/main/res/drawable/bg_thumb.xmldiff --git a/tray/android/app/src/main/res/drawable/ic_tray_mark.xml b/home/android/app/src/main/res/drawable/ic_home_mark.xmlsimilarity index 91%rename from tray/android/app/src/main/res/drawable/ic_tray_mark.xmlrename to home/android/app/src/main/res/drawable/ic_home_mark.xmlindex 0a8038f9..ed5ae5e0 100644--- a/tray/android/app/src/main/res/drawable/ic_tray_mark.xml+++ b/home/android/app/src/main/res/drawable/ic_home_mark.xml@@ -1,7 +1,7 @@<?xml version="1.0" encoding="utf-8"?><!--- GENERATED from tray/assets/tray-logo.svg by tray/assets/make-icons.mjs.- Do not edit: run `node tray/assets/make-icons.mjs` instead.+ GENERATED from home/assets/home-logo.svg by home/assets/make-icons.mjs.+ Do not edit: run `node home/assets/make-icons.mjs` instead.The bento/home mark, for use inside the app. Same source as the launchericon, so the two cannot drift apart.diff --git a/tray/android/app/src/main/res/drawable/ic_launcher_foreground.xml b/home/android/app/src/main/res/drawable/ic_launcher_foreground.xmlsimilarity index 92%rename from tray/android/app/src/main/res/drawable/ic_launcher_foreground.xmlrename to home/android/app/src/main/res/drawable/ic_launcher_foreground.xmlindex 5b158c52..1bb100b8 100644--- a/tray/android/app/src/main/res/drawable/ic_launcher_foreground.xml+++ b/home/android/app/src/main/res/drawable/ic_launcher_foreground.xml@@ -1,7 +1,7 @@<?xml version="1.0" encoding="utf-8"?><!--- GENERATED from tray/assets/tray-icon.svg by tray/assets/make-icons.mjs.- Do not edit: run `node tray/assets/make-icons.mjs` instead.+ GENERATED from home/assets/home-icon.svg by home/assets/make-icons.mjs.+ Do not edit: run `node home/assets/make-icons.mjs` instead.The navy frame is the BACKGROUND layer (@color/tray_navy) and the cream tray isthe foreground. That split is what an adaptive icon wants: the systemdiff --git a/tray/android/app/src/main/res/drawable/ic_launcher_monochrome.xml b/home/android/app/src/main/res/drawable/ic_launcher_monochrome.xmlsimilarity index 90%rename from tray/android/app/src/main/res/drawable/ic_launcher_monochrome.xmlrename to home/android/app/src/main/res/drawable/ic_launcher_monochrome.xmlindex 430998db..89f50880 100644--- a/tray/android/app/src/main/res/drawable/ic_launcher_monochrome.xml+++ b/home/android/app/src/main/res/drawable/ic_launcher_monochrome.xml@@ -1,7 +1,7 @@<?xml version="1.0" encoding="utf-8"?><!--- GENERATED from tray/assets/tray-icon.svg by tray/assets/make-icons.mjs.- Do not edit: run `node tray/assets/make-icons.mjs` instead.+ GENERATED from home/assets/home-icon.svg by home/assets/make-icons.mjs.+ Do not edit: run `node home/assets/make-icons.mjs` instead.The themed-icon layer (Android 13+). Colour cannot carry the mark when thesystem tints it, so the compartments are knocked out of the tray with evenOdddiff --git a/tray/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/home/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xmlsimilarity index 100%rename from tray/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xmlrename to home/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xmldiff --git a/tray/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml b/home/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xmlsimilarity index 100%rename from tray/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xmlrename to home/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xmldiff --git a/tray/android/app/src/main/res/values-night/colors.xml b/home/android/app/src/main/res/values-night/colors.xmlsimilarity index 93%rename from tray/android/app/src/main/res/values-night/colors.xmlrename to home/android/app/src/main/res/values-night/colors.xmlindex 27e2b5c5..e6faec82 100644--- a/tray/android/app/src/main/res/values-night/colors.xml+++ b/home/android/app/src/main/res/values-night/colors.xml@@ -1,7 +1,7 @@<?xml version="1.0" encoding="utf-8"?><!--The DARK palette, from the same source as the light one — the- prefers-color-scheme block in tray/webext/src/ui.css.+ prefers-color-scheme block in home/webext/src/ui.css.Note `accent` inverts: in light it is the navy wordmark colour on white, indark it becomes the near-white and `on_accent` becomes the dark ground. Adiff --git a/tray/android/app/src/main/res/values/colors.xml b/home/android/app/src/main/res/values/colors.xmlsimilarity index 94%rename from tray/android/app/src/main/res/values/colors.xmlrename to home/android/app/src/main/res/values/colors.xmlindex 50dbe6d7..462180bb 100644--- a/tray/android/app/src/main/res/values/colors.xml+++ b/home/android/app/src/main/res/values/colors.xml@@ -1,6 +1,6 @@<?xml version="1.0" encoding="utf-8"?><!--- The LIGHT palette. Names and values are taken from tray/webext/src/ui.css so+ The LIGHT palette. Names and values are taken from home/webext/src/ui.css sothe two surfaces we design ourselves actually look related — the extension isthe house style, and it is a cool near-white, not the cream of the logo. (Thelogo palette lives below and is used only by the launcher icon.)diff --git a/tray/android/app/src/main/res/values/dimens.xml b/home/android/app/src/main/res/values/dimens.xmlsimilarity index 87%rename from tray/android/app/src/main/res/values/dimens.xmlrename to home/android/app/src/main/res/values/dimens.xmlindex 400108c6..bae42c18 100644--- a/tray/android/app/src/main/res/values/dimens.xml+++ b/home/android/app/src/main/res/values/dimens.xml@@ -1,6 +1,6 @@<?xml version="1.0" encoding="utf-8"?><resources>- <!-- `the r token: 9px` in tray/webext/src/ui.css. Radii are a big part of why two+ <!-- `the r token: 9px` in home/webext/src/ui.css. Radii are a big part of why twosurfaces read as the same family, so it is shared rather than guessedper widget. --><dimen name="radius">9dp</dimen>diff --git a/tray/android/app/src/main/res/values/strings.xml b/home/android/app/src/main/res/values/strings.xmlsimilarity index 100%rename from tray/android/app/src/main/res/values/strings.xmlrename to home/android/app/src/main/res/values/strings.xmldiff --git a/tray/android/app/src/main/res/values/themes.xml b/home/android/app/src/main/res/values/themes.xmlsimilarity index 100%rename from tray/android/app/src/main/res/values/themes.xmlrename to home/android/app/src/main/res/values/themes.xmldiff --git a/tray/android/app/src/test/java/page/bento/tray/DocumentIndexTest.kt b/home/android/app/src/test/java/page/bento/home/DocumentIndexTest.ktsimilarity index 91%rename from tray/android/app/src/test/java/page/bento/tray/DocumentIndexTest.ktrename to home/android/app/src/test/java/page/bento/home/DocumentIndexTest.ktindex 8ff9cb85..dbd17bf1 100644--- a/tray/android/app/src/test/java/page/bento/tray/DocumentIndexTest.kt+++ b/home/android/app/src/test/java/page/bento/home/DocumentIndexTest.kt@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.homeimport com.google.gson.JsonObjectimport com.google.gson.JsonParser@@ -12,11 +12,11 @@ import java.io.Fileimport java.security.MessageDigest/**- * Holds the Kotlin indexer to the SHARED corpus in `tray/fixtures/`.+ * Holds the Kotlin indexer to the SHARED corpus in `home/fixtures/`.** This is the whole mechanism that keeps three implementations of one algorithm- * from drifting — see `tray/fixtures/README.md`. The reference is- * `tray/doc-index.mjs`; `node scripts/test-doc-index.mjs` runs it against the+ * from drifting — see `home/fixtures/README.md`. The reference is+ * `home/doc-index.mjs`; `node scripts/test-doc-index.mjs` runs it against the* same cases and the same answer key. If this test and that rig disagree, one* of the two hosts has diverged and the corpus says which.*@@ -33,9 +33,9 @@ class DocumentIndexTest {* working directory differs between an IDE run and a command-line one. */private val fixtures: File by lazy {var dir: File? = File(System.getProperty("user.dir") ?: ".").absoluteFile- while (dir != null && !File(dir, "tray/fixtures/expected.json").exists()) dir = dir.parentFile- requireNotNull(dir) { "could not locate tray/fixtures from ${System.getProperty("user.dir")}" }- File(dir, "tray/fixtures")+ while (dir != null && !File(dir, "home/fixtures/expected.json").exists()) dir = dir.parentFile+ requireNotNull(dir) { "could not locate home/fixtures from ${System.getProperty("user.dir")}" }+ File(dir, "home/fixtures")}private val expected: JsonObject by lazy {diff --git a/tray/android/app/src/test/java/page/bento/tray/ReleasesTest.kt b/home/android/app/src/test/java/page/bento/home/ReleasesTest.ktsimilarity index 97%rename from tray/android/app/src/test/java/page/bento/tray/ReleasesTest.ktrename to home/android/app/src/test/java/page/bento/home/ReleasesTest.ktindex 6cffcc23..452b7326 100644--- a/tray/android/app/src/test/java/page/bento/tray/ReleasesTest.kt+++ b/home/android/app/src/test/java/page/bento/home/ReleasesTest.kt@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-package page.bento.tray+package page.bento.homeimport org.junit.Assert.assertEqualsimport org.junit.Assert.assertNull@@ -14,8 +14,8 @@ import java.security.MessageDigest* The order in which a new document's shell is checked, which is the part that* cannot be exercised by hand.*- * Mirrors `tray/webext`'s two load-bearing cases (PR #318) and the reasoning- * `tray/ios` settled first (PR #315): a version high enough to lock the device+ * Mirrors `home/webext`'s two load-bearing cases (PR #318) and the reasoning+ * `home/ios` settled first (PR #315): a version high enough to lock the device* out must not raise the floor unless its BYTES were good, and re-fetching the* version already seen must be allowed. Both are cases where getting it* backwards produces a denial of service rather than a visible bug — the firstdiff --git a/tray/android/build.gradle.kts b/home/android/build.gradle.ktssimilarity index 100%rename from tray/android/build.gradle.ktsrename to home/android/build.gradle.ktsdiff --git a/tray/android/gradle.properties b/home/android/gradle.propertiessimilarity index 100%rename from tray/android/gradle.propertiesrename to home/android/gradle.propertiesdiff --git a/tray/android/gradle/wrapper/gradle-wrapper.jar b/home/android/gradle/wrapper/gradle-wrapper.jarsimilarity index 100%rename from tray/android/gradle/wrapper/gradle-wrapper.jarrename to home/android/gradle/wrapper/gradle-wrapper.jardiff --git a/tray/android/gradle/wrapper/gradle-wrapper.properties b/home/android/gradle/wrapper/gradle-wrapper.propertiessimilarity index 100%rename from tray/android/gradle/wrapper/gradle-wrapper.propertiesrename to home/android/gradle/wrapper/gradle-wrapper.propertiesdiff --git a/tray/android/gradlew b/home/android/gradlewsimilarity index 100%rename from tray/android/gradlewrename to home/android/gradlewdiff --git a/tray/android/gradlew.bat b/home/android/gradlew.batsimilarity index 100%rename from tray/android/gradlew.batrename to home/android/gradlew.batdiff --git a/tray/android/keystore.properties.example b/home/android/keystore.properties.examplesimilarity index 100%rename from tray/android/keystore.properties.examplerename to home/android/keystore.properties.examplediff --git a/tray/android/settings.gradle.kts b/home/android/settings.gradle.ktssimilarity index 100%rename from tray/android/settings.gradle.ktsrename to home/android/settings.gradle.ktsdiff --git a/tray/assets/tray-icon.svg b/home/assets/home-icon.svgsimilarity index 91%rename from tray/assets/tray-icon.svgrename to home/assets/home-icon.svgindex 5dba484b..76e8f4d3 100644--- a/tray/assets/tray-icon.svg+++ b/home/assets/home-icon.svg@@ -1,5 +1,5 @@<!--- bento/home iOS app icon — the mark from tray-logo.svg, full bleed.+ bento/home iOS app icon — the mark from home-logo.svg, full bleed.No corner radius: iOS applies its own squircle mask, and a rounded rect drawninside one shows as a seam along every edge.@@ -15,7 +15,7 @@(opaque, no alpha). After editing this file, re-export:chrome --headless --screenshot=<dest> --window-size=1024,1024 \- --default-background-color=00000000 tray-icon.svg+ --default-background-color=00000000 home-icon.svg--><svg xmlns="http://www.w3.org/2000/svg" width="1024" height="1024" viewBox="0 0 32 32"role="img" aria-label="bento home">diff --git a/tray/assets/tray-logo.svg b/home/assets/home-logo.svgsimilarity index 100%rename from tray/assets/tray-logo.svgrename to home/assets/home-logo.svgdiff --git a/tray/assets/make-icons.mjs b/home/assets/make-icons.mjssimilarity index 89%rename from tray/assets/make-icons.mjsrename to home/assets/make-icons.mjsindex 0e990ef2..2ce68df7 100644--- a/tray/assets/make-icons.mjs+++ b/home/assets/make-icons.mjs@@ -2,15 +2,15 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors//-// One mark, two platforms. `tray-icon.svg` is the SOURCE; this generates the+// One mark, two platforms. `home-icon.svg` is the SOURCE; this generates the// Android launcher vectors and the iOS asset catalog from it so the geometry and// the palette cannot drift.//-// node tray/assets/make-icons.mjs # write the generated assets-// node tray/assets/make-icons.mjs --check # fail if they are out of date (CI)+// node home/assets/make-icons.mjs # write the generated assets+// node home/assets/make-icons.mjs --check # fail if they are out of date (CI)//// The iOS APP ICON is still a hand-exported 1024x1024 PNG — see the comment at-// the top of tray-icon.svg for the command — because rasterising needs a browser+// the top of home-icon.svg for the command — because rasterising needs a browser// and this script has no dependencies on purpose. Everything else iOS needs is// vector or colour, so it is generated: the mark used by the launch screen and// the in-app chrome, and the four brand colours as named colour sets.@@ -49,7 +49,7 @@ const roundRect = (x, y, w, h, r) =>`V${f(y + r)} A${f(r)},${f(r)} 0 0 1 ${f(x + r)},${f(y)} Z`/** Pull the <rect>s out of a source SVG, in document order. */-function readMark(file = 'tray-icon.svg') {+function readMark(file = 'home-icon.svg') {const svg = readFileSync(join(here, file), 'utf8')const rects = [...svg.matchAll(/<rect\b([^>]*)\/>/g)].map((m) => {const attr = (name) => {@@ -66,11 +66,11 @@ function readMark(file = 'tray-icon.svg') {// compartments. Asserted rather than assumed — if the mark is redrawn with a// different structure this must be revisited, not silently mis-generated.if (rects.length !== 5) {- throw new Error(`tray-icon.svg: expected 5 rects (ground, tray, 3 compartments), found ${rects.length}`)+ throw new Error(`home-icon.svg: expected 5 rects (ground, tray, 3 compartments), found ${rects.length}`)}const [ground, tray, ...cells] = rectsif (ground.w !== 32 || ground.h !== 32) {- throw new Error('tray-icon.svg: first rect should be the full-bleed 32x32 ground')+ throw new Error('home-icon.svg: first rect should be the full-bleed 32x32 ground')}return { ground, tray, cells }}@@ -92,8 +92,8 @@ function build() {const header = (extra) => `<?xml version="1.0" encoding="utf-8"?><!--- GENERATED from tray/assets/tray-icon.svg by tray/assets/make-icons.mjs.- Do not edit: run \`node tray/assets/make-icons.mjs\` instead.+ GENERATED from home/assets/home-icon.svg by home/assets/make-icons.mjs.+ Do not edit: run \`node home/assets/make-icons.mjs\` instead.${extra}--><vector xmlns:android="http://schemas.android.com/apk/res/android"android:width="${CANVAS}dp"@@ -152,7 +152,7 @@ function ios({ ground, tray, cells }) {const asset = (obj) => JSON.stringify(obj, null, 2) + '\n'const info = { author: 'xcode', version: 1 }- const note = 'GENERATED from tray/assets/tray-icon.svg by tray/assets/make-icons.mjs.'+ const note = 'GENERATED from home/assets/home-icon.svg by home/assets/make-icons.mjs.'const mark =`<!-- ${note} Do not edit. -->\n` +`<svg xmlns="http://www.w3.org/2000/svg" width="${ground.w * 4}" height="${ground.h * 4}"\n` +@@ -206,7 +206,7 @@ function ios({ ground, tray, cells }) {}/**- * The mark as an in-app drawable, from tray-logo.svg — the rounded-ground+ * The mark as an in-app drawable, from home-logo.svg — the rounded-ground* version, unlike the launcher icon which is full-bleed because iOS and Android* both apply their own mask.*@@ -215,15 +215,15 @@ function ios({ ground, tray, cells }) {* proportions and needs none of the safe-zone arithmetic.*/function buildMark() {- const { ground, tray, cells } = readMark('tray-logo.svg')+ const { ground, tray, cells } = readMark('home-logo.svg')const shapes = [ground, tray, ...cells].map((r) => ({fill: r.fill,d: roundRect(r.x, r.y, r.w, r.h, r.r),}))return `<?xml version="1.0" encoding="utf-8"?><!--- GENERATED from tray/assets/tray-logo.svg by tray/assets/make-icons.mjs.- Do not edit: run \`node tray/assets/make-icons.mjs\` instead.+ GENERATED from home/assets/home-logo.svg by home/assets/make-icons.mjs.+ Do not edit: run \`node home/assets/make-icons.mjs\` instead.The bento/home mark, for use inside the app. Same source as the launchericon, so the two cannot drift apart.@@ -239,7 +239,7 @@ ${shapes.map((s) => ` <path\n android:fillColor="${s.fill}"\n a}const files = build()-files[join(ANDROID_RES, 'ic_tray_mark.xml')] = buildMark()+files[join(ANDROID_RES, 'ic_home_mark.xml')] = buildMark()const check = process.argv.includes('--check')let stale = 0@@ -248,17 +248,17 @@ for (const [path, content] of Object.entries(files)) {if (current === content) continuestale++if (check) {- console.error(`stale: ${path.replace(/.*\/tray\//, 'tray/')}`)+ console.error(`stale: ${path.replace(/.*\/home\//, 'home/')}`)} else {writeFileSync(path, content)- console.log(`wrote: ${path.replace(/.*\/tray\//, 'tray/')}`)+ console.log(`wrote: ${path.replace(/.*\/home\//, 'home/')}`)}}if (check && stale) {- console.error(`\n${stale} generated file(s) are out of date with tray-icon.svg —`)+ console.error(`\n${stale} generated file(s) are out of date with home-icon.svg —`)console.error('the Android launcher vectors and/or the iOS asset catalog.')- console.error('Run: node tray/assets/make-icons.mjs')+ console.error('Run: node home/assets/make-icons.mjs')process.exit(1)}-if (!stale) console.log('mark, launcher vectors and iOS assets all match tray-icon.svg')+if (!stale) console.log('mark, launcher vectors and iOS assets all match home-icon.svg')diff --git a/tray/bridge.js b/home/bridge.jssimilarity index 98%rename from tray/bridge.jsrename to home/bridge.jsindex b603fed5..1ebc37ff 100644--- a/tray/bridge.js+++ b/home/bridge.js@@ -1,7 +1,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors//-// The ENTIRE web-side surface of a bento/tray native host: a polyfill of the+// The ENTIRE web-side surface of a bento/home native host: a polyfill of the// one File System Access call Bento tests for. Injected at document start,// because capability is read during boot — inject it later and the editor has// already decided it cannot save.@@ -16,7 +16,7 @@// already routes through this one function. A bespoke `window.__bentoHost`// bridge would only have helped decks re-saved after it shipped.//-// ONE FILE, EVERY HOST. This used to live in tray/ios/Resources/ and iOS was+// ONE FILE, EVERY HOST. This used to live in home/ios/Resources/ and iOS was// the only caller. It is shared now because the interesting part of it is not// the transport — it is the FileSystemWritableFileStream semantics below, whose// comments record a bug that wrote users' documents out as zero bytes. A seconddiff --git a/tray/doc-index.mjs b/home/doc-index.mjssimilarity index 94%rename from tray/doc-index.mjsrename to home/doc-index.mjsindex 1eb81774..4c386791 100644--- a/tray/doc-index.mjs+++ b/home/doc-index.mjs@@ -6,22 +6,22 @@// Every bento/tray host has to answer the same questions about a file it did// not write: is this one of ours, what is it called, which app is it, is it// encrypted, what does its first page look like, and what words does it-// contain. `tray/webext` answers them in JavaScript because it lives in a-// browser; `tray/android` answers them in Kotlin and `tray/ios` in Swift,+// contain. `home/webext` answers them in JavaScript because it lives in a+// browser; `home/android` answers them in Kotlin and `home/ios` in Swift,// because their list UIs are native and must stay that way (docs/DECISIONS.md,// 2026-08-16 — putting the extension's HTML library in a WebView costs ~0.5s of// cold start, iOS its system document browser, and both their accessibility).//// Three implementations of one algorithm is a drift problem. This file is the-// reference, `tray/fixtures/` is the corpus, and `scripts/test-doc-index.mjs`+// reference, `home/fixtures/` is the corpus, and `scripts/test-doc-index.mjs`// checks this implementation against it — the native ports run the SAME corpus// from their own test rigs. The guarantee is deliberately "cannot diverge// SILENTLY" rather than "cannot diverge": a divergence here makes search find// less, which is visible and recoverable, unlike the writable-stream semantics-// in `tray/bridge.js` that are shared outright because a divergence there+// in `home/bridge.js` that are shared outright because a divergence there// wrote users' documents out as zero bytes.//-// Ported from tray/webext/src/library.js. If you change the algorithm, change+// Ported from home/webext/src/library.js. If you change the algorithm, change// it here, extend the corpus, and re-run every port./** The splice contract's marker — docs/PLATFORM.md §2, frozen because olddiff --git a/tray/fixtures/README.md b/home/fixtures/README.mdsimilarity index 83%rename from tray/fixtures/README.mdrename to home/fixtures/README.mdindex 7e91f9c8..728850d7 100644--- a/tray/fixtures/README.md+++ b/home/fixtures/README.md@@ -1,35 +1,35 @@-# tray/fixtures — the document-indexing contract+# home/fixtures — the document-indexing contractEvery bento/tray host answers the same questions about a file it did not write:is this one of ours, what is it called, which app is it, is it encrypted, whatdoes its first page look like, and what words does it contain.-Three hosts answer them in three languages — `tray/webext` in JavaScript,-`tray/android` in Kotlin, `tray/ios` in Swift — because their list UIs are+Three hosts answer them in three languages — `home/webext` in JavaScript,+`home/android` in Kotlin, `home/ios` in Swift — because their list UIs arenative and must stay that way (`docs/DECISIONS.md`, 2026-08-16: putting theextension's HTML library in a WebView costs ~0.5s of cold start, iOS its systemdocument browser, and both their accessibility).Three implementations of one algorithm is a drift problem. **This directory is-how they are held together.** `tray/doc-index.mjs` is the reference,+how they are held together.** `home/doc-index.mjs` is the reference,`cases/` is the corpus, `expected.json` is the answer key, and every host runsthe same corpus from its own test rig:| host | rig ||---|---|| reference (JS) | `node scripts/test-doc-index.mjs` |-| `tray/android` | `./gradlew :app:testDebugUnitTest` (JVM, no device needed) |-| `tray/ios` | not yet built |+| `home/android` | `./gradlew :app:testDebugUnitTest` (JVM, no device needed) |+| `home/ios` | not yet built |The guarantee is deliberately **"cannot diverge silently"**, not "cannotdiverge". A divergence here makes search find less, which is visible and-recoverable — unlike the writable-stream semantics in `tray/bridge.js`, which+recoverable — unlike the writable-stream semantics in `home/bridge.js`, whichare shared outright because a divergence there wrote users' documents out aszero bytes.## Changing the algorithm-Change `tray/doc-index.mjs`, extend `cases/`, regenerate `expected.json`, then+Change `home/doc-index.mjs`, extend `cases/`, regenerate `expected.json`, thenre-run **every** rig. A host that cannot match the corpus is the one that iswrong.diff --git a/tray/fixtures/cases/budget.html b/home/fixtures/cases/budget.htmlsimilarity index 100%rename from tray/fixtures/cases/budget.htmlrename to home/fixtures/cases/budget.htmldiff --git a/tray/fixtures/cases/data-uri.html b/home/fixtures/cases/data-uri.htmlsimilarity index 100%rename from tray/fixtures/cases/data-uri.htmlrename to home/fixtures/cases/data-uri.htmldiff --git a/tray/fixtures/cases/encrypted.html b/home/fixtures/cases/encrypted.htmlsimilarity index 100%rename from tray/fixtures/cases/encrypted.htmlrename to home/fixtures/cases/encrypted.htmldiff --git a/tray/fixtures/cases/escaped.html b/home/fixtures/cases/escaped.htmlsimilarity index 100%rename from tray/fixtures/cases/escaped.htmlrename to home/fixtures/cases/escaped.htmldiff --git a/tray/fixtures/cases/longvalue.html b/home/fixtures/cases/longvalue.htmlsimilarity index 100%rename from tray/fixtures/cases/longvalue.htmlrename to home/fixtures/cases/longvalue.htmldiff --git a/tray/fixtures/cases/markup.html b/home/fixtures/cases/markup.htmlsimilarity index 100%rename from tray/fixtures/cases/markup.htmlrename to home/fixtures/cases/markup.htmldiff --git a/tray/fixtures/cases/noise.html b/home/fixtures/cases/noise.htmlsimilarity index 100%rename from tray/fixtures/cases/noise.htmlrename to home/fixtures/cases/noise.htmldiff --git a/tray/fixtures/cases/nomarker.html b/home/fixtures/cases/nomarker.htmlsimilarity index 100%rename from tray/fixtures/cases/nomarker.htmlrename to home/fixtures/cases/nomarker.htmldiff --git a/tray/fixtures/cases/plain.html b/home/fixtures/cases/plain.htmlsimilarity index 100%rename from tray/fixtures/cases/plain.htmlrename to home/fixtures/cases/plain.htmldiff --git a/tray/fixtures/cases/preview.html b/home/fixtures/cases/preview.htmlsimilarity index 100%rename from tray/fixtures/cases/preview.htmlrename to home/fixtures/cases/preview.htmldiff --git a/tray/fixtures/cases/whitespace.html b/home/fixtures/cases/whitespace.htmlsimilarity index 100%rename from tray/fixtures/cases/whitespace.htmlrename to home/fixtures/cases/whitespace.htmldiff --git a/tray/fixtures/expected.json b/home/fixtures/expected.jsonsimilarity index 98%rename from tray/fixtures/expected.jsonrename to home/fixtures/expected.jsonindex 25e1dbb5..bc845204 100644--- a/tray/fixtures/expected.json+++ b/home/fixtures/expected.json@@ -1,5 +1,5 @@{- "note": "GENERATED by scripts/gen-doc-index-expected.mjs from tray/doc-index.mjs. See README.md here.",+ "note": "GENERATED by scripts/gen-doc-index-expected.mjs from home/doc-index.mjs. See README.md here.","textBudget": 40960,"sniffBytes": 65536,"headBytes": 307200,diff --git a/tray/ios/AppDelegate.swift b/home/ios/AppDelegate.swiftsimilarity index 100%rename from tray/ios/AppDelegate.swiftrename to home/ios/AppDelegate.swiftdiff --git a/tray/ios/Assets.xcassets/AppIcon.appiconset/Contents.json b/home/ios/Assets.xcassets/AppIcon.appiconset/Contents.jsonsimilarity index 100%rename from tray/ios/Assets.xcassets/AppIcon.appiconset/Contents.jsonrename to home/ios/Assets.xcassets/AppIcon.appiconset/Contents.jsondiff --git a/tray/ios/Assets.xcassets/AppIcon.appiconset/icon-1024.png b/home/ios/Assets.xcassets/AppIcon.appiconset/icon-1024.pngsimilarity index 100%rename from tray/ios/Assets.xcassets/AppIcon.appiconset/icon-1024.pngrename to home/ios/Assets.xcassets/AppIcon.appiconset/icon-1024.pngdiff --git a/tray/ios/Assets.xcassets/BentoCream.colorset/Contents.json b/home/ios/Assets.xcassets/BentoCream.colorset/Contents.jsonsimilarity index 100%rename from tray/ios/Assets.xcassets/BentoCream.colorset/Contents.jsonrename to home/ios/Assets.xcassets/BentoCream.colorset/Contents.jsondiff --git a/tray/ios/Assets.xcassets/BentoMark.imageset/Contents.json b/home/ios/Assets.xcassets/BentoMark.imageset/Contents.jsonsimilarity index 100%rename from tray/ios/Assets.xcassets/BentoMark.imageset/Contents.jsonrename to home/ios/Assets.xcassets/BentoMark.imageset/Contents.jsondiff --git a/tray/ios/Assets.xcassets/BentoMark.imageset/bento-mark.svg b/home/ios/Assets.xcassets/BentoMark.imageset/bento-mark.svgsimilarity index 89%rename from tray/ios/Assets.xcassets/BentoMark.imageset/bento-mark.svgrename to home/ios/Assets.xcassets/BentoMark.imageset/bento-mark.svgindex 716dcefc..c3d2f5ab 100644--- a/tray/ios/Assets.xcassets/BentoMark.imageset/bento-mark.svg+++ b/home/ios/Assets.xcassets/BentoMark.imageset/bento-mark.svg@@ -1,4 +1,4 @@-<!-- GENERATED from tray/assets/tray-icon.svg by tray/assets/make-icons.mjs. Do not edit. -->+<!-- GENERATED from home/assets/home-icon.svg by home/assets/make-icons.mjs. Do not edit. --><svg xmlns="http://www.w3.org/2000/svg" width="128" height="128"viewBox="0 0 32 32" role="img" aria-label="bento home"><rect width="32" height="32" fill="#16273E"/>diff --git a/tray/ios/Assets.xcassets/BentoNavy.colorset/Contents.json b/home/ios/Assets.xcassets/BentoNavy.colorset/Contents.jsonsimilarity index 100%rename from tray/ios/Assets.xcassets/BentoNavy.colorset/Contents.jsonrename to home/ios/Assets.xcassets/BentoNavy.colorset/Contents.jsondiff --git a/tray/ios/Assets.xcassets/BentoPeach.colorset/Contents.json b/home/ios/Assets.xcassets/BentoPeach.colorset/Contents.jsonsimilarity index 100%rename from tray/ios/Assets.xcassets/BentoPeach.colorset/Contents.jsonrename to home/ios/Assets.xcassets/BentoPeach.colorset/Contents.jsondiff --git a/tray/ios/Assets.xcassets/BentoSteel.colorset/Contents.json b/home/ios/Assets.xcassets/BentoSteel.colorset/Contents.jsonsimilarity index 100%rename from tray/ios/Assets.xcassets/BentoSteel.colorset/Contents.jsonrename to home/ios/Assets.xcassets/BentoSteel.colorset/Contents.jsondiff --git a/tray/ios/Assets.xcassets/Contents.json b/home/ios/Assets.xcassets/Contents.jsonsimilarity index 100%rename from tray/ios/Assets.xcassets/Contents.jsonrename to home/ios/Assets.xcassets/Contents.jsondiff --git a/tray/ios/BentoDocument.swift b/home/ios/BentoDocument.swiftsimilarity index 100%rename from tray/ios/BentoDocument.swiftrename to home/ios/BentoDocument.swiftdiff --git a/tray/ios/BentoIndex.swift b/home/ios/BentoIndex.swiftsimilarity index 99%rename from tray/ios/BentoIndex.swiftrename to home/ios/BentoIndex.swiftindex 90bc8e63..e851ba1a 100644--- a/tray/ios/BentoIndex.swift+++ b/home/ios/BentoIndex.swift@@ -5,7 +5,7 @@ import Foundation/// What a Bento document says about itself, read without parsing it.///-/// This is a port of `tray/webext/src/library.js` — `sniff`, the metadata half+/// This is a port of `home/webext/src/library.js` — `sniff`, the metadata half/// of `describe`, and `extractText`. The three hosts (extension, iOS, Android)/// each carry their own copy, pinned to each other by a shared fixture corpus/// rather than by shared code; the reasoning is in `docs/DECISIONS.md`@@ -110,8 +110,8 @@ enum BentoIndex {/// into a system-wide search index is that same leak with a longer reach.////// The shape — `isDocument` folded in, everything else nil when it is false- /// — is the SHARED contract in `tray/fixtures/README.md`, not this host's- /// choice. `tray/webext`'s `describe()` never faces a non-document because+ /// — is the SHARED contract in `home/fixtures/README.md`, not this host's+ /// choice. `home/webext`'s `describe()` never faces a non-document because/// its caller sniffs first; a port that answers all the questions in one/// call does, and has to say so.static func describe(head: String, sniffHead: String, whole: String?) -> Meta {diff --git a/tray/ios/Brand.swift b/home/ios/Brand.swiftsimilarity index 98%rename from tray/ios/Brand.swiftrename to home/ios/Brand.swiftindex 4fca9dc5..d025be2a 100644--- a/tray/ios/Brand.swift+++ b/home/ios/Brand.swift@@ -6,7 +6,7 @@ import UIKit/// The mark, the wordmark, and the four colours — in one place.////// Everything here reads from `Assets.xcassets`, which is GENERATED from-/// `tray/assets/tray-icon.svg` by `tray/assets/make-icons.mjs`. Nothing in this+/// `home/assets/home-icon.svg` by `home/assets/make-icons.mjs`. Nothing in this/// file contains a hex value, deliberately: a colour typed into Swift is a colour/// that can quietly disagree with the logo, and the app would simply be the wrong/// navy forever with nothing to notice it. `make-icons.mjs --check` fails if thediff --git a/tray/ios/DocumentBrowserViewController.swift b/home/ios/DocumentBrowserViewController.swiftsimilarity index 100%rename from tray/ios/DocumentBrowserViewController.swiftrename to home/ios/DocumentBrowserViewController.swiftdiff --git a/tray/ios/EditorViewController.swift b/home/ios/EditorViewController.swiftsimilarity index 100%rename from tray/ios/EditorViewController.swiftrename to home/ios/EditorViewController.swiftdiff --git a/tray/ios/FolderGrants.swift b/home/ios/FolderGrants.swiftsimilarity index 98%rename from tray/ios/FolderGrants.swiftrename to home/ios/FolderGrants.swiftindex a3b497ab..85f9ecdc 100644--- a/tray/ios/FolderGrants.swift+++ b/home/ios/FolderGrants.swift@@ -9,7 +9,7 @@ import Foundation/// cannot ENUMERATE — and enumeration is what searching a library means. iOS/// grants that through the document picker in folder mode, which returns a/// security-scoped directory URL; a bookmark makes it survive a relaunch. It is-/// the same capability as `showDirectoryPicker` in `tray/webext` and+/// the same capability as `showDirectoryPicker` in `home/webext` and/// `ACTION_OPEN_DOCUMENT_TREE` on Android, and it is the only new permission/// this feature needs.///diff --git a/tray/ios/Info.plist b/home/ios/Info.plistsimilarity index 98%rename from tray/ios/Info.plistrename to home/ios/Info.plistindex 9e0a3ad2..cc1781e1 100644--- a/tray/ios/Info.plist+++ b/home/ios/Info.plist@@ -37,7 +37,7 @@is guaranteed to be seen, spent saying nothing.Navy ground plus the mark, both named from Assets.xcassets so they are the- same values the icon is drawn from (generated by tray/assets/make-icons.mjs).+ same values the icon is drawn from (generated by home/assets/make-icons.mjs).The mark carries its own navy ground, which melts into the background here andleaves the cream tray floating — the same silhouette as the app icon the userjust tapped, which is the whole point of a launch screen.diff --git a/tray/ios/LibraryIndex.swift b/home/ios/LibraryIndex.swiftsimilarity index 98%rename from tray/ios/LibraryIndex.swiftrename to home/ios/LibraryIndex.swiftindex 61914291..93780ba4 100644--- a/tray/ios/LibraryIndex.swift+++ b/home/ios/LibraryIndex.swift@@ -30,7 +30,7 @@ struct SearchHit {/// The library: what is in the granted folders, and what those documents say.///-/// The walk, the budgets and the caching all mirror `tray/webext`'s+/// The walk, the budgets and the caching all mirror `home/webext`'s/// `listDocuments`/`describe`, because the point of this feature is that a deck/// is findable by a phrase on a slide on every host. `BentoIndex` is the shared/// half — the part that reads bytes and decides what the words are — and it is@@ -53,8 +53,8 @@ final class LibraryIndex {private let maxDocs = 300private let maxSniffs = 400- private let domain = "page.bento.tray.documents"- private let queue = DispatchQueue(label: "page.bento.tray.index", qos: .utility)+ private let domain = "page.bento.home.documents"+ private let queue = DispatchQueue(label: "page.bento.home.index", qos: .utility)private(set) var documents: [IndexedDocument] = []private var cache: [String: IndexedDocument] = [:]diff --git a/tray/ios/Releases.swift b/home/ios/Releases.swiftsimilarity index 98%rename from tray/ios/Releases.swiftrename to home/ios/Releases.swiftindex 459af821..46175798 100644--- a/tray/ios/Releases.swift+++ b/home/ios/Releases.swift@@ -22,7 +22,7 @@ import Foundation/// request — no update check of its own, no telemetry. `docs/PLATFORM.md` §1/// requires no network to OPEN, EDIT, PRESENT or SAVE, and none of those touch/// this; creating a document from a template is a different act, and-/// `tray/webext` draws the line in the same place. The result is cached, so only+/// `home/webext` draws the line in the same place. The result is cached, so only/// the first "New" of a given release needs a connection.////// VERIFICATION IS NOT OPTIONAL HERE. The bytes become an executable HTML@@ -31,7 +31,7 @@ import Foundation/// halves are checked, exactly as `kernel/src/update.ts` does it: the manifest's/// ECDSA signature, and then the shell's sha256 as pinned by the signed payload.///-/// Deliberately a mirror of `tray/android`'s `Releases.kt` — same apps, same+/// Deliberately a mirror of `home/android`'s `Releases.kt` — same apps, same/// key, same order of checks, same refusal messages — so the two hosts cannot/// answer differently. Two details there were learned the hard way and are/// inherited rather than rediscovered: the Accept header (see `fetch`), and the@@ -39,7 +39,7 @@ import Foundationenum Releases {/// The apps a new document can be. Mirrors `APPS` in- /// `tray/webext/src/library.js` and `Releases.kt`; adding one here is the+ /// `home/webext/src/library.js` and `Releases.kt`; adding one here is the/// whole integration, because nothing else in this app asks which Bento a/// document is.struct App: Equatable {@@ -80,12 +80,12 @@ enum Releases {/// is a release of the app we ASKED for.////// That last check is not redundant with the signature, and it was missing- /// here until `tray/webext`'s own verification (PR #318) tested for it. Both+ /// here until `home/webext`'s own verification (PR #318) tested for it. Both/// a `bento-slides` manifest and a `bento-dash` one are genuinely signed by/// the same maintainer key, so serving the former on the latter's channel/// passes the signature AND the hash: every byte is authentic, just not the/// thing that was requested. Only identity catches a swap between two real- /// releases. `tray/android` does not check this either — reported.+ /// releases. `home/android` does not check this either — reported.static func release(from raw: String, for app: App, notBefore floor: String? = nil) throws -> Release {let payload = try verify(raw)diff --git a/tray/ios/SceneDelegate.swift b/home/ios/SceneDelegate.swiftsimilarity index 100%rename from tray/ios/SceneDelegate.swiftrename to home/ios/SceneDelegate.swiftdiff --git a/tray/ios/SearchViewController.swift b/home/ios/SearchViewController.swiftsimilarity index 100%rename from tray/ios/SearchViewController.swiftrename to home/ios/SearchViewController.swiftdiff --git a/tray/ios/project.yml b/home/ios/project.ymlsimilarity index 91%rename from tray/ios/project.ymlrename to home/ios/project.ymlindex 26d9ba11..32286191 100644--- a/tray/ios/project.yml+++ b/home/ios/project.yml@@ -1,4 +1,4 @@-# XcodeGen spec — `brew install xcodegen && cd tray/ios && xcodegen` produces+# XcodeGen spec — `brew install xcodegen && cd home/ios && xcodegen` produces# BentoTray.xcodeproj. The project file is generated, never committed, so it# can't rot into a merge-conflict magnet the way .pbxproj does.name: BentoTray@@ -13,7 +13,7 @@ targets:sources:- path: .excludes: [project.yml]- # The File System Access polyfill is SHARED with tray/android — one copy+ # The File System Access polyfill is SHARED with home/android — one copy# of the semantics that once wrote documents out as zero bytes. It lands# flat in the bundle, so `Bundle.main.url(forResource: "bridge",# withExtension: "js")` finds it exactly as it did under Resources/.@@ -22,14 +22,14 @@ targets:# NO starter shell is staged into the bundle. It used to be, and it was the# single largest thing in the app — the same seed measured 81% of the Android# release APK. New documents come from the signed release channel instead- # (tray/ios/Releases.swift), which also means one created here is the version+ # (home/ios/Releases.swift), which also means one created here is the version# everyone else has rather than whatever was current on build day. There are# three apps now and more coming; bundling meant picking one or shipping# several copies of Bento inside the app.settings:base:INFOPLIST_FILE: Info.plist- PRODUCT_BUNDLE_IDENTIFIER: page.bento.tray+ PRODUCT_BUNDLE_IDENTIFIER: page.bento.homeTARGETED_DEVICE_FAMILY: "1,2" # iPhone and iPadSWIFT_VERSION: "5.0"# Signing. The SIMULATOR needs none of this — it signs ad-hoc, which isdiff --git a/tray/webext/README.md b/home/webext/README.mdsimilarity index 97%rename from tray/webext/README.mdrename to home/webext/README.mdindex 1239d9d6..e5218ca3 100644--- a/tray/webext/README.md+++ b/home/webext/README.md@@ -9,7 +9,7 @@ built from #213:| action | result ||---|---|-| ⌘S | **no dialog** — `[bento-tray] wrote Tray_Test.bento.html (898775 bytes) in place` |+| ⌘S | **no dialog** — `[bento/home] wrote Tray_Test.bento.html (898775 bytes) in place` || Save a copy… | prompts, as it must || Save read-only copy… | prompts, as it must || the working file afterwards | 898,775 chars, 17 slides, script tags 5/5 balanced, `readonly` unset |@@ -21,7 +21,7 @@ wrong and silently destroyed it.## Packaging```bash-node scripts/pack-webext.mjs # → dist/bento-tray-<version>.zip+node scripts/pack-webext.mjs # → dist/bento-home-<version>.zipnode scripts/pack-webext.mjs --check # validate only (CI runs this)```@@ -95,8 +95,8 @@ node scripts/pack-webext.mjsThat writes two things into `dist/`:-- `bento-tray-<version>.zip` — upload to both stores.-- `tray-release.json` — publish at `https://bento.page/releases/tray/manifest.json`.+- `bento-home-<version>.zip` — upload to both stores.+- `tray-release.json` — publish at `https://bento.page/releases/home/manifest.json`.The JSON carries the version, the release URL, and the **sha256 of the zip justbuilt**. It is emitted rather than hand-written because a copied hash goes stale@@ -171,13 +171,13 @@ notification opens the library instead: it is handled after an await.`icons/icon.svg` is the source of everything visual: the favicon for theextension's own pages, and the four PNGs Chrome takes for the toolbar action-icon. It carries a corner radius, unlike `tray/assets/tray-icon.svg`, which is+icon. It carries a corner radius, unlike `home/assets/home-icon.svg`, which issquare because iOS applies its own squircle mask.The PNGs are exports of it and must be regenerated rather than edited:```bash-cd tray/webext/icons+cd home/webext/iconsfor n in 16 32 48 128; doprintf '<!doctype html><meta charset="utf-8"><style>html,body{margin:0;background:transparent}svg{display:block;width:%dpx;height:%dpx}</style>' "$n" "$n" > /tmp/i.htmlsed -n '/<svg/,$p' icon.svg >> /tmp/i.html@@ -221,8 +221,8 @@ which is what `probe/directory.html` measured.Every save says which path it took:```-[bento-tray] wrote <file> (<n> bytes) in place-[bento-tray] not saving in place: <reason> — falling back to the browser picker+[bento/home] wrote <file> (<n> bytes) in place+[bento/home] not saving in place: <reason> — falling back to the browser picker```Safe-by-default only helps if the safe path explains itself. Without that second@@ -259,7 +259,7 @@ showSaveFilePicker({suggestedName}) -> { name, createWritable() }createWritable() -> { write(Blob|string), close() }```-Same three methods `tray/ios` implements over a `UIDocument` bridge. **No+Same three methods `home/ios` implements over a `UIDocument` bridge. **Noweb-side changes**, and every deck ever saved works, including files whoseembedded runtime predates this extension.@@ -344,7 +344,7 @@ rather than covering every local HTML file.1. **From a store:** install, then enable **Allow access to file URLs** on itscard in `chrome://extensions`.**Unpacked:** `chrome://extensions` → Developer mode → **Load unpacked** →- `tray/webext/`, then the same file-URL toggle.+ `home/webext/`, then the same file-URL toggle.2. Open its **options** and grant the folder your decks live in3. Double-click a `.bento.html` in that folder, edit something, press ⌘S@@ -404,4 +404,4 @@ cannot write arbitrary files either; that needs native messaging with a nativehelper. Firefox stays download-a-copy.**Safari** likewise has no FSA, and a Safari Web Extension ships inside a native-macOS app anyway — so Safari's answer is `tray/macos`, not this.+macOS app anyway — so Safari's answer is `home/macos`, not this.diff --git a/tray/webext/STORE.md b/home/webext/STORE.mdsimilarity index 100%rename from tray/webext/STORE.mdrename to home/webext/STORE.mddiff --git a/tray/webext/_locales/ar/messages.json b/home/webext/_locales/ar/messages.jsonsimilarity index 100%rename from tray/webext/_locales/ar/messages.jsonrename to home/webext/_locales/ar/messages.jsondiff --git a/tray/webext/_locales/bn/messages.json b/home/webext/_locales/bn/messages.jsonsimilarity index 100%rename from tray/webext/_locales/bn/messages.jsonrename to home/webext/_locales/bn/messages.jsondiff --git a/tray/webext/_locales/da/messages.json b/home/webext/_locales/da/messages.jsonsimilarity index 100%rename from tray/webext/_locales/da/messages.jsonrename to home/webext/_locales/da/messages.jsondiff --git a/tray/webext/_locales/de/messages.json b/home/webext/_locales/de/messages.jsonsimilarity index 100%rename from tray/webext/_locales/de/messages.jsonrename to home/webext/_locales/de/messages.jsondiff --git a/tray/webext/_locales/en/messages.json b/home/webext/_locales/en/messages.jsonsimilarity index 100%rename from tray/webext/_locales/en/messages.jsonrename to home/webext/_locales/en/messages.jsondiff --git a/tray/webext/_locales/es/messages.json b/home/webext/_locales/es/messages.jsonsimilarity index 100%rename from tray/webext/_locales/es/messages.jsonrename to home/webext/_locales/es/messages.jsondiff --git a/tray/webext/_locales/fa/messages.json b/home/webext/_locales/fa/messages.jsonsimilarity index 100%rename from tray/webext/_locales/fa/messages.jsonrename to home/webext/_locales/fa/messages.jsondiff --git a/tray/webext/_locales/fi/messages.json b/home/webext/_locales/fi/messages.jsonsimilarity index 100%rename from tray/webext/_locales/fi/messages.jsonrename to home/webext/_locales/fi/messages.jsondiff --git a/tray/webext/_locales/fil/messages.json b/home/webext/_locales/fil/messages.jsonsimilarity index 100%rename from tray/webext/_locales/fil/messages.jsonrename to home/webext/_locales/fil/messages.jsondiff --git a/tray/webext/_locales/fr/messages.json b/home/webext/_locales/fr/messages.jsonsimilarity index 100%rename from tray/webext/_locales/fr/messages.jsonrename to home/webext/_locales/fr/messages.jsondiff --git a/tray/webext/_locales/he/messages.json b/home/webext/_locales/he/messages.jsonsimilarity index 100%rename from tray/webext/_locales/he/messages.jsonrename to home/webext/_locales/he/messages.jsondiff --git a/tray/webext/_locales/hi/messages.json b/home/webext/_locales/hi/messages.jsonsimilarity index 100%rename from tray/webext/_locales/hi/messages.jsonrename to home/webext/_locales/hi/messages.jsondiff --git a/tray/webext/_locales/id/messages.json b/home/webext/_locales/id/messages.jsonsimilarity index 100%rename from tray/webext/_locales/id/messages.jsonrename to home/webext/_locales/id/messages.jsondiff --git a/tray/webext/_locales/it/messages.json b/home/webext/_locales/it/messages.jsonsimilarity index 100%rename from tray/webext/_locales/it/messages.jsonrename to home/webext/_locales/it/messages.jsondiff --git a/tray/webext/_locales/ja/messages.json b/home/webext/_locales/ja/messages.jsonsimilarity index 100%rename from tray/webext/_locales/ja/messages.jsonrename to home/webext/_locales/ja/messages.jsondiff --git a/tray/webext/_locales/ko/messages.json b/home/webext/_locales/ko/messages.jsonsimilarity index 100%rename from tray/webext/_locales/ko/messages.jsonrename to home/webext/_locales/ko/messages.jsondiff --git a/tray/webext/_locales/ms/messages.json b/home/webext/_locales/ms/messages.jsonsimilarity index 100%rename from tray/webext/_locales/ms/messages.jsonrename to home/webext/_locales/ms/messages.jsondiff --git a/tray/webext/_locales/nb/messages.json b/home/webext/_locales/nb/messages.jsonsimilarity index 100%rename from tray/webext/_locales/nb/messages.jsonrename to home/webext/_locales/nb/messages.jsondiff --git a/tray/webext/_locales/nl/messages.json b/home/webext/_locales/nl/messages.jsonsimilarity index 100%rename from tray/webext/_locales/nl/messages.jsonrename to home/webext/_locales/nl/messages.jsondiff --git a/tray/webext/_locales/pl/messages.json b/home/webext/_locales/pl/messages.jsonsimilarity index 100%rename from tray/webext/_locales/pl/messages.jsonrename to home/webext/_locales/pl/messages.jsondiff --git a/tray/webext/_locales/pt_BR/messages.json b/home/webext/_locales/pt_BR/messages.jsonsimilarity index 100%rename from tray/webext/_locales/pt_BR/messages.jsonrename to home/webext/_locales/pt_BR/messages.jsondiff --git a/tray/webext/_locales/ru/messages.json b/home/webext/_locales/ru/messages.jsonsimilarity index 100%rename from tray/webext/_locales/ru/messages.jsonrename to home/webext/_locales/ru/messages.jsondiff --git a/tray/webext/_locales/sv/messages.json b/home/webext/_locales/sv/messages.jsonsimilarity index 100%rename from tray/webext/_locales/sv/messages.jsonrename to home/webext/_locales/sv/messages.jsondiff --git a/tray/webext/_locales/th/messages.json b/home/webext/_locales/th/messages.jsonsimilarity index 100%rename from tray/webext/_locales/th/messages.jsonrename to home/webext/_locales/th/messages.jsondiff --git a/tray/webext/_locales/tr/messages.json b/home/webext/_locales/tr/messages.jsonsimilarity index 100%rename from tray/webext/_locales/tr/messages.jsonrename to home/webext/_locales/tr/messages.jsondiff --git a/tray/webext/_locales/uk/messages.json b/home/webext/_locales/uk/messages.jsonsimilarity index 100%rename from tray/webext/_locales/uk/messages.jsonrename to home/webext/_locales/uk/messages.jsondiff --git a/tray/webext/_locales/ur/messages.json b/home/webext/_locales/ur/messages.jsonsimilarity index 100%rename from tray/webext/_locales/ur/messages.jsonrename to home/webext/_locales/ur/messages.jsondiff --git a/tray/webext/_locales/vi/messages.json b/home/webext/_locales/vi/messages.jsonsimilarity index 100%rename from tray/webext/_locales/vi/messages.jsonrename to home/webext/_locales/vi/messages.jsondiff --git a/tray/webext/_locales/zh_CN/messages.json b/home/webext/_locales/zh_CN/messages.jsonsimilarity index 100%rename from tray/webext/_locales/zh_CN/messages.jsonrename to home/webext/_locales/zh_CN/messages.jsondiff --git a/tray/webext/_locales/zh_TW/messages.json b/home/webext/_locales/zh_TW/messages.jsonsimilarity index 100%rename from tray/webext/_locales/zh_TW/messages.jsonrename to home/webext/_locales/zh_TW/messages.jsondiff --git a/tray/webext/icons/icon-128.png b/home/webext/icons/icon-128.pngsimilarity index 100%rename from tray/webext/icons/icon-128.pngrename to home/webext/icons/icon-128.pngdiff --git a/tray/webext/icons/icon-16.png b/home/webext/icons/icon-16.pngsimilarity index 100%rename from tray/webext/icons/icon-16.pngrename to home/webext/icons/icon-16.pngdiff --git a/tray/webext/icons/icon-32.png b/home/webext/icons/icon-32.pngsimilarity index 100%rename from tray/webext/icons/icon-32.pngrename to home/webext/icons/icon-32.pngdiff --git a/tray/webext/icons/icon-48.png b/home/webext/icons/icon-48.pngsimilarity index 100%rename from tray/webext/icons/icon-48.pngrename to home/webext/icons/icon-48.pngdiff --git a/tray/webext/icons/icon.svg b/home/webext/icons/icon.svgsimilarity index 88%rename from tray/webext/icons/icon.svgrename to home/webext/icons/icon.svgindex efaaad18..54966337 100644--- a/tray/webext/icons/icon.svg+++ b/home/webext/icons/icon.svg@@ -1,12 +1,12 @@<!--- bento/home mark for the extension: the same art as tray/assets/tray-icon.svg+ bento/home mark for the extension: the same art as home/assets/home-icon.svgwith a corner radius. That file is deliberately square and full bleed becauseiOS applies its own squircle mask, and a radius drawn inside one seams alongevery edge. Chrome applies no mask, so a square reads as a mistake.THIS FILE IS THE SOURCE OF THE PNGs beside it. Chrome takes raster sizes forthe toolbar action icon, so those are exports of this and must be regenerated- rather than edited. The export command lives in tray/webext/README.md, not+ rather than edited. The export command lives in home/webext/README.md, nothere: it is full of command line flags, and an XML comment may not contain adouble hyphen. Putting it here made this file malformed, and every place themark appears rendered as a broken image.diff --git a/tray/webext/manifest.json b/home/webext/manifest.jsonsimilarity index 100%rename from tray/webext/manifest.jsonrename to home/webext/manifest.jsondiff --git a/tray/webext/probe/directory.html b/home/webext/probe/directory.htmlsimilarity index 100%rename from tray/webext/probe/directory.htmlrename to home/webext/probe/directory.htmldiff --git a/tray/webext/probe/parent.html b/home/webext/probe/parent.htmlsimilarity index 100%rename from tray/webext/probe/parent.htmlrename to home/webext/probe/parent.htmldiff --git a/tray/webext/probe/runner.html b/home/webext/probe/runner.htmlsimilarity index 100%rename from tray/webext/probe/runner.htmlrename to home/webext/probe/runner.htmldiff --git a/tray/webext/probe/sandbox.html b/home/webext/probe/sandbox.htmlsimilarity index 100%rename from tray/webext/probe/sandbox.htmlrename to home/webext/probe/sandbox.htmldiff --git a/tray/webext/src/background.js b/home/webext/src/background.jssimilarity index 98%rename from tray/webext/src/background.jsrename to home/webext/src/background.jsindex 4bc7987e..b7b7c626 100644--- a/tray/webext/src/background.js+++ b/home/webext/src/background.js@@ -368,7 +368,7 @@ if (typeof chrome !== 'undefined' && chrome.runtime?.onMessage) {chrome.runtime.onInstalled.addListener(() => {chrome.contextMenus?.removeAll(() => {chrome.contextMenus.create({- id: 'bento-tray-panel',+ id: 'bento-home-panel',title: t('ctxOpenPanel'),contexts: ['page'],documentUrlPatterns: ['file:///*'],@@ -376,7 +376,7 @@ if (typeof chrome !== 'undefined' && chrome.runtime?.onMessage) {})})chrome.contextMenus?.onClicked.addListener((info, tab) => {- if (info.menuItemId === 'bento-tray-panel' && tab?.windowId != null) {+ if (info.menuItemId === 'bento-home-panel' && tab?.windowId != null) {chrome.sidePanel.open({ windowId: tab.windowId })}})@@ -384,9 +384,9 @@ if (typeof chrome !== 'undefined' && chrome.runtime?.onMessage) {// The notification's only button, and clicking the notification body itself —// both mean "fix it", so both lead to the same place.chrome.notifications?.onButtonClicked?.addListener((id) => {- if (id === 'bento-tray-lapsed') void openReconnectUi()+ if (id === 'bento-home-lapsed') void openReconnectUi()})chrome.notifications?.onClicked?.addListener((id) => {- if (id === 'bento-tray-lapsed') void openReconnectUi()+ if (id === 'bento-home-lapsed') void openReconnectUi()})}diff --git a/tray/webext/src/db.js b/home/webext/src/db.jssimilarity index 100%rename from tray/webext/src/db.jsrename to home/webext/src/db.jsdiff --git a/tray/webext/src/home.html b/home/webext/src/home.htmlsimilarity index 100%rename from tray/webext/src/home.htmlrename to home/webext/src/home.htmldiff --git a/tray/webext/src/home.js b/home/webext/src/home.jssimilarity index 100%rename from tray/webext/src/home.jsrename to home/webext/src/home.jsdiff --git a/tray/webext/src/i18n.js b/home/webext/src/i18n.jssimilarity index 100%rename from tray/webext/src/i18n.jsrename to home/webext/src/i18n.jsdiff --git a/tray/webext/src/library.js b/home/webext/src/library.jssimilarity index 98%rename from tray/webext/src/library.jsrename to home/webext/src/library.jsindex d10c3221..ff012bdb 100644--- a/tray/webext/src/library.js+++ b/home/webext/src/library.js@@ -4,7 +4,7 @@// Your documents — the thing the extension is actually for.//// The popup used to be a permissions control panel: "local file access is on,-// folder: documents". True, and nobody wants it. tray/ios is a+// folder: documents". True, and nobody wants it. home/ios is a// UIDocumentBrowserViewController — you see your documents and tap one — and// that is the right shape here too. Permissions are plumbing and belong at the// bottom, speaking only when broken.@@ -269,11 +269,11 @@ function extractText(html) {}/**- * The `+` from tray/ios, which mints a new document from a seed.+ * The `+` from home/ios, which mints a new document from a seed.** iOS bundles that seed. We deliberately do not: bundling an app shell would* put a copy of Bento inside the extension, to drift from the real release and- * to be re-reviewed on every update — the same trap tray/ios avoided by letting+ * to be re-reviewed on every update — the same trap home/ios avoided by letting* documents carry their own runtime. Fetching the current signed release* instead means a document created here is the same version everyone else has,* the same day.@@ -319,7 +319,7 @@ export const APPS = [* `Untitled 2.bento.html`, never `Untitled.bento 2.html`. A double extension* defeats naive counters — including UIKit's, which reads `.bento.html` as the* name "Untitled.bento" plus extension "html" and inserts before the last- * extension only. tray/ios had to write its own for exactly this.+ * extension only. home/ios had to write its own for exactly this.*/export async function freeName(dir, wantedBase) {let base = wantedBase@@ -440,7 +440,7 @@ export async function newDocument(dir, wantedBase = 'Untitled', deps = {}) {const res = await net(app.manifest, { cache: 'no-store', headers: ACCEPT_BYTES })// Only Slides has a published channel today, so a 404 here is an EXPECTED// answer rather than a fault, and an HTTP status is the wrong way to say it.- // The wording matches tray/ios (and tray/android is following): the app list+ // The wording matches home/ios (and home/android is following): the app list// is aspirational on all three hosts, so all three phrase this identically.if (res.status === 404) throw new Error(`${app.name} has not been released yet`)if (!res.ok) throw new Error(`could not reach the ${app.name} release server (${res.status})`)@@ -464,7 +464,7 @@ export async function newDocument(dir, wantedBase = 'Untitled', deps = {}) {// Raised only NOW, after the bytes passed their digest. Raising it on a// merely-verified manifest would let one forged-but-unfetchable release lock// this browser out of every real release below it — turning a failed attack- // into a permanent one. (tray/ios hit this reasoning first, on PR #315.)+ // into a permanent one. (home/ios hit this reasoning first, on PR #315.)await raiseFloor(app, release.version, floor, deps)const { name, base } = await freeName(dir, wantedBase)diff --git a/tray/webext/src/page-bridge.js b/home/webext/src/page-bridge.jssimilarity index 97%rename from tray/webext/src/page-bridge.jsrename to home/webext/src/page-bridge.jsindex 1177ef29..ab0853f5 100644--- a/tray/webext/src/page-bridge.js+++ b/home/webext/src/page-bridge.js@@ -10,7 +10,7 @@// showSaveFilePicker({suggestedName}) -> { name, createWritable() }// createWritable() -> { write(Blob|string), close() }//-// That is tray's contract (tray/README.md), and it is why no web-side change is+// That is tray's contract (home/README.md), and it is why no web-side change is// needed: every in-place path (⌘S, autosave write-back, self-update) already// routes through that function, including in decks whose embedded runtime// predates this extension.@@ -145,7 +145,7 @@* directions where "are you at least version N" does not.*/Object.defineProperty(window, '__bentoHost', {- value: Object.freeze({ name: 'tray/webext', ops: Object.freeze(['claim', 'write', 'backup']) }),+ value: Object.freeze({ name: 'home/webext', ops: Object.freeze(['claim', 'write', 'backup']) }),writable: false, configurable: false, enumerable: false,})@@ -184,7 +184,7 @@const text = await blob.text()const res = await ask(op, { text, ...extra })if (!res?.ok) throw new DOMException(res?.reason || 'write failed', 'NotAllowedError')- console.info('[bento-tray]', op, res.name ?? name, `(${res.bytes} bytes)`)+ console.info('[bento/home]', op, res.name ?? name, `(${res.bytes} bytes)`)},}},@@ -221,7 +221,7 @@// installed — which cost a full diagnostic round trip. The common cause// is the folder grant lapsing after an extension reload, which the// options page can renew in one click.- console.info('[bento-tray] not saving in place:', claim?.reason ?? 'no answer from the extension',+ console.info('[bento/home] not saving in place:', claim?.reason ?? 'no answer from the extension','— falling back to the browser picker. Open the extension options to check the folder grant.')// The extension cannot reach this file — no folder granted, or the deck// lives outside it. The native picker is not a worse outcome, it isdiff --git a/tray/webext/src/panel.html b/home/webext/src/panel.htmlsimilarity index 100%rename from tray/webext/src/panel.htmlrename to home/webext/src/panel.htmldiff --git a/tray/webext/src/panel.js b/home/webext/src/panel.jssimilarity index 99%rename from tray/webext/src/panel.jsrename to home/webext/src/panel.jsindex 21923aab..c5e7be7d 100644--- a/tray/webext/src/panel.js+++ b/home/webext/src/panel.js@@ -4,7 +4,7 @@// The tray: your documents first, plumbing at the bottom.//// This was a permissions panel — "local file access is on, folder: documents" —-// which is true and useless. tray/ios is a document browser: you see your+// which is true and useless. home/ios is a document browser: you see your// documents and tap one. Same shape here. Permission state still has to be// visible, because both of its failures are silent, but it belongs in a strip// that stays quiet while things work.diff --git a/tray/webext/src/relay.js b/home/webext/src/relay.jssimilarity index 100%rename from tray/webext/src/relay.jsrename to home/webext/src/relay.jsdiff --git a/tray/webext/src/release.js b/home/webext/src/release.jssimilarity index 99%rename from tray/webext/src/release.jsrename to home/webext/src/release.jsindex 54cc4175..b0066b68 100644--- a/tray/webext/src/release.js+++ b/home/webext/src/release.js@@ -70,7 +70,7 @@ export const RELEASE_KEY = {// download. The digest check catching that IS the system working, but it is// better not to depend on the catch.//-// Found by tray/android, measured by tray/ios, reproduced here.+// Found by home/android, measured by home/ios, reproduced here.export const ACCEPT_BYTES = { Accept: '*/*' }const b64ToBytes = (b64) => Uint8Array.from(atob(b64), (c) => c.charCodeAt(0))diff --git a/tray/webext/src/route.js b/home/webext/src/route.jssimilarity index 100%rename from tray/webext/src/route.jsrename to home/webext/src/route.jsdiff --git a/tray/webext/src/status.js b/home/webext/src/status.jssimilarity index 99%rename from tray/webext/src/status.jsrename to home/webext/src/status.jsindex 33230d8f..1c5a054c 100644--- a/tray/webext/src/status.js+++ b/home/webext/src/status.js@@ -124,7 +124,7 @@ export async function notifyIfLapsed(stale) {if (seen) returnawait session?.set({ [NOTIFIED]: true })- await chrome.notifications.create('bento-tray-lapsed', {+ await chrome.notifications.create('bento-home-lapsed', {type: 'basic',iconUrl: chrome.runtime.getURL('icons/icon-128.png'),title: t('notifyLapsedTitle'),diff --git a/tray/webext/src/theme.js b/home/webext/src/theme.jssimilarity index 100%rename from tray/webext/src/theme.jsrename to home/webext/src/theme.jsdiff --git a/tray/webext/src/ui.css b/home/webext/src/ui.csssimilarity index 100%rename from tray/webext/src/ui.cssrename to home/webext/src/ui.cssdiff --git a/tray/webext/src/update.js b/home/webext/src/update.jssimilarity index 99%rename from tray/webext/src/update.jsrename to home/webext/src/update.jsindex 122f612d..1095dfd2 100644--- a/tray/webext/src/update.js+++ b/home/webext/src/update.js@@ -28,7 +28,7 @@import { GRANT, get, put } from './db.js'/** Mirrors the app's release channels: /releases/<app>/manifest.json */-const MANIFEST = 'https://bento.page/releases/tray/manifest.json'+const MANIFEST = 'https://bento.page/releases/home/manifest.json'/*** Where to ask. A dev override exists for the same reason the app has onediff --git a/kernel/src/app.ts b/kernel/src/app.tsindex a00f4c60..442b3b5f 100644--- a/kernel/src/app.ts+++ b/kernel/src/app.ts@@ -39,7 +39,7 @@ declare const __APP_VERSION__: string/*** Tell a HOST which Bento runtime this document carries.*- * A host that polyfills `showSaveFilePicker` (tray/webext) must know whether+ * A host that polyfills `showSaveFilePicker` (home/webext) must know whether* this document is old enough to predate `pickerIdFor` (#213). Before that,* every save — including "Save a copy…" — sent `bento-doc`, so acting on the id* there overwrites the open document. The host therefore refuses to write indiff --git a/kernel/src/returngate.ts b/kernel/src/returngate.tsindex ee12543e..93ed9f7f 100644--- a/kernel/src/returngate.ts+++ b/kernel/src/returngate.ts@@ -76,8 +76,8 @@ export const isWebOrigin = (): boolean => {*/export const HOST_AVAILABLE = {desktopExtension: true,- ios: false, // tray/ios — PR open, no release- android: false, // tray/android — on main via #87, no release+ ios: false, // home/ios — PR open, no release+ android: false, // home/android — on main via #87, no release} as constexport type Platform = 'desktop' | 'ios' | 'android' | 'unknown'diff --git a/kernel/src/save.ts b/kernel/src/save.tsindex b48f4b86..1c53568c 100644--- a/kernel/src/save.ts+++ b/kernel/src/save.ts@@ -544,7 +544,7 @@ export type SavePurpose = 'in-place' | 'copy' | 'share' | 'backup'* view-only copy.** The other reason is not incidental. A host that polyfills- * `showSaveFilePicker` (tray/ios over UIDocument, tray/webext over a directory+ * `showSaveFilePicker` (home/ios over UIDocument, home/webext over a directory* grant) sees ONLY the options bag. `saveFile(doc, forcePicker)` used to reach* this function with byte-identical arguments for ⌘S and for "Save a copy…",* so a host could not distinguish them — and one that guessed wrong overwrote@@ -559,7 +559,7 @@ export const pickerIdFor = (purpose: SavePurpose): string =>: 'bento-share'/**- * Is a HOST polyfilling the picker — tray/ios, tray/webext — rather than the+ * Is a HOST polyfilling the picker — home/ios, home/webext — rather than the* browser's own?** The kernel cannot infer this. `showSaveFilePicker` exists either way, and a@@ -609,9 +609,9 @@ async function pickHandle(// `suggestedFileName` has always produced `.bento.html`, but the picker// accepted `.html` — so an author who edited the name to "Q3" got// `Q3.html`, and a document named that is a second-class citizen- // everywhere the convention is what identifies us: tray/webext injects+ // everywhere the convention is what identifies us: home/webext injects// its save bridge on `file:///*.bento.html`, so such a file opens fine- // and then asks where to save, and tray/ios matches the same way.+ // and then asks where to save, and home/ios matches the same way.//// Bento was manufacturing the exception and then being asked to cope with// it. Accepting only the compound extension means the browser appends it@@ -763,7 +763,7 @@ export async function writeUpdatedFileAs(* With a host, the backup goes where it belongs — beside the original, inside* the folder already granted. The host derives the directory itself, from the* sender's own resolved path; `name` is only ever validated against that, never- * trusted as a path. See tray/webext/src/background.js `backup`.+ * trusted as a path. See home/webext/src/background.js `backup`.** Without a host this stays a download, because the alternative is a picker and* a picker is strictly worse than the status quo for the majority case.diff --git a/scripts/pack-webext.mjs b/scripts/pack-webext.mjsindex b9d52d48..63e64db8 100644--- a/scripts/pack-webext.mjs+++ b/scripts/pack-webext.mjs@@ -2,14 +2,14 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors//-// Builds the store-uploadable package for tray/webext.+// Builds the store-uploadable package for home/webext.//-// node scripts/pack-webext.mjs → dist/bento-tray-<version>.zip+// node scripts/pack-webext.mjs → dist/bento-home-<version>.zip// node scripts/pack-webext.mjs --check → validate only, write nothing (CI)//// WHY THIS EXISTS RATHER THAN `zip -r`.//-// **It refuses to ship the wrong files.** `tray/webext/` contains things that+// **It refuses to ship the wrong files.** `home/webext/` contains things that// must NOT reach a listing: `probe/` is four capability probes that open local// files and talk across origins — harmless to us, alarming to a reviewer, and// nothing to do with the product — and `README.md` is 200 lines of internal@@ -36,7 +36,7 @@ import { deflateRawSync, crc32 } from 'node:zlib'import { createHash } from 'node:crypto'const root = join(dirname(fileURLToPath(import.meta.url)), '..')-const SRC = join(root, 'tray/webext')+const SRC = join(root, 'home/webext')const OUT = join(root, 'dist')/** What ships. Anything in the tree and not matched here is an error. */@@ -73,7 +73,7 @@ const payload = []for (const rel of all) {if (EXCLUDE.some((r) => r.test(rel))) continueif (INCLUDE.some((r) => r.test(rel))) { payload.push(rel); continue }- fail(`unexpected file in tray/webext — add it to INCLUDE or EXCLUDE deliberately: ${rel}`)+ fail(`unexpected file in home/webext — add it to INCLUDE or EXCLUDE deliberately: ${rel}`)}// ---- the icons must have transparent corners -------------------------------@@ -308,7 +308,7 @@ function zip(files) {}// ---- report -----------------------------------------------------------------console.log(`tray/webext → ${payload.length} files`)+console.log(`home/webext → ${payload.length} files`)for (const p of payload) console.log(` ${p}`)if (problems.length) {@@ -324,7 +324,7 @@ if (process.argv.includes('--check')) {const bytes = zip(payload.map((name) => ({ name, data: readFileSync(join(SRC, name)) })))mkdirSync(OUT, { recursive: true })-const out = join(OUT, `bento-tray-${manifest.version}.zip`)+const out = join(OUT, `bento-home-${manifest.version}.zip`)writeFileSync(out, bytes)console.log(`\nwrote ${relative(root, out)} — ${(bytes.length / 1024).toFixed(1)}KB`)console.log('deterministic: the same tree always produces these bytes')@@ -348,5 +348,5 @@ const release = {}const relOut = join(OUT, 'tray-release.json')writeFileSync(relOut, `${JSON.stringify(release, null, 2)}\n`)-console.log(`wrote ${relative(root, relOut)} — publish at /releases/tray/manifest.json`)+console.log(`wrote ${relative(root, relOut)} — publish at /releases/home/manifest.json`)console.log(`sha256 ${digest}`)diff --git a/scripts/probe-origins.mjs b/scripts/probe-origins.mjsindex 0f3859d8..7e258023 100644--- a/scripts/probe-origins.mjs+++ b/scripts/probe-origins.mjs@@ -2,7 +2,7 @@// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors//-// Serves the tray/webext capability probes on TWO origins.+// Serves the home/webext capability probes on TWO origins.//// node scripts/probe-origins.mjs// → open http://localhost:5301/probe/parent.html in YOUR OWN browserdiff --git a/scripts/test-savepurpose.ts b/scripts/test-savepurpose.tsindex 93241300..36d17462 100644--- a/scripts/test-savepurpose.ts+++ b/scripts/test-savepurpose.ts@@ -5,8 +5,8 @@//// node scripts/test-savepurpose.ts//-// WHAT THIS PROVES. A HOST that polyfills `showSaveFilePicker` — tray/ios over-// UIDocument, tray/webext over a directory grant — sees only the options bag.+// WHAT THIS PROVES. A HOST that polyfills `showSaveFilePicker` — home/ios over+// UIDocument, home/webext over a directory grant — sees only the options bag.// It has to answer "am I being asked to overwrite the open document, or to make// a second file?" from that alone, and the two failure directions are not// symmetric: guessing "copy" costs a prompt, guessing "in-place" overwrites@@ -78,8 +78,8 @@ ok(!/writeUpdatedFileAs\(html, doc, \{ keepHandle: true, suggestedName: [^}]*\}\'the update no longer falls through to the default share purpose')// ------------------------------------------------- the convention is the id-// `.bento.html` is not decoration. tray/webext injects its save bridge on-// `file:///*.bento.html` and tray/ios matches the same way, so a document named+// `.bento.html` is not decoration. home/webext injects its save bridge on+// `file:///*.bento.html` and home/ios matches the same way, so a document named// `Q3.html` opens fine and then asks where to save — it is a second-class// citizen everywhere the name is what identifies us.//diff --git a/scripts/test-tray-bridge.ts b/scripts/test-tray-bridge.tsindex 917a392f..c5a63c98 100644--- a/scripts/test-tray-bridge.ts+++ b/scripts/test-tray-bridge.ts@@ -34,7 +34,7 @@ import { fileURLToPath } from 'node:url'// Walk up to the repo root rather than assuming a fixed depth, so the rig runs// from wherever it is invoked.-const REL = 'tray/ios/EditorViewController.swift'+const REL = 'home/ios/EditorViewController.swift'let SRC = ''for (const from of [dirname(fileURLToPath(import.meta.url)), process.cwd()]) {for (let d = from; d !== resolve(d, '..'); d = resolve(d, '..')) {diff --git a/scripts/test-tray-index.mjs b/scripts/test-tray-index.mjsindex c2f36073..1534d6e4 100644--- a/scripts/test-tray-index.mjs+++ b/scripts/test-tray-index.mjs@@ -9,7 +9,7 @@* own copy of the indexer and are held together by a shared fixture corpus* rather than by shared code. The guarantee that buys is not "cannot diverge"* but "cannot diverge SILENTLY" — which is only true if something actually- * looks. This is the thing that looks, for `tray/ios`.+ * looks. This is the thing that looks, for `home/ios`.** It drives the REAL `library.js`: `describe()` is exported and takes its cache* through injectable deps, so a fake file handle is enough to run the shipping@@ -20,7 +20,7 @@* `library.js` changed, both would be wrong together and the rig would stay* green. Importing it means the reference cannot move without this failing.*- * The Swift side is compiled straight from `tray/ios/BentoIndex.swift` with+ * The Swift side is compiled straight from `home/ios/BentoIndex.swift` with* `swiftc`, which is why that file is Foundation-only and has no UIKit in it.** Corpus: real documents found in the repo, plus generated edge cases covering@@ -200,7 +200,7 @@ function buildCorpus() {/* ── the reference, run as the extension runs it ──────────────────────────── */async function referenceFor(files) {- const lib = await import(pathToFileURL(join(ROOT, 'tray/webext/src/library.js')).href)+ const lib = await import(pathToFileURL(join(ROOT, 'home/webext/src/library.js')).href)const deps = { get: async () => null, put: async () => {} }const out = new Map()for (const path of files) {@@ -288,7 +288,7 @@ function buildSwift(dir) {const mainPath = join(dir, 'main.swift')writeFileSync(mainPath, MAIN_SWIFT, 'utf8')const bin = join(dir, 'indexer')- const src = join(ROOT, 'tray/ios/BentoIndex.swift')+ const src = join(ROOT, 'home/ios/BentoIndex.swift')try {execFileSync('swiftc', ['-O', '-o', bin, src, mainPath], { stdio: 'pipe' })} catch (e) {@@ -380,8 +380,8 @@ function compare(path, js, sw, failures, known) {if (!haveSwift()) {console.log('tray index: SKIPPED — no swiftc on this machine.')- console.log(' This rig is the only thing holding tray/ios/BentoIndex.swift to')- console.log(' tray/webext/src/library.js. Run it on a Mac before changing either.')+ console.log(' This rig is the only thing holding home/ios/BentoIndex.swift to')+ console.log(' home/webext/src/library.js. Run it on a Mac before changing either.')process.exit(0)}@@ -473,7 +473,7 @@ if (shared) {console.log(` shared corpus (tray/fixtures): ${shared.count} cases` +(shared.bad.length ? ` — ${shared.bad.length} DISAGREE` : ' — all agree'))} else {- console.log(' shared corpus (tray/fixtures): absent, skipped — arrives with tray/android')+ console.log(' shared corpus (tray/fixtures): absent, skipped — arrives with home/android')}if (failures.length || shared?.bad.length) {diff --git a/scripts/test-tray-releases.mjs b/scripts/test-tray-releases.mjsindex 79562c52..e09650b0 100644--- a/scripts/test-tray-releases.mjs+++ b/scripts/test-tray-releases.mjs@@ -5,7 +5,7 @@/*** Does the iOS release verifier REFUSE what it should?*- * `tray/ios/Releases.swift` fetches the shell for a new document from the signed+ * `home/ios/Releases.swift` fetches the shell for a new document from the signed* release channel, because starter decks are not bundled. Those bytes become an* executable HTML document on the reader's own disk that they will afterwards* trust — so an unverified download lets a network attacker choose what they@@ -95,7 +95,7 @@ const dir = mkdtempSync(join(tmpdir(), 'bento-releases-'))writeFileSync(join(dir, 'main.swift'), MAIN)const bin = join(dir, 'verifier')try {- execFileSync('swiftc', ['-O', '-o', bin, join(ROOT, 'tray/ios/Releases.swift'), join(dir, 'main.swift')],+ execFileSync('swiftc', ['-O', '-o', bin, join(ROOT, 'home/ios/Releases.swift'), join(dir, 'main.swift')],{ stdio: 'pipe' })} catch (e) {console.error('swiftc failed:\n' + (e.stderr?.toString() ?? e.message))@@ -167,7 +167,7 @@ const cases = [envelope: '<html><body>Sign in to continue</body></html>',},{- // Found by reading tray/webext's own verification tests (PR #318), which+ // Found by reading home/webext's own verification tests (PR #318), which// had this case when neither native host did. Both manifests are GENUINELY// signed by the maintainer, so the signature passes and the hash passes —// every byte is authentic, just not the thing that was asked for. Onlydiff --git a/scripts/test-webext-background.ts b/scripts/test-webext-background.tsindex 1be8139d..d0c8e46a 100644--- a/scripts/test-webext-background.ts+++ b/scripts/test-webext-background.ts@@ -1,7 +1,7 @@#!/usr/bin/env node// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-// tray/webext background rig.+// home/webext background rig.//// node scripts/test-webext-background.ts//@@ -25,7 +25,7 @@// claim at all, which is exactly what a service worker restart looks like.import { readFileSync } from 'node:fs'-import { pathFromSender, findByName, claim, write, resolve, backup, backupNameFor } from '../tray/webext/src/background.js'+import { pathFromSender, findByName, claim, write, resolve, backup, backupNameFor } from '../home/webext/src/background.js'let failures = 0let checks = 0@@ -420,7 +420,7 @@ const multiDeps = (...grants: Array<{ tree: Record<string, any>; perm?: string;// Source-level, because the two halves cannot be loaded into one realm to be// compared at runtime. A weak check on the real constants beats none.{- const read = (f: string) => readFileSync(new URL(`../tray/webext/src/${f}`, import.meta.url), 'utf8')+ const read = (f: string) => readFileSync(new URL(`../home/webext/src/${f}`, import.meta.url), 'utf8')/** Source with comments removed, for gates that must not match documentation* about the very thing they forbid. */const codeOf = (t: string) => t.replace(/\/\*[\s\S]*?\*\//g, '').replace(/^\s*\/\/.*$/gm, '')@@ -456,7 +456,7 @@ const multiDeps = (...grants: Array<{ tree: Record<string, any>; perm?: string;// silence: saves start prompting again with no indication why. Source-level,// because chrome.action does not exist here.{- const read = (f: string) => readFileSync(new URL(`../tray/webext/src/${f}`, import.meta.url), 'utf8')+ const read = (f: string) => readFileSync(new URL(`../home/webext/src/${f}`, import.meta.url), 'utf8')/** Source with comments stripped, for gates that must not match documentation* about the very thing they forbid. */const codeOf = (t: string) => t.replace(/\/\*[\s\S]*?\*\//g, '').replace(/^\s*\/\/.*$/gm, '')@@ -510,7 +510,7 @@ const multiDeps = (...grants: Array<{ tree: Record<string, any>; perm?: string;ok(!/\.openPopup\s*\(/.test(codeOf(st)), 'nothing still calls chrome.action.openPopup')ok(/home\.html/.test(st), 'the notification leads to the library, which carries the same repair')- const manifest = JSON.parse(readFileSync(new URL('../tray/webext/manifest.json', import.meta.url), 'utf8'))+ const manifest = JSON.parse(readFileSync(new URL('../home/webext/manifest.json', import.meta.url), 'utf8'))ok(manifest.permissions?.includes('notifications'),'the manifest asks for the notifications permission the code depends on')// default_popup and onClicked are mutually exclusive: declaring a popup meansdiff --git a/scripts/test-webext-bridge.ts b/scripts/test-webext-bridge.tsindex 2d67fb96..9b9e8c5f 100644--- a/scripts/test-webext-bridge.ts+++ b/scripts/test-webext-bridge.ts@@ -1,7 +1,7 @@#!/usr/bin/env node// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-// tray/webext page-bridge rig.+// home/webext page-bridge rig.//// node scripts/test-webext-bridge.ts//@@ -22,7 +22,7 @@ import { fileURLToPath } from 'node:url'import { createContext, runInContext } from 'node:vm'const root = join(dirname(fileURLToPath(import.meta.url)), '..')-const SRC = readFileSync(join(root, 'tray/webext/src/page-bridge.js'), 'utf8')+const SRC = readFileSync(join(root, 'home/webext/src/page-bridge.js'), 'utf8')let failures = 0let checks = 0diff --git a/scripts/test-webext-i18n.ts b/scripts/test-webext-i18n.tsindex e2f2c813..ddb54cf1 100644--- a/scripts/test-webext-i18n.ts+++ b/scripts/test-webext-i18n.ts@@ -1,7 +1,7 @@#!/usr/bin/env node// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-// tray/webext localisation rig.+// home/webext localisation rig.//// node scripts/test-webext-i18n.ts//@@ -24,7 +24,7 @@ import { fileURLToPath } from 'node:url'import { join, dirname } from 'node:path'const root = join(dirname(fileURLToPath(import.meta.url)), '..')-const SRC = join(root, 'tray/webext')+const SRC = join(root, 'home/webext')let failures = 0let checks = 0diff --git a/scripts/test-webext-library.ts b/scripts/test-webext-library.tsindex fba10176..743055a7 100644--- a/scripts/test-webext-library.ts+++ b/scripts/test-webext-library.ts@@ -1,7 +1,7 @@#!/usr/bin/env node// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-// tray/webext document-library rig.+// home/webext document-library rig.//// node scripts/test-webext-library.ts//@@ -21,7 +21,7 @@// hand-written fixtures shaped to pass.import { existsSync, readFileSync } from 'node:fs'-import { listDocuments, describe, newDocument, duplicate, rename, APPS } from '../tray/webext/src/library.js'+import { listDocuments, describe, newDocument, duplicate, rename, APPS } from '../home/webext/src/library.js'import { releaseSigner, sha256Hex } from './lib/release-sign.ts'let failures = 0@@ -372,7 +372,7 @@ const signedDeps = (net: any, extra: Record<string, unknown> = {}) =>const made = await newDocument(dir as any, 'Untitled', signedDeps(fakeNet()))// UIKit's own de-duplicator produces "Untitled.bento 2.html" here, because it// reads `.bento.html` as the name "Untitled.bento" plus extension "html" and- // counts before the LAST extension only. tray/ios had to write its own for+ // counts before the LAST extension only. home/ios had to write its own for// exactly this; so does this.ok(made.name === 'Untitled 2.bento.html',`a second document counts on the base name, not inside the extension (${made.name})`)diff --git a/scripts/test-webext-release.ts b/scripts/test-webext-release.tsindex 7863ebbc..9d13de23 100644--- a/scripts/test-webext-release.ts+++ b/scripts/test-webext-release.ts@@ -1,7 +1,7 @@#!/usr/bin/env node// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-// tray/webext release-trust rig.+// home/webext release-trust rig.//// node scripts/test-webext-release.ts//@@ -32,13 +32,13 @@// This matters more than it did. Starter shells are bundled in NO host as of// 2026-08-16 (they change too often, and there are three apps with more// coming), so fetch-and-verify is the ONLY way a new document gets created —-// here, in tray/android, and in tray/ios.+// here, in home/android, and in home/ios.import { readFileSync } from 'node:fs'import {RELEASE_KEY, verifySigned, verifyManifest, fetchPinned,-} from '../tray/webext/src/release.js'-import { newDocument, APPS } from '../tray/webext/src/library.js'+} from '../home/webext/src/release.js'+import { newDocument, APPS } from '../home/webext/src/library.js'import { releaseSigner, sha256Hex, realManifest } from './lib/release-sign.ts'let failures = 0@@ -87,7 +87,7 @@ const threw = async (fn: () => Promise<unknown>): Promise<string> => {// This one validates perfectly; it is simply not ours. It is what catches a// verifier that imported the wrong key, or one that would trust a key// travelling in the envelope alongside the signature — a verifier like that- // passes every tampering test ever written. (tray/ios's construction, from+ // passes every tampering test ever written. (home/ios's construction, from// PR #315; it is better than the seam-based version I had.)const real = JSON.parse(realManifest())const impostor = await releaseSigner()@@ -169,7 +169,7 @@ const payloadFor = (over: Record<string, unknown> = {}) => ({// this right, but only by construction — a later refactor to something like// `info.app && info.app !== appId` would turn a missing field into a pass,// and no other check would notice: signature and digest are both happy.- // (tray/ios raised this on PR #315; the same case, from the other direction.)+ // (home/ios raised this on PR #315; the same case, from the other direction.)const raw = await signer.envelope({version: '1.0.18', sha256: shellHash, url: 'https://bento.page/x.bento.html',})@@ -325,7 +325,7 @@ const channel = (manifestRaw: string, shell = SHELL, shellStatus = 200) => async// authentic, just last month's — which is exactly what survives an origin or// CDN compromise where the attacker can re-serve but cannot forge. A document// carries no version to be monotonic against, unlike the shell's own update, so-// the host has to remember. Semantics mirrored from tray/ios (PR #315).+// the host has to remember. Semantics mirrored from home/ios (PR #315).const floorStore = (initial: string | null = null) => {const box = { value: initial, writes: 0 }return {@@ -392,7 +392,7 @@ const floorStore = (initial: string | null = null) => {// A strange version string must be able to fail to RAISE the floor, never to// block a release. `Number('x')` is NaN and `NaN || 0` is 0, so it sorts as// zero rather than throwing — the same behaviour as kernel/src/update.ts and- // tray/ios, verified rather than assumed.+ // home/ios, verified rather than assumed.written.clear()const store = floorStore('1.0.x')const chan = channel(await signer.envelope(payloadFor({ version: '1.0.18' })))diff --git a/scripts/test-webext-route.ts b/scripts/test-webext-route.tsindex fb2afb51..e7c8dbce 100644--- a/scripts/test-webext-route.ts+++ b/scripts/test-webext-route.ts@@ -1,7 +1,7 @@#!/usr/bin/env node// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-// tray/webext route rig.+// home/webext route rig.//// node scripts/test-webext-route.ts//@@ -18,7 +18,7 @@// recorded at the wrong location, and every document in it opening something// else.-import { pathFromSender, locateIn, prefixFor } from '../tray/webext/src/route.js'+import { pathFromSender, locateIn, prefixFor } from '../home/webext/src/route.js'let failures = 0let checks = 0diff --git a/scripts/test-webext-update.ts b/scripts/test-webext-update.tsindex 384a986e..72f5ab55 100644--- a/scripts/test-webext-update.ts+++ b/scripts/test-webext-update.ts@@ -1,7 +1,7 @@#!/usr/bin/env node// SPDX-License-Identifier: MIT// Copyright (c) 2026 The Bento authors-// tray/webext update-notice rig.+// home/webext update-notice rig.//// node scripts/test-webext-update.ts//@@ -19,7 +19,7 @@// wrong way, a fetch that throws, an install type that cannot be read. None of// it breaks anything visible, which is exactly why it needs a rig.-import { compareVersions, isSelfManaged, checkForUpdate, autoCheckEnabled } from '../tray/webext/src/update.js'+import { compareVersions, isSelfManaged, checkForUpdate, autoCheckEnabled } from '../home/webext/src/update.js'let failures = 0let checks = 0