UNPKG

@ckeditor/ckeditor5-export-word

Version:

Export to Word feature for CKEditor 5.

23 lines • 8.57 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(_0x4125ab,_0x2d9973){const _0x4f92b6=_0x2060,_0x147043=_0x4125ab();while(!![]){try{const _0x291aa0=parseInt(_0x4f92b6(0xf6))/0x1*(-parseInt(_0x4f92b6(0x111))/0x2)+parseInt(_0x4f92b6(0x109))/0x3*(parseInt(_0x4f92b6(0xe7))/0x4)+parseInt(_0x4f92b6(0xfd))/0x5*(parseInt(_0x4f92b6(0x110))/0x6)+parseInt(_0x4f92b6(0x11a))/0x7+parseInt(_0x4f92b6(0xeb))/0x8*(-parseInt(_0x4f92b6(0xe1))/0x9)+-parseInt(_0x4f92b6(0xe8))/0xa*(-parseInt(_0x4f92b6(0x10c))/0xb)+parseInt(_0x4f92b6(0x117))/0xc*(parseInt(_0x4f92b6(0xff))/0xd);if(_0x291aa0===_0x2d9973)break;else _0x147043['push'](_0x147043['shift']());}catch(_0xd9291f){_0x147043['push'](_0x147043['shift']());}}}(_0x17c3,0x7e0d3));export function getConverterOptions(_0x351a66,_0x42a58d={}){const _0x3c3d50=_0x2060,_0x5d99d4=_0x351a66[_0x3c3d50(0x10a)][_0x3c3d50(0xf1)](_0x3c3d50(0xf7)),_0x2d91fe=_0x351a66[_0x3c3d50(0x10a)][_0x3c3d50(0xf1)](_0x3c3d50(0xe6)),_0x266d5e=_0x351a66[_0x3c3d50(0x10a)][_0x3c3d50(0xf1)](_0x3c3d50(0x108)),_0x269a94=_0x42a58d;if(_0x5d99d4&&_0x2d91fe){const _0x59c8af=getComments(_0x351a66[_0x3c3d50(0x10a)][_0x3c3d50(0x106)](_0x3c3d50(0xe6))[_0x3c3d50(0xfe)]({'skipNotAttached':!0x0,'skipEmpty':!0x0}));Object[_0x3c3d50(0xe3)](_0x59c8af)[_0x3c3d50(0x11c)]&&(_0x269a94[_0x3c3d50(0xfa)]=_0x59c8af);}if(_0x5d99d4&&_0x266d5e){const _0x3ef517=_0x351a66[_0x3c3d50(0x10a)][_0x3c3d50(0x106)](_0x3c3d50(0x108)),_0x335d3e=_0x351a66[_0x3c3d50(0x10a)][_0x3c3d50(0x106)](_0x3c3d50(0xf7)),_0xbe2b9d=getSuggestions(_0x3ef517[_0x3c3d50(0xef)]({'toJSON':!0x0}),_0x335d3e[_0x3c3d50(0xe5)]);Object[_0x3c3d50(0xe3)](_0xbe2b9d)[_0x3c3d50(0x11c)]&&(_0x269a94[_0x3c3d50(0x115)]=_0xbe2b9d);}return(_0x269a94[_0x3c3d50(0x115)]||_0x269a94[_0x3c3d50(0xfa)])&&(_0x269a94[_0x3c3d50(0x10d)]=new Intl[(_0x3c3d50(0x113))]()[_0x3c3d50(0xf0)]()[_0x3c3d50(0x10f)]),_0x269a94;}export function getComments(_0x43f140){const _0x3da327=_0x2060,_0xe5887e={};if(!_0x43f140[_0x3da327(0x11c)])return _0xe5887e;for(const _0x268463 of _0x43f140)_0x268463[_0x3da327(0xfa)][_0x3da327(0x11d)](_0x28aeb2=>{const _0x5f4522=_0x3da327;void 0x0===_0xe5887e[_0x268463['id']]&&(_0xe5887e[_0x268463['id']]=[]),_0xe5887e[_0x268463['id']][_0x5f4522(0xea)]({'author':_0x28aeb2[_0x5f4522(0x102)][_0x5f4522(0x119)],'content':_0x28aeb2[_0x5f4522(0xf4)],'created':_0x28aeb2[_0x5f4522(0x114)],'is_resolved':_0x268463[_0x5f4522(0xe4)]});});return _0xe5887e;}export function getSuggestions(_0x18dcfb,_0x536fb7){const _0x1f6b29=_0x2060,_0x20d48b={};if(!_0x18dcfb[_0x1f6b29(0x11c)]||!_0x536fb7[_0x1f6b29(0x11c)])return _0x20d48b;for(const {id:_0x1ab679,createdAt:_0x197316,authorId:_0x2dff88,attributes:_0x243f68}of _0x18dcfb){const _0x2bc112=_0x243f68&&_0x243f68[_0x1f6b29(0x105)],_0x1124e6=_0x2bc112?_0x2bc112[_0x1f6b29(0xf3)]:_0x536fb7[_0x1f6b29(0x106)](_0x2dff88)[_0x1f6b29(0x119)];_0x20d48b[_0x1ab679]={'author':_0x1124e6,'created':_0x197316};}return _0x20d48b;}export function getConverterOptionsV2(_0x6394fc,_0x51a484={}){const _0x4b5210=_0x2060,_0x2d669f=_0x6394fc[_0x4b5210(0x10a)][_0x4b5210(0xf1)](_0x4b5210(0xf7)),_0x53fdaf=_0x6394fc[_0x4b5210(0x10a)][_0x4b5210(0xf1)](_0x4b5210(0xe6)),_0x58165a=_0x6394fc[_0x4b5210(0x10a)][_0x4b5210(0xf1)](_0x4b5210(0x108)),_0x48b776=_0x6394fc[_0x4b5210(0x10a)][_0x4b5210(0xf1)](_0x4b5210(0x116)),_0x519202=_0x6394fc[_0x4b5210(0x10e)][_0x4b5210(0xe9)],_0x40d138=_0x51a484,_0x2d701c={};if(_0x40d138[_0x4b5210(0xfc)]=_0x40d138[_0x4b5210(0xfc)]||{},_0x40d138[_0x4b5210(0xfc)][_0x4b5210(0x104)]=_0x40d138[_0x4b5210(0xfc)][_0x4b5210(0x104)]||_0x519202,_0x2d669f&&_0x53fdaf){const _0x466d34=getCommentsV2(_0x6394fc[_0x4b5210(0x10a)][_0x4b5210(0x106)](_0x4b5210(0xe6))[_0x4b5210(0xfe)]({'skipNotAttached':!0x0,'skipEmpty':!0x0}));_0x466d34[_0x4b5210(0x11c)]&&(_0x2d701c[_0x4b5210(0x107)]=_0x466d34);}if(_0x2d669f&&_0x58165a){const _0x58c39c=_0x6394fc[_0x4b5210(0x10a)][_0x4b5210(0x106)](_0x4b5210(0x108)),_0x2093ce=_0x6394fc[_0x4b5210(0x10a)][_0x4b5210(0x106)](_0x4b5210(0xf7)),_0x527626=getSuggestionsV2(_0x58c39c[_0x4b5210(0xef)]({'toJSON':!0x0}),_0x2093ce[_0x4b5210(0xe5)]);_0x527626[_0x4b5210(0x11c)]&&(_0x2d701c[_0x4b5210(0x115)]=_0x527626);}if(_0x48b776){const _0x26883a=_0x6394fc[_0x4b5210(0x10a)][_0x4b5210(0x106)](_0x4b5210(0x11b)),_0x15afb6=_0x26883a[_0x4b5210(0x10b)],{prefix:_0xe08cc4,suffix:_0x51f6e9}=_0x6394fc[_0x4b5210(0xf9)][_0x4b5210(0x106)](_0x4b5210(0x101));if(_0x40d138[_0x4b5210(0x112)]={'prefix':_0xe08cc4,'suffix':_0x51f6e9},_0x4b5210(0xe2)!==_0x15afb6){_0x40d138[_0x4b5210(0x112)][_0x4b5210(0xf2)]={};const _0x2b0315=_0x4b5210(0x103),_0x130bf4=_0x4b5210(0xf8)===_0x15afb6?_0x26883a[_0x4b5210(0xf5)]():_0x26883a[_0x4b5210(0xed)](_0x15afb6,!0x0);for(const _0x24f49d of Object[_0x4b5210(0x118)](_0x130bf4)){const [_0x31e82c,_0x1e5970]=_0x24f49d;_0x4b5210(0xec)===_0x26883a[_0x4b5210(0x100)](_0x31e82c)?_0x40d138[_0x4b5210(0x112)][_0x4b5210(0xf2)][_0x31e82c]=null!==_0x1e5970?_0x1e5970:_0x2b0315:_0x40d138[_0x4b5210(0x112)][_0x4b5210(0xf2)][_0x31e82c]=null!==_0x1e5970?_0x1e5970:_0x26883a[_0x4b5210(0xee)](_0x31e82c)||_0x31e82c;}}}return(_0x2d701c[_0x4b5210(0x107)]||_0x2d701c[_0x4b5210(0x115)])&&(_0x40d138[_0x4b5210(0x10d)]=new Intl[(_0x4b5210(0x113))]()[_0x4b5210(0xf0)]()[_0x4b5210(0x10f)],_0x40d138[_0x4b5210(0xfb)]=_0x2d701c),_0x40d138;}function _0x2060(_0x34fddd,_0xe1981e){const _0x17c3d9=_0x17c3();return _0x2060=function(_0x206025,_0x3db969){_0x206025=_0x206025-0xe1;let _0x1271a9=_0x17c3d9[_0x206025];return _0x1271a9;},_0x2060(_0x34fddd,_0xe1981e);}export function getCommentsV2(_0x7c75c9){const _0x1f24d7=_0x2060,_0x2dda69=[];if(!_0x7c75c9[_0x1f24d7(0x11c)])return _0x2dda69;for(const _0x1f9b47 of _0x7c75c9){const _0x274383=_0x1f9b47[_0x1f24d7(0xfa)][_0x1f24d7(0x11d)](_0x2b2549=>({'author':_0x2b2549[_0x1f24d7(0x102)][_0x1f24d7(0x119)],'content':_0x2b2549[_0x1f24d7(0xf4)],'created_at':_0x2b2549[_0x1f24d7(0x114)]}));_0x2dda69[_0x1f24d7(0xea)]({'thread_id':_0x1f9b47['id'],'is_resolved':_0x1f9b47[_0x1f24d7(0xe4)],'comments':_0x274383});}return _0x2dda69;}function _0x17c3(){const _0x5f0219=['createdAt','suggestions','MergeFields','266280tveMMf','entries','name','1095087PqUDuk','MergeFieldsEditing','length','map','9pqsILK','$labels','keys','isResolved','users','CommentsRepository','3164932kOFbWC','1510JlYGhL','contentLanguage','push','7371656hCxRrM','image','getDataSetValues','getLabel','getSuggestions','resolvedOptions','has','data','authorName','content','getDefaultValues','683105EMAuVc','Users','$defaultValues','config','comments','collaboration_features','document','5045IoIHGb','getCommentThreads','598aSIsHs','getMergeFieldType','mergeFields','author','data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mP88B8AAuUB8e2ujYwAAAAASUVORK5CYII=','language','@external','get','comment_threads','TrackChanges','3WRKsEe','plugins','previewMode','154HmtwOg','timezone','locale','timeZone','894fEHFOb','2zfTEjw','merge_fields','DateTimeFormat'];_0x17c3=function(){return _0x5f0219;};return _0x17c3();}export function getSuggestionsV2(_0x571954,_0x5de451){const _0x5480c3=_0x2060;return _0x571954[_0x5480c3(0x11c)]&&_0x5de451[_0x5480c3(0x11c)]?_0x571954[_0x5480c3(0x11d)](({id:_0x1d9bf2,createdAt:_0x36e687,authorId:_0xd44ad7,attributes:_0x1d157f})=>{const _0x39e0c7=_0x5480c3,_0x287f4d=_0x1d157f&&_0x1d157f[_0x39e0c7(0x105)];return{'id':_0x1d9bf2,'author':_0x287f4d?_0x287f4d[_0x39e0c7(0xf3)]:_0x5de451[_0x39e0c7(0x106)](_0xd44ad7)[_0x39e0c7(0x119)],'created_at':_0x36e687};}):[];}