Options
All
  • Public
  • Public/Protected
  • All
Menu

The configuration for the ScrollPanel widget. You can access this configuration via BaseWidget.cfg. Please note that this configuration is usually meant to be read-only and should not be modified.

Hierarchy

Index

Properties

animateDuration: number

The number of milliseconds taken to animate to a new position.

animateEase: string

The type of easing to use when animating to a new position.

animateScroll: boolean

Whether to use animation when calling or JScrollPaneInstance.scrollBy. You can control the animation speed and easing by using the animateDuration and animateEase settings or if you want to exercise more complete control then you can override the animate API method.

arrowButtonSpeed: number

A multiplier which is used to control the amount that the scroll pane scrolls each time on of the arrow buttons is pressed.

arrowRepeatFreq: number

The number of milliseconds between each repeated scroll event when the mouse is held down over one of the arrow keys.

arrowScrollOnHover: boolean

Whether the arrow buttons should cause the JScrollPane to scroll while you are hovering over them.

autoReinitialise: boolean

Whether JScrollPane should automatically reinitialize itself periodically after you have initially initialized it.

This can help with instances when the size of the content of the scroll pane (or the surrounding element) changes.

However, it does involve an overhead of running a javascript function on a timer so it is recommended only to activate where necessary.

autoReinitialiseDelay: number

The number of milliseconds between each reinitialization (if autoReinitialise is true).

behaviors: Record<string, Behavior>

A map with all behaviors that were defined for this widget. The key is the name of the behavior, the value is the callback function that is invoked when the behavior is called.

clickOnTrack: boolean

Whether clicking on the track (e.g. the area behind the drag) should scroll towards the point clicked on.

Defaults to true as this is the native behavior in these situations.

contentWidth: number

The width of the content of the scroll pane. The default value of undefined will allow JScrollPane to calculate the width of its content. However, in some cases you will want to disable this (e.g. to prevent horizontal scrolling or where the calculation of the size of the content doesn't return reliable results).

enableKeyboardNavigation: boolean

Whether keyboard navigation should be enabled (e.g. whether the user can focus the scroll pane and then use the arrow (and other) keys to navigate around.

formId?: string

ID of the form to use for AJAX requests.

hideFocus: boolean

Whether the focus outline should be hidden in all browsers. For best accessibility you should not change this option. You can style the outline with the CSS property outline and outline-offset.

hijackInternalLinks: boolean

Whether internal links on the page should be hijacked so that if they point so content within a JScrollPane then they automatically scroll the JScrollPane to the correct place.

horizontalArrowPositions: ArrowPosition

Where the horizontal arrows should appear relative to the horizontal track.

horizontalDragMaxWidth: number

The largest width that the horizontal drag can have. The size of the drag elements is based on the proportion of the size of the content to the size of the viewport but is constrained within the minimum and maximum dimensions given.

horizontalDragMinWidth: number

The smallest width that the horizontal drag can have. The size of the drag elements is based on the proportion of the size of the content to the size of the viewport but is constrained within the minimum and maximum dimensions given.

horizontalGutter: number

The amount of space between the bottom of the content and the horizontal scrollbar.

id: string | string[]

The client-side ID of the widget, with all parent naming containers, such as myForm:myWidget. This is also the ID of the container HTML element for this widget. In case the widget needs multiple container elements (such as Paginator), this may also be an array if IDs.

maintainPosition: boolean

Whether the scroll pane should attempt to maintain it's position whenever it is reinitialized.

If true then the viewport of the scroll pane will remain the same when it is reinitialized, if false then the viewport will jump back up to the top when the scroll pane is reinitialized. See also stickToBottom and stickToRight.

mouseWheelSpeed: number

A multiplier which is used to control the amount that the scroll pane scrolls each time the mouse wheel is turned.

postConstruct: PostConstructCallback

An optional callback that is invoked after this widget was created successfully, at the end of the init method. This is usually specified via the widgetPostConstruct attribute on the JSF component. Note that this is also called during a refresh (AJAX update).

postRefresh: PostRefreshCallback

An optional callback that is invoked after this widget was refreshed after an AJAX update, at the end of the refresh method. This is usually specified via the widgetPostRefresh attribute on the JSF component.

preDestroy: PreDestroyCallback

An optional callback that is invoked before this widget is about to be destroyed, e.g., when the component was removed at the end of an AJAX update. This is called at the beginning of the destroy method. This is usually specified via the widgetPreDestroy attribute on the JSF component.

showArrows: boolean

Whether arrows should be shown on the generated scroll pane. When set to false only the scrollbar track and drag will be shown, if set to true then arrows buttons will also be shown.

stickToBottom: boolean

If maintainPosition is true and the scroll pane is scrolled to the bottom then the scroll pane then the scroll pane will remain scrolled to the bottom even if new content is added to the pane which makes it taller.

stickToRight: boolean

If maintainPosition is true and the scroll pane is scrolled to its right edge then the scroll pane then the scroll pane will remain scrolled to the right edge even if new content is added to the pane which makes it wider.

trackClickRepeatFreq: number

The number of milliseconds between each repeated scroll event when the mouse is held down over the track.

trackClickSpeed: number

A multiplier which is used to control the amount that the scroll pane scrolls each trackClickRepeatFreq while the mouse button is held down over the track.

verticalArrowPositions: ArrowPosition

Where the vertical arrows should appear relative to the vertical track.

verticalDragMaxHeight: number

The largest height that the vertical drag can have. The size of the drag elements is based on the proportion of the size of the content to the size of the viewport but is constrained within the minimum and maximum dimensions given.

verticalDragMinHeight: number

The smallest height that the vertical drag can have. The size of the drag elements is based on the proportion of the size of the content to the size of the viewport but is constrained within the minimum and maximum dimensions given.

verticalGutter: number

The amount of space between the side of the content and the vertical scrollbar.

widgetVar: string

The name of the widget variables of this widget. The widget variable can be used to access a widget instance by calling PF("myWidgetVar").

Generated using TypeDoc