@egjs/flicking 4.12.0-beta.0 → 4.12.0-beta.10

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.
@@ -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.12.0-beta.0
7
+ version: 4.12.0-beta.10
8
8
  */
9
9
  (function (global, factory) {
10
10
  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
@@ -794,6 +794,8 @@ version: 4.12.0-beta.0
794
794
  STRICT: "strict"
795
795
  };
796
796
  var CLASS = {
797
+ VIEWPORT: "flicking-viewport",
798
+ CAMERA: "flicking-camera",
797
799
  VERTICAL: "vertical",
798
800
  HIDDEN: "flicking-hidden",
799
801
  DEFAULT_VIRTUAL: "flicking-panel"
@@ -820,6 +822,17 @@ version: 4.12.0-beta.0
820
822
  LTR: "ltr",
821
823
  RTL: "rtl"
822
824
  };
825
+ /**
826
+ * An object that contains the direction that {@link Flicking} is moving
827
+ * @ko {@link Flicking}이 움직이는 방향을 담고 있는 객체
828
+ * @type {object}
829
+ * @property {"horizontal"} HORIZONTAL horizontal<ko>수평 방향</ko>
830
+ * @property {"vertical"} VERTICAL vertical<ko>수직 방향</ko>
831
+ */
832
+ var MOVE_DIRECTION = {
833
+ HORIZONTAL: "horizontal",
834
+ VERTICAL: "vertical"
835
+ };
823
836
 
824
837
  var Constants = {
825
838
  __proto__: null,
@@ -830,6 +843,7 @@ version: 4.12.0-beta.0
830
843
  CLASS: CLASS,
831
844
  CIRCULAR_FALLBACK: CIRCULAR_FALLBACK,
832
845
  ORDER: ORDER,
846
+ MOVE_DIRECTION: MOVE_DIRECTION,
833
847
  ERROR_CODE: CODE
834
848
  };
835
849
 
@@ -1146,6 +1160,26 @@ version: 4.12.0-beta.0
1146
1160
  obj.__proto__ = proto;
1147
1161
  return obj;
1148
1162
  };
1163
+ var camelize = function (str) {
1164
+ return str.replace(/[\s-_]([a-z])/g, function (all, letter) {
1165
+ return letter.toUpperCase();
1166
+ });
1167
+ };
1168
+ var getDataAttributes = function (element, attributePrefix) {
1169
+ var dataAttributes = {};
1170
+ var attributes = element.attributes;
1171
+ var length = attributes.length;
1172
+ for (var i = 0; i < length; ++i) {
1173
+ var attribute = attributes[i];
1174
+ var name_1 = attribute.name,
1175
+ value = attribute.value;
1176
+ if (name_1.indexOf(attributePrefix) === -1) {
1177
+ continue;
1178
+ }
1179
+ dataAttributes[camelize(name_1.replace(attributePrefix, ""))] = value;
1180
+ }
1181
+ return dataAttributes;
1182
+ };
1149
1183
 
1150
1184
  var Utils = {
1151
1185
  __proto__: null,
@@ -1177,7 +1211,9 @@ version: 4.12.0-beta.0
1177
1211
  circulateIndex: circulateIndex,
1178
1212
  range: range,
1179
1213
  getElementSize: getElementSize,
1180
- setPrototypeOf: setPrototypeOf
1214
+ setPrototypeOf: setPrototypeOf,
1215
+ camelize: camelize,
1216
+ getDataAttributes: getDataAttributes
1181
1217
  };
1182
1218
 
1183
1219
  /*
@@ -2659,7 +2695,7 @@ version: 4.12.0-beta.0
2659
2695
  license: MIT
2660
2696
  author: NAVER Corp.
2661
2697
  repository: https://github.com/naver/egjs-axes
2662
- version: 3.9.0
2698
+ version: 3.9.1-beta.0
2663
2699
  */
2664
2700
 
2665
2701
  /*! *****************************************************************************
@@ -2713,9 +2749,9 @@ version: 4.12.0-beta.0
2713
2749
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2714
2750
  }
2715
2751
 
2716
- /*
2717
- * Copyright (c) 2015 NAVER Corp.
2718
- * egjs projects are licensed under the MIT license
2752
+ /*
2753
+ * Copyright (c) 2015 NAVER Corp.
2754
+ * egjs projects are licensed under the MIT license
2719
2755
  */
2720
2756
  /* eslint-disable no-new-func, no-nested-ternary */
2721
2757
  var win;
@@ -2730,9 +2766,9 @@ version: 4.12.0-beta.0
2730
2766
  win = window;
2731
2767
  }
2732
2768
 
2733
- /*
2734
- * Copyright (c) 2015 NAVER Corp.
2735
- * egjs projects are licensed under the MIT license
2769
+ /*
2770
+ * Copyright (c) 2015 NAVER Corp.
2771
+ * egjs projects are licensed under the MIT license
2736
2772
  */
2737
2773
  var DIRECTION_NONE = 1;
2738
2774
  var DIRECTION_LEFT = 2;
@@ -2858,19 +2894,19 @@ version: 4.12.0-beta.0
2858
2894
  };
2859
2895
  caf = win.clearTimeout;
2860
2896
  }
2861
- /**
2862
- * A polyfill for the window.requestAnimationFrame() method.
2863
- * @see https://developer.mozilla.org/en-US/docs/Web/API/window/requestAnimationFrame
2864
- * @private
2897
+ /**
2898
+ * A polyfill for the window.requestAnimationFrame() method.
2899
+ * @see https://developer.mozilla.org/en-US/docs/Web/API/window/requestAnimationFrame
2900
+ * @private
2865
2901
  */
2866
- var requestAnimationFrame = function (fp) {
2902
+ var requestAnimationFrame$1 = function (fp) {
2867
2903
  return raf(fp);
2868
2904
  };
2869
- /**
2870
- * A polyfill for the window.cancelAnimationFrame() method. It cancels an animation executed through a call to the requestAnimationFrame() method.
2871
- * @param {Number} key − The ID value returned through a call to the requestAnimationFrame() method. <ko>requestAnimationFrame() 메서드가 반환한 아이디 값</ko>
2872
- * @see https://developer.mozilla.org/en-US/docs/Web/API/Window/cancelAnimationFrame
2873
- * @private
2905
+ /**
2906
+ * A polyfill for the window.cancelAnimationFrame() method. It cancels an animation executed through a call to the requestAnimationFrame() method.
2907
+ * @param {Number} key − The ID value returned through a call to the requestAnimationFrame() method. <ko>requestAnimationFrame() 메서드가 반환한 아이디 값</ko>
2908
+ * @see https://developer.mozilla.org/en-US/docs/Web/API/Window/cancelAnimationFrame
2909
+ * @private
2874
2910
  */
2875
2911
  var cancelAnimationFrame = function (key) {
2876
2912
  caf(key);
@@ -2997,6 +3033,9 @@ version: 4.12.0-beta.0
2997
3033
  });
2998
3034
  Object.keys(newCssProps_1).forEach(function (prop) {
2999
3035
  oldCssProps[prop] = element.style[prop];
3036
+ });
3037
+ // Old style props like user-select can be corrupted if you change the style directly in the logic above.
3038
+ Object.keys(newCssProps_1).forEach(function (prop) {
3000
3039
  element.style[prop] = newCssProps_1[prop];
3001
3040
  });
3002
3041
  }
@@ -3016,32 +3055,32 @@ version: 4.12.0-beta.0
3016
3055
  this._axes = _axes;
3017
3056
  this.holdingCount = 0;
3018
3057
  }
3019
- /**
3020
- * This event is fired when a user holds an element on the screen of the device.
3021
- * @ko 사용자가 기기의 화면에 손을 대고 있을 때 발생하는 이벤트
3022
- * @event Axes#hold
3023
- * @type {object}
3024
- * @property {Object.<string, number>} pos coordinate <ko>좌표 정보</ko>
3025
- * @property {Object} input The instance of inputType where the event occurred<ko>이벤트가 발생한 inputType 인스턴스</ko>
3026
- * @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
3027
- * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3028
- *
3029
- * @example
3030
- * ```js
3031
- * const axes = new eg.Axes({
3032
- * "x": {
3033
- * range: [0, 100]
3034
- * },
3035
- * "zoom": {
3036
- * range: [50, 30]
3037
- * }
3038
- * }).on("hold", function(event) {
3039
- * // event.pos
3040
- * // event.input
3041
- * // event.inputEvent
3042
- * // isTrusted
3043
- * });
3044
- * ```
3058
+ /**
3059
+ * This event is fired when a user holds an element on the screen of the device.
3060
+ * @ko 사용자가 기기의 화면에 손을 대고 있을 때 발생하는 이벤트
3061
+ * @event Axes#hold
3062
+ * @type {object}
3063
+ * @property {Object.<string, number>} pos coordinate <ko>좌표 정보</ko>
3064
+ * @property {Object} input The instance of inputType where the event occurred<ko>이벤트가 발생한 inputType 인스턴스</ko>
3065
+ * @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
3066
+ * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3067
+ *
3068
+ * @example
3069
+ * ```js
3070
+ * const axes = new eg.Axes({
3071
+ * "x": {
3072
+ * range: [0, 100]
3073
+ * },
3074
+ * "zoom": {
3075
+ * range: [50, 30]
3076
+ * }
3077
+ * }).on("hold", function(event) {
3078
+ * // event.pos
3079
+ * // event.input
3080
+ * // event.inputEvent
3081
+ * // isTrusted
3082
+ * });
3083
+ * ```
3045
3084
  */
3046
3085
  var __proto = EventManager.prototype;
3047
3086
  __proto.hold = function (pos, option) {
@@ -3053,78 +3092,78 @@ version: 4.12.0-beta.0
3053
3092
  isTrusted: true
3054
3093
  }));
3055
3094
  };
3056
- /**
3057
- * Specifies the coordinates to move after the 'change' event. It works when the holding value of the change event is true.
3058
- * @ko 'change' 이벤트 이후 이동할 좌표를 지정한다. change이벤트의 holding 값이 true일 경우에 동작한다
3059
- * @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
3060
- * @example
3061
- * ```js
3062
- * const axes = new eg.Axes({
3063
- * "x": {
3064
- * range: [0, 100]
3065
- * },
3066
- * "zoom": {
3067
- * range: [50, 30]
3068
- * }
3069
- * }).on("change", function(event) {
3070
- * event.holding && event.set({x: 10});
3071
- * });
3072
- * ```
3095
+ /**
3096
+ * Specifies the coordinates to move after the 'change' event. It works when the holding value of the change event is true.
3097
+ * @ko 'change' 이벤트 이후 이동할 좌표를 지정한다. change이벤트의 holding 값이 true일 경우에 동작한다
3098
+ * @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
3099
+ * @example
3100
+ * ```js
3101
+ * const axes = new eg.Axes({
3102
+ * "x": {
3103
+ * range: [0, 100]
3104
+ * },
3105
+ * "zoom": {
3106
+ * range: [50, 30]
3107
+ * }
3108
+ * }).on("change", function(event) {
3109
+ * event.holding && event.set({x: 10});
3110
+ * });
3111
+ * ```
3073
3112
  */
3074
- /** Specifies the animation coordinates to move after the 'release' or 'animationStart' events.
3075
- * @ko 'release' 또는 'animationStart' 이벤트 이후 이동할 좌표를 지정한다.
3076
- * @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
3077
- * @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
3078
- * @example
3079
- * ```js
3080
- * const axes = new eg.Axes({
3081
- * "x": {
3082
- * range: [0, 100]
3083
- * },
3084
- * "zoom": {
3085
- * range: [50, 30]
3086
- * }
3087
- * }).on("animationStart", function(event) {
3088
- * event.setTo({x: 10}, 2000);
3089
- * });
3090
- * ```
3113
+ /** Specifies the animation coordinates to move after the 'release' or 'animationStart' events.
3114
+ * @ko 'release' 또는 'animationStart' 이벤트 이후 이동할 좌표를 지정한다.
3115
+ * @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
3116
+ * @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
3117
+ * @example
3118
+ * ```js
3119
+ * const axes = new eg.Axes({
3120
+ * "x": {
3121
+ * range: [0, 100]
3122
+ * },
3123
+ * "zoom": {
3124
+ * range: [50, 30]
3125
+ * }
3126
+ * }).on("animationStart", function(event) {
3127
+ * event.setTo({x: 10}, 2000);
3128
+ * });
3129
+ * ```
3091
3130
  */
3092
- /**
3093
- * This event is fired when a user release an element on the screen of the device.
3094
- * @ko 사용자가 기기의 화면에서 손을 뗐을 때 발생하는 이벤트
3095
- * @event Axes#release
3096
- * @type {object}
3097
- * @property {Object.<string, number>} depaPos The coordinates when releasing an element<ko>손을 뗐을 때의 좌표 </ko>
3098
- * @property {Object.<string, number>} destPos The coordinates to move to after releasing an element<ko>손을 뗀 뒤에 이동할 좌표</ko>
3099
- * @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
3100
- * @property {Object.<string, number>} bounceRatio If the coordinates at the time of release are in the bounce area, the current bounce value divided by the maximum bounce value <ko>손을 뗐을 때의 좌표가 bounce 영역에 있는 경우 현재 bounce된 값을 최대 bounce 값으로 나눈 수치.</ko>
3101
- * @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
3102
- * @property {Object} input The instance of inputType where the event occurred<ko>이벤트가 발생한 inputType 인스턴스</ko>
3103
- * @property {setTo} setTo Specifies the animation coordinates to move after the event <ko>이벤트 이후 이동할 애니메이션 좌표를 지정한다</ko>
3104
- * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3105
- *
3106
- * @example
3107
- * ```js
3108
- * const axes = new eg.Axes({
3109
- * "x": {
3110
- * range: [0, 100]
3111
- * },
3112
- * "zoom": {
3113
- * range: [50, 30]
3114
- * }
3115
- * }).on("release", function(event) {
3116
- * // event.depaPos
3117
- * // event.destPos
3118
- * // event.delta
3119
- * // event.input
3120
- * // event.inputEvent
3121
- * // event.setTo
3122
- * // event.isTrusted
3123
- *
3124
- * // if you want to change the animation coordinates to move after the 'release' event.
3125
- * event.setTo({x: 10}, 2000);
3126
- * });
3127
- * ```
3131
+ /**
3132
+ * This event is fired when a user release an element on the screen of the device.
3133
+ * @ko 사용자가 기기의 화면에서 손을 뗐을 때 발생하는 이벤트
3134
+ * @event Axes#release
3135
+ * @type {object}
3136
+ * @property {Object.<string, number>} depaPos The coordinates when releasing an element<ko>손을 뗐을 때의 좌표 </ko>
3137
+ * @property {Object.<string, number>} destPos The coordinates to move to after releasing an element<ko>손을 뗀 뒤에 이동할 좌표</ko>
3138
+ * @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
3139
+ * @property {Object.<string, number>} bounceRatio If the coordinates at the time of release are in the bounce area, the current bounce value divided by the maximum bounce value <ko>손을 뗐을 때의 좌표가 bounce 영역에 있는 경우 현재 bounce된 값을 최대 bounce 값으로 나눈 수치.</ko>
3140
+ * @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
3141
+ * @property {Object} input The instance of inputType where the event occurred<ko>이벤트가 발생한 inputType 인스턴스</ko>
3142
+ * @property {setTo} setTo Specifies the animation coordinates to move after the event <ko>이벤트 이후 이동할 애니메이션 좌표를 지정한다</ko>
3143
+ * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3144
+ *
3145
+ * @example
3146
+ * ```js
3147
+ * const axes = new eg.Axes({
3148
+ * "x": {
3149
+ * range: [0, 100]
3150
+ * },
3151
+ * "zoom": {
3152
+ * range: [50, 30]
3153
+ * }
3154
+ * }).on("release", function(event) {
3155
+ * // event.depaPos
3156
+ * // event.destPos
3157
+ * // event.delta
3158
+ * // event.input
3159
+ * // event.inputEvent
3160
+ * // event.setTo
3161
+ * // event.isTrusted
3162
+ *
3163
+ * // if you want to change the animation coordinates to move after the 'release' event.
3164
+ * event.setTo({x: 10}, 2000);
3165
+ * });
3166
+ * ```
3128
3167
  */
3129
3168
  __proto.triggerRelease = function (param) {
3130
3169
  var _a = this._getRoundPos(param.destPos, param.depaPos),
@@ -3137,43 +3176,43 @@ version: 4.12.0-beta.0
3137
3176
  bounceRatio: this._getBounceRatio(roundPos)
3138
3177
  })));
3139
3178
  };
3140
- /**
3141
- * This event is fired when coordinate changes.
3142
- * @ko 좌표가 변경됐을 때 발생하는 이벤트
3143
- * @event Axes#change
3144
- * @type {object}
3145
- * @property {Object.<string, number>} pos The coordinate <ko>좌표</ko>
3146
- * @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
3147
- * @property {Object.<string, number>} bounceRatio If the current coordinates are in the bounce area, the current bounce value divided by the maximum bounce value <ko>현재 좌표가 bounce 영역에 있는 경우 현재 bounce된 값을 최대 bounce 값으로 나눈 수치.</ko>
3148
- * @property {Boolean} holding Indicates whether a user holds an element on the screen of the device.<ko>사용자가 기기의 화면을 누르고 있는지 여부</ko>
3149
- * @property {Object} input The instance of inputType where the event occurred. If the value is changed by animation, it returns 'null'.<ko>이벤트가 발생한 inputType 인스턴스. 애니메이션에 의해 값이 변경될 경우에는 'null'을 반환한다.</ko>
3150
- * @property {Object} inputEvent The event object received from inputType. If the value is changed by animation, it returns 'null'.<ko>inputType으로 부터 받은 이벤트 객체. 애니메이션에 의해 값이 변경될 경우에는 'null'을 반환한다.</ko>
3151
- * @property {set} set Specifies the coordinates to move after the event. It works when the holding value is true <ko>이벤트 이후 이동할 좌표를 지정한다. holding 값이 true일 경우에 동작한다.</ko>
3152
- * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3153
- *
3154
- * @example
3155
- * ```js
3156
- * const axes = new eg.Axes({
3157
- * "x": {
3158
- * range: [0, 100]
3159
- * },
3160
- * "zoom": {
3161
- * range: [50, 30]
3162
- * }
3163
- * }).on("change", function(event) {
3164
- * // event.pos
3165
- * // event.delta
3166
- * // event.input
3167
- * // event.inputEvent
3168
- * // event.holding
3169
- * // event.set
3170
- * // event.isTrusted
3171
- *
3172
- * // if you want to change the coordinates to move after the 'change' event.
3173
- * // it works when the holding value of the change event is true.
3174
- * event.holding && event.set({x: 10});
3175
- * });
3176
- * ```
3179
+ /**
3180
+ * This event is fired when coordinate changes.
3181
+ * @ko 좌표가 변경됐을 때 발생하는 이벤트
3182
+ * @event Axes#change
3183
+ * @type {object}
3184
+ * @property {Object.<string, number>} pos The coordinate <ko>좌표</ko>
3185
+ * @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
3186
+ * @property {Object.<string, number>} bounceRatio If the current coordinates are in the bounce area, the current bounce value divided by the maximum bounce value <ko>현재 좌표가 bounce 영역에 있는 경우 현재 bounce된 값을 최대 bounce 값으로 나눈 수치.</ko>
3187
+ * @property {Boolean} holding Indicates whether a user holds an element on the screen of the device.<ko>사용자가 기기의 화면을 누르고 있는지 여부</ko>
3188
+ * @property {Object} input The instance of inputType where the event occurred. If the value is changed by animation, it returns 'null'.<ko>이벤트가 발생한 inputType 인스턴스. 애니메이션에 의해 값이 변경될 경우에는 'null'을 반환한다.</ko>
3189
+ * @property {Object} inputEvent The event object received from inputType. If the value is changed by animation, it returns 'null'.<ko>inputType으로 부터 받은 이벤트 객체. 애니메이션에 의해 값이 변경될 경우에는 'null'을 반환한다.</ko>
3190
+ * @property {set} set Specifies the coordinates to move after the event. It works when the holding value is true <ko>이벤트 이후 이동할 좌표를 지정한다. holding 값이 true일 경우에 동작한다.</ko>
3191
+ * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3192
+ *
3193
+ * @example
3194
+ * ```js
3195
+ * const axes = new eg.Axes({
3196
+ * "x": {
3197
+ * range: [0, 100]
3198
+ * },
3199
+ * "zoom": {
3200
+ * range: [50, 30]
3201
+ * }
3202
+ * }).on("change", function(event) {
3203
+ * // event.pos
3204
+ * // event.delta
3205
+ * // event.input
3206
+ * // event.inputEvent
3207
+ * // event.holding
3208
+ * // event.set
3209
+ * // event.isTrusted
3210
+ *
3211
+ * // if you want to change the coordinates to move after the 'change' event.
3212
+ * // it works when the holding value of the change event is true.
3213
+ * event.holding && event.set({x: 10});
3214
+ * });
3215
+ * ```
3177
3216
  */
3178
3217
  __proto.triggerChange = function (pos, depaPos, option, holding) {
3179
3218
  var _this = this;
@@ -3210,42 +3249,42 @@ version: 4.12.0-beta.0
3210
3249
  }
3211
3250
  return !event.isCanceled();
3212
3251
  };
3213
- /**
3214
- * This event is fired when animation starts.
3215
- * @ko 에니메이션이 시작할 때 발생한다.
3216
- * @event Axes#animationStart
3217
- * @type {object}
3218
- * @property {Object.<string, number>} depaPos The coordinates when animation starts<ko>애니메이션이 시작 되었을 때의 좌표 </ko>
3219
- * @property {Object.<string, number>} destPos The coordinates to move to. If you change this value, you can run the animation<ko>이동할 좌표. 이값을 변경하여 애니메이션을 동작시킬수 있다</ko>
3220
- * @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
3221
- * @property {Number} duration Duration of the animation (unit: ms). If you change this value, you can control the animation duration time.<ko>애니메이션 진행 시간(단위: ms). 이값을 변경하여 애니메이션의 이동시간을 조절할 수 있다.</ko>
3222
- * @property {Object} input The instance of inputType where the event occurred. If the value is changed by animation, it returns 'null'.<ko>이벤트가 발생한 inputType 인스턴스. 애니메이션에 의해 값이 변경될 경우에는 'null'을 반환한다.</ko>
3223
- * @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
3224
- * @property {setTo} setTo Specifies the animation coordinates to move after the event <ko>이벤트 이후 이동할 애니메이션 좌표를 지정한다</ko>
3225
- * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3226
- *
3227
- * @example
3228
- * ```js
3229
- * const axes = new eg.Axes({
3230
- * "x": {
3231
- * range: [0, 100]
3232
- * },
3233
- * "zoom": {
3234
- * range: [50, 30]
3235
- * }
3236
- * }).on("release", function(event) {
3237
- * // event.depaPos
3238
- * // event.destPos
3239
- * // event.delta
3240
- * // event.input
3241
- * // event.inputEvent
3242
- * // event.setTo
3243
- * // event.isTrusted
3244
- *
3245
- * // if you want to change the animation coordinates to move after the 'animationStart' event.
3246
- * event.setTo({x: 10}, 2000);
3247
- * });
3248
- * ```
3252
+ /**
3253
+ * This event is fired when animation starts.
3254
+ * @ko 에니메이션이 시작할 때 발생한다.
3255
+ * @event Axes#animationStart
3256
+ * @type {object}
3257
+ * @property {Object.<string, number>} depaPos The coordinates when animation starts<ko>애니메이션이 시작 되었을 때의 좌표 </ko>
3258
+ * @property {Object.<string, number>} destPos The coordinates to move to. If you change this value, you can run the animation<ko>이동할 좌표. 이값을 변경하여 애니메이션을 동작시킬수 있다</ko>
3259
+ * @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
3260
+ * @property {Number} duration Duration of the animation (unit: ms). If you change this value, you can control the animation duration time.<ko>애니메이션 진행 시간(단위: ms). 이값을 변경하여 애니메이션의 이동시간을 조절할 수 있다.</ko>
3261
+ * @property {Object} input The instance of inputType where the event occurred. If the value is changed by animation, it returns 'null'.<ko>이벤트가 발생한 inputType 인스턴스. 애니메이션에 의해 값이 변경될 경우에는 'null'을 반환한다.</ko>
3262
+ * @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
3263
+ * @property {setTo} setTo Specifies the animation coordinates to move after the event <ko>이벤트 이후 이동할 애니메이션 좌표를 지정한다</ko>
3264
+ * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3265
+ *
3266
+ * @example
3267
+ * ```js
3268
+ * const axes = new eg.Axes({
3269
+ * "x": {
3270
+ * range: [0, 100]
3271
+ * },
3272
+ * "zoom": {
3273
+ * range: [50, 30]
3274
+ * }
3275
+ * }).on("release", function(event) {
3276
+ * // event.depaPos
3277
+ * // event.destPos
3278
+ * // event.delta
3279
+ * // event.input
3280
+ * // event.inputEvent
3281
+ * // event.setTo
3282
+ * // event.isTrusted
3283
+ *
3284
+ * // if you want to change the animation coordinates to move after the 'animationStart' event.
3285
+ * event.setTo({x: 10}, 2000);
3286
+ * });
3287
+ * ```
3249
3288
  */
3250
3289
  __proto.triggerAnimationStart = function (param) {
3251
3290
  var _a = this._getRoundPos(param.destPos, param.depaPos),
@@ -3258,26 +3297,26 @@ version: 4.12.0-beta.0
3258
3297
  this._axes.trigger(event);
3259
3298
  return !event.isCanceled();
3260
3299
  };
3261
- /**
3262
- * This event is fired when animation ends.
3263
- * @ko 에니메이션이 끝났을 때 발생한다.
3264
- * @event Axes#animationEnd
3265
- * @type {object}
3266
- * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3267
- *
3268
- * @example
3269
- * ```js
3270
- * const axes = new eg.Axes({
3271
- * "x": {
3272
- * range: [0, 100]
3273
- * },
3274
- * "zoom": {
3275
- * range: [50, 30]
3276
- * }
3277
- * }).on("animationEnd", function(event) {
3278
- * // event.isTrusted
3279
- * });
3280
- * ```
3300
+ /**
3301
+ * This event is fired when animation ends.
3302
+ * @ko 에니메이션이 끝났을 때 발생한다.
3303
+ * @event Axes#animationEnd
3304
+ * @type {object}
3305
+ * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3306
+ *
3307
+ * @example
3308
+ * ```js
3309
+ * const axes = new eg.Axes({
3310
+ * "x": {
3311
+ * range: [0, 100]
3312
+ * },
3313
+ * "zoom": {
3314
+ * range: [50, 30]
3315
+ * }
3316
+ * }).on("animationEnd", function(event) {
3317
+ * // event.isTrusted
3318
+ * });
3319
+ * ```
3281
3320
  */
3282
3321
  __proto.triggerAnimationEnd = function (isTrusted) {
3283
3322
  if (isTrusted === void 0) {
@@ -3287,26 +3326,26 @@ version: 4.12.0-beta.0
3287
3326
  isTrusted: isTrusted
3288
3327
  }));
3289
3328
  };
3290
- /**
3291
- * This event is fired when all actions have been completed.
3292
- * @ko 에니메이션이 끝났을 때 발생한다.
3293
- * @event Axes#finish
3294
- * @type {object}
3295
- * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3296
- *
3297
- * @example
3298
- * ```js
3299
- * const axes = new eg.Axes({
3300
- * "x": {
3301
- * range: [0, 100]
3302
- * },
3303
- * "zoom": {
3304
- * range: [50, 30]
3305
- * }
3306
- * }).on("finish", function(event) {
3307
- * // event.isTrusted
3308
- * });
3309
- * ```
3329
+ /**
3330
+ * This event is fired when all actions have been completed.
3331
+ * @ko 에니메이션이 끝났을 때 발생한다.
3332
+ * @event Axes#finish
3333
+ * @type {object}
3334
+ * @property {Boolean} isTrusted Returns true if an event was generated by the user action, or false if it was caused by a script or API call <ko>사용자의 액션에 의해 이벤트가 발생하였으면 true, 스크립트나 API호출에 의해 발생하였을 경우에는 false를 반환한다.</ko>
3335
+ *
3336
+ * @example
3337
+ * ```js
3338
+ * const axes = new eg.Axes({
3339
+ * "x": {
3340
+ * range: [0, 100]
3341
+ * },
3342
+ * "zoom": {
3343
+ * range: [50, 30]
3344
+ * }
3345
+ * }).on("finish", function(event) {
3346
+ * // event.isTrusted
3347
+ * });
3348
+ * ```
3310
3349
  */
3311
3350
  __proto.triggerFinish = function (isTrusted) {
3312
3351
  if (isTrusted === void 0) {
@@ -3388,9 +3427,9 @@ version: 4.12.0-beta.0
3388
3427
  return InterruptManager;
3389
3428
  }();
3390
3429
 
3391
- /*
3392
- * Copyright (c) 2015 NAVER Corp.
3393
- * egjs projects are licensed under the MIT license
3430
+ /*
3431
+ * Copyright (c) 2015 NAVER Corp.
3432
+ * egjs projects are licensed under the MIT license
3394
3433
  */
3395
3434
  var getInsidePosition = function (destPos, range, circular, bounce) {
3396
3435
  var toDestPos = destPos;
@@ -3519,9 +3558,9 @@ version: 4.12.0-beta.0
3519
3558
  });
3520
3559
  this._complementOptions();
3521
3560
  };
3522
- /**
3523
- * set up 'css' expression
3524
- * @private
3561
+ /**
3562
+ * set up 'css' expression
3563
+ * @private
3525
3564
  */
3526
3565
  __proto._complementOptions = function () {
3527
3566
  var _this = this;
@@ -4408,7 +4447,7 @@ version: 4.12.0-beta.0
4408
4447
  } else if (isCanceled) {
4409
4448
  _this.finish(false);
4410
4449
  } else {
4411
- _this._raf = requestAnimationFrame(loop_1);
4450
+ _this._raf = requestAnimationFrame$1(loop_1);
4412
4451
  }
4413
4452
  };
4414
4453
  loop_1();
@@ -4417,15 +4456,15 @@ version: 4.12.0-beta.0
4417
4456
  complete();
4418
4457
  }
4419
4458
  };
4420
- /**
4421
- * Get estimated final value.
4422
- *
4423
- * If destPos is within the 'error range' of the original intended position, the initial intended position is returned.
4424
- * - eg. original intended pos: 100, destPos: 100.0000000004 ==> return 100;
4425
- * If dest Pos is outside the 'range of error' compared to the originally intended pos, it is returned rounded based on the originally intended pos.
4426
- * - eg. original intended pos: 100.123 destPos: 50.12345 => return 50.123
4427
- * @param originalIntendedPos
4428
- * @param destPos
4459
+ /**
4460
+ * Get estimated final value.
4461
+ *
4462
+ * If destPos is within the 'error range' of the original intended position, the initial intended position is returned.
4463
+ * - eg. original intended pos: 100, destPos: 100.0000000004 ==> return 100;
4464
+ * If dest Pos is outside the 'range of error' compared to the originally intended pos, it is returned rounded based on the originally intended pos.
4465
+ * - eg. original intended pos: 100.123 destPos: 50.12345 => return 50.123
4466
+ * @param originalIntendedPos
4467
+ * @param destPos
4429
4468
  */
4430
4469
  __proto._getFinalPos = function (destPos, originalIntendedPos) {
4431
4470
  var _this = this;
@@ -4551,111 +4590,111 @@ version: 4.12.0-beta.0
4551
4590
  return EasingManager;
4552
4591
  }(AnimationManager);
4553
4592
 
4554
- /**
4555
- * @typedef {Object} AxisOption The Axis information. The key of the axis specifies the name to use as the logical virtual coordinate system.
4556
- * @ko 축 정보. 축의 키는 논리적인 가상 좌표계로 사용할 이름을 지정한다.
4557
- * @param {Number[]} [range] The range of coordinate <ko>좌표 범위</ko>
4558
- * @param {Number} [range[0]=0] The coordinate of the minimum <ko>최소 좌표</ko>
4559
- * @param {Number} [range[1]=0] The coordinate of the maximum <ko>최대 좌표</ko>
4560
- * @param {Number} [startPos=range[0]] The coordinates to be moved when creating an instance <ko>인스턴스 생성시 이동할 좌표</ko>
4561
- * @param {Number[]} [bounce] The size of bouncing area. The coordinates can exceed the coordinate area as much as the bouncing area based on user action. If the coordinates does not exceed the bouncing area when an element is dragged, the coordinates where bouncing effects are applied are retuned back into the coordinate area<ko>바운스 영역의 크기. 사용자의 동작에 따라 좌표가 좌표 영역을 넘어 바운스 영역의 크기만큼 더 이동할 수 있다. 사용자가 끌어다 놓는 동작을 했을 때 좌표가 바운스 영역에 있으면, 바운스 효과가 적용된 좌표가 다시 좌표 영역 안으로 들어온다</ko>
4562
- * @param {Number} [bounce[0]=0] The size of coordinate of the minimum area <ko>최소 좌표 바운스 영역의 크기</ko>
4563
- * @param {Number} [bounce[1]=0] The size of coordinate of the maximum area <ko>최대 좌표 바운스 영역의 크기</ko>
4564
- * @param {Boolean[]} [circular] Indicates whether a circular element is available. If it is set to "true" and an element is dragged outside the coordinate area, the element will appear on the other side.<ko>순환 여부. 'true'로 설정한 방향의 좌표 영역 밖으로 엘리먼트가 이동하면 반대 방향에서 엘리먼트가 나타난다</ko>
4565
- * @param {Boolean} [circular[0]=false] Indicates whether to circulate to the coordinate of the minimum <ko>최소 좌표 방향의 순환 여부</ko>
4566
- * @param {Boolean} [circular[1]=false] Indicates whether to circulate to the coordinate of the maximum <ko>최대 좌표 방향의 순환 여부</ko>
4593
+ /**
4594
+ * @typedef {Object} AxisOption The Axis information. The key of the axis specifies the name to use as the logical virtual coordinate system.
4595
+ * @ko 축 정보. 축의 키는 논리적인 가상 좌표계로 사용할 이름을 지정한다.
4596
+ * @param {Number[]} [range] The range of coordinate <ko>좌표 범위</ko>
4597
+ * @param {Number} [range[0]=0] The coordinate of the minimum <ko>최소 좌표</ko>
4598
+ * @param {Number} [range[1]=0] The coordinate of the maximum <ko>최대 좌표</ko>
4599
+ * @param {Number} [startPos=range[0]] The coordinates to be moved when creating an instance <ko>인스턴스 생성시 이동할 좌표</ko>
4600
+ * @param {Number[]} [bounce] The size of bouncing area. The coordinates can exceed the coordinate area as much as the bouncing area based on user action. If the coordinates does not exceed the bouncing area when an element is dragged, the coordinates where bouncing effects are applied are retuned back into the coordinate area<ko>바운스 영역의 크기. 사용자의 동작에 따라 좌표가 좌표 영역을 넘어 바운스 영역의 크기만큼 더 이동할 수 있다. 사용자가 끌어다 놓는 동작을 했을 때 좌표가 바운스 영역에 있으면, 바운스 효과가 적용된 좌표가 다시 좌표 영역 안으로 들어온다</ko>
4601
+ * @param {Number} [bounce[0]=0] The size of coordinate of the minimum area <ko>최소 좌표 바운스 영역의 크기</ko>
4602
+ * @param {Number} [bounce[1]=0] The size of coordinate of the maximum area <ko>최대 좌표 바운스 영역의 크기</ko>
4603
+ * @param {Boolean[]} [circular] Indicates whether a circular element is available. If it is set to "true" and an element is dragged outside the coordinate area, the element will appear on the other side.<ko>순환 여부. 'true'로 설정한 방향의 좌표 영역 밖으로 엘리먼트가 이동하면 반대 방향에서 엘리먼트가 나타난다</ko>
4604
+ * @param {Boolean} [circular[0]=false] Indicates whether to circulate to the coordinate of the minimum <ko>최소 좌표 방향의 순환 여부</ko>
4605
+ * @param {Boolean} [circular[1]=false] Indicates whether to circulate to the coordinate of the maximum <ko>최대 좌표 방향의 순환 여부</ko>
4567
4606
  **/
4568
- /**
4569
- * @typedef {Object} AxesOption The option object of the eg.Axes module
4570
- * @ko eg.Axes 모듈의 옵션 객체
4571
- * @param {Function} [easing=easing.easeOutCubic] The easing function to apply to an animation <ko>애니메이션에 적용할 easing 함수</ko>
4572
- * @param {Number} [maximumDuration=Infinity] Maximum duration of the animation <ko>가속도에 의해 애니메이션이 동작할 때의 최대 좌표 이동 시간</ko>
4573
- * @param {Number} [minimumDuration=0] Minimum duration of the animation <ko>가속도에 의해 애니메이션이 동작할 때의 최소 좌표 이동 시간</ko>
4574
- * @param {Number} [deceleration=0.0006] Deceleration of the animation where acceleration is manually enabled by user. A higher value indicates shorter running time. <ko>사용자의 동작으로 가속도가 적용된 애니메이션의 감속도. 값이 높을수록 애니메이션 실행 시간이 짧아진다</ko>
4575
- * @param {Boolean} [interruptable=true] Indicates whether an animation is interruptible.
4576
- * - true: It can be paused or stopped by user action or the API.
4577
- * - false: It cannot be paused or stopped by user action or the API while it is running.
4578
- * <ko>진행 중인 애니메이션 중지 가능 여부.
4579
- * - true: 사용자의 동작이나 API로 애니메이션을 중지할 수 있다.
4580
- * - false: 애니메이션이 진행 중일 때는 사용자의 동작이나 API가 적용되지 않는다</ko>
4581
- * @param {Number} [round=null] Rounding unit. For example, 0.1 rounds to 0.1 decimal point(6.1234 => 6.1), 5 rounds to 5 (93 => 95)
4582
- * [Details](https://github.com/naver/egjs-axes/wiki/round-option)<ko>반올림 단위. 예를 들어 0.1 은 소숫점 0.1 까지 반올림(6.1234 => 6.1), 5 는 5 단위로 반올림(93 => 95).
4583
- * [상세내용](https://github.com/naver/egjs-axes/wiki/round-option)</ko>
4584
- * @param {Boolean} [nested=false] Whether the event propagates to other instances when the coordinates reach the end of the movable area <ko>좌표가 이동 가능한 영역의 끝까지 도달했을 때 다른 인스턴스들로의 이벤트 전파 여부</ko>
4607
+ /**
4608
+ * @typedef {Object} AxesOption The option object of the eg.Axes module
4609
+ * @ko eg.Axes 모듈의 옵션 객체
4610
+ * @param {Function} [easing=easing.easeOutCubic] The easing function to apply to an animation <ko>애니메이션에 적용할 easing 함수</ko>
4611
+ * @param {Number} [maximumDuration=Infinity] Maximum duration of the animation <ko>가속도에 의해 애니메이션이 동작할 때의 최대 좌표 이동 시간</ko>
4612
+ * @param {Number} [minimumDuration=0] Minimum duration of the animation <ko>가속도에 의해 애니메이션이 동작할 때의 최소 좌표 이동 시간</ko>
4613
+ * @param {Number} [deceleration=0.0006] Deceleration of the animation where acceleration is manually enabled by user. A higher value indicates shorter running time. <ko>사용자의 동작으로 가속도가 적용된 애니메이션의 감속도. 값이 높을수록 애니메이션 실행 시간이 짧아진다</ko>
4614
+ * @param {Boolean} [interruptable=true] Indicates whether an animation is interruptible.
4615
+ * - true: It can be paused or stopped by user action or the API.
4616
+ * - false: It cannot be paused or stopped by user action or the API while it is running.
4617
+ * <ko>진행 중인 애니메이션 중지 가능 여부.
4618
+ * - true: 사용자의 동작이나 API로 애니메이션을 중지할 수 있다.
4619
+ * - false: 애니메이션이 진행 중일 때는 사용자의 동작이나 API가 적용되지 않는다</ko>
4620
+ * @param {Number} [round=null] Rounding unit. For example, 0.1 rounds to 0.1 decimal point(6.1234 => 6.1), 5 rounds to 5 (93 => 95)
4621
+ * [Details](https://github.com/naver/egjs-axes/wiki/round-option)<ko>반올림 단위. 예를 들어 0.1 은 소숫점 0.1 까지 반올림(6.1234 => 6.1), 5 는 5 단위로 반올림(93 => 95).
4622
+ * [상세내용](https://github.com/naver/egjs-axes/wiki/round-option)</ko>
4623
+ * @param {Boolean} [nested=false] Whether the event propagates to other instances when the coordinates reach the end of the movable area <ko>좌표가 이동 가능한 영역의 끝까지 도달했을 때 다른 인스턴스들로의 이벤트 전파 여부</ko>
4585
4624
  **/
4586
- /**
4587
- * A module used to change the information of user action entered by various input devices such as touch screen or mouse into the logical virtual coordinates. You can easily create a UI that responds to user actions.
4588
- * @ko 터치 입력 장치나 마우스와 같은 다양한 입력 장치를 통해 전달 받은 사용자의 동작을 논리적인 가상 좌표로 변경하는 모듈이다. 사용자 동작에 반응하는 UI를 손쉽게 만들수 있다.
4589
- * @extends eg.Component
4590
- *
4591
- * @param {Object.<string, AxisOption>} axis Axis information managed by eg.Axes. The key of the axis specifies the name to use as the logical virtual coordinate system. <ko>eg.Axes가 관리하는 축 정보. 축의 키는 논리적인 가상 좌표계로 사용할 이름을 지정한다.</ko>
4592
- * @param {AxesOption} [options={}] The option object of the eg.Axes module<ko>eg.Axes 모듈의 옵션 객체</ko>
4593
- * @param {Object.<string, number>} [startPos={}] The coordinates to be moved when creating an instance. It is applied with higher priority than startPos of axisOption.<ko>인스턴스 생성시 이동할 좌표, axisOption의 startPos보다 높은 우선순위로 적용된다.</ko>
4594
- *
4595
- * @support {"ie": "10+", "ch" : "latest", "ff" : "latest", "sf" : "latest", "edge" : "latest", "ios" : "7+", "an" : "2.3+ (except 3.x)"}
4596
- * @example
4597
- * ```js
4598
- * // 1. Initialize eg.Axes
4599
- * const axes = new eg.Axes({
4600
- * something1: {
4601
- * range: [0, 150],
4602
- * bounce: 50
4603
- * },
4604
- * something2: {
4605
- * range: [0, 200],
4606
- * bounce: 100
4607
- * },
4608
- * somethingN: {
4609
- * range: [1, 10],
4610
- * }
4611
- * }, {
4612
- * deceleration : 0.0024
4613
- * });
4614
- *
4615
- * // 2. attach event handler
4616
- * axes.on({
4617
- * "hold" : function(evt) {
4618
- * },
4619
- * "release" : function(evt) {
4620
- * },
4621
- * "animationStart" : function(evt) {
4622
- * },
4623
- * "animationEnd" : function(evt) {
4624
- * },
4625
- * "change" : function(evt) {
4626
- * }
4627
- * });
4628
- *
4629
- * // 3. Initialize inputTypes
4630
- * const panInputArea = new eg.Axes.PanInput("#area", {
4631
- * scale: [0.5, 1]
4632
- * });
4633
- * const panInputHmove = new eg.Axes.PanInput("#hmove");
4634
- * const panInputVmove = new eg.Axes.PanInput("#vmove");
4635
- * const pinchInputArea = new eg.Axes.PinchInput("#area", {
4636
- * scale: 1.5
4637
- * });
4638
- *
4639
- * // 4. Connect eg.Axes and InputTypes
4640
- * // [PanInput] When the mouse or touchscreen is down and moved.
4641
- * // Connect the 'something2' axis to the mouse or touchscreen x position and
4642
- * // connect the 'somethingN' axis to the mouse or touchscreen y position.
4643
- * axes.connect(["something2", "somethingN"], panInputArea); // or axes.connect("something2 somethingN", panInputArea);
4644
- *
4645
- * // Connect only one 'something1' axis to the mouse or touchscreen x position.
4646
- * axes.connect(["something1"], panInputHmove); // or axes.connect("something1", panInputHmove);
4647
- *
4648
- * // Connect only one 'something2' axis to the mouse or touchscreen y position.
4649
- * axes.connect(["", "something2"], panInputVmove); // or axes.connect(" something2", panInputVmove);
4650
- *
4651
- * // [PinchInput] Connect 'something2' axis when two pointers are moving toward (zoom-in) or away from each other (zoom-out).
4652
- * axes.connect("something2", pinchInputArea);
4653
- * ```
4625
+ /**
4626
+ * A module used to change the information of user action entered by various input devices such as touch screen or mouse into the logical virtual coordinates. You can easily create a UI that responds to user actions.
4627
+ * @ko 터치 입력 장치나 마우스와 같은 다양한 입력 장치를 통해 전달 받은 사용자의 동작을 논리적인 가상 좌표로 변경하는 모듈이다. 사용자 동작에 반응하는 UI를 손쉽게 만들수 있다.
4628
+ * @extends eg.Component
4629
+ *
4630
+ * @param {Object.<string, AxisOption>} axis Axis information managed by eg.Axes. The key of the axis specifies the name to use as the logical virtual coordinate system. <ko>eg.Axes가 관리하는 축 정보. 축의 키는 논리적인 가상 좌표계로 사용할 이름을 지정한다.</ko>
4631
+ * @param {AxesOption} [options={}] The option object of the eg.Axes module<ko>eg.Axes 모듈의 옵션 객체</ko>
4632
+ * @param {Object.<string, number>} [startPos={}] The coordinates to be moved when creating an instance. It is applied with higher priority than startPos of axisOption.<ko>인스턴스 생성시 이동할 좌표, axisOption의 startPos보다 높은 우선순위로 적용된다.</ko>
4633
+ *
4634
+ * @support {"ie": "10+", "ch" : "latest", "ff" : "latest", "sf" : "latest", "edge" : "latest", "ios" : "7+", "an" : "2.3+ (except 3.x)"}
4635
+ * @example
4636
+ * ```js
4637
+ * // 1. Initialize eg.Axes
4638
+ * const axes = new eg.Axes({
4639
+ * something1: {
4640
+ * range: [0, 150],
4641
+ * bounce: 50
4642
+ * },
4643
+ * something2: {
4644
+ * range: [0, 200],
4645
+ * bounce: 100
4646
+ * },
4647
+ * somethingN: {
4648
+ * range: [1, 10],
4649
+ * }
4650
+ * }, {
4651
+ * deceleration : 0.0024
4652
+ * });
4653
+ *
4654
+ * // 2. attach event handler
4655
+ * axes.on({
4656
+ * "hold" : function(evt) {
4657
+ * },
4658
+ * "release" : function(evt) {
4659
+ * },
4660
+ * "animationStart" : function(evt) {
4661
+ * },
4662
+ * "animationEnd" : function(evt) {
4663
+ * },
4664
+ * "change" : function(evt) {
4665
+ * }
4666
+ * });
4667
+ *
4668
+ * // 3. Initialize inputTypes
4669
+ * const panInputArea = new eg.Axes.PanInput("#area", {
4670
+ * scale: [0.5, 1]
4671
+ * });
4672
+ * const panInputHmove = new eg.Axes.PanInput("#hmove");
4673
+ * const panInputVmove = new eg.Axes.PanInput("#vmove");
4674
+ * const pinchInputArea = new eg.Axes.PinchInput("#area", {
4675
+ * scale: 1.5
4676
+ * });
4677
+ *
4678
+ * // 4. Connect eg.Axes and InputTypes
4679
+ * // [PanInput] When the mouse or touchscreen is down and moved.
4680
+ * // Connect the 'something2' axis to the mouse or touchscreen x position and
4681
+ * // connect the 'somethingN' axis to the mouse or touchscreen y position.
4682
+ * axes.connect(["something2", "somethingN"], panInputArea); // or axes.connect("something2 somethingN", panInputArea);
4683
+ *
4684
+ * // Connect only one 'something1' axis to the mouse or touchscreen x position.
4685
+ * axes.connect(["something1"], panInputHmove); // or axes.connect("something1", panInputHmove);
4686
+ *
4687
+ * // Connect only one 'something2' axis to the mouse or touchscreen y position.
4688
+ * axes.connect(["", "something2"], panInputVmove); // or axes.connect(" something2", panInputVmove);
4689
+ *
4690
+ * // [PinchInput] Connect 'something2' axis when two pointers are moving toward (zoom-in) or away from each other (zoom-out).
4691
+ * axes.connect("something2", pinchInputArea);
4692
+ * ```
4654
4693
  */
4655
4694
  var Axes = /*#__PURE__*/function (_super) {
4656
4695
  __extends$1(Axes, _super);
4657
- /**
4658
- *
4696
+ /**
4697
+ *
4659
4698
  */
4660
4699
  function Axes(axis, options, startPos) {
4661
4700
  if (axis === void 0) {
@@ -4695,23 +4734,23 @@ version: 4.12.0-beta.0
4695
4734
  }
4696
4735
  var __proto = Axes.prototype;
4697
4736
  Object.defineProperty(__proto, "holding", {
4698
- /**
4699
- * @name Axes#holding
4700
- * @desc Returns true if at least one input is in progress.
4701
- * @ko 입력이 하나 이상 진행 중인지 여부를 반환한다.
4702
- *
4703
- * @readonly
4704
- * @type {boolean}
4705
- * @example
4706
- * ```js
4707
- * const axes = new eg.Axes({
4708
- * x: {
4709
- * range: [0, 100],
4710
- * },
4711
- * });
4712
- *
4713
- * axes.holding
4714
- * ```
4737
+ /**
4738
+ * @name Axes#holding
4739
+ * @desc Returns true if at least one input is in progress.
4740
+ * @ko 입력이 하나 이상 진행 중인지 여부를 반환한다.
4741
+ *
4742
+ * @readonly
4743
+ * @type {boolean}
4744
+ * @example
4745
+ * ```js
4746
+ * const axes = new eg.Axes({
4747
+ * x: {
4748
+ * range: [0, 100],
4749
+ * },
4750
+ * });
4751
+ *
4752
+ * axes.holding
4753
+ * ```
4715
4754
  */
4716
4755
  get: function () {
4717
4756
  return this.eventManager.holdingCount > 0;
@@ -4719,30 +4758,30 @@ version: 4.12.0-beta.0
4719
4758
  enumerable: false,
4720
4759
  configurable: true
4721
4760
  });
4722
- /**
4723
- * Connect the axis of eg.Axes to the inputType.
4724
- * @ko eg.Axes의 축과 inputType을 연결한다
4725
- * @param {(String[]|String)} axes The name of the axis to associate with inputType <ko>inputType과 연결할 축의 이름</ko>
4726
- * @param {Object} inputType The inputType instance to associate with the axis of eg.Axes <ko>eg.Axes의 축과 연결할 inputType 인스턴스</ko>
4727
- * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4728
- * @example
4729
- * ```js
4730
- * const axes = new eg.Axes({
4731
- * "x": {
4732
- * range: [0, 100]
4733
- * },
4734
- * "xOther": {
4735
- * range: [-100, 100]
4736
- * }
4737
- * });
4738
- *
4739
- * axes.connect("x", new eg.Axes.PanInput("#area1"))
4740
- * .connect("x xOther", new eg.Axes.PanInput("#area2"))
4741
- * .connect(" xOther", new eg.Axes.PanInput("#area3"))
4742
- * .connect(["x"], new eg.Axes.PanInput("#area4"))
4743
- * .connect(["xOther", "x"], new eg.Axes.PanInput("#area5"))
4744
- * .connect(["", "xOther"], new eg.Axes.PanInput("#area6"));
4745
- * ```
4761
+ /**
4762
+ * Connect the axis of eg.Axes to the inputType.
4763
+ * @ko eg.Axes의 축과 inputType을 연결한다
4764
+ * @param {(String[]|String)} axes The name of the axis to associate with inputType <ko>inputType과 연결할 축의 이름</ko>
4765
+ * @param {Object} inputType The inputType instance to associate with the axis of eg.Axes <ko>eg.Axes의 축과 연결할 inputType 인스턴스</ko>
4766
+ * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4767
+ * @example
4768
+ * ```js
4769
+ * const axes = new eg.Axes({
4770
+ * "x": {
4771
+ * range: [0, 100]
4772
+ * },
4773
+ * "xOther": {
4774
+ * range: [-100, 100]
4775
+ * }
4776
+ * });
4777
+ *
4778
+ * axes.connect("x", new eg.Axes.PanInput("#area1"))
4779
+ * .connect("x xOther", new eg.Axes.PanInput("#area2"))
4780
+ * .connect(" xOther", new eg.Axes.PanInput("#area3"))
4781
+ * .connect(["x"], new eg.Axes.PanInput("#area4"))
4782
+ * .connect(["xOther", "x"], new eg.Axes.PanInput("#area5"))
4783
+ * .connect(["", "xOther"], new eg.Axes.PanInput("#area6"));
4784
+ * ```
4746
4785
  */
4747
4786
  __proto.connect = function (axes, inputType) {
4748
4787
  var mapped;
@@ -4760,33 +4799,33 @@ version: 4.12.0-beta.0
4760
4799
  this._inputs.push(inputType);
4761
4800
  return this;
4762
4801
  };
4763
- /**
4764
- * Disconnect the axis of eg.Axes from the inputType.
4765
- * @ko eg.Axes의 축과 inputType의 연결을 끊는다.
4766
- * @param {Object} [inputType] An inputType instance associated with the axis of eg.Axes <ko>eg.Axes의 축과 연결한 inputType 인스턴스</ko>
4767
- * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4768
- * @example
4769
- * ```js
4770
- * const axes = new eg.Axes({
4771
- * "x": {
4772
- * range: [0, 100]
4773
- * },
4774
- * "xOther": {
4775
- * range: [-100, 100]
4776
- * }
4777
- * });
4778
- *
4779
- * const input1 = new eg.Axes.PanInput("#area1");
4780
- * const input2 = new eg.Axes.PanInput("#area2");
4781
- * const input3 = new eg.Axes.PanInput("#area3");
4782
- *
4783
- * axes.connect("x", input1);
4784
- * .connect("x xOther", input2)
4785
- * .connect(["xOther", "x"], input3);
4786
- *
4787
- * axes.disconnect(input1); // disconnects input1
4788
- * axes.disconnect(); // disconnects all of them
4789
- * ```
4802
+ /**
4803
+ * Disconnect the axis of eg.Axes from the inputType.
4804
+ * @ko eg.Axes의 축과 inputType의 연결을 끊는다.
4805
+ * @param {Object} [inputType] An inputType instance associated with the axis of eg.Axes <ko>eg.Axes의 축과 연결한 inputType 인스턴스</ko>
4806
+ * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4807
+ * @example
4808
+ * ```js
4809
+ * const axes = new eg.Axes({
4810
+ * "x": {
4811
+ * range: [0, 100]
4812
+ * },
4813
+ * "xOther": {
4814
+ * range: [-100, 100]
4815
+ * }
4816
+ * });
4817
+ *
4818
+ * const input1 = new eg.Axes.PanInput("#area1");
4819
+ * const input2 = new eg.Axes.PanInput("#area2");
4820
+ * const input3 = new eg.Axes.PanInput("#area3");
4821
+ *
4822
+ * axes.connect("x", input1);
4823
+ * .connect("x xOther", input2)
4824
+ * .connect(["xOther", "x"], input3);
4825
+ *
4826
+ * axes.disconnect(input1); // disconnects input1
4827
+ * axes.disconnect(); // disconnects all of them
4828
+ * ```
4790
4829
  */
4791
4830
  __proto.disconnect = function (inputType) {
4792
4831
  if (inputType) {
@@ -4803,60 +4842,60 @@ version: 4.12.0-beta.0
4803
4842
  }
4804
4843
  return this;
4805
4844
  };
4806
- /**
4807
- * Returns the current position of the coordinates.
4808
- * @ko 좌표의 현재 위치를 반환한다
4809
- * @param {Object} [axes] The names of the axis <ko>축 이름들</ko>
4810
- * @return {Object.<string, number>} Axis coordinate information <ko>축 좌표 정보</ko>
4811
- * @example
4812
- * ```js
4813
- * const axes = new eg.Axes({
4814
- * "x": {
4815
- * range: [0, 100]
4816
- * },
4817
- * "xOther": {
4818
- * range: [-100, 100]
4819
- * },
4820
- * "zoom": {
4821
- * range: [50, 30]
4822
- * }
4823
- * });
4824
- *
4825
- * axes.get(); // {"x": 0, "xOther": -100, "zoom": 50}
4826
- * axes.get(["x", "zoom"]); // {"x": 0, "zoom": 50}
4827
- * ```
4845
+ /**
4846
+ * Returns the current position of the coordinates.
4847
+ * @ko 좌표의 현재 위치를 반환한다
4848
+ * @param {Object} [axes] The names of the axis <ko>축 이름들</ko>
4849
+ * @return {Object.<string, number>} Axis coordinate information <ko>축 좌표 정보</ko>
4850
+ * @example
4851
+ * ```js
4852
+ * const axes = new eg.Axes({
4853
+ * "x": {
4854
+ * range: [0, 100]
4855
+ * },
4856
+ * "xOther": {
4857
+ * range: [-100, 100]
4858
+ * },
4859
+ * "zoom": {
4860
+ * range: [50, 30]
4861
+ * }
4862
+ * });
4863
+ *
4864
+ * axes.get(); // {"x": 0, "xOther": -100, "zoom": 50}
4865
+ * axes.get(["x", "zoom"]); // {"x": 0, "zoom": 50}
4866
+ * ```
4828
4867
  */
4829
4868
  __proto.get = function (axes) {
4830
4869
  return this.axisManager.get(axes);
4831
4870
  };
4832
- /**
4833
- * Moves an axis to specific coordinates.
4834
- * @ko 좌표를 이동한다.
4835
- * @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
4836
- * @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
4837
- * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4838
- * @example
4839
- * ```js
4840
- * const axes = new eg.Axes({
4841
- * "x": {
4842
- * range: [0, 100]
4843
- * },
4844
- * "xOther": {
4845
- * range: [-100, 100]
4846
- * },
4847
- * "zoom": {
4848
- * range: [50, 30]
4849
- * }
4850
- * });
4851
- *
4852
- * axes.setTo({"x": 30, "zoom": 60});
4853
- * axes.get(); // {"x": 30, "xOther": -100, "zoom": 60}
4854
- *
4855
- * axes.setTo({"x": 100, "xOther": 60}, 1000); // animatation
4856
- *
4857
- * // after 1000 ms
4858
- * axes.get(); // {"x": 100, "xOther": 60, "zoom": 60}
4859
- * ```
4871
+ /**
4872
+ * Moves an axis to specific coordinates.
4873
+ * @ko 좌표를 이동한다.
4874
+ * @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
4875
+ * @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
4876
+ * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4877
+ * @example
4878
+ * ```js
4879
+ * const axes = new eg.Axes({
4880
+ * "x": {
4881
+ * range: [0, 100]
4882
+ * },
4883
+ * "xOther": {
4884
+ * range: [-100, 100]
4885
+ * },
4886
+ * "zoom": {
4887
+ * range: [50, 30]
4888
+ * }
4889
+ * });
4890
+ *
4891
+ * axes.setTo({"x": 30, "zoom": 60});
4892
+ * axes.get(); // {"x": 30, "xOther": -100, "zoom": 60}
4893
+ *
4894
+ * axes.setTo({"x": 100, "xOther": 60}, 1000); // animatation
4895
+ *
4896
+ * // after 1000 ms
4897
+ * axes.get(); // {"x": 100, "xOther": 60, "zoom": 60}
4898
+ * ```
4860
4899
  */
4861
4900
  __proto.setTo = function (pos, duration) {
4862
4901
  if (duration === void 0) {
@@ -4865,34 +4904,34 @@ version: 4.12.0-beta.0
4865
4904
  this.animationManager.setTo(pos, duration);
4866
4905
  return this;
4867
4906
  };
4868
- /**
4869
- * Moves an axis from the current coordinates to specific coordinates.
4870
- * @ko 현재 좌표를 기준으로 좌표를 이동한다.
4871
- * @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
4872
- * @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
4873
- * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4874
- * @example
4875
- * ```js
4876
- * const axes = new eg.Axes({
4877
- * "x": {
4878
- * range: [0, 100]
4879
- * },
4880
- * "xOther": {
4881
- * range: [-100, 100]
4882
- * },
4883
- * "zoom": {
4884
- * range: [50, 30]
4885
- * }
4886
- * });
4887
- *
4888
- * axes.setBy({"x": 30, "zoom": 10});
4889
- * axes.get(); // {"x": 30, "xOther": -100, "zoom": 60}
4890
- *
4891
- * axes.setBy({"x": 70, "xOther": 60}, 1000); // animatation
4892
- *
4893
- * // after 1000 ms
4894
- * axes.get(); // {"x": 100, "xOther": -40, "zoom": 60}
4895
- * ```
4907
+ /**
4908
+ * Moves an axis from the current coordinates to specific coordinates.
4909
+ * @ko 현재 좌표를 기준으로 좌표를 이동한다.
4910
+ * @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
4911
+ * @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
4912
+ * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4913
+ * @example
4914
+ * ```js
4915
+ * const axes = new eg.Axes({
4916
+ * "x": {
4917
+ * range: [0, 100]
4918
+ * },
4919
+ * "xOther": {
4920
+ * range: [-100, 100]
4921
+ * },
4922
+ * "zoom": {
4923
+ * range: [50, 30]
4924
+ * }
4925
+ * });
4926
+ *
4927
+ * axes.setBy({"x": 30, "zoom": 10});
4928
+ * axes.get(); // {"x": 30, "xOther": -100, "zoom": 60}
4929
+ *
4930
+ * axes.setBy({"x": 70, "xOther": 60}, 1000); // animatation
4931
+ *
4932
+ * // after 1000 ms
4933
+ * axes.get(); // {"x": 100, "xOther": -40, "zoom": 60}
4934
+ * ```
4896
4935
  */
4897
4936
  __proto.setBy = function (pos, duration) {
4898
4937
  if (duration === void 0) {
@@ -4901,230 +4940,230 @@ version: 4.12.0-beta.0
4901
4940
  this.animationManager.setBy(pos, duration);
4902
4941
  return this;
4903
4942
  };
4904
- /**
4905
- * Change the options of Axes instance.
4906
- * @ko 인스턴스의 옵션을 변경한다.
4907
- * @param {AxesOption} options Axes options to change <ko>변경할 옵션 목록</ko>
4908
- * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4909
- * @example
4910
- * ```js
4911
- * const axes = new eg.Axes({
4912
- * "x": {
4913
- * range: [0, 100]
4914
- * },
4915
- * }, {
4916
- * round: 10,
4917
- * });
4918
- *
4919
- * axes.setTo({"x": 48});
4920
- * axes.get(); // {"x": 50}
4921
- *
4922
- * axes.setOptions({
4923
- * round: 1,
4924
- * });
4925
- *
4926
- * axes.setTo({"x": 48});
4927
- * axes.get(); // {"x": 48}
4928
- * ```
4943
+ /**
4944
+ * Change the options of Axes instance.
4945
+ * @ko 인스턴스의 옵션을 변경한다.
4946
+ * @param {AxesOption} options Axes options to change <ko>변경할 옵션 목록</ko>
4947
+ * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4948
+ * @example
4949
+ * ```js
4950
+ * const axes = new eg.Axes({
4951
+ * "x": {
4952
+ * range: [0, 100]
4953
+ * },
4954
+ * }, {
4955
+ * round: 10,
4956
+ * });
4957
+ *
4958
+ * axes.setTo({"x": 48});
4959
+ * axes.get(); // {"x": 50}
4960
+ *
4961
+ * axes.setOptions({
4962
+ * round: 1,
4963
+ * });
4964
+ *
4965
+ * axes.setTo({"x": 48});
4966
+ * axes.get(); // {"x": 48}
4967
+ * ```
4929
4968
  */
4930
4969
  __proto.setOptions = function (options) {
4931
4970
  this.options = __assign$1(__assign$1({}, this.options), options);
4932
4971
  this.animationManager.setOptions(options);
4933
4972
  return this;
4934
4973
  };
4935
- /**
4936
- * Change the information of an existing axis.
4937
- * @ko 존재하는 축의 정보를 변경한다.
4938
- * @param {Object.<string, AxisOption>} axis Axis options to change <ko>변경할 축의 정보</ko>
4939
- * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4940
- * @example
4941
- * ```js
4942
- * const axes = new eg.Axes({
4943
- * "x": {
4944
- * range: [0, 100]
4945
- * },
4946
- * });
4947
- *
4948
- * axes.setTo({"x": 150});
4949
- * axes.get(); // {"x": 100}
4950
- *
4951
- * axes.setAxis({
4952
- * "x": {
4953
- * range: [0, 200]
4954
- * },
4955
- * });
4956
- *
4957
- * axes.setTo({"x": 150});
4958
- * axes.get(); // {"x": 150}
4959
- * ```
4974
+ /**
4975
+ * Change the information of an existing axis.
4976
+ * @ko 존재하는 축의 정보를 변경한다.
4977
+ * @param {Object.<string, AxisOption>} axis Axis options to change <ko>변경할 축의 정보</ko>
4978
+ * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4979
+ * @example
4980
+ * ```js
4981
+ * const axes = new eg.Axes({
4982
+ * "x": {
4983
+ * range: [0, 100]
4984
+ * },
4985
+ * });
4986
+ *
4987
+ * axes.setTo({"x": 150});
4988
+ * axes.get(); // {"x": 100}
4989
+ *
4990
+ * axes.setAxis({
4991
+ * "x": {
4992
+ * range: [0, 200]
4993
+ * },
4994
+ * });
4995
+ *
4996
+ * axes.setTo({"x": 150});
4997
+ * axes.get(); // {"x": 150}
4998
+ * ```
4960
4999
  */
4961
5000
  __proto.setAxis = function (axis) {
4962
5001
  this.axisManager.setAxis(axis);
4963
5002
  return this;
4964
5003
  };
4965
- /**
4966
- * Stop an animation in progress.
4967
- * @ko 재생 중인 애니메이션을 정지한다.
4968
- * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4969
- * @example
4970
- * ```js
4971
- * const axes = new eg.Axes({
4972
- * "x": {
4973
- * range: [0, 100]
4974
- * },
4975
- * });
4976
- *
4977
- * axes.setTo({"x": 10}, 1000); // start animatation
4978
- *
4979
- * // after 500 ms
4980
- * axes.stopAnimation(); // stop animation during movement.
4981
- * ```
5004
+ /**
5005
+ * Stop an animation in progress.
5006
+ * @ko 재생 중인 애니메이션을 정지한다.
5007
+ * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
5008
+ * @example
5009
+ * ```js
5010
+ * const axes = new eg.Axes({
5011
+ * "x": {
5012
+ * range: [0, 100]
5013
+ * },
5014
+ * });
5015
+ *
5016
+ * axes.setTo({"x": 10}, 1000); // start animatation
5017
+ *
5018
+ * // after 500 ms
5019
+ * axes.stopAnimation(); // stop animation during movement.
5020
+ * ```
4982
5021
  */
4983
5022
  __proto.stopAnimation = function () {
4984
5023
  this.animationManager.stopAnimation();
4985
5024
  this.animationManager.finish(false);
4986
5025
  return this;
4987
5026
  };
4988
- /**
4989
- * Change the destination of an animation in progress.
4990
- * @ko 재생 중인 애니메이션의 목적지와 진행 시간을 변경한다.
4991
- * @param {UpdateAnimationOption} pos The coordinate to move to <ko>이동할 좌표</ko>
4992
- * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
4993
- * @example
4994
- * ```js
4995
- * const axes = new eg.Axes({
4996
- * "x": {
4997
- * range: [0, 200]
4998
- * },
4999
- * "y": {
5000
- * range: [0, 200]
5001
- * }
5002
- * });
5003
- *
5004
- * axes.setTo({"x": 50, "y": 50}, 1000); // trigger animation by setTo
5005
- *
5006
- * // after 500 ms
5007
- * axes.updateAnimation({destPos: {"x": 100, "y": 100}}); // animation will end after 500 ms, at {"x": 100, "y": 100}
5008
- *
5009
- * // after 500 ms
5010
- * axes.setTo({"x": 50, "y": 50}, 1000); // trigger animation by setTo
5011
- *
5012
- * // after 700 ms
5013
- * axes.updateAnimation({destPos: {"x": 100, "y": 100}, duration: 1500, restart: true}); // this works same as axes.setTo({"x": 100, "y": 100}, 800) since restart is true.
5014
- * ```
5027
+ /**
5028
+ * Change the destination of an animation in progress.
5029
+ * @ko 재생 중인 애니메이션의 목적지와 진행 시간을 변경한다.
5030
+ * @param {UpdateAnimationOption} pos The coordinate to move to <ko>이동할 좌표</ko>
5031
+ * @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
5032
+ * @example
5033
+ * ```js
5034
+ * const axes = new eg.Axes({
5035
+ * "x": {
5036
+ * range: [0, 200]
5037
+ * },
5038
+ * "y": {
5039
+ * range: [0, 200]
5040
+ * }
5041
+ * });
5042
+ *
5043
+ * axes.setTo({"x": 50, "y": 50}, 1000); // trigger animation by setTo
5044
+ *
5045
+ * // after 500 ms
5046
+ * axes.updateAnimation({destPos: {"x": 100, "y": 100}}); // animation will end after 500 ms, at {"x": 100, "y": 100}
5047
+ *
5048
+ * // after 500 ms
5049
+ * axes.setTo({"x": 50, "y": 50}, 1000); // trigger animation by setTo
5050
+ *
5051
+ * // after 700 ms
5052
+ * axes.updateAnimation({destPos: {"x": 100, "y": 100}, duration: 1500, restart: true}); // this works same as axes.setTo({"x": 100, "y": 100}, 800) since restart is true.
5053
+ * ```
5015
5054
  */
5016
5055
  __proto.updateAnimation = function (options) {
5017
5056
  this.animationManager.updateAnimation(options);
5018
5057
  return this;
5019
5058
  };
5020
- /**
5021
- * Returns whether there is a coordinate in the bounce area of ​​the target axis.
5022
- * @ko 대상 축 중 bounce영역에 좌표가 존재하는지를 반환한다
5023
- * @param {Object} [axes] The names of the axis <ko>축 이름들</ko>
5024
- * @return {Boolen} Whether the bounce area exists. <ko>bounce 영역 존재 여부</ko>
5025
- * @example
5026
- * ```js
5027
- * const axes = new eg.Axes({
5028
- * "x": {
5029
- * range: [0, 100]
5030
- * },
5031
- * "xOther": {
5032
- * range: [-100, 100]
5033
- * },
5034
- * "zoom": {
5035
- * range: [50, 30]
5036
- * }
5037
- * });
5038
- *
5039
- * axes.isBounceArea(["x"]);
5040
- * axes.isBounceArea(["x", "zoom"]);
5041
- * axes.isBounceArea();
5042
- * ```
5059
+ /**
5060
+ * Returns whether there is a coordinate in the bounce area of ​​the target axis.
5061
+ * @ko 대상 축 중 bounce영역에 좌표가 존재하는지를 반환한다
5062
+ * @param {Object} [axes] The names of the axis <ko>축 이름들</ko>
5063
+ * @return {Boolen} Whether the bounce area exists. <ko>bounce 영역 존재 여부</ko>
5064
+ * @example
5065
+ * ```js
5066
+ * const axes = new eg.Axes({
5067
+ * "x": {
5068
+ * range: [0, 100]
5069
+ * },
5070
+ * "xOther": {
5071
+ * range: [-100, 100]
5072
+ * },
5073
+ * "zoom": {
5074
+ * range: [50, 30]
5075
+ * }
5076
+ * });
5077
+ *
5078
+ * axes.isBounceArea(["x"]);
5079
+ * axes.isBounceArea(["x", "zoom"]);
5080
+ * axes.isBounceArea();
5081
+ * ```
5043
5082
  */
5044
5083
  __proto.isBounceArea = function (axes) {
5045
5084
  return this.axisManager.isOutside(axes);
5046
5085
  };
5047
- /**
5048
- * Destroys properties, and events used in a module and disconnect all connections to inputTypes.
5049
- * @ko 모듈에 사용한 속성, 이벤트를 해제한다. 모든 inputType과의 연결을 끊는다.
5086
+ /**
5087
+ * Destroys properties, and events used in a module and disconnect all connections to inputTypes.
5088
+ * @ko 모듈에 사용한 속성, 이벤트를 해제한다. 모든 inputType과의 연결을 끊는다.
5050
5089
  */
5051
5090
  __proto.destroy = function () {
5052
5091
  this.disconnect();
5053
5092
  this.eventManager.destroy();
5054
5093
  };
5055
- /**
5056
- * @name VERSION
5057
- * @desc Version info string
5058
- * @ko 버전정보 문자열
5059
- *
5060
- * @constant
5061
- * @type {String}
5062
- * @example
5063
- * ```js
5064
- * eg.Axes.VERSION; // ex) 3.3.3
5065
- * ```
5094
+ /**
5095
+ * @name VERSION
5096
+ * @desc Version info string
5097
+ * @ko 버전정보 문자열
5098
+ *
5099
+ * @constant
5100
+ * @type {String}
5101
+ * @example
5102
+ * ```js
5103
+ * eg.Axes.VERSION; // ex) 3.3.3
5104
+ * ```
5066
5105
  */
5067
- Axes.VERSION = "3.9.0";
5106
+ Axes.VERSION = "3.9.1-beta.0";
5068
5107
  /* eslint-enable */
5069
- /**
5070
- * @name TRANSFORM
5071
- * @desc Returns the transform attribute with CSS vendor prefixes.
5072
- * @ko CSS vendor prefixes를 붙인 transform 속성을 반환한다.
5073
- *
5074
- * @constant
5075
- * @type {String}
5076
- * @example
5077
- * ```js
5078
- * eg.Axes.TRANSFORM; // "transform" or "webkitTransform"
5079
- * ```
5108
+ /**
5109
+ * @name TRANSFORM
5110
+ * @desc Returns the transform attribute with CSS vendor prefixes.
5111
+ * @ko CSS vendor prefixes를 붙인 transform 속성을 반환한다.
5112
+ *
5113
+ * @constant
5114
+ * @type {String}
5115
+ * @example
5116
+ * ```js
5117
+ * eg.Axes.TRANSFORM; // "transform" or "webkitTransform"
5118
+ * ```
5080
5119
  */
5081
5120
  Axes.TRANSFORM = TRANSFORM;
5082
- /**
5083
- * @name DIRECTION_NONE
5084
- * @constant
5085
- * @type {Number}
5121
+ /**
5122
+ * @name DIRECTION_NONE
5123
+ * @constant
5124
+ * @type {Number}
5086
5125
  */
5087
5126
  Axes.DIRECTION_NONE = DIRECTION_NONE;
5088
- /**
5089
- * @name DIRECTION_LEFT
5090
- * @constant
5091
- * @type {Number}
5127
+ /**
5128
+ * @name DIRECTION_LEFT
5129
+ * @constant
5130
+ * @type {Number}
5092
5131
  */
5093
5132
  Axes.DIRECTION_LEFT = DIRECTION_LEFT;
5094
- /**
5095
- * @name DIRECTION_RIGHT
5096
- * @constant
5097
- * @type {Number}
5133
+ /**
5134
+ * @name DIRECTION_RIGHT
5135
+ * @constant
5136
+ * @type {Number}
5098
5137
  */
5099
5138
  Axes.DIRECTION_RIGHT = DIRECTION_RIGHT;
5100
- /**
5101
- * @name DIRECTION_UP
5102
- * @constant
5103
- * @type {Number}
5139
+ /**
5140
+ * @name DIRECTION_UP
5141
+ * @constant
5142
+ * @type {Number}
5104
5143
  */
5105
5144
  Axes.DIRECTION_UP = DIRECTION_UP;
5106
- /**
5107
- * @name DIRECTION_DOWN
5108
- * @constant
5109
- * @type {Number}
5145
+ /**
5146
+ * @name DIRECTION_DOWN
5147
+ * @constant
5148
+ * @type {Number}
5110
5149
  */
5111
5150
  Axes.DIRECTION_DOWN = DIRECTION_DOWN;
5112
- /**
5113
- * @name DIRECTION_HORIZONTAL
5114
- * @constant
5115
- * @type {Number}
5151
+ /**
5152
+ * @name DIRECTION_HORIZONTAL
5153
+ * @constant
5154
+ * @type {Number}
5116
5155
  */
5117
5156
  Axes.DIRECTION_HORIZONTAL = DIRECTION_HORIZONTAL;
5118
- /**
5119
- * @name DIRECTION_VERTICAL
5120
- * @constant
5121
- * @type {Number}
5157
+ /**
5158
+ * @name DIRECTION_VERTICAL
5159
+ * @constant
5160
+ * @type {Number}
5122
5161
  */
5123
5162
  Axes.DIRECTION_VERTICAL = DIRECTION_VERTICAL;
5124
- /**
5125
- * @name DIRECTION_ALL
5126
- * @constant
5127
- * @type {Number}
5163
+ /**
5164
+ * @name DIRECTION_ALL
5165
+ * @constant
5166
+ * @type {Number}
5128
5167
  */
5129
5168
  Axes.DIRECTION_ALL = DIRECTION_ALL;
5130
5169
  __decorate([Computed], Axes.prototype, "holding", null);
@@ -5132,9 +5171,9 @@ version: 4.12.0-beta.0
5132
5171
  return Axes;
5133
5172
  }(Component);
5134
5173
 
5135
- /*
5136
- * Copyright (c) 2015 NAVER Corp.
5137
- * egjs projects are licensed under the MIT license
5174
+ /*
5175
+ * Copyright (c) 2015 NAVER Corp.
5176
+ * egjs projects are licensed under the MIT license
5138
5177
  */
5139
5178
  // get user's direction
5140
5179
  var getDirectionByAngle = function (angle, thresholdAngle) {
@@ -5144,73 +5183,73 @@ version: 4.12.0-beta.0
5144
5183
  var toAngle = Math.abs(angle);
5145
5184
  return toAngle > thresholdAngle && toAngle < 180 - thresholdAngle ? DIRECTION_VERTICAL : DIRECTION_HORIZONTAL;
5146
5185
  };
5147
- /**
5148
- * @typedef {Object} PanInputOption The option object of the eg.Axes.PanInput module.
5149
- * @ko eg.Axes.PanInput 모듈의 옵션 객체
5150
- * @param {String[]} [inputType=["touch", "mouse", "pointer"]] Types of input devices
5151
- * - touch: Touch screen
5152
- * - mouse: Mouse
5153
- * - pointer: Mouse and touch <ko>입력 장치 종류
5154
- * - touch: 터치 입력 장치
5155
- * - mouse: 마우스
5156
- * - pointer: 마우스 및 터치</ko>
5157
- * @param {String[]} [inputKey=["any"]] List of key combinations to allow input
5158
- * - any: any key
5159
- * - shift: shift key
5160
- * - ctrl: ctrl key and pinch gesture on the trackpad
5161
- * - alt: alt key
5162
- * - meta: meta key
5163
- * - none: none of these keys are pressed <ko>입력을 허용할 키 조합 목록
5164
- * - any: 아무 키
5165
- * - shift: shift 키
5166
- * - ctrl: ctrl 키 및 트랙패드의 pinch 제스쳐
5167
- * - alt: alt 키
5168
- * - meta: meta 키
5169
- * - none: 아무 키도 눌리지 않은 상태 </ko>
5170
- * @param {String[]} [inputButton=["left"]] List of buttons to allow input
5171
- * - left: Left mouse button and normal touch
5172
- * - middle: Mouse wheel press
5173
- * - right: Right mouse button <ko>입력을 허용할 버튼 목록
5174
- * - left: 마우스 왼쪽 버튼
5175
- * - middle: 마우스 휠 눌림
5176
- * - right: 마우스 오른쪽 버튼 </ko>
5177
- * @param {Number[]} [scale] Coordinate scale that a user can move<ko>사용자의 동작으로 이동하는 좌표의 배율</ko>
5178
- * @param {Number} [scale[0]=1] horizontal axis scale <ko>수평축 배율</ko>
5179
- * @param {Number} [scale[1]=1] vertical axis scale <ko>수직축 배율</ko>
5180
- * @param {Number} [thresholdAngle=45] The threshold value that determines whether user action is horizontal or vertical (0~90) <ko>사용자의 동작이 가로 방향인지 세로 방향인지 판단하는 기준 각도(0~90)</ko>
5181
- * @param {Number} [threshold=0] Minimal pan distance required before recognizing <ko>사용자의 Pan 동작을 인식하기 위해산 최소한의 거리</ko>
5182
- * @param {Boolean} [preventClickOnDrag=false] Whether to cancel the {@link https://developer.mozilla.org/en/docs/Web/API/Element/click_event click} event when the user finishes dragging more than 1 pixel <ko>사용자가 1픽셀 이상 드래그를 마쳤을 때 {@link https://developer.mozilla.org/ko/docs/Web/API/Element/click_event click} 이벤트 취소 여부</ko>
5183
- * @param {Boolean} [preventDefaultOnDrag=false] Whether to use the {@link https://developer.mozilla.org/ko/docs/Web/API/Event/preventDefault preventDefault} when the user starts dragging <ko>사용자가 드래그를 시작할 때 {@link https://developer.mozilla.org/ko/docs/Web/API/Event/preventDefault preventDefault} 실행 여부</ko>
5184
- * @param {Number} [iOSEdgeSwipeThreshold=30] Area (px) that can go to the next page when swiping the right edge in iOS safari <ko>iOS Safari에서 오른쪽 엣지를 스와이프 하는 경우 다음 페이지로 넘어갈 수 있는 영역(px)</ko>
5185
- * @param {String} [touchAction=null] Value that overrides the element's "touch-action" css property. If set to null, it is automatically set to prevent scrolling in the direction of the connected axis. <ko>엘리먼트의 "touch-action" CSS 속성을 덮어쓰는 값. 만약 null로 설정된 경우, 연결된 축 방향으로의 스크롤을 방지하게끔 자동으로 설정된다.</ko>
5186
+ /**
5187
+ * @typedef {Object} PanInputOption The option object of the eg.Axes.PanInput module.
5188
+ * @ko eg.Axes.PanInput 모듈의 옵션 객체
5189
+ * @param {String[]} [inputType=["touch", "mouse", "pointer"]] Types of input devices
5190
+ * - touch: Touch screen
5191
+ * - mouse: Mouse
5192
+ * - pointer: Mouse and touch <ko>입력 장치 종류
5193
+ * - touch: 터치 입력 장치
5194
+ * - mouse: 마우스
5195
+ * - pointer: 마우스 및 터치</ko>
5196
+ * @param {String[]} [inputKey=["any"]] List of key combinations to allow input
5197
+ * - any: any key
5198
+ * - shift: shift key
5199
+ * - ctrl: ctrl key and pinch gesture on the trackpad
5200
+ * - alt: alt key
5201
+ * - meta: meta key
5202
+ * - none: none of these keys are pressed <ko>입력을 허용할 키 조합 목록
5203
+ * - any: 아무 키
5204
+ * - shift: shift 키
5205
+ * - ctrl: ctrl 키 및 트랙패드의 pinch 제스쳐
5206
+ * - alt: alt 키
5207
+ * - meta: meta 키
5208
+ * - none: 아무 키도 눌리지 않은 상태 </ko>
5209
+ * @param {String[]} [inputButton=["left"]] List of buttons to allow input
5210
+ * - left: Left mouse button and normal touch
5211
+ * - middle: Mouse wheel press
5212
+ * - right: Right mouse button <ko>입력을 허용할 버튼 목록
5213
+ * - left: 마우스 왼쪽 버튼
5214
+ * - middle: 마우스 휠 눌림
5215
+ * - right: 마우스 오른쪽 버튼 </ko>
5216
+ * @param {Number[]} [scale] Coordinate scale that a user can move<ko>사용자의 동작으로 이동하는 좌표의 배율</ko>
5217
+ * @param {Number} [scale[0]=1] horizontal axis scale <ko>수평축 배율</ko>
5218
+ * @param {Number} [scale[1]=1] vertical axis scale <ko>수직축 배율</ko>
5219
+ * @param {Number} [thresholdAngle=45] The threshold value that determines whether user action is horizontal or vertical (0~90) <ko>사용자의 동작이 가로 방향인지 세로 방향인지 판단하는 기준 각도(0~90)</ko>
5220
+ * @param {Number} [threshold=0] Minimal pan distance required before recognizing <ko>사용자의 Pan 동작을 인식하기 위해산 최소한의 거리</ko>
5221
+ * @param {Boolean} [preventClickOnDrag=false] Whether to cancel the {@link https://developer.mozilla.org/en/docs/Web/API/Element/click_event click} event when the user finishes dragging more than 1 pixel <ko>사용자가 1픽셀 이상 드래그를 마쳤을 때 {@link https://developer.mozilla.org/ko/docs/Web/API/Element/click_event click} 이벤트 취소 여부</ko>
5222
+ * @param {Boolean} [preventDefaultOnDrag=false] Whether to use the {@link https://developer.mozilla.org/ko/docs/Web/API/Event/preventDefault preventDefault} when the user starts dragging <ko>사용자가 드래그를 시작할 때 {@link https://developer.mozilla.org/ko/docs/Web/API/Event/preventDefault preventDefault} 실행 여부</ko>
5223
+ * @param {Number} [iOSEdgeSwipeThreshold=30] Area (px) that can go to the next page when swiping the right edge in iOS safari <ko>iOS Safari에서 오른쪽 엣지를 스와이프 하는 경우 다음 페이지로 넘어갈 수 있는 영역(px)</ko>
5224
+ * @param {String} [touchAction=null] Value that overrides the element's "touch-action" css property. If set to null, it is automatically set to prevent scrolling in the direction of the connected axis. <ko>엘리먼트의 "touch-action" CSS 속성을 덮어쓰는 값. 만약 null로 설정된 경우, 연결된 축 방향으로의 스크롤을 방지하게끔 자동으로 설정된다.</ko>
5186
5225
  **/
5187
- /**
5188
- * A module that passes the amount of change to eg.Axes when the mouse or touchscreen is down and moved. use less than two axes.
5189
- * @ko 마우스나 터치 스크린을 누르고 움직일때의 변화량을 eg.Axes에 전달하는 모듈. 두개 이하의 축을 사용한다.
5190
- *
5191
- * @example
5192
- * ```js
5193
- * const pan = new eg.Axes.PanInput("#area", {
5194
- * inputType: ["touch"],
5195
- * scale: [1, 1.3],
5196
- * });
5197
- *
5198
- * // Connect the 'something2' axis to the mouse or touchscreen x position when the mouse or touchscreen is down and moved.
5199
- * // Connect the 'somethingN' axis to the mouse or touchscreen y position when the mouse or touchscreen is down and moved.
5200
- * axes.connect(["something2", "somethingN"], pan); // or axes.connect("something2 somethingN", pan);
5201
- *
5202
- * // Connect only one 'something1' axis to the mouse or touchscreen x position when the mouse or touchscreen is down and moved.
5203
- * axes.connect(["something1"], pan); // or axes.connect("something1", pan);
5204
- *
5205
- * // Connect only one 'something2' axis to the mouse or touchscreen y position when the mouse or touchscreen is down and moved.
5206
- * axes.connect(["", "something2"], pan); // or axes.connect(" something2", pan);
5207
- * ```
5208
- * @param {String|HTMLElement|Ref<HTMLElement>|jQuery} element An element to use the eg.Axes.PanInput module <ko>eg.Axes.PanInput 모듈을 사용할 엘리먼트</ko>
5209
- * @param {PanInputOption} [options={}] The option object of the eg.Axes.PanInput module<ko>eg.Axes.PanInput 모듈의 옵션 객체</ko>
5226
+ /**
5227
+ * A module that passes the amount of change to eg.Axes when the mouse or touchscreen is down and moved. use less than two axes.
5228
+ * @ko 마우스나 터치 스크린을 누르고 움직일때의 변화량을 eg.Axes에 전달하는 모듈. 두개 이하의 축을 사용한다.
5229
+ *
5230
+ * @example
5231
+ * ```js
5232
+ * const pan = new eg.Axes.PanInput("#area", {
5233
+ * inputType: ["touch"],
5234
+ * scale: [1, 1.3],
5235
+ * });
5236
+ *
5237
+ * // Connect the 'something2' axis to the mouse or touchscreen x position when the mouse or touchscreen is down and moved.
5238
+ * // Connect the 'somethingN' axis to the mouse or touchscreen y position when the mouse or touchscreen is down and moved.
5239
+ * axes.connect(["something2", "somethingN"], pan); // or axes.connect("something2 somethingN", pan);
5240
+ *
5241
+ * // Connect only one 'something1' axis to the mouse or touchscreen x position when the mouse or touchscreen is down and moved.
5242
+ * axes.connect(["something1"], pan); // or axes.connect("something1", pan);
5243
+ *
5244
+ * // Connect only one 'something2' axis to the mouse or touchscreen y position when the mouse or touchscreen is down and moved.
5245
+ * axes.connect(["", "something2"], pan); // or axes.connect(" something2", pan);
5246
+ * ```
5247
+ * @param {String|HTMLElement|Ref<HTMLElement>|jQuery} element An element to use the eg.Axes.PanInput module <ko>eg.Axes.PanInput 모듈을 사용할 엘리먼트</ko>
5248
+ * @param {PanInputOption} [options={}] The option object of the eg.Axes.PanInput module<ko>eg.Axes.PanInput 모듈의 옵션 객체</ko>
5210
5249
  */
5211
5250
  var PanInput = /*#__PURE__*/function () {
5212
- /**
5213
- *
5251
+ /**
5252
+ *
5214
5253
  */
5215
5254
  function PanInput(el, options) {
5216
5255
  var _this = this;
@@ -5259,56 +5298,60 @@ version: 4.12.0-beta.0
5259
5298
  this._detachWindowEvent(this._activeEvent);
5260
5299
  }
5261
5300
  this._attachElementEvent(observer);
5262
- this._originalCssProps = setCssProps(this.element, this.options, this._direction);
5263
5301
  return this;
5264
5302
  };
5265
5303
  __proto.disconnect = function () {
5266
5304
  this._detachElementEvent();
5267
5305
  this._detachWindowEvent(this._activeEvent);
5268
- if (!isCssPropsFromAxes(this._originalCssProps)) {
5269
- revertCssProps(this.element, this._originalCssProps);
5270
- }
5271
5306
  this._direction = DIRECTION_NONE;
5272
5307
  return this;
5273
5308
  };
5274
- /**
5275
- * Destroys elements, properties, and events used in a module.
5276
- * @ko 모듈에 사용한 엘리먼트와 속성, 이벤트를 해제한다.
5309
+ /**
5310
+ * Destroys elements, properties, and events used in a module.
5311
+ * @ko 모듈에 사용한 엘리먼트와 속성, 이벤트를 해제한다.
5277
5312
  */
5278
5313
  __proto.destroy = function () {
5279
5314
  this.disconnect();
5280
5315
  this.element = null;
5281
5316
  };
5282
- /**
5283
- * Enables input devices
5284
- * @ko 입력 장치를 사용할 수 있게 한다
5285
- * @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
5317
+ /**
5318
+ * Enables input devices
5319
+ * @ko 입력 장치를 사용할 수 있게 한다
5320
+ * @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
5286
5321
  */
5287
5322
  __proto.enable = function () {
5288
- this._enabled = true;
5323
+ if (!this._enabled) {
5324
+ this._enabled = true;
5325
+ this._originalCssProps = setCssProps(this.element, this.options, this._direction);
5326
+ }
5289
5327
  return this;
5290
5328
  };
5291
- /**
5292
- * Disables input devices
5293
- * @ko 입력 장치를 사용할 수 없게 한다.
5294
- * @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
5329
+ /**
5330
+ * Disables input devices
5331
+ * @ko 입력 장치를 사용할 수 없게 한다.
5332
+ * @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
5295
5333
  */
5296
5334
  __proto.disable = function () {
5297
- this._enabled = false;
5335
+ if (this._enabled) {
5336
+ this._enabled = false;
5337
+ if (!isCssPropsFromAxes(this._originalCssProps)) {
5338
+ revertCssProps(this.element, this._originalCssProps);
5339
+ }
5340
+ }
5298
5341
  return this;
5299
5342
  };
5300
- /**
5301
- * Returns whether to use an input device
5302
- * @ko 입력 장치 사용 여부를 반환한다.
5303
- * @return {Boolean} Whether to use an input device <ko>입력장치 사용여부</ko>
5343
+ /**
5344
+ * Returns whether to use an input device
5345
+ * @ko 입력 장치 사용 여부를 반환한다.
5346
+ * @return {Boolean} Whether to use an input device <ko>입력장치 사용여부</ko>
5304
5347
  */
5305
5348
  __proto.isEnabled = function () {
5306
5349
  return this._enabled;
5307
5350
  };
5308
- /**
5309
- * Releases current user input.
5310
- * @ko 사용자의 입력을 강제로 중단시킨다.
5311
- * @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
5351
+ /**
5352
+ * Releases current user input.
5353
+ * @ko 사용자의 입력을 강제로 중단시킨다.
5354
+ * @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
5312
5355
  */
5313
5356
  __proto.release = function () {
5314
5357
  var activeEvent = this._activeEvent;
@@ -5451,7 +5494,7 @@ version: 4.12.0-beta.0
5451
5494
  throw new Error("Element to connect input does not exist.");
5452
5495
  }
5453
5496
  this._observer = observer;
5454
- this._enabled = true;
5497
+ this.enable();
5455
5498
  this._activeEvent = activeEvent;
5456
5499
  element.addEventListener("click", this._preventClickWhenDragged, true);
5457
5500
  activeEvent.start.forEach(function (event) {
@@ -5475,15 +5518,15 @@ version: 4.12.0-beta.0
5475
5518
  element.removeEventListener(event, _this._voidFunction);
5476
5519
  });
5477
5520
  }
5478
- this._enabled = false;
5521
+ this.disable();
5479
5522
  this._observer = null;
5480
5523
  };
5481
5524
  return PanInput;
5482
5525
  }();
5483
5526
 
5484
- /*
5485
- * Copyright (c) 2015 NAVER Corp.
5486
- * egjs projects are licensed under the MIT license
5527
+ /*
5528
+ * Copyright (c) 2015 NAVER Corp.
5529
+ * egjs projects are licensed under the MIT license
5487
5530
  */
5488
5531
 
5489
5532
  var Axes$1 = Axes;
@@ -7937,6 +7980,7 @@ version: 4.12.0-beta.0
7937
7980
  var _this = this;
7938
7981
  var _b = (_a === void 0 ? {} : _a).align,
7939
7982
  align = _b === void 0 ? ALIGN.CENTER : _b;
7983
+ this._lookedOffset = 0;
7940
7984
  this._checkTranslateSupport = function () {
7941
7985
  var e_1, _a;
7942
7986
  var transforms = ["webkitTransform", "msTransform", "MozTransform", "OTransform", "transform"];
@@ -8296,6 +8340,8 @@ version: 4.12.0-beta.0
8296
8340
  */
8297
8341
  __proto.lookAt = function (pos) {
8298
8342
  var _this = this;
8343
+ var prevOffset = this._offset;
8344
+ var isChangedOffset = this._lookedOffset !== prevOffset;
8299
8345
  var flicking = getFlickingAttached(this._flicking);
8300
8346
  var prevPos = this._position;
8301
8347
  this._position = pos;
@@ -8306,7 +8352,12 @@ version: 4.12.0-beta.0
8306
8352
  if (toggled) {
8307
8353
  void flicking.renderer.render().then(function () {
8308
8354
  _this.updateOffset();
8355
+ _this._lookedOffset = _this._offset;
8309
8356
  });
8357
+ } else if (isChangedOffset) {
8358
+ // sync offset for renderOnlyVisible on resize
8359
+ this.updateOffset();
8360
+ this._lookedOffset = this._offset;
8310
8361
  } else {
8311
8362
  this.applyTransform();
8312
8363
  }
@@ -8481,8 +8532,8 @@ version: 4.12.0-beta.0
8481
8532
  return this;
8482
8533
  };
8483
8534
  /**
8484
- * Update Viewport's height to active panel's height
8485
- * @ko 현재 선택된 패널의 높이와 동일하도록 뷰포트의 높이를 업데이트합니다
8535
+ * Update Viewport's height to visible panel's max height
8536
+ * @ko 현재 활성화된 패널과 보이는 패널의 최대 높이와 동일하도록 뷰포트의 높이를 업데이트합니다
8486
8537
  * @throws {FlickingError}
8487
8538
  * {@link ERROR_CODE NOT_ATTACHED_TO_FLICKING} When {@link Camera#init init} is not called before
8488
8539
  * <ko>{@link ERROR_CODE NOT_ATTACHED_TO_FLICKING} {@link Camera#init init}이 이전에 호출되지 않은 경우</ko>
@@ -8492,9 +8543,17 @@ version: 4.12.0-beta.0
8492
8543
  __proto.updateAdaptiveHeight = function () {
8493
8544
  var flicking = getFlickingAttached(this._flicking);
8494
8545
  var activePanel = flicking.control.activePanel;
8495
- if (!flicking.horizontal || !flicking.adaptive || !activePanel) return;
8546
+ var visiblePanels = flicking.visiblePanels;
8547
+ var selectedPanels = __spread$1(visiblePanels);
8548
+ if (activePanel) {
8549
+ selectedPanels.push(activePanel);
8550
+ }
8551
+ if (!flicking.horizontal || !flicking.adaptive || !selectedPanels.length) return;
8552
+ var maxHeight = Math.max.apply(Math, __spread$1(selectedPanels.map(function (panel) {
8553
+ return panel.height;
8554
+ })));
8496
8555
  flicking.viewport.setSize({
8497
- height: activePanel.height
8556
+ height: maxHeight
8498
8557
  });
8499
8558
  };
8500
8559
  /**
@@ -8565,6 +8624,7 @@ version: 4.12.0-beta.0
8565
8624
  };
8566
8625
  __proto._resetInternalValues = function () {
8567
8626
  this._position = 0;
8627
+ this._lookedOffset = 0;
8568
8628
  this._alignPos = 0;
8569
8629
  this._offset = 0;
8570
8630
  this._circularOffset = 0;
@@ -12983,10 +13043,342 @@ version: 4.12.0-beta.0
12983
13043
  * Flicking.VERSION; // ex) 4.0.0
12984
13044
  * ```
12985
13045
  */
12986
- Flicking.VERSION = "4.12.0-beta.0";
13046
+ Flicking.VERSION = "4.12.0-beta.10";
12987
13047
  return Flicking;
12988
13048
  }(Component);
12989
13049
 
13050
+ var SIDE_EVENTS = {
13051
+ HOLD_START: "sideHoldStart",
13052
+ HOLD_END: "sideHoldEnd",
13053
+ MOVE_START: "sideMoveStart",
13054
+ MOVE: "sideMove",
13055
+ MOVE_END: "sideMoveEnd",
13056
+ WILL_CHANGE: "sideWillChange",
13057
+ CHANGED: "sideChanged"
13058
+ };
13059
+ var CrossFlicking = /*#__PURE__*/function (_super) {
13060
+ __extends$3(CrossFlicking, _super);
13061
+ function CrossFlicking(root, options) {
13062
+ var _this = _super.call(this, root, options) || this;
13063
+ _this._syncToCategory = function (index, outerIndex) {
13064
+ if (_this._disableIndexSync) {
13065
+ return;
13066
+ }
13067
+ _this.stopAnimation();
13068
+ _this._sideFlicking.forEach(function (child, i) {
13069
+ var _a = _this._sideState[i],
13070
+ start = _a.start,
13071
+ end = _a.end;
13072
+ if (start <= index && end >= index && outerIndex !== i) {
13073
+ child.stopAnimation();
13074
+ void child.moveTo(index, 0);
13075
+ void _this.moveTo(i, 0);
13076
+ }
13077
+ });
13078
+ };
13079
+ _this._setDraggable = function (direction, draggable) {
13080
+ if (!_this._disableSlideOnHold) {
13081
+ return;
13082
+ }
13083
+ var dragThreshold = _this._originalDragThreshold;
13084
+ var threshold = draggable ? dragThreshold && dragThreshold >= 10 ? dragThreshold : 10 : Infinity;
13085
+ if (direction === MOVE_DIRECTION.HORIZONTAL === _this.horizontal) {
13086
+ _this.dragThreshold = threshold;
13087
+ } else if (direction === MOVE_DIRECTION.VERTICAL === _this.horizontal) {
13088
+ _this._sideFlicking.forEach(function (child) {
13089
+ child.dragThreshold = threshold;
13090
+ });
13091
+ }
13092
+ };
13093
+ _this._setPreviousSideIndex = function () {
13094
+ _this._sideFlicking.forEach(function (child, i) {
13095
+ var _a = _this._sideState[i],
13096
+ start = _a.start,
13097
+ end = _a.end;
13098
+ if (_this._preserveIndex) {
13099
+ if (_this._nextIndex !== i) {
13100
+ if (child.index < start) {
13101
+ child.stopAnimation();
13102
+ void child.moveTo(start, 0);
13103
+ } else if (child.index > end) {
13104
+ child.stopAnimation();
13105
+ void child.moveTo(end, 0);
13106
+ }
13107
+ }
13108
+ } else {
13109
+ if (_this._nextIndex !== i) {
13110
+ void child.moveTo(start, 0);
13111
+ }
13112
+ }
13113
+ });
13114
+ };
13115
+ _this._onHorizontalHoldStart = function () {
13116
+ _this._setDraggable(MOVE_DIRECTION.HORIZONTAL, true);
13117
+ _this._moveDirection = null;
13118
+ };
13119
+ _this._onHorizontalMove = function (e) {
13120
+ if (e.isTrusted && !_this._moveDirection) {
13121
+ _this._setDraggable(MOVE_DIRECTION.VERTICAL, false);
13122
+ _this._moveDirection = MOVE_DIRECTION.HORIZONTAL;
13123
+ }
13124
+ };
13125
+ _this._onHorizontalMoveEnd = function (e) {
13126
+ var visiblePanels = _this.visiblePanels;
13127
+ if (visiblePanels.length > 1) {
13128
+ _this._nextIndex = e.direction === "NEXT" ? visiblePanels[1].index : visiblePanels[0].index;
13129
+ } else {
13130
+ _this._nextIndex = visiblePanels[0].index;
13131
+ }
13132
+ _this._setDraggable(MOVE_DIRECTION.VERTICAL, true);
13133
+ _this._moveDirection = null;
13134
+ // _syncToCategory에서 완전히 가로 이동이 이루어지기 전에 세로 방향 index가 변하는 경우가 있어 requestAnimationFrame 처리
13135
+ requestAnimationFrame(function () {
13136
+ return _this._setPreviousSideIndex();
13137
+ });
13138
+ if (e.isTrusted) {
13139
+ _this._syncToCategory(_this._sideFlicking[_this._nextIndex].index, _this._nextIndex);
13140
+ }
13141
+ };
13142
+ _this._onSideHoldStart = function () {
13143
+ _this._setDraggable(MOVE_DIRECTION.VERTICAL, true);
13144
+ _this._moveDirection = null;
13145
+ };
13146
+ _this._onSideMove = function (e) {
13147
+ if (e.isTrusted && !_this._moveDirection) {
13148
+ _this._setDraggable(MOVE_DIRECTION.HORIZONTAL, false);
13149
+ _this._moveDirection = MOVE_DIRECTION.VERTICAL;
13150
+ }
13151
+ };
13152
+ _this._onSideMoveEnd = function () {
13153
+ _this._setDraggable(MOVE_DIRECTION.HORIZONTAL, true);
13154
+ _this._moveDirection = null;
13155
+ };
13156
+ _this._onSideChanged = function (e) {
13157
+ // If this.visiblePanels.length >= 2, it means that horizontal flicking is being dragged.
13158
+ // In this case, syncToCategory in _onHorizontalMoveEnd will fire after moving finishes, so we don't fire it here.
13159
+ if (_this.visiblePanels.length < 2 && _this._sideFlicking[_this.index] === e.currentTarget) {
13160
+ _this._syncToCategory(e.index, _this.index);
13161
+ }
13162
+ };
13163
+ var _a = options.sideOptions,
13164
+ sideOptions = _a === void 0 ? {} : _a,
13165
+ _b = options.preserveIndex,
13166
+ preserveIndex = _b === void 0 ? true : _b,
13167
+ _c = options.disableSlideOnHold,
13168
+ disableSlideOnHold = _c === void 0 ? true : _c,
13169
+ _d = options.disableIndexSync,
13170
+ disableIndexSync = _d === void 0 ? false : _d;
13171
+ // Internal states
13172
+ _this._moveDirection = null;
13173
+ _this._nextIndex = 0;
13174
+ _this._originalDragThreshold = _this.dragThreshold;
13175
+ // Bind options
13176
+ _this._sideOptions = sideOptions;
13177
+ _this._preserveIndex = preserveIndex;
13178
+ _this._disableSlideOnHold = disableSlideOnHold;
13179
+ _this._disableIndexSync = disableIndexSync;
13180
+ return _this;
13181
+ }
13182
+ var __proto = CrossFlicking.prototype;
13183
+ Object.defineProperty(__proto, "sideFlicking", {
13184
+ // Components
13185
+ get: function () {
13186
+ return this._sideFlicking;
13187
+ },
13188
+ enumerable: false,
13189
+ configurable: true
13190
+ });
13191
+ Object.defineProperty(__proto, "sideState", {
13192
+ get: function () {
13193
+ return this._sideState;
13194
+ },
13195
+ enumerable: false,
13196
+ configurable: true
13197
+ });
13198
+ Object.defineProperty(__proto, "sideOptions", {
13199
+ // Options Getter
13200
+ get: function () {
13201
+ return this._sideOptions;
13202
+ },
13203
+ // Options Setter
13204
+ set: function (val) {
13205
+ this._sideOptions = val;
13206
+ },
13207
+ enumerable: false,
13208
+ configurable: true
13209
+ });
13210
+ Object.defineProperty(__proto, "preserveIndex", {
13211
+ get: function () {
13212
+ return this._preserveIndex;
13213
+ },
13214
+ set: function (val) {
13215
+ this._preserveIndex = val;
13216
+ },
13217
+ enumerable: false,
13218
+ configurable: true
13219
+ });
13220
+ Object.defineProperty(__proto, "disableSlideOnHold", {
13221
+ get: function () {
13222
+ return this._disableSlideOnHold;
13223
+ },
13224
+ set: function (val) {
13225
+ this._disableSlideOnHold = val;
13226
+ },
13227
+ enumerable: false,
13228
+ configurable: true
13229
+ });
13230
+ Object.defineProperty(__proto, "disableIndexSync", {
13231
+ get: function () {
13232
+ return this._disableIndexSync;
13233
+ },
13234
+ set: function (val) {
13235
+ this._disableIndexSync = val;
13236
+ },
13237
+ enumerable: false,
13238
+ configurable: true
13239
+ });
13240
+ __proto.init = function () {
13241
+ var _this = this;
13242
+ return _super.prototype.init.call(this).then(function () {
13243
+ _this._sideState = _this._createSideState();
13244
+ _this._sideFlicking = _this._createSideFlicking();
13245
+ _this._addComponentEvents();
13246
+ });
13247
+ };
13248
+ __proto.destroy = function () {
13249
+ this._sideFlicking.forEach(function (flicking) {
13250
+ flicking.destroy();
13251
+ });
13252
+ _super.prototype.destroy.call(this);
13253
+ };
13254
+ __proto._addComponentEvents = function () {
13255
+ var _this = this;
13256
+ this.on(EVENTS.HOLD_START, this._onHorizontalHoldStart);
13257
+ this.on(EVENTS.MOVE, this._onHorizontalMove);
13258
+ this.on(EVENTS.MOVE_END, this._onHorizontalMoveEnd);
13259
+ this._sideFlicking.forEach(function (flicking, mainIndex) {
13260
+ flicking.on(EVENTS.HOLD_START, _this._onSideHoldStart);
13261
+ flicking.on(EVENTS.MOVE, _this._onSideMove);
13262
+ flicking.on(EVENTS.MOVE_END, _this._onSideMoveEnd);
13263
+ flicking.on(EVENTS.CHANGED, _this._onSideChanged);
13264
+ Object.keys(SIDE_EVENTS).forEach(function (name) {
13265
+ flicking.on(EVENTS[name], function (event) {
13266
+ _this.trigger(new ComponentEvent$1(SIDE_EVENTS[name], __assign$2({
13267
+ mainIndex: mainIndex
13268
+ }, event)));
13269
+ });
13270
+ });
13271
+ });
13272
+ };
13273
+ __proto._createSideState = function () {
13274
+ var viewportEl = this.element;
13275
+ var cameraEl = this.camera.element;
13276
+ var panels = toArray$2(cameraEl.children);
13277
+ var isCrossStructure = getDataAttributes(viewportEl, "data-cross-").structure;
13278
+ var sideState = [];
13279
+ if (!isCrossStructure) {
13280
+ var groupPanels = this._getGroupFromAttribute(panels);
13281
+ var groupKeys = Object.keys(groupPanels);
13282
+ if (groupKeys.length) {
13283
+ sideState = this._getSideStateFromGroup(groupPanels);
13284
+ this.remove(0, this.panelCount - groupKeys.length);
13285
+ } else {
13286
+ sideState = this._getSideStateFromPanels(panels);
13287
+ }
13288
+ this._createCrossStructure(sideState);
13289
+ } else {
13290
+ sideState = this._getSideStateFromCrossStructure(panels);
13291
+ }
13292
+ void this.resize();
13293
+ return sideState;
13294
+ };
13295
+ __proto._createCrossStructure = function (sideState) {
13296
+ var _this = this;
13297
+ var sideCamera = document.createElement("div");
13298
+ var sidePanels = "";
13299
+ sideCamera.classList.add(CLASS.CAMERA);
13300
+ sideState.forEach(function (state, i) {
13301
+ var panel = _this.camera.children[i];
13302
+ sidePanels += state.element.innerHTML;
13303
+ Array.from(panel.attributes).forEach(function (attribute) {
13304
+ return panel.removeAttribute(attribute.name);
13305
+ });
13306
+ });
13307
+ sideCamera.innerHTML = sidePanels;
13308
+ sideState.forEach(function (_, i) {
13309
+ var panel = _this.camera.children[i];
13310
+ [CLASS.VIEWPORT, CLASS.VERTICAL].forEach(function (className) {
13311
+ if (!panel.classList.contains(className)) {
13312
+ panel.classList.add(className);
13313
+ }
13314
+ });
13315
+ panel.innerHTML = sideCamera.outerHTML;
13316
+ });
13317
+ this.element.setAttribute("data-cross-structure", "true");
13318
+ };
13319
+ __proto._getGroupFromAttribute = function (panels) {
13320
+ var groupKeys = [];
13321
+ var groupPanels = {};
13322
+ panels.forEach(function (panel) {
13323
+ var groupKey = getDataAttributes(panel, "data-cross-").groupkey;
13324
+ if (groupKey && !includes(groupKeys, groupKey)) {
13325
+ groupKeys.push(groupKey);
13326
+ groupPanels[groupKey] = [panel];
13327
+ } else if (groupKey) {
13328
+ groupPanels[groupKey].push(panel);
13329
+ }
13330
+ });
13331
+ return groupPanels;
13332
+ };
13333
+ __proto._getSideStateFromGroup = function (groupPanels) {
13334
+ return Object.keys(groupPanels).reduce(function (state, key) {
13335
+ var start = state.length ? +state[state.length - 1].end + 1 : 0;
13336
+ var element = groupPanels[key].reduce(function (el, panel) {
13337
+ el.innerHTML += panel.outerHTML;
13338
+ return el;
13339
+ }, document.createElement("div"));
13340
+ return __spread$1(state, [{
13341
+ key: key,
13342
+ start: start,
13343
+ end: start + groupPanels[key].length - 1,
13344
+ element: element
13345
+ }]);
13346
+ }, []);
13347
+ };
13348
+ __proto._getSideStateFromPanels = function (panels) {
13349
+ return panels.reduce(function (state, panel, i) {
13350
+ var start = state.length ? +state[state.length - 1].end + 1 : 0;
13351
+ return __spread$1(state, [{
13352
+ key: i.toString(),
13353
+ start: start,
13354
+ end: start + panel.children.length - 1,
13355
+ element: panel
13356
+ }]);
13357
+ }, []);
13358
+ };
13359
+ __proto._getSideStateFromCrossStructure = function (panels) {
13360
+ var groupPanels = this._getGroupFromAttribute(panels);
13361
+ return this._getSideStateFromGroup(groupPanels);
13362
+ };
13363
+ __proto._createSideFlicking = function () {
13364
+ var _this = this;
13365
+ return this.sideState.map(function (state, i) {
13366
+ return new Flicking(_this.camera.children[i], __assign$2(__assign$2({}, _this.sideOptions), {
13367
+ horizontal: false,
13368
+ panelsPerView: 1,
13369
+ defaultIndex: state.start
13370
+ }));
13371
+ });
13372
+ };
13373
+ return CrossFlicking;
13374
+ }(Flicking);
13375
+
13376
+ var CrossFlicking$1 = {
13377
+ __proto__: null,
13378
+ SIDE_EVENTS: SIDE_EVENTS,
13379
+ CrossFlicking: CrossFlicking
13380
+ };
13381
+
12990
13382
  /*
12991
13383
  * Copyright (c) 2015 NAVER Corp.
12992
13384
  * egjs projects are licensed under the MIT license
@@ -13232,6 +13624,7 @@ version: 4.12.0-beta.0
13232
13624
  merge(Flicking, Constants);
13233
13625
  merge(Flicking, CFC);
13234
13626
  merge(Flicking, Utils);
13627
+ merge(Flicking, CrossFlicking$1);
13235
13628
 
13236
13629
  return Flicking;
13237
13630