Console nav copy deck, Luna-reviewed, and its gate
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
4 files changed,
+303
−0
docs/superpowers/plans/2026-10-25-console-ux-nav-copy.md+84 −0docs/superpowers/plans/LUNA-COPY-BRIEF-CONSOLE-UX-NAV.md+78 −0docs/superpowers/plans/LUNA-COPY-REVIEW-CONSOLE-UX-NAV.md+12 −0internal/console/approved_nav_copy_test.go+129 −0
diff --git a/docs/superpowers/plans/2026-10-25-console-ux-nav-copy.md b/docs/superpowers/plans/2026-10-25-console-ux-nav-copy.md| new file mode 100644 |
| index 000000000..afd811637 |
| --- /dev/null |
| +++ b/docs/superpowers/plans/2026-10-25-console-ux-nav-copy.md |
| @@ -0,0 +1,84 @@ |
| +# Console navigation: copy deck |
| + |
| +Every new or changed user-facing string of the console navigation plan |
| +(`2026-10-25-console-ux-nav.md`, spec `2026-10-25-console-ux-perf-design.md`, |
| +Part 1). The gate is `internal/console/approved_nav_copy_test.go` |
| +(`TestNavCopyDeckIsApprovedAndApplied`). |
| + |
| +Approved 2026-10-25 by delegation: Luna pass (LUNA-COPY-REVIEW-CONSOLE-UX-NAV.md). |
| +Luna changed 4 rows (NAV-C16, C28, C38, C66), flagged none, and left 40 |
| +alone. Its answer to the Logs filter question: labels sit beside their |
| +controls. |
| + |
| +The rules: |
| + |
| +- One table, columns `| id | where | old | new | checked by | status |`. A row |
| + is one line. |
| +- `where` is a path relative to `internal/console/`, then a short location |
| + note in parentheses. The gate searches the file named by the first token. |
| +- `new` is the approved text, used verbatim by the task that writes it. It is |
| + `(removed)` for a string that goes. |
| +- `checked by` is `gate` (a plain string the gate finds literally in the |
| + file, once the owning task lists its id in `navCopyBuilt`) or the name of |
| + the owning task's test, which the gate only checks exists. |
| +- `status` is `pending`, then `approved` or `removed`. No pending row may |
| + reach code or a template. |
| +- No em dashes in `new`. A full stop and a new sentence instead. |
| +- Human text only. Error fragments, diagnostics, JSON keys and URLs are not |
| + rows. |
| +- Placeholders: `<n>` a whole number, `<app>` an app's name, `<name>` an |
| + account's name. `<a>` marks where a link starts and ends. |
| +- Redirects (`/deployments`, `/pipeline`, `/settings/advanced`) carry no |
| + flash. None is added. |
| +- Strings that move unchanged are not rows: the Placement section's |
| + sentences, the Errors and Analytics settings blocks, the Control plane |
| + card, and the canary and tag contents. |
| +- Ids are not renumbered. The gaps (C05 to C09, C17 to C20 and so on) are |
| + deliberate. |
| + |
| +| id | where | old | new | checked by | status | |
| +|---|---|---|---|---|---| |
| +| NAV-C01 | deployments.go (`deploymentsCopy.Title`: tab label, Overview tile heading, every "Managed on" pointer) | Deployments / Release history | Releases | TestAppTabBarIsOneLevel | approved | |
| +| NAV-C02 | templates/appnav.html (tab 5, was a Logs sub-tab) | Errors | Errors | TestAppTabBarIsOneLevel | approved | |
| +| NAV-C03 | templates/appnav.html (tab 6, was a Logs sub-tab) | Availability | Availability | TestAppTabBarIsOneLevel | approved | |
| +| NAV-C04 | templates/appnav.html (tab 7, was a Logs sub-tab) | Analytics | Analytics | TestAppTabBarIsOneLevel | approved | |
| +| NAV-C10 | templates/app_instances.html (heading) | Instances | Running | TestRunningTabHeadingAndToolbar | approved | |
| +| NAV-C11 | browserrestart.go (`AppButton`, Running heading row) | Restart | Restart app | gate | approved | |
| +| NAV-C12 | templates/app_instances.html (health links) | All | All `<n>` | TestRunningTabHeadingAndToolbar | approved | |
| +| NAV-C13 | templates/app_instance.html (back link) | Instances | Running | TestRunningLeftoversNameTheTab | approved | |
| +| NAV-C14 | templates/account_review.html (banner link) | Instances | Running | TestRunningLeftoversNameTheTab | approved | |
| +| NAV-C15 | templates/app_settings.html (General, Account, no-instances link) | Instances | Running | TestRunningLeftoversNameTheTab | approved | |
| +| NAV-C16 | templates/fleet_byo.html ("Then") | The box appears on your fleet page within minutes — it self-reports on a heartbeat cadence, not instantly. From there, place an app on it with `carlos apps place` or from the app's Instances tab. | The box appears on your fleet page within minutes. It reports in on a heartbeat, so the page does not update instantly. From there, place an app on it with `carlos apps place`, or in the app's Settings under Placement. | TestRunningLeftoversNameTheTab | approved | |
| +| NAV-C21 | templates/app_releases.html (callout heading) | (new) | What's next | gate | approved | |
| +| NAV-C22 | templates/app_releases.html (section heading) | (new) | Live now | gate | approved | |
| +| NAV-C23 | deployments.go (`Target`, Live now column) | Target version | Should run | TestReleasesPageOrder | approved | |
| +| NAV-C24 | deployments.go (`Observed`, Live now column) | Observed versions | Running | TestReleasesPageOrder | approved | |
| +| NAV-C25 | deployments.go (`NoTarget`) | No target published | Nothing published yet | gate | approved | |
| +| NAV-C26 | deployments.go (`NoChannels`, Live now empty state) | Open Release history for the commands to publish your first version. | Nothing is live yet. Ship your first version with the commands under Versions. | gate | approved | |
| +| NAV-C27 | deployments.go (`Instances`, link text in the Instances cell) | View instances | (removed: the count itself links to Running) | TestReleasesPageOrder | removed | |
| +| NAV-C28 | templates/app_releases.html (under Live now; replaces the "Rolling back" section) | Puts the previous build back in front of everyone straight away — rollbacks skip the safety delay. You'll be asked to confirm, and told which build it lands on. | Roll back puts the previous build back straight away and skips the safety delay. You confirm first and see which build it lands on. | gate | approved | |
| +| NAV-C29 | templates/app_releases.html (section heading) | All versions (`<n>`) | Versions | TestReleasesTab | approved | |
| +| NAV-C30 | templates/app_releases.html (link under Versions when an older page exists) | (new) | Older versions | TestReleasesOlderVersionsAreReachable | approved | |
| +| NAV-C35 | templates/app_releases.html (link under Versions on page 2 and later) | (new) | Newer versions | TestReleasesOlderVersionsAreReachable | approved | |
| +| NAV-C45 | templates/app_releases.html (Versions, a page past the last one) | (new) | No versions on this page. | gate | approved | |
| +| NAV-C31 | templates/app_releases.html (fold) | Release pipeline — channels, test versions, and the promotion ladder | Channels and the promotion ladder | gate | approved | |
| +| NAV-C32 | templates/app_releases.html (fold; was a heading, and part of "Test versions and rolling back") | Canaries | Canaries | TestReleasesPageOrder | approved | |
| +| NAV-C33 | templates/app_releases.html (fold; was a heading) | Tags | Tags | TestReleasesPageOrder | approved | |
| +| NAV-C34 | templates/app_releases.html (one-channel fold, and the "Rolling back" heading) | Test versions and rolling back / Rolling back | (removed) | TestOneChannelAppKeepsCanariesAndRollback | removed | |
| +| NAV-C36 | templates/app_overview.html (safety delay, unreadable) | Safety delay: this app's setting can't be read right now, so the delay stays on. Repair it on the Release history tab. | Safety delay: this app's setting can't be read right now, so the delay stays on. Repair it on the Releases tab. | TestNoLinkPointsAtDeployments | approved | |
| +| NAV-C37 | templates/app_overview.html (safety delay, on) | Safety delay: **on** — new versions wait before going live. Managed on Release history. | Safety delay: **on**. New versions wait before going live. Managed on Releases. | TestNoLinkPointsAtDeployments | approved | |
| +| NAV-C38 | templates/app_overview.html (safety delay, off, with nudge) | Safety delay: off — new versions go live as soon as they're promoted. This app looks like it's serving real users — consider turning it on, on Release history. | Safety delay: off. New versions go live straight away. This app looks like it's serving real users. Consider turning it on from Releases. | TestNoLinkPointsAtDeployments | approved | |
| +| NAV-C39 | templates/app_settings.html (Delete, production note) | It is marked as production right now, which blocks deletion — turn the safety delay off on the Release history tab first. | It is marked as production right now, which blocks deletion. Turn the safety delay off on the Releases tab first. | TestNoLinkPointsAtDeployments | approved | |
| +| NAV-C40 | server.go (`setAppSettingsSection`) | (new) | Placement | TestAppSettingsSectionRoutes | approved | |
| +| NAV-C41 | server.go (`setAppSettingsSection`) | (new) | Errors and analytics | TestAppSettingsSectionRoutes | approved | |
| +| NAV-C42 | server.go (`setAppSettingsSection`) | Advanced | (removed) | TestAppSettingsSectionRoutes | removed | |
| +| NAV-C43 | templates/app_errors.html (help line) | The level is set on the Settings tab. | The level is set in `<a>`Settings, under Errors and analytics`</a>`. | TestTelemetryHintsLinkTheSection | approved | |
| +| NAV-C44 | templates/app_analytics.html (analytics off) | Turn it on for this app or for the whole account on the `<a>`Settings`</a>` tab. | Turn it on for this app in `<a>`Settings, under Errors and analytics`</a>`, or for the whole account in the account's `<a>`Settings`</a>`. | TestTelemetryHintsLinkTheSection | approved | |
| +| NAV-C50 | server.go (`appLogsCopy.Level` field, set in `handleAppLogs`; the Logs level label) | All levels (label repeating its own first option) | Level | TestLogsToolbar | approved | |
| +| NAV-C60 | templates/apps.html (eyebrow) | (new) | Account · `<name>` | TestPageHeadsOnAccountPages | approved | |
| +| NAV-C61 | templates/apps.html (h1 when the account has apps) | `<name>` | Apps | TestPageHeadsOnAccountPages | approved | |
| +| NAV-C62 | templates/trash.html (eyebrow) | (new) | Account · `<name>` | TestPageHeadsOnAccountPages | approved | |
| +| NAV-C63 | templates/newaccount.html (eyebrow) | (new) | Accounts | TestPageHeadsOnAccountPages | approved | |
| +| NAV-C64 | templates/trash.html (row button) | Delete “`<app>`” permanently | Delete permanently | TestTrashDeleteSitsInItsRow | approved | |
| +| NAV-C65 | templates/trash.html (heading) | Delete now | (removed; its paragraph stays, above the table) | TestTrashDeleteSitsInItsRow | removed | |
| +| NAV-C66 | templates/newaccount.html (help paragraph) | Names are deliberately not unique — two accounts may both be called “blog”. Identity is the short id in the URL, so there is nothing to squat. You will be its first owner, and you can invite teammates from the account's page. | Names are deliberately not unique. Two accounts may both be called “blog”. Identity is the short id in the URL, so nobody can reserve a name. You will be its first owner, and you can invite teammates from the account's Team page. | gate | approved | |
diff --git a/docs/superpowers/plans/LUNA-COPY-BRIEF-CONSOLE-UX-NAV.md b/docs/superpowers/plans/LUNA-COPY-BRIEF-CONSOLE-UX-NAV.md| new file mode 100644 |
| index 000000000..c5971334c |
| --- /dev/null |
| +++ b/docs/superpowers/plans/LUNA-COPY-BRIEF-CONSOLE-UX-NAV.md |
| @@ -0,0 +1,78 @@ |
| +# Copy review brief: console navigation deck (delegated by Paul, 2026-10-25) |
| + |
| +Paul delegated copy review for plan copy to you. You are the copy editor; your |
| +edits will be applied as approved copy. |
| + |
| +Read `docs/superpowers/plans/2026-10-25-console-ux-nav-copy.md` (44 rows, ids |
| +NAV-C01 to NAV-C66, with gaps). The `new` column is yours to change. The ids, |
| +`where` and `checked by` columns are fixed. For what the strings are for, read |
| +Part 1 of `docs/superpowers/specs/2026-10-25-console-ux-perf-design.md` |
| +(sections 1.1 to 1.4 and 1.6; ignore 1.5). |
| + |
| +## What the change is |
| + |
| +The console (the web app people use to manage their apps) is getting a flatter |
| +navigation. One tab bar per app, with these tabs: Overview, Running, Releases, |
| +Logs, Errors, Availability, Analytics, Settings. |
| + |
| +- Deployments and Release history become one tab called Releases. It has a |
| + "What's next" callout, a "Live now" section (what should run and what does |
| + run, plus a Roll back button), and a "Versions" list with Older versions and |
| + Newer versions links. Channels, canaries and tags sit in a closed fold at |
| + the bottom. |
| +- The Instances tab becomes Running. Its Restart button becomes "Restart app". |
| +- App Settings gets two sections, Placement and Errors and analytics. The |
| + Advanced section goes. |
| +- Account pages (Apps, Trash, New account) get a small eyebrow line above the |
| + heading. `<name>` is the account's name. |
| +- Help text that points at another tab or section now names it. |
| + |
| +An app can have one release channel or several. Apps with one channel never |
| +see the words "channel", "promote" or the promotion ladder, so the text that |
| +all apps see must not use them. |
| + |
| +## House rules (Paul's, all binding) |
| + |
| +- No em dashes, ever. Use a full stop and a new sentence. Page text starts the |
| + new sentence with a capital, as drafted. The `old` column holds em dashes |
| + because it quotes the old text; do not copy them, and do not edit `old`. |
| +- Plain words. No jargon a reader would not know. Short. Say what to do next. |
| +- Neutral names only (shop, example.com). Never a tenant's name. |
| +- Human text only. If a string is not human text (a log line, a route |
| + pattern, a header name, a JSON key, an error fragment), flag it rather than |
| + edit it. |
| +- Keep every placeholder exactly (`<n>`, `<app>`, `<name>`), every `<a>` and |
| + `</a>` boundary where it is, and every backticked command exactly. Keep |
| + `**on**` as bold. |
| +- Do not change meaning or the facts a string states. If a fact looks wrong or |
| + conflicts with another row, flag it, do not rewrite it. |
| +- NAV-C26 and NAV-C28 must not use the words "Promote", "edge" or "ladder", |
| + because apps with one channel hide that vocabulary. |
| +- Tab and section labels stay short nouns (NAV-C01 to C04, C10, C21, C22, C29 |
| + to C33, C40, C41, C50, C60 to C63). Change one only if it is wrong, and say |
| + why. |
| +- A row whose `new` is `(removed)` or starts `(removed` is a string that goes. |
| + Leave it alone. |
| + |
| +## One question to answer |
| + |
| +On the Logs, Errors, Availability and Analytics tabs, a row of filter controls |
| +sits above the list: a search box, a level or channel select, a Follow button |
| +and so on. Each control has a text label. The plan's default is to keep the |
| +label visible beside its control on one line (for example "Level" then the |
| +select). The alternative is to stack the label above the control, as Logs does |
| +today. |
| + |
| +Which should it be? Answer in the flags list with the id `Q-LOGS-LABELS`, one |
| +line: "beside" or "stacked", and one short reason. NAV-C50 (the new Logs level |
| +label, "Level") is the string this affects. |
| + |
| +## Output |
| + |
| +Markdown, in this shape: |
| + |
| +1. A table of changes only: `ID | current | new | why` (a few words in why). |
| + Leave unchanged rows out. "current" is the deck's `new` text. |
| +2. A list of flagged rows: `id | problem` (fact conflict, not human text, |
| + placeholder unclear), plus the `Q-LOGS-LABELS` answer. |
| +3. One line of counts: how many rows you changed, flagged and left alone. |
diff --git a/docs/superpowers/plans/LUNA-COPY-REVIEW-CONSOLE-UX-NAV.md b/docs/superpowers/plans/LUNA-COPY-REVIEW-CONSOLE-UX-NAV.md| new file mode 100644 |
| index 000000000..5a66cf527 |
| --- /dev/null |
| +++ b/docs/superpowers/plans/LUNA-COPY-REVIEW-CONSOLE-UX-NAV.md |
| @@ -0,0 +1,12 @@ |
| +| ID | current | new | why | |
| +|---|---|---|---| |
| +| NAV-C16 | The box appears on your fleet page within minutes. It reports in on a heartbeat, so not instantly. From there, place an app on it with `carlos apps place`, or in the app's Settings under Placement. | The box appears on your fleet page within minutes. It reports in on a heartbeat, so the page does not update instantly. From there, place an app on it with `carlos apps place`, or in the app's Settings under Placement. | Removes fragment | |
| +| NAV-C28 | Roll back puts the previous build back straight away and skips the safety delay. You are asked to confirm first, and told which build it lands on. | Roll back puts the previous build back straight away and skips the safety delay. You confirm first and see which build it lands on. | Shorter and clearer | |
| +| NAV-C38 | Safety delay: off. New versions go live as soon as they're promoted. This app looks like it's serving real users. Consider turning it on, on Releases. | Safety delay: off. New versions go live straight away. This app looks like it's serving real users. Consider turning it on from Releases. | Avoids channel vocabulary | |
| +| NAV-C66 | Names are deliberately not unique. Two accounts may both be called “blog”. Identity is the short id in the URL, so there is nothing to squat. You will be its first owner, and you can invite teammates from the account's Team page. | Names are deliberately not unique. Two accounts may both be called “blog”. Identity is the short id in the URL, so nobody can reserve a name. You will be its first owner, and you can invite teammates from the account's Team page. | Removes jargon | |
| + |
| +Flagged rows: none. |
| + |
| +Q-LOGS-LABELS: beside. It keeps the shared toolbar compact and aligned across Logs, Errors, Availability and Analytics. |
| + |
| +Counts: 4 changed, 0 flagged, 40 left alone. |
| \ No newline at end of file |
diff --git a/internal/console/approved_nav_copy_test.go b/internal/console/approved_nav_copy_test.go| new file mode 100644 |
| index 000000000..d5f771fd7 |
| --- /dev/null |
| +++ b/internal/console/approved_nav_copy_test.go |
| @@ -0,0 +1,129 @@ |
| +package console |
| + |
| +import ( |
| + "os" |
| + "path/filepath" |
| + "strings" |
| + "testing" |
| +) |
| + |
| +// The copy gate of the console navigation plan |
| +// (docs/superpowers/plans/2026-10-25-console-ux-nav.md). The deck is |
| +// docs/superpowers/plans/2026-10-25-console-ux-nav-copy.md: one table with the |
| +// columns id, where, old, new, checked by, status. |
| +// |
| +// The root-level copy gates share entryBuiltRows (approved_asset_cache_copy_test.go, |
| +// package main). This gate lives in package console and cannot import it, and |
| +// its deck has a different shape (old and new cells, a checked-by column), so |
| +// it parses its own table. |
| +const navCopyDeckPath = "../../docs/superpowers/plans/2026-10-25-console-ux-nav-copy.md" |
| + |
| +// navCopyBuilt is every deck row whose text the code or templates carry. The |
| +// task that writes a row's text adds its id here in the same commit, once the |
| +// row is approved. From then on a "gate" row's new text must be in its file, |
| +// and any other row's named test must exist. |
| +var navCopyBuilt = map[string]bool{} |
| + |
| +type navCopyRow struct{ ID, Where, Old, New, CheckedBy, Status string } |
| + |
| +// parseNavCopyDeck reads the deck: every line that starts "| NAV-" is a row of |
| +// six cells. |
| +func parseNavCopyDeck(t *testing.T) []navCopyRow { |
| + t.Helper() |
| + raw, err := os.ReadFile(navCopyDeckPath) |
| + if err != nil { |
| + t.Fatal(err) |
| + } |
| + var rows []navCopyRow |
| + for _, line := range strings.Split(string(raw), "\n") { |
| + if !strings.HasPrefix(line, "| NAV-") { |
| + continue |
| + } |
| + line = strings.TrimSpace(line) |
| + line = strings.TrimSuffix(strings.TrimPrefix(line, "| "), " |") |
| + cells := strings.Split(line, " | ") |
| + if len(cells) != 6 { |
| + t.Fatalf("deck row has %d cells, want 6: %.60q", len(cells), line) |
| + } |
| + rows = append(rows, navCopyRow{ |
| + ID: strings.TrimSpace(cells[0]), Where: strings.TrimSpace(cells[1]), |
| + Old: strings.TrimSpace(cells[2]), New: strings.TrimSpace(cells[3]), |
| + CheckedBy: strings.TrimSpace(cells[4]), Status: strings.TrimSpace(cells[5]), |
| + }) |
| + } |
| + return rows |
| +} |
| + |
| +// navSpace collapses every run of whitespace to one space. |
| +func navSpace(s string) string { return strings.Join(strings.Fields(s), " ") } |
| + |
| +func TestNavCopyDeckIsApprovedAndApplied(t *testing.T) { |
| + rows := parseNavCopyDeck(t) |
| + if len(rows) < 40 { |
| + t.Fatalf("deck parsed %d rows, want at least 40", len(rows)) |
| + } |
| + |
| + seen := map[string]bool{} |
| + byID := map[string]navCopyRow{} |
| + for _, r := range rows { |
| + if seen[r.ID] { |
| + t.Errorf("%s appears twice in the deck", r.ID) |
| + } |
| + seen[r.ID] = true |
| + byID[r.ID] = r |
| + if r.Status != "approved" && r.Status != "removed" { |
| + t.Errorf("%s status is %q, want approved or removed", r.ID, r.Status) |
| + } |
| + if strings.Contains(r.New, "—") { |
| + t.Errorf("%s: new text holds an em dash", r.ID) |
| + } |
| + } |
| + for id := range navCopyBuilt { |
| + if _, ok := byID[id]; !ok { |
| + t.Errorf("navCopyBuilt names %s, which has no deck row", id) |
| + } |
| + } |
| + |
| + // Test sources, read once and only if some built row names a test. |
| + var sources string |
| + testSources := func() string { |
| + if sources == "" { |
| + files, err := filepath.Glob("*_test.go") |
| + if err != nil { |
| + t.Fatal(err) |
| + } |
| + var b strings.Builder |
| + for _, f := range files { |
| + raw, err := os.ReadFile(f) |
| + if err != nil { |
| + t.Fatal(err) |
| + } |
| + b.Write(raw) |
| + b.WriteByte('\n') |
| + } |
| + sources = b.String() |
| + } |
| + return sources |
| + } |
| + |
| + for _, r := range rows { |
| + if !navCopyBuilt[r.ID] { |
| + continue |
| + } |
| + if r.CheckedBy != "gate" { |
| + if !strings.Contains(testSources(), "func "+r.CheckedBy+"(") { |
| + t.Errorf("%s: its test %s does not exist", r.ID, r.CheckedBy) |
| + } |
| + continue |
| + } |
| + file, _, _ := strings.Cut(r.Where, " ") |
| + raw, err := os.ReadFile(file) |
| + if err != nil { |
| + t.Errorf("%s: %v", r.ID, err) |
| + continue |
| + } |
| + if !strings.Contains(navSpace(string(raw)), navSpace(r.New)) { |
| + t.Errorf("%s: %s does not contain %q", r.ID, file, r.New) |
| + } |
| + } |
| +} |