This is a test for the highly experimental New-Tiddler-Button.
The New-Tiddler-Button expects 2 parameters:
| Parameter | Mandatory | Explanation |
| title | yes | the title of the new tiddler. Will get numbers appended |
| skeleton | yes | an existing tiddler which may contain variable placeholders |
| edit | no | This defines wether to open the new tiddler in edit mode. Must be one of "yes", "no" or (not implemented yet) "inline |
The most important part lies in the skeleton! TiddlyWiki already can clone tiddlers, but you can't really prefill data of the newly created tiddler.
With <$newtiddler> you can put placeholders of the form $(variable)$ anywhere in the tiddler and they will be replaced by the values of the variables set with the <$set> or <$let> widget. Please note: The placeholders can be anywhere! In the tiddlers body, in fields, types, you name it…
The example skeleton used here looks like this:
| Property | Content |
| title | skeleton 1 |
| text | This is some test: $(placeholder)$ |
| tags | $(tag1)$ |
| field1 | $(f1)$ |
| field2 | $(f2)$ |
If we now put this into our tiddler:
<$let f1=<<uuid>> f2="field-2" placeholder="pl1" tag1="testtag"> <$newtiddler title="test" skeleton="skeleton 1">Create</$newtiddler> </$let>
We get a (Create) button.
Clicking it, will open a new tiddler with some values pre-filled.
Is there a way to tag the newly created tiddler with the current tiddler?
--
You received this message because you are subscribed to a topic in the Google Groups "TiddlyWiki" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tiddlywiki/EIEmWhTC9RE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/70a968ea-66c6-495c-b56d-f068d22ff973%40googlegroups.com.