officialblock 2.2.6 → 2.2.8
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/index-B5hcRa3i.js +1 -0
- package/dist/index-Bal-eOOC.mjs +4 -0
- package/dist/{index-CSB-f2SH.js → index-COljEDP8.js} +1 -1
- package/dist/{index-CxDMH1MH.mjs → index-Coasm1Q-.mjs} +9805 -9795
- package/dist/{index-Yvkp7IRe.js → index-s8heSTAB.js} +33 -33
- package/dist/{index-BlhIDKnv.mjs → index-xjTh6E3G.mjs} +56 -34
- package/dist/official-block.cjs.js +1 -1
- package/dist/official-block.es.js +1 -1
- package/dist/official-block.umd.js +31 -31
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/index-BmST88vq.mjs +0 -4
- package/dist/index-DhZdVJgn.js +0 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var r = (a, u,
|
|
1
|
+
var $ = Object.defineProperty;
|
|
2
|
+
var D = (a, u, i) => u in a ? $(a, u, { enumerable: !0, configurable: !0, writable: !0, value: i }) : a[u] = i;
|
|
3
|
+
var r = (a, u, i) => D(a, typeof u != "symbol" ? u + "" : u, i);
|
|
4
4
|
import { defineComponent as A, shallowRef as R, ref as p, computed as F, inject as y, watch as C, nextTick as b, onBeforeUnmount as q, createElementBlock as J, openBlock as G, createVNode as I, unref as H, normalizeStyle as P } from "vue";
|
|
5
5
|
import { Toolbar as Q, Editor as W } from "@wangeditor/editor-for-vue";
|
|
6
|
-
import { Boot as
|
|
7
|
-
import { a as X } from "./index-
|
|
6
|
+
import { Boot as k } from "@wangeditor/editor";
|
|
7
|
+
import { a as X } from "./index-Coasm1Q-.mjs";
|
|
8
8
|
const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
9
9
|
__name: "index",
|
|
10
10
|
props: {
|
|
@@ -19,8 +19,8 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
19
19
|
includeKeys: { default: () => [] }
|
|
20
20
|
},
|
|
21
21
|
emits: ["update:modelValue", "change", "focus", "blur", "created", "upload-image", "upload-video"],
|
|
22
|
-
setup(a, { expose: u, emit:
|
|
23
|
-
const n = a, d =
|
|
22
|
+
setup(a, { expose: u, emit: i }) {
|
|
23
|
+
const n = a, d = i, t = R(), c = p(""), z = F(() => typeof n.height == "number" ? `${n.height}px` : n.height), x = y("handleUpload", () => {
|
|
24
24
|
}), m = y("fileUrl", null), M = y("chooseName", null), f = p(""), h = p(null), V = (e) => {
|
|
25
25
|
if (!x) {
|
|
26
26
|
console.warn("Upload: handleUpload function not provided by ancestor");
|
|
@@ -77,7 +77,7 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
77
77
|
},
|
|
78
78
|
{ immediate: !1 }
|
|
79
79
|
);
|
|
80
|
-
function
|
|
80
|
+
function K(e) {
|
|
81
81
|
return class {
|
|
82
82
|
constructor() {
|
|
83
83
|
r(this, "title");
|
|
@@ -101,7 +101,7 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
101
101
|
}
|
|
102
102
|
};
|
|
103
103
|
}
|
|
104
|
-
function
|
|
104
|
+
function L(e) {
|
|
105
105
|
return class {
|
|
106
106
|
constructor() {
|
|
107
107
|
r(this, "title");
|
|
@@ -125,7 +125,7 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
125
125
|
}
|
|
126
126
|
};
|
|
127
127
|
}
|
|
128
|
-
const
|
|
128
|
+
const S = {
|
|
129
129
|
toolbarKeys: [
|
|
130
130
|
// 菜单 key
|
|
131
131
|
"headerSelect",
|
|
@@ -159,6 +159,9 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
159
159
|
// 左对齐
|
|
160
160
|
"justifyRight",
|
|
161
161
|
// 右对齐
|
|
162
|
+
"bulletedList",
|
|
163
|
+
"numberedList",
|
|
164
|
+
// 列表
|
|
162
165
|
"undo",
|
|
163
166
|
// 撤销
|
|
164
167
|
"redo",
|
|
@@ -168,15 +171,34 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
168
171
|
"codeBlock"
|
|
169
172
|
//代码块
|
|
170
173
|
]
|
|
171
|
-
},
|
|
174
|
+
}, N = {
|
|
172
175
|
placeholder: n.placeholder,
|
|
173
176
|
readOnly: n.disabled,
|
|
174
177
|
maxLength: n.maxLength,
|
|
175
|
-
MENU_CONF: {}
|
|
176
|
-
|
|
178
|
+
MENU_CONF: {},
|
|
179
|
+
// --- 新增:自定义选中文字时的气泡菜单 ---
|
|
180
|
+
hoverbarKeys: {
|
|
181
|
+
// text 类型代表选中文字时弹出的菜单
|
|
182
|
+
text: {
|
|
183
|
+
// 通过配置来覆盖默认菜单
|
|
184
|
+
// 我们重新定义 key 列表,排除掉 'color' (文字颜色) 和 'bgColor' (背景色)
|
|
185
|
+
menuKeys: [
|
|
186
|
+
"headerSelect",
|
|
187
|
+
"insertLink",
|
|
188
|
+
"bold",
|
|
189
|
+
"italic",
|
|
190
|
+
"underline",
|
|
191
|
+
"through",
|
|
192
|
+
// 'color', <-- 去掉这两个
|
|
193
|
+
// 'bgColor', <-- 去掉这两个
|
|
194
|
+
"clearStyle"
|
|
195
|
+
]
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
}, B = Math.random().toString(36).substring(2, 9), _ = `CustomImageMenu_${B}`, w = `CustomVideoMenu_${B}`, O = (e) => {
|
|
177
199
|
t.value = e;
|
|
178
200
|
try {
|
|
179
|
-
const l =
|
|
201
|
+
const l = K(V), o = L(V), v = {
|
|
180
202
|
key: _,
|
|
181
203
|
// 使用唯一的 key
|
|
182
204
|
factory() {
|
|
@@ -189,11 +211,11 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
189
211
|
return new o();
|
|
190
212
|
}
|
|
191
213
|
};
|
|
192
|
-
|
|
214
|
+
k.registerMenu(v), k.registerMenu(s);
|
|
193
215
|
} catch (l) {
|
|
194
216
|
console.warn("菜单注册失败:", l);
|
|
195
217
|
}
|
|
196
|
-
|
|
218
|
+
S.insertKeys = {
|
|
197
219
|
index: 0,
|
|
198
220
|
keys: [_, w]
|
|
199
221
|
}, d("created", e);
|
|
@@ -204,22 +226,22 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
204
226
|
}), C(
|
|
205
227
|
() => n.modelValue,
|
|
206
228
|
(e) => {
|
|
207
|
-
e !==
|
|
229
|
+
e !== c.value && (c.value = e || "");
|
|
208
230
|
},
|
|
209
231
|
{ immediate: !0 }
|
|
210
232
|
);
|
|
211
|
-
const
|
|
212
|
-
d("update:modelValue",
|
|
213
|
-
},
|
|
233
|
+
const U = (e) => {
|
|
234
|
+
d("update:modelValue", c.value), d("change", e);
|
|
235
|
+
}, j = () => {
|
|
214
236
|
t.value = void 0;
|
|
215
|
-
},
|
|
237
|
+
}, E = (e) => {
|
|
216
238
|
d("focus", e);
|
|
217
|
-
},
|
|
239
|
+
}, T = (e) => {
|
|
218
240
|
d("blur", e);
|
|
219
241
|
};
|
|
220
242
|
return u({
|
|
221
243
|
editor: t,
|
|
222
|
-
getHtml: () =>
|
|
244
|
+
getHtml: () => c.value,
|
|
223
245
|
getText: () => {
|
|
224
246
|
var e;
|
|
225
247
|
return ((e = t.value) == null ? void 0 : e.getText()) || "";
|
|
@@ -252,25 +274,25 @@ const Y = { class: "rich-text-editor" }, Z = /* @__PURE__ */ A({
|
|
|
252
274
|
I(H(Q), {
|
|
253
275
|
class: "editor-toolbar",
|
|
254
276
|
editor: t.value,
|
|
255
|
-
defaultConfig:
|
|
277
|
+
defaultConfig: S,
|
|
256
278
|
mode: a.mode
|
|
257
279
|
}, null, 8, ["editor", "mode"]),
|
|
258
280
|
I(H(W), {
|
|
259
281
|
class: "editor-content",
|
|
260
|
-
style: P({ height:
|
|
261
|
-
modelValue:
|
|
262
|
-
"onUpdate:modelValue": l[0] || (l[0] = (o) =>
|
|
263
|
-
defaultConfig:
|
|
282
|
+
style: P({ height: z.value }),
|
|
283
|
+
modelValue: c.value,
|
|
284
|
+
"onUpdate:modelValue": l[0] || (l[0] = (o) => c.value = o),
|
|
285
|
+
defaultConfig: N,
|
|
264
286
|
mode: a.mode,
|
|
265
|
-
onOnCreated:
|
|
266
|
-
onOnChange:
|
|
267
|
-
onOnDestroyed:
|
|
268
|
-
onOnFocus:
|
|
269
|
-
onOnBlur:
|
|
287
|
+
onOnCreated: O,
|
|
288
|
+
onOnChange: U,
|
|
289
|
+
onOnDestroyed: j,
|
|
290
|
+
onOnFocus: E,
|
|
291
|
+
onOnBlur: T
|
|
270
292
|
}, null, 8, ["style", "modelValue", "mode"])
|
|
271
293
|
]));
|
|
272
294
|
}
|
|
273
|
-
}), se = /* @__PURE__ */ X(Z, [["__scopeId", "data-v-
|
|
295
|
+
}), se = /* @__PURE__ */ X(Z, [["__scopeId", "data-v-55807020"]]);
|
|
274
296
|
export {
|
|
275
297
|
se as default
|
|
276
298
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const i=require("./index-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const i=require("./index-s8heSTAB.js");exports.AccordionText=i.ah;exports.AccordionTextPlugin=i.bm;exports.AlummiCommunityList=i.Q;exports.AlummiCommunityListPlugin=i.a_;exports.AnimationUtils=i.bq;exports.ArticleItem=i.k;exports.ArticleItemPlugin=i.aA;exports.ArticleList=i.A;exports.ArticleListPlugin=i.ai;exports.ArticleListPureText=i.a2;exports.ArticleListPureTextPlugin=i.b8;exports.BackgroundWrapper=i.ad;exports.BackgroundWrapperPlugin=i.bj;exports.BannerImage=i.B;exports.BannerImagePlugin=i.aj;exports.BannerImageWithLink=i.r;exports.BannerImageWithLinkPlugin=i.aK;exports.BannerPage=i.b;exports.BannerPagePlugin=i.ak;exports.BannerQuote=i.j;exports.BannerQuotePlugin=i.az;exports.BasicCollapse=i.z;exports.BasicCollapsePlugin=i.aU;exports.BlessingMessage=i.U;exports.BlessingMessagePlugin=i.a$;exports.BlessingSlider=i.V;exports.BlessingSliderPlugin=i.b0;exports.BtnList=i.c;exports.BtnListPlugin=i.al;exports.CardCarousel=i.h;exports.CardCarouselArticles=i.u;exports.CardCarouselArticlesPlugin=i.aP;exports.CardCarouselMultiRow=i.i;exports.CardCarouselMultiRowArticles=i.K;exports.CardCarouselMultiRowArticlesPlugin=i.aZ;exports.CardCarouselMultiRowPlugin=i.ay;exports.CardCarouselMultiRowPublications=i.Z;exports.CardCarouselMultiRowPublicationsPlugin=i.b4;exports.CardCarouselPlugin=i.ax;exports.CardListCircle=i.a6;exports.CardListCirclePlugin=i.bc;exports.CardListProgramme=i.a5;exports.CardListProgrammePlugin=i.bb;exports.CardListSchool=i.a7;exports.CardListSchoolPlugin=i.bd;exports.CardShowcase=i.W;exports.CardShowcasePlugin=i.b1;exports.CardShowcaseProfile=i.m;exports.CardShowcaseProfilePlugin=i.aF;exports.CarouselLogo=i.v;exports.CarouselLogoPlugin=i.aQ;exports.CollapseCustom=i.ae;exports.CollapseCustomPlugin=i.bk;exports.ContactUsInfo=i.s;exports.ContactUsInfoPlugin=i.aM;exports.ContactUsList=i.p;exports.ContactUsListPlugin=i.aH;exports.CountDown=i.n;exports.CountDownPlugin=i.aG;exports.CustomIframe=i.o;exports.CustomIframePlugin=i.aI;exports.CustomSpace=i.C;exports.CustomSpacePlugin=i.ar;exports.CustomText=i.$;exports.CustomTextPlugin=i.b5;exports.DetailLink=i.a9;exports.DetailLinkPlugin=i.bf;exports.Disc=i.y;exports.DiscPlugin=i.aT;exports.DonorLinks=i.D;exports.DonorLinksPlugin=i.aw;exports.ExploreLinks=i.X;exports.ExploreLinksPlugin=i.b2;exports.GalleryBlock=i.J;exports.GalleryBlockPlugin=i.aY;exports.GalleryCaptionRound=i.d;exports.GalleryCaptionRoundPlugin=i.an;exports.GalleryDefault=i.G;exports.GalleryDefaultPlugin=i.am;exports.GalleryList=i.g;exports.GalleryListPlugin=i.as;exports.GalleryTimeline=i.e;exports.GalleryTimelineCol=i.f;exports.GalleryTimelineColPlugin=i.ap;exports.GalleryTimelinePlugin=i.ao;exports.GridLinks=i.ag;exports.HeroSlide=i.H;exports.HeroSlidePlugin=i.at;exports.InformationLink=i.aa;exports.InformationLinkPlugin=i.bg;exports.LinkList=i.L;exports.LinkListPlugin=i.au;exports.MapStatic=i.M;exports.MapStaticPlugin=i.aO;exports.MediaImageFull=i.a0;exports.MediaImageFullPlugin=i.b6;exports.MediaImageStatic=i.a1;exports.MediaImageStaticPlugin=i.b7;exports.MediaLogo=i.F;exports.MediaLogoPlugin=i.aW;exports.MediaVideo=i.a8;exports.MediaVideoPlugin=i.be;exports.NewsList=i.N;exports.NewsListPlugin=i.aD;exports.Process=i.P;exports.ProcessPlugin=i.aq;exports.Publications=i.t;exports.PublicationsPlugin=i.aN;exports.QuoteText=i._;exports.QuoteTextPlugin=i.av;exports.RegisterForm=i.I;exports.RegisterFormPlugin=i.aX;exports.Resources=i.w;exports.ResourcesPlugin=i.aR;exports.ResourcesTwo=i.x;exports.ResourcesTwoPlugin=i.aS;exports.ResponsiveUtils=i.bp;exports.RibbonBlock=i.R;exports.RibbonBlockPlugin=i.aB;exports.SchoolLayout=i.Y;exports.SchoolLayoutPlugin=i.b3;exports.ScrollKeyInfo=i.S;exports.ScrollKeyInfoPlugin=i.aL;exports.StorageUtils=i.br;exports.TabDefault=i.a3;exports.TabDefaultPlugin=i.b9;exports.TabLogo=i.ac;exports.TabLogoPlugin=i.bi;exports.TabPage=i.ab;exports.TabPagePlugin=i.bh;exports.TabTimeLine=i.a4;exports.TabTimeLinePlugin=i.ba;exports.TableCollapse=i.E;exports.TableCollapsePlugin=i.aV;exports.TableTwo=i.q;exports.TableTwoPlugin=i.aJ;exports.TheHistoryCarousel=i.l;exports.TheHistoryCarouselPlugin=i.aE;exports.ThemeUtils=i.bo;exports.TimelineStory=i.T;exports.TimelineStoryPlugin=i.aC;exports.VrTour=i.af;exports.VrTourPlugin=i.bl;exports.VueScreenPlugin=i.bs;exports.default=i.O;exports.useTheme=i.bn;exports.useVueScreen=i.bt;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ah as i, bm as l, Q as e, a_ as n, bq as o, k as u, aA as r, A as t, ai as g, a2 as P, b8 as C, ad as c, bj as b, B as m, aj as L, r as d, aK as T, b as S, ak as y, j as B, az as p, z as k, aU as w, U as I, a$ as M, V as f, b0 as R, c as h, al as A, h as G, u as D, aP as x, i as U, K as V, aZ as F, ay as H, Z as Q, b4 as W, ax as E, a6 as K, bc as N, a5 as j, bb as q, a7 as v, bd as z, W as J, b1 as O, m as X, aF as Y, v as Z, aQ as _, ae as $, bk as aa, s as sa, aM as ia, p as la, aH as ea, n as na, aG as oa, o as ua, aI as ra, C as ta, ar as ga, $ as Pa, b5 as Ca, a9 as ca, bf as ba, y as ma, aT as La, D as da, aw as Ta, X as Sa, b2 as ya, J as Ba, aY as pa, d as ka, an as wa, G as Ia, am as Ma, g as fa, as as Ra, e as ha, f as Aa, ap as Ga, ao as Da, ag as xa, H as Ua, at as Va, aa as Fa, bg as Ha, L as Qa, au as Wa, M as Ea, aO as Ka, a0 as Na, b6 as ja, a1 as qa, b7 as va, F as za, aW as Ja, a8 as Oa, be as Xa, N as Ya, aD as Za, P as _a, aq as $a, t as as, aN as ss, _ as is, av as ls, I as es, aX as ns, w as os, aR as us, x as rs, aS as ts, bp as gs, R as Ps, aB as Cs, Y as cs, b3 as bs, S as ms, aL as Ls, br as ds, a3 as Ts, b9 as Ss, ac as ys, bi as Bs, ab as ps, bh as ks, a4 as ws, ba as Is, E as Ms, aV as fs, q as Rs, aJ as hs, l as As, aE as Gs, bo as Ds, T as xs, aC as Us, af as Vs, bl as Fs, bs as Hs, O as Qs, bn as Ws, bt as Es } from "./index-
|
|
1
|
+
import { ah as i, bm as l, Q as e, a_ as n, bq as o, k as u, aA as r, A as t, ai as g, a2 as P, b8 as C, ad as c, bj as b, B as m, aj as L, r as d, aK as T, b as S, ak as y, j as B, az as p, z as k, aU as w, U as I, a$ as M, V as f, b0 as R, c as h, al as A, h as G, u as D, aP as x, i as U, K as V, aZ as F, ay as H, Z as Q, b4 as W, ax as E, a6 as K, bc as N, a5 as j, bb as q, a7 as v, bd as z, W as J, b1 as O, m as X, aF as Y, v as Z, aQ as _, ae as $, bk as aa, s as sa, aM as ia, p as la, aH as ea, n as na, aG as oa, o as ua, aI as ra, C as ta, ar as ga, $ as Pa, b5 as Ca, a9 as ca, bf as ba, y as ma, aT as La, D as da, aw as Ta, X as Sa, b2 as ya, J as Ba, aY as pa, d as ka, an as wa, G as Ia, am as Ma, g as fa, as as Ra, e as ha, f as Aa, ap as Ga, ao as Da, ag as xa, H as Ua, at as Va, aa as Fa, bg as Ha, L as Qa, au as Wa, M as Ea, aO as Ka, a0 as Na, b6 as ja, a1 as qa, b7 as va, F as za, aW as Ja, a8 as Oa, be as Xa, N as Ya, aD as Za, P as _a, aq as $a, t as as, aN as ss, _ as is, av as ls, I as es, aX as ns, w as os, aR as us, x as rs, aS as ts, bp as gs, R as Ps, aB as Cs, Y as cs, b3 as bs, S as ms, aL as Ls, br as ds, a3 as Ts, b9 as Ss, ac as ys, bi as Bs, ab as ps, bh as ks, a4 as ws, ba as Is, E as Ms, aV as fs, q as Rs, aJ as hs, l as As, aE as Gs, bo as Ds, T as xs, aC as Us, af as Vs, bl as Fs, bs as Hs, O as Qs, bn as Ws, bt as Es } from "./index-Coasm1Q-.mjs";
|
|
2
2
|
export {
|
|
3
3
|
i as AccordionText,
|
|
4
4
|
l as AccordionTextPlugin,
|