@templatical/editor 0.0.2 → 0.0.3
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/{AiChatSidebar-XBj5Rw2l.js → AiChatSidebar-busJk9hm.js} +1 -1
- package/dist/{AiFeatureMenu-my1mZ9DL.js → AiFeatureMenu-DLGv_-pj.js} +3 -3
- package/dist/{CloudEditor-BVjgKwq3.js → CloudEditor-BDnHd6Um.js} +176 -197
- package/dist/{CollaboratorBar-BZq_Gv38.js → CollaboratorBar-Dv3l52vC.js} +2 -2
- package/dist/{CommentsSidebar-D9oxqO6l.js → CommentsSidebar-4tjp0VU5.js} +2 -2
- package/dist/{DesignReferenceSidebar-CyHq4SWt.js → DesignReferenceSidebar-CmwXvltV.js} +55 -54
- package/dist/{ModuleBrowserModal-Cus2Hdwl.js → ModuleBrowserModal-lrk3Fr0H.js} +6 -6
- package/dist/{ModulePreviewCanvas-DaByXKY_.js → ModulePreviewCanvas-BcBJLnwL.js} +3 -3
- package/dist/ParagraphEditor-DH8cSC6m.js +625 -0
- package/dist/{RichTextEditorContent-BRpjJ6SV.js → RichTextEditorContent-CQqodi7p.js} +3 -3
- package/dist/{SaveModuleDialog-BIZBQrd8.js → SaveModuleDialog-Bmzi72td.js} +4 -4
- package/dist/{SnapshotHistory-Ds1-QNbx.js → SnapshotHistory-AEgi9Xsn.js} +2 -2
- package/dist/{TemplateScoringPanel-C8XSk_Ys.js → TemplateScoringPanel-CTgMtc0-.js} +2 -2
- package/dist/{TestEmailModal-CCVfaFgV.js → TestEmailModal-Dpq1is9S.js} +3 -3
- package/dist/{TitleEditor-V4qaEULF.js → TitleEditor-CLcDdcWI.js} +7 -7
- package/dist/{TplModal-LT3FXlgs.js → TplModal-CGzRjR96.js} +2 -2
- package/dist/{blockTypeIcons-BujoY5Dl.js → blockTypeIcons-BpPTqcok.js} +1 -1
- package/dist/cdn/chunks/ParagraphEditor-CCtWbGDv.js +3 -0
- package/dist/cdn/chunks/ParagraphEditor-CCtWbGDv.js.map +1 -0
- package/dist/cdn/chunks/RichTextEditorContent-BUD9veXd.js +2 -0
- package/dist/cdn/chunks/RichTextEditorContent-BUD9veXd.js.map +1 -0
- package/dist/cdn/chunks/TitleEditor-e_UTyxjd.js +3 -0
- package/dist/cdn/chunks/TitleEditor-e_UTyxjd.js.map +1 -0
- package/dist/cdn/chunks/{extensions-BfjbWqOx.js → extensions-ea_ewKUl.js} +2 -2
- package/dist/cdn/chunks/{extensions-BfjbWqOx.js.map → extensions-ea_ewKUl.js.map} +1 -1
- package/dist/cdn/chunks/styleConstants-CNejCb-L.js +2 -0
- package/dist/cdn/chunks/{styleConstants-UTJ94gco.js.map → styleConstants-CNejCb-L.js.map} +1 -1
- package/dist/cdn/chunks/useEditorCore-CwuxQuvh.js +2 -0
- package/dist/cdn/chunks/useEditorCore-CwuxQuvh.js.map +1 -0
- package/dist/cdn/chunks/useMergeTag-DVOz1v9p.js +2 -0
- package/dist/cdn/chunks/useMergeTag-DVOz1v9p.js.map +1 -0
- package/dist/cdn/editor.js +1 -1
- package/dist/cdn/editor.js.map +1 -1
- package/dist/{dist-DNjZKe2Z.js → dist-DmpMJbmZ.js} +1 -1
- package/dist/{extensions-BA4NshZQ.js → extensions-CKM99njP.js} +3 -3
- package/dist/{i18n-ikyi28RU.js → i18n-CJsFtdbZ.js} +1 -1
- package/dist/keys-Dwa2PmdD.js +10 -0
- package/dist/{styleConstants-CgtFM9hQ.js → styleConstants-D4SOZGBV.js} +53 -2
- package/dist/{styles-hQgJKM4i.js → styles-DSw1VNU3.js} +592 -592
- package/dist/templatical-editor.css +1 -1
- package/dist/templatical-editor.js +5 -5
- package/dist/templatical-editor.umd.cjs +59 -59
- package/dist/{useEditorCore-DVp5qmtC.js → useEditorCore-Cc4RCwWq.js} +907 -903
- package/dist/{useI18n-DzH4KXDk.js → useI18n-DUirdXEX.js} +2 -2
- package/dist/{useMergeTag-D9zQVE-e.js → useMergeTag-DVnlvPYJ.js} +2 -2
- package/package.json +2 -2
- package/dist/ParagraphEditor-BSyk5B6S.js +0 -670
- package/dist/cdn/chunks/ParagraphEditor-BkJQO-ZW.js +0 -3
- package/dist/cdn/chunks/ParagraphEditor-BkJQO-ZW.js.map +0 -1
- package/dist/cdn/chunks/RichTextEditorContent-UGQorJm_.js +0 -2
- package/dist/cdn/chunks/RichTextEditorContent-UGQorJm_.js.map +0 -1
- package/dist/cdn/chunks/TitleEditor-CC3Adjai.js +0 -3
- package/dist/cdn/chunks/TitleEditor-CC3Adjai.js.map +0 -1
- package/dist/cdn/chunks/styleConstants-UTJ94gco.js +0 -2
- package/dist/cdn/chunks/useEditorCore-DRhPKq_z.js +0 -2
- package/dist/cdn/chunks/useEditorCore-DRhPKq_z.js.map +0 -1
- package/dist/cdn/chunks/useMergeTag-CBSlcqnk.js +0 -2
- package/dist/cdn/chunks/useMergeTag-CBSlcqnk.js.map +0 -1
- package/dist/keys-8B5MFafK.js +0 -4
|
@@ -1,45 +1,45 @@
|
|
|
1
1
|
import { a as e, c as t, i as n, n as r, o as i, r as a, s as o } from "./dist-CG-vEqSU.js";
|
|
2
|
-
import { C as s, S as c, _ as l, a as u, d, f, g as p, h as m, i as h, l as g, m as _, n as v, o as y, p as b, s as x, u as S, v as C, x as
|
|
3
|
-
import { t as
|
|
4
|
-
import { n as
|
|
5
|
-
import { t as
|
|
6
|
-
import { t as
|
|
7
|
-
import { t as
|
|
8
|
-
import { t as
|
|
9
|
-
import { t as re } from "./useMergeTag-
|
|
10
|
-
import { Fragment as
|
|
11
|
-
import { useAutoSave as
|
|
12
|
-
import { HEADING_LEVEL_FONT_SIZE as
|
|
2
|
+
import { C as s, S as c, _ as l, a as u, d, f, g as p, h as m, i as h, l as g, m as _, n as v, o as y, p as b, s as x, u as S, v as C, w, x as T } from "./keys-Dwa2PmdD.js";
|
|
3
|
+
import { t as E } from "./useI18n-DUirdXEX.js";
|
|
4
|
+
import { n as D, t as O } from "./_plugin-vue_export-helper-B1-bu7yR.js";
|
|
5
|
+
import { t as ee } from "./message-circle-Blgm6V_h.js";
|
|
6
|
+
import { t as k } from "./trash-2-OwjZ-guZ.js";
|
|
7
|
+
import { t as te } from "./triangle-alert-DOSRIUYZ.js";
|
|
8
|
+
import { t as ne } from "./LoadingTrack-vK8W2PJf.js";
|
|
9
|
+
import { t as re } from "./useMergeTag-DVnlvPYJ.js";
|
|
10
|
+
import { Fragment as ie, computed as A, createBlock as ae, createCommentVNode as oe, createElementBlock as j, createElementVNode as M, createTextVNode as se, createVNode as N, defineAsyncComponent as ce, defineComponent as le, getCurrentScope as ue, inject as de, normalizeClass as fe, normalizeStyle as P, onBeforeUnmount as pe, onMounted as me, onScopeDispose as he, openBlock as F, provide as I, ref as L, renderList as ge, renderSlot as _e, resolveDynamicComponent as ve, shallowRef as ye, toDisplayString as R, triggerRef as be, unref as z, vShow as xe, watch as Se, withCtx as Ce, withDirectives as we, withKeys as Te, withModifiers as Ee } from "vue";
|
|
11
|
+
import { useAutoSave as De, useBlockActions as Oe, useConditionPreview as ke, useDataSourceFetch as Ae, useHistory as je, useHistoryInterceptor as Me } from "@templatical/core";
|
|
12
|
+
import { HEADING_LEVEL_FONT_SIZE as Ne, containsMergeTag as Pe, createButtonBlock as Fe, createCountdownBlock as Ie, createCustomBlock as Le, createDividerBlock as Re, createHtmlBlock as ze, createImageBlock as Be, createMenuBlock as Ve, createParagraphBlock as He, createSectionBlock as Ue, createSocialIconsBlock as We, createSpacerBlock as Ge, createTableBlock as Ke, createTitleBlock as qe, createVideoBlock as Je, resolveHtmlLogicMergeTagLabels as Ye, resolveHtmlMergeTagLabels as Xe, resolveSyntax as Ze } from "@templatical/types";
|
|
13
13
|
//#region \0rolldown/runtime.js
|
|
14
|
-
var
|
|
14
|
+
var Qe = Object.create, $e = Object.defineProperty, et = Object.getOwnPropertyDescriptor, tt = Object.getOwnPropertyNames, nt = Object.getPrototypeOf, rt = Object.prototype.hasOwnProperty, it = (e, t) => () => (e && (t = e(e = 0)), t), at = (e, t) => () => (t || e((t = { exports: {} }).exports, t), t.exports), ot = (e, t) => {
|
|
15
15
|
let n = {};
|
|
16
|
-
for (var r in e)
|
|
16
|
+
for (var r in e) $e(n, r, {
|
|
17
17
|
get: e[r],
|
|
18
18
|
enumerable: !0
|
|
19
19
|
});
|
|
20
|
-
return t ||
|
|
21
|
-
},
|
|
22
|
-
if (t && typeof t == "object" || typeof t == "function") for (var i =
|
|
20
|
+
return t || $e(n, Symbol.toStringTag, { value: "Module" }), n;
|
|
21
|
+
}, st = (e, t, n, r) => {
|
|
22
|
+
if (t && typeof t == "object" || typeof t == "function") for (var i = tt(t), a = 0, o = i.length, s; a < o; a++) s = i[a], !rt.call(e, s) && s !== n && $e(e, s, {
|
|
23
23
|
get: ((e) => t[e]).bind(null, s),
|
|
24
|
-
enumerable: !(r =
|
|
24
|
+
enumerable: !(r = et(t, s)) || r.enumerable
|
|
25
25
|
});
|
|
26
26
|
return e;
|
|
27
|
-
},
|
|
27
|
+
}, ct = (e, t, n) => (n = e == null ? {} : Qe(nt(e)), st(t || !e || !e.__esModule ? $e(n, "default", {
|
|
28
28
|
value: e,
|
|
29
29
|
enumerable: !0
|
|
30
|
-
}) : n, e)),
|
|
30
|
+
}) : n, e)), lt = (e) => rt.call(e, "module.exports") ? e["module.exports"] : st($e({}, "__esModule", { value: !0 }), e), ut = /* @__PURE__ */ ((e) => typeof require < "u" ? require : typeof Proxy < "u" ? new Proxy(e, { get: (e, t) => (typeof require < "u" ? require : e)[t] }) : e)(function(e) {
|
|
31
31
|
if (typeof require < "u") return require.apply(this, arguments);
|
|
32
32
|
throw Error("Calling `require` for \"" + e + "\" in an environment that doesn't expose the `require` function. See https://rolldown.rs/in-depth/bundling-cjs#require-external-modules for more details.");
|
|
33
33
|
});
|
|
34
34
|
//#endregion
|
|
35
35
|
//#region src/composables/useUiTheme.ts
|
|
36
|
-
function
|
|
36
|
+
function dt(e) {
|
|
37
37
|
let t = n("(prefers-color-scheme: dark)");
|
|
38
38
|
return { resolvedTheme: A(() => e.value === "auto" ? t.value ? "dark" : "light" : e.value) };
|
|
39
39
|
}
|
|
40
40
|
//#endregion
|
|
41
41
|
//#region src/composables/useThemeStyles.ts
|
|
42
|
-
var
|
|
42
|
+
var ft = {
|
|
43
43
|
bg: "--tpl-bg",
|
|
44
44
|
bgElevated: "--tpl-bg-elevated",
|
|
45
45
|
bgHover: "--tpl-bg-hover",
|
|
@@ -63,10 +63,10 @@ var dt = {
|
|
|
63
63
|
dangerLight: "--tpl-danger-light",
|
|
64
64
|
canvasBg: "--tpl-canvas-bg"
|
|
65
65
|
};
|
|
66
|
-
function
|
|
66
|
+
function pt({ themeOverrides: e, resolvedTheme: t, extraStyles: n }) {
|
|
67
67
|
return { themeStyles: A(() => {
|
|
68
68
|
let r = {}, i = e.value, a = t.value === "dark" ? i.dark : i;
|
|
69
|
-
if (a) for (let [e, t] of Object.entries(
|
|
69
|
+
if (a) for (let [e, t] of Object.entries(ft)) {
|
|
70
70
|
let n = a[e];
|
|
71
71
|
n && (r[t] = n);
|
|
72
72
|
}
|
|
@@ -75,15 +75,15 @@ function ft({ themeOverrides: e, resolvedTheme: t, extraStyles: n }) {
|
|
|
75
75
|
}
|
|
76
76
|
//#endregion
|
|
77
77
|
//#region src/composables/useBlockRegistry.ts
|
|
78
|
-
function
|
|
79
|
-
let e =
|
|
78
|
+
function mt() {
|
|
79
|
+
let e = ye(/* @__PURE__ */ new Map());
|
|
80
80
|
function t(t, n) {
|
|
81
|
-
e.value.set(t, n),
|
|
81
|
+
e.value.set(t, n), be(e);
|
|
82
82
|
}
|
|
83
83
|
function n(t, n) {
|
|
84
84
|
let r = `custom:${t.type}`, i = {
|
|
85
85
|
component: n,
|
|
86
|
-
createBlock: () =>
|
|
86
|
+
createBlock: () => Le(t),
|
|
87
87
|
sidebarItem: {
|
|
88
88
|
type: r,
|
|
89
89
|
label: t.name,
|
|
@@ -93,7 +93,7 @@ function pt() {
|
|
|
93
93
|
},
|
|
94
94
|
definition: t
|
|
95
95
|
};
|
|
96
|
-
e.value.set(r, i),
|
|
96
|
+
e.value.set(r, i), be(e);
|
|
97
97
|
}
|
|
98
98
|
function r(t) {
|
|
99
99
|
if (t.type === "custom") {
|
|
@@ -146,75 +146,75 @@ function pt() {
|
|
|
146
146
|
}
|
|
147
147
|
//#endregion
|
|
148
148
|
//#region src/utils/registerBuiltInBlocks.ts
|
|
149
|
-
var
|
|
149
|
+
var ht = [
|
|
150
150
|
{
|
|
151
151
|
type: "section",
|
|
152
152
|
label: "Section",
|
|
153
|
-
createBlock:
|
|
153
|
+
createBlock: Ue
|
|
154
154
|
},
|
|
155
155
|
{
|
|
156
156
|
type: "title",
|
|
157
157
|
label: "Title",
|
|
158
|
-
createBlock:
|
|
158
|
+
createBlock: qe
|
|
159
159
|
},
|
|
160
160
|
{
|
|
161
161
|
type: "paragraph",
|
|
162
162
|
label: "Paragraph",
|
|
163
|
-
createBlock:
|
|
163
|
+
createBlock: He
|
|
164
164
|
},
|
|
165
165
|
{
|
|
166
166
|
type: "image",
|
|
167
167
|
label: "Image",
|
|
168
|
-
createBlock:
|
|
168
|
+
createBlock: Be
|
|
169
169
|
},
|
|
170
170
|
{
|
|
171
171
|
type: "button",
|
|
172
172
|
label: "Button",
|
|
173
|
-
createBlock:
|
|
173
|
+
createBlock: Fe
|
|
174
174
|
},
|
|
175
175
|
{
|
|
176
176
|
type: "divider",
|
|
177
177
|
label: "Divider",
|
|
178
|
-
createBlock:
|
|
178
|
+
createBlock: Re
|
|
179
179
|
},
|
|
180
180
|
{
|
|
181
181
|
type: "video",
|
|
182
182
|
label: "Video",
|
|
183
|
-
createBlock:
|
|
183
|
+
createBlock: Je
|
|
184
184
|
},
|
|
185
185
|
{
|
|
186
186
|
type: "social",
|
|
187
187
|
label: "Social",
|
|
188
|
-
createBlock:
|
|
188
|
+
createBlock: We
|
|
189
189
|
},
|
|
190
190
|
{
|
|
191
191
|
type: "menu",
|
|
192
192
|
label: "Menu",
|
|
193
|
-
createBlock:
|
|
193
|
+
createBlock: Ve
|
|
194
194
|
},
|
|
195
195
|
{
|
|
196
196
|
type: "table",
|
|
197
197
|
label: "Table",
|
|
198
|
-
createBlock:
|
|
198
|
+
createBlock: Ke
|
|
199
199
|
},
|
|
200
200
|
{
|
|
201
201
|
type: "spacer",
|
|
202
202
|
label: "Spacer",
|
|
203
|
-
createBlock:
|
|
203
|
+
createBlock: Ge
|
|
204
204
|
},
|
|
205
205
|
{
|
|
206
206
|
type: "html",
|
|
207
207
|
label: "HTML",
|
|
208
|
-
createBlock:
|
|
208
|
+
createBlock: ze
|
|
209
209
|
},
|
|
210
210
|
{
|
|
211
211
|
type: "countdown",
|
|
212
212
|
label: "Countdown",
|
|
213
|
-
createBlock:
|
|
213
|
+
createBlock: Ie
|
|
214
214
|
}
|
|
215
215
|
];
|
|
216
|
-
function
|
|
217
|
-
for (let n of
|
|
216
|
+
function gt(e, t) {
|
|
217
|
+
for (let n of ht) {
|
|
218
218
|
let r = t[n.type];
|
|
219
219
|
r && e.registerBuiltIn(n.type, {
|
|
220
220
|
component: r,
|
|
@@ -229,18 +229,18 @@ function ht(e, t) {
|
|
|
229
229
|
}
|
|
230
230
|
//#endregion
|
|
231
231
|
//#region src/utils/keyboardShortcuts.ts
|
|
232
|
-
function
|
|
232
|
+
function _t(e) {
|
|
233
233
|
let t = e.target;
|
|
234
234
|
return t.isContentEditable || t.tagName === "INPUT" || t.tagName === "TEXTAREA" || t.tagName === "SELECT";
|
|
235
235
|
}
|
|
236
|
-
function
|
|
236
|
+
function vt(e, t) {
|
|
237
237
|
let n = e.metaKey || e.ctrlKey;
|
|
238
238
|
if (n && e.key === "s") {
|
|
239
239
|
e.preventDefault(), t.onSave?.();
|
|
240
240
|
return;
|
|
241
241
|
}
|
|
242
242
|
if (n && e.key.toLowerCase() === "z") {
|
|
243
|
-
if (
|
|
243
|
+
if (_t(e)) return;
|
|
244
244
|
e.preventDefault(), e.shiftKey ? t.history.redo() : (t.onBeforeUndo?.(), t.history.undo());
|
|
245
245
|
return;
|
|
246
246
|
}
|
|
@@ -248,11 +248,11 @@ function _t(e, t) {
|
|
|
248
248
|
t.selectBlock(null);
|
|
249
249
|
return;
|
|
250
250
|
}
|
|
251
|
-
(e.key === "Delete" || e.key === "Backspace") && t.getSelectedBlockId() && !
|
|
251
|
+
(e.key === "Delete" || e.key === "Backspace") && t.getSelectedBlockId() && !_t(e) && (e.preventDefault(), t.history.record(), t.removeBlock(t.getSelectedBlockId()));
|
|
252
252
|
}
|
|
253
253
|
//#endregion
|
|
254
254
|
//#region src/components/blocks/ButtonBlock.vue?vue&type=script&setup=true&lang.ts
|
|
255
|
-
var
|
|
255
|
+
var yt = { class: "tpl:text-center" }, bt = ["href"], xt = /* @__PURE__ */ le({
|
|
256
256
|
__name: "ButtonBlock",
|
|
257
257
|
props: {
|
|
258
258
|
block: {},
|
|
@@ -273,27 +273,27 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
273
273
|
};
|
|
274
274
|
return t.block.fontFamily && (e.fontFamily = t.block.fontFamily), e;
|
|
275
275
|
});
|
|
276
|
-
return (t, r) => (
|
|
276
|
+
return (t, r) => (F(), j("div", yt, [M("a", {
|
|
277
277
|
href: e.block.url || "#",
|
|
278
|
-
style:
|
|
278
|
+
style: P(n.value),
|
|
279
279
|
class: "tpl:cursor-default",
|
|
280
|
-
onClick: r[0] ||=
|
|
281
|
-
}, R(e.block.text), 13,
|
|
280
|
+
onClick: r[0] ||= Ee(() => {}, ["prevent"])
|
|
281
|
+
}, R(e.block.text), 13, bt)]));
|
|
282
282
|
}
|
|
283
|
-
}),
|
|
283
|
+
}), St = {
|
|
284
284
|
key: 0,
|
|
285
285
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:py-8 tpl:text-sm tpl:text-[var(--tpl-text-dim)]"
|
|
286
|
-
},
|
|
286
|
+
}, Ct = {
|
|
287
287
|
key: 1,
|
|
288
288
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:py-4 tpl:text-xs tpl:text-[var(--tpl-text-dim)] tpl:opacity-50"
|
|
289
|
-
},
|
|
289
|
+
}, wt = { class: "tpl:text-center" }, Tt = /* @__PURE__ */ le({
|
|
290
290
|
__name: "CountdownBlock",
|
|
291
291
|
props: {
|
|
292
292
|
block: {},
|
|
293
293
|
viewport: {}
|
|
294
294
|
},
|
|
295
295
|
setup(e) {
|
|
296
|
-
let t = e, { t: n } =
|
|
296
|
+
let t = e, { t: n } = E(), r = L(Date.now());
|
|
297
297
|
i(() => {
|
|
298
298
|
r.value = Date.now();
|
|
299
299
|
}, 1e3);
|
|
@@ -347,27 +347,27 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
347
347
|
color: t.block.digitColor,
|
|
348
348
|
fontFamily: t.block.fontFamily || "inherit"
|
|
349
349
|
}));
|
|
350
|
-
return (t, r) => e.block.targetDate ? o.value && e.block.hideOnExpiry ? (
|
|
350
|
+
return (t, r) => e.block.targetDate ? o.value && e.block.hideOnExpiry ? (F(), j("div", Ct, R(z(n).countdown.hidden), 1)) : o.value ? (F(), j("div", {
|
|
351
351
|
key: 2,
|
|
352
|
-
style:
|
|
352
|
+
style: P(l.value),
|
|
353
353
|
class: "tpl:py-4 tpl:text-center"
|
|
354
|
-
}, [M("span", { style:
|
|
354
|
+
}, [M("span", { style: P({
|
|
355
355
|
fontSize: `${e.block.digitFontSize}px`,
|
|
356
356
|
color: e.block.digitColor
|
|
357
|
-
}) }, R(e.block.expiredMessage), 5)], 4)) : (
|
|
357
|
+
}) }, R(e.block.expiredMessage), 5)], 4)) : (F(), j("div", {
|
|
358
358
|
key: 3,
|
|
359
|
-
style:
|
|
359
|
+
style: P(l.value),
|
|
360
360
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:py-4"
|
|
361
|
-
}, [(
|
|
361
|
+
}, [(F(!0), j(ie, null, ge(c.value, (t, n) => (F(), j(ie, { key: t.label }, [n > 0 ? (F(), j("span", {
|
|
362
362
|
key: 0,
|
|
363
|
-
style:
|
|
363
|
+
style: P(f.value),
|
|
364
364
|
class: "tpl:self-start"
|
|
365
|
-
}, R(e.block.separator), 5)) :
|
|
365
|
+
}, R(e.block.separator), 5)) : oe("", !0), M("div", wt, [M("div", { style: P(u.value) }, R(t.value), 5), M("div", { style: P(d.value) }, R(t.label), 5)])], 64))), 128))], 4)) : (F(), j("div", St, R(z(n).countdown.setDate), 1));
|
|
366
366
|
}
|
|
367
|
-
}),
|
|
367
|
+
}), Et = D("bookmark", [["path", {
|
|
368
368
|
d: "M17 3a2 2 0 0 1 2 2v15a1 1 0 0 1-1.496.868l-4.512-2.578a2 2 0 0 0-1.984 0l-4.512 2.578A1 1 0 0 1 5 20V5a2 2 0 0 1 2-2z",
|
|
369
369
|
key: "oz39mx"
|
|
370
|
-
}]]),
|
|
370
|
+
}]]), Dt = D("box", [
|
|
371
371
|
["path", {
|
|
372
372
|
d: "M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",
|
|
373
373
|
key: "hh9hay"
|
|
@@ -380,13 +380,13 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
380
380
|
d: "M12 22V12",
|
|
381
381
|
key: "d0xqtd"
|
|
382
382
|
}]
|
|
383
|
-
]),
|
|
383
|
+
]), Ot = D("code", [["path", {
|
|
384
384
|
d: "m16 18 6-6-6-6",
|
|
385
385
|
key: "eg8j8"
|
|
386
386
|
}], ["path", {
|
|
387
387
|
d: "m8 6-6 6 6 6",
|
|
388
388
|
key: "ppft3o"
|
|
389
|
-
}]]),
|
|
389
|
+
}]]), kt = D("copy", [["rect", {
|
|
390
390
|
width: "14",
|
|
391
391
|
height: "14",
|
|
392
392
|
x: "8",
|
|
@@ -397,7 +397,7 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
397
397
|
}], ["path", {
|
|
398
398
|
d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",
|
|
399
399
|
key: "zix9uf"
|
|
400
|
-
}]]),
|
|
400
|
+
}]]), At = D("eye-off", [
|
|
401
401
|
["path", {
|
|
402
402
|
d: "M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",
|
|
403
403
|
key: "ct8e1f"
|
|
@@ -414,10 +414,10 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
414
414
|
d: "m2 2 20 20",
|
|
415
415
|
key: "1ooewy"
|
|
416
416
|
}]
|
|
417
|
-
]),
|
|
417
|
+
]), jt = D("funnel", [["path", {
|
|
418
418
|
d: "M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",
|
|
419
419
|
key: "sc7q7i"
|
|
420
|
-
}]]),
|
|
420
|
+
}]]), Mt = D("grip-vertical", [
|
|
421
421
|
["circle", {
|
|
422
422
|
cx: "9",
|
|
423
423
|
cy: "12",
|
|
@@ -454,7 +454,7 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
454
454
|
r: "1",
|
|
455
455
|
key: "f4zoj3"
|
|
456
456
|
}]
|
|
457
|
-
]),
|
|
457
|
+
]), Nt = D("image", [
|
|
458
458
|
["rect", {
|
|
459
459
|
width: "18",
|
|
460
460
|
height: "18",
|
|
@@ -474,13 +474,13 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
474
474
|
d: "m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",
|
|
475
475
|
key: "1xmnt7"
|
|
476
476
|
}]
|
|
477
|
-
]),
|
|
477
|
+
]), Pt = D("navigation", [["polygon", {
|
|
478
478
|
points: "3 11 22 2 13 21 11 13 3 11",
|
|
479
479
|
key: "1ltx0t"
|
|
480
|
-
}]]),
|
|
480
|
+
}]]), Ft = D("puzzle", [["path", {
|
|
481
481
|
d: "M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z",
|
|
482
482
|
key: "w46dr5"
|
|
483
|
-
}]]),
|
|
483
|
+
}]]), It = D("share-2", [
|
|
484
484
|
["circle", {
|
|
485
485
|
cx: "18",
|
|
486
486
|
cy: "5",
|
|
@@ -513,7 +513,7 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
513
513
|
y2: "10.49",
|
|
514
514
|
key: "1n3mei"
|
|
515
515
|
}]
|
|
516
|
-
]),
|
|
516
|
+
]), Lt = D("table", [
|
|
517
517
|
["path", {
|
|
518
518
|
d: "M12 3v18",
|
|
519
519
|
key: "108xh3"
|
|
@@ -534,7 +534,7 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
534
534
|
d: "M3 15h18",
|
|
535
535
|
key: "5xshup"
|
|
536
536
|
}]
|
|
537
|
-
]),
|
|
537
|
+
]), Rt = D("video", [["path", {
|
|
538
538
|
d: "m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",
|
|
539
539
|
key: "ftymec"
|
|
540
540
|
}], ["rect", {
|
|
@@ -544,11 +544,11 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
544
544
|
height: "12",
|
|
545
545
|
rx: "2",
|
|
546
546
|
key: "158x01"
|
|
547
|
-
}]]),
|
|
547
|
+
}]]), zt = ["innerHTML"], Bt = [
|
|
548
548
|
"src",
|
|
549
549
|
"width",
|
|
550
550
|
"height"
|
|
551
|
-
],
|
|
551
|
+
], Vt = /* @__PURE__ */ le({
|
|
552
552
|
__name: "CustomBlockIcon",
|
|
553
553
|
props: {
|
|
554
554
|
icon: {},
|
|
@@ -556,32 +556,32 @@ var vt = { class: "tpl:text-center" }, yt = ["href"], bt = /* @__PURE__ */ P({
|
|
|
556
556
|
},
|
|
557
557
|
setup(e) {
|
|
558
558
|
let t = e, n = A(() => t.size ?? 20), r = A(() => t.icon && (t.icon.trimStart().startsWith("<svg") || t.icon.trimStart().startsWith("<SVG"))), i = A(() => t.icon && !r.value && (t.icon.startsWith("http") || t.icon.startsWith("/")));
|
|
559
|
-
return (t, a) => r.value ? (
|
|
559
|
+
return (t, a) => r.value ? (F(), j("span", {
|
|
560
560
|
key: 0,
|
|
561
561
|
class: "tpl:inline-flex tpl:items-center tpl:justify-center",
|
|
562
|
-
style:
|
|
562
|
+
style: P({
|
|
563
563
|
width: `${n.value}px`,
|
|
564
564
|
height: `${n.value}px`
|
|
565
565
|
}),
|
|
566
566
|
innerHTML: e.icon
|
|
567
|
-
}, null, 12,
|
|
567
|
+
}, null, 12, zt)) : i.value ? (F(), j("img", {
|
|
568
568
|
key: 1,
|
|
569
569
|
src: e.icon,
|
|
570
570
|
width: n.value,
|
|
571
571
|
height: n.value,
|
|
572
572
|
class: "tpl:inline-block",
|
|
573
573
|
alt: ""
|
|
574
|
-
}, null, 8,
|
|
574
|
+
}, null, 8, Bt)) : (F(), ae(z(Dt), {
|
|
575
575
|
key: 2,
|
|
576
576
|
size: n.value,
|
|
577
577
|
"stroke-width": 1.5
|
|
578
578
|
}, null, 8, ["size"]));
|
|
579
579
|
}
|
|
580
|
-
}),
|
|
581
|
-
function
|
|
580
|
+
}), Ht = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"])";
|
|
581
|
+
function Ut(e, t) {
|
|
582
582
|
let n = null, r = null;
|
|
583
583
|
function i() {
|
|
584
|
-
return e.value ? Array.from(e.value.querySelectorAll(
|
|
584
|
+
return e.value ? Array.from(e.value.querySelectorAll(Ht)).filter((e) => e.offsetParent !== null) : [];
|
|
585
585
|
}
|
|
586
586
|
function o(e) {
|
|
587
587
|
if (e.key !== "Tab") return;
|
|
@@ -599,15 +599,18 @@ function Ht(e, t) {
|
|
|
599
599
|
function c() {
|
|
600
600
|
r?.(), r = null, n && n.focus && (n.focus(), n = null);
|
|
601
601
|
}
|
|
602
|
-
|
|
602
|
+
let l = Se([t, e], ([e, t]) => {
|
|
603
603
|
e && t ? s() : c();
|
|
604
604
|
}, { flush: "post" });
|
|
605
|
+
he(() => {
|
|
606
|
+
l(), c();
|
|
607
|
+
});
|
|
605
608
|
}
|
|
606
609
|
//#endregion
|
|
607
610
|
//#region src/composables/useEmoji.ts
|
|
608
|
-
function
|
|
609
|
-
let [e, n] = t(!1), r =
|
|
610
|
-
|
|
611
|
+
function Wt() {
|
|
612
|
+
let [e, n] = t(!1), r = ye([]);
|
|
613
|
+
Se(e, async (e) => {
|
|
611
614
|
if (e && r.value.length === 0) {
|
|
612
615
|
let { emojiCategories: e } = await import("./emojiData-BfWQS72m.js");
|
|
613
616
|
r.value = e;
|
|
@@ -628,7 +631,7 @@ function Ut() {
|
|
|
628
631
|
}
|
|
629
632
|
//#endregion
|
|
630
633
|
//#region src/composables/useDragDrop.ts
|
|
631
|
-
function
|
|
634
|
+
function Gt(e) {
|
|
632
635
|
let { onBlockMove: t, onBlockAdd: n } = e, r = L(!1), i = L(null), a = L(null);
|
|
633
636
|
function o(e) {
|
|
634
637
|
r.value = !0, i.value = e;
|
|
@@ -678,7 +681,7 @@ function Wt(e) {
|
|
|
678
681
|
}
|
|
679
682
|
//#endregion
|
|
680
683
|
//#region src/composables/useFonts.ts
|
|
681
|
-
var
|
|
684
|
+
var Kt = [
|
|
682
685
|
{
|
|
683
686
|
value: "Arial",
|
|
684
687
|
label: "Arial"
|
|
@@ -707,7 +710,7 @@ var Gt = [
|
|
|
707
710
|
value: "Courier New",
|
|
708
711
|
label: "Courier New"
|
|
709
712
|
}
|
|
710
|
-
],
|
|
713
|
+
], qt = {
|
|
711
714
|
arial: "Arial, sans-serif",
|
|
712
715
|
helvetica: "Helvetica, sans-serif",
|
|
713
716
|
georgia: "Georgia, serif",
|
|
@@ -715,14 +718,14 @@ var Gt = [
|
|
|
715
718
|
verdana: "Verdana, sans-serif",
|
|
716
719
|
"trebuchet ms": "'Trebuchet MS', sans-serif",
|
|
717
720
|
"courier new": "'Courier New', monospace"
|
|
718
|
-
},
|
|
719
|
-
function
|
|
720
|
-
let t = L(e?.customFonts ?? []), n = L(!0), r = L(!1), i = A(() => e?.defaultFallback ??
|
|
721
|
+
}, Jt = "Arial, sans-serif";
|
|
722
|
+
function Yt(e) {
|
|
723
|
+
let t = L(e?.customFonts ?? []), n = L(!0), r = L(!1), i = A(() => e?.defaultFallback ?? Jt);
|
|
721
724
|
function a(e) {
|
|
722
725
|
n.value = e;
|
|
723
726
|
}
|
|
724
727
|
let o = A(() => {
|
|
725
|
-
let e = [...
|
|
728
|
+
let e = [...Kt];
|
|
726
729
|
if (!n.value) return e.sort((e, t) => e.label.localeCompare(t.label));
|
|
727
730
|
let r = t.value.map((e) => ({
|
|
728
731
|
value: e.name,
|
|
@@ -735,17 +738,17 @@ function Jt(e) {
|
|
|
735
738
|
return o.value.some((t) => t.label.toLowerCase() === e.toLowerCase() || t.value.toLowerCase().startsWith(e.toLowerCase()));
|
|
736
739
|
}
|
|
737
740
|
function c(e) {
|
|
738
|
-
return
|
|
741
|
+
return Kt.some((t) => t.label.toLowerCase() === e.toLowerCase() || t.value.toLowerCase().startsWith(e.toLowerCase()));
|
|
739
742
|
}
|
|
740
743
|
function l() {
|
|
741
744
|
if (e?.defaultFont) {
|
|
742
|
-
if (!n.value && !c(e.defaultFont)) return
|
|
745
|
+
if (!n.value && !c(e.defaultFont)) return Jt;
|
|
743
746
|
if (s(e.defaultFont)) {
|
|
744
747
|
let t = o.value.find((t) => t.label.toLowerCase() === e.defaultFont.toLowerCase() || t.value.toLowerCase().startsWith(e.defaultFont.toLowerCase()));
|
|
745
748
|
if (t) return t.value;
|
|
746
749
|
}
|
|
747
750
|
}
|
|
748
|
-
return
|
|
751
|
+
return Jt;
|
|
749
752
|
}
|
|
750
753
|
let u = A(() => l());
|
|
751
754
|
function d(e) {
|
|
@@ -755,7 +758,7 @@ function Jt(e) {
|
|
|
755
758
|
let e = n.fallback ?? i.value;
|
|
756
759
|
return `'${n.name}', ${e}`;
|
|
757
760
|
}
|
|
758
|
-
return
|
|
761
|
+
return qt[e.toLowerCase()] || (e.includes(",") ? e : `${e}, ${i.value}`);
|
|
759
762
|
}
|
|
760
763
|
let f = [];
|
|
761
764
|
async function p() {
|
|
@@ -780,7 +783,7 @@ function Jt(e) {
|
|
|
780
783
|
for (let e of f) e.remove();
|
|
781
784
|
f.length = 0;
|
|
782
785
|
}
|
|
783
|
-
return
|
|
786
|
+
return ue() && he(m), {
|
|
784
787
|
fonts: o,
|
|
785
788
|
defaultFont: u,
|
|
786
789
|
defaultFallback: i,
|
|
@@ -796,9 +799,9 @@ function Jt(e) {
|
|
|
796
799
|
}
|
|
797
800
|
//#endregion
|
|
798
801
|
//#region src/composables/useRichTextLinkDialog.ts
|
|
799
|
-
function
|
|
802
|
+
function Xt(e) {
|
|
800
803
|
let t = L(!1), n = L(""), r = L(null);
|
|
801
|
-
|
|
804
|
+
Ut(r, t);
|
|
802
805
|
function i() {
|
|
803
806
|
n.value = e.value?.getAttributes("link").href || "", t.value = !0;
|
|
804
807
|
}
|
|
@@ -831,9 +834,9 @@ function Yt(e) {
|
|
|
831
834
|
}
|
|
832
835
|
//#endregion
|
|
833
836
|
//#region src/composables/useRichTextEditor.ts
|
|
834
|
-
function
|
|
835
|
-
let t =
|
|
836
|
-
async function
|
|
837
|
+
function Zt(e) {
|
|
838
|
+
let t = de(f, null), { mergeTags: n, isEnabled: r, isRequesting: i, requestMergeTag: s, syntax: c } = re(), l = ye(null), { showLinkDialog: u, linkUrl: d, linkDialogRef: p, openLinkDialog: m, insertLink: h, removeLink: g, closeLinkDialog: _, handleLinkKeydown: v } = Xt(l), { start: y, stop: b } = o(() => l.value?.commands.focus("end"), 0, { immediate: !1 }), x = ye(null), S = L(!0), C = L(null);
|
|
839
|
+
async function w() {
|
|
837
840
|
C.value = null, S.value = !0;
|
|
838
841
|
try {
|
|
839
842
|
let { TiptapEditor: r, EC: i, extensions: a } = await e.loadExtensions({
|
|
@@ -854,21 +857,22 @@ function Xt(e) {
|
|
|
854
857
|
console.error(`[${e.editorName ?? "RichTextEditor"}] Failed to initialize TipTap editor:`, t), C.value = t instanceof Error ? t.message : "Failed to load editor", S.value = !1;
|
|
855
858
|
}
|
|
856
859
|
}
|
|
857
|
-
function
|
|
858
|
-
l.value?.destroy(), l.value = null,
|
|
860
|
+
function T() {
|
|
861
|
+
l.value?.destroy(), l.value = null, w();
|
|
859
862
|
}
|
|
860
|
-
|
|
863
|
+
w();
|
|
864
|
+
let E = Se(() => e.blockContent(), (e) => {
|
|
861
865
|
l.value && l.value.getHTML() !== e && l.value.commands.setContent(e, { emitUpdate: !1 });
|
|
862
866
|
});
|
|
863
|
-
function
|
|
867
|
+
function D(t) {
|
|
864
868
|
if (i.value) return;
|
|
865
869
|
let n = t.target;
|
|
866
870
|
e.onClickOutsideSideEffect?.(n), !(n.closest(".tpl-text-editor-wrapper") || n.closest(".tpl-text-toolbar") || n.closest(".tpl-link-dialog")) && e.onDone();
|
|
867
871
|
}
|
|
868
|
-
a(document, "mousedown",
|
|
869
|
-
b(), l.value?.destroy();
|
|
872
|
+
a(document, "mousedown", D), pe(() => {
|
|
873
|
+
E(), b(), l.value?.destroy();
|
|
870
874
|
});
|
|
871
|
-
async function
|
|
875
|
+
async function O() {
|
|
872
876
|
let e = await s();
|
|
873
877
|
e && l.value ? l.value.chain().focus().insertMergeTag({
|
|
874
878
|
label: e.label,
|
|
@@ -880,7 +884,7 @@ function Xt(e) {
|
|
|
880
884
|
EditorContent: x,
|
|
881
885
|
isLoading: S,
|
|
882
886
|
initError: C,
|
|
883
|
-
retry:
|
|
887
|
+
retry: T,
|
|
884
888
|
showLinkDialog: u,
|
|
885
889
|
linkUrl: d,
|
|
886
890
|
linkDialogRef: p,
|
|
@@ -893,25 +897,25 @@ function Xt(e) {
|
|
|
893
897
|
removeLink: g,
|
|
894
898
|
closeLinkDialog: _,
|
|
895
899
|
handleLinkKeydown: v,
|
|
896
|
-
handleAddMergeTag:
|
|
900
|
+
handleAddMergeTag: O
|
|
897
901
|
};
|
|
898
902
|
}
|
|
899
903
|
//#endregion
|
|
900
904
|
//#region src/components/blocks/CustomBlock.vue?vue&type=script&setup=true&lang.ts
|
|
901
|
-
var
|
|
905
|
+
var Qt = { class: "tpl:w-full" }, $t = {
|
|
902
906
|
key: 0,
|
|
903
907
|
class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-warning)] tpl:bg-[var(--tpl-warning-light)]"
|
|
904
|
-
},
|
|
908
|
+
}, en = { class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, tn = {
|
|
905
909
|
key: 1,
|
|
906
910
|
class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-danger)] tpl:bg-[var(--tpl-danger-light)]"
|
|
907
|
-
},
|
|
911
|
+
}, nn = { class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, rn = {
|
|
908
912
|
key: 2,
|
|
909
913
|
class: "tpl:relative"
|
|
910
|
-
},
|
|
914
|
+
}, an = ["innerHTML"], on = {
|
|
911
915
|
key: 0,
|
|
912
916
|
class: "tpl:absolute tpl:inset-0 tpl:flex tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-3 tpl:rounded tpl:backdrop-blur-[2px]",
|
|
913
917
|
style: { "background-color": "color-mix(in srgb, var(--tpl-bg) 80%, transparent)" }
|
|
914
|
-
},
|
|
918
|
+
}, sn = /* @__PURE__ */ le({
|
|
915
919
|
__name: "CustomBlock",
|
|
916
920
|
props: {
|
|
917
921
|
block: {},
|
|
@@ -919,7 +923,7 @@ var Zt = { class: "tpl:w-full" }, Qt = {
|
|
|
919
923
|
},
|
|
920
924
|
emits: ["fetchData"],
|
|
921
925
|
setup(t, { emit: n }) {
|
|
922
|
-
let r = t, i = n, { t: a } =
|
|
926
|
+
let r = t, i = n, { t: a } = E(), o = de(y, null), s = L(""), c = L(!1), l = A(() => o?.getDefinition(r.block.customType)), u = A(() => !!l.value), { isFetching: d, fetch: f, needsFetch: p, hasDataSource: m } = Ae({
|
|
923
927
|
definition: l,
|
|
924
928
|
block: A(() => r.block),
|
|
925
929
|
onUpdate: (e, t) => {
|
|
@@ -941,31 +945,31 @@ var Zt = { class: "tpl:w-full" }, Qt = {
|
|
|
941
945
|
}
|
|
942
946
|
}
|
|
943
947
|
let g = e(h, 150);
|
|
944
|
-
return
|
|
948
|
+
return me(() => {
|
|
945
949
|
h();
|
|
946
|
-
}),
|
|
950
|
+
}), Se(() => r.block.fieldValues, () => {
|
|
947
951
|
g();
|
|
948
|
-
}, { deep: !0 }), (e, t) => (
|
|
952
|
+
}, { deep: !0 }), (e, t) => (F(), j("div", Qt, [u.value ? c.value ? (F(), j("div", tn, [N(z(te), {
|
|
949
953
|
size: 24,
|
|
950
954
|
class: "tpl:text-[var(--tpl-danger)]"
|
|
951
|
-
}), M("span",
|
|
955
|
+
}), M("span", nn, R(z(a).customBlocks.renderError), 1)])) : (F(), j("div", rn, [M("div", { innerHTML: s.value }, null, 8, an), z(m) && z(p) ? (F(), j("div", on, [z(d) ? (F(), ae(ne, {
|
|
952
956
|
key: 1,
|
|
953
957
|
class: "tpl:w-48"
|
|
954
|
-
})) : (
|
|
958
|
+
})) : (F(), j("button", {
|
|
955
959
|
key: 0,
|
|
956
960
|
type: "button",
|
|
957
961
|
class: "tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:border-[var(--tpl-border)] tpl:px-4 tpl:py-2 tpl:text-sm tpl:font-semibold tpl:shadow-sm tpl:transition-all tpl:duration-150 hover:tpl:border-[var(--tpl-primary)] hover:tpl:shadow-md tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary-hover)]",
|
|
958
|
-
onClick: t[0] ||=
|
|
959
|
-
}, [l.value?.icon ? (
|
|
962
|
+
onClick: t[0] ||= Ee((...e) => z(f) && z(f)(...e), ["stop"])
|
|
963
|
+
}, [l.value?.icon ? (F(), ae(Vt, {
|
|
960
964
|
key: 0,
|
|
961
965
|
icon: l.value.icon,
|
|
962
966
|
size: 16
|
|
963
|
-
}, null, 8, ["icon"])) :
|
|
967
|
+
}, null, 8, ["icon"])) : oe("", !0), se(" " + R(l.value?.dataSource?.label || z(a).customBlocks.dataSource.fetchButton), 1)]))])) : oe("", !0)])) : (F(), j("div", $t, [N(z(Ft), {
|
|
964
968
|
size: 24,
|
|
965
969
|
class: "tpl:text-[var(--tpl-warning)]"
|
|
966
|
-
}), M("span",
|
|
970
|
+
}), M("span", en, R(z(a).customBlocks.definitionNotFound), 1)]))]));
|
|
967
971
|
}
|
|
968
|
-
}),
|
|
972
|
+
}), cn = { class: "tpl:w-full" }, ln = /* @__PURE__ */ le({
|
|
969
973
|
__name: "DividerBlock",
|
|
970
974
|
props: {
|
|
971
975
|
block: {},
|
|
@@ -977,37 +981,37 @@ var Zt = { class: "tpl:w-full" }, Qt = {
|
|
|
977
981
|
width: t.block.width === "full" ? "100%" : `${t.block.width}px`,
|
|
978
982
|
margin: t.block.width === "full" ? "0" : "0 auto"
|
|
979
983
|
}));
|
|
980
|
-
return (e, t) => (
|
|
984
|
+
return (e, t) => (F(), j("div", cn, [M("hr", {
|
|
981
985
|
class: "tpl:m-0 tpl:border-none",
|
|
982
|
-
style:
|
|
986
|
+
style: P(n.value)
|
|
983
987
|
}, null, 4)]));
|
|
984
988
|
}
|
|
985
|
-
}),
|
|
989
|
+
}), un = { class: "tpl:w-full" }, dn = { class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)]" }, fn = {
|
|
986
990
|
key: 0,
|
|
987
991
|
class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]"
|
|
988
|
-
},
|
|
992
|
+
}, pn = {
|
|
989
993
|
key: 1,
|
|
990
994
|
class: "tpl:text-sm tpl:text-[var(--tpl-text-dim)]"
|
|
991
|
-
},
|
|
995
|
+
}, mn = /* @__PURE__ */ le({
|
|
992
996
|
__name: "HtmlBlock",
|
|
993
997
|
props: {
|
|
994
998
|
block: {},
|
|
995
999
|
viewport: {}
|
|
996
1000
|
},
|
|
997
1001
|
setup(e) {
|
|
998
|
-
let t = e, { t: n } =
|
|
999
|
-
return (e, t) => (
|
|
1002
|
+
let t = e, { t: n } = E(), r = A(() => t.block.content.trim().length > 0);
|
|
1003
|
+
return (e, t) => (F(), j("div", un, [M("div", dn, [N(z(Ot), {
|
|
1000
1004
|
size: 24,
|
|
1001
1005
|
class: "tpl:text-[var(--tpl-text-dim)]"
|
|
1002
|
-
}), r.value ? (
|
|
1006
|
+
}), r.value ? (F(), j("span", fn, R(z(n).html.preview), 1)) : (F(), j("span", pn, R(z(n).html.empty), 1))])]));
|
|
1003
1007
|
}
|
|
1004
|
-
}),
|
|
1008
|
+
}), hn = ["href"], gn = ["src", "alt"], _n = ["src", "alt"], vn = {
|
|
1005
1009
|
class: "tpl:max-w-full tpl:truncate tpl:px-3 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-primary)]",
|
|
1006
1010
|
style: { opacity: "0.7" }
|
|
1007
|
-
},
|
|
1011
|
+
}, yn = ["href"], bn = ["src", "alt"], xn = ["src", "alt"], Sn = {
|
|
1008
1012
|
key: 3,
|
|
1009
1013
|
class: "tpl:flex tpl:min-h-[100px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-sm tpl:border-[var(--tpl-border-light)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-dim)]"
|
|
1010
|
-
},
|
|
1014
|
+
}, Cn = ["aria-label"], wn = { key: 1 }, Tn = /* @__PURE__ */ le({
|
|
1011
1015
|
__name: "ImageBlock",
|
|
1012
1016
|
props: {
|
|
1013
1017
|
block: {},
|
|
@@ -1015,7 +1019,7 @@ var Zt = { class: "tpl:w-full" }, Qt = {
|
|
|
1015
1019
|
},
|
|
1016
1020
|
emits: ["update"],
|
|
1017
1021
|
setup(e, { emit: t }) {
|
|
1018
|
-
let n = e, r = t, { t: i } =
|
|
1022
|
+
let n = e, r = t, { t: i } = E(), { syntax: a } = re(), o = de(l, null), s = A(() => !!o);
|
|
1019
1023
|
async function c() {
|
|
1020
1024
|
let e = await o?.({ accept: ["images"] });
|
|
1021
1025
|
if (e) {
|
|
@@ -1029,76 +1033,76 @@ var Zt = { class: "tpl:w-full" }, Qt = {
|
|
|
1029
1033
|
display: "block",
|
|
1030
1034
|
margin: n.block.align === "center" ? "0 auto" : void 0,
|
|
1031
1035
|
marginLeft: n.block.align === "right" ? "auto" : void 0
|
|
1032
|
-
})), f = A(() =>
|
|
1033
|
-
return (t, n) => (
|
|
1036
|
+
})), f = A(() => Pe(n.block.src, a));
|
|
1037
|
+
return (t, n) => (F(), j("div", {
|
|
1034
1038
|
class: "tpl:w-full",
|
|
1035
|
-
style:
|
|
1036
|
-
}, [e.block.src && f.value && e.block.placeholderUrl ? (
|
|
1039
|
+
style: P(u.value)
|
|
1040
|
+
}, [e.block.src && f.value && e.block.placeholderUrl ? (F(), j(ie, { key: 0 }, [e.block.linkUrl ? (F(), j("a", {
|
|
1037
1041
|
key: 0,
|
|
1038
1042
|
href: e.block.linkUrl,
|
|
1039
1043
|
target: "_blank",
|
|
1040
1044
|
rel: "noopener noreferrer",
|
|
1041
|
-
onClick: n[0] ||=
|
|
1045
|
+
onClick: n[0] ||= Ee(() => {}, ["prevent"])
|
|
1042
1046
|
}, [M("img", {
|
|
1043
1047
|
class: "tpl:border-0",
|
|
1044
1048
|
loading: "lazy",
|
|
1045
1049
|
src: e.block.placeholderUrl,
|
|
1046
1050
|
alt: e.block.alt || z(i).image.altTextPlaceholder,
|
|
1047
|
-
style:
|
|
1048
|
-
}, null, 12,
|
|
1051
|
+
style: P(d.value)
|
|
1052
|
+
}, null, 12, gn)], 8, hn)) : (F(), j("img", {
|
|
1049
1053
|
key: 1,
|
|
1050
1054
|
class: "tpl:border-0",
|
|
1051
1055
|
src: e.block.placeholderUrl,
|
|
1052
1056
|
alt: e.block.alt,
|
|
1053
|
-
style:
|
|
1054
|
-
}, null, 12,
|
|
1057
|
+
style: P(d.value)
|
|
1058
|
+
}, null, 12, _n))], 64)) : e.block.src && f.value ? (F(), j("div", {
|
|
1055
1059
|
key: 1,
|
|
1056
1060
|
class: "tpl:!flex tpl:min-h-[120px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-center tpl:bg-[var(--tpl-bg-elevated)]",
|
|
1057
|
-
style:
|
|
1058
|
-
}, [N(z(
|
|
1061
|
+
style: P([{ "border-color": "color-mix(in srgb, var(--tpl-primary) 40%, transparent)" }, d.value])
|
|
1062
|
+
}, [N(z(Nt), {
|
|
1059
1063
|
size: 32,
|
|
1060
1064
|
"stroke-width": 1.5,
|
|
1061
1065
|
class: "tpl:text-[var(--tpl-primary)]",
|
|
1062
1066
|
style: { opacity: "0.5" }
|
|
1063
|
-
}), M("span",
|
|
1067
|
+
}), M("span", vn, R(e.block.src), 1)], 4)) : e.block.src ? (F(), j(ie, { key: 2 }, [e.block.linkUrl ? (F(), j("a", {
|
|
1064
1068
|
key: 0,
|
|
1065
1069
|
href: e.block.linkUrl,
|
|
1066
1070
|
target: "_blank",
|
|
1067
1071
|
rel: "noopener noreferrer",
|
|
1068
|
-
onClick: n[1] ||=
|
|
1072
|
+
onClick: n[1] ||= Ee(() => {}, ["prevent"])
|
|
1069
1073
|
}, [M("img", {
|
|
1070
1074
|
class: "tpl:border-0",
|
|
1071
1075
|
loading: "lazy",
|
|
1072
1076
|
src: e.block.src,
|
|
1073
1077
|
alt: e.block.alt || z(i).image.altTextPlaceholder,
|
|
1074
|
-
style:
|
|
1075
|
-
}, null, 12,
|
|
1078
|
+
style: P(d.value)
|
|
1079
|
+
}, null, 12, bn)], 8, yn)) : (F(), j("img", {
|
|
1076
1080
|
key: 1,
|
|
1077
1081
|
class: "tpl:border-0",
|
|
1078
1082
|
src: e.block.src,
|
|
1079
1083
|
alt: e.block.alt,
|
|
1080
|
-
style:
|
|
1081
|
-
}, null, 12,
|
|
1084
|
+
style: P(d.value)
|
|
1085
|
+
}, null, 12, xn))], 64)) : (F(), j("div", Sn, [s.value ? (F(), j("button", {
|
|
1082
1086
|
key: 0,
|
|
1083
1087
|
"aria-label": z(i).image.browseMedia,
|
|
1084
1088
|
class: "tpl:flex tpl:items-center tpl:gap-1.5 tpl:rounded-md tpl:border tpl:px-3 tpl:py-2 tpl:text-xs tpl:font-medium tpl:transition-all tpl:duration-150 tpl:cursor-pointer tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-primary)] tpl:bg-[var(--tpl-bg)]",
|
|
1085
|
-
onClick:
|
|
1086
|
-
}, [N(z(
|
|
1089
|
+
onClick: Ee(c, ["stop"])
|
|
1090
|
+
}, [N(z(Nt), {
|
|
1087
1091
|
size: 14,
|
|
1088
1092
|
"stroke-width": 1.5
|
|
1089
|
-
}),
|
|
1093
|
+
}), se(" " + R(z(i).image.browseMedia), 1)], 8, Cn)) : (F(), j("span", wn, R(z(i).image.clickToAdd), 1))]))], 4));
|
|
1090
1094
|
}
|
|
1091
|
-
}),
|
|
1095
|
+
}), En = { class: "tpl:w-full" }, Dn = ["href"], On = {
|
|
1092
1096
|
key: 1,
|
|
1093
1097
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
|
|
1094
|
-
},
|
|
1098
|
+
}, kn = /* @__PURE__ */ le({
|
|
1095
1099
|
__name: "MenuBlock",
|
|
1096
1100
|
props: {
|
|
1097
1101
|
block: {},
|
|
1098
1102
|
viewport: {}
|
|
1099
1103
|
},
|
|
1100
1104
|
setup(e) {
|
|
1101
|
-
let t = e, { t: n } =
|
|
1105
|
+
let t = e, { t: n } = E(), r = A(() => ({
|
|
1102
1106
|
display: "flex",
|
|
1103
1107
|
flexWrap: "wrap",
|
|
1104
1108
|
gap: `0 ${t.block.spacing}px`,
|
|
@@ -1110,31 +1114,31 @@ var Zt = { class: "tpl:w-full" }, Qt = {
|
|
|
1110
1114
|
function a(e) {
|
|
1111
1115
|
return e || t.block.linkColor || t.block.color;
|
|
1112
1116
|
}
|
|
1113
|
-
return (t, o) => (
|
|
1117
|
+
return (t, o) => (F(), j("div", En, [i.value ? (F(), j("div", {
|
|
1114
1118
|
key: 0,
|
|
1115
|
-
style:
|
|
1116
|
-
}, [(
|
|
1119
|
+
style: P(r.value)
|
|
1120
|
+
}, [(F(!0), j(ie, null, ge(e.block.items, (t, n) => (F(), j(ie, { key: t.id }, [M("a", {
|
|
1117
1121
|
href: t.url || "#",
|
|
1118
1122
|
class: "tpl:cursor-default tpl:no-underline",
|
|
1119
|
-
style:
|
|
1123
|
+
style: P({
|
|
1120
1124
|
color: a(t.color),
|
|
1121
1125
|
fontWeight: t.bold ? "bold" : "normal",
|
|
1122
1126
|
textDecoration: t.underline ? "underline" : "none"
|
|
1123
1127
|
}),
|
|
1124
|
-
onClick: o[0] ||=
|
|
1125
|
-
}, R(t.text || "..."), 13,
|
|
1128
|
+
onClick: o[0] ||= Ee(() => {}, ["prevent"])
|
|
1129
|
+
}, R(t.text || "..."), 13, Dn), n < e.block.items.length - 1 ? (F(), j("span", {
|
|
1126
1130
|
key: 0,
|
|
1127
|
-
style:
|
|
1131
|
+
style: P({
|
|
1128
1132
|
color: e.block.separatorColor,
|
|
1129
1133
|
padding: `0 ${e.block.spacing}px`
|
|
1130
1134
|
})
|
|
1131
|
-
}, R(e.block.separator), 5)) :
|
|
1135
|
+
}, R(e.block.separator), 5)) : oe("", !0)], 64))), 128))], 4)) : (F(), j("div", On, [N(z(Pt), { size: 16 }), M("span", null, R(z(n).menu.addLinks), 1)]))]));
|
|
1132
1136
|
}
|
|
1133
1137
|
});
|
|
1134
1138
|
//#endregion
|
|
1135
1139
|
//#region src/composables/useEditableTextBlock.ts
|
|
1136
|
-
function
|
|
1137
|
-
let t =
|
|
1140
|
+
function An(e) {
|
|
1141
|
+
let t = de(m, []), { syntax: n } = re(), i = A(() => Ye(Xe(e(), t), n)), a = L(!1), o = L(null), { top: s, left: c } = r(o), l = A(() => ({
|
|
1138
1142
|
top: s.value - 8,
|
|
1139
1143
|
left: c.value
|
|
1140
1144
|
}));
|
|
@@ -1155,20 +1159,20 @@ function kn(e) {
|
|
|
1155
1159
|
}
|
|
1156
1160
|
//#endregion
|
|
1157
1161
|
//#region src/components/blocks/ParagraphBlock.vue?vue&type=script&setup=true&lang.ts
|
|
1158
|
-
var
|
|
1162
|
+
var jn = ["innerHTML"], Mn = /* @__PURE__ */ le({
|
|
1159
1163
|
__name: "ParagraphBlock",
|
|
1160
1164
|
props: {
|
|
1161
1165
|
block: {},
|
|
1162
1166
|
viewport: {}
|
|
1163
1167
|
},
|
|
1164
1168
|
setup(e) {
|
|
1165
|
-
let t = e, n =
|
|
1166
|
-
return (t, l) => (
|
|
1169
|
+
let t = e, n = ce(() => import("./ParagraphEditor-DH8cSC6m.js")), { isEditing: r, blockRef: i, toolbarPosition: a, resolvedContent: o, handleDoubleClick: s, handleEditorDone: c } = An(() => t.block.content);
|
|
1170
|
+
return (t, l) => (F(), j("div", {
|
|
1167
1171
|
ref_key: "blockRef",
|
|
1168
1172
|
ref: i,
|
|
1169
1173
|
class: "tpl:min-h-[1em] tpl:w-full",
|
|
1170
1174
|
onDblclick: l[0] ||= (...e) => z(s) && z(s)(...e)
|
|
1171
|
-
}, [z(r) ? (
|
|
1175
|
+
}, [z(r) ? (F(), ae(z(n), {
|
|
1172
1176
|
key: 0,
|
|
1173
1177
|
block: e.block,
|
|
1174
1178
|
"toolbar-position": z(a),
|
|
@@ -1177,23 +1181,23 @@ var An = ["innerHTML"], jn = /* @__PURE__ */ P({
|
|
|
1177
1181
|
"block",
|
|
1178
1182
|
"toolbar-position",
|
|
1179
1183
|
"onDone"
|
|
1180
|
-
])) : (
|
|
1184
|
+
])) : (F(), j("div", {
|
|
1181
1185
|
key: 1,
|
|
1182
1186
|
class: "tpl-text-content tpl:outline-none [&_a]:tpl:underline [&_li]:tpl:my-1 [&_ol]:tpl:my-2 [&_ol]:tpl:pl-6 [&_p]:tpl:m-0 [&_p]:tpl:mb-2 [&_p:last-child]:tpl:mb-0 [&_s]:tpl:line-through [&_sub]:tpl:align-sub [&_sub]:tpl:text-[0.75em] [&_sup]:tpl:align-super [&_sup]:tpl:text-[0.75em] [&_ul]:tpl:my-2 [&_ul]:tpl:pl-6",
|
|
1183
1187
|
innerHTML: z(o)
|
|
1184
|
-
}, null, 8,
|
|
1188
|
+
}, null, 8, jn))], 544));
|
|
1185
1189
|
}
|
|
1186
1190
|
});
|
|
1187
1191
|
//#endregion
|
|
1188
1192
|
//#region src/utils/blockComponentResolver.ts
|
|
1189
|
-
function
|
|
1193
|
+
function Nn(e, t, n) {
|
|
1190
1194
|
if (t) {
|
|
1191
1195
|
let n = t.getComponent(e);
|
|
1192
1196
|
if (n) return n;
|
|
1193
1197
|
}
|
|
1194
1198
|
return n[e.type] ?? null;
|
|
1195
1199
|
}
|
|
1196
|
-
function
|
|
1200
|
+
function Pn(e) {
|
|
1197
1201
|
let { padding: t, margin: n, backgroundColor: r } = e.styles;
|
|
1198
1202
|
return {
|
|
1199
1203
|
padding: `${t.top}px ${t.right}px ${t.bottom}px ${t.left}px`,
|
|
@@ -1203,16 +1207,16 @@ function Nn(e) {
|
|
|
1203
1207
|
}
|
|
1204
1208
|
//#endregion
|
|
1205
1209
|
//#region src/components/blocks/BlockWrapper.vue?vue&type=script&setup=true&lang.ts
|
|
1206
|
-
var
|
|
1210
|
+
var Fn = ["data-block-id", "data-block-type"], In = ["aria-label"], Ln = ["aria-label", "title"], Rn = ["aria-label", "title"], zn = ["aria-label", "title"], Bn = ["aria-label", "title"], Vn = {
|
|
1207
1211
|
key: 1,
|
|
1208
1212
|
class: "tpl-block-hidden-overlay tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:z-[5] tpl:flex tpl:items-center tpl:justify-center tpl:rounded-sm"
|
|
1209
|
-
},
|
|
1213
|
+
}, Hn = { class: "tpl:flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-2 tpl:py-1 tpl:text-[10px] tpl:font-medium tpl:bg-[var(--tpl-bg-elevated)] tpl:text-[var(--tpl-text-muted)] tpl:shadow-[var(--tpl-shadow-sm)]" }, Un = {
|
|
1210
1214
|
key: 2,
|
|
1211
1215
|
class: "tpl:absolute tpl:-left-1 tpl:top-1/2 tpl:z-[5] tpl:-translate-x-full tpl:-translate-y-1/2"
|
|
1212
|
-
},
|
|
1216
|
+
}, Wn = ["aria-label", "title"], Gn = {
|
|
1213
1217
|
key: 3,
|
|
1214
1218
|
class: "tpl:absolute tpl:-right-1 tpl:-top-1 tpl:z-[5] tpl:translate-x-full"
|
|
1215
|
-
},
|
|
1219
|
+
}, Kn = ["aria-label"], qn = /* @__PURE__ */ O(/* @__PURE__ */ le({
|
|
1216
1220
|
__name: "BlockWrapper",
|
|
1217
1221
|
props: {
|
|
1218
1222
|
block: {},
|
|
@@ -1222,11 +1226,11 @@ var Pn = ["data-block-id", "data-block-type"], Fn = ["aria-label"], In = ["aria-
|
|
|
1222
1226
|
},
|
|
1223
1227
|
emits: ["select"],
|
|
1224
1228
|
setup(e, { emit: t }) {
|
|
1225
|
-
let n = e, r = t, { t: i, format: a } =
|
|
1229
|
+
let n = e, r = t, { t: i, format: a } = E(), o = A(() => !n.viewport || !n.block.visibility ? !1 : n.block.visibility[n.viewport] === !1), s = A(() => n.viewport ? {
|
|
1226
1230
|
desktop: i.viewport.desktop,
|
|
1227
1231
|
tablet: i.viewport.tablet,
|
|
1228
1232
|
mobile: i.viewport.mobile
|
|
1229
|
-
}[n.viewport] ?? n.viewport : ""), c = A(() => !!n.block.displayCondition), l =
|
|
1233
|
+
}[n.viewport] ?? n.viewport : ""), c = A(() => !!n.block.displayCondition), l = de(h, null), u = de(g, null), d = de(x, {}), f = A(() => !!d.savedModules), p = A(() => d.comments?.getBlockCount(n.block.id) ?? 0), m = A(() => Pn(n.block));
|
|
1230
1234
|
function _(e) {
|
|
1231
1235
|
n.previewMode || (e.stopPropagation(), r("select"));
|
|
1232
1236
|
}
|
|
@@ -1242,18 +1246,18 @@ var Pn = ["data-block-id", "data-block-type"], Fn = ["aria-label"], In = ["aria-
|
|
|
1242
1246
|
function S() {
|
|
1243
1247
|
u?.toggleBlock(n.block.id);
|
|
1244
1248
|
}
|
|
1245
|
-
return (t, n) => (
|
|
1246
|
-
class:
|
|
1249
|
+
return (t, n) => (F(), j("div", {
|
|
1250
|
+
class: fe(["tpl-block tpl:group tpl:relative tpl:cursor-pointer tpl:rounded-sm tpl:transition-shadow tpl:duration-150", {
|
|
1247
1251
|
"tpl-block--selected": e.isSelected,
|
|
1248
1252
|
"tpl-block--idle": !e.isSelected
|
|
1249
1253
|
}]),
|
|
1250
|
-
style:
|
|
1254
|
+
style: P(m.value),
|
|
1251
1255
|
"data-block-id": e.block.id,
|
|
1252
1256
|
"data-block-type": e.block.type,
|
|
1253
1257
|
draggable: "false",
|
|
1254
1258
|
onClick: _
|
|
1255
1259
|
}, [
|
|
1256
|
-
e.isSelected ? (
|
|
1260
|
+
e.isSelected ? (F(), j("div", {
|
|
1257
1261
|
key: 0,
|
|
1258
1262
|
role: "toolbar",
|
|
1259
1263
|
"aria-label": z(i).blockActions.drag,
|
|
@@ -1263,85 +1267,85 @@ var Pn = ["data-block-id", "data-block-type"], Fn = ["aria-label"], In = ["aria-
|
|
|
1263
1267
|
class: "tpl-block-btn tpl-block-action-btn tpl:flex tpl:size-7 tpl:cursor-grab tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors tpl:duration-150 tpl:active:cursor-grabbing",
|
|
1264
1268
|
"aria-label": z(i).blockActions.drag,
|
|
1265
1269
|
title: z(i).blockActions.drag
|
|
1266
|
-
}, [N(z(
|
|
1270
|
+
}, [N(z(Mt), {
|
|
1267
1271
|
size: 14,
|
|
1268
1272
|
"stroke-width": 1.5
|
|
1269
|
-
})], 8,
|
|
1273
|
+
})], 8, Ln),
|
|
1270
1274
|
M("button", {
|
|
1271
1275
|
class: "tpl-block-action-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors tpl:duration-150",
|
|
1272
1276
|
"aria-label": z(i).blockActions.duplicate,
|
|
1273
1277
|
title: z(i).blockActions.duplicate,
|
|
1274
|
-
onClick:
|
|
1275
|
-
}, [N(z(
|
|
1278
|
+
onClick: Ee(y, ["stop"])
|
|
1279
|
+
}, [N(z(kt), {
|
|
1276
1280
|
size: 14,
|
|
1277
1281
|
"stroke-width": 1.5
|
|
1278
|
-
})], 8,
|
|
1279
|
-
f.value ? (
|
|
1282
|
+
})], 8, Rn),
|
|
1283
|
+
f.value ? (F(), j("button", {
|
|
1280
1284
|
key: 0,
|
|
1281
1285
|
class: "tpl-block-action-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors tpl:duration-150",
|
|
1282
1286
|
"aria-label": z(i).blockActions.saveAsModule,
|
|
1283
1287
|
title: z(i).blockActions.saveAsModule,
|
|
1284
|
-
onClick:
|
|
1285
|
-
}, [N(z(
|
|
1288
|
+
onClick: Ee(b, ["stop"])
|
|
1289
|
+
}, [N(z(Et), {
|
|
1286
1290
|
size: 14,
|
|
1287
1291
|
"stroke-width": 1.5
|
|
1288
|
-
})], 8,
|
|
1292
|
+
})], 8, zn)) : oe("", !0),
|
|
1289
1293
|
M("button", {
|
|
1290
1294
|
class: "tpl-block-action-btn tpl-block-delete-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors tpl:duration-150",
|
|
1291
1295
|
"aria-label": z(i).blockActions.delete,
|
|
1292
1296
|
title: z(i).blockActions.delete,
|
|
1293
|
-
onClick:
|
|
1294
|
-
}, [N(z(
|
|
1297
|
+
onClick: Ee(v, ["stop"])
|
|
1298
|
+
}, [N(z(k), {
|
|
1295
1299
|
size: 14,
|
|
1296
1300
|
"stroke-width": 1.5
|
|
1297
|
-
})], 8,
|
|
1298
|
-
], 8,
|
|
1299
|
-
o.value ? (
|
|
1301
|
+
})], 8, Bn)
|
|
1302
|
+
], 8, In)) : oe("", !0),
|
|
1303
|
+
o.value ? (F(), j("div", Vn, [M("span", Hn, [N(z(At), {
|
|
1300
1304
|
size: 12,
|
|
1301
1305
|
"stroke-width": 1.5
|
|
1302
|
-
}),
|
|
1303
|
-
c.value && !o.value ? (
|
|
1306
|
+
}), se(" " + R(z(a)(z(i).blockActions.hiddenOnViewport, { viewport: s.value })), 1)])])) : oe("", !0),
|
|
1307
|
+
c.value && !o.value ? (F(), j("div", Un, [M("button", {
|
|
1304
1308
|
class: "tpl-condition-toggle tpl:flex tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-md tpl:p-1 tpl:transition-colors tpl:duration-150 tpl:bg-[var(--tpl-bg-elevated)] tpl:text-[var(--tpl-primary)] tpl:border tpl:border-[var(--tpl-border)]",
|
|
1305
1309
|
"aria-label": z(i).blockActions.conditionToggle,
|
|
1306
1310
|
title: e.block.displayCondition?.label,
|
|
1307
|
-
onClick:
|
|
1308
|
-
}, [N(z(
|
|
1311
|
+
onClick: Ee(S, ["stop"])
|
|
1312
|
+
}, [N(z(jt), {
|
|
1309
1313
|
size: 12,
|
|
1310
1314
|
"stroke-width": 2
|
|
1311
|
-
})], 8,
|
|
1312
|
-
p.value > 0 && !o.value ? (
|
|
1315
|
+
})], 8, Wn)])) : oe("", !0),
|
|
1316
|
+
p.value > 0 && !o.value ? (F(), j("div", Gn, [M("button", {
|
|
1313
1317
|
class: "tpl-comment-indicator tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-0.5 tpl:rounded-full tpl:border-none tpl:px-1.5 tpl:py-0.5 tpl:text-[10px] tpl:font-semibold tpl:transition-colors tpl:duration-150 tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary)]",
|
|
1314
1318
|
"aria-label": z(a)(z(i).blockActions.comments, { count: String(p.value) }),
|
|
1315
|
-
onClick: n[0] ||=
|
|
1316
|
-
}, [N(z(
|
|
1319
|
+
onClick: n[0] ||= Ee((t) => z(d).comments?.openForBlock(e.block.id), ["stop"])
|
|
1320
|
+
}, [N(z(ee), {
|
|
1317
1321
|
size: 10,
|
|
1318
1322
|
"stroke-width": 2.5
|
|
1319
|
-
}),
|
|
1320
|
-
|
|
1321
|
-
], 14,
|
|
1323
|
+
}), se(" " + R(p.value), 1)], 8, Kn)])) : oe("", !0),
|
|
1324
|
+
_e(t.$slots, "default", {}, void 0, !0)
|
|
1325
|
+
], 14, Fn));
|
|
1322
1326
|
}
|
|
1323
|
-
}), [["__scopeId", "data-v-
|
|
1327
|
+
}), [["__scopeId", "data-v-3966b698"]]), Jn = ["innerHTML"], Yn = /* @__PURE__ */ le({
|
|
1324
1328
|
__name: "TitleBlock",
|
|
1325
1329
|
props: {
|
|
1326
1330
|
block: {},
|
|
1327
1331
|
viewport: {}
|
|
1328
1332
|
},
|
|
1329
1333
|
setup(e) {
|
|
1330
|
-
let t = e, n =
|
|
1334
|
+
let t = e, n = ce(() => import("./TitleEditor-CLcDdcWI.js")), { isEditing: r, blockRef: i, toolbarPosition: a, resolvedContent: o, handleDoubleClick: s, handleEditorDone: c } = An(() => t.block.content), l = A(() => {
|
|
1331
1335
|
let e = {
|
|
1332
|
-
fontSize: `${
|
|
1336
|
+
fontSize: `${Ne[t.block.level]}px`,
|
|
1333
1337
|
color: t.block.color,
|
|
1334
1338
|
textAlign: t.block.textAlign
|
|
1335
1339
|
};
|
|
1336
1340
|
return t.block.fontFamily && (e.fontFamily = t.block.fontFamily), e;
|
|
1337
1341
|
});
|
|
1338
|
-
return (t, u) => (
|
|
1342
|
+
return (t, u) => (F(), j("div", {
|
|
1339
1343
|
ref_key: "blockRef",
|
|
1340
1344
|
ref: i,
|
|
1341
1345
|
class: "tpl:min-h-[1em] tpl:w-full",
|
|
1342
|
-
style:
|
|
1346
|
+
style: P(l.value),
|
|
1343
1347
|
onDblclick: u[0] ||= (...e) => z(s) && z(s)(...e)
|
|
1344
|
-
}, [z(r) ? (
|
|
1348
|
+
}, [z(r) ? (F(), ae(z(n), {
|
|
1345
1349
|
key: 0,
|
|
1346
1350
|
block: e.block,
|
|
1347
1351
|
"toolbar-position": z(a),
|
|
@@ -1350,19 +1354,19 @@ var Pn = ["data-block-id", "data-block-type"], Fn = ["aria-label"], In = ["aria-
|
|
|
1350
1354
|
"block",
|
|
1351
1355
|
"toolbar-position",
|
|
1352
1356
|
"onDone"
|
|
1353
|
-
])) : (
|
|
1357
|
+
])) : (F(), j("div", {
|
|
1354
1358
|
key: 1,
|
|
1355
1359
|
class: "tpl-text-content tpl:outline-none [&_a]:tpl:underline [&_p]:tpl:m-0 [&_p]:tpl:mb-2 [&_p:last-child]:tpl:mb-0",
|
|
1356
1360
|
innerHTML: z(o)
|
|
1357
|
-
}, null, 8,
|
|
1361
|
+
}, null, 8, Jn))], 36));
|
|
1358
1362
|
}
|
|
1359
|
-
}),
|
|
1360
|
-
MultiDrag: () =>
|
|
1363
|
+
}), Xn = /* @__PURE__ */ ot({
|
|
1364
|
+
MultiDrag: () => ti,
|
|
1361
1365
|
Sortable: () => K,
|
|
1362
|
-
Swap: () =>
|
|
1366
|
+
Swap: () => $r,
|
|
1363
1367
|
default: () => K
|
|
1364
1368
|
});
|
|
1365
|
-
function
|
|
1369
|
+
function Zn(e, t) {
|
|
1366
1370
|
var n = Object.keys(e);
|
|
1367
1371
|
if (Object.getOwnPropertySymbols) {
|
|
1368
1372
|
var r = Object.getOwnPropertySymbols(e);
|
|
@@ -1372,26 +1376,26 @@ function Xn(e, t) {
|
|
|
1372
1376
|
}
|
|
1373
1377
|
return n;
|
|
1374
1378
|
}
|
|
1375
|
-
function
|
|
1379
|
+
function Qn(e) {
|
|
1376
1380
|
for (var t = 1; t < arguments.length; t++) {
|
|
1377
1381
|
var n = arguments[t] == null ? {} : arguments[t];
|
|
1378
|
-
t % 2 ?
|
|
1379
|
-
|
|
1380
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) :
|
|
1382
|
+
t % 2 ? Zn(Object(n), !0).forEach(function(t) {
|
|
1383
|
+
er(e, t, n[t]);
|
|
1384
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : Zn(Object(n)).forEach(function(t) {
|
|
1381
1385
|
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
|
|
1382
1386
|
});
|
|
1383
1387
|
}
|
|
1384
1388
|
return e;
|
|
1385
1389
|
}
|
|
1386
|
-
function
|
|
1390
|
+
function $n(e) {
|
|
1387
1391
|
"@babel/helpers - typeof";
|
|
1388
|
-
return
|
|
1392
|
+
return $n = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
|
|
1389
1393
|
return typeof e;
|
|
1390
1394
|
} : function(e) {
|
|
1391
1395
|
return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
|
|
1392
|
-
},
|
|
1396
|
+
}, $n(e);
|
|
1393
1397
|
}
|
|
1394
|
-
function
|
|
1398
|
+
function er(e, t, n) {
|
|
1395
1399
|
return t in e ? Object.defineProperty(e, t, {
|
|
1396
1400
|
value: n,
|
|
1397
1401
|
enumerable: !0,
|
|
@@ -1399,65 +1403,65 @@ function $n(e, t, n) {
|
|
|
1399
1403
|
writable: !0
|
|
1400
1404
|
}) : e[t] = n, e;
|
|
1401
1405
|
}
|
|
1402
|
-
function
|
|
1403
|
-
return
|
|
1406
|
+
function tr() {
|
|
1407
|
+
return tr = Object.assign || function(e) {
|
|
1404
1408
|
for (var t = 1; t < arguments.length; t++) {
|
|
1405
1409
|
var n = arguments[t];
|
|
1406
1410
|
for (var r in n) Object.prototype.hasOwnProperty.call(n, r) && (e[r] = n[r]);
|
|
1407
1411
|
}
|
|
1408
1412
|
return e;
|
|
1409
|
-
},
|
|
1413
|
+
}, tr.apply(this, arguments);
|
|
1410
1414
|
}
|
|
1411
|
-
function
|
|
1415
|
+
function nr(e, t) {
|
|
1412
1416
|
if (e == null) return {};
|
|
1413
1417
|
var n = {}, r = Object.keys(e), i, a;
|
|
1414
1418
|
for (a = 0; a < r.length; a++) i = r[a], !(t.indexOf(i) >= 0) && (n[i] = e[i]);
|
|
1415
1419
|
return n;
|
|
1416
1420
|
}
|
|
1417
|
-
function
|
|
1421
|
+
function rr(e, t) {
|
|
1418
1422
|
if (e == null) return {};
|
|
1419
|
-
var n =
|
|
1423
|
+
var n = nr(e, t), r, i;
|
|
1420
1424
|
if (Object.getOwnPropertySymbols) {
|
|
1421
1425
|
var a = Object.getOwnPropertySymbols(e);
|
|
1422
1426
|
for (i = 0; i < a.length; i++) r = a[i], !(t.indexOf(r) >= 0) && Object.prototype.propertyIsEnumerable.call(e, r) && (n[r] = e[r]);
|
|
1423
1427
|
}
|
|
1424
1428
|
return n;
|
|
1425
1429
|
}
|
|
1426
|
-
function rr(e) {
|
|
1427
|
-
return ir(e) || ar(e) || or(e) || cr();
|
|
1428
|
-
}
|
|
1429
1430
|
function ir(e) {
|
|
1430
|
-
|
|
1431
|
+
return ar(e) || or(e) || sr(e) || lr();
|
|
1431
1432
|
}
|
|
1432
1433
|
function ar(e) {
|
|
1434
|
+
if (Array.isArray(e)) return cr(e);
|
|
1435
|
+
}
|
|
1436
|
+
function or(e) {
|
|
1433
1437
|
if (typeof Symbol < "u" && e[Symbol.iterator] != null || e["@@iterator"] != null) return Array.from(e);
|
|
1434
1438
|
}
|
|
1435
|
-
function
|
|
1439
|
+
function sr(e, t) {
|
|
1436
1440
|
if (e) {
|
|
1437
|
-
if (typeof e == "string") return
|
|
1441
|
+
if (typeof e == "string") return cr(e, t);
|
|
1438
1442
|
var n = Object.prototype.toString.call(e).slice(8, -1);
|
|
1439
1443
|
if (n === "Object" && e.constructor && (n = e.constructor.name), n === "Map" || n === "Set") return Array.from(e);
|
|
1440
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return
|
|
1444
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return cr(e, t);
|
|
1441
1445
|
}
|
|
1442
1446
|
}
|
|
1443
|
-
function
|
|
1447
|
+
function cr(e, t) {
|
|
1444
1448
|
(t == null || t > e.length) && (t = e.length);
|
|
1445
1449
|
for (var n = 0, r = Array(t); n < t; n++) r[n] = e[n];
|
|
1446
1450
|
return r;
|
|
1447
1451
|
}
|
|
1448
|
-
function
|
|
1452
|
+
function lr() {
|
|
1449
1453
|
throw TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
1450
1454
|
}
|
|
1451
|
-
function
|
|
1455
|
+
function ur(e) {
|
|
1452
1456
|
if (typeof window < "u" && window.navigator) return !!/* @__PURE__ */ navigator.userAgent.match(e);
|
|
1453
1457
|
}
|
|
1454
1458
|
function B(e, t, n) {
|
|
1455
|
-
e.addEventListener(t, n, !
|
|
1459
|
+
e.addEventListener(t, n, !oi && fi);
|
|
1456
1460
|
}
|
|
1457
1461
|
function V(e, t, n) {
|
|
1458
|
-
e.removeEventListener(t, n, !
|
|
1462
|
+
e.removeEventListener(t, n, !oi && fi);
|
|
1459
1463
|
}
|
|
1460
|
-
function
|
|
1464
|
+
function dr(e, t) {
|
|
1461
1465
|
if (t) {
|
|
1462
1466
|
if (t[0] === ">" && (t = t.substring(1)), e) try {
|
|
1463
1467
|
if (e.matches) return e.matches(t);
|
|
@@ -1469,21 +1473,21 @@ function ur(e, t) {
|
|
|
1469
1473
|
return !1;
|
|
1470
1474
|
}
|
|
1471
1475
|
}
|
|
1472
|
-
function
|
|
1476
|
+
function fr(e) {
|
|
1473
1477
|
return e.host && e !== document && e.host.nodeType ? e.host : e.parentNode;
|
|
1474
1478
|
}
|
|
1475
|
-
function
|
|
1479
|
+
function pr(e, t, n, r) {
|
|
1476
1480
|
if (e) {
|
|
1477
1481
|
n ||= document;
|
|
1478
1482
|
do {
|
|
1479
|
-
if (t != null && (t[0] === ">" ? e.parentNode === n &&
|
|
1483
|
+
if (t != null && (t[0] === ">" ? e.parentNode === n && dr(e, t) : dr(e, t)) || r && e === n) return e;
|
|
1480
1484
|
if (e === n) break;
|
|
1481
|
-
} while (e =
|
|
1485
|
+
} while (e = fr(e));
|
|
1482
1486
|
}
|
|
1483
1487
|
return null;
|
|
1484
1488
|
}
|
|
1485
1489
|
function H(e, t, n) {
|
|
1486
|
-
e && t && (e.classList ? e.classList[n ? "add" : "remove"](t) : e.className = ((" " + e.className + " ").replace(
|
|
1490
|
+
e && t && (e.classList ? e.classList[n ? "add" : "remove"](t) : e.className = ((" " + e.className + " ").replace(pi, " ").replace(" " + t + " ", " ") + (n ? " " + t : "")).replace(pi, " "));
|
|
1487
1491
|
}
|
|
1488
1492
|
function U(e, t, n) {
|
|
1489
1493
|
var r = e && e.style;
|
|
@@ -1492,7 +1496,7 @@ function U(e, t, n) {
|
|
|
1492
1496
|
!(t in r) && t.indexOf("webkit") === -1 && (t = "-webkit-" + t), r[t] = n + (typeof n == "string" ? "" : "px");
|
|
1493
1497
|
}
|
|
1494
1498
|
}
|
|
1495
|
-
function
|
|
1499
|
+
function mr(e, t) {
|
|
1496
1500
|
var n = "";
|
|
1497
1501
|
if (typeof e == "string") n = e;
|
|
1498
1502
|
else do {
|
|
@@ -1502,7 +1506,7 @@ function pr(e, t) {
|
|
|
1502
1506
|
var i = window.DOMMatrix || window.WebKitCSSMatrix || window.CSSMatrix || window.MSCSSMatrix;
|
|
1503
1507
|
return i && new i(n);
|
|
1504
1508
|
}
|
|
1505
|
-
function
|
|
1509
|
+
function hr(e, t, n) {
|
|
1506
1510
|
if (e) {
|
|
1507
1511
|
var r = e.getElementsByTagName(t), i = 0, a = r.length;
|
|
1508
1512
|
if (n) for (; i < a; i++) n(r[i], i);
|
|
@@ -1510,13 +1514,13 @@ function mr(e, t, n) {
|
|
|
1510
1514
|
}
|
|
1511
1515
|
return [];
|
|
1512
1516
|
}
|
|
1513
|
-
function
|
|
1517
|
+
function gr() {
|
|
1514
1518
|
return document.scrollingElement || document.documentElement;
|
|
1515
1519
|
}
|
|
1516
1520
|
function W(e, t, n, r, i) {
|
|
1517
1521
|
if (!(!e.getBoundingClientRect && e !== window)) {
|
|
1518
1522
|
var a, o, s, c, l, u, d;
|
|
1519
|
-
if (e !== window && e.parentNode && e !==
|
|
1523
|
+
if (e !== window && e.parentNode && e !== gr() ? (a = e.getBoundingClientRect(), o = a.top, s = a.left, c = a.bottom, l = a.right, u = a.height, d = a.width) : (o = 0, s = 0, c = window.innerHeight, l = window.innerWidth, u = window.innerHeight, d = window.innerWidth), (t || n) && e !== window && (i ||= e.parentNode, !oi)) do
|
|
1520
1524
|
if (i && i.getBoundingClientRect && (U(i, "transform") !== "none" || n && U(i, "position") !== "static")) {
|
|
1521
1525
|
var f = i.getBoundingClientRect();
|
|
1522
1526
|
o -= f.top + parseInt(U(i, "border-top-width")), s -= f.left + parseInt(U(i, "border-left-width")), c = o + a.height, l = s + a.width;
|
|
@@ -1524,7 +1528,7 @@ function W(e, t, n, r, i) {
|
|
|
1524
1528
|
}
|
|
1525
1529
|
while (i = i.parentNode);
|
|
1526
1530
|
if (r && e !== window) {
|
|
1527
|
-
var p =
|
|
1531
|
+
var p = mr(i || e), m = p && p.a, h = p && p.d;
|
|
1528
1532
|
p && (o /= h, s /= m, d /= m, u /= h, c = o + u, l = s + d);
|
|
1529
1533
|
}
|
|
1530
1534
|
return {
|
|
@@ -1537,18 +1541,18 @@ function W(e, t, n, r, i) {
|
|
|
1537
1541
|
};
|
|
1538
1542
|
}
|
|
1539
1543
|
}
|
|
1540
|
-
function
|
|
1541
|
-
for (var r =
|
|
1544
|
+
function _r(e, t, n) {
|
|
1545
|
+
for (var r = Sr(e, !0), i = W(e)[t]; r;) {
|
|
1542
1546
|
var a = W(r)[n], o = void 0;
|
|
1543
1547
|
if (o = n === "top" || n === "left" ? i >= a : i <= a, !o) return r;
|
|
1544
|
-
if (r ===
|
|
1545
|
-
r =
|
|
1548
|
+
if (r === gr()) break;
|
|
1549
|
+
r = Sr(r, !1);
|
|
1546
1550
|
}
|
|
1547
1551
|
return !1;
|
|
1548
1552
|
}
|
|
1549
|
-
function
|
|
1553
|
+
function vr(e, t, n, r) {
|
|
1550
1554
|
for (var i = 0, a = 0, o = e.children; a < o.length;) {
|
|
1551
|
-
if (o[a].style.display !== "none" && o[a] !== K.ghost && (r || o[a] !== K.dragged) &&
|
|
1555
|
+
if (o[a].style.display !== "none" && o[a] !== K.ghost && (r || o[a] !== K.dragged) && pr(o[a], n.draggable, e, !1)) {
|
|
1552
1556
|
if (i === t) return o[a];
|
|
1553
1557
|
i++;
|
|
1554
1558
|
}
|
|
@@ -1556,79 +1560,79 @@ function _r(e, t, n, r) {
|
|
|
1556
1560
|
}
|
|
1557
1561
|
return null;
|
|
1558
1562
|
}
|
|
1559
|
-
function
|
|
1560
|
-
for (var n = e.lastElementChild; n && (n === K.ghost || U(n, "display") === "none" || t && !
|
|
1563
|
+
function yr(e, t) {
|
|
1564
|
+
for (var n = e.lastElementChild; n && (n === K.ghost || U(n, "display") === "none" || t && !dr(n, t));) n = n.previousElementSibling;
|
|
1561
1565
|
return n || null;
|
|
1562
1566
|
}
|
|
1563
1567
|
function G(e, t) {
|
|
1564
1568
|
var n = 0;
|
|
1565
1569
|
if (!e || !e.parentNode) return -1;
|
|
1566
|
-
for (; e = e.previousElementSibling;) e.nodeName.toUpperCase() !== "TEMPLATE" && e !== K.clone && (!t ||
|
|
1570
|
+
for (; e = e.previousElementSibling;) e.nodeName.toUpperCase() !== "TEMPLATE" && e !== K.clone && (!t || dr(e, t)) && n++;
|
|
1567
1571
|
return n;
|
|
1568
1572
|
}
|
|
1569
|
-
function
|
|
1570
|
-
var t = 0, n = 0, r =
|
|
1573
|
+
function br(e) {
|
|
1574
|
+
var t = 0, n = 0, r = gr();
|
|
1571
1575
|
if (e) do {
|
|
1572
|
-
var i =
|
|
1576
|
+
var i = mr(e), a = i.a, o = i.d;
|
|
1573
1577
|
t += e.scrollLeft * a, n += e.scrollTop * o;
|
|
1574
1578
|
} while (e !== r && (e = e.parentNode));
|
|
1575
1579
|
return [t, n];
|
|
1576
1580
|
}
|
|
1577
|
-
function
|
|
1581
|
+
function xr(e, t) {
|
|
1578
1582
|
for (var n in e) if (e.hasOwnProperty(n)) {
|
|
1579
1583
|
for (var r in t) if (t.hasOwnProperty(r) && t[r] === e[n][r]) return Number(n);
|
|
1580
1584
|
}
|
|
1581
1585
|
return -1;
|
|
1582
1586
|
}
|
|
1583
|
-
function
|
|
1584
|
-
if (!e || !e.getBoundingClientRect) return
|
|
1587
|
+
function Sr(e, t) {
|
|
1588
|
+
if (!e || !e.getBoundingClientRect) return gr();
|
|
1585
1589
|
var n = e, r = !1;
|
|
1586
1590
|
do
|
|
1587
1591
|
if (n.clientWidth < n.scrollWidth || n.clientHeight < n.scrollHeight) {
|
|
1588
1592
|
var i = U(n);
|
|
1589
1593
|
if (n.clientWidth < n.scrollWidth && (i.overflowX == "auto" || i.overflowX == "scroll") || n.clientHeight < n.scrollHeight && (i.overflowY == "auto" || i.overflowY == "scroll")) {
|
|
1590
|
-
if (!n.getBoundingClientRect || n === document.body) return
|
|
1594
|
+
if (!n.getBoundingClientRect || n === document.body) return gr();
|
|
1591
1595
|
if (r || t) return n;
|
|
1592
1596
|
r = !0;
|
|
1593
1597
|
}
|
|
1594
1598
|
}
|
|
1595
1599
|
while (n = n.parentNode);
|
|
1596
|
-
return
|
|
1600
|
+
return gr();
|
|
1597
1601
|
}
|
|
1598
|
-
function
|
|
1602
|
+
function Cr(e, t) {
|
|
1599
1603
|
if (e && t) for (var n in t) t.hasOwnProperty(n) && (e[n] = t[n]);
|
|
1600
1604
|
return e;
|
|
1601
1605
|
}
|
|
1602
|
-
function
|
|
1606
|
+
function wr(e, t) {
|
|
1603
1607
|
return Math.round(e.top) === Math.round(t.top) && Math.round(e.left) === Math.round(t.left) && Math.round(e.height) === Math.round(t.height) && Math.round(e.width) === Math.round(t.width);
|
|
1604
1608
|
}
|
|
1605
|
-
function
|
|
1609
|
+
function Tr(e, t) {
|
|
1606
1610
|
return function() {
|
|
1607
|
-
if (!
|
|
1611
|
+
if (!mi) {
|
|
1608
1612
|
var n = arguments, r = this;
|
|
1609
|
-
n.length === 1 ? e.call(r, n[0]) : e.apply(r, n),
|
|
1610
|
-
|
|
1613
|
+
n.length === 1 ? e.call(r, n[0]) : e.apply(r, n), mi = setTimeout(function() {
|
|
1614
|
+
mi = void 0;
|
|
1611
1615
|
}, t);
|
|
1612
1616
|
}
|
|
1613
1617
|
};
|
|
1614
1618
|
}
|
|
1615
|
-
function
|
|
1616
|
-
clearTimeout(
|
|
1619
|
+
function Er() {
|
|
1620
|
+
clearTimeout(mi), mi = void 0;
|
|
1617
1621
|
}
|
|
1618
|
-
function
|
|
1622
|
+
function Dr(e, t, n) {
|
|
1619
1623
|
e.scrollLeft += t, e.scrollTop += n;
|
|
1620
1624
|
}
|
|
1621
|
-
function
|
|
1625
|
+
function Or(e) {
|
|
1622
1626
|
var t = window.Polymer, n = window.jQuery || window.Zepto;
|
|
1623
1627
|
return t && t.dom ? t.dom(e).cloneNode(!0) : n ? n(e).clone(!0)[0] : e.cloneNode(!0);
|
|
1624
1628
|
}
|
|
1625
|
-
function
|
|
1629
|
+
function kr(e, t) {
|
|
1626
1630
|
U(e, "position", "absolute"), U(e, "top", t.top), U(e, "left", t.left), U(e, "width", t.width), U(e, "height", t.height);
|
|
1627
1631
|
}
|
|
1628
|
-
function
|
|
1632
|
+
function Ar(e) {
|
|
1629
1633
|
U(e, "position", ""), U(e, "top", ""), U(e, "left", ""), U(e, "width", ""), U(e, "height", "");
|
|
1630
1634
|
}
|
|
1631
|
-
function
|
|
1635
|
+
function jr() {
|
|
1632
1636
|
var e = [], t;
|
|
1633
1637
|
return {
|
|
1634
1638
|
captureAnimationState: function() {
|
|
@@ -1638,9 +1642,9 @@ function Ar() {
|
|
|
1638
1642
|
target: t,
|
|
1639
1643
|
rect: W(t)
|
|
1640
1644
|
});
|
|
1641
|
-
var n =
|
|
1645
|
+
var n = Qn({}, e[e.length - 1].rect);
|
|
1642
1646
|
if (t.thisAnimationDuration) {
|
|
1643
|
-
var r =
|
|
1647
|
+
var r = mr(t, !0);
|
|
1644
1648
|
r && (n.top -= r.f, n.left -= r.e);
|
|
1645
1649
|
}
|
|
1646
1650
|
t.fromRect = n;
|
|
@@ -1651,7 +1655,7 @@ function Ar() {
|
|
|
1651
1655
|
e.push(t);
|
|
1652
1656
|
},
|
|
1653
1657
|
removeAnimationState: function(t) {
|
|
1654
|
-
e.splice(
|
|
1658
|
+
e.splice(xr(e, { target: t }), 1);
|
|
1655
1659
|
},
|
|
1656
1660
|
animateAll: function(n) {
|
|
1657
1661
|
var r = this;
|
|
@@ -1661,8 +1665,8 @@ function Ar() {
|
|
|
1661
1665
|
}
|
|
1662
1666
|
var i = !1, a = 0;
|
|
1663
1667
|
e.forEach(function(e) {
|
|
1664
|
-
var t = 0, n = e.target, o = n.fromRect, s = W(n), c = n.prevFromRect, l = n.prevToRect, u = e.rect, d =
|
|
1665
|
-
d && (s.top -= d.f, s.left -= d.e), n.toRect = s, n.thisAnimationDuration &&
|
|
1668
|
+
var t = 0, n = e.target, o = n.fromRect, s = W(n), c = n.prevFromRect, l = n.prevToRect, u = e.rect, d = mr(n, !0);
|
|
1669
|
+
d && (s.top -= d.f, s.left -= d.e), n.toRect = s, n.thisAnimationDuration && wr(c, s) && !wr(o, s) && (u.top - s.top) / (u.left - s.left) === (o.top - s.top) / (o.left - s.left) && (t = Nr(u, c, l, r.options)), wr(s, o) || (n.prevFromRect = o, n.prevToRect = s, t ||= r.options.animation, r.animate(n, u, s, t)), t && (i = !0, a = Math.max(a, t), clearTimeout(n.animationResetTimer), n.animationResetTimer = setTimeout(function() {
|
|
1666
1670
|
n.animationTime = 0, n.prevFromRect = null, n.fromRect = null, n.prevToRect = null, n.thisAnimationDuration = null;
|
|
1667
1671
|
}, t), n.thisAnimationDuration = t);
|
|
1668
1672
|
}), clearTimeout(t), i ? t = setTimeout(function() {
|
|
@@ -1672,48 +1676,48 @@ function Ar() {
|
|
|
1672
1676
|
animate: function(e, t, n, r) {
|
|
1673
1677
|
if (r) {
|
|
1674
1678
|
U(e, "transition", ""), U(e, "transform", "");
|
|
1675
|
-
var i =
|
|
1676
|
-
e.animatingX = !!s, e.animatingY = !!c, U(e, "transform", "translate3d(" + s + "px," + c + "px,0)"), this.forRepaintDummy =
|
|
1679
|
+
var i = mr(this.el), a = i && i.a, o = i && i.d, s = (t.left - n.left) / (a || 1), c = (t.top - n.top) / (o || 1);
|
|
1680
|
+
e.animatingX = !!s, e.animatingY = !!c, U(e, "transform", "translate3d(" + s + "px," + c + "px,0)"), this.forRepaintDummy = Mr(e), U(e, "transition", "transform " + r + "ms" + (this.options.easing ? " " + this.options.easing : "")), U(e, "transform", "translate3d(0,0,0)"), typeof e.animated == "number" && clearTimeout(e.animated), e.animated = setTimeout(function() {
|
|
1677
1681
|
U(e, "transition", ""), U(e, "transform", ""), e.animated = !1, e.animatingX = !1, e.animatingY = !1;
|
|
1678
1682
|
}, r);
|
|
1679
1683
|
}
|
|
1680
1684
|
}
|
|
1681
1685
|
};
|
|
1682
1686
|
}
|
|
1683
|
-
function
|
|
1687
|
+
function Mr(e) {
|
|
1684
1688
|
return e.offsetWidth;
|
|
1685
1689
|
}
|
|
1686
|
-
function
|
|
1690
|
+
function Nr(e, t, n, r) {
|
|
1687
1691
|
return Math.sqrt((t.top - e.top) ** 2 + (t.left - e.left) ** 2) / Math.sqrt((t.top - n.top) ** 2 + (t.left - n.left) ** 2) * r.animation;
|
|
1688
1692
|
}
|
|
1689
|
-
function
|
|
1693
|
+
function Pr(e) {
|
|
1690
1694
|
var t = e.sortable, n = e.rootEl, r = e.name, i = e.targetEl, a = e.cloneEl, o = e.toEl, s = e.fromEl, c = e.oldIndex, l = e.newIndex, u = e.oldDraggableIndex, d = e.newDraggableIndex, f = e.originalEvent, p = e.putSortable, m = e.extraEventProperties;
|
|
1691
|
-
if (t ||= n && n[
|
|
1695
|
+
if (t ||= n && n[hi], t) {
|
|
1692
1696
|
var h, g = t.options, _ = "on" + r.charAt(0).toUpperCase() + r.substr(1);
|
|
1693
|
-
window.CustomEvent && !
|
|
1697
|
+
window.CustomEvent && !oi && !si ? h = new CustomEvent(r, {
|
|
1694
1698
|
bubbles: !0,
|
|
1695
1699
|
cancelable: !0
|
|
1696
1700
|
}) : (h = document.createEvent("Event"), h.initEvent(r, !0, !0)), h.to = o || n, h.from = s || n, h.item = i || n, h.clone = a, h.oldIndex = c, h.newIndex = l, h.oldDraggableIndex = u, h.newDraggableIndex = d, h.originalEvent = f, h.pullMode = p ? p.lastPutMode : void 0;
|
|
1697
|
-
var v =
|
|
1701
|
+
var v = Qn(Qn({}, m), vi.getEventProperties(r, t));
|
|
1698
1702
|
for (var y in v) h[y] = v[y];
|
|
1699
1703
|
n && n.dispatchEvent(h), g[_] && g[_].call(t, h);
|
|
1700
1704
|
}
|
|
1701
1705
|
}
|
|
1702
|
-
function
|
|
1703
|
-
|
|
1704
|
-
putSortable:
|
|
1706
|
+
function Fr(e) {
|
|
1707
|
+
Pr(Qn({
|
|
1708
|
+
putSortable: ki,
|
|
1705
1709
|
cloneEl: Z,
|
|
1706
1710
|
targetEl: q,
|
|
1707
1711
|
rootEl: X,
|
|
1708
|
-
oldIndex:
|
|
1709
|
-
oldDraggableIndex:
|
|
1710
|
-
newIndex:
|
|
1711
|
-
newDraggableIndex:
|
|
1712
|
+
oldIndex: wi,
|
|
1713
|
+
oldDraggableIndex: Ei,
|
|
1714
|
+
newIndex: Ti,
|
|
1715
|
+
newDraggableIndex: Di
|
|
1712
1716
|
}, e));
|
|
1713
1717
|
}
|
|
1714
1718
|
function K(e, t) {
|
|
1715
1719
|
if (!(e && e.nodeType && e.nodeType === 1)) throw `Sortable: \`el\` must be an HTMLElement, not ${{}.toString.call(e)}`;
|
|
1716
|
-
this.el = e, this.options = t =
|
|
1720
|
+
this.el = e, this.options = t = tr({}, t), e[hi] = this;
|
|
1717
1721
|
var n = {
|
|
1718
1722
|
group: null,
|
|
1719
1723
|
sort: !0,
|
|
@@ -1726,7 +1730,7 @@ function K(e, t) {
|
|
|
1726
1730
|
invertedSwapThreshold: null,
|
|
1727
1731
|
removeCloneOnHide: !0,
|
|
1728
1732
|
direction: function() {
|
|
1729
|
-
return
|
|
1733
|
+
return ea(e, this.options);
|
|
1730
1734
|
},
|
|
1731
1735
|
ghostClass: "sortable-ghost",
|
|
1732
1736
|
chosenClass: "sortable-chosen",
|
|
@@ -1753,68 +1757,68 @@ function K(e, t) {
|
|
|
1753
1757
|
x: 0,
|
|
1754
1758
|
y: 0
|
|
1755
1759
|
},
|
|
1756
|
-
supportPointer: K.supportPointer !== !1 && "PointerEvent" in window && !
|
|
1760
|
+
supportPointer: K.supportPointer !== !1 && "PointerEvent" in window && !li,
|
|
1757
1761
|
emptyInsertThreshold: 5
|
|
1758
1762
|
};
|
|
1759
|
-
for (var r in
|
|
1760
|
-
for (var i in
|
|
1761
|
-
this.nativeDraggable = t.forceFallback ? !1 :
|
|
1763
|
+
for (var r in vi.initializePlugins(this, e, n), n) !(r in t) && (t[r] = n[r]);
|
|
1764
|
+
for (var i in ra(t), this) i.charAt(0) === "_" && typeof this[i] == "function" && (this[i] = this[i].bind(this));
|
|
1765
|
+
this.nativeDraggable = t.forceFallback ? !1 : Qi, this.nativeDraggable && (this.options.touchStartThreshold = 1), t.supportPointer ? B(e, "pointerdown", this._onTapStart) : (B(e, "mousedown", this._onTapStart), B(e, "touchstart", this._onTapStart)), this.nativeDraggable && (B(e, "dragover", this), B(e, "dragenter", this)), Mi.push(this.el), t.store && t.store.get && this.sort(t.store.get(this) || []), tr(this, jr());
|
|
1762
1766
|
}
|
|
1763
|
-
function
|
|
1767
|
+
function Ir(e) {
|
|
1764
1768
|
e.dataTransfer && (e.dataTransfer.dropEffect = "move"), e.cancelable && e.preventDefault();
|
|
1765
1769
|
}
|
|
1766
|
-
function
|
|
1767
|
-
var c, l = e[
|
|
1768
|
-
return window.CustomEvent && !
|
|
1770
|
+
function Lr(e, t, n, r, i, a, o, s) {
|
|
1771
|
+
var c, l = e[hi], u = l.options.onMove, d;
|
|
1772
|
+
return window.CustomEvent && !oi && !si ? c = new CustomEvent("move", {
|
|
1769
1773
|
bubbles: !0,
|
|
1770
1774
|
cancelable: !0
|
|
1771
1775
|
}) : (c = document.createEvent("Event"), c.initEvent("move", !0, !0)), c.to = t, c.from = e, c.dragged = n, c.draggedRect = r, c.related = i || t, c.relatedRect = a || W(t), c.willInsertAfter = s, c.originalEvent = o, e.dispatchEvent(c), u && (d = u.call(l, c, o)), d;
|
|
1772
1776
|
}
|
|
1773
|
-
function
|
|
1777
|
+
function Rr(e) {
|
|
1774
1778
|
e.draggable = !1;
|
|
1775
1779
|
}
|
|
1776
|
-
function
|
|
1777
|
-
|
|
1780
|
+
function zr() {
|
|
1781
|
+
qi = !1;
|
|
1778
1782
|
}
|
|
1779
|
-
function
|
|
1780
|
-
var r = W(
|
|
1783
|
+
function Br(e, t, n) {
|
|
1784
|
+
var r = W(vr(n.el, 0, n.options, !0)), i = 10;
|
|
1781
1785
|
return t ? e.clientX < r.left - i || e.clientY < r.top && e.clientX < r.right : e.clientY < r.top - i || e.clientY < r.bottom && e.clientX < r.left;
|
|
1782
1786
|
}
|
|
1783
|
-
function
|
|
1784
|
-
var r = W(
|
|
1787
|
+
function Vr(e, t, n) {
|
|
1788
|
+
var r = W(yr(n.el, n.options.draggable)), i = 10;
|
|
1785
1789
|
return t ? e.clientX > r.right + i || e.clientX <= r.right && e.clientY > r.bottom && e.clientX >= r.left : e.clientX > r.right && e.clientY > r.top || e.clientX <= r.right && e.clientY > r.bottom + i;
|
|
1786
1790
|
}
|
|
1787
|
-
function
|
|
1791
|
+
function Hr(e, t, n, r, i, a, o, s) {
|
|
1788
1792
|
var c = r ? e.clientY : e.clientX, l = r ? n.height : n.width, u = r ? n.top : n.left, d = r ? n.bottom : n.right, f = !1;
|
|
1789
1793
|
if (!o) {
|
|
1790
|
-
if (s &&
|
|
1791
|
-
if (!
|
|
1792
|
-
else if (
|
|
1793
|
-
} else if (c > u + l * (1 - i) / 2 && c < d - l * (1 - i) / 2) return
|
|
1794
|
+
if (s && Wi < l * i) {
|
|
1795
|
+
if (!Hi && (Vi === 1 ? c > u + l * a / 2 : c < d - l * a / 2) && (Hi = !0), Hi) f = !0;
|
|
1796
|
+
else if (Vi === 1 ? c < u + Wi : c > d - Wi) return -Vi;
|
|
1797
|
+
} else if (c > u + l * (1 - i) / 2 && c < d - l * (1 - i) / 2) return Ur(t);
|
|
1794
1798
|
}
|
|
1795
1799
|
return f ||= o, f && (c < u + l * a / 2 || c > d - l * a / 2) ? c > u + l / 2 ? 1 : -1 : 0;
|
|
1796
1800
|
}
|
|
1797
|
-
function
|
|
1801
|
+
function Ur(e) {
|
|
1798
1802
|
return G(q) < G(e) ? 1 : -1;
|
|
1799
1803
|
}
|
|
1800
|
-
function
|
|
1804
|
+
function Wr(e) {
|
|
1801
1805
|
for (var t = e.tagName + e.className + e.src + e.href + e.textContent, n = t.length, r = 0; n--;) r += t.charCodeAt(n);
|
|
1802
1806
|
return r.toString(36);
|
|
1803
1807
|
}
|
|
1804
|
-
function
|
|
1805
|
-
|
|
1808
|
+
function Gr(e) {
|
|
1809
|
+
Ji.length = 0;
|
|
1806
1810
|
for (var t = e.getElementsByTagName("input"), n = t.length; n--;) {
|
|
1807
1811
|
var r = t[n];
|
|
1808
|
-
r.checked &&
|
|
1812
|
+
r.checked && Ji.push(r);
|
|
1809
1813
|
}
|
|
1810
1814
|
}
|
|
1811
|
-
function
|
|
1815
|
+
function Kr(e) {
|
|
1812
1816
|
return setTimeout(e, 0);
|
|
1813
1817
|
}
|
|
1814
|
-
function
|
|
1818
|
+
function qr(e) {
|
|
1815
1819
|
return clearTimeout(e);
|
|
1816
1820
|
}
|
|
1817
|
-
function
|
|
1821
|
+
function Jr() {
|
|
1818
1822
|
function e() {
|
|
1819
1823
|
for (var e in this.defaults = {
|
|
1820
1824
|
scroll: !0,
|
|
@@ -1834,84 +1838,84 @@ function qr() {
|
|
|
1834
1838
|
!this.options.dragOverBubble && !t.rootEl && this._handleAutoScroll(t);
|
|
1835
1839
|
},
|
|
1836
1840
|
drop: function() {
|
|
1837
|
-
this.sortable.nativeDraggable ? V(document, "dragover", this._handleAutoScroll) : (V(document, "pointermove", this._handleFallbackAutoScroll), V(document, "touchmove", this._handleFallbackAutoScroll), V(document, "mousemove", this._handleFallbackAutoScroll)),
|
|
1841
|
+
this.sortable.nativeDraggable ? V(document, "dragover", this._handleAutoScroll) : (V(document, "pointermove", this._handleFallbackAutoScroll), V(document, "touchmove", this._handleFallbackAutoScroll), V(document, "mousemove", this._handleFallbackAutoScroll)), Xr(), Yr(), Er();
|
|
1838
1842
|
},
|
|
1839
1843
|
nulling: function() {
|
|
1840
|
-
|
|
1844
|
+
ma = ua = la = da = ha = fa = pa = null, ca.length = 0;
|
|
1841
1845
|
},
|
|
1842
1846
|
_handleFallbackAutoScroll: function(e) {
|
|
1843
1847
|
this._handleAutoScroll(e, !0);
|
|
1844
1848
|
},
|
|
1845
1849
|
_handleAutoScroll: function(e, t) {
|
|
1846
1850
|
var n = this, r = (e.touches ? e.touches[0] : e).clientX, i = (e.touches ? e.touches[0] : e).clientY, a = document.elementFromPoint(r, i);
|
|
1847
|
-
if (
|
|
1848
|
-
|
|
1849
|
-
var o =
|
|
1850
|
-
|
|
1851
|
-
var a =
|
|
1852
|
-
a !== o && (o = a,
|
|
1853
|
-
}, 10),
|
|
1851
|
+
if (ma = e, t || this.options.forceAutoScrollFallback || si || oi || li) {
|
|
1852
|
+
ga(e, this.options, a, t);
|
|
1853
|
+
var o = Sr(a, !0);
|
|
1854
|
+
da && (!ha || r !== fa || i !== pa) && (ha && Xr(), ha = setInterval(function() {
|
|
1855
|
+
var a = Sr(document.elementFromPoint(r, i), !0);
|
|
1856
|
+
a !== o && (o = a, Yr()), ga(e, n.options, a, t);
|
|
1857
|
+
}, 10), fa = r, pa = i);
|
|
1854
1858
|
} else {
|
|
1855
|
-
if (!this.options.bubbleScroll ||
|
|
1856
|
-
|
|
1859
|
+
if (!this.options.bubbleScroll || Sr(a, !0) === gr()) {
|
|
1860
|
+
Yr();
|
|
1857
1861
|
return;
|
|
1858
1862
|
}
|
|
1859
|
-
|
|
1863
|
+
ga(e, this.options, Sr(a, !1), !1);
|
|
1860
1864
|
}
|
|
1861
1865
|
}
|
|
1862
|
-
},
|
|
1866
|
+
}, tr(e, {
|
|
1863
1867
|
pluginName: "scroll",
|
|
1864
1868
|
initializeByDefault: !0
|
|
1865
1869
|
});
|
|
1866
1870
|
}
|
|
1867
|
-
function
|
|
1868
|
-
|
|
1871
|
+
function Yr() {
|
|
1872
|
+
ca.forEach(function(e) {
|
|
1869
1873
|
clearInterval(e.pid);
|
|
1870
|
-
}),
|
|
1874
|
+
}), ca = [];
|
|
1871
1875
|
}
|
|
1872
|
-
function
|
|
1873
|
-
clearInterval(
|
|
1876
|
+
function Xr() {
|
|
1877
|
+
clearInterval(ha);
|
|
1874
1878
|
}
|
|
1875
|
-
function Xr() {}
|
|
1876
1879
|
function Zr() {}
|
|
1877
|
-
function Qr() {
|
|
1880
|
+
function Qr() {}
|
|
1881
|
+
function $r() {
|
|
1878
1882
|
function e() {
|
|
1879
1883
|
this.defaults = { swapClass: "sortable-swap-highlight" };
|
|
1880
1884
|
}
|
|
1881
1885
|
return e.prototype = {
|
|
1882
1886
|
dragStart: function(e) {
|
|
1883
|
-
|
|
1887
|
+
va = e.dragEl;
|
|
1884
1888
|
},
|
|
1885
1889
|
dragOverValid: function(e) {
|
|
1886
1890
|
var t = e.completed, n = e.target, r = e.onMove, i = e.activeSortable, a = e.changed, o = e.cancel;
|
|
1887
1891
|
if (i.options.swap) {
|
|
1888
1892
|
var s = this.sortable.el, c = this.options;
|
|
1889
1893
|
if (n && n !== s) {
|
|
1890
|
-
var l =
|
|
1891
|
-
r(n) === !1 ?
|
|
1894
|
+
var l = va;
|
|
1895
|
+
r(n) === !1 ? va = null : (H(n, c.swapClass, !0), va = n), l && l !== va && H(l, c.swapClass, !1);
|
|
1892
1896
|
}
|
|
1893
1897
|
a(), t(!0), o();
|
|
1894
1898
|
}
|
|
1895
1899
|
},
|
|
1896
1900
|
drop: function(e) {
|
|
1897
1901
|
var t = e.activeSortable, n = e.putSortable, r = e.dragEl, i = n || this.sortable, a = this.options;
|
|
1898
|
-
|
|
1902
|
+
va && H(va, a.swapClass, !1), va && (a.swap || n && n.options.swap) && r !== va && (i.captureAnimationState(), i !== t && t.captureAnimationState(), ei(r, va), i.animateAll(), i !== t && t.animateAll());
|
|
1899
1903
|
},
|
|
1900
1904
|
nulling: function() {
|
|
1901
|
-
|
|
1905
|
+
va = null;
|
|
1902
1906
|
}
|
|
1903
|
-
},
|
|
1907
|
+
}, tr(e, {
|
|
1904
1908
|
pluginName: "swap",
|
|
1905
1909
|
eventProperties: function() {
|
|
1906
|
-
return { swapItem:
|
|
1910
|
+
return { swapItem: va };
|
|
1907
1911
|
}
|
|
1908
1912
|
});
|
|
1909
1913
|
}
|
|
1910
|
-
function
|
|
1914
|
+
function ei(e, t) {
|
|
1911
1915
|
var n = e.parentNode, r = t.parentNode, i, a;
|
|
1912
1916
|
!n || !r || n.isEqualNode(t) || r.isEqualNode(e) || (i = G(e), a = G(t), n.isEqualNode(r) && i < a && a++, n.insertBefore(t, n.children[i]), r.insertBefore(e, r.children[a]));
|
|
1913
1917
|
}
|
|
1914
|
-
function
|
|
1918
|
+
function ti() {
|
|
1915
1919
|
function e(e) {
|
|
1916
1920
|
for (var t in this) t.charAt(0) === "_" && typeof this[t] == "function" && (this[t] = this[t].bind(this));
|
|
1917
1921
|
e.options.supportPointer ? B(document, "pointerup", this._deselectMultiDrag) : (B(document, "mouseup", this._deselectMultiDrag), B(document, "touchend", this._deselectMultiDrag)), B(document, "keydown", this._checkKeyDown), B(document, "keyup", this._checkKeyUp), this.defaults = {
|
|
@@ -1919,7 +1923,7 @@ function ei() {
|
|
|
1919
1923
|
multiDragKey: null,
|
|
1920
1924
|
setData: function(t, n) {
|
|
1921
1925
|
var r = "";
|
|
1922
|
-
Q.length &&
|
|
1926
|
+
Q.length && xa === e ? Q.forEach(function(e, t) {
|
|
1923
1927
|
r += (t ? ", " : "") + e.textContent;
|
|
1924
1928
|
}) : r = n.textContent, t.setData("Text", r);
|
|
1925
1929
|
}
|
|
@@ -1937,34 +1941,34 @@ function ei() {
|
|
|
1937
1941
|
setupClone: function(e) {
|
|
1938
1942
|
var t = e.sortable, n = e.cancel;
|
|
1939
1943
|
if (this.isMultiDrag) {
|
|
1940
|
-
for (var r = 0; r < Q.length; r++)
|
|
1944
|
+
for (var r = 0; r < Q.length; r++) ya.push(Or(Q[r])), ya[r].sortableIndex = Q[r].sortableIndex, ya[r].draggable = !1, ya[r].style["will-change"] = "", H(ya[r], this.options.selectedClass, !1), Q[r] === $ && H(ya[r], this.options.chosenClass, !1);
|
|
1941
1945
|
t._hideClone(), n();
|
|
1942
1946
|
}
|
|
1943
1947
|
},
|
|
1944
1948
|
clone: function(e) {
|
|
1945
1949
|
var t = e.sortable, n = e.rootEl, r = e.dispatchSortableEvent, i = e.cancel;
|
|
1946
|
-
this.isMultiDrag && (this.options.removeCloneOnHide || Q.length &&
|
|
1950
|
+
this.isMultiDrag && (this.options.removeCloneOnHide || Q.length && xa === t && (ri(!0, n), r("clone"), i()));
|
|
1947
1951
|
},
|
|
1948
1952
|
showClone: function(e) {
|
|
1949
1953
|
var t = e.cloneNowShown, n = e.rootEl, r = e.cancel;
|
|
1950
|
-
this.isMultiDrag && (
|
|
1954
|
+
this.isMultiDrag && (ri(!1, n), ya.forEach(function(e) {
|
|
1951
1955
|
U(e, "display", "");
|
|
1952
|
-
}), t(),
|
|
1956
|
+
}), t(), Ea = !1, r());
|
|
1953
1957
|
},
|
|
1954
1958
|
hideClone: function(e) {
|
|
1955
1959
|
var t = this;
|
|
1956
1960
|
e.sortable;
|
|
1957
1961
|
var n = e.cloneNowHidden, r = e.cancel;
|
|
1958
|
-
this.isMultiDrag && (
|
|
1962
|
+
this.isMultiDrag && (ya.forEach(function(e) {
|
|
1959
1963
|
U(e, "display", "none"), t.options.removeCloneOnHide && e.parentNode && e.parentNode.removeChild(e);
|
|
1960
|
-
}), n(),
|
|
1964
|
+
}), n(), Ea = !0, r());
|
|
1961
1965
|
},
|
|
1962
1966
|
dragStartGlobal: function(e) {
|
|
1963
|
-
e.sortable, !this.isMultiDrag &&
|
|
1967
|
+
e.sortable, !this.isMultiDrag && xa && xa.multiDrag._deselectMultiDrag(), Q.forEach(function(e) {
|
|
1964
1968
|
e.sortableIndex = G(e);
|
|
1965
1969
|
}), Q = Q.sort(function(e, t) {
|
|
1966
1970
|
return e.sortableIndex - t.sortableIndex;
|
|
1967
|
-
}),
|
|
1971
|
+
}), wa = !0;
|
|
1968
1972
|
},
|
|
1969
1973
|
dragStarted: function(e) {
|
|
1970
1974
|
var t = this, n = e.sortable;
|
|
@@ -1975,45 +1979,45 @@ function ei() {
|
|
|
1975
1979
|
});
|
|
1976
1980
|
var r = W($, !1, !0, !0);
|
|
1977
1981
|
Q.forEach(function(e) {
|
|
1978
|
-
e !== $ &&
|
|
1979
|
-
}),
|
|
1982
|
+
e !== $ && kr(e, r);
|
|
1983
|
+
}), Ca = !0, Sa = !0;
|
|
1980
1984
|
}
|
|
1981
1985
|
n.animateAll(function() {
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
}), t.options.sort &&
|
|
1986
|
+
Ca = !1, Sa = !1, t.options.animation && Q.forEach(function(e) {
|
|
1987
|
+
Ar(e);
|
|
1988
|
+
}), t.options.sort && ii();
|
|
1985
1989
|
});
|
|
1986
1990
|
}
|
|
1987
1991
|
},
|
|
1988
1992
|
dragOver: function(e) {
|
|
1989
1993
|
var t = e.target, n = e.completed, r = e.cancel;
|
|
1990
|
-
|
|
1994
|
+
Ca && ~Q.indexOf(t) && (n(!1), r());
|
|
1991
1995
|
},
|
|
1992
1996
|
revert: function(e) {
|
|
1993
1997
|
var t = e.fromSortable, n = e.rootEl, r = e.sortable, i = e.dragRect;
|
|
1994
1998
|
Q.length > 1 && (Q.forEach(function(e) {
|
|
1995
1999
|
r.addAnimationState({
|
|
1996
2000
|
target: e,
|
|
1997
|
-
rect:
|
|
1998
|
-
}),
|
|
1999
|
-
}),
|
|
2001
|
+
rect: Ca ? W(e) : i
|
|
2002
|
+
}), Ar(e), e.fromRect = i, t.removeAnimationState(e);
|
|
2003
|
+
}), Ca = !1, ni(!this.options.removeCloneOnHide, n));
|
|
2000
2004
|
},
|
|
2001
2005
|
dragOverCompleted: function(e) {
|
|
2002
2006
|
var t = e.sortable, n = e.isOwner, r = e.insertion, i = e.activeSortable, a = e.parentEl, o = e.putSortable, s = this.options;
|
|
2003
2007
|
if (r) {
|
|
2004
|
-
if (n && i._hideClone(),
|
|
2008
|
+
if (n && i._hideClone(), Sa = !1, s.animation && Q.length > 1 && (Ca || !n && !i.options.sort && !o)) {
|
|
2005
2009
|
var c = W($, !1, !0, !0);
|
|
2006
2010
|
Q.forEach(function(e) {
|
|
2007
|
-
e !== $ && (
|
|
2008
|
-
}),
|
|
2011
|
+
e !== $ && (kr(e, c), a.appendChild(e));
|
|
2012
|
+
}), Ca = !0;
|
|
2009
2013
|
}
|
|
2010
|
-
if (!n) if (
|
|
2011
|
-
var l =
|
|
2012
|
-
i._showClone(t), i.options.animation && !
|
|
2014
|
+
if (!n) if (Ca || ii(), Q.length > 1) {
|
|
2015
|
+
var l = Ea;
|
|
2016
|
+
i._showClone(t), i.options.animation && !Ea && l && ya.forEach(function(e) {
|
|
2013
2017
|
i.addAnimationState({
|
|
2014
2018
|
target: e,
|
|
2015
|
-
rect:
|
|
2016
|
-
}), e.fromRect =
|
|
2019
|
+
rect: Ta
|
|
2020
|
+
}), e.fromRect = Ta, e.thisAnimationDuration = null;
|
|
2017
2021
|
});
|
|
2018
2022
|
} else i._showClone(t);
|
|
2019
2023
|
}
|
|
@@ -2023,19 +2027,19 @@ function ei() {
|
|
|
2023
2027
|
if (Q.forEach(function(e) {
|
|
2024
2028
|
e.thisAnimationDuration = null;
|
|
2025
2029
|
}), r.options.animation && !n && r.multiDrag.isMultiDrag) {
|
|
2026
|
-
|
|
2027
|
-
var i =
|
|
2028
|
-
|
|
2030
|
+
Ta = tr({}, t);
|
|
2031
|
+
var i = mr($, !0);
|
|
2032
|
+
Ta.top -= i.f, Ta.left -= i.e;
|
|
2029
2033
|
}
|
|
2030
2034
|
},
|
|
2031
2035
|
dragOverAnimationComplete: function() {
|
|
2032
|
-
|
|
2036
|
+
Ca && (Ca = !1, ii());
|
|
2033
2037
|
},
|
|
2034
2038
|
drop: function(e) {
|
|
2035
2039
|
var t = e.originalEvent, n = e.rootEl, r = e.parentEl, i = e.sortable, a = e.dispatchSortableEvent, o = e.oldIndex, s = e.putSortable, c = s || this.sortable;
|
|
2036
2040
|
if (t) {
|
|
2037
2041
|
var l = this.options, u = r.children;
|
|
2038
|
-
if (!
|
|
2042
|
+
if (!wa) if (l.multiDragKey && !this.multiDragKeyDown && this._deselectMultiDrag(), H($, l.selectedClass, !~Q.indexOf($)), ~Q.indexOf($)) Q.splice(Q.indexOf($), 1), ba = null, Pr({
|
|
2039
2043
|
sortable: i,
|
|
2040
2044
|
rootEl: n,
|
|
2041
2045
|
name: "deselect",
|
|
@@ -2043,17 +2047,17 @@ function ei() {
|
|
|
2043
2047
|
originalEvt: t
|
|
2044
2048
|
});
|
|
2045
2049
|
else {
|
|
2046
|
-
if (Q.push($),
|
|
2050
|
+
if (Q.push($), Pr({
|
|
2047
2051
|
sortable: i,
|
|
2048
2052
|
rootEl: n,
|
|
2049
2053
|
name: "select",
|
|
2050
2054
|
targetEl: $,
|
|
2051
2055
|
originalEvt: t
|
|
2052
|
-
}), t.shiftKey &&
|
|
2053
|
-
var d = G(
|
|
2056
|
+
}), t.shiftKey && ba && i.el.contains(ba)) {
|
|
2057
|
+
var d = G(ba), f = G($);
|
|
2054
2058
|
if (~d && ~f && d !== f) {
|
|
2055
2059
|
var p, m;
|
|
2056
|
-
for (f > d ? (m = d, p = f) : (m = f, p = d + 1); m < p; m++) ~Q.indexOf(u[m]) || (H(u[m], l.selectedClass, !0), Q.push(u[m]),
|
|
2060
|
+
for (f > d ? (m = d, p = f) : (m = f, p = d + 1); m < p; m++) ~Q.indexOf(u[m]) || (H(u[m], l.selectedClass, !0), Q.push(u[m]), Pr({
|
|
2057
2061
|
sortable: i,
|
|
2058
2062
|
rootEl: n,
|
|
2059
2063
|
name: "select",
|
|
@@ -2061,21 +2065,21 @@ function ei() {
|
|
|
2061
2065
|
originalEvt: t
|
|
2062
2066
|
}));
|
|
2063
2067
|
}
|
|
2064
|
-
} else
|
|
2065
|
-
|
|
2068
|
+
} else ba = $;
|
|
2069
|
+
xa = c;
|
|
2066
2070
|
}
|
|
2067
|
-
if (
|
|
2068
|
-
if (
|
|
2071
|
+
if (wa && this.isMultiDrag) {
|
|
2072
|
+
if (Ca = !1, (r[hi].options.sort || r !== n) && Q.length > 1) {
|
|
2069
2073
|
var h = W($), g = G($, ":not(." + this.options.selectedClass + ")");
|
|
2070
|
-
if (!
|
|
2074
|
+
if (!Sa && l.animation && ($.thisAnimationDuration = null), c.captureAnimationState(), !Sa && (l.animation && ($.fromRect = h, Q.forEach(function(e) {
|
|
2071
2075
|
if (e.thisAnimationDuration = null, e !== $) {
|
|
2072
|
-
var t =
|
|
2076
|
+
var t = Ca ? W(e) : h;
|
|
2073
2077
|
e.fromRect = t, c.addAnimationState({
|
|
2074
2078
|
target: e,
|
|
2075
2079
|
rect: t
|
|
2076
2080
|
});
|
|
2077
2081
|
}
|
|
2078
|
-
})),
|
|
2082
|
+
})), ii(), Q.forEach(function(e) {
|
|
2079
2083
|
u[g] ? r.insertBefore(e, u[g]) : r.appendChild(e), g++;
|
|
2080
2084
|
}), o === G($))) {
|
|
2081
2085
|
var _ = !1;
|
|
@@ -2087,26 +2091,26 @@ function ei() {
|
|
|
2087
2091
|
}), _ && a("update");
|
|
2088
2092
|
}
|
|
2089
2093
|
Q.forEach(function(e) {
|
|
2090
|
-
|
|
2094
|
+
Ar(e);
|
|
2091
2095
|
}), c.animateAll();
|
|
2092
2096
|
}
|
|
2093
|
-
|
|
2097
|
+
xa = c;
|
|
2094
2098
|
}
|
|
2095
|
-
(n === r || s && s.lastPutMode !== "clone") &&
|
|
2099
|
+
(n === r || s && s.lastPutMode !== "clone") && ya.forEach(function(e) {
|
|
2096
2100
|
e.parentNode && e.parentNode.removeChild(e);
|
|
2097
2101
|
});
|
|
2098
2102
|
}
|
|
2099
2103
|
},
|
|
2100
2104
|
nullingGlobal: function() {
|
|
2101
|
-
this.isMultiDrag =
|
|
2105
|
+
this.isMultiDrag = wa = !1, ya.length = 0;
|
|
2102
2106
|
},
|
|
2103
2107
|
destroyGlobal: function() {
|
|
2104
2108
|
this._deselectMultiDrag(), V(document, "pointerup", this._deselectMultiDrag), V(document, "mouseup", this._deselectMultiDrag), V(document, "touchend", this._deselectMultiDrag), V(document, "keydown", this._checkKeyDown), V(document, "keyup", this._checkKeyUp);
|
|
2105
2109
|
},
|
|
2106
2110
|
_deselectMultiDrag: function(e) {
|
|
2107
|
-
if (!(
|
|
2111
|
+
if (!(wa !== void 0 && wa) && xa === this.sortable && !(e && pr(e.target, this.options.draggable, this.sortable.el, !1)) && !(e && e.button !== 0)) for (; Q.length;) {
|
|
2108
2112
|
var t = Q[0];
|
|
2109
|
-
H(t, this.options.selectedClass, !1), Q.shift(),
|
|
2113
|
+
H(t, this.options.selectedClass, !1), Q.shift(), Pr({
|
|
2110
2114
|
sortable: this.sortable,
|
|
2111
2115
|
rootEl: this.sortable.el,
|
|
2112
2116
|
name: "deselect",
|
|
@@ -2121,15 +2125,15 @@ function ei() {
|
|
|
2121
2125
|
_checkKeyUp: function(e) {
|
|
2122
2126
|
e.key === this.options.multiDragKey && (this.multiDragKeyDown = !1);
|
|
2123
2127
|
}
|
|
2124
|
-
},
|
|
2128
|
+
}, tr(e, {
|
|
2125
2129
|
pluginName: "multiDrag",
|
|
2126
2130
|
utils: {
|
|
2127
2131
|
select: function(e) {
|
|
2128
|
-
var t = e.parentNode[
|
|
2129
|
-
!t || !t.options.multiDrag || ~Q.indexOf(e) || (
|
|
2132
|
+
var t = e.parentNode[hi];
|
|
2133
|
+
!t || !t.options.multiDrag || ~Q.indexOf(e) || (xa && xa !== t && (xa.multiDrag._deselectMultiDrag(), xa = t), H(e, t.options.selectedClass, !0), Q.push(e));
|
|
2130
2134
|
},
|
|
2131
2135
|
deselect: function(e) {
|
|
2132
|
-
var t = e.parentNode[
|
|
2136
|
+
var t = e.parentNode[hi], n = Q.indexOf(e);
|
|
2133
2137
|
!t || !t.options.multiDrag || !~n || (H(e, t.options.selectedClass, !1), Q.splice(n, 1));
|
|
2134
2138
|
}
|
|
2135
2139
|
},
|
|
@@ -2140,14 +2144,14 @@ function ei() {
|
|
|
2140
2144
|
multiDragElement: r,
|
|
2141
2145
|
index: r.sortableIndex
|
|
2142
2146
|
});
|
|
2143
|
-
var i =
|
|
2147
|
+
var i = Ca && r !== $ ? -1 : Ca ? G(r, ":not(." + e.options.selectedClass + ")") : G(r);
|
|
2144
2148
|
n.push({
|
|
2145
2149
|
multiDragElement: r,
|
|
2146
2150
|
index: i
|
|
2147
2151
|
});
|
|
2148
2152
|
}), {
|
|
2149
|
-
items:
|
|
2150
|
-
clones: [].concat(
|
|
2153
|
+
items: ir(Q),
|
|
2154
|
+
clones: [].concat(ya),
|
|
2151
2155
|
oldIndicies: t,
|
|
2152
2156
|
newIndicies: n
|
|
2153
2157
|
};
|
|
@@ -2157,33 +2161,33 @@ function ei() {
|
|
|
2157
2161
|
} }
|
|
2158
2162
|
});
|
|
2159
2163
|
}
|
|
2160
|
-
function
|
|
2164
|
+
function ni(e, t) {
|
|
2161
2165
|
Q.forEach(function(n, r) {
|
|
2162
2166
|
var i = t.children[n.sortableIndex + (e ? Number(r) : 0)];
|
|
2163
2167
|
i ? t.insertBefore(n, i) : t.appendChild(n);
|
|
2164
2168
|
});
|
|
2165
2169
|
}
|
|
2166
|
-
function
|
|
2167
|
-
|
|
2170
|
+
function ri(e, t) {
|
|
2171
|
+
ya.forEach(function(n, r) {
|
|
2168
2172
|
var i = t.children[n.sortableIndex + (e ? Number(r) : 0)];
|
|
2169
2173
|
i ? t.insertBefore(n, i) : t.appendChild(n);
|
|
2170
2174
|
});
|
|
2171
2175
|
}
|
|
2172
|
-
function
|
|
2176
|
+
function ii() {
|
|
2173
2177
|
Q.forEach(function(e) {
|
|
2174
2178
|
e !== $ && e.parentNode && e.parentNode.removeChild(e);
|
|
2175
2179
|
});
|
|
2176
2180
|
}
|
|
2177
|
-
var
|
|
2178
|
-
|
|
2181
|
+
var ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, bi, q, J, Y, X, xi, Si, Z, Ci, wi, Ti, Ei, Di, Oi, ki, Ai, ji, Mi, Ni, Pi, Fi, Ii, Li, Ri, zi, Bi, Vi, Hi, Ui, Wi, Gi, Ki, qi, Ji, Yi, Xi, Zi, Qi, $i, ea, ta, na, ra, ia, aa, oa, sa, ca, la, ua, da, fa, pa, ma, ha, ga, _a, va, Q, ya, ba, xa, Sa, Ca, wa, $, Ta, Ea, Da = it((() => {
|
|
2182
|
+
ai = "1.14.0", oi = ur(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), si = ur(/Edge/i), ci = ur(/firefox/i), li = ur(/safari/i) && !ur(/chrome/i) && !ur(/android/i), ui = ur(/iP(ad|od|hone)/i), di = ur(/chrome/i) && ur(/android/i), fi = {
|
|
2179
2183
|
capture: !1,
|
|
2180
2184
|
passive: !1
|
|
2181
|
-
},
|
|
2185
|
+
}, pi = /\s+/g, hi = "Sortable" + (/* @__PURE__ */ new Date()).getTime(), gi = [], _i = { initializeByDefault: !0 }, vi = {
|
|
2182
2186
|
mount: function(e) {
|
|
2183
|
-
for (var t in
|
|
2184
|
-
|
|
2187
|
+
for (var t in _i) _i.hasOwnProperty(t) && !(t in e) && (e[t] = _i[t]);
|
|
2188
|
+
gi.forEach(function(t) {
|
|
2185
2189
|
if (t.pluginName === e.pluginName) throw `Sortable: Cannot mount plugin ${e.pluginName} more than once`;
|
|
2186
|
-
}),
|
|
2190
|
+
}), gi.push(e);
|
|
2187
2191
|
},
|
|
2188
2192
|
pluginEvent: function(e, t, n) {
|
|
2189
2193
|
var r = this;
|
|
@@ -2191,16 +2195,16 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2191
2195
|
r.eventCanceled = !0;
|
|
2192
2196
|
};
|
|
2193
2197
|
var i = e + "Global";
|
|
2194
|
-
|
|
2195
|
-
t[r.pluginName] && (t[r.pluginName][i] && t[r.pluginName][i](
|
|
2198
|
+
gi.forEach(function(r) {
|
|
2199
|
+
t[r.pluginName] && (t[r.pluginName][i] && t[r.pluginName][i](Qn({ sortable: t }, n)), t.options[r.pluginName] && t[r.pluginName][e] && t[r.pluginName][e](Qn({ sortable: t }, n)));
|
|
2196
2200
|
});
|
|
2197
2201
|
},
|
|
2198
2202
|
initializePlugins: function(e, t, n, r) {
|
|
2199
|
-
for (var i in
|
|
2203
|
+
for (var i in gi.forEach(function(r) {
|
|
2200
2204
|
var i = r.pluginName;
|
|
2201
2205
|
if (!(!e.options[i] && !r.initializeByDefault)) {
|
|
2202
2206
|
var a = new r(e, t, e.options);
|
|
2203
|
-
a.sortable = e, a.options = e.options, e[i] = a,
|
|
2207
|
+
a.sortable = e, a.options = e.options, e[i] = a, tr(n, a.defaults);
|
|
2204
2208
|
}
|
|
2205
2209
|
}), e.options) if (e.options.hasOwnProperty(i)) {
|
|
2206
2210
|
var a = this.modifyOption(e, i, e.options[i]);
|
|
@@ -2209,79 +2213,79 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2209
2213
|
},
|
|
2210
2214
|
getEventProperties: function(e, t) {
|
|
2211
2215
|
var n = {};
|
|
2212
|
-
return
|
|
2213
|
-
typeof r.eventProperties == "function" &&
|
|
2216
|
+
return gi.forEach(function(r) {
|
|
2217
|
+
typeof r.eventProperties == "function" && tr(n, r.eventProperties.call(t[r.pluginName], e));
|
|
2214
2218
|
}), n;
|
|
2215
2219
|
},
|
|
2216
2220
|
modifyOption: function(e, t, n) {
|
|
2217
2221
|
var r;
|
|
2218
|
-
return
|
|
2222
|
+
return gi.forEach(function(i) {
|
|
2219
2223
|
e[i.pluginName] && i.optionListeners && typeof i.optionListeners[t] == "function" && (r = i.optionListeners[t].call(e[i.pluginName], n));
|
|
2220
2224
|
}), r;
|
|
2221
2225
|
}
|
|
2222
|
-
},
|
|
2223
|
-
var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, r = n.evt, i =
|
|
2224
|
-
|
|
2226
|
+
}, yi = ["evt"], bi = function(e, t) {
|
|
2227
|
+
var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, r = n.evt, i = rr(n, yi);
|
|
2228
|
+
vi.pluginEvent.bind(K)(e, t, Qn({
|
|
2225
2229
|
dragEl: q,
|
|
2226
2230
|
parentEl: J,
|
|
2227
2231
|
ghostEl: Y,
|
|
2228
2232
|
rootEl: X,
|
|
2229
|
-
nextEl:
|
|
2230
|
-
lastDownEl:
|
|
2233
|
+
nextEl: xi,
|
|
2234
|
+
lastDownEl: Si,
|
|
2231
2235
|
cloneEl: Z,
|
|
2232
|
-
cloneHidden:
|
|
2233
|
-
dragStarted:
|
|
2234
|
-
putSortable:
|
|
2236
|
+
cloneHidden: Ci,
|
|
2237
|
+
dragStarted: zi,
|
|
2238
|
+
putSortable: ki,
|
|
2235
2239
|
activeSortable: K.active,
|
|
2236
2240
|
originalEvent: r,
|
|
2237
|
-
oldIndex:
|
|
2238
|
-
oldDraggableIndex:
|
|
2239
|
-
newIndex:
|
|
2240
|
-
newDraggableIndex:
|
|
2241
|
-
hideGhostForTarget:
|
|
2242
|
-
unhideGhostForTarget:
|
|
2241
|
+
oldIndex: wi,
|
|
2242
|
+
oldDraggableIndex: Ei,
|
|
2243
|
+
newIndex: Ti,
|
|
2244
|
+
newDraggableIndex: Di,
|
|
2245
|
+
hideGhostForTarget: ia,
|
|
2246
|
+
unhideGhostForTarget: aa,
|
|
2243
2247
|
cloneNowHidden: function() {
|
|
2244
|
-
|
|
2248
|
+
Ci = !0;
|
|
2245
2249
|
},
|
|
2246
2250
|
cloneNowShown: function() {
|
|
2247
|
-
|
|
2251
|
+
Ci = !1;
|
|
2248
2252
|
},
|
|
2249
2253
|
dispatchSortableEvent: function(e) {
|
|
2250
|
-
|
|
2254
|
+
Fr({
|
|
2251
2255
|
sortable: t,
|
|
2252
2256
|
name: e,
|
|
2253
2257
|
originalEvent: r
|
|
2254
2258
|
});
|
|
2255
2259
|
}
|
|
2256
2260
|
}, i));
|
|
2257
|
-
},
|
|
2258
|
-
if (
|
|
2259
|
-
if (
|
|
2261
|
+
}, Ai = !1, ji = !1, Mi = [], Hi = !1, Ui = !1, Ki = [], qi = !1, Ji = [], Yi = typeof document < "u", Xi = ui, Zi = si || oi ? "cssFloat" : "float", Qi = Yi && !di && !ui && "draggable" in document.createElement("div"), $i = function() {
|
|
2262
|
+
if (Yi) {
|
|
2263
|
+
if (oi) return !1;
|
|
2260
2264
|
var e = document.createElement("x");
|
|
2261
2265
|
return e.style.cssText = "pointer-events:auto", e.style.pointerEvents === "auto";
|
|
2262
2266
|
}
|
|
2263
|
-
}(),
|
|
2264
|
-
var n = U(e), r = parseInt(n.width) - parseInt(n.paddingLeft) - parseInt(n.paddingRight) - parseInt(n.borderLeftWidth) - parseInt(n.borderRightWidth), i =
|
|
2267
|
+
}(), ea = function(e, t) {
|
|
2268
|
+
var n = U(e), r = parseInt(n.width) - parseInt(n.paddingLeft) - parseInt(n.paddingRight) - parseInt(n.borderLeftWidth) - parseInt(n.borderRightWidth), i = vr(e, 0, t), a = vr(e, 1, t), o = i && U(i), s = a && U(a), c = o && parseInt(o.marginLeft) + parseInt(o.marginRight) + W(i).width, l = s && parseInt(s.marginLeft) + parseInt(s.marginRight) + W(a).width;
|
|
2265
2269
|
if (n.display === "flex") return n.flexDirection === "column" || n.flexDirection === "column-reverse" ? "vertical" : "horizontal";
|
|
2266
2270
|
if (n.display === "grid") return n.gridTemplateColumns.split(" ").length <= 1 ? "vertical" : "horizontal";
|
|
2267
2271
|
if (i && o.float && o.float !== "none") {
|
|
2268
2272
|
var u = o.float === "left" ? "left" : "right";
|
|
2269
2273
|
return a && (s.clear === "both" || s.clear === u) ? "vertical" : "horizontal";
|
|
2270
2274
|
}
|
|
2271
|
-
return i && (o.display === "block" || o.display === "flex" || o.display === "table" || o.display === "grid" || c >= r && n[
|
|
2272
|
-
},
|
|
2275
|
+
return i && (o.display === "block" || o.display === "flex" || o.display === "table" || o.display === "grid" || c >= r && n[Zi] === "none" || a && n[Zi] === "none" && c + l > r) ? "vertical" : "horizontal";
|
|
2276
|
+
}, ta = function(e, t, n) {
|
|
2273
2277
|
var r = n ? e.left : e.top, i = n ? e.right : e.bottom, a = n ? e.width : e.height, o = n ? t.left : t.top, s = n ? t.right : t.bottom, c = n ? t.width : t.height;
|
|
2274
2278
|
return r === o || i === s || r + a / 2 === o + c / 2;
|
|
2275
|
-
},
|
|
2279
|
+
}, na = function(e, t) {
|
|
2276
2280
|
var n;
|
|
2277
|
-
return
|
|
2278
|
-
var i = r[
|
|
2279
|
-
if (!(!i ||
|
|
2281
|
+
return Mi.some(function(r) {
|
|
2282
|
+
var i = r[hi].options.emptyInsertThreshold;
|
|
2283
|
+
if (!(!i || yr(r))) {
|
|
2280
2284
|
var a = W(r), o = e >= a.left - i && e <= a.right + i, s = t >= a.top - i && t <= a.bottom + i;
|
|
2281
2285
|
if (o && s) return n = r;
|
|
2282
2286
|
}
|
|
2283
2287
|
}), n;
|
|
2284
|
-
},
|
|
2288
|
+
}, ra = function(e) {
|
|
2285
2289
|
function t(e, n) {
|
|
2286
2290
|
return function(r, i, a, o) {
|
|
2287
2291
|
var s = r.options.group.name && i.options.group.name && r.options.group.name === i.options.group.name;
|
|
@@ -2294,29 +2298,29 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2294
2298
|
};
|
|
2295
2299
|
}
|
|
2296
2300
|
var n = {}, r = e.group;
|
|
2297
|
-
(!r ||
|
|
2298
|
-
}, ra = function() {
|
|
2299
|
-
!Qi && Y && U(Y, "display", "none");
|
|
2301
|
+
(!r || $n(r) != "object") && (r = { name: r }), n.name = r.name, n.checkPull = t(r.pull, !0), n.checkPut = t(r.put), n.revertClone = r.revertClone, e.group = n;
|
|
2300
2302
|
}, ia = function() {
|
|
2301
|
-
|
|
2302
|
-
},
|
|
2303
|
-
|
|
2304
|
-
},
|
|
2303
|
+
!$i && Y && U(Y, "display", "none");
|
|
2304
|
+
}, aa = function() {
|
|
2305
|
+
!$i && Y && U(Y, "display", "");
|
|
2306
|
+
}, Yi && document.addEventListener("click", function(e) {
|
|
2307
|
+
if (ji) return e.preventDefault(), e.stopPropagation && e.stopPropagation(), e.stopImmediatePropagation && e.stopImmediatePropagation(), ji = !1, !1;
|
|
2308
|
+
}, !0), oa = function(e) {
|
|
2305
2309
|
if (q) {
|
|
2306
2310
|
e = e.touches ? e.touches[0] : e;
|
|
2307
|
-
var t =
|
|
2311
|
+
var t = na(e.clientX, e.clientY);
|
|
2308
2312
|
if (t) {
|
|
2309
2313
|
var n = {};
|
|
2310
2314
|
for (var r in e) e.hasOwnProperty(r) && (n[r] = e[r]);
|
|
2311
|
-
n.target = n.rootEl = t, n.preventDefault = void 0, n.stopPropagation = void 0, t[
|
|
2315
|
+
n.target = n.rootEl = t, n.preventDefault = void 0, n.stopPropagation = void 0, t[hi]._onDragOver(n);
|
|
2312
2316
|
}
|
|
2313
2317
|
}
|
|
2314
|
-
},
|
|
2315
|
-
q && q.parentNode[
|
|
2318
|
+
}, sa = function(e) {
|
|
2319
|
+
q && q.parentNode[hi]._isOutsideThisEl(e.target);
|
|
2316
2320
|
}, K.prototype = {
|
|
2317
2321
|
constructor: K,
|
|
2318
2322
|
_isOutsideThisEl: function(e) {
|
|
2319
|
-
!this.el.contains(e) && e !== this.el && (
|
|
2323
|
+
!this.el.contains(e) && e !== this.el && (Bi = null);
|
|
2320
2324
|
},
|
|
2321
2325
|
_getDirection: function(e, t) {
|
|
2322
2326
|
return typeof this.options.direction == "function" ? this.options.direction.call(this, e, t, q) : this.options.direction;
|
|
@@ -2324,33 +2328,33 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2324
2328
|
_onTapStart: function(e) {
|
|
2325
2329
|
if (e.cancelable) {
|
|
2326
2330
|
var t = this, n = this.el, r = this.options, i = r.preventOnFilter, a = e.type, o = e.touches && e.touches[0] || e.pointerType && e.pointerType === "touch" && e, s = (o || e).target, c = e.target.shadowRoot && (e.path && e.path[0] || e.composedPath && e.composedPath()[0]) || s, l = r.filter;
|
|
2327
|
-
if (
|
|
2328
|
-
if (
|
|
2331
|
+
if (Gr(n), !q && !(/mousedown|pointerdown/.test(a) && e.button !== 0 || r.disabled) && !c.isContentEditable && !(!this.nativeDraggable && li && s && s.tagName.toUpperCase() === "SELECT") && (s = pr(s, r.draggable, n, !1), !(s && s.animated) && Si !== s)) {
|
|
2332
|
+
if (wi = G(s), Ei = G(s, r.draggable), typeof l == "function") {
|
|
2329
2333
|
if (l.call(this, e, s, this)) {
|
|
2330
|
-
|
|
2334
|
+
Fr({
|
|
2331
2335
|
sortable: t,
|
|
2332
2336
|
rootEl: c,
|
|
2333
2337
|
name: "filter",
|
|
2334
2338
|
targetEl: s,
|
|
2335
2339
|
toEl: n,
|
|
2336
2340
|
fromEl: n
|
|
2337
|
-
}),
|
|
2341
|
+
}), bi("filter", t, { evt: e }), i && e.cancelable && e.preventDefault();
|
|
2338
2342
|
return;
|
|
2339
2343
|
}
|
|
2340
2344
|
} else if (l && (l = l.split(",").some(function(r) {
|
|
2341
|
-
if (r =
|
|
2345
|
+
if (r = pr(c, r.trim(), n, !1), r) return Fr({
|
|
2342
2346
|
sortable: t,
|
|
2343
2347
|
rootEl: r,
|
|
2344
2348
|
name: "filter",
|
|
2345
2349
|
targetEl: s,
|
|
2346
2350
|
fromEl: n,
|
|
2347
2351
|
toEl: n
|
|
2348
|
-
}),
|
|
2352
|
+
}), bi("filter", t, { evt: e }), !0;
|
|
2349
2353
|
}), l)) {
|
|
2350
2354
|
i && e.cancelable && e.preventDefault();
|
|
2351
2355
|
return;
|
|
2352
2356
|
}
|
|
2353
|
-
r.handle && !
|
|
2357
|
+
r.handle && !pr(c, r.handle, n, !1) || this._prepareDragStart(e, o, s);
|
|
2354
2358
|
}
|
|
2355
2359
|
}
|
|
2356
2360
|
},
|
|
@@ -2358,23 +2362,23 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2358
2362
|
var r = this, i = r.el, a = r.options, o = i.ownerDocument, s;
|
|
2359
2363
|
if (n && !q && n.parentNode === i) {
|
|
2360
2364
|
var c = W(n);
|
|
2361
|
-
if (X = i, q = n, J = q.parentNode,
|
|
2365
|
+
if (X = i, q = n, J = q.parentNode, xi = q.nextSibling, Si = n, Oi = a.group, K.dragged = q, Ni = {
|
|
2362
2366
|
target: q,
|
|
2363
2367
|
clientX: (t || e).clientX,
|
|
2364
2368
|
clientY: (t || e).clientY
|
|
2365
|
-
},
|
|
2366
|
-
if (
|
|
2369
|
+
}, Li = Ni.clientX - c.left, Ri = Ni.clientY - c.top, this._lastX = (t || e).clientX, this._lastY = (t || e).clientY, q.style["will-change"] = "all", s = function() {
|
|
2370
|
+
if (bi("delayEnded", r, { evt: e }), K.eventCanceled) {
|
|
2367
2371
|
r._onDrop();
|
|
2368
2372
|
return;
|
|
2369
2373
|
}
|
|
2370
|
-
r._disableDelayedDragEvents(), !
|
|
2374
|
+
r._disableDelayedDragEvents(), !ci && r.nativeDraggable && (q.draggable = !0), r._triggerDragStart(e, t), Fr({
|
|
2371
2375
|
sortable: r,
|
|
2372
2376
|
name: "choose",
|
|
2373
2377
|
originalEvent: e
|
|
2374
2378
|
}), H(q, a.chosenClass, !0);
|
|
2375
2379
|
}, a.ignore.split(",").forEach(function(e) {
|
|
2376
|
-
|
|
2377
|
-
}), B(o, "dragover",
|
|
2380
|
+
hr(q, e.trim(), Rr);
|
|
2381
|
+
}), B(o, "dragover", oa), B(o, "mousemove", oa), B(o, "touchmove", oa), B(o, "mouseup", r._onDrop), B(o, "touchend", r._onDrop), B(o, "touchcancel", r._onDrop), ci && this.nativeDraggable && (this.options.touchStartThreshold = 4, q.draggable = !0), bi("delayStart", this, { evt: e }), a.delay && (!a.delayOnTouchOnly || t) && (!this.nativeDraggable || !(si || oi))) {
|
|
2378
2382
|
if (K.eventCanceled) {
|
|
2379
2383
|
this._onDrop();
|
|
2380
2384
|
return;
|
|
@@ -2388,7 +2392,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2388
2392
|
Math.max(Math.abs(t.clientX - this._lastX), Math.abs(t.clientY - this._lastY)) >= Math.floor(this.options.touchStartThreshold / (this.nativeDraggable && window.devicePixelRatio || 1)) && this._disableDelayedDrag();
|
|
2389
2393
|
},
|
|
2390
2394
|
_disableDelayedDrag: function() {
|
|
2391
|
-
q &&
|
|
2395
|
+
q && Rr(q), clearTimeout(this._dragStartTimer), this._disableDelayedDragEvents();
|
|
2392
2396
|
},
|
|
2393
2397
|
_disableDelayedDragEvents: function() {
|
|
2394
2398
|
var e = this.el.ownerDocument;
|
|
@@ -2397,16 +2401,16 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2397
2401
|
_triggerDragStart: function(e, t) {
|
|
2398
2402
|
t ||= e.pointerType == "touch" && e, !this.nativeDraggable || t ? this.options.supportPointer ? B(document, "pointermove", this._onTouchMove) : t ? B(document, "touchmove", this._onTouchMove) : B(document, "mousemove", this._onTouchMove) : (B(q, "dragend", this), B(X, "dragstart", this._onDragStart));
|
|
2399
2403
|
try {
|
|
2400
|
-
document.selection ?
|
|
2404
|
+
document.selection ? Kr(function() {
|
|
2401
2405
|
document.selection.empty();
|
|
2402
2406
|
}) : window.getSelection().removeAllRanges();
|
|
2403
2407
|
} catch {}
|
|
2404
2408
|
},
|
|
2405
2409
|
_dragStarted: function(e, t) {
|
|
2406
|
-
if (
|
|
2407
|
-
|
|
2410
|
+
if (Ai = !1, X && q) {
|
|
2411
|
+
bi("dragStarted", this, { evt: t }), this.nativeDraggable && B(document, "dragover", sa);
|
|
2408
2412
|
var n = this.options;
|
|
2409
|
-
!e && H(q, n.dragClass, !1), H(q, n.ghostClass, !0), K.active = this, e && this._appendGhost(),
|
|
2413
|
+
!e && H(q, n.dragClass, !1), H(q, n.ghostClass, !0), K.active = this, e && this._appendGhost(), Fr({
|
|
2410
2414
|
sortable: this,
|
|
2411
2415
|
name: "start",
|
|
2412
2416
|
originalEvent: t
|
|
@@ -2414,33 +2418,33 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2414
2418
|
} else this._nulling();
|
|
2415
2419
|
},
|
|
2416
2420
|
_emulateDragOver: function() {
|
|
2417
|
-
if (
|
|
2418
|
-
this._lastX =
|
|
2419
|
-
for (var e = document.elementFromPoint(
|
|
2420
|
-
if (q.parentNode[
|
|
2421
|
-
if (t[
|
|
2421
|
+
if (Pi) {
|
|
2422
|
+
this._lastX = Pi.clientX, this._lastY = Pi.clientY, ia();
|
|
2423
|
+
for (var e = document.elementFromPoint(Pi.clientX, Pi.clientY), t = e; e && e.shadowRoot && (e = e.shadowRoot.elementFromPoint(Pi.clientX, Pi.clientY), e !== t);) t = e;
|
|
2424
|
+
if (q.parentNode[hi]._isOutsideThisEl(e), t) do {
|
|
2425
|
+
if (t[hi]) {
|
|
2422
2426
|
var n = void 0;
|
|
2423
|
-
if (n = t[
|
|
2424
|
-
clientX:
|
|
2425
|
-
clientY:
|
|
2427
|
+
if (n = t[hi]._onDragOver({
|
|
2428
|
+
clientX: Pi.clientX,
|
|
2429
|
+
clientY: Pi.clientY,
|
|
2426
2430
|
target: e,
|
|
2427
2431
|
rootEl: t
|
|
2428
2432
|
}), n && !this.options.dragoverBubble) break;
|
|
2429
2433
|
}
|
|
2430
2434
|
e = t;
|
|
2431
2435
|
} while (t = t.parentNode);
|
|
2432
|
-
|
|
2436
|
+
aa();
|
|
2433
2437
|
}
|
|
2434
2438
|
},
|
|
2435
2439
|
_onTouchMove: function(e) {
|
|
2436
|
-
if (
|
|
2437
|
-
var t = this.options, n = t.fallbackTolerance, r = t.fallbackOffset, i = e.touches ? e.touches[0] : e, a = Y &&
|
|
2438
|
-
if (!K.active && !
|
|
2440
|
+
if (Ni) {
|
|
2441
|
+
var t = this.options, n = t.fallbackTolerance, r = t.fallbackOffset, i = e.touches ? e.touches[0] : e, a = Y && mr(Y, !0), o = Y && a && a.a, s = Y && a && a.d, c = Xi && Gi && br(Gi), l = (i.clientX - Ni.clientX + r.x) / (o || 1) + (c ? c[0] - Ki[0] : 0) / (o || 1), u = (i.clientY - Ni.clientY + r.y) / (s || 1) + (c ? c[1] - Ki[1] : 0) / (s || 1);
|
|
2442
|
+
if (!K.active && !Ai) {
|
|
2439
2443
|
if (n && Math.max(Math.abs(i.clientX - this._lastX), Math.abs(i.clientY - this._lastY)) < n) return;
|
|
2440
2444
|
this._onDragStart(e, !0);
|
|
2441
2445
|
}
|
|
2442
2446
|
if (Y) {
|
|
2443
|
-
a ? (a.e += l - (
|
|
2447
|
+
a ? (a.e += l - (Fi || 0), a.f += u - (Ii || 0)) : a = {
|
|
2444
2448
|
a: 1,
|
|
2445
2449
|
b: 0,
|
|
2446
2450
|
c: 0,
|
|
@@ -2449,39 +2453,39 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2449
2453
|
f: u
|
|
2450
2454
|
};
|
|
2451
2455
|
var d = `matrix(${a.a},${a.b},${a.c},${a.d},${a.e},${a.f})`;
|
|
2452
|
-
U(Y, "webkitTransform", d), U(Y, "mozTransform", d), U(Y, "msTransform", d), U(Y, "transform", d),
|
|
2456
|
+
U(Y, "webkitTransform", d), U(Y, "mozTransform", d), U(Y, "msTransform", d), U(Y, "transform", d), Fi = l, Ii = u, Pi = i;
|
|
2453
2457
|
}
|
|
2454
2458
|
e.cancelable && e.preventDefault();
|
|
2455
2459
|
}
|
|
2456
2460
|
},
|
|
2457
2461
|
_appendGhost: function() {
|
|
2458
2462
|
if (!Y) {
|
|
2459
|
-
var e = this.options.fallbackOnBody ? document.body : X, t = W(q, !0,
|
|
2460
|
-
if (
|
|
2461
|
-
for (
|
|
2462
|
-
|
|
2463
|
+
var e = this.options.fallbackOnBody ? document.body : X, t = W(q, !0, Xi, !0, e), n = this.options;
|
|
2464
|
+
if (Xi) {
|
|
2465
|
+
for (Gi = e; U(Gi, "position") === "static" && U(Gi, "transform") === "none" && Gi !== document;) Gi = Gi.parentNode;
|
|
2466
|
+
Gi !== document.body && Gi !== document.documentElement ? (Gi === document && (Gi = gr()), t.top += Gi.scrollTop, t.left += Gi.scrollLeft) : Gi = gr(), Ki = br(Gi);
|
|
2463
2467
|
}
|
|
2464
|
-
Y = q.cloneNode(!0), H(Y, n.ghostClass, !1), H(Y, n.fallbackClass, !0), H(Y, n.dragClass, !0), U(Y, "transition", ""), U(Y, "transform", ""), U(Y, "box-sizing", "border-box"), U(Y, "margin", 0), U(Y, "top", t.top), U(Y, "left", t.left), U(Y, "width", t.width), U(Y, "height", t.height), U(Y, "opacity", "0.8"), U(Y, "position",
|
|
2468
|
+
Y = q.cloneNode(!0), H(Y, n.ghostClass, !1), H(Y, n.fallbackClass, !0), H(Y, n.dragClass, !0), U(Y, "transition", ""), U(Y, "transform", ""), U(Y, "box-sizing", "border-box"), U(Y, "margin", 0), U(Y, "top", t.top), U(Y, "left", t.left), U(Y, "width", t.width), U(Y, "height", t.height), U(Y, "opacity", "0.8"), U(Y, "position", Xi ? "absolute" : "fixed"), U(Y, "zIndex", "100000"), U(Y, "pointerEvents", "none"), K.ghost = Y, e.appendChild(Y), U(Y, "transform-origin", Li / parseInt(Y.style.width) * 100 + "% " + Ri / parseInt(Y.style.height) * 100 + "%");
|
|
2465
2469
|
}
|
|
2466
2470
|
},
|
|
2467
2471
|
_onDragStart: function(e, t) {
|
|
2468
2472
|
var n = this, r = e.dataTransfer, i = n.options;
|
|
2469
|
-
if (
|
|
2473
|
+
if (bi("dragStart", this, { evt: e }), K.eventCanceled) {
|
|
2470
2474
|
this._onDrop();
|
|
2471
2475
|
return;
|
|
2472
2476
|
}
|
|
2473
|
-
|
|
2474
|
-
|
|
2477
|
+
bi("setupClone", this), K.eventCanceled || (Z = Or(q), Z.draggable = !1, Z.style["will-change"] = "", this._hideClone(), H(Z, this.options.chosenClass, !1), K.clone = Z), n.cloneId = Kr(function() {
|
|
2478
|
+
bi("clone", n), !K.eventCanceled && (n.options.removeCloneOnHide || X.insertBefore(Z, q), n._hideClone(), Fr({
|
|
2475
2479
|
sortable: n,
|
|
2476
2480
|
name: "clone"
|
|
2477
2481
|
}));
|
|
2478
|
-
}), !t && H(q, i.dragClass, !0), t ? (
|
|
2482
|
+
}), !t && H(q, i.dragClass, !0), t ? (ji = !0, n._loopId = setInterval(n._emulateDragOver, 50)) : (V(document, "mouseup", n._onDrop), V(document, "touchend", n._onDrop), V(document, "touchcancel", n._onDrop), r && (r.effectAllowed = "move", i.setData && i.setData.call(n, r, q)), B(document, "drop", n), U(q, "transform", "translateZ(0)")), Ai = !0, n._dragStartId = Kr(n._dragStarted.bind(n, t, e)), B(document, "selectstart", n), zi = !0, li && U(document.body, "user-select", "none");
|
|
2479
2483
|
},
|
|
2480
2484
|
_onDragOver: function(e) {
|
|
2481
|
-
var t = this.el, n = e.target, r, i, a, o = this.options, s = o.group, c = K.active, l =
|
|
2482
|
-
if (
|
|
2485
|
+
var t = this.el, n = e.target, r, i, a, o = this.options, s = o.group, c = K.active, l = Oi === s, u = o.sort, d = ki || c, f, p = this, m = !1;
|
|
2486
|
+
if (qi) return;
|
|
2483
2487
|
function h(o, s) {
|
|
2484
|
-
|
|
2488
|
+
bi(o, p, Qn({
|
|
2485
2489
|
evt: e,
|
|
2486
2490
|
isOwner: l,
|
|
2487
2491
|
axis: f ? "vertical" : "horizontal",
|
|
@@ -2493,7 +2497,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2493
2497
|
target: n,
|
|
2494
2498
|
completed: _,
|
|
2495
2499
|
onMove: function(n, i) {
|
|
2496
|
-
return
|
|
2500
|
+
return Lr(X, t, q, r, n, W(n), e, i);
|
|
2497
2501
|
},
|
|
2498
2502
|
changed: v
|
|
2499
2503
|
}, s));
|
|
@@ -2502,50 +2506,50 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2502
2506
|
h("dragOverAnimationCapture"), p.captureAnimationState(), p !== d && d.captureAnimationState();
|
|
2503
2507
|
}
|
|
2504
2508
|
function _(r) {
|
|
2505
|
-
return h("dragOverCompleted", { insertion: r }), r && (l ? c._hideClone() : c._showClone(p), p !== d && (H(q,
|
|
2509
|
+
return h("dragOverCompleted", { insertion: r }), r && (l ? c._hideClone() : c._showClone(p), p !== d && (H(q, ki ? ki.options.ghostClass : c.options.ghostClass, !1), H(q, o.ghostClass, !0)), ki !== p && p !== K.active ? ki = p : p === K.active && ki && (ki = null), d === p && (p._ignoreWhileAnimating = n), p.animateAll(function() {
|
|
2506
2510
|
h("dragOverAnimationComplete"), p._ignoreWhileAnimating = null;
|
|
2507
|
-
}), p !== d && (d.animateAll(), d._ignoreWhileAnimating = null)), (n === q && !q.animated || n === t && !n.animated) && (
|
|
2511
|
+
}), p !== d && (d.animateAll(), d._ignoreWhileAnimating = null)), (n === q && !q.animated || n === t && !n.animated) && (Bi = null), !o.dragoverBubble && !e.rootEl && n !== document && (q.parentNode[hi]._isOutsideThisEl(e.target), !r && oa(e)), !o.dragoverBubble && e.stopPropagation && e.stopPropagation(), m = !0;
|
|
2508
2512
|
}
|
|
2509
2513
|
function v() {
|
|
2510
|
-
|
|
2514
|
+
Ti = G(q), Di = G(q, o.draggable), Fr({
|
|
2511
2515
|
sortable: p,
|
|
2512
2516
|
name: "change",
|
|
2513
2517
|
toEl: t,
|
|
2514
|
-
newIndex:
|
|
2515
|
-
newDraggableIndex:
|
|
2518
|
+
newIndex: Ti,
|
|
2519
|
+
newDraggableIndex: Di,
|
|
2516
2520
|
originalEvent: e
|
|
2517
2521
|
});
|
|
2518
2522
|
}
|
|
2519
|
-
if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), n =
|
|
2523
|
+
if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), n = pr(n, o.draggable, t, !0), h("dragOver"), K.eventCanceled) return m;
|
|
2520
2524
|
if (q.contains(e.target) || n.animated && n.animatingX && n.animatingY || p._ignoreWhileAnimating === n) return _(!1);
|
|
2521
|
-
if (
|
|
2525
|
+
if (ji = !1, c && !o.disabled && (l ? u || (a = J !== X) : ki === this || (this.lastPutMode = Oi.checkPull(this, c, q, e)) && s.checkPut(this, c, q, e))) {
|
|
2522
2526
|
if (f = this._getDirection(e, n) === "vertical", r = W(q), h("dragOverValid"), K.eventCanceled) return m;
|
|
2523
|
-
if (a) return J = X, g(), this._hideClone(), h("revert"), K.eventCanceled || (
|
|
2524
|
-
var y =
|
|
2525
|
-
if (!y ||
|
|
2527
|
+
if (a) return J = X, g(), this._hideClone(), h("revert"), K.eventCanceled || (xi ? X.insertBefore(q, xi) : X.appendChild(q)), _(!0);
|
|
2528
|
+
var y = yr(t, o.draggable);
|
|
2529
|
+
if (!y || Vr(e, f, this) && !y.animated) {
|
|
2526
2530
|
if (y === q) return _(!1);
|
|
2527
|
-
if (y && t === e.target && (n = y), n && (i = W(n)),
|
|
2528
|
-
} else if (y &&
|
|
2529
|
-
var b =
|
|
2531
|
+
if (y && t === e.target && (n = y), n && (i = W(n)), Lr(X, t, q, r, n, i, e, !!n) !== !1) return g(), t.appendChild(q), J = t, v(), _(!0);
|
|
2532
|
+
} else if (y && Br(e, f, this)) {
|
|
2533
|
+
var b = vr(t, 0, o, !0);
|
|
2530
2534
|
if (b === q) return _(!1);
|
|
2531
|
-
if (n = b, i = W(n),
|
|
2535
|
+
if (n = b, i = W(n), Lr(X, t, q, r, n, i, e, !1) !== !1) return g(), t.insertBefore(q, b), J = t, v(), _(!0);
|
|
2532
2536
|
} else if (n.parentNode === t) {
|
|
2533
2537
|
i = W(n);
|
|
2534
|
-
var x = 0, S, C = q.parentNode !== t,
|
|
2535
|
-
|
|
2536
|
-
var
|
|
2538
|
+
var x = 0, S, C = q.parentNode !== t, w = !ta(q.animated && q.toRect || r, n.animated && n.toRect || i, f), T = f ? "top" : "left", E = _r(n, "top", "top") || _r(q, "top", "top"), D = E ? E.scrollTop : void 0;
|
|
2539
|
+
Bi !== n && (S = i[T], Hi = !1, Ui = !w && o.invertSwap || C), x = Hr(e, n, i, f, w ? 1 : o.swapThreshold, o.invertedSwapThreshold == null ? o.swapThreshold : o.invertedSwapThreshold, Ui, Bi === n);
|
|
2540
|
+
var O;
|
|
2537
2541
|
if (x !== 0) {
|
|
2538
|
-
var
|
|
2542
|
+
var ee = G(q);
|
|
2539
2543
|
do
|
|
2540
|
-
|
|
2541
|
-
while (
|
|
2544
|
+
ee -= x, O = J.children[ee];
|
|
2545
|
+
while (O && (U(O, "display") === "none" || O === Y));
|
|
2542
2546
|
}
|
|
2543
|
-
if (x === 0 ||
|
|
2544
|
-
|
|
2545
|
-
var
|
|
2546
|
-
|
|
2547
|
-
var
|
|
2548
|
-
if (
|
|
2547
|
+
if (x === 0 || O === n) return _(!1);
|
|
2548
|
+
Bi = n, Vi = x;
|
|
2549
|
+
var k = n.nextElementSibling, te = !1;
|
|
2550
|
+
te = x === 1;
|
|
2551
|
+
var ne = Lr(X, t, q, r, n, i, e, te);
|
|
2552
|
+
if (ne !== !1) return (ne === 1 || ne === -1) && (te = ne === 1), qi = !0, setTimeout(zr, 30), g(), te && !k ? t.appendChild(q) : n.parentNode.insertBefore(q, te ? k : n), E && Dr(E, 0, D - E.scrollTop), J = q.parentNode, S !== void 0 && !Ui && (Wi = Math.abs(S - W(n)[T])), v(), _(!0);
|
|
2549
2553
|
}
|
|
2550
2554
|
if (t.contains(q)) return _(!1);
|
|
2551
2555
|
}
|
|
@@ -2553,7 +2557,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2553
2557
|
},
|
|
2554
2558
|
_ignoreWhileAnimating: null,
|
|
2555
2559
|
_offMoveEvents: function() {
|
|
2556
|
-
V(document, "mousemove", this._onTouchMove), V(document, "touchmove", this._onTouchMove), V(document, "pointermove", this._onTouchMove), V(document, "dragover",
|
|
2560
|
+
V(document, "mousemove", this._onTouchMove), V(document, "touchmove", this._onTouchMove), V(document, "pointermove", this._onTouchMove), V(document, "dragover", oa), V(document, "mousemove", oa), V(document, "touchmove", oa);
|
|
2557
2561
|
},
|
|
2558
2562
|
_offUpEvents: function() {
|
|
2559
2563
|
var e = this.el.ownerDocument;
|
|
@@ -2561,50 +2565,50 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2561
2565
|
},
|
|
2562
2566
|
_onDrop: function(e) {
|
|
2563
2567
|
var t = this.el, n = this.options;
|
|
2564
|
-
if (
|
|
2568
|
+
if (Ti = G(q), Di = G(q, n.draggable), bi("drop", this, { evt: e }), J = q && q.parentNode, Ti = G(q), Di = G(q, n.draggable), K.eventCanceled) {
|
|
2565
2569
|
this._nulling();
|
|
2566
2570
|
return;
|
|
2567
2571
|
}
|
|
2568
|
-
|
|
2572
|
+
Ai = !1, Ui = !1, Hi = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), qr(this.cloneId), qr(this._dragStartId), this.nativeDraggable && (V(document, "drop", this), V(t, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), li && U(document.body, "user-select", ""), U(q, "transform", ""), e && (zi && (e.cancelable && e.preventDefault(), !n.dropBubble && e.stopPropagation()), Y && Y.parentNode && Y.parentNode.removeChild(Y), (X === J || ki && ki.lastPutMode !== "clone") && Z && Z.parentNode && Z.parentNode.removeChild(Z), q && (this.nativeDraggable && V(q, "dragend", this), Rr(q), q.style["will-change"] = "", zi && !Ai && H(q, ki ? ki.options.ghostClass : this.options.ghostClass, !1), H(q, this.options.chosenClass, !1), Fr({
|
|
2569
2573
|
sortable: this,
|
|
2570
2574
|
name: "unchoose",
|
|
2571
2575
|
toEl: J,
|
|
2572
2576
|
newIndex: null,
|
|
2573
2577
|
newDraggableIndex: null,
|
|
2574
2578
|
originalEvent: e
|
|
2575
|
-
}), X === J ?
|
|
2579
|
+
}), X === J ? Ti !== wi && Ti >= 0 && (Fr({
|
|
2576
2580
|
sortable: this,
|
|
2577
2581
|
name: "update",
|
|
2578
2582
|
toEl: J,
|
|
2579
2583
|
originalEvent: e
|
|
2580
|
-
}),
|
|
2584
|
+
}), Fr({
|
|
2581
2585
|
sortable: this,
|
|
2582
2586
|
name: "sort",
|
|
2583
2587
|
toEl: J,
|
|
2584
2588
|
originalEvent: e
|
|
2585
|
-
})) : (
|
|
2589
|
+
})) : (Ti >= 0 && (Fr({
|
|
2586
2590
|
rootEl: J,
|
|
2587
2591
|
name: "add",
|
|
2588
2592
|
toEl: J,
|
|
2589
2593
|
fromEl: X,
|
|
2590
2594
|
originalEvent: e
|
|
2591
|
-
}),
|
|
2595
|
+
}), Fr({
|
|
2592
2596
|
sortable: this,
|
|
2593
2597
|
name: "remove",
|
|
2594
2598
|
toEl: J,
|
|
2595
2599
|
originalEvent: e
|
|
2596
|
-
}),
|
|
2600
|
+
}), Fr({
|
|
2597
2601
|
rootEl: J,
|
|
2598
2602
|
name: "sort",
|
|
2599
2603
|
toEl: J,
|
|
2600
2604
|
fromEl: X,
|
|
2601
2605
|
originalEvent: e
|
|
2602
|
-
}),
|
|
2606
|
+
}), Fr({
|
|
2603
2607
|
sortable: this,
|
|
2604
2608
|
name: "sort",
|
|
2605
2609
|
toEl: J,
|
|
2606
2610
|
originalEvent: e
|
|
2607
|
-
})),
|
|
2611
|
+
})), ki && ki.save()), K.active && ((Ti == null || Ti === -1) && (Ti = wi, Di = Ei), Fr({
|
|
2608
2612
|
sortable: this,
|
|
2609
2613
|
name: "end",
|
|
2610
2614
|
toEl: J,
|
|
@@ -2612,9 +2616,9 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2612
2616
|
}), this.save()))), this._nulling();
|
|
2613
2617
|
},
|
|
2614
2618
|
_nulling: function() {
|
|
2615
|
-
|
|
2619
|
+
bi("nulling", this), X = q = J = Y = xi = Z = Si = Ci = Ni = Pi = zi = Ti = Di = wi = Ei = Bi = Vi = ki = Oi = K.dragged = K.ghost = K.clone = K.active = null, Ji.forEach(function(e) {
|
|
2616
2620
|
e.checked = !0;
|
|
2617
|
-
}),
|
|
2621
|
+
}), Ji.length = Fi = Ii = 0;
|
|
2618
2622
|
},
|
|
2619
2623
|
handleEvent: function(e) {
|
|
2620
2624
|
switch (e.type) {
|
|
@@ -2624,7 +2628,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2624
2628
|
break;
|
|
2625
2629
|
case "dragenter":
|
|
2626
2630
|
case "dragover":
|
|
2627
|
-
q && (this._onDragOver(e),
|
|
2631
|
+
q && (this._onDragOver(e), Ir(e));
|
|
2628
2632
|
break;
|
|
2629
2633
|
case "selectstart":
|
|
2630
2634
|
e.preventDefault();
|
|
@@ -2632,14 +2636,14 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2632
2636
|
}
|
|
2633
2637
|
},
|
|
2634
2638
|
toArray: function() {
|
|
2635
|
-
for (var e = [], t, n = this.el.children, r = 0, i = n.length, a = this.options; r < i; r++) t = n[r],
|
|
2639
|
+
for (var e = [], t, n = this.el.children, r = 0, i = n.length, a = this.options; r < i; r++) t = n[r], pr(t, a.draggable, this.el, !1) && e.push(t.getAttribute(a.dataIdAttr) || Wr(t));
|
|
2636
2640
|
return e;
|
|
2637
2641
|
},
|
|
2638
2642
|
sort: function(e, t) {
|
|
2639
2643
|
var n = {}, r = this.el;
|
|
2640
2644
|
this.toArray().forEach(function(e, t) {
|
|
2641
2645
|
var i = r.children[t];
|
|
2642
|
-
|
|
2646
|
+
pr(i, this.options.draggable, r, !1) && (n[e] = i);
|
|
2643
2647
|
}, this), t && this.captureAnimationState(), e.forEach(function(e) {
|
|
2644
2648
|
n[e] && (r.removeChild(n[e]), r.appendChild(n[e]));
|
|
2645
2649
|
}), t && this.animateAll();
|
|
@@ -2649,25 +2653,25 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2649
2653
|
e && e.set && e.set(this);
|
|
2650
2654
|
},
|
|
2651
2655
|
closest: function(e, t) {
|
|
2652
|
-
return
|
|
2656
|
+
return pr(e, t || this.options.draggable, this.el, !1);
|
|
2653
2657
|
},
|
|
2654
2658
|
option: function(e, t) {
|
|
2655
2659
|
var n = this.options;
|
|
2656
2660
|
if (t === void 0) return n[e];
|
|
2657
|
-
var r =
|
|
2658
|
-
r === void 0 ? n[e] = t : n[e] = r, e === "group" &&
|
|
2661
|
+
var r = vi.modifyOption(this, e, t);
|
|
2662
|
+
r === void 0 ? n[e] = t : n[e] = r, e === "group" && ra(n);
|
|
2659
2663
|
},
|
|
2660
2664
|
destroy: function() {
|
|
2661
|
-
|
|
2665
|
+
bi("destroy", this);
|
|
2662
2666
|
var e = this.el;
|
|
2663
|
-
e[
|
|
2667
|
+
e[hi] = null, V(e, "mousedown", this._onTapStart), V(e, "touchstart", this._onTapStart), V(e, "pointerdown", this._onTapStart), this.nativeDraggable && (V(e, "dragover", this), V(e, "dragenter", this)), Array.prototype.forEach.call(e.querySelectorAll("[draggable]"), function(e) {
|
|
2664
2668
|
e.removeAttribute("draggable");
|
|
2665
|
-
}), this._onDrop(), this._disableDelayedDragEvents(),
|
|
2669
|
+
}), this._onDrop(), this._disableDelayedDragEvents(), Mi.splice(Mi.indexOf(this.el), 1), this.el = e = null;
|
|
2666
2670
|
},
|
|
2667
2671
|
_hideClone: function() {
|
|
2668
|
-
if (!
|
|
2669
|
-
if (
|
|
2670
|
-
U(Z, "display", "none"), this.options.removeCloneOnHide && Z.parentNode && Z.parentNode.removeChild(Z),
|
|
2672
|
+
if (!Ci) {
|
|
2673
|
+
if (bi("hideClone", this), K.eventCanceled) return;
|
|
2674
|
+
U(Z, "display", "none"), this.options.removeCloneOnHide && Z.parentNode && Z.parentNode.removeChild(Z), Ci = !0;
|
|
2671
2675
|
}
|
|
2672
2676
|
},
|
|
2673
2677
|
_showClone: function(e) {
|
|
@@ -2675,60 +2679,60 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2675
2679
|
this._hideClone();
|
|
2676
2680
|
return;
|
|
2677
2681
|
}
|
|
2678
|
-
if (
|
|
2679
|
-
if (
|
|
2680
|
-
q.parentNode == X && !this.options.group.revertClone ? X.insertBefore(Z, q) :
|
|
2682
|
+
if (Ci) {
|
|
2683
|
+
if (bi("showClone", this), K.eventCanceled) return;
|
|
2684
|
+
q.parentNode == X && !this.options.group.revertClone ? X.insertBefore(Z, q) : xi ? X.insertBefore(Z, xi) : X.appendChild(Z), this.options.group.revertClone && this.animate(q, Z), U(Z, "display", ""), Ci = !1;
|
|
2681
2685
|
}
|
|
2682
2686
|
}
|
|
2683
|
-
},
|
|
2684
|
-
(K.active ||
|
|
2687
|
+
}, Yi && B(document, "touchmove", function(e) {
|
|
2688
|
+
(K.active || Ai) && e.cancelable && e.preventDefault();
|
|
2685
2689
|
}), K.utils = {
|
|
2686
2690
|
on: B,
|
|
2687
2691
|
off: V,
|
|
2688
2692
|
css: U,
|
|
2689
|
-
find:
|
|
2693
|
+
find: hr,
|
|
2690
2694
|
is: function(e, t) {
|
|
2691
|
-
return !!
|
|
2695
|
+
return !!pr(e, t, e, !1);
|
|
2692
2696
|
},
|
|
2693
|
-
extend:
|
|
2694
|
-
throttle:
|
|
2695
|
-
closest:
|
|
2697
|
+
extend: Cr,
|
|
2698
|
+
throttle: Tr,
|
|
2699
|
+
closest: pr,
|
|
2696
2700
|
toggleClass: H,
|
|
2697
|
-
clone:
|
|
2701
|
+
clone: Or,
|
|
2698
2702
|
index: G,
|
|
2699
|
-
nextTick:
|
|
2700
|
-
cancelNextTick:
|
|
2701
|
-
detectDirection:
|
|
2702
|
-
getChild:
|
|
2703
|
+
nextTick: Kr,
|
|
2704
|
+
cancelNextTick: qr,
|
|
2705
|
+
detectDirection: ea,
|
|
2706
|
+
getChild: vr
|
|
2703
2707
|
}, K.get = function(e) {
|
|
2704
|
-
return e[
|
|
2708
|
+
return e[hi];
|
|
2705
2709
|
}, K.mount = function() {
|
|
2706
2710
|
var e = [...arguments];
|
|
2707
2711
|
e[0].constructor === Array && (e = e[0]), e.forEach(function(e) {
|
|
2708
2712
|
if (!e.prototype || !e.prototype.constructor) throw `Sortable: Mounted plugin must be a constructor function, not ${{}.toString.call(e)}`;
|
|
2709
|
-
e.utils && (K.utils =
|
|
2713
|
+
e.utils && (K.utils = Qn(Qn({}, K.utils), e.utils)), vi.mount(e);
|
|
2710
2714
|
});
|
|
2711
2715
|
}, K.create = function(e, t) {
|
|
2712
2716
|
return new K(e, t);
|
|
2713
|
-
}, K.version =
|
|
2717
|
+
}, K.version = ai, ca = [], da = !1, ga = Tr(function(e, t, n, r) {
|
|
2714
2718
|
if (t.scroll) {
|
|
2715
|
-
var i = (e.touches ? e.touches[0] : e).clientX, a = (e.touches ? e.touches[0] : e).clientY, o = t.scrollSensitivity, s = t.scrollSpeed, c =
|
|
2716
|
-
|
|
2717
|
-
var d = 0, f =
|
|
2719
|
+
var i = (e.touches ? e.touches[0] : e).clientX, a = (e.touches ? e.touches[0] : e).clientY, o = t.scrollSensitivity, s = t.scrollSpeed, c = gr(), l = !1, u;
|
|
2720
|
+
ua !== n && (ua = n, Yr(), la = t.scroll, u = t.scrollFn, la === !0 && (la = Sr(n, !0)));
|
|
2721
|
+
var d = 0, f = la;
|
|
2718
2722
|
do {
|
|
2719
|
-
var p = f, m = W(p), h = m.top, g = m.bottom, _ = m.left, v = m.right, y = m.width, b = m.height, x = void 0, S = void 0, C = p.scrollWidth,
|
|
2720
|
-
p === c ? (x = y < C && (
|
|
2721
|
-
var
|
|
2722
|
-
if (!
|
|
2723
|
-
(
|
|
2724
|
-
r && this.layer === 0 && K.active._onTouchMove(
|
|
2725
|
-
var t =
|
|
2726
|
-
typeof u == "function" && u.call(K.dragged.parentNode[
|
|
2723
|
+
var p = f, m = W(p), h = m.top, g = m.bottom, _ = m.left, v = m.right, y = m.width, b = m.height, x = void 0, S = void 0, C = p.scrollWidth, w = p.scrollHeight, T = U(p), E = p.scrollLeft, D = p.scrollTop;
|
|
2724
|
+
p === c ? (x = y < C && (T.overflowX === "auto" || T.overflowX === "scroll" || T.overflowX === "visible"), S = b < w && (T.overflowY === "auto" || T.overflowY === "scroll" || T.overflowY === "visible")) : (x = y < C && (T.overflowX === "auto" || T.overflowX === "scroll"), S = b < w && (T.overflowY === "auto" || T.overflowY === "scroll"));
|
|
2725
|
+
var O = x && (Math.abs(v - i) <= o && E + y < C) - (Math.abs(_ - i) <= o && !!E), ee = S && (Math.abs(g - a) <= o && D + b < w) - (Math.abs(h - a) <= o && !!D);
|
|
2726
|
+
if (!ca[d]) for (var k = 0; k <= d; k++) ca[k] || (ca[k] = {});
|
|
2727
|
+
(ca[d].vx != O || ca[d].vy != ee || ca[d].el !== p) && (ca[d].el = p, ca[d].vx = O, ca[d].vy = ee, clearInterval(ca[d].pid), (O != 0 || ee != 0) && (l = !0, ca[d].pid = setInterval(function() {
|
|
2728
|
+
r && this.layer === 0 && K.active._onTouchMove(ma);
|
|
2729
|
+
var t = ca[this.layer].vy ? ca[this.layer].vy * s : 0, n = ca[this.layer].vx ? ca[this.layer].vx * s : 0;
|
|
2730
|
+
typeof u == "function" && u.call(K.dragged.parentNode[hi], n, t, e, ma, ca[this.layer].el) !== "continue" || Dr(ca[this.layer].el, n, t);
|
|
2727
2731
|
}.bind({ layer: d }), 24))), d++;
|
|
2728
|
-
} while (t.bubbleScroll && f !== c && (f =
|
|
2729
|
-
|
|
2732
|
+
} while (t.bubbleScroll && f !== c && (f = Sr(f, !1)));
|
|
2733
|
+
da = l;
|
|
2730
2734
|
}
|
|
2731
|
-
}, 30),
|
|
2735
|
+
}, 30), _a = function(e) {
|
|
2732
2736
|
var t = e.originalEvent, n = e.putSortable, r = e.dragEl, i = e.activeSortable, a = e.dispatchSortableEvent, o = e.hideGhostForTarget, s = e.unhideGhostForTarget;
|
|
2733
2737
|
if (t) {
|
|
2734
2738
|
var c = n || i;
|
|
@@ -2739,7 +2743,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2739
2743
|
putSortable: n
|
|
2740
2744
|
}));
|
|
2741
2745
|
}
|
|
2742
|
-
},
|
|
2746
|
+
}, Zr.prototype = {
|
|
2743
2747
|
startIndex: null,
|
|
2744
2748
|
dragStart: function(e) {
|
|
2745
2749
|
this.startIndex = e.oldDraggableIndex;
|
|
@@ -2747,20 +2751,20 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
2747
2751
|
onSpill: function(e) {
|
|
2748
2752
|
var t = e.dragEl, n = e.putSortable;
|
|
2749
2753
|
this.sortable.captureAnimationState(), n && n.captureAnimationState();
|
|
2750
|
-
var r =
|
|
2754
|
+
var r = vr(this.sortable.el, this.startIndex, this.options);
|
|
2751
2755
|
r ? this.sortable.el.insertBefore(t, r) : this.sortable.el.appendChild(t), this.sortable.animateAll(), n && n.animateAll();
|
|
2752
2756
|
},
|
|
2753
|
-
drop:
|
|
2754
|
-
},
|
|
2757
|
+
drop: _a
|
|
2758
|
+
}, tr(Zr, { pluginName: "revertOnSpill" }), Qr.prototype = {
|
|
2755
2759
|
onSpill: function(e) {
|
|
2756
2760
|
var t = e.dragEl, n = e.putSortable || this.sortable;
|
|
2757
2761
|
n.captureAnimationState(), t.parentNode && t.parentNode.removeChild(t), n.animateAll();
|
|
2758
2762
|
},
|
|
2759
|
-
drop:
|
|
2760
|
-
},
|
|
2761
|
-
})),
|
|
2763
|
+
drop: _a
|
|
2764
|
+
}, tr(Qr, { pluginName: "removeOnSpill" }), Q = [], ya = [], Sa = !1, Ca = !1, wa = !1, K.mount(new Jr()), K.mount(Qr, Zr);
|
|
2765
|
+
})), Oa = /* @__PURE__ */ at(((e, t) => {
|
|
2762
2766
|
(function(n, r) {
|
|
2763
|
-
typeof e == "object" && typeof t == "object" ? t.exports = r(
|
|
2767
|
+
typeof e == "object" && typeof t == "object" ? t.exports = r(ut("vue"), (Da(), lt(Xn))) : typeof define == "function" && define.amd ? define([, "sortablejs"], r) : typeof e == "object" ? e.vuedraggable = r(ut("vue"), (Da(), lt(Xn))) : n.vuedraggable = r(n.Vue, n.Sortable);
|
|
2764
2768
|
})(typeof self < "u" ? self : e, function(e, t) {
|
|
2765
2769
|
return (function(e) {
|
|
2766
2770
|
var t = {};
|
|
@@ -3180,18 +3184,18 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
3180
3184
|
if (C === null || (S.push(C), !h)) break;
|
|
3181
3185
|
String(C[0]) === "" && (c.lastIndex = l(p, o(c.lastIndex), x));
|
|
3182
3186
|
}
|
|
3183
|
-
for (var
|
|
3184
|
-
C = S[
|
|
3185
|
-
for (var
|
|
3186
|
-
var
|
|
3187
|
+
for (var w = "", T = 0, E = 0; E < S.length; E++) {
|
|
3188
|
+
C = S[E];
|
|
3189
|
+
for (var D = String(C[0]), O = d(f(s(C.index), p.length), 0), ee = [], k = 1; k < C.length; k++) ee.push(g(C[k]));
|
|
3190
|
+
var te = C.groups;
|
|
3187
3191
|
if (m) {
|
|
3188
|
-
var
|
|
3189
|
-
|
|
3190
|
-
var
|
|
3191
|
-
} else
|
|
3192
|
-
|
|
3192
|
+
var ne = [D].concat(ee, O, p);
|
|
3193
|
+
te !== void 0 && ne.push(te);
|
|
3194
|
+
var re = String(r.apply(void 0, ne));
|
|
3195
|
+
} else re = b(D, p, O, ee, te, r);
|
|
3196
|
+
O >= T && (w += p.slice(T, O) + re, T = O + D.length);
|
|
3193
3197
|
}
|
|
3194
|
-
return
|
|
3198
|
+
return w + p.slice(T);
|
|
3195
3199
|
}];
|
|
3196
3200
|
function b(e, n, r, i, o, s) {
|
|
3197
3201
|
var c = r + e.length, l = i.length, u = h;
|
|
@@ -3404,8 +3408,8 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
3404
3408
|
e.exports = function(e, t, n, u, p, x, S) {
|
|
3405
3409
|
i(n, t, u);
|
|
3406
3410
|
var C = function(e) {
|
|
3407
|
-
if (e === p &&
|
|
3408
|
-
if (!h && e in
|
|
3411
|
+
if (e === p && O) return O;
|
|
3412
|
+
if (!h && e in E) return E[e];
|
|
3409
3413
|
switch (e) {
|
|
3410
3414
|
case _: return function() {
|
|
3411
3415
|
return new n(this, e);
|
|
@@ -3420,20 +3424,20 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
3420
3424
|
return function() {
|
|
3421
3425
|
return new n(this);
|
|
3422
3426
|
};
|
|
3423
|
-
},
|
|
3424
|
-
if (
|
|
3425
|
-
return
|
|
3426
|
-
}), (!d || S) &&
|
|
3427
|
+
}, w = t + " Iterator", T = !1, E = e.prototype, D = E[g] || E["@@iterator"] || p && E[p], O = !h && D || C(p), ee = t == "Array" && E.entries || D, k, te, ne;
|
|
3428
|
+
if (ee && (k = a(ee.call(new e())), m !== Object.prototype && k.next && (!d && a(k) !== m && (o ? o(k, m) : typeof k[g] != "function" && c(k, g, b)), s(k, w, !0, !0), d && (f[w] = b))), p == v && D && D.name !== v && (T = !0, O = function() {
|
|
3429
|
+
return D.call(this);
|
|
3430
|
+
}), (!d || S) && E[g] !== O && c(E, g, O), f[t] = O, p) if (te = {
|
|
3427
3431
|
values: C(v),
|
|
3428
|
-
keys: x ?
|
|
3432
|
+
keys: x ? O : C(_),
|
|
3429
3433
|
entries: C(y)
|
|
3430
|
-
}, S) for (
|
|
3434
|
+
}, S) for (ne in te) (h || T || !(ne in E)) && l(E, ne, te[ne]);
|
|
3431
3435
|
else r({
|
|
3432
3436
|
target: t,
|
|
3433
3437
|
proto: !0,
|
|
3434
|
-
forced: h ||
|
|
3435
|
-
},
|
|
3436
|
-
return
|
|
3438
|
+
forced: h || T
|
|
3439
|
+
}, te);
|
|
3440
|
+
return te;
|
|
3437
3441
|
};
|
|
3438
3442
|
}),
|
|
3439
3443
|
"7f9a": (function(e, t, n) {
|
|
@@ -3647,92 +3651,92 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
3647
3651
|
} });
|
|
3648
3652
|
}),
|
|
3649
3653
|
a4d3: (function(e, t, n) {
|
|
3650
|
-
var r = n("23e7"), i = n("da84"), a = n("d066"), o = n("c430"), s = n("83ab"), c = n("4930"), l = n("fdbf"), u = n("d039"), d = n("5135"), f = n("e8b5"), p = n("861d"), m = n("825a"), h = n("7b0b"), g = n("fc6a"), _ = n("c04e"), v = n("5c6c"), y = n("7c73"), b = n("df75"), x = n("241c"), S = n("057f"), C = n("7418"),
|
|
3651
|
-
return y(
|
|
3652
|
-
return
|
|
3654
|
+
var r = n("23e7"), i = n("da84"), a = n("d066"), o = n("c430"), s = n("83ab"), c = n("4930"), l = n("fdbf"), u = n("d039"), d = n("5135"), f = n("e8b5"), p = n("861d"), m = n("825a"), h = n("7b0b"), g = n("fc6a"), _ = n("c04e"), v = n("5c6c"), y = n("7c73"), b = n("df75"), x = n("241c"), S = n("057f"), C = n("7418"), w = n("06cf"), T = n("9bf2"), E = n("d1e7"), D = n("9112"), O = n("6eeb"), ee = n("5692"), k = n("f772"), te = n("d012"), ne = n("90e3"), re = n("b622"), ie = n("e538"), A = n("746f"), ae = n("d44e"), oe = n("69f3"), j = n("b727").forEach, M = k("hidden"), se = "Symbol", N = "prototype", ce = re("toPrimitive"), le = oe.set, ue = oe.getterFor(se), de = Object[N], fe = i.Symbol, P = a("JSON", "stringify"), pe = w.f, me = T.f, he = S.f, F = E.f, I = ee("symbols"), L = ee("op-symbols"), ge = ee("string-to-symbol-registry"), _e = ee("symbol-to-string-registry"), ve = ee("wks"), ye = i.QObject, R = !ye || !ye[N] || !ye[N].findChild, be = s && u(function() {
|
|
3655
|
+
return y(me({}, "a", { get: function() {
|
|
3656
|
+
return me(this, "a", { value: 7 }).a;
|
|
3653
3657
|
} })).a != 7;
|
|
3654
3658
|
}) ? function(e, t, n) {
|
|
3655
|
-
var r =
|
|
3656
|
-
r && delete
|
|
3657
|
-
} :
|
|
3658
|
-
var n =
|
|
3659
|
-
return
|
|
3660
|
-
type:
|
|
3659
|
+
var r = pe(de, t);
|
|
3660
|
+
r && delete de[t], me(e, t, n), r && e !== de && me(de, t, r);
|
|
3661
|
+
} : me, z = function(e, t) {
|
|
3662
|
+
var n = I[e] = y(fe[N]);
|
|
3663
|
+
return le(n, {
|
|
3664
|
+
type: se,
|
|
3661
3665
|
tag: e,
|
|
3662
3666
|
description: t
|
|
3663
3667
|
}), s || (n.description = t), n;
|
|
3664
3668
|
}, xe = l ? function(e) {
|
|
3665
3669
|
return typeof e == "symbol";
|
|
3666
3670
|
} : function(e) {
|
|
3667
|
-
return Object(e) instanceof
|
|
3671
|
+
return Object(e) instanceof fe;
|
|
3668
3672
|
}, Se = function(e, t, n) {
|
|
3669
|
-
e ===
|
|
3673
|
+
e === de && Se(L, t, n), m(e);
|
|
3670
3674
|
var r = _(t, !0);
|
|
3671
|
-
return m(n), d(
|
|
3675
|
+
return m(n), d(I, r) ? (n.enumerable ? (d(e, M) && e[M][r] && (e[M][r] = !1), n = y(n, { enumerable: v(0, !1) })) : (d(e, M) || me(e, M, v(1, {})), e[M][r] = !0), be(e, r, n)) : me(e, r, n);
|
|
3672
3676
|
}, Ce = function(e, t) {
|
|
3673
3677
|
m(e);
|
|
3674
3678
|
var n = g(t);
|
|
3675
|
-
return
|
|
3679
|
+
return j(b(n).concat(Oe(n)), function(t) {
|
|
3676
3680
|
(!s || Te.call(n, t)) && Se(e, t, n[t]);
|
|
3677
3681
|
}), e;
|
|
3678
3682
|
}, we = function(e, t) {
|
|
3679
3683
|
return t === void 0 ? y(e) : Ce(y(e), t);
|
|
3680
3684
|
}, Te = function(e) {
|
|
3681
|
-
var t = _(e, !0), n =
|
|
3682
|
-
return this ===
|
|
3685
|
+
var t = _(e, !0), n = F.call(this, t);
|
|
3686
|
+
return this === de && d(I, t) && !d(L, t) ? !1 : n || !d(this, t) || !d(I, t) || d(this, M) && this[M][t] ? n : !0;
|
|
3683
3687
|
}, Ee = function(e, t) {
|
|
3684
3688
|
var n = g(e), r = _(t, !0);
|
|
3685
|
-
if (!(n ===
|
|
3686
|
-
var i =
|
|
3687
|
-
return i && d(
|
|
3689
|
+
if (!(n === de && d(I, r) && !d(L, r))) {
|
|
3690
|
+
var i = pe(n, r);
|
|
3691
|
+
return i && d(I, r) && !(d(n, M) && n[M][r]) && (i.enumerable = !0), i;
|
|
3688
3692
|
}
|
|
3689
3693
|
}, De = function(e) {
|
|
3690
|
-
var t =
|
|
3691
|
-
return
|
|
3692
|
-
!d(
|
|
3694
|
+
var t = he(g(e)), n = [];
|
|
3695
|
+
return j(t, function(e) {
|
|
3696
|
+
!d(I, e) && !d(te, e) && n.push(e);
|
|
3693
3697
|
}), n;
|
|
3694
3698
|
}, Oe = function(e) {
|
|
3695
|
-
var t = e ===
|
|
3696
|
-
return
|
|
3697
|
-
d(
|
|
3699
|
+
var t = e === de, n = he(t ? L : g(e)), r = [];
|
|
3700
|
+
return j(n, function(e) {
|
|
3701
|
+
d(I, e) && (!t || d(de, e)) && r.push(I[e]);
|
|
3698
3702
|
}), r;
|
|
3699
3703
|
};
|
|
3700
|
-
c || (
|
|
3701
|
-
if (this instanceof
|
|
3702
|
-
var e = !arguments.length || arguments[0] === void 0 ? void 0 : String(arguments[0]), t =
|
|
3703
|
-
this ===
|
|
3704
|
+
c || (fe = function() {
|
|
3705
|
+
if (this instanceof fe) throw TypeError("Symbol is not a constructor");
|
|
3706
|
+
var e = !arguments.length || arguments[0] === void 0 ? void 0 : String(arguments[0]), t = ne(e), n = function(e) {
|
|
3707
|
+
this === de && n.call(L, e), d(this, M) && d(this[M], t) && (this[M][t] = !1), be(this, t, v(1, e));
|
|
3704
3708
|
};
|
|
3705
|
-
return s &&
|
|
3709
|
+
return s && R && be(de, t, {
|
|
3706
3710
|
configurable: !0,
|
|
3707
3711
|
set: n
|
|
3708
|
-
}),
|
|
3709
|
-
},
|
|
3710
|
-
return
|
|
3711
|
-
}),
|
|
3712
|
-
return
|
|
3713
|
-
}),
|
|
3714
|
-
return
|
|
3715
|
-
}, s && (
|
|
3712
|
+
}), z(t, e);
|
|
3713
|
+
}, O(fe[N], "toString", function() {
|
|
3714
|
+
return ue(this).tag;
|
|
3715
|
+
}), O(fe, "withoutSetter", function(e) {
|
|
3716
|
+
return z(ne(e), e);
|
|
3717
|
+
}), E.f = Te, T.f = Se, w.f = Ee, x.f = S.f = De, C.f = Oe, ie.f = function(e) {
|
|
3718
|
+
return z(re(e), e);
|
|
3719
|
+
}, s && (me(fe[N], "description", {
|
|
3716
3720
|
configurable: !0,
|
|
3717
3721
|
get: function() {
|
|
3718
|
-
return
|
|
3722
|
+
return ue(this).description;
|
|
3719
3723
|
}
|
|
3720
|
-
}), o ||
|
|
3724
|
+
}), o || O(de, "propertyIsEnumerable", Te, { unsafe: !0 }))), r({
|
|
3721
3725
|
global: !0,
|
|
3722
3726
|
wrap: !0,
|
|
3723
3727
|
forced: !c,
|
|
3724
3728
|
sham: !c
|
|
3725
|
-
}, { Symbol:
|
|
3726
|
-
|
|
3729
|
+
}, { Symbol: fe }), j(b(ve), function(e) {
|
|
3730
|
+
A(e);
|
|
3727
3731
|
}), r({
|
|
3728
|
-
target:
|
|
3732
|
+
target: se,
|
|
3729
3733
|
stat: !0,
|
|
3730
3734
|
forced: !c
|
|
3731
3735
|
}, {
|
|
3732
3736
|
for: function(e) {
|
|
3733
3737
|
var t = String(e);
|
|
3734
3738
|
if (d(ge, t)) return ge[t];
|
|
3735
|
-
var n =
|
|
3739
|
+
var n = fe(t);
|
|
3736
3740
|
return ge[t] = n, _e[n] = t, n;
|
|
3737
3741
|
},
|
|
3738
3742
|
keyFor: function(e) {
|
|
@@ -3740,10 +3744,10 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
3740
3744
|
if (d(_e, e)) return _e[e];
|
|
3741
3745
|
},
|
|
3742
3746
|
useSetter: function() {
|
|
3743
|
-
|
|
3747
|
+
R = !0;
|
|
3744
3748
|
},
|
|
3745
3749
|
useSimple: function() {
|
|
3746
|
-
|
|
3750
|
+
R = !1;
|
|
3747
3751
|
}
|
|
3748
3752
|
}), r({
|
|
3749
3753
|
target: "Object",
|
|
@@ -3770,19 +3774,19 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
3770
3774
|
})
|
|
3771
3775
|
}, { getOwnPropertySymbols: function(e) {
|
|
3772
3776
|
return C.f(h(e));
|
|
3773
|
-
} }),
|
|
3777
|
+
} }), P && r({
|
|
3774
3778
|
target: "JSON",
|
|
3775
3779
|
stat: !0,
|
|
3776
3780
|
forced: !c || u(function() {
|
|
3777
|
-
var e =
|
|
3778
|
-
return
|
|
3781
|
+
var e = fe();
|
|
3782
|
+
return P([e]) != "[null]" || P({ a: e }) != "{}" || P(Object(e)) != "{}";
|
|
3779
3783
|
})
|
|
3780
3784
|
}, { stringify: function(e, t, n) {
|
|
3781
3785
|
for (var r = [e], i = 1, a; arguments.length > i;) r.push(arguments[i++]);
|
|
3782
3786
|
if (a = t, !(!p(t) && e === void 0 || xe(e))) return f(t) || (t = function(e, t) {
|
|
3783
3787
|
if (typeof a == "function" && (t = a.call(this, e, t)), !xe(t)) return t;
|
|
3784
|
-
}), r[1] = t,
|
|
3785
|
-
} }),
|
|
3788
|
+
}), r[1] = t, P.apply(null, r);
|
|
3789
|
+
} }), fe[N][ce] || D(fe[N], ce, fe[N].valueOf), ae(fe, se), te[M] = !0;
|
|
3786
3790
|
}),
|
|
3787
3791
|
a630: (function(e, t, n) {
|
|
3788
3792
|
var r = n("23e7"), i = n("4df4");
|
|
@@ -3908,13 +3912,13 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
3908
3912
|
var r = n("0366"), i = n("44ad"), a = n("7b0b"), o = n("50c4"), s = n("65f0"), c = [].push, l = function(e) {
|
|
3909
3913
|
var t = e == 1, n = e == 2, l = e == 3, u = e == 4, d = e == 6, f = e == 5 || d;
|
|
3910
3914
|
return function(p, m, h, g) {
|
|
3911
|
-
for (var _ = a(p), v = i(_), y = r(m, h, 3), b = o(v.length), x = 0, S = g || s, C = t ? S(p, b) : n ? S(p, 0) : void 0,
|
|
3912
|
-
if (t) C[x] =
|
|
3913
|
-
else if (
|
|
3915
|
+
for (var _ = a(p), v = i(_), y = r(m, h, 3), b = o(v.length), x = 0, S = g || s, C = t ? S(p, b) : n ? S(p, 0) : void 0, w, T; b > x; x++) if ((f || x in v) && (w = v[x], T = y(w, x, _), e)) {
|
|
3916
|
+
if (t) C[x] = T;
|
|
3917
|
+
else if (T) switch (e) {
|
|
3914
3918
|
case 3: return !0;
|
|
3915
|
-
case 5: return
|
|
3919
|
+
case 5: return w;
|
|
3916
3920
|
case 6: return x;
|
|
3917
|
-
case 2: c.call(C,
|
|
3921
|
+
case 2: c.call(C, w);
|
|
3918
3922
|
}
|
|
3919
3923
|
else if (u) return !1;
|
|
3920
3924
|
}
|
|
@@ -4445,52 +4449,52 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4445
4449
|
}
|
|
4446
4450
|
var C = n("dbf1");
|
|
4447
4451
|
n("13d5"), n("4fad"), n("ac1f"), n("5319");
|
|
4448
|
-
function
|
|
4452
|
+
function w(e) {
|
|
4449
4453
|
var t = Object.create(null);
|
|
4450
4454
|
return function(n) {
|
|
4451
4455
|
return t[n] || (t[n] = e(n));
|
|
4452
4456
|
};
|
|
4453
4457
|
}
|
|
4454
|
-
var
|
|
4455
|
-
return e.replace(
|
|
4458
|
+
var T = /-(\w)/g, E = w(function(e) {
|
|
4459
|
+
return e.replace(T, function(e, t) {
|
|
4456
4460
|
return t.toUpperCase();
|
|
4457
4461
|
});
|
|
4458
4462
|
});
|
|
4459
4463
|
n("5db7"), n("73d9");
|
|
4460
|
-
var
|
|
4464
|
+
var D = [
|
|
4461
4465
|
"Start",
|
|
4462
4466
|
"Add",
|
|
4463
4467
|
"Remove",
|
|
4464
4468
|
"Update",
|
|
4465
4469
|
"End"
|
|
4466
|
-
],
|
|
4470
|
+
], O = [
|
|
4467
4471
|
"Choose",
|
|
4468
4472
|
"Unchoose",
|
|
4469
4473
|
"Sort",
|
|
4470
4474
|
"Filter",
|
|
4471
4475
|
"Clone"
|
|
4472
|
-
],
|
|
4473
|
-
|
|
4474
|
-
|
|
4475
|
-
|
|
4476
|
+
], ee = ["Move"], k = [
|
|
4477
|
+
ee,
|
|
4478
|
+
D,
|
|
4479
|
+
O
|
|
4476
4480
|
].flatMap(function(e) {
|
|
4477
4481
|
return e;
|
|
4478
4482
|
}).map(function(e) {
|
|
4479
4483
|
return `on${e}`;
|
|
4480
|
-
}),
|
|
4481
|
-
manage:
|
|
4482
|
-
manageAndEmit:
|
|
4483
|
-
emit:
|
|
4484
|
+
}), te = {
|
|
4485
|
+
manage: ee,
|
|
4486
|
+
manageAndEmit: D,
|
|
4487
|
+
emit: O
|
|
4484
4488
|
};
|
|
4485
|
-
function
|
|
4486
|
-
return
|
|
4489
|
+
function ne(e) {
|
|
4490
|
+
return k.indexOf(e) !== -1;
|
|
4487
4491
|
}
|
|
4488
4492
|
n("caad"), n("2ca0");
|
|
4489
|
-
var
|
|
4490
|
-
function A(e) {
|
|
4491
|
-
return k.includes(e);
|
|
4492
|
-
}
|
|
4493
|
+
var re = /* @__PURE__ */ "a.abbr.address.area.article.aside.audio.b.base.bdi.bdo.blockquote.body.br.button.canvas.caption.cite.code.col.colgroup.data.datalist.dd.del.details.dfn.dialog.div.dl.dt.em.embed.fieldset.figcaption.figure.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.iframe.img.input.ins.kbd.label.legend.li.link.main.map.mark.math.menu.menuitem.meta.meter.nav.noscript.object.ol.optgroup.option.output.p.param.picture.pre.progress.q.rb.rp.rt.rtc.ruby.s.samp.script.section.select.slot.small.source.span.strong.style.sub.summary.sup.svg.table.tbody.td.template.textarea.tfoot.th.thead.time.title.tr.track.u.ul.var.video.wbr".split(".");
|
|
4493
4494
|
function ie(e) {
|
|
4495
|
+
return re.includes(e);
|
|
4496
|
+
}
|
|
4497
|
+
function A(e) {
|
|
4494
4498
|
return ["transition-group", "TransitionGroup"].includes(e);
|
|
4495
4499
|
}
|
|
4496
4500
|
function ae(e) {
|
|
@@ -4501,67 +4505,67 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4501
4505
|
"style"
|
|
4502
4506
|
].includes(e) || e.startsWith("data-") || e.startsWith("aria-") || e.startsWith("on");
|
|
4503
4507
|
}
|
|
4504
|
-
function
|
|
4508
|
+
function oe(e) {
|
|
4505
4509
|
return e.reduce(function(e, t) {
|
|
4506
4510
|
var n = m(t, 2), r = n[0];
|
|
4507
4511
|
return e[r] = n[1], e;
|
|
4508
4512
|
}, {});
|
|
4509
4513
|
}
|
|
4510
|
-
function
|
|
4514
|
+
function j(e) {
|
|
4511
4515
|
var t = e.$attrs, n = e.componentData, r = n === void 0 ? {} : n;
|
|
4512
|
-
return c(c({},
|
|
4516
|
+
return c(c({}, oe(Object.entries(t).filter(function(e) {
|
|
4513
4517
|
var t = m(e, 2), n = t[0];
|
|
4514
4518
|
return t[1], ae(n);
|
|
4515
4519
|
}))), r);
|
|
4516
4520
|
}
|
|
4517
|
-
function
|
|
4518
|
-
var t = e.$attrs, n = e.callBackBuilder, r =
|
|
4521
|
+
function M(e) {
|
|
4522
|
+
var t = e.$attrs, n = e.callBackBuilder, r = oe(se(t));
|
|
4519
4523
|
Object.entries(n).forEach(function(e) {
|
|
4520
4524
|
var t = m(e, 2), n = t[0], i = t[1];
|
|
4521
|
-
|
|
4525
|
+
te[n].forEach(function(e) {
|
|
4522
4526
|
r[`on${e}`] = i(e);
|
|
4523
4527
|
});
|
|
4524
4528
|
});
|
|
4525
4529
|
var i = `[data-draggable]${r.draggable || ""}`;
|
|
4526
4530
|
return c(c({}, r), {}, { draggable: i });
|
|
4527
4531
|
}
|
|
4528
|
-
function
|
|
4532
|
+
function se(e) {
|
|
4529
4533
|
return Object.entries(e).filter(function(e) {
|
|
4530
4534
|
var t = m(e, 2), n = t[0];
|
|
4531
4535
|
return t[1], !ae(n);
|
|
4532
4536
|
}).map(function(e) {
|
|
4533
4537
|
var t = m(e, 2), n = t[0], r = t[1];
|
|
4534
|
-
return [
|
|
4538
|
+
return [E(n), r];
|
|
4535
4539
|
}).filter(function(e) {
|
|
4536
4540
|
var t = m(e, 2), n = t[0];
|
|
4537
|
-
return t[1], !
|
|
4541
|
+
return t[1], !ne(n);
|
|
4538
4542
|
});
|
|
4539
4543
|
}
|
|
4540
4544
|
n("c740");
|
|
4541
|
-
function
|
|
4545
|
+
function N(e, t) {
|
|
4542
4546
|
if (!(e instanceof t)) throw TypeError("Cannot call a class as a function");
|
|
4543
4547
|
}
|
|
4544
|
-
function
|
|
4548
|
+
function ce(e, t) {
|
|
4545
4549
|
for (var n = 0; n < t.length; n++) {
|
|
4546
4550
|
var r = t[n];
|
|
4547
4551
|
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r);
|
|
4548
4552
|
}
|
|
4549
4553
|
}
|
|
4550
|
-
function
|
|
4551
|
-
return t &&
|
|
4554
|
+
function le(e, t, n) {
|
|
4555
|
+
return t && ce(e.prototype, t), n && ce(e, n), e;
|
|
4552
4556
|
}
|
|
4553
|
-
var
|
|
4557
|
+
var ue = function(e) {
|
|
4554
4558
|
return e.el;
|
|
4555
|
-
},
|
|
4559
|
+
}, de = function(e, t) {
|
|
4556
4560
|
return e.__draggable_context = t;
|
|
4557
|
-
},
|
|
4561
|
+
}, fe = function(e) {
|
|
4558
4562
|
return e.__draggable_context;
|
|
4559
|
-
},
|
|
4563
|
+
}, P = /* @__PURE__ */ function() {
|
|
4560
4564
|
function e(t) {
|
|
4561
4565
|
var n = t.nodes, r = n.header, i = n.default, a = n.footer, o = t.root, s = t.realList;
|
|
4562
|
-
|
|
4566
|
+
N(this, e), this.defaultNodes = i, this.children = [].concat(v(r), v(i), v(a)), this.externalComponent = o.externalComponent, this.rootTransition = o.transition, this.tag = o.tag, this.realList = s;
|
|
4563
4567
|
}
|
|
4564
|
-
return
|
|
4568
|
+
return le(e, [
|
|
4565
4569
|
{
|
|
4566
4570
|
key: "render",
|
|
4567
4571
|
value: function(e, t) {
|
|
@@ -4576,7 +4580,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4576
4580
|
value: function() {
|
|
4577
4581
|
var e = this.defaultNodes, t = this.realList;
|
|
4578
4582
|
e.forEach(function(e, n) {
|
|
4579
|
-
ue(
|
|
4583
|
+
de(ue(e), {
|
|
4580
4584
|
element: t[n],
|
|
4581
4585
|
index: n
|
|
4582
4586
|
});
|
|
@@ -4586,7 +4590,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4586
4590
|
{
|
|
4587
4591
|
key: "getUnderlyingVm",
|
|
4588
4592
|
value: function(e) {
|
|
4589
|
-
return
|
|
4593
|
+
return fe(e);
|
|
4590
4594
|
}
|
|
4591
4595
|
},
|
|
4592
4596
|
{
|
|
@@ -4594,10 +4598,10 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4594
4598
|
value: function(e, t) {
|
|
4595
4599
|
var n = this.defaultNodes, r = n.length, i = t.children, a = i.item(e);
|
|
4596
4600
|
if (a === null) return r;
|
|
4597
|
-
var o =
|
|
4601
|
+
var o = fe(a);
|
|
4598
4602
|
if (o) return o.index;
|
|
4599
4603
|
if (r === 0) return 0;
|
|
4600
|
-
var s =
|
|
4604
|
+
var s = ue(n[0]);
|
|
4601
4605
|
return e < v(i).findIndex(function(e) {
|
|
4602
4606
|
return e === s;
|
|
4603
4607
|
}) ? 0 : r;
|
|
@@ -4610,14 +4614,14 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4610
4614
|
}
|
|
4611
4615
|
}
|
|
4612
4616
|
]), e;
|
|
4613
|
-
}(),
|
|
4614
|
-
function
|
|
4617
|
+
}(), pe = n("8bbf");
|
|
4618
|
+
function me(e, t) {
|
|
4615
4619
|
var n = e[t];
|
|
4616
4620
|
return n ? n() : [];
|
|
4617
4621
|
}
|
|
4618
|
-
function
|
|
4622
|
+
function he(e) {
|
|
4619
4623
|
var t = e.$slots, n = e.realList, r = e.getKey, i = n || [], a = m(["header", "footer"].map(function(e) {
|
|
4620
|
-
return
|
|
4624
|
+
return me(t, e);
|
|
4621
4625
|
}), 2), o = a[0], s = a[1], l = t.item;
|
|
4622
4626
|
if (!l) throw Error("draggable element must have an item slot");
|
|
4623
4627
|
var u = i.flatMap(function(e, t) {
|
|
@@ -4635,29 +4639,29 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4635
4639
|
default: u
|
|
4636
4640
|
};
|
|
4637
4641
|
}
|
|
4638
|
-
function
|
|
4639
|
-
var t =
|
|
4642
|
+
function F(e) {
|
|
4643
|
+
var t = A(e), n = !ie(e) && !t;
|
|
4640
4644
|
return {
|
|
4641
4645
|
transition: t,
|
|
4642
4646
|
externalComponent: n,
|
|
4643
|
-
tag: n ? (0,
|
|
4647
|
+
tag: n ? (0, pe.resolveComponent)(e) : t ? pe.TransitionGroup : e
|
|
4644
4648
|
};
|
|
4645
4649
|
}
|
|
4646
|
-
function
|
|
4650
|
+
function I(e) {
|
|
4647
4651
|
var t = e.$slots, n = e.tag, r = e.realList, i = e.getKey;
|
|
4648
|
-
return new
|
|
4649
|
-
nodes:
|
|
4652
|
+
return new P({
|
|
4653
|
+
nodes: he({
|
|
4650
4654
|
$slots: t,
|
|
4651
4655
|
realList: r,
|
|
4652
4656
|
getKey: i
|
|
4653
4657
|
}),
|
|
4654
|
-
root:
|
|
4658
|
+
root: F(n),
|
|
4655
4659
|
realList: r
|
|
4656
4660
|
});
|
|
4657
4661
|
}
|
|
4658
|
-
function
|
|
4662
|
+
function L(e, t) {
|
|
4659
4663
|
var n = this;
|
|
4660
|
-
(0,
|
|
4664
|
+
(0, pe.nextTick)(function() {
|
|
4661
4665
|
return n.$emit(e.toLowerCase(), t);
|
|
4662
4666
|
});
|
|
4663
4667
|
}
|
|
@@ -4670,10 +4674,10 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4670
4674
|
function _e(e) {
|
|
4671
4675
|
var t = this, n = ge.call(this, e);
|
|
4672
4676
|
return function(r, i) {
|
|
4673
|
-
n.call(t, r, i),
|
|
4677
|
+
n.call(t, r, i), L.call(t, e, r);
|
|
4674
4678
|
};
|
|
4675
4679
|
}
|
|
4676
|
-
var ve = null,
|
|
4680
|
+
var ve = null, ye = {
|
|
4677
4681
|
list: {
|
|
4678
4682
|
type: Array,
|
|
4679
4683
|
required: !1,
|
|
@@ -4707,34 +4711,34 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4707
4711
|
required: !1,
|
|
4708
4712
|
default: null
|
|
4709
4713
|
}
|
|
4710
|
-
},
|
|
4714
|
+
}, R = ["update:modelValue", "change"].concat(v([].concat(v(te.manageAndEmit), v(te.emit)).map(function(e) {
|
|
4711
4715
|
return e.toLowerCase();
|
|
4712
4716
|
})));
|
|
4713
|
-
t.default = (0,
|
|
4717
|
+
t.default = (0, pe.defineComponent)({
|
|
4714
4718
|
name: "draggable",
|
|
4715
4719
|
inheritAttrs: !1,
|
|
4716
|
-
props:
|
|
4717
|
-
emits:
|
|
4720
|
+
props: ye,
|
|
4721
|
+
emits: R,
|
|
4718
4722
|
data: function() {
|
|
4719
4723
|
return { error: !1 };
|
|
4720
4724
|
},
|
|
4721
4725
|
render: function() {
|
|
4722
4726
|
try {
|
|
4723
4727
|
this.error = !1;
|
|
4724
|
-
var e = this.$slots, t = this.$attrs, n = this.tag, r = this.componentData, i = this.realList, a = this.getKey, o =
|
|
4728
|
+
var e = this.$slots, t = this.$attrs, n = this.tag, r = this.componentData, i = this.realList, a = this.getKey, o = I({
|
|
4725
4729
|
$slots: e,
|
|
4726
4730
|
tag: n,
|
|
4727
4731
|
realList: i,
|
|
4728
4732
|
getKey: a
|
|
4729
4733
|
});
|
|
4730
4734
|
this.componentStructure = o;
|
|
4731
|
-
var s =
|
|
4735
|
+
var s = j({
|
|
4732
4736
|
$attrs: t,
|
|
4733
4737
|
componentData: r
|
|
4734
4738
|
});
|
|
4735
|
-
return o.render(
|
|
4739
|
+
return o.render(pe.h, s);
|
|
4736
4740
|
} catch (e) {
|
|
4737
|
-
return this.error = !0, (0,
|
|
4741
|
+
return this.error = !0, (0, pe.h)("pre", { style: { color: "red" } }, e.stack);
|
|
4738
4742
|
}
|
|
4739
4743
|
},
|
|
4740
4744
|
created: function() {
|
|
@@ -4745,14 +4749,14 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4745
4749
|
if (!this.error) {
|
|
4746
4750
|
var t = this.$attrs, n = this.$el;
|
|
4747
4751
|
this.componentStructure.updated();
|
|
4748
|
-
var r =
|
|
4752
|
+
var r = M({
|
|
4749
4753
|
$attrs: t,
|
|
4750
4754
|
callBackBuilder: {
|
|
4751
4755
|
manageAndEmit: function(t) {
|
|
4752
4756
|
return _e.call(e, t);
|
|
4753
4757
|
},
|
|
4754
4758
|
emit: function(t) {
|
|
4755
|
-
return
|
|
4759
|
+
return L.bind(e, t);
|
|
4756
4760
|
},
|
|
4757
4761
|
manage: function(t) {
|
|
4758
4762
|
return ge.call(e, t);
|
|
@@ -4782,7 +4786,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4782
4786
|
watch: { $attrs: {
|
|
4783
4787
|
handler: function(e) {
|
|
4784
4788
|
var t = this._sortable;
|
|
4785
|
-
t &&
|
|
4789
|
+
t && se(e).forEach(function(e) {
|
|
4786
4790
|
var n = m(e, 2), r = n[0], i = n[1];
|
|
4787
4791
|
t.option(r, i);
|
|
4788
4792
|
});
|
|
@@ -4798,7 +4802,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4798
4802
|
},
|
|
4799
4803
|
emitChanges: function(e) {
|
|
4800
4804
|
var t = this;
|
|
4801
|
-
(0,
|
|
4805
|
+
(0, pe.nextTick)(function() {
|
|
4802
4806
|
return t.$emit("change", e);
|
|
4803
4807
|
});
|
|
4804
4808
|
},
|
|
@@ -4958,10 +4962,10 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4958
4962
|
})
|
|
4959
4963
|
}).default;
|
|
4960
4964
|
});
|
|
4961
|
-
})),
|
|
4965
|
+
})), ka = /* @__PURE__ */ ct(Oa(), 1), Aa = { class: "tpl:w-full" }, ja = { class: "tpl:flex tpl:gap-0" }, Ma = {
|
|
4962
4966
|
key: 0,
|
|
4963
4967
|
class: "tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:flex tpl:items-center tpl:justify-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]"
|
|
4964
|
-
},
|
|
4968
|
+
}, Na = /* @__PURE__ */ le({
|
|
4965
4969
|
__name: "SectionBlock",
|
|
4966
4970
|
props: {
|
|
4967
4971
|
block: {},
|
|
@@ -4969,13 +4973,13 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
4969
4973
|
},
|
|
4970
4974
|
setup(e) {
|
|
4971
4975
|
let t = {
|
|
4972
|
-
title:
|
|
4973
|
-
paragraph:
|
|
4974
|
-
image:
|
|
4975
|
-
button:
|
|
4976
|
-
divider:
|
|
4977
|
-
custom:
|
|
4978
|
-
}, n = e, { t: r } =
|
|
4976
|
+
title: Yn,
|
|
4977
|
+
paragraph: Mn,
|
|
4978
|
+
image: Tn,
|
|
4979
|
+
button: xt,
|
|
4980
|
+
divider: ln,
|
|
4981
|
+
custom: sn
|
|
4982
|
+
}, n = e, { t: r } = E(), i = w(f, "SectionBlock"), a = de(g, null), o = de(y, null), s = A(() => {
|
|
4979
4983
|
switch (n.block.columns) {
|
|
4980
4984
|
case "2": return ["50%", "50%"];
|
|
4981
4985
|
case "3": return [
|
|
@@ -5001,7 +5005,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5001
5005
|
r[e] = t, i.updateBlock(n.block.id, { children: r });
|
|
5002
5006
|
}
|
|
5003
5007
|
function d(e) {
|
|
5004
|
-
return
|
|
5008
|
+
return Nn(e, o, t);
|
|
5005
5009
|
}
|
|
5006
5010
|
function p(e, t) {
|
|
5007
5011
|
e.type === "custom" && i.updateBlock(e.id, {
|
|
@@ -5009,11 +5013,11 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5009
5013
|
dataSourceFetched: t.dataSourceFetched
|
|
5010
5014
|
});
|
|
5011
5015
|
}
|
|
5012
|
-
return (t, n) => (
|
|
5016
|
+
return (t, n) => (F(), j("div", Aa, [M("div", ja, [(F(!0), j(ie, null, ge(c.value, (t, n) => (F(), j("div", {
|
|
5013
5017
|
key: n,
|
|
5014
|
-
class:
|
|
5015
|
-
style:
|
|
5016
|
-
}, [N(z(
|
|
5018
|
+
class: fe(["tpl:relative tpl:min-h-[60px] tpl:rounded", l(n).length === 0 ? "tpl:border tpl:border-dashed tpl:border-[var(--tpl-border)]" : ""]),
|
|
5019
|
+
style: P({ width: s.value[n] })
|
|
5020
|
+
}, [N(z(ka.default), {
|
|
5017
5021
|
"model-value": l(n),
|
|
5018
5022
|
group: {
|
|
5019
5023
|
name: "blocks",
|
|
@@ -5027,13 +5031,13 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5027
5031
|
class: "tpl:min-h-[60px]",
|
|
5028
5032
|
"onUpdate:modelValue": (e) => u(n, e)
|
|
5029
5033
|
}, {
|
|
5030
|
-
item:
|
|
5034
|
+
item: Ce(({ element: t }) => [we(M("div", null, [N(qn, {
|
|
5031
5035
|
block: t,
|
|
5032
5036
|
"is-selected": z(i).state.selectedBlockId === t.id,
|
|
5033
5037
|
viewport: e.viewport,
|
|
5034
5038
|
onSelect: (e) => z(i).selectBlock(t.id)
|
|
5035
5039
|
}, {
|
|
5036
|
-
default:
|
|
5040
|
+
default: Ce(() => [(F(), ae(ve(d(t)), {
|
|
5037
5041
|
block: t,
|
|
5038
5042
|
viewport: e.viewport,
|
|
5039
5043
|
onFetchData: (e) => p(t, e)
|
|
@@ -5048,15 +5052,15 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5048
5052
|
"is-selected",
|
|
5049
5053
|
"viewport",
|
|
5050
5054
|
"onSelect"
|
|
5051
|
-
])], 512), [[
|
|
5055
|
+
])], 512), [[xe, !z(a)?.isHidden(t.id)]])]),
|
|
5052
5056
|
_: 1
|
|
5053
5057
|
}, 8, [
|
|
5054
5058
|
"model-value",
|
|
5055
5059
|
"group",
|
|
5056
5060
|
"onUpdate:modelValue"
|
|
5057
|
-
]), l(n).length === 0 ? (
|
|
5061
|
+
]), l(n).length === 0 ? (F(), j("div", Ma, [M("span", null, R(z(r).section.dropHere), 1)])) : oe("", !0)], 6))), 128))])]));
|
|
5058
5062
|
}
|
|
5059
|
-
}),
|
|
5063
|
+
}), Pa = {
|
|
5060
5064
|
facebook: {
|
|
5061
5065
|
name: "Facebook",
|
|
5062
5066
|
color: "#1877F2",
|
|
@@ -5137,11 +5141,11 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5137
5141
|
color: "#1769FF",
|
|
5138
5142
|
path: "M22 7h-7V5h7v2zm1.726 10c-.442 1.297-2.029 3-5.101 3-3.074 0-5.564-1.729-5.564-5.675 0-3.91 2.325-5.92 5.466-5.92 3.082 0 4.964 1.782 5.375 4.426.078.506.109 1.188.095 2.14H15.97c.13 3.211 3.483 3.312 4.588 2.029h3.168zm-7.686-4h4.965c-.105-1.547-1.136-2.219-2.477-2.219-1.466 0-2.277.768-2.488 2.219zm-9.574 6.988H0V5.021h6.953c5.476.081 5.58 5.444 2.72 6.906 3.461 1.26 3.577 8.061-3.207 8.061zM3 11h3.584c2.508 0 2.906-3-.312-3H3v3zm3.391 3H3v3.016h3.341c3.055 0 2.868-3.016.05-3.016z"
|
|
5139
5143
|
}
|
|
5140
|
-
},
|
|
5144
|
+
}, Fa = {
|
|
5141
5145
|
small: 24,
|
|
5142
5146
|
medium: 32,
|
|
5143
5147
|
large: 48
|
|
5144
|
-
},
|
|
5148
|
+
}, Ia = [
|
|
5145
5149
|
"facebook",
|
|
5146
5150
|
"twitter",
|
|
5147
5151
|
"instagram",
|
|
@@ -5158,11 +5162,11 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5158
5162
|
"github",
|
|
5159
5163
|
"dribbble",
|
|
5160
5164
|
"behance"
|
|
5161
|
-
],
|
|
5165
|
+
], La = [
|
|
5162
5166
|
"width",
|
|
5163
5167
|
"height",
|
|
5164
5168
|
"fill"
|
|
5165
|
-
],
|
|
5169
|
+
], Ra = ["d"], za = /* @__PURE__ */ le({
|
|
5166
5170
|
__name: "SocialIconSvg",
|
|
5167
5171
|
props: {
|
|
5168
5172
|
platform: {},
|
|
@@ -5170,7 +5174,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5170
5174
|
iconSize: {}
|
|
5171
5175
|
},
|
|
5172
5176
|
setup(e) {
|
|
5173
|
-
let t = e, n = A(() =>
|
|
5177
|
+
let t = e, n = A(() => Pa[t.platform]), r = A(() => Fa[t.iconSize]), i = A(() => {
|
|
5174
5178
|
let e = {
|
|
5175
5179
|
display: "inline-flex",
|
|
5176
5180
|
alignItems: "center",
|
|
@@ -5208,39 +5212,39 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5208
5212
|
default: return e;
|
|
5209
5213
|
}
|
|
5210
5214
|
}), a = A(() => Math.floor(r.value * .6)), o = A(() => t.iconStyle === "outlined" ? n.value.color : "#ffffff");
|
|
5211
|
-
return (e, t) => (
|
|
5215
|
+
return (e, t) => (F(), j("span", { style: P(i.value) }, [(F(), j("svg", {
|
|
5212
5216
|
width: a.value,
|
|
5213
5217
|
height: a.value,
|
|
5214
5218
|
viewBox: "0 0 24 24",
|
|
5215
5219
|
fill: o.value,
|
|
5216
5220
|
xmlns: "http://www.w3.org/2000/svg"
|
|
5217
|
-
}, [M("path", { d: n.value.path }, null, 8,
|
|
5221
|
+
}, [M("path", { d: n.value.path }, null, 8, Ra)], 8, La))], 4));
|
|
5218
5222
|
}
|
|
5219
|
-
}),
|
|
5223
|
+
}), Ba = { class: "tpl:w-full" }, Va = ["href"], Ha = {
|
|
5220
5224
|
key: 1,
|
|
5221
5225
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
|
|
5222
|
-
},
|
|
5226
|
+
}, Ua = /* @__PURE__ */ le({
|
|
5223
5227
|
__name: "SocialIconsBlock",
|
|
5224
5228
|
props: {
|
|
5225
5229
|
block: {},
|
|
5226
5230
|
viewport: {}
|
|
5227
5231
|
},
|
|
5228
5232
|
setup(e) {
|
|
5229
|
-
let t = e, { t: n } =
|
|
5233
|
+
let t = e, { t: n } = E(), r = A(() => ({
|
|
5230
5234
|
display: "flex",
|
|
5231
5235
|
flexWrap: "wrap",
|
|
5232
5236
|
gap: `${t.block.spacing}px`,
|
|
5233
5237
|
justifyContent: t.block.align === "left" ? "flex-start" : t.block.align === "right" ? "flex-end" : "center"
|
|
5234
5238
|
})), i = A(() => t.block.icons.length > 0);
|
|
5235
|
-
return (t, a) => (
|
|
5239
|
+
return (t, a) => (F(), j("div", Ba, [i.value ? (F(), j("div", {
|
|
5236
5240
|
key: 0,
|
|
5237
|
-
style:
|
|
5238
|
-
}, [(
|
|
5241
|
+
style: P(r.value)
|
|
5242
|
+
}, [(F(!0), j(ie, null, ge(e.block.icons, (t) => (F(), j("a", {
|
|
5239
5243
|
key: t.id,
|
|
5240
5244
|
href: t.url || "#",
|
|
5241
5245
|
class: "tpl:cursor-default",
|
|
5242
|
-
onClick: a[0] ||=
|
|
5243
|
-
}, [N(
|
|
5246
|
+
onClick: a[0] ||= Ee(() => {}, ["prevent"])
|
|
5247
|
+
}, [N(za, {
|
|
5244
5248
|
platform: t.platform,
|
|
5245
5249
|
"icon-style": e.block.iconStyle,
|
|
5246
5250
|
"icon-size": e.block.iconSize
|
|
@@ -5248,53 +5252,53 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5248
5252
|
"platform",
|
|
5249
5253
|
"icon-style",
|
|
5250
5254
|
"icon-size"
|
|
5251
|
-
])], 8,
|
|
5255
|
+
])], 8, Va))), 128))], 4)) : (F(), j("div", Ha, [N(z(It), { size: 16 }), M("span", null, R(z(n).social.addIcons), 1)]))]));
|
|
5252
5256
|
}
|
|
5253
|
-
}),
|
|
5257
|
+
}), Wa = { class: "tpl:w-full" }, Ga = {
|
|
5254
5258
|
key: 0,
|
|
5255
5259
|
class: "tpl:absolute tpl:rounded tpl:px-2 tpl:py-0.5 tpl:text-[10px] tpl:font-medium",
|
|
5256
5260
|
style: {
|
|
5257
5261
|
"background-color": "var(--tpl-bg-hover)",
|
|
5258
5262
|
color: "var(--tpl-text-dim)"
|
|
5259
5263
|
}
|
|
5260
|
-
},
|
|
5264
|
+
}, Ka = /* @__PURE__ */ le({
|
|
5261
5265
|
__name: "SpacerBlock",
|
|
5262
5266
|
props: {
|
|
5263
5267
|
block: {},
|
|
5264
5268
|
viewport: {}
|
|
5265
5269
|
},
|
|
5266
5270
|
setup(e) {
|
|
5267
|
-
let t = e, n =
|
|
5271
|
+
let t = e, n = w(f, "SpacerBlock"), r = A(() => ({
|
|
5268
5272
|
height: `${t.block.height}px`,
|
|
5269
5273
|
minHeight: `${t.block.height}px`,
|
|
5270
5274
|
...n.state.previewMode ? {} : { borderColor: "var(--tpl-border)" }
|
|
5271
5275
|
}));
|
|
5272
|
-
return (t, i) => (
|
|
5273
|
-
style:
|
|
5274
|
-
class:
|
|
5275
|
-
}, [z(n).state.previewMode ?
|
|
5276
|
+
return (t, i) => (F(), j("div", Wa, [M("div", {
|
|
5277
|
+
style: P(r.value),
|
|
5278
|
+
class: fe(["tpl:relative tpl:flex tpl:items-center tpl:justify-center", { "tpl:border-y tpl:border-dashed": !z(n).state.previewMode }])
|
|
5279
|
+
}, [z(n).state.previewMode ? oe("", !0) : (F(), j("span", Ga, R(e.block.height) + "px ", 1))], 6)]));
|
|
5276
5280
|
}
|
|
5277
|
-
}),
|
|
5281
|
+
}), qa = { class: "tpl:w-full" }, Ja = { key: 0 }, Ya = [
|
|
5278
5282
|
"aria-label",
|
|
5279
5283
|
"data-placeholder",
|
|
5280
5284
|
"onBlur",
|
|
5281
5285
|
"textContent"
|
|
5282
|
-
],
|
|
5286
|
+
], Xa = [
|
|
5283
5287
|
"aria-label",
|
|
5284
5288
|
"data-placeholder",
|
|
5285
5289
|
"onBlur",
|
|
5286
5290
|
"textContent"
|
|
5287
|
-
],
|
|
5291
|
+
], Za = {
|
|
5288
5292
|
key: 1,
|
|
5289
5293
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
|
|
5290
|
-
},
|
|
5294
|
+
}, Qa = /* @__PURE__ */ O(/* @__PURE__ */ le({
|
|
5291
5295
|
__name: "TableBlock",
|
|
5292
5296
|
props: {
|
|
5293
5297
|
block: {},
|
|
5294
5298
|
viewport: {}
|
|
5295
5299
|
},
|
|
5296
5300
|
setup(e) {
|
|
5297
|
-
let t = e, { t: n } =
|
|
5301
|
+
let t = e, { t: n } = E(), r = w(f, "TableBlock"), i = A(() => t.block.rows.length > 0), a = A(() => ({
|
|
5298
5302
|
width: "100%",
|
|
5299
5303
|
borderCollapse: "collapse",
|
|
5300
5304
|
fontSize: `${t.block.fontSize}px`,
|
|
@@ -5323,40 +5327,40 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5323
5327
|
} : t);
|
|
5324
5328
|
r.updateBlock(t.block.id, { rows: o });
|
|
5325
5329
|
}
|
|
5326
|
-
return (e, t) => (
|
|
5330
|
+
return (e, t) => (F(), j("div", qa, [i.value ? (F(), j("table", {
|
|
5327
5331
|
key: 0,
|
|
5328
|
-
style:
|
|
5332
|
+
style: P(a.value),
|
|
5329
5333
|
class: "tpl-table-editable"
|
|
5330
|
-
}, [c.value ? (
|
|
5334
|
+
}, [c.value ? (F(), j("thead", Ja, [M("tr", null, [(F(!0), j(ie, null, ge(c.value.cells, (e) => (F(), j("th", {
|
|
5331
5335
|
key: e.id,
|
|
5332
|
-
style:
|
|
5336
|
+
style: P(s.value),
|
|
5333
5337
|
"aria-label": z(n).table.cellPlaceholder,
|
|
5334
5338
|
contenteditable: "true",
|
|
5335
5339
|
"data-placeholder": z(n).table.cellPlaceholder,
|
|
5336
5340
|
onBlur: (t) => d(c.value.id, e.id, t),
|
|
5337
|
-
onKeydown: t[0] ||=
|
|
5338
|
-
onClick:
|
|
5341
|
+
onKeydown: t[0] ||= Te(Ee((e) => e.target.blur(), ["prevent"]), ["enter"]),
|
|
5342
|
+
onClick: Ee(u, ["stop"]),
|
|
5339
5343
|
textContent: R(e.content)
|
|
5340
|
-
}, null, 44,
|
|
5344
|
+
}, null, 44, Ya))), 128))])])) : oe("", !0), M("tbody", null, [(F(!0), j(ie, null, ge(l.value, (e) => (F(), j("tr", { key: e.id }, [(F(!0), j(ie, null, ge(e.cells, (r) => (F(), j("td", {
|
|
5341
5345
|
key: r.id,
|
|
5342
|
-
style:
|
|
5346
|
+
style: P(o.value),
|
|
5343
5347
|
"aria-label": z(n).table.cellPlaceholder,
|
|
5344
5348
|
contenteditable: "true",
|
|
5345
5349
|
"data-placeholder": z(n).table.cellPlaceholder,
|
|
5346
5350
|
onBlur: (t) => d(e.id, r.id, t),
|
|
5347
|
-
onKeydown: t[1] ||=
|
|
5348
|
-
onClick:
|
|
5351
|
+
onKeydown: t[1] ||= Te(Ee((e) => e.target.blur(), ["prevent"]), ["enter"]),
|
|
5352
|
+
onClick: Ee(u, ["stop"]),
|
|
5349
5353
|
textContent: R(r.content)
|
|
5350
|
-
}, null, 44,
|
|
5354
|
+
}, null, 44, Xa))), 128))]))), 128))])], 4)) : (F(), j("div", Za, [N(z(Lt), { size: 16 }), M("span", null, R(z(n).table.empty), 1)]))]));
|
|
5351
5355
|
}
|
|
5352
|
-
}), [["__scopeId", "data-v-
|
|
5356
|
+
}), [["__scopeId", "data-v-dfc60174"]]), $a = /* @__PURE__ */ le({
|
|
5353
5357
|
__name: "VideoPlayButton",
|
|
5354
5358
|
props: { hoverEffect: {
|
|
5355
5359
|
type: Boolean,
|
|
5356
5360
|
default: !1
|
|
5357
5361
|
} },
|
|
5358
5362
|
setup(e) {
|
|
5359
|
-
return (t, n) => (
|
|
5363
|
+
return (t, n) => (F(), j("div", { class: fe(["tpl:absolute tpl:inset-0 tpl:flex tpl:items-center tpl:justify-center tpl:bg-black/30", e.hoverEffect && "tpl:transition-opacity tpl:group-hover:bg-black/40"]) }, [...n[0] ||= [M("div", { class: "tpl:flex tpl:size-16 tpl:items-center tpl:justify-center tpl:rounded-full tpl:bg-white/90 tpl:shadow-lg" }, [M("svg", {
|
|
5360
5364
|
class: "tpl:ml-1 tpl:text-[var(--tpl-danger)]",
|
|
5361
5365
|
width: "28",
|
|
5362
5366
|
height: "28",
|
|
@@ -5367,7 +5371,7 @@ var ii, ai, oi, si, ci, li, ui, di, fi, pi, mi, hi, gi, _i, vi, yi, q, J, Y, X,
|
|
|
5367
5371
|
});
|
|
5368
5372
|
//#endregion
|
|
5369
5373
|
//#region src/utils/videoThumbnail.ts
|
|
5370
|
-
function
|
|
5374
|
+
function eo(e) {
|
|
5371
5375
|
if (!e) return {
|
|
5372
5376
|
platform: "unknown",
|
|
5373
5377
|
videoId: null,
|
|
@@ -5399,127 +5403,127 @@ function $a(e) {
|
|
|
5399
5403
|
thumbnailUrl: null
|
|
5400
5404
|
};
|
|
5401
5405
|
}
|
|
5402
|
-
function
|
|
5403
|
-
return t ||
|
|
5406
|
+
function to(e, t) {
|
|
5407
|
+
return t || eo(e).thumbnailUrl;
|
|
5404
5408
|
}
|
|
5405
5409
|
//#endregion
|
|
5406
5410
|
//#region src/components/blocks/VideoBlock.vue?vue&type=script&setup=true&lang.ts
|
|
5407
|
-
var
|
|
5411
|
+
var no = ["src", "alt"], ro = {
|
|
5408
5412
|
class: "tpl:max-w-full tpl:truncate tpl:px-3 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-primary)]",
|
|
5409
5413
|
style: { opacity: "0.7" }
|
|
5410
|
-
},
|
|
5414
|
+
}, io = ["href"], ao = ["src", "alt"], oo = ["src", "alt"], so = {
|
|
5411
5415
|
key: 3,
|
|
5412
5416
|
class: "tpl:flex tpl:min-h-[150px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-sm tpl:border-[var(--tpl-border-light)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-dim)]"
|
|
5413
|
-
},
|
|
5417
|
+
}, co = /* @__PURE__ */ le({
|
|
5414
5418
|
__name: "VideoBlock",
|
|
5415
5419
|
props: {
|
|
5416
5420
|
block: {},
|
|
5417
5421
|
viewport: {}
|
|
5418
5422
|
},
|
|
5419
5423
|
setup(e) {
|
|
5420
|
-
let t = e, { t: n } =
|
|
5424
|
+
let t = e, { t: n } = E(), { syntax: r } = re(), i = A(() => Pe(t.block.url, r) || Pe(t.block.thumbnailUrl, r)), a = A(() => i.value ? null : to(t.block.url, t.block.thumbnailUrl)), o = A(() => ({ textAlign: t.block.align })), s = A(() => ({
|
|
5421
5425
|
maxWidth: "100%",
|
|
5422
5426
|
width: t.block.width === "full" ? "100%" : `${t.block.width}px`,
|
|
5423
5427
|
display: "block",
|
|
5424
5428
|
margin: t.block.align === "center" ? "0 auto" : void 0,
|
|
5425
5429
|
marginLeft: t.block.align === "right" ? "auto" : void 0
|
|
5426
|
-
})), c = A(() =>
|
|
5427
|
-
return (t, r) => (
|
|
5430
|
+
})), c = A(() => Pe(t.block.url, r) ? t.block.url : t.block.thumbnailUrl);
|
|
5431
|
+
return (t, r) => (F(), j("div", {
|
|
5428
5432
|
class: "tpl:w-full",
|
|
5429
|
-
style:
|
|
5430
|
-
}, [i.value && e.block.placeholderUrl ? (
|
|
5433
|
+
style: P(o.value)
|
|
5434
|
+
}, [i.value && e.block.placeholderUrl ? (F(), j("div", {
|
|
5431
5435
|
key: 0,
|
|
5432
5436
|
class: "tpl:relative tpl:inline-block",
|
|
5433
|
-
style:
|
|
5437
|
+
style: P(s.value)
|
|
5434
5438
|
}, [M("img", {
|
|
5435
5439
|
class: "tpl:w-full tpl:border-0",
|
|
5436
5440
|
src: e.block.placeholderUrl,
|
|
5437
5441
|
alt: e.block.alt
|
|
5438
|
-
}, null, 8,
|
|
5442
|
+
}, null, 8, no), N($a)], 4)) : i.value ? (F(), j("div", {
|
|
5439
5443
|
key: 1,
|
|
5440
5444
|
class: "tpl:relative tpl:!flex tpl:min-h-[150px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-center tpl:bg-[var(--tpl-bg-elevated)]",
|
|
5441
|
-
style:
|
|
5442
|
-
}, [N(z(
|
|
5445
|
+
style: P([{ "border-color": "color-mix(in srgb, var(--tpl-primary) 40%, transparent)" }, s.value])
|
|
5446
|
+
}, [N(z(Rt), {
|
|
5443
5447
|
size: 36,
|
|
5444
5448
|
"stroke-width": 1.5,
|
|
5445
5449
|
class: "tpl:text-[var(--tpl-primary)]",
|
|
5446
5450
|
style: { opacity: "0.5" }
|
|
5447
|
-
}), M("span",
|
|
5451
|
+
}), M("span", ro, R(c.value), 1)], 4)) : a.value ? (F(), j(ie, { key: 2 }, [e.block.url ? (F(), j("a", {
|
|
5448
5452
|
key: 0,
|
|
5449
5453
|
href: e.block.url,
|
|
5450
5454
|
target: "_blank",
|
|
5451
5455
|
rel: "noopener noreferrer",
|
|
5452
5456
|
class: "tpl:group tpl:relative tpl:inline-block",
|
|
5453
|
-
style:
|
|
5454
|
-
onClick: r[0] ||=
|
|
5457
|
+
style: P(s.value),
|
|
5458
|
+
onClick: r[0] ||= Ee(() => {}, ["prevent"])
|
|
5455
5459
|
}, [M("img", {
|
|
5456
5460
|
class: "tpl:w-full tpl:border-0",
|
|
5457
5461
|
src: a.value,
|
|
5458
5462
|
alt: e.block.alt
|
|
5459
|
-
}, null, 8,
|
|
5463
|
+
}, null, 8, ao), N($a, { "hover-effect": "" })], 12, io)) : (F(), j("div", {
|
|
5460
5464
|
key: 1,
|
|
5461
5465
|
class: "tpl:relative tpl:inline-block",
|
|
5462
|
-
style:
|
|
5466
|
+
style: P(s.value)
|
|
5463
5467
|
}, [M("img", {
|
|
5464
5468
|
class: "tpl:w-full tpl:border-0",
|
|
5465
5469
|
src: a.value,
|
|
5466
5470
|
alt: e.block.alt
|
|
5467
|
-
}, null, 8,
|
|
5471
|
+
}, null, 8, oo), N($a)], 4))], 64)) : (F(), j("div", so, [N(z(Rt), {
|
|
5468
5472
|
size: 40,
|
|
5469
5473
|
"stroke-width": 1.5,
|
|
5470
5474
|
class: "tpl:text-[var(--tpl-border-light)]"
|
|
5471
5475
|
}), M("span", null, R(z(n).video.addVideo), 1)]))], 4));
|
|
5472
5476
|
}
|
|
5473
|
-
}),
|
|
5474
|
-
section:
|
|
5475
|
-
title:
|
|
5476
|
-
paragraph:
|
|
5477
|
-
image:
|
|
5478
|
-
button:
|
|
5479
|
-
divider:
|
|
5480
|
-
video:
|
|
5481
|
-
social:
|
|
5482
|
-
menu:
|
|
5483
|
-
table:
|
|
5484
|
-
spacer:
|
|
5485
|
-
html:
|
|
5486
|
-
countdown:
|
|
5477
|
+
}), lo = {
|
|
5478
|
+
section: Na,
|
|
5479
|
+
title: Yn,
|
|
5480
|
+
paragraph: Mn,
|
|
5481
|
+
image: Tn,
|
|
5482
|
+
button: xt,
|
|
5483
|
+
divider: ln,
|
|
5484
|
+
video: co,
|
|
5485
|
+
social: Ua,
|
|
5486
|
+
menu: kn,
|
|
5487
|
+
table: Qa,
|
|
5488
|
+
spacer: Ka,
|
|
5489
|
+
html: mn,
|
|
5490
|
+
countdown: Tt
|
|
5487
5491
|
};
|
|
5488
|
-
function
|
|
5489
|
-
let { editor: t, config: n, translations: r, fontsManager: i } = e, { t: o, format:
|
|
5492
|
+
function uo(e) {
|
|
5493
|
+
let { editor: t, config: n, translations: r, fontsManager: i } = e, { t: o, format: w } = E(r);
|
|
5490
5494
|
t.setUiTheme(n.uiTheme ?? "auto");
|
|
5491
|
-
let { resolvedTheme:
|
|
5492
|
-
themeOverrides:
|
|
5493
|
-
resolvedTheme:
|
|
5495
|
+
let { resolvedTheme: D } = dt(A(() => t.state.uiTheme)), O = L(n.theme ?? {}), { themeStyles: ee } = pt({
|
|
5496
|
+
themeOverrides: O,
|
|
5497
|
+
resolvedTheme: D,
|
|
5494
5498
|
extraStyles: e.themeExtraStyles
|
|
5495
|
-
}),
|
|
5499
|
+
}), k = je({
|
|
5496
5500
|
content: t.content,
|
|
5497
5501
|
setContent: (e, n) => t.setContent(e, n),
|
|
5498
5502
|
...e.historyOptions
|
|
5499
5503
|
});
|
|
5500
|
-
|
|
5501
|
-
let
|
|
5504
|
+
Me(t, k);
|
|
5505
|
+
let te = Oe({
|
|
5502
5506
|
addBlock: t.addBlock,
|
|
5503
5507
|
removeBlock: t.removeBlock,
|
|
5504
5508
|
updateBlock: t.updateBlock,
|
|
5505
5509
|
selectBlock: t.selectBlock,
|
|
5506
5510
|
blockDefaults: n.blockDefaults
|
|
5507
|
-
}),
|
|
5511
|
+
}), ne = ke(t), re = e.autoSaveOptions !== null && e.autoSaveOptions !== void 0 ? De({
|
|
5508
5512
|
content: t.content,
|
|
5509
5513
|
isDirty: () => t.state.isDirty,
|
|
5510
5514
|
...e.autoSaveOptions
|
|
5511
|
-
}) : null;
|
|
5512
|
-
|
|
5513
|
-
e ?
|
|
5514
|
-
});
|
|
5515
|
-
let
|
|
5516
|
-
if (
|
|
5517
|
-
function
|
|
5518
|
-
for (let t of e)
|
|
5515
|
+
}) : null, ie = null;
|
|
5516
|
+
re && (ie = Se(k.isNavigating, (e) => {
|
|
5517
|
+
e ? re.pause() : re.resume();
|
|
5518
|
+
}));
|
|
5519
|
+
let ae = mt();
|
|
5520
|
+
if (gt(ae, lo), n.customBlocks?.length) for (let e of n.customBlocks) ae.registerCustom(e, sn);
|
|
5521
|
+
function oe(e) {
|
|
5522
|
+
for (let t of e) ae.registerCustom(t, sn);
|
|
5519
5523
|
}
|
|
5520
5524
|
function j(r) {
|
|
5521
|
-
|
|
5522
|
-
history:
|
|
5525
|
+
vt(r, {
|
|
5526
|
+
history: k,
|
|
5523
5527
|
selectBlock: (e) => t.selectBlock(e),
|
|
5524
5528
|
getSelectedBlockId: () => t.state.selectedBlockId,
|
|
5525
5529
|
removeBlock: (e) => t.removeBlock(e),
|
|
@@ -5527,26 +5531,26 @@ function lo(e) {
|
|
|
5527
5531
|
onBeforeUndo: e.keyboardOptions?.onBeforeUndo
|
|
5528
5532
|
});
|
|
5529
5533
|
}
|
|
5530
|
-
a(document, "keydown", j),
|
|
5531
|
-
let M =
|
|
5532
|
-
|
|
5533
|
-
function
|
|
5534
|
-
|
|
5534
|
+
a(document, "keydown", j), I(c, r), I(f, t), I(_, k), I(h, te), I(g, ne), I(b, i), I(T, ee), I(s, D), I(u, n.blockDefaults), I(y, ae), I(S, n.customBlocks ?? []);
|
|
5535
|
+
let M = Ze(n.mergeTags?.syntax);
|
|
5536
|
+
I(m, n.mergeTags?.tags ?? []), I(p, M), I(C, n.mergeTags?.onRequest ?? null), I(l, n.onRequestMedia ?? null), I(d, n.displayConditions?.conditions ?? []), I(v, n.displayConditions?.allowCustom ?? !1), I(x, e.capabilities ?? {});
|
|
5537
|
+
function se() {
|
|
5538
|
+
ie?.(), re?.destroy(), k.destroy();
|
|
5535
5539
|
}
|
|
5536
5540
|
return {
|
|
5537
5541
|
t: o,
|
|
5538
|
-
format:
|
|
5539
|
-
history:
|
|
5540
|
-
blockActions:
|
|
5541
|
-
conditionPreview:
|
|
5542
|
-
autoSave:
|
|
5543
|
-
resolvedTheme:
|
|
5544
|
-
themeStyles:
|
|
5545
|
-
themeOverrides:
|
|
5546
|
-
registry:
|
|
5547
|
-
registerCustomBlocks:
|
|
5548
|
-
destroy:
|
|
5542
|
+
format: w,
|
|
5543
|
+
history: k,
|
|
5544
|
+
blockActions: te,
|
|
5545
|
+
conditionPreview: ne,
|
|
5546
|
+
autoSave: re,
|
|
5547
|
+
resolvedTheme: D,
|
|
5548
|
+
themeStyles: ee,
|
|
5549
|
+
themeOverrides: O,
|
|
5550
|
+
registry: ae,
|
|
5551
|
+
registerCustomBlocks: oe,
|
|
5552
|
+
destroy: se
|
|
5549
5553
|
};
|
|
5550
5554
|
}
|
|
5551
5555
|
//#endregion
|
|
5552
|
-
export {
|
|
5556
|
+
export { At as A, Wt as C, It as D, Lt as E, ot as F, ct as I, Ot as M, Tt as N, Pt as O, xt as P, Gt as S, Vt as T, mn as _, Ua as a, Zt as b, Na as c, qn as d, Pn as f, Tn as g, kn as h, Ka as i, kt as j, Nt as k, Oa as l, Mn as m, co as n, Pa as o, Nn as p, Qa as r, Ia as s, uo as t, Yn as u, ln as v, Ut as w, Yt as x, sn as y };
|