Skip to content

fix(markdown): render task continuations as text - #11008

Merged
OrcaWin merged 1 commit into
mainfrom
markdown-render-issue
Jul 27, 2026
Merged

OrcaWin merged 1 commit into
mainfrom
markdown-render-issue

Conversation

@OrcaWin

@OrcaWin OrcaWin commented Jul 27, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • normalize Tiptap task-list tokens so aligned, no-blank continuation text does not become an indented code block
  • preserve genuine blank-separated indented code inside task items
  • scope task-list flex styles to direct task items so nested bullet markers remain visible

Test plan

  • pnpm exec vitest run --config config/vitest.config.ts src/renderer/src/components/editor/markdown-round-trip.test.ts src/renderer/src/components/editor/markdown-dirty-state.test.ts src/renderer/src/components/editor/rich-markdown-tab-key-handler.test.ts src/renderer/src/assets/rich-markdown-task-list-style.test.ts
  • pnpm exec tsc --noEmit -p config/tsconfig.tc.web.json
  • focused oxlint
  • pnpm run check:max-lines-ratchet
  • git diff --check

@coderabbitai

coderabbitai Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The rich Markdown editor now uses a custom task-list extension that normalizes indented code tokens within task items and recursively processes nested tokens. The extension registration was updated accordingly, with round-trip tests covering continuation text and indented code blocks. Task-list CSS selectors were narrowed to direct child items, and a test verifies the scoped layout rule.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description covers summary and testing, but omits required screenshots, AI review, security audit, and notes sections. Add the missing template sections and include the requested checklist-style testing and cross-platform review details.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly matches the main change: task-list continuation rendering in Markdown.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
src/renderer/src/components/editor/markdown-round-trip.test.ts (2)

284-303: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Cover recursive normalization with a nested task item.

This case nests ordinary bullets, but it does not exercise the recursive taskItem path in normalizeTaskListToken. Add a nested checked/unchecked task item with aligned continuation text so regressions in nested normalization are detected.


305-307: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Assert preserved code content and nesting, not only fences.

toContain('```') can pass even if echo ok is lost or moved outside the task item. Assert the canonical round-trip output, or at minimum verify the code content and its task-item placement.


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 12732732-4ef2-4ff4-bfbe-c98d4466ba94

📥 Commits

Reviewing files that changed from the base of the PR and between a065db1 and 5602e4e.

📒 Files selected for processing (5)
  • src/renderer/src/assets/rich-markdown-editor.css
  • src/renderer/src/assets/rich-markdown-task-list-style.test.ts
  • src/renderer/src/components/editor/markdown-round-trip.test.ts
  • src/renderer/src/components/editor/rich-markdown-extensions.ts
  • src/renderer/src/components/editor/rich-markdown-task-list.ts

@OrcaWin
OrcaWin merged commit 3716a7b into main Jul 27, 2026
23 checks passed
@OrcaWin
OrcaWin deleted the markdown-render-issue branch July 27, 2026 23:18
enrick-dev pushed a commit to enrick-dev/orca that referenced this pull request Oct 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant