diff options
| author | John MacFarlane <[email protected]> | 2024-08-01 08:41:00 -0700 |
|---|---|---|
| committer | John MacFarlane <[email protected]> | 2024-08-01 08:41:00 -0700 |
| commit | 720aa874023ac281e6844a96b66e3d5225d0af7e (patch) | |
| tree | 61fa07df6096621b29edecb7b23ee2569ade8fdf /src/Text | |
| parent | 3d0faf692708f9977a485ade57d67f2d528da817 (diff) | |
HTML writer: add `data-` when rendering `label` attribute.
Fixes #10048.
Diffstat (limited to 'src/Text')
| -rw-r--r-- | src/Text/Pandoc/Writers/HTML.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/HTML.hs b/src/Text/Pandoc/Writers/HTML.hs index c03ffaac2..08ee76023 100644 --- a/src/Text/Pandoc/Writers/HTML.hs +++ b/src/Text/Pandoc/Writers/HTML.hs @@ -678,7 +678,8 @@ toAttrs kvs = do addAttr html5 mbEpubVersion x y | T.null x = id -- see #7546 | html5 - = if x `Set.member` (html5Attributes <> rdfaAttributes) + = if (x `Set.member` (html5Attributes <> rdfaAttributes) + && x /= "label") -- #10048 || T.any (== ':') x -- e.g. epub: namespace || "data-" `T.isPrefixOf` x || "aria-" `T.isPrefixOf` x |
