From 81b4e99ccc3c2ca3c3f960b25c4463f60e79c268 Mon Sep 17 00:00:00 2001 From: Marxsal Date: Fri, 22 Oct 2021 06:35:25 -0700 Subject: [PATCH 1/5] Update LazyLoading.tid (#6099) --- editions/tw5.com/tiddlers/features/LazyLoading.tid | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/editions/tw5.com/tiddlers/features/LazyLoading.tid b/editions/tw5.com/tiddlers/features/LazyLoading.tid index 893e22bd2..5372fb35b 100644 --- a/editions/tw5.com/tiddlers/features/LazyLoading.tid +++ b/editions/tw5.com/tiddlers/features/LazyLoading.tid @@ -1,5 +1,5 @@ created: 20140206214608586 -modified: 20180701185417525 +modified: 20211009145417525 tags: Features title: LazyLoading type: text/vnd.tiddlywiki @@ -11,7 +11,7 @@ Lazy loading can be used in two configurations: * When running [[TiddlyWiki on Node.js]], just image tiddlers or all non-system tiddlers can be subject to lazy loading * When running [[TiddlyWiki in the Sky for TiddlyWeb]], all tiddlers are subject to lazy loading -See the LazyLoadingMechanism for details of how lazy loading is implemented. +See the [[Lazy Loading Mechanism|https://tiddlywiki.com/dev/#LazyLoadingMechanism]] for details of how lazy loading is implemented. ! Lazy loading under Node.js @@ -28,4 +28,3 @@ To apply lazy loading to all non-system tiddlers use this command: ``` tiddlywiki --listen root-tiddler=$:/core/save/lazy-all ``` - From 0cfe6597d4b041a8593ba5b47a3d893cbf931b21 Mon Sep 17 00:00:00 2001 From: Mario Pietsch Date: Mon, 25 Oct 2021 17:23:57 +0200 Subject: [PATCH 2/5] Add new improved "Icon Gallery" (#6112) * add a core icon selector to the docs * Add Icon Gallery and improve links to expose the function * re-add the ImageGallery Example tiddler --- editions/tw5.com/tiddlers/Icon Gallery.tid | 14 +++++++++++++ .../demonstrations/ImageGallery Example.tid | 21 +++++-------------- ... the things you can do with TiddlyWiki.tid | 4 ++-- ... create dynamic editor toolbar buttons.tid | 4 ++-- .../tiddlers/macros/image-picker Macro.tid | 4 ++-- .../systemtags/SystemTag_ $__tags_Image.tid | 4 ++-- 6 files changed, 27 insertions(+), 24 deletions(-) create mode 100644 editions/tw5.com/tiddlers/Icon Gallery.tid diff --git a/editions/tw5.com/tiddlers/Icon Gallery.tid b/editions/tw5.com/tiddlers/Icon Gallery.tid new file mode 100644 index 000000000..947dc8f78 --- /dev/null +++ b/editions/tw5.com/tiddlers/Icon Gallery.tid @@ -0,0 +1,14 @@ +created: 20211013132515594 +modified: 20211018102307833 +tags: Learning +title: Icon Gallery +type: text/vnd.tiddlywiki + +\define copyActions() <$action-sendmessage $message="tm-copy-to-clipboard" $param=<>/> + +This gallery let's you ''click'' the ''icons'' and ''copies the title to the clipboard''. So it's easy to transclude them into other UI elements. + +
+<$macrocall $name="image-picker-list" filter="[all[shadows+tiddlers]tag[$:/tags/Image]]" actions=<> /> +
+ diff --git a/editions/tw5.com/tiddlers/demonstrations/ImageGallery Example.tid b/editions/tw5.com/tiddlers/demonstrations/ImageGallery Example.tid index d0d2538df..8827c7260 100644 --- a/editions/tw5.com/tiddlers/demonstrations/ImageGallery Example.tid +++ b/editions/tw5.com/tiddlers/demonstrations/ImageGallery Example.tid @@ -1,22 +1,11 @@ created: 20140809113603449 -modified: 20150520161451179 +modified: 20211022195248529 tags: Learning title: ImageGallery Example type: text/vnd.tiddlywiki -Here is an example of using the ListWidget and the TranscludeWidget to show a grid of all system images (ie, tiddlers tagged [[$:/tags/Image]]). +''Info:'' The "~ImageGallery Example" has been replaced. This tiddler will be kept, so external links won't break. Below you see the [[Icon Gallery]] as a transcluded tiddler. - - +--- + +{{Icon Gallery}} \ No newline at end of file diff --git a/editions/tw5.com/tiddlers/hellothere/Some of the things you can do with TiddlyWiki.tid b/editions/tw5.com/tiddlers/hellothere/Some of the things you can do with TiddlyWiki.tid index 8ca09ca71..b2cc5d6aa 100644 --- a/editions/tw5.com/tiddlers/hellothere/Some of the things you can do with TiddlyWiki.tid +++ b/editions/tw5.com/tiddlers/hellothere/Some of the things you can do with TiddlyWiki.tid @@ -1,5 +1,5 @@ created: 20140904090300000 -modified: 20160602051709631 +modified: 20211018102355896 tags: HelloThere title: Some of the things you can do with TiddlyWiki type: text/vnd.tiddlywiki @@ -11,7 +11,7 @@ type: text/vnd.tiddlywiki * Inventory just about anything: your recipes, personal library, contacts, music collection, and more * Create a blog or website * Write a book -* Organise your images into galleries (see our [[ImageGallery Example]]) +* Organise your images into galleries (see [[Icon Gallery]]) * Share the information in your ~TiddlyWiki with others, as an online file, as a file attachment, as a tiddler file, or as a link to a specific online tiddler (try clicking and dragging a tiddler from one ~TiddlyWiki file to another to see what happens) * Draw a sketch (Edit [[Motovun Jack.jpg]] and start drawing over the image to see what happens) * Use familiar web user interface elements such as lightboxes - see SampleWizard diff --git a/editions/tw5.com/tiddlers/howtos/How to create dynamic editor toolbar buttons.tid b/editions/tw5.com/tiddlers/howtos/How to create dynamic editor toolbar buttons.tid index 27ed11d03..03df1adca 100644 --- a/editions/tw5.com/tiddlers/howtos/How to create dynamic editor toolbar buttons.tid +++ b/editions/tw5.com/tiddlers/howtos/How to create dynamic editor toolbar buttons.tid @@ -1,5 +1,5 @@ created: 20201216182347597 -modified: 20201217193318816 +modified: 20211018102328148 tags: title: How to create dynamic editor toolbar buttons type: text/vnd.tiddlywiki @@ -86,7 +86,7 @@ This tiddler contains all the necessary elements that are important for toolbar : Is used as the button tooltip ; icon -: Assigns the button icon. We use `$:/core/images/spiral` {{$:/core/images/spiral}} here. +: Assigns the button icon. We use `$:/core/images/spiral` {{$:/core/images/spiral}} here. More button icons can be found at the [[Icon Gallery]] ; shortcuts : This is the [[Keyboard Shortcut Descriptor]] eg: `((temp-bold))` diff --git a/editions/tw5.com/tiddlers/macros/image-picker Macro.tid b/editions/tw5.com/tiddlers/macros/image-picker Macro.tid index d6e2d38dd..8db810799 100644 --- a/editions/tw5.com/tiddlers/macros/image-picker Macro.tid +++ b/editions/tw5.com/tiddlers/macros/image-picker Macro.tid @@ -1,6 +1,6 @@ caption: image-picker created: 20160418155531395 -modified: 20160418155805435 +modified: 20211018102346306 tags: Macros [[Core Macros]] title: image-picker Macro type: text/vnd.tiddlywiki @@ -18,4 +18,4 @@ The images are selected by means of a [[filter expression|Filter Expression]], i > `[all[shadows+tiddlers]is[image]$subfilter$!has[draft.of]] -[type[application/pdf]] +[sort[title]]` -<<.macro-examples "image-picker">> +See: <<.macro-examples "image-picker">> and [[Icon Gallery]] diff --git a/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid b/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid index 7eef1f05a..434aa8ac3 100644 --- a/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid +++ b/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid @@ -1,9 +1,9 @@ caption: $:/tags/Image created: 20180926170345251 description: marks (core) images -modified: 20180926171456494 +modified: 20211018102336342 tags: SystemTags title: SystemTag: $:/tags/Image type: text/vnd.tiddlywiki -The [[system tag|SystemTags]] `$:/tags/Image` marks (core) images \ No newline at end of file +The [[system tag|SystemTags]] `$:/tags/Image` marks (core) images. An overview of system icons can be found at: [[Icon Gallery]] \ No newline at end of file From 3d86d62a6e091644b3d7de0e6429a2081d7f987d Mon Sep 17 00:00:00 2001 From: "jeremy@jermolene.com" Date: Mon, 25 Oct 2021 16:29:53 +0100 Subject: [PATCH 3/5] Minor tweaks to 0cfe6597d4b041a8593ba5b47a3d893cbf931b21 --- editions/tw5.com/tiddlers/Icon Gallery.tid | 2 +- .../tw5.com/tiddlers/demonstrations/ImageGallery Example.tid | 4 ++-- .../howtos/How to create dynamic editor toolbar buttons.tid | 2 +- editions/tw5.com/tiddlers/macros/image-picker Macro.tid | 4 ++-- .../tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/editions/tw5.com/tiddlers/Icon Gallery.tid b/editions/tw5.com/tiddlers/Icon Gallery.tid index 947dc8f78..9985cbc0f 100644 --- a/editions/tw5.com/tiddlers/Icon Gallery.tid +++ b/editions/tw5.com/tiddlers/Icon Gallery.tid @@ -6,7 +6,7 @@ type: text/vnd.tiddlywiki \define copyActions() <$action-sendmessage $message="tm-copy-to-clipboard" $param=<>/> -This gallery let's you ''click'' the ''icons'' and ''copies the title to the clipboard''. So it's easy to transclude them into other UI elements. +<<.tip "Click an icon to copy the title to the clipboard">>
<$macrocall $name="image-picker-list" filter="[all[shadows+tiddlers]tag[$:/tags/Image]]" actions=<> /> diff --git a/editions/tw5.com/tiddlers/demonstrations/ImageGallery Example.tid b/editions/tw5.com/tiddlers/demonstrations/ImageGallery Example.tid index 8827c7260..c9df4ac0b 100644 --- a/editions/tw5.com/tiddlers/demonstrations/ImageGallery Example.tid +++ b/editions/tw5.com/tiddlers/demonstrations/ImageGallery Example.tid @@ -4,8 +4,8 @@ tags: Learning title: ImageGallery Example type: text/vnd.tiddlywiki -''Info:'' The "~ImageGallery Example" has been replaced. This tiddler will be kept, so external links won't break. Below you see the [[Icon Gallery]] as a transcluded tiddler. +<<.warning "The [[ImageGallery Example]] has been replaced with the new [[Icon Gallery]] which is transcluded below">> --- -{{Icon Gallery}} \ No newline at end of file +{{Icon Gallery}} diff --git a/editions/tw5.com/tiddlers/howtos/How to create dynamic editor toolbar buttons.tid b/editions/tw5.com/tiddlers/howtos/How to create dynamic editor toolbar buttons.tid index 03df1adca..5ec53f2ee 100644 --- a/editions/tw5.com/tiddlers/howtos/How to create dynamic editor toolbar buttons.tid +++ b/editions/tw5.com/tiddlers/howtos/How to create dynamic editor toolbar buttons.tid @@ -86,7 +86,7 @@ This tiddler contains all the necessary elements that are important for toolbar : Is used as the button tooltip ; icon -: Assigns the button icon. We use `$:/core/images/spiral` {{$:/core/images/spiral}} here. More button icons can be found at the [[Icon Gallery]] +: Assigns the button icon. We use `$:/core/images/spiral` {{$:/core/images/spiral}} here. More button icons can be found in the [[Icon Gallery]] ; shortcuts : This is the [[Keyboard Shortcut Descriptor]] eg: `((temp-bold))` diff --git a/editions/tw5.com/tiddlers/macros/image-picker Macro.tid b/editions/tw5.com/tiddlers/macros/image-picker Macro.tid index 8db810799..d6e2d38dd 100644 --- a/editions/tw5.com/tiddlers/macros/image-picker Macro.tid +++ b/editions/tw5.com/tiddlers/macros/image-picker Macro.tid @@ -1,6 +1,6 @@ caption: image-picker created: 20160418155531395 -modified: 20211018102346306 +modified: 20160418155805435 tags: Macros [[Core Macros]] title: image-picker Macro type: text/vnd.tiddlywiki @@ -18,4 +18,4 @@ The images are selected by means of a [[filter expression|Filter Expression]], i > `[all[shadows+tiddlers]is[image]$subfilter$!has[draft.of]] -[type[application/pdf]] +[sort[title]]` -See: <<.macro-examples "image-picker">> and [[Icon Gallery]] +<<.macro-examples "image-picker">> diff --git a/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid b/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid index 434aa8ac3..0fdc44f4a 100644 --- a/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid +++ b/editions/tw5.com/tiddlers/systemtags/SystemTag_ $__tags_Image.tid @@ -6,4 +6,4 @@ tags: SystemTags title: SystemTag: $:/tags/Image type: text/vnd.tiddlywiki -The [[system tag|SystemTags]] `$:/tags/Image` marks (core) images. An overview of system icons can be found at: [[Icon Gallery]] \ No newline at end of file +The [[system tag|SystemTags]] `$:/tags/Image` marks core images. An overview of system icons can be found in the [[Icon Gallery]] \ No newline at end of file From 989947b99a385c6c917946373480d67dadd3528b Mon Sep 17 00:00:00 2001 From: btheado Date: Mon, 25 Oct 2021 11:35:57 -0400 Subject: [PATCH 4/5] Make filter operater examples live-editable (#6139) * Make filter operator examples easily editable * Add 'Reset' button to filter operator examples * Only display the reset button when filter has changed * Introduce '.doc-example input' class rather than re-use tc-advanced-search to make input wider * Grab focus for the filter text box * Fix firefox ctrl-z/undo issue by replacing list widget with filter transclusion * Replace spaced indent with tabs to make it consistent with the other code --- editions/tw5.com/tiddlers/system/doc-styles.tid | 3 +++ .../tw5.com/tiddlers/system/operator-macros.tid | 17 ++++++++++++----- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/editions/tw5.com/tiddlers/system/doc-styles.tid b/editions/tw5.com/tiddlers/system/doc-styles.tid index 2e33a266c..35b955105 100644 --- a/editions/tw5.com/tiddlers/system/doc-styles.tid +++ b/editions/tw5.com/tiddlers/system/doc-styles.tid @@ -110,6 +110,9 @@ td svg { padding-bottom: 0; margin-top: 0.2em; } +.doc-example input { + width: 60%; +} .doc-example pre:first-child { margin-top: 0; } diff --git a/editions/tw5.com/tiddlers/system/operator-macros.tid b/editions/tw5.com/tiddlers/system/operator-macros.tid index df917402b..477968945 100644 --- a/editions/tw5.com/tiddlers/system/operator-macros.tid +++ b/editions/tw5.com/tiddlers/system/operator-macros.tid @@ -5,22 +5,29 @@ tags: $:/tags/Macro \define .operator-examples(op,text:"Examples") <$link to="$op$ Operator (Examples)">$text$ +\define .operator-example-tryit-actions() <$action-setfield $tiddler=<<.state>> text="show" filter=<<__eg__>>/> \define .operator-example(n,eg,ie)
-`$eg$` -<$macrocall $name=".if" cond="""$ie$""" then="""
→ $ie$
"""/> <$list filter="[title<.state-prefix>addsuffix{!!title}addsuffix[/]addsuffix[$n$]]" variable=".state"> <$reveal state=<<.state>> type="nomatch" text="show"> + `$eg$` + <$macrocall $name=".if" cond="""$ie$""" then="""
→ $ie$
"""/>
-
<$button set=<<.state>> setTo="show">Try it
+
<$button actions=<<.operator-example-tryit-actions>>>Try it
<$reveal state=<<.state>> type="match" text="show"> + <$edit-text tiddler=<<.state>> field="filter" tag="input" type=search focus="true"/>
-
<$button set=<<.state>> setTo="">Hide
+
+ <$button set=<<.state>> setTo="">Hide + <$reveal stateTitle=<<.state>> stateField="filter" type="nomatch" text=<<__eg__>>> + <$button actions=<<.operator-example-tryit-actions>>>Reset + +
-
    <$list filter="""$eg$""" emptyMessage="(empty)"> +
      <$list filter={{{[<.state>get[filter]]}}} emptyMessage="(empty)">
    • <$link><$view field="title"/>
From 71be16759245bfbd740484cc833781a0f663c2a8 Mon Sep 17 00:00:00 2001 From: "jeremy@jermolene.com" Date: Tue, 26 Oct 2021 09:50:02 +0100 Subject: [PATCH 5/5] Clarify ActionWidget Execution Modes to include default value --- .../tiddlers/widgets/ActionWidget Execution Modes.tid | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/editions/tw5.com/tiddlers/widgets/ActionWidget Execution Modes.tid b/editions/tw5.com/tiddlers/widgets/ActionWidget Execution Modes.tid index 2c54eb69b..f48be2154 100644 --- a/editions/tw5.com/tiddlers/widgets/ActionWidget Execution Modes.tid +++ b/editions/tw5.com/tiddlers/widgets/ActionWidget Execution Modes.tid @@ -1,4 +1,6 @@ title: ActionWidget Execution Modes +modified: 20211026094722447 +created: 20211003094722447 <<.from-version "5.2.0">> The default behaviour of action widgets has some peculiarities that often cause confusion. There is now an improved mode that simplifies how things work, but due to BackwardsCompatibility constraints, it must be explicitly engaged in order to take advantage of it. @@ -21,9 +23,9 @@ Current value of ActionTestTiddler: {{ActionTestTiddler}} Click me '/> -The new behaviour avoids these problems by refreshing all widgets before execution, not just action widgets. It is engaged by running the actions in a scopr that includes the variable `tv-action-refresh-policy` set to the value `always`. +The new behaviour avoids these problems by refreshing all widgets before execution, not just action widgets. It is engaged by running the actions in a scope that includes the variable `tv-action-refresh-policy` set to the value `always`. (The default value for `tv-action-refresh-policy` is `once`). -This can be done within an action string, or via a local variable declaration containing the widget triggering the action. +The assignment can be done within an action string, or via a local variable declaration containing the widget triggering the action. <<.warning "Do not attempt to set `tv-action-refresh-policy` globally; the core will only work correctly with the default setting">>