UNPKG

@ckeditor/ckeditor5-import-word

Version:

Import from Word feature for CKEditor 5.

23 lines 4.98 kB
/* * Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved. * * * * * +---------------------------------------------------------------------------------+ * | | * | Hello stranger! | * | | * | | * | What you're currently looking at is the source code of a legally protected, | * | proprietary software. Any attempts to deobfuscate / disassemble this code | * | are forbidden and will result in legal consequences. | * | | * | | * +---------------------------------------------------------------------------------+ * * * * */ function _0xf46a(){const _0x16ceee=['isVisible','pluginName','Importing\x20Word\x20document','menuBar:importWord','children','label','219828NJKxMH','15YsimAr','46220ZHCgVy','get','isEnabled','commands','add','componentFactory','166738PpSSqR','tooltip','bind','focus','64EDchpQ','application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.wordprocessingml.template','execute','iconView','set','importWord','editor','isOn','6778kQSBxG','isOfficialPlugin','_createButton','view','init','123246hZhdkJ','897295kDiiYo','67986wEoLuS','9RIYoWs','locale','done','ImportWordUI','isPremiumPlugin','84ffLEvU','editing','16yShPGs','Import\x20from\x20Word','isBusy'];_0xf46a=function(){return _0x16ceee;};return _0xf46a();}const _0x21a816=_0x2c30;function _0x2c30(_0x30c20c,_0x5ccbab){const _0xf46a06=_0xf46a();return _0x2c30=function(_0x2c30c6,_0x254df4){_0x2c30c6=_0x2c30c6-0xec;let _0x345462=_0xf46a06[_0x2c30c6];return _0x345462;},_0x2c30(_0x30c20c,_0x5ccbab);}(function(_0x201a48,_0x144b82){const _0x2e7755=_0x2c30,_0x27addf=_0x201a48();while(!![]){try{const _0x5466d8=parseInt(_0x2e7755(0x10e))/0x1*(parseInt(_0x2e7755(0xf1))/0x2)+parseInt(_0x2e7755(0x116))/0x3*(parseInt(_0x2e7755(0xfa))/0x4)+-parseInt(_0x2e7755(0xfb))/0x5*(-parseInt(_0x2e7755(0x115))/0x6)+-parseInt(_0x2e7755(0x114))/0x7+parseInt(_0x2e7755(0x106))/0x8*(parseInt(_0x2e7755(0x113))/0x9)+parseInt(_0x2e7755(0xfc))/0xa+parseInt(_0x2e7755(0x102))/0xb*(-parseInt(_0x2e7755(0xef))/0xc);if(_0x5466d8===_0x144b82)break;else _0x27addf['push'](_0x27addf['shift']());}catch(_0x4e8f22){_0x27addf['push'](_0x27addf['shift']());}}}(_0xf46a,0x2076b));import{Plugin as _0x489019}from'ckeditor5/src/core.js';import{IconImportWord as _0x113418}from'ckeditor5/src/icons.js';import{MenuBarMenuListItemFileDialogButtonView as _0x31c61a,SpinnerView as _0x477eaa,FileDialogButtonView as _0x6a7e68}from'ckeditor5/src/ui.js';import{getTranslation as _0x3d7385}from'./utils/common-translations.js';export class ImportWordUI extends _0x489019{static get[_0x21a816(0xf5)](){const _0x39b50d=_0x21a816;return _0x39b50d(0xed);}static get[_0x21a816(0x10f)](){return!0x0;}static get[_0x21a816(0xee)](){return!0x0;}[_0x21a816(0x112)](){const _0x4faa96=_0x21a816,_0x58f48e=this[_0x4faa96(0x10c)];_0x58f48e['ui'][_0x4faa96(0x101)][_0x4faa96(0x100)](_0x4faa96(0x10b),()=>{const _0x135bf0=_0x4faa96,_0x2a9355=this[_0x135bf0(0x110)](_0x6a7e68),_0x58a0e6=_0x58f48e[_0x135bf0(0xff)][_0x135bf0(0xfd)](_0x135bf0(0x10b));return _0x2a9355[_0x135bf0(0x104)](_0x135bf0(0x10d))['to'](_0x58a0e6,_0x135bf0(0xf3)),_0x2a9355[_0x135bf0(0x103)]=!0x0,_0x2a9355;}),_0x58f48e['ui'][_0x4faa96(0x101)][_0x4faa96(0x100)](_0x4faa96(0xf7),()=>this[_0x4faa96(0x110)](_0x31c61a));}[_0x21a816(0x110)](_0x3e0592){const _0x49fa66=_0x21a816,_0x54160b=this[_0x49fa66(0x10c)],_0x85f1b5=_0x54160b[_0x49fa66(0xff)][_0x49fa66(0xfd)](_0x49fa66(0x10b)),_0x2e2290=new _0x3e0592(_0x54160b[_0x49fa66(0x117)]),_0x4828cd=new _0x477eaa();return _0x2e2290[_0x49fa66(0x10a)]({'acceptedType':_0x49fa66(0x107)}),_0x2e2290[_0x49fa66(0x10a)]({'icon':_0x113418}),_0x2e2290[_0x49fa66(0x104)](_0x49fa66(0xfe))['to'](_0x85f1b5),_0x2e2290[_0x49fa66(0x104)](_0x49fa66(0xf9))['to'](_0x85f1b5,_0x49fa66(0xf3),_0x4b666b=>_0x3d7385(_0x54160b[_0x49fa66(0x117)],_0x4b666b?_0x49fa66(0xf6):_0x49fa66(0xf2))),_0x4828cd[_0x49fa66(0x104)](_0x49fa66(0xf4))['to'](_0x85f1b5,_0x49fa66(0xf3)),_0x2e2290[_0x49fa66(0x109)][_0x49fa66(0x104)](_0x49fa66(0xf4))['to'](_0x85f1b5,_0x49fa66(0xf3),_0x221fbc=>!_0x221fbc),_0x2e2290[_0x49fa66(0xf8)][_0x49fa66(0x100)](_0x4828cd),_0x2e2290['on'](_0x49fa66(0xec),(_0x2ab5d5,_0x51f581)=>{const _0x489901=_0x49fa66;_0x54160b[_0x489901(0x108)](_0x489901(0x10b),_0x51f581[0x0],{}),_0x54160b[_0x489901(0xf0)][_0x489901(0x111)][_0x489901(0x105)]();}),_0x2e2290;}}