Closed tajmone closed 3 years ago
OK, I've managed to fix the Superscript element now. The link element is also back, which was part of the original syntax, implemented together with the generic macro
definition.
In order to prevent document disruption with tables options like [cols="3*^"]
, I had to introduce a new "dummy element" in order to consume the occurrence of similar table options, without providing any scope to them. In the future I might need to introduce a dedicated element for these table options (what are they called?), but for now the fix will do.
Also, it would be a good idea to create a separate element for handling links, for we could provide better semantics and cover more fine-grain details — e.g. title=""
and ^
for target blank, and others — as well as to allow attributes in links (which are not uncommon).
Anyhow, now all tests are back, along with new ones checking for false positive Subscript matches, and they all pass.
The Superscript element works, but needs to be disabled until the following conditions are met:
Implementlink:
element, and capture^
for blank targeting.[cols="<...>"]
one-liner that precedes tables.Tests/quotes/_syntax_test_Superscript.asciidoc
.Superscript was temporarily disabled (commit f7ab8323b) because it was breaking up documents where the caret
^
was used for links with blank target or tables alignments.If a document contained, e.g.:
or
the
^
was parsed as an opening subscript delimiter, thus breaking up the whole document until another^
was encountered.To fix this, we need to implement the
link:
element and capture the[cols="<...>"]
one-liner that precedes tables, and ensure that these elements always precede subscript in the syntax parsing order, so that the^
will be properly handled in these contexts.