You can also wrap the list with a Wikify, although I like Marks solution
better.
See how I reuse the variable name;
<$wikify name=combo text="<<combo>>">
*<<combo>> | <$list
filter="[tag[Journal]prefix<combo>]">{{!!title}}</$list>*
</$wikfy>
PS in your Question you refer to YYY not YYYY but I doubt its important
here.
Regards
Tones
On Tuesday, 20 April 2021 at 07:14:30 UTC+10 Mark S. wrote:
> The combo variable isn't being rendered and then passed to the list filter
> as you might imagine. It's being rendered right there in place, and the
> filter is getting the literal text.
>
> Try getting rid of the <$set> widget and replacing the text in the middle
> with:
>
> <$vars combo={{{ [<year>]addsuffix[-]addsuffix<month>] }}} >
> <<combo>> | <$list filter="[tag[Journal]prefix<combo>]">{{!!title}}</$list>
> </$vars>
>
> I'm not sure if the nested bit with the <$tiddler tiddler=year> widget is
> necessary.
> On Monday, April 19, 2021 at 1:52:48 PM UTC-7 Brian Radspinner wrote:
>
>>
>> Hello all,
>>
>> I am trying to get a nested timeline of Journal entries. Each Journal
>> tiddler title starts with the prefix "YYY-0MM-0DD/" (example:
>> *2021-04-19/Walking*). For each day, there is also an empty tiddler
>> titled with the format "YYY-0MM-0DD" (example: *2021-04-19*). These
>> "day" tiddlers also have a "year" and "month" field (example: year=2021,
>> month=-4).
>>
>> I am trying to get a nested timeline list using the fields to break out
>> the year & months, then finally display a list of transcluded entries for
>> each year-month combo. So far I have the below code:
>> ----------------------------
>> \define combo() $(getCombo)$
>>
>> <$set name="getCombo" value="""<<year>>-<<month>>""" >
>>
>> <$list
>> filter="[tag[Journal]has:field[year]each[year]get[year]!nsort[title]]"
>> variable="year">
>> <$tiddler tiddler=<<year>>>
>> <<year>><br/>
>> <$list
>> filter="[prefix<year>has:field[month]each[month]get[month]!nsort[title]]"
>> variable="month">
>> <$tiddler tiddler=<<month>>>
>> {{!!title}}<br/>
>> <<combo>> | <$list
>> filter="[tag[Journal]prefix<combo>]">{{!!title}}</$list>
>> </$tiddler><hr/>
>> </$list>
>> </$tiddler><br/><br/>
>> </$list>
>>
>> </$set>
>> ----------------------------
>>
>> Everything works great until the line *<<combo>> | <$list
>> filter="[tag[Journal]prefix<combo>]">{{!!title}}</$list>*. Outside the
>> list, the <<combo>> variable properly displays, but inside the list <combo>
>> is (maybe) not working. I am getting an empty list instead a list of
>> tiddler titles prefixed with the <<year>>-<<month>> variables.
>>
>> Any suggestions?
>>
>> Thanks
>>
>
--
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/1ffe8b4e-516c-40d8-81b3-ff95d86ab89fn%40googlegroups.com.