quarto-dev / quarto-cli

Open-source scientific and technical publishing system built on Pandoc.
https://quarto.org
Other
3.88k stars 318 forks source link

Some callouts inherit from parent callout icon #11112

Open mcanouil opened 3 days ago

mcanouil commented 3 days ago

Bug description

Callouts' icon gets inherited following this rule:

It's worst for revealjs than html where top banner can also inherit the colour of the parent.

Same result for: 1.6, 1.5, and 1.4

Screenshots | `html` | `revealjs` | |--------|------------| | ![Image](https://github.com/user-attachments/assets/7ccea985-a8cb-4e4c-87e1-86e2474572e7) | ![Image](https://github.com/user-attachments/assets/c64fea63-041e-4772-8d9d-690d08a0d6b8) | | ![Image](https://github.com/user-attachments/assets/23fef23b-fb4a-471b-9caf-e7da972077e8) | ![Image](https://github.com/user-attachments/assets/be1fff01-c0af-49dc-9a04-6cd9644edb30) | | ![Image](https://github.com/user-attachments/assets/6d57586e-ec7c-434b-9ce4-22b8ad2dd485) | ![Image](https://github.com/user-attachments/assets/093f924b-b68f-4e09-aa48-bac657d048f6) | | ![Image](https://github.com/user-attachments/assets/59bfa30f-d4a1-46f1-af9b-69ae5a2a8c54) | ![Image](https://github.com/user-attachments/assets/8f0eed2b-364a-4854-9e9b-5b43e2607cc0) | | ![Image](https://github.com/user-attachments/assets/920facfb-440c-4a7f-aa92-ced0718103a0) | ![Image](https://github.com/user-attachments/assets/e691967f-0c5a-499e-b269-768860bfb2d2) |

Steps to reproduce

Quarto document ````qmd --- title: "Callouts" format: html: default revealjs: default --- ## Important :::: {.callout-important} ::: {.callout-tip} - HTML: Yes - Reveal.js: No ::: ::: {.callout-note} - HTML: Yes - Reveal.js: Yes + banner colour ::: ::: {.callout-warning} - HTML: Yes - Reveal.js: No ::: ::: {.callout-caution} - HTML: Yes - Reveal.js: No ::: :::: ## Caution :::: {.callout-caution} ::: {.callout-tip} - HTML: Yes - Reveal.js: Yes + banner colour ::: ::: {.callout-note} - HTML: Yes - Reveal.js: Yes + banner colour ::: ::: {.callout-warning} - HTML: Yes - Reveal.js: Yes + banner colour ::: ::: {.callout-important} - HTML: No - Reveal.js: Yes + banner colour ::: :::: ## Warning :::: {.callout-warning} ::: {.callout-tip} - HTML: Yes - Reveal.js: No ::: ::: {.callout-note} - HTML: Yes - Reveal.js: Yes + banner colour ::: ::: {.callout-important} - HTML: No - Reveal.js: Yes + banner colour ::: ::: {.callout-caution} - HTML: No - Reveal.js: No ::: :::: ## Tip :::: {.callout-tip} ::: {.callout-note} - HTML: Yes - Reveal.js: Yes + banner colour ::: ::: {.callout-important} - HTML: No - Reveal.js: Yes + banner colour ::: ::: {.callout-warning} - HTML: No - Reveal.js: Yes + banner colour ::: ::: {.callout-caution} - HTML: No - Reveal.js: No ::: :::: ## Note :::: {.callout-note} ::: {.callout-important} - HTML: No - Reveal.js: No ::: ::: {.callout-tip} - HTML: No - Reveal.js: No ::: ::: {.callout-warning} - HTML: No - Reveal.js: No ::: ::: {.callout-caution} - HTML: No - Reveal.js: No ::: :::: ````

Expected behaviour

Parent callout should not matter.

Actual behaviour

Parent matters.

Quarto check output

Full ```bash Quarto 99.9.9 [✓] Checking versions of quarto binary dependencies... Pandoc version 3.4.0: OK Dart Sass version 1.70.0: OK Deno version 1.46.3: OK Typst version 0.11.0: OK [✓] Checking versions of quarto dependencies......OK [✓] Checking Quarto installation......OK Version: 99.9.9 commit: 9d866bd7b142f004a3a32d3b71e1a4da8c9b97af Path: /Users/mcanouil/Projects/quarto/quarto-cli/package/dist/bin [✓] Checking tools....................OK TinyTeX: v2024.07.03 Chromium: (not installed) [✓] Checking LaTeX....................OK Using: TinyTex Path: /Users/mcanouil/Library/TinyTeX/bin/universal-darwin Version: 2024 [✓] Checking basic markdown render....OK [✓] Checking Python 3 installation....OK Version: 3.13.0 Path: /Users/mcanouil/Projects/quarto/quarto-playground/.venv/bin/python3 Jupyter: 5.7.2 Kernels: julia-1.10, python3 [✓] Checking Jupyter engine render....OK (/) Checking R installation...........ℹ R version 4.4.1 (2024-06-14) ! Config '~/.Rprofile' was loaded! [✓] Checking R installation...........OK Version: 4.4.1 Path: /Library/Frameworks/R.framework/Resources LibPaths: - /Users/mcanouil/Projects/quarto/quarto-playground/renv/library/macos/R-4.4/aarch64-apple-darwin20 - /Users/mcanouil/Library/Caches/org.R-project.R/R/renv/sandbox/macos/R-4.4/aarch64-apple-darwin20/f7156815 knitr: 1.48 rmarkdown: 2.27 [✓] Checking Knitr engine render......OK ```
cscheid commented 3 days ago

We don't (and will not) support nested callouts, but we should issue error messages