wjschne / apaquarto

A quarto extension for creating APA7 documents in .docx, .html, and .pdf formats
https://wjschne.github.io/apaquarto/
Creative Commons Zero v1.0 Universal
153 stars 13 forks source link

Cross Referencing #66

Closed bsgallih12 closed 4 months ago

bsgallih12 commented 4 months ago

Hello,

I'm not sure if this is a limitation or a bug but I can only do figure cross-referencing with the pdf output option. The Word, Typst, and HTML options are throwing an error when I try to invoke cross-referencing. Works perfectly fine on the PDF output though

wjschne commented 4 months ago

Is this fixed now?

bsgallih12 commented 4 months ago

It appears to still be an issue. It will run until I try to label a photo inside the document like shown below and then I reference it with @fig-corr.

{fig-corr)

wjschne commented 4 months ago

I am not sure what you meant to display. {fig-corr) has no closing curly brace.

bsgallih12 commented 4 months ago

Hi! So this is what I have in my .qmd file but when I got to render it won't. In case it helps. This is a child document, but even when I just try to render the individual .qmd file (attached here), it doesn't render correctly

Screenshot 2024-05-13 at 12 39 34 PM
wjschne commented 4 months ago

I see now! The apaquarto template assumes that all figures have captions. If you set the caption, it should work:

![My Correlation Plot](Corr_Plot.png){#fig-corr1}

Do you need to make a figure without a caption?

bsgallih12 commented 4 months ago

Oh I see! I don't have a pressing need to have one without a caption however if I did need one what would I need to do?

bsgallih12 commented 4 months ago

Also that fixed the issue!

wjschne commented 4 months ago

For a rock-solid solution, I would need to reconfigure the Lua filters. For a temporary solution, you can try putting in a non-printing character (e.g, a non-breaking space:  )