Skip to content
New issue

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.

Already on GitHub? Sign in to your account

Make our implementation of attributes compatible with jgm/pandoc #279

Closed
4 tasks done
Witiko opened this issue Mar 13, 2023 · 1 comment · Fixed by #297
Closed
4 tasks done

Make our implementation of attributes compatible with jgm/pandoc #279

Witiko opened this issue Mar 13, 2023 · 1 comment · Fixed by #297
Labels
bug lua Related to the Lua interface and implementation syntax extension Related to syntax extensions and dialects of markdown
Milestone

Comments

@Witiko
Copy link
Owner

Witiko commented Mar 13, 2023

Our implementation of attributes differs from the implementation in Pandoc.
Here is a list of the differences in a decreasing order of importance:

  • Besides alphanumeric characters, Pandoc also allows -_:. to appear in an identifier, whereas we only allow -_.
    This prohibits users from assigning colon-delimited identifiers to elements, e.g. # Introduction {#sec:introduction}.
  • For key-value pairs, Pandoc allows values to be enclosed in ASCII quotation marks or apostrophes, wheras we don't.
    This prohibits users from typing values that contain spaces.
  • Key-value pairs in the form id=VALUE are treated as though #VALUE were specified.
  • Key-value pairs in the form class="VALUE1 VALUE2 VALUE3" are treated as though .VALUE1 .VALUE2 .VALUE3 ... were specified.

Continues #164 and #177.

@Witiko Witiko added bug lua Related to the Lua interface and implementation syntax extension Related to syntax extensions and dialects of markdown labels Mar 13, 2023
@Witiko Witiko added this to the 2.23.0 milestone Mar 13, 2023
@Witiko
Copy link
Owner Author

Witiko commented Mar 18, 2023

Also update the link-attributes.test testfile according to Pandoc's manual, so that we use a key-value pair in the form class="VALUE1 VALUE2 VALUE3".

@Witiko Witiko changed the title Make our implementation of header attributes compatible with jgm/pandoc Make our implementation of attributes compatible with jgm/pandoc Mar 24, 2023
Witiko added a commit that referenced this issue Mar 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug lua Related to the Lua interface and implementation syntax extension Related to syntax extensions and dialects of markdown
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant