@egjs/flicking 4.9.0 → 4.9.3-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/declaration/control/AxesController.d.ts +1 -0
- package/declaration/control/Control.d.ts +1 -0
- package/declaration/core/panel/Panel.d.ts +1 -1
- package/dist/flicking.esm.js +51 -9
- package/dist/flicking.esm.js.map +1 -1
- package/dist/flicking.js +51 -9
- package/dist/flicking.js.map +1 -1
- package/dist/flicking.min.js +2 -2
- package/dist/flicking.min.js.map +1 -1
- package/dist/flicking.pkgd.js +445 -144
- package/dist/flicking.pkgd.js.map +1 -1
- package/dist/flicking.pkgd.min.js +2 -2
- package/dist/flicking.pkgd.min.js.map +1 -1
- package/package.json +3 -3
- package/src/Flicking.ts +8 -3
- package/src/control/AxesController.ts +12 -0
- package/src/control/Control.ts +12 -0
- package/src/core/panel/Panel.ts +8 -2
- package/src/renderer/Renderer.ts +2 -2
- package/TODO.md +0 -3
package/dist/flicking.esm.js
CHANGED
|
@@ -4,7 +4,7 @@ name: @egjs/flicking
|
|
|
4
4
|
license: MIT
|
|
5
5
|
author: NAVER Corp.
|
|
6
6
|
repository: https://github.com/naver/egjs-flicking
|
|
7
|
-
version: 4.9.0
|
|
7
|
+
version: 4.9.3-beta.0
|
|
8
8
|
*/
|
|
9
9
|
import Component, { ComponentEvent } from '@egjs/component';
|
|
10
10
|
import Axes, { PanInput } from '@egjs/axes';
|
|
@@ -2450,6 +2450,20 @@ function () {
|
|
|
2450
2450
|
(_a = this._panInput) === null || _a === void 0 ? void 0 : _a.disable();
|
|
2451
2451
|
return this;
|
|
2452
2452
|
};
|
|
2453
|
+
/**
|
|
2454
|
+
* Releases ongoing user input (mouse/touch)
|
|
2455
|
+
* @ko 사용자의 현재 입력(마우스/터치)를 중단시킵니다
|
|
2456
|
+
* @chainable
|
|
2457
|
+
* @return {this}
|
|
2458
|
+
*/
|
|
2459
|
+
|
|
2460
|
+
|
|
2461
|
+
__proto.release = function () {
|
|
2462
|
+
var _a;
|
|
2463
|
+
|
|
2464
|
+
(_a = this._panInput) === null || _a === void 0 ? void 0 : _a.release();
|
|
2465
|
+
return this;
|
|
2466
|
+
};
|
|
2453
2467
|
/**
|
|
2454
2468
|
* Update {@link https://naver.github.io/egjs-axes/ @egjs/axes}'s state
|
|
2455
2469
|
* @ko {@link https://naver.github.io/egjs-axes/ @egjs/axes}의 상태를 갱신합니다
|
|
@@ -2761,6 +2775,19 @@ function () {
|
|
|
2761
2775
|
|
|
2762
2776
|
return this;
|
|
2763
2777
|
};
|
|
2778
|
+
/**
|
|
2779
|
+
* Releases ongoing user input (mouse/touch)
|
|
2780
|
+
* @ko 사용자의 현재 입력(마우스/터치)를 중단시킵니다
|
|
2781
|
+
* @chainable
|
|
2782
|
+
* @return {this}
|
|
2783
|
+
*/
|
|
2784
|
+
|
|
2785
|
+
|
|
2786
|
+
__proto.release = function () {
|
|
2787
|
+
this._controller.release();
|
|
2788
|
+
|
|
2789
|
+
return this;
|
|
2790
|
+
};
|
|
2764
2791
|
/**
|
|
2765
2792
|
* Update position after resizing
|
|
2766
2793
|
* @ko resize 이후에 position을 업데이트합니다
|
|
@@ -5482,11 +5509,13 @@ function () {
|
|
|
5482
5509
|
} : {
|
|
5483
5510
|
height: panelSize
|
|
5484
5511
|
};
|
|
5485
|
-
|
|
5512
|
+
|
|
5513
|
+
var firstPanelSizeObj = __assign({
|
|
5486
5514
|
size: panelSize,
|
|
5487
|
-
height: referencePanel.height,
|
|
5488
5515
|
margin: referencePanel.margin
|
|
5489
|
-
}
|
|
5516
|
+
}, !flicking.horizontal && {
|
|
5517
|
+
height: referencePanel.height
|
|
5518
|
+
});
|
|
5490
5519
|
|
|
5491
5520
|
if (!flicking.noPanelStyleOverride) {
|
|
5492
5521
|
this._strategy.updatePanelSizes(flicking, panelSizeObj);
|
|
@@ -6020,6 +6049,8 @@ function () {
|
|
|
6020
6049
|
|
|
6021
6050
|
|
|
6022
6051
|
__proto.resize = function (cached) {
|
|
6052
|
+
var _a;
|
|
6053
|
+
|
|
6023
6054
|
var el = this.element;
|
|
6024
6055
|
var flicking = this._flicking;
|
|
6025
6056
|
var horizontal = flicking.horizontal,
|
|
@@ -6028,7 +6059,13 @@ function () {
|
|
|
6028
6059
|
if (cached) {
|
|
6029
6060
|
this._size = cached.size;
|
|
6030
6061
|
this._margin = __assign({}, cached.margin);
|
|
6031
|
-
this._height = cached.height
|
|
6062
|
+
this._height = (_a = cached.height) !== null && _a !== void 0 ? _a : getElementSize({
|
|
6063
|
+
el: el,
|
|
6064
|
+
horizontal: false,
|
|
6065
|
+
useFractionalSize: useFractionalSize,
|
|
6066
|
+
useOffset: true,
|
|
6067
|
+
style: getStyle(el)
|
|
6068
|
+
});
|
|
6032
6069
|
} else {
|
|
6033
6070
|
var elStyle = getStyle(el);
|
|
6034
6071
|
this._size = getElementSize({
|
|
@@ -7990,6 +8027,10 @@ function (_super) {
|
|
|
7990
8027
|
return Promise.reject(new FlickingError(MESSAGE.ANIMATION_ALREADY_PLAYING, CODE.ANIMATION_ALREADY_PLAYING));
|
|
7991
8028
|
}
|
|
7992
8029
|
|
|
8030
|
+
if (this._control.holding) {
|
|
8031
|
+
this._control.controller.release();
|
|
8032
|
+
}
|
|
8033
|
+
|
|
7993
8034
|
return this._control.moveToPanel(panel, {
|
|
7994
8035
|
duration: duration,
|
|
7995
8036
|
direction: direction
|
|
@@ -8474,9 +8515,10 @@ function (_super) {
|
|
|
8474
8515
|
var renderer = this._renderer;
|
|
8475
8516
|
var control = this._control;
|
|
8476
8517
|
var camera = this._camera;
|
|
8477
|
-
var
|
|
8478
|
-
if (!
|
|
8479
|
-
var nearestAnchor = camera.findNearestAnchor(
|
|
8518
|
+
var defaultPanel = renderer.getPanel(this._defaultIndex) || renderer.getPanel(0);
|
|
8519
|
+
if (!defaultPanel) return;
|
|
8520
|
+
var nearestAnchor = camera.findNearestAnchor(defaultPanel.position);
|
|
8521
|
+
var initialPanel = nearestAnchor && defaultPanel.index !== nearestAnchor.panel.index ? nearestAnchor.panel : defaultPanel;
|
|
8480
8522
|
control.setActive(initialPanel, null, false);
|
|
8481
8523
|
|
|
8482
8524
|
if (!nearestAnchor) {
|
|
@@ -8537,7 +8579,7 @@ function (_super) {
|
|
|
8537
8579
|
*/
|
|
8538
8580
|
|
|
8539
8581
|
|
|
8540
|
-
Flicking.VERSION = "4.9.0";
|
|
8582
|
+
Flicking.VERSION = "4.9.3-beta.0";
|
|
8541
8583
|
return Flicking;
|
|
8542
8584
|
}(Component);
|
|
8543
8585
|
|