aboutsummaryrefslogtreecommitdiffhomepage
path: root/hugolib/page.go
diff options
context:
space:
mode:
authorJoe Mooring <[email protected]>2023-10-24 03:04:13 -0700
committerGitHub <[email protected]>2023-10-24 12:04:13 +0200
commit272484f8bfab97dbadad49a638a3e4b6af499f15 (patch)
tree39853fd0d9a1c7e28372777e0924497cc26607b2 /hugolib/page.go
parentde4e466036026e9a5805155f00882b93267231b5 (diff)
downloadhugo-272484f8bfab97dbadad49a638a3e4b6af499f15.tar.gz
hugo-272484f8bfab97dbadad49a638a3e4b6af499f15.zip
markdown: Pass emoji codes to yuin/goldmark-emoji
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
Diffstat (limited to 'hugolib/page.go')
-rw-r--r--hugolib/page.go6
1 files changed, 1 insertions, 5 deletions
diff --git a/hugolib/page.go b/hugolib/page.go
index 5b2411441..48f4c9d2b 100644
--- a/hugolib/page.go
+++ b/hugolib/page.go
@@ -794,11 +794,7 @@ Loop:
rn.AddShortcode(currShortcode)
case it.Type == pageparser.TypeEmoji:
- if emoji := helpers.Emoji(it.ValStr(result.Input())); emoji != nil {
- rn.AddReplacement(emoji, it)
- } else {
- rn.AddBytes(it)
- }
+ rn.AddBytes(it)
case it.IsEOF():
break Loop
case it.IsError():