I am creating a presentation in RevealJS using Quarto. The text of one of the slides is too long and gets truncated. Is there a way to automatically (or manually) adjust the font size to make the text fit into one slide? Here is a MWE:
---
title: "My slides"
format:
    revealjs:
        embed-resources: true
        transition: slide
output: 
    revealjs::revealjs_presentation:
        css: styles.css
execute:
    echo: TRUE
---
# This is fine
- Topic 1
   - Level 1
   - Level 2
   - Level 3
# This does not fit
- Topic 2
   - Level 1
   - Level 2
   - Level 3
- Topic 3
   - Level 1
   - Level 2
   - Level 3
- Topic 4
   - Level 1
   - Level 2
   - Level 3
We can follow the suggestions from the section Content Overflow to use the class .smaller to use smaller font for a slide if it contains too much content and even can make the content scrollable by using the .scrollable class.
---
title: "My slides"
format: revealjs
execute: 
  echo: true
---
# This is fine
- Topic 1
   - Level 1
   - Level 2
   - Level 3
# This does not fit {.scrollable .smaller}
- Topic 2
   - Level 1
   - Level 2
   - Level 3
- Topic 3
   - Level 1
   - Level 2
   - Level 3
- Topic 4
   - Level 1
   - Level 2
   - Level 3
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With