Merge remote-tracking branch 'origin/tiddlywiki-com'

This commit is contained in:
Jeremy Ruston 2023-08-20 11:18:43 +01:00
commit 9201d2bedc
7 changed files with 51 additions and 11 deletions

View File

@ -1,11 +1,11 @@
created: 20140129085406905
modified: 20210106151027268
modified: 20230805140720289
tags: [[Other Resources]] Articles
title: "TiddlyWiki Posts" by Jeffrey Kishner
type: text/vnd.tiddlywiki
url: http://blog.jeffreykishner.com/tiddlywiki/
url: https://web.archive.org/web/20221015011644/http://blog.jeffreykishner.com/tiddlywiki/
A collection of articles covering integration with Fargo, Font Awesome and Google Calendar, and tips for managing task lists.
A collection of articles covering integration with Fargo, Font Awesome and Google Calendar, and tips for managing task lists. The original site is missing, but a link to an archive is provided.
{{!!url}}

View File

@ -13,7 +13,7 @@ This tiddler describes the different ways in which [[Procedures|Procedures]] can
Procedures are created using the [[Pragma: \procedure]] at the start of a tiddler. The definitions are available in the rest of the tiddler that defines them, plus any tiddlers that it transcludes.
```
\define my-procedure(param)
\procedure my-procedure(param)
This is the procedure text (param=<<param>>)
\end
```

View File

@ -1,6 +1,6 @@
caption: action-listops
created: 20141025120850184
modified: 20230301183438774
modified: 20230805103548113
myfield:
tags: ActionWidgets Widgets
title: ActionListopsWidget
@ -22,6 +22,28 @@ The ''action-listops'' widget is invisible. Any content within it is ignored.
|$subfilter |An optional subfilter expression, which takes the list being manipulated as input, and saves the modified list back to the field/index being manipulated |
|$tags |An optional subfilter expression, which takes the <<.field tags>> field of the target tiddler as input, and saves the modified list of tags back to the <<.field tags>> field |
!! Note on subfilter expressions
If the manipulation depends on the current contents of the list, e.g. when using the <<.olink toggle>> operator to toggle the presence of an element, the [[Filter Run]] would be prefixed with the `+` / `:and` [[filter run prefix|Filter Expression]] so that it properly receives the list as input.
```
<$action-listops $subfilter="+[toggle[List Item]]"/>
```
The above widget will toggle the presence of the element <<.value "List Item">> in the field <<.field list>> of the current tiddler, removing or adding the element as necessary.
Similarly, if an element is to always be removed when it is present, the `-` / `:except` [[filter run prefix|Filter Expression]] can be used. Both of the following yield the same result:
```
<$action-listops $subfilter="-[[List Item]]"/>
<$action-listops $subfilter="+[remove[List Item]]"/>
```
Without any prefixes, the filter run output is simply [[dominantly appended|Dominant Append]] to the list.
See also the [[Examples|ActionListopsWidget (Examples)]].
!! Using $filter or $subfilter
Standalone use of the `$subfilter` attribute can be replaced by using a (more complicated) `$filter` attribute value.
@ -103,4 +125,4 @@ Add 'abc' to 'myfield'
The [[enlist Operator]] with `raw` suffix will enlist the list saved in <<.field myfield>> of the current tiddler without de-duplication, while e.g. the [[list Operator]] will always de-duplicate. The widget then adds the item <<.value abc>> -- whether or not it is already included in the list -- and replaces the original list in <<.field myfield>>.
! [[Examples|ActionListopsWidget (Examples)]]
! [[Examples|ActionListopsWidget (Examples)]]

View File

@ -1,6 +1,6 @@
caption: action-popup
created: 20200303114556528
modified: 20220815205132124
modified: 20230731193016105
tags: Widgets ActionWidgets
title: ActionPopupWidget
type: text/vnd.tiddlywiki
@ -30,6 +30,6 @@ Here is an example of button that triggers the "more" button in the sidebar "Too
<$macrocall $name='wikitext-example-without-html'
src='<$button>
<$action-setfield $tiddler="$:/state/tab/sidebar--595412856" $value="$:/core/ui/SideBar/Tools"/>
<$action-popup $state="$:/state/popup/more-2053862905" $coords="(0,20,0,0)"/>
<$action-popup $state="$:/state/popup/more--810643385" $coords="(0,20,0,0)"/>
Click me!
</$button>'/>

View File

@ -1,8 +1,9 @@
created: 20230301174431218
list: efg hlm pqr
modified: 20230301174431218
modified: 20230805103601224
myfield:
revision: 0
tags: ActionListopsWidget
title: ActionListopsWidget (Examples)
type: text/vnd.tiddlywiki
@ -47,6 +48,16 @@ Unmangle List
</$list>"""/>
---
The following example toggles the tag <<.value Examples>> for the current tiddler.
<$macrocall $name='wikitext-example-without-html'
src="""<$button>
<$action-listops $tags="+[toggle[Examples]]"/>
Toggle 'Examples' tag
</$button>
"""/>
---
In this example we shall append a few tags to the 'tags' field of this tiddler (the default). We shall then remove some of the appended tags.

View File

@ -1,10 +1,10 @@
created: 20230615045526689
modified: 20230615060059476
modified: 20230731210638956
tags: WikiText
title: Widget Attributes
type: text/vnd.tiddlywiki
Attributes of HTML elements and widgets can be specified in several different ways:
Attributes of [[HTML elements|HTML in WikiText]] and widgets can be specified in several different ways:
* [[a literal string|Literal Attribute Values]]
* [[a transclusion of a textReference|Transcluded Attribute Values]]
@ -19,3 +19,8 @@ Attributes of HTML elements and widgets can be specified in several different wa
|filtered |triple curly braces around a filter expression|
|substituted|single or triple backticks around the text to be processed for substitutions|
<$list filter="[[Literal Attribute Values]] [[Transcluded Attribute Values]] [[Variable Attribute Values]] [[Filtered Attribute Values]] [[Substituted Attribute Values]]">
<$link><h1><$text text=<<currentTiddler>>/></h1></$link>
<$transclude mode="block"/>
</$list>

View File

@ -545,3 +545,5 @@ Eric Haberstroh, @pille1842, 2023/07/23
@TiddlyTweeter, 2023/07/25
@catter-fly, 2023/07/27
@cmo-pomerium, 2023/08/03