Nice references to latex items
Let me share a small example of latex code:
\documentclass[a4paper, DIV=15]{scrartcl}
\usepackage{enumitem}
\begin{document}
Some text
\begin{enumerate}[label={(\alph*)}]
\item\label{item1} Some item;
\item Another item;
\item An item that has references to Item~\ref{item1}.
\end{enumerate}
\end{document}
which is compiled to very nice pdf:

Unfortunately when I compiled it to .docx I have this wired things:

And markdown version looks same to .docx:
Some text
1. [\[item1\]]{#item1 label="item1"} Some item;
2. Another item;
3. An item that has references to
Item [\[item1\]](#item1){reference-type="ref" reference="item1"}.
Is it possible to add a magic option to achive output at docx similar with nice pdf?
I'm using:
pandoc 2.13
Compiled with pandoc-types 1.22, texmath 0.12.2, skylighting 0.10.5,
citeproc 0.3.0.9, ipynb 0.1.0.1
User data directory: /Users/catap/.local/share/pandoc
Copyright (C) 2006-2021 John MacFarlane. Web: https://pandoc.org
This is free software; see the source for copying conditions. There is no
warranty, not even for merchantability or fitness for a particular purpose.
Slightly related issues: #813 and #1774.
We wouldn't need to make an option for this; it should ideally just be done by default. It shouldn't be too hard to implement.
Note also that in your example the list style information ([label={(\alph*)}]) is being lost.
@jgm yeah, double bug! :)
Hello @jgm! I'm using Pandoc to convert Latex to html and I'm having the same issue. The following latex:
\begin{enumerate}
\item[(E1)] First
\item[(E2)] Second
\end{enumerate}
Outputs the following html:
<ol>
<li><p>First</p></li>
<li><p>Second</p></li>
</ol>
Is this still unresolved?
I could try and fix it if you think this is a good first issue.
if you think this is a good first issue.
Definitely not. The Pandoc AST has no way to represent a list with arbitrary markers.
I see. Is there any workaround I could try? Thanks
@wilitp Your question should better be asked in Discussions. It is not really relevant to this issue, which has to do with references to list items, not list items with custom enumerators.