From 1617aa27562c6c92c981cadf13f0fb999558e1cc Mon Sep 17 00:00:00 2001 From: Sean McGivern Date: Thu, 6 Jun 2019 17:49:08 +0100 Subject: Allow emoji in label and milestone references If we put the emoji filter before the reference filters, each emoji will have a wrapper element that prevents the reference filter from detecting the presence of the emoji. As the emoji filter now runs after the reference filters, references must contain a literal emoji, not the GitLab Flavored Markdown versions (:100`, for example). A weird side-effect is that if you have a label with the 100 emoji, and a label named :100:, then trying to reference the latter will work (link to the correct label), but will render with the 100 emoji. I'm comfortable with that edge case, I think. --- lib/banzai/pipeline/gfm_pipeline.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/banzai/pipeline/gfm_pipeline.rb b/lib/banzai/pipeline/gfm_pipeline.rb index 30cafd11834..d67f461be57 100644 --- a/lib/banzai/pipeline/gfm_pipeline.rb +++ b/lib/banzai/pipeline/gfm_pipeline.rb @@ -25,7 +25,6 @@ module Banzai Filter::VideoLinkFilter, Filter::ImageLazyLoadFilter, Filter::ImageLinkFilter, - Filter::EmojiFilter, Filter::TableOfContentsFilter, Filter::AutolinkFilter, Filter::ExternalLinkFilter, @@ -34,6 +33,7 @@ module Banzai *reference_filters, + Filter::EmojiFilter, Filter::TaskListFilter, Filter::InlineDiffFilter, -- cgit v1.2.1