@antv/g-lite 1.2.10 → 1.2.11
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/dist/index.esm.js +4 -3
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +4 -3
- package/dist/index.js.map +1 -1
- package/dist/index.umd.min.js +1 -1
- package/dist/index.umd.min.js.map +1 -1
- package/dist/utils/event.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7745,6 +7745,7 @@ var TOUCH_TO_POINTER = {
|
|
|
7745
7745
|
touchmove: 'pointermove',
|
|
7746
7746
|
touchcancel: 'pointercancel',
|
|
7747
7747
|
};
|
|
7748
|
+
var clock = typeof performance === 'object' && performance.now ? performance : Date;
|
|
7748
7749
|
|
|
7749
7750
|
function isFillOrStrokeAffected(pointerEvents, fill, stroke) {
|
|
7750
7751
|
// account for pointerEvents
|
|
@@ -9199,7 +9200,7 @@ var EventService = /** @class */ (function () {
|
|
|
9199
9200
|
};
|
|
9200
9201
|
this.onPointerUp = function (from) {
|
|
9201
9202
|
var _a;
|
|
9202
|
-
var now =
|
|
9203
|
+
var now = clock.now();
|
|
9203
9204
|
var e = _this.createPointerEvent(from, undefined, undefined, _this.context.config.alwaysTriggerPointerEventOnCanvas
|
|
9204
9205
|
? _this.rootTarget
|
|
9205
9206
|
: undefined);
|
|
@@ -9796,7 +9797,7 @@ var EventService = /** @class */ (function () {
|
|
|
9796
9797
|
};
|
|
9797
9798
|
EventService.prototype.copyData = function (from, to) {
|
|
9798
9799
|
to.isTrusted = from.isTrusted;
|
|
9799
|
-
to.timeStamp =
|
|
9800
|
+
to.timeStamp = clock.now();
|
|
9800
9801
|
to.type = from.type;
|
|
9801
9802
|
to.detail = from.detail;
|
|
9802
9803
|
to.view = from.view;
|
|
@@ -14536,7 +14537,7 @@ var EventPlugin = /** @class */ (function () {
|
|
|
14536
14537
|
EventPlugin.prototype.transferMouseData = function (event, nativeEvent) {
|
|
14537
14538
|
event.isTrusted = nativeEvent.isTrusted;
|
|
14538
14539
|
event.srcElement = nativeEvent.srcElement;
|
|
14539
|
-
event.timeStamp =
|
|
14540
|
+
event.timeStamp = clock.now();
|
|
14540
14541
|
event.type = nativeEvent.type;
|
|
14541
14542
|
event.altKey = nativeEvent.altKey;
|
|
14542
14543
|
event.metaKey = nativeEvent.metaKey;
|