@ckeditor/ckeditor5-uploadcare 0.0.0-nightly-20251108.0 → 0.0.0-nightly-20251110.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/dist/index.js CHANGED
@@ -20,6 +20,6 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Plugin as _0x47677f,Command as _0x557747}from'@ckeditor/ckeditor5-core/dist/index.js';import{IconOneDrive as _0x57ad23,IconGooglePhotos as _0x175904,IconGoogleDrive as _0x43c613,IconFacebook as _0x11223c,IconDropbox as _0x3ff723,IconUploadcareLink as _0x4a1f55,IconUploadcareImageUpload as _0x1d24ab,IconError as _0x1c126d,IconUploadcareImageEdit as _0x2bff6e}from'@ckeditor/ckeditor5-icons/dist/index.js';import{ButtonView as _0x4bd808,MenuBarMenuListItemButtonView as _0x5a704f,View as _0xf79a67,FocusCycler as _0x43173,Dialog as _0x2a7e1a,DialogViewPosition as _0x5006c0,SpinnerView as _0x15f1f0,IconView as _0x1c43c7,Notification as _0x46fe69}from'@ckeditor/ckeditor5-ui/dist/index.js';import{FocusTracker as _0x14ef31,DomEmitterMixin as _0x212838,global as _0x1d624a,getAncestors as _0x29fa4c,ObservableMixin as _0xc01041,uid as _0x44c743,createElement as _0x51a047}from'@ckeditor/ckeditor5-utils/dist/index.js';import{FileRepository as _0x2d7b6f}from'@ckeditor/ckeditor5-upload/dist/index.js';import{uploadFile as _0xe505e3,info as _0x58b02e}from'@uploadcare/upload-client';import*as _0x486e4a from'@uploadcare/file-uploader';var i=function(_0x4efacd){return _0x4efacd['Local']='local',_0x4efacd['URL']='url',_0x4efacd['Dropbox']='dropbox',_0x4efacd['GDrive']='gdrive',_0x4efacd['Facebook']='facebook',_0x4efacd['GPhotos']='gphotos',_0x4efacd['OneDrive']='onedrive',_0x4efacd;}({});function _(_0x24c260,_0x19c457,_0x362e3f){const t=_0x24c260['t'],_0x5c690e=_0x24c260['t'];switch(_0x19c457){case i['Local']:return{'text':_0x5c690e('Insert'===_0x362e3f?'Upload\x20from\x20computer':'Replace\x20from\x20computer'),'shortText':_0x5c690e('From\x20computer')};case i['URL']:return{'text':'Insert'===_0x362e3f?_0x5c690e('Insert\x20via\x20URL'):t('Replace\x20via\x20URL'),'shortText':_0x5c690e('Via\x20URL')};case i['Dropbox']:return{'text':t('Insert'===_0x362e3f?'Insert\x20with\x20Dropbox':'Replace\x20with\x20Dropbox'),'shortText':t('With\x20Dropbox')};case i['Facebook']:return{'text':t('Insert'===_0x362e3f?'Insert\x20with\x20Facebook':'Replace\x20with\x20Facebook'),'shortText':t('With\x20Facebook')};case i['GDrive']:return{'text':t('Insert'===_0x362e3f?'Insert\x20with\x20Google\x20Drive':'Replace\x20with\x20Google\x20Drive'),'shortText':t('With\x20Google\x20Drive')};case i['GPhotos']:return{'text':t('Insert'===_0x362e3f?'Insert\x20with\x20Google\x20Photos':'Replace\x20with\x20Google\x20Photos'),'shortText':t('With\x20Google\x20Photos')};case i['OneDrive']:return{'text':t('Insert'===_0x362e3f?'Insert\x20with\x20OneDrive':'Replace\x20with\x20OneDrive'),'shortText':t('With\x20OneDrive')};default:return _0x19c457;}}class e extends _0x47677f{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'UploadcareUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3fdc33=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1e6685;for(const _0x5c9717 in _0x3fdc33){const _0xf15101=_0x5c9717,_0x1a71ea=_0x3fdc33[_0xf15101];if('uploadcareLicenseKeyValid'==_0x1a71ea||'uploadcareLicenseKeyInvalid'==_0x1a71ea||'uploadcareLicenseKeyExpired'==_0x1a71ea||'uploadcareLicenseKeyDomainLimit'==_0x1a71ea||'uploadcareLicenseKeyNotAllowed'==_0x1a71ea||'uploadcareLicenseKeyEvaluationLimit'==_0x1a71ea||'uploadcareLicenseKeyTrialLimit'==_0x1a71ea||'uploadcareLicenseKeyUsageLimit'==_0x1a71ea){delete _0x3fdc33[_0xf15101],_0x1e6685=_0x1a71ea,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'uploadcareLicenseKeyInvalid'==_0x1e6685&&_0x3fdc33['_showLicenseError']('invalid'),'uploadcareLicenseKeyExpired'==_0x1e6685&&_0x3fdc33['_showLicenseError']('expired'),'uploadcareLicenseKeyDomainLimit'==_0x1e6685&&_0x3fdc33['_showLicenseError']('domainLimit'),'uploadcareLicenseKeyNotAllowed'==_0x1e6685&&_0x3fdc33['_showLicenseError']('featureNotAllowed','Uploadcare'),'uploadcareLicenseKeyEvaluationLimit'==_0x1e6685&&_0x3fdc33['_showLicenseError']('evaluationLimit'),'uploadcareLicenseKeyTrialLimit'==_0x1e6685&&_0x3fdc33['_showLicenseError']('trialLimit'),'uploadcareLicenseKeyUsageLimit'==_0x1e6685&&_0x3fdc33['_showLicenseError']('usageLimit');},0x3e8);}['afterInit'](){const {editor:_0x5857eb}=this,_0x5160a6=_0x5857eb['commands']['get']('uploadcare');if(!_0x5160a6)return;const _0x405655=this['_normalizeConfigSourceList'](_0x5857eb['config']['get']('uploadcare.uploader.sourceList'))['reduce']((_0xdef213,_0x16b0fc)=>{const _0x26816a=this['_getIntegrationKey'](_0x16b0fc['type']);return _0xdef213[_0x26816a]||(_0xdef213[_0x26816a]=[]),_0xdef213[_0x26816a]['push'](_0x16b0fc),_0xdef213;},{});_0x5857eb['plugins']['has']('ImageInsertUI')&&_0x5857eb['commands']['get']('uploadcare')&&Object['entries'](_0x405655)['forEach'](([_0x216ca1,_0x512f3e])=>{_0x5857eb['plugins']['get']('ImageInsertUI')['registerIntegration']({'name':_0x216ca1,'observable':()=>_0x5160a6,'buttonViewCreator':()=>this['_createToolbarButton'](_0x512f3e),'formViewCreator':()=>this['_createDropdownButtons'](_0x512f3e),'menuBarButtonViewCreator':()=>this['_createMenuBarButtons'](_0x512f3e),'override':'assetManager'!==_0x216ca1});});}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_normalizeConfigSourceList'](_0x4217c1){const {locale:_0x2119dc}=this['editor'];return _0x4217c1['map'](_0xbf695d=>{const _0x37a211=_(_0x2119dc,_0xbf695d,'Insert');switch(_0xbf695d){case i['Local']:return{'icon':_0x1d24ab,'type':i['Local'],..._0x37a211};case i['URL']:return{'icon':_0x4a1f55,'type':i['URL'],..._0x37a211};case i['Dropbox']:return{'icon':_0x3ff723,'type':i['Dropbox'],..._0x37a211};case i['Facebook']:return{'icon':_0x11223c,'type':i['Facebook'],..._0x37a211};case i['GDrive']:return{'icon':_0x43c613,'type':i['GDrive'],..._0x37a211};case i['GPhotos']:return{'icon':_0x175904,'type':i['GPhotos'],..._0x37a211};case i['OneDrive']:return{'icon':_0x57ad23,'type':i['OneDrive'],..._0x37a211};}});}['_getIntegrationKey'](_0x9f5bfd){switch(_0x9f5bfd){case i['Local']:return'upload';case i['URL']:return'url';default:return'assetManager';}}['_createButton'](_0x3f2a03,_0x432538){const _0x278425=this['editor'],_0xa39b11=new _0x3f2a03(_0x278425['locale']),_0x3c2b4e=_0x278425['commands']['get']('uploadcare');return _0xa39b11['bind']('isEnabled')['to'](_0x3c2b4e),_0xa39b11['on']('execute',()=>{_0x3c2b4e['execute'](_0x432538);}),_0xa39b11;}['_createToolbarButton'](_0x510cb3){const {locale:_0x8db50b}=this['editor'],_0x3b36ba=this['editor']['plugins']['get']('ImageInsertUI'),_0xdb4db1=_0x510cb3[0x0],_0x568c52=this['_createButton'](_0x4bd808,_0xdb4db1['type']);return _0x568c52['icon']=_0xdb4db1['icon'],_0x568c52['bind']('label')['to'](_0x3b36ba,'isImageSelected',_0x12e78d=>_(_0x8db50b,_0xdb4db1['type'],_0x12e78d?'Replace':'Insert')['text']),_0x568c52['tooltip']=!0x0,_0x568c52;}['_createDropdownButtons'](_0x3127b0){const {locale:_0x2ad465}=this['editor'],_0x43da1f=this['editor']['plugins']['get']('ImageInsertUI');return _0x3127b0['map'](_0x569afb=>{const _0x5d2d61=this['_createButton'](_0x4bd808,_0x569afb['type']);return _0x5d2d61['withText']=!0x0,_0x5d2d61['icon']=_0x569afb['icon'],_0x5d2d61['bind']('label')['to'](_0x43da1f,'isImageSelected',_0x13b8cc=>_(_0x2ad465,_0x569afb['type'],_0x13b8cc?'Replace':'Insert')['text']),_0x5d2d61;});}['_createMenuBarButtons'](_0x397ca7){return _0x397ca7['map'](_0x47df3b=>{const _0x27588a=this['_createButton'](_0x5a704f,_0x47df3b['type']);return _0x27588a['icon']=_0x47df3b['icon'],_0x27588a['label']=_0x47df3b['shortText'],_0x27588a;});}}class F extends _0xf79a67{['focusTracker'];['focusCycler'];constructor(_0x81f8c0){super(_0x81f8c0),this['focusTracker']=new _0x14ef31(),this['focusCycler']=new _0x43173({'focusables':this['createCollection'](),'focusTracker':this['focusTracker']});}['getFocusableElement'](){return{'tag':'div','attributes':{'aria-hidden':'true','tabindex':'0'},'on':{'focus':this['bindTemplate']['to'](()=>{this['focusCycler']['fire']('forwardCycle');})}};}}class x extends F{constructor(_0x224257,_0x122fa3){super(_0x224257),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all-excluded','ck-uploadcare-form'],'tabindex':'-1'},'children':[{'tag':'uc-file-uploader-inline','attributes':{'class':['uc-light','ck-uploadcare-theme'],'ctx-name':'uploader-'+_0x122fa3}},this['getFocusableElement']()]});}['focus'](){this['element']['focus']();}}function C(_0x5cbd95,_0x49a58b){const _0x7a6514=[0x140,0x1e0,0x300,0x400,0x4b0,0x640,0x780,0x960]['filter'](_0x17c364=>_0x17c364<=_0x49a58b)['map'](_0x343c4b=>_0x5cbd95['replace'](/\/$/,'')+'/-/resize/'+_0x343c4b+'x/\x20'+_0x343c4b+'w');return{'imageFallbackUrl':_0x5cbd95,'imageSources':[{'srcset':_0x7a6514['join'](',\x20'),'sizes':'(max-width:\x20'+_0x49a58b+'px)\x20100vw,\x20'+_0x49a58b+'px','type':'image/webp'}]};}function S(_0x82198,_0x35211c,_0x366de3){const _0x4d265c=_0x82198['match'](/\/crop\/(\d+)x(\d+)\//);return{'width':_0x4d265c?parseInt(_0x4d265c[0x1],0xa):_0x35211c,'height':_0x4d265c?parseInt(_0x4d265c[0x2],0xa):_0x366de3};}function p(_0x1366a5,_0x34fbed){const _0x19d348=new(_0x212838())(),_0x43e786=_0x1366a5['plugins']['get']('ImageUtils'),_0x1cea71=_0x1366a5['editing']['mapper']['toViewElement'](_0x34fbed),_0x290de5=_0x43e786['findViewImgElement'](_0x1cea71),_0x490e6e=_0x1366a5['editing']['view']['domConverter']['viewToDom'](_0x290de5),_0xb3804b=_0x34fbed['getAttribute']('width'),_0x2d1523=_0x34fbed['getAttribute']('height'),_0x14503b='image-processing';_0x1366a5['editing']['view']['change'](_0x5e3c39=>{_0x5e3c39['addClass'](_0x14503b,_0x1cea71),_0x5e3c39['setStyle']('aspect-ratio',_0xb3804b+'/'+_0x2d1523,_0x290de5);}),_0x19d348['listenTo'](_0x490e6e,'load',()=>{_0x19d348['stopListening'](_0x490e6e,'load'),_0x1366a5['editing']['view']['change'](_0x53922c=>{_0x53922c['removeClass'](_0x14503b,_0x1cea71),_0x53922c['removeStyle']('aspect-ratio',_0x290de5);});});}function z(_0x1efa5c){if(Array['isArray'](_0x1efa5c)){const _0x5558ca=_0x1efa5c['map'](z);return _0x48263d=>_0x5558ca['some'](_0x5314df=>_0x5314df(_0x48263d));}if('origin'==_0x1efa5c){const _0x56d837=_0x1d624a['window']['location']['origin'];return _0x5a979b=>new URL(_0x5a979b,_0x1d624a['document']['baseURI'])['origin']==_0x56d837;}return'function'==typeof _0x1efa5c?_0x1efa5c:_0x1efa5c instanceof RegExp?_0x5e4c55=>!(!_0x5e4c55['match'](_0x1efa5c)&&!_0x5e4c55['replace'](/^https?:\/\//,'')['match'](_0x1efa5c)):()=>!0x1;}function A(_0x5768ab,_0x491b2){return _0x29fa4c(_0x5768ab['target'])['includes'](_0x491b2);}class n extends/* #__PURE__ -- @preserve */
24
- _0xc01041(){['_editor'];['_dialog'];['_editing'];['_api'];['_type']=null;['_formView']=null;constructor(_0x351d23,_0x264df3,_0x18e35c){super(),this['_editor']=_0x351d23,this['_editing']=_0x264df3,this['_dialog']=_0x351d23['plugins']['get'](_0x2a7e1a),this['_api']=_0x264df3['ctxElement']['getAPI'](),this['_type']=_0x18e35c,this['_editing']['configElement']['setAttribute']('source-list',this['_type']),this['_initDialog'](),this['_initListeners'](),this['_api']['initFlow']();}['destroy'](){this['_formView']&&(this['_formView']['destroy'](),this['_formView']=null),this['_api']&&this['_api']['doneFlow'](),this['stopListening'](),this['stopDelegating']();}['_initDialog'](){const {locale:_0x2ae471,model:_0x4349cc}=this['_editor'],_0xc40d0e=_0x4349cc['document']['selection']['getSelectedElement'](),_0x57a72c=_0xc40d0e&&(_0xc40d0e['is']('element','imageBlock')||_0xc40d0e['is']('element','imageInline'));this['_formView']=new x(_0x2ae471,this['_editing']['ucContextId']),this['_dialog']['show']({'id':'uploadCare','icon':_0x1d24ab,'title':_(_0x2ae471,this['_type'],_0x57a72c?'Replace':'Insert')['text'],'content':this['_formView'],'position':_0x5006c0['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{this['_formView']['focus']();},'onHide':()=>{this['_api']['removeAllFiles'](),this['_editor']['editing']['view']['focus'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x59ca93=>!A(_0x59ca93,this['_formView']['element'])}});}['_initListeners'](){this['_editing']['ctxElement']['addEventListener']('done-click',()=>{const {allEntries:_0x4392e9}=this['_api']['getOutputCollectionState']();this['_editor']['model']['change'](_0x47648e=>{const _0x30d49f=_0x4392e9['length'];for(const _0x4a7308 of _0x4392e9){const _0x554242=_0x4a7308===_0x4392e9[_0x30d49f-0x1],{cdnUrl:_0x19b604,fileInfo:_0x1abb6d}=_0x4a7308;if(!_0x19b604||!_0x1abb6d)continue;const {width:_0x130a42,height:_0x1db58}=_0x1abb6d['imageInfo'],_0xb12832=S(_0x19b604,_0x130a42,_0x1db58),_0xcc596c=C(_0x19b604,_0xb12832['width']),_0x236ee6={'id':_0x1abb6d['uuid'],'type':'image','attributes':{'imageDimension':_0xb12832,..._0xcc596c}};this['_insertAsset'](_0x236ee6,_0x554242,_0x47648e);}}),this['_dialog']['hide']();}),this['_editing']['ctxElement']['addEventListener']('change',_0x30132c=>{'idle'===_0x30132c['detail']['status']&&!_0x30132c['detail']['allEntries']['length']&&this['_dialog']['isOpen']&&(this['_type']===i['Local']?this['_api']['setCurrentActivity'](i['Local']):this['_api']['initFlow']());});}['_insertAsset'](_0xe097ac,_0x4c0e81,_0x46c292){const _0x55c50e=this['_editor']['model']['document']['selection'],_0x1dee20=_0x55c50e['getSelectedElement'](),_0x78de8e=!(!_0x1dee20||!_0x1dee20['is']('element','imageInline'));_0x46c292['removeSelectionAttribute']('linkHref'),this['_insertImage'](_0xe097ac,_0x78de8e),_0x4c0e81||_0x46c292['setSelection'](_0x55c50e['getLastPosition']());}['_insertImage'](_0x29be69,_0x5d35a2){const _0x14b523=this['_editor'],{imageDimension:_0x431608,imageFallbackUrl:_0x454748,imageSources:_0x4cbf2b}=_0x29be69['attributes'];_0x14b523['execute']('insertImage',{'imageType':_0x5d35a2?'imageInline':null,'source':{'uploadcareImageId':_0x29be69['id'],'src':_0x454748,'sources':_0x4cbf2b,..._0x431608}});}}class w extends _0x557747{['_editing'];['_controller']=null;static get['requires'](){return[_0x2a7e1a,o];}constructor(_0x54f996){super(_0x54f996),this['_editing']=_0x54f996['plugins']['get'](o);}['refresh'](){this['isEnabled']=this['_checkEnabled']();}['execute'](_0x10c580){this['_controller']&&(this['_controller']['destroy'](),this['_controller']=null),this['_controller']=new n(this['editor'],this['_editing'],_0x10c580);}['_checkEnabled'](){return this['editor']['commands']['get']('insertImage')['isEnabled'];}}class j{static['upload']({file:_0xfc7d94,..._0x3ae5c1}){return _0xe505e3(_0xfc7d94,_0x3ae5c1);}static['getInfo'](_0x49ac86,_0xdc06d5){return _0x58b02e(_0x49ac86,_0xdc06d5);}}class f extends _0x47677f{static get['requires'](){return['ImageUploadEditing','ImageUploadProgress',_0x2d7b6f,o];}static get['pluginName'](){return'UploadcareUploadAdapter';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}async['afterInit'](){const _0x16d5bb=this['editor'];if(!!!_0x16d5bb['config']['get']('uploadcare'))return;_0x16d5bb['plugins']['get'](_0x2d7b6f)['createUploadAdapter']=_0xde5137=>new k(_0xde5137,_0x16d5bb),_0x16d5bb['plugins']['get']('ImageUploadEditing')['on']('uploadComplete',(_0x4c9cc2,{imageElement:_0x103c5c,data:_0x497949})=>{_0x16d5bb['model']['change'](_0x1a5d6b=>{_0x1a5d6b['setAttribute']('uploadcareImageId',_0x497949['uploadcareImageId'],_0x103c5c);});});}}class k{['loader'];['editor'];['controller'];constructor(_0x2f6a68,_0x58e187){this['loader']=_0x2f6a68,this['editor']=_0x58e187,this['controller']=new AbortController();}async['upload'](){const t=this['editor']['t'],_0x2440fb=await this['loader']['file'];return j['upload']({'file':_0x2440fb,'publicKey':this['editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['editor']['config']['get']('uploadcare.uploader.baseUrl'),'baseCDN':this['editor']['config']['get']('uploadcare.uploader.cdnCname'),'signal':this['controller']['signal'],'onProgress':_0xe1d277=>{_0xe1d277&&_0xe1d277['isComputable']&&(this['loader']['uploadTotal']=0x1,this['loader']['uploaded']=_0xe1d277['value']);}})['then'](async _0x2cc1da=>{const {imageFallbackUrl:_0x1a225c,imageSources:_0x5763e7}=C(_0x2cc1da['cdnUrl'],_0x2cc1da['imageInfo']['width']);return{'uploadcareImageId':_0x2cc1da['uuid'],'default':_0x1a225c,'sources':_0x5763e7};})['catch'](()=>{const _0x28e923=t('Cannot\x20upload\x20file:')+('\x20'+_0x2440fb['name']+'.');return Promise['reject'](_0x28e923);});}['abort'](){this['controller']['abort']();}}class o extends _0x47677f{['_configElement']=null;['_ctxElement']=null;static get['pluginName'](){return'UploadcareEditing';}static get['requires'](){return['PictureEditing',f,_0x2a7e1a];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['ucContextId'];get['configElement'](){return this['_configElement'];}get['ctxElement'](){return this['_ctxElement'];}constructor(_0x5526ee){super(_0x5526ee),this['ucContextId']=_0x44c743();}['init'](){const _0x1e8dab=this['editor'];_0x1e8dab['commands']['add']('uploadcare',new w(_0x1e8dab));}['afterInit'](){this['_initSchema'](),this['_initConversion'](),this['_initConfig'](),this['_initCtx'](),this['_initImageProcessingIndicator'](),this['listenTo'](this['editor'],'destroy',()=>{this['_configElement']&&(this['_configElement']['remove'](),this['_configElement']=null),this['_ctxElement']&&(this['_ctxElement']['remove'](),this['_ctxElement']=null);const _0x3c526f=_0x1d624a['document']['querySelector']('input[uploadcare-file-input]');_0x3c526f&&_0x3c526f['remove']();}),async function(_0x13be50){const _0x464613=_0x355351([0x68,0x67,0x50,0x36,0x38,0x70,0x71,0x63,0x37,0x4f,0x42,0x4a,0x78,0x39,0x75,0x33,0x7a,0x72,0x48,0x61,0x74,0x59,0x55,0x58,0x66,0x30,0x34,0x54,0x64,0x56,0x6b,0x4d,0x46,0x6d,0x77,0x43,0x73,0x35,0x53,0x44,0x41,0x76,0x6a,0x32,0x31,0x69,0x57,0x51,0x47,0x65,0x5a,0x4b,0x4c,0x79,0x52,0x6c,0x45,0x4e,0x6e,0x6f,0x49,0x62]),_0x5d5453=0x535f8c3a,_0x2b7085=0x5358f4ba^_0x5d5453,_0x282d41=window[_0x355351([0x44,0x61,0x74,0x65])][_0x355351([0x6e,0x6f,0x77])](),_0x2d8535=_0x13be50[_0x355351([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x57d4c6=new window[(_0x355351([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2ffc5c=>{_0x2d8535[_0x355351([0x6f,0x6e,0x63,0x65])](_0x355351([0x72,0x65,0x61,0x64,0x79]),_0x2ffc5c);}),_0x11ea98={[_0x355351([0x6b,0x74,0x79])]:_0x355351([0x45,0x43]),[_0x355351([0x75,0x73,0x65])]:_0x355351([0x73,0x69,0x67]),[_0x355351([0x63,0x72,0x76])]:_0x355351([0x50,0x2d,0x32,0x35,0x36]),[_0x355351([0x78])]:_0x355351([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x355351([0x79])]:_0x355351([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x355351([0x61,0x6c,0x67])]:_0x355351([0x45,0x53,0x32,0x35,0x36])},_0x405fa9=_0x2d8535[_0x355351([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x355351([0x67,0x65,0x74])](_0x355351([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x2067c3(){let _0x3d8ff2,_0x1f51de=null,_0x15765a=null;try{if(_0x405fa9==_0x355351([0x47,0x50,0x4c]))return _0x355351([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3d8ff2=_0x4c922e(),!_0x3d8ff2)return _0x355351([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3d8ff2[_0x355351([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x15765a=_0x287ae3(_0x3d8ff2[_0x355351([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3d8ff2[_0x355351([0x6a,0x74,0x69])])),await _0x2d67e4()?_0x3324d2()?_0x53b3c2()?_0x355351([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x27e20c()?(_0x3d8ff2[_0x355351([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x355351([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1f51de=_0x1f0e8b(_0x355351([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x3d8ff2[_0x355351([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x355351([0x74,0x72,0x69,0x61,0x6c])&&(_0x1f51de=_0x1f0e8b(_0x355351([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2d9c10()):_0x355351([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x355351([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x355351([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x355351([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x53b3c2(){const _0x2ac231=[_0x355351([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x355351([0x74,0x72,0x69,0x61,0x6c])][_0x355351([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3d8ff2[_0x355351([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x282d41/0x3e8:0xe10*_0x2b7085;return _0x3d8ff2[_0x355351([0x65,0x78,0x70])]<_0x2ac231;}function _0x3324d2(){const _0x5cb4fb=_0x3d8ff2[_0x355351([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x5cb4fb&&(!!_0x5cb4fb[_0x355351([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x355351([0x2a]))||!!_0x5cb4fb[_0x355351([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x355351([0x55,0x50,0x4c,0x43])));}function _0x27e20c(){const _0x260bda=_0x3d8ff2[_0x355351([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x260bda||0x0==_0x260bda[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2a7d34}=new URL(window[_0x355351([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x260bda[_0x355351([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2a7d34))return!0x0;const _0x392b5f=_0x2a7d34[_0x355351([0x73,0x70,0x6c,0x69,0x74])](_0x355351([0x2e]));return _0x260bda[_0x355351([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3b016d=>_0x3b016d[_0x355351([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x355351([0x2a])))[_0x355351([0x6d,0x61,0x70])](_0x27a783=>_0x27a783[_0x355351([0x73,0x70,0x6c,0x69,0x74])](_0x355351([0x2e])))[_0x355351([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xd92d19=>_0xd92d19[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x392b5f[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x355351([0x6d,0x61,0x70])](_0x5d8b90=>Array(_0x392b5f[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x5d8b90[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x355351([0x66,0x69,0x6c,0x6c])](_0x5d8b90[0x0]===_0x355351([0x2a])?_0x355351([0x2a]):'')[_0x355351([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x5d8b90))[_0x355351([0x73,0x6f,0x6d,0x65])](_0x3e6858=>_0x392b5f[_0x355351([0x65,0x76,0x65,0x72,0x79])]((_0x2a7bc3,_0x40a504)=>_0x3e6858[_0x40a504]===_0x2a7bc3||_0x3e6858[_0x40a504]===_0x355351([0x2a])));}function _0x2d9c10(){return _0x1f51de&&_0x15765a?new window[(_0x355351([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3bccb6,_0x813d1f)=>{_0x1f51de[_0x355351([0x74,0x68,0x65,0x6e])](_0x3bccb6,_0x813d1f),_0x15765a[_0x355351([0x74,0x68,0x65,0x6e])](_0x10a8e5=>{_0x10a8e5!=_0x355351([0x56,0x61,0x6c,0x69,0x64])&&_0x3bccb6(_0x10a8e5);},_0x813d1f);}):_0x1f51de||_0x15765a||_0x355351([0x56,0x61,0x6c,0x69,0x64]);}}function _0x287ae3(_0x102e80,_0x51f00a){return new window[(_0x355351([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x938e32=>{if(_0x2f3deb())return _0x938e32(_0x355351([0x56,0x61,0x6c,0x69,0x64]));_0x1bdf15(),_0x2d8535[_0x355351([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x355351([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x24e0af=!0x1;const _0x3f9d34=_0x44c743();function _0x38a666(_0x475c92){return!!_0x475c92&&(typeof _0x475c92===_0x355351([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x475c92===_0x355351([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x475c92[_0x355351([0x74,0x68,0x65,0x6e])]===_0x355351([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x475c92[_0x355351([0x63,0x61,0x74,0x63,0x68])]===_0x355351([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0xcfdf6f(_0x1f642e){_0x608c6d(_0x1f642e)[_0x355351([0x74,0x68,0x65,0x6e])](_0x3828de=>{if(!_0x3828de||_0x3828de[_0x355351([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x355351([0x6f,0x6b]))return _0x355351([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x105cb7(_0x3b4bef(_0x3f9d34+_0x51f00a))!=_0x3828de[_0x355351([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x355351([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x355351([0x56,0x61,0x6c,0x69,0x64]);})[_0x355351([0x74,0x68,0x65,0x6e])](_0x5dd4b7=>(_0x56e596(),_0x5dd4b7),()=>{const _0x51e2a9=_0xc5af77();return null==_0x51e2a9?(_0x56e596(),_0x355351([0x56,0x61,0x6c,0x69,0x64])):_0x355351(_0x282d41-_0x51e2a9>(0x7753083a^_0x5d5453)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x355351([0x74,0x68,0x65,0x6e])](_0x938e32)[_0x355351([0x63,0x61,0x74,0x63,0x68])](()=>{_0x938e32(_0x355351([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x575974=0x536962ba^_0x5d5453;function _0x56e596(){const _0x43e34c=_0x355351([0x6c,0x6c,0x63,0x74,0x2d])+_0x105cb7(_0x3b4bef(_0x102e80)),_0x4c1df9=_0x5e21ad(_0x105cb7(window[_0x355351([0x4d,0x61,0x74,0x68])][_0x355351([0x63,0x65,0x69,0x6c])](_0x282d41/_0x575974)));window[_0x355351([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x355351([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x43e34c,_0x4c1df9);}function _0xc5af77(){const _0x12f117=_0x355351([0x6c,0x6c,0x63,0x74,0x2d])+_0x105cb7(_0x3b4bef(_0x102e80)),_0x2b4d34=window[_0x355351([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x355351([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x12f117);return _0x2b4d34?window[_0x355351([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5e21ad(_0x2b4d34),0x10)*_0x575974:null;}function _0x608c6d(_0x1f08bd){return new window[(_0x355351([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x18964c,_0x2dec04)=>{_0x1f08bd[_0x355351([0x74,0x68,0x65,0x6e])](_0x18964c,_0x2dec04),window[_0x355351([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2dec04,0x535e58fa^_0x5d5453);});}}_0x2d8535[_0x355351([0x6f,0x6e])](_0x355351([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x374630,_0x2596f4)=>{if(_0x2596f4[0x0]!=_0x102e80)return _0x938e32(_0x355351([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x2596f4[0x1]={..._0x2596f4[0x1],[_0x355351([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3f9d34};},{[_0x355351([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x355351([0x68,0x69,0x67,0x68])}),_0x2d8535[_0x355351([0x6f,0x6e])](_0x355351([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x5d9394=>{_0x38a666(_0x5d9394[_0x355351([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x24e0af=!0x0,_0xcfdf6f(_0x5d9394[_0x355351([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x355351([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x355351([0x6c,0x6f,0x77])}),_0x57d4c6[_0x355351([0x74,0x68,0x65,0x6e])](()=>{_0x24e0af||_0x938e32(_0x355351([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x2f3deb(){return _0x2d8535[_0x355351([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x355351([0x76,0x69,0x65,0x77])][_0x355351([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x355351([0x61,0x75,0x74,0x6f]);}function _0x1bdf15(){_0x2d8535[_0x355351([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x355351([0x76,0x69,0x65,0x77])][_0x355351([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x355351([0x61,0x75,0x74,0x6f]);}}function _0x1f0e8b(_0x2b2fdf){const _0x2e2892=[new window[(_0x355351([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3fd283=>setTimeout(_0x3fd283,0x5356b2f6^_0x5d5453)),_0x57d4c6[_0x355351([0x74,0x68,0x65,0x6e])](()=>new window[(_0x355351([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1dcb01=>{let _0x580e39=0x0;_0x2d8535[_0x355351([0x6d,0x6f,0x64,0x65,0x6c])][_0x355351([0x6f,0x6e])](_0x355351([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x36e9ab,_0x2ed36b)=>{_0x2ed36b[0x0][_0x355351([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x580e39++,_0x580e39==(0x535f8dc2^_0x5d5453)&&(_0x1dcb01(),_0x36e9ab[_0x355351([0x6f,0x66,0x66])]());});}))];return window[_0x355351([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x355351([0x72,0x61,0x63,0x65])](_0x2e2892)[_0x355351([0x74,0x68,0x65,0x6e])](()=>_0x2b2fdf);}async function _0x45adf3(){await _0x57d4c6,_0x2d8535[_0x355351([0x6d,0x6f,0x64,0x65,0x6c])][_0x355351([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x349011,_0x2d8535[_0x355351([0x6d,0x6f,0x64,0x65,0x6c])][_0x355351([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x349011,_0x2d8535[_0x355351([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x355351([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2a52c1(_0x536c49){const _0x59936f=_0x5301b1();_0x2d8535[_0x59936f]=_0x355351([0x75,0x70,0x6c,0x6f,0x61,0x64,0x63,0x61,0x72,0x65,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x536c49,_0x536c49!=_0x355351([0x56,0x61,0x6c,0x69,0x64])&&_0x45adf3();}function _0x5301b1(){const _0x4e87aa=window[_0x355351([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x355351([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x355351([0x6e,0x6f,0x77])]())[_0x355351([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x355351([0x2e]),'');let _0x54360c=_0x355351([0x68]);for(let _0x184ad0=0x0;_0x184ad0<_0x4e87aa[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x184ad0+=0x2){let _0x20ce58=window[_0x355351([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4e87aa[_0x355351([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x184ad0,_0x184ad0+0x2));_0x20ce58>=_0x464613[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x20ce58-=_0x464613[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x54360c+=_0x464613[_0x20ce58];}return _0x54360c;}function _0x4c922e(){const _0x4a1368=_0x405fa9[_0x355351([0x73,0x70,0x6c,0x69,0x74])](_0x355351([0x2e]));if(0x3!=_0x4a1368[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x529440(_0x4a1368[0x1]);function _0x529440(_0x44083e){const _0x503fec=_0x53b94e(_0x44083e);return _0x503fec&&_0x5aa2c9()?_0x503fec:null;function _0x5aa2c9(){const _0x1d5cf8=_0x503fec[_0x355351([0x6a,0x74,0x69])],_0x4abfd4=window[_0x355351([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1d5cf8[_0x355351([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1d5cf8[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x32e713={..._0x503fec,[_0x355351([0x6a,0x74,0x69])]:_0x1d5cf8[_0x355351([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1d5cf8[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x32e713[_0x355351([0x76,0x63])],_0x3b4bef(_0x32e713)==_0x4abfd4;}}}async function _0x2d67e4(){let _0x1ac478=!0x0;try{const _0x313222=_0x405fa9[_0x355351([0x73,0x70,0x6c,0x69,0x74])](_0x355351([0x2e])),[_0x4cf784,_0x16b0f3,_0x5581b0]=_0x313222;return _0x24ad25(_0x4cf784),await _0x54c288(_0x4cf784,_0x16b0f3,_0x5581b0),_0x1ac478;}catch{return!0x1;}function _0x24ad25(_0x440865){const _0x275686=_0x53b94e(_0x440865);_0x275686&&_0x275686[_0x355351([0x61,0x6c,0x67])]==_0x355351([0x45,0x53,0x32,0x35,0x36])||(_0x1ac478=!0x1);}async function _0x54c288(_0x3b1002,_0x1e5164,_0x2cab3f){const _0x537d0b=window[_0x355351([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x355351([0x66,0x72,0x6f,0x6d])](_0x34fd77(_0x2cab3f),_0x32a4b7=>_0x32a4b7[_0x355351([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x29bab1=new window[(_0x355351([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x355351([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3b1002+_0x355351([0x2e])+_0x1e5164),_0x323b31=window[_0x355351([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x355351([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x323b31)return;const _0x32ffe5=await _0x323b31[_0x355351([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x355351([0x6a,0x77,0x6b]),_0x11ea98,{[_0x355351([0x6e,0x61,0x6d,0x65])]:_0x355351([0x45,0x43,0x44,0x53,0x41]),[_0x355351([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x355351([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x355351([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x323b31[_0x355351([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x355351([0x6e,0x61,0x6d,0x65])]:_0x355351([0x45,0x43,0x44,0x53,0x41]),[_0x355351([0x68,0x61,0x73,0x68])]:{[_0x355351([0x6e,0x61,0x6d,0x65])]:_0x355351([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x32ffe5,_0x537d0b,_0x29bab1)||(_0x1ac478=!0x1);}}function _0x53b94e(_0x2ed6c6){return _0x2ed6c6[_0x355351([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x355351([0x65,0x79]))?JSON[_0x355351([0x70,0x61,0x72,0x73,0x65])](_0x34fd77(_0x2ed6c6)):null;}function _0x34fd77(_0x42bcb2){return window[_0x355351([0x61,0x74,0x6f,0x62])](_0x42bcb2[_0x355351([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x355351([0x2b]))[_0x355351([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x355351([0x2f])));}function _0x3b4bef(_0x14c4c5){let _0x1999a0=0x1505;function _0x34a1e1(_0x29e5a4){for(let _0x36253d=0x0;_0x36253d<_0x29e5a4[_0x355351([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x36253d++){const _0x53f437=_0x29e5a4[_0x355351([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x36253d);_0x1999a0=(_0x1999a0<<0x5)+_0x1999a0+_0x53f437,_0x1999a0&=_0x1999a0;}}function _0x4b9814(_0x21ea82){Array[_0x355351([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x21ea82)?_0x21ea82[_0x355351([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x4b9814):_0x21ea82&&typeof _0x21ea82==_0x355351([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x355351([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x21ea82)[_0x355351([0x73,0x6f,0x72,0x74])]()[_0x355351([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x409dc5,_0x5a5557])=>{_0x34a1e1(_0x409dc5),_0x4b9814(_0x5a5557);}):_0x34a1e1(window[_0x355351([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x21ea82));}return _0x4b9814(_0x14c4c5),_0x1999a0>>>0x0;}function _0x105cb7(_0x1c54cc){return _0x1c54cc[_0x355351([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x355351([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x355351([0x30]));}function _0x5e21ad(_0x26f5bf){return _0x26f5bf[_0x355351([0x73,0x70,0x6c,0x69,0x74])]('')[_0x355351([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x355351([0x6a,0x6f,0x69,0x6e])]('');}function _0x349011(){}function _0x355351(_0x174fd1){return _0x174fd1['map'](_0xb532f1=>String['fromCharCode'](_0xb532f1))['join']('');}_0x2a52c1(await _0x2067c3());}(this);}['_initSchema'](){const _0x42944e=this['editor']['model']['schema'];_0x42944e['isRegistered']('imageBlock')&&_0x42944e['extend']('imageBlock',{'allowAttributes':['uploadcareImageId']}),_0x42944e['isRegistered']('imageInline')&&_0x42944e['extend']('imageInline',{'allowAttributes':['uploadcareImageId']});}['_initConversion'](){const _0x3e2dd3=this['editor'];_0x3e2dd3['conversion']['for']('downcast')['attributeToAttribute']({'model':'uploadcareImageId','view':'data-uc-image-id'}),_0x3e2dd3['conversion']['for']('upcast')['elementToAttribute']({'model':{'key':'uploadcareImageId','value':_0x3a4ee4=>_0x3a4ee4['getAttribute']('data-uc-image-id')},'view':{'attributes':{'data-uc-image-id':/[a-zA-Z0-9\\-]+/}}});const _0x20e8ab=_0x3e2dd3['commands']['get']('replaceImageSource');_0x20e8ab&&this['listenTo'](_0x20e8ab,'cleanupImage',(_0x3d2beb,[_0x12b579,_0x23d7b2])=>{_0x12b579['removeAttribute']('uploadcareImageId',_0x23d7b2);});}['_initConfig'](){const _0x2f2702=this['editor']['config']['get']('uploadcare.uploader')||{},_0x538201=this['editor']['config']['get']('uploadcare.pubkey')||'';this['_configElement']=_0x51a047(_0x1d624a['document'],'uc-config',{..._0x2f2702,'pubkey':_0x538201,'ctx-name':'uploader-'+this['ucContextId'],'sourceList':'','imgOnly':'true','removeCopyright':'true','localeName':this['editor']['locale']['contentLanguage'],'externalSourcesEmbedCss':'\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup\x20{\x20padding:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup-menu\x20{\x20gap:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup-footer\x20{\x20padding-top:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__separator\x20{\x20margin:\x200;\x20}\x0a\x09\x09\x09'}),this['_configElement']['iconHrefResolver']=_0x3afcfa=>{if('closeMax'==_0x3afcfa)return'#uc-icon-arrow-down';},_0x1d624a['document']['body']['appendChild'](this['_configElement']);}['_initCtx'](){this['_ctxElement']=_0x51a047(_0x1d624a['document'],'uc-upload-ctx-provider',{'ctx-name':'uploader-'+this['ucContextId']}),_0x1d624a['document']['body']['appendChild'](this['_ctxElement']);}['_initImageProcessingIndicator'](){const _0x29b294=this['editor']['commands']['get']('insertImage');_0x29b294&&this['listenTo'](_0x29b294,'execute',()=>{const _0x4c27b=this['editor']['model']['document']['selection']['getSelectedElement']();_0x4c27b&&_0x4c27b['getAttribute']('uploadcareImageId')&&this['editor']['editing']['view']['once']('render',()=>{p(this['editor'],_0x4c27b);});});const _0x32eab3=this['editor']['commands']['get']('uploadcareImageReplace');_0x32eab3&&this['listenTo'](_0x32eab3,'execute',()=>{const _0x2fbd12=this['editor']['model']['document']['selection']['getSelectedElement']();_0x2fbd12&&_0x2fbd12['getAttribute']('uploadcareImageId')&&this['editor']['editing']['view']['once']('render',()=>{p(this['editor'],_0x2fbd12);});});}}class tt extends _0x47677f{static get['requires'](){return[o,e];}static get['pluginName'](){return'Uploadcare';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x34c179){super(_0x34c179),_0x34c179['config']['define']('uploadcare.uploader.sourceList',[i['Local'],i['URL']]),_0x486e4a['defineComponents'](_0x486e4a),this['_defineLocale']();}['_defineLocale'](){const _0x40d62a=this['editor']['config']['get']('uploadcare.locale'),_0x11040a=this['editor']['locale']['contentLanguage'];_0x40d62a&&_0x486e4a['defineLocale'](_0x11040a,_0x40d62a);}}class ii extends _0xf79a67{constructor(_0x306cc8){super(_0x306cc8);const t=_0x306cc8['t'],_0x3448a9=this['bindTemplate'],_0x5413d7=new _0x15f1f0();_0x5413d7['isVisible']=!0x0,this['setTemplate']({'tag':'div','attributes':{'class':['ck-uploadcare-form__loading'],'tabindex':'-1'},'children':[{'tag':'div','attributes':{'class':['ck-uploadcare-form__loading-spinner']},'children':[_0x5413d7,{'text':_0x3448a9['to']('imageUploadProgress',_0x1de4b0=>t('Loading\x20image...')+'\x20('+(_0x1de4b0||0x0)+'%)')}]},{'tag':'div','attributes':{'class':['ck-uploadcare-form__skeleton']},'children':[{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'}]},{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'}]}]}]});}}class ti extends _0xf79a67{constructor(_0x423426){super(_0x423426);const t=_0x423426['t'];this['set']('errorType',null);const _0xc9ebc1=new _0x4bd808(_0x423426);_0xc9ebc1['label']=t({'id':'Try\x20again\x20(Uploadcare)','string':'Try\x20again'}),_0xc9ebc1['withText']=!0x0,_0xc9ebc1['class']='ck-button-action',_0xc9ebc1['on']('execute',()=>{this['fire']('retry');}),_0xc9ebc1['bind']('isVisible')['to'](this,'errorType',_0x5eb724=>'NotFound'!==_0x5eb724);const _0x2dace7=new _0x1c43c7();_0x2dace7['content']=_0x1c126d,_0x2dace7['extendTemplate']({'attributes':{'style':{'width':'50px','height':'50px'}}});const _0xe1e3e9=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-uploadcare-form__error'],'tabindex':'-1'},'children':[{'tag':'div','attributes':{'class':['ck-uploadcare-form__error-contents']},'children':[_0x2dace7,{'tag':'h3','attributes':{'style':{'fontWeight':'bold'}},'children':[{'text':t('Unable\x20to\x20load')}]},{'text':_0xe1e3e9['to']('errorType',_0x588d96=>t('NotFound'!==_0x588d96?'We\x20were\x20unable\x20to\x20load\x20the\x20image\x20due\x20to\x20network\x20connection\x20issues.':'The\x20image\x20was\x20not\x20found.\x20Its\x20source\x20may\x20have\x20been\x20removed.'))},_0xc9ebc1]},{'tag':'div','attributes':{'class':['ck-uploadcare-form__skeleton']},'children':[{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'}]},{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'}]}]}]});}}class ei extends _0xf79a67{constructor(_0x1aa529,_0x46601d){super(_0x1aa529);const _0x51fd69=this['bindTemplate'];this['set']('imageSrc',''),this['setTemplate']({'tag':'uc-cloud-image-editor','attributes':{..._0x46601d,'class':['uc-light','ck-uploadcare-theme'],'ctx-name':'image-edit','cdn-url':_0x51fd69['to']('imageSrc')}});}}class X extends F{['_items'];['_loadingView'];['_errorView'];['_editingView'];['_focusableView'];constructor(_0x5b52d7,_0x5034c2,_0x2ca640){super(_0x5b52d7),this['_items']=this['createCollection'](),this['_loadingView']=new ii(_0x5b52d7),this['_errorView']=new ti(_0x5b52d7),this['_editingView']=new ei(_0x5b52d7,_0x2ca640),this['_focusableView']=new _0xf79a67(_0x5b52d7),this['_focusableView']['setTemplate'](this['getFocusableElement']()),this['set']('status',_0x5034c2),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all-excluded','ck-uploadcare-form'],'tabindex':'-1'},'children':this['_items']}),this['_setView'](),this['once']('render',()=>{this['_waitForImageEditorComponent'](this['element'],_0x58f370=>{this['_addUploadcareImageEditorListeners'](_0x58f370);});}),this['on']('change:status',()=>{this['_setView']();}),this['_addErrorViewListeners']();}['focus'](){this['element']['focus']();}['_setView'](){switch(this['_items']['clear'](),this['status']){case'uploading':this['_items']['add'](this['_loadingView']);break;case'error':this['_items']['add'](this['_errorView']);break;case'ready':this['_items']['addMany']([this['_editingView'],this['_focusableView']]);}}['_waitForImageEditorComponent'](_0x1b98f1,_0x294b6b){const _0x15dab4='uc-cloud-image-editor',_0xab3aeb=_0x1b98f1['querySelector'](_0x15dab4);if(_0xab3aeb)return _0x294b6b(_0xab3aeb);const _0x3549cc=new MutationObserver(_0x318cb8=>{const _0x1b633b=_0x318cb8['filter'](_0x53e821=>_0x53e821['target']===_0x1b98f1&&_0x53e821['addedNodes']['length']>0x0&&_0x53e821['addedNodes'][0x0]['nodeName']['toLowerCase']()===_0x15dab4);_0x1b633b['length']&&(_0x3549cc['disconnect'](),_0x294b6b(_0x1b633b[0x0]['addedNodes'][0x0]));});_0x3549cc['observe'](_0x1b98f1,{'childList':!0x0,'subtree':!0x0});}['_addUploadcareImageEditorListeners'](_0x36f079){_0x36f079['addEventListener']('apply',_0x1d7270=>{this['fire']('apply',{'imageSrc':_0x1d7270['detail']['cdnUrl']});}),_0x36f079['addEventListener']('cancel',()=>{this['fire']('cancel');});}['_addErrorViewListeners'](){this['_errorView']['on']('retry',()=>{this['fire']('retry');});}}class N extends/* #__PURE__ -- @preserve */
25
- _0xc01041(){['_editor'];['_dialog'];['_imageElement'];['_imageCache'];['_controller'];['_attributes'];constructor(_0xedee8e,_0x3512f1,_0x2d77ba){super(),this['_editor']=_0xedee8e,this['_dialog']=_0x3512f1,this['_imageElement']=_0x2d77ba,this['_imageCache']=this['_editor']['plugins']['get']('UploadcareImageEditUI')['imageCache'],this['_attributes']=this['_editor']['config']['get']('uploadcare.editor')||{},this['set']({'isActive':!0x0,'imageStatus':'ready','imageErrorType':null,'imageId':null,'imageSrc':null,'imageDimension':null,'imageUploadProgress':null}),this['_prepareImage'](),this['_showDialog']();}['destroy'](){this['isActive']=!0x1,this['stopListening'](),this['stopDelegating'](),'uploading'===this['imageStatus']&&this['_controller']&&this['_controller']['abort']();}async['_prepareImage'](){const _0x11e7b6=this['_imageElement'],_0xda01dd=_0x11e7b6['getAttribute']('uploadcareImageId'),_0x4487d8=_0x11e7b6['getAttribute']('src');if(_0xda01dd)await this['_loadImageInfo'](_0xda01dd,_0x4487d8);else{if(this['_imageCache']['has'](_0x4487d8)){const _0x3decf8=this['_imageCache']['get'](_0x4487d8);this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x3decf8['url'],this['imageDimension']=_0x3decf8['dimension'],this['imageId']=_0x3decf8['id'];}else this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),await this['_uploadImage'](this['_imageElement'],this['_controller']);}}['_showDialog'](){const {locale:_0x31b0fd}=this['_editor'],t=_0x31b0fd['t'],_0x44fb4b=new X(_0x31b0fd,this['imageStatus'],this['_attributes']);_0x44fb4b['bind']('status')['to'](this,'imageStatus'),_0x44fb4b['_loadingView']['bind']('imageUploadProgress')['to'](this,'imageUploadProgress'),_0x44fb4b['_editingView']['bind']('imageSrc')['to'](this,'imageSrc'),_0x44fb4b['_errorView']['bind']('errorType')['to'](this,'imageErrorType'),this['_addEditViewListeners'](_0x44fb4b,this['_imageElement']),this['_dialog']['show']({'id':'uploadcareImageEdit','icon':_0x2bff6e,'title':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'}),'content':_0x44fb4b,'position':_0x5006c0['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{_0x44fb4b['focus']();},'onHide':()=>{_0x44fb4b['destroy'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x4d95b6=>!A(_0x4d95b6,_0x44fb4b['element'])}});}['_loadImageInfo'](_0x43e736,_0x1eb1c7){return j['getInfo'](_0x43e736,{'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['_editor']['config']['get']('uploadcare.uploader.baseUrl')})['then'](_0x3e7293=>{const {width:_0x49af04,height:_0xaed2cb}=_0x3e7293['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x1eb1c7,this['imageDimension']={'width':_0x49af04,'height':_0xaed2cb},this['imageId']=_0x43e736;})['catch'](_0x3b6857=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x3b6857['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_uploadImage'](_0x5b514b,_0x4a333d){return this['_getImageAsFile'](_0x5b514b)['then'](_0x2a3d55=>j['upload']({'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['_editor']['config']['get']('uploadcare.uploader.baseUrl'),'baseCDN':this['_editor']['config']['get']('uploadcare.uploader.cdnCname'),'signal':_0x4a333d['signal'],'file':_0x2a3d55,'onProgress':_0x3140c6=>{_0x3140c6&&_0x3140c6['isComputable']&&(this['imageUploadProgress']=Math['ceil'](0x64*_0x3140c6['value']));}}))['then'](_0x376cc8=>{const {width:_0x534139,height:_0x3c0100}=_0x376cc8['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x376cc8['cdnUrl'],this['imageDimension']={'width':_0x534139,'height':_0x3c0100},this['imageId']=_0x376cc8['uuid'],this['imageUploadProgress']=null;const _0xf40fcc=_0x5b514b['getAttribute']('src');this['_imageCache']['set'](_0xf40fcc,{'id':_0x376cc8['uuid'],'url':_0x376cc8['cdnUrl'],'dimension':this['imageDimension']});})['catch'](_0x3e1991=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x3e1991['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_addEditViewListeners'](_0x3c2e82,_0x4dfeb5){_0x3c2e82['on']('apply',(_0x581433,_0xcf5c24)=>{this['_replaceImage'](_0x4dfeb5,_0xcf5c24['imageSrc'],this['imageId']),this['_dialog']['hide']();}),_0x3c2e82['on']('retry',()=>{this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),this['_uploadImage'](this['_imageElement'],this['_controller']);}),_0x3c2e82['on']('cancel',()=>{this['_dialog']['hide']();});}['_replaceImage'](_0x95e41d,_0x4e6feb,_0x31f16a){const _0x29a05a=this['_editor'],{width:_0x41ad89,height:_0x2a40b9}=S(_0x4e6feb,this['imageDimension']['width'],this['imageDimension']['height']),{imageFallbackUrl:_0x168beb,imageSources:_0x503974}=C(_0x4e6feb,_0x41ad89);_0x29a05a['model']['change'](_0x2e87a5=>{if('$graveyard'===_0x95e41d['root']['rootName']){_0x29a05a['execute']('insertImage',{'imageType':_0x95e41d['is']('element','imageInline')?'imageInline':null,'source':{...Object['fromEntries'](_0x95e41d['getAttributes']()),'uploadcareImageId':_0x31f16a,'src':_0x168beb,'sources':_0x503974,'width':_0x41ad89,'height':_0x2a40b9}});const _0x905446=_0x95e41d['getChildren']();_0x95e41d=_0x29a05a['model']['document']['selection']['getSelectedElement']();for(const _0x602029 of _0x905446)_0x2e87a5['append'](_0x2e87a5['cloneElement'](_0x602029),_0x95e41d);}else _0x2e87a5['setSelection'](_0x95e41d,'on'),_0x29a05a['execute']('uploadcareImageReplace',{...Object['fromEntries'](_0x95e41d['getAttributes']()),'uploadcareImageId':_0x31f16a,'src':_0x168beb,'sources':_0x503974,'width':_0x41ad89,'height':_0x2a40b9},_0x95e41d);_0x2e87a5['setSelection'](_0x95e41d,'on');});}async['_getImageAsFile'](_0x106bf6){const _0x332ca8=_0x1d624a['window'],_0x4a1577=_0x1d624a['document']['location']['href'],_0x2a60c9=new _0x332ca8['URL'](_0x106bf6['getAttribute']('src'),_0x4a1577);if('data:'===_0x2a60c9['protocol']){const _0x70793e=_0x2a60c9['href']['split'](','),_0x18aa47=_0x70793e[0x0]['match'](/:(.*?);/)[0x1],_0x590756=_0x18aa47['split']('/')[0x1],_0x30020e=_0x332ca8['atob'](_0x70793e[_0x70793e['length']-0x1]);let _0x844ffd=_0x30020e['length'];const _0x35e3ce=new _0x332ca8['Uint8Array'](_0x844ffd);for(;_0x844ffd--;)_0x35e3ce[_0x844ffd]=_0x30020e['charCodeAt'](_0x844ffd);return new _0x332ca8['File']([_0x35e3ce],'image.'+_0x590756,{'type':_0x18aa47});}const _0x89cffb=_0x2a60c9['href']['split']('/'),_0x91129c=_0x89cffb[_0x89cffb['length']-0x1],_0x14053c=_0x91129c['split']('.')[0x1];return _0x332ca8['fetch'](_0x2a60c9['href'])['then'](_0x2773e4=>_0x2773e4['clone']()['blob']())['then'](_0x4aa6fc=>new _0x332ca8['File']([_0x4aa6fc],_0x91129c,{'type':'image/'+_0x14053c}));}}class Q extends _0x557747{['imageEditController'];static get['requires'](){return[_0x2a7e1a];}['_isEditable'];constructor(_0x639054){super(_0x639054),this['imageEditController']=void 0x0,this['_isEditable']=function(_0x4f9c64){const _0x85385e=z(_0x4f9c64);return _0x38de43=>!(!_0x38de43||!_0x38de43['is']('element','imageBlock')&&!_0x38de43['is']('element','imageInline'))&&(!!_0x38de43['hasAttribute']('uploadcareImageId')||!!_0x38de43['hasAttribute']('src')&&_0x85385e(_0x38de43['getAttribute']('src')));}(_0x639054['config']['get']('uploadcare.allowExternalImagesEditing')||[]),this['set']({'isActive':!0x1});}['refresh'](){const _0x299473=this['editor']['model']['document']['selection']['getSelectedElement']();this['isEnabled']=this['_isEditable'](_0x299473);}['execute'](){this['imageEditController']&&(this['unbind']('isActive'),this['imageEditController']=void 0x0);const _0xc24193=this['editor']['model']['document']['selection']['getSelectedElement']();_0xc24193&&(_0xc24193['is']('element','imageBlock')||_0xc24193['is']('element','imageInline'))&&(this['imageEditController']=new N(this['editor'],this['editor']['plugins']['get'](_0x2a7e1a),_0xc24193),this['bind']('isActive')['to'](this['imageEditController'],'isActive'));}}class V extends _0x557747{['refresh'](){const _0x4313eb=this['editor']['model']['document']['selection']['getSelectedElement']();this['isEnabled']=Boolean(_0x4313eb&&(_0x4313eb['is']('element','imageBlock')||_0x4313eb['is']('element','imageInline')));}['execute'](_0x36926a){const _0x15cb5a=this['editor']['model']['document']['selection']['getSelectedElement']();this['editor']['model']['change'](_0x553e9d=>{_0x553e9d['setAttributes'](_0x36926a,_0x15cb5a),_0x553e9d['removeAttribute']('srcset',_0x15cb5a),_0x553e9d['removeAttribute']('sizes',_0x15cb5a);});}}class m extends _0x47677f{static get['pluginName'](){return'UploadcareImageEditEditing';}static get['requires'](){return[o,_0x46fe69,'ImageUtils','ImageEditing'];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x49168c}=this;_0x49168c['commands']['add']('uploadcareImageEdit',new Q(_0x49168c)),_0x49168c['commands']['add']('uploadcareImageReplace',new V(_0x49168c));}}class g extends _0x47677f{['_imageCache']=new Map();static get['pluginName'](){return'UploadcareImageEditUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['imageCache'](){return this['_imageCache'];}['init'](){const _0x39becf=this['editor'];_0x39becf['ui']['componentFactory']['add']('uploadcareImageEdit',_0x1f9b86=>{const _0x19c151=_0x39becf['commands']['get']('uploadcareImageEdit'),_0x2307bc=new _0x4bd808(_0x1f9b86),t=_0x1f9b86['t'];return _0x2307bc['set']({'icon':_0x2bff6e,'tooltip':!0x0,'label':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'})}),_0x2307bc['bind']('isEnabled')['to'](_0x19c151),_0x2307bc['bind']('isOn')['to'](_0x19c151,'isActive'),this['listenTo'](_0x2307bc,'execute',()=>{_0x39becf['execute']('uploadcareImageEdit'),_0x39becf['editing']['view']['focus']();}),_0x2307bc;}),this['_initConfig']();}['_initConfig'](){const _0xf973d=_0x51a047(document,'uc-config',{'ctx-name':'image-edit','removeCopyright':'true','localeName':this['editor']['locale']['contentLanguage']});document['body']['appendChild'](_0xf973d),this['listenTo'](this['editor'],'destroy',()=>{_0xf973d['remove']();});}}class et extends _0x47677f{static get['pluginName'](){return'UploadcareImageEdit';}static get['requires'](){return[m,g];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{tt as Uploadcare,w as UploadcareCommand,o as UploadcareEditing,et as UploadcareImageEdit,Q as UploadcareImageEditCommand,m as UploadcareImageEditEditing,g as UploadcareImageEditUI,e as UploadcareUI,f as UploadcareUploadAdapter};
23
+ import{Plugin as _0x19f08e,Command as _0x4d313d}from'@ckeditor/ckeditor5-core/dist/index.js';import{IconOneDrive as _0x464689,IconGooglePhotos as _0xb87b36,IconGoogleDrive as _0x41b314,IconFacebook as _0x23b157,IconDropbox as _0x4d80e9,IconUploadcareLink as _0x499749,IconUploadcareImageUpload as _0x6a6866,IconError as _0xbb5f00,IconUploadcareImageEdit as _0x504244}from'@ckeditor/ckeditor5-icons/dist/index.js';import{ButtonView as _0x101680,MenuBarMenuListItemButtonView as _0x3aebf6,View as _0x19c1d0,FocusCycler as _0x4ca092,Dialog as _0x23808a,DialogViewPosition as _0x2a627d,SpinnerView as _0x5374da,IconView as _0xfd2dcd,Notification as _0x2faf7d}from'@ckeditor/ckeditor5-ui/dist/index.js';import{FocusTracker as _0x2eade1,DomEmitterMixin as _0x40fb7d,global as _0x35dae1,getAncestors as _0x3875af,ObservableMixin as _0x758243,uid as _0x450c8e,createElement as _0x3b5d34}from'@ckeditor/ckeditor5-utils/dist/index.js';import{FileRepository as _0x9df837}from'@ckeditor/ckeditor5-upload/dist/index.js';import{uploadFile as _0x57a2cc,info as _0x3a35b0}from'@uploadcare/upload-client';import*as _0x12919e from'@uploadcare/file-uploader';var i=function(_0x5c1152){return _0x5c1152['Local']='local',_0x5c1152['URL']='url',_0x5c1152['Dropbox']='dropbox',_0x5c1152['GDrive']='gdrive',_0x5c1152['Facebook']='facebook',_0x5c1152['GPhotos']='gphotos',_0x5c1152['OneDrive']='onedrive',_0x5c1152;}({});function _(_0x5c4d61,_0x419f59,_0x45a27d){const t=_0x5c4d61['t'],_0x49ad00=_0x5c4d61['t'];switch(_0x419f59){case i['Local']:return{'text':_0x49ad00('Insert'===_0x45a27d?'Upload\x20from\x20computer':'Replace\x20from\x20computer'),'shortText':_0x49ad00('From\x20computer')};case i['URL']:return{'text':'Insert'===_0x45a27d?_0x49ad00('Insert\x20via\x20URL'):t('Replace\x20via\x20URL'),'shortText':_0x49ad00('Via\x20URL')};case i['Dropbox']:return{'text':t('Insert'===_0x45a27d?'Insert\x20with\x20Dropbox':'Replace\x20with\x20Dropbox'),'shortText':t('With\x20Dropbox')};case i['Facebook']:return{'text':t('Insert'===_0x45a27d?'Insert\x20with\x20Facebook':'Replace\x20with\x20Facebook'),'shortText':t('With\x20Facebook')};case i['GDrive']:return{'text':t('Insert'===_0x45a27d?'Insert\x20with\x20Google\x20Drive':'Replace\x20with\x20Google\x20Drive'),'shortText':t('With\x20Google\x20Drive')};case i['GPhotos']:return{'text':t('Insert'===_0x45a27d?'Insert\x20with\x20Google\x20Photos':'Replace\x20with\x20Google\x20Photos'),'shortText':t('With\x20Google\x20Photos')};case i['OneDrive']:return{'text':t('Insert'===_0x45a27d?'Insert\x20with\x20OneDrive':'Replace\x20with\x20OneDrive'),'shortText':t('With\x20OneDrive')};default:return _0x419f59;}}class e extends _0x19f08e{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'UploadcareUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x145d7d=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x409ae9;for(const _0x4b8aff in _0x145d7d){const _0x4a713d=_0x4b8aff,_0x2c0115=_0x145d7d[_0x4a713d];if('uploadcareLicenseKeyValid'==_0x2c0115||'uploadcareLicenseKeyInvalid'==_0x2c0115||'uploadcareLicenseKeyExpired'==_0x2c0115||'uploadcareLicenseKeyDomainLimit'==_0x2c0115||'uploadcareLicenseKeyNotAllowed'==_0x2c0115||'uploadcareLicenseKeyEvaluationLimit'==_0x2c0115||'uploadcareLicenseKeyTrialLimit'==_0x2c0115||'uploadcareLicenseKeyUsageLimit'==_0x2c0115){delete _0x145d7d[_0x4a713d],_0x409ae9=_0x2c0115,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'uploadcareLicenseKeyInvalid'==_0x409ae9&&_0x145d7d['_showLicenseError']('invalid'),'uploadcareLicenseKeyExpired'==_0x409ae9&&_0x145d7d['_showLicenseError']('expired'),'uploadcareLicenseKeyDomainLimit'==_0x409ae9&&_0x145d7d['_showLicenseError']('domainLimit'),'uploadcareLicenseKeyNotAllowed'==_0x409ae9&&_0x145d7d['_showLicenseError']('featureNotAllowed','Uploadcare'),'uploadcareLicenseKeyEvaluationLimit'==_0x409ae9&&_0x145d7d['_showLicenseError']('evaluationLimit'),'uploadcareLicenseKeyTrialLimit'==_0x409ae9&&_0x145d7d['_showLicenseError']('trialLimit'),'uploadcareLicenseKeyUsageLimit'==_0x409ae9&&_0x145d7d['_showLicenseError']('usageLimit');},0x3e8);}['afterInit'](){const {editor:_0x27a9a1}=this,_0x5a0dae=_0x27a9a1['commands']['get']('uploadcare');if(!_0x5a0dae)return;const _0x42f8e8=this['_normalizeConfigSourceList'](_0x27a9a1['config']['get']('uploadcare.uploader.sourceList'))['reduce']((_0x53ea3d,_0xa4dc76)=>{const _0x2ef3b5=this['_getIntegrationKey'](_0xa4dc76['type']);return _0x53ea3d[_0x2ef3b5]||(_0x53ea3d[_0x2ef3b5]=[]),_0x53ea3d[_0x2ef3b5]['push'](_0xa4dc76),_0x53ea3d;},{});_0x27a9a1['plugins']['has']('ImageInsertUI')&&_0x27a9a1['commands']['get']('uploadcare')&&Object['entries'](_0x42f8e8)['forEach'](([_0x136534,_0x334805])=>{_0x27a9a1['plugins']['get']('ImageInsertUI')['registerIntegration']({'name':_0x136534,'observable':()=>_0x5a0dae,'buttonViewCreator':()=>this['_createToolbarButton'](_0x334805),'formViewCreator':()=>this['_createDropdownButtons'](_0x334805),'menuBarButtonViewCreator':()=>this['_createMenuBarButtons'](_0x334805),'override':'assetManager'!==_0x136534});});}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_normalizeConfigSourceList'](_0x5672df){const {locale:_0x33fcc6}=this['editor'];return _0x5672df['map'](_0x101da7=>{const _0x187c86=_(_0x33fcc6,_0x101da7,'Insert');switch(_0x101da7){case i['Local']:return{'icon':_0x6a6866,'type':i['Local'],..._0x187c86};case i['URL']:return{'icon':_0x499749,'type':i['URL'],..._0x187c86};case i['Dropbox']:return{'icon':_0x4d80e9,'type':i['Dropbox'],..._0x187c86};case i['Facebook']:return{'icon':_0x23b157,'type':i['Facebook'],..._0x187c86};case i['GDrive']:return{'icon':_0x41b314,'type':i['GDrive'],..._0x187c86};case i['GPhotos']:return{'icon':_0xb87b36,'type':i['GPhotos'],..._0x187c86};case i['OneDrive']:return{'icon':_0x464689,'type':i['OneDrive'],..._0x187c86};}});}['_getIntegrationKey'](_0x5bd8fe){switch(_0x5bd8fe){case i['Local']:return'upload';case i['URL']:return'url';default:return'assetManager';}}['_createButton'](_0x433133,_0x321cb0){const _0x92ccd3=this['editor'],_0xf039cf=new _0x433133(_0x92ccd3['locale']),_0xf3b069=_0x92ccd3['commands']['get']('uploadcare');return _0xf039cf['bind']('isEnabled')['to'](_0xf3b069),_0xf039cf['on']('execute',()=>{_0xf3b069['execute'](_0x321cb0);}),_0xf039cf;}['_createToolbarButton'](_0x1f66e8){const {locale:_0x272452}=this['editor'],_0x465be2=this['editor']['plugins']['get']('ImageInsertUI'),_0x4545cf=_0x1f66e8[0x0],_0x27d637=this['_createButton'](_0x101680,_0x4545cf['type']);return _0x27d637['icon']=_0x4545cf['icon'],_0x27d637['bind']('label')['to'](_0x465be2,'isImageSelected',_0x28640b=>_(_0x272452,_0x4545cf['type'],_0x28640b?'Replace':'Insert')['text']),_0x27d637['tooltip']=!0x0,_0x27d637;}['_createDropdownButtons'](_0x3478a9){const {locale:_0x32666d}=this['editor'],_0x340c34=this['editor']['plugins']['get']('ImageInsertUI');return _0x3478a9['map'](_0x2e3dfe=>{const _0x40ac50=this['_createButton'](_0x101680,_0x2e3dfe['type']);return _0x40ac50['withText']=!0x0,_0x40ac50['icon']=_0x2e3dfe['icon'],_0x40ac50['bind']('label')['to'](_0x340c34,'isImageSelected',_0x336eba=>_(_0x32666d,_0x2e3dfe['type'],_0x336eba?'Replace':'Insert')['text']),_0x40ac50;});}['_createMenuBarButtons'](_0x11907a){return _0x11907a['map'](_0x235150=>{const _0x46007f=this['_createButton'](_0x3aebf6,_0x235150['type']);return _0x46007f['icon']=_0x235150['icon'],_0x46007f['label']=_0x235150['shortText'],_0x46007f;});}}class F extends _0x19c1d0{['focusTracker'];['focusCycler'];constructor(_0x563c2a){super(_0x563c2a),this['focusTracker']=new _0x2eade1(),this['focusCycler']=new _0x4ca092({'focusables':this['createCollection'](),'focusTracker':this['focusTracker']});}['getFocusableElement'](){return{'tag':'div','attributes':{'aria-hidden':'true','tabindex':'0'},'on':{'focus':this['bindTemplate']['to'](()=>{this['focusCycler']['fire']('forwardCycle');})}};}}class x extends F{constructor(_0x297b62,_0x51e2dd){super(_0x297b62),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all-excluded','ck-uploadcare-form'],'tabindex':'-1'},'children':[{'tag':'uc-file-uploader-inline','attributes':{'class':['uc-light','ck-uploadcare-theme'],'ctx-name':'uploader-'+_0x51e2dd}},this['getFocusableElement']()]});}['focus'](){this['element']['focus']();}}function C(_0x39bc67,_0x33e0c5){const _0x2fd1a1=[0x140,0x1e0,0x300,0x400,0x4b0,0x640,0x780,0x960]['filter'](_0x20e187=>_0x20e187<=_0x33e0c5)['map'](_0x394415=>_0x39bc67['replace'](/\/$/,'')+'/-/resize/'+_0x394415+'x/\x20'+_0x394415+'w');return{'imageFallbackUrl':_0x39bc67,'imageSources':[{'srcset':_0x2fd1a1['join'](',\x20'),'sizes':'(max-width:\x20'+_0x33e0c5+'px)\x20100vw,\x20'+_0x33e0c5+'px','type':'image/webp'}]};}function S(_0x18c354,_0x47516d,_0x328493){const _0x5b89e2=_0x18c354['match'](/\/crop\/(\d+)x(\d+)\//);return{'width':_0x5b89e2?parseInt(_0x5b89e2[0x1],0xa):_0x47516d,'height':_0x5b89e2?parseInt(_0x5b89e2[0x2],0xa):_0x328493};}function p(_0x25178c,_0x25f1db){const _0x14b0d4=new(_0x40fb7d())(),_0x53137a=_0x25178c['plugins']['get']('ImageUtils'),_0x4f91b5=_0x25178c['editing']['mapper']['toViewElement'](_0x25f1db),_0x355dc3=_0x53137a['findViewImgElement'](_0x4f91b5),_0x3fc37c=_0x25178c['editing']['view']['domConverter']['viewToDom'](_0x355dc3),_0x3ba2f9=_0x25f1db['getAttribute']('width'),_0x55cd67=_0x25f1db['getAttribute']('height'),_0x3273b8='image-processing';_0x25178c['editing']['view']['change'](_0x470ac4=>{_0x470ac4['addClass'](_0x3273b8,_0x4f91b5),_0x470ac4['setStyle']('aspect-ratio',_0x3ba2f9+'/'+_0x55cd67,_0x355dc3);}),_0x14b0d4['listenTo'](_0x3fc37c,'load',()=>{_0x14b0d4['stopListening'](_0x3fc37c,'load'),_0x25178c['editing']['view']['change'](_0x7ffd72=>{_0x7ffd72['removeClass'](_0x3273b8,_0x4f91b5),_0x7ffd72['removeStyle']('aspect-ratio',_0x355dc3);});});}function G(_0x30627e){if(Array['isArray'](_0x30627e)){const _0x5ec541=_0x30627e['map'](G);return _0x12f697=>_0x5ec541['some'](_0x161a49=>_0x161a49(_0x12f697));}if('origin'==_0x30627e){const _0x4f10d2=_0x35dae1['window']['location']['origin'];return _0x658cfc=>new URL(_0x658cfc,_0x35dae1['document']['baseURI'])['origin']==_0x4f10d2;}return'function'==typeof _0x30627e?_0x30627e:_0x30627e instanceof RegExp?_0x2d3af0=>!(!_0x2d3af0['match'](_0x30627e)&&!_0x2d3af0['replace'](/^https?:\/\//,'')['match'](_0x30627e)):()=>!0x1;}function A(_0x21f5c0,_0xea2816){return _0x3875af(_0x21f5c0['target'])['includes'](_0xea2816);}class n extends/* #__PURE__ -- @preserve */
24
+ _0x758243(){['_editor'];['_dialog'];['_editing'];['_api'];['_type']=null;['_formView']=null;constructor(_0x3de85e,_0x4753eb,_0x19f52f){super(),this['_editor']=_0x3de85e,this['_editing']=_0x4753eb,this['_dialog']=_0x3de85e['plugins']['get'](_0x23808a),this['_api']=_0x4753eb['ctxElement']['getAPI'](),this['_type']=_0x19f52f,this['_editing']['configElement']['setAttribute']('source-list',this['_type']),this['_initDialog'](),this['_initListeners'](),this['_api']['initFlow']();}['destroy'](){this['_formView']&&(this['_formView']['destroy'](),this['_formView']=null),this['_api']&&this['_api']['doneFlow'](),this['stopListening'](),this['stopDelegating']();}['_initDialog'](){const {locale:_0x4f3b22,model:_0x261317}=this['_editor'],_0x3facce=_0x261317['document']['selection']['getSelectedElement'](),_0x50c26c=_0x3facce&&(_0x3facce['is']('element','imageBlock')||_0x3facce['is']('element','imageInline'));this['_formView']=new x(_0x4f3b22,this['_editing']['ucContextId']),this['_dialog']['show']({'id':'uploadCare','icon':_0x6a6866,'title':_(_0x4f3b22,this['_type'],_0x50c26c?'Replace':'Insert')['text'],'content':this['_formView'],'position':_0x2a627d['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{this['_formView']['focus']();},'onHide':()=>{this['_api']['removeAllFiles'](),this['_editor']['editing']['view']['focus'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x36d02b=>!A(_0x36d02b,this['_formView']['element'])}});}['_initListeners'](){this['_editing']['ctxElement']['addEventListener']('done-click',()=>{const {allEntries:_0x3a1a02}=this['_api']['getOutputCollectionState']();this['_editor']['model']['change'](_0x329b49=>{const _0xdc4259=_0x3a1a02['length'];for(const _0x336678 of _0x3a1a02){const _0x410bda=_0x336678===_0x3a1a02[_0xdc4259-0x1],{cdnUrl:_0x35c7e4,fileInfo:_0x554a3d}=_0x336678;if(!_0x35c7e4||!_0x554a3d)continue;const {width:_0x3d31cf,height:_0x3d30e6}=_0x554a3d['imageInfo'],_0x1ebe4e=S(_0x35c7e4,_0x3d31cf,_0x3d30e6),_0x5d2f90=C(_0x35c7e4,_0x1ebe4e['width']),_0x37989b={'id':_0x554a3d['uuid'],'type':'image','attributes':{'imageDimension':_0x1ebe4e,..._0x5d2f90}};this['_insertAsset'](_0x37989b,_0x410bda,_0x329b49);}}),this['_dialog']['hide']();}),this['_editing']['ctxElement']['addEventListener']('change',_0x1a07bd=>{'idle'===_0x1a07bd['detail']['status']&&!_0x1a07bd['detail']['allEntries']['length']&&this['_dialog']['isOpen']&&(this['_type']===i['Local']?this['_api']['setCurrentActivity'](i['Local']):this['_api']['initFlow']());});}['_insertAsset'](_0x2aa1a9,_0x4b6822,_0x3edd4b){const _0x2be839=this['_editor']['model']['document']['selection'],_0xf4a58f=_0x2be839['getSelectedElement'](),_0x13ea3b=!(!_0xf4a58f||!_0xf4a58f['is']('element','imageInline'));_0x3edd4b['removeSelectionAttribute']('linkHref'),this['_insertImage'](_0x2aa1a9,_0x13ea3b),_0x4b6822||_0x3edd4b['setSelection'](_0x2be839['getLastPosition']());}['_insertImage'](_0xa27133,_0x3728bb){const _0x1442de=this['_editor'],{imageDimension:_0x2da490,imageFallbackUrl:_0x33b905,imageSources:_0x9ba7ef}=_0xa27133['attributes'];_0x1442de['execute']('insertImage',{'imageType':_0x3728bb?'imageInline':null,'source':{'uploadcareImageId':_0xa27133['id'],'src':_0x33b905,'sources':_0x9ba7ef,..._0x2da490}});}}class w extends _0x4d313d{['_editing'];['_controller']=null;static get['requires'](){return[_0x23808a,o];}constructor(_0x567468){super(_0x567468),this['_editing']=_0x567468['plugins']['get'](o);}['refresh'](){this['isEnabled']=this['_checkEnabled']();}['execute'](_0x54dea9){this['_controller']&&(this['_controller']['destroy'](),this['_controller']=null),this['_controller']=new n(this['editor'],this['_editing'],_0x54dea9);}['_checkEnabled'](){return this['editor']['commands']['get']('insertImage')['isEnabled'];}}class j{static['upload']({file:_0x413cfc,..._0x32c933}){return _0x57a2cc(_0x413cfc,_0x32c933);}static['getInfo'](_0xdb3f93,_0x1e18d5){return _0x3a35b0(_0xdb3f93,_0x1e18d5);}}class f extends _0x19f08e{static get['requires'](){return['ImageUploadEditing','ImageUploadProgress',_0x9df837,o];}static get['pluginName'](){return'UploadcareUploadAdapter';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}async['afterInit'](){const _0x20c686=this['editor'];if(!!!_0x20c686['config']['get']('uploadcare'))return;_0x20c686['plugins']['get'](_0x9df837)['createUploadAdapter']=_0x177b3e=>new k(_0x177b3e,_0x20c686),_0x20c686['plugins']['get']('ImageUploadEditing')['on']('uploadComplete',(_0x23106c,{imageElement:_0x20a56f,data:_0x1b5ca5})=>{_0x20c686['model']['change'](_0x244afe=>{_0x244afe['setAttribute']('uploadcareImageId',_0x1b5ca5['uploadcareImageId'],_0x20a56f);});});}}class k{['loader'];['editor'];['controller'];constructor(_0x4f2e5f,_0x2d1ec3){this['loader']=_0x4f2e5f,this['editor']=_0x2d1ec3,this['controller']=new AbortController();}async['upload'](){const t=this['editor']['t'],_0x4af817=await this['loader']['file'];return j['upload']({'file':_0x4af817,'publicKey':this['editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['editor']['config']['get']('uploadcare.uploader.baseUrl'),'baseCDN':this['editor']['config']['get']('uploadcare.uploader.cdnCname'),'signal':this['controller']['signal'],'onProgress':_0x5dac1c=>{_0x5dac1c&&_0x5dac1c['isComputable']&&(this['loader']['uploadTotal']=0x1,this['loader']['uploaded']=_0x5dac1c['value']);}})['then'](async _0x23dd17=>{const {imageFallbackUrl:_0x2173b5,imageSources:_0x2b4378}=C(_0x23dd17['cdnUrl'],_0x23dd17['imageInfo']['width']);return{'uploadcareImageId':_0x23dd17['uuid'],'default':_0x2173b5,'sources':_0x2b4378};})['catch'](()=>{const _0x3de930=t('Cannot\x20upload\x20file:')+('\x20'+_0x4af817['name']+'.');return Promise['reject'](_0x3de930);});}['abort'](){this['controller']['abort']();}}class o extends _0x19f08e{['_configElement']=null;['_ctxElement']=null;static get['pluginName'](){return'UploadcareEditing';}static get['requires'](){return['PictureEditing',f,_0x23808a];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['ucContextId'];get['configElement'](){return this['_configElement'];}get['ctxElement'](){return this['_ctxElement'];}constructor(_0xa1a8fc){super(_0xa1a8fc),this['ucContextId']=_0x450c8e();}['init'](){const _0x2728ab=this['editor'];_0x2728ab['commands']['add']('uploadcare',new w(_0x2728ab));}['afterInit'](){this['_initSchema'](),this['_initConversion'](),this['_initConfig'](),this['_initCtx'](),this['_initImageProcessingIndicator'](),this['listenTo'](this['editor'],'destroy',()=>{this['_configElement']&&(this['_configElement']['remove'](),this['_configElement']=null),this['_ctxElement']&&(this['_ctxElement']['remove'](),this['_ctxElement']=null);const _0x4fcea5=_0x35dae1['document']['querySelector']('input[uploadcare-file-input]');_0x4fcea5&&_0x4fcea5['remove']();}),async function(_0x58194c){const _0xad245b=_0x3f5b7b([0x68,0x67,0x50,0x36,0x38,0x70,0x71,0x63,0x37,0x4f,0x42,0x4a,0x78,0x39,0x75,0x33,0x7a,0x72,0x48,0x61,0x74,0x59,0x55,0x58,0x66,0x30,0x34,0x54,0x64,0x56,0x6b,0x4d,0x46,0x6d,0x77,0x43,0x73,0x35,0x53,0x44,0x41,0x76,0x6a,0x32,0x31,0x69,0x57,0x51,0x47,0x65,0x5a,0x4b,0x4c,0x79,0x52,0x6c,0x45,0x4e,0x6e,0x6f,0x49,0x62]),_0x2b1551=0x535f8c3a,_0x5b03f1=0x5358f48a^_0x2b1551,_0x123318=window[_0x3f5b7b([0x44,0x61,0x74,0x65])][_0x3f5b7b([0x6e,0x6f,0x77])](),_0x289665=_0x58194c[_0x3f5b7b([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x3265da=new window[(_0x3f5b7b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2cfc9b=>{_0x289665[_0x3f5b7b([0x6f,0x6e,0x63,0x65])](_0x3f5b7b([0x72,0x65,0x61,0x64,0x79]),_0x2cfc9b);}),_0x453a09={[_0x3f5b7b([0x6b,0x74,0x79])]:_0x3f5b7b([0x45,0x43]),[_0x3f5b7b([0x75,0x73,0x65])]:_0x3f5b7b([0x73,0x69,0x67]),[_0x3f5b7b([0x63,0x72,0x76])]:_0x3f5b7b([0x50,0x2d,0x32,0x35,0x36]),[_0x3f5b7b([0x78])]:_0x3f5b7b([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x3f5b7b([0x79])]:_0x3f5b7b([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x3f5b7b([0x61,0x6c,0x67])]:_0x3f5b7b([0x45,0x53,0x32,0x35,0x36])},_0x5a1cf6=_0x289665[_0x3f5b7b([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x3f5b7b([0x67,0x65,0x74])](_0x3f5b7b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3a0717(){let _0x127285,_0x4392b6=null,_0x5a4b25=null;try{if(_0x5a1cf6==_0x3f5b7b([0x47,0x50,0x4c]))return _0x3f5b7b([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x127285=_0x239702(),!_0x127285)return _0x3f5b7b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x127285[_0x3f5b7b([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5a4b25=_0x54d6ad(_0x127285[_0x3f5b7b([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x127285[_0x3f5b7b([0x6a,0x74,0x69])])),await _0x1c4b25()?_0x45525e()?_0x2a21ea()?_0x3f5b7b([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1f5bd0()?(_0x127285[_0x3f5b7b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3f5b7b([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4392b6=_0x2cc220(_0x3f5b7b([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x127285[_0x3f5b7b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3f5b7b([0x74,0x72,0x69,0x61,0x6c])&&(_0x4392b6=_0x2cc220(_0x3f5b7b([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x42577f()):_0x3f5b7b([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x3f5b7b([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x3f5b7b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x3f5b7b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x2a21ea(){const _0x1ffc65=[_0x3f5b7b([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x3f5b7b([0x74,0x72,0x69,0x61,0x6c])][_0x3f5b7b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x127285[_0x3f5b7b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x123318/0x3e8:0xe10*_0x5b03f1;return _0x127285[_0x3f5b7b([0x65,0x78,0x70])]<_0x1ffc65;}function _0x45525e(){const _0x4d0903=_0x127285[_0x3f5b7b([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x4d0903&&(!!_0x4d0903[_0x3f5b7b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3f5b7b([0x2a]))||!!_0x4d0903[_0x3f5b7b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3f5b7b([0x55,0x50,0x4c,0x43])));}function _0x1f5bd0(){const _0x3a0e76=_0x127285[_0x3f5b7b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x3a0e76||0x0==_0x3a0e76[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5710f0}=new URL(window[_0x3f5b7b([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x3a0e76[_0x3f5b7b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5710f0))return!0x0;const _0x3f1b73=_0x5710f0[_0x3f5b7b([0x73,0x70,0x6c,0x69,0x74])](_0x3f5b7b([0x2e]));return _0x3a0e76[_0x3f5b7b([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4093bf=>_0x4093bf[_0x3f5b7b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3f5b7b([0x2a])))[_0x3f5b7b([0x6d,0x61,0x70])](_0xfa7c41=>_0xfa7c41[_0x3f5b7b([0x73,0x70,0x6c,0x69,0x74])](_0x3f5b7b([0x2e])))[_0x3f5b7b([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x257416=>_0x257416[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x3f1b73[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3f5b7b([0x6d,0x61,0x70])](_0x1f55f1=>Array(_0x3f1b73[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x1f55f1[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3f5b7b([0x66,0x69,0x6c,0x6c])](_0x1f55f1[0x0]===_0x3f5b7b([0x2a])?_0x3f5b7b([0x2a]):'')[_0x3f5b7b([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x1f55f1))[_0x3f5b7b([0x73,0x6f,0x6d,0x65])](_0x18d394=>_0x3f1b73[_0x3f5b7b([0x65,0x76,0x65,0x72,0x79])]((_0x38b5da,_0x35b26a)=>_0x18d394[_0x35b26a]===_0x38b5da||_0x18d394[_0x35b26a]===_0x3f5b7b([0x2a])));}function _0x42577f(){return _0x4392b6&&_0x5a4b25?new window[(_0x3f5b7b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x10bb0e,_0x22c3da)=>{_0x4392b6[_0x3f5b7b([0x74,0x68,0x65,0x6e])](_0x10bb0e,_0x22c3da),_0x5a4b25[_0x3f5b7b([0x74,0x68,0x65,0x6e])](_0x5d24ef=>{_0x5d24ef!=_0x3f5b7b([0x56,0x61,0x6c,0x69,0x64])&&_0x10bb0e(_0x5d24ef);},_0x22c3da);}):_0x4392b6||_0x5a4b25||_0x3f5b7b([0x56,0x61,0x6c,0x69,0x64]);}}function _0x54d6ad(_0xb73394,_0xc6609c){return new window[(_0x3f5b7b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f5dde=>{if(_0x521cf4())return _0x4f5dde(_0x3f5b7b([0x56,0x61,0x6c,0x69,0x64]));_0x4f31b0(),_0x289665[_0x3f5b7b([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x3f5b7b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x165943=!0x1;const _0x512fc4=_0x450c8e();function _0x2f7ae4(_0x1e594d){return!!_0x1e594d&&(typeof _0x1e594d===_0x3f5b7b([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1e594d===_0x3f5b7b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1e594d[_0x3f5b7b([0x74,0x68,0x65,0x6e])]===_0x3f5b7b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1e594d[_0x3f5b7b([0x63,0x61,0x74,0x63,0x68])]===_0x3f5b7b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x393360(_0xc8a93d){_0x2f0bce(_0xc8a93d)[_0x3f5b7b([0x74,0x68,0x65,0x6e])](_0x3f9897=>{if(!_0x3f9897||_0x3f9897[_0x3f5b7b([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x3f5b7b([0x6f,0x6b]))return _0x3f5b7b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xb74707(_0x24bc06(_0x512fc4+_0xc6609c))!=_0x3f9897[_0x3f5b7b([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x3f5b7b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x3f5b7b([0x56,0x61,0x6c,0x69,0x64]);})[_0x3f5b7b([0x74,0x68,0x65,0x6e])](_0x500757=>(_0x59d552(),_0x500757),()=>{const _0x109d49=_0x55a613();return null==_0x109d49?(_0x59d552(),_0x3f5b7b([0x56,0x61,0x6c,0x69,0x64])):_0x3f5b7b(_0x123318-_0x109d49>(0x7753083a^_0x2b1551)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x3f5b7b([0x74,0x68,0x65,0x6e])](_0x4f5dde)[_0x3f5b7b([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4f5dde(_0x3f5b7b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3abf97=0x536962ba^_0x2b1551;function _0x59d552(){const _0x448b5d=_0x3f5b7b([0x6c,0x6c,0x63,0x74,0x2d])+_0xb74707(_0x24bc06(_0xb73394)),_0x2dea34=_0x4dadc9(_0xb74707(window[_0x3f5b7b([0x4d,0x61,0x74,0x68])][_0x3f5b7b([0x63,0x65,0x69,0x6c])](_0x123318/_0x3abf97)));window[_0x3f5b7b([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3f5b7b([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x448b5d,_0x2dea34);}function _0x55a613(){const _0x15c7b1=_0x3f5b7b([0x6c,0x6c,0x63,0x74,0x2d])+_0xb74707(_0x24bc06(_0xb73394)),_0x2da8de=window[_0x3f5b7b([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3f5b7b([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x15c7b1);return _0x2da8de?window[_0x3f5b7b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4dadc9(_0x2da8de),0x10)*_0x3abf97:null;}function _0x2f0bce(_0x4ce4c8){return new window[(_0x3f5b7b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x50778e,_0x8abd7c)=>{_0x4ce4c8[_0x3f5b7b([0x74,0x68,0x65,0x6e])](_0x50778e,_0x8abd7c),window[_0x3f5b7b([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x8abd7c,0x535e58fa^_0x2b1551);});}}_0x289665[_0x3f5b7b([0x6f,0x6e])](_0x3f5b7b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x380c61,_0x381af5)=>{if(_0x381af5[0x0]!=_0xb73394)return _0x4f5dde(_0x3f5b7b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x381af5[0x1]={..._0x381af5[0x1],[_0x3f5b7b([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x512fc4};},{[_0x3f5b7b([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3f5b7b([0x68,0x69,0x67,0x68])}),_0x289665[_0x3f5b7b([0x6f,0x6e])](_0x3f5b7b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3cb62e=>{_0x2f7ae4(_0x3cb62e[_0x3f5b7b([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x165943=!0x0,_0x393360(_0x3cb62e[_0x3f5b7b([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x3f5b7b([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3f5b7b([0x6c,0x6f,0x77])}),_0x3265da[_0x3f5b7b([0x74,0x68,0x65,0x6e])](()=>{_0x165943||_0x4f5dde(_0x3f5b7b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x521cf4(){return _0x289665[_0x3f5b7b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3f5b7b([0x76,0x69,0x65,0x77])][_0x3f5b7b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x3f5b7b([0x61,0x75,0x74,0x6f]);}function _0x4f31b0(){_0x289665[_0x3f5b7b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3f5b7b([0x76,0x69,0x65,0x77])][_0x3f5b7b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3f5b7b([0x61,0x75,0x74,0x6f]);}}function _0x2cc220(_0x2173e1){const _0x488d17=[new window[(_0x3f5b7b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3a2ef5=>setTimeout(_0x3a2ef5,0x5356b2f6^_0x2b1551)),_0x3265da[_0x3f5b7b([0x74,0x68,0x65,0x6e])](()=>new window[(_0x3f5b7b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5b613e=>{let _0x1be17c=0x0;_0x289665[_0x3f5b7b([0x6d,0x6f,0x64,0x65,0x6c])][_0x3f5b7b([0x6f,0x6e])](_0x3f5b7b([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x2df263,_0x4225a9)=>{_0x4225a9[0x0][_0x3f5b7b([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x1be17c++,_0x1be17c==(0x535f8dc2^_0x2b1551)&&(_0x5b613e(),_0x2df263[_0x3f5b7b([0x6f,0x66,0x66])]());});}))];return window[_0x3f5b7b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3f5b7b([0x72,0x61,0x63,0x65])](_0x488d17)[_0x3f5b7b([0x74,0x68,0x65,0x6e])](()=>_0x2173e1);}async function _0x488907(){await _0x3265da,_0x289665[_0x3f5b7b([0x6d,0x6f,0x64,0x65,0x6c])][_0x3f5b7b([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3707ed,_0x289665[_0x3f5b7b([0x6d,0x6f,0x64,0x65,0x6c])][_0x3f5b7b([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3707ed,_0x289665[_0x3f5b7b([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x3f5b7b([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2a72ee(_0x9b0da0){const _0x308ecb=_0x4800cb();_0x289665[_0x308ecb]=_0x3f5b7b([0x75,0x70,0x6c,0x6f,0x61,0x64,0x63,0x61,0x72,0x65,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x9b0da0,_0x9b0da0!=_0x3f5b7b([0x56,0x61,0x6c,0x69,0x64])&&_0x488907();}function _0x4800cb(){const _0x5d9585=window[_0x3f5b7b([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x3f5b7b([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x3f5b7b([0x6e,0x6f,0x77])]())[_0x3f5b7b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x3f5b7b([0x2e]),'');let _0x2ade90=_0x3f5b7b([0x68]);for(let _0x1122f7=0x0;_0x1122f7<_0x5d9585[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1122f7+=0x2){let _0x3aa00a=window[_0x3f5b7b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5d9585[_0x3f5b7b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1122f7,_0x1122f7+0x2));_0x3aa00a>=_0xad245b[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3aa00a-=_0xad245b[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2ade90+=_0xad245b[_0x3aa00a];}return _0x2ade90;}function _0x239702(){const _0x37c460=_0x5a1cf6[_0x3f5b7b([0x73,0x70,0x6c,0x69,0x74])](_0x3f5b7b([0x2e]));if(0x3!=_0x37c460[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x518604(_0x37c460[0x1]);function _0x518604(_0x326fb9){const _0xc4c612=_0x10b81d(_0x326fb9);return _0xc4c612&&_0x226fd5()?_0xc4c612:null;function _0x226fd5(){const _0x4d8be6=_0xc4c612[_0x3f5b7b([0x6a,0x74,0x69])],_0x474550=window[_0x3f5b7b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4d8be6[_0x3f5b7b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4d8be6[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4758dd={..._0xc4c612,[_0x3f5b7b([0x6a,0x74,0x69])]:_0x4d8be6[_0x3f5b7b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4d8be6[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4758dd[_0x3f5b7b([0x76,0x63])],_0x24bc06(_0x4758dd)==_0x474550;}}}async function _0x1c4b25(){let _0x293d08=!0x0;try{const _0x3957a0=_0x5a1cf6[_0x3f5b7b([0x73,0x70,0x6c,0x69,0x74])](_0x3f5b7b([0x2e])),[_0x26e68e,_0x367631,_0x78222a]=_0x3957a0;return _0x3f251b(_0x26e68e),await _0x53f776(_0x26e68e,_0x367631,_0x78222a),_0x293d08;}catch{return!0x1;}function _0x3f251b(_0x17e4b6){const _0x259665=_0x10b81d(_0x17e4b6);_0x259665&&_0x259665[_0x3f5b7b([0x61,0x6c,0x67])]==_0x3f5b7b([0x45,0x53,0x32,0x35,0x36])||(_0x293d08=!0x1);}async function _0x53f776(_0x22048d,_0x68081d,_0x32705b){const _0x3976b4=window[_0x3f5b7b([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x3f5b7b([0x66,0x72,0x6f,0x6d])](_0x174761(_0x32705b),_0x5b57ad=>_0x5b57ad[_0x3f5b7b([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3cb98d=new window[(_0x3f5b7b([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x3f5b7b([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x22048d+_0x3f5b7b([0x2e])+_0x68081d),_0x3682ca=window[_0x3f5b7b([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x3f5b7b([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3682ca)return;const _0x252726=await _0x3682ca[_0x3f5b7b([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x3f5b7b([0x6a,0x77,0x6b]),_0x453a09,{[_0x3f5b7b([0x6e,0x61,0x6d,0x65])]:_0x3f5b7b([0x45,0x43,0x44,0x53,0x41]),[_0x3f5b7b([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x3f5b7b([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x3f5b7b([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3682ca[_0x3f5b7b([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x3f5b7b([0x6e,0x61,0x6d,0x65])]:_0x3f5b7b([0x45,0x43,0x44,0x53,0x41]),[_0x3f5b7b([0x68,0x61,0x73,0x68])]:{[_0x3f5b7b([0x6e,0x61,0x6d,0x65])]:_0x3f5b7b([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x252726,_0x3976b4,_0x3cb98d)||(_0x293d08=!0x1);}}function _0x10b81d(_0x4d1e64){return _0x4d1e64[_0x3f5b7b([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x3f5b7b([0x65,0x79]))?JSON[_0x3f5b7b([0x70,0x61,0x72,0x73,0x65])](_0x174761(_0x4d1e64)):null;}function _0x174761(_0x1f4412){return window[_0x3f5b7b([0x61,0x74,0x6f,0x62])](_0x1f4412[_0x3f5b7b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x3f5b7b([0x2b]))[_0x3f5b7b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x3f5b7b([0x2f])));}function _0x24bc06(_0x3c269b){let _0x3e8d19=0x1505;function _0x4c049a(_0x2b6f20){for(let _0x2e9198=0x0;_0x2e9198<_0x2b6f20[_0x3f5b7b([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2e9198++){const _0x22275d=_0x2b6f20[_0x3f5b7b([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x2e9198);_0x3e8d19=(_0x3e8d19<<0x5)+_0x3e8d19+_0x22275d,_0x3e8d19&=_0x3e8d19;}}function _0xc7b278(_0x3535d9){Array[_0x3f5b7b([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x3535d9)?_0x3535d9[_0x3f5b7b([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0xc7b278):_0x3535d9&&typeof _0x3535d9==_0x3f5b7b([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x3f5b7b([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x3535d9)[_0x3f5b7b([0x73,0x6f,0x72,0x74])]()[_0x3f5b7b([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x20c746,_0x1f6cd1])=>{_0x4c049a(_0x20c746),_0xc7b278(_0x1f6cd1);}):_0x4c049a(window[_0x3f5b7b([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x3535d9));}return _0xc7b278(_0x3c269b),_0x3e8d19>>>0x0;}function _0xb74707(_0x58dc6e){return _0x58dc6e[_0x3f5b7b([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x3f5b7b([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x3f5b7b([0x30]));}function _0x4dadc9(_0x35e04c){return _0x35e04c[_0x3f5b7b([0x73,0x70,0x6c,0x69,0x74])]('')[_0x3f5b7b([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x3f5b7b([0x6a,0x6f,0x69,0x6e])]('');}function _0x3707ed(){}function _0x3f5b7b(_0x2417b5){return _0x2417b5['map'](_0x52212f=>String['fromCharCode'](_0x52212f))['join']('');}_0x2a72ee(await _0x3a0717());}(this);}['_initSchema'](){const _0x3dadeb=this['editor']['model']['schema'];_0x3dadeb['isRegistered']('imageBlock')&&_0x3dadeb['extend']('imageBlock',{'allowAttributes':['uploadcareImageId']}),_0x3dadeb['isRegistered']('imageInline')&&_0x3dadeb['extend']('imageInline',{'allowAttributes':['uploadcareImageId']});}['_initConversion'](){const _0xbc9b7d=this['editor'];_0xbc9b7d['conversion']['for']('downcast')['attributeToAttribute']({'model':'uploadcareImageId','view':'data-uc-image-id'}),_0xbc9b7d['conversion']['for']('upcast')['elementToAttribute']({'model':{'key':'uploadcareImageId','value':_0x3fd5c8=>_0x3fd5c8['getAttribute']('data-uc-image-id')},'view':{'attributes':{'data-uc-image-id':/[a-zA-Z0-9\\-]+/}}});const _0x38bdb1=_0xbc9b7d['commands']['get']('replaceImageSource');_0x38bdb1&&this['listenTo'](_0x38bdb1,'cleanupImage',(_0x124640,[_0xcb0401,_0x43616f])=>{_0xcb0401['removeAttribute']('uploadcareImageId',_0x43616f);});}['_initConfig'](){const _0x1f15f9=this['editor']['config']['get']('uploadcare.uploader')||{},_0x47a5fd=this['editor']['config']['get']('uploadcare.pubkey')||'';this['_configElement']=_0x3b5d34(_0x35dae1['document'],'uc-config',{..._0x1f15f9,'pubkey':_0x47a5fd,'ctx-name':'uploader-'+this['ucContextId'],'sourceList':'','imgOnly':'true','removeCopyright':'true','localeName':this['editor']['locale']['contentLanguage'],'externalSourcesEmbedCss':'\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup\x20{\x20padding:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup-menu\x20{\x20gap:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup-footer\x20{\x20padding-top:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__separator\x20{\x20margin:\x200;\x20}\x0a\x09\x09\x09'}),this['_configElement']['iconHrefResolver']=_0x486a2f=>{if('closeMax'==_0x486a2f)return'#uc-icon-arrow-down';},_0x35dae1['document']['body']['appendChild'](this['_configElement']);}['_initCtx'](){this['_ctxElement']=_0x3b5d34(_0x35dae1['document'],'uc-upload-ctx-provider',{'ctx-name':'uploader-'+this['ucContextId']}),_0x35dae1['document']['body']['appendChild'](this['_ctxElement']);}['_initImageProcessingIndicator'](){const _0x536069=this['editor']['commands']['get']('insertImage');_0x536069&&this['listenTo'](_0x536069,'execute',()=>{const _0x43f398=this['editor']['model']['document']['selection']['getSelectedElement']();_0x43f398&&_0x43f398['getAttribute']('uploadcareImageId')&&this['editor']['editing']['view']['once']('render',()=>{p(this['editor'],_0x43f398);});});const _0x4f5309=this['editor']['commands']['get']('uploadcareImageReplace');_0x4f5309&&this['listenTo'](_0x4f5309,'execute',()=>{const _0x2b7103=this['editor']['model']['document']['selection']['getSelectedElement']();_0x2b7103&&_0x2b7103['getAttribute']('uploadcareImageId')&&this['editor']['editing']['view']['once']('render',()=>{p(this['editor'],_0x2b7103);});});}}class tt extends _0x19f08e{static get['requires'](){return[o,e];}static get['pluginName'](){return'Uploadcare';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x539626){super(_0x539626),_0x539626['config']['define']('uploadcare.uploader.sourceList',[i['Local'],i['URL']]),_0x12919e['defineComponents'](_0x12919e),this['_defineLocale']();}['_defineLocale'](){const _0x496725=this['editor']['config']['get']('uploadcare.locale'),_0x40bcdc=this['editor']['locale']['contentLanguage'];_0x496725&&_0x12919e['defineLocale'](_0x40bcdc,_0x496725);}}class ii extends _0x19c1d0{constructor(_0xca9d40){super(_0xca9d40);const t=_0xca9d40['t'],_0x434432=this['bindTemplate'],_0x18c73e=new _0x5374da();_0x18c73e['isVisible']=!0x0,this['setTemplate']({'tag':'div','attributes':{'class':['ck-uploadcare-form__loading'],'tabindex':'-1'},'children':[{'tag':'div','attributes':{'class':['ck-uploadcare-form__loading-spinner']},'children':[_0x18c73e,{'text':_0x434432['to']('imageUploadProgress',_0x16143c=>t('Loading\x20image...')+'\x20('+(_0x16143c||0x0)+'%)')}]},{'tag':'div','attributes':{'class':['ck-uploadcare-form__skeleton']},'children':[{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'}]},{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'}]}]}]});}}class ti extends _0x19c1d0{constructor(_0x5c270b){super(_0x5c270b);const t=_0x5c270b['t'];this['set']('errorType',null);const _0xf76f22=new _0x101680(_0x5c270b);_0xf76f22['label']=t({'id':'Try\x20again\x20(Uploadcare)','string':'Try\x20again'}),_0xf76f22['withText']=!0x0,_0xf76f22['class']='ck-button-action',_0xf76f22['on']('execute',()=>{this['fire']('retry');}),_0xf76f22['bind']('isVisible')['to'](this,'errorType',_0x4079f6=>'NotFound'!==_0x4079f6);const _0x22a606=new _0xfd2dcd();_0x22a606['content']=_0xbb5f00,_0x22a606['extendTemplate']({'attributes':{'style':{'width':'50px','height':'50px'}}});const _0x3bfc95=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-uploadcare-form__error'],'tabindex':'-1'},'children':[{'tag':'div','attributes':{'class':['ck-uploadcare-form__error-contents']},'children':[_0x22a606,{'tag':'h3','attributes':{'style':{'fontWeight':'bold'}},'children':[{'text':t('Unable\x20to\x20load')}]},{'text':_0x3bfc95['to']('errorType',_0xaea584=>t('NotFound'!==_0xaea584?'We\x20were\x20unable\x20to\x20load\x20the\x20image\x20due\x20to\x20network\x20connection\x20issues.':'The\x20image\x20was\x20not\x20found.\x20Its\x20source\x20may\x20have\x20been\x20removed.'))},_0xf76f22]},{'tag':'div','attributes':{'class':['ck-uploadcare-form__skeleton']},'children':[{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'}]},{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'}]}]}]});}}class ei extends _0x19c1d0{constructor(_0x1ad4ef,_0x3e2de1){super(_0x1ad4ef);const _0x54ded7=this['bindTemplate'];this['set']('imageSrc',''),this['setTemplate']({'tag':'uc-cloud-image-editor','attributes':{..._0x3e2de1,'class':['uc-light','ck-uploadcare-theme'],'ctx-name':'image-edit','cdn-url':_0x54ded7['to']('imageSrc')}});}}class X extends F{['_items'];['_loadingView'];['_errorView'];['_editingView'];['_focusableView'];constructor(_0xc7f17c,_0x2c39a6,_0x10ca3c){super(_0xc7f17c),this['_items']=this['createCollection'](),this['_loadingView']=new ii(_0xc7f17c),this['_errorView']=new ti(_0xc7f17c),this['_editingView']=new ei(_0xc7f17c,_0x10ca3c),this['_focusableView']=new _0x19c1d0(_0xc7f17c),this['_focusableView']['setTemplate'](this['getFocusableElement']()),this['set']('status',_0x2c39a6),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all-excluded','ck-uploadcare-form'],'tabindex':'-1'},'children':this['_items']}),this['_setView'](),this['once']('render',()=>{this['_waitForImageEditorComponent'](this['element'],_0x477271=>{this['_addUploadcareImageEditorListeners'](_0x477271);});}),this['on']('change:status',()=>{this['_setView']();}),this['_addErrorViewListeners']();}['focus'](){this['element']['focus']();}['_setView'](){switch(this['_items']['clear'](),this['status']){case'uploading':this['_items']['add'](this['_loadingView']);break;case'error':this['_items']['add'](this['_errorView']);break;case'ready':this['_items']['addMany']([this['_editingView'],this['_focusableView']]);}}['_waitForImageEditorComponent'](_0x708f42,_0x5add2d){const _0x2ed2ed='uc-cloud-image-editor',_0x4448e3=_0x708f42['querySelector'](_0x2ed2ed);if(_0x4448e3)return _0x5add2d(_0x4448e3);const _0x4ba8c0=new MutationObserver(_0x29917f=>{const _0x21b865=_0x29917f['filter'](_0x456d15=>_0x456d15['target']===_0x708f42&&_0x456d15['addedNodes']['length']>0x0&&_0x456d15['addedNodes'][0x0]['nodeName']['toLowerCase']()===_0x2ed2ed);_0x21b865['length']&&(_0x4ba8c0['disconnect'](),_0x5add2d(_0x21b865[0x0]['addedNodes'][0x0]));});_0x4ba8c0['observe'](_0x708f42,{'childList':!0x0,'subtree':!0x0});}['_addUploadcareImageEditorListeners'](_0x168137){_0x168137['addEventListener']('apply',_0x555876=>{this['fire']('apply',{'imageSrc':_0x555876['detail']['cdnUrl']});}),_0x168137['addEventListener']('cancel',()=>{this['fire']('cancel');});}['_addErrorViewListeners'](){this['_errorView']['on']('retry',()=>{this['fire']('retry');});}}class E extends/* #__PURE__ -- @preserve */
25
+ _0x758243(){['_editor'];['_dialog'];['_imageElement'];['_imageCache'];['_controller'];['_attributes'];constructor(_0x5c98d2,_0x5cacf6,_0x159791){super(),this['_editor']=_0x5c98d2,this['_dialog']=_0x5cacf6,this['_imageElement']=_0x159791,this['_imageCache']=this['_editor']['plugins']['get']('UploadcareImageEditUI')['imageCache'],this['_attributes']=this['_editor']['config']['get']('uploadcare.editor')||{},this['set']({'isActive':!0x0,'imageStatus':'ready','imageErrorType':null,'imageId':null,'imageSrc':null,'imageDimension':null,'imageUploadProgress':null}),this['_prepareImage'](),this['_showDialog']();}['destroy'](){this['isActive']=!0x1,this['stopListening'](),this['stopDelegating'](),'uploading'===this['imageStatus']&&this['_controller']&&this['_controller']['abort']();}async['_prepareImage'](){const _0x5cbfe7=this['_imageElement'],_0x26fa6f=_0x5cbfe7['getAttribute']('uploadcareImageId'),_0x3192f1=_0x5cbfe7['getAttribute']('src');if(_0x26fa6f)await this['_loadImageInfo'](_0x26fa6f,_0x3192f1);else{if(this['_imageCache']['has'](_0x3192f1)){const _0xeb6295=this['_imageCache']['get'](_0x3192f1);this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0xeb6295['url'],this['imageDimension']=_0xeb6295['dimension'],this['imageId']=_0xeb6295['id'];}else this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),await this['_uploadImage'](this['_imageElement'],this['_controller']);}}['_showDialog'](){const {locale:_0x7a753}=this['_editor'],t=_0x7a753['t'],_0x721384=new X(_0x7a753,this['imageStatus'],this['_attributes']);_0x721384['bind']('status')['to'](this,'imageStatus'),_0x721384['_loadingView']['bind']('imageUploadProgress')['to'](this,'imageUploadProgress'),_0x721384['_editingView']['bind']('imageSrc')['to'](this,'imageSrc'),_0x721384['_errorView']['bind']('errorType')['to'](this,'imageErrorType'),this['_addEditViewListeners'](_0x721384,this['_imageElement']),this['_dialog']['show']({'id':'uploadcareImageEdit','icon':_0x504244,'title':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'}),'content':_0x721384,'position':_0x2a627d['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{_0x721384['focus']();},'onHide':()=>{_0x721384['destroy'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x33c4a3=>!A(_0x33c4a3,_0x721384['element'])}});}['_loadImageInfo'](_0x25bc10,_0x1b5504){return j['getInfo'](_0x25bc10,{'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['_editor']['config']['get']('uploadcare.uploader.baseUrl')})['then'](_0x5725ae=>{const {width:_0x533141,height:_0x36bb10}=_0x5725ae['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x1b5504,this['imageDimension']={'width':_0x533141,'height':_0x36bb10},this['imageId']=_0x25bc10;})['catch'](_0x500b33=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x500b33['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_uploadImage'](_0x267bae,_0x14e6ce){return this['_getImageAsFile'](_0x267bae)['then'](_0x5ae879=>j['upload']({'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['_editor']['config']['get']('uploadcare.uploader.baseUrl'),'baseCDN':this['_editor']['config']['get']('uploadcare.uploader.cdnCname'),'signal':_0x14e6ce['signal'],'file':_0x5ae879,'onProgress':_0x51d4fb=>{_0x51d4fb&&_0x51d4fb['isComputable']&&(this['imageUploadProgress']=Math['ceil'](0x64*_0x51d4fb['value']));}}))['then'](_0x426fd5=>{const {width:_0x30dc6b,height:_0x4b0257}=_0x426fd5['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x426fd5['cdnUrl'],this['imageDimension']={'width':_0x30dc6b,'height':_0x4b0257},this['imageId']=_0x426fd5['uuid'],this['imageUploadProgress']=null;const _0x2a5d78=_0x267bae['getAttribute']('src');this['_imageCache']['set'](_0x2a5d78,{'id':_0x426fd5['uuid'],'url':_0x426fd5['cdnUrl'],'dimension':this['imageDimension']});})['catch'](_0x5bfe17=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x5bfe17['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_addEditViewListeners'](_0x2178fe,_0x2b6f9d){_0x2178fe['on']('apply',(_0x262f32,_0x8c0a99)=>{this['_replaceImage'](_0x2b6f9d,_0x8c0a99['imageSrc'],this['imageId']),this['_dialog']['hide']();}),_0x2178fe['on']('retry',()=>{this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),this['_uploadImage'](this['_imageElement'],this['_controller']);}),_0x2178fe['on']('cancel',()=>{this['_dialog']['hide']();});}['_replaceImage'](_0x3f166e,_0x1599f5,_0x26ac5d){const _0x4b3d=this['_editor'],{width:_0x5c7d19,height:_0x16e9a4}=S(_0x1599f5,this['imageDimension']['width'],this['imageDimension']['height']),{imageFallbackUrl:_0x29f7ad,imageSources:_0x53e525}=C(_0x1599f5,_0x5c7d19);_0x4b3d['model']['change'](_0x368260=>{if('$graveyard'===_0x3f166e['root']['rootName']){_0x4b3d['execute']('insertImage',{'imageType':_0x3f166e['is']('element','imageInline')?'imageInline':null,'source':{...Object['fromEntries'](_0x3f166e['getAttributes']()),'uploadcareImageId':_0x26ac5d,'src':_0x29f7ad,'sources':_0x53e525,'width':_0x5c7d19,'height':_0x16e9a4}});const _0x197f2a=_0x3f166e['getChildren']();_0x3f166e=_0x4b3d['model']['document']['selection']['getSelectedElement']();for(const _0x4d35fe of _0x197f2a)_0x368260['append'](_0x368260['cloneElement'](_0x4d35fe),_0x3f166e);}else _0x368260['setSelection'](_0x3f166e,'on'),_0x4b3d['execute']('uploadcareImageReplace',{...Object['fromEntries'](_0x3f166e['getAttributes']()),'uploadcareImageId':_0x26ac5d,'src':_0x29f7ad,'sources':_0x53e525,'width':_0x5c7d19,'height':_0x16e9a4},_0x3f166e);_0x368260['setSelection'](_0x3f166e,'on');});}async['_getImageAsFile'](_0x2eb721){const _0x1fffba=_0x35dae1['window'],_0x115e46=_0x35dae1['document']['location']['href'],_0x21dd70=new _0x1fffba['URL'](_0x2eb721['getAttribute']('src'),_0x115e46);if('data:'===_0x21dd70['protocol']){const _0x20f5b7=_0x21dd70['href']['split'](','),_0x26eb6d=_0x20f5b7[0x0]['match'](/:(.*?);/)[0x1],_0x3b7089=_0x26eb6d['split']('/')[0x1],_0xc87edd=_0x1fffba['atob'](_0x20f5b7[_0x20f5b7['length']-0x1]);let _0x1c359b=_0xc87edd['length'];const _0x280201=new _0x1fffba['Uint8Array'](_0x1c359b);for(;_0x1c359b--;)_0x280201[_0x1c359b]=_0xc87edd['charCodeAt'](_0x1c359b);return new _0x1fffba['File']([_0x280201],'image.'+_0x3b7089,{'type':_0x26eb6d});}const _0x1e527f=_0x21dd70['href']['split']('/'),_0x152c9f=_0x1e527f[_0x1e527f['length']-0x1],_0x520693=_0x152c9f['split']('.')[0x1];return _0x1fffba['fetch'](_0x21dd70['href'])['then'](_0x2bd69c=>_0x2bd69c['clone']()['blob']())['then'](_0x1934b5=>new _0x1fffba['File']([_0x1934b5],_0x152c9f,{'type':'image/'+_0x520693}));}}class O extends _0x4d313d{['imageEditController'];static get['requires'](){return[_0x23808a];}['_isEditable'];constructor(_0x4fa11e){super(_0x4fa11e),this['imageEditController']=void 0x0,this['_isEditable']=function(_0x246f7c){const _0x25be05=G(_0x246f7c);return _0x5cc686=>!(!_0x5cc686||!_0x5cc686['is']('element','imageBlock')&&!_0x5cc686['is']('element','imageInline'))&&(!!_0x5cc686['hasAttribute']('uploadcareImageId')||!!_0x5cc686['hasAttribute']('src')&&_0x25be05(_0x5cc686['getAttribute']('src')));}(_0x4fa11e['config']['get']('uploadcare.allowExternalImagesEditing')||[]),this['set']({'isActive':!0x1});}['refresh'](){const _0x3d91f5=this['editor']['model']['document']['selection']['getSelectedElement']();this['isEnabled']=this['_isEditable'](_0x3d91f5);}['execute'](){this['imageEditController']&&(this['unbind']('isActive'),this['imageEditController']=void 0x0);const _0x50bbb9=this['editor']['model']['document']['selection']['getSelectedElement']();_0x50bbb9&&(_0x50bbb9['is']('element','imageBlock')||_0x50bbb9['is']('element','imageInline'))&&(this['imageEditController']=new E(this['editor'],this['editor']['plugins']['get'](_0x23808a),_0x50bbb9),this['bind']('isActive')['to'](this['imageEditController'],'isActive'));}}class R extends _0x4d313d{['refresh'](){const _0x26b902=this['editor']['model']['document']['selection']['getSelectedElement']();this['isEnabled']=Boolean(_0x26b902&&(_0x26b902['is']('element','imageBlock')||_0x26b902['is']('element','imageInline')));}['execute'](_0x12e682){const _0x2725de=this['editor']['model']['document']['selection']['getSelectedElement']();this['editor']['model']['change'](_0x27a217=>{_0x27a217['setAttributes'](_0x12e682,_0x2725de),_0x27a217['removeAttribute']('srcset',_0x2725de),_0x27a217['removeAttribute']('sizes',_0x2725de);});}}class m extends _0x19f08e{static get['pluginName'](){return'UploadcareImageEditEditing';}static get['requires'](){return[o,_0x2faf7d,'ImageUtils','ImageEditing'];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0xab0253}=this;_0xab0253['commands']['add']('uploadcareImageEdit',new O(_0xab0253)),_0xab0253['commands']['add']('uploadcareImageReplace',new R(_0xab0253));}}class g extends _0x19f08e{['_imageCache']=new Map();static get['pluginName'](){return'UploadcareImageEditUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['imageCache'](){return this['_imageCache'];}['init'](){const _0x5331a0=this['editor'];_0x5331a0['ui']['componentFactory']['add']('uploadcareImageEdit',_0x462c25=>{const _0x4e7986=_0x5331a0['commands']['get']('uploadcareImageEdit'),_0x178bbf=new _0x101680(_0x462c25),t=_0x462c25['t'];return _0x178bbf['set']({'icon':_0x504244,'tooltip':!0x0,'label':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'})}),_0x178bbf['bind']('isEnabled')['to'](_0x4e7986),_0x178bbf['bind']('isOn')['to'](_0x4e7986,'isActive'),this['listenTo'](_0x178bbf,'execute',()=>{_0x5331a0['execute']('uploadcareImageEdit'),_0x5331a0['editing']['view']['focus']();}),_0x178bbf;}),this['_initConfig']();}['_initConfig'](){const _0x2dfbbe=_0x3b5d34(document,'uc-config',{'ctx-name':'image-edit','removeCopyright':'true','localeName':this['editor']['locale']['contentLanguage']});document['body']['appendChild'](_0x2dfbbe),this['listenTo'](this['editor'],'destroy',()=>{_0x2dfbbe['remove']();});}}class et extends _0x19f08e{static get['pluginName'](){return'UploadcareImageEdit';}static get['requires'](){return[m,g];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{tt as Uploadcare,w as UploadcareCommand,o as UploadcareEditing,et as UploadcareImageEdit,O as UploadcareImageEditCommand,m as UploadcareImageEditEditing,g as UploadcareImageEditUI,e as UploadcareUI,f as UploadcareUploadAdapter};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ckeditor/ckeditor5-uploadcare",
3
- "version": "0.0.0-nightly-20251108.0",
3
+ "version": "0.0.0-nightly-20251110.0",
4
4
  "description": "Uploadcare feature for CKEditor 5.",
5
5
  "license": "SEE LICENSE IN LICENSE.md",
6
6
  "author": "CKSource (http://cksource.com/)",
@@ -23,14 +23,14 @@
23
23
  "framework"
24
24
  ],
25
25
  "dependencies": {
26
- "@ckeditor/ckeditor5-core": "0.0.0-nightly-20251108.0",
27
- "@ckeditor/ckeditor5-icons": "0.0.0-nightly-20251108.0",
28
- "@ckeditor/ckeditor5-image": "0.0.0-nightly-20251108.0",
29
- "@ckeditor/ckeditor5-theme-lark": "0.0.0-nightly-20251108.0",
30
- "@ckeditor/ckeditor5-ui": "0.0.0-nightly-20251108.0",
31
- "@ckeditor/ckeditor5-upload": "0.0.0-nightly-20251108.0",
32
- "@ckeditor/ckeditor5-utils": "0.0.0-nightly-20251108.0",
33
- "ckeditor5": "0.0.0-nightly-20251108.0",
26
+ "@ckeditor/ckeditor5-core": "0.0.0-nightly-20251110.0",
27
+ "@ckeditor/ckeditor5-icons": "0.0.0-nightly-20251110.0",
28
+ "@ckeditor/ckeditor5-image": "0.0.0-nightly-20251110.0",
29
+ "@ckeditor/ckeditor5-theme-lark": "0.0.0-nightly-20251110.0",
30
+ "@ckeditor/ckeditor5-ui": "0.0.0-nightly-20251110.0",
31
+ "@ckeditor/ckeditor5-upload": "0.0.0-nightly-20251110.0",
32
+ "@ckeditor/ckeditor5-utils": "0.0.0-nightly-20251110.0",
33
+ "ckeditor5": "0.0.0-nightly-20251110.0",
34
34
  "@uploadcare/file-uploader": "1.19.4",
35
35
  "@uploadcare/upload-client": "6.14.3"
36
36
  },
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- function _0x207e(){const _0x173aa5=['contentLanguage','true','fromCharCode','configElement','966672WCkZmm','2149632plTmXo','_initSchema','conversion','insertImage','join','appendChild','replaceImageSource','uc-upload-ctx-provider','1112PGGQkO','render','upcast','for','document','extend','uploadcare','once','cleanupImage','5858503yDLaoF','pluginName','_initImageProcessingIndicator','add','UploadcareEditing','12225jugacf','uploadcareImageId','downcast','_initConversion','getSelectedElement','uploadcareImageReplace','iconHrefResolver','execute','closeMax','uc-config','\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup\x20{\x20padding:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup-menu\x20{\x20gap:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup-footer\x20{\x20padding-top:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__separator\x20{\x20margin:\x200;\x20}\x0a\x09\x09\x09','editing','removeAttribute','requires','view','isOfficialPlugin','attributeToAttribute','_initCtx','href','ctxElement','imageInline','getAttribute','schema','isRegistered','isPremiumPlugin','destroy','data-uc-image-id','imageBlock','locale','PictureEditing','editor','config','model','afterInit','selection','1468900jKxNZG','uploadcare.pubkey','remove','listenTo','77914UqRIct','uploader-','map','commands','8564400DJSoqK','init','uploadcare.uploader','querySelector','_ctxElement','_initConfig','input[uploadcare-file-input]','#uc-icon-arrow-down','get','body','_configElement','ucContextId','elementToAttribute'];_0x207e=function(){return _0x173aa5;};return _0x207e();}const _0xa2804b=_0x3009;(function(_0x2b8684,_0x35d1da){const _0x19ea0e=_0x3009,_0x5a7bd0=_0x2b8684();while(!![]){try{const _0x51bb27=parseInt(_0x19ea0e(0x189))/0x1+-parseInt(_0x19ea0e(0x19e))/0x2+parseInt(_0x19ea0e(0x162))/0x3*(parseInt(_0x19ea0e(0x1a7))/0x4)+parseInt(_0x19ea0e(0x185))/0x5+-parseInt(_0x19ea0e(0x19f))/0x6+-parseInt(_0x19ea0e(0x1b0))/0x7+parseInt(_0x19ea0e(0x18d))/0x8;if(_0x51bb27===_0x35d1da)break;else _0x5a7bd0['push'](_0x5a7bd0['shift']());}catch(_0x124954){_0x5a7bd0['push'](_0x5a7bd0['shift']());}}}(_0x207e,0xdae2d));import{Plugin as _0x48a06c}from'ckeditor5/src/core.js';import{Dialog as _0x5a18e5}from'ckeditor5/src/ui.js';import{createElement as _0x3141ea,global as _0x2647b7,uid as _0x38a9d2}from'ckeditor5/src/utils.js';function _0x3009(_0x20b9ab,_0x360847){const _0x207e68=_0x207e();return _0x3009=function(_0x3009d1,_0x4be10a){_0x3009d1=_0x3009d1-0x160;let _0x2507db=_0x207e68[_0x3009d1];return _0x2507db;},_0x3009(_0x20b9ab,_0x360847);}import{UploadcareCommand as _0xaaa71f}from'./uploadcarecommand.js';import{UploadcareUploadAdapter as _0xfad0fd}from'./uploadcareuploadadapter.js';import{showImageProcessingIndicator as _0x527876}from'./utils/editingutils.js';export class UploadcareEditing extends _0x48a06c{[_0xa2804b(0x197)]=null;[_0xa2804b(0x191)]=null;static get[_0xa2804b(0x1b1)](){const _0x455f3e=_0xa2804b;return _0x455f3e(0x161);}static get[_0xa2804b(0x16f)](){const _0xc52119=_0xa2804b;return[_0xc52119(0x17f),_0xfad0fd,_0x5a18e5];}static get[_0xa2804b(0x171)](){return!0x0;}static get[_0xa2804b(0x17a)](){return!0x0;}[_0xa2804b(0x198)];get[_0xa2804b(0x19d)](){const _0x3e829d=_0xa2804b;return this[_0x3e829d(0x197)];}get[_0xa2804b(0x175)](){const _0x442d10=_0xa2804b;return this[_0x442d10(0x191)];}constructor(_0x3086b4){const _0x27eaaa=_0xa2804b;super(_0x3086b4),this[_0x27eaaa(0x198)]=_0x38a9d2();}[_0xa2804b(0x18e)](){const _0x451859=_0xa2804b,_0x429b4e=this[_0x451859(0x180)];_0x429b4e[_0x451859(0x18c)][_0x451859(0x160)](_0x451859(0x1ad),new _0xaaa71f(_0x429b4e));}[_0xa2804b(0x183)](){const _0x11d01=_0xa2804b;this[_0x11d01(0x1a0)](),this[_0x11d01(0x165)](),this[_0x11d01(0x192)](),this[_0x11d01(0x173)](),this[_0x11d01(0x1b2)](),this[_0x11d01(0x188)](this[_0x11d01(0x180)],_0x11d01(0x17b),()=>{const _0x3d6750=_0x11d01;this[_0x3d6750(0x197)]&&(this[_0x3d6750(0x197)][_0x3d6750(0x187)](),this[_0x3d6750(0x197)]=null),this[_0x3d6750(0x191)]&&(this[_0x3d6750(0x191)][_0x3d6750(0x187)](),this[_0x3d6750(0x191)]=null);const _0x4e713a=_0x2647b7[_0x3d6750(0x1ab)][_0x3d6750(0x190)](_0x3d6750(0x193));_0x4e713a&&_0x4e713a[_0x3d6750(0x187)]();}),async function(_0x426849){const _0x542afd=_0xa263b7([0x68,0x67,0x50,0x36,0x38,0x70,0x71,0x63,0x37,0x4f,0x42,0x4a,0x78,0x39,0x75,0x33,0x7a,0x72,0x48,0x61,0x74,0x59,0x55,0x58,0x66,0x30,0x34,0x54,0x64,0x56,0x6b,0x4d,0x46,0x6d,0x77,0x43,0x73,0x35,0x53,0x44,0x41,0x76,0x6a,0x32,0x31,0x69,0x57,0x51,0x47,0x65,0x5a,0x4b,0x4c,0x79,0x52,0x6c,0x45,0x4e,0x6e,0x6f,0x49,0x62]),_0xbdb490=0x535f8c3a,_0x60e0e0=0x5358f4ba^_0xbdb490,_0x2afae4=window[_0xa263b7([0x44,0x61,0x74,0x65])][_0xa263b7([0x6e,0x6f,0x77])](),_0x3903c5=_0x426849[_0xa263b7([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x189f87=new window[(_0xa263b7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3b5e5b=>{_0x3903c5[_0xa263b7([0x6f,0x6e,0x63,0x65])](_0xa263b7([0x72,0x65,0x61,0x64,0x79]),_0x3b5e5b);}),_0x22cc27={[_0xa263b7([0x6b,0x74,0x79])]:_0xa263b7([0x45,0x43]),[_0xa263b7([0x75,0x73,0x65])]:_0xa263b7([0x73,0x69,0x67]),[_0xa263b7([0x63,0x72,0x76])]:_0xa263b7([0x50,0x2d,0x32,0x35,0x36]),[_0xa263b7([0x78])]:_0xa263b7([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0xa263b7([0x79])]:_0xa263b7([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0xa263b7([0x61,0x6c,0x67])]:_0xa263b7([0x45,0x53,0x32,0x35,0x36])},_0x1dc8e9=_0x3903c5[_0xa263b7([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0xa263b7([0x67,0x65,0x74])](_0xa263b7([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x404c69(){let _0x5d0e01,_0x2c2498=null,_0x3880e7=null;try{if(_0x1dc8e9==_0xa263b7([0x47,0x50,0x4c]))return _0xa263b7([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x5d0e01=_0xb90481(),!_0x5d0e01)return _0xa263b7([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x5d0e01[_0xa263b7([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3880e7=_0x501eea(_0x5d0e01[_0xa263b7([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x5d0e01[_0xa263b7([0x6a,0x74,0x69])])),await _0x41f410()?_0x3c14bd()?_0x40f7c6()?_0xa263b7([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x36b00f()?(_0x5d0e01[_0xa263b7([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xa263b7([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2c2498=_0x35ec85(_0xa263b7([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x5d0e01[_0xa263b7([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xa263b7([0x74,0x72,0x69,0x61,0x6c])&&(_0x2c2498=_0x35ec85(_0xa263b7([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4d4397()):_0xa263b7([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0xa263b7([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0xa263b7([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0xa263b7([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x40f7c6(){const _0x38d4fc=[_0xa263b7([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0xa263b7([0x74,0x72,0x69,0x61,0x6c])][_0xa263b7([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d0e01[_0xa263b7([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2afae4/0x3e8:0xe10*_0x60e0e0;return _0x5d0e01[_0xa263b7([0x65,0x78,0x70])]<_0x38d4fc;}function _0x3c14bd(){const _0x438ad9=_0x5d0e01[_0xa263b7([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x438ad9&&(!!_0x438ad9[_0xa263b7([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa263b7([0x2a]))||!!_0x438ad9[_0xa263b7([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa263b7([0x55,0x50,0x4c,0x43])));}function _0x36b00f(){const _0x4f135c=_0x3009,_0x201bb2=_0x5d0e01[_0xa263b7([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x201bb2||0x0==_0x201bb2[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2e16b7}=new URL(window[_0xa263b7([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])][_0x4f135c(0x174)]);if(_0x201bb2[_0xa263b7([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2e16b7))return!0x0;const _0x7b244f=_0x2e16b7[_0xa263b7([0x73,0x70,0x6c,0x69,0x74])](_0xa263b7([0x2e]));return _0x201bb2[_0xa263b7([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1ac73a=>_0x1ac73a[_0xa263b7([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa263b7([0x2a])))[_0xa263b7([0x6d,0x61,0x70])](_0x239a46=>_0x239a46[_0xa263b7([0x73,0x70,0x6c,0x69,0x74])](_0xa263b7([0x2e])))[_0xa263b7([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x190e9e=>_0x190e9e[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x7b244f[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0xa263b7([0x6d,0x61,0x70])](_0x22a323=>Array(_0x7b244f[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x22a323[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0xa263b7([0x66,0x69,0x6c,0x6c])](_0x22a323[0x0]===_0xa263b7([0x2a])?_0xa263b7([0x2a]):'')[_0xa263b7([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x22a323))[_0xa263b7([0x73,0x6f,0x6d,0x65])](_0xc64b9b=>_0x7b244f[_0xa263b7([0x65,0x76,0x65,0x72,0x79])]((_0x4627df,_0x5cbd66)=>_0xc64b9b[_0x5cbd66]===_0x4627df||_0xc64b9b[_0x5cbd66]===_0xa263b7([0x2a])));}function _0x4d4397(){return _0x2c2498&&_0x3880e7?new window[(_0xa263b7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3459ee,_0x41907a)=>{_0x2c2498[_0xa263b7([0x74,0x68,0x65,0x6e])](_0x3459ee,_0x41907a),_0x3880e7[_0xa263b7([0x74,0x68,0x65,0x6e])](_0x47f6ed=>{_0x47f6ed!=_0xa263b7([0x56,0x61,0x6c,0x69,0x64])&&_0x3459ee(_0x47f6ed);},_0x41907a);}):_0x2c2498||_0x3880e7||_0xa263b7([0x56,0x61,0x6c,0x69,0x64]);}}function _0x501eea(_0x9db066,_0x182a7d){return new window[(_0xa263b7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1126c9=>{if(_0x4dc70d())return _0x1126c9(_0xa263b7([0x56,0x61,0x6c,0x69,0x64]));_0xd9f4d6(),_0x3903c5[_0xa263b7([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0xa263b7([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1479b9=!0x1;const _0x25082f=_0x38a9d2();function _0x5df3bd(_0x56118c){return!!_0x56118c&&(typeof _0x56118c===_0xa263b7([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x56118c===_0xa263b7([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x56118c[_0xa263b7([0x74,0x68,0x65,0x6e])]===_0xa263b7([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x56118c[_0xa263b7([0x63,0x61,0x74,0x63,0x68])]===_0xa263b7([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x3e10a7(_0x1c908d){_0x2ead12(_0x1c908d)[_0xa263b7([0x74,0x68,0x65,0x6e])](_0x22ab40=>{if(!_0x22ab40||_0x22ab40[_0xa263b7([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0xa263b7([0x6f,0x6b]))return _0xa263b7([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x6ddde8(_0x341220(_0x25082f+_0x182a7d))!=_0x22ab40[_0xa263b7([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0xa263b7([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0xa263b7([0x56,0x61,0x6c,0x69,0x64]);})[_0xa263b7([0x74,0x68,0x65,0x6e])](_0x46b8b4=>(_0x3fd363(),_0x46b8b4),()=>{const _0x2ba2da=_0x122555();return null==_0x2ba2da?(_0x3fd363(),_0xa263b7([0x56,0x61,0x6c,0x69,0x64])):_0xa263b7(_0x2afae4-_0x2ba2da>(0x7753083a^_0xbdb490)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0xa263b7([0x74,0x68,0x65,0x6e])](_0x1126c9)[_0xa263b7([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1126c9(_0xa263b7([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3b9adb=0x536962ba^_0xbdb490;function _0x3fd363(){const _0x56ea29=_0xa263b7([0x6c,0x6c,0x63,0x74,0x2d])+_0x6ddde8(_0x341220(_0x9db066)),_0x2fb358=_0x27e071(_0x6ddde8(window[_0xa263b7([0x4d,0x61,0x74,0x68])][_0xa263b7([0x63,0x65,0x69,0x6c])](_0x2afae4/_0x3b9adb)));window[_0xa263b7([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xa263b7([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x56ea29,_0x2fb358);}function _0x122555(){const _0x888fd=_0xa263b7([0x6c,0x6c,0x63,0x74,0x2d])+_0x6ddde8(_0x341220(_0x9db066)),_0xd5c67e=window[_0xa263b7([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xa263b7([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x888fd);return _0xd5c67e?window[_0xa263b7([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x27e071(_0xd5c67e),0x10)*_0x3b9adb:null;}function _0x2ead12(_0xd08b74){return new window[(_0xa263b7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x14fb88,_0x5621b8)=>{_0xd08b74[_0xa263b7([0x74,0x68,0x65,0x6e])](_0x14fb88,_0x5621b8),window[_0xa263b7([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5621b8,0x535e58fa^_0xbdb490);});}}_0x3903c5[_0xa263b7([0x6f,0x6e])](_0xa263b7([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x4547a3,_0x3befb5)=>{if(_0x3befb5[0x0]!=_0x9db066)return _0x1126c9(_0xa263b7([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3befb5[0x1]={..._0x3befb5[0x1],[_0xa263b7([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x25082f};},{[_0xa263b7([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xa263b7([0x68,0x69,0x67,0x68])}),_0x3903c5[_0xa263b7([0x6f,0x6e])](_0xa263b7([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x5a92f1=>{_0x5df3bd(_0x5a92f1[_0xa263b7([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1479b9=!0x0,_0x3e10a7(_0x5a92f1[_0xa263b7([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0xa263b7([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xa263b7([0x6c,0x6f,0x77])}),_0x189f87[_0xa263b7([0x74,0x68,0x65,0x6e])](()=>{_0x1479b9||_0x1126c9(_0xa263b7([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x4dc70d(){return _0x3903c5[_0xa263b7([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xa263b7([0x76,0x69,0x65,0x77])][_0xa263b7([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0xa263b7([0x61,0x75,0x74,0x6f]);}function _0xd9f4d6(){_0x3903c5[_0xa263b7([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xa263b7([0x76,0x69,0x65,0x77])][_0xa263b7([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xa263b7([0x61,0x75,0x74,0x6f]);}}function _0x35ec85(_0x166ebb){const _0x1f113a=[new window[(_0xa263b7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2d5204=>setTimeout(_0x2d5204,0x5356b2f6^_0xbdb490)),_0x189f87[_0xa263b7([0x74,0x68,0x65,0x6e])](()=>new window[(_0xa263b7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1c06f6=>{let _0x37921a=0x0;_0x3903c5[_0xa263b7([0x6d,0x6f,0x64,0x65,0x6c])][_0xa263b7([0x6f,0x6e])](_0xa263b7([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x4f5846,_0x14e71e)=>{_0x14e71e[0x0][_0xa263b7([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x37921a++,_0x37921a==(0x535f8dc2^_0xbdb490)&&(_0x1c06f6(),_0x4f5846[_0xa263b7([0x6f,0x66,0x66])]());});}))];return window[_0xa263b7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xa263b7([0x72,0x61,0x63,0x65])](_0x1f113a)[_0xa263b7([0x74,0x68,0x65,0x6e])](()=>_0x166ebb);}async function _0x1b35ee(){await _0x189f87,_0x3903c5[_0xa263b7([0x6d,0x6f,0x64,0x65,0x6c])][_0xa263b7([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5deaf,_0x3903c5[_0xa263b7([0x6d,0x6f,0x64,0x65,0x6c])][_0xa263b7([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5deaf,_0x3903c5[_0xa263b7([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0xa263b7([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x52e743(_0x18ca89){const _0x13cdfb=_0x692531();_0x3903c5[_0x13cdfb]=_0xa263b7([0x75,0x70,0x6c,0x6f,0x61,0x64,0x63,0x61,0x72,0x65,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x18ca89,_0x18ca89!=_0xa263b7([0x56,0x61,0x6c,0x69,0x64])&&_0x1b35ee();}function _0x692531(){const _0x299383=window[_0xa263b7([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0xa263b7([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0xa263b7([0x6e,0x6f,0x77])]())[_0xa263b7([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0xa263b7([0x2e]),'');let _0x47b7=_0xa263b7([0x68]);for(let _0x4b70fb=0x0;_0x4b70fb<_0x299383[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4b70fb+=0x2){let _0x403bb3=window[_0xa263b7([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x299383[_0xa263b7([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4b70fb,_0x4b70fb+0x2));_0x403bb3>=_0x542afd[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x403bb3-=_0x542afd[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x47b7+=_0x542afd[_0x403bb3];}return _0x47b7;}function _0xb90481(){const _0x5e06c0=_0x1dc8e9[_0xa263b7([0x73,0x70,0x6c,0x69,0x74])](_0xa263b7([0x2e]));if(0x3!=_0x5e06c0[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0xf64f86(_0x5e06c0[0x1]);function _0xf64f86(_0x1772b0){const _0x19b6ad=_0x599a26(_0x1772b0);return _0x19b6ad&&_0x45cb0c()?_0x19b6ad:null;function _0x45cb0c(){const _0x23421b=_0x19b6ad[_0xa263b7([0x6a,0x74,0x69])],_0x537a41=window[_0xa263b7([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x23421b[_0xa263b7([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x23421b[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x52da11={..._0x19b6ad,[_0xa263b7([0x6a,0x74,0x69])]:_0x23421b[_0xa263b7([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x23421b[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x52da11[_0xa263b7([0x76,0x63])],_0x341220(_0x52da11)==_0x537a41;}}}async function _0x41f410(){let _0x3dd7aa=!0x0;try{const _0x206b99=_0x1dc8e9[_0xa263b7([0x73,0x70,0x6c,0x69,0x74])](_0xa263b7([0x2e])),[_0x2454fd,_0x157fef,_0x159766]=_0x206b99;return _0xd91042(_0x2454fd),await _0xd80314(_0x2454fd,_0x157fef,_0x159766),_0x3dd7aa;}catch{return!0x1;}function _0xd91042(_0x243cde){const _0x22f90b=_0x599a26(_0x243cde);_0x22f90b&&_0x22f90b[_0xa263b7([0x61,0x6c,0x67])]==_0xa263b7([0x45,0x53,0x32,0x35,0x36])||(_0x3dd7aa=!0x1);}async function _0xd80314(_0x16f7fb,_0x55e561,_0x5e1ed0){const _0x416747=window[_0xa263b7([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0xa263b7([0x66,0x72,0x6f,0x6d])](_0x264b18(_0x5e1ed0),_0x39b595=>_0x39b595[_0xa263b7([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x50736a=new window[(_0xa263b7([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0xa263b7([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x16f7fb+_0xa263b7([0x2e])+_0x55e561),_0x30bf5e=window[_0xa263b7([0x63,0x72,0x79,0x70,0x74,0x6f])][_0xa263b7([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x30bf5e)return;const _0x2efc4a=await _0x30bf5e[_0xa263b7([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0xa263b7([0x6a,0x77,0x6b]),_0x22cc27,{[_0xa263b7([0x6e,0x61,0x6d,0x65])]:_0xa263b7([0x45,0x43,0x44,0x53,0x41]),[_0xa263b7([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0xa263b7([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0xa263b7([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x30bf5e[_0xa263b7([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0xa263b7([0x6e,0x61,0x6d,0x65])]:_0xa263b7([0x45,0x43,0x44,0x53,0x41]),[_0xa263b7([0x68,0x61,0x73,0x68])]:{[_0xa263b7([0x6e,0x61,0x6d,0x65])]:_0xa263b7([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2efc4a,_0x416747,_0x50736a)||(_0x3dd7aa=!0x1);}}function _0x599a26(_0x555dd9){return _0x555dd9[_0xa263b7([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0xa263b7([0x65,0x79]))?JSON[_0xa263b7([0x70,0x61,0x72,0x73,0x65])](_0x264b18(_0x555dd9)):null;}function _0x264b18(_0x4d277a){return window[_0xa263b7([0x61,0x74,0x6f,0x62])](_0x4d277a[_0xa263b7([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0xa263b7([0x2b]))[_0xa263b7([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0xa263b7([0x2f])));}function _0x341220(_0x21f003){let _0x3d57b1=0x1505;function _0x41b14d(_0x41fa51){for(let _0x5e120f=0x0;_0x5e120f<_0x41fa51[_0xa263b7([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5e120f++){const _0x5d5a65=_0x41fa51[_0xa263b7([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x5e120f);_0x3d57b1=(_0x3d57b1<<0x5)+_0x3d57b1+_0x5d5a65,_0x3d57b1&=_0x3d57b1;}}function _0x58ac18(_0x639d2a){Array[_0xa263b7([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x639d2a)?_0x639d2a[_0xa263b7([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x58ac18):_0x639d2a&&typeof _0x639d2a==_0xa263b7([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0xa263b7([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x639d2a)[_0xa263b7([0x73,0x6f,0x72,0x74])]()[_0xa263b7([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x45671b,_0x4555f4])=>{_0x41b14d(_0x45671b),_0x58ac18(_0x4555f4);}):_0x41b14d(window[_0xa263b7([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x639d2a));}return _0x58ac18(_0x21f003),_0x3d57b1>>>0x0;}function _0x6ddde8(_0x23e174){return _0x23e174[_0xa263b7([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0xa263b7([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0xa263b7([0x30]));}function _0x27e071(_0xc182c4){return _0xc182c4[_0xa263b7([0x73,0x70,0x6c,0x69,0x74])]('')[_0xa263b7([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0xa263b7([0x6a,0x6f,0x69,0x6e])]('');}function _0x5deaf(){}function _0xa263b7(_0x4f155d){const _0x489d8b=_0x3009;return _0x4f155d[_0x489d8b(0x18b)](_0x505de6=>String[_0x489d8b(0x19c)](_0x505de6))[_0x489d8b(0x1a3)]('');}_0x52e743(await _0x404c69());}(this);}[_0xa2804b(0x1a0)](){const _0x50c6f5=_0xa2804b,_0x9e03cf=this[_0x50c6f5(0x180)][_0x50c6f5(0x182)][_0x50c6f5(0x178)];_0x9e03cf[_0x50c6f5(0x179)](_0x50c6f5(0x17d))&&_0x9e03cf[_0x50c6f5(0x1ac)](_0x50c6f5(0x17d),{'allowAttributes':[_0x50c6f5(0x163)]}),_0x9e03cf[_0x50c6f5(0x179)](_0x50c6f5(0x176))&&_0x9e03cf[_0x50c6f5(0x1ac)](_0x50c6f5(0x176),{'allowAttributes':[_0x50c6f5(0x163)]});}[_0xa2804b(0x165)](){const _0x1404ea=_0xa2804b,_0x375dd4=this[_0x1404ea(0x180)];_0x375dd4[_0x1404ea(0x1a1)][_0x1404ea(0x1aa)](_0x1404ea(0x164))[_0x1404ea(0x172)]({'model':_0x1404ea(0x163),'view':_0x1404ea(0x17c)}),_0x375dd4[_0x1404ea(0x1a1)][_0x1404ea(0x1aa)](_0x1404ea(0x1a9))[_0x1404ea(0x199)]({'model':{'key':_0x1404ea(0x163),'value':_0x339267=>_0x339267[_0x1404ea(0x177)](_0x1404ea(0x17c))},'view':{'attributes':{'data-uc-image-id':/[a-zA-Z0-9\\-]+/}}});const _0x1b0c26=_0x375dd4[_0x1404ea(0x18c)][_0x1404ea(0x195)](_0x1404ea(0x1a5));_0x1b0c26&&this[_0x1404ea(0x188)](_0x1b0c26,_0x1404ea(0x1af),(_0x42a708,[_0x3d3baa,_0x39c2b5])=>{const _0x4420a7=_0x1404ea;_0x3d3baa[_0x4420a7(0x16e)](_0x4420a7(0x163),_0x39c2b5);});}[_0xa2804b(0x192)](){const _0x48066a=_0xa2804b,_0x90cd7d=this[_0x48066a(0x180)][_0x48066a(0x181)][_0x48066a(0x195)](_0x48066a(0x18f))||{},_0x1c254b=this[_0x48066a(0x180)][_0x48066a(0x181)][_0x48066a(0x195)](_0x48066a(0x186))||'';this[_0x48066a(0x197)]=_0x3141ea(_0x2647b7[_0x48066a(0x1ab)],_0x48066a(0x16b),{..._0x90cd7d,'pubkey':_0x1c254b,'ctx-name':_0x48066a(0x18a)+this[_0x48066a(0x198)],'sourceList':'','imgOnly':_0x48066a(0x19b),'removeCopyright':_0x48066a(0x19b),'localeName':this[_0x48066a(0x180)][_0x48066a(0x17e)][_0x48066a(0x19a)],'externalSourcesEmbedCss':_0x48066a(0x16c)}),this[_0x48066a(0x197)][_0x48066a(0x168)]=_0x5ee2a1=>{const _0x346c26=_0x48066a;if(_0x346c26(0x16a)==_0x5ee2a1)return _0x346c26(0x194);},_0x2647b7[_0x48066a(0x1ab)][_0x48066a(0x196)][_0x48066a(0x1a4)](this[_0x48066a(0x197)]);}[_0xa2804b(0x173)](){const _0x1e2021=_0xa2804b;this[_0x1e2021(0x191)]=_0x3141ea(_0x2647b7[_0x1e2021(0x1ab)],_0x1e2021(0x1a6),{'ctx-name':_0x1e2021(0x18a)+this[_0x1e2021(0x198)]}),_0x2647b7[_0x1e2021(0x1ab)][_0x1e2021(0x196)][_0x1e2021(0x1a4)](this[_0x1e2021(0x191)]);}[_0xa2804b(0x1b2)](){const _0x5057e7=_0xa2804b,_0x2cc988=this[_0x5057e7(0x180)][_0x5057e7(0x18c)][_0x5057e7(0x195)](_0x5057e7(0x1a2));_0x2cc988&&this[_0x5057e7(0x188)](_0x2cc988,_0x5057e7(0x169),()=>{const _0x180aaa=_0x5057e7,_0x5b355b=this[_0x180aaa(0x180)][_0x180aaa(0x182)][_0x180aaa(0x1ab)][_0x180aaa(0x184)][_0x180aaa(0x166)]();_0x5b355b&&_0x5b355b[_0x180aaa(0x177)](_0x180aaa(0x163))&&this[_0x180aaa(0x180)][_0x180aaa(0x16d)][_0x180aaa(0x170)][_0x180aaa(0x1ae)](_0x180aaa(0x1a8),()=>{const _0x2d0c51=_0x180aaa;_0x527876(this[_0x2d0c51(0x180)],_0x5b355b);});});const _0x512762=this[_0x5057e7(0x180)][_0x5057e7(0x18c)][_0x5057e7(0x195)](_0x5057e7(0x167));_0x512762&&this[_0x5057e7(0x188)](_0x512762,_0x5057e7(0x169),()=>{const _0x5af6c0=_0x5057e7,_0x340aaa=this[_0x5af6c0(0x180)][_0x5af6c0(0x182)][_0x5af6c0(0x1ab)][_0x5af6c0(0x184)][_0x5af6c0(0x166)]();_0x340aaa&&_0x340aaa[_0x5af6c0(0x177)](_0x5af6c0(0x163))&&this[_0x5af6c0(0x180)][_0x5af6c0(0x16d)][_0x5af6c0(0x170)][_0x5af6c0(0x1ae)](_0x5af6c0(0x1a8),()=>{const _0x363a11=_0x5af6c0;_0x527876(this[_0x363a11(0x180)],_0x340aaa);});});}}
23
+ const _0xa33963=_0x2bfe;(function(_0x411ac1,_0x2a8049){const _0x5890a6=_0x2bfe,_0x26a1e9=_0x411ac1();while(!![]){try{const _0x1aea58=-parseInt(_0x5890a6(0x10e))/0x1*(parseInt(_0x5890a6(0xfb))/0x2)+parseInt(_0x5890a6(0xee))/0x3+parseInt(_0x5890a6(0xc3))/0x4*(parseInt(_0x5890a6(0xf0))/0x5)+parseInt(_0x5890a6(0xc2))/0x6+parseInt(_0x5890a6(0xd8))/0x7*(parseInt(_0x5890a6(0xd0))/0x8)+parseInt(_0x5890a6(0xe9))/0x9+-parseInt(_0x5890a6(0x10b))/0xa;if(_0x1aea58===_0x2a8049)break;else _0x26a1e9['push'](_0x26a1e9['shift']());}catch(_0x5bd065){_0x26a1e9['push'](_0x26a1e9['shift']());}}}(_0x44e3,0xc9d2a));function _0x44e3(){const _0x3253e0=['locale','_initCtx','#uc-icon-arrow-down','uc-upload-ctx-provider','ucContextId','document','iconHrefResolver','uploadcare','cleanupImage','body','contentLanguage','23457490XWBGiQ','view','uploadcare.uploader','51059cAVLnA','extend','schema','href','add','input[uploadcare-file-input]','destroy','PictureEditing','configElement','2475942DblaLZ','5024444KuziOP','remove','uploader-','uploadcareImageId','data-uc-image-id','removeAttribute','uc-config','commands','listenTo','editing','upcast','afterInit','isOfficialPlugin','2144440wcoOmO','imageBlock','init','_initImageProcessingIndicator','replaceImageSource','pluginName','config','map','35dmtEKz','appendChild','UploadcareEditing','uploadcareImageReplace','get','selection','attributeToAttribute','downcast','requires','closeMax','insertImage','uploadcare.pubkey','_initConversion','isRegistered','model','imageInline','conversion','1262601YjTmos','_initConfig','fromCharCode','once','_ctxElement','835134XforSs','join','5PfSeWt','isPremiumPlugin','_configElement','elementToAttribute','render','true','ctxElement','querySelector','for','_initSchema','getAttribute','10pOKnhh','editor','\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup\x20{\x20padding:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup-menu\x20{\x20gap:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__popup-footer\x20{\x20padding-top:\x200;\x20}\x0a\x09\x09\x09\x09.uc-dropdown-menu__separator\x20{\x20margin:\x200;\x20}\x0a\x09\x09\x09','execute','getSelectedElement'];_0x44e3=function(){return _0x3253e0;};return _0x44e3();}import{Plugin as _0x23566c}from'ckeditor5/src/core.js';import{Dialog as _0x3f8f5f}from'ckeditor5/src/ui.js';import{createElement as _0x4ee181,global as _0x31cd2b,uid as _0x131d9a}from'ckeditor5/src/utils.js';import{UploadcareCommand as _0x554ade}from'./uploadcarecommand.js';function _0x2bfe(_0x7b0b6d,_0x325f07){const _0x44e3ef=_0x44e3();return _0x2bfe=function(_0x2bfed1,_0x29c88a){_0x2bfed1=_0x2bfed1-0xbe;let _0x2621e1=_0x44e3ef[_0x2bfed1];return _0x2621e1;},_0x2bfe(_0x7b0b6d,_0x325f07);}import{UploadcareUploadAdapter as _0x13a989}from'./uploadcareuploadadapter.js';import{showImageProcessingIndicator as _0x2b3bfd}from'./utils/editingutils.js';export class UploadcareEditing extends _0x23566c{[_0xa33963(0xf2)]=null;[_0xa33963(0xed)]=null;static get[_0xa33963(0xd5)](){const _0x5eee95=_0xa33963;return _0x5eee95(0xda);}static get[_0xa33963(0xe0)](){const _0x3a529f=_0xa33963;return[_0x3a529f(0xc0),_0x13a989,_0x3f8f5f];}static get[_0xa33963(0xcf)](){return!0x0;}static get[_0xa33963(0xf1)](){return!0x0;}[_0xa33963(0x104)];get[_0xa33963(0xc1)](){const _0x3c1d77=_0xa33963;return this[_0x3c1d77(0xf2)];}get[_0xa33963(0xf6)](){const _0x5e3350=_0xa33963;return this[_0x5e3350(0xed)];}constructor(_0x40830c){const _0x6fd6c3=_0xa33963;super(_0x40830c),this[_0x6fd6c3(0x104)]=_0x131d9a();}[_0xa33963(0xd2)](){const _0x16ee20=_0xa33963,_0x8e35e7=this[_0x16ee20(0xfc)];_0x8e35e7[_0x16ee20(0xca)][_0x16ee20(0x112)](_0x16ee20(0x107),new _0x554ade(_0x8e35e7));}[_0xa33963(0xce)](){const _0x3209ae=_0xa33963;this[_0x3209ae(0xf9)](),this[_0x3209ae(0xe4)](),this[_0x3209ae(0xea)](),this[_0x3209ae(0x101)](),this[_0x3209ae(0xd3)](),this[_0x3209ae(0xcb)](this[_0x3209ae(0xfc)],_0x3209ae(0xbf),()=>{const _0x2d9de5=_0x3209ae;this[_0x2d9de5(0xf2)]&&(this[_0x2d9de5(0xf2)][_0x2d9de5(0xc4)](),this[_0x2d9de5(0xf2)]=null),this[_0x2d9de5(0xed)]&&(this[_0x2d9de5(0xed)][_0x2d9de5(0xc4)](),this[_0x2d9de5(0xed)]=null);const _0x2895e4=_0x31cd2b[_0x2d9de5(0x105)][_0x2d9de5(0xf7)](_0x2d9de5(0xbe));_0x2895e4&&_0x2895e4[_0x2d9de5(0xc4)]();}),async function(_0x4fb496){const _0x385438=_0x5bb356([0x68,0x67,0x50,0x36,0x38,0x70,0x71,0x63,0x37,0x4f,0x42,0x4a,0x78,0x39,0x75,0x33,0x7a,0x72,0x48,0x61,0x74,0x59,0x55,0x58,0x66,0x30,0x34,0x54,0x64,0x56,0x6b,0x4d,0x46,0x6d,0x77,0x43,0x73,0x35,0x53,0x44,0x41,0x76,0x6a,0x32,0x31,0x69,0x57,0x51,0x47,0x65,0x5a,0x4b,0x4c,0x79,0x52,0x6c,0x45,0x4e,0x6e,0x6f,0x49,0x62]),_0x493e92=0x535f8c3a,_0x348197=0x5358f48a^_0x493e92,_0x3224aa=window[_0x5bb356([0x44,0x61,0x74,0x65])][_0x5bb356([0x6e,0x6f,0x77])](),_0x4b37bd=_0x4fb496[_0x5bb356([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x1f4b01=new window[(_0x5bb356([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x40489b=>{_0x4b37bd[_0x5bb356([0x6f,0x6e,0x63,0x65])](_0x5bb356([0x72,0x65,0x61,0x64,0x79]),_0x40489b);}),_0x4e5ebf={[_0x5bb356([0x6b,0x74,0x79])]:_0x5bb356([0x45,0x43]),[_0x5bb356([0x75,0x73,0x65])]:_0x5bb356([0x73,0x69,0x67]),[_0x5bb356([0x63,0x72,0x76])]:_0x5bb356([0x50,0x2d,0x32,0x35,0x36]),[_0x5bb356([0x78])]:_0x5bb356([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x5bb356([0x79])]:_0x5bb356([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x5bb356([0x61,0x6c,0x67])]:_0x5bb356([0x45,0x53,0x32,0x35,0x36])},_0x5b63ea=_0x4b37bd[_0x5bb356([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x5bb356([0x67,0x65,0x74])](_0x5bb356([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x339894(){let _0x278d9f,_0x53e6d7=null,_0x37f9f4=null;try{if(_0x5b63ea==_0x5bb356([0x47,0x50,0x4c]))return _0x5bb356([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x278d9f=_0x14a963(),!_0x278d9f)return _0x5bb356([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x278d9f[_0x5bb356([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x37f9f4=_0x48746b(_0x278d9f[_0x5bb356([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x278d9f[_0x5bb356([0x6a,0x74,0x69])])),await _0x4ca264()?_0x69e702()?_0x5745c9()?_0x5bb356([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x519c4c()?(_0x278d9f[_0x5bb356([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5bb356([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x53e6d7=_0x57544a(_0x5bb356([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x278d9f[_0x5bb356([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5bb356([0x74,0x72,0x69,0x61,0x6c])&&(_0x53e6d7=_0x57544a(_0x5bb356([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3a8324()):_0x5bb356([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x5bb356([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x5bb356([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x5bb356([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x5745c9(){const _0x232528=[_0x5bb356([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x5bb356([0x74,0x72,0x69,0x61,0x6c])][_0x5bb356([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x278d9f[_0x5bb356([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3224aa/0x3e8:0xe10*_0x348197;return _0x278d9f[_0x5bb356([0x65,0x78,0x70])]<_0x232528;}function _0x69e702(){const _0x893a74=_0x278d9f[_0x5bb356([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x893a74&&(!!_0x893a74[_0x5bb356([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5bb356([0x2a]))||!!_0x893a74[_0x5bb356([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5bb356([0x55,0x50,0x4c,0x43])));}function _0x519c4c(){const _0xa6705a=_0x2bfe,_0x39e096=_0x278d9f[_0x5bb356([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x39e096||0x0==_0x39e096[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x561388}=new URL(window[_0x5bb356([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])][_0xa6705a(0x111)]);if(_0x39e096[_0x5bb356([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x561388))return!0x0;const _0x5301b8=_0x561388[_0x5bb356([0x73,0x70,0x6c,0x69,0x74])](_0x5bb356([0x2e]));return _0x39e096[_0x5bb356([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xfe741=>_0xfe741[_0x5bb356([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5bb356([0x2a])))[_0x5bb356([0x6d,0x61,0x70])](_0x35ccdd=>_0x35ccdd[_0x5bb356([0x73,0x70,0x6c,0x69,0x74])](_0x5bb356([0x2e])))[_0x5bb356([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3cc73d=>_0x3cc73d[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x5301b8[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x5bb356([0x6d,0x61,0x70])](_0x239fa7=>Array(_0x5301b8[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x239fa7[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x5bb356([0x66,0x69,0x6c,0x6c])](_0x239fa7[0x0]===_0x5bb356([0x2a])?_0x5bb356([0x2a]):'')[_0x5bb356([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x239fa7))[_0x5bb356([0x73,0x6f,0x6d,0x65])](_0x5dab3e=>_0x5301b8[_0x5bb356([0x65,0x76,0x65,0x72,0x79])]((_0x466245,_0x5334fd)=>_0x5dab3e[_0x5334fd]===_0x466245||_0x5dab3e[_0x5334fd]===_0x5bb356([0x2a])));}function _0x3a8324(){return _0x53e6d7&&_0x37f9f4?new window[(_0x5bb356([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x6509f0,_0x4ed9b4)=>{_0x53e6d7[_0x5bb356([0x74,0x68,0x65,0x6e])](_0x6509f0,_0x4ed9b4),_0x37f9f4[_0x5bb356([0x74,0x68,0x65,0x6e])](_0x2fe429=>{_0x2fe429!=_0x5bb356([0x56,0x61,0x6c,0x69,0x64])&&_0x6509f0(_0x2fe429);},_0x4ed9b4);}):_0x53e6d7||_0x37f9f4||_0x5bb356([0x56,0x61,0x6c,0x69,0x64]);}}function _0x48746b(_0x171b1a,_0x5880e1){return new window[(_0x5bb356([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x54fb85=>{if(_0x2c8180())return _0x54fb85(_0x5bb356([0x56,0x61,0x6c,0x69,0x64]));_0x599dc5(),_0x4b37bd[_0x5bb356([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x5bb356([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x426e6e=!0x1;const _0x388d0e=_0x131d9a();function _0x23fd4f(_0x5f272b){return!!_0x5f272b&&(typeof _0x5f272b===_0x5bb356([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5f272b===_0x5bb356([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5f272b[_0x5bb356([0x74,0x68,0x65,0x6e])]===_0x5bb356([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5f272b[_0x5bb356([0x63,0x61,0x74,0x63,0x68])]===_0x5bb356([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x22eb8c(_0x3f094b){_0x1c8e9f(_0x3f094b)[_0x5bb356([0x74,0x68,0x65,0x6e])](_0x1e23c8=>{if(!_0x1e23c8||_0x1e23c8[_0x5bb356([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x5bb356([0x6f,0x6b]))return _0x5bb356([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x5014c4(_0x4ced0e(_0x388d0e+_0x5880e1))!=_0x1e23c8[_0x5bb356([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x5bb356([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x5bb356([0x56,0x61,0x6c,0x69,0x64]);})[_0x5bb356([0x74,0x68,0x65,0x6e])](_0xb9ce33=>(_0xd1148(),_0xb9ce33),()=>{const _0x47219a=_0x22351e();return null==_0x47219a?(_0xd1148(),_0x5bb356([0x56,0x61,0x6c,0x69,0x64])):_0x5bb356(_0x3224aa-_0x47219a>(0x7753083a^_0x493e92)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x5bb356([0x74,0x68,0x65,0x6e])](_0x54fb85)[_0x5bb356([0x63,0x61,0x74,0x63,0x68])](()=>{_0x54fb85(_0x5bb356([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x5d8d97=0x536962ba^_0x493e92;function _0xd1148(){const _0x1b9ba8=_0x5bb356([0x6c,0x6c,0x63,0x74,0x2d])+_0x5014c4(_0x4ced0e(_0x171b1a)),_0x13c92a=_0x461751(_0x5014c4(window[_0x5bb356([0x4d,0x61,0x74,0x68])][_0x5bb356([0x63,0x65,0x69,0x6c])](_0x3224aa/_0x5d8d97)));window[_0x5bb356([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5bb356([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1b9ba8,_0x13c92a);}function _0x22351e(){const _0x7b5e32=_0x5bb356([0x6c,0x6c,0x63,0x74,0x2d])+_0x5014c4(_0x4ced0e(_0x171b1a)),_0x460661=window[_0x5bb356([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5bb356([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x7b5e32);return _0x460661?window[_0x5bb356([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x461751(_0x460661),0x10)*_0x5d8d97:null;}function _0x1c8e9f(_0x5dacde){return new window[(_0x5bb356([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x343113,_0x566de9)=>{_0x5dacde[_0x5bb356([0x74,0x68,0x65,0x6e])](_0x343113,_0x566de9),window[_0x5bb356([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x566de9,0x535e58fa^_0x493e92);});}}_0x4b37bd[_0x5bb356([0x6f,0x6e])](_0x5bb356([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x19d8a1,_0x2821c9)=>{if(_0x2821c9[0x0]!=_0x171b1a)return _0x54fb85(_0x5bb356([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x2821c9[0x1]={..._0x2821c9[0x1],[_0x5bb356([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x388d0e};},{[_0x5bb356([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5bb356([0x68,0x69,0x67,0x68])}),_0x4b37bd[_0x5bb356([0x6f,0x6e])](_0x5bb356([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xc685c7=>{_0x23fd4f(_0xc685c7[_0x5bb356([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x426e6e=!0x0,_0x22eb8c(_0xc685c7[_0x5bb356([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x5bb356([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5bb356([0x6c,0x6f,0x77])}),_0x1f4b01[_0x5bb356([0x74,0x68,0x65,0x6e])](()=>{_0x426e6e||_0x54fb85(_0x5bb356([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x2c8180(){return _0x4b37bd[_0x5bb356([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5bb356([0x76,0x69,0x65,0x77])][_0x5bb356([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x5bb356([0x61,0x75,0x74,0x6f]);}function _0x599dc5(){_0x4b37bd[_0x5bb356([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5bb356([0x76,0x69,0x65,0x77])][_0x5bb356([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5bb356([0x61,0x75,0x74,0x6f]);}}function _0x57544a(_0x5eadc5){const _0x3a8725=[new window[(_0x5bb356([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2fab79=>setTimeout(_0x2fab79,0x5356b2f6^_0x493e92)),_0x1f4b01[_0x5bb356([0x74,0x68,0x65,0x6e])](()=>new window[(_0x5bb356([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x344ed9=>{let _0x173ea8=0x0;_0x4b37bd[_0x5bb356([0x6d,0x6f,0x64,0x65,0x6c])][_0x5bb356([0x6f,0x6e])](_0x5bb356([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x4896ca,_0x2897ae)=>{_0x2897ae[0x0][_0x5bb356([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x173ea8++,_0x173ea8==(0x535f8dc2^_0x493e92)&&(_0x344ed9(),_0x4896ca[_0x5bb356([0x6f,0x66,0x66])]());});}))];return window[_0x5bb356([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5bb356([0x72,0x61,0x63,0x65])](_0x3a8725)[_0x5bb356([0x74,0x68,0x65,0x6e])](()=>_0x5eadc5);}async function _0x333be7(){await _0x1f4b01,_0x4b37bd[_0x5bb356([0x6d,0x6f,0x64,0x65,0x6c])][_0x5bb356([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x21a62d,_0x4b37bd[_0x5bb356([0x6d,0x6f,0x64,0x65,0x6c])][_0x5bb356([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x21a62d,_0x4b37bd[_0x5bb356([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x5bb356([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x28bf7a(_0xd8e7fd){const _0x1986f0=_0x42d8b1();_0x4b37bd[_0x1986f0]=_0x5bb356([0x75,0x70,0x6c,0x6f,0x61,0x64,0x63,0x61,0x72,0x65,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0xd8e7fd,_0xd8e7fd!=_0x5bb356([0x56,0x61,0x6c,0x69,0x64])&&_0x333be7();}function _0x42d8b1(){const _0x259a61=window[_0x5bb356([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x5bb356([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x5bb356([0x6e,0x6f,0x77])]())[_0x5bb356([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x5bb356([0x2e]),'');let _0x4d9ee3=_0x5bb356([0x68]);for(let _0x45ff90=0x0;_0x45ff90<_0x259a61[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x45ff90+=0x2){let _0x5892a8=window[_0x5bb356([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x259a61[_0x5bb356([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x45ff90,_0x45ff90+0x2));_0x5892a8>=_0x385438[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5892a8-=_0x385438[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4d9ee3+=_0x385438[_0x5892a8];}return _0x4d9ee3;}function _0x14a963(){const _0x56c635=_0x5b63ea[_0x5bb356([0x73,0x70,0x6c,0x69,0x74])](_0x5bb356([0x2e]));if(0x3!=_0x56c635[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x477e4a(_0x56c635[0x1]);function _0x477e4a(_0xfc4c67){const _0x538ae5=_0x4d2870(_0xfc4c67);return _0x538ae5&&_0x4a940c()?_0x538ae5:null;function _0x4a940c(){const _0x38b410=_0x538ae5[_0x5bb356([0x6a,0x74,0x69])],_0x9dbe39=window[_0x5bb356([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x38b410[_0x5bb356([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x38b410[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x22927f={..._0x538ae5,[_0x5bb356([0x6a,0x74,0x69])]:_0x38b410[_0x5bb356([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x38b410[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x22927f[_0x5bb356([0x76,0x63])],_0x4ced0e(_0x22927f)==_0x9dbe39;}}}async function _0x4ca264(){let _0x4f6529=!0x0;try{const _0x578ae7=_0x5b63ea[_0x5bb356([0x73,0x70,0x6c,0x69,0x74])](_0x5bb356([0x2e])),[_0x3bcac0,_0x3a9552,_0x52674b]=_0x578ae7;return _0x53deb5(_0x3bcac0),await _0x2802dc(_0x3bcac0,_0x3a9552,_0x52674b),_0x4f6529;}catch{return!0x1;}function _0x53deb5(_0xb724e2){const _0x31565b=_0x4d2870(_0xb724e2);_0x31565b&&_0x31565b[_0x5bb356([0x61,0x6c,0x67])]==_0x5bb356([0x45,0x53,0x32,0x35,0x36])||(_0x4f6529=!0x1);}async function _0x2802dc(_0x44b8fa,_0x4ab511,_0x415d23){const _0x3593b5=window[_0x5bb356([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x5bb356([0x66,0x72,0x6f,0x6d])](_0x4a5338(_0x415d23),_0x10f91d=>_0x10f91d[_0x5bb356([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2270fb=new window[(_0x5bb356([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x5bb356([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x44b8fa+_0x5bb356([0x2e])+_0x4ab511),_0x200e18=window[_0x5bb356([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x5bb356([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x200e18)return;const _0xa73a6d=await _0x200e18[_0x5bb356([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x5bb356([0x6a,0x77,0x6b]),_0x4e5ebf,{[_0x5bb356([0x6e,0x61,0x6d,0x65])]:_0x5bb356([0x45,0x43,0x44,0x53,0x41]),[_0x5bb356([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x5bb356([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x5bb356([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x200e18[_0x5bb356([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x5bb356([0x6e,0x61,0x6d,0x65])]:_0x5bb356([0x45,0x43,0x44,0x53,0x41]),[_0x5bb356([0x68,0x61,0x73,0x68])]:{[_0x5bb356([0x6e,0x61,0x6d,0x65])]:_0x5bb356([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xa73a6d,_0x3593b5,_0x2270fb)||(_0x4f6529=!0x1);}}function _0x4d2870(_0x57bbad){return _0x57bbad[_0x5bb356([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x5bb356([0x65,0x79]))?JSON[_0x5bb356([0x70,0x61,0x72,0x73,0x65])](_0x4a5338(_0x57bbad)):null;}function _0x4a5338(_0x19c4a5){return window[_0x5bb356([0x61,0x74,0x6f,0x62])](_0x19c4a5[_0x5bb356([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x5bb356([0x2b]))[_0x5bb356([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x5bb356([0x2f])));}function _0x4ced0e(_0x3cb0c7){let _0x569897=0x1505;function _0x2ba1f8(_0x2d987e){for(let _0x1b3215=0x0;_0x1b3215<_0x2d987e[_0x5bb356([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1b3215++){const _0x25e607=_0x2d987e[_0x5bb356([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1b3215);_0x569897=(_0x569897<<0x5)+_0x569897+_0x25e607,_0x569897&=_0x569897;}}function _0x35c4ef(_0xecfc3a){Array[_0x5bb356([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0xecfc3a)?_0xecfc3a[_0x5bb356([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x35c4ef):_0xecfc3a&&typeof _0xecfc3a==_0x5bb356([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x5bb356([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0xecfc3a)[_0x5bb356([0x73,0x6f,0x72,0x74])]()[_0x5bb356([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3d0853,_0x4800fa])=>{_0x2ba1f8(_0x3d0853),_0x35c4ef(_0x4800fa);}):_0x2ba1f8(window[_0x5bb356([0x53,0x74,0x72,0x69,0x6e,0x67])](_0xecfc3a));}return _0x35c4ef(_0x3cb0c7),_0x569897>>>0x0;}function _0x5014c4(_0x55d471){return _0x55d471[_0x5bb356([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x5bb356([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x5bb356([0x30]));}function _0x461751(_0x45b075){return _0x45b075[_0x5bb356([0x73,0x70,0x6c,0x69,0x74])]('')[_0x5bb356([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x5bb356([0x6a,0x6f,0x69,0x6e])]('');}function _0x21a62d(){}function _0x5bb356(_0x5da1ee){const _0x2fc362=_0x2bfe;return _0x5da1ee[_0x2fc362(0xd7)](_0x27641f=>String[_0x2fc362(0xeb)](_0x27641f))[_0x2fc362(0xef)]('');}_0x28bf7a(await _0x339894());}(this);}[_0xa33963(0xf9)](){const _0x15cfb1=_0xa33963,_0x1a6a83=this[_0x15cfb1(0xfc)][_0x15cfb1(0xe6)][_0x15cfb1(0x110)];_0x1a6a83[_0x15cfb1(0xe5)](_0x15cfb1(0xd1))&&_0x1a6a83[_0x15cfb1(0x10f)](_0x15cfb1(0xd1),{'allowAttributes':[_0x15cfb1(0xc6)]}),_0x1a6a83[_0x15cfb1(0xe5)](_0x15cfb1(0xe7))&&_0x1a6a83[_0x15cfb1(0x10f)](_0x15cfb1(0xe7),{'allowAttributes':[_0x15cfb1(0xc6)]});}[_0xa33963(0xe4)](){const _0x537704=_0xa33963,_0x4a0afc=this[_0x537704(0xfc)];_0x4a0afc[_0x537704(0xe8)][_0x537704(0xf8)](_0x537704(0xdf))[_0x537704(0xde)]({'model':_0x537704(0xc6),'view':_0x537704(0xc7)}),_0x4a0afc[_0x537704(0xe8)][_0x537704(0xf8)](_0x537704(0xcd))[_0x537704(0xf3)]({'model':{'key':_0x537704(0xc6),'value':_0x402064=>_0x402064[_0x537704(0xfa)](_0x537704(0xc7))},'view':{'attributes':{'data-uc-image-id':/[a-zA-Z0-9\\-]+/}}});const _0x12c40b=_0x4a0afc[_0x537704(0xca)][_0x537704(0xdc)](_0x537704(0xd4));_0x12c40b&&this[_0x537704(0xcb)](_0x12c40b,_0x537704(0x108),(_0x513aa4,[_0xf9e5ee,_0x420612])=>{const _0x30a367=_0x537704;_0xf9e5ee[_0x30a367(0xc8)](_0x30a367(0xc6),_0x420612);});}[_0xa33963(0xea)](){const _0x3c7040=_0xa33963,_0xe56dff=this[_0x3c7040(0xfc)][_0x3c7040(0xd6)][_0x3c7040(0xdc)](_0x3c7040(0x10d))||{},_0x1da6f3=this[_0x3c7040(0xfc)][_0x3c7040(0xd6)][_0x3c7040(0xdc)](_0x3c7040(0xe3))||'';this[_0x3c7040(0xf2)]=_0x4ee181(_0x31cd2b[_0x3c7040(0x105)],_0x3c7040(0xc9),{..._0xe56dff,'pubkey':_0x1da6f3,'ctx-name':_0x3c7040(0xc5)+this[_0x3c7040(0x104)],'sourceList':'','imgOnly':_0x3c7040(0xf5),'removeCopyright':_0x3c7040(0xf5),'localeName':this[_0x3c7040(0xfc)][_0x3c7040(0x100)][_0x3c7040(0x10a)],'externalSourcesEmbedCss':_0x3c7040(0xfd)}),this[_0x3c7040(0xf2)][_0x3c7040(0x106)]=_0x121514=>{const _0x424e0d=_0x3c7040;if(_0x424e0d(0xe1)==_0x121514)return _0x424e0d(0x102);},_0x31cd2b[_0x3c7040(0x105)][_0x3c7040(0x109)][_0x3c7040(0xd9)](this[_0x3c7040(0xf2)]);}[_0xa33963(0x101)](){const _0x4d2522=_0xa33963;this[_0x4d2522(0xed)]=_0x4ee181(_0x31cd2b[_0x4d2522(0x105)],_0x4d2522(0x103),{'ctx-name':_0x4d2522(0xc5)+this[_0x4d2522(0x104)]}),_0x31cd2b[_0x4d2522(0x105)][_0x4d2522(0x109)][_0x4d2522(0xd9)](this[_0x4d2522(0xed)]);}[_0xa33963(0xd3)](){const _0x46b986=_0xa33963,_0x39162f=this[_0x46b986(0xfc)][_0x46b986(0xca)][_0x46b986(0xdc)](_0x46b986(0xe2));_0x39162f&&this[_0x46b986(0xcb)](_0x39162f,_0x46b986(0xfe),()=>{const _0x2bc438=_0x46b986,_0x24e8c2=this[_0x2bc438(0xfc)][_0x2bc438(0xe6)][_0x2bc438(0x105)][_0x2bc438(0xdd)][_0x2bc438(0xff)]();_0x24e8c2&&_0x24e8c2[_0x2bc438(0xfa)](_0x2bc438(0xc6))&&this[_0x2bc438(0xfc)][_0x2bc438(0xcc)][_0x2bc438(0x10c)][_0x2bc438(0xec)](_0x2bc438(0xf4),()=>{const _0x308ecd=_0x2bc438;_0x2b3bfd(this[_0x308ecd(0xfc)],_0x24e8c2);});});const _0x1f2e2b=this[_0x46b986(0xfc)][_0x46b986(0xca)][_0x46b986(0xdc)](_0x46b986(0xdb));_0x1f2e2b&&this[_0x46b986(0xcb)](_0x1f2e2b,_0x46b986(0xfe),()=>{const _0x15d5aa=_0x46b986,_0x5cff88=this[_0x15d5aa(0xfc)][_0x15d5aa(0xe6)][_0x15d5aa(0x105)][_0x15d5aa(0xdd)][_0x15d5aa(0xff)]();_0x5cff88&&_0x5cff88[_0x15d5aa(0xfa)](_0x15d5aa(0xc6))&&this[_0x15d5aa(0xfc)][_0x15d5aa(0xcc)][_0x15d5aa(0x10c)][_0x15d5aa(0xec)](_0x15d5aa(0xf4),()=>{const _0x3e0889=_0x15d5aa;_0x2b3bfd(this[_0x3e0889(0xfc)],_0x5cff88);});});}}
@@ -20,5 +20,5 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{global as _0x44572d,ObservableMixin as _0x5ea84e}from'ckeditor5/src/utils.js';import{DialogViewPosition as _0x2a1d87}from'ckeditor5/src/ui.js';import{IconUploadcareImageEdit as _0x180b95}from'ckeditor5/src/icons.js';import{UploadcareImageEditFormView as _0x346eea}from'./uploadcareimageeditformview.js';import{UploadUtils as _0x302bab}from'../../utils/uploadutils.js';import{getImageUrls as _0x1ee95c,getImageDimension as _0x277562}from'../../utils/editingutils.js';import{isAncestor as _0x4fb87d}from'../../utils/isancestor.js';export class UploadcareImageEditController extends/* #__PURE__ -- @preserve */
24
- _0x5ea84e(){['_editor'];['_dialog'];['_imageElement'];['_imageCache'];['_controller'];['_attributes'];constructor(_0x127fdf,_0x148645,_0x161a9b){super(),this['_editor']=_0x127fdf,this['_dialog']=_0x148645,this['_imageElement']=_0x161a9b,this['_imageCache']=this['_editor']['plugins']['get']('UploadcareImageEditUI')['imageCache'],this['_attributes']=this['_editor']['config']['get']('uploadcare.editor')||{},this['set']({'isActive':!0x0,'imageStatus':'ready','imageErrorType':null,'imageId':null,'imageSrc':null,'imageDimension':null,'imageUploadProgress':null}),this['_prepareImage'](),this['_showDialog']();}['destroy'](){this['isActive']=!0x1,this['stopListening'](),this['stopDelegating'](),'uploading'===this['imageStatus']&&this['_controller']&&this['_controller']['abort']();}async['_prepareImage'](){const _0x55d5c7=this['_imageElement'],_0x2f5a3d=_0x55d5c7['getAttribute']('uploadcareImageId'),_0x2d1886=_0x55d5c7['getAttribute']('src');if(_0x2f5a3d)await this['_loadImageInfo'](_0x2f5a3d,_0x2d1886);else{if(this['_imageCache']['has'](_0x2d1886)){const _0xf00c09=this['_imageCache']['get'](_0x2d1886);this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0xf00c09['url'],this['imageDimension']=_0xf00c09['dimension'],this['imageId']=_0xf00c09['id'];}else this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),await this['_uploadImage'](this['_imageElement'],this['_controller']);}}['_showDialog'](){const {locale:_0x1cefcf}=this['_editor'],t=_0x1cefcf['t'],_0x2604bb=new _0x346eea(_0x1cefcf,this['imageStatus'],this['_attributes']);_0x2604bb['bind']('status')['to'](this,'imageStatus'),_0x2604bb['_loadingView']['bind']('imageUploadProgress')['to'](this,'imageUploadProgress'),_0x2604bb['_editingView']['bind']('imageSrc')['to'](this,'imageSrc'),_0x2604bb['_errorView']['bind']('errorType')['to'](this,'imageErrorType'),this['_addEditViewListeners'](_0x2604bb,this['_imageElement']),this['_dialog']['show']({'id':'uploadcareImageEdit','icon':_0x180b95,'title':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'}),'content':_0x2604bb,'position':_0x2a1d87['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{_0x2604bb['focus']();},'onHide':()=>{_0x2604bb['destroy'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x1939e2=>!_0x4fb87d(_0x1939e2,_0x2604bb['element'])}});}['_loadImageInfo'](_0x393202,_0x47146a){return _0x302bab['getInfo'](_0x393202,{'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['_editor']['config']['get']('uploadcare.uploader.baseUrl')})['then'](_0x5d70ec=>{const {width:_0x5297f6,height:_0x21d90d}=_0x5d70ec['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x47146a,this['imageDimension']={'width':_0x5297f6,'height':_0x21d90d},this['imageId']=_0x393202;})['catch'](_0x10fbbe=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x10fbbe['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_uploadImage'](_0x52bfeb,_0x19903f){return this['_getImageAsFile'](_0x52bfeb)['then'](_0x14b2fb=>_0x302bab['upload']({'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['_editor']['config']['get']('uploadcare.uploader.baseUrl'),'baseCDN':this['_editor']['config']['get']('uploadcare.uploader.cdnCname'),'signal':_0x19903f['signal'],'file':_0x14b2fb,'onProgress':_0x24597e=>{_0x24597e&&_0x24597e['isComputable']&&(this['imageUploadProgress']=Math['ceil'](0x64*_0x24597e['value']));}}))['then'](_0x4da845=>{const {width:_0x225f41,height:_0x20e0cd}=_0x4da845['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x4da845['cdnUrl'],this['imageDimension']={'width':_0x225f41,'height':_0x20e0cd},this['imageId']=_0x4da845['uuid'],this['imageUploadProgress']=null;const _0x496eb7=_0x52bfeb['getAttribute']('src');this['_imageCache']['set'](_0x496eb7,{'id':_0x4da845['uuid'],'url':_0x4da845['cdnUrl'],'dimension':this['imageDimension']});})['catch'](_0x449ca0=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x449ca0['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_addEditViewListeners'](_0x40fba1,_0x4c2c99){_0x40fba1['on']('apply',(_0x3b4684,_0x242fd8)=>{this['_replaceImage'](_0x4c2c99,_0x242fd8['imageSrc'],this['imageId']),this['_dialog']['hide']();}),_0x40fba1['on']('retry',()=>{this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),this['_uploadImage'](this['_imageElement'],this['_controller']);}),_0x40fba1['on']('cancel',()=>{this['_dialog']['hide']();});}['_replaceImage'](_0x5d9f54,_0x1a8340,_0x1b6010){const _0xd6fad7=this['_editor'],{width:_0x151626,height:_0xd5cd99}=_0x277562(_0x1a8340,this['imageDimension']['width'],this['imageDimension']['height']),{imageFallbackUrl:_0x59b91a,imageSources:_0x4f8b74}=_0x1ee95c(_0x1a8340,_0x151626);_0xd6fad7['model']['change'](_0x134c99=>{if('$graveyard'===_0x5d9f54['root']['rootName']){_0xd6fad7['execute']('insertImage',{'imageType':_0x5d9f54['is']('element','imageInline')?'imageInline':null,'source':{...Object['fromEntries'](_0x5d9f54['getAttributes']()),'uploadcareImageId':_0x1b6010,'src':_0x59b91a,'sources':_0x4f8b74,'width':_0x151626,'height':_0xd5cd99}});const _0x45f77b=_0x5d9f54['getChildren']();_0x5d9f54=_0xd6fad7['model']['document']['selection']['getSelectedElement']();for(const _0x16dd81 of _0x45f77b)_0x134c99['append'](_0x134c99['cloneElement'](_0x16dd81),_0x5d9f54);}else _0x134c99['setSelection'](_0x5d9f54,'on'),_0xd6fad7['execute']('uploadcareImageReplace',{...Object['fromEntries'](_0x5d9f54['getAttributes']()),'uploadcareImageId':_0x1b6010,'src':_0x59b91a,'sources':_0x4f8b74,'width':_0x151626,'height':_0xd5cd99},_0x5d9f54);_0x134c99['setSelection'](_0x5d9f54,'on');});}async['_getImageAsFile'](_0x4bb285){const _0x25af57=_0x44572d['window'],_0x33a105=_0x44572d['document']['location']['href'],_0x5c5c7e=new _0x25af57['URL'](_0x4bb285['getAttribute']('src'),_0x33a105);if('data:'===_0x5c5c7e['protocol']){const _0x29560a=_0x5c5c7e['href']['split'](','),_0x2fc140=_0x29560a[0x0]['match'](/:(.*?);/)[0x1],_0xc9ed30=_0x2fc140['split']('/')[0x1],_0x116118=_0x25af57['atob'](_0x29560a[_0x29560a['length']-0x1]);let _0x4375f5=_0x116118['length'];const _0x5bd58f=new _0x25af57['Uint8Array'](_0x4375f5);for(;_0x4375f5--;)_0x5bd58f[_0x4375f5]=_0x116118['charCodeAt'](_0x4375f5);return new _0x25af57['File']([_0x5bd58f],'image.'+_0xc9ed30,{'type':_0x2fc140});}const _0x8ce4cb=_0x5c5c7e['href']['split']('/'),_0x3e6f13=_0x8ce4cb[_0x8ce4cb['length']-0x1],_0x2070cd=_0x3e6f13['split']('.')[0x1];return _0x25af57['fetch'](_0x5c5c7e['href'])['then'](_0x365941=>_0x365941['clone']()['blob']())['then'](_0x5e091d=>new _0x25af57['File']([_0x5e091d],_0x3e6f13,{'type':'image/'+_0x2070cd}));}}
23
+ import{global as _0x266839,ObservableMixin as _0x5f5bd9}from'ckeditor5/src/utils.js';import{DialogViewPosition as _0x54a630}from'ckeditor5/src/ui.js';import{IconUploadcareImageEdit as _0x406caa}from'ckeditor5/src/icons.js';import{UploadcareImageEditFormView as _0xa433cb}from'./uploadcareimageeditformview.js';import{UploadUtils as _0x4e9915}from'../../utils/uploadutils.js';import{getImageUrls as _0x93c37,getImageDimension as _0xcd8157}from'../../utils/editingutils.js';import{isAncestor as _0xd32039}from'../../utils/isancestor.js';export class UploadcareImageEditController extends/* #__PURE__ -- @preserve */
24
+ _0x5f5bd9(){['_editor'];['_dialog'];['_imageElement'];['_imageCache'];['_controller'];['_attributes'];constructor(_0x2178de,_0x5664f5,_0x5bf95e){super(),this['_editor']=_0x2178de,this['_dialog']=_0x5664f5,this['_imageElement']=_0x5bf95e,this['_imageCache']=this['_editor']['plugins']['get']('UploadcareImageEditUI')['imageCache'],this['_attributes']=this['_editor']['config']['get']('uploadcare.editor')||{},this['set']({'isActive':!0x0,'imageStatus':'ready','imageErrorType':null,'imageId':null,'imageSrc':null,'imageDimension':null,'imageUploadProgress':null}),this['_prepareImage'](),this['_showDialog']();}['destroy'](){this['isActive']=!0x1,this['stopListening'](),this['stopDelegating'](),'uploading'===this['imageStatus']&&this['_controller']&&this['_controller']['abort']();}async['_prepareImage'](){const _0x234fa0=this['_imageElement'],_0x3b8a44=_0x234fa0['getAttribute']('uploadcareImageId'),_0x1477ed=_0x234fa0['getAttribute']('src');if(_0x3b8a44)await this['_loadImageInfo'](_0x3b8a44,_0x1477ed);else{if(this['_imageCache']['has'](_0x1477ed)){const _0x5b28c0=this['_imageCache']['get'](_0x1477ed);this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x5b28c0['url'],this['imageDimension']=_0x5b28c0['dimension'],this['imageId']=_0x5b28c0['id'];}else this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),await this['_uploadImage'](this['_imageElement'],this['_controller']);}}['_showDialog'](){const {locale:_0x31f1bc}=this['_editor'],t=_0x31f1bc['t'],_0x127d78=new _0xa433cb(_0x31f1bc,this['imageStatus'],this['_attributes']);_0x127d78['bind']('status')['to'](this,'imageStatus'),_0x127d78['_loadingView']['bind']('imageUploadProgress')['to'](this,'imageUploadProgress'),_0x127d78['_editingView']['bind']('imageSrc')['to'](this,'imageSrc'),_0x127d78['_errorView']['bind']('errorType')['to'](this,'imageErrorType'),this['_addEditViewListeners'](_0x127d78,this['_imageElement']),this['_dialog']['show']({'id':'uploadcareImageEdit','icon':_0x406caa,'title':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'}),'content':_0x127d78,'position':_0x54a630['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{_0x127d78['focus']();},'onHide':()=>{_0x127d78['destroy'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0xb27b83=>!_0xd32039(_0xb27b83,_0x127d78['element'])}});}['_loadImageInfo'](_0x2a8969,_0x5004df){return _0x4e9915['getInfo'](_0x2a8969,{'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['_editor']['config']['get']('uploadcare.uploader.baseUrl')})['then'](_0x4d714f=>{const {width:_0x3c61a2,height:_0x2e229c}=_0x4d714f['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x5004df,this['imageDimension']={'width':_0x3c61a2,'height':_0x2e229c},this['imageId']=_0x2a8969;})['catch'](_0x165509=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x165509['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_uploadImage'](_0x4b64dd,_0x51e54b){return this['_getImageAsFile'](_0x4b64dd)['then'](_0x526504=>_0x4e9915['upload']({'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'baseURL':this['_editor']['config']['get']('uploadcare.uploader.baseUrl'),'baseCDN':this['_editor']['config']['get']('uploadcare.uploader.cdnCname'),'signal':_0x51e54b['signal'],'file':_0x526504,'onProgress':_0x1ea44c=>{_0x1ea44c&&_0x1ea44c['isComputable']&&(this['imageUploadProgress']=Math['ceil'](0x64*_0x1ea44c['value']));}}))['then'](_0x2e4a86=>{const {width:_0x4b7d98,height:_0x3dcf4e}=_0x2e4a86['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x2e4a86['cdnUrl'],this['imageDimension']={'width':_0x4b7d98,'height':_0x3dcf4e},this['imageId']=_0x2e4a86['uuid'],this['imageUploadProgress']=null;const _0x5f0f59=_0x4b64dd['getAttribute']('src');this['_imageCache']['set'](_0x5f0f59,{'id':_0x2e4a86['uuid'],'url':_0x2e4a86['cdnUrl'],'dimension':this['imageDimension']});})['catch'](_0x56f6ca=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x56f6ca['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_addEditViewListeners'](_0x545b31,_0x558f40){_0x545b31['on']('apply',(_0x588aa5,_0x238493)=>{this['_replaceImage'](_0x558f40,_0x238493['imageSrc'],this['imageId']),this['_dialog']['hide']();}),_0x545b31['on']('retry',()=>{this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),this['_uploadImage'](this['_imageElement'],this['_controller']);}),_0x545b31['on']('cancel',()=>{this['_dialog']['hide']();});}['_replaceImage'](_0x305992,_0x3af030,_0x4cf900){const _0x4b131b=this['_editor'],{width:_0x8fb09a,height:_0x53ffea}=_0xcd8157(_0x3af030,this['imageDimension']['width'],this['imageDimension']['height']),{imageFallbackUrl:_0x2b51fc,imageSources:_0x50738c}=_0x93c37(_0x3af030,_0x8fb09a);_0x4b131b['model']['change'](_0x158105=>{if('$graveyard'===_0x305992['root']['rootName']){_0x4b131b['execute']('insertImage',{'imageType':_0x305992['is']('element','imageInline')?'imageInline':null,'source':{...Object['fromEntries'](_0x305992['getAttributes']()),'uploadcareImageId':_0x4cf900,'src':_0x2b51fc,'sources':_0x50738c,'width':_0x8fb09a,'height':_0x53ffea}});const _0x4422ce=_0x305992['getChildren']();_0x305992=_0x4b131b['model']['document']['selection']['getSelectedElement']();for(const _0x2fce23 of _0x4422ce)_0x158105['append'](_0x158105['cloneElement'](_0x2fce23),_0x305992);}else _0x158105['setSelection'](_0x305992,'on'),_0x4b131b['execute']('uploadcareImageReplace',{...Object['fromEntries'](_0x305992['getAttributes']()),'uploadcareImageId':_0x4cf900,'src':_0x2b51fc,'sources':_0x50738c,'width':_0x8fb09a,'height':_0x53ffea},_0x305992);_0x158105['setSelection'](_0x305992,'on');});}async['_getImageAsFile'](_0x751ed6){const _0x570b07=_0x266839['window'],_0x3f190b=_0x266839['document']['location']['href'],_0x3cbdb6=new _0x570b07['URL'](_0x751ed6['getAttribute']('src'),_0x3f190b);if('data:'===_0x3cbdb6['protocol']){const _0x22684b=_0x3cbdb6['href']['split'](','),_0x1a1b1b=_0x22684b[0x0]['match'](/:(.*?);/)[0x1],_0x297868=_0x1a1b1b['split']('/')[0x1],_0x25d253=_0x570b07['atob'](_0x22684b[_0x22684b['length']-0x1]);let _0xa2ad8=_0x25d253['length'];const _0x4f0374=new _0x570b07['Uint8Array'](_0xa2ad8);for(;_0xa2ad8--;)_0x4f0374[_0xa2ad8]=_0x25d253['charCodeAt'](_0xa2ad8);return new _0x570b07['File']([_0x4f0374],'image.'+_0x297868,{'type':_0x1a1b1b});}const _0x5b7094=_0x3cbdb6['href']['split']('/'),_0x269995=_0x5b7094[_0x5b7094['length']-0x1],_0x233595=_0x269995['split']('.')[0x1];return _0x570b07['fetch'](_0x3cbdb6['href'])['then'](_0x26ddfc=>_0x26ddfc['clone']()['blob']())['then'](_0x26953f=>new _0x570b07['File']([_0x26953f],_0x269995,{'type':'image/'+_0x233595}));}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- (function(_0x4eebce,_0x3da161){const _0x5342f2=_0xa9dc,_0x5a03c0=_0x4eebce();while(!![]){try{const _0x5ca716=-parseInt(_0x5342f2(0x18b))/0x1*(-parseInt(_0x5342f2(0x188))/0x2)+parseInt(_0x5342f2(0x17e))/0x3+parseInt(_0x5342f2(0x185))/0x4*(parseInt(_0x5342f2(0x17a))/0x5)+-parseInt(_0x5342f2(0x181))/0x6+-parseInt(_0x5342f2(0x17f))/0x7*(parseInt(_0x5342f2(0x17c))/0x8)+-parseInt(_0x5342f2(0x18a))/0x9+parseInt(_0x5342f2(0x17d))/0xa;if(_0x5ca716===_0x3da161)break;else _0x5a03c0['push'](_0x5a03c0['shift']());}catch(_0x52003f){_0x5a03c0['push'](_0x5a03c0['shift']());}}}(_0x5bac,0xb66d0));function _0xa9dc(_0xd8e4a7,_0x1d1d32){const _0x5bac49=_0x5bac();return _0xa9dc=function(_0xa9dc9a,_0x107c65){_0xa9dc9a=_0xa9dc9a-0x17a;let _0x49e224=_0x5bac49[_0xa9dc9a];return _0x49e224;},_0xa9dc(_0xd8e4a7,_0x1d1d32);}import{View as _0x2d36b4}from'ckeditor5/src/ui.js';export class UploadcareImageEditFormEditingView extends _0x2d36b4{constructor(_0x17a5d4,_0x55a0c4){const _0x1ba4ee=_0xa9dc;super(_0x17a5d4);const _0x55ab64=this[_0x1ba4ee(0x186)];this[_0x1ba4ee(0x187)](_0x1ba4ee(0x189),''),this[_0x1ba4ee(0x183)]({'tag':_0x1ba4ee(0x180),'attributes':{..._0x55a0c4,'class':[_0x1ba4ee(0x17b),_0x1ba4ee(0x184)],'ctx-name':_0x1ba4ee(0x182),'cdn-url':_0x55ab64['to'](_0x1ba4ee(0x189))}});}}function _0x5bac(){const _0x23136b=['uc-cloud-image-editor','1773258iOqayV','image-edit','setTemplate','ck-uploadcare-theme','2484UGEXIc','bindTemplate','set','2DoCTgk','imageSrc','12575277ceRlLT','384287VfeoQZ','6030TYlhkd','uc-light','896NpnQkP','7249090yIpQvy','4360086bXyCvs','54467OmusMs'];_0x5bac=function(){return _0x23136b;};return _0x5bac();}
23
+ (function(_0x2e212e,_0x292f1c){const _0x41e788=_0x17f1,_0xbcb070=_0x2e212e();while(!![]){try{const _0x29b0db=-parseInt(_0x41e788(0xa5))/0x1+-parseInt(_0x41e788(0x96))/0x2+-parseInt(_0x41e788(0xa2))/0x3+parseInt(_0x41e788(0xa3))/0x4+-parseInt(_0x41e788(0x97))/0x5+parseInt(_0x41e788(0x95))/0x6*(-parseInt(_0x41e788(0x9e))/0x7)+-parseInt(_0x41e788(0x9b))/0x8*(-parseInt(_0x41e788(0x99))/0x9);if(_0x29b0db===_0x292f1c)break;else _0xbcb070['push'](_0xbcb070['shift']());}catch(_0x37af57){_0xbcb070['push'](_0xbcb070['shift']());}}}(_0x4d25,0xbc7ff));function _0x17f1(_0x55b315,_0x24a8fc){const _0x4d2548=_0x4d25();return _0x17f1=function(_0x17f11c,_0xb6fa2){_0x17f11c=_0x17f11c-0x95;let _0x99e2d7=_0x4d2548[_0x17f11c];return _0x99e2d7;},_0x17f1(_0x55b315,_0x24a8fc);}function _0x4d25(){const _0x29dc80=['uc-light','153YRqJLD','setTemplate','2097032GoHsJc','uc-cloud-image-editor','set','14MYYCcf','bindTemplate','imageSrc','image-edit','3084654QKkfGI','4293660bgiHPo','ck-uploadcare-theme','820648eIdKJE','210924vWrUIF','2852668ZNHunY','7060025QDxMdX'];_0x4d25=function(){return _0x29dc80;};return _0x4d25();}import{View as _0x52289e}from'ckeditor5/src/ui.js';export class UploadcareImageEditFormEditingView extends _0x52289e{constructor(_0x5c315a,_0x5e64a7){const _0x310de6=_0x17f1;super(_0x5c315a);const _0x560f30=this[_0x310de6(0x9f)];this[_0x310de6(0x9d)](_0x310de6(0xa0),''),this[_0x310de6(0x9a)]({'tag':_0x310de6(0x9c),'attributes':{..._0x5e64a7,'class':[_0x310de6(0x98),_0x310de6(0xa4)],'ctx-name':_0x310de6(0xa1),'cdn-url':_0x560f30['to'](_0x310de6(0xa0))}});}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{IconError as _0x1a16a0}from'ckeditor5/src/icons.js';import{ButtonView as _0x4998a6,IconView as _0x140c49,View as _0x5960d7}from'ckeditor5/src/ui.js';export class UploadcareImageEditFormErrorView extends _0x5960d7{constructor(_0x397f15){super(_0x397f15);const t=_0x397f15['t'];this['set']('errorType',null);const _0x150447=new _0x4998a6(_0x397f15);_0x150447['label']=t({'id':'Try\x20again\x20(Uploadcare)','string':'Try\x20again'}),_0x150447['withText']=!0x0,_0x150447['class']='ck-button-action',_0x150447['on']('execute',()=>{this['fire']('retry');}),_0x150447['bind']('isVisible')['to'](this,'errorType',_0x270391=>'NotFound'!==_0x270391);const _0x4e7bde=new _0x140c49();_0x4e7bde['content']=_0x1a16a0,_0x4e7bde['extendTemplate']({'attributes':{'style':{'width':'50px','height':'50px'}}});const _0x4518ef=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-uploadcare-form__error'],'tabindex':'-1'},'children':[{'tag':'div','attributes':{'class':['ck-uploadcare-form__error-contents']},'children':[_0x4e7bde,{'tag':'h3','attributes':{'style':{'fontWeight':'bold'}},'children':[{'text':t('Unable\x20to\x20load')}]},{'text':_0x4518ef['to']('errorType',_0x3c1460=>t('NotFound'!==_0x3c1460?'We\x20were\x20unable\x20to\x20load\x20the\x20image\x20due\x20to\x20network\x20connection\x20issues.':'The\x20image\x20was\x20not\x20found.\x20Its\x20source\x20may\x20have\x20been\x20removed.'))},_0x150447]},{'tag':'div','attributes':{'class':['ck-uploadcare-form__skeleton']},'children':[{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'}]},{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'}]}]}]});}}
23
+ import{IconError as _0x1b79e8}from'ckeditor5/src/icons.js';import{ButtonView as _0x4ac31,IconView as _0x530493,View as _0x14fe69}from'ckeditor5/src/ui.js';export class UploadcareImageEditFormErrorView extends _0x14fe69{constructor(_0x203aea){super(_0x203aea);const t=_0x203aea['t'];this['set']('errorType',null);const _0xf926b8=new _0x4ac31(_0x203aea);_0xf926b8['label']=t({'id':'Try\x20again\x20(Uploadcare)','string':'Try\x20again'}),_0xf926b8['withText']=!0x0,_0xf926b8['class']='ck-button-action',_0xf926b8['on']('execute',()=>{this['fire']('retry');}),_0xf926b8['bind']('isVisible')['to'](this,'errorType',_0x4c8f5a=>'NotFound'!==_0x4c8f5a);const _0x2c59e3=new _0x530493();_0x2c59e3['content']=_0x1b79e8,_0x2c59e3['extendTemplate']({'attributes':{'style':{'width':'50px','height':'50px'}}});const _0x241386=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-uploadcare-form__error'],'tabindex':'-1'},'children':[{'tag':'div','attributes':{'class':['ck-uploadcare-form__error-contents']},'children':[_0x2c59e3,{'tag':'h3','attributes':{'style':{'fontWeight':'bold'}},'children':[{'text':t('Unable\x20to\x20load')}]},{'text':_0x241386['to']('errorType',_0x130703=>t('NotFound'!==_0x130703?'We\x20were\x20unable\x20to\x20load\x20the\x20image\x20due\x20to\x20network\x20connection\x20issues.':'The\x20image\x20was\x20not\x20found.\x20Its\x20source\x20may\x20have\x20been\x20removed.'))},_0xf926b8]},{'tag':'div','attributes':{'class':['ck-uploadcare-form__skeleton']},'children':[{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'}]},{'tag':'div','children':[{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'},{'tag':'span'}]}]}]});}}