I have created a template for a button and I'm trying to turn it into a macro that has the option to also add <<currentTiddler>> as a tag. It's not clear to me from the manual how to do this so I would really appreciate any help.
Here is a simplified example to illustrate what I mean. Say this is my button:
\define add-tiddler()
<$button><$action-sendmessage $message="tm-new-tiddler" title=<<now>> tags="tag1" />
New Tiddler
</$button>
\end
I'm trying to modify the macro so that <<add-tiddler tag:"false">> would run something like this:
<$action-sendmessage $message="tm-new-tiddler" title=<<now>> tags="tag1" />
While <<add-tiddler tag:"true">> would run this:
<$action-sendmessage $message="tm-new-tiddler" title=<<now>> tags="tag1 [[<<currentTiddler>>]]" />
I'm trying to avoid creating two separate templates/macros because my actual button code is pretty long and it will be awkward to have to edit both every time I want to make a change.
Thanks in advance for your help.