1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-01-11 18:00:26 +00:00

[DOCS] Improve "each operator" links (#8798)

This commit is contained in:
Mario Pietsch 2024-12-05 13:18:16 +01:00 committed by GitHub
parent 59548f066a
commit 86d3e9560b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 19 additions and 19 deletions

View File

@ -1,18 +1,18 @@
title: GroupedLists
tags: ListWidget Lists
created: 20150106180000000
modified: 20150221230117000
modified: 20241204085601176
tags: ListWidget Lists
title: GroupedLists
The following sidebar tabs give examples of grouped lists created by nesting.
!! Types Tab
!! [[Types Tab|$:/core/ui/MoreSideBar/Types]]
For the [[Types|$:/core/ui/MoreSideBar/Types]] tab, the outer list filter as shown below selects each discrete value found in the `type` field. The inner list filter selects all the (non-system) tiddlers with that type.
For the "Types Tab", the outer list filter as shown below selects each discrete value found in the `type` field. The inner list filter selects all the (non-system) tiddlers with that type.
<<tw-code "$:/core/ui/MoreSideBar/Types">>
!! Recent Tab
!! [[Recent Tab|$:/core/ui/SideBar/Recent]]
The list in the [[Recent|$:/core/ui/SideBar/Recent]] tab is generated using the <<.mlink timeline>> macro. Here, the outer list filter selects each discrete day found in the `modified` field, while the inner list filter selects all the tiddlers dated the same day in the `modified` field.
The list in the "Recent Tab" is generated using the <<.mlink timeline>> macro. Here, the outer list filter selects each discrete day found in the `modified` field, while the inner list filter selects all the tiddlers dated the same day in the `modified` field.
<<tw-code-link "$:/core/macros/timeline">>
<<tw-code "$:/core/macros/timeline">>

View File

@ -1,15 +1,15 @@
caption: each
created: 20140410103123179
modified: 20191209085901849
modified: 20241204090042816
op-input: a [[selection of titles|Title Selection]]
op-output: a selection containing the first input title encountered for each distinct value of field <<.place F>>
op-parameter: the name of a [[field|TiddlerFields]], defaulting to <<.field title>>
op-parameter-name: F
op-purpose: select one of each group of input titles by field
op-suffix: optionally, `list-item` or `value`
tags: [[Filter Operators]] [[Group Operators]]
title: each Operator
type: text/vnd.tiddlywiki
caption: each
op-purpose: select one of each group of input titles by field
op-input: a [[selection of titles|Title Selection]]
op-suffix: optionally, `list-item` or `value`
op-parameter: the name of a [[field|TiddlerFields]], defaulting to <<.field title>>
op-parameter-name: F
op-output: a selection containing the first input title encountered for each distinct value of field <<.place F>>
Each input title is processed in turn. The value of field <<.place F>> in the corresponding tiddler is examined.
@ -22,4 +22,6 @@ Each input title is processed in turn. The value of field <<.place F>> in the co
Note that if a tiddler does not contain field <<.place F>>, it is treated as if the value of the field were empty. Thus, a filter expression such as `[each[motovun]]` will return one tiddler that doesn't have a `motovun` field, as well as one tiddler with each distinct value of that field, if any. To obtain just the tiddlers that have a non-blank value for the `motovun` field one can use `[each[motovun]has[motovun]]`.
<<.note"""For an example of using the <<.op each>> operator to generate a two-tier list of groups and members, see [[GroupedLists]].""">>
<<.operator-examples "each">>

View File

@ -1,5 +1,5 @@
created: 20150118134611000
modified: 20150118183152000
modified: 20241204085904594
tags: [[each Operator]] [[Operator Examples]]
title: each Operator (Examples)
type: text/vnd.tiddlywiki
@ -9,5 +9,3 @@ type: text/vnd.tiddlywiki
<<.operator-example 3 "[each:list-item[list]]" "all tiddlers listed anywhere in the core list field">>
<<.operator-example 4 "[[Non existing]] [[GettingStarted]] +[each:value[]]" "Compare this to `+[each[]]` below">>
<<.operator-example 5 "[[Non existing]] [[GettingStarted]] +[each[]]" "Compare this to `+[each:value[]]` above">>
For an example of using the <<.op each>> operator to generate a two-tier list of groups and members, see [[GroupedLists]].