Add new example from @kookma

This commit is contained in:
jeremy@jermolene.com 2023-04-23 13:14:46 +01:00
parent 06758183d3
commit 374a0fe56d
1 changed files with 11 additions and 0 deletions

View File

@ -1,5 +1,8 @@
title: Core Icons title: Core Icons
tags: Features tags: Features
modified: 20230423103154329
created: 20230423103154329
!! Introduction !! Introduction
@ -18,6 +21,14 @@ The core icons are parameterised. The first parameter `size` specified the size
<$transclude $tiddler="$:/core/images/picture" size="32px"/> <$transclude $tiddler="$:/core/images/picture" size="32px"/>
""">> """>>
Here is an example of dynamically resizing icons:
<<wikitext-example-without-html """<$list filter="[range[24,56,8]]" variable=iconSize>
<$text text={{{ [<iconSize>addsuffix[px]] }}} />
<$transclude $tiddler="$:/core/icon" size=<<iconSize>>/>
</$list>
""">>
Some icons take further parameters to customise how they are rendered. For example, the $:/core/images/new-journal-button icon takes an additional parameter `day` that specifies the day of the month that should be shown on the calendar. It defaults to the current date if not specified Some icons take further parameters to customise how they are rendered. For example, the $:/core/images/new-journal-button icon takes an additional parameter `day` that specifies the day of the month that should be shown on the calendar. It defaults to the current date if not specified
<<wikitext-example-without-html """{{$:/core/images/new-journal-button|48px|17}} <<wikitext-example-without-html """{{$:/core/images/new-journal-button|48px|17}}