This page is part of a static HTML representation of the TiddlyWiki at https://tiddlywiki.com/

tag Macro (Examples)

 25th July 2023 at 8:37pm

<<tag>>
<<tag Concepts>>

If a list widget generates multiple tag macros for the same tag, clicking any of them opens dropdowns on all of them, as in the example below. This is usually unwanted.

<$list filter="[tag[HelloThere]]">

* <$link/> is tagged with: <$list filter="[<currentTiddler>tags[]]"> <<tag>> </$list>

</$list>

Adding the counter="transclusion" attribute to the list widget that generates multiple identical tag macros causes each of them to be identified as a unique one. Clicking on any of them opens only a single dropdown.

<$list filter="[tag[HelloThere]]" counter="transclusion">

* <$link/> is tagged with: <$list filter="[<currentTiddler>tags[]]"> <<tag>> </$list>

</$list>

A slightly more performant option is to use the variable="transclusion" attribute in the list widget. In this case, the variable <<transclusion>> has to be used inside the list widget instead of the <<currentTiddler>> .

<$list filter="[tag[HelloThere]]" variable="transclusion">

* <$link to=<<transclusion>>/> is tagged with: <$list filter="[<transclusion>tags[]]"> <<tag>> </$list>

</$list>