iking-web-ui-pro 0.2.43 → 0.2.44
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/IKPreviewFile/ik.index.es.js +352 -354
- package/dist/IKPreviewFile/ik.index.umd.js +44 -44
- package/dist/IKSearch/ik.index.es.js +111 -109
- package/dist/IKSearch/ik.index.umd.js +2 -2
- package/dist/IkApprovalProcess/ik.index.es.js +167 -158
- package/dist/IkApprovalProcess/ik.index.umd.js +1 -1
- package/dist/IkApprovalProcess/style.css +1 -1
- package/dist/IkApprovalProcessDetail/ik.index.es.js +359 -361
- package/dist/IkApprovalProcessDetail/ik.index.umd.js +44 -44
- package/dist/IkCalendar/ik.index.es.js +355 -353
- package/dist/IkCalendar/ik.index.umd.js +1 -1
- package/dist/IkDescription/ik.index.es.js +299 -301
- package/dist/IkDescription/ik.index.umd.js +44 -44
- package/dist/IkDetailPreviewFiles/ik.index.es.js +307 -309
- package/dist/IkDetailPreviewFiles/ik.index.umd.js +44 -44
- package/dist/IkOnlyOffice/ik.index.es.js +13 -19
- package/dist/IkOnlyOffice/ik.index.umd.js +1 -1
- package/dist/IkPageFull/ik.index.es.js +154 -152
- package/dist/IkPageFull/ik.index.umd.js +2 -2
- package/dist/IkPickerUser/ik.index.es.js +119 -117
- package/dist/IkPickerUser/ik.index.umd.js +1 -1
- package/dist/IkPreviewFileDialog/ik.index.es.js +343 -345
- package/dist/IkPreviewFileDialog/ik.index.umd.js +44 -44
- package/dist/IkTemplateOfficeConfig/ik.index.es.js +77 -78
- package/dist/IkTemplateOfficeConfig/ik.index.umd.js +1 -1
- package/dist/IkTinymce/ik.index.es.js +8803 -8741
- package/dist/IkTinymce/ik.index.umd.js +38 -38
- package/dist/IkTinymce/style.css +1 -1
- package/dist/IkUploadFile/ik.index.es.js +333 -335
- package/dist/IkUploadFile/ik.index.umd.js +46 -46
- package/dist/index.es.js +6738 -6729
- package/dist/index.umd.js +106 -106
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/IkOnlyOffice/style.css +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as v, openBlock as p, createElementBlock as g, ref as
|
|
1
|
+
import { defineComponent as v, openBlock as p, createElementBlock as g, ref as w, normalizeStyle as m, createVNode as _, unref as y } from "vue";
|
|
2
2
|
const R = (n, e) => {
|
|
3
3
|
if (n.install = (o) => {
|
|
4
4
|
for (const s of [n, ...Object.values(e ?? {})])
|
|
@@ -114,12 +114,12 @@ var E = function(n, e) {
|
|
|
114
114
|
if (!d) {
|
|
115
115
|
if (clearInterval(c), window.DocsAPI)
|
|
116
116
|
return s(null);
|
|
117
|
-
var i =
|
|
117
|
+
var i = f(e, n, s, r);
|
|
118
118
|
t.remove(), document.body.appendChild(i);
|
|
119
119
|
}
|
|
120
120
|
}, 500);
|
|
121
121
|
else {
|
|
122
|
-
var u =
|
|
122
|
+
var u = f(e, n, s, r);
|
|
123
123
|
document.body.appendChild(u);
|
|
124
124
|
}
|
|
125
125
|
} catch (d) {
|
|
@@ -128,14 +128,14 @@ var E = function(n, e) {
|
|
|
128
128
|
})];
|
|
129
129
|
});
|
|
130
130
|
});
|
|
131
|
-
},
|
|
131
|
+
}, f = function(n, e, o, s) {
|
|
132
132
|
var r = document.createElement("script");
|
|
133
133
|
return r.id = n, r.type = "text/javascript", r.src = e, r.async = !0, r.onload = function() {
|
|
134
134
|
r.removeAttribute("loading"), o(null);
|
|
135
135
|
}, r.onerror = function(t) {
|
|
136
136
|
r.removeAttribute("loading"), s(t);
|
|
137
137
|
}, r.setAttribute("loading", ""), r;
|
|
138
|
-
},
|
|
138
|
+
}, h = v({
|
|
139
139
|
name: "DocumentEditor",
|
|
140
140
|
props: {
|
|
141
141
|
id: {
|
|
@@ -308,8 +308,8 @@ const D = ["id"];
|
|
|
308
308
|
function b(n, e, o, s, r, t) {
|
|
309
309
|
return p(), g("div", { id: n.id }, null, 8, D);
|
|
310
310
|
}
|
|
311
|
-
|
|
312
|
-
|
|
311
|
+
h.render = b;
|
|
312
|
+
h.__file = "src/components/DocumentEditor.vue";
|
|
313
313
|
const C = /* @__PURE__ */ v({
|
|
314
314
|
__name: "IkOnlyOffice",
|
|
315
315
|
props: {
|
|
@@ -331,7 +331,7 @@ const C = /* @__PURE__ */ v({
|
|
|
331
331
|
}
|
|
332
332
|
},
|
|
333
333
|
setup(n) {
|
|
334
|
-
const e = n, o =
|
|
334
|
+
const e = n, o = w({
|
|
335
335
|
width: "100%",
|
|
336
336
|
height: "100%",
|
|
337
337
|
...e.configOptions || {},
|
|
@@ -342,10 +342,10 @@ const C = /* @__PURE__ */ v({
|
|
|
342
342
|
return (r, t) => (p(), g(
|
|
343
343
|
"div",
|
|
344
344
|
{
|
|
345
|
-
style:
|
|
345
|
+
style: m({ height: e.officeHeight })
|
|
346
346
|
},
|
|
347
347
|
[
|
|
348
|
-
|
|
348
|
+
_(y(h), {
|
|
349
349
|
id: `${(/* @__PURE__ */ new Date()).getTime()}`,
|
|
350
350
|
ref: "editorRef",
|
|
351
351
|
"document-server-url": n.documentServerUrl,
|
|
@@ -357,14 +357,8 @@ const C = /* @__PURE__ */ v({
|
|
|
357
357
|
/* STYLE */
|
|
358
358
|
));
|
|
359
359
|
}
|
|
360
|
-
});
|
|
361
|
-
const I = (n, e) => {
|
|
362
|
-
const o = n.__vccOpts || n;
|
|
363
|
-
for (const [s, r] of e)
|
|
364
|
-
o[s] = r;
|
|
365
|
-
return o;
|
|
366
|
-
}, F = /* @__PURE__ */ I(C, [["__scopeId", "data-v-98d51ef9"]]), k = R(F);
|
|
360
|
+
}), I = R(C);
|
|
367
361
|
export {
|
|
368
|
-
|
|
369
|
-
|
|
362
|
+
I as IkOnlyOffice,
|
|
363
|
+
I as default
|
|
370
364
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(d,c){typeof exports=="object"&&typeof module<"u"?c(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],c):(d=typeof globalThis<"u"?globalThis:d||self,c(d.index={},d.vue))})(this,function(d,c){"use strict";const
|
|
1
|
+
(function(d,c){typeof exports=="object"&&typeof module<"u"?c(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],c):(d=typeof globalThis<"u"?globalThis:d||self,c(d.index={},d.vue))})(this,function(d,c){"use strict";const m=(n,e)=>{if(n.install=o=>{for(const r of[n,...Object.values(e??{})])o.component(r.name,r)},e)for(const[o,r]of Object.entries(e))n[o]=r;return n};function w(n,e,o,r){function s(t){return t instanceof o?t:new o(function(u){u(t)})}return new(o||(o=Promise))(function(t,u){function l(a){try{i(r.next(a))}catch(v){u(v)}}function f(a){try{i(r.throw(a))}catch(v){u(v)}}function i(a){a.done?t(a.value):s(a.value).then(l,f)}i((r=r.apply(n,e||[])).next())})}function _(n,e){var o={label:0,sent:function(){if(t[0]&1)throw t[1];return t[1]},trys:[],ops:[]},r,s,t,u;return u={next:l(0),throw:l(1),return:l(2)},typeof Symbol=="function"&&(u[Symbol.iterator]=function(){return this}),u;function l(i){return function(a){return f([i,a])}}function f(i){if(r)throw new TypeError("Generator is already executing.");for(;u&&(u=0,i[0]&&(o=0)),o;)try{if(r=1,s&&(t=i[0]&2?s.return:i[0]?s.throw||((t=s.return)&&t.call(s),0):s.next)&&!(t=t.call(s,i[1])).done)return t;switch(s=0,t&&(i=[i[0]&2,t.value]),i[0]){case 0:case 1:t=i;break;case 4:return o.label++,{value:i[1],done:!1};case 5:o.label++,s=i[1],i=[0];continue;case 7:i=o.ops.pop(),o.trys.pop();continue;default:if(t=o.trys,!(t=t.length>0&&t[t.length-1])&&(i[0]===6||i[0]===2)){o=0;continue}if(i[0]===3&&(!t||i[1]>t[0]&&i[1]<t[3])){o.label=i[1];break}if(i[0]===6&&o.label<t[1]){o.label=t[1],t=i;break}if(t&&o.label<t[2]){o.label=t[2],o.ops.push(i);break}t[2]&&o.ops.pop(),o.trys.pop();continue}i=e.call(n,o)}catch(a){i=[6,a],s=0}finally{r=t=0}if(i[0]&5)throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}}typeof SuppressedError=="function"&&SuppressedError;var y=function(n,e){return w(void 0,void 0,void 0,function(){return _(this,function(o){return[2,new Promise(function(r,s){try{if(window.DocsAPI)return r(null);var t=document.getElementById(e);if(t)var u=setInterval(function(){var f=t.getAttribute("loading");if(!f){if(clearInterval(u),window.DocsAPI)return r(null);var i=p(e,n,r,s);t.remove(),document.body.appendChild(i)}},500);else{var l=p(e,n,r,s);document.body.appendChild(l)}}catch(f){console.error(f)}})]})})},p=function(n,e,o,r){var s=document.createElement("script");return s.id=n,s.type="text/javascript",s.src=e,s.async=!0,s.onload=function(){s.removeAttribute("loading"),o(null)},s.onerror=function(t){s.removeAttribute("loading"),r(t)},s.setAttribute("loading",""),s},h=c.defineComponent({name:"DocumentEditor",props:{id:{type:String,required:!0},documentServerUrl:{type:String,required:!0},config:{type:Object,required:!0},document_fileType:String,document_title:String,documentType:String,editorConfig_lang:String,height:String,type:String,width:String,onLoadComponentError:Function,events_onAppReady:Function,events_onDocumentStateChange:Function,events_onMetaChange:Function,events_onDocumentReady:Function,events_onInfo:Function,events_onWarning:Function,events_onError:Function,events_onRequestSharingSettings:Function,events_onRequestRename:Function,events_onMakeActionLink:Function,events_onRequestInsertImage:Function,events_onRequestSaveAs:Function,events_onRequestMailMergeRecipients:Function,events_onRequestCompareFile:Function,events_onRequestEditRights:Function,events_onRequestHistory:Function,events_onRequestHistoryClose:Function,events_onRequestHistoryData:Function,events_onRequestRestore:Function,events_onRequestSelectSpreadsheet:Function,events_onRequestSelectDocument:Function},mounted:function(){var n=this,e=this.documentServerUrl;e.endsWith("/")||(e+="/");var o="".concat(e,"web-apps/apps/api/documents/api.js");y(o,"onlyoffice-api-script").then(function(){return n.onLoad()}).catch(function(){n.onError(-2)})},unmounted:function(){var n,e=this.id||"";!((n=window==null?void 0:window.DocEditor)===null||n===void 0)&&n.instances[e]&&(window.DocEditor.instances[e].destroyEditor(),window.DocEditor.instances[e]=void 0)},watch:{config:{handler:function(n,e){this.onChangeProps()},deep:!0},document_fileType:function(n,e){this.onChangeProps()},document_title:function(n,e){this.onChangeProps()},documentType:function(n,e){this.onChangeProps()},editorConfig_lang:function(n,e){this.onChangeProps()},height:function(n,e){this.onChangeProps()},type:function(n,e){this.onChangeProps()},width:function(n,e){this.onChangeProps()}},methods:{onLoad:function(){var n,e;try{var o=this.id||"";if(window.DocsAPI||this.onError(-3),!((n=window==null?void 0:window.DocEditor)===null||n===void 0)&&n.instances[o]){console.log("Skip loading. Instance already exists",o);return}!((e=window==null?void 0:window.DocEditor)===null||e===void 0)&&e.instances||(window.DocEditor={instances:{}});var r=Object.assign({document:{fileType:this.document_fileType,title:this.document_title},documentType:this.documentType,editorConfig:{lang:this.editorConfig_lang},events:{onAppReady:this.onAppReady,onDocumentStateChange:this.events_onDocumentStateChange,onMetaChange:this.events_onMetaChange,onDocumentReady:this.events_onDocumentReady,onInfo:this.events_onInfo,onWarning:this.events_onWarning,onError:this.events_onError,onRequestSharingSettings:this.events_onRequestSharingSettings,onRequestRename:this.events_onRequestRename,onMakeActionLink:this.events_onMakeActionLink,onRequestInsertImage:this.events_onRequestInsertImage,onRequestSaveAs:this.events_onRequestSaveAs,onRequestMailMergeRecipients:this.events_onRequestMailMergeRecipients,onRequestCompareFile:this.events_onRequestCompareFile,onRequestEditRights:this.events_onRequestEditRights,onRequestHistory:this.events_onRequestHistory,onRequestHistoryClose:this.events_onRequestHistoryClose,onRequestHistoryData:this.events_onRequestHistoryData,onRequestRestore:this.events_onRequestRestore,onRequestSelectSpreadsheet:this.events_onRequestSelectSpreadsheet,onRequestSelectDocument:this.events_onRequestSelectDocument},height:this.height,type:this.type,width:this.width},this.config||{}),s=window.DocsAPI.DocEditor(o,r);window.DocEditor.instances[o]=s}catch(t){console.error(t),this.onError(-1)}},onError:function(n){var e;switch(n){case-2:e="Error load DocsAPI from "+this.documentServerUrl;break;case-3:e="DocsAPI is not defined";break;default:e="Unknown error loading component",n=-1}typeof this.onLoadComponentError>"u"?console.error(e):this.onLoadComponentError(n,e)},onAppReady:function(){var n=this.id||"";this.events_onAppReady(window.DocEditor.instances[n])},onChangeProps:function(){var n,e=this.id||"";!((n=window==null?void 0:window.DocEditor)===null||n===void 0)&&n.instances[e]&&(window.DocEditor.instances[e].destroyEditor(),window.DocEditor.instances[e]=void 0,console.log("Important props have been changed. Load new Editor."),this.onLoad())}}});const R=["id"];function S(n,e,o,r,s,t){return c.openBlock(),c.createElementBlock("div",{id:n.id},null,8,R)}h.render=S,h.__file="src/components/DocumentEditor.vue";const g=m(c.defineComponent({__name:"IkOnlyOffice",props:{documentServerUrl:{type:String,default:""},configOptions:{type:Object,default:()=>{}},officeHeight:{type:String,default:"100%"}},setup(n){const e=n,o=c.ref({width:"100%",height:"100%",...e.configOptions||{},...e.configOptions}),r=()=>{console.info("文档加载完成",e.configOptions)};return(s,t)=>(c.openBlock(),c.createElementBlock("div",{style:c.normalizeStyle({height:e.officeHeight})},[c.createVNode(c.unref(h),{id:`${new Date().getTime()}`,ref:"editorRef","document-server-url":n.documentServerUrl,config:o.value,events_onDocumentReady:r},null,8,["id","document-server-url","config"])],4))}}));d.IkOnlyOffice=g,d.default=g,Object.defineProperties(d,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|