Arrow
A plugin to easily create prev/next arrow buttons for Flicking
See Also:
Constructor
constructor(options?: Partial<ArrowOptions>);
Constructs a new instance of the Arrow class
Parameters
options (Partial<ArrowOptions>) - Options for the Arrow instance
Examples
flicking.addPlugins(new Arrow({ parentEl: null, prevElSelector: ".flicking-arrow-prev", nextElSelector: ".flicking-arrow-next" }));
Options
disabledClass
Type: string
CSS class added to an arrow element when it is disabled (at the start/end of non-circular Flicking)
Default: "flicking-arrow-disabled"
moveByViewportSize
Type: boolean
Whether to move by viewport size instead of panel count
Default: false
parentEl
Type: HTMLElement | null
The parent element to search for arrow elements. If null, the Flicking element is used
Default: null
prevElSelector
Type: string
CSS selector for the "previous" arrow element
Default: ".flicking-arrow-prev"
Properties
moveByViewportSize
Type: ArrowOptions["moveByViewportSize"]
Current value of the moveByViewportSize option.
Methods
init
init(flicking: Flicking): void
Initialize the plugin and attach arrow event listeners to the Flicking instance.
Parameters:
flicking(Flicking) - The Flicking instance to attach this plugin to