diff --git a/vignettes/tutorial.qmd b/vignettes/tutorial.qmd index a06f69f8..a60f5389 100644 --- a/vignettes/tutorial.qmd +++ b/vignettes/tutorial.qmd @@ -172,7 +172,7 @@ tt(x, notes = list(a = "Blah.", b = "Blah blah.")) ## Math -In LaTeX and MathJax (for HTML), there are two main ways to enclose mathematical expressions, either between dollar signs or escaped parentheses: `$...$` or `\(...\)`. The first strategy [is discouraged by MathJax,](https://docs.mathjax.org/en/latest/basic/mathematics.html) because dollar signs are very common in non-mathematical contexts, which can cause rendering errors. In that spirit, `tinytable` will not render dollar-enclosed expressions as mathematical expressions in HTML. Following the default MathJax settings, `tinytable` expects users to employ the escaped parentheses strategy: +In LaTeX and MathJax (for HTML), there are two main ways to enclose mathematical expressions, either between dollar signs or escaped parentheses: `$...$` or `\(...\)`. The first strategy [is discouraged by MathJax,](https://docs.mathjax.org/en/latest/basic/mathematics.html) because dollar signs are very common in non-mathematical contexts, which can cause rendering errors. In that spirit, `tinytable` will not render dollar-enclosed strings as mathematical expressions in HTML. Following the default MathJax settings, `tinytable` expects users to employ the escaped parentheses strategy: ```{r} dat <- data.frame(Math = c("\\( x^2 + y^2 = z^2 \\)", "\\( \\frac{1}{2} \\)")) @@ -302,6 +302,7 @@ The font size is specified in terms of `pt` units, where 1pt=1.333px: tt(x) |> style_tt(j = "mpg|hp|qsec", fontsize = 18) ``` +::: {.content-visible when-format="pdf"} ## Spanning cells Sometimes, it can be useful to make a cell stretch across multiple colums, for example when we want to insert a label. To achieve this, we can use the `colspan` argument. Here, we make the 2nd cell of the 2nd row stretch across three columns: @@ -320,6 +321,7 @@ Here is the original table for comparison: ```{r} tt(x) ``` +::: ## Headers