@zealsolutions/zeal-ui 1.0.0-alpha.353 → 1.0.0-alpha.355
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/sop-diff/index.js +151 -141
- package/dist/components/tiptap/index.js +598 -595
- package/package.json +1 -1
|
@@ -1,152 +1,152 @@
|
|
|
1
|
-
import { computed as q, openBlock as f, createElementBlock as
|
|
2
|
-
import { _ as
|
|
3
|
-
const
|
|
4
|
-
class
|
|
5
|
-
constructor(
|
|
6
|
-
this.start_in_before =
|
|
1
|
+
import { computed as q, openBlock as f, createElementBlock as y, createElementVNode as v, toDisplayString as x, createCommentVNode as S, Fragment as D, renderList as F, normalizeClass as B, createStaticVNode as V } from "vue";
|
|
2
|
+
import { _ as T } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
|
|
3
|
+
const U = (e) => e === ">", A = (e) => e === "<", P = (e) => /^\s+$/.test(e), E = (e) => /^\s*<[^>]+>\s*$/.test(e), j = (e) => !E(e);
|
|
4
|
+
class O {
|
|
5
|
+
constructor(t, i, n) {
|
|
6
|
+
this.start_in_before = t, this.start_in_after = i, this.length = n, this.end_in_before = t + n - 1, this.end_in_after = i + n - 1;
|
|
7
7
|
}
|
|
8
8
|
}
|
|
9
9
|
function N(e) {
|
|
10
|
-
let
|
|
10
|
+
let t = "char", i = "";
|
|
11
11
|
const n = [];
|
|
12
|
-
for (let
|
|
13
|
-
const
|
|
14
|
-
switch (
|
|
12
|
+
for (let r = 0, a = e.length; r < a; r++) {
|
|
13
|
+
const l = e[r];
|
|
14
|
+
switch (t) {
|
|
15
15
|
case "tag":
|
|
16
|
-
|
|
16
|
+
U(l) ? (i += ">", n.push(i), i = "", t = P(l) ? "whitespace" : "char") : i += l;
|
|
17
17
|
break;
|
|
18
18
|
case "char":
|
|
19
|
-
A(
|
|
19
|
+
A(l) ? (i && n.push(i), i = "<", t = "tag") : /\s/.test(l) ? (i && n.push(i), i = l, t = "whitespace") : /[\w#@]+/i.test(l) ? i += l : (i && n.push(i), i = l);
|
|
20
20
|
break;
|
|
21
21
|
case "whitespace":
|
|
22
|
-
A(
|
|
22
|
+
A(l) ? (i && n.push(i), i = "<", t = "tag") : P(l) ? i += l : (i && n.push(i), i = l, t = "char");
|
|
23
23
|
break;
|
|
24
24
|
default:
|
|
25
|
-
throw new Error("Unknown mode " +
|
|
25
|
+
throw new Error("Unknown mode " + t);
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
|
-
return
|
|
28
|
+
return i && n.push(i), n;
|
|
29
29
|
}
|
|
30
|
-
function
|
|
31
|
-
let
|
|
32
|
-
for (let o = n; o <
|
|
33
|
-
const _ = {}, g = e[o],
|
|
34
|
-
for (let
|
|
35
|
-
const
|
|
36
|
-
if (
|
|
30
|
+
function H(e, t, i, n, r, a, l) {
|
|
31
|
+
let u = n, s = a, d = 0, c = {}, p;
|
|
32
|
+
for (let o = n; o < r; o++) {
|
|
33
|
+
const _ = {}, g = e[o], h = i[g];
|
|
34
|
+
for (let R = 0, L = h.length; R < L; R++) {
|
|
35
|
+
const b = h[R];
|
|
36
|
+
if (b < a)
|
|
37
37
|
continue;
|
|
38
|
-
if (
|
|
38
|
+
if (b >= l)
|
|
39
39
|
break;
|
|
40
|
-
c[
|
|
41
|
-
const k = c[
|
|
42
|
-
_[
|
|
40
|
+
c[b - 1] == null && (c[b - 1] = 0);
|
|
41
|
+
const k = c[b - 1] + 1;
|
|
42
|
+
_[b] = k, k > d && (u = o - k + 1, s = b - k + 1, d = k);
|
|
43
43
|
}
|
|
44
44
|
c = _;
|
|
45
45
|
}
|
|
46
|
-
return
|
|
46
|
+
return d !== 0 && (p = new O(u, s, d)), p;
|
|
47
47
|
}
|
|
48
|
-
function C(e,
|
|
49
|
-
const s =
|
|
50
|
-
return s != null && (n < s.start_in_before &&
|
|
48
|
+
function C(e, t, i, n, r, a, l, u) {
|
|
49
|
+
const s = H(e, t, i, n, r, a, l);
|
|
50
|
+
return s != null && (n < s.start_in_before && a < s.start_in_after && C(e, t, i, n, s.start_in_before, a, s.start_in_after, u), u.push(s), s.end_in_before <= r && s.end_in_after <= l && C(e, t, i, s.end_in_before + 1, r, s.end_in_after + 1, l, u)), u;
|
|
51
51
|
}
|
|
52
|
-
function
|
|
52
|
+
function W(e) {
|
|
53
53
|
if (e.find_these == null)
|
|
54
54
|
throw new Error("params must have find_these key");
|
|
55
55
|
if (e.in_these == null)
|
|
56
56
|
throw new Error("params must have in_these key");
|
|
57
|
-
const
|
|
58
|
-
for (let
|
|
59
|
-
const
|
|
60
|
-
|
|
61
|
-
let
|
|
62
|
-
for (;
|
|
63
|
-
|
|
57
|
+
const t = {};
|
|
58
|
+
for (let i = 0, n = e.find_these.length; i < n; i++) {
|
|
59
|
+
const r = e.find_these[i];
|
|
60
|
+
t[r] = [];
|
|
61
|
+
let a = e.in_these.indexOf(r);
|
|
62
|
+
for (; a !== -1; )
|
|
63
|
+
t[r].push(a), a = e.in_these.indexOf(r, a + 1);
|
|
64
64
|
}
|
|
65
|
-
return
|
|
65
|
+
return t;
|
|
66
66
|
}
|
|
67
|
-
function
|
|
68
|
-
const
|
|
69
|
-
return C(e,
|
|
67
|
+
function $(e, t) {
|
|
68
|
+
const i = [], n = W({ find_these: e, in_these: t });
|
|
69
|
+
return C(e, t, n, 0, e.length, 0, t.length, i);
|
|
70
70
|
}
|
|
71
|
-
function
|
|
71
|
+
function z(e, t) {
|
|
72
72
|
if (e == null)
|
|
73
73
|
throw new Error("before_tokens?");
|
|
74
|
-
if (
|
|
74
|
+
if (t == null)
|
|
75
75
|
throw new Error("after_tokens?");
|
|
76
|
-
let
|
|
77
|
-
const
|
|
76
|
+
let i = 0, n = 0;
|
|
77
|
+
const r = [], a = {
|
|
78
78
|
"false,false": "replace",
|
|
79
79
|
"true,false": "insert",
|
|
80
80
|
"false,true": "delete",
|
|
81
81
|
"true,true": "none"
|
|
82
|
-
},
|
|
83
|
-
|
|
84
|
-
for (let c = 0,
|
|
85
|
-
const o =
|
|
86
|
-
|
|
87
|
-
action:
|
|
88
|
-
start_in_before:
|
|
89
|
-
end_in_before:
|
|
82
|
+
}, l = $(e, t);
|
|
83
|
+
l.push(new O(e.length, t.length, 0));
|
|
84
|
+
for (let c = 0, p = l.length; c < p; c++) {
|
|
85
|
+
const o = l[c], _ = i === o.start_in_before, g = n === o.start_in_after, h = a[[_, g].toString()];
|
|
86
|
+
h !== "none" && r.push({
|
|
87
|
+
action: h,
|
|
88
|
+
start_in_before: i,
|
|
89
|
+
end_in_before: h !== "insert" ? o.start_in_before - 1 : void 0,
|
|
90
90
|
start_in_after: n,
|
|
91
|
-
end_in_after:
|
|
92
|
-
}), o.length !== 0 &&
|
|
91
|
+
end_in_after: h !== "delete" ? o.start_in_after - 1 : void 0
|
|
92
|
+
}), o.length !== 0 && r.push({
|
|
93
93
|
action: "equal",
|
|
94
94
|
start_in_before: o.start_in_before,
|
|
95
95
|
end_in_before: o.end_in_before,
|
|
96
96
|
start_in_after: o.start_in_after,
|
|
97
97
|
end_in_after: o.end_in_after
|
|
98
|
-
}),
|
|
98
|
+
}), i = o.end_in_before + 1, n = o.end_in_after + 1;
|
|
99
99
|
}
|
|
100
|
-
const
|
|
100
|
+
const u = [];
|
|
101
101
|
let s = { action: "none" };
|
|
102
|
-
const
|
|
103
|
-
for (let c = 0,
|
|
104
|
-
const o =
|
|
105
|
-
|
|
102
|
+
const d = (c) => c.action !== "equal" || c.end_in_before - c.start_in_before !== 0 ? !1 : /^\s$/.test(e.slice(c.start_in_before, +c.end_in_before + 1 || 9e9));
|
|
103
|
+
for (let c = 0, p = r.length; c < p; c++) {
|
|
104
|
+
const o = r[c];
|
|
105
|
+
d(o) && s.action === "replace" || o.action === "replace" && s.action === "replace" ? (s.end_in_before = o.end_in_before, s.end_in_after = o.end_in_after) : (u.push(o), s = o);
|
|
106
106
|
}
|
|
107
|
-
return
|
|
107
|
+
return u;
|
|
108
108
|
}
|
|
109
|
-
function G(e,
|
|
110
|
-
|
|
109
|
+
function G(e, t, i) {
|
|
110
|
+
t = t.slice(e, +t.length + 1 || 9e9);
|
|
111
111
|
let n;
|
|
112
|
-
for (let
|
|
113
|
-
const
|
|
114
|
-
if (
|
|
112
|
+
for (let r = 0, a = t.length; r < a; r++) {
|
|
113
|
+
const l = t[r], u = i(l);
|
|
114
|
+
if (u === !0 && (n = r), u === !1)
|
|
115
115
|
break;
|
|
116
116
|
}
|
|
117
|
-
return n != null ?
|
|
117
|
+
return n != null ? t.slice(0, +n + 1 || 9e9) : [];
|
|
118
118
|
}
|
|
119
|
-
function I(e,
|
|
120
|
-
let
|
|
121
|
-
const
|
|
122
|
-
for (; !(n >=
|
|
123
|
-
const
|
|
124
|
-
if (n +=
|
|
119
|
+
function I(e, t) {
|
|
120
|
+
let i = "", n = 0;
|
|
121
|
+
const r = t.length;
|
|
122
|
+
for (; !(n >= r); ) {
|
|
123
|
+
const a = G(n, t, j);
|
|
124
|
+
if (n += a.length, a.length !== 0 && (i += "<" + e + ">" + a.join("") + "</" + e + ">"), n >= r)
|
|
125
125
|
break;
|
|
126
|
-
const
|
|
127
|
-
n +=
|
|
126
|
+
const l = G(n, t, E);
|
|
127
|
+
n += l.length, i += l.join("");
|
|
128
128
|
}
|
|
129
|
-
return
|
|
129
|
+
return i;
|
|
130
130
|
}
|
|
131
131
|
const m = {
|
|
132
|
-
equal: (e,
|
|
133
|
-
insert: (e,
|
|
134
|
-
delete: (e,
|
|
132
|
+
equal: (e, t) => t.slice(e.start_in_before, +e.end_in_before + 1 || 9e9).join(""),
|
|
133
|
+
insert: (e, t, i) => I("ins", i.slice(e.start_in_after, +e.end_in_after + 1 || 9e9)),
|
|
134
|
+
delete: (e, t) => I("del", t.slice(e.start_in_before, +e.end_in_before + 1 || 9e9))
|
|
135
135
|
};
|
|
136
|
-
m.replace = (e,
|
|
137
|
-
function
|
|
136
|
+
m.replace = (e, t, i) => m.delete(e, t, i) + m.insert(e, t, i);
|
|
137
|
+
function Q(e, t, i) {
|
|
138
138
|
let n = "";
|
|
139
|
-
for (let
|
|
140
|
-
const
|
|
141
|
-
n += m[
|
|
139
|
+
for (let r = 0, a = i.length; r < a; r++) {
|
|
140
|
+
const l = i[r];
|
|
141
|
+
n += m[l.action](l, e, t);
|
|
142
142
|
}
|
|
143
143
|
return n;
|
|
144
144
|
}
|
|
145
|
-
function
|
|
146
|
-
if (e ===
|
|
145
|
+
function Y(e, t) {
|
|
146
|
+
if (e === t)
|
|
147
147
|
return e;
|
|
148
|
-
const
|
|
149
|
-
return
|
|
148
|
+
const i = N(e ?? ""), n = N(t ?? ""), r = z(i, n);
|
|
149
|
+
return Q(i, n, r);
|
|
150
150
|
}
|
|
151
151
|
const J = {
|
|
152
152
|
sop: {
|
|
@@ -165,7 +165,7 @@ const J = {
|
|
|
165
165
|
{ label: "Code", key: "SOPCode" },
|
|
166
166
|
// wire key "SOPCode" (SopReadService.GetSop) — see the draft-mode gap note above
|
|
167
167
|
{ label: "Core capabilities", key: "CoreCapabilities" },
|
|
168
|
-
{ label: "Active", key: "IsActive" },
|
|
168
|
+
{ label: "Active", key: "IsActive", bool: !0 },
|
|
169
169
|
{ label: "Summary", key: "Summary", rich: !0 },
|
|
170
170
|
{ label: "Generic Provisions", key: "GenericProvisions", rich: !0 },
|
|
171
171
|
{ label: "Further reading", key: "FurtherReading", rich: !0 },
|
|
@@ -203,8 +203,8 @@ const J = {
|
|
|
203
203
|
// wire key for entity `ResidualRiskConsequence`
|
|
204
204
|
{ label: "Residual Risk Likelihood", key: "ResidualLikelihood" },
|
|
205
205
|
// wire key for entity `ResidualRiskLikelihood`
|
|
206
|
-
{ label: "Active", key: "IsActive" },
|
|
207
|
-
{ label: "ECU Only", key: "IsNaruOnly" }
|
|
206
|
+
{ label: "Active", key: "IsActive", bool: !0 },
|
|
207
|
+
{ label: "ECU Only", key: "IsNaruOnly", bool: !0 }
|
|
208
208
|
// wire key for entity `IsNARUOnly`
|
|
209
209
|
]
|
|
210
210
|
},
|
|
@@ -227,7 +227,7 @@ const J = {
|
|
|
227
227
|
{ label: "Code", key: "TISCode" },
|
|
228
228
|
{ label: "Review Date", key: "ReviewDue" },
|
|
229
229
|
// wire key for entity `ReviewDate` (stored as String) — see the draft-mode gap note above
|
|
230
|
-
{ label: "Active", key: "IsActive" },
|
|
230
|
+
{ label: "Active", key: "IsActive", bool: !0 },
|
|
231
231
|
{ label: "Mandatory Frequency", key: "Frequency" },
|
|
232
232
|
// raw lookup id (SOPTISFrequencyID), NOT resolved display text — legacy resolves it via a DB lookup this record shape doesn't carry
|
|
233
233
|
{ label: "Mandatory Re-certification", key: "Recert" }
|
|
@@ -250,9 +250,9 @@ const J = {
|
|
|
250
250
|
{ label: "Review Due By", key: "ReviewDue" },
|
|
251
251
|
{ label: "Service Line", key: "ServiceLine" },
|
|
252
252
|
{ label: "Summary", key: "Summary", rich: !0 },
|
|
253
|
-
{ label: "Active", key: "IsActive" },
|
|
253
|
+
{ label: "Active", key: "IsActive", bool: !0 },
|
|
254
254
|
// bug #3 — appears once, not twice
|
|
255
|
-
{ label: "ECU Only", key: "IsNaruOnly" },
|
|
255
|
+
{ label: "ECU Only", key: "IsNaruOnly", bool: !0 },
|
|
256
256
|
// bug #3 — legacy comments this row out; included as a real edited field
|
|
257
257
|
{ label: "Personal Issue", key: "PersonalIssue" },
|
|
258
258
|
{ label: "Is Personal Issue - can it be re-issued? Only", key: "PersonalReIssue" },
|
|
@@ -295,8 +295,8 @@ const J = {
|
|
|
295
295
|
// bug #4
|
|
296
296
|
{ label: "Equipment PPE", key: "EquipmentPPE", rich: !0 },
|
|
297
297
|
// bug #4
|
|
298
|
-
{ label: "Active", key: "IsActive" },
|
|
299
|
-
{ label: "ECU Only", key: "IsNARUOnly" }
|
|
298
|
+
{ label: "Active", key: "IsActive", bool: !0 },
|
|
299
|
+
{ label: "ECU Only", key: "IsNARUOnly", bool: !0 }
|
|
300
300
|
]
|
|
301
301
|
},
|
|
302
302
|
activity: {
|
|
@@ -310,9 +310,9 @@ const J = {
|
|
|
310
310
|
// landing this config at 4.
|
|
311
311
|
{ label: "Name", key: "Name" },
|
|
312
312
|
{ label: "Activity content", key: "ActivityContent", rich: !0 },
|
|
313
|
-
{ label: "Active", key: "IsActive" },
|
|
313
|
+
{ label: "Active", key: "IsActive", bool: !0 },
|
|
314
314
|
// not present on the draft/amend read shape — see the draft-mode gap note above
|
|
315
|
-
{ label: "ECU Only", key: "IsNaruOnly" }
|
|
315
|
+
{ label: "ECU Only", key: "IsNaruOnly", bool: !0 }
|
|
316
316
|
// not present on the draft/amend read shape — see the draft-mode gap note above
|
|
317
317
|
]
|
|
318
318
|
},
|
|
@@ -322,8 +322,8 @@ const J = {
|
|
|
322
322
|
// sop-appendix-view-compare.aspx diffs exactly 4 fields: Name, PageContents, Active, ECU Only.
|
|
323
323
|
{ label: "Name", key: "Name" },
|
|
324
324
|
{ label: "Content", key: "PageContents", rich: !0 },
|
|
325
|
-
{ label: "Active", key: "IsActive" },
|
|
326
|
-
{ label: "ECU Only", key: "IsNaruOnly" }
|
|
325
|
+
{ label: "Active", key: "IsActive", bool: !0 },
|
|
326
|
+
{ label: "ECU Only", key: "IsNaruOnly", bool: !0 }
|
|
327
327
|
// wire key for entity `IsNARUOnly` — see the draft-mode gap note above
|
|
328
328
|
]
|
|
329
329
|
}
|
|
@@ -331,44 +331,54 @@ const J = {
|
|
|
331
331
|
function w(e) {
|
|
332
332
|
return e == null ? !1 : String(e).replace(/<[^>]*>/g, "").replace(/ /g, " ").trim().length > 0;
|
|
333
333
|
}
|
|
334
|
-
function
|
|
335
|
-
|
|
336
|
-
|
|
334
|
+
function M(e) {
|
|
335
|
+
if (e == null || e === "")
|
|
336
|
+
return "";
|
|
337
|
+
if (e === !0 || e === 1)
|
|
338
|
+
return "Yes";
|
|
339
|
+
if (e === !1 || e === 0)
|
|
340
|
+
return "No";
|
|
341
|
+
const t = String(e).trim().toLowerCase();
|
|
342
|
+
return t === "true" || t === "1" || t === "yes" ? "Yes" : t === "false" || t === "0" || t === "no" ? "No" : String(e);
|
|
343
|
+
}
|
|
344
|
+
function fe(e, t, i = {}, n = null) {
|
|
345
|
+
const r = J[e];
|
|
346
|
+
if (!r || !t)
|
|
337
347
|
return { title: "", sections: [] };
|
|
338
|
-
const
|
|
339
|
-
const
|
|
340
|
-
if (!
|
|
341
|
-
return w(
|
|
342
|
-
const c =
|
|
343
|
-
return !w(
|
|
348
|
+
const a = { ...t, ...i }, l = n ? { ...n, ...i } : null, u = r.fields.map((s) => {
|
|
349
|
+
const d = s.bool ? M(a[s.key]) : a[s.key];
|
|
350
|
+
if (!l)
|
|
351
|
+
return w(d) ? { label: s.label, value: d, rich: !!s.rich } : null;
|
|
352
|
+
const c = s.bool ? M(l[s.key]) : l[s.key];
|
|
353
|
+
return !w(d) && !w(c) ? null : {
|
|
344
354
|
label: s.label,
|
|
345
|
-
value:
|
|
355
|
+
value: Y(String(d ?? ""), String(c ?? "")),
|
|
346
356
|
rich: !!s.rich,
|
|
347
357
|
// original field richness — the modal uses it to pre-wrap plain diffs
|
|
348
358
|
diff: !0
|
|
349
359
|
};
|
|
350
360
|
}).filter(Boolean);
|
|
351
|
-
return { title:
|
|
361
|
+
return { title: r.title(n || t), sections: u };
|
|
352
362
|
}
|
|
353
|
-
const K = { class: "flex flex-col h-full overflow-hidden" }, X = { class: "text-style-sub-header font-medium text-app-950 leading-[1.3]" },
|
|
363
|
+
const K = { class: "flex flex-col h-full overflow-hidden" }, X = { class: "text-style-sub-header font-medium text-app-950 leading-[1.3]" }, Z = {
|
|
354
364
|
key: 0,
|
|
355
365
|
"data-testid": "preview-diff-legend",
|
|
356
366
|
class: "border-b-[1px] border-steel-300 px-6 py-[10px] flex items-center gap-[16px] text-[12px] text-[#697277] shrink-0"
|
|
357
|
-
},
|
|
367
|
+
}, ee = /* @__PURE__ */ V('<span class="font-semibold" data-v-781d71ec>Unpublished draft changes</span><span class="flex items-center gap-[5px]" data-v-781d71ec><span class="inline-block w-[14px] h-[10px] rounded-[2px]" style="background-color:#d4fcbc;" data-v-781d71ec></span>Added</span><span class="flex items-center gap-[5px]" data-v-781d71ec><span class="inline-block w-[14px] h-[10px] rounded-[2px]" style="background-color:#fbb6c2;" data-v-781d71ec></span>Removed</span>', 3), te = {
|
|
358
368
|
key: 0,
|
|
359
369
|
"data-testid": "preview-diff-loading",
|
|
360
370
|
class: "italic"
|
|
361
|
-
},
|
|
371
|
+
}, ie = { class: "flex-1 min-h-0 overflow-y-auto px-6 py-5" }, ne = {
|
|
362
372
|
key: 0,
|
|
363
373
|
"data-testid": "preview-empty",
|
|
364
374
|
class: "text-[14px] text-[#697277]"
|
|
365
|
-
},
|
|
375
|
+
}, re = {
|
|
366
376
|
key: 1,
|
|
367
377
|
class: "flex flex-col gap-6"
|
|
368
|
-
}, le = { class: "font-semibold text-[13px] text-[#326d68] dark:text-proclusteal-950 leading-[1.2] mb-[6px]" }, ae = ["innerHTML"],
|
|
378
|
+
}, le = { class: "font-semibold text-[13px] text-[#326d68] dark:text-proclusteal-950 leading-[1.2] mb-[6px]" }, ae = ["innerHTML"], se = ["innerHTML"], oe = {
|
|
369
379
|
key: 2,
|
|
370
380
|
class: "text-[15px] text-black-950 leading-[1.5] whitespace-pre-wrap"
|
|
371
|
-
},
|
|
381
|
+
}, ce = {
|
|
372
382
|
__name: "SopCompare",
|
|
373
383
|
props: {
|
|
374
384
|
title: { type: String, default: "" },
|
|
@@ -376,38 +386,38 @@ const K = { class: "flex flex-col h-full overflow-hidden" }, X = { class: "text-
|
|
|
376
386
|
loading: { type: Boolean, default: !1 }
|
|
377
387
|
},
|
|
378
388
|
setup(e) {
|
|
379
|
-
const
|
|
380
|
-
return (n,
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
e.loading ? (f(),
|
|
389
|
+
const t = e, i = q(() => t.sections.some((n) => n.diff));
|
|
390
|
+
return (n, r) => (f(), y("div", K, [
|
|
391
|
+
v("p", X, x(e.title), 1),
|
|
392
|
+
i.value || e.loading ? (f(), y("div", Z, [
|
|
393
|
+
ee,
|
|
394
|
+
e.loading ? (f(), y("span", te, "Loading changes…")) : S("", !0)
|
|
385
395
|
])) : S("", !0),
|
|
386
|
-
|
|
387
|
-
e.sections.length ? (f(),
|
|
388
|
-
(f(!0),
|
|
389
|
-
key:
|
|
396
|
+
v("div", ie, [
|
|
397
|
+
e.sections.length ? (f(), y("div", re, [
|
|
398
|
+
(f(!0), y(D, null, F(e.sections, (a, l) => (f(), y("section", {
|
|
399
|
+
key: l,
|
|
390
400
|
"data-testid": "preview-section"
|
|
391
401
|
}, [
|
|
392
|
-
|
|
393
|
-
|
|
402
|
+
v("p", le, x(a.label), 1),
|
|
403
|
+
a.diff ? (f(), y("div", {
|
|
394
404
|
key: 0,
|
|
395
|
-
class:
|
|
396
|
-
innerHTML:
|
|
397
|
-
}, null, 10, ae)) :
|
|
405
|
+
class: B(["preview-content text-[15px] text-black-950 leading-[1.5]", { "whitespace-pre-wrap": !a.rich }]),
|
|
406
|
+
innerHTML: a.value
|
|
407
|
+
}, null, 10, ae)) : a.rich ? (f(), y("div", {
|
|
398
408
|
key: 1,
|
|
399
409
|
class: "preview-content text-[15px] text-black-950 leading-[1.5]",
|
|
400
|
-
innerHTML:
|
|
401
|
-
}, null, 8,
|
|
410
|
+
innerHTML: a.value
|
|
411
|
+
}, null, 8, se)) : (f(), y("p", oe, x(a.value), 1))
|
|
402
412
|
]))), 128))
|
|
403
|
-
])) : (f(),
|
|
413
|
+
])) : (f(), y("p", ne, " There is no content to preview yet. "))
|
|
404
414
|
])
|
|
405
415
|
]));
|
|
406
416
|
}
|
|
407
|
-
},
|
|
417
|
+
}, ye = /* @__PURE__ */ T(ce, [["__scopeId", "data-v-781d71ec"]]);
|
|
408
418
|
export {
|
|
409
|
-
|
|
410
|
-
|
|
419
|
+
ye as SopCompare,
|
|
420
|
+
fe as buildPreview,
|
|
411
421
|
w as hasContent,
|
|
412
|
-
|
|
422
|
+
Y as htmlDiff
|
|
413
423
|
};
|