From e4e7a0912dc74d8c38ceb7de6c2b88ccf42b400e Mon Sep 17 00:00:00 2001 From: Jermolene Date: Wed, 12 Sep 2018 08:42:56 +0100 Subject: [PATCH] Revert "Fix tag macro problems with bad characters in title/tags (#3435)" This reverts commit b76c5011cf293a3b3045bb14cfacb9e609d1b33a. Thanks @pmario @BurningTreeC, let's redo this. --- core/wiki/macros/tag.tid | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/wiki/macros/tag.tid b/core/wiki/macros/tag.tid index 57f09bf28..0afa74c53 100644 --- a/core/wiki/macros/tag.tid +++ b/core/wiki/macros/tag.tid @@ -10,18 +10,18 @@ color:$(foregroundColor)$; \define tag-pill-inner(tag,icon,colour,fallbackTarget,colourA,colourB,element-tag,element-attributes,actions) <$vars foregroundColor=<> backgroundColor="""$colour$"""> <$element-tag$ $element-attributes$ class="tc-tag-label tc-btn-invisible" style=<>> -$actions$removeprefix[$colourA$]addprefix[tc-tag-icon-dark]] [removeprefix[$colourB$]addprefix[tc-tag-icon-light]] }}}><$transclude tiddler="""$icon$"""/> <$view tiddler=<<__tag__>> field="title" format="text" /> +$actions$<$transclude tiddler="""$icon$"""/> <$view tiddler="""$tag$""" field="title" format="text" /> \end \define tag-pill-body(tag,icon,colour,palette,element-tag,element-attributes,actions) -<$macrocall $name="tag-pill-inner" tag=<<__tag__>> icon="""$icon$""" colour="""$colour$""" fallbackTarget={{$palette$##tag-background}} colourA={{$palette$##foreground}} colourB={{$palette$##background}} element-tag="""$element-tag$""" element-attributes="""$element-attributes$""" actions="""$actions$"""/> +<$macrocall $name="tag-pill-inner" tag="""$tag$""" icon="""$icon$""" colour="""$colour$""" fallbackTarget={{$palette$##tag-background}} colourA={{$palette$##foreground}} colourB={{$palette$##background}} element-tag="""$element-tag$""" element-attributes="""$element-attributes$""" actions="""$actions$"""/> \end \define tag-pill(tag,element-tag:"span",element-attributes:"",actions:"") -<$macrocall $name="tag-pill-body" tag=<<__tag__>> icon={{{ [<__tag__>get[icon]] }}} colour={{{ [<__tag__>get[color]] }}} palette={{$:/palette}} element-tag="""$element-tag$""" element-attributes="""$element-attributes$""" actions="""$actions$"""/> +<$macrocall $name="tag-pill-body" tag="""$tag$""" icon={{$tag$!!icon}} colour={{$tag$!!color}} palette={{$:/palette}} element-tag="""$element-tag$""" element-attributes="""$element-attributes$""" actions="""$actions$"""/> \end