I’m creating some slides using Quarto and the revealjs format. There is some analysis text in the left-hand side column which I’d like to have a background colour. The background box should extend to a set length rather than finish where the text ends. The right-hand side column will have an image. I’m currently working with the below but am not sure what needs including to add the background colour.
Code:
## Title
:::: {.columns}
::: {.column width="30%"}
* Point 1
* Point 2
* Point 3
:::
::: {.column width="70%"}
Image will go here
:::
::::
Result:
The kind of thing I’m aiming for:
2
Answers
Define a css class (suppose
text-col
) and defineheight
andbackground-color
for this class and then apply the class selector.text-col
on the.column
Div you want.style.css
presentation.qmd
If you’re not familiar with CSS you can use the below pattern as one way to do it and nest multiple css arguments in a row with the same div.