Skip to content

Checkbox task lists (- [x]/- [ ]) lose check state — converted to plain bulletList instead of taskList #8

Description

@acreeger

Markdown checkbox syntax is converted to regular bulletList/listItem nodes, losing the checked/unchecked state entirely. ADF supports taskList/taskItem nodes with a state attribute (TODO/DONE) for this.

Input:

- [x] Completed task
- [ ] Pending task

Current output:

{
  "type": "bulletList",
  "content": [
    { "type": "listItem", "content": [{ "type": "paragraph", "content": [{ "type": "text", "text": "Completed task" }] }] },
    { "type": "listItem", "content": [{ "type": "paragraph", "content": [{ "type": "text", "text": "Pending task" }] }] }
  ]
}

The [x] and [ ] markers are stripped entirely — no trace remains in the ADF output. The checkbox state is lost.

Expected output:

{
  "type": "taskList",
  "attrs": { "localId": "unique-id" },
  "content": [
    { "type": "taskItem", "attrs": { "localId": "unique-id-1", "state": "DONE" }, "content": [{ "type": "text", "text": "Completed task" }] },
    { "type": "taskItem", "attrs": { "localId": "unique-id-2", "state": "TODO" }, "content": [{ "type": "text", "text": "Pending task" }] }
  ]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions