Clarify Introduction to filter notation.tid (#4639)

I'm reading the documentation for the first time and I'm trying to clarify parts which are hard to understand for first-time users.
Jermolene-patch-1
mocsa 2020-05-14 15:30:48 +02:00 zatwierdzone przez GitHub
rodzic 71a827eead
commit 1812cbbb7c
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 3 dodań i 3 usunięć

Wyświetl plik

@ -72,13 +72,13 @@ In a similar way, we can use a `-` sign to <<.em remove>> a run's tiddlers from
!Special parameters
The parameter of each step we've seen so far has been in square brackets, meaning that ~TiddlyWiki treats it literally. But two other kinds of bracket are possible:
The parameter of each step we've seen so far has been in square brackets. It means that ~TiddlyWiki will filter for the exact string found between the brackets. But two other kinds of bracket are possible:
<<.def "Curly brackets">> `{}` mean that the parameter is a TextReference, and that its value is to be looked up in a specified tiddler. For example, if we have a tiddler called <<.tid Preference>> whose text happens to be the word <<.value Vegetarian>>, we can say
<<.def "Curly brackets">> `{}` mean that the parameter is a TextReference, and it will be replaced with content from another tiddler. For example, if we have a tiddler with the title <<.tid Preference>> whose content is the single word <<.value Vegetarian>>, we can say
> `[tag{Preference}]`
as an alternative to `[tag[Vegetarian]]`. This allows the preference to change over time.
In this simplest form the TextReference will take the full content of the tiddler (in technical terms, the text field of the tiddler) and substitute it in place of the TextReference. This way the tiddler's content will become the filter parameter, just like if you have written `[tag[Vegetarian]]`. But it gives you the added flexibility to change the parameter by changing the content of the Preference tiddler.
<<.def "Angle brackets">> `<>` mean that the parameter is the name of a [[variable|Variables]] whose value is to be used instead. Here we use the built-in <<.vlink currentTiddler>> variable in a filter that selects any tiddlers whose text contains the title of the current one: