Hi Daniel,
Mario's syntax uses the macrocall widget, which is a somewhat more formal
way of calling a macro that works better in some situations.
The problem with the timeline macro is that it doesn't give you access to
the sorting order (A/D), as you can see in this filter:
[!is[system]$subfilter$has[$dateField$]*!**sort*[$dateField$]limit[$limit$]
eachday[$dateField$]]
You can't reach the *!sort* in the macro invocation. You can try putting
the following into a tiddler, which is modified from the original timeline
code:
\define timeline2(limit:"100",format:"DDth MMM YYYY",subfilter:"",dateField:
"modified")
<div class="tc-timeline">
<$list filter=
"[!is[system]$subfilter$has[$dateField$]sort[$dateField$]limit[$limit$]eachday[$dateField$]]"
>
<div class="tc-menu-list-item">
<$view field="$dateField$" format="date" template="$format$"/>
<$list filter=
"[sameday:$dateField${!!$dateField$}!is[system]$subfilter$sort[$dateField$]]"
>
<div class="tc-menu-list-subitem">
<$link to={{!!title}}>
<<timeline-title>>
</$link>
</div>
</$list>
</div>
</$list>
</div>
\end
<$macrocall $name="timeline2" subfilter="" format={{$:/language/
RecentChanges/DateFormat}} dateField="created"/>
It seemed to work in my quick test, though I didn't look at dates too
closely.
Good luck!
Mark
On Thursday, February 23, 2017 at 4:12:26 PM UTC-8, Daniel Cunningham wrote:
>
> Many thanks, Mario! I tried that, and it works.
>
> But rather than change a shadow tiddler, I elected to put in into a
> "end-user" tiddler, that I can then place in the sidebar with a
> "$:tags/SideBar" tag. That gives me the functionality I was looking for.
> Also, I won't shoot myself in the foot if core changes during my "learning
> curve". :-)
>
> As a follow-up, the results are still in descending order (same as the
> original Recent tab functionality). So, to get ascending order, I recon I
> should apply a sort operator to the results of your code segment. But the
> syntax of your code is very different than that shown in the docs -- can
> you give guidance on this?
>
> Best,
>
> -- Daniel
>
>
> On Wednesday, February 22, 2017 at 4:22:50 PM UTC-8, PMario wrote:
>>
>> On Wednesday, February 22, 2017 at 11:48:49 PM UTC+1, Daniel Cunningham
>> wrote:
>>>
>>> And then what you are saying is that since this is embedded in the
>>> timeline macro, any sort criteria I try to apply to "created" will be to no
>>> avail?
>>>
>>
>> Have a look at the docs: http://tiddlywiki.com/#timeline%20Macro
>>
>>
>>>
>>> Unless... I clone the macro & modfify it to use the "created" field?
>>>
>>
>> Edit: $:/core/ui/SideBar/Recent
>> <http://tiddlywiki.com/#%24%3A%2Fcore%2Fui%2FSideBar%2FRecent>
>>
>> like so: <$macrocall $name="timeline"
>> format={{$:/language/RecentChanges/DateFormat}} dateField="created"/>
>>
>> and you should be good to go.
>>
>> have fun!
>> mario
>>
>>
--
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 post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/7e045124-c89f-476b-9d3e-6992563bb9c1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.