Skip to content

[HAS PR] feat: clickable text extmarks for expand/collapse interactions #809

@tobwen

Description

@tobwen

Summary

Add first-class clickable text extmark support so downstream TUIs can implement features like expand/edit/collapse summaries.

Scope

  • support click-capable extmark handlers in text buffers
  • preserve click target via the original mousedown offset
  • ignore drag-selection for click handler dispatch
  • keep typeId reindexing correct when extmarks are updated

Verification

  • added targeted tests for typeId update behavior and the drag-selection click regression
  • bun run build:lib passes
  • bun test src/lib/extmarks.test.ts src/renderables/__tests__/Textarea.selection.test.ts segfaults on local Bun 1.3.10

Screenshots / recordings

The closed state currently has no interactivity; video shows the final status.

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions