More flexibility for cross referencing labels and others will be in order for a later Quarto version. Follow
for updates. Among the proposal:
However, I cannot figure out an easy way to have the fig-labels bold.
For now, this seem to work but only for the label not the number
---
title: "test"
format: html
crossref:
fig-title: "**Figure**"
---
{#fig-elephant}
See @fig-elephant for an illustration.
You would need to use JS if you really need to that in HTML , but to do the same for LaTeX (and PDF) it would require post processing the .tex before rendering to PDF.
Example for catching all Figure i caption and applying bold using <strong> tag (could also be a span with class and then add a CSS to apply font-weight)
I updated the regex into /^(Fig.*? \d+([.]\d+[.]))/ to meet my project's requirements. And the result is this:
So JavaScript solution really works.
Just I'm wondering why this part (Fig. with the numbers) is not assigned an additional CSS class with e.g., <span class="fig-cap-numbers"> tag to be easier to work with it via CSS. As this is the case in Bookdown HTML files? Was this tag/class not included in Quarto on purpose?