created: 20201130191618831 modified: 20210307102027763 tags: RangeWidget title: RangeWidget Example type: text/vnd.tiddlywiki \define getText() $(text)$ - value: $(value)$ - changed: $(actionValueHasChanged)$ \define range-log(text:"", value:"", tiddler:"$:/temp/range/log") <$vars text="""$text$""" value="""$value$""" > <$action-setfield $tiddler="""$tiddler$""" $index=<> $value=<>/> \end \define clear-range-log(tiddler:"$:/temp/range/log") <$action-setfield $tiddler="""$tiddler$""" text="{}" show=show/> \end \define logTiddler()$:/temp/range/log \define clearLogButton()<$button actions=<>>Clear Log \define actionsStop() <$macrocall $name="range-log" text=" actionsStop" value=<> /> \end \define actionsStart() <$macrocall $name="range-log" text=" actionsStart" value=<> /> \end \define actions() <$macrocall $name="range-log" text="actions" value=<> /> \end !! Using Actions <$range tiddler="$:/temp/range/1__" min="-1" max="10" default="1" increment="1" actionsStart=<> actionsStop=<> actions=<>/> {{$:/temp/range/1__}} <$range tiddler="$:/temp/range/__2" min="0" max="1" default=".01" increment=".01" actionsStart=<> actionsStop=<> actions=<> /> {{$:/temp/range/__2}} <$checkbox tiddler=<> field="show" checked="show" unchecked="hide"> Show log <> <$reveal stateTitle=<> stateField="show" type="match" text="show"> <$transclude tiddler=<> /> --- The wikitext of this example is shown below: <$codeblock code={{RangeWidget Example!!text}}/>