@keyblade/tinymce-editor-vue2 1.2.0 → 1.2.1
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/es/_virtual/_plugin-vue2_normalizer.js +3 -3
- package/es/editor.vue.d.ts +21 -42
- package/es/editor.vue.js +5 -5
- package/es/editor.vue2.js +4 -3
- package/es/index.d.ts +28 -33
- package/es/index.js +1 -1
- package/es/types.d.ts +4 -1
- package/package.json +2 -2
- package/es/style.less.js +0 -1
- /package/es/{style.css → tinymce-editor-vue2.css} +0 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
function
|
|
1
|
+
function f(e, o, t, d, i, a, l, u) {
|
|
2
2
|
var n = typeof e == "function" ? e.options : e;
|
|
3
|
-
return
|
|
3
|
+
return n.render = o, n.staticRenderFns = t, n._compiled = !0, {
|
|
4
4
|
exports: e,
|
|
5
5
|
options: n
|
|
6
6
|
};
|
|
7
7
|
}
|
|
8
8
|
export {
|
|
9
|
-
|
|
9
|
+
f as default
|
|
10
10
|
};
|
package/es/editor.vue.d.ts
CHANGED
|
@@ -1,65 +1,49 @@
|
|
|
1
1
|
import { Editor, RawEditorOptions } from 'tinymce';
|
|
2
2
|
import { AudioUploadOptions, ImageUploadOptions, VideoUploadOptions } from './types';
|
|
3
|
-
|
|
4
|
-
declare const _default: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
3
|
+
type __VLS_Props = {
|
|
5
4
|
/** vue2 v-model */
|
|
6
|
-
value?: string
|
|
5
|
+
value?: string;
|
|
7
6
|
/** 是否禁止编辑 */
|
|
8
|
-
disabled?: boolean
|
|
7
|
+
disabled?: boolean;
|
|
9
8
|
/** 额外参数 */
|
|
10
|
-
extParameters?: Record<string, any
|
|
9
|
+
extParameters?: Record<string, any>;
|
|
11
10
|
/** 富文本编辑器选项 */
|
|
12
|
-
options?: Partial<RawEditorOptions
|
|
11
|
+
options?: Partial<RawEditorOptions>;
|
|
13
12
|
/** 图片上传选项 */
|
|
14
|
-
imageUploadOptions?: ImageUploadOptions
|
|
13
|
+
imageUploadOptions?: ImageUploadOptions;
|
|
15
14
|
/** 音频上传组件选项 */
|
|
16
|
-
audioUploadOptions?: AudioUploadOptions
|
|
15
|
+
audioUploadOptions?: AudioUploadOptions;
|
|
17
16
|
/** 视频上传选项 */
|
|
18
|
-
videoUploadOptions?: VideoUploadOptions
|
|
17
|
+
videoUploadOptions?: VideoUploadOptions;
|
|
19
18
|
/** 初始化完成 */
|
|
20
|
-
initComplete?: (
|
|
19
|
+
initComplete?: (params: {
|
|
21
20
|
editorIns: Editor;
|
|
22
|
-
}) => void
|
|
23
|
-
}
|
|
21
|
+
}) => void;
|
|
22
|
+
};
|
|
23
|
+
declare const _default: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_Props>, {
|
|
24
24
|
value: string;
|
|
25
25
|
disabled: boolean;
|
|
26
26
|
extParameters: () => {};
|
|
27
27
|
options: () => {};
|
|
28
|
-
}>, {}, {}, {}, {}, import('vue/types/v3-component-options').ComponentOptionsMixin, import('vue/types/v3-component-options').ComponentOptionsMixin, {
|
|
29
|
-
input: (value: string) => void;
|
|
30
|
-
}, string, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
31
|
-
/** vue2 v-model */
|
|
32
|
-
value?: string | undefined;
|
|
33
|
-
/** 是否禁止编辑 */
|
|
34
|
-
disabled?: boolean | undefined;
|
|
35
|
-
/** 额外参数 */
|
|
36
|
-
extParameters?: Record<string, any> | undefined;
|
|
37
|
-
/** 富文本编辑器选项 */
|
|
38
|
-
options?: Partial<RawEditorOptions> | undefined;
|
|
39
|
-
/** 图片上传选项 */
|
|
40
|
-
imageUploadOptions?: ImageUploadOptions | undefined;
|
|
41
|
-
/** 音频上传组件选项 */
|
|
42
|
-
audioUploadOptions?: AudioUploadOptions | undefined;
|
|
43
|
-
/** 视频上传选项 */
|
|
44
|
-
videoUploadOptions?: VideoUploadOptions | undefined;
|
|
45
|
-
/** 初始化完成 */
|
|
46
|
-
initComplete?: ((params: {
|
|
47
|
-
editorIns: Editor;
|
|
48
|
-
}) => void) | undefined;
|
|
49
|
-
}>, {
|
|
28
|
+
}>, {}, {}, {}, {}, import('vue/types/v3-component-options').ComponentOptionsMixin, import('vue/types/v3-component-options').ComponentOptionsMixin, {}, string, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_Props>, {
|
|
50
29
|
value: string;
|
|
51
30
|
disabled: boolean;
|
|
52
31
|
extParameters: () => {};
|
|
53
32
|
options: () => {};
|
|
54
33
|
}>>>, {
|
|
34
|
+
options: Partial<RawEditorOptions>;
|
|
55
35
|
value: string;
|
|
56
36
|
disabled: boolean;
|
|
57
37
|
extParameters: Record<string, any>;
|
|
58
|
-
options: Partial<RawEditorOptions>;
|
|
59
38
|
}>;
|
|
60
39
|
export default _default;
|
|
40
|
+
type __VLS_WithDefaults<P, D> = {
|
|
41
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_PrettifyLocal<P[K] & {
|
|
42
|
+
default: D[K];
|
|
43
|
+
}> : P[K];
|
|
44
|
+
};
|
|
61
45
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
62
|
-
type
|
|
46
|
+
type __VLS_TypePropsToOption<T> = {
|
|
63
47
|
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
64
48
|
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
65
49
|
} : {
|
|
@@ -67,11 +51,6 @@ type __VLS_TypePropsToRuntimeProps<T> = {
|
|
|
67
51
|
required: true;
|
|
68
52
|
};
|
|
69
53
|
};
|
|
70
|
-
type
|
|
71
|
-
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
72
|
-
default: D[K];
|
|
73
|
-
}> : P[K];
|
|
74
|
-
};
|
|
75
|
-
type __VLS_Prettify<T> = {
|
|
54
|
+
type __VLS_PrettifyLocal<T> = {
|
|
76
55
|
[K in keyof T]: T[K];
|
|
77
56
|
} & {};
|
package/es/editor.vue.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import A from "./editor.vue2.js";
|
|
2
2
|
import I from "./_virtual/_plugin-vue2_normalizer.js";
|
|
3
3
|
var h = function() {
|
|
4
|
-
var i, l, s,
|
|
4
|
+
var i, l, s, d, u, r, p, n, m, c, g, f, C, v, F, U, _, D, E, b, y;
|
|
5
5
|
var a = this, o = a._self._c, e = a._self._setupProxy;
|
|
6
6
|
return o("div", { staticClass: "tinymce-editor" }, [o("textarea", { ref: "insRef" }), o("el-dialog", { staticClass: "tinymce-editor-dialog tinymce-editor-upload-image-dialog", attrs: { visible: e.uploadImage.dialogVisible, title: "插入图片", "append-to-body": !0, "close-on-click-modal": !1, "destroy-on-close": "" }, on: { close: e.onUploadImageClose } }, [o("el-form", { ref: "uploadImageFormRef", staticClass: "uploadImageForm", attrs: { model: e.uploadImage.formData } }, [o("el-form-item", { attrs: { prop: "images", rules: { required: !0, message: "必填项" } } }, [o("kb-pro-vue2-image-upload", a._b({ attrs: { accept: (i = e.mergeImageUploadOptions) == null ? void 0 : i.accept, action: e.mergeImageUploadOptions.action || "", data: e.getUploadImageData(), headers: e.getUploadImageHeaders(), onInnerBeforeUploadEnd: e.onUploadImageInnerBeforeUploadEnd }, model: { value: e.uploadImage.formData.images, callback: function(t) {
|
|
7
7
|
a.$set(e.uploadImage.formData, "images", t);
|
|
8
|
-
}, expression: "uploadImage.formData.images" } }, "kb-pro-vue2-image-upload", e.mergeImageUploadOptions, !1))], 1), o("div", { staticClass: "tips" }, [o("span", { staticStyle: { "font-size": "15px", "font-weight": "bold" } }, [a._v("注意:")]), o("span", [a._v("1. 单次最多可同时选择" + a._s(e.mergeImageUploadOptions.singleLimit) + "张图片")]), o("span", [a._v("2. 仅支持" + a._s((s = (l = e.mergeImageUploadOptions) == null ? void 0 : l.accept) == null ? void 0 : s.map((t) => t.toUpperCase()).join("、")) + "格式")]), o("span", [a._v("3. 单张图片大小不可超过" + a._s((
|
|
8
|
+
}, expression: "uploadImage.formData.images" } }, "kb-pro-vue2-image-upload", e.mergeImageUploadOptions, !1))], 1), o("div", { staticClass: "tips" }, [o("span", { staticStyle: { "font-size": "15px", "font-weight": "bold" } }, [a._v("注意:")]), o("span", [a._v("1. 单次最多可同时选择" + a._s(e.mergeImageUploadOptions.singleLimit) + "张图片")]), o("span", [a._v("2. 仅支持" + a._s((s = (l = e.mergeImageUploadOptions) == null ? void 0 : l.accept) == null ? void 0 : s.map((t) => t.toUpperCase()).join("、")) + "格式")]), o("span", [a._v("3. 单张图片大小不可超过" + a._s((u = (d = e.mergeImageUploadOptions) == null ? void 0 : d.checkOptions) == null ? void 0 : u.maxSize) + "M")]), o("span", [a._v("4. 像素不低于" + a._s((p = (r = e.mergeImageUploadOptions) == null ? void 0 : r.checkOptions) == null ? void 0 : p.minWidth) + "*" + a._s((m = (n = e.mergeImageUploadOptions) == null ? void 0 : n.checkOptions) == null ? void 0 : m.minHeight) + "且像素不高于" + a._s((g = (c = e.mergeImageUploadOptions) == null ? void 0 : c.checkOptions) == null ? void 0 : g.maxWidth) + "*" + a._s((C = (f = e.mergeImageUploadOptions) == null ? void 0 : f.checkOptions) == null ? void 0 : C.maxHeight))])])], 1), o("div", { attrs: { slot: "footer" }, slot: "footer" }, [o("el-button", { on: { click: e.onUploadImageClose } }, [a._v("取消")]), o("el-button", { attrs: { type: "primary" }, on: { click: e.onUploadImageConfirm } }, [a._v("确定")])], 1)], 1), o("el-dialog", { staticClass: "tinymce-editor-dialog tinymce-editor-upload-audio-dialog", attrs: { visible: e.uploadAudio.dialogVisible, title: "插入音频", "append-to-body": !0, "close-on-click-modal": !1, "destroy-on-close": "" }, on: { close: e.onUploadAudioClose } }, [o("el-form", { ref: "uploadAudioFormRef", staticClass: "uploadAudioForm", attrs: { model: e.uploadAudio.formData, "label-width": "auto" } }, [o("el-form-item", { attrs: { label: "名称", prop: "name", rules: { required: !0, message: "必填项" } } }, [o("el-input", { attrs: { maxlength: "14", "show-word-limit": "", placeholder: "请输入" }, model: { value: e.uploadAudio.formData.name, callback: function(t) {
|
|
9
9
|
a.$set(e.uploadAudio.formData, "name", t);
|
|
10
10
|
}, expression: "uploadAudio.formData.name" } })], 1), o("el-form-item", { attrs: { label: "封面", prop: "cover", rules: { required: !0, message: "必填项" } } }, [o("kb-pro-vue2-image-upload", a._b({ attrs: { accept: (v = e.mergeImageUploadOptions) == null ? void 0 : v.accept, action: e.mergeImageUploadOptions.action || "", data: e.getUploadImageData(), headers: e.getUploadImageHeaders(), onInnerBeforeUploadEnd: e.onUploadImageInnerBeforeUploadEnd, limit: 1, multiple: !1 }, model: { value: e.uploadAudio.formData.cover, callback: function(t) {
|
|
11
11
|
a.$set(e.uploadAudio.formData, "cover", t);
|
|
12
|
-
}, expression: "uploadAudio.formData.cover" } }, "kb-pro-vue2-image-upload", e.mergeImageUploadOptions, !1))], 1), o("el-form-item", { attrs: { label: "音频", prop: "file", rules: { required: !0, message: "必填项" } } }, [o("el-upload", { class: ["upload", { "upload-hide": e.uploadAudio.formData.file.length >= 1 }], attrs: { name:
|
|
12
|
+
}, expression: "uploadAudio.formData.cover" } }, "kb-pro-vue2-image-upload", e.mergeImageUploadOptions, !1))], 1), o("el-form-item", { attrs: { label: "音频", prop: "file", rules: { required: !0, message: "必填项" } } }, [o("el-upload", { class: ["upload", { "upload-hide": e.uploadAudio.formData.file.length >= 1 }], attrs: { name: e.mergeAudioUploadOptions.name, "file-list": e.uploadAudio.formData.file, action: ((F = e.mergeAudioUploadOptions) == null ? void 0 : F.action) || "", data: e.getUploadAudioData(), accept: e.mergeAudioUploadOptions.accept, "list-type": "headTextContent", "before-upload": e.onUploadAudioBeforeUpload, headers: e.getUploadAudioHeaders(), "on-remove": e.onUploadAudioRemove, "on-success": e.onUploadAudioSuccess, "on-error": e.onUploadAudioError, limit: 1 } }, [o("el-button", { attrs: { size: "small", type: "primary" } }, [a._v("上传文件"), o("i", { staticClass: "el-icon-upload el-icon--right" })]), o("div", { staticClass: "el-upload__tip", attrs: { slot: "tip" }, slot: "tip" }, [o("div", { staticClass: "tips" }, [o("p", [a._v("注意:")]), o("div", [o("span", [a._v("1. 仅支持" + a._s((_ = (U = e.mergeAudioUploadOptions) == null ? void 0 : U.allowedType) == null ? void 0 : _.map((t) => t.toUpperCase()).join("、")) + "格式")]), o("span", [a._v("2. 单个音频大小不可超过" + a._s((D = e.mergeAudioUploadOptions) == null ? void 0 : D.maxSize) + "M")])])])])], 1)], 1)], 1), o("div", { attrs: { slot: "footer" }, slot: "footer" }, [o("el-button", { on: { click: e.onUploadAudioClose } }, [a._v("取消")]), o("el-button", { attrs: { type: "primary" }, on: { click: e.onUploadAudioConfirm } }, [a._v("确定")])], 1)], 1), o("el-dialog", { staticClass: "tinymce-editor-dialog tinymce-editor-upload-video-dialog", attrs: { visible: e.uploadVideo.dialogVisible, title: "插入视频", "append-to-body": !0, "close-on-click-modal": !1, "destroy-on-close": "" }, on: { close: e.onUploadVideoClose } }, [o("el-form", { ref: "uploadVideoFormRef", staticClass: "uploadVideoForm", attrs: { model: e.uploadVideo.formData, "label-width": "auto" } }, [o("el-form-item", { attrs: { label: "视频", prop: "file", rules: { required: !0, message: "必填项" } } }, [o("el-upload", { class: ["upload", { "upload-hide": e.uploadVideo.formData.file.length >= 1 }], attrs: { name: e.mergeVideoUploadOptions.name, "file-list": e.uploadVideo.formData.file, action: e.mergeVideoUploadOptions.action || "", data: e.getUploadVideoData(), accept: e.mergeVideoUploadOptions.accept, "list-type": "headTextContent", "before-upload": e.onUploadVideoBeforeUpload, headers: e.getUploadVideoHeaders(), "on-remove": e.onUploadVideoRemove, "on-success": e.onUploadVideoSuccess, "on-error": e.onUploadVideoError, limit: 1 } }, [o("el-button", { attrs: { size: "small", type: "primary" } }, [a._v("上传文件"), o("i", { staticClass: "el-icon-upload el-icon--right" })]), o("div", { staticClass: "el-upload__tip", attrs: { slot: "tip" }, slot: "tip" }, [o("div", { staticClass: "tips" }, [o("p", [a._v("注意:")]), o("div", [o("span", [a._v("1. 仅支持" + a._s((b = (E = e.mergeVideoUploadOptions) == null ? void 0 : E.allowedType) == null ? void 0 : b.map((t) => t.toUpperCase()).join("、")) + "格式")]), o("span", [a._v("2. 单个视频大小不可超过" + a._s((y = e.mergeVideoUploadOptions) == null ? void 0 : y.maxSize) + "M")])])])])], 1)], 1)], 1), o("div", { attrs: { slot: "footer" }, slot: "footer" }, [o("el-button", { on: { click: e.onUploadVideoClose } }, [a._v("取消")]), o("el-button", { attrs: { type: "primary" }, on: { click: e.onUploadVideoConfirm } }, [a._v("确定")])], 1)], 1), o("el-dialog", { staticClass: "tinymce-editor-loading-dialog", attrs: { fullscreen: "", "append-to-body": "", visible: e.uploadLoadingConfig.show, "show-close": !1, "close-on-press-escape": !1, "close-on-click-modal": !1, "destroy-on-close": "" }, on: { "update:visible": function(t) {
|
|
13
13
|
return a.$set(e.uploadLoadingConfig, "show", t);
|
|
14
14
|
} } }, [o("div", { staticClass: "tinymce-editor-loading-dialog-content" }, [o("div", { staticClass: "tinymce-editor-spinner" }, [o("div", { staticClass: "tinymce-editor-spinner-dot1" }), o("div", { staticClass: "tinymce-editor-spinner-dot2" }), o("div", { staticClass: "tinymce-editor-spinner-dot3" })]), o("span", [a._v(a._s(e.uploadLoadingConfig.text))])])])], 1);
|
|
15
|
-
}, O = [],
|
|
15
|
+
}, O = [], V = /* @__PURE__ */ I(
|
|
16
16
|
A,
|
|
17
17
|
h,
|
|
18
18
|
O
|
|
19
19
|
);
|
|
20
|
-
const w =
|
|
20
|
+
const w = V.exports;
|
|
21
21
|
export {
|
|
22
22
|
w as default
|
|
23
23
|
};
|
package/es/editor.vue2.js
CHANGED
|
@@ -30,7 +30,7 @@ var L = (u, n, i) => new Promise((O, T) => {
|
|
|
30
30
|
var G = (u, n, i) => (n = u[ce("asyncIterator")]) ? n.call(u) : (u = u[ce("iterator")](), n = {}, i = (O, T) => (T = u[O]) && (n[O] = (P) => new Promise((V, c, g) => (P = T.call(u, P), g = P.done, Promise.resolve(P.value).then((I) => V({ value: I, done: g }), c)))), i("next"), i("return"), n);
|
|
31
31
|
import { defineComponent as Ee, ref as A, computed as X, onMounted as Re, onUnmounted as qe, watch as de } from "vue";
|
|
32
32
|
import { oneTravelImageCheckAndTransform as Fe, oneTravelImageCompressor as We, blobToFile as Ne, getImagePixel as Le, getFileExtension as Ge } from "@keyblade/one-travel";
|
|
33
|
-
|
|
33
|
+
/* empty css */
|
|
34
34
|
import { conclude as F } from "vue-global-config";
|
|
35
35
|
import pe from "tinymce";
|
|
36
36
|
import Xe from "./langs/zh_CN.js";
|
|
@@ -94,11 +94,13 @@ const Ha = /* @__PURE__ */ Ee({
|
|
|
94
94
|
compressorOptions: S.compressorOptions,
|
|
95
95
|
cropOptions: S.cropOptions
|
|
96
96
|
}, T = {
|
|
97
|
+
name: "file",
|
|
97
98
|
enable: !0,
|
|
98
99
|
maxSize: 300,
|
|
99
100
|
allowedType: ["avi", "wmv", "mp4", "mov", "3gp"],
|
|
100
101
|
accept: ".avi,.wmv,.mp4,.mov,.3gp"
|
|
101
102
|
}, P = {
|
|
103
|
+
name: "file",
|
|
102
104
|
enable: !0,
|
|
103
105
|
maxSize: 200,
|
|
104
106
|
allowedType: ["wav", "mp3", "mp4", "m4a", "wma", "aac"],
|
|
@@ -248,8 +250,7 @@ const Ha = /* @__PURE__ */ Ee({
|
|
|
248
250
|
$.value.show = !1;
|
|
249
251
|
const Oe = new XMLSerializer().serializeToString(H.body);
|
|
250
252
|
e.insertContent(Oe);
|
|
251
|
-
} else
|
|
252
|
-
a.includes("text/plain") && e.insertContent(o.getData("text/plain"));
|
|
253
|
+
} else a.includes("text/plain") && e.insertContent(o.getData("text/plain"));
|
|
253
254
|
const t = Array.from((o == null ? void 0 : o.files) || []), r = [];
|
|
254
255
|
for (const z of t) {
|
|
255
256
|
if (!z)
|
package/es/index.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { RawEditorOptions } from 'tinymce';
|
|
2
2
|
import { AudioUploadOptions, ImageUploadOptions, VideoUploadOptions } from './types';
|
|
3
|
-
|
|
4
3
|
interface TinymceEditorGlobalOptions {
|
|
5
4
|
/** 富文本编辑器选项 */
|
|
6
5
|
options?: RawEditorOptions;
|
|
@@ -13,6 +12,10 @@ interface TinymceEditorGlobalOptions {
|
|
|
13
12
|
}
|
|
14
13
|
declare const globalProps: TinymceEditorGlobalOptions;
|
|
15
14
|
declare const TinymceEditor: import('vue/types/v3-component-public-instance').ComponentPublicInstanceConstructor<import('vue/types/v3-component-public-instance').Vue3Instance<{}, Readonly<import('vue').ExtractPropTypes<{
|
|
15
|
+
options: {
|
|
16
|
+
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
17
|
+
default: () => {};
|
|
18
|
+
};
|
|
16
19
|
value: {
|
|
17
20
|
type: import('vue').PropType<string>;
|
|
18
21
|
default: string;
|
|
@@ -25,10 +28,6 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
25
28
|
type: import('vue').PropType<Record<string, any>>;
|
|
26
29
|
default: () => {};
|
|
27
30
|
};
|
|
28
|
-
options: {
|
|
29
|
-
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
30
|
-
default: () => {};
|
|
31
|
-
};
|
|
32
31
|
imageUploadOptions: {
|
|
33
32
|
type: import('vue').PropType<ImageUploadOptions>;
|
|
34
33
|
};
|
|
@@ -44,6 +43,10 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
44
43
|
}) => void>;
|
|
45
44
|
};
|
|
46
45
|
}>>, Readonly<import('vue').ExtractPropTypes<{
|
|
46
|
+
options: {
|
|
47
|
+
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
48
|
+
default: () => {};
|
|
49
|
+
};
|
|
47
50
|
value: {
|
|
48
51
|
type: import('vue').PropType<string>;
|
|
49
52
|
default: string;
|
|
@@ -56,10 +59,6 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
56
59
|
type: import('vue').PropType<Record<string, any>>;
|
|
57
60
|
default: () => {};
|
|
58
61
|
};
|
|
59
|
-
options: {
|
|
60
|
-
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
61
|
-
default: () => {};
|
|
62
|
-
};
|
|
63
62
|
imageUploadOptions: {
|
|
64
63
|
type: import('vue').PropType<ImageUploadOptions>;
|
|
65
64
|
};
|
|
@@ -74,14 +73,16 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
74
73
|
editorIns: import('tinymce').Editor;
|
|
75
74
|
}) => void>;
|
|
76
75
|
};
|
|
77
|
-
}>>, {
|
|
78
|
-
|
|
79
|
-
}, {
|
|
76
|
+
}>>, {}, {
|
|
77
|
+
options: Partial<RawEditorOptions>;
|
|
80
78
|
value: string;
|
|
81
79
|
disabled: boolean;
|
|
82
80
|
extParameters: Record<string, any>;
|
|
83
|
-
options: Partial<RawEditorOptions>;
|
|
84
81
|
}, true, import('vue/types/v3-component-options').ComponentOptionsBase<any, any, any, any, any, any, any, any, any, any>> & Readonly<Readonly<import('vue').ExtractPropTypes<{
|
|
82
|
+
options: {
|
|
83
|
+
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
84
|
+
default: () => {};
|
|
85
|
+
};
|
|
85
86
|
value: {
|
|
86
87
|
type: import('vue').PropType<string>;
|
|
87
88
|
default: string;
|
|
@@ -94,10 +95,6 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
94
95
|
type: import('vue').PropType<Record<string, any>>;
|
|
95
96
|
default: () => {};
|
|
96
97
|
};
|
|
97
|
-
options: {
|
|
98
|
-
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
99
|
-
default: () => {};
|
|
100
|
-
};
|
|
101
98
|
imageUploadOptions: {
|
|
102
99
|
type: import('vue').PropType<ImageUploadOptions>;
|
|
103
100
|
};
|
|
@@ -113,6 +110,10 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
113
110
|
}) => void>;
|
|
114
111
|
};
|
|
115
112
|
}>>> & import('vue').ShallowUnwrapRef<{}> & import('vue/types/v3-component-options').ExtractComputedReturns<{}> & import('vue').ComponentCustomProperties & Readonly<import('vue').ExtractPropTypes<{
|
|
113
|
+
options: {
|
|
114
|
+
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
115
|
+
default: () => {};
|
|
116
|
+
};
|
|
116
117
|
value: {
|
|
117
118
|
type: import('vue').PropType<string>;
|
|
118
119
|
default: string;
|
|
@@ -125,10 +126,6 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
125
126
|
type: import('vue').PropType<Record<string, any>>;
|
|
126
127
|
default: () => {};
|
|
127
128
|
};
|
|
128
|
-
options: {
|
|
129
|
-
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
130
|
-
default: () => {};
|
|
131
|
-
};
|
|
132
129
|
imageUploadOptions: {
|
|
133
130
|
type: import('vue').PropType<ImageUploadOptions>;
|
|
134
131
|
};
|
|
@@ -144,6 +141,10 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
144
141
|
}) => void>;
|
|
145
142
|
};
|
|
146
143
|
}>>> & import('vue/types/v3-component-options').ComponentOptionsBase<Readonly<import('vue').ExtractPropTypes<{
|
|
144
|
+
options: {
|
|
145
|
+
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
146
|
+
default: () => {};
|
|
147
|
+
};
|
|
147
148
|
value: {
|
|
148
149
|
type: import('vue').PropType<string>;
|
|
149
150
|
default: string;
|
|
@@ -156,10 +157,6 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
156
157
|
type: import('vue').PropType<Record<string, any>>;
|
|
157
158
|
default: () => {};
|
|
158
159
|
};
|
|
159
|
-
options: {
|
|
160
|
-
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
161
|
-
default: () => {};
|
|
162
|
-
};
|
|
163
160
|
imageUploadOptions: {
|
|
164
161
|
type: import('vue').PropType<ImageUploadOptions>;
|
|
165
162
|
};
|
|
@@ -174,15 +171,17 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
174
171
|
editorIns: import('tinymce').Editor;
|
|
175
172
|
}) => void>;
|
|
176
173
|
};
|
|
177
|
-
}>>, {}, {}, {}, {}, import('vue/types/v3-component-options').ComponentOptionsMixin, import('vue/types/v3-component-options').ComponentOptionsMixin, {
|
|
178
|
-
|
|
179
|
-
}, string, {
|
|
174
|
+
}>>, {}, {}, {}, {}, import('vue/types/v3-component-options').ComponentOptionsMixin, import('vue/types/v3-component-options').ComponentOptionsMixin, {}, string, {
|
|
175
|
+
options: Partial<RawEditorOptions>;
|
|
180
176
|
value: string;
|
|
181
177
|
disabled: boolean;
|
|
182
178
|
extParameters: Record<string, any>;
|
|
183
|
-
options: Partial<RawEditorOptions>;
|
|
184
179
|
}> & {
|
|
185
180
|
props: {
|
|
181
|
+
options: {
|
|
182
|
+
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
183
|
+
default: () => {};
|
|
184
|
+
};
|
|
186
185
|
value: {
|
|
187
186
|
type: import('vue').PropType<string>;
|
|
188
187
|
default: string;
|
|
@@ -195,10 +194,6 @@ declare const TinymceEditor: import('vue/types/v3-component-public-instance').Co
|
|
|
195
194
|
type: import('vue').PropType<Record<string, any>>;
|
|
196
195
|
default: () => {};
|
|
197
196
|
};
|
|
198
|
-
options: {
|
|
199
|
-
type: import('vue').PropType<Partial<RawEditorOptions>>;
|
|
200
|
-
default: () => {};
|
|
201
|
-
};
|
|
202
197
|
imageUploadOptions: {
|
|
203
198
|
type: import('vue').PropType<ImageUploadOptions>;
|
|
204
199
|
};
|
package/es/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import './
|
|
1
|
+
import './tinymce-editor-vue2.css';
|
|
2
2
|
import e from "./editor.vue.js";
|
|
3
3
|
import { Button as t, Slider as u, Dialog as i, Upload as n, Tag as r, Form as m, FormItem as c, ButtonGroup as l, InputNumber as d, Loading as g } from "element-ui";
|
|
4
4
|
const b = {}, y = Object.assign(e, {
|
package/es/types.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ImageUploadCheckOptions, ImageUploadCompressorOptions, ImageUploadCropOptions } from '@keyblade/one-travel';
|
|
2
|
-
|
|
3
2
|
/** 图片选项 */
|
|
4
3
|
export interface ImageUploadOptions {
|
|
5
4
|
/** 上传的文件字段名 - 默认: file */
|
|
@@ -59,6 +58,8 @@ export interface ImageUploadOptions {
|
|
|
59
58
|
}
|
|
60
59
|
/** 视频选项 */
|
|
61
60
|
export interface VideoUploadOptions {
|
|
61
|
+
/** 上传的文件字段名 - 默认: file */
|
|
62
|
+
name?: string;
|
|
62
63
|
/** 是否启用 */
|
|
63
64
|
enable?: boolean;
|
|
64
65
|
/** 最大尺寸(M) */
|
|
@@ -89,6 +90,8 @@ export interface VideoUploadOptions {
|
|
|
89
90
|
}
|
|
90
91
|
/** 音频选项 */
|
|
91
92
|
export interface AudioUploadOptions {
|
|
93
|
+
/** 上传的文件字段名 - 默认: file */
|
|
94
|
+
name?: string;
|
|
92
95
|
/** 是否启用 */
|
|
93
96
|
enable?: boolean;
|
|
94
97
|
/** 最大尺寸(M) */
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@keyblade/tinymce-editor-vue2",
|
|
3
3
|
"description": "KeyBlade Tinymce Editor Vue2",
|
|
4
4
|
"author": "yangshuai <704807396@qq.com>",
|
|
5
|
-
"version": "1.2.
|
|
5
|
+
"version": "1.2.1",
|
|
6
6
|
"private": false,
|
|
7
7
|
"type": "module",
|
|
8
8
|
"main": "es/index.js",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
},
|
|
28
28
|
"peerDependencies": {
|
|
29
29
|
"vue": "^2.7.0",
|
|
30
|
-
"@keyblade/pro-components-vue2": "^1.13.
|
|
30
|
+
"@keyblade/pro-components-vue2": "^1.13.2"
|
|
31
31
|
},
|
|
32
32
|
"scripts": {
|
|
33
33
|
"build": "vite build",
|
package/es/style.less.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
|
File without changes
|