Managed to make it work with two modifications: <$list variable="parent" filter="[all[current]tags[]!limit[1]]"> <$list filter="[title<parent>tagging[]before<currentTiddler>sort[list]]"> prev: <$link><<toc-caption>></$link> </$list> <$list filter="[title<parent>tagging[]after<currentTiddler>sort[list]]"> next: <$link><<toc-caption>></$link> </$list> </$list>
For some reason limit[1] yields the last tiddler not the first and my toc is sorted by list field I don't understand what `variable` list widget parameter is generally doing (or specifically here either...). Does it just declare a variable and puts filter result into it? Do you just separate and abstract the common filter part with it or is it for something else? I have two tags on a tiddler I call it from. When I transclude it within the list it yields the resulting tag, but when I remove the !limit[1] part it regenerates both inner lists for each of two resulting tags. Wierd. Does it work as an iterator of sorts? Not exactly what I had in mind as this requires the thing to be present on every entry rather than on the toc tiddler. But I'll try to adapt your solution to that as well and post here what I manage. On Thursday, August 3, 2017 at 11:00:13 PM UTC+3, Eric Shulman wrote: > > On Thursday, August 3, 2017 at 10:43:51 AM UTC-7, Vayu Asura wrote: >> >> ... >> > next[] and previous[] operators... require hard-coded list field to work >> properly >> ... >> If there is a more reasonable way to do it esp without hard-coded lists, >> I'm very open to suggestions. >> > > before[] and after[] filters work like previous[] and next[] but use the > current filter result instead of a hard-coded list. > > Perhaps something like this will fit your needs: > > <$list variable="parent" filter="[all[current]tags[]limit[1]]"> > <$list filter="[title<parent>tagging[]before<currentTiddler>]"> > prev: <$link><<toc-caption>></$link> > </$list> > <$list filter="[title<parent>tagging[]after<currentTiddler>]"> > next: <$link><<toc-caption>></$link> > </$list> > </$list> > > Notes: > * the outer <$list> assumes that the first tag on the current tiddler is > the "parent" (a common usage for the <<toc>> macro) > * the inner <$list> uses the tagging[] filter to get the siblings from the > parent, followed by the before[] or after[] filter to find the > previous/next sibling of the current tiddler > > let me know how it goes... > > enjoy, > -e > Eric Shulman > TiddlyTools.com: "Small Tools for Big Ideas" (tm) > InsideTiddlyWiki: The Missing Manuals > > > -- 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 tiddlywiki+unsubscr...@googlegroups.com. To post to this group, send email to tiddlywiki@googlegroups.com. 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/0953a9d9-8aff-468b-9050-5f9c6988708b%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.