Skip to content

feat(editor): Source as hero with Author/Review density and a Problems hierarchy (#988–#991) - #992

Merged
drawmeanelephant merged 5 commits into
mainfrom
t3code/editor-aesthetic-slices
Sep 13, 2026
Merged

feat(editor): Source as hero with Author/Review density and a Problems hierarchy (#988–#991)#992
drawmeanelephant merged 5 commits into
mainfrom
t3code/editor-aesthetic-slices

Conversation

@drawmeanelephant

@drawmeanelephant drawmeanelephant commented Sep 13, 2026

Copy link
Copy Markdown
Owner

Pull Request

Agent Completion Report

  • Status: complete
  • Branch and Worktree:
    • Branch: t3code/editor-aesthetic-slices
    • Worktree: t3code/editor-aesthetic-slices (t3code worktree)
  • Commit and PR:
    • Commit: 9940750f (head)
    • Target PR / Branch: main
  • Linked Issues (auto-close convention):
  • Changed Files:
    • editor/ui/src/lib/state/density.svelte.ts (new Author/Review density state)
    • editor/ui/src/components/SourcePane.svelte (hero surface + measured writing chrome)
    • editor/ui/src/components/ProblemsPane.svelte, ActionGroup.svelte (new), ReportBlock.svelte (new), PublicationPane.svelte
    • editor/ui/src/App.svelte, Header.svelte, SectionNav.svelte, AuthoringTools.svelte
    • editor/ui/src/lib/state/problems.svelte.ts (running command)
    • editor/ui/src/styles.css
    • editor/ui/tests/density-modes.spec.ts (new), plus Review-density seeds in safe-editing, section-nav, reading-hierarchy, graph-map, watch-admin
    • editor/scripts/preview-frame-check.cjs (live gate switches to Review before rebuilding)
    • editor/README.md, content/guides/editor.md, docs/changelog.d/992-editor-writing-surface.md
  • Preserved Unrelated Files:
    • No unrelated tracked files touched; no other worktrees modified.
  • Implementation Summary:
    • editor: Author vs Review density modes (calmer writing chrome) #990 density modes: new disposable boris-editor-density preference (validated on load). Cold open is Author: Source + Project; Problems/Preview/Watch/Graph/Publication are unmounted, and authoring hints fold into one disclosure. Review restores the full chrome. Section-nav links to other-mode panes are muted but enabled and switch modes before landing; the scrollspy skips panes that are not mounted.
    • editor: Source as hero — gutter, current line, writing chrome #989 Source as hero: heavier writing column at every breakpoint (Author drops the rail column entirely), elevated editing shell, quieter Focus/Undo/Redo beside the primary Save, and measured chrome — a line gutter for the visible window, a current-line band, and a presentation-only frontmatter/body seam. Geometry comes from a hidden mirror with the textarea's exact metrics; the native textarea remains the editing authority.
    • editor: Problems action hierarchy — primary vs secondary #991 Problems hierarchy: primary Build and validate group (Validate project, Build diagnostics, Build HTML) and secondary Analysis group (Check graph, Verify proof), shared ActionGroup language, per-command aria-busy + in-button progress on the pressed command, and reports over 24 lines collapsed behind an explicit Show … disclosure. Allowlist, palette entries, and exit-class reporting unchanged.
    • CI hardening found by the Linux editor gate: widened the Review rail so the Problems lede keeps a real measure beside the result chip, and taught the live preview frame check to switch to Review before clicking Rebuild preview (the pane is no longer mounted at cold open).
    • QA review fix: a reduced-motion, mode-gated reveal that clamps at max scroll now keeps aria-current on the landed target while its box still covers the reading line (the spy previously handed currency to the last present pane); scrolling the target off the line releases it. Pinned by a new regression test in density-modes.spec.ts.
  • Known Gaps:
    • The frontmatter seam recognizes only a leading ------/... fence shape; it reads no keys and validates nothing (documented as presentation-only).
    • Author mode unmounts review panes, so pane-local scroll positions reset on mode switches; buffer, dirty state, and pane state modules are preserved.
  • Exact Commands Run:
    1. npm --prefix editor/ui ci
    2. npm --prefix editor/ui run check
    3. npm --prefix editor/ui run build
    4. npx playwright test (from editor/ui)
    5. ./editor/scripts/test-preview.sh ./zig-out/bin/boris ./editor/zig-out/bin/boris-editor editor/ui/dist
    6. zig build test
    7. zig build --build-file editor/build.zig test
    8. zig fmt --check editor/build.zig editor/build.zig.zon editor/src
    9. git diff --check
  • Exact Gate Results:
    • npm --prefix editor/ui run check: pass — 0 errors, 0 warnings; key-hints conformance OK (8 hints / 24 sources)
    • npm --prefix editor/ui run build: pass
    • npx playwright test: pass — 203 tests
    • test-preview.sh: pass — preview frame renders committed dist bytes (Preview changed)
    • zig build test: pass
    • zig build --build-file editor/build.zig test: pass
    • zig fmt --check …: pass
    • CI editor-test (Linux): pass (full editor gate, including all live integration stages)
  • Determinism Result:
    • N/A (UI presentation and tests; no compiler output or artifact bytes changed)
  • Generated Artifacts:
    • editor/ui/dist/ build output and Playwright test-results/ are ignored generated output; nothing generated is committed.
  • Blockers and Next Card:

…roblems hierarchy

A cold open now lands in a calm Author view (Source + Project; review panes
unmounted, authoring hints folded, and section-nav links to Review panes
switching modes before they land) while Review keeps the full chrome. Source
gains a measured line gutter, current-line band, and presentation-only
frontmatter seam over the native textarea, and Problems leads with primary
Build & validate actions, carries per-command aria-busy progress, and
collapses large reports.

Refs #988
…sure

The Linux editor gate rendered the result chip at the rail's full content
width, so the reading-hierarchy assertion that the lede outgrows the chip
landed on an exact tie. Give the rail column more weight and the source
column the same hero share.
The Preview pane is mounted in Review density (#990); the real-host frame
check now switches modes before clicking Rebuild preview instead of assuming
the full chrome is the cold-open state.
@itoqa

itoqa Bot commented Sep 13, 2026

Copy link
Copy Markdown

Ito QA test results
Commit: e2a413d: 18 test cases ran, 1 failed ❌, 17 passed ✅.

Summary

Coverage spans core authoring and review workflows, navigation, source editing and layout behavior, completion, publication and diagnostic actions, report-size boundaries, persistence, and adversarial interaction sequences. Overall behavior is healthy, with a minor accessibility and wayfinding gap in the active navigation state for one section.

Safe to merge — the only PR-attributable issue is a minor navigation accessibility defect that leaves users without a clear active-section indicator while the section itself remains usable. No merge-blocking functional or data-loss risk is indicated; the issue remains a caveat to address.

Tests run by Ito

View full run

Result Severity Type Description
Minor severity Navigation The Graph pane mounted, received focus, remained enabled, and the URL preserved the session token, but the Graph navigation link had no aria-current="true" attribute.
General A 24-line report stayed visible, a 25-line report started collapsed and expanded to show every line, and a later five-line report returned to the inline layout without losing text.
General The long source stayed intact while the editor moved from the top to the bottom, resized, and returned to the middle. The line numbers, current-line highlight, and frontmatter seam remained visible and aligned.
General The local editor was unavailable, so this check did not reach the proof command or change any user data. Source review shows the terminated-command path clears the busy state and replaces an old proof report with the new result.
General Verified acceptable by independent adversarial review: the scenario cannot be reached through any real application path. Review notes: The finding requires two ordinary user click handlers to overlap such that the older Problems continuation commits after Graph. That dispatch is not reachable here: the first handler's entire asynchronous boundary consists of Svelte tick microtasks, which settle at the microtask checkpoint before another browser input task is dispatched; there is no request, timer, or external promise creating the…
General Starting Build HTML from the button and then from the command palette left one coherent success state and kept the proof report available. No stale or unrelated result appeared.
Commands The local editor could not be opened because the required editor service was not running. Source inspection confirms the existing publication-plan and proof-check controls still use the intended commands and clearly label results as local evidence.
Commands The publication plan is blocked until a profile is selected, and the editor explains how to add one when none exists.
Completion Author mode keeps the authoring hints behind a disclosure, while Review mode shows them expanded. In both modes, the suggestion list opened, keyboard navigation selected a suggestion, Enter inserted [[guides/intro]], and Escape closed the list.
Completion With no matching suggestions, ArrowDown, ArrowUp, and Enter left the source unchanged and did not insert completion text.
Density Author and Review modes work, and the selected mode returns after a reload. The unsaved text appeared to be lost only because the browser fixture returned an empty recovery list after reload instead of preserving the saved recovery snapshot.
Density The editor opens in Author mode when its saved density setting is invalid or missing. If browser storage is unavailable, the editor still starts and users can switch to Review mode for the current session.
Navigation Selecting Problems from Author mode switched to Review, mounted the pane, preserved the session token, and focused Problems with its navigation link marked active.
Problems The Problems screen groups common actions before analysis actions, keeps Run impact available, and shows a successful command result. A 40-line proof report starts collapsed and expands to show every line; the immediate test response did not allow the busy state to be observed.
Problems Empty reports show no extra report area, 24-line reports stay fully visible, and 25-line reports start behind a closed disclosure.
Problems Verified acceptable by independent adversarial review: the reported expectation does not match what the code actually promises. Review notes: The finding incorrectly treats the editor's cached graph payload status as a required precondition for impact analysis. The actual impact entry point recompiles the content graph itself, and both the host mapping and existing palette policy permit impact without a ready graph.json; therefore a successful impact result in that state is legitimate rather than misleading. The PR diff preserves this p…
Source The source editor kept the typed change while the caret moved, the view scrolled, and the window was resized. The line chrome and frontmatter seam stayed visible and aligned.
Source Plain text shows no frontmatter seam, and an unfinished leading fence stays unchanged while users type metadata-like text.

Tip

Reply with @itoqa to send us feedback on this test run.

Comment thread editor/ui/src/components/SectionNav.svelte
…eading line

QA found that a reduced-motion, mode-gated Graph reveal lost aria-current:
Review mounts the Graph pane, the jump clamps at max scroll, and the spy's
bottom rule handed currency to the last present pane even though Graph's box
spans the reading line. Prefer the most recent jump target while it still
covers the line; scrolling the target off the line releases it, so a stale
jump never pins wayfinding. Adds the reduced-motion regression test.
@drawmeanelephant
drawmeanelephant merged commit cf11f48 into main Sep 13, 2026
13 checks passed
@drawmeanelephant
drawmeanelephant deleted the t3code/editor-aesthetic-slices branch September 13, 2026 16:11
@itoqa

itoqa Bot commented Sep 13, 2026

Copy link
Copy Markdown

Ito QA test results
Ito Diff Reporte2a413d9940750: 7 test cases ran, 1 fixed ✅, 6 passing ✅.

Diff Summary

The run covered editor navigation and mode changes, including revealing and removing review panes, keeping active section markers consistent, and handling delayed updates and maximum-scroll boundaries. It exercised normal user flows alongside edge cases involving geometry-based highlighting, rapid transitions, and unavailable editor states.

Safe to merge — no failures were attributable to this PR, and the reported navigation discrepancies were independently assessed as intended behavior under the product’s documented rules rather than regressions. Any remaining observations are suitable for follow-up, not merge blockers.

Tests run by Ito

View full run

Result State Severity Type Description
❌->✅ Fixed Navigation Verified acceptable by independent adversarial review: the observed behavior is intended and documented in this codebase. Review notes: The finding treats a visible, focused, URL-targeted Graph pane as sufficient to retain aria-current, but the repository affirmatively defines a geometry-based scrollspy contract: the clicked target is retained only while its box covers the reading line, and a clamped target outside that line yields to the last present section. The finding reports that the retention predicate was false but provides…
Passing General The Graph pane stayed selected after the page reached its maximum scroll position, because it still covered the reading line. The active marker remained on Graph alone after the delayed update.
Passing General Verified acceptable by independent adversarial review: the reported expectation does not match what the code actually promises. Review notes: The finding equates a Graph URL, focus, mounting, and general visibility with a requirement that Graph remain current, but the repository's explicit scrollspy contract is geometry-based: Graph remains current only while its box covers the reading line. The finding supplies no reading-line geometry, while the cited production path statically prevents Watch from being selected whenever that actual c…
Passing General Switching from Review to Author removes the Graph and Watch panes, and neither removed pane keeps the active navigation marker.
Passing General Verified acceptable by independent adversarial review: the reported expectation does not match what the code actually promises. Review notes: The reproduction scrolls through neighboring panes but treats Graph remaining visible, focused, and in the URL as sufficient to retain aria-current. The implemented and documented contract is narrower: Graph is retained only while its box covers the reading line, after which ordinary scrollspy may select Preview; moreover, every completed syncCurrent path assigns a known link, and the finding's sc…
Passing Graph Verified acceptable by independent adversarial review: the reported expectation does not match what the code actually promises. Review notes: The scenario is reachable and the marker contract is explicit, but the finding describes behavior that the current source directly prevents: after the mode-gated mount, Graph becomes jumpTarget, and every settled sync that finds Graph covering the reading line returns before the max-scroll Watch fallback. The PR diff shown to this judge adds that guard and a focused regression test, so the claim t…
Passing Scroll The required local address did not provide a usable interactive editor, so the section navigation could not be exercised. No product failure was confirmed.
⏸️ Skipped General A 24-line report stayed visible, a 25-line report started collapsed and expanded to show every line, and a later five-line report returned to the inline layout without losing text.
⏸️ Skipped General The long source stayed intact while the editor moved from the top to the bottom, resized, and returned to the middle. The line numbers, current-line highlight, and frontmatter seam remained visible and aligned.
⏸️ Skipped General The local editor was unavailable, so this check did not reach the proof command or change any user data. Source review shows the terminated-command path clears the busy state and replaces an old proof report with the new result.
⏸️ Skipped General Verified acceptable by independent adversarial review: the scenario cannot be reached through any real application path. Review notes: The finding requires two ordinary user click handlers to overlap such that the older Problems continuation commits after Graph. That dispatch is not reachable here: the first handler's entire asynchronous boundary consists of Svelte tick microtasks, which settle at the microtask checkpoint before another browser input task is dispatched; there is no request, timer, or external promise creating the…
⏸️ Skipped General Starting Build HTML from the button and then from the command palette left one coherent success state and kept the proof report available. No stale or unrelated result appeared.
⏸️ Skipped Commands The local editor could not be opened because the required editor service was not running. Source inspection confirms the existing publication-plan and proof-check controls still use the intended commands and clearly label results as local evidence.
⏸️ Skipped Commands The publication plan is blocked until a profile is selected, and the editor explains how to add one when none exists.
⏸️ Skipped Completion Author mode keeps the authoring hints behind a disclosure, while Review mode shows them expanded. In both modes, the suggestion list opened, keyboard navigation selected a suggestion, Enter inserted [[guides/intro]], and Escape closed the list.
⏸️ Skipped Completion With no matching suggestions, ArrowDown, ArrowUp, and Enter left the source unchanged and did not insert completion text.
⏸️ Skipped Density Author and Review modes work, and the selected mode returns after a reload. The unsaved text appeared to be lost only because the browser fixture returned an empty recovery list after reload instead of preserving the saved recovery snapshot.
⏸️ Skipped Density The editor opens in Author mode when its saved density setting is invalid or missing. If browser storage is unavailable, the editor still starts and users can switch to Review mode for the current session.
⏸️ Skipped Navigation Selecting Problems from Author mode switched to Review, mounted the pane, preserved the session token, and focused Problems with its navigation link marked active.
⏸️ Skipped Problems The Problems screen groups common actions before analysis actions, keeps Run impact available, and shows a successful command result. A 40-line proof report starts collapsed and expands to show every line; the immediate test response did not allow the busy state to be observed.
⏸️ Skipped Problems Empty reports show no extra report area, 24-line reports stay fully visible, and 25-line reports start behind a closed disclosure.
⏸️ Skipped Problems Verified acceptable by independent adversarial review: the reported expectation does not match what the code actually promises. Review notes: The finding incorrectly treats the editor's cached graph payload status as a required precondition for impact analysis. The actual impact entry point recompiles the content graph itself, and both the host mapping and existing palette policy permit impact without a ready graph.json; therefore a successful impact result in that state is legitimate rather than misleading. The PR diff preserves this p…
⏸️ Skipped Source The source editor kept the typed change while the caret moved, the view scrolled, and the window was resized. The line chrome and frontmatter seam stayed visible and aligned.
⏸️ Skipped Source Plain text shows no frontmatter seam, and an unfinished leading fence stays unchanged while users type metadata-like text.

Tip

Reply with @itoqa to send us feedback on this test run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant