From 7beaddb29325f9437baa87c6eef7fea37f6ed477 Mon Sep 17 00:00:00 2001 From: springerspandrel <66639553+springerspandrel@users.noreply.github.com> Date: Sat, 29 Jun 2024 08:25:03 -0400 Subject: [PATCH] Docs: Add InputActions example to EditTextWidget (#8306) --- .../tiddlers/widgets/EditTextWidget.tid | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/editions/tw5.com/tiddlers/widgets/EditTextWidget.tid b/editions/tw5.com/tiddlers/widgets/EditTextWidget.tid index 93da9b865..dcfd088fb 100644 --- a/editions/tw5.com/tiddlers/widgets/EditTextWidget.tid +++ b/editions/tw5.com/tiddlers/widgets/EditTextWidget.tid @@ -1,7 +1,9 @@ caption: edit-text created: 20131024141900000 -modified: 20230122210049893 +heading: +modified: 20240627184331133 tags: Widgets +temp: title: EditTextWidget type: text/vnd.tiddlywiki @@ -66,3 +68,18 @@ Provide a dated heading for this example where only the placeholder (but not the <$macrocall $name=".example" n="3" eg="""<$edit-text tiddler=<> field="heading" size="25" focus="yes" focusSelectFromEnd="13" default={{{ [[Heading Text (]] [] [[)]] +[join[]] }}} /> """/> + +!!! Input Actions, with class attribute + +<$macrocall $name=".example" n="4" +eg="""\procedure onInput() + <%if [get[temp]match[$:/]] %> + <$action-confirm $message="Yes, this is how system tiddler names begin!"/> + <% endif %> +\end + +Type a new tiddler name, starting with the system prefix `$:/`: <$edit-text inputActions=<> field="temp" class="tc-edit-texteditor"/> + +"""/> + +