This page is part of a static HTML representation of the TiddlyWiki at https://tiddlywiki.com/

Release 5.3.2

13 décembre 2023 à 8h06

See GitHub for detailed change history of this release

Congratulations to catter-fly for their winning design for the banner for this release (here is the competition thread).

Major Improvements

Conditional Shortcut Syntax

ajouté a new shortcut syntax for concisely expressing if-then-else logic. This is the first of a new type of wikitext syntax based on tokens delimited with <% and %>. We plan to introduce other structures using the same format such as a "case" statement.

These new token-based shortcuts allow a richer structure and expressivity than existing features such as widgets or pragmas. For example:

<%if [<animal>match[Elephant]] %>
  It is an elephant
<%elseif [<animal>match[Giraffe]] %>
	It is a giraffe
<%else%>
	It is completely unknown
<%endif%>

Behind the scenes, the conditional shortcut syntax is rendered as the equivalent ListWidgets.

Explicit Templates for the ListWidget

ajouté support for <$list-template> and <$list-empty> as immediate children of the $ListWidget widget to specify the list item template and/or the empty template.

This new feature is designed to replace a common pattern of using the emptyMessage attribute of the ListWidget to render complex wikitext that thus has to be quoted. Working with wikitext within quotes is awkward and error prone. The new structure can be somewhat faster because it allows the empty message to be parsed in advanced of rendering.

For example:

<$list filter=<<filter>>>
	<$list-template>
		<$text text=<<currentTiddler>>/>
	</$list-template>
	<$list-empty>
		None!
	</$list-empty>
</$list>

Note that the emptyMessage and template attributes take precedence if they are present.

Joiners for the ListWidget

ajouté a join attribute to the $ListWidget widget to insert a short piece of text between list items. This is both easier to use and faster than using the counter attribute for the same purpose. So if your list looked like this:

<$list filter=<<filter>> counter="counter" variable="item">
<$text text=<<item>>/><$list filter="[<counter-last>match[no]]" variable="ignore"><$text text=", "/></$list>
</$list>

You can replace it with:

<$list filter=<<filter>> variable="item" join=", "><$text text=<<item>>/></$list>

If the joiner text that you need is long and awkward to write in an attribute, you can use the new <$list-join> widget. Like <$list-template> and <$list-empty>, it must be an immediate child of the $ListWidget:

<$list filter=<<filter>> variable="item"><$text text=<<item>>/><$list-join>, and <em>also</em> let's not forget </$list-join></$list>

jsonset operator

ajouté jsonset Operator for setting values within JSON objects

QR Code Reader

étendu QR Code plugin to be able to read QR codes and a number of other bar code formats

Translation improvements

Improvements to the following translations:

  • Chinese
  • Polish
  • Spanish

Plugin Improvements

  • corrigé Comments Plugin to use predefined palette colours
  • amélioré Evernote Importer Plugin to support images and other attachments
  • ajouté $floating attribute to Dynannotate Plugin to support popups that do not disappear when another part of the screen is clicked. Instead they have to dismissed manually

Widget Improvements

Usability Improvements

  • mis à jour editor preview button to automatically focus the editor
  • amélioré file type names in the export menu

Hackability Improvements

Bug Fixes

Node.js Improvements

  • corrigé a significant flaw in the synchronisation algorithm used by the client-server configuration. The flaw could lead to tiddlers temporarily disappearing from the browser

Performance Improvements

Developer Improvements

  • amélioré global hook handling to support removing hooks
  • ajouté some useful npm scripts to package.json

Infrastructure Improvements

Acknowledgements

@Jermolene would like to thank the contributors to this release who have generously given their time to help improve TiddlyWiki: