@ckeditor/ckeditor5-import-word 41.3.0 → 41.3.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.
@@ -2,4 +2,4 @@
2
2
  /*!
3
3
  * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
4
4
  * For licensing, see LICENSE.md.
5
- */(()=>{var t={331:(t,e,r)=>{t.exports=r(237)("./src/clipboard.js")},782:(t,e,r)=>{t.exports=r(237)("./src/core.js")},783:(t,e,r)=>{t.exports=r(237)("./src/engine.js")},311:(t,e,r)=>{t.exports=r(237)("./src/ui.js")},584:(t,e,r)=>{t.exports=r(237)("./src/utils.js")},237:t=>{"use strict";t.exports=CKEditor5.dll}},e={};function r(o){var n=e[o];if(void 0!==n)return n.exports;var i=e[o]={exports:{}};return t[o](i,i.exports,r),i.exports}r.d=(t,e)=>{for(var o in e)r.o(e,o)&&!r.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:e[o]})},r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var o={};(()=>{"use strict";r.r(o),r.d(o,{ImportWord:()=>f,ImportWordEditing:()=>u,ImportWordUI:()=>n});var t=r(782),e=r(311);class n extends t.Plugin{static get pluginName(){return"ImportWordUI"}init(){const t=this.editor;t.ui.componentFactory.add("importWord",(()=>{const r=this._createButton(e.FileDialogButtonView),o=t.commands.get("importWord");return r.bind("isOn").to(o,"isBusy"),r.tooltip=!0,r})),t.ui.componentFactory.add("menuBar:importWord",(()=>this._createButton(e.MenuBarMenuListItemFileDialogButtonView)))}_createButton(t){const r=this.editor,o=r.locale.t,n=r.commands.get("importWord"),i=new t(r.locale),s=new e.SpinnerView;return i.set({acceptedType:"application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.wordprocessingml.template"}),i.set({label:o("Import from Word"),icon:'<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="m14 0 5 4.5v8.892l-1.5-1.8V6.5h-5v-5h-8v3H3V0h11Zm0 2v3h3.3L14 2Z"/><path d="M10.74 18a2.76 2.76 0 0 1-.469-.5H3V19h9.25v-.374A2.737 2.737 0 0 1 10.74 18Z"/><path d="M8.5 6a1.5 1.5 0 0 1 1.493 1.356L10 7.5v7a1.5 1.5 0 0 1-1.356 1.493L8.5 16h-7a1.5 1.5 0 0 1-1.493-1.356L0 14.5v-7a1.5 1.5 0 0 1 1.356-1.493L1.5 6h7ZM7.483 8.795l-.042.088-.986 2.534-.947-2.528-.043-.092a.601.601 0 0 0-1.042.008l-.042.093-.883 2.465-.937-2.475-.042-.089a.6.6 0 0 0-1.107.42l.027.093 1.514 4 .044.092a.6.6 0 0 0 1.041-.01l.041-.092.88-2.458.925 2.467.046.096a.602.602 0 0 0 1.032 0l.043-.09 1.554-4 .028-.093a.6.6 0 0 0-1.104-.43v.001ZM11.674 15.407a.75.75 0 1 0 1.152.96L14 14.96V20h1.5v-5.04l1.174 1.408a.75.75 0 1 0 1.152-.96l-2.346-2.816a.95.95 0 0 0-1.46 0l-2.346 2.815Z"/></svg>\n'}),i.bind("isEnabled").to(n),s.bind("isVisible").to(n,"isBusy"),i.iconView.bind("isVisible").to(n,"isBusy",(t=>!t)),i.children.add(s),i.on("done",((t,e)=>{r.execute("importWord",e[0],{}),r.editing.view.focus()})),i}}var i=r(331),s=r(783),a=r(584);class c extends t.Command{constructor(t){super(t),this.set("isBusy",!1),this._importMarker=null,this._undoStepBatch=null,this._abortController=null,this.on("dataInsert",((e,r)=>{const o=new DataTransfer;o.setData("text/html",r.html);const n=this._importMarker.getRange();this.editor.model.enqueueChange(this._undoStepBatch,(e=>{this._importMarker.stopListening(),e.setSelection(n),t.editing.view.document.fire("clipboardInput",{dataTransfer:o})}))}),{priority:"low"})}refresh(){this.isEnabled=this._checkEnabled()}execute(t,e={}){if(this.isBusy)return Promise.resolve();const r=this.editor.config.get("importWord"),o={url:r.converterUrl,file:t,serviceConfig:{...e,formatting:r.formatting}};return this._prepareForImport(),this._sendImportRequest(o).then(this._handleImportResponse.bind(this)).catch(this._handleImportFailure.bind(this)).finally(this._cleanUpAfterImport.bind(this))}_checkEnabled(){if(this.isBusy)return!1;const t=this.editor.model,e=t.schema,r=t.document.selection,o=(0,a.first)(r.getSelectedBlocks());return!!o&&e.checkChild(o.parent,"paragraph")}_prepareForImport(){const t=this.editor,e=t.model,r=e.document.selection;this._abortController=new AbortController,this._undoStepBatch=t.model.createBatch({isUndoable:!0}),e.enqueueChange(this._undoStepBatch,(t=>{r.isCollapsed||e.deleteContent(r,{leaveUnmerged:!0});const o=r.getFirstPosition(),n=(0,a.first)(r.getSelectedBlocks());let i;i=n.is("element","paragraph")&&n.isEmpty?o:o.isAtStart?e.createPositionBefore(n):o.isAtEnd?e.createPositionAfter(n):t.split(o).position,this._importMarker=t.addMarker("importWord:"+(0,a.uid)(),{usingOperation:!1,affectsData:!1,range:new s.Range(i)}),this._importMarker.on("change:range",(()=>{"$graveyard"===this._importMarker.getRange().root.rootName&&this._abortController.abort()}))})),this.isBusy=!0,this.refresh()}_cleanUpAfterImport(){const t=this.editor.model;t.markers.has(this._importMarker)&&t.enqueueChange(this._undoStepBatch,(t=>{t.removeMarker(this._importMarker)})),this._importMarker=null,this._undoStepBatch=null,this._abortController=null,this.isBusy=!1,this.refresh()}_sendImportRequest({url:t,file:e,serviceConfig:r}){const o=this.editor.plugins.get("ImportWordEditing").getToken(),n=new FormData;n.set("config",JSON.stringify(r)),n.set("file",e);const i={method:"POST",headers:{},body:n,signal:this._abortController.signal};return o&&(i.headers.Authorization=o.value),fetch(t,i)}_handleImportResponse(t){return t.ok?t.json().then((t=>{this.editor.model.markers.has(this._importMarker)&&"$graveyard"!==this._importMarker.getRange().root.rootName&&this.fire("dataInsert",t)})):Promise.reject()}_handleImportFailure(){if(this._abortController.signal.aborted)return void(0,a.logWarning)("import-word-plugin-import-cancelled");const t=this.editor,e=(0,t.t)("An error occurred while importing the Word file.");t.plugins.get("Notification").showWarning(e),(0,a.logError)("import-word-plugin-conversion-failed")}}const p=d;function l(){const t=["7680726LcpoMS","pluginName","6mrvaKU","519187MGTAuZ","ImportWordEditing","5492100kVuzao","config","token","2PVwsnk","CloudServices","get","none","140776MwvWal","16819VIUWpy","add","inline","init","7630PFclZx","importWord","https://docx-converter.cke-cs.com/v2/convert/docx-html","commands","6947227ATdkbq","6TgLQEA","editor","_token","23737512UbFkAH","8jrTfWc","cloudServices","plugins","requires","registerTokenUrl","define","tokenUrl","getToken"];return(l=function(){return t})()}function d(t,e){const r=l();return(d=function(t,e){return r[t-=440]})(t,e)}!function(t,e){const r=d,o=t();for(;;)try{if(649257===-parseInt(r(460))/1*(-parseInt(r(465))/2)+parseInt(r(445))/3*(-parseInt(r(469))/4)+-parseInt(r(462))/5+parseInt(r(459))/6*(-parseInt(r(444))/7)+-parseInt(r(449))/8*(parseInt(r(457))/9)+-parseInt(r(440))/10*(-parseInt(r(470))/11)+parseInt(r(448))/12)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(l);class u extends t.Plugin{static get[p(458)](){return p(461)}static get[p(452)](){const t=p;return[e.Notification,i.ClipboardPipeline,t(466)]}constructor(t){const e=p;super(t),this[e(447)]=null}async[p(473)](){const t=p,e=this[t(446)];e[t(463)][t(454)](t(441),{converterUrl:t(442),tokenUrl:(e[t(463)][t(467)](t(450))||{})[t(455)],formatting:{resets:t(468),defaults:t(468),styles:t(472)}}),e[t(443)][t(471)](t(441),new c(e));const{tokenUrl:r}=e[t(463)][t(467)](t(441));if(r){const{tokenUrl:o}=e[t(463)][t(467)](t(450))||{};this[t(447)]=r===o?e[t(451)][t(467)](t(466))[t(464)]:await e[t(451)][t(467)](t(466))[t(453)](r)}}[p(456)](){return this[p(447)]}}function h(){var t=["1152422bePpQZ","357387wPmLxh","28563315tLCRPi","30DJoYeF","535105SDPGHk","pluginName","requires","1265661gTNwDx","44mApJVj","ImportWord","1043HcXCSB","2208912KticxT","4LIpsjB","8328yywpvD"];return(h=function(){return t})()}function m(t,e){var r=h();return(m=function(t,e){return r[t-=470]})(t,e)}var g=m;!function(t,e){for(var r=m,o=t();;)try{if(606176===parseInt(r(483))/1+-parseInt(r(481))/2*(-parseInt(r(470))/3)+parseInt(r(477))/4*(parseInt(r(473))/5)+parseInt(r(480))/6+-parseInt(r(479))/7*(parseInt(r(482))/8)+-parseInt(r(476))/9*(-parseInt(r(472))/10)+-parseInt(r(471))/11)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(h);class f extends t.Plugin{static get[g(474)](){return g(478)}static get[g(475)](){return[u,n]}}function I(){var t=["18506213qETZWP","150WGmhZh","984kBJIkb","10377CRLrET","3700BXhctK","24606vGGYlY","6308190hwiHpr","100675YbTarx","70PquJiE","3544TiBdEb","6456840PDzwEg"];return(I=function(){return t})()}function v(t,e){var r=I();return(v=function(t,e){return r[t-=130]})(t,e)}!function(t,e){for(var r=v,o=t();;)try{if(692774===parseInt(r(130))/1*(parseInt(r(134))/2)+parseInt(r(140))/3*(parseInt(r(139))/4)+parseInt(r(133))/5*(-parseInt(r(138))/6)+-parseInt(r(132))/7+-parseInt(r(135))/8*(parseInt(r(131))/9)+parseInt(r(136))/10+parseInt(r(137))/11)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(I)})(),(window.CKEditor5=window.CKEditor5||{}).importWord=o})();
5
+ */(()=>{var t={331:(t,e,r)=>{t.exports=r(237)("./src/clipboard.js")},782:(t,e,r)=>{t.exports=r(237)("./src/core.js")},783:(t,e,r)=>{t.exports=r(237)("./src/engine.js")},311:(t,e,r)=>{t.exports=r(237)("./src/ui.js")},584:(t,e,r)=>{t.exports=r(237)("./src/utils.js")},237:t=>{"use strict";t.exports=CKEditor5.dll}},e={};function r(o){var n=e[o];if(void 0!==n)return n.exports;var i=e[o]={exports:{}};return t[o](i,i.exports,r),i.exports}r.d=(t,e)=>{for(var o in e)r.o(e,o)&&!r.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:e[o]})},r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var o={};(()=>{"use strict";r.r(o),r.d(o,{ImportWord:()=>g,ImportWordEditing:()=>u,ImportWordUI:()=>n});var t=r(782),e=r(311);class n extends t.Plugin{static get pluginName(){return"ImportWordUI"}init(){const t=this.editor;t.ui.componentFactory.add("importWord",(()=>{const r=this._createButton(e.FileDialogButtonView),o=t.commands.get("importWord");return r.bind("isOn").to(o,"isBusy"),r.tooltip=!0,r})),t.ui.componentFactory.add("menuBar:importWord",(()=>this._createButton(e.MenuBarMenuListItemFileDialogButtonView)))}_createButton(t){const r=this.editor,o=r.locale.t,n=r.commands.get("importWord"),i=new t(r.locale),s=new e.SpinnerView;return i.set({acceptedType:"application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.wordprocessingml.template"}),i.set({label:o("Import from Word"),icon:'<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="m14 0 5 4.5v8.892l-1.5-1.8V6.5h-5v-5h-8v3H3V0h11Zm0 2v3h3.3L14 2Z"/><path d="M10.74 18a2.76 2.76 0 0 1-.469-.5H3V19h9.25v-.374A2.737 2.737 0 0 1 10.74 18Z"/><path d="M8.5 6a1.5 1.5 0 0 1 1.493 1.356L10 7.5v7a1.5 1.5 0 0 1-1.356 1.493L8.5 16h-7a1.5 1.5 0 0 1-1.493-1.356L0 14.5v-7a1.5 1.5 0 0 1 1.356-1.493L1.5 6h7ZM7.483 8.795l-.042.088-.986 2.534-.947-2.528-.043-.092a.601.601 0 0 0-1.042.008l-.042.093-.883 2.465-.937-2.475-.042-.089a.6.6 0 0 0-1.107.42l.027.093 1.514 4 .044.092a.6.6 0 0 0 1.041-.01l.041-.092.88-2.458.925 2.467.046.096a.602.602 0 0 0 1.032 0l.043-.09 1.554-4 .028-.093a.6.6 0 0 0-1.104-.43v.001ZM11.674 15.407a.75.75 0 1 0 1.152.96L14 14.96V20h1.5v-5.04l1.174 1.408a.75.75 0 1 0 1.152-.96l-2.346-2.816a.95.95 0 0 0-1.46 0l-2.346 2.815Z"/></svg>\n'}),i.bind("isEnabled").to(n),s.bind("isVisible").to(n,"isBusy"),i.iconView.bind("isVisible").to(n,"isBusy",(t=>!t)),i.children.add(s),i.on("done",((t,e)=>{r.execute("importWord",e[0],{}),r.editing.view.focus()})),i}}var i=r(331),s=r(783),a=r(584);class c extends t.Command{constructor(t){super(t),this.set("isBusy",!1),this._importMarker=null,this._undoStepBatch=null,this._abortController=null,this.on("dataInsert",((e,r)=>{const o=new DataTransfer;o.setData("text/html",r.html);const n=this._importMarker.getRange();this.editor.model.enqueueChange(this._undoStepBatch,(e=>{this._importMarker.stopListening(),e.setSelection(n),t.editing.view.document.fire("clipboardInput",{dataTransfer:o})}))}),{priority:"low"})}refresh(){this.isEnabled=this._checkEnabled()}execute(t,e={}){if(this.isBusy)return Promise.resolve();const r=this.editor.config.get("importWord"),o={url:r.converterUrl,file:t,serviceConfig:{...e,formatting:r.formatting}};return this._prepareForImport(),this._sendImportRequest(o).then(this._handleImportResponse.bind(this)).catch(this._handleImportFailure.bind(this)).finally(this._cleanUpAfterImport.bind(this))}_checkEnabled(){if(this.isBusy)return!1;const t=this.editor.model,e=t.schema,r=t.document.selection,o=(0,a.first)(r.getSelectedBlocks());return!!o&&e.checkChild(o.parent,"paragraph")}_prepareForImport(){const t=this.editor,e=t.model,r=e.document.selection;this._abortController=new AbortController,this._undoStepBatch=t.model.createBatch({isUndoable:!0}),e.enqueueChange(this._undoStepBatch,(t=>{r.isCollapsed||e.deleteContent(r,{leaveUnmerged:!0});const o=r.getFirstPosition(),n=(0,a.first)(r.getSelectedBlocks());let i;i=n.is("element","paragraph")&&n.isEmpty?o:o.isAtStart?e.createPositionBefore(n):o.isAtEnd?e.createPositionAfter(n):t.split(o).position,this._importMarker=t.addMarker("importWord:"+(0,a.uid)(),{usingOperation:!1,affectsData:!1,range:new s.Range(i)}),this._importMarker.on("change:range",(()=>{"$graveyard"===this._importMarker.getRange().root.rootName&&this._abortController.abort()}))})),this.isBusy=!0,this.refresh()}_cleanUpAfterImport(){const t=this.editor.model;t.markers.has(this._importMarker)&&t.enqueueChange(this._undoStepBatch,(t=>{t.removeMarker(this._importMarker)})),this._importMarker=null,this._undoStepBatch=null,this._abortController=null,this.isBusy=!1,this.refresh()}_sendImportRequest({url:t,file:e,serviceConfig:r}){const o=this.editor.plugins.get("ImportWordEditing").getToken(),n=new FormData;n.set("config",JSON.stringify(r)),n.set("file",e);const i={method:"POST",headers:{},body:n,signal:this._abortController.signal};return o&&(i.headers.Authorization=o.value),fetch(t,i)}_handleImportResponse(t){return t.ok?t.json().then((t=>{this.editor.model.markers.has(this._importMarker)&&"$graveyard"!==this._importMarker.getRange().root.rootName&&this.fire("dataInsert",t)})):Promise.reject()}_handleImportFailure(){if(this._abortController.signal.aborted)return void(0,a.logWarning)("import-word-plugin-import-cancelled");const t=this.editor,e=(0,t.t)("An error occurred while importing the Word file.");t.plugins.get("Notification").showWarning(e),(0,a.logError)("import-word-plugin-conversion-failed")}}const l=p;function p(t,e){const r=d();return(p=function(t,e){return r[t-=421]})(t,e)}function d(){const t=["170432NhgxSj","19336610NYHDwF","config","26472QAlomG","importWord","16WXAWiB","tokenUrl","token","define","add","_token","cloudServices","CloudServices","commands","1954116kOTTCn","pluginName","init","requires","editor","inline","1385QoYOzg","plugins","12356bTZVCp","2720484iRjTsC","https://docx-converter.cke-cs.com/v2/convert/docx-html","1274rWSxqs","getToken","get","registerTokenUrl","ImportWordEditing","none","255260TvGseP"];return(d=function(){return t})()}!function(t,e){const r=p,o=t();for(;;)try{if(475210===-parseInt(r(452))/1+parseInt(r(421))/2+-parseInt(r(444))/3+parseInt(r(443))/4*(parseInt(r(441))/5)+-parseInt(r(424))/6*(parseInt(r(446))/7)+-parseInt(r(426))/8*(parseInt(r(435))/9)+parseInt(r(422))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(d);class u extends t.Plugin{static get[l(436)](){return l(450)}static get[l(438)](){const t=l;return[e.Notification,i.ClipboardPipeline,t(433)]}constructor(t){const e=l;super(t),this[e(431)]=null}async[l(437)](){const t=l,e=this[t(439)];e[t(423)][t(429)](t(425),{converterUrl:t(445),tokenUrl:(e[t(423)][t(448)](t(432))||{})[t(427)],formatting:{resets:t(451),defaults:t(451),styles:t(440)}}),e[t(434)][t(430)](t(425),new c(e));const{tokenUrl:r}=e[t(423)][t(448)](t(425));if(r){const{tokenUrl:o}=e[t(423)][t(448)](t(432))||{};this[t(431)]=r===o?e[t(442)][t(448)](t(433))[t(428)]:await e[t(442)][t(448)](t(433))[t(449)](r)}}[l(447)](){return this[l(431)]}}var h=m;function m(t,e){var r=f();return(m=function(t,e){return r[t-=172]})(t,e)}!function(t,e){for(var r=m,o=t();;)try{if(213730===-parseInt(r(172))/1+-parseInt(r(179))/2*(parseInt(r(183))/3)+-parseInt(r(173))/4+-parseInt(r(182))/5*(parseInt(r(181))/6)+parseInt(r(180))/7+parseInt(r(175))/8*(-parseInt(r(178))/9)+parseInt(r(177))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(f);class g extends t.Plugin{static get[h(174)](){return h(176)}static get[h(184)](){return[u,n]}}function f(){var t=["12300600eSiPQu","675AMVsJg","128gpQlya","152859FYkAcv","6lhVqbd","691885CHeDlx","2970pMKRHO","requires","85681kIyBwr","1302296vYqzNj","pluginName","45352juAfID","ImportWord"];return(f=function(){return t})()}function I(t,e){var r=v();return(I=function(t,e){return r[t-=397]})(t,e)}function v(){var t=["5646452IfWmts","2117648GElGxC","2121095nrXBgQ","1938126ByWCYh","2111352vxPAwG","14TWltrN","4437582zFuVeI","2076010nHglnA"];return(v=function(){return t})()}!function(t,e){for(var r=I,o=t();;)try{if(982561===parseInt(r(397))/1+-parseInt(r(401))/2+parseInt(r(398))/3+-parseInt(r(402))/4+-parseInt(r(404))/5+-parseInt(r(400))/6*(-parseInt(r(399))/7)+-parseInt(r(403))/8)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(v)})(),(window.CKEditor5=window.CKEditor5||{}).importWord=o})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ckeditor/ckeditor5-import-word",
3
- "version": "41.3.0",
3
+ "version": "41.3.1",
4
4
  "description": "Import from Word feature for CKEditor 5.",
5
5
  "keywords": [
6
6
  "ckeditor",
@@ -30,7 +30,7 @@
30
30
  "type": "module",
31
31
  "main": "src/index.js",
32
32
  "dependencies": {
33
- "ckeditor5": "41.3.0"
33
+ "ckeditor5": "41.3.1"
34
34
  },
35
35
  "license": "SEE LICENSE IN LICENSE.md",
36
36
  "author": "CKSource (https://cksource.com/)",
package/src/importword.js CHANGED
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- function _0x27da(){var _0x3323cc=['1152422bePpQZ','357387wPmLxh','28563315tLCRPi','30DJoYeF','535105SDPGHk','pluginName','requires','1265661gTNwDx','44mApJVj','ImportWord','1043HcXCSB','2208912KticxT','4LIpsjB','8328yywpvD'];_0x27da=function(){return _0x3323cc;};return _0x27da();}function _0x3224(_0x65b135,_0x3f4ee5){var _0x27da5b=_0x27da();return _0x3224=function(_0x322463,_0x148418){_0x322463=_0x322463-0x1d6;var _0xd1cce=_0x27da5b[_0x322463];return _0xd1cce;},_0x3224(_0x65b135,_0x3f4ee5);}var _0x15ec35=_0x3224;(function(_0x2e98b3,_0x3db021){var _0x38fccc=_0x3224,_0xe3bbbf=_0x2e98b3();while(!![]){try{var _0x305ac5=parseInt(_0x38fccc(0x1e3))/0x1+-parseInt(_0x38fccc(0x1e1))/0x2*(-parseInt(_0x38fccc(0x1d6))/0x3)+parseInt(_0x38fccc(0x1dd))/0x4*(parseInt(_0x38fccc(0x1d9))/0x5)+parseInt(_0x38fccc(0x1e0))/0x6+-parseInt(_0x38fccc(0x1df))/0x7*(parseInt(_0x38fccc(0x1e2))/0x8)+-parseInt(_0x38fccc(0x1dc))/0x9*(-parseInt(_0x38fccc(0x1d8))/0xa)+-parseInt(_0x38fccc(0x1d7))/0xb;if(_0x305ac5===_0x3db021)break;else _0xe3bbbf['push'](_0xe3bbbf['shift']());}catch(_0x4e76e0){_0xe3bbbf['push'](_0xe3bbbf['shift']());}}}(_0x27da,0x93fe0));import{Plugin as _0x51d4cb}from'ckeditor5/src/core.js';import _0x4e4197 from'./importwordui.js';import _0x4ad87f from'./importwordediting.js';export default class i extends _0x51d4cb{static get[_0x15ec35(0x1da)](){var _0x1cb470=_0x15ec35;return _0x1cb470(0x1de);}static get[_0x15ec35(0x1db)](){return[_0x4ad87f,_0x4e4197];}}
23
+ var _0x5c5479=_0x622d;(function(_0x1dd5ac,_0x3bfdf9){var _0x3b7bf3=_0x622d,_0x1ffca6=_0x1dd5ac();while(!![]){try{var _0x213a13=-parseInt(_0x3b7bf3(0xac))/0x1+-parseInt(_0x3b7bf3(0xb3))/0x2*(parseInt(_0x3b7bf3(0xb7))/0x3)+-parseInt(_0x3b7bf3(0xad))/0x4+-parseInt(_0x3b7bf3(0xb6))/0x5*(parseInt(_0x3b7bf3(0xb5))/0x6)+parseInt(_0x3b7bf3(0xb4))/0x7+parseInt(_0x3b7bf3(0xaf))/0x8*(-parseInt(_0x3b7bf3(0xb2))/0x9)+parseInt(_0x3b7bf3(0xb1))/0xa;if(_0x213a13===_0x3bfdf9)break;else _0x1ffca6['push'](_0x1ffca6['shift']());}catch(_0x23642f){_0x1ffca6['push'](_0x1ffca6['shift']());}}}(_0x4b33,0x342e2));import{Plugin as _0x1e0250}from'ckeditor5/src/core.js';import _0x222d3d from'./importwordui.js';import _0x1dae6b from'./importwordediting.js';function _0x622d(_0x1f2573,_0x5ef9f5){var _0x4b331e=_0x4b33();return _0x622d=function(_0x622d52,_0x58054b){_0x622d52=_0x622d52-0xac;var _0x323070=_0x4b331e[_0x622d52];return _0x323070;},_0x622d(_0x1f2573,_0x5ef9f5);}export default class i extends _0x1e0250{static get[_0x5c5479(0xae)](){var _0x47a40c=_0x5c5479;return _0x47a40c(0xb0);}static get[_0x5c5479(0xb8)](){return[_0x1dae6b,_0x222d3d];}}function _0x4b33(){var _0x42553c=['12300600eSiPQu','675AMVsJg','128gpQlya','152859FYkAcv','6lhVqbd','691885CHeDlx','2970pMKRHO','requires','85681kIyBwr','1302296vYqzNj','pluginName','45352juAfID','ImportWord'];_0x4b33=function(){return _0x42553c;};return _0x4b33();}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Command as _0x1f0f4}from'ckeditor5/src/core.js';import{Range as _0x5df0a2}from'ckeditor5/src/engine.js';import{logWarning as _0x23b21d,logError as _0x4fd322,first as _0x1debaa,uid as _0x5bc941}from'ckeditor5/src/utils.js';export default class d extends _0x1f0f4{constructor(_0x46e509){super(_0x46e509),this['set']('isBusy',!0x1),this['_importMarker']=null,this['_undoStepBatch']=null,this['_abortController']=null,this['on']('dataInsert',(_0x5a1ba6,_0x5f1f15)=>{const _0x2f6261=new DataTransfer();_0x2f6261['setData']('text/html',_0x5f1f15['html']);const _0x100d1a=this['_importMarker']['getRange']();this['editor']['model']['enqueueChange'](this['_undoStepBatch'],_0x5b1da4=>{this['_importMarker']['stopListening'](),_0x5b1da4['setSelection'](_0x100d1a),_0x46e509['editing']['view']['document']['fire']('clipboardInput',{'dataTransfer':_0x2f6261});});},{'priority':'low'});}['refresh'](){this['isEnabled']=this['_checkEnabled']();}['execute'](_0x293ac6,_0x4d0de6={}){if(this['isBusy'])return Promise['resolve']();const _0x25035a=this['editor']['config']['get']('importWord'),_0x2caff7={'url':_0x25035a['converterUrl'],'file':_0x293ac6,'serviceConfig':{..._0x4d0de6,'formatting':_0x25035a['formatting']}};return this['_prepareForImport'](),this['_sendImportRequest'](_0x2caff7)['then'](this['_handleImportResponse']['bind'](this))['catch'](this['_handleImportFailure']['bind'](this))['finally'](this['_cleanUpAfterImport']['bind'](this));}['_checkEnabled'](){if(this['isBusy'])return!0x1;const _0x4dcfac=this['editor']['model'],_0x2045ef=_0x4dcfac['schema'],_0x3de587=_0x4dcfac['document']['selection'],_0x23468a=_0x1debaa(_0x3de587['getSelectedBlocks']());return!!_0x23468a&&_0x2045ef['checkChild'](_0x23468a['parent'],'paragraph');}['_prepareForImport'](){const _0x9c7797=this['editor'],_0x18e227=_0x9c7797['model'],_0x450a45=_0x18e227['document']['selection'];this['_abortController']=new AbortController(),this['_undoStepBatch']=_0x9c7797['model']['createBatch']({'isUndoable':!0x0}),_0x18e227['enqueueChange'](this['_undoStepBatch'],_0x54cd9c=>{_0x450a45['isCollapsed']||_0x18e227['deleteContent'](_0x450a45,{'leaveUnmerged':!0x0});const _0x3157c0=_0x450a45['getFirstPosition'](),_0x4700bc=_0x1debaa(_0x450a45['getSelectedBlocks']());let _0x3aba2c;_0x3aba2c=_0x4700bc['is']('element','paragraph')&&_0x4700bc['isEmpty']?_0x3157c0:_0x3157c0['isAtStart']?_0x18e227['createPositionBefore'](_0x4700bc):_0x3157c0['isAtEnd']?_0x18e227['createPositionAfter'](_0x4700bc):_0x54cd9c['split'](_0x3157c0)['position'],this['_importMarker']=_0x54cd9c['addMarker']('importWord:'+_0x5bc941(),{'usingOperation':!0x1,'affectsData':!0x1,'range':new _0x5df0a2(_0x3aba2c)}),this['_importMarker']['on']('change:range',()=>{'$graveyard'===this['_importMarker']['getRange']()['root']['rootName']&&this['_abortController']['abort']();});}),this['isBusy']=!0x0,this['refresh']();}['_cleanUpAfterImport'](){const _0x1711ea=this['editor']['model'];_0x1711ea['markers']['has'](this['_importMarker'])&&_0x1711ea['enqueueChange'](this['_undoStepBatch'],_0x305d92=>{_0x305d92['removeMarker'](this['_importMarker']);}),this['_importMarker']=null,this['_undoStepBatch']=null,this['_abortController']=null,this['isBusy']=!0x1,this['refresh']();}['_sendImportRequest']({url:_0x2f9618,file:_0x2a70d5,serviceConfig:_0x5d91d9}){const _0x26bf98=this['editor']['plugins']['get']('ImportWordEditing')['getToken'](),_0x595e5d=new FormData();_0x595e5d['set']('config',JSON['stringify'](_0x5d91d9)),_0x595e5d['set']('file',_0x2a70d5);const _0x75c704={'method':'POST','headers':{},'body':_0x595e5d,'signal':this['_abortController']['signal']};return _0x26bf98&&(_0x75c704['headers']['Authorization']=_0x26bf98['value']),fetch(_0x2f9618,_0x75c704);}['_handleImportResponse'](_0x5c3cd5){return _0x5c3cd5['ok']?_0x5c3cd5['json']()['then'](_0x1680f3=>{if(!this['editor']['model']['markers']['has'](this['_importMarker']))return;'$graveyard'!==this['_importMarker']['getRange']()['root']['rootName']&&this['fire']('dataInsert',_0x1680f3);}):Promise['reject']();}['_handleImportFailure'](){if(this['_abortController']['signal']['aborted'])return void _0x23b21d('import-word-plugin-import-cancelled');const _0x1b83c4=this['editor'],_0xede749=(0x0,_0x1b83c4['t'])('An\x20error\x20occurred\x20while\x20importing\x20the\x20Word\x20file.');_0x1b83c4['plugins']['get']('Notification')['showWarning'](_0xede749),_0x4fd322('import-word-plugin-conversion-failed');}}
23
+ import{Command as _0x143ada}from'ckeditor5/src/core.js';import{Range as _0x5566ea}from'ckeditor5/src/engine.js';import{logWarning as _0x22053e,logError as _0x4a736e,first as _0x384a1a,uid as _0x352307}from'ckeditor5/src/utils.js';export default class d extends _0x143ada{constructor(_0x1707f0){super(_0x1707f0),this['set']('isBusy',!0x1),this['_importMarker']=null,this['_undoStepBatch']=null,this['_abortController']=null,this['on']('dataInsert',(_0x2e4f81,_0x9eacd9)=>{const _0x498761=new DataTransfer();_0x498761['setData']('text/html',_0x9eacd9['html']);const _0x4d97ff=this['_importMarker']['getRange']();this['editor']['model']['enqueueChange'](this['_undoStepBatch'],_0xab58a8=>{this['_importMarker']['stopListening'](),_0xab58a8['setSelection'](_0x4d97ff),_0x1707f0['editing']['view']['document']['fire']('clipboardInput',{'dataTransfer':_0x498761});});},{'priority':'low'});}['refresh'](){this['isEnabled']=this['_checkEnabled']();}['execute'](_0x5bbdf3,_0x4ea4a2={}){if(this['isBusy'])return Promise['resolve']();const _0x2450c1=this['editor']['config']['get']('importWord'),_0x4ae53c={'url':_0x2450c1['converterUrl'],'file':_0x5bbdf3,'serviceConfig':{..._0x4ea4a2,'formatting':_0x2450c1['formatting']}};return this['_prepareForImport'](),this['_sendImportRequest'](_0x4ae53c)['then'](this['_handleImportResponse']['bind'](this))['catch'](this['_handleImportFailure']['bind'](this))['finally'](this['_cleanUpAfterImport']['bind'](this));}['_checkEnabled'](){if(this['isBusy'])return!0x1;const _0x33ef88=this['editor']['model'],_0xef7717=_0x33ef88['schema'],_0x12f710=_0x33ef88['document']['selection'],_0x1f89a2=_0x384a1a(_0x12f710['getSelectedBlocks']());return!!_0x1f89a2&&_0xef7717['checkChild'](_0x1f89a2['parent'],'paragraph');}['_prepareForImport'](){const _0x184e98=this['editor'],_0x3ddd3c=_0x184e98['model'],_0x3a6700=_0x3ddd3c['document']['selection'];this['_abortController']=new AbortController(),this['_undoStepBatch']=_0x184e98['model']['createBatch']({'isUndoable':!0x0}),_0x3ddd3c['enqueueChange'](this['_undoStepBatch'],_0x1f1fb1=>{_0x3a6700['isCollapsed']||_0x3ddd3c['deleteContent'](_0x3a6700,{'leaveUnmerged':!0x0});const _0x3e3532=_0x3a6700['getFirstPosition'](),_0x245fa1=_0x384a1a(_0x3a6700['getSelectedBlocks']());let _0x5b8172;_0x5b8172=_0x245fa1['is']('element','paragraph')&&_0x245fa1['isEmpty']?_0x3e3532:_0x3e3532['isAtStart']?_0x3ddd3c['createPositionBefore'](_0x245fa1):_0x3e3532['isAtEnd']?_0x3ddd3c['createPositionAfter'](_0x245fa1):_0x1f1fb1['split'](_0x3e3532)['position'],this['_importMarker']=_0x1f1fb1['addMarker']('importWord:'+_0x352307(),{'usingOperation':!0x1,'affectsData':!0x1,'range':new _0x5566ea(_0x5b8172)}),this['_importMarker']['on']('change:range',()=>{'$graveyard'===this['_importMarker']['getRange']()['root']['rootName']&&this['_abortController']['abort']();});}),this['isBusy']=!0x0,this['refresh']();}['_cleanUpAfterImport'](){const _0x2f47b4=this['editor']['model'];_0x2f47b4['markers']['has'](this['_importMarker'])&&_0x2f47b4['enqueueChange'](this['_undoStepBatch'],_0x5db408=>{_0x5db408['removeMarker'](this['_importMarker']);}),this['_importMarker']=null,this['_undoStepBatch']=null,this['_abortController']=null,this['isBusy']=!0x1,this['refresh']();}['_sendImportRequest']({url:_0xd84def,file:_0xa6d5a1,serviceConfig:_0x4898b6}){const _0x53dee9=this['editor']['plugins']['get']('ImportWordEditing')['getToken'](),_0x521fe2=new FormData();_0x521fe2['set']('config',JSON['stringify'](_0x4898b6)),_0x521fe2['set']('file',_0xa6d5a1);const _0x3d6d70={'method':'POST','headers':{},'body':_0x521fe2,'signal':this['_abortController']['signal']};return _0x53dee9&&(_0x3d6d70['headers']['Authorization']=_0x53dee9['value']),fetch(_0xd84def,_0x3d6d70);}['_handleImportResponse'](_0x24cd99){return _0x24cd99['ok']?_0x24cd99['json']()['then'](_0x102d3b=>{if(!this['editor']['model']['markers']['has'](this['_importMarker']))return;'$graveyard'!==this['_importMarker']['getRange']()['root']['rootName']&&this['fire']('dataInsert',_0x102d3b);}):Promise['reject']();}['_handleImportFailure'](){if(this['_abortController']['signal']['aborted'])return void _0x22053e('import-word-plugin-import-cancelled');const _0x1b9c6d=this['editor'],_0x53b309=(0x0,_0x1b9c6d['t'])('An\x20error\x20occurred\x20while\x20importing\x20the\x20Word\x20file.');_0x1b9c6d['plugins']['get']('Notification')['showWarning'](_0x53b309),_0x4a736e('import-word-plugin-conversion-failed');}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x3c9562=_0x46e9;(function(_0x3a58c7,_0x3ebe41){const _0x1c905b=_0x46e9,_0x59eda9=_0x3a58c7();while(!![]){try{const _0xf07cb7=-parseInt(_0x1c905b(0x1cc))/0x1*(-parseInt(_0x1c905b(0x1d1))/0x2)+parseInt(_0x1c905b(0x1bd))/0x3*(-parseInt(_0x1c905b(0x1d5))/0x4)+-parseInt(_0x1c905b(0x1ce))/0x5+parseInt(_0x1c905b(0x1cb))/0x6*(-parseInt(_0x1c905b(0x1bc))/0x7)+-parseInt(_0x1c905b(0x1c1))/0x8*(parseInt(_0x1c905b(0x1c9))/0x9)+-parseInt(_0x1c905b(0x1b8))/0xa*(-parseInt(_0x1c905b(0x1d6))/0xb)+parseInt(_0x1c905b(0x1c0))/0xc;if(_0xf07cb7===_0x3ebe41)break;else _0x59eda9['push'](_0x59eda9['shift']());}catch(_0x48809a){_0x59eda9['push'](_0x59eda9['shift']());}}}(_0x1447,0x9e829));function _0x1447(){const _0x5b3957=['7680726LcpoMS','pluginName','6mrvaKU','519187MGTAuZ','ImportWordEditing','5492100kVuzao','config','token','2PVwsnk','CloudServices','get','none','140776MwvWal','16819VIUWpy','add','inline','init','7630PFclZx','importWord','https://docx-converter.cke-cs.com/v2/convert/docx-html','commands','6947227ATdkbq','6TgLQEA','editor','_token','23737512UbFkAH','8jrTfWc','cloudServices','plugins','requires','registerTokenUrl','define','tokenUrl','getToken'];_0x1447=function(){return _0x5b3957;};return _0x1447();}import{Plugin as _0x5a70c1}from'ckeditor5/src/core.js';function _0x46e9(_0x5f5689,_0x37f02a){const _0x14476a=_0x1447();return _0x46e9=function(_0x46e9c8,_0x11b4d8){_0x46e9c8=_0x46e9c8-0x1b8;let _0xd32c05=_0x14476a[_0x46e9c8];return _0xd32c05;},_0x46e9(_0x5f5689,_0x37f02a);}import{Notification as _0x233799}from'ckeditor5/src/ui.js';import{ClipboardPipeline as _0x168edb}from'ckeditor5/src/clipboard.js';import _0x33b8ca from'./importwordcommand.js';export default class e extends _0x5a70c1{static get[_0x3c9562(0x1ca)](){const _0x2d9471=_0x3c9562;return _0x2d9471(0x1cd);}static get[_0x3c9562(0x1c4)](){const _0x4cf54a=_0x3c9562;return[_0x233799,_0x168edb,_0x4cf54a(0x1d2)];}constructor(_0x13d5b5){const _0x41b643=_0x3c9562;super(_0x13d5b5),this[_0x41b643(0x1bf)]=null;}async[_0x3c9562(0x1d9)](){const _0x488d77=_0x3c9562,_0x538667=this[_0x488d77(0x1be)];_0x538667[_0x488d77(0x1cf)][_0x488d77(0x1c6)](_0x488d77(0x1b9),{'converterUrl':_0x488d77(0x1ba),'tokenUrl':(_0x538667[_0x488d77(0x1cf)][_0x488d77(0x1d3)](_0x488d77(0x1c2))||{})[_0x488d77(0x1c7)],'formatting':{'resets':_0x488d77(0x1d4),'defaults':_0x488d77(0x1d4),'styles':_0x488d77(0x1d8)}}),_0x538667[_0x488d77(0x1bb)][_0x488d77(0x1d7)](_0x488d77(0x1b9),new _0x33b8ca(_0x538667));const {tokenUrl:_0xb9586c}=_0x538667[_0x488d77(0x1cf)][_0x488d77(0x1d3)](_0x488d77(0x1b9));if(_0xb9586c){const {tokenUrl:_0xd4cf64}=_0x538667[_0x488d77(0x1cf)][_0x488d77(0x1d3)](_0x488d77(0x1c2))||{};this[_0x488d77(0x1bf)]=_0xb9586c===_0xd4cf64?_0x538667[_0x488d77(0x1c3)][_0x488d77(0x1d3)](_0x488d77(0x1d2))[_0x488d77(0x1d0)]:await _0x538667[_0x488d77(0x1c3)][_0x488d77(0x1d3)](_0x488d77(0x1d2))[_0x488d77(0x1c5)](_0xb9586c);}}[_0x3c9562(0x1c8)](){const _0x172428=_0x3c9562;return this[_0x172428(0x1bf)];}}
23
+ const _0x3d44fa=_0x1d05;(function(_0x15f420,_0x1f9460){const _0x4160bd=_0x1d05,_0x2d0f74=_0x15f420();while(!![]){try{const _0xd5e2a5=-parseInt(_0x4160bd(0x1c4))/0x1+parseInt(_0x4160bd(0x1a5))/0x2+-parseInt(_0x4160bd(0x1bc))/0x3+parseInt(_0x4160bd(0x1bb))/0x4*(parseInt(_0x4160bd(0x1b9))/0x5)+-parseInt(_0x4160bd(0x1a8))/0x6*(parseInt(_0x4160bd(0x1be))/0x7)+-parseInt(_0x4160bd(0x1aa))/0x8*(parseInt(_0x4160bd(0x1b3))/0x9)+parseInt(_0x4160bd(0x1a6))/0xa;if(_0xd5e2a5===_0x1f9460)break;else _0x2d0f74['push'](_0x2d0f74['shift']());}catch(_0x5acd55){_0x2d0f74['push'](_0x2d0f74['shift']());}}}(_0x3bfb,0x7404a));import{Plugin as _0x151417}from'ckeditor5/src/core.js';import{Notification as _0x13ea12}from'ckeditor5/src/ui.js';import{ClipboardPipeline as _0x4d15b8}from'ckeditor5/src/clipboard.js';import _0x224f45 from'./importwordcommand.js';function _0x1d05(_0x331d12,_0x34c93a){const _0x3bfb47=_0x3bfb();return _0x1d05=function(_0x1d053e,_0x1710ee){_0x1d053e=_0x1d053e-0x1a5;let _0x97b07c=_0x3bfb47[_0x1d053e];return _0x97b07c;},_0x1d05(_0x331d12,_0x34c93a);}function _0x3bfb(){const _0x36678e=['170432NhgxSj','19336610NYHDwF','config','26472QAlomG','importWord','16WXAWiB','tokenUrl','token','define','add','_token','cloudServices','CloudServices','commands','1954116kOTTCn','pluginName','init','requires','editor','inline','1385QoYOzg','plugins','12356bTZVCp','2720484iRjTsC','https://docx-converter.cke-cs.com/v2/convert/docx-html','1274rWSxqs','getToken','get','registerTokenUrl','ImportWordEditing','none','255260TvGseP'];_0x3bfb=function(){return _0x36678e;};return _0x3bfb();}export default class e extends _0x151417{static get[_0x3d44fa(0x1b4)](){const _0x27d56c=_0x3d44fa;return _0x27d56c(0x1c2);}static get[_0x3d44fa(0x1b6)](){const _0x12764d=_0x3d44fa;return[_0x13ea12,_0x4d15b8,_0x12764d(0x1b1)];}constructor(_0x2b6b8e){const _0x13325b=_0x3d44fa;super(_0x2b6b8e),this[_0x13325b(0x1af)]=null;}async[_0x3d44fa(0x1b5)](){const _0x524f2e=_0x3d44fa,_0x1a5191=this[_0x524f2e(0x1b7)];_0x1a5191[_0x524f2e(0x1a7)][_0x524f2e(0x1ad)](_0x524f2e(0x1a9),{'converterUrl':_0x524f2e(0x1bd),'tokenUrl':(_0x1a5191[_0x524f2e(0x1a7)][_0x524f2e(0x1c0)](_0x524f2e(0x1b0))||{})[_0x524f2e(0x1ab)],'formatting':{'resets':_0x524f2e(0x1c3),'defaults':_0x524f2e(0x1c3),'styles':_0x524f2e(0x1b8)}}),_0x1a5191[_0x524f2e(0x1b2)][_0x524f2e(0x1ae)](_0x524f2e(0x1a9),new _0x224f45(_0x1a5191));const {tokenUrl:_0x51225d}=_0x1a5191[_0x524f2e(0x1a7)][_0x524f2e(0x1c0)](_0x524f2e(0x1a9));if(_0x51225d){const {tokenUrl:_0x51aa52}=_0x1a5191[_0x524f2e(0x1a7)][_0x524f2e(0x1c0)](_0x524f2e(0x1b0))||{};this[_0x524f2e(0x1af)]=_0x51225d===_0x51aa52?_0x1a5191[_0x524f2e(0x1ba)][_0x524f2e(0x1c0)](_0x524f2e(0x1b1))[_0x524f2e(0x1ac)]:await _0x1a5191[_0x524f2e(0x1ba)][_0x524f2e(0x1c0)](_0x524f2e(0x1b1))[_0x524f2e(0x1c1)](_0x51225d);}}[_0x3d44fa(0x1bf)](){const _0x347bbd=_0x3d44fa;return this[_0x347bbd(0x1af)];}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Plugin as _0x5efefb}from'ckeditor5/src/core.js';import{SpinnerView as _0x42fa66,FileDialogButtonView as _0x42b2b1,MenuBarMenuListItemFileDialogButtonView as _0x57f377}from'ckeditor5/src/ui.js';import _0x4c6794 from'../theme/icons/importword.svg';export default class o extends _0x5efefb{static get['pluginName'](){return'ImportWordUI';}['init'](){const _0x3d8a22=this['editor'];_0x3d8a22['ui']['componentFactory']['add']('importWord',()=>{const _0x27ad20=this['_createButton'](_0x42b2b1),_0x5bede2=_0x3d8a22['commands']['get']('importWord');return _0x27ad20['bind']('isOn')['to'](_0x5bede2,'isBusy'),_0x27ad20['tooltip']=!0x0,_0x27ad20;}),_0x3d8a22['ui']['componentFactory']['add']('menuBar:importWord',()=>this['_createButton'](_0x57f377));}['_createButton'](_0x1ceb83){const _0x38fe67=this['editor'],t=_0x38fe67['locale']['t'],_0x146b8f=_0x38fe67['commands']['get']('importWord'),_0x407d8c=new _0x1ceb83(_0x38fe67['locale']),_0xe69836=new _0x42fa66();return _0x407d8c['set']({'acceptedType':'application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.wordprocessingml.template'}),_0x407d8c['set']({'label':t('Import\x20from\x20Word'),'icon':_0x4c6794}),_0x407d8c['bind']('isEnabled')['to'](_0x146b8f),_0xe69836['bind']('isVisible')['to'](_0x146b8f,'isBusy'),_0x407d8c['iconView']['bind']('isVisible')['to'](_0x146b8f,'isBusy',_0x1ca523=>!_0x1ca523),_0x407d8c['children']['add'](_0xe69836),_0x407d8c['on']('done',(_0x549d49,_0x47a241)=>{_0x38fe67['execute']('importWord',_0x47a241[0x0],{}),_0x38fe67['editing']['view']['focus']();}),_0x407d8c;}}
23
+ import{Plugin as _0x24ba72}from'ckeditor5/src/core.js';import{SpinnerView as _0x209af5,FileDialogButtonView as _0x18884c,MenuBarMenuListItemFileDialogButtonView as _0x32fd7d}from'ckeditor5/src/ui.js';import _0x33fd2d from'../theme/icons/importword.svg';export default class o extends _0x24ba72{static get['pluginName'](){return'ImportWordUI';}['init'](){const _0x319c8f=this['editor'];_0x319c8f['ui']['componentFactory']['add']('importWord',()=>{const _0x2d34b2=this['_createButton'](_0x18884c),_0x37d9c9=_0x319c8f['commands']['get']('importWord');return _0x2d34b2['bind']('isOn')['to'](_0x37d9c9,'isBusy'),_0x2d34b2['tooltip']=!0x0,_0x2d34b2;}),_0x319c8f['ui']['componentFactory']['add']('menuBar:importWord',()=>this['_createButton'](_0x32fd7d));}['_createButton'](_0x5b47ce){const _0x558930=this['editor'],t=_0x558930['locale']['t'],_0x2fd97c=_0x558930['commands']['get']('importWord'),_0x1d727f=new _0x5b47ce(_0x558930['locale']),_0x35f10c=new _0x209af5();return _0x1d727f['set']({'acceptedType':'application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.wordprocessingml.template'}),_0x1d727f['set']({'label':t('Import\x20from\x20Word'),'icon':_0x33fd2d}),_0x1d727f['bind']('isEnabled')['to'](_0x2fd97c),_0x35f10c['bind']('isVisible')['to'](_0x2fd97c,'isBusy'),_0x1d727f['iconView']['bind']('isVisible')['to'](_0x2fd97c,'isBusy',_0x3ab2c5=>!_0x3ab2c5),_0x1d727f['children']['add'](_0x35f10c),_0x1d727f['on']('done',(_0x4abfed,_0xe1cf34)=>{_0x558930['execute']('importWord',_0xe1cf34[0x0],{}),_0x558930['editing']['view']['focus']();}),_0x1d727f;}}
package/src/index.js CHANGED
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- function _0x3417(){var _0x1a707e=['18506213qETZWP','150WGmhZh','984kBJIkb','10377CRLrET','3700BXhctK','24606vGGYlY','6308190hwiHpr','100675YbTarx','70PquJiE','3544TiBdEb','6456840PDzwEg'];_0x3417=function(){return _0x1a707e;};return _0x3417();}(function(_0x2925c9,_0x5dda0a){var _0x44ff33=_0x3d74,_0x31b621=_0x2925c9();while(!![]){try{var _0x27c47f=parseInt(_0x44ff33(0x82))/0x1*(parseInt(_0x44ff33(0x86))/0x2)+parseInt(_0x44ff33(0x8c))/0x3*(parseInt(_0x44ff33(0x8b))/0x4)+parseInt(_0x44ff33(0x85))/0x5*(-parseInt(_0x44ff33(0x8a))/0x6)+-parseInt(_0x44ff33(0x84))/0x7+-parseInt(_0x44ff33(0x87))/0x8*(parseInt(_0x44ff33(0x83))/0x9)+parseInt(_0x44ff33(0x88))/0xa+parseInt(_0x44ff33(0x89))/0xb;if(_0x27c47f===_0x5dda0a)break;else _0x31b621['push'](_0x31b621['shift']());}catch(_0x28728e){_0x31b621['push'](_0x31b621['shift']());}}}(_0x3417,0xa9226));export{default as ImportWord}from'./importword.js';export{default as ImportWordEditing}from'./importwordediting.js';export{default as ImportWordUI}from'./importwordui.js';function _0x3d74(_0x366db1,_0x115177){var _0x34179d=_0x3417();return _0x3d74=function(_0x3d745e,_0x1ebe45){_0x3d745e=_0x3d745e-0x82;var _0x1e96e7=_0x34179d[_0x3d745e];return _0x1e96e7;},_0x3d74(_0x366db1,_0x115177);}import'./augmentation.js';
23
+ (function(_0x44dc92,_0x11a54e){var _0x37bd13=_0x4698,_0x975f49=_0x44dc92();while(!![]){try{var _0x48d56f=parseInt(_0x37bd13(0x18d))/0x1+-parseInt(_0x37bd13(0x191))/0x2+parseInt(_0x37bd13(0x18e))/0x3+-parseInt(_0x37bd13(0x192))/0x4+-parseInt(_0x37bd13(0x194))/0x5+-parseInt(_0x37bd13(0x190))/0x6*(-parseInt(_0x37bd13(0x18f))/0x7)+-parseInt(_0x37bd13(0x193))/0x8;if(_0x48d56f===_0x11a54e)break;else _0x975f49['push'](_0x975f49['shift']());}catch(_0x4030cd){_0x975f49['push'](_0x975f49['shift']());}}}(_0x2cbf,0xefe21));export{default as ImportWord}from'./importword.js';export{default as ImportWordEditing}from'./importwordediting.js';export{default as ImportWordUI}from'./importwordui.js';import'./augmentation.js';function _0x4698(_0xa8f5b8,_0x51ea09){var _0x2cbf55=_0x2cbf();return _0x4698=function(_0x4698bd,_0x2a4711){_0x4698bd=_0x4698bd-0x18d;var _0x2904c=_0x2cbf55[_0x4698bd];return _0x2904c;},_0x4698(_0xa8f5b8,_0x51ea09);}function _0x2cbf(){var _0x363408=['5646452IfWmts','2117648GElGxC','2121095nrXBgQ','1938126ByWCYh','2111352vxPAwG','14TWltrN','4437582zFuVeI','2076010nHglnA'];_0x2cbf=function(){return _0x363408;};return _0x2cbf();}