Repository navigation
Description
Problem
The Scroll dial rotates to scroll the focused editor's viewport (keyboard-free reading), but it does nothing when the reviewer is looking at a spec or plan — the exact long document where scrolling without the keyboard is most useful. Its two neighbours (Review: Files / Headings and Review: Changes / Blocks) can navigate a spec/plan; the Scroll dial cannot.
Discovered during #1498's dev-approval hardware testing. #1498 deliberately left rotation unchanged and scoped itself to apps/streamdeck only, so this is a separate follow-up rather than part of that lane.
Root cause
The Scroll dial's rotation relays the scroll verb, which maps to VSCode's built-in editorScroll command (apps/vscode/src/command-relay.ts:59). editorScroll acts only on the active text editor's viewport.
A spec/plan under review is not a text editor — it opens in the artifact-canvas, a WebviewPanel (apps/vscode/src/markdown-preview/preview-provider.ts, the shared artifact-canvas surface). When that canvas is focused there is no active text editor, so editorScroll has nothing to act on and silently no-ops.
The review dials work on a spec/plan because they switch channels by phase: in canvas mode ReviewNav stops sending editor/diff verbs and drives the canvas over sendCanvasCommand (heading-next, block-next, etc.). The Scroll dial has only the single editorScroll channel, so it can never reach the canvas.
Proposed direction
Give the canvas a viewport-scroll capability and phase-switch the Scroll dial's rotation the way the review dials already switch:
- Add a canvas command that scrolls the artifact-canvas viewport by N lines (up/down) — the canvas currently exposes heading/block/comment navigation and composer commands, but no raw viewport pan.
- In
ScrollNav.onDialRotate, when the selected builder's phase is canvas mode (reviewMode(...) === 'canvas'), route rotation to that canvas command viasendCanvasCommandinstead ofeditorScroll; keepeditorScrollfor diff/text-editor mode. This mirrors the existingReviewNavmode split. - Leave
revealCursor: falsesemantics intact (viewport move only).
What "fixed" means — the two gestures have different scopes
Discovered while absorbing the canvas-mode honesty into #1498: the Scroll dial's two gestures do not share a scope, so a canvas viewport-scroll capability would only half-fix the dial on a canvas.
- Rotation is any-text-editor (
editorScroll). This issue would revive it on a canvas via a new canvas viewport-scroll command. - The press (
feedback-selection) is builder-diff-only: its anchor (selectionAnchor()→activeEntry(),apps/vscode/src/review-queue/feedback.ts:48-90) requires a tracked builder-diff entry, which a spec/plan in the artifact-canvas never has. So the press stays inert on a canvas by design, even after this lands.
Consequence: even with this issue fixed, the Scroll dial is half-live on a canvas (rotation works, press does not). #1498's Scroll · editor only label therefore cannot simply collapse back to Scroll · send/queue when this lands. Making the press work on a spec/plan too would be a separate, larger change (a spec/plan feedback path that isn't diff-anchored), not part of this issue.
Scope note
Unlike #1498 (which was apps/streamdeck-only), this needs a new canvas viewport-scroll command, which likely touches the artifact-canvas surface, the wire/types contract, and the VSCode relay in addition to the deck. Sizing/protocol is for the architect to decide; flagging the cross-surface nature so it isn't mistaken for a deck-only change.
Out of scope
- The Scroll dial's touchstrip narration and press behaviour (delivered by Stream Deck: the Scroll dial does not narrate itself — no live mode, no builder, no empty state #1498).
- The other three dials.
Activity
[PIR #1498] Thread: record dev-approval finding + follow-up #1501
[PIR #1498] Scroll dial: 'Scroll · editor only' in canvas mode (both …
[PIR #1498] Thread: canvas-mode wording implemented, #1501 scope note
amrmelsayed commentedon Aug 18, 2026
Architect scoping — running this as a PIR lane
Owner has stated the need directly: the Scroll dial must scroll a spec/plan under review.
Findings below are verified at source, not inferred — they narrow the scope from what this
issue's original body assumed.
Root cause, exactly
apps/vscode/src/command-relay.ts:59maps the canonical verb straight to a built-in:editorScrollacts only on a focused text editor. A spec/plan opens in themarkdown-preview webview (
apps/vscode/src/markdown-preview/preview-provider.ts), which isnot a text editor, so the relayed command arrives and does nothing.
What is ALREADY correct — do not touch these
ScrollNav.onDialRotaterelays the scroll verbunconditionally; it never consults
reviewMode. So rotation already leaves the dial andreaches VS Code in canvas mode. No Stream Deck change is needed to make rotation function.
to/by/value/revealCursor. No wire or protocol change.preview-provider.ts:134doespanel.webview.postMessage, and the webview listens atmarkdown-preview/webview/main.ts:144.So this is a VS Code + webview change, NOT the three-surface change the issue body assumed.
Scope
apps/vscode— the scroll verb stops being a direct alias to a built-in and becomes aCodev command that branches: canvas/preview panel focused, post a scroll message into the
webview; otherwise delegate to
editorScrollexactly as today. The existing text-editorbehaviour must not regress.
apps/streamdeck— the canvas-mode label, see the decision below.DECISION FOR THE PLAN GATE — do not guess this
Once rotation works on a canvas, the current canvas label
Scroll · editor onlybecomesfalse. But it must NOT simply collapse back to
send/queue, because the press staysdiff-bound by design:
feedback-selectionneeds a builder-diff anchor, and a spec/plan isnot one. So on a canvas the dial becomes half-live in the OPPOSITE direction from the
no-builder case just settled in #1505: rotation live, press inert.
Surface the wording options in the plan with a recommendation and let the owner rule at the
plan gate. Note the precedent from #1505: the owner chose the minimal honest form (a bare
Scroll) over a more talkative qualifier, because line 2 already carries the context.Do not treat #1505 / PR #1508 as a dependency — it is unrelated code in the same method's
neighbourhood. If it has merged by the time you touch
renderTo, rebase; if not, leave thatbranch alone.
Verification
The payoff is viewport movement inside a webview, so tests alone cannot close this. The
dev-approval gate is the point: get it running, then the owner exercises the real dial
against a real spec/plan. Do not claim hardware or deck observation yourself.
amrmelsayed commentedon Aug 18, 2026
Architect scoping — running this as a PIR lane
Owner has stated the requirement directly: the Scroll dial must scroll a spec/plan under
review. Findings below are verified at source, and they NARROW the scope from what this
issue's body assumes.
Root cause, exactly
apps/vscode/src/command-relay.ts:59maps the canonical verb straight to a VS Code built-in:editorScrollacts only on a focused text editor. A spec/plan opens in themarkdown-preview webview (
apps/vscode/src/markdown-preview/preview-provider.ts), which isnot a text editor, so the relayed command arrives and does nothing. That is the whole bug.
What ALREADY works — do not "fix" these
ScrollNav.onDialRotaterelays the scroll verbunconditionally; it never consults
reviewMode. Rotation already leaves the dial andreaches VS Code in canvas mode. No Stream Deck change is needed to make rotation FUNCTION.
to/by/value/revealCursor. No wire or protocol change.preview-provider.ts:134doespanel.webview.postMessage, and the webview listens atmarkdown-preview/webview/main.ts:144.So this is a VS Code + webview change, not the three-surface change the issue body
assumed. Scope your plan accordingly and say so if you find otherwise.
Scope
apps/vscode— the scroll verb stops being a direct alias to a built-in and becomes aCodev command that branches: preview/canvas panel focused, post a scroll message into the
webview; otherwise delegate to
editorScrollexactly as today. The existingtext-editor behaviour must not regress — that is the main risk in this lane.
apps/streamdeck— the canvas-mode label; see the decision below.DECISION FOR THE PLAN GATE — surface it, do not guess it
Once rotation works on a canvas, the current canvas label
Scroll · editor onlybecomesfalse. It must NOT simply collapse back to
send/queue, because the press staysdiff-bound by design:
feedback-selectionneeds a builder-diff anchor and a spec/plan isnot one. So on a canvas the dial becomes half-live in the OPPOSITE direction from the
no-builder case just shipped in #1505 (PR #1508, merged): there, rotation live + press
inert with no qualifier; here, rotation live + press inert on a canvas.
Present the wording options in the plan with a recommendation and let the owner rule at the
plan gate. Precedent worth weighing: for #1505 the owner chose the minimal honest form (a
bare
Scroll) over a more talkative qualifier, because line 2 already carried the context.Note #1505 is already merged into your base, so
ScrollNav.renderTonow has theno-builder early return. Build on it; do not revert or duplicate it.
Verification
The payoff is viewport movement inside a webview, so tests alone cannot close this — that is
exactly why this is PIR and not AIR. The dev-approval gate is the point: get it running,
then the owner exercises the real dial against a real spec/plan. Do NOT claim hardware or
deck observation yourself; report what you ran and hand the observation to the architect.
amrmelsayed commentedon Aug 18, 2026
On it! Working on this with the PIR protocol (plan + dev-approval gates before PR).
[PIR #1501] Plan draft
[PIR #1501] Add viewport-down/up to the canvas command wire contract
[PIR #1501] Allow viewport-scroll commands through the Tower relay an…
[PIR #1501] Scroll the canvas viewport on viewport-down/up (host page…
[PIR #1501] Route the Scroll dial to canvas viewport-scroll in canvas…
[PIR #1501] Test Scroll dial rotation in both modes; add first genuin…
[PIR #1501] Update builder thread
[PIR #1501] Address impl-review: fix stale Scroll dial docs, host-con…
[PIR #1501] Update builder thread with consult results
[PIR #1501] Review + retrospective
[PIR #1501] Update thread: dev-approval + review phase
[PIR #1501] Review consult: pin horizontal-mode inert scroll; note de…
[PIR #1501] Fix canvasErrorLine comment: invalid-request is reachable…