8000 Margin marks · Issue #65 · kiran-brahma/writing-tool · GitHub
[go: up one dir, main page]

Skip to content

Margin marks #65

Closed
Closed

Description

@kiran-brahma

Parent

#57 — Spec: Obelus v1.3, the page and the mark

What to build

Margin marks. Beside each Paragraph where open Findings begin, an obelus with the count sits in the right-hand margin between the prose and the Rail. marginMarks(tree, highlights) — a pure function beside the Callout's — gives one entry per top-level block where an open, attached Finding's interval begins. The Highlight plugin draws each as a widget between top-level blocks (never inside a textblock, where widgets disturb Safari's caret), so marks follow typing with no measuring. Each is a button, out of the Tab order, labelled with its count. A click opens the Callout through the same path as a Highlight click, and the Current Finding does not move (ADR 0011).

Stories 217–227.

Acceptance criteria

  • marginMarks is tested: one entry per open Finding where it begins; a multi-Paragraph Finding counted once; Orphaned and closed Findings absent; shared blocks counted correctly.
  • A click on a Margin mark opens the Callout with that Paragraph's open Findings; the Current Finding and the Rail do not move.
  • Marks stay beside the right Paragraph while typing above them.
  • A mark disappears when its last Finding leaves the queue.
  • Tab never lands on a Margin mark; a screen reader announces its count.
  • The caret moves normally at the start of a marked Paragraph in Safari.
  • Typing with about 490 Highlights feels no slower than before (checked by hand).

Blocked by

Activity

  1. kiran-brahma commented on Sep 26, 2026

    @kiran-brahma
    OwnerAuthor

    Done in #89 (merged into v1.3). marginMarks(tree, highlights) sits beside calloutFindings and is tested (begin block, multi-Paragraph counted once, shared blocks, Orphaned/closed absent). The Highlight plugin draws each as a zero-height widget at a top-level block boundary: a button, tabIndex=-1, aria-label "N Findings", showing ÷N in the blue pencil. A click opens the Callout via the Highlight-click path; the Current Finding, Rail, caret and focus don't move. "Margin mark" added to CONTEXT.md. Checked in headless Chromium at 900/1024/1440 in both schemes.

    Needs a human: the Safari caret at the start of a marked Paragraph, and hand-typed speed with ~490 Highlights. Chromium proxy: median keystroke ~3% slower (38.1 vs 36.9 ms, means overlap). Not tested with a real screen reader. Three-digit counts would overflow the column's right padding.


    Generated by Claude Code

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

    ready-for-agentSpec is ready for an agent to implement

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0