Skip to content

web UI: playbook Enter has no list continuation and Tab inserts two spaces instead of indenting the item #1097

Open

Description

@edwin-zvs

Spec 0094 gives the TUI Playbook list-aware editing: Enter on a list item continues the list (same indent and marker, checklists restart unchecked) and dissolves the marker on an empty item; Tab/S-Tab indent and outdent every list line the selection spans. Spec 0059 asks the web UI to be the peer of that surface.

The web UI has neither.

Tab inserts two spaces at the caret:

if (e.key === "Tab" && !mod) {
  e.preventDefault();
  document.execCommand("insertText", false, "  ");
  return;
}

(crates/daemon/assets/index.html ~line 9218 @ ad47152)

There is no S-Tab outdent, and no notion of the list item — pressing Tab anywhere on the line pushes two spaces in at the caret rather than nesting the item.

Enter has no handler at all, so it inserts a plain newline with no marker and no indent.

Repro

Same document, same keys, in both surfaces:

TUI web UI
Enter at end of - child item - (list continues) `` (bare newline)
Tab on - item - item (item nests) - item (two spaces at caret)
S-Tab on - item - item (outdents) nothing

Expected

Web UI Playbook editing matches the TUI's list affordances — the shared block-identity and merge rules are already ports of the same logic, and the editing model should follow.

Acceptance criteria

  • Enter on a non-empty markdown list item continues the list (indent + marker; checklist items restart as unchecked).
  • Enter on an empty list item dissolves the marker.
  • Tab / S-Tab indent / outdent the list item(s) the caret or selection covers, not raw spaces at the caret.
  • Non-list lines keep plain newline / no-op behaviour.

Found during a hands-on UX audit of the Playbook in the TUI and web UI.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions