@egjs/flicking 4.11.3 → 4.12.0-beta.1
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.
- package/declaration/CrossFlicking.d.ts +29 -0
- package/declaration/Flicking.d.ts +244 -240
- package/declaration/camera/Camera.d.ts +89 -89
- package/declaration/camera/index.d.ts +4 -4
- package/declaration/camera/mode/BoundCameraMode.d.ts +13 -13
- package/declaration/camera/mode/CameraMode.d.ts +20 -20
- package/declaration/camera/mode/CircularCameraMode.d.ts +19 -19
- package/declaration/camera/mode/LinearCameraMode.d.ts +9 -9
- package/declaration/camera/mode/index.d.ts +6 -6
- package/declaration/cfc/getDefaultCameraTransform.d.ts +3 -3
- package/declaration/cfc/getRenderingPanels.d.ts +4 -4
- package/declaration/cfc/index.d.ts +5 -5
- package/declaration/cfc/sync.d.ts +4 -4
- package/declaration/cfc/withFlickingMethods.d.ts +2 -2
- package/declaration/const/axes.d.ts +8 -8
- package/declaration/const/error.d.ts +34 -34
- package/declaration/const/external.d.ts +52 -48
- package/declaration/control/AxesController.d.ts +44 -44
- package/declaration/control/Control.d.ts +45 -45
- package/declaration/control/FreeControl.d.ts +14 -14
- package/declaration/control/SnapControl.d.ts +16 -16
- package/declaration/control/StateMachine.d.ts +14 -14
- package/declaration/control/StrictControl.d.ts +20 -20
- package/declaration/control/index.d.ts +14 -14
- package/declaration/control/states/AnimatingState.d.ts +9 -9
- package/declaration/control/states/DisabledState.d.ts +9 -9
- package/declaration/control/states/DraggingState.d.ts +8 -8
- package/declaration/control/states/HoldingState.d.ts +10 -10
- package/declaration/control/states/IdleState.d.ts +9 -9
- package/declaration/control/states/State.d.ts +47 -47
- package/declaration/core/AnchorPoint.d.ts +15 -15
- package/declaration/core/AutoResizer.d.ts +16 -16
- package/declaration/core/FlickingError.d.ts +5 -5
- package/declaration/core/ResizeWatcher.d.ts +33 -33
- package/declaration/core/Viewport.d.ts +25 -25
- package/declaration/core/VirtualManager.d.ts +37 -37
- package/declaration/core/index.d.ts +6 -6
- package/declaration/core/panel/Panel.d.ts +89 -89
- package/declaration/core/panel/VirtualPanel.d.ts +19 -19
- package/declaration/core/panel/index.d.ts +5 -5
- package/declaration/core/panel/provider/ElementProvider.d.ts +8 -8
- package/declaration/core/panel/provider/VanillaElementProvider.d.ts +12 -12
- package/declaration/core/panel/provider/VirtualElementProvider.d.ts +15 -15
- package/declaration/core/panel/provider/index.d.ts +5 -5
- package/declaration/index.cjs.d.ts +3 -3
- package/declaration/index.d.ts +14 -13
- package/declaration/index.umd.d.ts +2 -2
- package/declaration/renderer/ExternalRenderer.d.ts +7 -7
- package/declaration/renderer/Renderer.d.ts +59 -59
- package/declaration/renderer/VanillaRenderer.d.ts +10 -10
- package/declaration/renderer/index.d.ts +6 -6
- package/declaration/renderer/strategy/NormalRenderingStrategy.d.ts +23 -23
- package/declaration/renderer/strategy/RenderingStrategy.d.ts +15 -15
- package/declaration/renderer/strategy/VirtualRenderingStrategy.d.ts +17 -17
- package/declaration/renderer/strategy/index.d.ts +5 -5
- package/declaration/type/event.d.ts +88 -88
- package/declaration/type/external.d.ts +31 -31
- package/declaration/type/internal.d.ts +13 -13
- package/declaration/utils.d.ts +45 -45
- package/dist/flicking.cjs.js +252 -39
- package/dist/flicking.cjs.js.map +1 -1
- package/dist/flicking.esm.js +249 -40
- package/dist/flicking.esm.js.map +1 -1
- package/dist/flicking.js +255 -39
- package/dist/flicking.js.map +1 -1
- package/dist/flicking.min.js +2 -2
- package/dist/flicking.min.js.map +1 -1
- package/dist/flicking.pkgd.js +255 -39
- package/dist/flicking.pkgd.js.map +1 -1
- package/dist/flicking.pkgd.min.js +2 -2
- package/dist/flicking.pkgd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/CrossFlicking.ts +252 -0
- package/src/Flicking.ts +24 -2
- package/src/const/external.ts +12 -0
- package/src/control/AxesController.ts +1 -1
- package/src/index.ts +2 -0
- package/src/index.umd.ts +2 -0
package/dist/flicking.cjs.js
CHANGED
|
@@ -4,7 +4,7 @@ name: @egjs/flicking
|
|
|
4
4
|
license: MIT
|
|
5
5
|
author: NAVER Corp.
|
|
6
6
|
repository: https://github.com/naver/egjs-flicking
|
|
7
|
-
version: 4.
|
|
7
|
+
version: 4.12.0-beta.1
|
|
8
8
|
*/
|
|
9
9
|
'use strict';
|
|
10
10
|
|
|
@@ -413,6 +413,17 @@ var ORDER = {
|
|
|
413
413
|
LTR: "ltr",
|
|
414
414
|
RTL: "rtl"
|
|
415
415
|
};
|
|
416
|
+
/**
|
|
417
|
+
* An object that contains the direction that {@link Flicking} is moving
|
|
418
|
+
* @ko {@link Flicking}이 움직이는 방향을 담고 있는 객체
|
|
419
|
+
* @type {object}
|
|
420
|
+
* @property {"horizontal"} HORIZONTAL horizontal<ko>수평 방향</ko>
|
|
421
|
+
* @property {"vertical"} VERTICAL vertical<ko>수직 방향</ko>
|
|
422
|
+
*/
|
|
423
|
+
var MOVE_DIRECTION = {
|
|
424
|
+
HORIZONTAL: "horizontal",
|
|
425
|
+
VERTICAL: "vertical"
|
|
426
|
+
};
|
|
416
427
|
|
|
417
428
|
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
418
429
|
var merge = function (target) {
|
|
@@ -2102,7 +2113,7 @@ var AxesController = /*#__PURE__*/function () {
|
|
|
2102
2113
|
});
|
|
2103
2114
|
this._panInput = new Axes.PanInput(flicking.viewport.element, {
|
|
2104
2115
|
inputType: flicking.inputType,
|
|
2105
|
-
threshold:
|
|
2116
|
+
threshold: flicking.dragThreshold,
|
|
2106
2117
|
iOSEdgeSwipeThreshold: flicking.iOSEdgeSwipeThreshold,
|
|
2107
2118
|
preventDefaultOnDrag: flicking.preventDefaultOnDrag,
|
|
2108
2119
|
scale: flicking.horizontal ? [flicking.camera.panelOrder === ORDER.RTL ? 1 : -1, 0] : [0, -1],
|
|
@@ -6012,40 +6023,42 @@ var Flicking = /*#__PURE__*/function (_super) {
|
|
|
6012
6023
|
moveType = _v === void 0 ? "snap" : _v,
|
|
6013
6024
|
_w = _b.threshold,
|
|
6014
6025
|
threshold = _w === void 0 ? 40 : _w,
|
|
6015
|
-
_x = _b.
|
|
6016
|
-
|
|
6017
|
-
_y = _b.
|
|
6018
|
-
|
|
6019
|
-
_z = _b.
|
|
6020
|
-
|
|
6021
|
-
_0 = _b.
|
|
6022
|
-
|
|
6023
|
-
_1 = _b.
|
|
6024
|
-
|
|
6025
|
-
_2 = _b.
|
|
6026
|
-
|
|
6027
|
-
_3 = _b.
|
|
6028
|
-
|
|
6029
|
-
_4 = _b.
|
|
6030
|
-
|
|
6031
|
-
_5 = _b.
|
|
6032
|
-
|
|
6033
|
-
_6 = _b.
|
|
6034
|
-
|
|
6035
|
-
_7 = _b.
|
|
6036
|
-
|
|
6037
|
-
_8 = _b.
|
|
6038
|
-
|
|
6039
|
-
_9 = _b.
|
|
6040
|
-
|
|
6041
|
-
_10 = _b.
|
|
6042
|
-
|
|
6043
|
-
_11 = _b.
|
|
6044
|
-
|
|
6045
|
-
_12 = _b.
|
|
6046
|
-
|
|
6047
|
-
_13 = _b.
|
|
6048
|
-
|
|
6026
|
+
_x = _b.dragThreshold,
|
|
6027
|
+
dragThreshold = _x === void 0 ? 1 : _x,
|
|
6028
|
+
_y = _b.interruptable,
|
|
6029
|
+
interruptable = _y === void 0 ? true : _y,
|
|
6030
|
+
_z = _b.bounce,
|
|
6031
|
+
bounce = _z === void 0 ? "20%" : _z,
|
|
6032
|
+
_0 = _b.iOSEdgeSwipeThreshold,
|
|
6033
|
+
iOSEdgeSwipeThreshold = _0 === void 0 ? 30 : _0,
|
|
6034
|
+
_1 = _b.preventClickOnDrag,
|
|
6035
|
+
preventClickOnDrag = _1 === void 0 ? true : _1,
|
|
6036
|
+
_2 = _b.preventDefaultOnDrag,
|
|
6037
|
+
preventDefaultOnDrag = _2 === void 0 ? false : _2,
|
|
6038
|
+
_3 = _b.disableOnInit,
|
|
6039
|
+
disableOnInit = _3 === void 0 ? false : _3,
|
|
6040
|
+
_4 = _b.changeOnHold,
|
|
6041
|
+
changeOnHold = _4 === void 0 ? false : _4,
|
|
6042
|
+
_5 = _b.renderOnlyVisible,
|
|
6043
|
+
renderOnlyVisible = _5 === void 0 ? false : _5,
|
|
6044
|
+
_6 = _b.virtual,
|
|
6045
|
+
virtual = _6 === void 0 ? null : _6,
|
|
6046
|
+
_7 = _b.autoInit,
|
|
6047
|
+
autoInit = _7 === void 0 ? true : _7,
|
|
6048
|
+
_8 = _b.autoResize,
|
|
6049
|
+
autoResize = _8 === void 0 ? true : _8,
|
|
6050
|
+
_9 = _b.useResizeObserver,
|
|
6051
|
+
useResizeObserver = _9 === void 0 ? true : _9,
|
|
6052
|
+
_10 = _b.resizeDebounce,
|
|
6053
|
+
resizeDebounce = _10 === void 0 ? 0 : _10,
|
|
6054
|
+
_11 = _b.maxResizeDebounce,
|
|
6055
|
+
maxResizeDebounce = _11 === void 0 ? 100 : _11,
|
|
6056
|
+
_12 = _b.useFractionalSize,
|
|
6057
|
+
useFractionalSize = _12 === void 0 ? false : _12,
|
|
6058
|
+
_13 = _b.externalRenderer,
|
|
6059
|
+
externalRenderer = _13 === void 0 ? null : _13,
|
|
6060
|
+
_14 = _b.renderExternal,
|
|
6061
|
+
renderExternal = _14 === void 0 ? null : _14;
|
|
6049
6062
|
var _this = _super.call(this) || this;
|
|
6050
6063
|
// Internal states
|
|
6051
6064
|
_this._initialized = false;
|
|
@@ -6071,6 +6084,7 @@ var Flicking = /*#__PURE__*/function (_super) {
|
|
|
6071
6084
|
_this._inputType = inputType;
|
|
6072
6085
|
_this._moveType = moveType;
|
|
6073
6086
|
_this._threshold = threshold;
|
|
6087
|
+
_this._dragThreshold = dragThreshold;
|
|
6074
6088
|
_this._interruptable = interruptable;
|
|
6075
6089
|
_this._bounce = bounce;
|
|
6076
6090
|
_this._iOSEdgeSwipeThreshold = iOSEdgeSwipeThreshold;
|
|
@@ -6385,7 +6399,7 @@ var Flicking = /*#__PURE__*/function (_super) {
|
|
|
6385
6399
|
Object.defineProperty(__proto, "defaultIndex", {
|
|
6386
6400
|
/**
|
|
6387
6401
|
* Index of the panel to move when Flicking's {@link Flicking#init init()} is called. A zero-based integer
|
|
6388
|
-
* @ko Flicking의 {@link Flicking#init init()}이 호출될 때 이동할 디폴트 패널의 인덱스로, 0부터 시작하는
|
|
6402
|
+
* @ko Flicking의 {@link Flicking#init init()}이 호출될 때 이동할 디폴트 패널의 인덱스로, 0부터 시작하는 정수입니다.
|
|
6389
6403
|
* @type {number}
|
|
6390
6404
|
* @default 0
|
|
6391
6405
|
* @see {@link https://naver.github.io/egjs-flicking/Options#defaultindex defaultIndex ( Options )}
|
|
@@ -6750,7 +6764,7 @@ var Flicking = /*#__PURE__*/function (_super) {
|
|
|
6750
6764
|
Object.defineProperty(__proto, "threshold", {
|
|
6751
6765
|
/**
|
|
6752
6766
|
* Movement threshold to change panel (unit: px). It should be dragged above the threshold to change the current panel.
|
|
6753
|
-
* @ko 패널 변경을 위한 이동 임계값 (단위: px). 주어진 값 이상으로 스크롤해야만 패널 변경이
|
|
6767
|
+
* @ko 패널 변경을 위한 이동 임계값 (단위: px). 주어진 값 이상으로 스크롤해야만 패널 변경이 가능합니다.
|
|
6754
6768
|
* @type {number}
|
|
6755
6769
|
* @default 40
|
|
6756
6770
|
* @see {@link https://naver.github.io/egjs-flicking/Options#threshold Threshold ( Options )}
|
|
@@ -6764,6 +6778,27 @@ var Flicking = /*#__PURE__*/function (_super) {
|
|
|
6764
6778
|
enumerable: false,
|
|
6765
6779
|
configurable: true
|
|
6766
6780
|
});
|
|
6781
|
+
Object.defineProperty(__proto, "dragThreshold", {
|
|
6782
|
+
/**
|
|
6783
|
+
* Minimal distance of user input before recognizing (unit: px). It should be dragged above the dragThreshold to move the panel.
|
|
6784
|
+
* @ko 사용자의 입력을 인식하기 위한 최소한의 거리 (단위: px). 주어진 값 이상으로 스크롤해야만 패널이 움직입니다.
|
|
6785
|
+
* @type {number}
|
|
6786
|
+
* @default 1
|
|
6787
|
+
* @see {@link https://naver.github.io/egjs-flicking/Options#dragThreshold dragThreshold ( Options )}
|
|
6788
|
+
*/
|
|
6789
|
+
get: function () {
|
|
6790
|
+
return this._dragThreshold;
|
|
6791
|
+
},
|
|
6792
|
+
set: function (val) {
|
|
6793
|
+
this._dragThreshold = val;
|
|
6794
|
+
var panInput = this._control.controller.panInput;
|
|
6795
|
+
if (panInput) {
|
|
6796
|
+
panInput.options.threshold = val;
|
|
6797
|
+
}
|
|
6798
|
+
},
|
|
6799
|
+
enumerable: false,
|
|
6800
|
+
configurable: true
|
|
6801
|
+
});
|
|
6767
6802
|
Object.defineProperty(__proto, "interruptable", {
|
|
6768
6803
|
/**
|
|
6769
6804
|
* Set animation to be interruptable by click/touch.
|
|
@@ -7838,10 +7873,184 @@ var Flicking = /*#__PURE__*/function (_super) {
|
|
|
7838
7873
|
* Flicking.VERSION; // ex) 4.0.0
|
|
7839
7874
|
* ```
|
|
7840
7875
|
*/
|
|
7841
|
-
Flicking.VERSION = "4.
|
|
7876
|
+
Flicking.VERSION = "4.12.0-beta.1";
|
|
7842
7877
|
return Flicking;
|
|
7843
7878
|
}(Component);
|
|
7844
7879
|
|
|
7880
|
+
/*
|
|
7881
|
+
* Copyright (c) 2015 NAVER Corp.
|
|
7882
|
+
* egjs projects are licensed under the MIT license
|
|
7883
|
+
*/
|
|
7884
|
+
/**
|
|
7885
|
+
* @extends Component
|
|
7886
|
+
* @support {"ie": "9+(with polyfill)", "ch" : "latest", "ff" : "latest", "sf" : "latest", "edge" : "latest", "ios" : "7+", "an" : "4.X+"}
|
|
7887
|
+
* @requires {@link https://github.com/naver/egjs-component|@egjs/component}
|
|
7888
|
+
* @requires {@link https://github.com/naver/egjs-axes|@egjs/axes}
|
|
7889
|
+
*/
|
|
7890
|
+
var CrossFlicking = /*#__PURE__*/function (_super) {
|
|
7891
|
+
__extends(CrossFlicking, _super);
|
|
7892
|
+
// Options Setter
|
|
7893
|
+
// UI / LAYOUT
|
|
7894
|
+
// public set align(val: FlickingOptions["align"]) {
|
|
7895
|
+
// this._align = val;
|
|
7896
|
+
// }
|
|
7897
|
+
function CrossFlicking(root, _a) {
|
|
7898
|
+
var _b = (_a === void 0 ? {} : _a).verticalOptions,
|
|
7899
|
+
verticalOptions = _b === void 0 ? undefined : _b;
|
|
7900
|
+
var _this = _super.call(this, root) || this;
|
|
7901
|
+
_this._onHorizontalHoldStart = function () {
|
|
7902
|
+
_this.dragThreshold = 10;
|
|
7903
|
+
_this._moveDirection = null;
|
|
7904
|
+
};
|
|
7905
|
+
_this._onHorizontalMove = function (e) {
|
|
7906
|
+
if (e.isTrusted && !_this._moveDirection) {
|
|
7907
|
+
_this._verticalFlicking.forEach(function (child) {
|
|
7908
|
+
child.dragThreshold = Infinity;
|
|
7909
|
+
});
|
|
7910
|
+
_this._moveDirection = MOVE_DIRECTION.HORIZONTAL;
|
|
7911
|
+
}
|
|
7912
|
+
};
|
|
7913
|
+
_this._onHorizontalMoveEnd = function (e) {
|
|
7914
|
+
var visiblePanels = _this.visiblePanels;
|
|
7915
|
+
_this._verticalFlicking.forEach(function (child) {
|
|
7916
|
+
child.dragThreshold = 10;
|
|
7917
|
+
});
|
|
7918
|
+
_this._moveDirection = null;
|
|
7919
|
+
if (visiblePanels.length > 1) {
|
|
7920
|
+
_this._nextIndex = e.direction === "NEXT" ? visiblePanels[1].index : visiblePanels[0].index;
|
|
7921
|
+
} else {
|
|
7922
|
+
_this._nextIndex = visiblePanels[0].index;
|
|
7923
|
+
}
|
|
7924
|
+
_this._verticalFlicking.forEach(function (child, i) {
|
|
7925
|
+
if (_this._nextIndex !== i) {
|
|
7926
|
+
var _a = _this._verticalState[i],
|
|
7927
|
+
start = _a.start,
|
|
7928
|
+
end = _a.end;
|
|
7929
|
+
if (child.index < start) {
|
|
7930
|
+
child.stopAnimation();
|
|
7931
|
+
void child.moveTo(start, 0);
|
|
7932
|
+
} else if (child.index > end) {
|
|
7933
|
+
child.stopAnimation();
|
|
7934
|
+
void child.moveTo(end, 0);
|
|
7935
|
+
}
|
|
7936
|
+
}
|
|
7937
|
+
});
|
|
7938
|
+
if (e.isTrusted) {
|
|
7939
|
+
_this._syncToCategory(_this._verticalFlicking[_this._nextIndex].index, _this._nextIndex);
|
|
7940
|
+
}
|
|
7941
|
+
};
|
|
7942
|
+
_this._onVerticalHoldStart = function () {
|
|
7943
|
+
_this._verticalFlicking.forEach(function (child) {
|
|
7944
|
+
child.dragThreshold = 10;
|
|
7945
|
+
});
|
|
7946
|
+
_this._moveDirection = null;
|
|
7947
|
+
};
|
|
7948
|
+
_this._onVerticalMove = function (e) {
|
|
7949
|
+
if (e.isTrusted && !_this._moveDirection) {
|
|
7950
|
+
_this.dragThreshold = Infinity;
|
|
7951
|
+
_this._moveDirection = MOVE_DIRECTION.VERTICAL;
|
|
7952
|
+
}
|
|
7953
|
+
};
|
|
7954
|
+
_this._onVerticalMoveEnd = function () {
|
|
7955
|
+
_this.dragThreshold = 10;
|
|
7956
|
+
_this._moveDirection = null;
|
|
7957
|
+
};
|
|
7958
|
+
_this._onVerticalChanged = function (e) {
|
|
7959
|
+
// this.visiblePanels.length 가 2보다 크다면 가로 방향 Flicking이 조작 중이라는 것을 의미합니다.
|
|
7960
|
+
// 이 경우 가로 방향 Flicking의 이동이 완전히 끝난 뒤 _onHorizontalMoveEnd 에서 syncToCategory할 것이므로 여기서는 하지 않습니다.
|
|
7961
|
+
if (_this.visiblePanels.length < 2 && _this._verticalFlicking[_this.index] === e.currentTarget) {
|
|
7962
|
+
_this._syncToCategory(e.index, _this.index);
|
|
7963
|
+
}
|
|
7964
|
+
};
|
|
7965
|
+
// Internal states
|
|
7966
|
+
_this._verticalState = [];
|
|
7967
|
+
_this._moveDirection = null;
|
|
7968
|
+
_this._nextIndex = 0;
|
|
7969
|
+
// Bind options
|
|
7970
|
+
_this._verticalOptions = verticalOptions;
|
|
7971
|
+
return _this;
|
|
7972
|
+
// Create core components
|
|
7973
|
+
// this._viewport = new Viewport(this, getElement(root));
|
|
7974
|
+
}
|
|
7975
|
+
var __proto = CrossFlicking.prototype;
|
|
7976
|
+
Object.defineProperty(__proto, "verticalOptions", {
|
|
7977
|
+
// Components
|
|
7978
|
+
/**
|
|
7979
|
+
* Change active panel index on mouse/touch hold while animating.
|
|
7980
|
+
* `index` of the `willChange`/`willRestore` event will be used as new index.
|
|
7981
|
+
* @ko 애니메이션 도중 마우스/터치 입력시 현재 활성화된 패널의 인덱스를 변경합니다.
|
|
7982
|
+
* `willChange`/`willRestore` 이벤트의 `index`값이 새로운 인덱스로 사용될 것입니다.
|
|
7983
|
+
* @type {FlickingOptions}
|
|
7984
|
+
* @default undefined
|
|
7985
|
+
* @see {@link https://naver.github.io/egjs-flicking/Options#changeonhold changeOnHold ( Options )}
|
|
7986
|
+
*/
|
|
7987
|
+
get: function () {
|
|
7988
|
+
return this._verticalOptions;
|
|
7989
|
+
},
|
|
7990
|
+
enumerable: false,
|
|
7991
|
+
configurable: true
|
|
7992
|
+
});
|
|
7993
|
+
/**
|
|
7994
|
+
* Initialize Flicking and move to the default index
|
|
7995
|
+
* This is automatically called on Flicking's constructor when `autoInit` is true(default)
|
|
7996
|
+
* @ko Flicking을 초기화하고, 디폴트 인덱스로 이동합니다
|
|
7997
|
+
* 이 메소드는 `autoInit` 옵션이 true(default)일 경우 Flicking이 생성될 때 자동으로 호출됩니다
|
|
7998
|
+
* @fires Flicking#ready
|
|
7999
|
+
* @return {Promise<void>}
|
|
8000
|
+
*/
|
|
8001
|
+
__proto.init = function () {
|
|
8002
|
+
var _this = this;
|
|
8003
|
+
return _super.prototype.init.call(this).then(function () {
|
|
8004
|
+
// data-index로 분류하기 전에 임시로 모든 children에 대해 vertical flicking으로 해보자.
|
|
8005
|
+
// camera.children들에 대해 갯수 세기
|
|
8006
|
+
var verticalPanels = "";
|
|
8007
|
+
_this._verticalState = _this.camera.children.reduce(function (state, child) {
|
|
8008
|
+
var start = state.length ? +state[state.length - 1].end + 1 : 0;
|
|
8009
|
+
verticalPanels += child.children[0].innerHTML;
|
|
8010
|
+
return __spread(state, [{
|
|
8011
|
+
start: start,
|
|
8012
|
+
end: start + child.children[0].children.length - 1,
|
|
8013
|
+
element: child
|
|
8014
|
+
}]);
|
|
8015
|
+
}, []);
|
|
8016
|
+
_this.camera.children.forEach(function (child) {
|
|
8017
|
+
child.children[0].innerHTML = verticalPanels;
|
|
8018
|
+
});
|
|
8019
|
+
_this._verticalFlicking = _this.camera.children.map(function (child, i) {
|
|
8020
|
+
return new Flicking(child, __assign(__assign({}, _this.verticalOptions), {
|
|
8021
|
+
horizontal: false,
|
|
8022
|
+
panelsPerView: 1,
|
|
8023
|
+
defaultIndex: _this._verticalState[i].start
|
|
8024
|
+
}));
|
|
8025
|
+
});
|
|
8026
|
+
_this.on(EVENTS.HOLD_START, _this._onHorizontalHoldStart);
|
|
8027
|
+
_this.on(EVENTS.MOVE, _this._onHorizontalMove);
|
|
8028
|
+
_this.on(EVENTS.MOVE_END, _this._onHorizontalMoveEnd);
|
|
8029
|
+
_this._verticalFlicking.forEach(function (child) {
|
|
8030
|
+
child.on(EVENTS.HOLD_START, _this._onVerticalHoldStart);
|
|
8031
|
+
child.on(EVENTS.MOVE, _this._onVerticalMove);
|
|
8032
|
+
child.on(EVENTS.MOVE_END, _this._onVerticalMoveEnd);
|
|
8033
|
+
child.on(EVENTS.CHANGED, _this._onVerticalChanged);
|
|
8034
|
+
});
|
|
8035
|
+
});
|
|
8036
|
+
};
|
|
8037
|
+
__proto._syncToCategory = function (index, outerIndex) {
|
|
8038
|
+
var _this = this;
|
|
8039
|
+
this.stopAnimation();
|
|
8040
|
+
this._verticalFlicking.forEach(function (child, i) {
|
|
8041
|
+
var _a = _this._verticalState[i],
|
|
8042
|
+
start = _a.start,
|
|
8043
|
+
end = _a.end;
|
|
8044
|
+
if (start <= index && end >= index && outerIndex !== i) {
|
|
8045
|
+
child.stopAnimation();
|
|
8046
|
+
void child.moveTo(index, 0);
|
|
8047
|
+
void _this.moveTo(i, 0);
|
|
8048
|
+
}
|
|
8049
|
+
});
|
|
8050
|
+
};
|
|
8051
|
+
return CrossFlicking;
|
|
8052
|
+
}(Flicking);
|
|
8053
|
+
|
|
7845
8054
|
/**
|
|
7846
8055
|
* Decorator that makes the method of flicking available in the framework.
|
|
7847
8056
|
* @ko 프레임워크에서 플리킹의 메소드를 사용할 수 있게 하는 데코레이터.
|
|
@@ -8059,6 +8268,7 @@ var parseAlign = function (alignVal) {
|
|
|
8059
8268
|
var modules = {
|
|
8060
8269
|
__proto__: null,
|
|
8061
8270
|
'default': Flicking,
|
|
8271
|
+
CrossFlicking: CrossFlicking,
|
|
8062
8272
|
VanillaElementProvider: VanillaElementProvider,
|
|
8063
8273
|
VirtualElementProvider: VirtualElementProvider,
|
|
8064
8274
|
Panel: Panel,
|
|
@@ -8096,6 +8306,7 @@ var modules = {
|
|
|
8096
8306
|
CLASS: CLASS,
|
|
8097
8307
|
CIRCULAR_FALLBACK: CIRCULAR_FALLBACK,
|
|
8098
8308
|
ORDER: ORDER,
|
|
8309
|
+
MOVE_DIRECTION: MOVE_DIRECTION,
|
|
8099
8310
|
withFlickingMethods: withFlickingMethods,
|
|
8100
8311
|
sync: sync,
|
|
8101
8312
|
getRenderingPanels: getRenderingPanels,
|
|
@@ -8150,6 +8361,7 @@ exports.CLASS = CLASS;
|
|
|
8150
8361
|
exports.Camera = Camera;
|
|
8151
8362
|
exports.CircularCameraMode = CircularCameraMode;
|
|
8152
8363
|
exports.Control = Control;
|
|
8364
|
+
exports.CrossFlicking = CrossFlicking;
|
|
8153
8365
|
exports.DIRECTION = DIRECTION;
|
|
8154
8366
|
exports.DisabledState = DisabledState;
|
|
8155
8367
|
exports.DraggingState = DraggingState;
|
|
@@ -8161,6 +8373,7 @@ exports.FreeControl = FreeControl;
|
|
|
8161
8373
|
exports.HoldingState = HoldingState;
|
|
8162
8374
|
exports.IdleState = IdleState;
|
|
8163
8375
|
exports.LinearCameraMode = LinearCameraMode;
|
|
8376
|
+
exports.MOVE_DIRECTION = MOVE_DIRECTION;
|
|
8164
8377
|
exports.MOVE_TYPE = MOVE_TYPE;
|
|
8165
8378
|
exports.NormalRenderingStrategy = NormalRenderingStrategy;
|
|
8166
8379
|
exports.ORDER = ORDER;
|