Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

# Incorrect html5 figure breaks css #1005

Closed
opened this issue Jun 7, 2018 · 1 comment
Labels
Milestone

### teepeemm commented Jun 7, 2018

 Continuing my adventures with the caption package, the following tex \documentclass{article} \usepackage{caption} \begin{document} \begin{center} \marginpar{\captionsetup{type=figure}\caption{good caption}} \end{center} \begin{center} text \marginpar{\captionsetup{type=figure}\caption{bad caption}} \end{center} \end{document} produces html I would expect, but that turns out to be incorrect. A simplified version of that html is the following:  Test

 The problem is that it seems figure tags aren't allowed in p tags (a severely out of date source). Therefore, Chrome and Firefox (at least) treat the second figure as if it were 

 This means that the default css for margin notes no longer applies. (The W3C validator also complains about the first span > figure, but Chrome and Firefox at least render it correctly.)
added labels Jun 7, 2018
added this to the LaTeXML-0.8.4 milestone Jun 7, 2018

### brucemiller commented Jun 16, 2018

 yeah; another one of those situations where you have to fall-back to span-soup. Fixed in the xslt (but note that the figure will end up as a span with class=ltx_figure). Thanks for the report.
modified the milestones: LaTeXML-0.8.4, LaTeXML-0.8.3 Jul 10, 2018
to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.