diff options
author | satotake <doublequotation@gmail.com> | 2020-02-23 02:06:30 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-22 18:06:30 +0100 |
commit | ca68abf0bc2fa003c2052143218f7b2ab195a46e (patch) | |
tree | da1732c53edd4ba003e458a74efc0f82bdefc612 /hugolib/shortcode_test.go | |
parent | a524124beb0e7ca226c207ea48a90cea2cbef76e (diff) |
Fix goldmark toc rendering
Previously gordmark-based TOC renderes only `KindText` and `KindString`
This commit expands target node with Goldmark's renderer
I am not sure of what are expected results as TOC contents in some (rare) cases
but Blackfriday's behaviours are fundamentally respected.
For example,
- image `[image text](link)` is rendered as `<img>` tag
- GFM AutoLink `gohugo.io` is rendered as text
* Render AutoLink as <a> tag as Blackfriday does
Fixes #6736
Fixes #6809
Diffstat (limited to 'hugolib/shortcode_test.go')
-rw-r--r-- | hugolib/shortcode_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hugolib/shortcode_test.go b/hugolib/shortcode_test.go index d57a0d663..d60bdd48b 100644 --- a/hugolib/shortcode_test.go +++ b/hugolib/shortcode_test.go @@ -1136,7 +1136,7 @@ TOC: {{ .TableOfContents }} "NEW INLINE: W1: [1 2 3 4 5]", "INLINE IN INNER: Inner: W2: [1 2 3 4]", "REUSED INLINE IN INNER: Inner: W1: [1 2 3]", - `<li><a href="#markdown-delimiter-hugo-rocks">MARKDOWN DELIMITER: Hugo Rocks!</a></li>`, + `<li><a href="#markdown-delimiter-hugo-rocks">MARKDOWN DELIMITER: <strong>Hugo Rocks!</strong></a></li>`, } if enableInlineShortcodes { |