quarto-dev / quarto-dev/quarto-cli
fig-align not working for indented code chunks
Open
Nobody has claimed this yet.
bug
diagrams-mermaid
- Dominant language
- JavaScript
- Stars
- 6k
- Forks
- 458
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 41
Description
I have:
- searched the issue tracker for similar issues
- installed the latest version of Quarto CLI
- formatted my issue following the Bug Reports guide
Bug description
fig-align: center is not working for indented code chunk
Steps to reproduce
---
title: abc
format: revealjs
---
# Test
- abc
```{mermaid}
%%| fig-align: center
graph LR
abc --> cde
```
Actual behavior
Resulting figure not indented
Expected behavior
resulting figure indented
Your environment
- VSCode: 1.105.1
- debian trixie (devcontainer on remote rocky 9 machine)
- MacOS 15.7.1 (24G231)
Quarto check output
Quarto 1.7.33
[✓] Checking environment information...
Quarto cache location: /home/stefan/.cache/quarto
[✓] Checking versions of quarto binary dependencies...
Pandoc version 3.6.3: OK
NOTE: Dart Sass version 1.59.1 does not strictly match 1.85.1 and strict checking is enabled. Please use 1.85.1.
Deno version 1.46.3: OK
Typst version 0.13.0: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
Version: 1.7.33
Path: /opt/conda/envs/dev/bin
[✓] Checking tools....................OK
TinyTeX: v2025.09
Chromium: (not installed)
[✓] Checking LaTeX....................OK
Using: TinyTex
Path: /home/stefan/.TinyTeX/bin/x86_64-linux
Version: 2025
[✓] Checking Chrome Headless....................OK
Chrome: (not detected)
[✓] Checking basic markdown render....OK
[✓] Checking Python 3 installation....OK
Version: 3.13.7 (Conda)
Path: /opt/conda/envs/dev/bin/python
Jupyter: 5.8.1
Kernels: python3
[✓] Checking Jupyter engine render....OK
[✓] Checking R installation...........(None)
Unable to locate an installed version of R.
Install R from https://cloud.r-project.org/
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by rendering the provided QMD example with Quarto 1.7.33 and the revealjs format, checking how the Mermaid figure behaves inside the indented list item. Trace the figure-alignment handling for indented code chunks and compare it with a non-indented chunk. Done means the resulting figure stays centered and correctly indented within the list item.
Written by the indexing model from the issue text.
Assessment
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100