mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-03-30 07:16:56 +00:00
Extend ScrollableWidget example to have buttons to scroll up/down by 10 pixels
This commit is contained in:
parent
a8f477a3ab
commit
22f7af05de
@ -60,6 +60,16 @@ This wiki text shows how to display a list within the scrollable widget:
|
||||
Set current scroll position to 100,100
|
||||
</$button>
|
||||
|
||||
<$button>
|
||||
<$action-setfield $tiddler="$:/my-scroll-position" scroll-top={{{ [{$:/my-scroll-position!!scroll-top}subtract[10]] }}}/>
|
||||
Scroll up by 10 pixels
|
||||
</$button>
|
||||
|
||||
<$button>
|
||||
<$action-setfield $tiddler="$:/my-scroll-position" scroll-top={{{ [{$:/my-scroll-position!!scroll-top}add[10]] }}}/>
|
||||
Scroll down by 10 pixels
|
||||
</$button>
|
||||
|
||||
<<wikitext-example-without-html "<$scrollable class='tc-scrollable-demo' bind='$:/my-scroll-position'>
|
||||
<$list filter='[tag[Reference]]'>
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user