@bluepic/embed 0.6.37 → 0.6.39
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/bluepic-embed.iife.js +4 -4
- package/dist/bluepic-embed.umd.js +4 -4
- package/dist/components/TemplateEditor/BxTemplateEditor.vue.d.ts +58 -8
- package/dist/components/TemplateEditor/TemplateView.vue.d.ts +18 -2
- package/dist/embed/embed.d.ts +214 -32
- package/dist/main.cjs +4 -4
- package/dist/main.mjs +160 -146
- package/dist/style.css +1 -1
- package/dist/util/zoompinchFrame.d.ts +8 -1
- package/package.json +2 -2
package/dist/main.mjs
CHANGED
|
@@ -53212,7 +53212,7 @@ var wA = class extends EventTarget {
|
|
|
53212
53212
|
y: 0,
|
|
53213
53213
|
width: 100,
|
|
53214
53214
|
height: 100
|
|
53215
|
-
}), yA(this, "translateSpeed", 1), yA(this, "zoomSpeed", 1), yA(this, "translateSpeedAppleTrackpad", 1), yA(this, "zoomSpeedAppleTrackpad", 1), yA(this, "isGestureActive", !1), yA(this, "roElement", null), yA(this, "roCanvas", null), yA(this, "ancestorMotionCleanup", null), yA(this, "gestureStartRotate", 0), yA(this, "dragStart", null), yA(this, "dragStartFrozenX", null), yA(this, "dragStartFrozenY", null), yA(this, "touchStarts", null), yA(this, "touchStartTranslateX", 0), yA(this, "touchStartTranslateY", 0), this.element = e, this.offset = t, this.translateX = n, this.translateY = r, this.scale = i, this.rotate = a, this.minScale = o, this.maxScale = s, this.clampBounds = c, this.rotation = l, this.roElement = new ResizeObserver(() => {
|
|
53215
|
+
}), yA(this, "translateSpeed", 1), yA(this, "zoomSpeed", 1), yA(this, "translateSpeedAppleTrackpad", 1), yA(this, "zoomSpeedAppleTrackpad", 1), yA(this, "maxNaturalScale", 1 / 0), yA(this, "isGestureActive", !1), yA(this, "roElement", null), yA(this, "roCanvas", null), yA(this, "ancestorMotionCleanup", null), yA(this, "gestureStartRotate", 0), yA(this, "dragStart", null), yA(this, "dragStartFrozenX", null), yA(this, "dragStartFrozenY", null), yA(this, "touchStarts", null), yA(this, "touchStartTranslateX", 0), yA(this, "touchStartTranslateY", 0), this.element = e, this.offset = t, this.translateX = n, this.translateY = r, this.scale = i, this.rotate = a, this.minScale = o, this.maxScale = s, this.clampBounds = c, this.rotation = l, this.roElement = new ResizeObserver(() => {
|
|
53216
53216
|
let { x: e, y: t, width: n, height: r } = this.element.getBoundingClientRect();
|
|
53217
53217
|
this.wrapperBounds = {
|
|
53218
53218
|
x: e,
|
|
@@ -53276,7 +53276,9 @@ var wA = class extends EventTarget {
|
|
|
53276
53276
|
return this.canvasBounds.width / this.canvasBounds.height;
|
|
53277
53277
|
}
|
|
53278
53278
|
get naturalScale() {
|
|
53279
|
-
|
|
53279
|
+
if (!(this.canvasBounds.width > 0) || !(this.canvasBounds.height > 0)) return 1;
|
|
53280
|
+
let e = this.canvasNaturalRatio >= this.wrapperInnerRatio ? this.wrapperInnerWidth / this.canvasBounds.width : this.wrapperInnerHeight / this.canvasBounds.height;
|
|
53281
|
+
return Math.min(e, this.maxNaturalScale);
|
|
53280
53282
|
}
|
|
53281
53283
|
setTranslateFromUserGesture(e, t) {
|
|
53282
53284
|
if (this.clampBounds) {
|
|
@@ -53455,6 +53457,7 @@ var wA = class extends EventTarget {
|
|
|
53455
53457
|
}) },
|
|
53456
53458
|
maxScale: { default: 10 },
|
|
53457
53459
|
minScale: { default: .5 },
|
|
53460
|
+
maxNaturalScale: { default: 1 / 0 },
|
|
53458
53461
|
clampBounds: {
|
|
53459
53462
|
type: Boolean,
|
|
53460
53463
|
default: !1
|
|
@@ -53497,7 +53500,7 @@ var wA = class extends EventTarget {
|
|
|
53497
53500
|
throw Error("Not initialized yet");
|
|
53498
53501
|
}), l = V(0), u = V(0);
|
|
53499
53502
|
F(() => {
|
|
53500
|
-
a.value && (o.value = new wA(a.value, r.offset, r.transform.translateX, r.transform.translateY, r.transform.scale, r.transform.rotate, r.minScale, r.maxScale, r.clampBounds, r.rotation), r.zoomSpeed !== void 0 && (o.value.zoomSpeed = r.zoomSpeed), r.translateSpeed !== void 0 && (o.value.translateSpeed = r.translateSpeed), r.zoomSpeedAppleTrackpad !== void 0 && (o.value.zoomSpeedAppleTrackpad = r.zoomSpeedAppleTrackpad), r.translateSpeedAppleTrackpad !== void 0 && (o.value.translateSpeedAppleTrackpad = r.translateSpeedAppleTrackpad), o.value.addEventListener("init", () => {
|
|
53503
|
+
a.value && (o.value = new wA(a.value, r.offset, r.transform.translateX, r.transform.translateY, r.transform.scale, r.transform.rotate, r.minScale, r.maxScale, r.clampBounds, r.rotation), o.value.maxNaturalScale = r.maxNaturalScale, r.zoomSpeed !== void 0 && (o.value.zoomSpeed = r.zoomSpeed), r.translateSpeed !== void 0 && (o.value.translateSpeed = r.translateSpeed), r.zoomSpeedAppleTrackpad !== void 0 && (o.value.zoomSpeedAppleTrackpad = r.zoomSpeedAppleTrackpad), r.translateSpeedAppleTrackpad !== void 0 && (o.value.translateSpeedAppleTrackpad = r.translateSpeedAppleTrackpad), o.value.addEventListener("init", () => {
|
|
53501
53504
|
i("init");
|
|
53502
53505
|
}), o.value.addEventListener("update", () => {
|
|
53503
53506
|
if (!o.value) return;
|
|
@@ -53519,6 +53522,8 @@ var wA = class extends EventTarget {
|
|
|
53519
53522
|
o.value && (o.value.minScale = e, o.value.update());
|
|
53520
53523
|
}), G(() => r.maxScale, (e) => {
|
|
53521
53524
|
o.value && (o.value.maxScale = e, o.value.update());
|
|
53525
|
+
}), G(() => r.maxNaturalScale, (e) => {
|
|
53526
|
+
o.value && (o.value.maxNaturalScale = e, o.value.update());
|
|
53522
53527
|
}), G(() => r.clampBounds, (e) => {
|
|
53523
53528
|
o.value && (o.value.clampBounds = e, o.value.setTranslateFromUserGesture(o.value.translateX, o.value.translateY), o.value.update());
|
|
53524
53529
|
}), G(() => r.rotation, (e) => {
|
|
@@ -53587,7 +53592,7 @@ var wA = class extends EventTarget {
|
|
|
53587
53592
|
canvasHeight: u.value
|
|
53588
53593
|
}, void 0, !0, 0) : f("", !0)])], 544));
|
|
53589
53594
|
}
|
|
53590
|
-
}), [["__scopeId", "data-v-
|
|
53595
|
+
}), [["__scopeId", "data-v-dfa79561"]]), OA = /* @__PURE__ */ new Set();
|
|
53591
53596
|
requestAnimationFrame(function e() {
|
|
53592
53597
|
OA.forEach((e) => e()), requestAnimationFrame(e);
|
|
53593
53598
|
});
|
|
@@ -59920,7 +59925,7 @@ var fR = ["data-overlay-id"], pR = ["data-overlay-id"], mR = /*#__PURE__*/ po(/*
|
|
|
59920
59925
|
_: 1
|
|
59921
59926
|
})], 2));
|
|
59922
59927
|
}
|
|
59923
|
-
}), [["__scopeId", "data-v-
|
|
59928
|
+
}), [["__scopeId", "data-v-ed160cc2"]]), hR = /*#__PURE__*/ po(/* @__PURE__ */ y({
|
|
59924
59929
|
__name: "MessageProvider",
|
|
59925
59930
|
setup(e, { expose: t }) {
|
|
59926
59931
|
let n = V([]), r = [
|
|
@@ -61114,30 +61119,30 @@ var qR = {
|
|
|
61114
61119
|
}), [["__scopeId", "data-v-5501b47b"]]);
|
|
61115
61120
|
//#endregion
|
|
61116
61121
|
//#region src/util/zoompinchFrame.ts
|
|
61117
|
-
function lz(e, t, n, r, i, a) {
|
|
61118
|
-
let
|
|
61122
|
+
function lz(e, t, n, r, i, a, o = V(Infinity)) {
|
|
61123
|
+
let s = (e, t) => !(e > 0) || !(t > 0) ? 1 : Math.min(i.value / e, a.value / t), c = l(() => !(n.value > 0) || !(r.value > 0) ? 1 : Math.min(s(n.value, r.value), o.value)), u = l(() => ({
|
|
61119
61124
|
width: n.value / t.value.x,
|
|
61120
61125
|
height: r.value / t.value.y
|
|
61121
|
-
})),
|
|
61122
|
-
let n =
|
|
61126
|
+
})), d = l(() => Math.min(s(u.value.width, u.value.height), o.value) / c.value), f = (e, t) => {
|
|
61127
|
+
let n = c.value * d.value, r = u.value.width * n, o = u.value.height * n, s = (i.value - r) / 2, l = (a.value - o) / 2;
|
|
61123
61128
|
return {
|
|
61124
|
-
x:
|
|
61125
|
-
y:
|
|
61126
|
-
scale:
|
|
61129
|
+
x: s - e * r,
|
|
61130
|
+
y: l - t * o,
|
|
61131
|
+
scale: d.value
|
|
61127
61132
|
};
|
|
61128
61133
|
};
|
|
61129
|
-
window.getFrameTransform =
|
|
61130
|
-
function
|
|
61131
|
-
let r =
|
|
61134
|
+
window.getFrameTransform = f;
|
|
61135
|
+
function p(t, n) {
|
|
61136
|
+
let r = f(t, n);
|
|
61132
61137
|
e.value.translateX = r.x, e.value.translateY = r.y, e.value.scale = r.scale;
|
|
61133
61138
|
}
|
|
61134
|
-
function
|
|
61139
|
+
function m() {
|
|
61135
61140
|
let n = e.value.scale, r = e.value.translateX, i = e.value.translateY, a = {
|
|
61136
61141
|
x: 0,
|
|
61137
61142
|
y: 0
|
|
61138
61143
|
}, o = Infinity;
|
|
61139
61144
|
for (let e = 0; e < t.value.x; e++) for (let s = 0; s < t.value.y; s++) {
|
|
61140
|
-
let t =
|
|
61145
|
+
let t = f(e, s), c = Math.sqrt((t.x - r) ** 2 + (t.y - i) ** 2 + (t.scale - n) ** 2);
|
|
61141
61146
|
c < o && (o = c, a = {
|
|
61142
61147
|
x: e,
|
|
61143
61148
|
y: s
|
|
@@ -61145,19 +61150,19 @@ function lz(e, t, n, r, i, a) {
|
|
|
61145
61150
|
}
|
|
61146
61151
|
return a;
|
|
61147
61152
|
}
|
|
61148
|
-
let
|
|
61153
|
+
let h = l(() => Math.abs(1 - e.value.scale / d.value));
|
|
61149
61154
|
return {
|
|
61150
|
-
frameFocusScaleDiff:
|
|
61155
|
+
frameFocusScaleDiff: h,
|
|
61151
61156
|
currentlyFocusedFrame: l(() => {
|
|
61152
|
-
if (
|
|
61157
|
+
if (h.value <= .25) return m();
|
|
61153
61158
|
}),
|
|
61154
|
-
focusFrame:
|
|
61155
|
-
getFrameTransform:
|
|
61159
|
+
focusFrame: p,
|
|
61160
|
+
getFrameTransform: f,
|
|
61156
61161
|
tiles: l(() => Array.from({ length: t.value.y }, (e, n) => Array.from({ length: t.value.x }, (e, t) => ({
|
|
61157
|
-
x: t *
|
|
61158
|
-
y: n *
|
|
61159
|
-
width:
|
|
61160
|
-
height:
|
|
61162
|
+
x: t * u.value.width,
|
|
61163
|
+
y: n * u.value.height,
|
|
61164
|
+
width: u.value.width,
|
|
61165
|
+
height: u.value.height
|
|
61161
61166
|
}))).flat())
|
|
61162
61167
|
};
|
|
61163
61168
|
}
|
|
@@ -61186,6 +61191,7 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61186
61191
|
personalizedPreviewSrc: {},
|
|
61187
61192
|
offset: {},
|
|
61188
61193
|
zoomAndPan: { type: Boolean },
|
|
61194
|
+
maxUpscale: {},
|
|
61189
61195
|
watermark: { type: Boolean },
|
|
61190
61196
|
accessibilityDescription: {},
|
|
61191
61197
|
fieldHitboxes: {},
|
|
@@ -61207,121 +61213,124 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61207
61213
|
],
|
|
61208
61214
|
setup(e, { expose: t, emit: n }) {
|
|
61209
61215
|
let r = e, i = n, o = l(() => r.fieldHitboxes ?? []), s = l(() => {
|
|
61210
|
-
|
|
61211
|
-
|
|
61216
|
+
let e = r.maxUpscale;
|
|
61217
|
+
return e !== void 0 && Number.isFinite(e) && e > 0 ? e : Infinity;
|
|
61218
|
+
}), c = l(() => {
|
|
61219
|
+
if (b.value && k.value) return k.value.y * y.value.x + k.value.x + 1;
|
|
61220
|
+
}), u = V({
|
|
61212
61221
|
translateX: 0,
|
|
61213
61222
|
translateY: 0,
|
|
61214
61223
|
scale: 1,
|
|
61215
61224
|
rotate: 0
|
|
61216
61225
|
});
|
|
61217
|
-
function
|
|
61226
|
+
function h(e) {
|
|
61218
61227
|
[
|
|
61219
61228
|
e.translateX,
|
|
61220
61229
|
e.translateY,
|
|
61221
61230
|
e.scale,
|
|
61222
61231
|
e.rotate
|
|
61223
|
-
].every(Number.isFinite) && (
|
|
61232
|
+
].every(Number.isFinite) && (u.value = e);
|
|
61224
61233
|
}
|
|
61225
|
-
let
|
|
61234
|
+
let g = T("data"), _ = V(), y = l(() => r.serial?.frames ?? {
|
|
61226
61235
|
x: 1,
|
|
61227
61236
|
y: 1
|
|
61228
|
-
}),
|
|
61237
|
+
}), b = l(() => Object.values(y.value).reduce((e, t) => t * e, 1) > 1), x = V(), S = V(), { width: C, height: w } = ao(S), { focusFrame: D, frameFocusScaleDiff: O, currentlyFocusedFrame: k, getFrameTransform: j, tiles: M } = lz(u, l(() => r.serial?.frames ?? {
|
|
61229
61238
|
x: 1,
|
|
61230
61239
|
y: 1
|
|
61231
|
-
}), l(() =>
|
|
61240
|
+
}), l(() => x.value?.canvasWidth ?? 0), l(() => x.value?.canvasHeight ?? 0), l(() => Math.max(0, C.value - r.offset.left - r.offset.right)), l(() => Math.max(0, w.value - r.offset.top - r.offset.bottom)), s), N = l(() => {
|
|
61232
61241
|
if (r.serial) return r.serial.width / r.serial.height;
|
|
61233
|
-
}), N = l(() => {
|
|
61234
|
-
if (b.value?.zoompinchEngine) return b.value.zoompinchEngine.wrapperBounds.width / b.value.zoompinchEngine.wrapperBounds.height;
|
|
61235
61242
|
}), P = l(() => {
|
|
61236
|
-
if (
|
|
61243
|
+
if (x.value?.zoompinchEngine) return x.value.zoompinchEngine.wrapperBounds.width / x.value.zoompinchEngine.wrapperBounds.height;
|
|
61244
|
+
}), F = l(() => {
|
|
61245
|
+
if (N.value && P.value) return N.value > P.value ? "width" : "height";
|
|
61237
61246
|
});
|
|
61238
61247
|
l(() => {
|
|
61239
|
-
if (
|
|
61248
|
+
if (x.value?.zoompinchEngine && N.value) return F.value === "height" ? 1 : x.value.zoompinchEngine.wrapperBounds.height / x.value.zoompinchEngine.wrapperBounds.width;
|
|
61240
61249
|
}), l(() => {
|
|
61241
|
-
if (
|
|
61250
|
+
if (x.value?.zoompinchEngine && N.value) return F.value === "width" ? 1 : x.value.zoompinchEngine.wrapperBounds.width / x.value.zoompinchEngine.wrapperBounds.height;
|
|
61242
61251
|
});
|
|
61243
|
-
let
|
|
61244
|
-
if (!
|
|
61245
|
-
let [e, t] =
|
|
61246
|
-
return
|
|
61247
|
-
}),
|
|
61248
|
-
|
|
61249
|
-
},
|
|
61250
|
-
function
|
|
61251
|
-
|
|
61252
|
-
}
|
|
61253
|
-
L(() => clearTimeout(
|
|
61254
|
-
!e &&
|
|
61252
|
+
let I = l(() => {
|
|
61253
|
+
if (!x.value?.zoompinchEngine) return;
|
|
61254
|
+
let [e, t] = x.value.zoompinchEngine.calcProjectionTranslate(1, [.5, .5], [.5, .5]);
|
|
61255
|
+
return u.value.scale !== 1 || u.value.translateX !== e || u.value.translateY !== t || u.value.rotate !== 0;
|
|
61256
|
+
}), ee = () => {
|
|
61257
|
+
x.value?.applyTransform(1, [.5, .5], [.5, .5]);
|
|
61258
|
+
}, B;
|
|
61259
|
+
function te() {
|
|
61260
|
+
ee(), requestAnimationFrame(ee), clearTimeout(B), B = setTimeout(ee, 160);
|
|
61261
|
+
}
|
|
61262
|
+
L(() => clearTimeout(B)), G(() => r.zoomAndPan, (e) => {
|
|
61263
|
+
!e && I.value && ee();
|
|
61255
61264
|
});
|
|
61256
|
-
function te(e, t) {
|
|
61257
|
-
let n = O.value?.y ?? 0;
|
|
61258
|
-
w(e, n), t.stopPropagation();
|
|
61259
|
-
}
|
|
61260
61265
|
function H(e, t) {
|
|
61261
|
-
let n =
|
|
61262
|
-
|
|
61266
|
+
let n = k.value?.y ?? 0;
|
|
61267
|
+
D(e, n), t.stopPropagation();
|
|
61263
61268
|
}
|
|
61264
|
-
function re(
|
|
61269
|
+
function re(e, t) {
|
|
61270
|
+
let n = k.value?.x ?? 0;
|
|
61271
|
+
D(n, e), t.stopPropagation();
|
|
61272
|
+
}
|
|
61273
|
+
function ie({ clientX: e, clientY: t }) {
|
|
61265
61274
|
if (r.editingElementId) return;
|
|
61266
|
-
let n =
|
|
61275
|
+
let n = x.value?.normalizeClientCoords(e, t);
|
|
61267
61276
|
if (!n) return console.error("no matrix coords. This should not happen");
|
|
61268
|
-
let i =
|
|
61269
|
-
if (
|
|
61270
|
-
let e =
|
|
61271
|
-
t && n && r ?
|
|
61272
|
-
} else
|
|
61273
|
-
}
|
|
61274
|
-
let
|
|
61275
|
-
|
|
61276
|
-
},
|
|
61277
|
+
let i = M.value.findIndex((e) => e.x <= n[0] && e.x + e.width >= n[0] && e.y <= n[1] && e.y + e.height >= n[1]), a = i % y.value.x, o = Math.floor(i / y.value.x);
|
|
61278
|
+
if (k.value) {
|
|
61279
|
+
let e = j(a, o), t = Ma(e?.scale ?? 0, 6) === Ma(u.value.scale, 6), n = Ma(e?.x ?? 0, 6) === Ma(u.value.translateX, 6), r = Ma(e?.y ?? 0, 6) === Ma(u.value.translateY, 6);
|
|
61280
|
+
t && n && r ? ee() : (console.log(Math.min(Math.max(0, a), y.value.x - 1), Math.min(Math.max(0, o), y.value.y - 1)), D(Math.min(Math.max(0, a), y.value.x - 1), Math.min(Math.max(0, o), y.value.y - 1)));
|
|
61281
|
+
} else D(Math.min(Math.max(1, a), y.value.x), Math.min(Math.max(1, o), y.value.y));
|
|
61282
|
+
}
|
|
61283
|
+
let ae = V(), oe = V(0), U = (e) => {
|
|
61284
|
+
oe.value = Math.max(oe.value, e.touches.length);
|
|
61285
|
+
}, se = (e) => {
|
|
61277
61286
|
if (e.touches.length > 0) return;
|
|
61278
|
-
let t =
|
|
61279
|
-
if (
|
|
61280
|
-
|
|
61287
|
+
let t = oe.value > 1;
|
|
61288
|
+
if (oe.value = 0, t) {
|
|
61289
|
+
ae.value = void 0;
|
|
61281
61290
|
return;
|
|
61282
61291
|
}
|
|
61283
61292
|
let n = Date.now();
|
|
61284
|
-
if (
|
|
61285
|
-
|
|
61293
|
+
if (ae.value && n - ae.value < 300) {
|
|
61294
|
+
ie({
|
|
61286
61295
|
clientX: e.changedTouches[0].clientX,
|
|
61287
61296
|
clientY: e.changedTouches[0].clientY
|
|
61288
|
-
}),
|
|
61297
|
+
}), ae.value = void 0;
|
|
61289
61298
|
return;
|
|
61290
61299
|
}
|
|
61291
|
-
|
|
61292
|
-
},
|
|
61293
|
-
function
|
|
61294
|
-
|
|
61300
|
+
ae.value = n;
|
|
61301
|
+
}, ce, le;
|
|
61302
|
+
function ue() {
|
|
61303
|
+
ce = k.value?.x ?? 1, le = k.value?.y ?? 1;
|
|
61295
61304
|
}
|
|
61296
|
-
function
|
|
61297
|
-
if (
|
|
61298
|
-
let e =
|
|
61299
|
-
|
|
61305
|
+
function de(e) {
|
|
61306
|
+
if (b.value) {
|
|
61307
|
+
let e = k.value?.x, t = k.value?.y;
|
|
61308
|
+
D(e ?? ce, t ?? le);
|
|
61300
61309
|
}
|
|
61301
61310
|
}
|
|
61302
|
-
let
|
|
61303
|
-
console.log("INIT",
|
|
61311
|
+
let fe = () => {
|
|
61312
|
+
console.log("INIT", x.value?.zoompinchEngine?.canvasBounds), x.value?.applyTransform(1, [.5, .5], [.5, .5]);
|
|
61304
61313
|
};
|
|
61305
|
-
G([
|
|
61306
|
-
e && t && n && r &&
|
|
61314
|
+
G([C, w], ([e, t], [n, r]) => {
|
|
61315
|
+
e && t && n && r && te();
|
|
61307
61316
|
});
|
|
61308
|
-
let
|
|
61309
|
-
G(
|
|
61310
|
-
|
|
61311
|
-
|
|
61317
|
+
let pe = l(() => _.value?.ready ?? !1);
|
|
61318
|
+
G(pe, () => {
|
|
61319
|
+
pe.value && setTimeout(() => {
|
|
61320
|
+
x.value?.applyTransform(1, [.5, .5], [.5, .5]);
|
|
61312
61321
|
}, 50);
|
|
61313
61322
|
});
|
|
61314
|
-
function
|
|
61315
|
-
let t =
|
|
61323
|
+
function me(e) {
|
|
61324
|
+
let t = x.value?.normalizeClientCoords(e.clientX, e.clientY);
|
|
61316
61325
|
t && r.serial && (t[0] * r.serial.width, t[1] * r.serial.height);
|
|
61317
61326
|
}
|
|
61318
|
-
let
|
|
61319
|
-
...
|
|
61320
|
-
...
|
|
61321
|
-
})),
|
|
61327
|
+
let he = V({}), ge = l(() => ({
|
|
61328
|
+
...g?.value ?? {},
|
|
61329
|
+
...he.value
|
|
61330
|
+
})), _e = l(() => {
|
|
61322
61331
|
let e = r.accessibilityDescription;
|
|
61323
61332
|
if (!e) return;
|
|
61324
|
-
let t =
|
|
61333
|
+
let t = ge.value;
|
|
61325
61334
|
return e.replace(/\{\{([^}]+)\}\}/g, (e, n) => {
|
|
61326
61335
|
let r = String(n).trim();
|
|
61327
61336
|
if (Object.prototype.hasOwnProperty.call(t, r)) {
|
|
@@ -61337,34 +61346,35 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61337
61346
|
}).replace(/\s+/g, " ").trim() || void 0;
|
|
61338
61347
|
});
|
|
61339
61348
|
return t({
|
|
61340
|
-
currentlyFocusedFrame:
|
|
61341
|
-
focusFrame:
|
|
61342
|
-
globalScope:
|
|
61343
|
-
bxLiveTemplateRef:
|
|
61344
|
-
ready:
|
|
61345
|
-
templateViewRootWidth:
|
|
61346
|
-
templateViewRootHeight:
|
|
61347
|
-
fit:
|
|
61348
|
-
needsToFit:
|
|
61349
|
-
transform:
|
|
61350
|
-
zoompinchRef:
|
|
61351
|
-
isMultiFrame:
|
|
61349
|
+
currentlyFocusedFrame: k,
|
|
61350
|
+
focusFrame: D,
|
|
61351
|
+
globalScope: he,
|
|
61352
|
+
bxLiveTemplateRef: _,
|
|
61353
|
+
ready: pe,
|
|
61354
|
+
templateViewRootWidth: C,
|
|
61355
|
+
templateViewRootHeight: w,
|
|
61356
|
+
fit: ee,
|
|
61357
|
+
needsToFit: I,
|
|
61358
|
+
transform: u,
|
|
61359
|
+
zoompinchRef: x,
|
|
61360
|
+
isMultiFrame: b
|
|
61352
61361
|
}), (t, n) => (R(), p("div", {
|
|
61353
61362
|
ref_key: "templateViewRootRef",
|
|
61354
|
-
ref:
|
|
61363
|
+
ref: S,
|
|
61355
61364
|
class: "template-view",
|
|
61356
|
-
role:
|
|
61357
|
-
"aria-label":
|
|
61358
|
-
onClick:
|
|
61359
|
-
onDblclick:
|
|
61360
|
-
onTouchstart:
|
|
61361
|
-
onTouchend:
|
|
61365
|
+
role: _e.value ? "img" : void 0,
|
|
61366
|
+
"aria-label": _e.value || void 0,
|
|
61367
|
+
onClick: me,
|
|
61368
|
+
onDblclick: ie,
|
|
61369
|
+
onTouchstart: U,
|
|
61370
|
+
onTouchend: se
|
|
61362
61371
|
}, [v(W(DA), {
|
|
61363
61372
|
ref_key: "zoompinchRef",
|
|
61364
|
-
ref:
|
|
61365
|
-
transform:
|
|
61366
|
-
"onUpdate:transform":
|
|
61373
|
+
ref: x,
|
|
61374
|
+
transform: u.value,
|
|
61375
|
+
"onUpdate:transform": h,
|
|
61367
61376
|
offset: e.offset,
|
|
61377
|
+
"max-natural-scale": s.value,
|
|
61368
61378
|
"min-scale": .1,
|
|
61369
61379
|
"max-scale": 10,
|
|
61370
61380
|
rotation: !1,
|
|
@@ -61373,16 +61383,16 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61373
61383
|
touch: e.zoomAndPan,
|
|
61374
61384
|
wheel: e.zoomAndPan,
|
|
61375
61385
|
gesture: "",
|
|
61376
|
-
onDragGestureStart:
|
|
61377
|
-
onDragGestureEnd:
|
|
61378
|
-
onInit:
|
|
61386
|
+
onDragGestureStart: ue,
|
|
61387
|
+
onDragGestureEnd: de,
|
|
61388
|
+
onInit: fe
|
|
61379
61389
|
}, {
|
|
61380
|
-
matrix: K(({ composePoint: t, canvasWidth: r, canvasHeight:
|
|
61390
|
+
matrix: K(({ composePoint: t, canvasWidth: r, canvasHeight: s, normalizeClientCoords: l }) => [
|
|
61381
61391
|
e.imageOverlays?.length ? (R(), d(cz, {
|
|
61382
61392
|
key: 0,
|
|
61383
61393
|
overlays: e.imageOverlays,
|
|
61384
61394
|
"compose-point": t,
|
|
61385
|
-
transform:
|
|
61395
|
+
transform: u.value
|
|
61386
61396
|
}, null, 8, [
|
|
61387
61397
|
"overlays",
|
|
61388
61398
|
"compose-point",
|
|
@@ -61394,15 +61404,15 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61394
61404
|
"covered-element-ids": e.coveredElementIds,
|
|
61395
61405
|
"compose-point": t,
|
|
61396
61406
|
"canvas-width": r,
|
|
61397
|
-
"canvas-height":
|
|
61407
|
+
"canvas-height": s,
|
|
61398
61408
|
"serial-width": e.serial?.width ?? e.serialWidth ?? 0,
|
|
61399
61409
|
"serial-height": e.serial?.height ?? e.serialHeight ?? 0,
|
|
61400
|
-
transform:
|
|
61401
|
-
"active-frame-index":
|
|
61410
|
+
transform: u.value,
|
|
61411
|
+
"active-frame-index": c.value,
|
|
61402
61412
|
revealed: !!e.hintsRevealed,
|
|
61403
61413
|
"text-state": e.textState,
|
|
61404
61414
|
"editing-element-id": e.editingElementId,
|
|
61405
|
-
"normalize-client-coords":
|
|
61415
|
+
"normalize-client-coords": l,
|
|
61406
61416
|
onActivateField: n[2] ||= (e) => i("activate-field", e),
|
|
61407
61417
|
onFocusField: n[3] ||= (e) => i("focus-field", e),
|
|
61408
61418
|
onHoverField: n[4] ||= (e) => i("hover-field", e),
|
|
@@ -61427,25 +61437,25 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61427
61437
|
"normalize-client-coords"
|
|
61428
61438
|
])) : f("", !0),
|
|
61429
61439
|
m("div", dz, [
|
|
61430
|
-
|
|
61440
|
+
y.value.x > 1 ? (R(), p("div", fz, [m("div", pz, [(R(!0), p(a, null, ne(y.value.x, (e) => (R(), p("div", {
|
|
61431
61441
|
class: A(["frame-dot", {
|
|
61432
|
-
active: W(
|
|
61433
|
-
disabled: !W(
|
|
61442
|
+
active: W(k)?.x === e - 1,
|
|
61443
|
+
disabled: !W(k)
|
|
61434
61444
|
}]),
|
|
61435
|
-
onClick: (t) =>
|
|
61445
|
+
onClick: (t) => H(e - 1, t)
|
|
61436
61446
|
}, null, 10, mz))), 256))])])) : f("", !0),
|
|
61437
|
-
|
|
61447
|
+
y.value.y > 1 ? (R(), p("div", hz, [m("div", gz, [(R(!0), p(a, null, ne(y.value.y, (e) => (R(), p("div", {
|
|
61438
61448
|
class: A(["frame-dot", {
|
|
61439
|
-
active: W(
|
|
61440
|
-
disabled: !W(
|
|
61449
|
+
active: W(k)?.y === e - 1,
|
|
61450
|
+
disabled: !W(k)
|
|
61441
61451
|
}]),
|
|
61442
|
-
onClick: (t) =>
|
|
61452
|
+
onClick: (t) => re(e - 1, t)
|
|
61443
61453
|
}, null, 10, _z))), 256))])])) : f("", !0),
|
|
61444
61454
|
e.watermark ? (R(), p("svg", vz, [v(MR, {
|
|
61445
|
-
width: W(
|
|
61446
|
-
height: W(
|
|
61455
|
+
width: W(C),
|
|
61456
|
+
height: W(w)
|
|
61447
61457
|
}, null, 8, ["width", "height"])])) : f("", !0),
|
|
61448
|
-
|
|
61458
|
+
I.value ? (R(), p("div", {
|
|
61449
61459
|
key: 3,
|
|
61450
61460
|
class: "fit-btn-wrapper",
|
|
61451
61461
|
onTouchstart: n[10] ||= ve(() => {}, ["stop"]),
|
|
@@ -61455,7 +61465,7 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61455
61465
|
}, [v(Ux, {
|
|
61456
61466
|
circle: "",
|
|
61457
61467
|
tertiary: "",
|
|
61458
|
-
onClick:
|
|
61468
|
+
onClick: ee
|
|
61459
61469
|
}, {
|
|
61460
61470
|
icon: K(() => [v(WC, null, {
|
|
61461
61471
|
default: K(() => [v(W(VS))]),
|
|
@@ -61467,7 +61477,7 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61467
61477
|
]),
|
|
61468
61478
|
default: K(() => [v(BR, {
|
|
61469
61479
|
ref_key: "bxLiveTemplateRef",
|
|
61470
|
-
ref:
|
|
61480
|
+
ref: _,
|
|
61471
61481
|
"bx-core-version": e.bxCoreVersion,
|
|
61472
61482
|
"cloudflare-pages-hostname": e.cloudflarePagesHostname,
|
|
61473
61483
|
"asset-proxy": e.assetProxy,
|
|
@@ -61476,10 +61486,10 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61476
61486
|
"serial-height": e.serialHeight,
|
|
61477
61487
|
preview: e.preview,
|
|
61478
61488
|
"personalized-preview-src": e.personalizedPreviewSrc,
|
|
61479
|
-
globalScope:
|
|
61480
|
-
"onUpdate:globalScope": n[0] ||= (e) =>
|
|
61481
|
-
data: W(
|
|
61482
|
-
"onUpdate:data": n[1] ||= (e) => E(
|
|
61489
|
+
globalScope: he.value,
|
|
61490
|
+
"onUpdate:globalScope": n[0] ||= (e) => he.value = e,
|
|
61491
|
+
data: W(g),
|
|
61492
|
+
"onUpdate:data": n[1] ||= (e) => E(g) ? g.value = e : null
|
|
61483
61493
|
}, null, 8, [
|
|
61484
61494
|
"bx-core-version",
|
|
61485
61495
|
"cloudflare-pages-hostname",
|
|
@@ -61496,12 +61506,13 @@ var uz = ["role", "aria-label"], dz = { class: "controls-layer" }, fz = {
|
|
|
61496
61506
|
}, 8, [
|
|
61497
61507
|
"transform",
|
|
61498
61508
|
"offset",
|
|
61509
|
+
"max-natural-scale",
|
|
61499
61510
|
"mouse",
|
|
61500
61511
|
"touch",
|
|
61501
61512
|
"wheel"
|
|
61502
61513
|
])], 40, uz));
|
|
61503
61514
|
}
|
|
61504
|
-
}), [["__scopeId", "data-v-
|
|
61515
|
+
}), [["__scopeId", "data-v-4ae63352"]]), bz = /*#__PURE__*/ po(/* @__PURE__ */ y({
|
|
61505
61516
|
__name: "SlidesNavigation",
|
|
61506
61517
|
props: /*@__PURE__*/ D({ length: {} }, {
|
|
61507
61518
|
index: { required: !0 },
|
|
@@ -72148,6 +72159,7 @@ var jK = ["data-preview"], MK = { class: "back-btn-wrapper" }, NK = {
|
|
|
72148
72159
|
bottom: 0,
|
|
72149
72160
|
left: 0
|
|
72150
72161
|
}) },
|
|
72162
|
+
liveViewMaxUpscale: {},
|
|
72151
72163
|
analytics: {},
|
|
72152
72164
|
editMode: { default: "single" },
|
|
72153
72165
|
videoBatchMaxSize: { default: 1 },
|
|
@@ -72798,6 +72810,7 @@ var jK = ["data-preview"], MK = { class: "back-btn-wrapper" }, NK = {
|
|
|
72798
72810
|
preview: e.preview,
|
|
72799
72811
|
"personalized-preview-src": e.personalizedPreviewSrc,
|
|
72800
72812
|
offset: me.value ? ie : S.value === "desktop" ? e.liveViewOffsetDesktop : e.liveViewOffsetMobile,
|
|
72813
|
+
"max-upscale": e.liveViewMaxUpscale,
|
|
72801
72814
|
"zoom-and-pan": !me.value && e.zoomAndPan,
|
|
72802
72815
|
data: ee.value,
|
|
72803
72816
|
watermark: e.watermark,
|
|
@@ -72827,6 +72840,7 @@ var jK = ["data-preview"], MK = { class: "back-btn-wrapper" }, NK = {
|
|
|
72827
72840
|
"preview",
|
|
72828
72841
|
"personalized-preview-src",
|
|
72829
72842
|
"offset",
|
|
72843
|
+
"max-upscale",
|
|
72830
72844
|
"zoom-and-pan",
|
|
72831
72845
|
"data",
|
|
72832
72846
|
"watermark",
|
|
@@ -72892,7 +72906,7 @@ var jK = ["data-preview"], MK = { class: "back-btn-wrapper" }, NK = {
|
|
|
72892
72906
|
])) : f("", !0)
|
|
72893
72907
|
], 14, jK));
|
|
72894
72908
|
}
|
|
72895
|
-
}), [["__scopeId", "data-v-
|
|
72909
|
+
}), [["__scopeId", "data-v-54f3b7c8"]]), QK = (/* @__PURE__ */ n((/* @__PURE__ */ i(((e, t) => {
|
|
72896
72910
|
function n(e) {
|
|
72897
72911
|
return e instanceof Map ? e.clear = e.delete = e.set = function() {
|
|
72898
72912
|
throw Error("map is read-only");
|