@aswin.dev/editor 0.6.3 → 0.7.0
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/AccessibilityPanel-CvQGLdu6.js +108 -0
- package/dist/AiChatSidebar-B3SJIKG_.js +229 -0
- package/dist/AiFeatureMenu-BLLKoOos.js +63 -0
- package/dist/BlockA11yBadge-CXDLqkcJ.js +34 -0
- package/dist/CloudEditor-BCz1ZTYC.js +1172 -0
- package/dist/CollaboratorBar-DuPYW5iF.js +95 -0
- package/dist/CommentsSidebar-B1pvJdqF.js +441 -0
- package/dist/CountdownBlock-BNSj1jvJ.js +92 -0
- package/dist/CountdownToolbar-ClJr2GzL.js +210 -0
- package/dist/DesignReferenceSidebar-B8V_F2yF.js +276 -0
- package/dist/LoadingTrack-B0CWFHXQ.js +10 -0
- package/dist/ModuleBrowserModal-DrUFMTDx.js +206 -0
- package/dist/ModulePreviewCanvas-CHdOwV_4.js +106 -0
- package/dist/NumberWithSuffix-DkXUez9t.js +422 -0
- package/dist/ParagraphEditor-D75wl3BX.js +695 -0
- package/dist/RichTextEditorContent-DYkIauIk.js +137 -0
- package/dist/SaveModuleDialog-FZ9lxY7_.js +123 -0
- package/dist/SnapshotHistory-BR3eV120.js +127 -0
- package/dist/TemplateScoringPanel-4GTNHej5.js +256 -0
- package/dist/TestEmailModal--ue5w9fT.js +94 -0
- package/dist/TitleEditor-fStSADI-.js +172 -0
- package/dist/TplModal-BwSfxIHf.js +44 -0
- package/dist/_plugin-vue_export-helper-B0hnzhyu.js +8 -0
- package/dist/accessibility-e8JYu_zd.js +27 -0
- package/dist/blockTypeIcons-BcTrDjmH.js +126 -0
- package/dist/bundle-stats.json +10 -0
- package/dist/cdn/chunks/AccessibilityPanel-B6DOjojm.js +97 -0
- package/dist/cdn/chunks/AccessibilityPanel-B6DOjojm.js.map +1 -0
- package/dist/cdn/chunks/AiFeatureMenu-qEdB2fZJ.js +59 -0
- package/dist/cdn/chunks/AiFeatureMenu-qEdB2fZJ.js.map +1 -0
- package/dist/cdn/chunks/BlockA11yBadge-DcEZftf6.js +33 -0
- package/dist/cdn/chunks/BlockA11yBadge-DcEZftf6.js.map +1 -0
- package/dist/cdn/chunks/CloudEditor-D2GsEC_n.js +1143 -0
- package/dist/cdn/chunks/CloudEditor-D2GsEC_n.js.map +1 -0
- package/dist/cdn/chunks/CollaboratorBar--nO7TX6b.js +51 -0
- package/dist/cdn/chunks/CollaboratorBar--nO7TX6b.js.map +1 -0
- package/dist/cdn/chunks/CountdownBlock-5YdT1uUu.js +93 -0
- package/dist/cdn/chunks/CountdownBlock-5YdT1uUu.js.map +1 -0
- package/dist/cdn/chunks/CountdownToolbar-DXPXrbAA.js +212 -0
- package/dist/cdn/chunks/CountdownToolbar-DXPXrbAA.js.map +1 -0
- package/dist/cdn/chunks/ModuleBrowserModal-DxoPp81s.js +195 -0
- package/dist/cdn/chunks/ModuleBrowserModal-DxoPp81s.js.map +1 -0
- package/dist/cdn/chunks/ModulePreviewCanvas-CoLdb4ar.js +107 -0
- package/dist/cdn/chunks/ModulePreviewCanvas-CoLdb4ar.js.map +1 -0
- package/dist/cdn/chunks/NumberWithSuffix-CE3NrZhH.js +423 -0
- package/dist/cdn/chunks/NumberWithSuffix-CE3NrZhH.js.map +1 -0
- package/dist/cdn/chunks/ParagraphEditor-B6Ygu-Mq.js +544 -0
- package/dist/cdn/chunks/ParagraphEditor-B6Ygu-Mq.js.map +1 -0
- package/dist/cdn/chunks/RichTextEditorContent-DL_y2SrR.js +106 -0
- package/dist/cdn/chunks/RichTextEditorContent-DL_y2SrR.js.map +1 -0
- package/dist/cdn/chunks/SaveModuleDialog-B0TnO_o9.js +119 -0
- package/dist/cdn/chunks/SaveModuleDialog-B0TnO_o9.js.map +1 -0
- package/dist/cdn/chunks/TitleEditor-BHpfxvwy.js +171 -0
- package/dist/cdn/chunks/TitleEditor-BHpfxvwy.js.map +1 -0
- package/dist/cdn/chunks/blockTypeIcons-BzzY9_kA.js +22 -0
- package/dist/cdn/chunks/blockTypeIcons-BzzY9_kA.js.map +1 -0
- package/dist/cdn/chunks/de-Ce-LbJ2J.js +89 -0
- package/dist/cdn/chunks/de-Ce-LbJ2J.js.map +1 -0
- package/dist/cdn/chunks/de-D8CnZxV9.js +523 -0
- package/dist/cdn/chunks/de-D8CnZxV9.js.map +1 -0
- package/dist/cdn/chunks/de-RQrZR56a.js +209 -0
- package/dist/cdn/chunks/de-RQrZR56a.js.map +1 -0
- package/dist/cdn/chunks/draggable-Bcb86AsV.js +11572 -0
- package/dist/cdn/chunks/draggable-Bcb86AsV.js.map +1 -0
- package/dist/cdn/chunks/emojiData-EMFlj6FJ.js +19 -0
- package/dist/cdn/chunks/emojiData-EMFlj6FJ.js.map +1 -0
- package/dist/cdn/chunks/en-8FHaQv4V.js +523 -0
- package/dist/cdn/chunks/en-8FHaQv4V.js.map +1 -0
- package/dist/cdn/chunks/en-Bl1ecfRF.js +209 -0
- package/dist/cdn/chunks/en-Bl1ecfRF.js.map +1 -0
- package/dist/cdn/chunks/en-DiCWK5fG.js +89 -0
- package/dist/cdn/chunks/en-DiCWK5fG.js.map +1 -0
- package/dist/cdn/chunks/extensions-DIxF31tA.js +598 -0
- package/dist/cdn/chunks/extensions-DIxF31tA.js.map +1 -0
- package/dist/cdn/chunks/features-DEMb13KS.js +6814 -0
- package/dist/cdn/chunks/features-DEMb13KS.js.map +1 -0
- package/dist/cdn/chunks/icons-CsLTcirh.js +700 -0
- package/dist/cdn/chunks/icons-CsLTcirh.js.map +1 -0
- package/dist/cdn/chunks/liquid.browser-lQbkge2E.js +3279 -0
- package/dist/cdn/chunks/liquid.browser-lQbkge2E.js.map +1 -0
- package/dist/cdn/chunks/media-library-CVaNvhpM.js +6014 -0
- package/dist/cdn/chunks/media-library-CVaNvhpM.js.map +1 -0
- package/dist/cdn/chunks/pusher-CDbNlZBE.js +2508 -0
- package/dist/cdn/chunks/pusher-CDbNlZBE.js.map +1 -0
- package/dist/cdn/chunks/quality-BaBfc54_.js +1456 -0
- package/dist/cdn/chunks/quality-BaBfc54_.js.map +1 -0
- package/dist/cdn/chunks/readableTextColor-DhoK4XiZ.js +32 -0
- package/dist/cdn/chunks/readableTextColor-DhoK4XiZ.js.map +1 -0
- package/dist/cdn/chunks/renderer-CUxvx7ro.js +548 -0
- package/dist/cdn/chunks/renderer-CUxvx7ro.js.map +1 -0
- package/dist/cdn/chunks/rolldown-runtime-BNuo_Jkg.js +20 -0
- package/dist/cdn/chunks/src-CRaqN-p8.js +497 -0
- package/dist/cdn/chunks/src-CRaqN-p8.js.map +1 -0
- package/dist/cdn/chunks/styleConstants-DP1VOca8.js +57 -0
- package/dist/cdn/chunks/styleConstants-DP1VOca8.js.map +1 -0
- package/dist/cdn/chunks/styles-BHJULjNR.js +2947 -0
- package/dist/cdn/chunks/styles-BHJULjNR.js.map +1 -0
- package/dist/cdn/chunks/tiptap-ZhwKyFp7.js +14654 -0
- package/dist/cdn/chunks/tiptap-ZhwKyFp7.js.map +1 -0
- package/dist/cdn/editor.css +2 -0
- package/dist/cdn/editor.js +250 -0
- package/dist/cdn/editor.js.map +1 -0
- package/dist/check-Da05j8yl.js +7 -0
- package/dist/chevron-down-R2uY34iD.js +7 -0
- package/dist/circle-alert-DZuGWPX-.js +25 -0
- package/dist/clock-CRp2sIub.js +12 -0
- package/dist/cloud-DEk_b4CR.js +1733 -0
- package/dist/createLucideIcon-C3pa2siy.js +43 -0
- package/dist/de-Brqvgr43.js +521 -0
- package/dist/de-DCaaCE5s.js +207 -0
- package/dist/dist-B1IR0bpH.js +326 -0
- package/dist/dist-BFawx6IS.js +519 -0
- package/dist/dist-BaQIYPsn.js +35 -0
- package/dist/dist-Cp0zXPAD.js +189 -0
- package/dist/dist-D6uC2xhi.js +5 -0
- package/dist/dist-D90y8dvT.js +2082 -0
- package/dist/dist-DDJIWTRY.js +776 -0
- package/dist/dist-DJmnUmW9.js +362 -0
- package/dist/dist-DjviJBCi.js +74 -0
- package/dist/dist-KoBJjK1G.js +61 -0
- package/dist/dist-aRzjfSRN.js +35 -0
- package/dist/dist-iLBdeBDR.js +10658 -0
- package/dist/dist-us-RpCWN.js +47 -0
- package/dist/dist-wzMIGj-D.js +5 -0
- package/dist/emojiData-PQyVa4bU.js +17 -0
- package/dist/en-DXCyK4-X.js +207 -0
- package/dist/en-WDVp87TE.js +521 -0
- package/dist/extensions-CUcl9Ok4.js +799 -0
- package/dist/formatRelativeTime-BOEf47hq.js +12 -0
- package/dist/image-up-MBZKKg9p.js +23 -0
- package/dist/index.d.ts +275 -0
- package/dist/info-CJEC7piy.js +19 -0
- package/dist/keys-ciNfSSGj.js +10 -0
- package/dist/liquid.browser-CdMv1BTn.js +3277 -0
- package/dist/loader-circle-DsY5Yg33.js +7 -0
- package/dist/message-circle-yElBbR2C.js +7 -0
- package/dist/readableTextColor-CY3SiRnt.js +30 -0
- package/dist/refresh-cw-CE_AGtn8.js +29 -0
- package/dist/rolldown-runtime-BZGGJVDF.js +20 -0
- package/dist/scan-line-D0vcUekt.js +25 -0
- package/dist/send-DH4oDQqC.js +10 -0
- package/dist/shield-check-CfJgs2Hd.js +10 -0
- package/dist/sparkles-CvRXGqFs.js +23 -0
- package/dist/style.css +2 -0
- package/dist/styleConstants-fWzlIIwN.js +55 -0
- package/dist/styles-DEXEkBvg.js +3176 -0
- package/dist/templatical-editor.js +249 -0
- package/dist/text-align-start-BT9VUDxK.js +43 -0
- package/dist/timeouts-BSGxjuUF.js +4 -0
- package/dist/trash-2-DbP2Y6t2.js +25 -0
- package/dist/triangle-alert-aOXceTSe.js +17 -0
- package/dist/useCloudI18n-BuIwR6OE.js +23 -0
- package/dist/useEditorCore-C6ost42Q.js +9342 -0
- package/dist/useI18n-lb2DHDiu.js +17 -0
- package/dist/useMergeTag-CBwKnnNB.js +34 -0
- package/dist/vue.runtime.esm-bundler-DpvJL-nX.js +5775 -0
- package/dist/x-u2oVmjN_.js +10 -0
- package/package.json +1 -1
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
//#region ../types/dist/index.js
|
|
2
|
+
var e = {
|
|
3
|
+
1: 36,
|
|
4
|
+
2: 28,
|
|
5
|
+
3: 22,
|
|
6
|
+
4: 18
|
|
7
|
+
};
|
|
8
|
+
function t(e) {
|
|
9
|
+
return e.type === "custom";
|
|
10
|
+
}
|
|
11
|
+
var n = {
|
|
12
|
+
content: "<p>Enter your title</p>",
|
|
13
|
+
level: 2,
|
|
14
|
+
color: "#1a1a1a",
|
|
15
|
+
textAlign: "left"
|
|
16
|
+
}, r = { content: "<p>Enter your text here</p>" }, i = {
|
|
17
|
+
src: "",
|
|
18
|
+
alt: "",
|
|
19
|
+
width: "full",
|
|
20
|
+
align: "center"
|
|
21
|
+
}, a = {
|
|
22
|
+
text: "Click Here",
|
|
23
|
+
url: "",
|
|
24
|
+
backgroundColor: "#333333",
|
|
25
|
+
textColor: "#ffffff",
|
|
26
|
+
borderRadius: 6,
|
|
27
|
+
fontSize: 15,
|
|
28
|
+
buttonPadding: {
|
|
29
|
+
top: 12,
|
|
30
|
+
right: 24,
|
|
31
|
+
bottom: 12,
|
|
32
|
+
left: 24
|
|
33
|
+
}
|
|
34
|
+
}, o = {
|
|
35
|
+
lineStyle: "solid",
|
|
36
|
+
color: "#e0e0e0",
|
|
37
|
+
thickness: 1,
|
|
38
|
+
width: "full"
|
|
39
|
+
}, s = { columns: "1" }, c = {
|
|
40
|
+
url: "",
|
|
41
|
+
thumbnailUrl: "",
|
|
42
|
+
alt: "Video",
|
|
43
|
+
width: "full",
|
|
44
|
+
align: "center"
|
|
45
|
+
}, l = {
|
|
46
|
+
iconStyle: "solid",
|
|
47
|
+
iconSize: "medium",
|
|
48
|
+
spacing: 10,
|
|
49
|
+
align: "center"
|
|
50
|
+
}, u = { height: 24 }, d = { content: "" }, f = {
|
|
51
|
+
fontSize: 15,
|
|
52
|
+
color: "#1a1a1a",
|
|
53
|
+
textAlign: "center",
|
|
54
|
+
separator: "|",
|
|
55
|
+
separatorColor: "#e0e0e0",
|
|
56
|
+
spacing: 10
|
|
57
|
+
}, p = {
|
|
58
|
+
hasHeaderRow: !0,
|
|
59
|
+
borderColor: "#e0e0e0",
|
|
60
|
+
borderWidth: 1,
|
|
61
|
+
cellPadding: 8,
|
|
62
|
+
fontSize: 15,
|
|
63
|
+
color: "#1a1a1a",
|
|
64
|
+
textAlign: "left"
|
|
65
|
+
}, m = {
|
|
66
|
+
targetDate: "",
|
|
67
|
+
timezone: "UTC",
|
|
68
|
+
showDays: !0,
|
|
69
|
+
showHours: !0,
|
|
70
|
+
showMinutes: !0,
|
|
71
|
+
showSeconds: !0,
|
|
72
|
+
separator: ":",
|
|
73
|
+
digitFontSize: 32,
|
|
74
|
+
digitColor: "#1a1a1a",
|
|
75
|
+
labelColor: "#6b7280",
|
|
76
|
+
labelFontSize: 12,
|
|
77
|
+
backgroundColor: "#ffffff",
|
|
78
|
+
labelDays: "Days",
|
|
79
|
+
labelHours: "Hours",
|
|
80
|
+
labelMinutes: "Minutes",
|
|
81
|
+
labelSeconds: "Seconds",
|
|
82
|
+
expiredMessage: "This offer has expired",
|
|
83
|
+
expiredImageUrl: "",
|
|
84
|
+
hideOnExpiry: !1
|
|
85
|
+
}, h = {
|
|
86
|
+
width: 600,
|
|
87
|
+
backgroundColor: "#ffffff",
|
|
88
|
+
fontFamily: "Arial",
|
|
89
|
+
locale: "en"
|
|
90
|
+
};
|
|
91
|
+
function g(e) {
|
|
92
|
+
return typeof e == "object" && !!e && !Array.isArray(e) && Object.getPrototypeOf(e) === Object.prototype;
|
|
93
|
+
}
|
|
94
|
+
function _(e, t) {
|
|
95
|
+
let n = { ...e };
|
|
96
|
+
for (let r of Object.keys(t)) {
|
|
97
|
+
let i = e[r], a = t[r];
|
|
98
|
+
a !== void 0 && (g(i) && g(a) ? n[r] = _(i, a) : n[r] = a);
|
|
99
|
+
}
|
|
100
|
+
return n;
|
|
101
|
+
}
|
|
102
|
+
function v(e = "Arial", t) {
|
|
103
|
+
return {
|
|
104
|
+
blocks: [],
|
|
105
|
+
settings: {
|
|
106
|
+
...h,
|
|
107
|
+
fontFamily: e,
|
|
108
|
+
...t
|
|
109
|
+
}
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
function y(e, t) {
|
|
113
|
+
return !t || Object.keys(t).length === 0 ? e : _(e, t);
|
|
114
|
+
}
|
|
115
|
+
function b() {
|
|
116
|
+
return crypto.randomUUID();
|
|
117
|
+
}
|
|
118
|
+
function x(e = 0) {
|
|
119
|
+
return {
|
|
120
|
+
top: e,
|
|
121
|
+
right: e,
|
|
122
|
+
bottom: e,
|
|
123
|
+
left: e
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
function S(e = 10) {
|
|
127
|
+
return {
|
|
128
|
+
padding: x(e),
|
|
129
|
+
margin: x(0)
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
function C(e = {}) {
|
|
133
|
+
return y({
|
|
134
|
+
id: b(),
|
|
135
|
+
type: "title",
|
|
136
|
+
...n,
|
|
137
|
+
styles: S()
|
|
138
|
+
}, e);
|
|
139
|
+
}
|
|
140
|
+
function w(e = {}) {
|
|
141
|
+
return y({
|
|
142
|
+
id: b(),
|
|
143
|
+
type: "paragraph",
|
|
144
|
+
...r,
|
|
145
|
+
styles: S()
|
|
146
|
+
}, e);
|
|
147
|
+
}
|
|
148
|
+
function T(e = {}) {
|
|
149
|
+
return y({
|
|
150
|
+
id: b(),
|
|
151
|
+
type: "image",
|
|
152
|
+
...i,
|
|
153
|
+
styles: S()
|
|
154
|
+
}, e);
|
|
155
|
+
}
|
|
156
|
+
function E(e = {}) {
|
|
157
|
+
return y({
|
|
158
|
+
id: b(),
|
|
159
|
+
type: "button",
|
|
160
|
+
...a,
|
|
161
|
+
styles: S()
|
|
162
|
+
}, e);
|
|
163
|
+
}
|
|
164
|
+
function D(e = {}) {
|
|
165
|
+
return y({
|
|
166
|
+
id: b(),
|
|
167
|
+
type: "divider",
|
|
168
|
+
...o,
|
|
169
|
+
styles: S(20)
|
|
170
|
+
}, e);
|
|
171
|
+
}
|
|
172
|
+
function O(e = {}) {
|
|
173
|
+
return y({
|
|
174
|
+
id: b(),
|
|
175
|
+
type: "section",
|
|
176
|
+
...s,
|
|
177
|
+
children: [[]],
|
|
178
|
+
styles: S(20)
|
|
179
|
+
}, e);
|
|
180
|
+
}
|
|
181
|
+
function k(e = {}) {
|
|
182
|
+
return y({
|
|
183
|
+
id: b(),
|
|
184
|
+
type: "video",
|
|
185
|
+
...c,
|
|
186
|
+
styles: S()
|
|
187
|
+
}, e);
|
|
188
|
+
}
|
|
189
|
+
function A(e = {}) {
|
|
190
|
+
return y({
|
|
191
|
+
id: b(),
|
|
192
|
+
type: "social",
|
|
193
|
+
icons: [],
|
|
194
|
+
...l,
|
|
195
|
+
styles: S()
|
|
196
|
+
}, e);
|
|
197
|
+
}
|
|
198
|
+
function j(e = {}) {
|
|
199
|
+
return y({
|
|
200
|
+
id: b(),
|
|
201
|
+
type: "spacer",
|
|
202
|
+
...u,
|
|
203
|
+
styles: S(0)
|
|
204
|
+
}, e);
|
|
205
|
+
}
|
|
206
|
+
function M(e = {}) {
|
|
207
|
+
return y({
|
|
208
|
+
id: b(),
|
|
209
|
+
type: "html",
|
|
210
|
+
...d,
|
|
211
|
+
styles: S()
|
|
212
|
+
}, e);
|
|
213
|
+
}
|
|
214
|
+
function N(e = {}) {
|
|
215
|
+
return y({
|
|
216
|
+
id: b(),
|
|
217
|
+
type: "menu",
|
|
218
|
+
items: [],
|
|
219
|
+
...f,
|
|
220
|
+
styles: S()
|
|
221
|
+
}, e);
|
|
222
|
+
}
|
|
223
|
+
function P(e, t) {
|
|
224
|
+
return Array.from({ length: t }, () => ({
|
|
225
|
+
id: b(),
|
|
226
|
+
cells: Array.from({ length: e }, () => ({
|
|
227
|
+
id: b(),
|
|
228
|
+
content: ""
|
|
229
|
+
}))
|
|
230
|
+
}));
|
|
231
|
+
}
|
|
232
|
+
function F(e = {}) {
|
|
233
|
+
return y({
|
|
234
|
+
id: b(),
|
|
235
|
+
type: "table",
|
|
236
|
+
rows: P(3, 3),
|
|
237
|
+
...p,
|
|
238
|
+
styles: S()
|
|
239
|
+
}, e);
|
|
240
|
+
}
|
|
241
|
+
function I(e = {}) {
|
|
242
|
+
return y({
|
|
243
|
+
id: b(),
|
|
244
|
+
type: "countdown",
|
|
245
|
+
...m,
|
|
246
|
+
styles: S()
|
|
247
|
+
}, e);
|
|
248
|
+
}
|
|
249
|
+
function L(e) {
|
|
250
|
+
return e.type === "repeatable" ? e.default ?? [] : e.type === "boolean" ? e.default ?? !1 : e.type === "number" ? e.default ?? 0 : e.default ?? "";
|
|
251
|
+
}
|
|
252
|
+
function R(e) {
|
|
253
|
+
let t = {};
|
|
254
|
+
for (let n of e.fields) t[n.key] = L(n);
|
|
255
|
+
return {
|
|
256
|
+
id: b(),
|
|
257
|
+
type: "custom",
|
|
258
|
+
customType: e.type,
|
|
259
|
+
fieldValues: t,
|
|
260
|
+
styles: S(),
|
|
261
|
+
...e.dataSource ? { dataSourceFetched: !1 } : {}
|
|
262
|
+
};
|
|
263
|
+
}
|
|
264
|
+
function z(e, t) {
|
|
265
|
+
switch (e) {
|
|
266
|
+
case "section": return O(t?.section);
|
|
267
|
+
case "title": return C(t?.title);
|
|
268
|
+
case "paragraph": return w(t?.paragraph);
|
|
269
|
+
case "image": return T(t?.image);
|
|
270
|
+
case "button": return E(t?.button);
|
|
271
|
+
case "divider": return D(t?.divider);
|
|
272
|
+
case "video": return k(t?.video);
|
|
273
|
+
case "social": return A(t?.social);
|
|
274
|
+
case "spacer": return j(t?.spacer);
|
|
275
|
+
case "html": return M(t?.html);
|
|
276
|
+
case "menu": return N(t?.menu);
|
|
277
|
+
case "table": return F(t?.table);
|
|
278
|
+
case "countdown": return I(t?.countdown);
|
|
279
|
+
default: throw Error(`Unknown block type: ${e}`);
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
function B(e) {
|
|
283
|
+
let t = JSON.parse(JSON.stringify(e));
|
|
284
|
+
return t.id = b(), t.type === "section" && (t.children = t.children.map((e) => e.map((e) => B(e)))), t;
|
|
285
|
+
}
|
|
286
|
+
var V = {
|
|
287
|
+
liquid: {
|
|
288
|
+
value: /\{\{.+?\}\}/g,
|
|
289
|
+
logic: /\{%-?\s*(\w+).*?-?%\}/g
|
|
290
|
+
},
|
|
291
|
+
handlebars: {
|
|
292
|
+
value: /\{\{\{?.+?\}?\}\}/g,
|
|
293
|
+
logic: /\{\{[#/](\w+).*?\}\}/g
|
|
294
|
+
},
|
|
295
|
+
mailchimp: {
|
|
296
|
+
value: /\*\|\w+\|\*/g,
|
|
297
|
+
logic: /\*\|(\w+)[:|].*?\|\*/g
|
|
298
|
+
},
|
|
299
|
+
ampscript: {
|
|
300
|
+
value: /%%=.+?=%%/g,
|
|
301
|
+
logic: /%%\[\s*(\w+).*?\]%%/g
|
|
302
|
+
}
|
|
303
|
+
}, H = {
|
|
304
|
+
liquid: "{{",
|
|
305
|
+
handlebars: "{{",
|
|
306
|
+
mailchimp: "*|",
|
|
307
|
+
ampscript: "%%="
|
|
308
|
+
};
|
|
309
|
+
function U(e) {
|
|
310
|
+
for (let t of Object.keys(V)) if (V[t].value.source === e.value.source) return H[t];
|
|
311
|
+
return null;
|
|
312
|
+
}
|
|
313
|
+
function W(e) {
|
|
314
|
+
return e ? typeof e == "string" ? V[e] ?? V.liquid : e : V.liquid;
|
|
315
|
+
}
|
|
316
|
+
function G(e) {
|
|
317
|
+
let t = e.source, n = e.flags.replace("g", "");
|
|
318
|
+
return RegExp(`^${t}$`, n);
|
|
319
|
+
}
|
|
320
|
+
function K(e, t) {
|
|
321
|
+
let n = e?.trim() || "";
|
|
322
|
+
return G(t.logic).test(n) ? !1 : G(t.value).test(n);
|
|
323
|
+
}
|
|
324
|
+
function q(e, t) {
|
|
325
|
+
let n = t.find((t) => t.value === e);
|
|
326
|
+
return n ? n.label : e;
|
|
327
|
+
}
|
|
328
|
+
function J(e, t) {
|
|
329
|
+
return e.replace(/(<span[^>]*\sdata-merge-tag="([^"]*)"[^>]*>)(.*?)(<\/span>)/g, (e, n, r, i, a) => `${n}${q(r, t)}${a}`);
|
|
330
|
+
}
|
|
331
|
+
function Y(e, t) {
|
|
332
|
+
if (!e) return !1;
|
|
333
|
+
let n = new RegExp(t.value.source, t.value.flags), r = new RegExp(t.logic.source, t.logic.flags);
|
|
334
|
+
return n.test(e) || r.test(e);
|
|
335
|
+
}
|
|
336
|
+
function X(e, t) {
|
|
337
|
+
return G(t.logic).test(e?.trim() || "");
|
|
338
|
+
}
|
|
339
|
+
function Z(e, t) {
|
|
340
|
+
let n = new RegExp(t.logic.source, t.logic.flags.replace("g", "")), r = e.match(n);
|
|
341
|
+
return r && r[1] ? r[1].toUpperCase() : e;
|
|
342
|
+
}
|
|
343
|
+
function Q(e, t) {
|
|
344
|
+
return e.replace(/(<span[^>]*\sdata-logic-merge-tag="([^"]*)"[^>]*>)(.*?)(<\/span>)/g, (e, n, r, i, a) => `${n}${Z(r, t)}${a}`);
|
|
345
|
+
}
|
|
346
|
+
var $ = class extends Error {
|
|
347
|
+
constructor(e, t) {
|
|
348
|
+
super(e), this.statusCode = t, this.name = "SdkError";
|
|
349
|
+
}
|
|
350
|
+
statusCode;
|
|
351
|
+
get isNotFound() {
|
|
352
|
+
return this.statusCode === 404;
|
|
353
|
+
}
|
|
354
|
+
get isUnauthorized() {
|
|
355
|
+
return this.statusCode === 401;
|
|
356
|
+
}
|
|
357
|
+
get isServerError() {
|
|
358
|
+
return this.statusCode !== void 0 && this.statusCode >= 500;
|
|
359
|
+
}
|
|
360
|
+
};
|
|
361
|
+
//#endregion
|
|
362
|
+
export { J as A, Z as C, X as D, t as E, K as O, b as S, U as T, A as _, Y as a, C as b, I as c, D as d, M as f, O as g, w as h, B as i, W as j, Q as k, R as l, N as m, V as n, z as o, T as p, $ as r, E as s, e as t, v as u, j as v, q as w, k as x, F as y };
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { Gt as e, Ht as t, Ut as n, c as r } from "./dist-iLBdeBDR.js";
|
|
2
|
+
//#region ../../node_modules/.pnpm/@tiptap+extension-highlight@3.22.5_@tiptap+core@3.22.5_@tiptap+pm@3.22.5_/node_modules/@tiptap/extension-highlight/dist/index.js
|
|
3
|
+
var i = /(?:^|\s)(==(?!\s+==)((?:[^=]+))==(?!\s+==))$/, a = /(?:^|\s)(==(?!\s+==)((?:[^=]+))==(?!\s+==))/g, o = r.create({
|
|
4
|
+
name: "highlight",
|
|
5
|
+
addOptions() {
|
|
6
|
+
return {
|
|
7
|
+
multicolor: !1,
|
|
8
|
+
HTMLAttributes: {}
|
|
9
|
+
};
|
|
10
|
+
},
|
|
11
|
+
addAttributes() {
|
|
12
|
+
return this.options.multicolor ? { color: {
|
|
13
|
+
default: null,
|
|
14
|
+
parseHTML: (e) => e.getAttribute("data-color") || e.style.backgroundColor,
|
|
15
|
+
renderHTML: (e) => e.color ? {
|
|
16
|
+
"data-color": e.color,
|
|
17
|
+
style: `background-color: ${e.color}; color: inherit`
|
|
18
|
+
} : {}
|
|
19
|
+
} } : {};
|
|
20
|
+
},
|
|
21
|
+
parseHTML() {
|
|
22
|
+
return [{ tag: "mark" }];
|
|
23
|
+
},
|
|
24
|
+
renderHTML({ HTMLAttributes: t }) {
|
|
25
|
+
return [
|
|
26
|
+
"mark",
|
|
27
|
+
e(this.options.HTMLAttributes, t),
|
|
28
|
+
0
|
|
29
|
+
];
|
|
30
|
+
},
|
|
31
|
+
renderMarkdown: (e, t) => `==${t.renderChildren(e)}==`,
|
|
32
|
+
parseMarkdown: (e, t) => t.applyMark("highlight", t.parseInline(e.tokens || [])),
|
|
33
|
+
markdownTokenizer: {
|
|
34
|
+
name: "highlight",
|
|
35
|
+
level: "inline",
|
|
36
|
+
start: (e) => e.indexOf("=="),
|
|
37
|
+
tokenize(e, t, n) {
|
|
38
|
+
let r = /^(==)([^=]+)(==)/.exec(e);
|
|
39
|
+
if (r) {
|
|
40
|
+
let e = r[2].trim(), t = n.inlineTokens(e);
|
|
41
|
+
return {
|
|
42
|
+
type: "highlight",
|
|
43
|
+
raw: r[0],
|
|
44
|
+
text: e,
|
|
45
|
+
tokens: t
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
addCommands() {
|
|
51
|
+
return {
|
|
52
|
+
setHighlight: (e) => ({ commands: t }) => t.setMark(this.name, e),
|
|
53
|
+
toggleHighlight: (e) => ({ commands: t }) => t.toggleMark(this.name, e),
|
|
54
|
+
unsetHighlight: () => ({ commands: e }) => e.unsetMark(this.name)
|
|
55
|
+
};
|
|
56
|
+
},
|
|
57
|
+
addKeyboardShortcuts() {
|
|
58
|
+
return { "Mod-Shift-h": () => this.editor.commands.toggleHighlight() };
|
|
59
|
+
},
|
|
60
|
+
addInputRules() {
|
|
61
|
+
return [t({
|
|
62
|
+
find: i,
|
|
63
|
+
type: this.type
|
|
64
|
+
})];
|
|
65
|
+
},
|
|
66
|
+
addPasteRules() {
|
|
67
|
+
return [n({
|
|
68
|
+
find: a,
|
|
69
|
+
type: this.type
|
|
70
|
+
})];
|
|
71
|
+
}
|
|
72
|
+
}), s = o;
|
|
73
|
+
//#endregion
|
|
74
|
+
export { o as Highlight, s as default, i as inputRegex, a as pasteRegex };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { Gt as e, c as t } from "./dist-iLBdeBDR.js";
|
|
2
|
+
//#region ../../node_modules/.pnpm/@tiptap+extension-underline@3.22.5_@tiptap+core@3.22.5_@tiptap+pm@3.22.5_/node_modules/@tiptap/extension-underline/dist/index.js
|
|
3
|
+
var n = t.create({
|
|
4
|
+
name: "underline",
|
|
5
|
+
addOptions() {
|
|
6
|
+
return { HTMLAttributes: {} };
|
|
7
|
+
},
|
|
8
|
+
parseHTML() {
|
|
9
|
+
return [{ tag: "u" }, {
|
|
10
|
+
style: "text-decoration",
|
|
11
|
+
consuming: !1,
|
|
12
|
+
getAttrs: (e) => e.includes("underline") ? {} : !1
|
|
13
|
+
}];
|
|
14
|
+
},
|
|
15
|
+
renderHTML({ HTMLAttributes: t }) {
|
|
16
|
+
return [
|
|
17
|
+
"u",
|
|
18
|
+
e(this.options.HTMLAttributes, t),
|
|
19
|
+
0
|
|
20
|
+
];
|
|
21
|
+
},
|
|
22
|
+
parseMarkdown(e, t) {
|
|
23
|
+
return t.applyMark(this.name || "underline", t.parseInline(e.tokens || []));
|
|
24
|
+
},
|
|
25
|
+
renderMarkdown(e, t) {
|
|
26
|
+
return `++${t.renderChildren(e)}++`;
|
|
27
|
+
},
|
|
28
|
+
markdownTokenizer: {
|
|
29
|
+
name: "underline",
|
|
30
|
+
level: "inline",
|
|
31
|
+
start(e) {
|
|
32
|
+
return e.indexOf("++");
|
|
33
|
+
},
|
|
34
|
+
tokenize(e, t, n) {
|
|
35
|
+
let r = /^(\+\+)([\s\S]+?)(\+\+)/.exec(e);
|
|
36
|
+
if (!r) return;
|
|
37
|
+
let i = r[2].trim();
|
|
38
|
+
return {
|
|
39
|
+
type: "underline",
|
|
40
|
+
raw: r[0],
|
|
41
|
+
text: i,
|
|
42
|
+
tokens: n.inlineTokens(i)
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
addCommands() {
|
|
47
|
+
return {
|
|
48
|
+
setUnderline: () => ({ commands: e }) => e.setMark(this.name),
|
|
49
|
+
toggleUnderline: () => ({ commands: e }) => e.toggleMark(this.name),
|
|
50
|
+
unsetUnderline: () => ({ commands: e }) => e.unsetMark(this.name)
|
|
51
|
+
};
|
|
52
|
+
},
|
|
53
|
+
addKeyboardShortcuts() {
|
|
54
|
+
return {
|
|
55
|
+
"Mod-u": () => this.editor.commands.toggleUnderline(),
|
|
56
|
+
"Mod-U": () => this.editor.commands.toggleUnderline()
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
}), r = n;
|
|
60
|
+
//#endregion
|
|
61
|
+
export { n as Underline, r as default };
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { Gt as e, c as t } from "./dist-iLBdeBDR.js";
|
|
2
|
+
//#region ../../node_modules/.pnpm/@tiptap+extension-superscript@3.22.5_@tiptap+core@3.22.5_@tiptap+pm@3.22.5__@tiptap+pm@3.22.5/node_modules/@tiptap/extension-superscript/dist/index.js
|
|
3
|
+
var n = t.create({
|
|
4
|
+
name: "superscript",
|
|
5
|
+
addOptions() {
|
|
6
|
+
return { HTMLAttributes: {} };
|
|
7
|
+
},
|
|
8
|
+
parseHTML() {
|
|
9
|
+
return [{ tag: "sup" }, {
|
|
10
|
+
style: "vertical-align",
|
|
11
|
+
getAttrs(e) {
|
|
12
|
+
return e === "super" ? null : !1;
|
|
13
|
+
}
|
|
14
|
+
}];
|
|
15
|
+
},
|
|
16
|
+
renderHTML({ HTMLAttributes: t }) {
|
|
17
|
+
return [
|
|
18
|
+
"sup",
|
|
19
|
+
e(this.options.HTMLAttributes, t),
|
|
20
|
+
0
|
|
21
|
+
];
|
|
22
|
+
},
|
|
23
|
+
addCommands() {
|
|
24
|
+
return {
|
|
25
|
+
setSuperscript: () => ({ commands: e }) => e.setMark(this.name),
|
|
26
|
+
toggleSuperscript: () => ({ commands: e }) => e.toggleMark(this.name),
|
|
27
|
+
unsetSuperscript: () => ({ commands: e }) => e.unsetMark(this.name)
|
|
28
|
+
};
|
|
29
|
+
},
|
|
30
|
+
addKeyboardShortcuts() {
|
|
31
|
+
return { "Mod-.": () => this.editor.commands.toggleSuperscript() };
|
|
32
|
+
}
|
|
33
|
+
}), r = n;
|
|
34
|
+
//#endregion
|
|
35
|
+
export { n as Superscript, r as default };
|