@egjs/flicking 4.10.5-beta.0 → 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.
- package/declaration/Flicking.d.ts +236 -236
- package/declaration/camera/Camera.d.ts +82 -82
- package/declaration/camera/index.d.ts +4 -4
- package/declaration/camera/mode/BoundCameraMode.d.ts +13 -13
- package/declaration/camera/mode/CameraMode.d.ts +20 -20
- package/declaration/camera/mode/CircularCameraMode.d.ts +19 -19
- package/declaration/camera/mode/LinearCameraMode.d.ts +9 -9
- package/declaration/camera/mode/index.d.ts +6 -6
- package/declaration/cfc/getDefaultCameraTransform.d.ts +3 -3
- package/declaration/cfc/getRenderingPanels.d.ts +4 -4
- package/declaration/cfc/index.d.ts +5 -5
- package/declaration/cfc/sync.d.ts +4 -4
- package/declaration/cfc/withFlickingMethods.d.ts +2 -2
- package/declaration/const/axes.d.ts +8 -8
- package/declaration/const/error.d.ts +34 -34
- package/declaration/const/external.d.ts +44 -44
- package/declaration/control/AxesController.d.ts +44 -44
- package/declaration/control/Control.d.ts +44 -44
- package/declaration/control/FreeControl.d.ts +14 -14
- package/declaration/control/SnapControl.d.ts +16 -16
- package/declaration/control/StateMachine.d.ts +14 -14
- package/declaration/control/StrictControl.d.ts +20 -20
- package/declaration/control/index.d.ts +14 -14
- package/declaration/control/states/AnimatingState.d.ts +9 -9
- package/declaration/control/states/DisabledState.d.ts +9 -9
- package/declaration/control/states/DraggingState.d.ts +8 -8
- package/declaration/control/states/HoldingState.d.ts +10 -10
- package/declaration/control/states/IdleState.d.ts +9 -9
- package/declaration/control/states/State.d.ts +47 -47
- package/declaration/core/AnchorPoint.d.ts +15 -15
- package/declaration/core/AutoResizer.d.ts +16 -16
- package/declaration/core/FlickingError.d.ts +5 -5
- package/declaration/core/ResizeWatcher.d.ts +33 -33
- package/declaration/core/Viewport.d.ts +25 -25
- package/declaration/core/VirtualManager.d.ts +37 -37
- package/declaration/core/index.d.ts +6 -6
- package/declaration/core/panel/Panel.d.ts +89 -89
- package/declaration/core/panel/VirtualPanel.d.ts +19 -19
- package/declaration/core/panel/index.d.ts +5 -5
- package/declaration/core/panel/provider/ElementProvider.d.ts +8 -8
- package/declaration/core/panel/provider/VanillaElementProvider.d.ts +12 -12
- package/declaration/core/panel/provider/VirtualElementProvider.d.ts +15 -15
- package/declaration/core/panel/provider/index.d.ts +5 -5
- package/declaration/index.d.ts +13 -13
- package/declaration/index.umd.d.ts +2 -2
- package/declaration/renderer/ExternalRenderer.d.ts +7 -7
- package/declaration/renderer/Renderer.d.ts +58 -58
- package/declaration/renderer/VanillaRenderer.d.ts +10 -10
- package/declaration/renderer/index.d.ts +6 -6
- package/declaration/renderer/strategy/NormalRenderingStrategy.d.ts +23 -23
- package/declaration/renderer/strategy/RenderingStrategy.d.ts +15 -15
- package/declaration/renderer/strategy/VirtualRenderingStrategy.d.ts +17 -17
- package/declaration/renderer/strategy/index.d.ts +5 -5
- package/declaration/type/event.d.ts +88 -88
- package/declaration/type/external.d.ts +31 -31
- package/declaration/type/internal.d.ts +13 -13
- package/declaration/utils.d.ts +45 -45
- package/dist/flicking.esm.js +16 -8
- package/dist/flicking.esm.js.map +1 -1
- package/dist/flicking.js +16 -8
- 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 +858 -842
- package/dist/flicking.pkgd.js.map +1 -1
- package/dist/flicking.pkgd.min.js +2 -2
- package/dist/flicking.pkgd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/control/SnapControl.ts +2 -2
- package/src/control/StrictControl.ts +9 -3
- package/src/core/ResizeWatcher.ts +1 -1
- package/src/utils.ts +1 -1
package/dist/flicking.pkgd.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.10.5
|
|
7
|
+
version: 4.10.5
|
|
8
8
|
*/
|
|
9
9
|
(function (global, factory) {
|
|
10
10
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
@@ -256,7 +256,7 @@ version: 4.10.5-beta.0
|
|
|
256
256
|
license: MIT
|
|
257
257
|
author: NAVER Corp.
|
|
258
258
|
repository: https://github.com/naver/egjs-component
|
|
259
|
-
version: 3.0.
|
|
259
|
+
version: 3.0.2
|
|
260
260
|
*/
|
|
261
261
|
/*! *****************************************************************************
|
|
262
262
|
Copyright (c) Microsoft Corporation.
|
|
@@ -274,8 +274,8 @@ version: 4.10.5-beta.0
|
|
|
274
274
|
***************************************************************************** */
|
|
275
275
|
function __values(o) {
|
|
276
276
|
var s = typeof Symbol === "function" && Symbol.iterator,
|
|
277
|
-
|
|
278
|
-
|
|
277
|
+
m = s && o[s],
|
|
278
|
+
i = 0;
|
|
279
279
|
if (m) return m.call(o);
|
|
280
280
|
if (o && typeof o.length === "number") return {
|
|
281
281
|
next: function () {
|
|
@@ -292,9 +292,10 @@ version: 4.10.5-beta.0
|
|
|
292
292
|
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
293
293
|
if (!m) return o;
|
|
294
294
|
var i = m.call(o),
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
295
|
+
r,
|
|
296
|
+
ar = [],
|
|
297
|
+
e;
|
|
298
|
+
|
|
298
299
|
try {
|
|
299
300
|
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
300
301
|
} catch (error) {
|
|
@@ -308,10 +309,12 @@ version: 4.10.5-beta.0
|
|
|
308
309
|
if (e) throw e.error;
|
|
309
310
|
}
|
|
310
311
|
}
|
|
312
|
+
|
|
311
313
|
return ar;
|
|
312
314
|
}
|
|
313
315
|
function __spread() {
|
|
314
316
|
for (var ar = [], i = 0; i < arguments.length; i++) ar = ar.concat(__read(arguments[i]));
|
|
317
|
+
|
|
315
318
|
return ar;
|
|
316
319
|
}
|
|
317
320
|
|
|
@@ -323,12 +326,14 @@ version: 4.10.5-beta.0
|
|
|
323
326
|
return typeof value === "undefined";
|
|
324
327
|
};
|
|
325
328
|
|
|
326
|
-
// This class name is not matched to file name intentionally
|
|
327
329
|
/**
|
|
328
330
|
* Event class to provide additional properties
|
|
329
331
|
* @ko Component에서 추가적인 프로퍼티를 제공하는 이벤트 클래스
|
|
330
332
|
*/
|
|
331
|
-
|
|
333
|
+
|
|
334
|
+
var ComponentEvent =
|
|
335
|
+
/*#__PURE__*/
|
|
336
|
+
function () {
|
|
332
337
|
/**
|
|
333
338
|
* Create a new instance of ComponentEvent.
|
|
334
339
|
* @ko ComponentEvent의 새로운 인스턴스를 생성한다.
|
|
@@ -337,12 +342,14 @@ version: 4.10.5-beta.0
|
|
|
337
342
|
*/
|
|
338
343
|
function ComponentEvent(eventType, props) {
|
|
339
344
|
var e_1, _a;
|
|
345
|
+
|
|
340
346
|
this._canceled = false;
|
|
347
|
+
|
|
341
348
|
if (props) {
|
|
342
349
|
try {
|
|
343
350
|
for (var _b = __values(Object.keys(props)), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
344
|
-
var key = _c.value;
|
|
345
|
-
|
|
351
|
+
var key = _c.value; // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
|
|
352
|
+
|
|
346
353
|
this[key] = props[key];
|
|
347
354
|
}
|
|
348
355
|
} catch (e_1_1) {
|
|
@@ -357,13 +364,17 @@ version: 4.10.5-beta.0
|
|
|
357
364
|
}
|
|
358
365
|
}
|
|
359
366
|
}
|
|
367
|
+
|
|
360
368
|
this.eventType = eventType;
|
|
361
369
|
}
|
|
362
370
|
/**
|
|
363
371
|
* Stop the event. {@link ComponentEvent#isCanceled} will return `true` after.
|
|
364
372
|
* @ko 이벤트를 중단한다. 이후 {@link ComponentEvent#isCanceled}가 `true`를 반환한다.
|
|
365
373
|
*/
|
|
374
|
+
|
|
375
|
+
|
|
366
376
|
var __proto = ComponentEvent.prototype;
|
|
377
|
+
|
|
367
378
|
__proto.stop = function () {
|
|
368
379
|
this._canceled = true;
|
|
369
380
|
};
|
|
@@ -372,9 +383,12 @@ version: 4.10.5-beta.0
|
|
|
372
383
|
* @ko {@link ComponentEvent#stop}이 호출되었는지 여부를 반환한다.
|
|
373
384
|
* @return {boolean} A boolean value that indicates whether {@link ComponentEvent#stop} is called before.<ko>이전에 {@link ComponentEvent#stop}이 불려졌는지 여부를 반환한다.</ko>
|
|
374
385
|
*/
|
|
386
|
+
|
|
387
|
+
|
|
375
388
|
__proto.isCanceled = function () {
|
|
376
389
|
return this._canceled;
|
|
377
390
|
};
|
|
391
|
+
|
|
378
392
|
return ComponentEvent;
|
|
379
393
|
}();
|
|
380
394
|
|
|
@@ -382,7 +396,10 @@ version: 4.10.5-beta.0
|
|
|
382
396
|
* A class used to manage events in a component
|
|
383
397
|
* @ko 컴포넌트의 이벤트을 관리할 수 있게 하는 클래스
|
|
384
398
|
*/
|
|
385
|
-
|
|
399
|
+
|
|
400
|
+
var Component =
|
|
401
|
+
/*#__PURE__*/
|
|
402
|
+
function () {
|
|
386
403
|
/**
|
|
387
404
|
* @support {"ie": "7+", "ch" : "latest", "ff" : "latest", "sf" : "latest", "edge" : "latest", "ios" : "7+", "an" : "2.1+ (except 3.x)"}
|
|
388
405
|
*/
|
|
@@ -430,17 +447,25 @@ version: 4.10.5-beta.0
|
|
|
430
447
|
* // https://github.com/naver/egjs-component/wiki/How-to-make-Component-event-design%3F
|
|
431
448
|
* ```
|
|
432
449
|
*/
|
|
450
|
+
|
|
451
|
+
|
|
433
452
|
var __proto = Component.prototype;
|
|
453
|
+
|
|
434
454
|
__proto.trigger = function (event) {
|
|
435
455
|
var params = [];
|
|
456
|
+
|
|
436
457
|
for (var _i = 1; _i < arguments.length; _i++) {
|
|
437
458
|
params[_i - 1] = arguments[_i];
|
|
438
459
|
}
|
|
460
|
+
|
|
439
461
|
var eventName = event instanceof ComponentEvent ? event.eventType : event;
|
|
462
|
+
|
|
440
463
|
var handlers = __spread(this._eventHandler[eventName] || []);
|
|
464
|
+
|
|
441
465
|
if (handlers.length <= 0) {
|
|
442
466
|
return this;
|
|
443
467
|
}
|
|
468
|
+
|
|
444
469
|
if (event instanceof ComponentEvent) {
|
|
445
470
|
event.currentTarget = this;
|
|
446
471
|
handlers.forEach(function (handler) {
|
|
@@ -452,6 +477,7 @@ version: 4.10.5-beta.0
|
|
|
452
477
|
handler.apply(void 0, __spread(params));
|
|
453
478
|
});
|
|
454
479
|
}
|
|
480
|
+
|
|
455
481
|
return this;
|
|
456
482
|
};
|
|
457
483
|
/**
|
|
@@ -483,26 +509,36 @@ version: 4.10.5-beta.0
|
|
|
483
509
|
* // Nothing happens
|
|
484
510
|
* ```
|
|
485
511
|
*/
|
|
512
|
+
|
|
513
|
+
|
|
486
514
|
__proto.once = function (eventName, handlerToAttach) {
|
|
487
515
|
var _this = this;
|
|
516
|
+
|
|
488
517
|
if (typeof eventName === "object" && isUndefined(handlerToAttach)) {
|
|
489
518
|
var eventHash = eventName;
|
|
519
|
+
|
|
490
520
|
for (var key in eventHash) {
|
|
491
521
|
this.once(key, eventHash[key]);
|
|
492
522
|
}
|
|
523
|
+
|
|
493
524
|
return this;
|
|
494
525
|
} else if (typeof eventName === "string" && typeof handlerToAttach === "function") {
|
|
495
526
|
var listener_1 = function () {
|
|
496
527
|
var args = [];
|
|
528
|
+
|
|
497
529
|
for (var _i = 0; _i < arguments.length; _i++) {
|
|
498
530
|
args[_i] = arguments[_i];
|
|
499
|
-
}
|
|
500
|
-
|
|
531
|
+
} // eslint-disable-next-line @typescript-eslint/no-unsafe-call
|
|
532
|
+
|
|
533
|
+
|
|
501
534
|
handlerToAttach.apply(void 0, __spread(args));
|
|
535
|
+
|
|
502
536
|
_this.off(eventName, listener_1);
|
|
503
537
|
};
|
|
538
|
+
|
|
504
539
|
this.on(eventName, listener_1);
|
|
505
540
|
}
|
|
541
|
+
|
|
506
542
|
return this;
|
|
507
543
|
};
|
|
508
544
|
/**
|
|
@@ -523,6 +559,8 @@ version: 4.10.5-beta.0
|
|
|
523
559
|
* }
|
|
524
560
|
* ```
|
|
525
561
|
*/
|
|
562
|
+
|
|
563
|
+
|
|
526
564
|
__proto.hasOn = function (eventName) {
|
|
527
565
|
return !!this._eventHandler[eventName];
|
|
528
566
|
};
|
|
@@ -548,21 +586,28 @@ version: 4.10.5-beta.0
|
|
|
548
586
|
* }
|
|
549
587
|
* ```
|
|
550
588
|
*/
|
|
589
|
+
|
|
590
|
+
|
|
551
591
|
__proto.on = function (eventName, handlerToAttach) {
|
|
552
592
|
if (typeof eventName === "object" && isUndefined(handlerToAttach)) {
|
|
553
593
|
var eventHash = eventName;
|
|
594
|
+
|
|
554
595
|
for (var name in eventHash) {
|
|
555
596
|
this.on(name, eventHash[name]);
|
|
556
597
|
}
|
|
598
|
+
|
|
557
599
|
return this;
|
|
558
600
|
} else if (typeof eventName === "string" && typeof handlerToAttach === "function") {
|
|
559
601
|
var handlerList = this._eventHandler[eventName];
|
|
602
|
+
|
|
560
603
|
if (isUndefined(handlerList)) {
|
|
561
604
|
this._eventHandler[eventName] = [];
|
|
562
605
|
handlerList = this._eventHandler[eventName];
|
|
563
606
|
}
|
|
607
|
+
|
|
564
608
|
handlerList.push(handlerToAttach);
|
|
565
609
|
}
|
|
610
|
+
|
|
566
611
|
return this;
|
|
567
612
|
};
|
|
568
613
|
/**
|
|
@@ -587,40 +632,53 @@ version: 4.10.5-beta.0
|
|
|
587
632
|
* }
|
|
588
633
|
* ```
|
|
589
634
|
*/
|
|
635
|
+
|
|
636
|
+
|
|
590
637
|
__proto.off = function (eventName, handlerToDetach) {
|
|
591
|
-
var e_1, _a;
|
|
592
|
-
|
|
638
|
+
var e_1, _a; // Detach all event handlers.
|
|
639
|
+
|
|
640
|
+
|
|
593
641
|
if (isUndefined(eventName)) {
|
|
594
642
|
this._eventHandler = {};
|
|
595
643
|
return this;
|
|
596
|
-
}
|
|
597
|
-
|
|
644
|
+
} // Detach all handlers for eventname or detach event handlers by object.
|
|
645
|
+
|
|
646
|
+
|
|
598
647
|
if (isUndefined(handlerToDetach)) {
|
|
599
648
|
if (typeof eventName === "string") {
|
|
600
649
|
delete this._eventHandler[eventName];
|
|
601
650
|
return this;
|
|
602
651
|
} else {
|
|
603
652
|
var eventHash = eventName;
|
|
653
|
+
|
|
604
654
|
for (var name in eventHash) {
|
|
605
655
|
this.off(name, eventHash[name]);
|
|
606
656
|
}
|
|
657
|
+
|
|
607
658
|
return this;
|
|
608
659
|
}
|
|
609
|
-
}
|
|
610
|
-
|
|
660
|
+
} // Detach single event handler
|
|
661
|
+
|
|
662
|
+
|
|
611
663
|
var handlerList = this._eventHandler[eventName];
|
|
664
|
+
|
|
612
665
|
if (handlerList) {
|
|
613
666
|
var idx = 0;
|
|
667
|
+
|
|
614
668
|
try {
|
|
615
669
|
for (var handlerList_1 = __values(handlerList), handlerList_1_1 = handlerList_1.next(); !handlerList_1_1.done; handlerList_1_1 = handlerList_1.next()) {
|
|
616
670
|
var handlerFunction = handlerList_1_1.value;
|
|
671
|
+
|
|
617
672
|
if (handlerFunction === handlerToDetach) {
|
|
618
673
|
handlerList.splice(idx, 1);
|
|
674
|
+
|
|
619
675
|
if (handlerList.length <= 0) {
|
|
620
676
|
delete this._eventHandler[eventName];
|
|
621
677
|
}
|
|
678
|
+
|
|
622
679
|
break;
|
|
623
680
|
}
|
|
681
|
+
|
|
624
682
|
idx++;
|
|
625
683
|
}
|
|
626
684
|
} catch (e_1_1) {
|
|
@@ -635,6 +693,7 @@ version: 4.10.5-beta.0
|
|
|
635
693
|
}
|
|
636
694
|
}
|
|
637
695
|
}
|
|
696
|
+
|
|
638
697
|
return this;
|
|
639
698
|
};
|
|
640
699
|
/**
|
|
@@ -646,7 +705,9 @@ version: 4.10.5-beta.0
|
|
|
646
705
|
* Component.VERSION; // ex) 3.0.0
|
|
647
706
|
* @memberof Component
|
|
648
707
|
*/
|
|
649
|
-
|
|
708
|
+
|
|
709
|
+
|
|
710
|
+
Component.VERSION = "3.0.2";
|
|
650
711
|
return Component;
|
|
651
712
|
}();
|
|
652
713
|
|
|
@@ -654,7 +715,7 @@ version: 4.10.5-beta.0
|
|
|
654
715
|
* Copyright (c) 2015 NAVER Corp.
|
|
655
716
|
* egjs projects are licensed under the MIT license
|
|
656
717
|
*/
|
|
657
|
-
|
|
718
|
+
|
|
658
719
|
var ComponentEvent$1 = ComponentEvent;
|
|
659
720
|
|
|
660
721
|
/*
|
|
@@ -1087,7 +1148,7 @@ version: 4.10.5-beta.0
|
|
|
1087
1148
|
if (pos < min) {
|
|
1088
1149
|
var offset = (min - pos) % size;
|
|
1089
1150
|
pos = max - offset;
|
|
1090
|
-
} else if (pos
|
|
1151
|
+
} else if (pos > max) {
|
|
1091
1152
|
var offset = (pos - max) % size;
|
|
1092
1153
|
pos = min + offset;
|
|
1093
1154
|
}
|
|
@@ -2365,7 +2426,7 @@ version: 4.10.5-beta.0
|
|
|
2365
2426
|
license: MIT
|
|
2366
2427
|
author: NAVER Corp.
|
|
2367
2428
|
repository: https://github.com/naver/egjs-axes
|
|
2368
|
-
version: 3.8.
|
|
2429
|
+
version: 3.8.3
|
|
2369
2430
|
*/
|
|
2370
2431
|
|
|
2371
2432
|
/*! *****************************************************************************
|
|
@@ -2426,9 +2487,9 @@ version: 4.10.5-beta.0
|
|
|
2426
2487
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
2427
2488
|
}
|
|
2428
2489
|
|
|
2429
|
-
/*
|
|
2430
|
-
* Copyright (c) 2015 NAVER Corp.
|
|
2431
|
-
* egjs projects are licensed under the MIT license
|
|
2490
|
+
/*
|
|
2491
|
+
* Copyright (c) 2015 NAVER Corp.
|
|
2492
|
+
* egjs projects are licensed under the MIT license
|
|
2432
2493
|
*/
|
|
2433
2494
|
|
|
2434
2495
|
/* eslint-disable no-new-func, no-nested-ternary */
|
|
@@ -2445,9 +2506,9 @@ version: 4.10.5-beta.0
|
|
|
2445
2506
|
win = window;
|
|
2446
2507
|
}
|
|
2447
2508
|
|
|
2448
|
-
/*
|
|
2449
|
-
* Copyright (c) 2015 NAVER Corp.
|
|
2450
|
-
* egjs projects are licensed under the MIT license
|
|
2509
|
+
/*
|
|
2510
|
+
* Copyright (c) 2015 NAVER Corp.
|
|
2511
|
+
* egjs projects are licensed under the MIT license
|
|
2451
2512
|
*/
|
|
2452
2513
|
var DIRECTION_NONE = 1;
|
|
2453
2514
|
var DIRECTION_LEFT = 2;
|
|
@@ -2580,21 +2641,21 @@ version: 4.10.5-beta.0
|
|
|
2580
2641
|
|
|
2581
2642
|
caf = win.clearTimeout;
|
|
2582
2643
|
}
|
|
2583
|
-
/**
|
|
2584
|
-
* A polyfill for the window.requestAnimationFrame() method.
|
|
2585
|
-
* @see https://developer.mozilla.org/en-US/docs/Web/API/window/requestAnimationFrame
|
|
2586
|
-
* @private
|
|
2644
|
+
/**
|
|
2645
|
+
* A polyfill for the window.requestAnimationFrame() method.
|
|
2646
|
+
* @see https://developer.mozilla.org/en-US/docs/Web/API/window/requestAnimationFrame
|
|
2647
|
+
* @private
|
|
2587
2648
|
*/
|
|
2588
2649
|
|
|
2589
2650
|
|
|
2590
2651
|
var requestAnimationFrame = function (fp) {
|
|
2591
2652
|
return raf(fp);
|
|
2592
2653
|
};
|
|
2593
|
-
/**
|
|
2594
|
-
* A polyfill for the window.cancelAnimationFrame() method. It cancels an animation executed through a call to the requestAnimationFrame() method.
|
|
2595
|
-
* @param {Number} key − The ID value returned through a call to the requestAnimationFrame() method. <ko>requestAnimationFrame() 메서드가 반환한 아이디 값</ko>
|
|
2596
|
-
* @see https://developer.mozilla.org/en-US/docs/Web/API/Window/cancelAnimationFrame
|
|
2597
|
-
* @private
|
|
2654
|
+
/**
|
|
2655
|
+
* A polyfill for the window.cancelAnimationFrame() method. It cancels an animation executed through a call to the requestAnimationFrame() method.
|
|
2656
|
+
* @param {Number} key − The ID value returned through a call to the requestAnimationFrame() method. <ko>requestAnimationFrame() 메서드가 반환한 아이디 값</ko>
|
|
2657
|
+
* @see https://developer.mozilla.org/en-US/docs/Web/API/Window/cancelAnimationFrame
|
|
2658
|
+
* @private
|
|
2598
2659
|
*/
|
|
2599
2660
|
|
|
2600
2661
|
var cancelAnimationFrame = function (key) {
|
|
@@ -2761,32 +2822,32 @@ version: 4.10.5-beta.0
|
|
|
2761
2822
|
function EventManager(_axes) {
|
|
2762
2823
|
this._axes = _axes;
|
|
2763
2824
|
}
|
|
2764
|
-
/**
|
|
2765
|
-
* This event is fired when a user holds an element on the screen of the device.
|
|
2766
|
-
* @ko 사용자가 기기의 화면에 손을 대고 있을 때 발생하는 이벤트
|
|
2767
|
-
* @event Axes#hold
|
|
2768
|
-
* @type {object}
|
|
2769
|
-
* @property {Object.<string, number>} pos coordinate <ko>좌표 정보</ko>
|
|
2770
|
-
* @property {Object} input The instance of inputType where the event occurred<ko>이벤트가 발생한 inputType 인스턴스</ko>
|
|
2771
|
-
* @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
|
|
2772
|
-
* @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>
|
|
2773
|
-
*
|
|
2774
|
-
* @example
|
|
2775
|
-
* ```js
|
|
2776
|
-
* const axes = new eg.Axes({
|
|
2777
|
-
* "x": {
|
|
2778
|
-
* range: [0, 100]
|
|
2779
|
-
* },
|
|
2780
|
-
* "zoom": {
|
|
2781
|
-
* range: [50, 30]
|
|
2782
|
-
* }
|
|
2783
|
-
* }).on("hold", function(event) {
|
|
2784
|
-
* // event.pos
|
|
2785
|
-
* // event.input
|
|
2786
|
-
* // event.inputEvent
|
|
2787
|
-
* // isTrusted
|
|
2788
|
-
* });
|
|
2789
|
-
* ```
|
|
2825
|
+
/**
|
|
2826
|
+
* This event is fired when a user holds an element on the screen of the device.
|
|
2827
|
+
* @ko 사용자가 기기의 화면에 손을 대고 있을 때 발생하는 이벤트
|
|
2828
|
+
* @event Axes#hold
|
|
2829
|
+
* @type {object}
|
|
2830
|
+
* @property {Object.<string, number>} pos coordinate <ko>좌표 정보</ko>
|
|
2831
|
+
* @property {Object} input The instance of inputType where the event occurred<ko>이벤트가 발생한 inputType 인스턴스</ko>
|
|
2832
|
+
* @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
|
|
2833
|
+
* @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>
|
|
2834
|
+
*
|
|
2835
|
+
* @example
|
|
2836
|
+
* ```js
|
|
2837
|
+
* const axes = new eg.Axes({
|
|
2838
|
+
* "x": {
|
|
2839
|
+
* range: [0, 100]
|
|
2840
|
+
* },
|
|
2841
|
+
* "zoom": {
|
|
2842
|
+
* range: [50, 30]
|
|
2843
|
+
* }
|
|
2844
|
+
* }).on("hold", function(event) {
|
|
2845
|
+
* // event.pos
|
|
2846
|
+
* // event.input
|
|
2847
|
+
* // event.inputEvent
|
|
2848
|
+
* // isTrusted
|
|
2849
|
+
* });
|
|
2850
|
+
* ```
|
|
2790
2851
|
*/
|
|
2791
2852
|
|
|
2792
2853
|
|
|
@@ -2802,80 +2863,80 @@ version: 4.10.5-beta.0
|
|
|
2802
2863
|
isTrusted: true
|
|
2803
2864
|
}));
|
|
2804
2865
|
};
|
|
2805
|
-
/**
|
|
2806
|
-
* Specifies the coordinates to move after the 'change' event. It works when the holding value of the change event is true.
|
|
2807
|
-
* @ko 'change' 이벤트 이후 이동할 좌표를 지정한다. change이벤트의 holding 값이 true일 경우에 동작한다
|
|
2808
|
-
* @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
2809
|
-
* @example
|
|
2810
|
-
* ```js
|
|
2811
|
-
* const axes = new eg.Axes({
|
|
2812
|
-
* "x": {
|
|
2813
|
-
* range: [0, 100]
|
|
2814
|
-
* },
|
|
2815
|
-
* "zoom": {
|
|
2816
|
-
* range: [50, 30]
|
|
2817
|
-
* }
|
|
2818
|
-
* }).on("change", function(event) {
|
|
2819
|
-
* event.holding && event.set({x: 10});
|
|
2820
|
-
* });
|
|
2821
|
-
* ```
|
|
2866
|
+
/**
|
|
2867
|
+
* Specifies the coordinates to move after the 'change' event. It works when the holding value of the change event is true.
|
|
2868
|
+
* @ko 'change' 이벤트 이후 이동할 좌표를 지정한다. change이벤트의 holding 값이 true일 경우에 동작한다
|
|
2869
|
+
* @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
2870
|
+
* @example
|
|
2871
|
+
* ```js
|
|
2872
|
+
* const axes = new eg.Axes({
|
|
2873
|
+
* "x": {
|
|
2874
|
+
* range: [0, 100]
|
|
2875
|
+
* },
|
|
2876
|
+
* "zoom": {
|
|
2877
|
+
* range: [50, 30]
|
|
2878
|
+
* }
|
|
2879
|
+
* }).on("change", function(event) {
|
|
2880
|
+
* event.holding && event.set({x: 10});
|
|
2881
|
+
* });
|
|
2882
|
+
* ```
|
|
2822
2883
|
*/
|
|
2823
2884
|
|
|
2824
|
-
/** Specifies the animation coordinates to move after the 'release' or 'animationStart' events.
|
|
2825
|
-
* @ko 'release' 또는 'animationStart' 이벤트 이후 이동할 좌표를 지정한다.
|
|
2826
|
-
* @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
2827
|
-
* @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
|
|
2828
|
-
* @example
|
|
2829
|
-
* ```js
|
|
2830
|
-
* const axes = new eg.Axes({
|
|
2831
|
-
* "x": {
|
|
2832
|
-
* range: [0, 100]
|
|
2833
|
-
* },
|
|
2834
|
-
* "zoom": {
|
|
2835
|
-
* range: [50, 30]
|
|
2836
|
-
* }
|
|
2837
|
-
* }).on("animationStart", function(event) {
|
|
2838
|
-
* event.setTo({x: 10}, 2000);
|
|
2839
|
-
* });
|
|
2840
|
-
* ```
|
|
2885
|
+
/** Specifies the animation coordinates to move after the 'release' or 'animationStart' events.
|
|
2886
|
+
* @ko 'release' 또는 'animationStart' 이벤트 이후 이동할 좌표를 지정한다.
|
|
2887
|
+
* @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
2888
|
+
* @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
|
|
2889
|
+
* @example
|
|
2890
|
+
* ```js
|
|
2891
|
+
* const axes = new eg.Axes({
|
|
2892
|
+
* "x": {
|
|
2893
|
+
* range: [0, 100]
|
|
2894
|
+
* },
|
|
2895
|
+
* "zoom": {
|
|
2896
|
+
* range: [50, 30]
|
|
2897
|
+
* }
|
|
2898
|
+
* }).on("animationStart", function(event) {
|
|
2899
|
+
* event.setTo({x: 10}, 2000);
|
|
2900
|
+
* });
|
|
2901
|
+
* ```
|
|
2841
2902
|
*/
|
|
2842
2903
|
|
|
2843
|
-
/**
|
|
2844
|
-
* This event is fired when a user release an element on the screen of the device.
|
|
2845
|
-
* @ko 사용자가 기기의 화면에서 손을 뗐을 때 발생하는 이벤트
|
|
2846
|
-
* @event Axes#release
|
|
2847
|
-
* @type {object}
|
|
2848
|
-
* @property {Object.<string, number>} depaPos The coordinates when releasing an element<ko>손을 뗐을 때의 좌표 </ko>
|
|
2849
|
-
* @property {Object.<string, number>} destPos The coordinates to move to after releasing an element<ko>손을 뗀 뒤에 이동할 좌표</ko>
|
|
2850
|
-
* @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
|
|
2851
|
-
* @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>
|
|
2852
|
-
* @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
|
|
2853
|
-
* @property {Object} input The instance of inputType where the event occurred<ko>이벤트가 발생한 inputType 인스턴스</ko>
|
|
2854
|
-
* @property {setTo} setTo Specifies the animation coordinates to move after the event <ko>이벤트 이후 이동할 애니메이션 좌표를 지정한다</ko>
|
|
2855
|
-
* @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>
|
|
2856
|
-
*
|
|
2857
|
-
* @example
|
|
2858
|
-
* ```js
|
|
2859
|
-
* const axes = new eg.Axes({
|
|
2860
|
-
* "x": {
|
|
2861
|
-
* range: [0, 100]
|
|
2862
|
-
* },
|
|
2863
|
-
* "zoom": {
|
|
2864
|
-
* range: [50, 30]
|
|
2865
|
-
* }
|
|
2866
|
-
* }).on("release", function(event) {
|
|
2867
|
-
* // event.depaPos
|
|
2868
|
-
* // event.destPos
|
|
2869
|
-
* // event.delta
|
|
2870
|
-
* // event.input
|
|
2871
|
-
* // event.inputEvent
|
|
2872
|
-
* // event.setTo
|
|
2873
|
-
* // event.isTrusted
|
|
2874
|
-
*
|
|
2875
|
-
* // if you want to change the animation coordinates to move after the 'release' event.
|
|
2876
|
-
* event.setTo({x: 10}, 2000);
|
|
2877
|
-
* });
|
|
2878
|
-
* ```
|
|
2904
|
+
/**
|
|
2905
|
+
* This event is fired when a user release an element on the screen of the device.
|
|
2906
|
+
* @ko 사용자가 기기의 화면에서 손을 뗐을 때 발생하는 이벤트
|
|
2907
|
+
* @event Axes#release
|
|
2908
|
+
* @type {object}
|
|
2909
|
+
* @property {Object.<string, number>} depaPos The coordinates when releasing an element<ko>손을 뗐을 때의 좌표 </ko>
|
|
2910
|
+
* @property {Object.<string, number>} destPos The coordinates to move to after releasing an element<ko>손을 뗀 뒤에 이동할 좌표</ko>
|
|
2911
|
+
* @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
|
|
2912
|
+
* @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>
|
|
2913
|
+
* @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
|
|
2914
|
+
* @property {Object} input The instance of inputType where the event occurred<ko>이벤트가 발생한 inputType 인스턴스</ko>
|
|
2915
|
+
* @property {setTo} setTo Specifies the animation coordinates to move after the event <ko>이벤트 이후 이동할 애니메이션 좌표를 지정한다</ko>
|
|
2916
|
+
* @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>
|
|
2917
|
+
*
|
|
2918
|
+
* @example
|
|
2919
|
+
* ```js
|
|
2920
|
+
* const axes = new eg.Axes({
|
|
2921
|
+
* "x": {
|
|
2922
|
+
* range: [0, 100]
|
|
2923
|
+
* },
|
|
2924
|
+
* "zoom": {
|
|
2925
|
+
* range: [50, 30]
|
|
2926
|
+
* }
|
|
2927
|
+
* }).on("release", function(event) {
|
|
2928
|
+
* // event.depaPos
|
|
2929
|
+
* // event.destPos
|
|
2930
|
+
* // event.delta
|
|
2931
|
+
* // event.input
|
|
2932
|
+
* // event.inputEvent
|
|
2933
|
+
* // event.setTo
|
|
2934
|
+
* // event.isTrusted
|
|
2935
|
+
*
|
|
2936
|
+
* // if you want to change the animation coordinates to move after the 'release' event.
|
|
2937
|
+
* event.setTo({x: 10}, 2000);
|
|
2938
|
+
* });
|
|
2939
|
+
* ```
|
|
2879
2940
|
*/
|
|
2880
2941
|
|
|
2881
2942
|
|
|
@@ -2892,43 +2953,43 @@ version: 4.10.5-beta.0
|
|
|
2892
2953
|
bounceRatio: this._getBounceRatio(roundPos)
|
|
2893
2954
|
})));
|
|
2894
2955
|
};
|
|
2895
|
-
/**
|
|
2896
|
-
* This event is fired when coordinate changes.
|
|
2897
|
-
* @ko 좌표가 변경됐을 때 발생하는 이벤트
|
|
2898
|
-
* @event Axes#change
|
|
2899
|
-
* @type {object}
|
|
2900
|
-
* @property {Object.<string, number>} pos The coordinate <ko>좌표</ko>
|
|
2901
|
-
* @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
|
|
2902
|
-
* @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>
|
|
2903
|
-
* @property {Boolean} holding Indicates whether a user holds an element on the screen of the device.<ko>사용자가 기기의 화면을 누르고 있는지 여부</ko>
|
|
2904
|
-
* @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>
|
|
2905
|
-
* @property {Object} inputEvent The event object received from inputType. If the value is changed by animation, it returns 'null'.<ko>inputType으로 부터 받은 이벤트 객체. 애니메이션에 의해 값이 변경될 경우에는 'null'을 반환한다.</ko>
|
|
2906
|
-
* @property {set} set Specifies the coordinates to move after the event. It works when the holding value is true <ko>이벤트 이후 이동할 좌표를 지정한다. holding 값이 true일 경우에 동작한다.</ko>
|
|
2907
|
-
* @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>
|
|
2908
|
-
*
|
|
2909
|
-
* @example
|
|
2910
|
-
* ```js
|
|
2911
|
-
* const axes = new eg.Axes({
|
|
2912
|
-
* "x": {
|
|
2913
|
-
* range: [0, 100]
|
|
2914
|
-
* },
|
|
2915
|
-
* "zoom": {
|
|
2916
|
-
* range: [50, 30]
|
|
2917
|
-
* }
|
|
2918
|
-
* }).on("change", function(event) {
|
|
2919
|
-
* // event.pos
|
|
2920
|
-
* // event.delta
|
|
2921
|
-
* // event.input
|
|
2922
|
-
* // event.inputEvent
|
|
2923
|
-
* // event.holding
|
|
2924
|
-
* // event.set
|
|
2925
|
-
* // event.isTrusted
|
|
2926
|
-
*
|
|
2927
|
-
* // if you want to change the coordinates to move after the 'change' event.
|
|
2928
|
-
* // it works when the holding value of the change event is true.
|
|
2929
|
-
* event.holding && event.set({x: 10});
|
|
2930
|
-
* });
|
|
2931
|
-
* ```
|
|
2956
|
+
/**
|
|
2957
|
+
* This event is fired when coordinate changes.
|
|
2958
|
+
* @ko 좌표가 변경됐을 때 발생하는 이벤트
|
|
2959
|
+
* @event Axes#change
|
|
2960
|
+
* @type {object}
|
|
2961
|
+
* @property {Object.<string, number>} pos The coordinate <ko>좌표</ko>
|
|
2962
|
+
* @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
|
|
2963
|
+
* @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>
|
|
2964
|
+
* @property {Boolean} holding Indicates whether a user holds an element on the screen of the device.<ko>사용자가 기기의 화면을 누르고 있는지 여부</ko>
|
|
2965
|
+
* @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>
|
|
2966
|
+
* @property {Object} inputEvent The event object received from inputType. If the value is changed by animation, it returns 'null'.<ko>inputType으로 부터 받은 이벤트 객체. 애니메이션에 의해 값이 변경될 경우에는 'null'을 반환한다.</ko>
|
|
2967
|
+
* @property {set} set Specifies the coordinates to move after the event. It works when the holding value is true <ko>이벤트 이후 이동할 좌표를 지정한다. holding 값이 true일 경우에 동작한다.</ko>
|
|
2968
|
+
* @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>
|
|
2969
|
+
*
|
|
2970
|
+
* @example
|
|
2971
|
+
* ```js
|
|
2972
|
+
* const axes = new eg.Axes({
|
|
2973
|
+
* "x": {
|
|
2974
|
+
* range: [0, 100]
|
|
2975
|
+
* },
|
|
2976
|
+
* "zoom": {
|
|
2977
|
+
* range: [50, 30]
|
|
2978
|
+
* }
|
|
2979
|
+
* }).on("change", function(event) {
|
|
2980
|
+
* // event.pos
|
|
2981
|
+
* // event.delta
|
|
2982
|
+
* // event.input
|
|
2983
|
+
* // event.inputEvent
|
|
2984
|
+
* // event.holding
|
|
2985
|
+
* // event.set
|
|
2986
|
+
* // event.isTrusted
|
|
2987
|
+
*
|
|
2988
|
+
* // if you want to change the coordinates to move after the 'change' event.
|
|
2989
|
+
* // it works when the holding value of the change event is true.
|
|
2990
|
+
* event.holding && event.set({x: 10});
|
|
2991
|
+
* });
|
|
2992
|
+
* ```
|
|
2932
2993
|
*/
|
|
2933
2994
|
|
|
2934
2995
|
|
|
@@ -2975,42 +3036,42 @@ version: 4.10.5-beta.0
|
|
|
2975
3036
|
|
|
2976
3037
|
return !event.isCanceled();
|
|
2977
3038
|
};
|
|
2978
|
-
/**
|
|
2979
|
-
* This event is fired when animation starts.
|
|
2980
|
-
* @ko 에니메이션이 시작할 때 발생한다.
|
|
2981
|
-
* @event Axes#animationStart
|
|
2982
|
-
* @type {object}
|
|
2983
|
-
* @property {Object.<string, number>} depaPos The coordinates when animation starts<ko>애니메이션이 시작 되었을 때의 좌표 </ko>
|
|
2984
|
-
* @property {Object.<string, number>} destPos The coordinates to move to. If you change this value, you can run the animation<ko>이동할 좌표. 이값을 변경하여 애니메이션을 동작시킬수 있다</ko>
|
|
2985
|
-
* @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
|
|
2986
|
-
* @property {Number} duration Duration of the animation (unit: ms). If you change this value, you can control the animation duration time.<ko>애니메이션 진행 시간(단위: ms). 이값을 변경하여 애니메이션의 이동시간을 조절할 수 있다.</ko>
|
|
2987
|
-
* @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>
|
|
2988
|
-
* @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
|
|
2989
|
-
* @property {setTo} setTo Specifies the animation coordinates to move after the event <ko>이벤트 이후 이동할 애니메이션 좌표를 지정한다</ko>
|
|
2990
|
-
* @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>
|
|
2991
|
-
*
|
|
2992
|
-
* @example
|
|
2993
|
-
* ```js
|
|
2994
|
-
* const axes = new eg.Axes({
|
|
2995
|
-
* "x": {
|
|
2996
|
-
* range: [0, 100]
|
|
2997
|
-
* },
|
|
2998
|
-
* "zoom": {
|
|
2999
|
-
* range: [50, 30]
|
|
3000
|
-
* }
|
|
3001
|
-
* }).on("release", function(event) {
|
|
3002
|
-
* // event.depaPos
|
|
3003
|
-
* // event.destPos
|
|
3004
|
-
* // event.delta
|
|
3005
|
-
* // event.input
|
|
3006
|
-
* // event.inputEvent
|
|
3007
|
-
* // event.setTo
|
|
3008
|
-
* // event.isTrusted
|
|
3009
|
-
*
|
|
3010
|
-
* // if you want to change the animation coordinates to move after the 'animationStart' event.
|
|
3011
|
-
* event.setTo({x: 10}, 2000);
|
|
3012
|
-
* });
|
|
3013
|
-
* ```
|
|
3039
|
+
/**
|
|
3040
|
+
* This event is fired when animation starts.
|
|
3041
|
+
* @ko 에니메이션이 시작할 때 발생한다.
|
|
3042
|
+
* @event Axes#animationStart
|
|
3043
|
+
* @type {object}
|
|
3044
|
+
* @property {Object.<string, number>} depaPos The coordinates when animation starts<ko>애니메이션이 시작 되었을 때의 좌표 </ko>
|
|
3045
|
+
* @property {Object.<string, number>} destPos The coordinates to move to. If you change this value, you can run the animation<ko>이동할 좌표. 이값을 변경하여 애니메이션을 동작시킬수 있다</ko>
|
|
3046
|
+
* @property {Object.<string, number>} delta The movement variation of coordinate <ko>좌표의 변화량</ko>
|
|
3047
|
+
* @property {Number} duration Duration of the animation (unit: ms). If you change this value, you can control the animation duration time.<ko>애니메이션 진행 시간(단위: ms). 이값을 변경하여 애니메이션의 이동시간을 조절할 수 있다.</ko>
|
|
3048
|
+
* @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>
|
|
3049
|
+
* @property {Object} inputEvent The event object received from inputType <ko>inputType으로 부터 받은 이벤트 객체</ko>
|
|
3050
|
+
* @property {setTo} setTo Specifies the animation coordinates to move after the event <ko>이벤트 이후 이동할 애니메이션 좌표를 지정한다</ko>
|
|
3051
|
+
* @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>
|
|
3052
|
+
*
|
|
3053
|
+
* @example
|
|
3054
|
+
* ```js
|
|
3055
|
+
* const axes = new eg.Axes({
|
|
3056
|
+
* "x": {
|
|
3057
|
+
* range: [0, 100]
|
|
3058
|
+
* },
|
|
3059
|
+
* "zoom": {
|
|
3060
|
+
* range: [50, 30]
|
|
3061
|
+
* }
|
|
3062
|
+
* }).on("release", function(event) {
|
|
3063
|
+
* // event.depaPos
|
|
3064
|
+
* // event.destPos
|
|
3065
|
+
* // event.delta
|
|
3066
|
+
* // event.input
|
|
3067
|
+
* // event.inputEvent
|
|
3068
|
+
* // event.setTo
|
|
3069
|
+
* // event.isTrusted
|
|
3070
|
+
*
|
|
3071
|
+
* // if you want to change the animation coordinates to move after the 'animationStart' event.
|
|
3072
|
+
* event.setTo({x: 10}, 2000);
|
|
3073
|
+
* });
|
|
3074
|
+
* ```
|
|
3014
3075
|
*/
|
|
3015
3076
|
|
|
3016
3077
|
|
|
@@ -3028,26 +3089,26 @@ version: 4.10.5-beta.0
|
|
|
3028
3089
|
|
|
3029
3090
|
return !event.isCanceled();
|
|
3030
3091
|
};
|
|
3031
|
-
/**
|
|
3032
|
-
* This event is fired when animation ends.
|
|
3033
|
-
* @ko 에니메이션이 끝났을 때 발생한다.
|
|
3034
|
-
* @event Axes#animationEnd
|
|
3035
|
-
* @type {object}
|
|
3036
|
-
* @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>
|
|
3037
|
-
*
|
|
3038
|
-
* @example
|
|
3039
|
-
* ```js
|
|
3040
|
-
* const axes = new eg.Axes({
|
|
3041
|
-
* "x": {
|
|
3042
|
-
* range: [0, 100]
|
|
3043
|
-
* },
|
|
3044
|
-
* "zoom": {
|
|
3045
|
-
* range: [50, 30]
|
|
3046
|
-
* }
|
|
3047
|
-
* }).on("animationEnd", function(event) {
|
|
3048
|
-
* // event.isTrusted
|
|
3049
|
-
* });
|
|
3050
|
-
* ```
|
|
3092
|
+
/**
|
|
3093
|
+
* This event is fired when animation ends.
|
|
3094
|
+
* @ko 에니메이션이 끝났을 때 발생한다.
|
|
3095
|
+
* @event Axes#animationEnd
|
|
3096
|
+
* @type {object}
|
|
3097
|
+
* @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>
|
|
3098
|
+
*
|
|
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("animationEnd", function(event) {
|
|
3109
|
+
* // event.isTrusted
|
|
3110
|
+
* });
|
|
3111
|
+
* ```
|
|
3051
3112
|
*/
|
|
3052
3113
|
|
|
3053
3114
|
|
|
@@ -3060,26 +3121,26 @@ version: 4.10.5-beta.0
|
|
|
3060
3121
|
isTrusted: isTrusted
|
|
3061
3122
|
}));
|
|
3062
3123
|
};
|
|
3063
|
-
/**
|
|
3064
|
-
* This event is fired when all actions have been completed.
|
|
3065
|
-
* @ko 에니메이션이 끝났을 때 발생한다.
|
|
3066
|
-
* @event Axes#finish
|
|
3067
|
-
* @type {object}
|
|
3068
|
-
* @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>
|
|
3069
|
-
*
|
|
3070
|
-
* @example
|
|
3071
|
-
* ```js
|
|
3072
|
-
* const axes = new eg.Axes({
|
|
3073
|
-
* "x": {
|
|
3074
|
-
* range: [0, 100]
|
|
3075
|
-
* },
|
|
3076
|
-
* "zoom": {
|
|
3077
|
-
* range: [50, 30]
|
|
3078
|
-
* }
|
|
3079
|
-
* }).on("finish", function(event) {
|
|
3080
|
-
* // event.isTrusted
|
|
3081
|
-
* });
|
|
3082
|
-
* ```
|
|
3124
|
+
/**
|
|
3125
|
+
* This event is fired when all actions have been completed.
|
|
3126
|
+
* @ko 에니메이션이 끝났을 때 발생한다.
|
|
3127
|
+
* @event Axes#finish
|
|
3128
|
+
* @type {object}
|
|
3129
|
+
* @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>
|
|
3130
|
+
*
|
|
3131
|
+
* @example
|
|
3132
|
+
* ```js
|
|
3133
|
+
* const axes = new eg.Axes({
|
|
3134
|
+
* "x": {
|
|
3135
|
+
* range: [0, 100]
|
|
3136
|
+
* },
|
|
3137
|
+
* "zoom": {
|
|
3138
|
+
* range: [50, 30]
|
|
3139
|
+
* }
|
|
3140
|
+
* }).on("finish", function(event) {
|
|
3141
|
+
* // event.isTrusted
|
|
3142
|
+
* });
|
|
3143
|
+
* ```
|
|
3083
3144
|
*/
|
|
3084
3145
|
|
|
3085
3146
|
|
|
@@ -3179,9 +3240,9 @@ version: 4.10.5-beta.0
|
|
|
3179
3240
|
return InterruptManager;
|
|
3180
3241
|
}();
|
|
3181
3242
|
|
|
3182
|
-
/*
|
|
3183
|
-
* Copyright (c) 2015 NAVER Corp.
|
|
3184
|
-
* egjs projects are licensed under the MIT license
|
|
3243
|
+
/*
|
|
3244
|
+
* Copyright (c) 2015 NAVER Corp.
|
|
3245
|
+
* egjs projects are licensed under the MIT license
|
|
3185
3246
|
*/
|
|
3186
3247
|
var getInsidePosition = function (destPos, range, circular, bounce) {
|
|
3187
3248
|
var toDestPos = destPos;
|
|
@@ -3335,9 +3396,9 @@ version: 4.10.5-beta.0
|
|
|
3335
3396
|
|
|
3336
3397
|
this._complementOptions();
|
|
3337
3398
|
};
|
|
3338
|
-
/**
|
|
3339
|
-
* set up 'css' expression
|
|
3340
|
-
* @private
|
|
3399
|
+
/**
|
|
3400
|
+
* set up 'css' expression
|
|
3401
|
+
* @private
|
|
3341
3402
|
*/
|
|
3342
3403
|
|
|
3343
3404
|
|
|
@@ -3927,6 +3988,13 @@ version: 4.10.5-beta.0
|
|
|
3927
3988
|
|
|
3928
3989
|
return null;
|
|
3929
3990
|
};
|
|
3991
|
+
function getAddEventOptions(eventName) {
|
|
3992
|
+
// The passive default value of the touch event is true.
|
|
3993
|
+
// If not a touch event, return false to support ie11
|
|
3994
|
+
return eventName.indexOf("touch") > -1 ? {
|
|
3995
|
+
passive: false
|
|
3996
|
+
} : false;
|
|
3997
|
+
}
|
|
3930
3998
|
|
|
3931
3999
|
var InputObserver =
|
|
3932
4000
|
/*#__PURE__*/
|
|
@@ -3976,7 +4044,7 @@ version: 4.10.5-beta.0
|
|
|
3976
4044
|
this._moveDistance = this._axisManager.get(input.axes);
|
|
3977
4045
|
};
|
|
3978
4046
|
|
|
3979
|
-
__proto.change = function (input, event, offset, useAnimation
|
|
4047
|
+
__proto.change = function (input, event, offset, useAnimation) {
|
|
3980
4048
|
if (this._isStopped || !this._interruptManager.isInterrupting() || this._axisManager.every(offset, function (v) {
|
|
3981
4049
|
return v === 0;
|
|
3982
4050
|
})) {
|
|
@@ -3989,7 +4057,8 @@ version: 4.10.5-beta.0
|
|
|
3989
4057
|
return;
|
|
3990
4058
|
}
|
|
3991
4059
|
|
|
3992
|
-
var depaPos =
|
|
4060
|
+
var depaPos = this._moveDistance || this._axisManager.get(input.axes);
|
|
4061
|
+
|
|
3993
4062
|
var destPos; // for outside logic
|
|
3994
4063
|
|
|
3995
4064
|
destPos = map(depaPos, function (v, k) {
|
|
@@ -4024,7 +4093,9 @@ version: 4.10.5-beta.0
|
|
|
4024
4093
|
};
|
|
4025
4094
|
|
|
4026
4095
|
if (useAnimation) {
|
|
4027
|
-
this._animationManager.
|
|
4096
|
+
var duration = this._animationManager.getDuration(destPos, depaPos);
|
|
4097
|
+
|
|
4098
|
+
this._animationManager.animateTo(destPos, duration, changeOption);
|
|
4028
4099
|
} else {
|
|
4029
4100
|
var isCanceled = !this._eventManager.triggerChange(destPos, depaPos, changeOption, true);
|
|
4030
4101
|
|
|
@@ -4033,15 +4104,6 @@ version: 4.10.5-beta.0
|
|
|
4033
4104
|
this._moveDistance = null;
|
|
4034
4105
|
|
|
4035
4106
|
this._animationManager.finish(false);
|
|
4036
|
-
} else if (velocity) {
|
|
4037
|
-
var displacement = this._animationManager.getDisplacement(velocity);
|
|
4038
|
-
|
|
4039
|
-
var nextOffset_1 = toAxis(input.axes, displacement);
|
|
4040
|
-
destPos = this._atOutside(map(destPos, function (v, k) {
|
|
4041
|
-
return v + (nextOffset_1[k] || 0);
|
|
4042
|
-
}));
|
|
4043
|
-
|
|
4044
|
-
this._animationManager.changeTo(destPos, changeOption);
|
|
4045
4107
|
}
|
|
4046
4108
|
}
|
|
4047
4109
|
};
|
|
@@ -4089,7 +4151,6 @@ version: 4.10.5-beta.0
|
|
|
4089
4151
|
destPos: destPos,
|
|
4090
4152
|
duration: duration,
|
|
4091
4153
|
delta: this._axisManager.getDelta(depaPos, destPos),
|
|
4092
|
-
triggerAnimationEvent: true,
|
|
4093
4154
|
inputEvent: event,
|
|
4094
4155
|
input: input,
|
|
4095
4156
|
isTrusted: true
|
|
@@ -4141,7 +4202,7 @@ version: 4.10.5-beta.0
|
|
|
4141
4202
|
var out = opt.bounce;
|
|
4142
4203
|
var circular = opt.circular;
|
|
4143
4204
|
|
|
4144
|
-
if (circular
|
|
4205
|
+
if (circular[0] && v < min || circular[1] && v > max) {
|
|
4145
4206
|
return v;
|
|
4146
4207
|
} else if (v < min) {
|
|
4147
4208
|
// left
|
|
@@ -4228,11 +4289,14 @@ version: 4.10.5-beta.0
|
|
|
4228
4289
|
this.eventManager.triggerChange(pos, orgPos_1, option, !!option);
|
|
4229
4290
|
}
|
|
4230
4291
|
|
|
4231
|
-
|
|
4232
|
-
|
|
4292
|
+
this._animateParam = null;
|
|
4293
|
+
|
|
4294
|
+
if (this._raf) {
|
|
4295
|
+
cancelAnimationFrame(this._raf);
|
|
4233
4296
|
}
|
|
4234
4297
|
|
|
4235
|
-
this.
|
|
4298
|
+
this._raf = null;
|
|
4299
|
+
this.eventManager.triggerAnimationEnd(!!(option === null || option === void 0 ? void 0 : option.event));
|
|
4236
4300
|
}
|
|
4237
4301
|
};
|
|
4238
4302
|
|
|
@@ -4293,30 +4357,6 @@ version: 4.10.5-beta.0
|
|
|
4293
4357
|
return userWish;
|
|
4294
4358
|
};
|
|
4295
4359
|
|
|
4296
|
-
__proto.changeTo = function (destPos, option) {
|
|
4297
|
-
var _this = this;
|
|
4298
|
-
|
|
4299
|
-
var depaPos = this.axisManager.get(option.input.axes);
|
|
4300
|
-
|
|
4301
|
-
if (this._raf) {
|
|
4302
|
-
cancelAnimationFrame(this._raf);
|
|
4303
|
-
}
|
|
4304
|
-
|
|
4305
|
-
if (!equal(destPos, depaPos)) {
|
|
4306
|
-
var newParam = {
|
|
4307
|
-
depaPos: depaPos,
|
|
4308
|
-
destPos: destPos,
|
|
4309
|
-
duration: this.getDuration(destPos, depaPos),
|
|
4310
|
-
delta: this.axisManager.getDelta(depaPos, destPos),
|
|
4311
|
-
triggerAnimationEvent: false
|
|
4312
|
-
};
|
|
4313
|
-
|
|
4314
|
-
this._animateLoop(newParam, function () {
|
|
4315
|
-
return _this._removeAnimationParam();
|
|
4316
|
-
});
|
|
4317
|
-
}
|
|
4318
|
-
};
|
|
4319
|
-
|
|
4320
4360
|
__proto.animateTo = function (destPos, duration, option) {
|
|
4321
4361
|
var _this = this;
|
|
4322
4362
|
|
|
@@ -4344,7 +4384,6 @@ version: 4.10.5-beta.0
|
|
|
4344
4384
|
destPos: userWish.destPos,
|
|
4345
4385
|
duration: userWish.duration,
|
|
4346
4386
|
delta: this.axisManager.getDelta(depaPos, userWish.destPos),
|
|
4347
|
-
triggerAnimationEvent: true,
|
|
4348
4387
|
isTrusted: !!inputEvent,
|
|
4349
4388
|
inputEvent: inputEvent,
|
|
4350
4389
|
input: (option === null || option === void 0 ? void 0 : option.input) || null
|
|
@@ -4420,7 +4459,6 @@ version: 4.10.5-beta.0
|
|
|
4420
4459
|
destPos: destPos,
|
|
4421
4460
|
duration: clamp(duration, this._options.minimumDuration, this._options.maximumDuration),
|
|
4422
4461
|
delta: this.axisManager.getDelta(depaPos, destPos),
|
|
4423
|
-
triggerAnimationEvent: true,
|
|
4424
4462
|
inputEvent: inputEvent,
|
|
4425
4463
|
input: (option === null || option === void 0 ? void 0 : option.input) || null,
|
|
4426
4464
|
isTrusted: !!inputEvent,
|
|
@@ -4428,16 +4466,6 @@ version: 4.10.5-beta.0
|
|
|
4428
4466
|
};
|
|
4429
4467
|
};
|
|
4430
4468
|
|
|
4431
|
-
__proto._removeAnimationParam = function () {
|
|
4432
|
-
this._animateParam = null;
|
|
4433
|
-
|
|
4434
|
-
if (this._raf) {
|
|
4435
|
-
cancelAnimationFrame(this._raf);
|
|
4436
|
-
}
|
|
4437
|
-
|
|
4438
|
-
this._raf = null;
|
|
4439
|
-
};
|
|
4440
|
-
|
|
4441
4469
|
__proto._animateLoop = function (param, complete) {
|
|
4442
4470
|
var _this = this;
|
|
4443
4471
|
|
|
@@ -4482,15 +4510,15 @@ version: 4.10.5-beta.0
|
|
|
4482
4510
|
complete();
|
|
4483
4511
|
}
|
|
4484
4512
|
};
|
|
4485
|
-
/**
|
|
4486
|
-
* Get estimated final value.
|
|
4487
|
-
*
|
|
4488
|
-
* If destPos is within the 'error range' of the original intended position, the initial intended position is returned.
|
|
4489
|
-
* - eg. original intended pos: 100, destPos: 100.0000000004 ==> return 100;
|
|
4490
|
-
* 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.
|
|
4491
|
-
* - eg. original intended pos: 100.123 destPos: 50.12345 => return 50.123
|
|
4492
|
-
* @param originalIntendedPos
|
|
4493
|
-
* @param destPos
|
|
4513
|
+
/**
|
|
4514
|
+
* Get estimated final value.
|
|
4515
|
+
*
|
|
4516
|
+
* If destPos is within the 'error range' of the original intended position, the initial intended position is returned.
|
|
4517
|
+
* - eg. original intended pos: 100, destPos: 100.0000000004 ==> return 100;
|
|
4518
|
+
* 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.
|
|
4519
|
+
* - eg. original intended pos: 100.123 destPos: 50.12345 => return 50.123
|
|
4520
|
+
* @param originalIntendedPos
|
|
4521
|
+
* @param destPos
|
|
4494
4522
|
*/
|
|
4495
4523
|
|
|
4496
4524
|
|
|
@@ -4647,116 +4675,116 @@ version: 4.10.5-beta.0
|
|
|
4647
4675
|
return EasingManager;
|
|
4648
4676
|
}(AnimationManager);
|
|
4649
4677
|
|
|
4650
|
-
/**
|
|
4651
|
-
* @typedef {Object} AxisOption The Axis information. The key of the axis specifies the name to use as the logical virtual coordinate system.
|
|
4652
|
-
* @ko 축 정보. 축의 키는 논리적인 가상 좌표계로 사용할 이름을 지정한다.
|
|
4653
|
-
* @param {Number[]} [range] The range of coordinate <ko>좌표 범위</ko>
|
|
4654
|
-
* @param {Number} [range[0]=0] The coordinate of the minimum <ko>최소 좌표</ko>
|
|
4655
|
-
* @param {Number} [range[1]=0] The coordinate of the maximum <ko>최대 좌표</ko>
|
|
4656
|
-
* @param {Number} [startPos=range[0]] The coordinates to be moved when creating an instance <ko>인스턴스 생성시 이동할 좌표</ko>
|
|
4657
|
-
* @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>
|
|
4658
|
-
* @param {Number} [bounce[0]=0] The size of coordinate of the minimum area <ko>최소 좌표 바운스 영역의 크기</ko>
|
|
4659
|
-
* @param {Number} [bounce[1]=0] The size of coordinate of the maximum area <ko>최대 좌표 바운스 영역의 크기</ko>
|
|
4660
|
-
* @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>
|
|
4661
|
-
* @param {Boolean} [circular[0]=false] Indicates whether to circulate to the coordinate of the minimum <ko>최소 좌표 방향의 순환 여부</ko>
|
|
4662
|
-
* @param {Boolean} [circular[1]=false] Indicates whether to circulate to the coordinate of the maximum <ko>최대 좌표 방향의 순환 여부</ko>
|
|
4678
|
+
/**
|
|
4679
|
+
* @typedef {Object} AxisOption The Axis information. The key of the axis specifies the name to use as the logical virtual coordinate system.
|
|
4680
|
+
* @ko 축 정보. 축의 키는 논리적인 가상 좌표계로 사용할 이름을 지정한다.
|
|
4681
|
+
* @param {Number[]} [range] The range of coordinate <ko>좌표 범위</ko>
|
|
4682
|
+
* @param {Number} [range[0]=0] The coordinate of the minimum <ko>최소 좌표</ko>
|
|
4683
|
+
* @param {Number} [range[1]=0] The coordinate of the maximum <ko>최대 좌표</ko>
|
|
4684
|
+
* @param {Number} [startPos=range[0]] The coordinates to be moved when creating an instance <ko>인스턴스 생성시 이동할 좌표</ko>
|
|
4685
|
+
* @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>
|
|
4686
|
+
* @param {Number} [bounce[0]=0] The size of coordinate of the minimum area <ko>최소 좌표 바운스 영역의 크기</ko>
|
|
4687
|
+
* @param {Number} [bounce[1]=0] The size of coordinate of the maximum area <ko>최대 좌표 바운스 영역의 크기</ko>
|
|
4688
|
+
* @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>
|
|
4689
|
+
* @param {Boolean} [circular[0]=false] Indicates whether to circulate to the coordinate of the minimum <ko>최소 좌표 방향의 순환 여부</ko>
|
|
4690
|
+
* @param {Boolean} [circular[1]=false] Indicates whether to circulate to the coordinate of the maximum <ko>최대 좌표 방향의 순환 여부</ko>
|
|
4663
4691
|
**/
|
|
4664
4692
|
|
|
4665
|
-
/**
|
|
4666
|
-
* @typedef {Object} AxesOption The option object of the eg.Axes module
|
|
4667
|
-
* @ko eg.Axes 모듈의 옵션 객체
|
|
4668
|
-
* @param {Function} [easing=easing.easeOutCubic] The easing function to apply to an animation <ko>애니메이션에 적용할 easing 함수</ko>
|
|
4669
|
-
* @param {Number} [maximumDuration=Infinity] Maximum duration of the animation <ko>가속도에 의해 애니메이션이 동작할 때의 최대 좌표 이동 시간</ko>
|
|
4670
|
-
* @param {Number} [minimumDuration=0] Minimum duration of the animation <ko>가속도에 의해 애니메이션이 동작할 때의 최소 좌표 이동 시간</ko>
|
|
4671
|
-
* @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>
|
|
4672
|
-
* @param {Boolean} [interruptable=true] Indicates whether an animation is interruptible.
|
|
4673
|
-
* - true: It can be paused or stopped by user action or the API.
|
|
4674
|
-
* - false: It cannot be paused or stopped by user action or the API while it is running.
|
|
4675
|
-
* <ko>진행 중인 애니메이션 중지 가능 여부.
|
|
4676
|
-
* - true: 사용자의 동작이나 API로 애니메이션을 중지할 수 있다.
|
|
4677
|
-
* - false: 애니메이션이 진행 중일 때는 사용자의 동작이나 API가 적용되지 않는다</ko>
|
|
4678
|
-
* @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)
|
|
4679
|
-
* [Details](https://github.com/naver/egjs-axes/wiki/round-option)<ko>반올림 단위. 예를 들어 0.1 은 소숫점 0.1 까지 반올림(6.1234 => 6.1), 5 는 5 단위로 반올림(93 => 95).
|
|
4680
|
-
* [상세내용](https://github.com/naver/egjs-axes/wiki/round-option)</ko>
|
|
4681
|
-
* @param {Boolean} [nested=false] Whether the event propagates to other instances when the coordinates reach the end of the movable area <ko>좌표가 이동 가능한 영역의 끝까지 도달했을 때 다른 인스턴스들로의 이벤트 전파 여부</ko>
|
|
4693
|
+
/**
|
|
4694
|
+
* @typedef {Object} AxesOption The option object of the eg.Axes module
|
|
4695
|
+
* @ko eg.Axes 모듈의 옵션 객체
|
|
4696
|
+
* @param {Function} [easing=easing.easeOutCubic] The easing function to apply to an animation <ko>애니메이션에 적용할 easing 함수</ko>
|
|
4697
|
+
* @param {Number} [maximumDuration=Infinity] Maximum duration of the animation <ko>가속도에 의해 애니메이션이 동작할 때의 최대 좌표 이동 시간</ko>
|
|
4698
|
+
* @param {Number} [minimumDuration=0] Minimum duration of the animation <ko>가속도에 의해 애니메이션이 동작할 때의 최소 좌표 이동 시간</ko>
|
|
4699
|
+
* @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>
|
|
4700
|
+
* @param {Boolean} [interruptable=true] Indicates whether an animation is interruptible.
|
|
4701
|
+
* - true: It can be paused or stopped by user action or the API.
|
|
4702
|
+
* - false: It cannot be paused or stopped by user action or the API while it is running.
|
|
4703
|
+
* <ko>진행 중인 애니메이션 중지 가능 여부.
|
|
4704
|
+
* - true: 사용자의 동작이나 API로 애니메이션을 중지할 수 있다.
|
|
4705
|
+
* - false: 애니메이션이 진행 중일 때는 사용자의 동작이나 API가 적용되지 않는다</ko>
|
|
4706
|
+
* @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)
|
|
4707
|
+
* [Details](https://github.com/naver/egjs-axes/wiki/round-option)<ko>반올림 단위. 예를 들어 0.1 은 소숫점 0.1 까지 반올림(6.1234 => 6.1), 5 는 5 단위로 반올림(93 => 95).
|
|
4708
|
+
* [상세내용](https://github.com/naver/egjs-axes/wiki/round-option)</ko>
|
|
4709
|
+
* @param {Boolean} [nested=false] Whether the event propagates to other instances when the coordinates reach the end of the movable area <ko>좌표가 이동 가능한 영역의 끝까지 도달했을 때 다른 인스턴스들로의 이벤트 전파 여부</ko>
|
|
4682
4710
|
**/
|
|
4683
4711
|
|
|
4684
|
-
/**
|
|
4685
|
-
* 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.
|
|
4686
|
-
* @ko 터치 입력 장치나 마우스와 같은 다양한 입력 장치를 통해 전달 받은 사용자의 동작을 논리적인 가상 좌표로 변경하는 모듈이다. 사용자 동작에 반응하는 UI를 손쉽게 만들수 있다.
|
|
4687
|
-
* @extends eg.Component
|
|
4688
|
-
*
|
|
4689
|
-
* @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>
|
|
4690
|
-
* @param {AxesOption} [options={}] The option object of the eg.Axes module<ko>eg.Axes 모듈의 옵션 객체</ko>
|
|
4691
|
-
* @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>
|
|
4692
|
-
*
|
|
4693
|
-
* @support {"ie": "10+", "ch" : "latest", "ff" : "latest", "sf" : "latest", "edge" : "latest", "ios" : "7+", "an" : "2.3+ (except 3.x)"}
|
|
4694
|
-
* @example
|
|
4695
|
-
* ```js
|
|
4696
|
-
* // 1. Initialize eg.Axes
|
|
4697
|
-
* const axes = new eg.Axes({
|
|
4698
|
-
* something1: {
|
|
4699
|
-
* range: [0, 150],
|
|
4700
|
-
* bounce: 50
|
|
4701
|
-
* },
|
|
4702
|
-
* something2: {
|
|
4703
|
-
* range: [0, 200],
|
|
4704
|
-
* bounce: 100
|
|
4705
|
-
* },
|
|
4706
|
-
* somethingN: {
|
|
4707
|
-
* range: [1, 10],
|
|
4708
|
-
* }
|
|
4709
|
-
* }, {
|
|
4710
|
-
* deceleration : 0.0024
|
|
4711
|
-
* });
|
|
4712
|
-
*
|
|
4713
|
-
* // 2. attach event handler
|
|
4714
|
-
* axes.on({
|
|
4715
|
-
* "hold" : function(evt) {
|
|
4716
|
-
* },
|
|
4717
|
-
* "release" : function(evt) {
|
|
4718
|
-
* },
|
|
4719
|
-
* "animationStart" : function(evt) {
|
|
4720
|
-
* },
|
|
4721
|
-
* "animationEnd" : function(evt) {
|
|
4722
|
-
* },
|
|
4723
|
-
* "change" : function(evt) {
|
|
4724
|
-
* }
|
|
4725
|
-
* });
|
|
4726
|
-
*
|
|
4727
|
-
* // 3. Initialize inputTypes
|
|
4728
|
-
* const panInputArea = new eg.Axes.PanInput("#area", {
|
|
4729
|
-
* scale: [0.5, 1]
|
|
4730
|
-
* });
|
|
4731
|
-
* const panInputHmove = new eg.Axes.PanInput("#hmove");
|
|
4732
|
-
* const panInputVmove = new eg.Axes.PanInput("#vmove");
|
|
4733
|
-
* const pinchInputArea = new eg.Axes.PinchInput("#area", {
|
|
4734
|
-
* scale: 1.5
|
|
4735
|
-
* });
|
|
4736
|
-
*
|
|
4737
|
-
* // 4. Connect eg.Axes and InputTypes
|
|
4738
|
-
* // [PanInput] When the mouse or touchscreen is down and moved.
|
|
4739
|
-
* // Connect the 'something2' axis to the mouse or touchscreen x position and
|
|
4740
|
-
* // connect the 'somethingN' axis to the mouse or touchscreen y position.
|
|
4741
|
-
* axes.connect(["something2", "somethingN"], panInputArea); // or axes.connect("something2 somethingN", panInputArea);
|
|
4742
|
-
*
|
|
4743
|
-
* // Connect only one 'something1' axis to the mouse or touchscreen x position.
|
|
4744
|
-
* axes.connect(["something1"], panInputHmove); // or axes.connect("something1", panInputHmove);
|
|
4745
|
-
*
|
|
4746
|
-
* // Connect only one 'something2' axis to the mouse or touchscreen y position.
|
|
4747
|
-
* axes.connect(["", "something2"], panInputVmove); // or axes.connect(" something2", panInputVmove);
|
|
4748
|
-
*
|
|
4749
|
-
* // [PinchInput] Connect 'something2' axis when two pointers are moving toward (zoom-in) or away from each other (zoom-out).
|
|
4750
|
-
* axes.connect("something2", pinchInputArea);
|
|
4751
|
-
* ```
|
|
4712
|
+
/**
|
|
4713
|
+
* 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.
|
|
4714
|
+
* @ko 터치 입력 장치나 마우스와 같은 다양한 입력 장치를 통해 전달 받은 사용자의 동작을 논리적인 가상 좌표로 변경하는 모듈이다. 사용자 동작에 반응하는 UI를 손쉽게 만들수 있다.
|
|
4715
|
+
* @extends eg.Component
|
|
4716
|
+
*
|
|
4717
|
+
* @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>
|
|
4718
|
+
* @param {AxesOption} [options={}] The option object of the eg.Axes module<ko>eg.Axes 모듈의 옵션 객체</ko>
|
|
4719
|
+
* @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>
|
|
4720
|
+
*
|
|
4721
|
+
* @support {"ie": "10+", "ch" : "latest", "ff" : "latest", "sf" : "latest", "edge" : "latest", "ios" : "7+", "an" : "2.3+ (except 3.x)"}
|
|
4722
|
+
* @example
|
|
4723
|
+
* ```js
|
|
4724
|
+
* // 1. Initialize eg.Axes
|
|
4725
|
+
* const axes = new eg.Axes({
|
|
4726
|
+
* something1: {
|
|
4727
|
+
* range: [0, 150],
|
|
4728
|
+
* bounce: 50
|
|
4729
|
+
* },
|
|
4730
|
+
* something2: {
|
|
4731
|
+
* range: [0, 200],
|
|
4732
|
+
* bounce: 100
|
|
4733
|
+
* },
|
|
4734
|
+
* somethingN: {
|
|
4735
|
+
* range: [1, 10],
|
|
4736
|
+
* }
|
|
4737
|
+
* }, {
|
|
4738
|
+
* deceleration : 0.0024
|
|
4739
|
+
* });
|
|
4740
|
+
*
|
|
4741
|
+
* // 2. attach event handler
|
|
4742
|
+
* axes.on({
|
|
4743
|
+
* "hold" : function(evt) {
|
|
4744
|
+
* },
|
|
4745
|
+
* "release" : function(evt) {
|
|
4746
|
+
* },
|
|
4747
|
+
* "animationStart" : function(evt) {
|
|
4748
|
+
* },
|
|
4749
|
+
* "animationEnd" : function(evt) {
|
|
4750
|
+
* },
|
|
4751
|
+
* "change" : function(evt) {
|
|
4752
|
+
* }
|
|
4753
|
+
* });
|
|
4754
|
+
*
|
|
4755
|
+
* // 3. Initialize inputTypes
|
|
4756
|
+
* const panInputArea = new eg.Axes.PanInput("#area", {
|
|
4757
|
+
* scale: [0.5, 1]
|
|
4758
|
+
* });
|
|
4759
|
+
* const panInputHmove = new eg.Axes.PanInput("#hmove");
|
|
4760
|
+
* const panInputVmove = new eg.Axes.PanInput("#vmove");
|
|
4761
|
+
* const pinchInputArea = new eg.Axes.PinchInput("#area", {
|
|
4762
|
+
* scale: 1.5
|
|
4763
|
+
* });
|
|
4764
|
+
*
|
|
4765
|
+
* // 4. Connect eg.Axes and InputTypes
|
|
4766
|
+
* // [PanInput] When the mouse or touchscreen is down and moved.
|
|
4767
|
+
* // Connect the 'something2' axis to the mouse or touchscreen x position and
|
|
4768
|
+
* // connect the 'somethingN' axis to the mouse or touchscreen y position.
|
|
4769
|
+
* axes.connect(["something2", "somethingN"], panInputArea); // or axes.connect("something2 somethingN", panInputArea);
|
|
4770
|
+
*
|
|
4771
|
+
* // Connect only one 'something1' axis to the mouse or touchscreen x position.
|
|
4772
|
+
* axes.connect(["something1"], panInputHmove); // or axes.connect("something1", panInputHmove);
|
|
4773
|
+
*
|
|
4774
|
+
* // Connect only one 'something2' axis to the mouse or touchscreen y position.
|
|
4775
|
+
* axes.connect(["", "something2"], panInputVmove); // or axes.connect(" something2", panInputVmove);
|
|
4776
|
+
*
|
|
4777
|
+
* // [PinchInput] Connect 'something2' axis when two pointers are moving toward (zoom-in) or away from each other (zoom-out).
|
|
4778
|
+
* axes.connect("something2", pinchInputArea);
|
|
4779
|
+
* ```
|
|
4752
4780
|
*/
|
|
4753
4781
|
|
|
4754
4782
|
var Axes =
|
|
4755
4783
|
/*#__PURE__*/
|
|
4756
4784
|
function (_super) {
|
|
4757
4785
|
__extends$1(Axes, _super);
|
|
4758
|
-
/**
|
|
4759
|
-
*
|
|
4786
|
+
/**
|
|
4787
|
+
*
|
|
4760
4788
|
*/
|
|
4761
4789
|
|
|
4762
4790
|
|
|
@@ -4803,30 +4831,30 @@ version: 4.10.5-beta.0
|
|
|
4803
4831
|
|
|
4804
4832
|
return _this;
|
|
4805
4833
|
}
|
|
4806
|
-
/**
|
|
4807
|
-
* Connect the axis of eg.Axes to the inputType.
|
|
4808
|
-
* @ko eg.Axes의 축과 inputType을 연결한다
|
|
4809
|
-
* @param {(String[]|String)} axes The name of the axis to associate with inputType <ko>inputType과 연결할 축의 이름</ko>
|
|
4810
|
-
* @param {Object} inputType The inputType instance to associate with the axis of eg.Axes <ko>eg.Axes의 축과 연결할 inputType 인스턴스</ko>
|
|
4811
|
-
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
4812
|
-
* @example
|
|
4813
|
-
* ```js
|
|
4814
|
-
* const axes = new eg.Axes({
|
|
4815
|
-
* "x": {
|
|
4816
|
-
* range: [0, 100]
|
|
4817
|
-
* },
|
|
4818
|
-
* "xOther": {
|
|
4819
|
-
* range: [-100, 100]
|
|
4820
|
-
* }
|
|
4821
|
-
* });
|
|
4822
|
-
*
|
|
4823
|
-
* axes.connect("x", new eg.Axes.PanInput("#area1"))
|
|
4824
|
-
* .connect("x xOther", new eg.Axes.PanInput("#area2"))
|
|
4825
|
-
* .connect(" xOther", new eg.Axes.PanInput("#area3"))
|
|
4826
|
-
* .connect(["x"], new eg.Axes.PanInput("#area4"))
|
|
4827
|
-
* .connect(["xOther", "x"], new eg.Axes.PanInput("#area5"))
|
|
4828
|
-
* .connect(["", "xOther"], new eg.Axes.PanInput("#area6"));
|
|
4829
|
-
* ```
|
|
4834
|
+
/**
|
|
4835
|
+
* Connect the axis of eg.Axes to the inputType.
|
|
4836
|
+
* @ko eg.Axes의 축과 inputType을 연결한다
|
|
4837
|
+
* @param {(String[]|String)} axes The name of the axis to associate with inputType <ko>inputType과 연결할 축의 이름</ko>
|
|
4838
|
+
* @param {Object} inputType The inputType instance to associate with the axis of eg.Axes <ko>eg.Axes의 축과 연결할 inputType 인스턴스</ko>
|
|
4839
|
+
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
4840
|
+
* @example
|
|
4841
|
+
* ```js
|
|
4842
|
+
* const axes = new eg.Axes({
|
|
4843
|
+
* "x": {
|
|
4844
|
+
* range: [0, 100]
|
|
4845
|
+
* },
|
|
4846
|
+
* "xOther": {
|
|
4847
|
+
* range: [-100, 100]
|
|
4848
|
+
* }
|
|
4849
|
+
* });
|
|
4850
|
+
*
|
|
4851
|
+
* axes.connect("x", new eg.Axes.PanInput("#area1"))
|
|
4852
|
+
* .connect("x xOther", new eg.Axes.PanInput("#area2"))
|
|
4853
|
+
* .connect(" xOther", new eg.Axes.PanInput("#area3"))
|
|
4854
|
+
* .connect(["x"], new eg.Axes.PanInput("#area4"))
|
|
4855
|
+
* .connect(["xOther", "x"], new eg.Axes.PanInput("#area5"))
|
|
4856
|
+
* .connect(["", "xOther"], new eg.Axes.PanInput("#area6"));
|
|
4857
|
+
* ```
|
|
4830
4858
|
*/
|
|
4831
4859
|
|
|
4832
4860
|
|
|
@@ -4853,33 +4881,33 @@ version: 4.10.5-beta.0
|
|
|
4853
4881
|
|
|
4854
4882
|
return this;
|
|
4855
4883
|
};
|
|
4856
|
-
/**
|
|
4857
|
-
* Disconnect the axis of eg.Axes from the inputType.
|
|
4858
|
-
* @ko eg.Axes의 축과 inputType의 연결을 끊는다.
|
|
4859
|
-
* @param {Object} [inputType] An inputType instance associated with the axis of eg.Axes <ko>eg.Axes의 축과 연결한 inputType 인스턴스</ko>
|
|
4860
|
-
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
4861
|
-
* @example
|
|
4862
|
-
* ```js
|
|
4863
|
-
* const axes = new eg.Axes({
|
|
4864
|
-
* "x": {
|
|
4865
|
-
* range: [0, 100]
|
|
4866
|
-
* },
|
|
4867
|
-
* "xOther": {
|
|
4868
|
-
* range: [-100, 100]
|
|
4869
|
-
* }
|
|
4870
|
-
* });
|
|
4871
|
-
*
|
|
4872
|
-
* const input1 = new eg.Axes.PanInput("#area1");
|
|
4873
|
-
* const input2 = new eg.Axes.PanInput("#area2");
|
|
4874
|
-
* const input3 = new eg.Axes.PanInput("#area3");
|
|
4875
|
-
*
|
|
4876
|
-
* axes.connect("x", input1);
|
|
4877
|
-
* .connect("x xOther", input2)
|
|
4878
|
-
* .connect(["xOther", "x"], input3);
|
|
4879
|
-
*
|
|
4880
|
-
* axes.disconnect(input1); // disconnects input1
|
|
4881
|
-
* axes.disconnect(); // disconnects all of them
|
|
4882
|
-
* ```
|
|
4884
|
+
/**
|
|
4885
|
+
* Disconnect the axis of eg.Axes from the inputType.
|
|
4886
|
+
* @ko eg.Axes의 축과 inputType의 연결을 끊는다.
|
|
4887
|
+
* @param {Object} [inputType] An inputType instance associated with the axis of eg.Axes <ko>eg.Axes의 축과 연결한 inputType 인스턴스</ko>
|
|
4888
|
+
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
4889
|
+
* @example
|
|
4890
|
+
* ```js
|
|
4891
|
+
* const axes = new eg.Axes({
|
|
4892
|
+
* "x": {
|
|
4893
|
+
* range: [0, 100]
|
|
4894
|
+
* },
|
|
4895
|
+
* "xOther": {
|
|
4896
|
+
* range: [-100, 100]
|
|
4897
|
+
* }
|
|
4898
|
+
* });
|
|
4899
|
+
*
|
|
4900
|
+
* const input1 = new eg.Axes.PanInput("#area1");
|
|
4901
|
+
* const input2 = new eg.Axes.PanInput("#area2");
|
|
4902
|
+
* const input3 = new eg.Axes.PanInput("#area3");
|
|
4903
|
+
*
|
|
4904
|
+
* axes.connect("x", input1);
|
|
4905
|
+
* .connect("x xOther", input2)
|
|
4906
|
+
* .connect(["xOther", "x"], input3);
|
|
4907
|
+
*
|
|
4908
|
+
* axes.disconnect(input1); // disconnects input1
|
|
4909
|
+
* axes.disconnect(); // disconnects all of them
|
|
4910
|
+
* ```
|
|
4883
4911
|
*/
|
|
4884
4912
|
|
|
4885
4913
|
|
|
@@ -4902,62 +4930,62 @@ version: 4.10.5-beta.0
|
|
|
4902
4930
|
|
|
4903
4931
|
return this;
|
|
4904
4932
|
};
|
|
4905
|
-
/**
|
|
4906
|
-
* Returns the current position of the coordinates.
|
|
4907
|
-
* @ko 좌표의 현재 위치를 반환한다
|
|
4908
|
-
* @param {Object} [axes] The names of the axis <ko>축 이름들</ko>
|
|
4909
|
-
* @return {Object.<string, number>} Axis coordinate information <ko>축 좌표 정보</ko>
|
|
4910
|
-
* @example
|
|
4911
|
-
* ```js
|
|
4912
|
-
* const axes = new eg.Axes({
|
|
4913
|
-
* "x": {
|
|
4914
|
-
* range: [0, 100]
|
|
4915
|
-
* },
|
|
4916
|
-
* "xOther": {
|
|
4917
|
-
* range: [-100, 100]
|
|
4918
|
-
* },
|
|
4919
|
-
* "zoom": {
|
|
4920
|
-
* range: [50, 30]
|
|
4921
|
-
* }
|
|
4922
|
-
* });
|
|
4923
|
-
*
|
|
4924
|
-
* axes.get(); // {"x": 0, "xOther": -100, "zoom": 50}
|
|
4925
|
-
* axes.get(["x", "zoom"]); // {"x": 0, "zoom": 50}
|
|
4926
|
-
* ```
|
|
4933
|
+
/**
|
|
4934
|
+
* Returns the current position of the coordinates.
|
|
4935
|
+
* @ko 좌표의 현재 위치를 반환한다
|
|
4936
|
+
* @param {Object} [axes] The names of the axis <ko>축 이름들</ko>
|
|
4937
|
+
* @return {Object.<string, number>} Axis coordinate information <ko>축 좌표 정보</ko>
|
|
4938
|
+
* @example
|
|
4939
|
+
* ```js
|
|
4940
|
+
* const axes = new eg.Axes({
|
|
4941
|
+
* "x": {
|
|
4942
|
+
* range: [0, 100]
|
|
4943
|
+
* },
|
|
4944
|
+
* "xOther": {
|
|
4945
|
+
* range: [-100, 100]
|
|
4946
|
+
* },
|
|
4947
|
+
* "zoom": {
|
|
4948
|
+
* range: [50, 30]
|
|
4949
|
+
* }
|
|
4950
|
+
* });
|
|
4951
|
+
*
|
|
4952
|
+
* axes.get(); // {"x": 0, "xOther": -100, "zoom": 50}
|
|
4953
|
+
* axes.get(["x", "zoom"]); // {"x": 0, "zoom": 50}
|
|
4954
|
+
* ```
|
|
4927
4955
|
*/
|
|
4928
4956
|
|
|
4929
4957
|
|
|
4930
4958
|
__proto.get = function (axes) {
|
|
4931
4959
|
return this.axisManager.get(axes);
|
|
4932
4960
|
};
|
|
4933
|
-
/**
|
|
4934
|
-
* Moves an axis to specific coordinates.
|
|
4935
|
-
* @ko 좌표를 이동한다.
|
|
4936
|
-
* @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
4937
|
-
* @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
|
|
4938
|
-
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
4939
|
-
* @example
|
|
4940
|
-
* ```js
|
|
4941
|
-
* const axes = new eg.Axes({
|
|
4942
|
-
* "x": {
|
|
4943
|
-
* range: [0, 100]
|
|
4944
|
-
* },
|
|
4945
|
-
* "xOther": {
|
|
4946
|
-
* range: [-100, 100]
|
|
4947
|
-
* },
|
|
4948
|
-
* "zoom": {
|
|
4949
|
-
* range: [50, 30]
|
|
4950
|
-
* }
|
|
4951
|
-
* });
|
|
4952
|
-
*
|
|
4953
|
-
* axes.setTo({"x": 30, "zoom": 60});
|
|
4954
|
-
* axes.get(); // {"x": 30, "xOther": -100, "zoom": 60}
|
|
4955
|
-
*
|
|
4956
|
-
* axes.setTo({"x": 100, "xOther": 60}, 1000); // animatation
|
|
4957
|
-
*
|
|
4958
|
-
* // after 1000 ms
|
|
4959
|
-
* axes.get(); // {"x": 100, "xOther": 60, "zoom": 60}
|
|
4960
|
-
* ```
|
|
4961
|
+
/**
|
|
4962
|
+
* Moves an axis to specific coordinates.
|
|
4963
|
+
* @ko 좌표를 이동한다.
|
|
4964
|
+
* @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
4965
|
+
* @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
|
|
4966
|
+
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
4967
|
+
* @example
|
|
4968
|
+
* ```js
|
|
4969
|
+
* const axes = new eg.Axes({
|
|
4970
|
+
* "x": {
|
|
4971
|
+
* range: [0, 100]
|
|
4972
|
+
* },
|
|
4973
|
+
* "xOther": {
|
|
4974
|
+
* range: [-100, 100]
|
|
4975
|
+
* },
|
|
4976
|
+
* "zoom": {
|
|
4977
|
+
* range: [50, 30]
|
|
4978
|
+
* }
|
|
4979
|
+
* });
|
|
4980
|
+
*
|
|
4981
|
+
* axes.setTo({"x": 30, "zoom": 60});
|
|
4982
|
+
* axes.get(); // {"x": 30, "xOther": -100, "zoom": 60}
|
|
4983
|
+
*
|
|
4984
|
+
* axes.setTo({"x": 100, "xOther": 60}, 1000); // animatation
|
|
4985
|
+
*
|
|
4986
|
+
* // after 1000 ms
|
|
4987
|
+
* axes.get(); // {"x": 100, "xOther": 60, "zoom": 60}
|
|
4988
|
+
* ```
|
|
4961
4989
|
*/
|
|
4962
4990
|
|
|
4963
4991
|
|
|
@@ -4969,34 +4997,34 @@ version: 4.10.5-beta.0
|
|
|
4969
4997
|
this.animationManager.setTo(pos, duration);
|
|
4970
4998
|
return this;
|
|
4971
4999
|
};
|
|
4972
|
-
/**
|
|
4973
|
-
* Moves an axis from the current coordinates to specific coordinates.
|
|
4974
|
-
* @ko 현재 좌표를 기준으로 좌표를 이동한다.
|
|
4975
|
-
* @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
4976
|
-
* @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
|
|
4977
|
-
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
4978
|
-
* @example
|
|
4979
|
-
* ```js
|
|
4980
|
-
* const axes = new eg.Axes({
|
|
4981
|
-
* "x": {
|
|
4982
|
-
* range: [0, 100]
|
|
4983
|
-
* },
|
|
4984
|
-
* "xOther": {
|
|
4985
|
-
* range: [-100, 100]
|
|
4986
|
-
* },
|
|
4987
|
-
* "zoom": {
|
|
4988
|
-
* range: [50, 30]
|
|
4989
|
-
* }
|
|
4990
|
-
* });
|
|
4991
|
-
*
|
|
4992
|
-
* axes.setBy({"x": 30, "zoom": 10});
|
|
4993
|
-
* axes.get(); // {"x": 30, "xOther": -100, "zoom": 60}
|
|
4994
|
-
*
|
|
4995
|
-
* axes.setBy({"x": 70, "xOther": 60}, 1000); // animatation
|
|
4996
|
-
*
|
|
4997
|
-
* // after 1000 ms
|
|
4998
|
-
* axes.get(); // {"x": 100, "xOther": -40, "zoom": 60}
|
|
4999
|
-
* ```
|
|
5000
|
+
/**
|
|
5001
|
+
* Moves an axis from the current coordinates to specific coordinates.
|
|
5002
|
+
* @ko 현재 좌표를 기준으로 좌표를 이동한다.
|
|
5003
|
+
* @param {Object.<string, number>} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
5004
|
+
* @param {Number} [duration=0] Duration of the animation (unit: ms) <ko>애니메이션 진행 시간(단위: ms)</ko>
|
|
5005
|
+
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5006
|
+
* @example
|
|
5007
|
+
* ```js
|
|
5008
|
+
* const axes = new eg.Axes({
|
|
5009
|
+
* "x": {
|
|
5010
|
+
* range: [0, 100]
|
|
5011
|
+
* },
|
|
5012
|
+
* "xOther": {
|
|
5013
|
+
* range: [-100, 100]
|
|
5014
|
+
* },
|
|
5015
|
+
* "zoom": {
|
|
5016
|
+
* range: [50, 30]
|
|
5017
|
+
* }
|
|
5018
|
+
* });
|
|
5019
|
+
*
|
|
5020
|
+
* axes.setBy({"x": 30, "zoom": 10});
|
|
5021
|
+
* axes.get(); // {"x": 30, "xOther": -100, "zoom": 60}
|
|
5022
|
+
*
|
|
5023
|
+
* axes.setBy({"x": 70, "xOther": 60}, 1000); // animatation
|
|
5024
|
+
*
|
|
5025
|
+
* // after 1000 ms
|
|
5026
|
+
* axes.get(); // {"x": 100, "xOther": -40, "zoom": 60}
|
|
5027
|
+
* ```
|
|
5000
5028
|
*/
|
|
5001
5029
|
|
|
5002
5030
|
|
|
@@ -5008,31 +5036,31 @@ version: 4.10.5-beta.0
|
|
|
5008
5036
|
this.animationManager.setBy(pos, duration);
|
|
5009
5037
|
return this;
|
|
5010
5038
|
};
|
|
5011
|
-
/**
|
|
5012
|
-
* Change the options of Axes instance.
|
|
5013
|
-
* @ko 인스턴스의 옵션을 변경한다.
|
|
5014
|
-
* @param {AxesOption} options Axes options to change <ko>변경할 옵션 목록</ko>
|
|
5015
|
-
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5016
|
-
* @example
|
|
5017
|
-
* ```js
|
|
5018
|
-
* const axes = new eg.Axes({
|
|
5019
|
-
* "x": {
|
|
5020
|
-
* range: [0, 100]
|
|
5021
|
-
* },
|
|
5022
|
-
* }, {
|
|
5023
|
-
* round: 10,
|
|
5024
|
-
* });
|
|
5025
|
-
*
|
|
5026
|
-
* axes.setTo({"x": 48});
|
|
5027
|
-
* axes.get(); // {"x": 50}
|
|
5028
|
-
*
|
|
5029
|
-
* axes.setOptions({
|
|
5030
|
-
* round: 1,
|
|
5031
|
-
* });
|
|
5032
|
-
*
|
|
5033
|
-
* axes.setTo({"x": 48});
|
|
5034
|
-
* axes.get(); // {"x": 48}
|
|
5035
|
-
* ```
|
|
5039
|
+
/**
|
|
5040
|
+
* Change the options of Axes instance.
|
|
5041
|
+
* @ko 인스턴스의 옵션을 변경한다.
|
|
5042
|
+
* @param {AxesOption} options Axes options to change <ko>변경할 옵션 목록</ko>
|
|
5043
|
+
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5044
|
+
* @example
|
|
5045
|
+
* ```js
|
|
5046
|
+
* const axes = new eg.Axes({
|
|
5047
|
+
* "x": {
|
|
5048
|
+
* range: [0, 100]
|
|
5049
|
+
* },
|
|
5050
|
+
* }, {
|
|
5051
|
+
* round: 10,
|
|
5052
|
+
* });
|
|
5053
|
+
*
|
|
5054
|
+
* axes.setTo({"x": 48});
|
|
5055
|
+
* axes.get(); // {"x": 50}
|
|
5056
|
+
*
|
|
5057
|
+
* axes.setOptions({
|
|
5058
|
+
* round: 1,
|
|
5059
|
+
* });
|
|
5060
|
+
*
|
|
5061
|
+
* axes.setTo({"x": 48});
|
|
5062
|
+
* axes.get(); // {"x": 48}
|
|
5063
|
+
* ```
|
|
5036
5064
|
*/
|
|
5037
5065
|
|
|
5038
5066
|
|
|
@@ -5040,31 +5068,31 @@ version: 4.10.5-beta.0
|
|
|
5040
5068
|
this.options = __assign$1(__assign$1({}, this.options), options);
|
|
5041
5069
|
return this;
|
|
5042
5070
|
};
|
|
5043
|
-
/**
|
|
5044
|
-
* Change the information of an existing axis.
|
|
5045
|
-
* @ko 존재하는 축의 정보를 변경한다.
|
|
5046
|
-
* @param {Object.<string, AxisOption>} axis Axis options to change <ko>변경할 축의 정보</ko>
|
|
5047
|
-
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5048
|
-
* @example
|
|
5049
|
-
* ```js
|
|
5050
|
-
* const axes = new eg.Axes({
|
|
5051
|
-
* "x": {
|
|
5052
|
-
* range: [0, 100]
|
|
5053
|
-
* },
|
|
5054
|
-
* });
|
|
5055
|
-
*
|
|
5056
|
-
* axes.setTo({"x": 150});
|
|
5057
|
-
* axes.get(); // {"x": 100}
|
|
5058
|
-
*
|
|
5059
|
-
* axes.setAxis({
|
|
5060
|
-
* "x": {
|
|
5061
|
-
* range: [0, 200]
|
|
5062
|
-
* },
|
|
5063
|
-
* });
|
|
5064
|
-
*
|
|
5065
|
-
* axes.setTo({"x": 150});
|
|
5066
|
-
* axes.get(); // {"x": 150}
|
|
5067
|
-
* ```
|
|
5071
|
+
/**
|
|
5072
|
+
* Change the information of an existing axis.
|
|
5073
|
+
* @ko 존재하는 축의 정보를 변경한다.
|
|
5074
|
+
* @param {Object.<string, AxisOption>} axis Axis options to change <ko>변경할 축의 정보</ko>
|
|
5075
|
+
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5076
|
+
* @example
|
|
5077
|
+
* ```js
|
|
5078
|
+
* const axes = new eg.Axes({
|
|
5079
|
+
* "x": {
|
|
5080
|
+
* range: [0, 100]
|
|
5081
|
+
* },
|
|
5082
|
+
* });
|
|
5083
|
+
*
|
|
5084
|
+
* axes.setTo({"x": 150});
|
|
5085
|
+
* axes.get(); // {"x": 100}
|
|
5086
|
+
*
|
|
5087
|
+
* axes.setAxis({
|
|
5088
|
+
* "x": {
|
|
5089
|
+
* range: [0, 200]
|
|
5090
|
+
* },
|
|
5091
|
+
* });
|
|
5092
|
+
*
|
|
5093
|
+
* axes.setTo({"x": 150});
|
|
5094
|
+
* axes.get(); // {"x": 150}
|
|
5095
|
+
* ```
|
|
5068
5096
|
*/
|
|
5069
5097
|
|
|
5070
5098
|
|
|
@@ -5072,23 +5100,23 @@ version: 4.10.5-beta.0
|
|
|
5072
5100
|
this.axisManager.setAxis(axis);
|
|
5073
5101
|
return this;
|
|
5074
5102
|
};
|
|
5075
|
-
/**
|
|
5076
|
-
* Stop an animation in progress.
|
|
5077
|
-
* @ko 재생 중인 애니메이션을 정지한다.
|
|
5078
|
-
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5079
|
-
* @example
|
|
5080
|
-
* ```js
|
|
5081
|
-
* const axes = new eg.Axes({
|
|
5082
|
-
* "x": {
|
|
5083
|
-
* range: [0, 100]
|
|
5084
|
-
* },
|
|
5085
|
-
* });
|
|
5086
|
-
*
|
|
5087
|
-
* axes.setTo({"x": 10}, 1000); // start animatation
|
|
5088
|
-
*
|
|
5089
|
-
* // after 500 ms
|
|
5090
|
-
* axes.stopAnimation(); // stop animation during movement.
|
|
5091
|
-
* ```
|
|
5103
|
+
/**
|
|
5104
|
+
* Stop an animation in progress.
|
|
5105
|
+
* @ko 재생 중인 애니메이션을 정지한다.
|
|
5106
|
+
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5107
|
+
* @example
|
|
5108
|
+
* ```js
|
|
5109
|
+
* const axes = new eg.Axes({
|
|
5110
|
+
* "x": {
|
|
5111
|
+
* range: [0, 100]
|
|
5112
|
+
* },
|
|
5113
|
+
* });
|
|
5114
|
+
*
|
|
5115
|
+
* axes.setTo({"x": 10}, 1000); // start animatation
|
|
5116
|
+
*
|
|
5117
|
+
* // after 500 ms
|
|
5118
|
+
* axes.stopAnimation(); // stop animation during movement.
|
|
5119
|
+
* ```
|
|
5092
5120
|
*/
|
|
5093
5121
|
|
|
5094
5122
|
|
|
@@ -5097,33 +5125,33 @@ version: 4.10.5-beta.0
|
|
|
5097
5125
|
this.animationManager.finish(false);
|
|
5098
5126
|
return this;
|
|
5099
5127
|
};
|
|
5100
|
-
/**
|
|
5101
|
-
* Change the destination of an animation in progress.
|
|
5102
|
-
* @ko 재생 중인 애니메이션의 목적지와 진행 시간을 변경한다.
|
|
5103
|
-
* @param {UpdateAnimationOption} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
5104
|
-
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5105
|
-
* @example
|
|
5106
|
-
* ```js
|
|
5107
|
-
* const axes = new eg.Axes({
|
|
5108
|
-
* "x": {
|
|
5109
|
-
* range: [0, 200]
|
|
5110
|
-
* },
|
|
5111
|
-
* "y": {
|
|
5112
|
-
* range: [0, 200]
|
|
5113
|
-
* }
|
|
5114
|
-
* });
|
|
5115
|
-
*
|
|
5116
|
-
* axes.setTo({"x": 50, "y": 50}, 1000); // trigger animation by setTo
|
|
5117
|
-
*
|
|
5118
|
-
* // after 500 ms
|
|
5119
|
-
* axes.updateAnimation({destPos: {"x": 100, "y": 100}}); // animation will end after 500 ms, at {"x": 100, "y": 100}
|
|
5120
|
-
*
|
|
5121
|
-
* // after 500 ms
|
|
5122
|
-
* axes.setTo({"x": 50, "y": 50}, 1000); // trigger animation by setTo
|
|
5123
|
-
*
|
|
5124
|
-
* // after 700 ms
|
|
5125
|
-
* 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.
|
|
5126
|
-
* ```
|
|
5128
|
+
/**
|
|
5129
|
+
* Change the destination of an animation in progress.
|
|
5130
|
+
* @ko 재생 중인 애니메이션의 목적지와 진행 시간을 변경한다.
|
|
5131
|
+
* @param {UpdateAnimationOption} pos The coordinate to move to <ko>이동할 좌표</ko>
|
|
5132
|
+
* @return {eg.Axes} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5133
|
+
* @example
|
|
5134
|
+
* ```js
|
|
5135
|
+
* const axes = new eg.Axes({
|
|
5136
|
+
* "x": {
|
|
5137
|
+
* range: [0, 200]
|
|
5138
|
+
* },
|
|
5139
|
+
* "y": {
|
|
5140
|
+
* range: [0, 200]
|
|
5141
|
+
* }
|
|
5142
|
+
* });
|
|
5143
|
+
*
|
|
5144
|
+
* axes.setTo({"x": 50, "y": 50}, 1000); // trigger animation by setTo
|
|
5145
|
+
*
|
|
5146
|
+
* // after 500 ms
|
|
5147
|
+
* axes.updateAnimation({destPos: {"x": 100, "y": 100}}); // animation will end after 500 ms, at {"x": 100, "y": 100}
|
|
5148
|
+
*
|
|
5149
|
+
* // after 500 ms
|
|
5150
|
+
* axes.setTo({"x": 50, "y": 50}, 1000); // trigger animation by setTo
|
|
5151
|
+
*
|
|
5152
|
+
* // after 700 ms
|
|
5153
|
+
* 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.
|
|
5154
|
+
* ```
|
|
5127
5155
|
*/
|
|
5128
5156
|
|
|
5129
5157
|
|
|
@@ -5131,38 +5159,38 @@ version: 4.10.5-beta.0
|
|
|
5131
5159
|
this.animationManager.updateAnimation(options);
|
|
5132
5160
|
return this;
|
|
5133
5161
|
};
|
|
5134
|
-
/**
|
|
5135
|
-
* Returns whether there is a coordinate in the bounce area of the target axis.
|
|
5136
|
-
* @ko 대상 축 중 bounce영역에 좌표가 존재하는지를 반환한다
|
|
5137
|
-
* @param {Object} [axes] The names of the axis <ko>축 이름들</ko>
|
|
5138
|
-
* @return {Boolen} Whether the bounce area exists. <ko>bounce 영역 존재 여부</ko>
|
|
5139
|
-
* @example
|
|
5140
|
-
* ```js
|
|
5141
|
-
* const axes = new eg.Axes({
|
|
5142
|
-
* "x": {
|
|
5143
|
-
* range: [0, 100]
|
|
5144
|
-
* },
|
|
5145
|
-
* "xOther": {
|
|
5146
|
-
* range: [-100, 100]
|
|
5147
|
-
* },
|
|
5148
|
-
* "zoom": {
|
|
5149
|
-
* range: [50, 30]
|
|
5150
|
-
* }
|
|
5151
|
-
* });
|
|
5152
|
-
*
|
|
5153
|
-
* axes.isBounceArea(["x"]);
|
|
5154
|
-
* axes.isBounceArea(["x", "zoom"]);
|
|
5155
|
-
* axes.isBounceArea();
|
|
5156
|
-
* ```
|
|
5162
|
+
/**
|
|
5163
|
+
* Returns whether there is a coordinate in the bounce area of the target axis.
|
|
5164
|
+
* @ko 대상 축 중 bounce영역에 좌표가 존재하는지를 반환한다
|
|
5165
|
+
* @param {Object} [axes] The names of the axis <ko>축 이름들</ko>
|
|
5166
|
+
* @return {Boolen} Whether the bounce area exists. <ko>bounce 영역 존재 여부</ko>
|
|
5167
|
+
* @example
|
|
5168
|
+
* ```js
|
|
5169
|
+
* const axes = new eg.Axes({
|
|
5170
|
+
* "x": {
|
|
5171
|
+
* range: [0, 100]
|
|
5172
|
+
* },
|
|
5173
|
+
* "xOther": {
|
|
5174
|
+
* range: [-100, 100]
|
|
5175
|
+
* },
|
|
5176
|
+
* "zoom": {
|
|
5177
|
+
* range: [50, 30]
|
|
5178
|
+
* }
|
|
5179
|
+
* });
|
|
5180
|
+
*
|
|
5181
|
+
* axes.isBounceArea(["x"]);
|
|
5182
|
+
* axes.isBounceArea(["x", "zoom"]);
|
|
5183
|
+
* axes.isBounceArea();
|
|
5184
|
+
* ```
|
|
5157
5185
|
*/
|
|
5158
5186
|
|
|
5159
5187
|
|
|
5160
5188
|
__proto.isBounceArea = function (axes) {
|
|
5161
5189
|
return this.axisManager.isOutside(axes);
|
|
5162
5190
|
};
|
|
5163
|
-
/**
|
|
5164
|
-
* Destroys properties, and events used in a module and disconnect all connections to inputTypes.
|
|
5165
|
-
* @ko 모듈에 사용한 속성, 이벤트를 해제한다. 모든 inputType과의 연결을 끊는다.
|
|
5191
|
+
/**
|
|
5192
|
+
* Destroys properties, and events used in a module and disconnect all connections to inputTypes.
|
|
5193
|
+
* @ko 모듈에 사용한 속성, 이벤트를 해제한다. 모든 inputType과의 연결을 끊는다.
|
|
5166
5194
|
*/
|
|
5167
5195
|
|
|
5168
5196
|
|
|
@@ -5170,90 +5198,90 @@ version: 4.10.5-beta.0
|
|
|
5170
5198
|
this.disconnect();
|
|
5171
5199
|
this.eventManager.destroy();
|
|
5172
5200
|
};
|
|
5173
|
-
/**
|
|
5174
|
-
* @name VERSION
|
|
5175
|
-
* @desc Version info string
|
|
5176
|
-
* @ko 버전정보 문자열
|
|
5177
|
-
*
|
|
5178
|
-
* @constant
|
|
5179
|
-
* @type {String}
|
|
5180
|
-
* @example
|
|
5181
|
-
* ```js
|
|
5182
|
-
* eg.Axes.VERSION; // ex) 3.3.3
|
|
5183
|
-
* ```
|
|
5201
|
+
/**
|
|
5202
|
+
* @name VERSION
|
|
5203
|
+
* @desc Version info string
|
|
5204
|
+
* @ko 버전정보 문자열
|
|
5205
|
+
*
|
|
5206
|
+
* @constant
|
|
5207
|
+
* @type {String}
|
|
5208
|
+
* @example
|
|
5209
|
+
* ```js
|
|
5210
|
+
* eg.Axes.VERSION; // ex) 3.3.3
|
|
5211
|
+
* ```
|
|
5184
5212
|
*/
|
|
5185
5213
|
|
|
5186
5214
|
|
|
5187
|
-
Axes.VERSION = "3.8.
|
|
5215
|
+
Axes.VERSION = "3.8.3";
|
|
5188
5216
|
/* eslint-enable */
|
|
5189
5217
|
|
|
5190
|
-
/**
|
|
5191
|
-
* @name TRANSFORM
|
|
5192
|
-
* @desc Returns the transform attribute with CSS vendor prefixes.
|
|
5193
|
-
* @ko CSS vendor prefixes를 붙인 transform 속성을 반환한다.
|
|
5194
|
-
*
|
|
5195
|
-
* @constant
|
|
5196
|
-
* @type {String}
|
|
5197
|
-
* @example
|
|
5198
|
-
* ```js
|
|
5199
|
-
* eg.Axes.TRANSFORM; // "transform" or "webkitTransform"
|
|
5200
|
-
* ```
|
|
5218
|
+
/**
|
|
5219
|
+
* @name TRANSFORM
|
|
5220
|
+
* @desc Returns the transform attribute with CSS vendor prefixes.
|
|
5221
|
+
* @ko CSS vendor prefixes를 붙인 transform 속성을 반환한다.
|
|
5222
|
+
*
|
|
5223
|
+
* @constant
|
|
5224
|
+
* @type {String}
|
|
5225
|
+
* @example
|
|
5226
|
+
* ```js
|
|
5227
|
+
* eg.Axes.TRANSFORM; // "transform" or "webkitTransform"
|
|
5228
|
+
* ```
|
|
5201
5229
|
*/
|
|
5202
5230
|
|
|
5203
5231
|
Axes.TRANSFORM = TRANSFORM;
|
|
5204
|
-
/**
|
|
5205
|
-
* @name DIRECTION_NONE
|
|
5206
|
-
* @constant
|
|
5207
|
-
* @type {Number}
|
|
5232
|
+
/**
|
|
5233
|
+
* @name DIRECTION_NONE
|
|
5234
|
+
* @constant
|
|
5235
|
+
* @type {Number}
|
|
5208
5236
|
*/
|
|
5209
5237
|
|
|
5210
5238
|
Axes.DIRECTION_NONE = DIRECTION_NONE;
|
|
5211
|
-
/**
|
|
5212
|
-
* @name DIRECTION_LEFT
|
|
5213
|
-
* @constant
|
|
5214
|
-
* @type {Number}
|
|
5239
|
+
/**
|
|
5240
|
+
* @name DIRECTION_LEFT
|
|
5241
|
+
* @constant
|
|
5242
|
+
* @type {Number}
|
|
5215
5243
|
*/
|
|
5216
5244
|
|
|
5217
5245
|
Axes.DIRECTION_LEFT = DIRECTION_LEFT;
|
|
5218
|
-
/**
|
|
5219
|
-
* @name DIRECTION_RIGHT
|
|
5220
|
-
* @constant
|
|
5221
|
-
* @type {Number}
|
|
5246
|
+
/**
|
|
5247
|
+
* @name DIRECTION_RIGHT
|
|
5248
|
+
* @constant
|
|
5249
|
+
* @type {Number}
|
|
5222
5250
|
*/
|
|
5223
5251
|
|
|
5224
5252
|
Axes.DIRECTION_RIGHT = DIRECTION_RIGHT;
|
|
5225
|
-
/**
|
|
5226
|
-
* @name DIRECTION_UP
|
|
5227
|
-
* @constant
|
|
5228
|
-
* @type {Number}
|
|
5253
|
+
/**
|
|
5254
|
+
* @name DIRECTION_UP
|
|
5255
|
+
* @constant
|
|
5256
|
+
* @type {Number}
|
|
5229
5257
|
*/
|
|
5230
5258
|
|
|
5231
5259
|
Axes.DIRECTION_UP = DIRECTION_UP;
|
|
5232
|
-
/**
|
|
5233
|
-
* @name DIRECTION_DOWN
|
|
5234
|
-
* @constant
|
|
5235
|
-
* @type {Number}
|
|
5260
|
+
/**
|
|
5261
|
+
* @name DIRECTION_DOWN
|
|
5262
|
+
* @constant
|
|
5263
|
+
* @type {Number}
|
|
5236
5264
|
*/
|
|
5237
5265
|
|
|
5238
5266
|
Axes.DIRECTION_DOWN = DIRECTION_DOWN;
|
|
5239
|
-
/**
|
|
5240
|
-
* @name DIRECTION_HORIZONTAL
|
|
5241
|
-
* @constant
|
|
5242
|
-
* @type {Number}
|
|
5267
|
+
/**
|
|
5268
|
+
* @name DIRECTION_HORIZONTAL
|
|
5269
|
+
* @constant
|
|
5270
|
+
* @type {Number}
|
|
5243
5271
|
*/
|
|
5244
5272
|
|
|
5245
5273
|
Axes.DIRECTION_HORIZONTAL = DIRECTION_HORIZONTAL;
|
|
5246
|
-
/**
|
|
5247
|
-
* @name DIRECTION_VERTICAL
|
|
5248
|
-
* @constant
|
|
5249
|
-
* @type {Number}
|
|
5274
|
+
/**
|
|
5275
|
+
* @name DIRECTION_VERTICAL
|
|
5276
|
+
* @constant
|
|
5277
|
+
* @type {Number}
|
|
5250
5278
|
*/
|
|
5251
5279
|
|
|
5252
5280
|
Axes.DIRECTION_VERTICAL = DIRECTION_VERTICAL;
|
|
5253
|
-
/**
|
|
5254
|
-
* @name DIRECTION_ALL
|
|
5255
|
-
* @constant
|
|
5256
|
-
* @type {Number}
|
|
5281
|
+
/**
|
|
5282
|
+
* @name DIRECTION_ALL
|
|
5283
|
+
* @constant
|
|
5284
|
+
* @type {Number}
|
|
5257
5285
|
*/
|
|
5258
5286
|
|
|
5259
5287
|
Axes.DIRECTION_ALL = DIRECTION_ALL;
|
|
@@ -5261,9 +5289,9 @@ version: 4.10.5-beta.0
|
|
|
5261
5289
|
return Axes;
|
|
5262
5290
|
}(Component);
|
|
5263
5291
|
|
|
5264
|
-
/*
|
|
5265
|
-
* Copyright (c) 2015 NAVER Corp.
|
|
5266
|
-
* egjs projects are licensed under the MIT license
|
|
5292
|
+
/*
|
|
5293
|
+
* Copyright (c) 2015 NAVER Corp.
|
|
5294
|
+
* egjs projects are licensed under the MIT license
|
|
5267
5295
|
*/
|
|
5268
5296
|
|
|
5269
5297
|
var getDirectionByAngle = function (angle, thresholdAngle) {
|
|
@@ -5274,77 +5302,76 @@ version: 4.10.5-beta.0
|
|
|
5274
5302
|
var toAngle = Math.abs(angle);
|
|
5275
5303
|
return toAngle > thresholdAngle && toAngle < 180 - thresholdAngle ? DIRECTION_VERTICAL : DIRECTION_HORIZONTAL;
|
|
5276
5304
|
};
|
|
5277
|
-
/**
|
|
5278
|
-
* @typedef {Object} PanInputOption The option object of the eg.Axes.PanInput module.
|
|
5279
|
-
* @ko eg.Axes.PanInput 모듈의 옵션 객체
|
|
5280
|
-
* @param {String[]} [inputType=["touch", "mouse", "pointer"]] Types of input devices
|
|
5281
|
-
* - touch: Touch screen
|
|
5282
|
-
* - mouse: Mouse
|
|
5283
|
-
* - pointer: Mouse and touch <ko>입력 장치 종류
|
|
5284
|
-
* - touch: 터치 입력 장치
|
|
5285
|
-
* - mouse: 마우스
|
|
5286
|
-
* - pointer: 마우스 및 터치</ko>
|
|
5287
|
-
* @param {String[]} [inputKey=["any"]] List of key combinations to allow input
|
|
5288
|
-
* - any: any key
|
|
5289
|
-
* - shift: shift key
|
|
5290
|
-
* - ctrl: ctrl key and pinch gesture on the trackpad
|
|
5291
|
-
* - alt: alt key
|
|
5292
|
-
* - meta: meta key
|
|
5293
|
-
* - none: none of these keys are pressed <ko>입력을 허용할 키 조합 목록
|
|
5294
|
-
* - any: 아무 키
|
|
5295
|
-
* - shift: shift 키
|
|
5296
|
-
* - ctrl: ctrl 키 및 트랙패드의 pinch 제스쳐
|
|
5297
|
-
* - alt: alt 키
|
|
5298
|
-
* - meta: meta 키
|
|
5299
|
-
* - none: 아무 키도 눌리지 않은 상태 </ko>
|
|
5300
|
-
* @param {String[]} [inputButton=["left"]] List of buttons to allow input
|
|
5301
|
-
* - left: Left mouse button and normal touch
|
|
5302
|
-
* - middle: Mouse wheel press
|
|
5303
|
-
* - right: Right mouse button <ko>입력을 허용할 버튼 목록
|
|
5304
|
-
* - left: 마우스 왼쪽 버튼
|
|
5305
|
-
* - middle: 마우스 휠 눌림
|
|
5306
|
-
* - right: 마우스 오른쪽 버튼 </ko>
|
|
5307
|
-
* @param {Number[]} [scale] Coordinate scale that a user can move<ko>사용자의 동작으로 이동하는 좌표의 배율</ko>
|
|
5308
|
-
* @param {Number} [scale[0]=1] horizontal axis scale <ko>수평축 배율</ko>
|
|
5309
|
-
* @param {Number} [scale[1]=1] vertical axis scale <ko>수직축 배율</ko>
|
|
5310
|
-
* @param {Number} [thresholdAngle=45] The threshold value that determines whether user action is horizontal or vertical (0~90) <ko>사용자의 동작이 가로 방향인지 세로 방향인지 판단하는 기준 각도(0~90)</ko>
|
|
5311
|
-
* @param {Number} [threshold=0] Minimal pan distance required before recognizing <ko>사용자의 Pan 동작을 인식하기 위해산 최소한의 거리</ko>
|
|
5312
|
-
* @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
|
|
5313
|
-
* @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>
|
|
5314
|
-
* @param {
|
|
5315
|
-
* @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>
|
|
5305
|
+
/**
|
|
5306
|
+
* @typedef {Object} PanInputOption The option object of the eg.Axes.PanInput module.
|
|
5307
|
+
* @ko eg.Axes.PanInput 모듈의 옵션 객체
|
|
5308
|
+
* @param {String[]} [inputType=["touch", "mouse", "pointer"]] Types of input devices
|
|
5309
|
+
* - touch: Touch screen
|
|
5310
|
+
* - mouse: Mouse
|
|
5311
|
+
* - pointer: Mouse and touch <ko>입력 장치 종류
|
|
5312
|
+
* - touch: 터치 입력 장치
|
|
5313
|
+
* - mouse: 마우스
|
|
5314
|
+
* - pointer: 마우스 및 터치</ko>
|
|
5315
|
+
* @param {String[]} [inputKey=["any"]] List of key combinations to allow input
|
|
5316
|
+
* - any: any key
|
|
5317
|
+
* - shift: shift key
|
|
5318
|
+
* - ctrl: ctrl key and pinch gesture on the trackpad
|
|
5319
|
+
* - alt: alt key
|
|
5320
|
+
* - meta: meta key
|
|
5321
|
+
* - none: none of these keys are pressed <ko>입력을 허용할 키 조합 목록
|
|
5322
|
+
* - any: 아무 키
|
|
5323
|
+
* - shift: shift 키
|
|
5324
|
+
* - ctrl: ctrl 키 및 트랙패드의 pinch 제스쳐
|
|
5325
|
+
* - alt: alt 키
|
|
5326
|
+
* - meta: meta 키
|
|
5327
|
+
* - none: 아무 키도 눌리지 않은 상태 </ko>
|
|
5328
|
+
* @param {String[]} [inputButton=["left"]] List of buttons to allow input
|
|
5329
|
+
* - left: Left mouse button and normal touch
|
|
5330
|
+
* - middle: Mouse wheel press
|
|
5331
|
+
* - right: Right mouse button <ko>입력을 허용할 버튼 목록
|
|
5332
|
+
* - left: 마우스 왼쪽 버튼
|
|
5333
|
+
* - middle: 마우스 휠 눌림
|
|
5334
|
+
* - right: 마우스 오른쪽 버튼 </ko>
|
|
5335
|
+
* @param {Number[]} [scale] Coordinate scale that a user can move<ko>사용자의 동작으로 이동하는 좌표의 배율</ko>
|
|
5336
|
+
* @param {Number} [scale[0]=1] horizontal axis scale <ko>수평축 배율</ko>
|
|
5337
|
+
* @param {Number} [scale[1]=1] vertical axis scale <ko>수직축 배율</ko>
|
|
5338
|
+
* @param {Number} [thresholdAngle=45] The threshold value that determines whether user action is horizontal or vertical (0~90) <ko>사용자의 동작이 가로 방향인지 세로 방향인지 판단하는 기준 각도(0~90)</ko>
|
|
5339
|
+
* @param {Number} [threshold=0] Minimal pan distance required before recognizing <ko>사용자의 Pan 동작을 인식하기 위해산 최소한의 거리</ko>
|
|
5340
|
+
* @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>
|
|
5341
|
+
* @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>
|
|
5342
|
+
* @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>
|
|
5316
5343
|
**/
|
|
5317
5344
|
|
|
5318
|
-
/**
|
|
5319
|
-
* 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.
|
|
5320
|
-
* @ko 마우스나 터치 스크린을 누르고 움직일때의 변화량을 eg.Axes에 전달하는 모듈. 두개 이하의 축을 사용한다.
|
|
5321
|
-
*
|
|
5322
|
-
* @example
|
|
5323
|
-
* ```js
|
|
5324
|
-
* const pan = new eg.Axes.PanInput("#area", {
|
|
5325
|
-
* inputType: ["touch"],
|
|
5326
|
-
* scale: [1, 1.3],
|
|
5327
|
-
* });
|
|
5328
|
-
*
|
|
5329
|
-
* // Connect the 'something2' axis to the mouse or touchscreen x position when the mouse or touchscreen is down and moved.
|
|
5330
|
-
* // Connect the 'somethingN' axis to the mouse or touchscreen y position when the mouse or touchscreen is down and moved.
|
|
5331
|
-
* axes.connect(["something2", "somethingN"], pan); // or axes.connect("something2 somethingN", pan);
|
|
5332
|
-
*
|
|
5333
|
-
* // Connect only one 'something1' axis to the mouse or touchscreen x position when the mouse or touchscreen is down and moved.
|
|
5334
|
-
* axes.connect(["something1"], pan); // or axes.connect("something1", pan);
|
|
5335
|
-
*
|
|
5336
|
-
* // Connect only one 'something2' axis to the mouse or touchscreen y position when the mouse or touchscreen is down and moved.
|
|
5337
|
-
* axes.connect(["", "something2"], pan); // or axes.connect(" something2", pan);
|
|
5338
|
-
* ```
|
|
5339
|
-
* @param {String|HTMLElement|Ref<HTMLElement>|jQuery} element An element to use the eg.Axes.PanInput module <ko>eg.Axes.PanInput 모듈을 사용할 엘리먼트</ko>
|
|
5340
|
-
* @param {PanInputOption} [options={}] The option object of the eg.Axes.PanInput module<ko>eg.Axes.PanInput 모듈의 옵션 객체</ko>
|
|
5345
|
+
/**
|
|
5346
|
+
* 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.
|
|
5347
|
+
* @ko 마우스나 터치 스크린을 누르고 움직일때의 변화량을 eg.Axes에 전달하는 모듈. 두개 이하의 축을 사용한다.
|
|
5348
|
+
*
|
|
5349
|
+
* @example
|
|
5350
|
+
* ```js
|
|
5351
|
+
* const pan = new eg.Axes.PanInput("#area", {
|
|
5352
|
+
* inputType: ["touch"],
|
|
5353
|
+
* scale: [1, 1.3],
|
|
5354
|
+
* });
|
|
5355
|
+
*
|
|
5356
|
+
* // Connect the 'something2' axis to the mouse or touchscreen x position when the mouse or touchscreen is down and moved.
|
|
5357
|
+
* // Connect the 'somethingN' axis to the mouse or touchscreen y position when the mouse or touchscreen is down and moved.
|
|
5358
|
+
* axes.connect(["something2", "somethingN"], pan); // or axes.connect("something2 somethingN", pan);
|
|
5359
|
+
*
|
|
5360
|
+
* // Connect only one 'something1' axis to the mouse or touchscreen x position when the mouse or touchscreen is down and moved.
|
|
5361
|
+
* axes.connect(["something1"], pan); // or axes.connect("something1", pan);
|
|
5362
|
+
*
|
|
5363
|
+
* // Connect only one 'something2' axis to the mouse or touchscreen y position when the mouse or touchscreen is down and moved.
|
|
5364
|
+
* axes.connect(["", "something2"], pan); // or axes.connect(" something2", pan);
|
|
5365
|
+
* ```
|
|
5366
|
+
* @param {String|HTMLElement|Ref<HTMLElement>|jQuery} element An element to use the eg.Axes.PanInput module <ko>eg.Axes.PanInput 모듈을 사용할 엘리먼트</ko>
|
|
5367
|
+
* @param {PanInputOption} [options={}] The option object of the eg.Axes.PanInput module<ko>eg.Axes.PanInput 모듈의 옵션 객체</ko>
|
|
5341
5368
|
*/
|
|
5342
5369
|
|
|
5343
5370
|
var PanInput =
|
|
5344
5371
|
/*#__PURE__*/
|
|
5345
5372
|
function () {
|
|
5346
|
-
/**
|
|
5347
|
-
*
|
|
5373
|
+
/**
|
|
5374
|
+
*
|
|
5348
5375
|
*/
|
|
5349
5376
|
function PanInput(el, options) {
|
|
5350
5377
|
var _this = this;
|
|
@@ -5380,7 +5407,6 @@ version: 4.10.5-beta.0
|
|
|
5380
5407
|
preventClickOnDrag: false,
|
|
5381
5408
|
iOSEdgeSwipeThreshold: IOS_EDGE_THRESHOLD,
|
|
5382
5409
|
releaseOnScroll: false,
|
|
5383
|
-
useAcceleration: false,
|
|
5384
5410
|
touchAction: null
|
|
5385
5411
|
}, options);
|
|
5386
5412
|
this._onPanstart = this._onPanstart.bind(this);
|
|
@@ -5420,9 +5446,9 @@ version: 4.10.5-beta.0
|
|
|
5420
5446
|
this._direction = DIRECTION_NONE;
|
|
5421
5447
|
return this;
|
|
5422
5448
|
};
|
|
5423
|
-
/**
|
|
5424
|
-
* Destroys elements, properties, and events used in a module.
|
|
5425
|
-
* @ko 모듈에 사용한 엘리먼트와 속성, 이벤트를 해제한다.
|
|
5449
|
+
/**
|
|
5450
|
+
* Destroys elements, properties, and events used in a module.
|
|
5451
|
+
* @ko 모듈에 사용한 엘리먼트와 속성, 이벤트를 해제한다.
|
|
5426
5452
|
*/
|
|
5427
5453
|
|
|
5428
5454
|
|
|
@@ -5430,10 +5456,10 @@ version: 4.10.5-beta.0
|
|
|
5430
5456
|
this.disconnect();
|
|
5431
5457
|
this.element = null;
|
|
5432
5458
|
};
|
|
5433
|
-
/**
|
|
5434
|
-
* Enables input devices
|
|
5435
|
-
* @ko 입력 장치를 사용할 수 있게 한다
|
|
5436
|
-
* @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5459
|
+
/**
|
|
5460
|
+
* Enables input devices
|
|
5461
|
+
* @ko 입력 장치를 사용할 수 있게 한다
|
|
5462
|
+
* @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5437
5463
|
*/
|
|
5438
5464
|
|
|
5439
5465
|
|
|
@@ -5441,10 +5467,10 @@ version: 4.10.5-beta.0
|
|
|
5441
5467
|
this._enabled = true;
|
|
5442
5468
|
return this;
|
|
5443
5469
|
};
|
|
5444
|
-
/**
|
|
5445
|
-
* Disables input devices
|
|
5446
|
-
* @ko 입력 장치를 사용할 수 없게 한다.
|
|
5447
|
-
* @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5470
|
+
/**
|
|
5471
|
+
* Disables input devices
|
|
5472
|
+
* @ko 입력 장치를 사용할 수 없게 한다.
|
|
5473
|
+
* @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5448
5474
|
*/
|
|
5449
5475
|
|
|
5450
5476
|
|
|
@@ -5452,20 +5478,20 @@ version: 4.10.5-beta.0
|
|
|
5452
5478
|
this._enabled = false;
|
|
5453
5479
|
return this;
|
|
5454
5480
|
};
|
|
5455
|
-
/**
|
|
5456
|
-
* Returns whether to use an input device
|
|
5457
|
-
* @ko 입력 장치 사용 여부를 반환한다.
|
|
5458
|
-
* @return {Boolean} Whether to use an input device <ko>입력장치 사용여부</ko>
|
|
5481
|
+
/**
|
|
5482
|
+
* Returns whether to use an input device
|
|
5483
|
+
* @ko 입력 장치 사용 여부를 반환한다.
|
|
5484
|
+
* @return {Boolean} Whether to use an input device <ko>입력장치 사용여부</ko>
|
|
5459
5485
|
*/
|
|
5460
5486
|
|
|
5461
5487
|
|
|
5462
5488
|
__proto.isEnabled = function () {
|
|
5463
5489
|
return this._enabled;
|
|
5464
5490
|
};
|
|
5465
|
-
/**
|
|
5466
|
-
* Releases current user input.
|
|
5467
|
-
* @ko 사용자의 입력을 강제로 중단시킨다.
|
|
5468
|
-
* @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5491
|
+
/**
|
|
5492
|
+
* Releases current user input.
|
|
5493
|
+
* @ko 사용자의 입력을 강제로 중단시킨다.
|
|
5494
|
+
* @return {PanInput} An instance of a module itself <ko>모듈 자신의 인스턴스</ko>
|
|
5469
5495
|
*/
|
|
5470
5496
|
|
|
5471
5497
|
|
|
@@ -5512,8 +5538,8 @@ version: 4.10.5-beta.0
|
|
|
5512
5538
|
|
|
5513
5539
|
var _a = this.options,
|
|
5514
5540
|
iOSEdgeSwipeThreshold = _a.iOSEdgeSwipeThreshold,
|
|
5541
|
+
preventClickOnDrag = _a.preventClickOnDrag,
|
|
5515
5542
|
releaseOnScroll = _a.releaseOnScroll,
|
|
5516
|
-
useAcceleration = _a.useAcceleration,
|
|
5517
5543
|
inputKey = _a.inputKey,
|
|
5518
5544
|
inputButton = _a.inputButton,
|
|
5519
5545
|
threshold = _a.threshold,
|
|
@@ -5578,11 +5604,10 @@ version: 4.10.5-beta.0
|
|
|
5578
5604
|
panEvent.preventSystemEvent = prevent;
|
|
5579
5605
|
|
|
5580
5606
|
if (prevent && (this._isOverThreshold || distance >= threshold)) {
|
|
5581
|
-
|
|
5582
|
-
this._dragged = true;
|
|
5607
|
+
this._dragged = preventClickOnDrag;
|
|
5583
5608
|
this._isOverThreshold = true;
|
|
5584
5609
|
|
|
5585
|
-
this._observer.change(this, panEvent, toAxis(this.axes, offset)
|
|
5610
|
+
this._observer.change(this, panEvent, toAxis(this.axes, offset));
|
|
5586
5611
|
}
|
|
5587
5612
|
|
|
5588
5613
|
activeEvent.prevEvent = panEvent;
|
|
@@ -5601,9 +5626,7 @@ version: 4.10.5-beta.0
|
|
|
5601
5626
|
|
|
5602
5627
|
clearTimeout(this._rightEdgeTimer);
|
|
5603
5628
|
var prevEvent = activeEvent.prevEvent;
|
|
5604
|
-
|
|
5605
|
-
var velocity = this._getVelocity(prevEvent);
|
|
5606
|
-
|
|
5629
|
+
var velocity = this._isOverThreshold ? this._getOffset([Math.abs(prevEvent.velocityX) * (prevEvent.offsetX < 0 ? -1 : 1), Math.abs(prevEvent.velocityY) * (prevEvent.offsetY < 0 ? -1 : 1)], [useDirection(DIRECTION_HORIZONTAL, this._direction), useDirection(DIRECTION_VERTICAL, this._direction)]) : [0, 0];
|
|
5607
5630
|
activeEvent.onRelease();
|
|
5608
5631
|
|
|
5609
5632
|
this._observer.release(this, prevEvent, velocity);
|
|
@@ -5613,14 +5636,10 @@ version: 4.10.5-beta.0
|
|
|
5613
5636
|
var _this = this;
|
|
5614
5637
|
|
|
5615
5638
|
activeEvent === null || activeEvent === void 0 ? void 0 : activeEvent.move.forEach(function (event) {
|
|
5616
|
-
window.addEventListener(event, _this._onPanmove,
|
|
5617
|
-
passive: false
|
|
5618
|
-
});
|
|
5639
|
+
window.addEventListener(event, _this._onPanmove, getAddEventOptions(event));
|
|
5619
5640
|
});
|
|
5620
5641
|
activeEvent === null || activeEvent === void 0 ? void 0 : activeEvent.end.forEach(function (event) {
|
|
5621
|
-
window.addEventListener(event, _this._onPanend,
|
|
5622
|
-
passive: false
|
|
5623
|
-
});
|
|
5642
|
+
window.addEventListener(event, _this._onPanend, getAddEventOptions(event));
|
|
5624
5643
|
});
|
|
5625
5644
|
};
|
|
5626
5645
|
|
|
@@ -5640,10 +5659,6 @@ version: 4.10.5-beta.0
|
|
|
5640
5659
|
return [direction[0] ? properties[0] * scale[0] : 0, direction[1] ? properties[1] * scale[1] : 0];
|
|
5641
5660
|
};
|
|
5642
5661
|
|
|
5643
|
-
__proto._getVelocity = function (event) {
|
|
5644
|
-
return this._isOverThreshold ? this._getOffset([Math.abs(event.velocityX) * (event.offsetX < 0 ? -1 : 1), Math.abs(event.velocityY) * (event.offsetY < 0 ? -1 : 1)], [useDirection(DIRECTION_HORIZONTAL, this._direction), useDirection(DIRECTION_VERTICAL, this._direction)]) : [0, 0];
|
|
5645
|
-
};
|
|
5646
|
-
|
|
5647
5662
|
__proto._getDistance = function (delta, direction) {
|
|
5648
5663
|
return Math.sqrt(Number(direction[0]) * Math.pow(delta[0], 2) + Number(direction[1]) * Math.pow(delta[1], 2));
|
|
5649
5664
|
};
|
|
@@ -5665,11 +5680,7 @@ version: 4.10.5-beta.0
|
|
|
5665
5680
|
this._observer = observer;
|
|
5666
5681
|
this._enabled = true;
|
|
5667
5682
|
this._activeEvent = activeEvent;
|
|
5668
|
-
|
|
5669
|
-
if (this.options.preventClickOnDrag) {
|
|
5670
|
-
element.addEventListener("click", this._preventClickWhenDragged, true);
|
|
5671
|
-
}
|
|
5672
|
-
|
|
5683
|
+
element.addEventListener("click", this._preventClickWhenDragged, true);
|
|
5673
5684
|
activeEvent.start.forEach(function (event) {
|
|
5674
5685
|
element.addEventListener(event, _this._onPanstart);
|
|
5675
5686
|
}); // adding event listener to element prevents invalid behavior in iOS Safari
|
|
@@ -5686,10 +5697,7 @@ version: 4.10.5-beta.0
|
|
|
5686
5697
|
var element = this.element;
|
|
5687
5698
|
|
|
5688
5699
|
if (element) {
|
|
5689
|
-
|
|
5690
|
-
element.removeEventListener("click", this._preventClickWhenDragged, true);
|
|
5691
|
-
}
|
|
5692
|
-
|
|
5700
|
+
element.removeEventListener("click", this._preventClickWhenDragged, true);
|
|
5693
5701
|
activeEvent === null || activeEvent === void 0 ? void 0 : activeEvent.start.forEach(function (event) {
|
|
5694
5702
|
element.removeEventListener(event, _this._onPanstart);
|
|
5695
5703
|
});
|
|
@@ -5705,9 +5713,9 @@ version: 4.10.5-beta.0
|
|
|
5705
5713
|
return PanInput;
|
|
5706
5714
|
}();
|
|
5707
5715
|
|
|
5708
|
-
/*
|
|
5709
|
-
* Copyright (c) 2015 NAVER Corp.
|
|
5710
|
-
* egjs projects are licensed under the MIT license
|
|
5716
|
+
/*
|
|
5717
|
+
* Copyright (c) 2015 NAVER Corp.
|
|
5718
|
+
* egjs projects are licensed under the MIT license
|
|
5711
5719
|
*/
|
|
5712
5720
|
|
|
5713
5721
|
var Axes$1 = Axes;
|
|
@@ -7601,8 +7609,8 @@ version: 4.10.5-beta.0
|
|
|
7601
7609
|
// Move to the adjacent panel
|
|
7602
7610
|
targetAnchor = this._findAdjacentAnchor(position, posDelta, anchorAtCamera);
|
|
7603
7611
|
} else {
|
|
7604
|
-
//
|
|
7605
|
-
return this.moveToPanel(
|
|
7612
|
+
// Fallback to nearest panel from current camera
|
|
7613
|
+
return this.moveToPanel(anchorAtCamera.panel, {
|
|
7606
7614
|
duration: duration,
|
|
7607
7615
|
axesEvent: axesEvent
|
|
7608
7616
|
});
|
|
@@ -8070,9 +8078,17 @@ version: 4.10.5-beta.0
|
|
|
8070
8078
|
targetPanel = adjacentAnchor.panel;
|
|
8071
8079
|
targetPos = adjacentAnchor.position;
|
|
8072
8080
|
} else {
|
|
8073
|
-
//
|
|
8074
|
-
|
|
8075
|
-
|
|
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
|
+
});
|
|
8076
8092
|
}
|
|
8077
8093
|
|
|
8078
8094
|
this._triggerIndexChangeEvent(targetPanel, position, axesEvent);
|
|
@@ -14178,7 +14194,7 @@ version: 4.10.5-beta.0
|
|
|
14178
14194
|
*/
|
|
14179
14195
|
|
|
14180
14196
|
|
|
14181
|
-
Flicking.VERSION = "4.10.5
|
|
14197
|
+
Flicking.VERSION = "4.10.5";
|
|
14182
14198
|
return Flicking;
|
|
14183
14199
|
}(Component);
|
|
14184
14200
|
|