github / github/app

Mermaid in markdown breaks editor

未关闭
#1,260 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
Bugs
主要语言
没有语言数据
星标
2.1k
派生
153
PR 合并指标
30 天内没有已合并 PR

描述

### Short summary

When there is a longer mermaid entry in a markdown document, the markdown preview does no longer allow editing.

### Affected version or release

_No response_

### Installation context

_No response_

### What happened?

When working with Markdown files that include Mermaid diagrams, the editor switches to the canvas/preview experience. At that point, the file becomes effectively uneditable — the editor blocks and I can no longer make changes.
The preview/canvas view renders, but the editing experience breaks. I have to switch to code mode (or “agent/go-to-code mode”) to regain the ability to edit the file.

### Steps to reproduce

Open a Markdown file
Add or include Mermaid code block (e.g. ```mermaid)
Let the editor render/open the canvas/preview experience
Try to edit the file in the editor

### Expected behavior

I can continue editing the Markdown file normally
Preview/canvas view does not block editing
Switching between edit and preview works seamlessly

### Additional context

_No response_

贡献指南

打开贡献指南

调研方向

通过打开包含较长 Mermaid 代码块的 Markdown 文件来重现该问题,然后让画布或预览体验打开并尝试进行编辑。跟踪编辑、预览和代码模式之间的转换;完成的标准是 Markdown 仍可编辑,并且在不同视图之间切换时不再阻止更改。

由索引模型根据 Issue 内容生成。

评估

技术栈
markdown
领域
frontend
Issue 类型
缺陷
难度
3/5
预计耗时
1-2 天
活跃度
冷清
描述清晰度
基本清楚
新手友好度
55/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。