summaryrefslogtreecommitdiffstats
path: root/markup/goldmark/integration_test.go
AgeCommit message (Collapse)Author
2023-10-24markdown: Pass emoji codes to yuin/goldmark-emojiJoe Mooring
Removes emoji code conversion from the page and shortcode parsers. Emoji codes in markdown are now passed to Goldmark, where the goldmark-emoji extension converts them to decimal numeric character references. This disables emoji rendering for the alternate content formats: html, asciidoc, org, pandoc, and rst. Fixes #7332 Fixes #11587 Closes #11598
2022-11-24markup/goldmark: Improve benchmarkBjørn Erik Pedersen
2022-03-12deps: Update github.com/yuin/goldmark v1.4.9 => v1.4.10Bjørn Erik Pedersen
Fixes #9658
2022-03-11deps: Fix Goldmark regression with HTML commentsBjørn Erik Pedersen
Fixes #9650
2022-03-10Fail with error when double-rendering text in markdownify/RenderStringBjørn Erik Pedersen
This commit prevents the most commons case of infinite recursion in link render hooks when the `linkify` option is enabled (see below). This is always a user error, but getting a `stack overflow` (the current stack limit in Go is 1 GB on 64-bit, 250 MB on 32-bit) error isn't very helpful. This fix will not prevent all such errors, though, but we may do better once #9570 is in place. So, these will fail: ``` <a href="{{ .Destination | safeURL }}" >{{ .Text | markdownify }}</a> <a href="{{ .Destination | safeURL }}" >{{ .Text | .Page.RenderString }}</a> ``` `.Text` is already rendered to `HTML`. The above needs to be rewritten to: ``` <a href="{{ .Destination | safeURL }}" >{{ .Text | safeHTML }}</a> <a href="{{ .Destination | safeURL }}" >{{ .Text | safeHTML }}</a> ``` Fixes #8959
2022-03-09markup/goldmark: Default to https for linkifyBjørn Erik Pedersen
Fixes #9639
2022-03-02markup/goldmark: Escape image alt attributeJoe Mooring
Fixes #9594
2022-02-26 markup/goldmark: Unify some code block testsBjørn Erik Pedersen
2022-02-24Add Markdown diagrams and render hooks for code blocksBjørn Erik Pedersen
You can now create custom hook templates for code blocks, either one for all (`render-codeblock.html`) or for a given code language (e.g. `render-codeblock-go.html`). We also used this new hook to add support for diagrams in Hugo: * Goat (Go ASCII Tool) is built-in and enabled by default; just create a fenced code block with the language `goat` and start draw your Ascii diagrams. * Another popular alternative for diagrams in Markdown, Mermaid (supported by GitHub), can also be implemented with a simple template. See the Hugo documentation for more information. Updates #7765 Closes #9538 Fixes #9553 Fixes #8520 Fixes #6702 Fixes #9558
2022-02-21markup/goldmark: Add BenchmarkCodeblocksBjørn Erik Pedersen
2022-02-16markup/goldmark: Exclude event attributes from markdown render hookJoe Mooring
Fixes #9511
2022-02-16markup/goldmark: Fix mangling of headers/links in render hooksBjørn Erik Pedersen
```bash name old time/op new time/op delta SiteWithRenderHooks-10 11.9ms ± 1% 11.9ms ± 1% ~ (p=0.486 n=4+4) name old alloc/op new alloc/op delta SiteWithRenderHooks-10 11.2MB ± 0% 11.3MB ± 0% +0.16% (p=0.029 n=4+4) name old allocs/op new allocs/op delta SiteWithRenderHooks-10 145k ± 0% 145k ± 0% +0.14% (p=0.029 n=4+4) ``` Fixes #9504
2022-02-16markup/goldmark: Add a render hook benchmarkBjørn Erik Pedersen
Updates #9504
2022-02-10Exclude event attributes when rendering markdownJoe Mooring
Closes #9463