@evercam/ui 1.0.0-preview-stats-monitor-commponent-6baabcfb7 → 1.0.0-preview-addingZoomButtonsToLiveViewVideo-de40a7d88
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/components/EZoomable.vue.d.ts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.mjs +10 -1
- package/dist/index.mjs.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types.d.ts +0 -28
- package/dist/web-types.json +1 -1
- package/package.json +1 -1
|
@@ -16,6 +16,7 @@ declare const _default: import("vue/types/vue").ExtendedVue<Vue<Record<string, a
|
|
|
16
16
|
pointers: Record<number, PointerEvent>;
|
|
17
17
|
transform: string;
|
|
18
18
|
}, {
|
|
19
|
+
zoom(delta: number): void;
|
|
19
20
|
updateZoomScale(): void;
|
|
20
21
|
handleZoom(e: WheelEvent): void;
|
|
21
22
|
handleMouseDown(e: MouseEvent): void;
|
package/dist/index.d.ts
CHANGED
package/dist/index.mjs
CHANGED
|
@@ -9393,6 +9393,15 @@ const Z0 = R.extend({
|
|
|
9393
9393
|
}
|
|
9394
9394
|
},
|
|
9395
9395
|
methods: {
|
|
9396
|
+
zoom(t) {
|
|
9397
|
+
const e = this.$refs.container;
|
|
9398
|
+
if (this.disabled)
|
|
9399
|
+
return;
|
|
9400
|
+
const r = e.getBoundingClientRect(), n = { x: r.width / 2, y: r.height / 2 }, i = this.scale;
|
|
9401
|
+
t < 0 ? this.scale *= 1.2 : this.scale *= 0.8, this.updateZoomScale(), this.left = (this.left - n.x) * (this.scale / i) + n.x, this.top = (this.top - n.y) * (this.scale / i) + n.y;
|
|
9402
|
+
const o = 0 - r.width * (this.scale - 1), a = 0 - r.height * (this.scale - 1);
|
|
9403
|
+
this.left = Math.min(0, Math.max(o, this.left)), this.top = Math.min(0, Math.max(a, this.top)), this.updateTransform();
|
|
9404
|
+
},
|
|
9396
9405
|
updateZoomScale() {
|
|
9397
9406
|
this.scale > this.maxScale ? this.scale = this.maxScale : this.scale < this.minScale && (this.scale = this.minScale);
|
|
9398
9407
|
},
|
|
@@ -9494,7 +9503,7 @@ var V0 = function() {
|
|
|
9494
9503
|
Y0,
|
|
9495
9504
|
!1,
|
|
9496
9505
|
null,
|
|
9497
|
-
"
|
|
9506
|
+
"06b5341b",
|
|
9498
9507
|
null,
|
|
9499
9508
|
null
|
|
9500
9509
|
);
|