@keyblade/tinymce-editor-vue2 0.0.12-alpha.9 → 0.1.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/README.md +130 -119
- package/es/editor.vue.d.ts +25 -219
- package/es/editor.vue.js +20 -19
- package/es/editor.vue2.js +427 -291
- package/es/index.d.ts +85 -805
- package/es/index.js +12 -11
- package/es/langs/zh_CN.d.ts +0 -5
- package/es/langs/zh_CN.js +1 -1
- package/es/style.css +1 -1
- package/es/types.d.ts +91 -0
- package/es/util.d.ts +13 -32
- package/es/util.js +20 -68
- package/package.json +5 -4
- package/src/index.ts +16 -31
- /package/es/{editor.vue3.js → style.less.js} +0 -0
package/es/editor.vue.js
CHANGED
|
@@ -1,22 +1,23 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "./
|
|
3
|
-
|
|
4
|
-
var d
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
},
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
1
|
+
import c from "./editor.vue2.js";
|
|
2
|
+
import g from "./_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
+
var f = function() {
|
|
4
|
+
var l, i, s, u, d, r, p, n, m;
|
|
5
|
+
var a = this, e = a._self._c, o = a._self._setupProxy;
|
|
6
|
+
return e("div", { staticClass: "tinymce-editor" }, [e("textarea", { ref: "insRef" }), e("el-dialog", { staticClass: "tinymce-editor-dialog tinymce-editor-upload-image-dialog", attrs: { visible: o.uploadImage.dialogVisible, title: "插入图片", "append-to-body": !0, "close-on-click-modal": !1, "destroy-on-close": "" }, on: { close: o.onUploadImageClose } }, [e("el-form", { ref: "uploadImageFormRef", staticClass: "uploadImageForm", attrs: { model: o.uploadImage.formData } }, [e("el-form-item", { attrs: { prop: "images", rules: { required: !0, message: "必填项" } } }, [e(o.ImgPond, a._b({ ref: "uploadImageImgPondRef", attrs: { valueType: "array", accept: o.imgPondAccept, size: o.mergeImageUploadOptions.maxSize, count: o.mergeImageUploadOptions.maxCount, upload: o.onImageUploadUpload }, on: { exceed: o.onImageUploadUploadExceed }, model: { value: o.uploadImage.formData.images, callback: function(t) {
|
|
7
|
+
a.$set(o.uploadImage.formData, "images", t);
|
|
8
|
+
}, expression: "uploadImage.formData.images" } }, "ImgPond", o.mergeImgPondOptions, !1))], 1), e("div", { staticClass: "tips" }, [e("span", { staticStyle: { "font-size": "15px", "font-weight": "bold" } }, [a._v("注意:")]), e("span", [a._v("1. 单次最多可同时选择" + a._s(o.mergeImageUploadOptions.maxCount) + "张图片")]), e("span", [a._v("2. 仅支持" + a._s((i = (l = o.mergeImageUploadOptions) == null ? void 0 : l.allowedType) == null ? void 0 : i.map((t) => t.toUpperCase()).join("、")) + "格式")]), e("span", [a._v("3. 单张图片大小不可超过" + a._s(o.mergeImageUploadOptions.maxSize) + "M")]), e("span", [a._v("4. 像素不低于" + a._s(o.mergeImageUploadOptions.minWidth) + "*" + a._s(o.mergeImageUploadOptions.minHeight) + "且像素不高于" + a._s(o.mergeImageUploadOptions.maxWidth) + "*" + a._s(o.mergeImageUploadOptions.maxHeight))])])], 1), e("div", { attrs: { slot: "footer" }, slot: "footer" }, [e("el-button", { on: { click: o.onUploadImageClose } }, [a._v("取消")]), e("el-button", { attrs: { type: "primary" }, on: { click: o.onUploadImageConfirm } }, [a._v("确定")])], 1)], 1), e("el-dialog", { staticClass: "tinymce-editor-dialog tinymce-editor-upload-audio-dialog", attrs: { visible: o.uploadAudio.dialogVisible, title: "插入音频", "append-to-body": !0, "close-on-click-modal": !1, "destroy-on-close": "" }, on: { close: o.onUploadAudioClose } }, [e("el-form", { ref: "uploadAudioFormRef", staticClass: "uploadAudioForm", attrs: { model: o.uploadAudio.formData, "label-width": "auto" } }, [e("el-form-item", { attrs: { label: "名称", prop: "name", rules: { required: !0, message: "必填项" } } }, [e("el-input", { attrs: { maxlength: "14", "show-word-limit": "", placeholder: "请输入" }, model: { value: o.uploadAudio.formData.name, callback: function(t) {
|
|
9
|
+
a.$set(o.uploadAudio.formData, "name", t);
|
|
10
|
+
}, expression: "uploadAudio.formData.name" } })], 1), e("el-form-item", { attrs: { label: "封面", prop: "cover", rules: { required: !0, message: "必填项" } } }, [e(o.ImgPond, a._b({ ref: "audioImageImgPondRef", attrs: { valueType: "array", accept: o.imgPondAccept, size: o.mergeImageUploadOptions.maxSize, count: 1, upload: o.onImageUploadUpload }, model: { value: o.uploadAudio.formData.cover, callback: function(t) {
|
|
11
|
+
a.$set(o.uploadAudio.formData, "cover", t);
|
|
12
|
+
}, expression: "uploadAudio.formData.cover" } }, "ImgPond", o.mergeImgPondOptions, !1))], 1), e("el-form-item", { attrs: { label: "音频", prop: "file", rules: { required: !0, message: "必填项" } } }, [e("el-upload", { class: ["upload", { "upload-hide": o.uploadAudio.formData.file.length >= 1 }], attrs: { name: "file", "file-list": o.uploadAudio.formData.file, action: ((s = o.mergeAudioUploadOptions) == null ? void 0 : s.action) || "", data: o.getUploadAudioData(), accept: o.mergeAudioUploadOptions.accept, "list-type": "headTextContent", "before-upload": o.onUploadAudioBeforeUpload, headers: o.getUploadAudioHeaders(), "on-remove": o.onUploadAudioRemove, "on-success": o.onUploadAudioSuccess, "on-error": o.onUploadAudioError, limit: 1 } }, [e("el-button", { attrs: { size: "small", type: "primary" } }, [a._v("上传文件"), e("i", { staticClass: "el-icon-upload el-icon--right" })]), e("div", { staticClass: "el-upload__tip", attrs: { slot: "tip" }, slot: "tip" }, [e("div", { staticClass: "tips" }, [e("p", [a._v("注意:")]), e("div", [e("span", [a._v("1. 仅支持" + a._s((d = (u = o.mergeAudioUploadOptions) == null ? void 0 : u.allowedType) == null ? void 0 : d.map((t) => t.toUpperCase()).join("、")) + "格式")]), e("span", [a._v("2. 单个音频大小不可超过" + a._s((r = o.mergeAudioUploadOptions) == null ? void 0 : r.maxSize) + "M")])])])])], 1)], 1)], 1), e("div", { attrs: { slot: "footer" }, slot: "footer" }, [e("el-button", { on: { click: o.onUploadAudioClose } }, [a._v("取消")]), e("el-button", { attrs: { type: "primary" }, on: { click: o.onUploadAudioConfirm } }, [a._v("确定")])], 1)], 1), e("el-dialog", { staticClass: "tinymce-editor-dialog tinymce-editor-upload-video-dialog", attrs: { visible: o.uploadVideo.dialogVisible, title: "插入视频", "append-to-body": !0, "close-on-click-modal": !1, "destroy-on-close": "" }, on: { close: o.onUploadVideoClose } }, [e("el-form", { ref: "uploadVideoFormRef", staticClass: "uploadVideoForm", attrs: { model: o.uploadVideo.formData, "label-width": "auto" } }, [e("el-form-item", { attrs: { label: "视频", prop: "file", rules: { required: !0, message: "必填项" } } }, [e("el-upload", { class: ["upload", { "upload-hide": o.uploadVideo.formData.file.length >= 1 }], attrs: { name: "file", "file-list": o.uploadVideo.formData.file, action: o.mergeVideoUploadOptions.action || "", data: o.getUploadVideoData(), accept: o.mergeVideoUploadOptions.accept, "list-type": "headTextContent", "before-upload": o.onUploadVideoBeforeUpload, headers: o.getUploadVideoHeaders(), "on-remove": o.onUploadVideoRemove, "on-success": o.onUploadVideoSuccess, "on-error": o.onUploadVideoError, limit: 1 } }, [e("el-button", { attrs: { size: "small", type: "primary" } }, [a._v("上传文件"), e("i", { staticClass: "el-icon-upload el-icon--right" })]), e("div", { staticClass: "el-upload__tip", attrs: { slot: "tip" }, slot: "tip" }, [e("div", { staticClass: "tips" }, [e("p", [a._v("注意:")]), e("div", [e("span", [a._v("1. 仅支持" + a._s((n = (p = o.mergeVideoUploadOptions) == null ? void 0 : p.allowedType) == null ? void 0 : n.map((t) => t.toUpperCase()).join("、")) + "格式")]), e("span", [a._v("2. 单个视频大小不可超过" + a._s((m = o.mergeVideoUploadOptions) == null ? void 0 : m.maxSize) + "M")])])])])], 1)], 1)], 1), e("div", { attrs: { slot: "footer" }, slot: "footer" }, [e("el-button", { on: { click: o.onUploadVideoClose } }, [a._v("取消")]), e("el-button", { attrs: { type: "primary" }, on: { click: o.onUploadVideoConfirm } }, [a._v("确定")])], 1)], 1), e("el-dialog", { staticClass: "tinymce-editor-loading-dialog", attrs: { fullscreen: "", "append-to-body": "", visible: o.uploadLoadingConfig.show, "show-close": !1, "close-on-press-escape": !1, "close-on-click-modal": !1, "destroy-on-close": "" }, on: { "update:visible": function(t) {
|
|
13
|
+
return a.$set(o.uploadLoadingConfig, "show", t);
|
|
14
|
+
} } }, [e("div", { staticClass: "tinymce-editor-loading-dialog-content" }, [e("div", { staticClass: "tinymce-editor-spinner" }, [e("div", { staticClass: "tinymce-editor-spinner-dot1" }), e("div", { staticClass: "tinymce-editor-spinner-dot2" }), e("div", { staticClass: "tinymce-editor-spinner-dot3" })]), e("span", [a._v(a._s(o.uploadLoadingConfig.text))])])])], 1);
|
|
15
|
+
}, C = [], v = /* @__PURE__ */ g(
|
|
16
|
+
c,
|
|
17
|
+
f,
|
|
18
|
+
C
|
|
18
19
|
);
|
|
19
|
-
const
|
|
20
|
+
const y = v.exports;
|
|
20
21
|
export {
|
|
21
|
-
|
|
22
|
+
y as default
|
|
22
23
|
};
|