mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-09-09 05:56:50 +00:00
29 lines
851 B
Plaintext
29 lines
851 B
Plaintext
![]() |
created: 20200131144828713
|
||
|
modified: 20200131152102232
|
||
|
tags: ActionCreateTiddlerWidget
|
||
|
title: ActionCreateTiddlerWidget Example 2
|
||
|
type: text/vnd.tiddlywiki
|
||
|
|
||
|
\define testCreate()
|
||
|
<$action-createtiddler $basetitle={{$:/language/DefaultNewTiddlerTitle}} $overwrite="yes"/>
|
||
|
\end
|
||
|
|
||
|
This example will use the base title defined in [[$:/language/DefaultNewTiddlerTitle]].
|
||
|
|
||
|
It will overwrite the tiddler, if the button is clicked several times.
|
||
|
|
||
|
```
|
||
|
\define testCreate()
|
||
|
<$action-createtiddler $basetitle={{$:/language/DefaultNewTiddlerTitle}} $overwrite="yes"/>
|
||
|
\end
|
||
|
|
||
|
<$button actions=<<testCreate>> >
|
||
|
Create Tiddler
|
||
|
</$button>
|
||
|
```
|
||
|
|
||
|
<$button actions=<<testCreate>> >
|
||
|
<$action-setfield $tiddler="$:/state/tab/sidebar-1206596165" text="$:/core/ui/SideBar/Recent"/>
|
||
|
Create Tiddler
|
||
|
</$button> - Clicking this button, will also open the Right sidebar: Recent tab
|