github / github/app

Mermaid in markdown breaks editor

Abierto
#1,260 0 comentarios 0 reacciones 0 asignados Ver en GitHub
Bugs
Lenguaje dominante
Sin datos de lenguaje
Estrellas
2.1k
Forks
153
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

### 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_

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

Reproduce the issue by opening a Markdown file with a longer Mermaid code block, then letting the canvas or preview experience open and attempting to edit. Trace the transition between edit, preview, and code mode; done means Markdown remains editable and switching between views no longer blocks changes.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
markdown
Área
frontend
Tipo de issue
Error
Dificultad
3/5
Tiempo estimado
1-2 días
Estado de actividad
Tranquilo
Claridad
Bastante claro
Aptitud para principiantes
55/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.