@grapesjs/studio-sdk-plugins 1.0.21-rc.1 → 1.0.21
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/canvasAbsoluteMode/index.cjs.js +1 -1
- package/dist/canvasAbsoluteMode/index.es.js +41 -41
- package/dist/canvasAbsoluteMode/index.umd.js +1 -1
- package/dist/googleFontsAssetProvider/index.cjs.js +1 -1
- package/dist/googleFontsAssetProvider/index.es.js +21 -21
- package/dist/googleFontsAssetProvider/index.umd.js +1 -1
- package/dist/googleFontsAssetProvider/shared.d.ts +3 -0
- package/dist/googleFontsAssetProvider/typesSchema.d.ts +2 -2
- package/dist/index.cjs.js +17 -17
- package/dist/index.es.js +227 -226
- package/dist/index.umd.js +15 -15
- package/dist/prosemirror/index.cjs.js +7 -7
- package/dist/prosemirror/index.es.js +109 -108
- package/dist/prosemirror/index.umd.js +7 -7
- package/dist/prosemirror/types.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -433,7 +433,7 @@ const go = (n, e) => {
|
|
|
433
433
|
t.remove(r), o.removeType(r);
|
|
434
434
|
}
|
|
435
435
|
});
|
|
436
|
-
},
|
|
436
|
+
}, py = W(ru), iu = "iconifyComponent", lu = H.startup, au = { ratioDefault: !0, tc: !1, cl: !1, cr: !1, bc: !1 }, is = `<svg viewBox="0 0 24 24">
|
|
437
437
|
<path d="M19 0H9C7.9 0 7 .9 7 2V18C7 19.1 7.9 20 9 20H19C20.1 20 21 19.1 21 18V2C21 .9 20.1 0 19 0M19 18H9V2H19V18M3 4V22C3 23.1 3.9 24 5 24H17V22H5V4H3M14 5L11 10L14 15L17 10L14 5Z" />
|
|
438
438
|
</svg>`, ga = "layout-icon-picker", cu = "icons-layout-", ya = "icons-list-layout", ba = "gs-iconify-picker", Pr = "__iconify_collection", du = "https://api.iconify.design", ls = /* @__PURE__ */ new Map();
|
|
439
439
|
let Qn;
|
|
@@ -687,7 +687,7 @@ const xu = function(n, e = {}) {
|
|
|
687
687
|
o.remove(c), t.removeType(c);
|
|
688
688
|
}
|
|
689
689
|
});
|
|
690
|
-
},
|
|
690
|
+
}, hy = W(xu);
|
|
691
691
|
function Ko(n, e, t) {
|
|
692
692
|
let o, s, r, i, l;
|
|
693
693
|
const a = e === void 0 ? 100 : e;
|
|
@@ -1380,7 +1380,7 @@ const za = "Cell settings", zu = "Merge cells", Vu = "Split cell", $u = (n) => n
|
|
|
1380
1380
|
n.off("component:select", r), n.Blocks.remove(Ie), Cu.forEach((i) => o.removeType(i));
|
|
1381
1381
|
}
|
|
1382
1382
|
});
|
|
1383
|
-
},
|
|
1383
|
+
}, fy = W(ju), qu = "listPagesComponent", Ku = H.startup, pi = "page://", pt = "list-pages", Vt = "list-pages-item", ht = "list-pages-link", Uu = (n) => n.components().reduce(
|
|
1384
1384
|
(e, t) => {
|
|
1385
1385
|
var i;
|
|
1386
1386
|
const o = t.findFirstType(ht), s = (i = o == null ? void 0 : o.attributes.attributes) == null ? void 0 : i.href, r = s != null && s.startsWith(pi) ? s.replace(pi, "") : "";
|
|
@@ -1489,7 +1489,7 @@ const za = "Cell settings", zu = "Merge cells", Vu = "Split cell", $u = (n) => n
|
|
|
1489
1489
|
t.remove(pt), o.removeType(pt);
|
|
1490
1490
|
}
|
|
1491
1491
|
});
|
|
1492
|
-
},
|
|
1492
|
+
}, my = W(Xu), Qu = "fsLightboxComponent", ep = H.startup, eo = "data-fslightbox", to = "data-type", tp = "fslightbox-open", $t = "fslightbox", Bt = {
|
|
1493
1493
|
image: '<svg viewBox="0 0 24 24"><path d="m8.5 13.5 2.5 3 3.5-4.5 4.5 6H5m16 1V5a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2Z"/></svg>',
|
|
1494
1494
|
video: '<svg viewBox="0 0 24 24"><path d="M17 10.5V7a1 1 0 0 0-1-1H4a1 1 0 0 0-1 1v10a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-3.5l4 4v-11l-4 4Z"/></svg>',
|
|
1495
1495
|
imageLightbox: '<svg viewBox="0 0 24 24"><path d="M4,2H20A2,2 0 0,1 22,4V16A2,2 0 0,1 20,18H16L12,22L8,18H4A2,2 0 0,1 2,16V4A2,2 0 0,1 4,2M19,15V7L15,11L13,9L7,15H19M7,5A2,2 0 0,0 5,7A2,2 0 0,0 7,9A2,2 0 0,0 9,7A2,2 0 0,0 7,5Z" /></svg>',
|
|
@@ -1675,7 +1675,7 @@ const za = "Cell settings", zu = "Merge cells", Vu = "Split cell", $u = (n) => n
|
|
|
1675
1675
|
t.remove($t), o.removeType($t);
|
|
1676
1676
|
}
|
|
1677
1677
|
});
|
|
1678
|
-
},
|
|
1678
|
+
}, gy = W(np), op = "lightGalleryComponent", sp = H.startup;
|
|
1679
1679
|
var Gt = /* @__PURE__ */ ((n) => (n.image = "image", n.video = "video", n.external = "external", n))(Gt || {});
|
|
1680
1680
|
const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${bo}-item`, To = "toggle", bt = {
|
|
1681
1681
|
image: '<svg viewBox="0 0 24 24"><path d="m8.5 13.5 2.5 3 3.5-4.5 4.5 6H5m16 1V5a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2Z"/></svg>',
|
|
@@ -1684,7 +1684,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
1684
1684
|
galleryItem: '<svg viewBox="0 0 24 24"><path d="M20 2H4a2 2 0 0 0-2 2v18l4-4h14a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2M8 14H6v-2h2v2m0-3H6V9h2v2m0-3H6V6h2v2m7 6h-5v-2h5v2m3-3h-8V9h8v2m0-3h-8V6h8v2Z"/></svg>',
|
|
1685
1685
|
external: '<svg viewBox="0 0 24 24"><path d="M14 3v2h3.6l-9.8 9.8 1.4 1.4L19 6.4V10h2V3m-2 16H5V5h7V3H5a2 2 0 0 0-2 2v14c0 1.1.9 2 2 2h14a2 2 0 0 0 2-2v-7h-2v7z"/></svg>',
|
|
1686
1686
|
eye: '<svg viewBox="0 0 24 24"><path d="M12 9a3 3 0 0 0-3 3 3 3 0 0 0 3 3 3 3 0 0 0 3-3 3 3 0 0 0-3-3m0 8a5 5 0 0 1-5-5 5 5 0 0 1 5-5 5 5 0 0 1 5 5 5 5 0 0 1-5 5m0-12.5C7 4.5 2.7 7.6 1 12a11.8 11.8 0 0 0 22 0c-1.7-4.4-6-7.5-11-7.5Z"/></svg>'
|
|
1687
|
-
}, cs = { propKeys: [], props: {}, traits: [] },
|
|
1687
|
+
}, cs = { propKeys: [], props: {}, traits: [] }, fn = (n, e = {}) => {
|
|
1688
1688
|
var s;
|
|
1689
1689
|
const t = {}, o = [];
|
|
1690
1690
|
for (const r in n) {
|
|
@@ -2161,7 +2161,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
2161
2161
|
!x.find((M) => M.id === S.id) && (x == null || x.unshift(S));
|
|
2162
2162
|
};
|
|
2163
2163
|
let p = [];
|
|
2164
|
-
const h = i.plugins || [], f =
|
|
2164
|
+
const h = i.plugins || [], f = fn(ip), m = h.includes(gi) ? fn(lp) : cs, g = h.includes(yi) ? fn(ap) : cs, v = h.includes(bi) ? fn(cp) : cs;
|
|
2165
2165
|
o.addType(mt, {
|
|
2166
2166
|
block: l && {
|
|
2167
2167
|
label: s,
|
|
@@ -2256,7 +2256,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
2256
2256
|
}
|
|
2257
2257
|
}
|
|
2258
2258
|
});
|
|
2259
|
-
const C =
|
|
2259
|
+
const C = fn(dp);
|
|
2260
2260
|
o.addType(hi, {
|
|
2261
2261
|
isComponent: (y) => go(y, fi) || y.tagName === "A" && go(y.parentElement, bo),
|
|
2262
2262
|
extendFn: ["init", "initToolbar"],
|
|
@@ -2311,7 +2311,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
2311
2311
|
t.remove(mt), o.removeType(mt);
|
|
2312
2312
|
}
|
|
2313
2313
|
});
|
|
2314
|
-
},
|
|
2314
|
+
}, yy = W(pp), Me = "swiper", Ln = `${Me}-slide`, Jt = `${Me}-wrapper`, Yt = `${Me}-nav-prev`, Eo = `${Me}-nav-next`, Zt = `${Me}-pagination`, kn = `${Me}-scrollbar`, le = {
|
|
2315
2315
|
slider: `<svg viewBox="0 0 24 24">
|
|
2316
2316
|
<path d="M22 7.6c0-1-.5-1.6-1.3-1.6H3.4C2.5 6 2 6.7 2 7.6v9.8c0 1 .5 1.6 1.3 1.6h17.4c.8 0 1.3-.6 1.3-1.6V7.6zM21 18H3V7h18v11z" fill-rule="nonzero"/>
|
|
2317
2317
|
<path d="M4 12.5L6 14v-3zM20 12.5L18 14v-3z"/>
|
|
@@ -2740,10 +2740,10 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
2740
2740
|
category: { id: "swiper-scrollbar", label: "Scrollbar", icon: le.scrollbar },
|
|
2741
2741
|
type: "checkbox",
|
|
2742
2742
|
label: "Enable Scrollbar",
|
|
2743
|
-
getValue: ({ component: n }) => !!n.findFirstType(
|
|
2743
|
+
getValue: ({ component: n }) => !!n.findFirstType(kn),
|
|
2744
2744
|
setValue: ({ component: n, value: e }) => {
|
|
2745
|
-
const t = n.findFirstType(
|
|
2746
|
-
t == null || t.remove(), e && n.append({ type:
|
|
2745
|
+
const t = n.findFirstType(kn);
|
|
2746
|
+
t == null || t.remove(), e && n.append({ type: kn }), n.set({ scrollbar: e });
|
|
2747
2747
|
},
|
|
2748
2748
|
subTraits: {
|
|
2749
2749
|
false: [],
|
|
@@ -2982,7 +2982,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
2982
2982
|
E(k), P(M);
|
|
2983
2983
|
}
|
|
2984
2984
|
}, d = (p = 0) => ({
|
|
2985
|
-
type:
|
|
2985
|
+
type: Ln,
|
|
2986
2986
|
style: { padding: "50px" },
|
|
2987
2987
|
components: { type: "text", components: { type: "textnode", content: `Slide ${p}` } }
|
|
2988
2988
|
}), u = t.getType("default").model;
|
|
@@ -3036,7 +3036,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3036
3036
|
var h;
|
|
3037
3037
|
const p = ((h = this.findFirstType(Jt)) == null ? void 0 : h.components().length) || 0;
|
|
3038
3038
|
return {
|
|
3039
|
-
type:
|
|
3039
|
+
type: Ln,
|
|
3040
3040
|
components: { type: "text", components: { type: "textnode", content: `Slide ${p + 1}` } }
|
|
3041
3041
|
};
|
|
3042
3042
|
},
|
|
@@ -3151,7 +3151,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3151
3151
|
};
|
|
3152
3152
|
}, vp = "Scrollbar", wi = `${pn}scrollbar`, xp = (n) => {
|
|
3153
3153
|
const { Components: e } = n;
|
|
3154
|
-
return e.addType(
|
|
3154
|
+
return e.addType(kn, {
|
|
3155
3155
|
isComponent: (t) => Pt(t, wi),
|
|
3156
3156
|
model: {
|
|
3157
3157
|
defaults: {
|
|
@@ -3168,11 +3168,11 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3168
3168
|
}
|
|
3169
3169
|
}
|
|
3170
3170
|
}), () => {
|
|
3171
|
-
e.removeType(
|
|
3171
|
+
e.removeType(kn);
|
|
3172
3172
|
};
|
|
3173
3173
|
}, Sp = "Slide", Ci = `${pn}slide`, wp = (n) => {
|
|
3174
3174
|
const { Components: e } = n;
|
|
3175
|
-
return e.addType(
|
|
3175
|
+
return e.addType(Ln, {
|
|
3176
3176
|
isComponent: (t) => Pt(t, Ci),
|
|
3177
3177
|
model: {
|
|
3178
3178
|
defaults: {
|
|
@@ -3184,7 +3184,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3184
3184
|
// TODO VIEW slide to this slide when selected
|
|
3185
3185
|
}
|
|
3186
3186
|
}), () => {
|
|
3187
|
-
e.removeType(
|
|
3187
|
+
e.removeType(Ln);
|
|
3188
3188
|
};
|
|
3189
3189
|
}, Cp = "Wrapper", ki = `${pn}wrapper`, kp = (n) => {
|
|
3190
3190
|
const { Components: e } = n, { events: t } = e;
|
|
@@ -3199,7 +3199,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3199
3199
|
removable: !1,
|
|
3200
3200
|
draggable: !1,
|
|
3201
3201
|
highlightable: !1,
|
|
3202
|
-
droppable: (o) => o.is(
|
|
3202
|
+
droppable: (o) => o.is(Ln)
|
|
3203
3203
|
},
|
|
3204
3204
|
init() {
|
|
3205
3205
|
const o = this.components();
|
|
@@ -3244,7 +3244,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3244
3244
|
o.forEach((s) => s());
|
|
3245
3245
|
}
|
|
3246
3246
|
});
|
|
3247
|
-
},
|
|
3247
|
+
}, by = W(Ep), ue = "accordion", mn = `${ue}-group`, Ge = `${ue}-header`, et = `${ue}-content`, vt = `${ue}-marker`, Ti = `${Re}${Ge}`, Gs = `${Re}${vt}`, Ap = `${Re}${et}`, Ba = `${Gs}-open`, Nt = {
|
|
3248
3248
|
accordion: '<svg viewBox="0 0 24 24"><path fill="currentColor" d="M5.616 20q-.691 0-1.153-.462T4 18.384V5.616q0-.691.463-1.153T5.616 4h12.769q.69 0 1.153.463T20 5.616v12.769q0 .69-.462 1.153T18.384 20zm0-1h12.769q.23 0 .423-.192t.192-.424V8.154H5v10.23q0 .232.192.424t.423.192"/></svg>',
|
|
3249
3249
|
accordionGroup: '<svg viewBox="0 0 24 24"><path fill="currentColor" d="M8.116 16h10.769q.23 0 .423-.192t.192-.423V6h-12v9.385q0 .23.192.423t.423.192m0 1q-.69 0-1.153-.462T6.5 15.385V4.615q0-.69.463-1.153T8.116 3h10.769q.69 0 1.153.462t.462 1.153v10.77q0 .69-.462 1.152T18.884 17zm-3 3q-.69 0-1.153-.462T3.5 18.385V6.615h1v11.77q0 .23.192.423t.423.192h11.77v1zM7.5 4v12z"/></svg>',
|
|
3250
3250
|
accordionHeader: '<svg viewBox="0 0 24 24"><path fill="currentColor" d="M5.616 20q-.691 0-1.153-.462T4 18.384V5.616q0-.691.463-1.153T5.616 4h12.769q.69 0 1.153.463T20 5.616v12.769q0 .69-.462 1.153T18.384 20zm0-1h12.769q.23 0 .423-.192t.192-.424V5.616q0-.231-.192-.424T18.384 5H5.616q-.231 0-.424.192T5 5.616v12.769q0 .23.192.423t.423.192M5 5v14zm2.616 4.192h6q.413 0 .706-.293q.294-.293.294-.707t-.294-.706q-.293-.294-.706-.294h-6q-.414 0-.707.294t-.293.706t.293.707t.707.293"/></svg>',
|
|
@@ -3374,7 +3374,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3374
3374
|
}
|
|
3375
3375
|
]
|
|
3376
3376
|
});
|
|
3377
|
-
return t.addType(
|
|
3377
|
+
return t.addType(mn, {
|
|
3378
3378
|
block: s && {
|
|
3379
3379
|
label: r,
|
|
3380
3380
|
media: Nt.accordionGroup,
|
|
@@ -3382,11 +3382,11 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3382
3382
|
select: !0,
|
|
3383
3383
|
...s
|
|
3384
3384
|
},
|
|
3385
|
-
isComponent: ct(
|
|
3385
|
+
isComponent: ct(mn),
|
|
3386
3386
|
model: {
|
|
3387
3387
|
defaults: {
|
|
3388
3388
|
name: r,
|
|
3389
|
-
attributes: { [qe]:
|
|
3389
|
+
attributes: { [qe]: mn },
|
|
3390
3390
|
droppable: Mr(ue),
|
|
3391
3391
|
single: !0,
|
|
3392
3392
|
emptyState: !0,
|
|
@@ -3411,7 +3411,7 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3411
3411
|
}
|
|
3412
3412
|
}
|
|
3413
3413
|
}), () => {
|
|
3414
|
-
o.remove(
|
|
3414
|
+
o.remove(mn), t.removeType(mn);
|
|
3415
3415
|
};
|
|
3416
3416
|
}, Ip = (n, e) => {
|
|
3417
3417
|
const { Components: t } = n;
|
|
@@ -3497,13 +3497,13 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3497
3497
|
t.forEach((o) => o());
|
|
3498
3498
|
}
|
|
3499
3499
|
});
|
|
3500
|
-
},
|
|
3500
|
+
}, vy = W(zp), In = class In {
|
|
3501
3501
|
constructor(e) {
|
|
3502
3502
|
this.config = e;
|
|
3503
3503
|
}
|
|
3504
3504
|
getSize(e) {
|
|
3505
3505
|
var t;
|
|
3506
|
-
return (t = this.config) != null && t.getSize ? this.config.getSize(e) : Rr(e.componentColumn,
|
|
3506
|
+
return (t = this.config) != null && t.getSize ? this.config.getSize(e) : Rr(e.componentColumn, In.CSS_FLEX_BASIS);
|
|
3507
3507
|
}
|
|
3508
3508
|
setSize(e) {
|
|
3509
3509
|
var t;
|
|
@@ -3511,13 +3511,13 @@ const mt = "lightGallery", hi = `${mt}-item`, bo = "data-lightgallery", fi = `${
|
|
|
3511
3511
|
this.config.setSize(e);
|
|
3512
3512
|
else {
|
|
3513
3513
|
const { componentColumn: o, sizeValue: s, partial: r } = e;
|
|
3514
|
-
o.addStyle({ [
|
|
3514
|
+
o.addStyle({ [In.CSS_FLEX_BASIS]: s }, { partial: r });
|
|
3515
3515
|
}
|
|
3516
3516
|
}
|
|
3517
3517
|
};
|
|
3518
|
-
|
|
3519
|
-
let Ws =
|
|
3520
|
-
const
|
|
3518
|
+
In.CSS_FLEX_BASIS = "flex-basis";
|
|
3519
|
+
let Ws = In;
|
|
3520
|
+
const Rn = class Rn {
|
|
3521
3521
|
constructor(e) {
|
|
3522
3522
|
this.config = e;
|
|
3523
3523
|
}
|
|
@@ -3526,7 +3526,7 @@ const In = class In {
|
|
|
3526
3526
|
}
|
|
3527
3527
|
getGap(e) {
|
|
3528
3528
|
var t;
|
|
3529
|
-
return (t = this.config) != null && t.getGap ? this.config.getGap(e) : Rr(e.componentRow,
|
|
3529
|
+
return (t = this.config) != null && t.getGap ? this.config.getGap(e) : Rr(e.componentRow, Rn.CSS_GAP);
|
|
3530
3530
|
}
|
|
3531
3531
|
setGap(e) {
|
|
3532
3532
|
var t;
|
|
@@ -3534,12 +3534,12 @@ const In = class In {
|
|
|
3534
3534
|
this.config.setGap(e);
|
|
3535
3535
|
else {
|
|
3536
3536
|
const { componentRow: o, gapValue: s, partial: r } = e;
|
|
3537
|
-
o.addStyle({ [
|
|
3537
|
+
o.addStyle({ [Rn.CSS_GAP]: s }, { partial: r });
|
|
3538
3538
|
}
|
|
3539
3539
|
}
|
|
3540
3540
|
};
|
|
3541
|
-
|
|
3542
|
-
let js =
|
|
3541
|
+
Rn.CSS_GAP = "gap";
|
|
3542
|
+
let js = Rn;
|
|
3543
3543
|
const jo = class jo {
|
|
3544
3544
|
constructor(e) {
|
|
3545
3545
|
this.config = e;
|
|
@@ -3559,7 +3559,7 @@ const jo = class jo {
|
|
|
3559
3559
|
};
|
|
3560
3560
|
jo.CSS_FLEX_DIRECTION = "flex-direction";
|
|
3561
3561
|
let qs = jo;
|
|
3562
|
-
const
|
|
3562
|
+
const Dn = class Dn {
|
|
3563
3563
|
constructor(e) {
|
|
3564
3564
|
this.config = e;
|
|
3565
3565
|
}
|
|
@@ -3567,7 +3567,7 @@ const Rn = class Rn {
|
|
|
3567
3567
|
var o;
|
|
3568
3568
|
if ((o = this.config) != null && o.getSize) return this.config.getSize(e);
|
|
3569
3569
|
const t = e.componentColumn;
|
|
3570
|
-
if (t.is(
|
|
3570
|
+
if (t.is(Dn.MJML_COLUMN_TYPE)) {
|
|
3571
3571
|
const r = t.getAttributes().width;
|
|
3572
3572
|
if (r && (r.includes("%") || !isNaN(parseFloat(r))))
|
|
3573
3573
|
return parseFloat(r);
|
|
@@ -3582,12 +3582,12 @@ const Rn = class Rn {
|
|
|
3582
3582
|
this.config.setSize(e);
|
|
3583
3583
|
else {
|
|
3584
3584
|
const { componentColumn: o, sizeValue: s, partial: r } = e;
|
|
3585
|
-
o.is(
|
|
3585
|
+
o.is(Dn.MJML_COLUMN_TYPE) && o.addAttributes({ width: `${parseFloat(s)}%` }, { partial: r });
|
|
3586
3586
|
}
|
|
3587
3587
|
}
|
|
3588
3588
|
};
|
|
3589
|
-
|
|
3590
|
-
let Ks =
|
|
3589
|
+
Dn.MJML_COLUMN_TYPE = "mj-column";
|
|
3590
|
+
let Ks = Dn;
|
|
3591
3591
|
const qo = class qo {
|
|
3592
3592
|
constructor(e) {
|
|
3593
3593
|
this.config = e;
|
|
@@ -3661,7 +3661,7 @@ const Mi = (n) => {
|
|
|
3661
3661
|
n.style.display = "none";
|
|
3662
3662
|
}, Ei = (n) => {
|
|
3663
3663
|
n.style.display = "block";
|
|
3664
|
-
},
|
|
3664
|
+
}, Tn = (n) => +parseFloat(`${n}`).toFixed(2), on = (n) => n.projectType === fa.email, ro = (n, e) => {
|
|
3665
3665
|
const t = n.Canvas.getFramesEl();
|
|
3666
3666
|
t && (t.style.pointerEvents = e ? "none" : "");
|
|
3667
3667
|
}, $p = (n) => n ? ["top", "bottom"] : ["left", "right"], Bp = (n) => {
|
|
@@ -3696,17 +3696,17 @@ const Mi = (n) => {
|
|
|
3696
3696
|
}, Pi = (n, e, t) => {
|
|
3697
3697
|
const o = Js({ componentRow: n, isVertical: e }, t), s = n.components().models;
|
|
3698
3698
|
return o * (s.length - 1);
|
|
3699
|
-
},
|
|
3699
|
+
}, zn = (n, e) => Lt(e).parentSizeHandler.isLayoutVertical({ componentRow: n }), Vn = (n, e) => Lt(e).sizeHandler.getSize(n), Js = (n, e) => {
|
|
3700
3700
|
if (e != null && e.disableGapHandler) return 0;
|
|
3701
3701
|
const { gapHandler: t, parentSizeHandler: o } = Lt(e);
|
|
3702
3702
|
if (!t.isGapSupported()) return 0;
|
|
3703
3703
|
const s = t.getGap(n), r = o.getParentSize(n);
|
|
3704
3704
|
return s / 100 * r;
|
|
3705
|
-
}, Ys = (n, e) => Lt(e).parentSizeHandler.getParentSize(n),
|
|
3705
|
+
}, Ys = (n, e) => Lt(e).parentSizeHandler.getParentSize(n), Mn = (n, e) => {
|
|
3706
3706
|
Lt(e).sizeHandler.setSize(n);
|
|
3707
3707
|
}, Fa = (n, e) => {
|
|
3708
|
-
const t =
|
|
3709
|
-
|
|
3708
|
+
const t = Vn(n, e);
|
|
3709
|
+
Mn({ ...n, sizeValue: `${t}%`, partial: !1 }, e);
|
|
3710
3710
|
}, _a = (n, e) => {
|
|
3711
3711
|
if (e != null && e.disableGapHandler) return;
|
|
3712
3712
|
const { gapHandler: t } = Lt(e);
|
|
@@ -3714,7 +3714,7 @@ const Mi = (n) => {
|
|
|
3714
3714
|
}, jp = (n, e) => {
|
|
3715
3715
|
const t = n.getStyle().gap;
|
|
3716
3716
|
if (!t) return;
|
|
3717
|
-
const o = n.components().models, s = { componentRow: n, isVertical:
|
|
3717
|
+
const o = n.components().models, s = { componentRow: n, isVertical: zn(n, e) };
|
|
3718
3718
|
o.map((r) => Fa({ ...s, componentColumn: r }, e)), _a({ ...s, gapValue: String(t), partial: !1 }, e);
|
|
3719
3719
|
};
|
|
3720
3720
|
function qp(n, e) {
|
|
@@ -3888,12 +3888,12 @@ class Xp {
|
|
|
3888
3888
|
const i = e.parent();
|
|
3889
3889
|
if (!i || !this.registry.isValidRelationship(i, e)) return;
|
|
3890
3890
|
r.snapEnabled = i.get("snap") ?? s.snapEnabled, r.snapDivisions = i.get("snap-divisions") ?? s.snapDivisions ?? 12;
|
|
3891
|
-
const l = i.components().models, a = l.findIndex((p) => p.cid === e.cid), c =
|
|
3891
|
+
const l = i.components().models, a = l.findIndex((p) => p.cid === e.cid), c = zn(i, s), d = _p(a, t, c, l.length);
|
|
3892
3892
|
d !== -1 && (r.adjacentIdx = d);
|
|
3893
3893
|
const u = { componentColumn: e, componentRow: i, isVertical: c };
|
|
3894
|
-
if (r.startPercent =
|
|
3894
|
+
if (r.startPercent = Vn(u, s), typeof r.adjacentIdx < "u") {
|
|
3895
3895
|
const p = l[r.adjacentIdx];
|
|
3896
|
-
r.neighborStartPercent =
|
|
3896
|
+
r.neighborStartPercent = Vn({ ...u, componentColumn: p }, s);
|
|
3897
3897
|
}
|
|
3898
3898
|
}
|
|
3899
3899
|
updateResizeByDelta(e, t, o) {
|
|
@@ -3901,7 +3901,7 @@ class Xp {
|
|
|
3901
3901
|
!s.resizing || !r || (s.snapEnabled ? this.updateSnapResize(e, t, o) : this.updateContinuesResize(e, t, o));
|
|
3902
3902
|
}
|
|
3903
3903
|
finishResize(e) {
|
|
3904
|
-
const t = e.parent(), o = t == null ? void 0 : t.components().models, s = { componentRow: t, isVertical: !!t &&
|
|
3904
|
+
const t = e.parent(), o = t == null ? void 0 : t.components().models, s = { componentRow: t, isVertical: !!t && zn(t, this.opts) };
|
|
3905
3905
|
o == null || o.forEach((r) => Fa({ ...s, componentColumn: r }, this.opts)), this.clearState(e);
|
|
3906
3906
|
}
|
|
3907
3907
|
updateContinuesResize(e, t, o) {
|
|
@@ -3910,13 +3910,13 @@ class Xp {
|
|
|
3910
3910
|
const l = i.minItemPercent ?? 0, a = Ao(t), c = Ys({ componentRow: r, isVertical: a }, i), d = Pi(r, a, this.opts), p = 100 - d / c * 100, h = o / (c - d) * p, { startPercent: f = 0, neighborStartPercent: m = 0 } = s, g = { componentRow: r, isVertical: a, componentColumn: e, partial: !0 }, v = Ai(t, o) ? f + Math.abs(h) : f - Math.abs(h);
|
|
3911
3911
|
if (typeof s.adjacentIdx < "u") {
|
|
3912
3912
|
const C = r.components().models[s.adjacentIdx], y = f + m, b = y - l, S = Math.min(b, Math.max(l, v)), w = y - S;
|
|
3913
|
-
|
|
3914
|
-
{ ...g, componentColumn: C, sizeValue: `${
|
|
3913
|
+
Mn({ ...g, sizeValue: `${Tn(S)}%` }, i), Mn(
|
|
3914
|
+
{ ...g, componentColumn: C, sizeValue: `${Tn(w)}%` },
|
|
3915
3915
|
i
|
|
3916
3916
|
);
|
|
3917
3917
|
} else {
|
|
3918
3918
|
const C = Math.max(l, Math.min(p, v));
|
|
3919
|
-
|
|
3919
|
+
Mn({ ...g, sizeValue: `${Tn(C)}%` }, i);
|
|
3920
3920
|
}
|
|
3921
3921
|
}
|
|
3922
3922
|
updateSnapResize(e, t, o) {
|
|
@@ -3935,16 +3935,16 @@ class Qp {
|
|
|
3935
3935
|
updateGapByDelta(e, t, o, s) {
|
|
3936
3936
|
if (!this.registry.isGapAdjustableParent(e)) return;
|
|
3937
3937
|
const { opts: r } = this, i = Math.max(0, o + t), l = Ys({ componentRow: e, isVertical: s }, r), a = i / l * 100, c = e.components().models, d = c.length - 1, u = { componentRow: e, isVertical: s }, p = c.reduce(
|
|
3938
|
-
(b, x) => b +
|
|
3938
|
+
(b, x) => b + Vn({ ...u, componentColumn: x }, r),
|
|
3939
3939
|
0
|
|
3940
3940
|
), f = 100 - a * d, m = r.minItemPercent || 5;
|
|
3941
3941
|
if (f < m * c.length)
|
|
3942
3942
|
return;
|
|
3943
3943
|
const v = 100 - d * a, C = p - v, y = { componentRow: e, isVertical: s, partial: !0 };
|
|
3944
3944
|
c.map((b) => {
|
|
3945
|
-
const x =
|
|
3946
|
-
|
|
3947
|
-
}), _a({ ...y, gapValue: `${
|
|
3945
|
+
const x = Vn({ ...u, componentColumn: b }, r), S = x - x / p * C;
|
|
3946
|
+
Mn({ ...y, componentColumn: b, sizeValue: `${Tn(S)}%` }, r);
|
|
3947
|
+
}), _a({ ...y, gapValue: `${Tn(a)}%` }, r);
|
|
3948
3948
|
}
|
|
3949
3949
|
finishGapAdjust(e) {
|
|
3950
3950
|
jp(e, this.opts);
|
|
@@ -4028,7 +4028,7 @@ function nh(n, e) {
|
|
|
4028
4028
|
if (!c) return;
|
|
4029
4029
|
const w = c;
|
|
4030
4030
|
ro(n, !0), S.stopPropagation(), S.preventDefault();
|
|
4031
|
-
const M =
|
|
4031
|
+
const M = zn(w, e), k = Js({ componentRow: w, isVertical: M }, e), E = S.clientX, P = S.clientY;
|
|
4032
4032
|
S.target.setPointerCapture(S.pointerId);
|
|
4033
4033
|
const O = (D) => {
|
|
4034
4034
|
const V = n.Canvas.getZoomMultiplier(), J = M ? (D.clientY - P) * V : (D.clientX - E) * V;
|
|
@@ -4044,7 +4044,7 @@ function nh(n, e) {
|
|
|
4044
4044
|
Ei(s);
|
|
4045
4045
|
const k = S.getStyle();
|
|
4046
4046
|
r && Object.assign(r.style, k);
|
|
4047
|
-
const E =
|
|
4047
|
+
const E = zn(M, e), P = $p(E);
|
|
4048
4048
|
if (Object.values(i).forEach(Mi), P.forEach((N) => {
|
|
4049
4049
|
if (Gp(w, N)) return;
|
|
4050
4050
|
const D = i[N];
|
|
@@ -4102,7 +4102,7 @@ const oh = function(n, e = {}) {
|
|
|
4102
4102
|
o.forEach((i) => i == null ? void 0 : i()), s(), r == null || r();
|
|
4103
4103
|
}
|
|
4104
4104
|
});
|
|
4105
|
-
},
|
|
4105
|
+
}, xy = W(oh), sh = (n) => n.dispatchEvent(new CustomEvent("input"));
|
|
4106
4106
|
function rh(n, e) {
|
|
4107
4107
|
if (!e) return () => {
|
|
4108
4108
|
};
|
|
@@ -4347,7 +4347,7 @@ const ih = "rteTinyMce", lh = H.startup, ah = `
|
|
|
4347
4347
|
n.RichTextEditor.customRte = void 0, c();
|
|
4348
4348
|
}
|
|
4349
4349
|
});
|
|
4350
|
-
},
|
|
4350
|
+
}, Sy = W(hh);
|
|
4351
4351
|
function X(n) {
|
|
4352
4352
|
this.content = n;
|
|
4353
4353
|
}
|
|
@@ -5019,7 +5019,7 @@ function Ct(n, e) {
|
|
|
5019
5019
|
let t = e.length - 1;
|
|
5020
5020
|
t >= 0 && n.isText && n.sameMarkup(e[t]) ? e[t] = n.withText(e[t].text + n.text) : e.push(n);
|
|
5021
5021
|
}
|
|
5022
|
-
function
|
|
5022
|
+
function En(n, e, t, o) {
|
|
5023
5023
|
let s = (e || n).node(t), r = 0, i = e ? e.index(t) : s.childCount;
|
|
5024
5024
|
n && (r = n.index(t), n.depth > t ? r++ : n.textOffset && (Ct(n.nodeAfter, o), r++));
|
|
5025
5025
|
for (let l = r; l < i; l++)
|
|
@@ -5031,15 +5031,15 @@ function kt(n, e) {
|
|
|
5031
5031
|
}
|
|
5032
5032
|
function Ja(n, e, t, o, s) {
|
|
5033
5033
|
let r = n.depth > s && Zs(n, e, s + 1), i = o.depth > s && Zs(t, o, s + 1), l = [];
|
|
5034
|
-
return
|
|
5034
|
+
return En(null, n, s, l), r && i && e.index(s) == t.index(s) ? (Ua(r, i), Ct(kt(r, Ja(n, e, t, o, s + 1)), l)) : (r && Ct(kt(r, Io(n, e, s + 1)), l), En(e, t, s, l), i && Ct(kt(i, Io(t, o, s + 1)), l)), En(o, null, s, l), new T(l);
|
|
5035
5035
|
}
|
|
5036
5036
|
function Io(n, e, t) {
|
|
5037
5037
|
let o = [];
|
|
5038
|
-
if (
|
|
5038
|
+
if (En(null, n, t, o), n.depth > t) {
|
|
5039
5039
|
let s = Zs(n, e, t + 1);
|
|
5040
5040
|
Ct(kt(s, Io(n, e, t + 1)), o);
|
|
5041
5041
|
}
|
|
5042
|
-
return
|
|
5042
|
+
return En(e, null, t, o), new T(o);
|
|
5043
5043
|
}
|
|
5044
5044
|
function mh(n, e) {
|
|
5045
5045
|
let t = e.depth - n.openStart, s = e.node(t).copy(n.content);
|
|
@@ -5050,7 +5050,7 @@ function mh(n, e) {
|
|
|
5050
5050
|
end: s.resolveNoCache(s.content.size - n.openEnd - t)
|
|
5051
5051
|
};
|
|
5052
5052
|
}
|
|
5053
|
-
class
|
|
5053
|
+
class $n {
|
|
5054
5054
|
/**
|
|
5055
5055
|
@internal
|
|
5056
5056
|
*/
|
|
@@ -5278,7 +5278,7 @@ class Vn {
|
|
|
5278
5278
|
break;
|
|
5279
5279
|
r = c - 1, s += a + 1;
|
|
5280
5280
|
}
|
|
5281
|
-
return new
|
|
5281
|
+
return new $n(t, o, r);
|
|
5282
5282
|
}
|
|
5283
5283
|
/**
|
|
5284
5284
|
@internal
|
|
@@ -5293,7 +5293,7 @@ class Vn {
|
|
|
5293
5293
|
}
|
|
5294
5294
|
else
|
|
5295
5295
|
Ri.set(e, o = new gh());
|
|
5296
|
-
let s = o.elts[o.i] =
|
|
5296
|
+
let s = o.elts[o.i] = $n.resolve(e, t);
|
|
5297
5297
|
return o.i = (o.i + 1) % yh, s;
|
|
5298
5298
|
}
|
|
5299
5299
|
}
|
|
@@ -5548,13 +5548,13 @@ let Tt = class Xs {
|
|
|
5548
5548
|
[object](https://prosemirror.net/docs/ref/#model.ResolvedPos) with information about its context.
|
|
5549
5549
|
*/
|
|
5550
5550
|
resolve(e) {
|
|
5551
|
-
return
|
|
5551
|
+
return $n.resolveCached(this, e);
|
|
5552
5552
|
}
|
|
5553
5553
|
/**
|
|
5554
5554
|
@internal
|
|
5555
5555
|
*/
|
|
5556
5556
|
resolveNoCache(e) {
|
|
5557
|
-
return
|
|
5557
|
+
return $n.resolve(this, e);
|
|
5558
5558
|
}
|
|
5559
5559
|
/**
|
|
5560
5560
|
Test whether a given mark or mark type occurs in this document
|
|
@@ -6651,13 +6651,13 @@ const sc = {
|
|
|
6651
6651
|
script: !0,
|
|
6652
6652
|
style: !0,
|
|
6653
6653
|
title: !0
|
|
6654
|
-
}, rc = { ol: !0, ul: !0 }, Lo = 1, zo = 2,
|
|
6654
|
+
}, rc = { ol: !0, ul: !0 }, Lo = 1, zo = 2, An = 4;
|
|
6655
6655
|
function $i(n, e, t) {
|
|
6656
|
-
return e != null ? (e ? Lo : 0) | (e === "full" ? zo : 0) : n && n.whitespace == "pre" ? Lo | zo : t & ~
|
|
6656
|
+
return e != null ? (e ? Lo : 0) | (e === "full" ? zo : 0) : n && n.whitespace == "pre" ? Lo | zo : t & ~An;
|
|
6657
6657
|
}
|
|
6658
6658
|
class ao {
|
|
6659
6659
|
constructor(e, t, o, s, r, i) {
|
|
6660
|
-
this.type = e, this.attrs = t, this.marks = o, this.solid = s, this.options = i, this.content = [], this.activeMarks = B.none, this.match = r || (i &
|
|
6660
|
+
this.type = e, this.attrs = t, this.marks = o, this.solid = s, this.options = i, this.content = [], this.activeMarks = B.none, this.match = r || (i & An ? null : e.contentMatch);
|
|
6661
6661
|
}
|
|
6662
6662
|
findWrapping(e) {
|
|
6663
6663
|
if (!this.match) {
|
|
@@ -6691,7 +6691,7 @@ class ao {
|
|
|
6691
6691
|
class Bi {
|
|
6692
6692
|
constructor(e, t, o) {
|
|
6693
6693
|
this.parser = e, this.options = t, this.isOpen = o, this.open = 0;
|
|
6694
|
-
let s = t.topNode, r, i = $i(null, t.preserveWhitespace, 0) | (o ?
|
|
6694
|
+
let s = t.topNode, r, i = $i(null, t.preserveWhitespace, 0) | (o ? An : 0);
|
|
6695
6695
|
s ? r = new ao(s.type, s.attrs, B.none, !0, t.topMatch || s.type.contentMatch, i) : o ? r = new ao(null, null, B.none, !0, null, i) : r = new ao(e.schema.topNodeType, null, B.none, !0, null, i), this.nodes = [r], this.find = t.findPositions, this.needsBlock = !1;
|
|
6696
6696
|
}
|
|
6697
6697
|
get top() {
|
|
@@ -6858,7 +6858,7 @@ class Bi {
|
|
|
6858
6858
|
let i = this.top;
|
|
6859
6859
|
i.match = i.match && i.match.matchType(e);
|
|
6860
6860
|
let l = $i(e, r, i.options);
|
|
6861
|
-
i.options &
|
|
6861
|
+
i.options & An && i.content.length == 0 && (l |= An);
|
|
6862
6862
|
let a = B.none;
|
|
6863
6863
|
return o = o.filter((c) => (i.type ? i.type.allowsMarkType(c.type) : Fi(c.type, e)) ? (a = c.addToSet(a), !1) : !0), this.nodes.push(new ao(e, t, a, s, null, l)), this.open++, o;
|
|
6864
6864
|
}
|
|
@@ -8135,9 +8135,9 @@ class nf {
|
|
|
8135
8135
|
let { content: e, openStart: t, openEnd: o } = this.unplaced, s = ms(e, t);
|
|
8136
8136
|
if (s.childCount <= 1 && t > 0) {
|
|
8137
8137
|
let r = e.size - t <= t + s.size;
|
|
8138
|
-
this.unplaced = new A(
|
|
8138
|
+
this.unplaced = new A(Sn(e, t - 1, 1), t - 1, r ? t - 1 : o);
|
|
8139
8139
|
} else
|
|
8140
|
-
this.unplaced = new A(
|
|
8140
|
+
this.unplaced = new A(Sn(e, t, 1), t, o);
|
|
8141
8141
|
}
|
|
8142
8142
|
// Move content from the unplaced slice at `sliceDepth` to the
|
|
8143
8143
|
// frontier node at `frontierDepth`. Close that frontier node when
|
|
@@ -8162,12 +8162,12 @@ class nf {
|
|
|
8162
8162
|
c++, (c > 1 || a == 0 || m.content.size) && (u = g, d.push(mc(m.mark(p.allowedMarks(m.marks)), c == 1 ? a : 0, c == l.childCount ? h : -1)));
|
|
8163
8163
|
}
|
|
8164
8164
|
let f = c == l.childCount;
|
|
8165
|
-
f || (h = -1), this.placed =
|
|
8165
|
+
f || (h = -1), this.placed = wn(this.placed, t, T.from(d)), this.frontier[t].match = u, f && h < 0 && o && o.type == this.frontier[this.depth].type && this.frontier.length > 1 && this.closeFrontierNode();
|
|
8166
8166
|
for (let m = 0, g = l; m < h; m++) {
|
|
8167
8167
|
let v = g.lastChild;
|
|
8168
8168
|
this.frontier.push({ type: v.type, match: v.contentMatchAt(v.childCount) }), g = v.content;
|
|
8169
8169
|
}
|
|
8170
|
-
this.unplaced = f ? e == 0 ? A.empty : new A(
|
|
8170
|
+
this.unplaced = f ? e == 0 ? A.empty : new A(Sn(i.content, e - 1, 1), e - 1, h < 0 ? i.openEnd : e - 1) : new A(Sn(i.content, e, c), i.openStart, i.openEnd);
|
|
8171
8171
|
}
|
|
8172
8172
|
mustMoveInline() {
|
|
8173
8173
|
if (!this.$to.parent.isTextblock)
|
|
@@ -8199,7 +8199,7 @@ class nf {
|
|
|
8199
8199
|
return null;
|
|
8200
8200
|
for (; this.depth > t.depth; )
|
|
8201
8201
|
this.closeFrontierNode();
|
|
8202
|
-
t.fit.childCount && (this.placed =
|
|
8202
|
+
t.fit.childCount && (this.placed = wn(this.placed, t.depth, t.fit)), e = t.move;
|
|
8203
8203
|
for (let o = t.depth + 1; o <= e.depth; o++) {
|
|
8204
8204
|
let s = e.node(o), r = s.type.contentMatch.fillBefore(s.content, !0, e.index(o));
|
|
8205
8205
|
this.openFrontierNode(s.type, s.attrs, r);
|
|
@@ -8208,18 +8208,18 @@ class nf {
|
|
|
8208
8208
|
}
|
|
8209
8209
|
openFrontierNode(e, t = null, o) {
|
|
8210
8210
|
let s = this.frontier[this.depth];
|
|
8211
|
-
s.match = s.match.matchType(e), this.placed =
|
|
8211
|
+
s.match = s.match.matchType(e), this.placed = wn(this.placed, this.depth, T.from(e.create(t, o))), this.frontier.push({ type: e, match: e.contentMatch });
|
|
8212
8212
|
}
|
|
8213
8213
|
closeFrontierNode() {
|
|
8214
8214
|
let t = this.frontier.pop().match.fillBefore(T.empty, !0);
|
|
8215
|
-
t.childCount && (this.placed =
|
|
8215
|
+
t.childCount && (this.placed = wn(this.placed, this.frontier.length, t));
|
|
8216
8216
|
}
|
|
8217
8217
|
}
|
|
8218
|
-
function xn(n, e, t) {
|
|
8219
|
-
return e == 0 ? n.cutByIndex(t, n.childCount) : n.replaceChild(0, n.firstChild.copy(xn(n.firstChild.content, e - 1, t)));
|
|
8220
|
-
}
|
|
8221
8218
|
function Sn(n, e, t) {
|
|
8222
|
-
return e == 0 ? n.
|
|
8219
|
+
return e == 0 ? n.cutByIndex(t, n.childCount) : n.replaceChild(0, n.firstChild.copy(Sn(n.firstChild.content, e - 1, t)));
|
|
8220
|
+
}
|
|
8221
|
+
function wn(n, e, t) {
|
|
8222
|
+
return e == 0 ? n.append(t) : n.replaceChild(n.childCount - 1, n.lastChild.copy(wn(n.lastChild.content, e - 1, t)));
|
|
8223
8223
|
}
|
|
8224
8224
|
function ms(n, e) {
|
|
8225
8225
|
for (let t = 0; t < e; t++)
|
|
@@ -8375,7 +8375,7 @@ class en extends ie {
|
|
|
8375
8375
|
}
|
|
8376
8376
|
}
|
|
8377
8377
|
ie.jsonID("attr", en);
|
|
8378
|
-
class
|
|
8378
|
+
class Bn extends ie {
|
|
8379
8379
|
/**
|
|
8380
8380
|
Construct an attribute step.
|
|
8381
8381
|
*/
|
|
@@ -8394,7 +8394,7 @@ class $n extends ie {
|
|
|
8394
8394
|
return me.empty;
|
|
8395
8395
|
}
|
|
8396
8396
|
invert(e) {
|
|
8397
|
-
return new
|
|
8397
|
+
return new Bn(this.attr, e.attrs[this.attr]);
|
|
8398
8398
|
}
|
|
8399
8399
|
map(e) {
|
|
8400
8400
|
return this;
|
|
@@ -8405,10 +8405,10 @@ class $n extends ie {
|
|
|
8405
8405
|
static fromJSON(e, t) {
|
|
8406
8406
|
if (typeof t.attr != "string")
|
|
8407
8407
|
throw new RangeError("Invalid input for DocAttrStep.fromJSON");
|
|
8408
|
-
return new
|
|
8408
|
+
return new Bn(t.attr, t.value);
|
|
8409
8409
|
}
|
|
8410
8410
|
}
|
|
8411
|
-
ie.jsonID("docAttr",
|
|
8411
|
+
ie.jsonID("docAttr", Bn);
|
|
8412
8412
|
let ln = class extends Error {
|
|
8413
8413
|
};
|
|
8414
8414
|
ln = function n(e) {
|
|
@@ -8581,7 +8581,7 @@ class bc {
|
|
|
8581
8581
|
Set a single attribute on the document to a new value.
|
|
8582
8582
|
*/
|
|
8583
8583
|
setDocAttribute(e, t) {
|
|
8584
|
-
return this.step(new
|
|
8584
|
+
return this.step(new Bn(e, t)), this;
|
|
8585
8585
|
}
|
|
8586
8586
|
/**
|
|
8587
8587
|
Add a mark to the node at position `pos`.
|
|
@@ -9188,13 +9188,13 @@ class df extends bc {
|
|
|
9188
9188
|
function Zi(n, e) {
|
|
9189
9189
|
return !e || !n ? n : n.bind(e);
|
|
9190
9190
|
}
|
|
9191
|
-
class
|
|
9191
|
+
class Cn {
|
|
9192
9192
|
constructor(e, t, o) {
|
|
9193
9193
|
this.name = e, this.init = Zi(t.init, o), this.apply = Zi(t.apply, o);
|
|
9194
9194
|
}
|
|
9195
9195
|
}
|
|
9196
9196
|
const uf = [
|
|
9197
|
-
new
|
|
9197
|
+
new Cn("doc", {
|
|
9198
9198
|
init(n) {
|
|
9199
9199
|
return n.doc || n.schema.topNodeType.createAndFill();
|
|
9200
9200
|
},
|
|
@@ -9202,7 +9202,7 @@ const uf = [
|
|
|
9202
9202
|
return n.doc;
|
|
9203
9203
|
}
|
|
9204
9204
|
}),
|
|
9205
|
-
new
|
|
9205
|
+
new Cn("selection", {
|
|
9206
9206
|
init(n, e) {
|
|
9207
9207
|
return n.selection || L.atStart(e.doc);
|
|
9208
9208
|
},
|
|
@@ -9210,7 +9210,7 @@ const uf = [
|
|
|
9210
9210
|
return n.selection;
|
|
9211
9211
|
}
|
|
9212
9212
|
}),
|
|
9213
|
-
new
|
|
9213
|
+
new Cn("storedMarks", {
|
|
9214
9214
|
init(n) {
|
|
9215
9215
|
return n.storedMarks || null;
|
|
9216
9216
|
},
|
|
@@ -9218,7 +9218,7 @@ const uf = [
|
|
|
9218
9218
|
return o.selection.$cursor ? n.storedMarks : null;
|
|
9219
9219
|
}
|
|
9220
9220
|
}),
|
|
9221
|
-
new
|
|
9221
|
+
new Cn("scrollToSelection", {
|
|
9222
9222
|
init() {
|
|
9223
9223
|
return 0;
|
|
9224
9224
|
},
|
|
@@ -9232,7 +9232,7 @@ class bs {
|
|
|
9232
9232
|
this.schema = e, this.plugins = [], this.pluginsByKey = /* @__PURE__ */ Object.create(null), this.fields = uf.slice(), t && t.forEach((o) => {
|
|
9233
9233
|
if (this.pluginsByKey[o.key])
|
|
9234
9234
|
throw new RangeError("Adding different instances of a keyed plugin (" + o.key + ")");
|
|
9235
|
-
this.plugins.push(o), this.pluginsByKey[o.key] = o, o.spec.state && this.fields.push(new
|
|
9235
|
+
this.plugins.push(o), this.pluginsByKey[o.key] = o, o.spec.state && this.fields.push(new Cn(o.key, o.spec.state, o));
|
|
9236
9236
|
});
|
|
9237
9237
|
}
|
|
9238
9238
|
}
|
|
@@ -9408,7 +9408,7 @@ function xc(n, e, t) {
|
|
|
9408
9408
|
}
|
|
9409
9409
|
return t;
|
|
9410
9410
|
}
|
|
9411
|
-
class
|
|
9411
|
+
class hn {
|
|
9412
9412
|
/**
|
|
9413
9413
|
Create a plugin.
|
|
9414
9414
|
*/
|
|
@@ -9760,7 +9760,7 @@ function gt(n, e = null, t) {
|
|
|
9760
9760
|
return !0;
|
|
9761
9761
|
};
|
|
9762
9762
|
}
|
|
9763
|
-
function
|
|
9763
|
+
function Hn(...n) {
|
|
9764
9764
|
return function(e, t, o) {
|
|
9765
9765
|
for (let s = 0; s < n.length; s++)
|
|
9766
9766
|
if (n[s](e, t, o))
|
|
@@ -9768,9 +9768,9 @@ function Bn(...n) {
|
|
|
9768
9768
|
return !1;
|
|
9769
9769
|
};
|
|
9770
9770
|
}
|
|
9771
|
-
let xs =
|
|
9771
|
+
let xs = Hn(wc, hf, ff), Xi = Hn(wc, gf, yf);
|
|
9772
9772
|
const _e = {
|
|
9773
|
-
Enter:
|
|
9773
|
+
Enter: Hn(bf, vf, Mc, xf),
|
|
9774
9774
|
"Mod-Enter": Tc,
|
|
9775
9775
|
Backspace: xs,
|
|
9776
9776
|
"Mod-Backspace": xs,
|
|
@@ -10094,7 +10094,7 @@ function zf(n = {}) {
|
|
|
10094
10094
|
return n = {
|
|
10095
10095
|
depth: n.depth || 100,
|
|
10096
10096
|
newGroupDelay: n.newGroupDelay || 500
|
|
10097
|
-
}, new
|
|
10097
|
+
}, new hn({
|
|
10098
10098
|
key: Mt,
|
|
10099
10099
|
state: {
|
|
10100
10100
|
init() {
|
|
@@ -10248,7 +10248,7 @@ function ks(n, e, t = !0) {
|
|
|
10248
10248
|
return e.altKey && (n = "Alt-" + n), e.ctrlKey && (n = "Ctrl-" + n), e.metaKey && (n = "Meta-" + n), t && e.shiftKey && (n = "Shift-" + n), n;
|
|
10249
10249
|
}
|
|
10250
10250
|
function Ts(n) {
|
|
10251
|
-
return new
|
|
10251
|
+
return new hn({ props: { handleKeyDown: Lc(n) } });
|
|
10252
10252
|
}
|
|
10253
10253
|
function Lc(n) {
|
|
10254
10254
|
let e = _f(n);
|
|
@@ -10380,7 +10380,7 @@ const ee = function(n) {
|
|
|
10380
10380
|
for (var e = 0; ; e++)
|
|
10381
10381
|
if (n = n.previousSibling, !n)
|
|
10382
10382
|
return e;
|
|
10383
|
-
},
|
|
10383
|
+
}, Fn = function(n) {
|
|
10384
10384
|
let e = n.assignedSlot || n.parentNode;
|
|
10385
10385
|
return e && e.nodeType == 11 ? e.host : e;
|
|
10386
10386
|
};
|
|
@@ -10515,7 +10515,7 @@ function sm(n) {
|
|
|
10515
10515
|
}
|
|
10516
10516
|
function sl(n, e, t) {
|
|
10517
10517
|
let o = n.someProp("scrollThreshold") || 0, s = n.someProp("scrollMargin") || 5, r = n.dom.ownerDocument;
|
|
10518
|
-
for (let i = t || n.dom; i; i =
|
|
10518
|
+
for (let i = t || n.dom; i; i = Fn(i)) {
|
|
10519
10519
|
if (i.nodeType != 1)
|
|
10520
10520
|
continue;
|
|
10521
10521
|
let l = i, a = l == r.body, c = a ? om(r) : sm(l), d = 0, u = 0;
|
|
@@ -10548,7 +10548,7 @@ function rm(n) {
|
|
|
10548
10548
|
}
|
|
10549
10549
|
function $c(n) {
|
|
10550
10550
|
let e = [], t = n.ownerDocument;
|
|
10551
|
-
for (let o = n; o && (e.push({ dom: o, top: o.scrollTop, left: o.scrollLeft }), n != t); o =
|
|
10551
|
+
for (let o = n; o && (e.push({ dom: o, top: o.scrollTop, left: o.scrollLeft }), n != t); o = Fn(o))
|
|
10552
10552
|
;
|
|
10553
10553
|
return e;
|
|
10554
10554
|
}
|
|
@@ -10671,7 +10671,7 @@ function pm(n, e) {
|
|
|
10671
10671
|
return null;
|
|
10672
10672
|
}
|
|
10673
10673
|
if (ae)
|
|
10674
|
-
for (let c = i; o && c; c =
|
|
10674
|
+
for (let c = i; o && c; c = Fn(c))
|
|
10675
10675
|
c.draggable && (o = void 0);
|
|
10676
10676
|
if (i = cm(i, e), o) {
|
|
10677
10677
|
if (Ee && o.nodeType == 1 && (s = Math.min(s, o.childNodes.length), s < o.childNodes.length)) {
|
|
@@ -10708,13 +10708,13 @@ function _c(n, e, t) {
|
|
|
10708
10708
|
if (c.top == a.top) {
|
|
10709
10709
|
let d = Ue(Fe(o, s, s + 1), -1);
|
|
10710
10710
|
if (d.top != a.top)
|
|
10711
|
-
return
|
|
10711
|
+
return gn(d, d.left < c.left);
|
|
10712
10712
|
}
|
|
10713
10713
|
}
|
|
10714
10714
|
return a;
|
|
10715
10715
|
} else {
|
|
10716
10716
|
let a = s, c = s, d = t < 0 ? 1 : -1;
|
|
10717
|
-
return t < 0 && !s ? (c++, d = -1) : t >= 0 && s == o.nodeValue.length ? (a--, d = 1) : t < 0 ? a-- : c++,
|
|
10717
|
+
return t < 0 && !s ? (c++, d = -1) : t >= 0 && s == o.nodeValue.length ? (a--, d = 1) : t < 0 ? a-- : c++, gn(Ue(Fe(o, a, c), d), d < 0);
|
|
10718
10718
|
}
|
|
10719
10719
|
if (!n.state.doc.resolve(e - (r || 0)).parent.inlineContent) {
|
|
10720
10720
|
if (r == null && s && (t < 0 || s == Se(o))) {
|
|
@@ -10732,7 +10732,7 @@ function _c(n, e, t) {
|
|
|
10732
10732
|
if (r == null && s && (t < 0 || s == Se(o))) {
|
|
10733
10733
|
let a = o.childNodes[s - 1], c = a.nodeType == 3 ? Fe(a, Se(a) - (i ? 0 : 1)) : a.nodeType == 1 && (a.nodeName != "BR" || !a.nextSibling) ? a : null;
|
|
10734
10734
|
if (c)
|
|
10735
|
-
return
|
|
10735
|
+
return gn(Ue(c, 1), !1);
|
|
10736
10736
|
}
|
|
10737
10737
|
if (r == null && s < Se(o)) {
|
|
10738
10738
|
let a = o.childNodes[s];
|
|
@@ -10740,11 +10740,11 @@ function _c(n, e, t) {
|
|
|
10740
10740
|
a = a.nextSibling;
|
|
10741
10741
|
let c = a ? a.nodeType == 3 ? Fe(a, 0, i ? 0 : 1) : a.nodeType == 1 ? a : null : null;
|
|
10742
10742
|
if (c)
|
|
10743
|
-
return
|
|
10743
|
+
return gn(Ue(c, -1), !0);
|
|
10744
10744
|
}
|
|
10745
|
-
return
|
|
10745
|
+
return gn(Ue(o.nodeType == 3 ? Fe(o) : o, -t), t >= 0);
|
|
10746
10746
|
}
|
|
10747
|
-
function
|
|
10747
|
+
function gn(n, e) {
|
|
10748
10748
|
if (n.width == 0)
|
|
10749
10749
|
return n;
|
|
10750
10750
|
let t = e ? n.left : n.right;
|
|
@@ -11488,22 +11488,22 @@ function qc(n, e, t) {
|
|
|
11488
11488
|
o = ul(o), s = !0;
|
|
11489
11489
|
s && t.trackWrites == n && (t.trackWrites = null);
|
|
11490
11490
|
}
|
|
11491
|
-
const
|
|
11491
|
+
const Pn = function(n) {
|
|
11492
11492
|
n && (this.nodeName = n);
|
|
11493
11493
|
};
|
|
11494
|
-
|
|
11495
|
-
const St = [new
|
|
11494
|
+
Pn.prototype = /* @__PURE__ */ Object.create(null);
|
|
11495
|
+
const St = [new Pn()];
|
|
11496
11496
|
function lr(n, e, t) {
|
|
11497
11497
|
if (n.length == 0)
|
|
11498
11498
|
return St;
|
|
11499
|
-
let o = t ? St[0] : new
|
|
11499
|
+
let o = t ? St[0] : new Pn(), s = [o];
|
|
11500
11500
|
for (let r = 0; r < n.length; r++) {
|
|
11501
11501
|
let i = n[r].type.attrs;
|
|
11502
11502
|
if (i) {
|
|
11503
|
-
i.nodeName && s.push(o = new
|
|
11503
|
+
i.nodeName && s.push(o = new Pn(i.nodeName));
|
|
11504
11504
|
for (let l in i) {
|
|
11505
11505
|
let a = i[l];
|
|
11506
|
-
a != null && (t && s.length == 1 && s.push(o = new
|
|
11506
|
+
a != null && (t && s.length == 1 && s.push(o = new Pn(e.isInline ? "span" : "div")), l == "class" ? o.class = (o.class ? o.class + " " : "") + a : l == "style" ? o.style = (o.style ? o.style + ";" : "") + a : l != "nodeName" && (o[l] = a));
|
|
11507
11507
|
}
|
|
11508
11508
|
}
|
|
11509
11509
|
}
|
|
@@ -11991,7 +11991,7 @@ function yl(n, e, t) {
|
|
|
11991
11991
|
function Ho(n) {
|
|
11992
11992
|
return n.nodeType == 3 ? n.nodeValue.length : n.childNodes.length;
|
|
11993
11993
|
}
|
|
11994
|
-
function
|
|
11994
|
+
function Nn(n, e) {
|
|
11995
11995
|
let t = n.pmViewDesc;
|
|
11996
11996
|
return t && t.size == 0 && (e < 0 || n.nextSibling || n.nodeName != "BR");
|
|
11997
11997
|
}
|
|
@@ -12003,13 +12003,13 @@ function Nm(n) {
|
|
|
12003
12003
|
if (!t)
|
|
12004
12004
|
return;
|
|
12005
12005
|
let s, r, i = !1;
|
|
12006
|
-
for (Ee && t.nodeType == 1 && o < Ho(t) &&
|
|
12006
|
+
for (Ee && t.nodeType == 1 && o < Ho(t) && Nn(t.childNodes[o], -1) && (i = !0); ; )
|
|
12007
12007
|
if (o > 0) {
|
|
12008
12008
|
if (t.nodeType != 1)
|
|
12009
12009
|
break;
|
|
12010
12010
|
{
|
|
12011
12011
|
let l = t.childNodes[o - 1];
|
|
12012
|
-
if (
|
|
12012
|
+
if (Nn(l, -1))
|
|
12013
12013
|
s = t, r = --o;
|
|
12014
12014
|
else if (l.nodeType == 3)
|
|
12015
12015
|
t = l, o = t.nodeValue.length;
|
|
@@ -12021,7 +12021,7 @@ function Nm(n) {
|
|
|
12021
12021
|
break;
|
|
12022
12022
|
{
|
|
12023
12023
|
let l = t.previousSibling;
|
|
12024
|
-
for (; l &&
|
|
12024
|
+
for (; l && Nn(l, -1); )
|
|
12025
12025
|
s = t.parentNode, r = ee(l), l = l.previousSibling;
|
|
12026
12026
|
if (l)
|
|
12027
12027
|
t = l, o = Ho(t);
|
|
@@ -12044,7 +12044,7 @@ function Om(n) {
|
|
|
12044
12044
|
if (t.nodeType != 1)
|
|
12045
12045
|
break;
|
|
12046
12046
|
let l = t.childNodes[o];
|
|
12047
|
-
if (
|
|
12047
|
+
if (Nn(l, 1))
|
|
12048
12048
|
r = t, i = ++o;
|
|
12049
12049
|
else
|
|
12050
12050
|
break;
|
|
@@ -12053,7 +12053,7 @@ function Om(n) {
|
|
|
12053
12053
|
break;
|
|
12054
12054
|
{
|
|
12055
12055
|
let l = t.nextSibling;
|
|
12056
|
-
for (; l &&
|
|
12056
|
+
for (; l && Nn(l, 1); )
|
|
12057
12057
|
r = l.parentNode, i = ee(l) + 1, l = l.nextSibling;
|
|
12058
12058
|
if (l)
|
|
12059
12059
|
t = l, o = 0, s = Ho(t);
|
|
@@ -12682,12 +12682,12 @@ function ig(n, e) {
|
|
|
12682
12682
|
t.parentNode && t.parentNode.removeChild(t), n.focus();
|
|
12683
12683
|
}, 50);
|
|
12684
12684
|
}
|
|
12685
|
-
const
|
|
12685
|
+
const _n = he && rt < 15 || cn && nm < 604;
|
|
12686
12686
|
ce.copy = de.cut = (n, e) => {
|
|
12687
12687
|
let t = e, o = n.state.selection, s = t.type == "cut";
|
|
12688
12688
|
if (o.empty)
|
|
12689
12689
|
return;
|
|
12690
|
-
let r =
|
|
12690
|
+
let r = _n ? null : t.clipboardData, i = o.content(), { dom: l, text: a } = Qc(n, i);
|
|
12691
12691
|
r ? (t.preventDefault(), r.clearData(), r.setData("text/html", l.innerHTML), r.setData("text/plain", a)) : ig(n, l), s && n.dispatch(n.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent", "cut"));
|
|
12692
12692
|
};
|
|
12693
12693
|
function lg(n) {
|
|
@@ -12700,10 +12700,10 @@ function ag(n, e) {
|
|
|
12700
12700
|
t || (o.contentEditable = "true"), o.style.cssText = "position: fixed; left: -10000px; top: 10px", o.focus();
|
|
12701
12701
|
let s = n.input.shiftKey && n.input.lastKeyCode != 45;
|
|
12702
12702
|
setTimeout(() => {
|
|
12703
|
-
n.focus(), o.parentNode && o.parentNode.removeChild(o), t ?
|
|
12703
|
+
n.focus(), o.parentNode && o.parentNode.removeChild(o), t ? Gn(n, o.value, null, s, e) : Gn(n, o.textContent, o.innerHTML, s, e);
|
|
12704
12704
|
}, 50);
|
|
12705
12705
|
}
|
|
12706
|
-
function
|
|
12706
|
+
function Gn(n, e, t, o, s) {
|
|
12707
12707
|
let r = ed(n, e, t, o, n.state.selection.$from);
|
|
12708
12708
|
if (n.someProp("handlePaste", (a) => a(n, s, r || A.empty)))
|
|
12709
12709
|
return !0;
|
|
@@ -12723,8 +12723,8 @@ de.paste = (n, e) => {
|
|
|
12723
12723
|
let t = e;
|
|
12724
12724
|
if (n.composing && !ke)
|
|
12725
12725
|
return;
|
|
12726
|
-
let o =
|
|
12727
|
-
o &&
|
|
12726
|
+
let o = _n ? null : t.clipboardData, s = n.input.shiftKey && n.input.lastKeyCode != 45;
|
|
12727
|
+
o && Gn(n, dd(o), o.getData("text/html"), s, t) ? t.preventDefault() : ag(n, t);
|
|
12728
12728
|
};
|
|
12729
12729
|
class ud {
|
|
12730
12730
|
constructor(e, t, o) {
|
|
@@ -12746,7 +12746,7 @@ ce.dragstart = (n, e) => {
|
|
|
12746
12746
|
}
|
|
12747
12747
|
}
|
|
12748
12748
|
let l = (i || n.state.selection).content(), { dom: a, text: c, slice: d } = Qc(n, l);
|
|
12749
|
-
(!t.dataTransfer.files.length || !re || Vc > 120) && t.dataTransfer.clearData(), t.dataTransfer.setData(
|
|
12749
|
+
(!t.dataTransfer.files.length || !re || Vc > 120) && t.dataTransfer.clearData(), t.dataTransfer.setData(_n ? "Text" : "text/html", a.innerHTML), t.dataTransfer.effectAllowed = "copyMove", _n || t.dataTransfer.setData("text/plain", c), n.dragging = new ud(d, !t[pd], i);
|
|
12750
12750
|
};
|
|
12751
12751
|
ce.dragend = (n) => {
|
|
12752
12752
|
let e = n.dragging;
|
|
@@ -12765,7 +12765,7 @@ de.drop = (n, e) => {
|
|
|
12765
12765
|
let r = n.state.doc.resolve(s.pos), i = o && o.slice;
|
|
12766
12766
|
i ? n.someProp("transformPasted", (f) => {
|
|
12767
12767
|
i = f(i, n);
|
|
12768
|
-
}) : i = ed(n, dd(t.dataTransfer),
|
|
12768
|
+
}) : i = ed(n, dd(t.dataTransfer), _n ? null : t.dataTransfer.getData("text/html"), !1, r);
|
|
12769
12769
|
let l = !!(o && !t[pd]);
|
|
12770
12770
|
if (n.someProp("handleDrop", (f) => f(n, t, i || A.empty, l))) {
|
|
12771
12771
|
t.preventDefault();
|
|
@@ -12816,7 +12816,7 @@ ce.beforeinput = (n, e) => {
|
|
|
12816
12816
|
};
|
|
12817
12817
|
for (let n in de)
|
|
12818
12818
|
ce[n] = de[n];
|
|
12819
|
-
function
|
|
12819
|
+
function Wn(n, e) {
|
|
12820
12820
|
if (n == e)
|
|
12821
12821
|
return !0;
|
|
12822
12822
|
for (let t in n)
|
|
@@ -12839,7 +12839,7 @@ class _o {
|
|
|
12839
12839
|
return !0;
|
|
12840
12840
|
}
|
|
12841
12841
|
eq(e) {
|
|
12842
|
-
return this == e || e instanceof _o && (this.spec.key && this.spec.key == e.spec.key || this.toDOM == e.toDOM &&
|
|
12842
|
+
return this == e || e instanceof _o && (this.spec.key && this.spec.key == e.spec.key || this.toDOM == e.toDOM && Wn(this.spec, e.spec));
|
|
12843
12843
|
}
|
|
12844
12844
|
destroy(e) {
|
|
12845
12845
|
this.spec.destroy && this.spec.destroy(e);
|
|
@@ -12857,7 +12857,7 @@ class lt {
|
|
|
12857
12857
|
return t.from < t.to;
|
|
12858
12858
|
}
|
|
12859
12859
|
eq(e) {
|
|
12860
|
-
return this == e || e instanceof lt &&
|
|
12860
|
+
return this == e || e instanceof lt && Wn(this.attrs, e.attrs) && Wn(this.spec, e.spec);
|
|
12861
12861
|
}
|
|
12862
12862
|
static is(e) {
|
|
12863
12863
|
return e.type instanceof lt;
|
|
@@ -12881,7 +12881,7 @@ class qr {
|
|
|
12881
12881
|
return s == t.from && !(r = e.child(o)).isText && s + r.nodeSize == t.to;
|
|
12882
12882
|
}
|
|
12883
12883
|
eq(e) {
|
|
12884
|
-
return this == e || e instanceof qr &&
|
|
12884
|
+
return this == e || e instanceof qr && Wn(this.attrs, e.attrs) && Wn(this.spec, e.spec);
|
|
12885
12885
|
}
|
|
12886
12886
|
destroy() {
|
|
12887
12887
|
}
|
|
@@ -13407,9 +13407,9 @@ class fg {
|
|
|
13407
13407
|
if (!e.focusNode)
|
|
13408
13408
|
return !0;
|
|
13409
13409
|
let t = /* @__PURE__ */ new Set(), o;
|
|
13410
|
-
for (let r = e.focusNode; r; r =
|
|
13410
|
+
for (let r = e.focusNode; r; r = Fn(r))
|
|
13411
13411
|
t.add(r);
|
|
13412
|
-
for (let r = e.anchorNode; r; r =
|
|
13412
|
+
for (let r = e.anchorNode; r; r = Fn(r))
|
|
13413
13413
|
if (t.has(r)) {
|
|
13414
13414
|
o = r;
|
|
13415
13415
|
break;
|
|
@@ -13984,13 +13984,13 @@ class Tg {
|
|
|
13984
13984
|
[`handlePaste`](https://prosemirror.net/docs/ref/#view.EditorProps.handlePaste) hook.
|
|
13985
13985
|
*/
|
|
13986
13986
|
pasteHTML(e, t) {
|
|
13987
|
-
return
|
|
13987
|
+
return Gn(this, "", e, !1, t || new ClipboardEvent("paste"));
|
|
13988
13988
|
}
|
|
13989
13989
|
/**
|
|
13990
13990
|
Run the editor's paste logic with the given plain-text input.
|
|
13991
13991
|
*/
|
|
13992
13992
|
pasteText(e, t) {
|
|
13993
|
-
return
|
|
13993
|
+
return Gn(this, e, null, !0, t || new ClipboardEvent("paste"));
|
|
13994
13994
|
}
|
|
13995
13995
|
/**
|
|
13996
13996
|
Removes the editor from the DOM and destroys all [node
|
|
@@ -15326,7 +15326,7 @@ function e1({
|
|
|
15326
15326
|
View: o = Qg,
|
|
15327
15327
|
lastColumnResizable: s = !0
|
|
15328
15328
|
} = {}) {
|
|
15329
|
-
const r = new
|
|
15329
|
+
const r = new hn({
|
|
15330
15330
|
key: ge,
|
|
15331
15331
|
state: {
|
|
15332
15332
|
init(i, l) {
|
|
@@ -15544,7 +15544,7 @@ function c1(n, e) {
|
|
|
15544
15544
|
function d1({
|
|
15545
15545
|
allowTableNodeSelection: n = !1
|
|
15546
15546
|
} = {}) {
|
|
15547
|
-
return new
|
|
15547
|
+
return new hn({
|
|
15548
15548
|
key: Qe,
|
|
15549
15549
|
// This piece of state is used to remember when a mouse-drag
|
|
15550
15550
|
// cell-selection is happening, so that it can continue even as
|
|
@@ -15584,7 +15584,7 @@ function d1({
|
|
|
15584
15584
|
}
|
|
15585
15585
|
});
|
|
15586
15586
|
}
|
|
15587
|
-
const
|
|
15587
|
+
const On = (n) => {
|
|
15588
15588
|
const e = Object.fromEntries(Array.from(n.attributes).map((t) => [t.name, t.value]));
|
|
15589
15589
|
return delete e.draggable, e;
|
|
15590
15590
|
}, ql = "data-gs-mrk-fs", Kl = "data-gs-ib", Wo = "data-gs-ifrg", je = "attrs", wd = {
|
|
@@ -15592,8 +15592,8 @@ const Nn = (n) => {
|
|
|
15592
15592
|
}, $e = {
|
|
15593
15593
|
[je]: { default: {} }
|
|
15594
15594
|
}, Cd = (n) => ({
|
|
15595
|
-
[je]: JSON.stringify(
|
|
15596
|
-
}), Be = (n) => ({ attrs:
|
|
15595
|
+
[je]: JSON.stringify(On(n))
|
|
15596
|
+
}), Be = (n) => ({ attrs: On(n) }), yn = (n) => (e) => [n, e.attrs.attrs, 0], Ze = (n) => n.attrs[je] ? JSON.parse(n.attrs[je]) : {}, u1 = {
|
|
15597
15597
|
doc: {
|
|
15598
15598
|
content: "block+"
|
|
15599
15599
|
},
|
|
@@ -15613,35 +15613,35 @@ const Nn = (n) => {
|
|
|
15613
15613
|
content: "inline*",
|
|
15614
15614
|
attrs: $e,
|
|
15615
15615
|
parseDOM: [{ tag: "div", getAttrs: Be }],
|
|
15616
|
-
toDOM:
|
|
15616
|
+
toDOM: yn("div")
|
|
15617
15617
|
},
|
|
15618
15618
|
paragraph: {
|
|
15619
15619
|
group: "block",
|
|
15620
15620
|
content: "inline*",
|
|
15621
15621
|
attrs: $e,
|
|
15622
15622
|
parseDOM: [{ tag: "p", getAttrs: Be }],
|
|
15623
|
-
toDOM:
|
|
15623
|
+
toDOM: yn("p")
|
|
15624
15624
|
},
|
|
15625
15625
|
orderedList: {
|
|
15626
15626
|
group: "block",
|
|
15627
15627
|
content: "listItem+",
|
|
15628
15628
|
attrs: $e,
|
|
15629
15629
|
parseDOM: [{ tag: "ol", getAttrs: Be }],
|
|
15630
|
-
toDOM:
|
|
15630
|
+
toDOM: yn("ol")
|
|
15631
15631
|
},
|
|
15632
15632
|
bulletList: {
|
|
15633
15633
|
group: "block",
|
|
15634
15634
|
content: "listItem+",
|
|
15635
15635
|
attrs: $e,
|
|
15636
15636
|
parseDOM: [{ tag: "ul", getAttrs: Be }],
|
|
15637
|
-
toDOM:
|
|
15637
|
+
toDOM: yn("ul")
|
|
15638
15638
|
},
|
|
15639
15639
|
listItem: {
|
|
15640
15640
|
content: "block*",
|
|
15641
15641
|
group: "block",
|
|
15642
15642
|
attrs: $e,
|
|
15643
15643
|
parseDOM: [{ tag: "li", getAttrs: Be }],
|
|
15644
|
-
toDOM:
|
|
15644
|
+
toDOM: yn("li"),
|
|
15645
15645
|
defining: !0
|
|
15646
15646
|
},
|
|
15647
15647
|
codeBlock: {
|
|
@@ -15689,7 +15689,7 @@ const Nn = (n) => {
|
|
|
15689
15689
|
tag: `h${e + 1}`,
|
|
15690
15690
|
getAttrs: (t) => ({
|
|
15691
15691
|
level: e + 1,
|
|
15692
|
-
attrs:
|
|
15692
|
+
attrs: On(t)
|
|
15693
15693
|
})
|
|
15694
15694
|
})),
|
|
15695
15695
|
toDOM({ attrs: n }) {
|
|
@@ -15703,7 +15703,7 @@ const Nn = (n) => {
|
|
|
15703
15703
|
cellAttributes: {
|
|
15704
15704
|
[je]: {
|
|
15705
15705
|
default: $e[je].default,
|
|
15706
|
-
getFromDOM:
|
|
15706
|
+
getFromDOM: On,
|
|
15707
15707
|
setDOMAttr: (n, e) => {
|
|
15708
15708
|
n && Object.assign(e, n);
|
|
15709
15709
|
}
|
|
@@ -15732,7 +15732,7 @@ const Nn = (n) => {
|
|
|
15732
15732
|
tag: "*:not(tbody)",
|
|
15733
15733
|
getAttrs: (n) => ({
|
|
15734
15734
|
tagName: n.tagName.toLowerCase(),
|
|
15735
|
-
attrs:
|
|
15735
|
+
attrs: On(n)
|
|
15736
15736
|
}),
|
|
15737
15737
|
priority: 0
|
|
15738
15738
|
}
|
|
@@ -15742,7 +15742,7 @@ const Nn = (n) => {
|
|
|
15742
15742
|
return [e, t, 0];
|
|
15743
15743
|
}
|
|
15744
15744
|
}
|
|
15745
|
-
},
|
|
15745
|
+
}, bn = (n, e) => ({
|
|
15746
15746
|
attrs: wd,
|
|
15747
15747
|
parseDOM: n.map((t) => ({
|
|
15748
15748
|
tag: t,
|
|
@@ -15750,11 +15750,11 @@ const Nn = (n) => {
|
|
|
15750
15750
|
})),
|
|
15751
15751
|
toDOM: e
|
|
15752
15752
|
}), p1 = {
|
|
15753
|
-
strong:
|
|
15754
|
-
link:
|
|
15755
|
-
em:
|
|
15756
|
-
underline:
|
|
15757
|
-
strikethrough:
|
|
15753
|
+
strong: bn(["strong", "b"], (n) => ["b", Ze(n)]),
|
|
15754
|
+
link: bn(["a"], (n) => ["a", Ze(n), 0]),
|
|
15755
|
+
em: bn(["em", "i"], (n) => ["em", Ze(n)]),
|
|
15756
|
+
underline: bn(["u"], (n) => ["u", Ze(n), 0]),
|
|
15757
|
+
strikethrough: bn(["s"], (n) => ["s", Ze(n), 0]),
|
|
15758
15758
|
font_size: {
|
|
15759
15759
|
attrs: {
|
|
15760
15760
|
...wd,
|
|
@@ -15887,7 +15887,7 @@ function w1(n, e, t) {
|
|
|
15887
15887
|
}
|
|
15888
15888
|
i.docChanged && s(i.scrollIntoView());
|
|
15889
15889
|
}
|
|
15890
|
-
const
|
|
15890
|
+
const vn = (n, e) => {
|
|
15891
15891
|
const { from: t, to: o } = n.selection;
|
|
15892
15892
|
let s = !1;
|
|
15893
15893
|
return n.doc.nodesBetween(t, o, (r) => {
|
|
@@ -15998,19 +15998,19 @@ const E1 = (n, e) => {
|
|
|
15998
15998
|
},
|
|
15999
15999
|
bold: {
|
|
16000
16000
|
toggle: () => gt(s.strong)(n.state, t),
|
|
16001
|
-
isActive: () =>
|
|
16001
|
+
isActive: () => vn(n.state, s.strong)
|
|
16002
16002
|
},
|
|
16003
16003
|
italic: {
|
|
16004
16004
|
toggle: () => gt(s.em)(n.state, t),
|
|
16005
|
-
isActive: () =>
|
|
16005
|
+
isActive: () => vn(n.state, s.em)
|
|
16006
16006
|
},
|
|
16007
16007
|
underline: {
|
|
16008
16008
|
toggle: () => gt(s.underline)(n.state, t),
|
|
16009
|
-
isActive: () =>
|
|
16009
|
+
isActive: () => vn(n.state, s.underline)
|
|
16010
16010
|
},
|
|
16011
16011
|
strikethrough: {
|
|
16012
16012
|
toggle: () => gt(s.strikethrough)(n.state, t),
|
|
16013
|
-
isActive: () =>
|
|
16013
|
+
isActive: () => vn(n.state, s.strikethrough)
|
|
16014
16014
|
},
|
|
16015
16015
|
link: {
|
|
16016
16016
|
get: () => {
|
|
@@ -16023,7 +16023,7 @@ const E1 = (n, e) => {
|
|
|
16023
16023
|
}
|
|
16024
16024
|
},
|
|
16025
16025
|
toggle: () => gt(s.link)(n.state, t),
|
|
16026
|
-
isActive: () =>
|
|
16026
|
+
isActive: () => vn(n.state, s.link),
|
|
16027
16027
|
create: (r) => {
|
|
16028
16028
|
const i = Jl(n);
|
|
16029
16029
|
i != null && i.is("link") ? (i.addAttributes({ href: r.url, target: r.target }), n.focus()) : C1(n, r.url, r.target);
|
|
@@ -16122,7 +16122,7 @@ function R1(n) {
|
|
|
16122
16122
|
}
|
|
16123
16123
|
const D1 = 500;
|
|
16124
16124
|
function L1({ rules: n }) {
|
|
16125
|
-
let e = new
|
|
16125
|
+
let e = new hn({
|
|
16126
16126
|
state: {
|
|
16127
16127
|
init() {
|
|
16128
16128
|
return null;
|
|
@@ -16521,6 +16521,7 @@ const Q1 = function(n, e = {}) {
|
|
|
16521
16521
|
schema: a,
|
|
16522
16522
|
plugins: (m = t.plugins) == null ? void 0 : m.call(t, {
|
|
16523
16523
|
editor: n,
|
|
16524
|
+
Plugin: hn,
|
|
16524
16525
|
plugins: [
|
|
16525
16526
|
e1(),
|
|
16526
16527
|
d1(),
|
|
@@ -16531,8 +16532,8 @@ const Q1 = function(n, e = {}) {
|
|
|
16531
16532
|
"Shift-Tab": $l(-1)
|
|
16532
16533
|
}),
|
|
16533
16534
|
Ts({
|
|
16534
|
-
Enter:
|
|
16535
|
-
"Shift-Enter":
|
|
16535
|
+
Enter: Hn(Mc, Wf(c.listItem), v1),
|
|
16536
|
+
"Shift-Enter": Hn(Tc, (g, v) => (v && v(g.tr.replaceSelectionWith(c.inlineBreak.create()).scrollIntoView()), !0)),
|
|
16536
16537
|
"Mod-z": Dc,
|
|
16537
16538
|
"Mod-y": tr,
|
|
16538
16539
|
// On Windows
|
|
@@ -16605,7 +16606,7 @@ const Q1 = function(n, e = {}) {
|
|
|
16605
16606
|
n.RichTextEditor.customRte = void 0, r();
|
|
16606
16607
|
}
|
|
16607
16608
|
});
|
|
16608
|
-
},
|
|
16609
|
+
}, wy = W(Q1), e0 = "canvasEmptyState", t0 = H.startup, n0 = function(n, e = {}) {
|
|
16609
16610
|
const t = /* @__PURE__ */ new WeakMap(), o = /* @__PURE__ */ new WeakMap(), s = /* @__PURE__ */ new WeakMap(), r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new WeakMap(), l = {
|
|
16610
16611
|
emptyStates: [],
|
|
16611
16612
|
...e
|
|
@@ -16664,7 +16665,7 @@ const Q1 = function(n, e = {}) {
|
|
|
16664
16665
|
n.off(m, u), n.off(g, u), n.off(C, p), n.off(v, h);
|
|
16665
16666
|
}
|
|
16666
16667
|
});
|
|
16667
|
-
},
|
|
16668
|
+
}, Cy = W(n0), Xl = "canvasFullSize", o0 = H.startup, s0 = function(n, e = {}) {
|
|
16668
16669
|
const { Canvas: t, Commands: o, Devices: s } = n, r = {
|
|
16669
16670
|
deviceMaxWidth: 1200,
|
|
16670
16671
|
deviceMinHeigth: 500,
|
|
@@ -16749,7 +16750,7 @@ const Q1 = function(n, e = {}) {
|
|
|
16749
16750
|
n.runCommand(C);
|
|
16750
16751
|
}
|
|
16751
16752
|
});
|
|
16752
|
-
},
|
|
16753
|
+
}, ky = W(s0), vr = "canvasGridMode", r0 = H.startup, xr = "component-grid-mode", jn = "grid-mode", Xn = "gjs-drag-grid-spot", Nd = `${Xn}__grid-item`, Od = `${Xn}__grid-target`, Id = `${Xn}__snapped`, i0 = `${Xn}__container`, l0 = () => {
|
|
16753
16754
|
const n = "data-gjs-drag-grid-style", e = document, t = "var(--gs-theme-cl-cmp-bg1, var(--gjs-color-highlight))", o = "var(--gs-theme-cl-cmp-bg2, var(--gjs-color-blue))", s = e.querySelector(`style[${n}]`) || e.createElement("style");
|
|
16754
16755
|
s.setAttribute(n, "true"), s.innerHTML = `
|
|
16755
16756
|
.${Nd} {
|
|
@@ -16789,7 +16790,7 @@ function Rd(n) {
|
|
|
16789
16790
|
shadowSnappedEl: document.createElement("div"),
|
|
16790
16791
|
shadowTargetEl: document.createElement("div"),
|
|
16791
16792
|
spot: e.Canvas.addSpot({
|
|
16792
|
-
type:
|
|
16793
|
+
type: jn,
|
|
16793
16794
|
component: s.component
|
|
16794
16795
|
})
|
|
16795
16796
|
};
|
|
@@ -16797,7 +16798,7 @@ function Rd(n) {
|
|
|
16797
16798
|
function Dd(n) {
|
|
16798
16799
|
const { editor: e, shadowTargetEl: t, shadowSnappedEl: o, shadowContainerEl: s, spotEl: r, target: i, container: l } = n, { Canvas: a } = e, c = e.config.stylePrefix;
|
|
16799
16800
|
r == null || r.appendChild(s), s == null || s.appendChild(t), s == null || s.appendChild(o), a0(s, l), c0(t, i, l), d0(o, i), u0(s, l.el), i.el.style.opacity = "0";
|
|
16800
|
-
const d = a.getSpots().filter((u) => u.type !==
|
|
16801
|
+
const d = a.getSpots().filter((u) => u.type !== jn);
|
|
16801
16802
|
e.em.stopDefault({ preserveSelected: !0 }), a.removeSpots(d), a.startAutoscroll(), a.getBody().classList.add(`${c}is__grabbing`);
|
|
16802
16803
|
}
|
|
16803
16804
|
function Ld(n) {
|
|
@@ -16810,7 +16811,7 @@ function Ld(n) {
|
|
|
16810
16811
|
height: ""
|
|
16811
16812
|
});
|
|
16812
16813
|
}
|
|
16813
|
-
s.el.style.opacity = "", o.contains(t) && (o == null || o.removeChild(t)), e.getModel().runDefault({ preserveSelected: 1 }), i.stopAutoscroll(), i.getBody().classList.remove(`${l}is__grabbing`), i.removeSpots({ type:
|
|
16814
|
+
s.el.style.opacity = "", o.contains(t) && (o == null || o.removeChild(t)), e.getModel().runDefault({ preserveSelected: 1 }), i.stopAutoscroll(), i.getBody().classList.remove(`${l}is__grabbing`), i.removeSpots({ type: jn }), e.select(a);
|
|
16814
16815
|
}
|
|
16815
16816
|
function a0(n, {
|
|
16816
16817
|
rows: e,
|
|
@@ -17261,14 +17262,14 @@ const w0 = function(n, e = {}) {
|
|
|
17261
17262
|
Rs(n, y.target, t) && Object.assign(y.options, m0(n, y));
|
|
17262
17263
|
}, m = () => {
|
|
17263
17264
|
const y = o.getSpots({
|
|
17264
|
-
type:
|
|
17265
|
+
type: jn
|
|
17265
17266
|
}).pop();
|
|
17266
17267
|
if (!y) return;
|
|
17267
17268
|
let b = y.attributes.spotEl;
|
|
17268
17269
|
b || (b = document.createElement("div"), b.className = Xn, y.set({ spotEl: b })), Object.entries(y.getStyle()).forEach(([x, S]) => b.style.setProperty(x, S)), p == null || p.appendChild(b);
|
|
17269
17270
|
}, g = ({ spot: y }) => {
|
|
17270
17271
|
const b = y.attributes.spotEl;
|
|
17271
|
-
y.type !==
|
|
17272
|
+
y.type !== jn || !b || p == null || p.removeChild(b);
|
|
17272
17273
|
};
|
|
17273
17274
|
if (i) {
|
|
17274
17275
|
const y = (b) => {
|
|
@@ -17316,7 +17317,7 @@ const w0 = function(n, e = {}) {
|
|
|
17316
17317
|
pluginName: vr,
|
|
17317
17318
|
cleanup: C
|
|
17318
17319
|
});
|
|
17319
|
-
},
|
|
17320
|
+
}, Ty = W(w0);
|
|
17320
17321
|
var Ne = /* @__PURE__ */ ((n) => (n.panelBlocks = "panelBlocks", n.panelPagesLayers = "panelPagesLayers", n.panelGlobalStyles = "panelGlobalStyles", n.panelSidebarTabs = "panelSidebarTabs", n.panelAssets = "panelAssets", n))(Ne || {});
|
|
17321
17322
|
const $d = "sidebarButtonsTarget", fo = (n) => {
|
|
17322
17323
|
const { id: e, icon: t, label: o, tooltip: s, className: r, skipSelfClose: i, removeLayouts: l, layoutComponent: a, layoutCommand: c } = n, d = e;
|
|
@@ -17799,7 +17800,7 @@ const O0 = "presetPrintable", I0 = function(n, e = {}) {
|
|
|
17799
17800
|
pluginName: O0,
|
|
17800
17801
|
cleanup: C
|
|
17801
17802
|
});
|
|
17802
|
-
},
|
|
17803
|
+
}, My = W(I0);
|
|
17803
17804
|
class R0 {
|
|
17804
17805
|
getHelperId() {
|
|
17805
17806
|
}
|
|
@@ -17905,7 +17906,7 @@ const D0 = "dataSourceEjs", L0 = function(n, e = {}) {
|
|
|
17905
17906
|
n.off(o, t);
|
|
17906
17907
|
}
|
|
17907
17908
|
});
|
|
17908
|
-
},
|
|
17909
|
+
}, Ey = W(L0);
|
|
17909
17910
|
class z0 {
|
|
17910
17911
|
getHelperId(e, t) {
|
|
17911
17912
|
return {
|
|
@@ -18005,7 +18006,7 @@ const V0 = "dataSourceHandlebars", $0 = function(n, e = {}) {
|
|
|
18005
18006
|
n.off(o, t);
|
|
18006
18007
|
}
|
|
18007
18008
|
});
|
|
18008
|
-
},
|
|
18009
|
+
}, Ay = W($0), B0 = (n) => {
|
|
18009
18010
|
const e = {};
|
|
18010
18011
|
for (const t of Object.keys(n)) {
|
|
18011
18012
|
let o = n[t];
|
|
@@ -18159,14 +18160,14 @@ const V0 = "dataSourceHandlebars", $0 = function(n, e = {}) {
|
|
|
18159
18160
|
});
|
|
18160
18161
|
}
|
|
18161
18162
|
});
|
|
18162
|
-
},
|
|
18163
|
+
}, Py = W(W0), qn = (n) => n.replaceAll('"', "").replaceAll("'", ""), Tr = (n) => n.includes(",") ? n : /\s/.test(n) ? `"${qn(n)}"` : qn(n), ra = (n, e, t) => ({ family: n, variant: e, ...t }), _d = (n, e) => {
|
|
18163
18164
|
n = Tr(n);
|
|
18164
18165
|
const { menuVariant: t, variants: o } = e;
|
|
18165
18166
|
return {
|
|
18166
18167
|
family: n,
|
|
18167
|
-
familyLabel:
|
|
18168
|
+
familyLabel: qn(n),
|
|
18168
18169
|
menuVariant: t && ra(
|
|
18169
|
-
Tr(`menuFont-${
|
|
18170
|
+
Tr(`menuFont-${qn(n)}`),
|
|
18170
18171
|
"regular",
|
|
18171
18172
|
t
|
|
18172
18173
|
),
|
|
@@ -18182,7 +18183,7 @@ const V0 = "dataSourceHandlebars", $0 = function(n, e = {}) {
|
|
|
18182
18183
|
const t = _d(n.family, n), o = t.menuVariant ?? ((l = Object.values(t.variants)) == null ? void 0 : l[0]);
|
|
18183
18184
|
if (!o)
|
|
18184
18185
|
return "Arial, Helvetica, sans-serif";
|
|
18185
|
-
const { source: s, descriptors: r } = o, i =
|
|
18186
|
+
const { source: s, descriptors: r } = o, i = qn(o.family);
|
|
18186
18187
|
if (!e) {
|
|
18187
18188
|
const a = new FontFace(i, `url("${s}")`, r), c = Array.from(document.fonts.values()).filter((d) => d.family === i);
|
|
18188
18189
|
for (const d of c)
|
|
@@ -18231,7 +18232,7 @@ const V0 = "dataSourceHandlebars", $0 = function(n, e = {}) {
|
|
|
18231
18232
|
const { font: e } = n.customData;
|
|
18232
18233
|
return n.customData.needsLoading ? (n.customData.needsLoading = !1, ia(e)) : ia(e, !0);
|
|
18233
18234
|
};
|
|
18234
|
-
let
|
|
18235
|
+
let xn;
|
|
18235
18236
|
const U0 = (n) => {
|
|
18236
18237
|
const e = [];
|
|
18237
18238
|
for (const t of Object.keys(n)) {
|
|
@@ -18251,8 +18252,8 @@ const U0 = (n) => {
|
|
|
18251
18252
|
search: { reloadOnInput: !1 },
|
|
18252
18253
|
async onLoad() {
|
|
18253
18254
|
var c;
|
|
18254
|
-
if (
|
|
18255
|
-
return
|
|
18255
|
+
if (xn)
|
|
18256
|
+
return xn;
|
|
18256
18257
|
const s = {
|
|
18257
18258
|
key: e,
|
|
18258
18259
|
sort: "alpha",
|
|
@@ -18262,10 +18263,10 @@ const U0 = (n) => {
|
|
|
18262
18263
|
...s,
|
|
18263
18264
|
...r
|
|
18264
18265
|
}, a = await (await fetch(o(i))).json();
|
|
18265
|
-
return (c = a.items) != null && c.length ? (
|
|
18266
|
+
return (c = a.items) != null && c.length ? (xn = a.items.map(q0), xn) : [];
|
|
18266
18267
|
},
|
|
18267
18268
|
itemLayout: (s) => {
|
|
18268
|
-
const r =
|
|
18269
|
+
const r = xn.find((l) => l.id === s.assetProps.id), i = K0(r);
|
|
18269
18270
|
return {
|
|
18270
18271
|
type: "column",
|
|
18271
18272
|
onClick: () => s.onSelect(r),
|
|
@@ -18314,7 +18315,7 @@ const U0 = (n) => {
|
|
|
18314
18315
|
modalTitle: "Select Font",
|
|
18315
18316
|
providerLabel: "Google Fonts"
|
|
18316
18317
|
}
|
|
18317
|
-
}, Z0 = "googleFontsAssetProvider", X0 = function(n, e) {
|
|
18318
|
+
}, Z0 = "googleFontsAssetProvider", X0 = H.startup, Q0 = function(n, e) {
|
|
18318
18319
|
const { i18n: t = {} } = e, o = J0(e);
|
|
18319
18320
|
n.runCommand(F.assetProviderAdd, { provider: o }), n.I18n.addMessages({
|
|
18320
18321
|
en: Y0,
|
|
@@ -18322,13 +18323,13 @@ const U0 = (n) => {
|
|
|
18322
18323
|
}), j({
|
|
18323
18324
|
editor: n,
|
|
18324
18325
|
licenseKey: e.licenseKey,
|
|
18325
|
-
plan:
|
|
18326
|
+
plan: X0,
|
|
18326
18327
|
pluginName: Z0,
|
|
18327
18328
|
cleanup: () => {
|
|
18328
18329
|
n.runCommand(F.assetProviderRemove, { id: o.id });
|
|
18329
18330
|
}
|
|
18330
18331
|
});
|
|
18331
|
-
},
|
|
18332
|
+
}, Ny = W(Q0), ey = "canvasAbsoluteMode", ty = H.startup, ny = (n, e, t) => {
|
|
18332
18333
|
const o = t.enableAbsolute ?? ((a) => a.hasAbsolute), r = (Array.isArray(e) ? e : e ? [e] : [...n.getSelectedAll()])[0];
|
|
18333
18334
|
if (!r) return;
|
|
18334
18335
|
const i = r.getEl();
|
|
@@ -18348,7 +18349,7 @@ function ko({
|
|
|
18348
18349
|
const { guide: l, matched: a } = n, c = e.getElBoxRect(l.componentView.el), d = e.getElBoxRect(((E = a.componentView) == null ? void 0 : E.el) || a.componentEl), u = c.y, p = c.y + c.height, h = c.x, f = c.x + c.width, m = d.y, g = d.y + d.height, v = d.x, C = d.x + d.width, y = Math.max(0, u - g), b = Math.max(0, m - p), x = Math.max(0, h - C), S = Math.max(0, v - f), w = y > b, M = x > S, k = l.type;
|
|
18349
18350
|
return t === "x" && (k === "l" ? (o = h, w ? (s = g, r = y) : (s = p, r = b)) : k === "r" ? (o = f, w ? (s = g, r = y) : (s = p, r = b)) : k === "x" && (o = h - (h - f) / 2, w ? (s = g, r = y) : (s = p, r = b))), t === "y" && (k === "t" ? (s = u, M ? (o = C, i = x) : (o = f, i = S)) : k === "b" ? (s = p, M ? (o = C, i = x) : (o = f, i = S)) : k === "y" && (s = u - (u - p) / 2, M ? (o = C, i = x) : (o = f, i = S))), { axis: t, x: o, y: s, width: i, height: r };
|
|
18350
18351
|
}
|
|
18351
|
-
function
|
|
18352
|
+
function oy({
|
|
18352
18353
|
guideMatched: n,
|
|
18353
18354
|
component: e,
|
|
18354
18355
|
canvasView: t
|
|
@@ -18386,7 +18387,7 @@ function Gd({
|
|
|
18386
18387
|
Math.abs(g) >= a && (C = Math.round((m.left + g) / a) * a, r.__lastSnappedGuideMatched = null), Math.abs(v) >= c && (y = Math.round((m.top + v) / c) * c, r.__lastSnappedGuideMatched = null);
|
|
18387
18388
|
return r.addStyle({ left: `${C}px`, top: `${y}px` }, { partial: !0 }), r.__lastSnappedPosition = { left: C, top: y }, { x: C, y, guideMatched: r.__lastSnappedGuideMatched };
|
|
18388
18389
|
}
|
|
18389
|
-
function
|
|
18390
|
+
function sy({
|
|
18390
18391
|
snapping: n,
|
|
18391
18392
|
props: e,
|
|
18392
18393
|
editor: t
|
|
@@ -18394,9 +18395,9 @@ function oy({
|
|
|
18394
18395
|
const { x: o, y: s } = Gd({ snapping: n, props: e, editor: t }), r = e.component;
|
|
18395
18396
|
r.addStyle({ left: `${o}px`, top: `${s}px` }), delete r.__lastSnappedPosition, delete r.__lastSnappedGuideMatched;
|
|
18396
18397
|
}
|
|
18397
|
-
const
|
|
18398
|
+
const ry = "core:component-drag", iy = "studio:setDragAbsolute", ly = "dmode:start", la = "dmode:move", aa = "dmode:end", Ls = "dragAbsolute", ay = "select", cy = "hover", dy = "spacing", uy = function(n, e = {}) {
|
|
18398
18399
|
const { Commands: t } = n, o = t.events, s = t.getConfig().defaultOptions ?? {}, r = `${o.runBeforeCommand}tlb-move`;
|
|
18399
|
-
s[
|
|
18400
|
+
s[ry] = {
|
|
18400
18401
|
run: (w) => ({
|
|
18401
18402
|
...w,
|
|
18402
18403
|
skipGuidesRender: !0
|
|
@@ -18419,7 +18420,7 @@ const sy = "core:component-drag", ry = "studio:setDragAbsolute", iy = "dmode:sta
|
|
|
18419
18420
|
p = k[0];
|
|
18420
18421
|
else {
|
|
18421
18422
|
const Ae = p, q = Ae.guide.x === void 0 ? "x" : "y";
|
|
18422
|
-
(q === "x" && (l == null ? void 0 : l.x) || q === "y" && (l == null ? void 0 : l.y)) && (
|
|
18423
|
+
(q === "x" && (l == null ? void 0 : l.x) || q === "y" && (l == null ? void 0 : l.y)) && (oy({ guideMatched: Ae, component: M, canvasView: O }), D = [Ae.matched.componentEl], V = [ko({ guideMatched: Ae, canvasView: O })]);
|
|
18423
18424
|
}
|
|
18424
18425
|
else
|
|
18425
18426
|
p = null;
|
|
@@ -18434,19 +18435,19 @@ const sy = "core:component-drag", ry = "studio:setDragAbsolute", iy = "dmode:sta
|
|
|
18434
18435
|
};
|
|
18435
18436
|
u.addSpot(J);
|
|
18436
18437
|
}, f = ({ enabled: w }) => {
|
|
18437
|
-
n.runCommand(
|
|
18438
|
+
n.runCommand(iy, { enabled: w });
|
|
18438
18439
|
}, m = ({ type: w }) => {
|
|
18439
18440
|
u.removeSpots({ type: w });
|
|
18440
18441
|
}, g = () => {
|
|
18441
|
-
m({ type:
|
|
18442
|
+
m({ type: ay }), m({ type: cy }), m({ type: dy });
|
|
18442
18443
|
}, v = (w) => {
|
|
18443
18444
|
f({ enabled: !0 }), h(w), g();
|
|
18444
18445
|
}, C = (w) => {
|
|
18445
18446
|
h(w), g();
|
|
18446
18447
|
}, y = (w) => {
|
|
18447
|
-
m({ type: Ls }), c &&
|
|
18448
|
+
m({ type: Ls }), c && sy({ snapping: i, props: w, editor: n }), f({ enabled: !1 });
|
|
18448
18449
|
}, S = [
|
|
18449
|
-
[
|
|
18450
|
+
[ly, (w) => {
|
|
18450
18451
|
v(w), n.on(la, C);
|
|
18451
18452
|
const M = () => {
|
|
18452
18453
|
y(w), n.off(la, C), n.off(aa, M);
|
|
@@ -18455,40 +18456,40 @@ const sy = "core:component-drag", ry = "studio:setDragAbsolute", iy = "dmode:sta
|
|
|
18455
18456
|
}],
|
|
18456
18457
|
[r, (w) => {
|
|
18457
18458
|
if (a) return;
|
|
18458
|
-
const M = w.options.target, k =
|
|
18459
|
-
k != null && k.result && !k.dmode && k.component.set({ dmode: "absolute" });
|
|
18459
|
+
const M = w.options.target, k = ny(n, M, e);
|
|
18460
|
+
k != null && k.result && !k.dmode && (k.component.set({ dmode: "absolute" }), w.options.mode = "absolute");
|
|
18460
18461
|
}]
|
|
18461
18462
|
];
|
|
18462
18463
|
S.forEach(([w, M]) => n.on(w, M)), j({
|
|
18463
18464
|
editor: n,
|
|
18464
18465
|
licenseKey: e.licenseKey,
|
|
18465
|
-
plan:
|
|
18466
|
-
pluginName:
|
|
18466
|
+
plan: ty,
|
|
18467
|
+
pluginName: ey,
|
|
18467
18468
|
cleanup: () => {
|
|
18468
18469
|
f({ enabled: !1 }), S.forEach(([w, M]) => n.off(w, M));
|
|
18469
18470
|
}
|
|
18470
18471
|
});
|
|
18471
|
-
},
|
|
18472
|
+
}, Oy = W(uy);
|
|
18472
18473
|
export {
|
|
18473
|
-
|
|
18474
|
-
|
|
18475
|
-
|
|
18476
|
-
|
|
18477
|
-
|
|
18478
|
-
|
|
18479
|
-
|
|
18480
|
-
|
|
18481
|
-
|
|
18482
|
-
|
|
18483
|
-
|
|
18484
|
-
|
|
18474
|
+
vy as accordionComponent,
|
|
18475
|
+
Oy as canvasAbsoluteMode,
|
|
18476
|
+
Cy as canvasEmptyState,
|
|
18477
|
+
ky as canvasFullSize,
|
|
18478
|
+
Ty as canvasGridMode,
|
|
18479
|
+
Ey as dataSourceEjs,
|
|
18480
|
+
Ay as dataSourceHandlebars,
|
|
18481
|
+
py as dialogComponent,
|
|
18482
|
+
xy as flexComponent,
|
|
18483
|
+
gy as fsLightboxComponent,
|
|
18484
|
+
Ny as googleFontsAssetProvider,
|
|
18485
|
+
hy as iconifyComponent,
|
|
18485
18486
|
T0 as layoutSidebarButtons,
|
|
18486
|
-
|
|
18487
|
-
|
|
18488
|
-
|
|
18489
|
-
|
|
18490
|
-
|
|
18491
|
-
|
|
18492
|
-
|
|
18493
|
-
|
|
18487
|
+
yy as lightGalleryComponent,
|
|
18488
|
+
my as listPagesComponent,
|
|
18489
|
+
My as presetPrintable,
|
|
18490
|
+
wy as rteProseMirror,
|
|
18491
|
+
Sy as rteTinyMce,
|
|
18492
|
+
by as swiperComponent,
|
|
18493
|
+
fy as tableComponent,
|
|
18494
|
+
Py as youtubeAssetProvider
|
|
18494
18495
|
};
|