Checkbox task lists (- [x]/- [ ]) lose check state — converted to plain bulletList instead of taskList - #10
Conversation
Complexity Assessment - Issue #8Analyzing: Checkbox task lists ( Analysis Plan
Key FindingsFiles Affected (Estimated 7-8):
Complexity Indicators:
Architecture Quality:
Reasoning: Multiple files affected (>5), including a large 2578-line file with mixed responsibilities, combined with bidirectional conversion needs and multi-layer pipeline changes make this COMPLEX. High cognitive load and potential for breaking existing list parsing. Complexity AssessmentClassification: COMPLEX Metrics:
Reasoning: Implementation requires coordinating changes across multiple architectural layers (markdown parsing → token conversion → ADF building → reverse conversion) and modifying a large mixed-concern file (ASTBuilder). Bidirectional conversion adds complexity. Cross-cutting state flow (checkbox state) propagates through 4+ layers. |
Analysis Phase
Executive SummaryMarkdown checkbox syntax ( Questions and Key Decisions
HIGH/CRITICAL Risks
Impact Summary
Complete Technical Reference (click to expand for implementation details)Problem Space ResearchProblem UnderstandingMarkdown task lists ( Architectural ContextThe parser has two conversion directions:
Both directions must be updated for round-trip fidelity. Edge Cases Identified
Third-Party Research Findingsremark-gfm v4.0.1 (already installed)Source: Codebase dependency analysis + mdast type definitions
Atlassian ADF taskList/taskItem SpecSource: Issue description links
Codebase Research FindingsAffected Area: Markdown-to-ADF (mdast path)Entry Point: ASTBuilder.convertMdastList at
ASTBuilder.convertMdastListItem at
Affected Area: Markdown-to-ADF (token path)MarkdownTokenizer.parseList at
MarkdownTokenizer.parseListItem at
ASTBuilder.convertList at
ASTBuilder.convertListItem at
ASTBuilder.parseBlockContent at
Affected Area: ADF-to-Markdown (reverse direction)AdfToMarkdownEngine.registerConverters at
Parser.registerConverters at
BulletListConverter at
ListItemConverter at
Affected Area: Type Definitionsadf.types.ts at
Affected Area: JSON Schemaadf-schema.json at
Affected Area: ASTBuilder mdast-to-ADF roundtripASTBuilder.convertAdfNodeToMdast at
Architectural Flow AnalysisData Flow: Checkbox State (Markdown to ADF, mdast path)Entry Point:
Data Flow: Checkbox State (ADF to Markdown)Entry Point:
Affected Interfaces (ALL must be updated):
Critical Implementation Note: This is a cross-cutting change affecting 8+ files across both conversion directions. The mdast path is the primary code path; the token-based path is secondary but still active inside ADF fence block content parsing. Affected Files
Integration Points
Medium Severity Risks
|
Implementation Plan for Issue #8SummaryMarkdown checkbox task lists ( Questions and Key Decisions
Edge Case: Complex Checkbox ItemsADF - [x] Simple task (inline only -- converts to taskItem)
- [ ] Complex task
Second paragraph of content (block-level -- CANNOT be taskItem)
- [ ] Task with sub-list
- nested item (block-level -- CANNOT be taskItem)Strategy -- per-item fallback:
High-Level Execution Phases
Quick Stats
Potential Risks (HIGH/CRITICAL only)
Complete Implementation Guide (click to expand for step-by-step details)Automated Test Cases to CreateTest File:
|
Implementation CompleteSummaryAdded full bidirectional support for markdown checkbox task lists ( Changes Made
Validation Results
Detailed Changes by File (click to expand)
|
…ox syntax Convert markdown checkbox task lists (- [x]/- [ ]) to ADF taskList/taskItem nodes with proper state (DONE/TODO) and localId attributes, instead of stripping checkbox state and emitting plain bulletList/listItem nodes. Covers all three parsing paths (mdast, token, block content) plus ADF-to-markdown reverse conversion via new TaskListConverter and TaskItemConverter. Falls back to bulletList for complex items with nested content that can't be represented as inline-only taskItem nodes. Fixes JeromeErasmus#8
4800bf0 to
78bb230
Compare
…Erasmus#8 - Add task list and task item node types to Markdown lexer - Implement ASTBuilder conversion between checkbox syntax and task nodes - Add unit tests for task list parsing and AST building - Support bidirectional transformation of checkbox markdown to ADF
iloom Session SummaryKey Themes:
Session Details (click to expand)Key Insights
Decisions Made
Challenges Resolved
Lessons Learned
Generated with 🤖❤️ by iloom.ai |
Fixes #8
Checkbox task lists (
- [x]/- [ ]) lose check state — converted to plainbulletListinstead oftaskListMarkdown checkbox syntax is converted to regular
bulletList/listItemnodes, losing the checked/unchecked state entirely. ADF supportstaskList/taskItemnodes with astateattribute (TODO/DONE) for this.Input:
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" }] } ] }This PR was created automatically by iloom.