import Flicking, { Plugin } from "@egjs/flicking"; /** * Options for the {@link Arrow} plugin */ export interface ArrowOptions { /** * The parent element to search for arrow elements. If `null`, the Flicking element is used * @defaultValue null */ parentEl: HTMLElement | null; /** * CSS selector for the "previous" arrow element * @defaultValue ".flicking-arrow-prev" */ prevElSelector: string; /** * CSS selector for the "next" arrow element * @defaultValue ".flicking-arrow-next" */ nextElSelector: string; /** * CSS class added to an arrow element when it is disabled (at the start/end of non-circular Flicking) * @defaultValue "flicking-arrow-disabled" */ disabledClass: string; /** * Number of panels to move when an arrow is clicked * @defaultValue 1 */ moveCount: number; /** * Whether to move by viewport size instead of panel count * @defaultValue false */ moveByViewportSize: boolean; } /** * A plugin to easily create prev/next arrow buttons for Flicking * @see {@link https://naver.github.io/egjs-flicking/docs/demos/plugins/arrow | Demo: Arrow} */ declare class Arrow implements Plugin { private _flicking; private _prevEl; private _nextEl; private _parentEl; private _prevElSelector; private _nextElSelector; private _disabledClass; private _moveCount; private _moveByViewportSize; /** The "previous" arrow HTMLElement * @readonly */ get prevEl(): HTMLElement; /** The "next" arrow HTMLElement * @readonly */ get nextEl(): HTMLElement; /** Current value of the {@link ArrowOptions.parentEl | parentEl} option. */ get parentEl(): ArrowOptions["parentEl"]; /** Current value of the {@link ArrowOptions.prevElSelector | prevElSelector} option. */ get prevElSelector(): ArrowOptions["prevElSelector"]; /** Current value of the {@link ArrowOptions.nextElSelector | nextElSelector} option. */ get nextElSelector(): ArrowOptions["nextElSelector"]; /** Current value of the {@link ArrowOptions.disabledClass | disabledClass} option. */ get disabledClass(): ArrowOptions["disabledClass"]; /** Current value of the {@link ArrowOptions.moveCount | moveCount} option. */ get moveCount(): ArrowOptions["moveCount"]; /** Current value of the {@link ArrowOptions.moveByViewportSize | moveByViewportSize} option. */ get moveByViewportSize(): ArrowOptions["moveByViewportSize"]; /** Sets {@link ArrowOptions.parentEl | parentEl}. */ set parentEl(val: ArrowOptions["parentEl"]); /** Sets {@link ArrowOptions.prevElSelector | prevElSelector}. */ set prevElSelector(val: ArrowOptions["prevElSelector"]); /** Sets {@link ArrowOptions.nextElSelector | nextElSelector}. */ set nextElSelector(val: ArrowOptions["nextElSelector"]); /** Sets {@link ArrowOptions.disabledClass | disabledClass}. */ set disabledClass(val: ArrowOptions["disabledClass"]); /** Sets {@link ArrowOptions.moveCount | moveCount}. */ set moveCount(val: ArrowOptions["moveCount"]); /** Sets {@link ArrowOptions.moveByViewportSize | moveByViewportSize}. */ set moveByViewportSize(val: ArrowOptions["moveByViewportSize"]); /** * @param options - Options for the Arrow instance * @example * ```ts * flicking.addPlugins(new Arrow({ parentEl: null, prevElSelector: ".flicking-arrow-prev", nextElSelector: ".flicking-arrow-next" })); * ``` */ constructor(options?: Partial); /** Initialize the plugin and attach arrow event listeners to the Flicking instance. * @param flicking - The Flicking instance to attach this plugin to */ init(flicking: Flicking): void; /** Destroy the plugin and remove all arrow event listeners. */ destroy(): void; /** Update the arrow disabled/enabled state based on the current camera position. */ update(): void; private _preventInputPropagation; private _onPrevClick; private _onNextClick; private _onAnimation; private _updateClass; private _onCatch; } export default Arrow;