Thank you Eric!

That's did the trick for me to keep my macro with default value of input 
parameter as currentTiddler!

Cheers
Mohammad

On Monday, October 7, 2019 at 12:46:09 AM UTC+3:30, Eric Shulman wrote:
>
> On Sunday, October 6, 2019 at 10:38:45 AM UTC-7, Mohammad wrote:
>>
>> I understood transclusion is inheritable.
>> On Sunday, October 6, 2019 at 8:08:56 PM UTC+3:30, Jeremy Ruston wrote:
>>
>>> The reason the content of Test01 displays differently in the tiddler 
>>> “Tabs Macro Example” is because the current tiddler is “Tabs Macro 
>>> Example”, which is inherited by the transcluded content of Test01. When 
>>> displaying Test01 on its own the current tiddler will be “Test01”.
>>>
>>
> A bit more clarification:
>
> When displaying tabs, the value of <<currentTiddler>> is dependent upon 
> the tiddler in which the tabset is rendered.  This allows you to use tabs 
> to show information related to that containing tiddler (e.g., the "info" 
> tabset displayed from the "more" menu for each tiddler shows information 
> about the tiddler containing that tabset).  However, for some use-cases, 
> the intention of the tabset is to simply show a set of tiddlers, where the 
> content of each tiddler is independent of the tabset in which they are 
> shown.
>
> Fortunately, there IS a way to achieve this, by using the <<currentTab>> 
> variable within the specific tab content, like this:
>
> <$tiddler tiddler=<<currentTab>>
> ... normal tiddler content here ...
> </$tiddler>
>
> When the above code is displayed directly (i.e., NOT within a tab), then 
> <<currentTab>> has *no value*, so the <$tiddler> widget does nothing, and 
> you get content using that tiddler's fields as the source.
>
> When the tiddler is displayed from within a tab, then the <<currentTab>> 
> value is the title of the source tiddler for that tab so you still get 
> content using that tiddler's field as the source.
>
> hope this helps,
>
> enjoy,
> -e
>
>
>
>
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/97919342-13cd-4785-b5d2-2e7f155fe34b%40googlegroups.com.

Reply via email to