Skip to content

[latex] output: email autolinks is missing a pair of curly braces #595

@ghost

Description

file that demonstrates the issue: repro.tex

latex output for email autolinks is incorrect:

input repro.md:
<example@example.com>
output of cmark --to latex repro.md:
\href{mailto:example@example.com}\nolinkurl{example@example.com}
expected (matching pandoc):
\href{mailto:example@example.com}{\nolinkurl{example@example.com}}

difference: the "clickable link" covers a sliver instead of covering the entire text area
example: repro.pdf
tested with:
cmark cmark 0.31.1 - CommonMark converter
lualatex This is LuaHBTeX, Version 1.18.0 (TeX Live 2024/Alpine Linux)
pdf reader: zathura zathura 0.5.14 girara 0.4.5 (runtime: 0.4.5) (plugin) djvu (0.2.11) (/usr/lib/zathura/libdjvu.so) (plugin) pdf-mupdf (0.4.4) (/usr/lib/zathura/libpdf-mupdf.so) (browser behaves differently)

code in question:

LIT("}\\nolinkurl{");

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions