githubnext/chopinPublic

Let's compose rich plans together

Stop typing into a selected decorator and skip hidden decision cards 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>
C5MAMaggie Appleton and Claude Sonnet 5.5 authored
c818d8fPatch
Parentec3b038
5 files changed+359-0
StackedSplit
e2e/decision-marker.e2e.ts+75 โˆ’0
packages/editor/src/widgets-plugin.tsx+2 โˆ’0
packages/editor/src/widgets/decorator-selection.test.ts+93 โˆ’0
packages/editor/src/widgets/decorator-selection.tsx+188 โˆ’0
packages/editor/src/widgets/index.ts+1 โˆ’0