@egjs/flicking 4.10.4 → 4.10.5

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.10.4
7
+ version: 4.10.5
8
8
  */
9
9
  (function (global, factory) {
10
10
  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
@@ -7609,8 +7609,8 @@ version: 4.10.4
7609
7609
  // Move to the adjacent panel
7610
7610
  targetAnchor = this._findAdjacentAnchor(position, posDelta, anchorAtCamera);
7611
7611
  } else {
7612
- // Restore to active panel
7613
- return this.moveToPanel(activeAnchor.panel, {
7612
+ // Fallback to nearest panel from current camera
7613
+ return this.moveToPanel(anchorAtCamera.panel, {
7614
7614
  duration: duration,
7615
7615
  axesEvent: axesEvent
7616
7616
  });
@@ -8078,9 +8078,17 @@ version: 4.10.4
8078
8078
  targetPanel = adjacentAnchor.panel;
8079
8079
  targetPos = adjacentAnchor.position;
8080
8080
  } else {
8081
- // Restore to active panel
8082
- targetPos = camera.clampToReachablePosition(activePanel.position);
8083
- targetPanel = activePanel;
8081
+ // Fallback to nearest panel from current camera
8082
+ var anchorAtCamera = camera.findNearestAnchor(camera.position);
8083
+
8084
+ if (!anchorAtCamera) {
8085
+ return Promise.reject(new FlickingError(MESSAGE.POSITION_NOT_REACHABLE(position), CODE.POSITION_NOT_REACHABLE));
8086
+ }
8087
+
8088
+ return this.moveToPanel(anchorAtCamera.panel, {
8089
+ duration: duration,
8090
+ axesEvent: axesEvent
8091
+ });
8084
8092
  }
8085
8093
 
8086
8094
  this._triggerIndexChangeEvent(targetPanel, position, axesEvent);
@@ -12572,6 +12580,7 @@ version: 4.10.4
12572
12580
  * @property {ALIGN | string | number} panel The align value for each {@link Panel}s<ko>개개의 {@link Panel}에 적용할 값</ko>
12573
12581
  * @property {ALIGN | string | number} camera The align value for {@link Camera}<ko>{@link Camera}에 적용할 값</ko>
12574
12582
  * @default "center"
12583
+ * @see {@link https://naver.github.io/egjs-flicking/Options#align align ( Options )}
12575
12584
  * @example
12576
12585
  * ```ts
12577
12586
  * const possibleOptions = [
@@ -12612,6 +12621,7 @@ version: 4.10.4
12612
12621
  * @ko Flicking의 {@link Flicking#init init()}이 호출될 때 이동할 디폴트 패널의 인덱스로, 0부터 시작하는 정수입니다
12613
12622
  * @type {number}
12614
12623
  * @default 0
12624
+ * @see {@link https://naver.github.io/egjs-flicking/Options#defaultindex defaultIndex ( Options )}
12615
12625
  */
12616
12626
  get: function () {
12617
12627
  return this._defaultIndex;
@@ -12628,6 +12638,7 @@ version: 4.10.4
12628
12638
  * @ko 패널 이동 방향 (true: 가로방향, false: 세로방향)
12629
12639
  * @type {boolean}
12630
12640
  * @default true
12641
+ * @see {@link https://naver.github.io/egjs-flicking/Options#horizontal horizontal ( Options )}
12631
12642
  */
12632
12643
  get: function () {
12633
12644
  return this._horizontal;
@@ -12648,6 +12659,7 @@ version: 4.10.4
12648
12659
  * @ko 순환 모드를 활성화합니다. 순환 모드에서는 양 끝의 패널이 서로 연결되어 끊김없는 스크롤이 가능합니다.
12649
12660
  * @type {boolean}
12650
12661
  * @default false
12662
+ * @see {@link https://naver.github.io/egjs-flicking/Options#circular circular ( Options )}
12651
12663
  */
12652
12664
  get: function () {
12653
12665
  return this._circular;
@@ -12670,6 +12682,7 @@ version: 4.10.4
12670
12682
  * @see CIRCULAR_FALLBACK
12671
12683
  * @type {string}
12672
12684
  * @default "linear"
12685
+ * @see {@link https://naver.github.io/egjs-flicking/Options#circularfallback circularFallback ( Options )}
12673
12686
  */
12674
12687
  get: function () {
12675
12688
  return this._circularFallback;
@@ -12685,6 +12698,7 @@ version: 4.10.4
12685
12698
  * `circular=false`인 경우에만 사용할 수 있습니다
12686
12699
  * @type {boolean}
12687
12700
  * @default false
12701
+ * @see {@link https://naver.github.io/egjs-flicking/Options#bound bound ( Options )}
12688
12702
  */
12689
12703
  get: function () {
12690
12704
  return this._bound;
@@ -12702,6 +12716,7 @@ version: 4.10.4
12702
12716
  * @ko 이동한 후 뷰포트 엘리먼트의 크기를 현재 패널의 높이와 동일하게 설정합니다. `horizontal=true`인 경우에만 사용할 수 있습니다.
12703
12717
  * @type {boolean}
12704
12718
  * @default false
12719
+ * @see {@link https://naver.github.io/egjs-flicking/Options#adaptive adaptive ( Options )}
12705
12720
  */
12706
12721
  get: function () {
12707
12722
  return this._adaptive;
@@ -12719,6 +12734,7 @@ version: 4.10.4
12719
12734
  * @ko 한 화면에 보이는 패널의 개수. 이 옵션을 활성화할 경우 패널의 크기를 강제로 재조정합니다
12720
12735
  * @type {number}
12721
12736
  * @default -1
12737
+ * @see {@link https://naver.github.io/egjs-flicking/Options#panelsperview panelsPerView ( Options )}
12722
12738
  */
12723
12739
  get: function () {
12724
12740
  return this._panelsPerView;
@@ -12757,6 +12773,7 @@ version: 4.10.4
12757
12773
  * 이 동작은 Flicking 내부에 로드 전/후로 크기가 변하는 콘텐츠를 포함하고 있을 때 유용하게 사용하실 수 있습니다.
12758
12774
  * @type {boolean}
12759
12775
  * @default false
12776
+ * @see {@link https://naver.github.io/egjs-flicking/Options#resizeOnContentsReady resizeOnContentsReady ( Options )}
12760
12777
  */
12761
12778
  get: function () {
12762
12779
  return this._resizeOnContentsReady;
@@ -12779,6 +12796,7 @@ version: 4.10.4
12779
12796
  * 만약 상위 Flicking과 하위 Flicking이 서로 다른 horizontal 옵션을 가지고 있다면 이 옵션을 설정할 필요가 없습니다.
12780
12797
  * @type {boolean}
12781
12798
  * @default false
12799
+ * @see {@link https://naver.github.io/egjs-flicking/Options#nested nested ( Options )}
12782
12800
  */
12783
12801
  get: function () {
12784
12802
  return this._nested;
@@ -12802,6 +12820,7 @@ version: 4.10.4
12802
12820
  * @ko `needPanel`이벤트가 발생하기 위한 뷰포트 끝으로부터의 최대 거리
12803
12821
  * @type {number}
12804
12822
  * @default 0
12823
+ * @see {@link https://naver.github.io/egjs-flicking/Options#needpanelthreshold needPanelThreshold ( Options )}
12805
12824
  */
12806
12825
  get: function () {
12807
12826
  return this._needPanelThreshold;
@@ -12819,6 +12838,7 @@ version: 4.10.4
12819
12838
  * @ko 활성화할 경우 초기화시 `ready` 이벤트 이전의 이벤트가 발생하지 않습니다.
12820
12839
  * @type {boolean}
12821
12840
  * @default true
12841
+ * @see {@link https://naver.github.io/egjs-flicking/Options#preventeventsbeforeinit preventEventsBeforeInit ( Options )}
12822
12842
  */
12823
12843
  get: function () {
12824
12844
  return this._preventEventsBeforeInit;
@@ -12837,6 +12857,7 @@ version: 4.10.4
12837
12857
  * @ko 사용자의 동작으로 가속도가 적용된 패널 이동 애니메이션의 감속도. 값이 높을수록 애니메이션 실행 시간이 짧아집니다
12838
12858
  * @type {number}
12839
12859
  * @default 0.0075
12860
+ * @see {@link https://naver.github.io/egjs-flicking/Options#deceleration deceleration ( Options )}
12840
12861
  */
12841
12862
  get: function () {
12842
12863
  return this._deceleration;
@@ -12860,6 +12881,7 @@ version: 4.10.4
12860
12881
  * @type {function}
12861
12882
  * @default x => 1 - Math.pow(1 - x, 3)
12862
12883
  * @see Easing Functions Cheat Sheet {@link http://easings.net/} <ko>이징 함수 Cheat Sheet {@link http://easings.net/}</ko>
12884
+ * @see {@link https://naver.github.io/egjs-flicking/Options#easing Easing ( Options )}
12863
12885
  */
12864
12886
  get: function () {
12865
12887
  return this._easing;
@@ -12881,6 +12903,7 @@ version: 4.10.4
12881
12903
  * @ko 디폴트 애니메이션 재생 시간 (ms)
12882
12904
  * @type {number}
12883
12905
  * @default 500
12906
+ * @see {@link https://naver.github.io/egjs-flicking/Options#duration duration ( Options )}
12884
12907
  */
12885
12908
  get: function () {
12886
12909
  return this._duration;
@@ -12899,8 +12922,9 @@ version: 4.10.4
12899
12922
  * @ko 활성화할 입력 장치 종류
12900
12923
  * @type {string[]}
12901
12924
  * @default ["touch", "mouse"]
12902
- * @see {@link https://naver.github.io/egjs-axes/release/latest/doc/global.html#PanInputOption Possible values (PanInputOption#inputType)}
12903
- * <ko>{@link https://naver.github.io/egjs-axes/release/latest/doc/global.html#PanInputOption 가능한 값들 (PanInputOption#inputType)}</ko>
12925
+ * @see {@link https://naver.github.io/egjs-axes/Options#paninput-options Possible values (PanInputOption#inputType)}
12926
+ * <ko>{@link https://naver.github.io/egjs-axes/Options#paninput-options 가능한 값들 (PanInputOption#inputType)}</ko>
12927
+ * @see {@link https://naver.github.io/egjs-flicking/Options#inputtype inputType ( Options )}
12904
12928
  */
12905
12929
  get: function () {
12906
12930
  return this._inputType;
@@ -12925,6 +12949,7 @@ version: 4.10.4
12925
12949
  * 상수 {@link MOVE_TYPE}에 정의된 값들을 이용할 수 있습니다
12926
12950
  * @type {MOVE_TYPE | Pair<string, object>}
12927
12951
  * @default "snap"
12952
+ * @see {@link https://naver.github.io/egjs-flicking/Options#movetype moveType ( Options )}
12928
12953
  * @example
12929
12954
  * |moveType|control|options|
12930
12955
  * |:---:|:---:|:---:|
@@ -12975,6 +13000,7 @@ version: 4.10.4
12975
13000
  * @ko 패널 변경을 위한 이동 임계값 (단위: px). 주어진 값 이상으로 스크롤해야만 패널 변경이 가능하다.
12976
13001
  * @type {number}
12977
13002
  * @default 40
13003
+ * @see {@link https://naver.github.io/egjs-flicking/Options#threshold Threshold ( Options )}
12978
13004
  */
12979
13005
  get: function () {
12980
13006
  return this._threshold;
@@ -12991,6 +13017,7 @@ version: 4.10.4
12991
13017
  * @ko 사용자의 클릭/터치로 인해 애니메이션을 도중에 멈출 수 있도록 설정합니다.
12992
13018
  * @type {boolean}
12993
13019
  * @default true
13020
+ * @see {@link https://naver.github.io/egjs-flicking/Options#interruptable Interruptable ( Options )}
12994
13021
  */
12995
13022
  get: function () {
12996
13023
  return this._interruptable;
@@ -13018,6 +13045,7 @@ version: 4.10.4
13018
13045
  * 이 값을 변경시 {@link Control#updateInput}를 호출해야 합니다.
13019
13046
  * @type {string | number | Array<string | number>}
13020
13047
  * @default "20%"
13048
+ * @see {@link https://naver.github.io/egjs-flicking/Options#bounce bounce ( Options )}
13021
13049
  * @example
13022
13050
  * ```ts
13023
13051
  * const possibleOptions = [
@@ -13055,6 +13083,7 @@ version: 4.10.4
13055
13083
  * @ko iOS Safari에서 swipe를 통한 뒤로가기/앞으로가기를 활성화하는 오른쪽 끝으로부터의 영역의 크기 (px)
13056
13084
  * @type {number}
13057
13085
  * @default 30
13086
+ * @see {@link https://naver.github.io/egjs-flicking/Options#iosedgeswipethreshold iOSEdgeSwipeThreshold ( Options )}
13058
13087
  */
13059
13088
  get: function () {
13060
13089
  return this._iOSEdgeSwipeThreshold;
@@ -13076,6 +13105,7 @@ version: 4.10.4
13076
13105
  * @ko 사용자가 뷰포트 영역을 1픽셀이라도 드래그했을 경우 자동으로 {@link https://developer.mozilla.org/ko/docs/Web/API/Element/click_event click} 이벤트를 취소합니다
13077
13106
  * @type {boolean}
13078
13107
  * @default true
13108
+ * @see {@link https://naver.github.io/egjs-flicking/Options#preventclickondrag preventClickOnDrag ( Options )}
13079
13109
  */
13080
13110
  get: function () {
13081
13111
  return this._preventClickOnDrag;
@@ -13102,6 +13132,7 @@ version: 4.10.4
13102
13132
  * @ko Flicking init시에 {@link Flicking#disableInput disableInput()}을 바로 호출합니다
13103
13133
  * @type {boolean}
13104
13134
  * @default false
13135
+ * @see {@link https://naver.github.io/egjs-flicking/Options#disableoninit disableOnInit ( Options )}
13105
13136
  */
13106
13137
  get: function () {
13107
13138
  return this._disableOnInit;
@@ -13120,6 +13151,7 @@ version: 4.10.4
13120
13151
  * `willChange`/`willRestore` 이벤트의 `index`값이 새로운 인덱스로 사용될 것입니다.
13121
13152
  * @type {boolean}
13122
13153
  * @default false
13154
+ * @see {@link https://naver.github.io/egjs-flicking/Options#changeonhold changeOnHold ( Options )}
13123
13155
  */
13124
13156
  get: function () {
13125
13157
  return this._changeOnHold;
@@ -13138,6 +13170,7 @@ version: 4.10.4
13138
13170
  * @ko 보이는 패널만 렌더링할지 여부를 설정합니다. 패널이 많을 경우에 퍼포먼스를 크게 향상시킬 수 있습니다
13139
13171
  * @type {boolean}
13140
13172
  * @default false
13173
+ * @see {@link https://naver.github.io/egjs-flicking/Options#renderonlyvisible renderOnlyVisible ( Options )}
13141
13174
  */
13142
13175
  get: function () {
13143
13176
  return this._renderOnlyVisible;
@@ -13163,6 +13196,7 @@ version: 4.10.4
13163
13196
  * @property {number} initialPanelCount Initial panel count to render<ko>최초로 렌더링할 패널의 개수</ko>
13164
13197
  * @property {boolean} [cache=false] Whether to cache rendered panel's innerHTML<ko>렌더링된 패널의 innerHTML 정보를 캐시할지 여부</ko>
13165
13198
  * @property {string} [panelClass="flicking-panel"] The class name that will be applied to rendered panel elements<ko>렌더링되는 패널 엘리먼트에 적용될 클래스 이름</ko>
13199
+ * @see {@link https://naver.github.io/egjs-flicking/Options#virtual virtual ( Options )}
13166
13200
  * @example
13167
13201
  * ```ts
13168
13202
  * import Flicking, { VirtualPanel } from "@egjs/flicking";
@@ -13196,6 +13230,7 @@ version: 4.10.4
13196
13230
  * @ko Flicking 인스턴스를 생성할 때 자동으로 {@link Flicking#init init()}를 호출합니다
13197
13231
  * @type {boolean}
13198
13232
  * @default true
13233
+ * @see {@link https://naver.github.io/egjs-flicking/Options#autoinit autoInit ( Options )}
13199
13234
  * @readonly
13200
13235
  */
13201
13236
  get: function () {
@@ -13233,6 +13268,7 @@ version: 4.10.4
13233
13268
  * @ko autoResize 옵션 사용시 {@link https://developer.mozilla.org/en-US/docs/Web/API/ResizeObserver ResizeObserver}의 이벤트를 Window객체의 {@link https://developer.mozilla.org/ko/docs/Web/API/Window/resize_event resize} 이벤트 대신 수신할지 여부를 설정합니다
13234
13269
  * @type {boolean}
13235
13270
  * @default true
13271
+ * @see {@link https://naver.github.io/egjs-flicking/Options#useresizeobserver useResizeObserver ( Options )}
13236
13272
  */
13237
13273
  get: function () {
13238
13274
  return this._useResizeObserver;
@@ -13257,6 +13293,7 @@ version: 4.10.4
13257
13293
  * 이를 통해 `resize`가 너무 많이 호출되는 것을 방지하여 성능을 향상시킬 수 있습니다.
13258
13294
  * @type {number}
13259
13295
  * @default 0
13296
+ * @see {@link https://naver.github.io/egjs-flicking/Options#resizedebounce resizeDebounce ( Options )}
13260
13297
  */
13261
13298
  get: function () {
13262
13299
  return this._resizeDebounce;
@@ -13272,6 +13309,7 @@ version: 4.10.4
13272
13309
  * 이를 통해, 적어도 (n)ms에 한번은 크기 재계산을 수행하는 것을 보장할 수 있습니다.
13273
13310
  * @type {number}
13274
13311
  * @default 100
13312
+ * @see {@link https://naver.github.io/egjs-flicking/Options#maxresizedebounce maxResizeDebounce ( Options )}
13275
13313
  */
13276
13314
  get: function () {
13277
13315
  return this._maxResizeDebounce;
@@ -13289,6 +13327,7 @@ version: 4.10.4
13289
13327
  * 모든 크기는 CSS {@link https://developer.mozilla.org/en-US/docs/Web/CSS/transform transform}이 엘리먼트에 적용되기 이전의 크기를 사용할 것입니다.
13290
13328
  * @type {boolean}
13291
13329
  * @default false
13330
+ * @see {@link https://naver.github.io/egjs-flicking/Options#usefractionalsize useFractionalSize ( Options )}
13292
13331
  */
13293
13332
  get: function () {
13294
13333
  return this._useFractionalSize;
@@ -14155,7 +14194,7 @@ version: 4.10.4
14155
14194
  */
14156
14195
 
14157
14196
 
14158
- Flicking.VERSION = "4.10.4";
14197
+ Flicking.VERSION = "4.10.5";
14159
14198
  return Flicking;
14160
14199
  }(Component);
14161
14200