quarto-dev / quarto-cli

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

Can a single `quarto` website have different themes for different `revealjs` slides? #9990

Closed paddyroddy closed 3 months ago

paddyroddy commented 3 months ago

Bug description

I had made a GitHub Pages for my https://paddyroddy.github.io/talks, but only started with a single talk. I set the theme darkly for the website, and moon for my single revealjs slide. I have now made a second set of slides and set the theme as night. I was expecting to that different slides could have different themes, but perhaps this isn't the case in a single quarto website project?

Steps to reproduce

_quarto.yml

---
project:
  type: website

format:
  html:
    theme: darkly

index.qmd

---
title: Talks
format: html
listing:
  contents: .
---

a/index.qmd

---
title: A
author: Me
format:
  revealjs:
    theme: moon
---

b/index.qmd

---
title: B
author: Me
format:
  revealjs:
    theme: night
---

Expected behavior

I was expecting the main page to have the darkly theme, the a slides to have the moon theme and the b slides to have the night theme.

Actual behavior

It seems that both slides adopt the night theme.

Your environment

Actual website build in GitHub Actions, repo here https://github.com/paddyroddy/talks.

Quarto check output

Quarto 1.4.555
[✓] Checking versions of quarto binary dependencies...
      Pandoc version 3.1.11: OK
      Dart Sass version 1.69.5: OK
      Deno version 1.37.2: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
      Version: 1.4.555
      Path: /Applications/quarto/bin

[✓] Checking tools....................OK
      TinyTeX: (not installed)
      Chromium: (not installed)

[✓] Checking LaTeX....................OK
      Using: Installation From Path
      Path: /Users/paddy/texlive/2024/bin/universal-darwin
      Version: 2024

[✓] Checking basic markdown render....OK

[✓] Checking Python 3 installation....OK
      Version: 3.11.9
      Path: /Users/paddy/arc/misc/sleplet/.venv/bin/python3
      Jupyter: (None)

      Jupyter is not available in this Python installation.
      Install with python3 -m pip install jupyter

[✓] Checking R installation...........OK
      Version: 4.4.0
      Path: /opt/homebrew/Cellar/r/4.4.0_1/lib/R
      LibPaths:
        - /opt/homebrew/lib/R/4.4/site-library
        - /opt/homebrew/Cellar/r/4.4.0_1/lib/R/library
      knitr: 1.47
      rmarkdown: 2.27

[✓] Checking Knitr engine render......OK
cderv commented 3 months ago

Unfortunately, this is a known issue. Several revealjs slides leading to different CSS are not correctly handle in website.

Duplicate of

You can follow there.

paddyroddy commented 3 months ago

Duplicate of

* [Different revealjs formats in a Quarto website don't work as expected #8383](https://github.com/quarto-dev/quarto-cli/issues/8383)

Thanks, sorry for the noise!