sprintify-ui 0.10.80 → 0.10.82
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/{BaseCkeditor-B4PbYw6a.js → BaseCkeditor-Laq0HbvP.js} +49 -32
- package/dist/sprintify-ui.es.js +31388 -14290
- package/dist/style.css +2 -2
- package/dist/types/components/BaseCkeditor.vue.d.ts +2 -6
- package/dist/types/components/BaseGantt.vue.d.ts +12 -12
- package/dist/types/components/BaseRichText.vue.d.ts +8 -2
- package/dist/types/components/BaseTipTap.vue.d.ts +14 -0
- package/package.json +8 -4
- package/src/assets/base-rich-text.css +32 -1
- package/src/components/BaseCkeditor.vue +22 -8
- package/src/components/BaseRichText.stories.js +9 -0
- package/src/components/BaseRichText.vue +21 -6
- package/src/components/BaseTipTap.vue +259 -0
|
@@ -1,29 +1,47 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ClassicEditor as B, BalloonEditor as k, InlineEditor as y, Essentials as z, SourceEditing as E, Paragraph as v, Bold as C, Italic as T, Underline as V, Code as h, CodeBlock as w, List as F, Link as L, Autoformat as R, Heading as S, Image as A, AutoImage as D, ImageStyle as P, ImageResize as U, ImageToolbar as
|
|
1
|
+
import { defineComponent as c, computed as r, createBlock as f, openBlock as I, unref as n } from "vue";
|
|
2
|
+
import { ClassicEditor as B, BalloonEditor as k, InlineEditor as y, Essentials as z, SourceEditing as E, Paragraph as v, Bold as C, Italic as T, Underline as V, Code as h, CodeBlock as w, List as F, Link as L, Autoformat as R, Heading as S, Image as A, AutoImage as D, ImageStyle as P, ImageResize as U, ImageToolbar as x, ImageInsert as G, Base64UploadAdapter as O, Table as H, TableToolbar as K, MediaEmbed as M, PasteFromOffice as N, BlockToolbar as W, Font as j, FindAndReplace as q, RemoveFormat as J } from "ckeditor5";
|
|
3
3
|
import { Ckeditor as Q } from "@ckeditor/ckeditor5-vue";
|
|
4
|
-
const $ = /* @__PURE__ */
|
|
4
|
+
const $ = /* @__PURE__ */ c({
|
|
5
5
|
__name: "BaseCkeditor",
|
|
6
6
|
props: {
|
|
7
7
|
modelValue: {},
|
|
8
8
|
editor: { default: "classic" },
|
|
9
9
|
size: { default: "md" },
|
|
10
10
|
toolbar: { default() {
|
|
11
|
-
return [
|
|
11
|
+
return [
|
|
12
|
+
"undo",
|
|
13
|
+
"redo",
|
|
14
|
+
"|",
|
|
15
|
+
"sourceEditing",
|
|
16
|
+
"heading",
|
|
17
|
+
"bold",
|
|
18
|
+
"italic",
|
|
19
|
+
"underline",
|
|
20
|
+
"|",
|
|
21
|
+
"link",
|
|
22
|
+
"insertImage",
|
|
23
|
+
"|",
|
|
24
|
+
"numberedList",
|
|
25
|
+
"bulletedList",
|
|
26
|
+
"|",
|
|
27
|
+
"code",
|
|
28
|
+
"codeblock",
|
|
29
|
+
"|",
|
|
30
|
+
"insertTable"
|
|
31
|
+
];
|
|
12
32
|
} },
|
|
13
33
|
placeholder: { default: "" },
|
|
14
|
-
disabled: { type: Boolean, default: !1 }
|
|
15
|
-
required: { type: Boolean, default: !1 },
|
|
16
|
-
name: { default: "" }
|
|
34
|
+
disabled: { type: Boolean, default: !1 }
|
|
17
35
|
},
|
|
18
36
|
emits: ["update:modelValue", "focus", "blur", "input", "ready"],
|
|
19
|
-
setup(d, { expose: u, emit:
|
|
20
|
-
const
|
|
21
|
-
let
|
|
22
|
-
function
|
|
23
|
-
|
|
37
|
+
setup(d, { expose: u, emit: s }) {
|
|
38
|
+
const o = d, a = s;
|
|
39
|
+
let t = null;
|
|
40
|
+
function m(i) {
|
|
41
|
+
t = i, a("ready", i);
|
|
24
42
|
}
|
|
25
|
-
const g =
|
|
26
|
-
switch (
|
|
43
|
+
const g = r(() => {
|
|
44
|
+
switch (o.editor) {
|
|
27
45
|
case "inline":
|
|
28
46
|
return y;
|
|
29
47
|
case "balloon":
|
|
@@ -31,7 +49,7 @@ const $ = /* @__PURE__ */ f({
|
|
|
31
49
|
default:
|
|
32
50
|
return B;
|
|
33
51
|
}
|
|
34
|
-
}), p =
|
|
52
|
+
}), p = r(() => o.modelValue === null ? "" : o.modelValue), b = r(() => ({
|
|
35
53
|
licenseKey: "GPL",
|
|
36
54
|
plugins: [
|
|
37
55
|
z,
|
|
@@ -50,20 +68,20 @@ const $ = /* @__PURE__ */ f({
|
|
|
50
68
|
D,
|
|
51
69
|
P,
|
|
52
70
|
U,
|
|
71
|
+
x,
|
|
53
72
|
G,
|
|
54
73
|
O,
|
|
55
|
-
q,
|
|
56
|
-
x,
|
|
57
74
|
H,
|
|
58
75
|
K,
|
|
59
76
|
M,
|
|
60
77
|
N,
|
|
61
78
|
W,
|
|
62
79
|
j,
|
|
80
|
+
q,
|
|
63
81
|
J
|
|
64
82
|
],
|
|
65
83
|
toolbar: {
|
|
66
|
-
items:
|
|
84
|
+
items: o.toolbar,
|
|
67
85
|
shouldNotGroupWhenFull: !0
|
|
68
86
|
},
|
|
69
87
|
table: {
|
|
@@ -99,24 +117,23 @@ const $ = /* @__PURE__ */ f({
|
|
|
99
117
|
"resizeImage"
|
|
100
118
|
]
|
|
101
119
|
},
|
|
102
|
-
placeholder:
|
|
120
|
+
placeholder: o.placeholder
|
|
103
121
|
}));
|
|
104
122
|
return u({
|
|
105
123
|
getEditorData() {
|
|
106
|
-
return (
|
|
124
|
+
return (t == null ? void 0 : t.getData()) || "";
|
|
107
125
|
}
|
|
108
|
-
}), (
|
|
109
|
-
"model-value":
|
|
110
|
-
editor:
|
|
111
|
-
config:
|
|
112
|
-
disabled:
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
}, null, 8, ["model-value", "editor", "config", "disabled", "name"]));
|
|
126
|
+
}), (i, e) => (I(), f(n(Q), {
|
|
127
|
+
"model-value": n(p),
|
|
128
|
+
editor: n(g),
|
|
129
|
+
config: n(b),
|
|
130
|
+
disabled: i.disabled,
|
|
131
|
+
"onUpdate:modelValue": e[0] || (e[0] = (l) => a("update:modelValue", l)),
|
|
132
|
+
onFocus: e[1] || (e[1] = (l) => a("focus", l)),
|
|
133
|
+
onBlur: e[2] || (e[2] = (l) => a("blur", l)),
|
|
134
|
+
onInput: e[3] || (e[3] = (l) => a("input", l)),
|
|
135
|
+
onReady: m
|
|
136
|
+
}, null, 8, ["model-value", "editor", "config", "disabled"]));
|
|
120
137
|
}
|
|
121
138
|
});
|
|
122
139
|
export {
|