"[<currentTiddler>has[death-date]]" means "if the current tiddler has a non-blank death-date field"
Without using <currentTiddler> at the beginning of the filter, then filter would be applied to ALL tiddlers by default,
and "has[death-date]" would produce output for every tiddler with a non-blank death-date field, not just the current one.
The problem here is that TiddlyWiki syntax doesn't "nest". That is, you can't use one kind of syntax
such as transclusion -- {{!!orcid}} -- within another, such as a link -- [[text|url]].
You can, however, *construct* the link syntax by using a macro, like this:
\define mylink() [[$(this_orcid)$|https://orcid.org/$(this_orcid)$]]
<$list filter="[<currentTiddler>get[orcid]]" variable="this_orcid">
''ORCID'': <<mylink>>
</$list>
Note that the filter uses "get[orcid]" rather than "has[orcid]". This not only tests to see if the "orcid" field is non-blank, but also fetches it's value, which is set into the "this_orcid" variable. Then, the $(this_orcid)$ syntax within the macro does a string substitution, based on the current value of the "this_orcid" variable.
Note also that the $(...)$ syntax can only be used within a macro. Keep in mind that macros only do two things:
- replace instances of $(...)$ with values from variables, where the variables are defined *outside* of the macro
- replace instances of $...$ with values from parameters, where the parameters are passed into the macro
All other processing of the macro output is performed by the calling context. In the above example, this means the resulting link syntax -- [[foo|https:/
orcid.org/foo]] -- is parsed and wikified after being "returned" from the macro.
Another point about macro syntax: if you want to use the "parameter" method to pass the "this_orcid" value into the macro, you would write something like this:
\define mylink(id) [[$id$|https://orcid.org/$id$]]
<$list filter="[<currentTiddler>get[orcid]]" variable="this_orcid">
''ORCID'': <$macrocall $name="mylink" id=<<this_orcid>> />
</$list>
Note the use of the <$macrocall> widget to invoke the "mylink" macro with the "id" parameter set to the current value of the "this_orcid" variable. This is needed because you can't nest the variable reference -- <<this_orcid>> within the shorthand <<mylink>> syntax; i.e., you CANNOT write <<mylink <<this_orcide>>>> because the closing ">>" of the variable reference would be seen as ending the enclosing macro, with the second ">>" being left over to "fall out" as displayed text.
TiddlyWiki syntax is consistent, but somewhat less flexible than other languages. While this may be a little confusing at first, once you get used to it's peculiarities, it becomes easier.