Resolved decisions in prose: margin marker, hover preview, pinned popover - #234
Conversation
|
Independent review (08bb6a1 pushed). Fixed
Checked, no change needed
Notes (not changed)
Checks: bun run fix, bun test (1767 pass), types exit 0, ci green. E2E chromium decision-marker 11/11; fixtures project sidecar, responsive-decisions, responsive-comments, comment-motion 48 passed, responsive-content 10 passed. |
|
Fix for the arrow-down / typing bug (pushed, see the latest commit) Cause. Arrowing onto a decorator block gives Lexical a node selection. Its Fix (
Tests. Unit: Not addressed. With a visible card selected, typed text is ignored rather than creating a paragraph. Backspace in the paragraph right after a hidden card still selects the invisible placeholder first (Lexical's behaviour); a vertical move onto a visible card that follows a hidden one still selects the hidden one. 🤖 Generated with Claude Code |
|
Follow-up (pushed): the open items from the previous comment are closed.
Each was reproduced in e2e first (three new tests in 🤖 Generated with Claude Code |
cf6a972 to
947f77d
Compare
947f77d to
44d0676
Compare
44d0676 to
3165f12
Compare
A linked, answered decision collapses out of the plan and becomes a gutter marker on the first line of the first anchored block. Hovering the marker or the prose washes the passage and previews the decision; pressing pins the popover, which also lists the options not chosen. Pending, empty and orphaned decisions keep a compact card. The decisions pane is unchanged. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
A hover preview no longer swallows Escape (it would block closing a child document); only a pinned popover owns the key. Adds an e2e for the marker following an edit above its prose. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…with the arrow keys Arrowing onto a decorator gives Lexical a node selection, and its beforeinput handler returns without cancelling the event, so the browser inserted text at the start of the root, each character in front of the last. Cancel insertion while a node is selected. A collapsed resolved decision is an invisible placeholder, so arrow keys now step over it to the next block of text instead of selecting it. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…Delete or arrows Backspace/Delete beside a collapsed decision now join the text blocks around it, and a node selection that lands on a hidden placeholder is handed on to the next visible block, so a visible card after a hidden one is what a vertical arrow selects. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
3165f12 to
6cba2d8
Compare
Summary
PR 3 of the decision card redesign. Stacked on #232 (presence) → #231 (restyle); base is
design/decision-card-presence.A resolved decision is now only a margin marker beside the prose it produced.
Decision: <answer>..plan-comment-previewsurface and motion: question, chosen answer with a check, decider (18px Face + handle) and date (clock icon)..plan-comment-button.ClockIconandMessageForwardIconare added to@chopin/icons(the latter is unused until "Show in chat" has data).Decisions made
question:cancelonly applies to open ones). The footer is omitted rather than shown inert. "Show in chat" and "with ..." are omitted as specified (no data).marks.pinlapses after 5 s, which is wrong for a popover. The layer holds the wash itself viahighlightfor as long as it is shown, andclears only what it painted.revealis not used: the marker already sits at the prose, so there is no scroll to do and no walk between several blocks.--color-success-washthrough a second highlight name (plan-decision); comments keep the brand wash.marks.tsnow tracks the wash per owner. This also changes the Decisions-pane hover wash from brand to success, which matches the target design.rolechanges with state); folded content and close button areinertuntil pinned.hidden, zero margin) so the decorator node still exists; it can no longer be selected and deleted from the plan view (still possible in Decisions context by removing the source). Noted as a trade-off.@chopin/iconsicons carry a native<title>, so the marker is excluded from the design-system icon tooltip (like.plan-comment-button); the preview is the tooltip.Before / after (2x)
Checks
bun run fix,bun test(1765 pass, 0 fail),bun run types(exit 0),bun run ciall green.packages/editor/src/resolved.test.ts(unchosen derivation, hover/pin state machine, marker and popover placement, card-collapse rule).e2e/decision-marker.e2e.ts(10 tests: gutter geometry, hover preview and wash, prose hover, pin / close / Escape / outside press and wash teardown, one pin at a time, keyboard, scroll, narrow, 44px touch target, compact-card fallback) plussidecar,responsive-decisions,responsive-comments,comment-motion,focus,interface-quality: 69 passed, 0 failed.line.tsx/questionnaire.tsxhashes renewed.Not done
🤖 Generated with Claude Code