@egjs/flicking 4.11.3-beta.4 → 4.11.4-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (71) hide show
  1. package/declaration/Flicking.d.ts +240 -240
  2. package/declaration/camera/Camera.d.ts +89 -89
  3. package/declaration/camera/index.d.ts +4 -4
  4. package/declaration/camera/mode/BoundCameraMode.d.ts +13 -13
  5. package/declaration/camera/mode/CameraMode.d.ts +20 -20
  6. package/declaration/camera/mode/CircularCameraMode.d.ts +19 -19
  7. package/declaration/camera/mode/LinearCameraMode.d.ts +9 -9
  8. package/declaration/camera/mode/index.d.ts +6 -6
  9. package/declaration/cfc/getDefaultCameraTransform.d.ts +3 -3
  10. package/declaration/cfc/getRenderingPanels.d.ts +4 -4
  11. package/declaration/cfc/index.d.ts +5 -5
  12. package/declaration/cfc/sync.d.ts +4 -4
  13. package/declaration/cfc/withFlickingMethods.d.ts +2 -2
  14. package/declaration/const/axes.d.ts +8 -8
  15. package/declaration/const/error.d.ts +34 -34
  16. package/declaration/const/external.d.ts +48 -48
  17. package/declaration/control/AxesController.d.ts +44 -44
  18. package/declaration/control/Control.d.ts +45 -45
  19. package/declaration/control/FreeControl.d.ts +14 -14
  20. package/declaration/control/SnapControl.d.ts +16 -16
  21. package/declaration/control/StateMachine.d.ts +14 -14
  22. package/declaration/control/StrictControl.d.ts +20 -20
  23. package/declaration/control/index.d.ts +14 -14
  24. package/declaration/control/states/AnimatingState.d.ts +9 -9
  25. package/declaration/control/states/DisabledState.d.ts +9 -9
  26. package/declaration/control/states/DraggingState.d.ts +8 -8
  27. package/declaration/control/states/HoldingState.d.ts +10 -10
  28. package/declaration/control/states/IdleState.d.ts +9 -9
  29. package/declaration/control/states/State.d.ts +47 -47
  30. package/declaration/core/AnchorPoint.d.ts +15 -15
  31. package/declaration/core/AutoResizer.d.ts +16 -16
  32. package/declaration/core/FlickingError.d.ts +5 -5
  33. package/declaration/core/ResizeWatcher.d.ts +33 -33
  34. package/declaration/core/Viewport.d.ts +25 -25
  35. package/declaration/core/VirtualManager.d.ts +37 -37
  36. package/declaration/core/index.d.ts +6 -6
  37. package/declaration/core/panel/Panel.d.ts +89 -89
  38. package/declaration/core/panel/VirtualPanel.d.ts +19 -19
  39. package/declaration/core/panel/index.d.ts +5 -5
  40. package/declaration/core/panel/provider/ElementProvider.d.ts +8 -8
  41. package/declaration/core/panel/provider/VanillaElementProvider.d.ts +12 -12
  42. package/declaration/core/panel/provider/VirtualElementProvider.d.ts +15 -15
  43. package/declaration/core/panel/provider/index.d.ts +5 -5
  44. package/declaration/index.cjs.d.ts +3 -3
  45. package/declaration/index.d.ts +13 -13
  46. package/declaration/index.umd.d.ts +2 -2
  47. package/declaration/renderer/ExternalRenderer.d.ts +7 -7
  48. package/declaration/renderer/Renderer.d.ts +59 -59
  49. package/declaration/renderer/VanillaRenderer.d.ts +10 -10
  50. package/declaration/renderer/index.d.ts +6 -6
  51. package/declaration/renderer/strategy/NormalRenderingStrategy.d.ts +23 -23
  52. package/declaration/renderer/strategy/RenderingStrategy.d.ts +15 -15
  53. package/declaration/renderer/strategy/VirtualRenderingStrategy.d.ts +17 -17
  54. package/declaration/renderer/strategy/index.d.ts +5 -5
  55. package/declaration/type/event.d.ts +88 -88
  56. package/declaration/type/external.d.ts +31 -31
  57. package/declaration/type/internal.d.ts +13 -13
  58. package/declaration/utils.d.ts +45 -45
  59. package/dist/flicking.cjs.js +9 -5
  60. package/dist/flicking.cjs.js.map +1 -1
  61. package/dist/flicking.esm.js +9 -5
  62. package/dist/flicking.esm.js.map +1 -1
  63. package/dist/flicking.js +9 -5
  64. package/dist/flicking.js.map +1 -1
  65. package/dist/flicking.min.js +2 -2
  66. package/dist/flicking.min.js.map +1 -1
  67. package/dist/flicking.pkgd.js +774 -763
  68. package/dist/flicking.pkgd.js.map +1 -1
  69. package/dist/flicking.pkgd.min.js +2 -2
  70. package/dist/flicking.pkgd.min.js.map +1 -1
  71. package/package.json +2 -2
@@ -1,14 +1,14 @@
1
- import { AxesEvents } from "@egjs/axes";
2
- import Flicking from "../Flicking";
3
- import State, { STATE_TYPE } from "./states/State";
4
- declare class StateMachine {
5
- private _state;
6
- get state(): State;
7
- constructor();
8
- fire(eventType: keyof AxesEvents, externalCtx: {
9
- flicking: Flicking;
10
- axesEvent: any;
11
- }): void;
12
- transitTo: (nextStateType: STATE_TYPE) => State;
13
- }
14
- export default StateMachine;
1
+ import { AxesEvents } from "@egjs/axes";
2
+ import Flicking from "../Flicking";
3
+ import State, { STATE_TYPE } from "./states/State";
4
+ declare class StateMachine {
5
+ private _state;
6
+ get state(): State;
7
+ constructor();
8
+ fire(eventType: keyof AxesEvents, externalCtx: {
9
+ flicking: Flicking;
10
+ axesEvent: any;
11
+ }): void;
12
+ transitTo: (nextStateType: STATE_TYPE) => State;
13
+ }
14
+ export default StateMachine;
@@ -1,20 +1,20 @@
1
- import { OnRelease } from "@egjs/axes";
2
- import Panel from "../core/panel/Panel";
3
- import Control from "./Control";
4
- export interface StrictControlOptions {
5
- count: number;
6
- }
7
- declare class StrictControl extends Control {
8
- private _count;
9
- private _indexRange;
10
- get count(): StrictControlOptions["count"];
11
- set count(val: StrictControlOptions["count"]);
12
- constructor({ count }?: Partial<StrictControlOptions>);
13
- destroy(): void;
14
- updateInput(): this;
15
- moveToPanel(panel: Panel, options: Parameters<Control["moveToPanel"]>[1]): Promise<void>;
16
- moveToPosition(position: number, duration: number, axesEvent?: OnRelease): Promise<void>;
17
- setActive: (newActivePanel: Panel, prevActivePanel: Panel | null, isTrusted: boolean) => void;
18
- private _resetIndexRange;
19
- }
20
- export default StrictControl;
1
+ import { OnRelease } from "@egjs/axes";
2
+ import Panel from "../core/panel/Panel";
3
+ import Control from "./Control";
4
+ export interface StrictControlOptions {
5
+ count: number;
6
+ }
7
+ declare class StrictControl extends Control {
8
+ private _count;
9
+ private _indexRange;
10
+ get count(): StrictControlOptions["count"];
11
+ set count(val: StrictControlOptions["count"]);
12
+ constructor({ count }?: Partial<StrictControlOptions>);
13
+ destroy(): void;
14
+ updateInput(): this;
15
+ moveToPanel(panel: Panel, options: Parameters<Control["moveToPanel"]>[1]): Promise<void>;
16
+ moveToPosition(position: number, duration: number, axesEvent?: OnRelease): Promise<void>;
17
+ setActive: (newActivePanel: Panel, prevActivePanel: Panel | null, isTrusted: boolean) => void;
18
+ private _resetIndexRange;
19
+ }
20
+ export default StrictControl;
@@ -1,14 +1,14 @@
1
- import Control from "./Control";
2
- import SnapControl, { SnapControlOptions } from "./SnapControl";
3
- import FreeControl, { FreeControlOptions } from "./FreeControl";
4
- import StrictControl, { StrictControlOptions } from "./StrictControl";
5
- import AxesController from "./AxesController";
6
- import State from "./states/State";
7
- import IdleState from "./states/IdleState";
8
- import HoldingState from "./states/HoldingState";
9
- import DraggingState from "./states/DraggingState";
10
- import AnimatingState from "./states/AnimatingState";
11
- import DisabledState from "./states/DisabledState";
12
- import StateMachine from "./StateMachine";
13
- export { Control, SnapControl, FreeControl, StrictControl, AxesController, State, IdleState, HoldingState, DraggingState, AnimatingState, DisabledState, StateMachine };
14
- export type { SnapControlOptions, FreeControlOptions, StrictControlOptions };
1
+ import Control from "./Control";
2
+ import SnapControl, { SnapControlOptions } from "./SnapControl";
3
+ import FreeControl, { FreeControlOptions } from "./FreeControl";
4
+ import StrictControl, { StrictControlOptions } from "./StrictControl";
5
+ import AxesController from "./AxesController";
6
+ import State from "./states/State";
7
+ import IdleState from "./states/IdleState";
8
+ import HoldingState from "./states/HoldingState";
9
+ import DraggingState from "./states/DraggingState";
10
+ import AnimatingState from "./states/AnimatingState";
11
+ import DisabledState from "./states/DisabledState";
12
+ import StateMachine from "./StateMachine";
13
+ export { Control, SnapControl, FreeControl, StrictControl, AxesController, State, IdleState, HoldingState, DraggingState, AnimatingState, DisabledState, StateMachine };
14
+ export type { SnapControlOptions, FreeControlOptions, StrictControlOptions };
@@ -1,9 +1,9 @@
1
- import State from "./State";
2
- declare class AnimatingState extends State {
3
- readonly holding = false;
4
- readonly animating = true;
5
- onHold(ctx: Parameters<State["onHold"]>[0]): void;
6
- onChange(ctx: Parameters<State["onChange"]>[0]): void;
7
- onFinish(ctx: Parameters<State["onFinish"]>[0]): void;
8
- }
9
- export default AnimatingState;
1
+ import State from "./State";
2
+ declare class AnimatingState extends State {
3
+ readonly holding = false;
4
+ readonly animating = true;
5
+ onHold(ctx: Parameters<State["onHold"]>[0]): void;
6
+ onChange(ctx: Parameters<State["onChange"]>[0]): void;
7
+ onFinish(ctx: Parameters<State["onFinish"]>[0]): void;
8
+ }
9
+ export default AnimatingState;
@@ -1,9 +1,9 @@
1
- import State from "./State";
2
- declare class DisabledState extends State {
3
- readonly holding = false;
4
- readonly animating = true;
5
- onAnimationEnd(ctx: Parameters<State["onAnimationEnd"]>[0]): void;
6
- onChange(ctx: Parameters<State["onChange"]>[0]): void;
7
- onRelease(ctx: Parameters<State["onRelease"]>[0]): void;
8
- }
9
- export default DisabledState;
1
+ import State from "./State";
2
+ declare class DisabledState extends State {
3
+ readonly holding = false;
4
+ readonly animating = true;
5
+ onAnimationEnd(ctx: Parameters<State["onAnimationEnd"]>[0]): void;
6
+ onChange(ctx: Parameters<State["onChange"]>[0]): void;
7
+ onRelease(ctx: Parameters<State["onRelease"]>[0]): void;
8
+ }
9
+ export default DisabledState;
@@ -1,8 +1,8 @@
1
- import State from "./State";
2
- declare class DraggingState extends State {
3
- readonly holding = true;
4
- readonly animating = true;
5
- onChange(ctx: Parameters<State["onChange"]>[0]): void;
6
- onRelease(ctx: Parameters<State["onRelease"]>[0]): void;
7
- }
8
- export default DraggingState;
1
+ import State from "./State";
2
+ declare class DraggingState extends State {
3
+ readonly holding = true;
4
+ readonly animating = true;
5
+ onChange(ctx: Parameters<State["onChange"]>[0]): void;
6
+ onRelease(ctx: Parameters<State["onRelease"]>[0]): void;
7
+ }
8
+ export default DraggingState;
@@ -1,10 +1,10 @@
1
- import State from "./State";
2
- declare class HoldingState extends State {
3
- readonly holding = true;
4
- readonly animating = false;
5
- private _releaseEvent;
6
- onChange(ctx: Parameters<State["onChange"]>[0]): void;
7
- onRelease(ctx: Parameters<State["onRelease"]>[0]): void;
8
- onFinish(ctx: Parameters<State["onFinish"]>[0]): void;
9
- }
10
- export default HoldingState;
1
+ import State from "./State";
2
+ declare class HoldingState extends State {
3
+ readonly holding = true;
4
+ readonly animating = false;
5
+ private _releaseEvent;
6
+ onChange(ctx: Parameters<State["onChange"]>[0]): void;
7
+ onRelease(ctx: Parameters<State["onRelease"]>[0]): void;
8
+ onFinish(ctx: Parameters<State["onFinish"]>[0]): void;
9
+ }
10
+ export default HoldingState;
@@ -1,9 +1,9 @@
1
- import State from "./State";
2
- declare class IdleState extends State {
3
- readonly holding = false;
4
- readonly animating = false;
5
- onEnter(): void;
6
- onHold(ctx: Parameters<State["onHold"]>[0]): void;
7
- onChange(ctx: Parameters<State["onChange"]>[0]): void;
8
- }
9
- export default IdleState;
1
+ import State from "./State";
2
+ declare class IdleState extends State {
3
+ readonly holding = false;
4
+ readonly animating = false;
5
+ onEnter(): void;
6
+ onHold(ctx: Parameters<State["onHold"]>[0]): void;
7
+ onChange(ctx: Parameters<State["onChange"]>[0]): void;
8
+ }
9
+ export default IdleState;
@@ -1,47 +1,47 @@
1
- import { OnAnimationEnd, OnChange, OnFinish, OnHold, OnRelease } from "@egjs/axes";
2
- import Flicking from "../../Flicking";
3
- import Panel from "../../core/panel/Panel";
4
- export declare enum STATE_TYPE {
5
- IDLE = 0,
6
- HOLDING = 1,
7
- DRAGGING = 2,
8
- ANIMATING = 3,
9
- DISABLED = 4
10
- }
11
- declare abstract class State {
12
- abstract readonly holding: boolean;
13
- abstract readonly animating: boolean;
14
- protected _delta: number;
15
- protected _targetPanel: Panel | null;
16
- get delta(): number;
17
- get targetPanel(): Panel | null;
18
- set targetPanel(val: Panel | null);
19
- onEnter(prevState: State): void;
20
- onHold(ctx: {
21
- flicking: Flicking;
22
- axesEvent: OnHold;
23
- transitTo: (nextState: STATE_TYPE) => State;
24
- }): void;
25
- onChange(ctx: {
26
- flicking: Flicking;
27
- axesEvent: OnChange;
28
- transitTo: (nextState: STATE_TYPE) => State;
29
- }): void;
30
- onRelease(ctx: {
31
- flicking: Flicking;
32
- axesEvent: OnRelease;
33
- transitTo: (nextState: STATE_TYPE) => State;
34
- }): void;
35
- onAnimationEnd(ctx: {
36
- flicking: Flicking;
37
- axesEvent: OnAnimationEnd;
38
- transitTo: (nextState: STATE_TYPE) => State;
39
- }): void;
40
- onFinish(ctx: {
41
- flicking: Flicking;
42
- axesEvent: OnFinish;
43
- transitTo: (nextState: STATE_TYPE) => State;
44
- }): void;
45
- protected _moveToChangedPosition(ctx: Parameters<State["onChange"]>[0]): void;
46
- }
47
- export default State;
1
+ import { OnAnimationEnd, OnChange, OnFinish, OnHold, OnRelease } from "@egjs/axes";
2
+ import Flicking from "../../Flicking";
3
+ import Panel from "../../core/panel/Panel";
4
+ export declare enum STATE_TYPE {
5
+ IDLE = 0,
6
+ HOLDING = 1,
7
+ DRAGGING = 2,
8
+ ANIMATING = 3,
9
+ DISABLED = 4
10
+ }
11
+ declare abstract class State {
12
+ abstract readonly holding: boolean;
13
+ abstract readonly animating: boolean;
14
+ protected _delta: number;
15
+ protected _targetPanel: Panel | null;
16
+ get delta(): number;
17
+ get targetPanel(): Panel | null;
18
+ set targetPanel(val: Panel | null);
19
+ onEnter(prevState: State): void;
20
+ onHold(ctx: {
21
+ flicking: Flicking;
22
+ axesEvent: OnHold;
23
+ transitTo: (nextState: STATE_TYPE) => State;
24
+ }): void;
25
+ onChange(ctx: {
26
+ flicking: Flicking;
27
+ axesEvent: OnChange;
28
+ transitTo: (nextState: STATE_TYPE) => State;
29
+ }): void;
30
+ onRelease(ctx: {
31
+ flicking: Flicking;
32
+ axesEvent: OnRelease;
33
+ transitTo: (nextState: STATE_TYPE) => State;
34
+ }): void;
35
+ onAnimationEnd(ctx: {
36
+ flicking: Flicking;
37
+ axesEvent: OnAnimationEnd;
38
+ transitTo: (nextState: STATE_TYPE) => State;
39
+ }): void;
40
+ onFinish(ctx: {
41
+ flicking: Flicking;
42
+ axesEvent: OnFinish;
43
+ transitTo: (nextState: STATE_TYPE) => State;
44
+ }): void;
45
+ protected _moveToChangedPosition(ctx: Parameters<State["onChange"]>[0]): void;
46
+ }
47
+ export default State;
@@ -1,15 +1,15 @@
1
- import Panel from "./panel/Panel";
2
- declare class AnchorPoint {
3
- private _index;
4
- private _pos;
5
- private _panel;
6
- get index(): number;
7
- get position(): number;
8
- get panel(): Panel;
9
- constructor({ index, position, panel }: {
10
- index: number;
11
- position: number;
12
- panel: Panel;
13
- });
14
- }
15
- export default AnchorPoint;
1
+ import Panel from "./panel/Panel";
2
+ declare class AnchorPoint {
3
+ private _index;
4
+ private _pos;
5
+ private _panel;
6
+ get index(): number;
7
+ get position(): number;
8
+ get panel(): Panel;
9
+ constructor({ index, position, panel }: {
10
+ index: number;
11
+ position: number;
12
+ panel: Panel;
13
+ });
14
+ }
15
+ export default AnchorPoint;
@@ -1,16 +1,16 @@
1
- import Flicking from "../Flicking";
2
- declare class AutoResizer {
3
- private _flicking;
4
- private _enabled;
5
- private _resizeObserver;
6
- private _resizeTimer;
7
- private _maxResizeDebounceTimer;
8
- get enabled(): boolean;
9
- constructor(flicking: Flicking);
10
- enable(): this;
11
- disable(): this;
12
- private _onResize;
13
- private _doScheduledResize;
14
- private _skipFirstResize;
15
- }
16
- export default AutoResizer;
1
+ import Flicking from "../Flicking";
2
+ declare class AutoResizer {
3
+ private _flicking;
4
+ private _enabled;
5
+ private _resizeObserver;
6
+ private _resizeTimer;
7
+ private _maxResizeDebounceTimer;
8
+ get enabled(): boolean;
9
+ constructor(flicking: Flicking);
10
+ enable(): this;
11
+ disable(): this;
12
+ private _onResize;
13
+ private _doScheduledResize;
14
+ private _skipFirstResize;
15
+ }
16
+ export default AutoResizer;
@@ -1,5 +1,5 @@
1
- declare class FlickingError extends Error {
2
- code: number;
3
- constructor(message: string, code: number);
4
- }
5
- export default FlickingError;
1
+ declare class FlickingError extends Error {
2
+ code: number;
3
+ constructor(message: string, code: number);
4
+ }
5
+ export default FlickingError;
@@ -1,33 +1,33 @@
1
- export interface ResizeWatherOptions {
2
- resizeDebounce?: number;
3
- maxResizeDebounce?: number;
4
- useResizeObserver?: boolean;
5
- useWindowResize?: boolean;
6
- watchDirection?: "width" | "height" | "box" | false;
7
- rectBox?: "border-box" | "content-box";
8
- }
9
- declare class ResizeWatcher {
10
- private _container;
11
- private _rect;
12
- private _resizeTimer;
13
- private _maxResizeDebounceTimer;
14
- private _emitter;
15
- private _observer;
16
- private _options;
17
- constructor(container: HTMLElement | string, options?: ResizeWatherOptions);
18
- getRect(): {
19
- width: number;
20
- height: number;
21
- };
22
- setRect(rect: {
23
- width: number;
24
- height: number;
25
- }): void;
26
- resize(): void;
27
- listen(callback: () => void): this;
28
- destroy(): void;
29
- private _init;
30
- private _onResize;
31
- private _scheduleResize;
32
- }
33
- export default ResizeWatcher;
1
+ export interface ResizeWatherOptions {
2
+ resizeDebounce?: number;
3
+ maxResizeDebounce?: number;
4
+ useResizeObserver?: boolean;
5
+ useWindowResize?: boolean;
6
+ watchDirection?: "width" | "height" | "box" | false;
7
+ rectBox?: "border-box" | "content-box";
8
+ }
9
+ declare class ResizeWatcher {
10
+ private _container;
11
+ private _rect;
12
+ private _resizeTimer;
13
+ private _maxResizeDebounceTimer;
14
+ private _emitter;
15
+ private _observer;
16
+ private _options;
17
+ constructor(container: HTMLElement | string, options?: ResizeWatherOptions);
18
+ getRect(): {
19
+ width: number;
20
+ height: number;
21
+ };
22
+ setRect(rect: {
23
+ width: number;
24
+ height: number;
25
+ }): void;
26
+ resize(): void;
27
+ listen(callback: () => void): this;
28
+ destroy(): void;
29
+ private _init;
30
+ private _onResize;
31
+ private _scheduleResize;
32
+ }
33
+ export default ResizeWatcher;
@@ -1,25 +1,25 @@
1
- import Flicking from "../Flicking";
2
- declare class Viewport {
3
- private _flicking;
4
- private _el;
5
- private _width;
6
- private _height;
7
- private _isBorderBoxSizing;
8
- private _padding;
9
- get element(): HTMLElement;
10
- get width(): number;
11
- get height(): number;
12
- get padding(): {
13
- left: number;
14
- right: number;
15
- top: number;
16
- bottom: number;
17
- };
18
- constructor(flicking: Flicking, el: HTMLElement);
19
- setSize({ width, height }: Partial<{
20
- width: number | string;
21
- height: number | string;
22
- }>): void;
23
- resize(): void;
24
- }
25
- export default Viewport;
1
+ import Flicking from "../Flicking";
2
+ declare class Viewport {
3
+ private _flicking;
4
+ private _el;
5
+ private _width;
6
+ private _height;
7
+ private _isBorderBoxSizing;
8
+ private _padding;
9
+ get element(): HTMLElement;
10
+ get width(): number;
11
+ get height(): number;
12
+ get padding(): {
13
+ left: number;
14
+ right: number;
15
+ top: number;
16
+ bottom: number;
17
+ };
18
+ constructor(flicking: Flicking, el: HTMLElement);
19
+ setSize({ width, height }: Partial<{
20
+ width: number | string;
21
+ height: number | string;
22
+ }>): void;
23
+ resize(): void;
24
+ }
25
+ export default Viewport;
@@ -1,37 +1,37 @@
1
- import Flicking from "../Flicking";
2
- import VirtualPanel from "./panel/VirtualPanel";
3
- export interface VirtualOptions {
4
- renderPanel: (panel: VirtualPanel, index: number) => string;
5
- initialPanelCount: number;
6
- cache?: boolean;
7
- panelClass?: string;
8
- }
9
- declare class VirtualManager {
10
- private _flicking;
11
- private _renderPanel;
12
- private _initialPanelCount;
13
- private _cache;
14
- private _panelClass;
15
- private _elements;
16
- get elements(): {
17
- nativeElement: HTMLElement;
18
- visible: boolean;
19
- }[];
20
- get renderPanel(): VirtualOptions["renderPanel"];
21
- get initialPanelCount(): number;
22
- get cache(): NonNullable<VirtualOptions["cache"]>;
23
- get panelClass(): NonNullable<VirtualOptions["panelClass"]>;
24
- set renderPanel(val: VirtualOptions["renderPanel"]);
25
- set cache(val: NonNullable<VirtualOptions["cache"]>);
26
- set panelClass(val: NonNullable<VirtualOptions["panelClass"]>);
27
- constructor(flicking: Flicking, options: VirtualOptions | null);
28
- init(): void;
29
- show(index: number): void;
30
- hide(index: number): void;
31
- append(count?: number): VirtualPanel[];
32
- prepend(count?: number): VirtualPanel[];
33
- insert(index: number, count?: number): VirtualPanel[];
34
- remove(index: number, count: number): VirtualPanel[];
35
- private _initVirtualElements;
36
- }
37
- export default VirtualManager;
1
+ import Flicking from "../Flicking";
2
+ import VirtualPanel from "./panel/VirtualPanel";
3
+ export interface VirtualOptions {
4
+ renderPanel: (panel: VirtualPanel, index: number) => string;
5
+ initialPanelCount: number;
6
+ cache?: boolean;
7
+ panelClass?: string;
8
+ }
9
+ declare class VirtualManager {
10
+ private _flicking;
11
+ private _renderPanel;
12
+ private _initialPanelCount;
13
+ private _cache;
14
+ private _panelClass;
15
+ private _elements;
16
+ get elements(): {
17
+ nativeElement: HTMLElement;
18
+ visible: boolean;
19
+ }[];
20
+ get renderPanel(): VirtualOptions["renderPanel"];
21
+ get initialPanelCount(): number;
22
+ get cache(): NonNullable<VirtualOptions["cache"]>;
23
+ get panelClass(): NonNullable<VirtualOptions["panelClass"]>;
24
+ set renderPanel(val: VirtualOptions["renderPanel"]);
25
+ set cache(val: NonNullable<VirtualOptions["cache"]>);
26
+ set panelClass(val: NonNullable<VirtualOptions["panelClass"]>);
27
+ constructor(flicking: Flicking, options: VirtualOptions | null);
28
+ init(): void;
29
+ show(index: number): void;
30
+ hide(index: number): void;
31
+ append(count?: number): VirtualPanel[];
32
+ prepend(count?: number): VirtualPanel[];
33
+ insert(index: number, count?: number): VirtualPanel[];
34
+ remove(index: number, count: number): VirtualPanel[];
35
+ private _initVirtualElements;
36
+ }
37
+ export default VirtualManager;
@@ -1,6 +1,6 @@
1
- import Viewport from "./Viewport";
2
- import FlickingError from "./FlickingError";
3
- import AnchorPoint from "./AnchorPoint";
4
- import VirtualManager from "./VirtualManager";
5
- export { Viewport, FlickingError, AnchorPoint, VirtualManager };
6
- export * from "./panel";
1
+ import Viewport from "./Viewport";
2
+ import FlickingError from "./FlickingError";
3
+ import AnchorPoint from "./AnchorPoint";
4
+ import VirtualManager from "./VirtualManager";
5
+ export { Viewport, FlickingError, AnchorPoint, VirtualManager };
6
+ export * from "./panel";