Skip to main content

ScrollContainerController

Purpose​

Controller to be used on a scrollable container element, to enable control over the scroll height of the container.

Actions​

ActionPurpose
scrollTopScroll to the very top of the element
scrollBottomScroll to the very bottom of the element
scrollLeftScroll to the very left of the element
scrollRightScroll to the very right of the element
upScroll up by incrementAmount in 'px'
downScroll down by incrementAmount in 'px'
leftScroll left by incrementAmount in 'px'
rightScroll right by incrementAmount in 'px'

Targets​

TargetPurposeDefault
---

Classes​

ClassPurposeDefault
---

Values​

See ScrollToOptions documentation for possible values for behaviour

ValueTypeDescriptionDefault
behaviourStringOne of auto, smooth. Note: If the user's browser does not support smooth scrolling, the browser will ignore these values and scroll using the browser default.auto
incrementNumberThe amount to scroll by when using up, down, left, right actions50

Events​

EventWhenDispatched onevent.detail
----

Side Effects​

None

How to Use​

See Also​

Scroll To Controller Scroll To Top Controller Scroll To Bottom Controller Scroll Into Focus Controller