Bug description
Apparently, r-fit-text takes into account the LaTeX "source" characters instead of the displayed ones when calculating the size of the text.
I am running quarto in preview mode, which might have to do with this issue.
The following example illustrates the problem:
---
format:
revealjs:
center: true
---
## Title
::: {.r-fit-text}
r-fit-text and LaTeX don't play well with each other: $\mathcal{N}(\mathcal{a},\mathcal{b},\mathcal{c})$
:::
::: {.r-fit-text}
r-fit-text and LaTeX don't play well with each other: N(a,b,c)
:::
Output:

Edit: I just noticed that if the slide in question is not being currently displayed in the browser (e.g. another slide or tab is being displayed) then the line with LaTeX output is displayed correctly. This makes me think that there might be a race condition related to the time MathJax takes to render the LaTeX equations.
System info
quarto-cli git version: d7a4cf1cc
❯ quarto check
[✓] Checking Quarto installation......OK
Version: 99.9.9
Path: /home/mroavi/repos/quarto-cli/package/dist/bin
[✓] Checking basic markdown render....OK
[✓] Checking Python 3 installation....OK
Version: 3.10.4
Path: /usr/bin/python3
Jupyter: 4.10.0
Kernels: julia-1.5, julia-1.7, python3
[✓] Checking Jupyter engine render....OK
[✓] Checking R installation...........(None)
Unable to locate an installed version of R.
Install R from https://cloud.r-project.org/
I'm not using RStudio IDE.
My system:
OS: Manjaro Linux x86_64
Host: XPS 13 9360
Kernel: 5.15.36-1-rt41-MANJARO
Checklist
Bug description
Apparently,
r-fit-texttakes into account the LaTeX "source" characters instead of the displayed ones when calculating the size of the text.I am running quarto in preview mode, which might have to do with this issue.
The following example illustrates the problem:
Output:
Edit: I just noticed that if the slide in question is not being currently displayed in the browser (e.g. another slide or tab is being displayed) then the line with LaTeX output is displayed correctly. This makes me think that there might be a race condition related to the time MathJax takes to render the LaTeX equations.
System info
quarto-cli git version:
d7a4cf1ccI'm not using RStudio IDE.
My system:
Checklist
quarto checkin a terminal in your issue?