@ckeditor/ckeditor5-uploadcare 45.0.0-alpha.4 → 45.0.0-alpha.5
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/build/uploadcare.js +1 -1
- package/dist/index.js +3 -3
- package/package.json +9 -9
- package/src/uploadcareediting.js +1 -1
- package/src/uploadcareimageedit/ui/uploadcareimageeditcontroller.js +2 -2
- package/src/uploadcareimageedit/ui/uploadcareimageeditformeditingview.js +1 -1
- package/src/uploadcareimageedit/ui/uploadcareimageeditformerrorview.js +1 -1
- package/src/uploadcareimageedit/ui/uploadcareimageeditformloadingview.js +1 -1
- package/src/uploadcareimageedit/ui/uploadcareimageeditformview.js +1 -1
- package/src/uploadcareimageedit/uploadcareimageeditcommand.js +1 -1
- package/src/uploadcareimageedit/uploadcareimageeditediting.js +1 -1
- package/src/uploadcareimageedit/uploadcareimageeditui.js +1 -1
- package/src/uploadcareimageedit/uploadcareimagereplacecommand.js +1 -1
- package/src/utils/dialogfocusmanagerview.js +1 -1
- package/src/utils/editingutils.js +1 -1
- package/src/utils/isancestor.js +1 -1
- package/src/utils/uploadutils.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,6 +20,6 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{Plugin as _0x3f832c,Command as _0x1cbf3c}from'@ckeditor/ckeditor5-core/dist/index.js';import{IconOneDrive as _0x3afa1d,IconGooglePhotos as _0x25f90c,IconGoogleDrive as _0x35b20f,IconFacebook as _0xe1844e,IconDropbox as _0xfe20df,IconUploadcareLink as _0x3cdd92,IconUploadcareImageUpload as _0x32913c,IconError as et,IconUploadcareImageEdit as _0x598dbc}from'@ckeditor/ckeditor5-icons/dist/index.js';import{ButtonView as _0x5481b9,MenuBarMenuListItemButtonView as _0x9227ba,View as _0x20cea7,FocusCycler as _0x516a18,Dialog as _0x1e0d7e,DialogViewPosition as _0x49163a,SpinnerView as _0x12628c,IconView as at,Notification as _0x55a996}from'@ckeditor/ckeditor5-ui/dist/index.js';import{FocusTracker as _0x138ef7,DomEmitterMixin as _0x376a86,global as _0x508d8c,getAncestors as _0xd4ccb2,ObservableMixin as _0x4014d4,createElement as _0x19b262,uid as _0x48ea72}from'@ckeditor/ckeditor5-utils/dist/index.js';import{FileRepository as _0x3d055f}from'@ckeditor/ckeditor5-upload/dist/index.js';import{uploadFile as _0x3e08a9,info as _0x417c81}from'@uploadcare/upload-client';import*as _0x1575d6 from'@uploadcare/file-uploader';var o=function(_0x27420a){return _0x27420a['Local']='local',_0x27420a['URL']='url',_0x27420a['Dropbox']='dropbox',_0x27420a['GDrive']='gdrive',_0x27420a['Facebook']='facebook',_0x27420a['GPhotos']='gphotos',_0x27420a['OneDrive']='onedrive',_0x27420a;}({});function _(_0x5ea7e5,_0x3a8b52,_0x1be1da){const t=_0x5ea7e5['t'],_0x241748=_0x5ea7e5['t'];switch(_0x3a8b52){case o['Local']:return{'text':_0x241748('Insert'===_0x1be1da?'Upload\x20from\x20computer':'Replace\x20from\x20computer'),'shortText':_0x241748('From\x20computer')};case o['URL']:return{'text':'Insert'===_0x1be1da?_0x241748('Insert\x20via\x20URL'):t('Replace\x20via\x20URL'),'shortText':_0x241748('Via\x20URL')};case o['Dropbox']:return{'text':t('Insert'===_0x1be1da?'Insert\x20with\x20Dropbox':'Replace\x20with\x20Dropbox'),'shortText':t('With\x20Dropbox')};case o['Facebook']:return{'text':t('Insert'===_0x1be1da?'Insert\x20with\x20Facebook':'Replace\x20with\x20Facebook'),'shortText':t('With\x20Facebook')};case o['GDrive']:return{'text':t('Insert'===_0x1be1da?'Insert\x20with\x20Google\x20Drive':'Replace\x20with\x20Google\x20Drive'),'shortText':t('With\x20Google\x20Drive')};case o['GPhotos']:return{'text':t('Insert'===_0x1be1da?'Insert\x20with\x20Google\x20Photos':'Replace\x20with\x20Google\x20Photos'),'shortText':t('With\x20Google\x20Photos')};case o['OneDrive']:return{'text':t('Insert'===_0x1be1da?'Insert\x20with\x20OneDrive':'Replace\x20with\x20OneDrive'),'shortText':t('With\x20OneDrive')};default:return _0x3a8b52;}}class e extends _0x3f832c{['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 _0x4ae565=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x41c5a9;for(const _0x2f6ff0 in _0x4ae565){const _0x146e75=_0x2f6ff0,_0x245c91=_0x4ae565[_0x146e75];if('uploadcareLicenseKeyValid'==_0x245c91||'uploadcareLicenseKeyInvalid'==_0x245c91||'uploadcareLicenseKeyExpired'==_0x245c91||'uploadcareLicenseKeyDomainLimit'==_0x245c91||'uploadcareLicenseKeyNotAllowed'==_0x245c91||'uploadcareLicenseKeyEvaluationLimit'==_0x245c91||'uploadcareLicenseKeyTrialLimit'==_0x245c91||'uploadcareLicenseKeyUsageLimit'==_0x245c91){delete _0x4ae565[_0x146e75],_0x41c5a9=_0x245c91,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'uploadcareLicenseKeyInvalid'==_0x41c5a9&&_0x4ae565['_showLicenseError']('invalid'),'uploadcareLicenseKeyExpired'==_0x41c5a9&&_0x4ae565['_showLicenseError']('expired'),'uploadcareLicenseKeyDomainLimit'==_0x41c5a9&&_0x4ae565['_showLicenseError']('domainLimit'),'uploadcareLicenseKeyNotAllowed'==_0x41c5a9&&_0x4ae565['_showLicenseError']('featureNotAllowed','Uploadcare'),'uploadcareLicenseKeyEvaluationLimit'==_0x41c5a9&&_0x4ae565['_showLicenseError']('evaluationLimit'),'uploadcareLicenseKeyTrialLimit'==_0x41c5a9&&_0x4ae565['_showLicenseError']('trialLimit'),'uploadcareLicenseKeyUsageLimit'==_0x41c5a9&&_0x4ae565['_showLicenseError']('usageLimit');},0x3e8);}['afterInit'](){const {editor:_0x13f4cd}=this,_0xcab98d=_0x13f4cd['commands']['get']('uploadcare');if(!_0xcab98d)return;const _0x511530=this['_normalizeConfigSourceList'](_0x13f4cd['config']['get']('uploadcare.uploader.sourceList'))['reduce']((_0x27d046,_0x3d3905)=>{const _0x4705c0=this['_getIntegrationKey'](_0x3d3905['type']);return _0x27d046[_0x4705c0]||(_0x27d046[_0x4705c0]=[]),_0x27d046[_0x4705c0]['push'](_0x3d3905),_0x27d046;},{});_0x13f4cd['plugins']['has']('ImageInsertUI')&&_0x13f4cd['commands']['get']('uploadcare')&&Object['entries'](_0x511530)['forEach'](([_0x10813e,_0x16a924])=>{_0x13f4cd['plugins']['get']('ImageInsertUI')['registerIntegration']({'name':_0x10813e,'observable':()=>_0xcab98d,'buttonViewCreator':()=>this['_createToolbarButton'](_0x16a924),'formViewCreator':()=>this['_createDropdownButtons'](_0x16a924),'menuBarButtonViewCreator':()=>this['_createMenuBarButtons'](_0x16a924),'override':'assetManager'!==_0x10813e});});}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_normalizeConfigSourceList'](_0x5dd7a5){const {locale:_0x496583}=this['editor'];return _0x5dd7a5['map'](_0x3eec4d=>{const _0x356f9a=_(_0x496583,_0x3eec4d,'Insert');switch(_0x3eec4d){case o['Local']:return{'icon':_0x32913c,'type':o['Local'],..._0x356f9a};case o['URL']:return{'icon':_0x3cdd92,'type':o['URL'],..._0x356f9a};case o['Dropbox']:return{'icon':_0xfe20df,'type':o['Dropbox'],..._0x356f9a};case o['Facebook']:return{'icon':_0xe1844e,'type':o['Facebook'],..._0x356f9a};case o['GDrive']:return{'icon':_0x35b20f,'type':o['GDrive'],..._0x356f9a};case o['GPhotos']:return{'icon':_0x25f90c,'type':o['GPhotos'],..._0x356f9a};case o['OneDrive']:return{'icon':_0x3afa1d,'type':o['OneDrive'],..._0x356f9a};}});}['_getIntegrationKey'](_0x243afa){switch(_0x243afa){case o['Local']:return'upload';case o['URL']:return'url';default:return'assetManager';}}['_createButton'](_0x1a458b,_0x2dc7b9){const _0x190077=this['editor'],_0x143cb2=new _0x1a458b(_0x190077['locale']),_0x273fd6=_0x190077['commands']['get']('uploadcare');return _0x143cb2['bind']('isEnabled')['to'](_0x273fd6),_0x143cb2['on']('execute',()=>{_0x273fd6['execute'](_0x2dc7b9);}),_0x143cb2;}['_createToolbarButton'](_0x1422b9){const {locale:_0xbb8354}=this['editor'],_0x35c1a7=this['editor']['plugins']['get']('ImageInsertUI'),_0x49638d=_0x1422b9[0x0],_0x1ea159=this['_createButton'](_0x5481b9,_0x49638d['type']);return _0x1ea159['icon']=_0x49638d['icon'],_0x1ea159['bind']('label')['to'](_0x35c1a7,'isImageSelected',_0x578ed5=>_(_0xbb8354,_0x49638d['type'],_0x578ed5?'Replace':'Insert')['text']),_0x1ea159['tooltip']=!0x0,_0x1ea159;}['_createDropdownButtons'](_0x19473a){const {locale:_0x1997db}=this['editor'],_0x305a62=this['editor']['plugins']['get']('ImageInsertUI');return _0x19473a['map'](_0x4bf058=>{const _0x2a4e10=this['_createButton'](_0x5481b9,_0x4bf058['type']);return _0x2a4e10['withText']=!0x0,_0x2a4e10['icon']=_0x4bf058['icon'],_0x2a4e10['bind']('label')['to'](_0x305a62,'isImageSelected',_0x12068f=>_(_0x1997db,_0x4bf058['type'],_0x12068f?'Replace':'Insert')['text']),_0x2a4e10;});}['_createMenuBarButtons'](_0x5bfbc2){return _0x5bfbc2['map'](_0x2da64d=>{const _0x32ff93=this['_createButton'](_0x9227ba,_0x2da64d['type']);return _0x32ff93['icon']=_0x2da64d['icon'],_0x32ff93['label']=_0x2da64d['shortText'],_0x32ff93;});}}class q extends _0x20cea7{['focusTracker'];['focusCycler'];constructor(_0x482357){super(_0x482357),this['focusTracker']=new _0x138ef7(),this['focusCycler']=new _0x516a18({'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 S extends q{constructor(_0x5aa84b){super(_0x5aa84b),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'}},this['getFocusableElement']()]});}['focus'](){this['element']['focus']();}}function E(_0x46ace7,_0x28f1f){const _0x450880=[0x140,0x1e0,0x300,0x400,0x4b0,0x640,0x780,0x960]['filter'](_0xd4a708=>_0xd4a708<=_0x28f1f)['map'](_0x4bbf40=>_0x46ace7['replace'](/\/$/,'')+'/-/resize/'+_0x4bbf40+'x/\x20'+_0x4bbf40+'w');return{'imageFallbackUrl':_0x46ace7,'imageSources':[{'srcset':_0x450880['join'](',\x20'),'sizes':'(max-width:\x20'+_0x28f1f+'px)\x20100vw,\x20'+_0x28f1f+'px','type':'image/webp'}]};}function A(_0x8f9765,_0x48a8da,_0x25ae26){const _0x48fda1=_0x8f9765['match'](/\/crop\/(\d+)x(\d+)\//);return{'width':_0x48fda1?parseInt(_0x48fda1[0x1],0xa):_0x48a8da,'height':_0x48fda1?parseInt(_0x48fda1[0x2],0xa):_0x25ae26};}function m(_0x3bb5d7,_0x1abddf){const _0x330b2f=Object['create'](_0x376a86),_0x4252bf=_0x3bb5d7['plugins']['get']('ImageUtils'),_0xfac19a=_0x3bb5d7['editing']['mapper']['toViewElement'](_0x1abddf),_0x2c9aaa=_0x4252bf['findViewImgElement'](_0xfac19a),_0x45f0da=_0x3bb5d7['editing']['view']['domConverter']['viewToDom'](_0x2c9aaa),_0x4ae4be=_0x1abddf['getAttribute']('width'),_0x295123=_0x1abddf['getAttribute']('height'),_0x46b3f1='image-processing';_0x3bb5d7['editing']['view']['change'](_0x4e4022=>{_0x4e4022['addClass'](_0x46b3f1,_0xfac19a),_0x4e4022['setStyle']('aspect-ratio',_0x4ae4be+'/'+_0x295123,_0x2c9aaa);}),_0x330b2f['listenTo'](_0x45f0da,'load',()=>{_0x330b2f['stopListening'](_0x45f0da,'load'),_0x3bb5d7['editing']['view']['change'](_0x1b5a61=>{_0x1b5a61['removeClass'](_0x46b3f1,_0xfac19a),_0x1b5a61['removeStyle']('aspect-ratio',_0x2c9aaa);});});}function V(_0x5164ba){if(Array['isArray'](_0x5164ba)){const _0x14e711=_0x5164ba['map'](V);return _0x58fc44=>_0x14e711['some'](_0x379839=>_0x379839(_0x58fc44));}if('origin'==_0x5164ba){const _0x39f587=_0x508d8c['window']['location']['origin'];return _0x2b9f5f=>new URL(_0x2b9f5f,_0x508d8c['document']['baseURI'])['origin']==_0x39f587;}return'function'==typeof _0x5164ba?_0x5164ba:_0x5164ba instanceof RegExp?_0x1e9387=>!(!_0x1e9387['match'](_0x5164ba)&&!_0x1e9387['replace'](/^https?:\/\//,'')['match'](_0x5164ba)):()=>!0x1;}function F(_0x34c89a,_0x55f58a){return _0xd4ccb2(_0x34c89a['target'])['includes'](_0x55f58a);}class l extends/* #__PURE__ -- @preserve */
|
|
24
|
-
_0x4014d4(){['_editor'];['_dialog'];['_editing'];['_api'];['_type']=null;['_formView']=null;constructor(_0x2bc40c,_0x4bf409,_0x3db1db){super(),this['_editor']=_0x2bc40c,this['_editing']=_0x4bf409,this['_dialog']=_0x2bc40c['plugins']['get'](_0x1e0d7e),this['_api']=_0x4bf409['ctxElement']['getAPI'](),this['_type']=_0x3db1db,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:_0x4f057d,model:_0x153fdd}=this['_editor'],_0x2357cb=_0x153fdd['document']['selection']['getSelectedElement'](),_0x55f72a=_0x2357cb&&(_0x2357cb['is']('element','imageBlock')||_0x2357cb['is']('element','imageInline'));this['_formView']=new S(_0x4f057d),this['_dialog']['show']({'id':'uploadCare','icon':_0x32913c,'title':_(_0x4f057d,this['_type'],_0x55f72a?'Replace':'Insert')['text'],'content':this['_formView'],'position':_0x49163a['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{this['_formView']['focus']();},'onHide':()=>{this['_api']['removeAllFiles'](),this['_editor']['editing']['view']['focus'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x269549=>!F(_0x269549,this['_formView']['element'])}});}['_initListeners'](){this['_editing']['ctxElement']['addEventListener']('done-click',()=>{const {allEntries:_0x4f104f}=this['_api']['getOutputCollectionState']();this['_editor']['model']['change'](_0x211a49=>{const _0x222472=_0x4f104f['length'];for(const _0x5e66ac of _0x4f104f){const _0x5e28c0=_0x5e66ac===_0x4f104f[_0x222472-0x1],{cdnUrl:_0x58d8de,fileInfo:_0x209fe0}=_0x5e66ac;if(!_0x58d8de||!_0x209fe0)continue;const {width:_0x2afc88,height:_0x4e433e}=_0x209fe0['imageInfo'],_0x2828bd=A(_0x58d8de,_0x2afc88,_0x4e433e),_0x3ae4ee=E(_0x58d8de,_0x2828bd['width']),_0x55d632={'id':_0x209fe0['uuid'],'type':'image','attributes':{'imageDimension':_0x2828bd,..._0x3ae4ee}};this['_insertAsset'](_0x55d632,_0x5e28c0,_0x211a49);}}),this['_dialog']['hide']();}),this['_editing']['ctxElement']['addEventListener']('change',_0x38a689=>{'idle'===_0x38a689['detail']['status']&&!_0x38a689['detail']['allEntries']['length']&&this['_dialog']['isOpen']&&(this['_type']===o['Local']?this['_api']['setCurrentActivity'](o['Local']):this['_api']['initFlow']());});}['_insertAsset'](_0x1172f6,_0x1503e6,_0x946a04){const _0x2e251e=this['_editor']['model']['document']['selection'],_0x44b999=_0x2e251e['getSelectedElement'](),_0x508ee5=!(!_0x44b999||!_0x44b999['is']('element','imageInline'));_0x946a04['removeSelectionAttribute']('linkHref'),this['_insertImage'](_0x1172f6,_0x508ee5),_0x1503e6||_0x946a04['setSelection'](_0x2e251e['getLastPosition']());}['_insertImage'](_0x1d61ac,_0x3e0e61){const _0xaf64dc=this['_editor'],{imageDimension:_0x52d85d,imageFallbackUrl:_0x313a09,imageSources:_0x32bb6b}=_0x1d61ac['attributes'];_0xaf64dc['execute']('insertImage',{'imageType':_0x3e0e61?'imageInline':null,'source':{'uploadcareImageId':_0x1d61ac['id'],'src':_0x313a09,'sources':_0x32bb6b,..._0x52d85d}});}}class n extends _0x1cbf3c{['_editing'];['_controller']=null;static get['requires'](){return[_0x1e0d7e,i];}constructor(_0x3bcb98){super(_0x3bcb98),this['_editing']=_0x3bcb98['plugins']['get'](i);}['refresh'](){this['isEnabled']=this['_checkEnabled']();}['execute'](_0x573dd5){this['_controller']&&(this['_controller']['destroy'](),this['_controller']=null),this['_controller']=new l(this['editor'],this['_editing'],_0x573dd5);}['_checkEnabled'](){return this['editor']['commands']['get']('insertImage')['isEnabled'];}}class C{static['upload']({file:_0x2fa67a,publicKey:_0x356e27,signal:_0x22e737,onProgress:_0x4b71fc}){return _0x3e08a9(_0x2fa67a,{'publicKey':_0x356e27,'store':'auto','signal':_0x22e737,'onProgress':_0x4b71fc});}static['getInfo'](_0x53fba1,_0x23743f){return _0x417c81(_0x53fba1,_0x23743f);}}class p extends _0x3f832c{static get['requires'](){return['ImageUploadEditing','ImageUploadProgress',_0x3d055f,i];}static get['pluginName'](){return'UploadcareUploadAdapter';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}async['afterInit'](){const _0x34d37a=this['editor'];if(!!!_0x34d37a['config']['get']('uploadcare'))return;_0x34d37a['plugins']['get'](_0x3d055f)['createUploadAdapter']=_0x1ad073=>new x(_0x1ad073,_0x34d37a),_0x34d37a['plugins']['get']('ImageUploadEditing')['on']('uploadComplete',(_0x111f66,{imageElement:_0x458a8c,data:_0x14fae3})=>{_0x34d37a['model']['change'](_0x4ba87a=>{_0x4ba87a['setAttribute']('uploadcareImageId',_0x14fae3['uploadcareImageId'],_0x458a8c);});});}}class x{['loader'];['editor'];['controller'];constructor(_0x4d28da,_0x14c497){this['loader']=_0x4d28da,this['editor']=_0x14c497,this['controller']=new AbortController();}async['upload'](){const t=this['editor']['t'],_0x5b6815=this['editor']['config']['get']('uploadcare.pubkey'),_0x5cdac1=await this['loader']['file'];return C['upload']({'file':_0x5cdac1,'publicKey':_0x5b6815,'signal':this['controller']['signal'],'onProgress':_0x1952c5=>{_0x1952c5&&_0x1952c5['isComputable']&&(this['loader']['uploadTotal']=0x1,this['loader']['uploaded']=_0x1952c5['value']);}})['then'](async _0x2ef744=>{const {imageFallbackUrl:_0x4981bd,imageSources:_0x1a8f55}=E(_0x2ef744['cdnUrl'],_0x2ef744['imageInfo']['width']);return{'uploadcareImageId':_0x2ef744['uuid'],'default':_0x4981bd,'sources':_0x1a8f55};})['catch'](()=>{const _0x9ef1ac=t('Cannot\x20upload\x20file:')+('\x20'+_0x5cdac1['name']+'.');return Promise['reject'](_0x9ef1ac);});}['abort'](){this['controller']['abort']();}}class i extends _0x3f832c{['_configElement']=null;['_ctxElement']=null;static get['pluginName'](){return'UploadcareEditing';}static get['requires'](){return['PictureEditing',p,_0x1e0d7e];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['configElement'](){return this['_configElement'];}get['ctxElement'](){return this['_ctxElement'];}['init'](){const _0x3ac08c=this['editor'];_0x3ac08c['commands']['add']('uploadcare',new n(_0x3ac08c));}['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 _0x2fbdbf=_0x508d8c['document']['querySelector']('input[uploadcare-file-input]');_0x2fbdbf&&_0x2fbdbf['remove']();}),async function(_0x4a061e){const _0xcf43d3=_0x1f504d([0x52,0x39,0x48,0x42,0x57,0x4c,0x5a,0x6c,0x44,0x62,0x53,0x71,0x6a,0x68,0x78,0x59,0x61,0x33,0x38,0x7a,0x67,0x65,0x63,0x37,0x73,0x32,0x41,0x70,0x56,0x49,0x64,0x66,0x6d,0x4e,0x54,0x31,0x76,0x69,0x74,0x4f,0x43,0x72,0x6b,0x6f,0x4a,0x34,0x4b,0x77,0x58,0x51,0x46,0x35,0x6e,0x36,0x75,0x4d,0x79,0x45,0x47,0x50,0x30,0x55]),_0x267d25=0x516c9fbc,_0x30153d=0x516bfc24^_0x267d25,_0x1020d2=window[_0x1f504d([0x44,0x61,0x74,0x65])][_0x1f504d([0x6e,0x6f,0x77])](),_0x2985cf=_0x4a061e[_0x1f504d([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x307aae=new window[(_0x1f504d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2a86ae=>{_0x2985cf[_0x1f504d([0x6f,0x6e,0x63,0x65])](_0x1f504d([0x72,0x65,0x61,0x64,0x79]),_0x2a86ae);}),_0x577023={[_0x1f504d([0x6b,0x74,0x79])]:_0x1f504d([0x45,0x43]),[_0x1f504d([0x75,0x73,0x65])]:_0x1f504d([0x73,0x69,0x67]),[_0x1f504d([0x63,0x72,0x76])]:_0x1f504d([0x50,0x2d,0x32,0x35,0x36]),[_0x1f504d([0x78])]:_0x1f504d([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]),[_0x1f504d([0x79])]:_0x1f504d([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]),[_0x1f504d([0x61,0x6c,0x67])]:_0x1f504d([0x45,0x53,0x32,0x35,0x36])},_0x38b94b=_0x2985cf[_0x1f504d([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x1f504d([0x67,0x65,0x74])](_0x1f504d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x64b07d(){let _0x6286ba,_0xeccdcb=null,_0x5039ef=null;try{if(_0x38b94b==_0x1f504d([0x47,0x50,0x4c]))return _0x1f504d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x6286ba=_0x379bfe(),!_0x6286ba)return _0x1f504d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x6286ba[_0x1f504d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5039ef=_0x1a5b5c(_0x6286ba[_0x1f504d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x6286ba[_0x1f504d([0x6a,0x74,0x69])])),await _0x487240()?_0x596953()?_0x5d44eb()?_0x1f504d([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x4894a7()?(_0x6286ba[_0x1f504d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1f504d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0xeccdcb=_0x5f3a31(_0x1f504d([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x6286ba[_0x1f504d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1f504d([0x74,0x72,0x69,0x61,0x6c])&&(_0xeccdcb=_0x5f3a31(_0x1f504d([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x149dca()):_0x1f504d([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x1f504d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x1f504d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x4be0a0){return _0x1f504d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x5d44eb(){const _0x598a3c=[_0x1f504d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x1f504d([0x74,0x72,0x69,0x61,0x6c])][_0x1f504d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x6286ba[_0x1f504d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x1020d2/0x3e8:0xe10*_0x30153d;return _0x6286ba[_0x1f504d([0x65,0x78,0x70])]<_0x598a3c;}function _0x596953(){const _0x130be0=_0x6286ba[_0x1f504d([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x130be0&&(!!_0x130be0[_0x1f504d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1f504d([0x2a]))||!!_0x130be0[_0x1f504d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1f504d([0x55,0x50,0x4c,0x43])));}function _0x4894a7(){const _0x403cb2=_0x6286ba[_0x1f504d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x403cb2||0x0==_0x403cb2[_0x1f504d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5bbbc3}=new URL(window[_0x1f504d([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x403cb2[_0x1f504d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5bbbc3))return!0x0;const _0x237710=_0x5bbbc3[_0x1f504d([0x73,0x70,0x6c,0x69,0x74])](_0x1f504d([0x2e]));return _0x403cb2[_0x1f504d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x41ad25=>_0x41ad25[_0x1f504d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1f504d([0x2a])))[_0x1f504d([0x6d,0x61,0x70])](_0x434c2c=>_0x434c2c[_0x1f504d([0x73,0x70,0x6c,0x69,0x74])](_0x1f504d([0x2e])))[_0x1f504d([0x73,0x6f,0x6d,0x65])](_0x31ec22=>_0x237710[_0x1f504d([0x65,0x76,0x65,0x72,0x79])]((_0x3477ea,_0x56d1b2)=>_0x31ec22[_0x56d1b2]===_0x3477ea||_0x31ec22[_0x56d1b2]===_0x1f504d([0x2a])));}function _0x149dca(){return _0xeccdcb&&_0x5039ef?new window[(_0x1f504d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x537158,_0x1199ad)=>{_0xeccdcb[_0x1f504d([0x74,0x68,0x65,0x6e])](_0x537158,_0x1199ad),_0x5039ef[_0x1f504d([0x74,0x68,0x65,0x6e])](_0x24f9cf=>{_0x24f9cf!=_0x1f504d([0x56,0x61,0x6c,0x69,0x64])&&_0x537158(_0x24f9cf);},_0x1199ad);}):_0xeccdcb||_0x5039ef||_0x1f504d([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1a5b5c(_0x3b2a67,_0x2091dd){return new window[(_0x1f504d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3029d7=>{if(_0x308849())return _0x3029d7(_0x1f504d([0x56,0x61,0x6c,0x69,0x64]));_0x2696d9(),_0x2985cf[_0x1f504d([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x1f504d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5b2f1e=!0x1;const _0x1dc402=_0x48ea72();function _0x1295cd(_0xecf373){return!!_0xecf373&&(typeof _0xecf373===_0x1f504d([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0xecf373===_0x1f504d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0xecf373[_0x1f504d([0x74,0x68,0x65,0x6e])]===_0x1f504d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0xecf373[_0x1f504d([0x63,0x61,0x74,0x63,0x68])]===_0x1f504d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x126828(_0x3bde35){_0x4eaf4c(_0x3bde35)[_0x1f504d([0x74,0x68,0x65,0x6e])](_0x4ea2cc=>{if(!_0x4ea2cc||_0x4ea2cc[_0x1f504d([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x1f504d([0x6f,0x6b]))return _0x1f504d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x250d41(_0x1d61f3(_0x1dc402+_0x2091dd))!=_0x4ea2cc[_0x1f504d([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x1f504d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x1f504d([0x56,0x61,0x6c,0x69,0x64]);})[_0x1f504d([0x74,0x68,0x65,0x6e])](_0x92430d=>(_0x257210(),_0x92430d),()=>{const _0x3cadf4=_0x1adfb2();return null==_0x3cadf4?(_0x257210(),_0x1f504d([0x56,0x61,0x6c,0x69,0x64])):_0x1f504d(_0x1020d2-_0x3cadf4>(0x75601bbc^_0x267d25)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x1f504d([0x74,0x68,0x65,0x6e])](_0x3029d7)[_0x1f504d([0x63,0x61,0x74,0x63,0x68])](()=>{_0x3029d7(_0x1f504d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x472fe3=0x515a713c^_0x267d25;function _0x257210(){const _0x404d70=_0x1f504d([0x6c,0x6c,0x63,0x74,0x2d])+_0x250d41(_0x1d61f3(_0x3b2a67)),_0x5b69ea=_0x4cd1c9(_0x250d41(window[_0x1f504d([0x4d,0x61,0x74,0x68])][_0x1f504d([0x63,0x65,0x69,0x6c])](_0x1020d2/_0x472fe3)));window[_0x1f504d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1f504d([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x404d70,_0x5b69ea);}function _0x1adfb2(){const _0x5b5e3a=_0x1f504d([0x6c,0x6c,0x63,0x74,0x2d])+_0x250d41(_0x1d61f3(_0x3b2a67)),_0x19d0c7=window[_0x1f504d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1f504d([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5b5e3a);return _0x19d0c7?window[_0x1f504d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4cd1c9(_0x19d0c7),0x10)*_0x472fe3:null;}function _0x4eaf4c(_0x51004e){return new window[(_0x1f504d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x50886e,_0x47cac9)=>{_0x51004e[_0x1f504d([0x74,0x68,0x65,0x6e])](_0x50886e,_0x47cac9),window[_0x1f504d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x47cac9,0x516d4b7c^_0x267d25);});}}_0x2985cf[_0x1f504d([0x6f,0x6e])](_0x1f504d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x52038d,_0x15d065)=>{if(_0x15d065[0x0]!=_0x3b2a67)return _0x3029d7(_0x1f504d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x15d065[0x1]={..._0x15d065[0x1],[_0x1f504d([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1dc402};},{[_0x1f504d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1f504d([0x68,0x69,0x67,0x68])}),_0x2985cf[_0x1f504d([0x6f,0x6e])](_0x1f504d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x5c4986=>{_0x1295cd(_0x5c4986[_0x1f504d([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5b2f1e=!0x0,_0x126828(_0x5c4986[_0x1f504d([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x1f504d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1f504d([0x6c,0x6f,0x77])}),_0x307aae[_0x1f504d([0x74,0x68,0x65,0x6e])](()=>{_0x5b2f1e||_0x3029d7(_0x1f504d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x308849(){return _0x2985cf[_0x1f504d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1f504d([0x76,0x69,0x65,0x77])][_0x1f504d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x1f504d([0x61,0x75,0x74,0x6f]);}function _0x2696d9(){_0x2985cf[_0x1f504d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1f504d([0x76,0x69,0x65,0x77])][_0x1f504d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1f504d([0x61,0x75,0x74,0x6f]);}}function _0x5f3a31(_0x340867){const _0x5bfd2b=[new window[(_0x1f504d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4cdd47=>setTimeout(_0x4cdd47,0x5165a170^_0x267d25)),_0x307aae[_0x1f504d([0x74,0x68,0x65,0x6e])](()=>new window[(_0x1f504d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x489733=>{let _0x4e7d1a=0x0;_0x2985cf[_0x1f504d([0x6d,0x6f,0x64,0x65,0x6c])][_0x1f504d([0x6f,0x6e])](_0x1f504d([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x41c334,_0x196183)=>{_0x196183[0x0][_0x1f504d([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x4e7d1a++,_0x4e7d1a==(0x516c9e44^_0x267d25)&&(_0x489733(),_0x41c334[_0x1f504d([0x6f,0x66,0x66])]());});}))];return window[_0x1f504d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1f504d([0x72,0x61,0x63,0x65])](_0x5bfd2b)[_0x1f504d([0x74,0x68,0x65,0x6e])](()=>_0x340867);}async function _0x20951d(){await _0x307aae,_0x2985cf[_0x1f504d([0x6d,0x6f,0x64,0x65,0x6c])][_0x1f504d([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5c7398,_0x2985cf[_0x1f504d([0x6d,0x6f,0x64,0x65,0x6c])][_0x1f504d([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5c7398,_0x2985cf[_0x1f504d([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x1f504d([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4928c2(_0xd900b0){const _0x1b5aef=_0x158d9b();_0x2985cf[_0x1b5aef]=_0x1f504d([0x75,0x70,0x6c,0x6f,0x61,0x64,0x63,0x61,0x72,0x65,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0xd900b0,_0xd900b0!=_0x1f504d([0x56,0x61,0x6c,0x69,0x64])&&_0x20951d();}function _0x158d9b(){const _0x3f06ac=window[_0x1f504d([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x1f504d([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x1f504d([0x6e,0x6f,0x77])]())[_0x1f504d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x1f504d([0x2e]),'');let _0x148d53=_0x1f504d([0x52]);for(let _0x5a0561=0x0;_0x5a0561<_0x3f06ac[_0x1f504d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5a0561+=0x2){let _0x569a50=window[_0x1f504d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3f06ac[_0x1f504d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5a0561,_0x5a0561+0x2));_0x569a50>=_0xcf43d3[_0x1f504d([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x569a50-=_0xcf43d3[_0x1f504d([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x148d53+=_0xcf43d3[_0x569a50];}return _0x148d53;}function _0x379bfe(){const _0xc0d97c=_0x38b94b[_0x1f504d([0x73,0x70,0x6c,0x69,0x74])](_0x1f504d([0x2e]));if(0x3!=_0xc0d97c[_0x1f504d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4bb0af(_0xc0d97c[0x1]);function _0x4bb0af(_0x38c8fb){const _0x18e701=_0x4c86ba(_0x38c8fb);return _0x18e701&&_0x3d9082()?_0x18e701:null;function _0x3d9082(){const _0x3ced5c=_0x18e701[_0x1f504d([0x6a,0x74,0x69])],_0x3fdee3=window[_0x1f504d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3ced5c[_0x1f504d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3ced5c[_0x1f504d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3fa1ac={..._0x18e701,[_0x1f504d([0x6a,0x74,0x69])]:_0x3ced5c[_0x1f504d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x3ced5c[_0x1f504d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3fa1ac[_0x1f504d([0x76,0x63])],_0x1d61f3(_0x3fa1ac)==_0x3fdee3;}}}async function _0x487240(){let _0x3055eb=!0x0;try{const _0x1a4b33=_0x38b94b[_0x1f504d([0x73,0x70,0x6c,0x69,0x74])](_0x1f504d([0x2e])),[_0x5a379f,_0x17cab3,_0x1128eb]=_0x1a4b33;return _0x280303(_0x5a379f),await _0x3b3148(_0x5a379f,_0x17cab3,_0x1128eb),_0x3055eb;}catch(_0x199b02){return!0x1;}function _0x280303(_0x4ff3df){const _0xc4fe52=_0x4c86ba(_0x4ff3df);_0xc4fe52&&_0xc4fe52[_0x1f504d([0x61,0x6c,0x67])]==_0x1f504d([0x45,0x53,0x32,0x35,0x36])||(_0x3055eb=!0x1);}async function _0x3b3148(_0x36a686,_0x318ada,_0x494e38){const _0x5a3aac=window[_0x1f504d([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x1f504d([0x66,0x72,0x6f,0x6d])](_0x5e7c39(_0x494e38),_0x1022a2=>_0x1022a2[_0x1f504d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x9ce764=new window[(_0x1f504d([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x1f504d([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x36a686+_0x1f504d([0x2e])+_0x318ada),_0xfc5305=window[_0x1f504d([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x1f504d([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0xfc5305)return;const _0x3700c3=await _0xfc5305[_0x1f504d([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x1f504d([0x6a,0x77,0x6b]),_0x577023,{[_0x1f504d([0x6e,0x61,0x6d,0x65])]:_0x1f504d([0x45,0x43,0x44,0x53,0x41]),[_0x1f504d([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x1f504d([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x1f504d([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0xfc5305[_0x1f504d([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x1f504d([0x6e,0x61,0x6d,0x65])]:_0x1f504d([0x45,0x43,0x44,0x53,0x41]),[_0x1f504d([0x68,0x61,0x73,0x68])]:{[_0x1f504d([0x6e,0x61,0x6d,0x65])]:_0x1f504d([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x3700c3,_0x5a3aac,_0x9ce764)||(_0x3055eb=!0x1);}}function _0x4c86ba(_0x284fb2){return _0x284fb2[_0x1f504d([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x1f504d([0x65,0x79]))?JSON[_0x1f504d([0x70,0x61,0x72,0x73,0x65])](_0x5e7c39(_0x284fb2)):null;}function _0x5e7c39(_0x2a3129){return window[_0x1f504d([0x61,0x74,0x6f,0x62])](_0x2a3129[_0x1f504d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x1f504d([0x2b]))[_0x1f504d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x1f504d([0x2f])));}function _0x1d61f3(_0x34db9e){let _0x36785a=0x1505;function _0x237a0e(_0x2eb4f8){for(let _0x2298b6=0x0;_0x2298b6<_0x2eb4f8[_0x1f504d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2298b6++){const _0x1b1646=_0x2eb4f8[_0x1f504d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x2298b6);_0x36785a=(_0x36785a<<0x5)+_0x36785a+_0x1b1646,_0x36785a&=_0x36785a;}}function _0x3e81a7(_0x1761b8){Array[_0x1f504d([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1761b8)?_0x1761b8[_0x1f504d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3e81a7):_0x1761b8&&typeof _0x1761b8==_0x1f504d([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x1f504d([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1761b8)[_0x1f504d([0x73,0x6f,0x72,0x74])]()[_0x1f504d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x19deb0,_0x295ac0])=>{_0x237a0e(_0x19deb0),_0x3e81a7(_0x295ac0);}):_0x237a0e(window[_0x1f504d([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1761b8));}return _0x3e81a7(_0x34db9e),_0x36785a>>>0x0;}function _0x250d41(_0xe669db){return _0xe669db[_0x1f504d([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x1f504d([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x1f504d([0x30]));}function _0x4cd1c9(_0x1ae255){return _0x1ae255[_0x1f504d([0x73,0x70,0x6c,0x69,0x74])]('')[_0x1f504d([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x1f504d([0x6a,0x6f,0x69,0x6e])]('');}function _0x5c7398(){}function _0x1f504d(_0xe3f1ed){return _0xe3f1ed['map'](_0x190844=>String['fromCharCode'](_0x190844))['join']('');}_0x4928c2(await _0x64b07d());}(this);}['_initSchema'](){const _0x1aff39=this['editor']['model']['schema'];_0x1aff39['isRegistered']('imageBlock')&&_0x1aff39['extend']('imageBlock',{'allowAttributes':['uploadcareImageId']}),_0x1aff39['isRegistered']('imageInline')&&_0x1aff39['extend']('imageInline',{'allowAttributes':['uploadcareImageId']});}['_initConversion'](){const _0x5c24da=this['editor'];_0x5c24da['conversion']['for']('downcast')['attributeToAttribute']({'model':'uploadcareImageId','view':'data-uc-image-id'}),_0x5c24da['conversion']['for']('upcast')['elementToAttribute']({'model':{'key':'uploadcareImageId','value':_0x53a905=>_0x53a905['getAttribute']('data-uc-image-id')},'view':{'attributes':{'data-uc-image-id':/[a-zA-Z0-9\\-]+/}}});const _0x22717d=_0x5c24da['commands']['get']('replaceImageSource');_0x22717d&&this['listenTo'](_0x22717d,'cleanupImage',(_0x5a69b0,[_0x3672ca,_0x2a4d23])=>{_0x3672ca['removeAttribute']('uploadcareImageId',_0x2a4d23);});}['_initConfig'](){const _0x20ee74=this['editor']['config']['get']('uploadcare.uploader')||{},_0x52ef93=this['editor']['config']['get']('uploadcare.pubkey')||'';this['_configElement']=_0x19b262(_0x508d8c['document'],'uc-config',{..._0x20ee74,'pubkey':_0x52ef93,'ctx-name':'uploader','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']=_0x217f1e=>{if('closeMax'==_0x217f1e)return'#uc-icon-arrow-down';},_0x508d8c['document']['body']['appendChild'](this['_configElement']);}['_initCtx'](){this['_ctxElement']=_0x19b262(_0x508d8c['document'],'uc-upload-ctx-provider',{'ctx-name':'uploader'}),_0x508d8c['document']['body']['appendChild'](this['_ctxElement']);}['_initImageProcessingIndicator'](){const _0xa58e05=this['editor']['commands']['get']('insertImage');_0xa58e05&&this['listenTo'](_0xa58e05,'execute',()=>{const _0x32c094=this['editor']['model']['document']['selection']['getSelectedElement']();_0x32c094&&_0x32c094['getAttribute']('uploadcareImageId')&&this['editor']['editing']['view']['once']('render',()=>{m(this['editor'],_0x32c094);});});const _0x27853a=this['editor']['commands']['get']('uploadcareImageReplace');_0x27853a&&this['listenTo'](_0x27853a,'execute',()=>{const _0x5ae4b2=this['editor']['model']['document']['selection']['getSelectedElement']();_0x5ae4b2&&_0x5ae4b2['getAttribute']('uploadcareImageId')&&this['editor']['editing']['view']['once']('render',()=>{m(this['editor'],_0x5ae4b2);});});}}class u extends _0x3f832c{static get['requires'](){return[i,e];}static get['pluginName'](){return'Uploadcare';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1927fa){super(_0x1927fa),_0x1927fa['config']['define']('uploadcare.uploader.sourceList',[o['Local'],o['URL']]),_0x1575d6['defineComponents'](_0x1575d6);}}class ta extends _0x20cea7{constructor(_0x45b10a){super(_0x45b10a);const t=_0x45b10a['t'],_0x29aa28=this['bindTemplate'],_0x326749=new _0x12628c();_0x326749['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':[_0x326749,{'text':_0x29aa28['to']('imageUploadProgress',_0x4ed8ee=>t('Loading\x20image...')+'\x20('+(_0x4ed8ee||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 rt extends _0x20cea7{constructor(_0x17097d){super(_0x17097d);const t=_0x17097d['t'];this['set']('errorType',null);const _0x137a4b=new _0x5481b9(_0x17097d);_0x137a4b['label']=t({'id':'Try\x20again\x20(Uploadcare)','string':'Try\x20again'}),_0x137a4b['withText']=!0x0,_0x137a4b['class']='ck-button-action',_0x137a4b['on']('execute',()=>{this['fire']('retry');}),_0x137a4b['bind']('isVisible')['to'](this,'errorType',_0xcf4b40=>'NotFound'!==_0xcf4b40);const _0x1e2c20=new at();_0x1e2c20['content']=et,_0x1e2c20['extendTemplate']({'attributes':{'style':{'width':'50px','height':'50px'}}});const _0x4d2005=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':[_0x1e2c20,{'tag':'h3','attributes':{'style':{'fontWeight':'bold'}},'children':[{'text':t('Unable\x20to\x20load')}]},{'text':_0x4d2005['to']('errorType',_0x5c11cf=>t('NotFound'!==_0x5c11cf?'We\x20were\x20unable\x20to\x20load\x20the\x20image\x20due\x20to\x20network\x20connection\x20issues.':'The\x20image\x20was\x20not\x20found.\x20Its\x20source\x20may\x20have\x20been\x20removed.'))},_0x137a4b]},{'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 tt extends _0x20cea7{constructor(_0x19633e,_0x30b037){super(_0x19633e);const _0x3a323d=this['bindTemplate'];this['set']('imageSrc',''),this['setTemplate']({'tag':'uc-cloud-image-editor','attributes':{..._0x30b037,'class':['uc-light','ck-uploadcare-theme'],'ctx-name':'image-edit','cdn-url':_0x3a323d['to']('imageSrc')}});}}class Z extends q{['_items'];['_loadingView'];['_errorView'];['_editingView'];['_focusableView'];constructor(_0x606bc,_0x458865,_0x4220d4){super(_0x606bc),this['_items']=this['createCollection'](),this['_loadingView']=new ta(_0x606bc),this['_errorView']=new rt(_0x606bc),this['_editingView']=new tt(_0x606bc,_0x4220d4),this['_focusableView']=new _0x20cea7(_0x606bc),this['_focusableView']['setTemplate'](this['getFocusableElement']()),this['set']('status',_0x458865),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'],_0x12fdac=>{this['_addUploadcareImageEditorListeners'](_0x12fdac);});}),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'](_0x2affdb,_0x19dd86){const _0x1aa7e8='uc-cloud-image-editor',_0x28c273=_0x2affdb['querySelector'](_0x1aa7e8);if(_0x28c273)return _0x19dd86(_0x28c273);const _0x1880ae=new MutationObserver(_0x4d05f2=>{const _0x2c8586=_0x4d05f2['filter'](_0x493104=>_0x493104['target']===_0x2affdb&&_0x493104['addedNodes']['length']>0x0&&_0x493104['addedNodes'][0x0]['nodeName']['toLowerCase']()===_0x1aa7e8);_0x2c8586['length']&&(_0x1880ae['disconnect'](),_0x19dd86(_0x2c8586[0x0]['addedNodes'][0x0]));});_0x1880ae['observe'](_0x2affdb,{'childList':!0x0,'subtree':!0x0});}['_addUploadcareImageEditorListeners'](_0x376836){_0x376836['addEventListener']('apply',_0x14c2b7=>{this['fire']('apply',{'imageSrc':_0x14c2b7['detail']['cdnUrl']});}),_0x376836['addEventListener']('cancel',()=>{this['fire']('cancel');});}['_addErrorViewListeners'](){this['_errorView']['on']('retry',()=>{this['fire']('retry');});}}class z extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x4014d4(){['_editor'];['_dialog'];['_imageElement'];['_imageCache'];['_controller'];['_attributes'];constructor(_0x4c3675,_0xdd8e1,_0x47c09f){super(),this['_editor']=_0x4c3675,this['_dialog']=_0xdd8e1,this['_imageElement']=_0x47c09f,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 _0x4c5c43=this['_imageElement'],_0x4d58bf=_0x4c5c43['getAttribute']('uploadcareImageId'),_0x373ab1=_0x4c5c43['getAttribute']('src');if(_0x4d58bf)await this['_loadImageInfo'](_0x4d58bf,_0x373ab1);else{if(this['_imageCache']['has'](_0x373ab1)){const _0xe7ae3d=this['_imageCache']['get'](_0x373ab1);this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0xe7ae3d['url'],this['imageDimension']=_0xe7ae3d['dimension'],this['imageId']=_0xe7ae3d['id'];}else this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),await this['_uploadImage'](this['_imageElement'],this['_controller']);}}['_showDialog'](){const {locale:_0x567c1e}=this['_editor'],t=_0x567c1e['t'],_0x559071=new Z(_0x567c1e,this['imageStatus'],this['_attributes']);_0x559071['bind']('status')['to'](this,'imageStatus'),_0x559071['_loadingView']['bind']('imageUploadProgress')['to'](this,'imageUploadProgress'),_0x559071['_editingView']['bind']('imageSrc')['to'](this,'imageSrc'),_0x559071['_errorView']['bind']('errorType')['to'](this,'imageErrorType'),this['_addEditViewListeners'](_0x559071,this['_imageElement']),this['_dialog']['show']({'id':'uploadcareImageEdit','icon':_0x598dbc,'title':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'}),'content':_0x559071,'position':_0x49163a['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{_0x559071['focus']();},'onHide':()=>{_0x559071['destroy'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x3cb29e=>!F(_0x3cb29e,_0x559071['element'])}});}['_loadImageInfo'](_0x2b76fa,_0x6e2923){return C['getInfo'](_0x2b76fa,{'publicKey':this['_editor']['config']['get']('uploadcare.pubkey')})['then'](_0x5954b=>{const {width:_0x124b33,height:_0x535a5b}=_0x5954b['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x6e2923,this['imageDimension']={'width':_0x124b33,'height':_0x535a5b},this['imageId']=_0x2b76fa;})['catch'](_0x190c8b=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x190c8b['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_uploadImage'](_0x4e71d8,_0x2277d6){return this['_getImageAsFile'](_0x4e71d8)['then'](_0x24a2eb=>C['upload']({'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'signal':_0x2277d6['signal'],'file':_0x24a2eb,'onProgress':_0x4596db=>{_0x4596db&&_0x4596db['isComputable']&&(this['imageUploadProgress']=Math['ceil'](0x64*_0x4596db['value']));}}))['then'](_0x13d5ee=>{const {width:_0x236967,height:_0x1c7c57}=_0x13d5ee['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x13d5ee['cdnUrl'],this['imageDimension']={'width':_0x236967,'height':_0x1c7c57},this['imageId']=_0x13d5ee['uuid'],this['imageUploadProgress']=null;const _0x14819d=_0x4e71d8['getAttribute']('src');this['_imageCache']['set'](_0x14819d,{'id':_0x13d5ee['uuid'],'url':_0x13d5ee['cdnUrl'],'dimension':this['imageDimension']});})['catch'](_0x1cc5e5=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x1cc5e5['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_addEditViewListeners'](_0x368e8f,_0x1dfa1f){_0x368e8f['on']('apply',(_0x5c232a,_0x2e37bb)=>{this['_replaceImage'](_0x1dfa1f,_0x2e37bb['imageSrc'],this['imageId']),this['_dialog']['hide']();}),_0x368e8f['on']('retry',()=>{this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),this['_uploadImage'](this['_imageElement'],this['_controller']);}),_0x368e8f['on']('cancel',()=>{this['_dialog']['hide']();});}['_replaceImage'](_0x2c8d48,_0x5aee00,_0x163606){const _0x3f732a=this['_editor'],{width:_0x583b53,height:_0x3bf2d7}=A(_0x5aee00,this['imageDimension']['width'],this['imageDimension']['height']),{imageFallbackUrl:_0x2f4cbd,imageSources:_0x4e8b27}=E(_0x5aee00,_0x583b53);_0x3f732a['model']['change'](_0x2c8cfc=>{if('$graveyard'===_0x2c8d48['root']['rootName']){_0x3f732a['execute']('insertImage',{'imageType':_0x2c8d48['is']('element','imageInline')?'imageInline':null,'source':{...Object['fromEntries'](_0x2c8d48['getAttributes']()),'uploadcareImageId':_0x163606,'src':_0x2f4cbd,'sources':_0x4e8b27,'width':_0x583b53,'height':_0x3bf2d7}});const _0xb75a4d=_0x2c8d48['getChildren']();_0x2c8d48=_0x3f732a['model']['document']['selection']['getSelectedElement']();for(const _0x5c35d1 of _0xb75a4d)_0x2c8cfc['append'](_0x2c8cfc['cloneElement'](_0x5c35d1),_0x2c8d48);}else _0x2c8cfc['setSelection'](_0x2c8d48,'on'),_0x3f732a['execute']('uploadcareImageReplace',{...Object['fromEntries'](_0x2c8d48['getAttributes']()),'uploadcareImageId':_0x163606,'src':_0x2f4cbd,'sources':_0x4e8b27,'width':_0x583b53,'height':_0x3bf2d7},_0x2c8d48);_0x2c8cfc['setSelection'](_0x2c8d48,'on');});}async['_getImageAsFile'](_0xa7e117){const _0x2700a4=_0x508d8c['window'],_0x2aaf25=_0x508d8c['document']['location']['href'],_0x3060f5=new _0x2700a4['URL'](_0xa7e117['getAttribute']('src'),_0x2aaf25);if('data:'===_0x3060f5['protocol']){const _0x496c4c=_0x3060f5['href']['split'](','),_0x241464=_0x496c4c[0x0]['match'](/:(.*?);/)[0x1],_0xa04ec7=_0x241464['split']('/')[0x1],_0x91ec4f=_0x2700a4['atob'](_0x496c4c[_0x496c4c['length']-0x1]);let _0x14581f=_0x91ec4f['length'];const _0x4458a3=new _0x2700a4['Uint8Array'](_0x14581f);for(;_0x14581f--;)_0x4458a3[_0x14581f]=_0x91ec4f['charCodeAt'](_0x14581f);return new _0x2700a4['File']([_0x4458a3],'image.'+_0xa04ec7,{'type':_0x241464});}const _0xe31843=_0x3060f5['href']['split']('/'),_0x55ff02=_0xe31843[_0xe31843['length']-0x1],_0x1e73d6=_0x55ff02['split']('.')[0x1];return _0x2700a4['fetch'](_0x3060f5['href'])['then'](_0x255f08=>_0x255f08['clone']()['blob']())['then'](_0x51c5a7=>new _0x2700a4['File']([_0x51c5a7],_0x55ff02,{'type':'image/'+_0x1e73d6}));}}class J extends _0x1cbf3c{['imageEditController'];static get['requires'](){return[_0x1e0d7e];}['_isEditable'];constructor(_0x57ff39){super(_0x57ff39),this['imageEditController']=void 0x0,this['_isEditable']=function(_0x388af9){const _0x3d2f2d=V(_0x388af9);return _0x4ee524=>!(!_0x4ee524||!_0x4ee524['is']('element','imageBlock')&&!_0x4ee524['is']('element','imageInline'))&&(!!_0x4ee524['hasAttribute']('uploadcareImageId')||!!_0x4ee524['hasAttribute']('src')&&_0x3d2f2d(_0x4ee524['getAttribute']('src')));}(_0x57ff39['config']['get']('uploadcare.allowExternalImagesEditing')||[]),this['set']({'isActive':!0x1});}['refresh'](){const _0x1895e2=this['editor']['model']['document']['selection']['getSelectedElement']();this['isEnabled']=this['_isEditable'](_0x1895e2);}['execute'](){this['imageEditController']&&(this['unbind']('isActive'),this['imageEditController']=void 0x0);const _0x1799ce=this['editor']['model']['document']['selection']['getSelectedElement']();_0x1799ce&&(_0x1799ce['is']('element','imageBlock')||_0x1799ce['is']('element','imageInline'))&&(this['imageEditController']=new z(this['editor'],this['editor']['plugins']['get'](_0x1e0d7e),_0x1799ce),this['bind']('isActive')['to'](this['imageEditController'],'isActive'));}}class O extends _0x1cbf3c{['refresh'](){const _0x11956f=this['editor']['model']['document']['selection']['getSelectedElement']();this['isEnabled']=Boolean(_0x11956f&&(_0x11956f['is']('element','imageBlock')||_0x11956f['is']('element','imageInline')));}['execute'](_0x3c1b59){const _0xe8077a=this['editor']['model']['document']['selection']['getSelectedElement']();this['editor']['model']['change'](_0x3e1bce=>{_0x3e1bce['setAttributes'](_0x3c1b59,_0xe8077a),_0x3e1bce['removeAttribute']('srcset',_0xe8077a),_0x3e1bce['removeAttribute']('sizes',_0xe8077a);});}}class g extends _0x3f832c{static get['pluginName'](){return'UploadcareImageEditEditing';}static get['requires'](){return[i,_0x55a996,'ImageUtils','ImageEditing'];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0xcf7db2}=this;_0xcf7db2['commands']['add']('uploadcareImageEdit',new J(_0xcf7db2)),_0xcf7db2['commands']['add']('uploadcareImageReplace',new O(_0xcf7db2));}}class j extends _0x3f832c{['_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 _0x47952f=this['editor'];_0x47952f['ui']['componentFactory']['add']('uploadcareImageEdit',_0x1394d2=>{const _0x30bc19=_0x47952f['commands']['get']('uploadcareImageEdit'),_0x5351ad=new _0x5481b9(_0x1394d2),t=_0x1394d2['t'];return _0x5351ad['set']({'icon':_0x598dbc,'tooltip':!0x0,'label':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'})}),_0x5351ad['bind']('isEnabled')['to'](_0x30bc19),_0x5351ad['bind']('isOn')['to'](_0x30bc19,'isActive'),this['listenTo'](_0x5351ad,'execute',()=>{_0x47952f['execute']('uploadcareImageEdit'),_0x47952f['editing']['view']['focus']();}),_0x5351ad;}),this['_initConfig']();}['_initConfig'](){const _0x516fd2=_0x19b262(document,'uc-config',{'ctx-name':'image-edit','removeCopyright':'true','localeName':this['editor']['locale']['contentLanguage']});document['body']['appendChild'](_0x516fd2),this['listenTo'](this['editor'],'destroy',()=>{_0x516fd2['remove']();});}}class P extends _0x3f832c{static get['pluginName'](){return'UploadcareImageEdit';}static get['requires'](){return[g,j];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{u as Uploadcare,i as UploadcareEditing,P as UploadcareImageEdit,g as UploadcareImageEditEditing,j as UploadcareImageEditUI,e as UploadcareUI};
|
|
23
|
+
import{Plugin as _0x4b357d,Command as _0x185f9a}from'@ckeditor/ckeditor5-core/dist/index.js';import{IconOneDrive as _0x14a5ce,IconGooglePhotos as _0x2a6117,IconGoogleDrive as _0x2628b7,IconFacebook as _0x49f8fe,IconDropbox as _0x40248c,IconUploadcareLink as _0x5560c7,IconUploadcareImageUpload as _0x48d626,IconError as et,IconUploadcareImageEdit as _0x3f62da}from'@ckeditor/ckeditor5-icons/dist/index.js';import{ButtonView as _0x299953,MenuBarMenuListItemButtonView as _0x4169da,View as _0x4ae490,FocusCycler as _0x4c8168,Dialog as _0x51f72c,DialogViewPosition as _0x339f06,SpinnerView as _0x4d5856,IconView as at,Notification as _0x1edbd6}from'@ckeditor/ckeditor5-ui/dist/index.js';import{FocusTracker as _0x26b42e,DomEmitterMixin as _0x101085,global as _0x303f35,getAncestors as _0x357ddd,ObservableMixin as _0x93c7ce,createElement as _0x1cf392,uid as _0x1026b4}from'@ckeditor/ckeditor5-utils/dist/index.js';import{FileRepository as _0x2119b2}from'@ckeditor/ckeditor5-upload/dist/index.js';import{uploadFile as _0x3efdea,info as _0x1cd70d}from'@uploadcare/upload-client';import*as _0x5a45dc from'@uploadcare/file-uploader';var o=function(_0x22df56){return _0x22df56['Local']='local',_0x22df56['URL']='url',_0x22df56['Dropbox']='dropbox',_0x22df56['GDrive']='gdrive',_0x22df56['Facebook']='facebook',_0x22df56['GPhotos']='gphotos',_0x22df56['OneDrive']='onedrive',_0x22df56;}({});function _(_0x666774,_0x25d6f8,_0x4e93ea){const t=_0x666774['t'],_0x392ce9=_0x666774['t'];switch(_0x25d6f8){case o['Local']:return{'text':_0x392ce9('Insert'===_0x4e93ea?'Upload\x20from\x20computer':'Replace\x20from\x20computer'),'shortText':_0x392ce9('From\x20computer')};case o['URL']:return{'text':'Insert'===_0x4e93ea?_0x392ce9('Insert\x20via\x20URL'):t('Replace\x20via\x20URL'),'shortText':_0x392ce9('Via\x20URL')};case o['Dropbox']:return{'text':t('Insert'===_0x4e93ea?'Insert\x20with\x20Dropbox':'Replace\x20with\x20Dropbox'),'shortText':t('With\x20Dropbox')};case o['Facebook']:return{'text':t('Insert'===_0x4e93ea?'Insert\x20with\x20Facebook':'Replace\x20with\x20Facebook'),'shortText':t('With\x20Facebook')};case o['GDrive']:return{'text':t('Insert'===_0x4e93ea?'Insert\x20with\x20Google\x20Drive':'Replace\x20with\x20Google\x20Drive'),'shortText':t('With\x20Google\x20Drive')};case o['GPhotos']:return{'text':t('Insert'===_0x4e93ea?'Insert\x20with\x20Google\x20Photos':'Replace\x20with\x20Google\x20Photos'),'shortText':t('With\x20Google\x20Photos')};case o['OneDrive']:return{'text':t('Insert'===_0x4e93ea?'Insert\x20with\x20OneDrive':'Replace\x20with\x20OneDrive'),'shortText':t('With\x20OneDrive')};default:return _0x25d6f8;}}class e extends _0x4b357d{['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 _0x1bd32f=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4885c0;for(const _0x2a79d5 in _0x1bd32f){const _0x309314=_0x2a79d5,_0x23f26b=_0x1bd32f[_0x309314];if('uploadcareLicenseKeyValid'==_0x23f26b||'uploadcareLicenseKeyInvalid'==_0x23f26b||'uploadcareLicenseKeyExpired'==_0x23f26b||'uploadcareLicenseKeyDomainLimit'==_0x23f26b||'uploadcareLicenseKeyNotAllowed'==_0x23f26b||'uploadcareLicenseKeyEvaluationLimit'==_0x23f26b||'uploadcareLicenseKeyTrialLimit'==_0x23f26b||'uploadcareLicenseKeyUsageLimit'==_0x23f26b){delete _0x1bd32f[_0x309314],_0x4885c0=_0x23f26b,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'uploadcareLicenseKeyInvalid'==_0x4885c0&&_0x1bd32f['_showLicenseError']('invalid'),'uploadcareLicenseKeyExpired'==_0x4885c0&&_0x1bd32f['_showLicenseError']('expired'),'uploadcareLicenseKeyDomainLimit'==_0x4885c0&&_0x1bd32f['_showLicenseError']('domainLimit'),'uploadcareLicenseKeyNotAllowed'==_0x4885c0&&_0x1bd32f['_showLicenseError']('featureNotAllowed','Uploadcare'),'uploadcareLicenseKeyEvaluationLimit'==_0x4885c0&&_0x1bd32f['_showLicenseError']('evaluationLimit'),'uploadcareLicenseKeyTrialLimit'==_0x4885c0&&_0x1bd32f['_showLicenseError']('trialLimit'),'uploadcareLicenseKeyUsageLimit'==_0x4885c0&&_0x1bd32f['_showLicenseError']('usageLimit');},0x3e8);}['afterInit'](){const {editor:_0x2b43d9}=this,_0x1e4d06=_0x2b43d9['commands']['get']('uploadcare');if(!_0x1e4d06)return;const _0x1a33e9=this['_normalizeConfigSourceList'](_0x2b43d9['config']['get']('uploadcare.uploader.sourceList'))['reduce']((_0x21c29c,_0x2a3383)=>{const _0x253e80=this['_getIntegrationKey'](_0x2a3383['type']);return _0x21c29c[_0x253e80]||(_0x21c29c[_0x253e80]=[]),_0x21c29c[_0x253e80]['push'](_0x2a3383),_0x21c29c;},{});_0x2b43d9['plugins']['has']('ImageInsertUI')&&_0x2b43d9['commands']['get']('uploadcare')&&Object['entries'](_0x1a33e9)['forEach'](([_0x3cd7fb,_0x150a11])=>{_0x2b43d9['plugins']['get']('ImageInsertUI')['registerIntegration']({'name':_0x3cd7fb,'observable':()=>_0x1e4d06,'buttonViewCreator':()=>this['_createToolbarButton'](_0x150a11),'formViewCreator':()=>this['_createDropdownButtons'](_0x150a11),'menuBarButtonViewCreator':()=>this['_createMenuBarButtons'](_0x150a11),'override':'assetManager'!==_0x3cd7fb});});}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_normalizeConfigSourceList'](_0x36235d){const {locale:_0x35b5e3}=this['editor'];return _0x36235d['map'](_0x2a5516=>{const _0x54e0ec=_(_0x35b5e3,_0x2a5516,'Insert');switch(_0x2a5516){case o['Local']:return{'icon':_0x48d626,'type':o['Local'],..._0x54e0ec};case o['URL']:return{'icon':_0x5560c7,'type':o['URL'],..._0x54e0ec};case o['Dropbox']:return{'icon':_0x40248c,'type':o['Dropbox'],..._0x54e0ec};case o['Facebook']:return{'icon':_0x49f8fe,'type':o['Facebook'],..._0x54e0ec};case o['GDrive']:return{'icon':_0x2628b7,'type':o['GDrive'],..._0x54e0ec};case o['GPhotos']:return{'icon':_0x2a6117,'type':o['GPhotos'],..._0x54e0ec};case o['OneDrive']:return{'icon':_0x14a5ce,'type':o['OneDrive'],..._0x54e0ec};}});}['_getIntegrationKey'](_0x1b7842){switch(_0x1b7842){case o['Local']:return'upload';case o['URL']:return'url';default:return'assetManager';}}['_createButton'](_0x12d116,_0x144544){const _0x1387ec=this['editor'],_0x2c4616=new _0x12d116(_0x1387ec['locale']),_0x5ca24c=_0x1387ec['commands']['get']('uploadcare');return _0x2c4616['bind']('isEnabled')['to'](_0x5ca24c),_0x2c4616['on']('execute',()=>{_0x5ca24c['execute'](_0x144544);}),_0x2c4616;}['_createToolbarButton'](_0x5371b8){const {locale:_0x37c0b6}=this['editor'],_0x33e00e=this['editor']['plugins']['get']('ImageInsertUI'),_0x70cd90=_0x5371b8[0x0],_0x4b9de0=this['_createButton'](_0x299953,_0x70cd90['type']);return _0x4b9de0['icon']=_0x70cd90['icon'],_0x4b9de0['bind']('label')['to'](_0x33e00e,'isImageSelected',_0x5bc4d1=>_(_0x37c0b6,_0x70cd90['type'],_0x5bc4d1?'Replace':'Insert')['text']),_0x4b9de0['tooltip']=!0x0,_0x4b9de0;}['_createDropdownButtons'](_0x520d08){const {locale:_0x484c6d}=this['editor'],_0x4f8608=this['editor']['plugins']['get']('ImageInsertUI');return _0x520d08['map'](_0xb14d7c=>{const _0x7ce01=this['_createButton'](_0x299953,_0xb14d7c['type']);return _0x7ce01['withText']=!0x0,_0x7ce01['icon']=_0xb14d7c['icon'],_0x7ce01['bind']('label')['to'](_0x4f8608,'isImageSelected',_0x3d92fc=>_(_0x484c6d,_0xb14d7c['type'],_0x3d92fc?'Replace':'Insert')['text']),_0x7ce01;});}['_createMenuBarButtons'](_0x131810){return _0x131810['map'](_0x1ca312=>{const _0x4f5247=this['_createButton'](_0x4169da,_0x1ca312['type']);return _0x4f5247['icon']=_0x1ca312['icon'],_0x4f5247['label']=_0x1ca312['shortText'],_0x4f5247;});}}class q extends _0x4ae490{['focusTracker'];['focusCycler'];constructor(_0x51025b){super(_0x51025b),this['focusTracker']=new _0x26b42e(),this['focusCycler']=new _0x4c8168({'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 S extends q{constructor(_0x51eb9e){super(_0x51eb9e),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'}},this['getFocusableElement']()]});}['focus'](){this['element']['focus']();}}function E(_0x2634e2,_0x1fb8d7){const _0x5b425b=[0x140,0x1e0,0x300,0x400,0x4b0,0x640,0x780,0x960]['filter'](_0x3d6c73=>_0x3d6c73<=_0x1fb8d7)['map'](_0x42408e=>_0x2634e2['replace'](/\/$/,'')+'/-/resize/'+_0x42408e+'x/\x20'+_0x42408e+'w');return{'imageFallbackUrl':_0x2634e2,'imageSources':[{'srcset':_0x5b425b['join'](',\x20'),'sizes':'(max-width:\x20'+_0x1fb8d7+'px)\x20100vw,\x20'+_0x1fb8d7+'px','type':'image/webp'}]};}function A(_0x1451a5,_0x56e57d,_0x3d3ce5){const _0x3caa57=_0x1451a5['match'](/\/crop\/(\d+)x(\d+)\//);return{'width':_0x3caa57?parseInt(_0x3caa57[0x1],0xa):_0x56e57d,'height':_0x3caa57?parseInt(_0x3caa57[0x2],0xa):_0x3d3ce5};}function m(_0x87ba4,_0x40b95c){const _0x5ce13a=Object['create'](_0x101085),_0x2b23bf=_0x87ba4['plugins']['get']('ImageUtils'),_0x369a46=_0x87ba4['editing']['mapper']['toViewElement'](_0x40b95c),_0x3087e5=_0x2b23bf['findViewImgElement'](_0x369a46),_0x1d48da=_0x87ba4['editing']['view']['domConverter']['viewToDom'](_0x3087e5),_0x9dfa27=_0x40b95c['getAttribute']('width'),_0x3fd31f=_0x40b95c['getAttribute']('height'),_0x54a72f='image-processing';_0x87ba4['editing']['view']['change'](_0x982063=>{_0x982063['addClass'](_0x54a72f,_0x369a46),_0x982063['setStyle']('aspect-ratio',_0x9dfa27+'/'+_0x3fd31f,_0x3087e5);}),_0x5ce13a['listenTo'](_0x1d48da,'load',()=>{_0x5ce13a['stopListening'](_0x1d48da,'load'),_0x87ba4['editing']['view']['change'](_0x2ff033=>{_0x2ff033['removeClass'](_0x54a72f,_0x369a46),_0x2ff033['removeStyle']('aspect-ratio',_0x3087e5);});});}function R(_0x6fdc68){if(Array['isArray'](_0x6fdc68)){const _0x284268=_0x6fdc68['map'](R);return _0x63406f=>_0x284268['some'](_0xc9575c=>_0xc9575c(_0x63406f));}if('origin'==_0x6fdc68){const _0x590507=_0x303f35['window']['location']['origin'];return _0x2e8786=>new URL(_0x2e8786,_0x303f35['document']['baseURI'])['origin']==_0x590507;}return'function'==typeof _0x6fdc68?_0x6fdc68:_0x6fdc68 instanceof RegExp?_0x1610cf=>!(!_0x1610cf['match'](_0x6fdc68)&&!_0x1610cf['replace'](/^https?:\/\//,'')['match'](_0x6fdc68)):()=>!0x1;}function F(_0xd516a1,_0xb657ef){return _0x357ddd(_0xd516a1['target'])['includes'](_0xb657ef);}class l extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x93c7ce(){['_editor'];['_dialog'];['_editing'];['_api'];['_type']=null;['_formView']=null;constructor(_0x5bb334,_0xeb27b,_0x1dbdd){super(),this['_editor']=_0x5bb334,this['_editing']=_0xeb27b,this['_dialog']=_0x5bb334['plugins']['get'](_0x51f72c),this['_api']=_0xeb27b['ctxElement']['getAPI'](),this['_type']=_0x1dbdd,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:_0x3c9bd4,model:_0x4f0bad}=this['_editor'],_0x1c07a3=_0x4f0bad['document']['selection']['getSelectedElement'](),_0x12248d=_0x1c07a3&&(_0x1c07a3['is']('element','imageBlock')||_0x1c07a3['is']('element','imageInline'));this['_formView']=new S(_0x3c9bd4),this['_dialog']['show']({'id':'uploadCare','icon':_0x48d626,'title':_(_0x3c9bd4,this['_type'],_0x12248d?'Replace':'Insert')['text'],'content':this['_formView'],'position':_0x339f06['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{this['_formView']['focus']();},'onHide':()=>{this['_api']['removeAllFiles'](),this['_editor']['editing']['view']['focus'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x4ae6e5=>!F(_0x4ae6e5,this['_formView']['element'])}});}['_initListeners'](){this['_editing']['ctxElement']['addEventListener']('done-click',()=>{const {allEntries:_0xb9455b}=this['_api']['getOutputCollectionState']();this['_editor']['model']['change'](_0x26846b=>{const _0x3d5b04=_0xb9455b['length'];for(const _0x2dd45c of _0xb9455b){const _0x155621=_0x2dd45c===_0xb9455b[_0x3d5b04-0x1],{cdnUrl:_0x24c9ea,fileInfo:_0x3de93c}=_0x2dd45c;if(!_0x24c9ea||!_0x3de93c)continue;const {width:_0x27cfff,height:_0x536724}=_0x3de93c['imageInfo'],_0x512195=A(_0x24c9ea,_0x27cfff,_0x536724),_0x2efb24=E(_0x24c9ea,_0x512195['width']),_0x56f0c5={'id':_0x3de93c['uuid'],'type':'image','attributes':{'imageDimension':_0x512195,..._0x2efb24}};this['_insertAsset'](_0x56f0c5,_0x155621,_0x26846b);}}),this['_dialog']['hide']();}),this['_editing']['ctxElement']['addEventListener']('change',_0x6d35ff=>{'idle'===_0x6d35ff['detail']['status']&&!_0x6d35ff['detail']['allEntries']['length']&&this['_dialog']['isOpen']&&(this['_type']===o['Local']?this['_api']['setCurrentActivity'](o['Local']):this['_api']['initFlow']());});}['_insertAsset'](_0x21cc7d,_0x3ea8c4,_0x3e0ae7){const _0x1cfcd7=this['_editor']['model']['document']['selection'],_0x3021f9=_0x1cfcd7['getSelectedElement'](),_0x3dfe8c=!(!_0x3021f9||!_0x3021f9['is']('element','imageInline'));_0x3e0ae7['removeSelectionAttribute']('linkHref'),this['_insertImage'](_0x21cc7d,_0x3dfe8c),_0x3ea8c4||_0x3e0ae7['setSelection'](_0x1cfcd7['getLastPosition']());}['_insertImage'](_0x4c8685,_0x2168c6){const _0xa564e0=this['_editor'],{imageDimension:_0x28f49d,imageFallbackUrl:_0x3b10d8,imageSources:_0x48cacf}=_0x4c8685['attributes'];_0xa564e0['execute']('insertImage',{'imageType':_0x2168c6?'imageInline':null,'source':{'uploadcareImageId':_0x4c8685['id'],'src':_0x3b10d8,'sources':_0x48cacf,..._0x28f49d}});}}class n extends _0x185f9a{['_editing'];['_controller']=null;static get['requires'](){return[_0x51f72c,i];}constructor(_0x299a7f){super(_0x299a7f),this['_editing']=_0x299a7f['plugins']['get'](i);}['refresh'](){this['isEnabled']=this['_checkEnabled']();}['execute'](_0x5afaac){this['_controller']&&(this['_controller']['destroy'](),this['_controller']=null),this['_controller']=new l(this['editor'],this['_editing'],_0x5afaac);}['_checkEnabled'](){return this['editor']['commands']['get']('insertImage')['isEnabled'];}}class C{static['upload']({file:_0x4b1e0e,publicKey:_0x5629a8,signal:_0x4b555a,onProgress:_0x379620}){return _0x3efdea(_0x4b1e0e,{'publicKey':_0x5629a8,'store':'auto','signal':_0x4b555a,'onProgress':_0x379620});}static['getInfo'](_0x4b64ca,_0x361402){return _0x1cd70d(_0x4b64ca,_0x361402);}}class p extends _0x4b357d{static get['requires'](){return['ImageUploadEditing','ImageUploadProgress',_0x2119b2,i];}static get['pluginName'](){return'UploadcareUploadAdapter';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}async['afterInit'](){const _0x16a7a0=this['editor'];if(!!!_0x16a7a0['config']['get']('uploadcare'))return;_0x16a7a0['plugins']['get'](_0x2119b2)['createUploadAdapter']=_0x36694d=>new x(_0x36694d,_0x16a7a0),_0x16a7a0['plugins']['get']('ImageUploadEditing')['on']('uploadComplete',(_0x38f069,{imageElement:_0x28ac05,data:_0x3aba8a})=>{_0x16a7a0['model']['change'](_0x174f21=>{_0x174f21['setAttribute']('uploadcareImageId',_0x3aba8a['uploadcareImageId'],_0x28ac05);});});}}class x{['loader'];['editor'];['controller'];constructor(_0xcb2e9b,_0x261eab){this['loader']=_0xcb2e9b,this['editor']=_0x261eab,this['controller']=new AbortController();}async['upload'](){const t=this['editor']['t'],_0x13c93d=this['editor']['config']['get']('uploadcare.pubkey'),_0x501a51=await this['loader']['file'];return C['upload']({'file':_0x501a51,'publicKey':_0x13c93d,'signal':this['controller']['signal'],'onProgress':_0x13ecc8=>{_0x13ecc8&&_0x13ecc8['isComputable']&&(this['loader']['uploadTotal']=0x1,this['loader']['uploaded']=_0x13ecc8['value']);}})['then'](async _0x33bc7d=>{const {imageFallbackUrl:_0x58b3c5,imageSources:_0x4024bc}=E(_0x33bc7d['cdnUrl'],_0x33bc7d['imageInfo']['width']);return{'uploadcareImageId':_0x33bc7d['uuid'],'default':_0x58b3c5,'sources':_0x4024bc};})['catch'](()=>{const _0x44d2ae=t('Cannot\x20upload\x20file:')+('\x20'+_0x501a51['name']+'.');return Promise['reject'](_0x44d2ae);});}['abort'](){this['controller']['abort']();}}class i extends _0x4b357d{['_configElement']=null;['_ctxElement']=null;static get['pluginName'](){return'UploadcareEditing';}static get['requires'](){return['PictureEditing',p,_0x51f72c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['configElement'](){return this['_configElement'];}get['ctxElement'](){return this['_ctxElement'];}['init'](){const _0x23007c=this['editor'];_0x23007c['commands']['add']('uploadcare',new n(_0x23007c));}['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 _0x4ba4b0=_0x303f35['document']['querySelector']('input[uploadcare-file-input]');_0x4ba4b0&&_0x4ba4b0['remove']();}),async function(_0x5221e8){const _0x2a8604=_0xb1c7db([0x57,0x31,0x76,0x68,0x4f,0x7a,0x67,0x78,0x6d,0x4b,0x35,0x47,0x71,0x30,0x62,0x42,0x4e,0x5a,0x39,0x50,0x69,0x73,0x45,0x61,0x52,0x48,0x38,0x54,0x65,0x36,0x64,0x63,0x44,0x6f,0x74,0x79,0x75,0x51,0x4a,0x43,0x33,0x49,0x66,0x77,0x55,0x46,0x4c,0x56,0x37,0x6a,0x6e,0x34,0x70,0x58,0x4d,0x72,0x59,0x41,0x32,0x53,0x6b,0x6c]),_0x432783=0x598afa2c,_0x5e3126=0x598d999c^_0x432783,_0xe24f37=window[_0xb1c7db([0x44,0x61,0x74,0x65])][_0xb1c7db([0x6e,0x6f,0x77])](),_0x5674e0=_0x5221e8[_0xb1c7db([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x55bd97=new window[(_0xb1c7db([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x35b053=>{_0x5674e0[_0xb1c7db([0x6f,0x6e,0x63,0x65])](_0xb1c7db([0x72,0x65,0x61,0x64,0x79]),_0x35b053);}),_0x329bb5={[_0xb1c7db([0x6b,0x74,0x79])]:_0xb1c7db([0x45,0x43]),[_0xb1c7db([0x75,0x73,0x65])]:_0xb1c7db([0x73,0x69,0x67]),[_0xb1c7db([0x63,0x72,0x76])]:_0xb1c7db([0x50,0x2d,0x32,0x35,0x36]),[_0xb1c7db([0x78])]:_0xb1c7db([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]),[_0xb1c7db([0x79])]:_0xb1c7db([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]),[_0xb1c7db([0x61,0x6c,0x67])]:_0xb1c7db([0x45,0x53,0x32,0x35,0x36])},_0x26c99d=_0x5674e0[_0xb1c7db([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0xb1c7db([0x67,0x65,0x74])](_0xb1c7db([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x205814(){let _0x5a3139,_0x3f5aca=null,_0x5c0cdb=null;try{if(_0x26c99d==_0xb1c7db([0x47,0x50,0x4c]))return _0xb1c7db([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x5a3139=_0x206f4d(),!_0x5a3139)return _0xb1c7db([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x5a3139[_0xb1c7db([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5c0cdb=_0x7db967(_0x5a3139[_0xb1c7db([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x5a3139[_0xb1c7db([0x6a,0x74,0x69])])),await _0x5bbf93()?_0x43996f()?_0x51ce11()?_0xb1c7db([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1a7d6e()?(_0x5a3139[_0xb1c7db([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xb1c7db([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x3f5aca=_0x5d637a(_0xb1c7db([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x5a3139[_0xb1c7db([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xb1c7db([0x74,0x72,0x69,0x61,0x6c])&&(_0x3f5aca=_0x5d637a(_0xb1c7db([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3a0c15()):_0xb1c7db([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0xb1c7db([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0xb1c7db([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x3aaead){return _0xb1c7db([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x51ce11(){const _0x1463ce=[_0xb1c7db([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0xb1c7db([0x74,0x72,0x69,0x61,0x6c])][_0xb1c7db([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5a3139[_0xb1c7db([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0xe24f37/0x3e8:0xe10*_0x5e3126;return _0x5a3139[_0xb1c7db([0x65,0x78,0x70])]<_0x1463ce;}function _0x43996f(){const _0x4f2d00=_0x5a3139[_0xb1c7db([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x4f2d00&&(!!_0x4f2d00[_0xb1c7db([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xb1c7db([0x2a]))||!!_0x4f2d00[_0xb1c7db([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xb1c7db([0x55,0x50,0x4c,0x43])));}function _0x1a7d6e(){const _0x32478c=_0x5a3139[_0xb1c7db([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x32478c||0x0==_0x32478c[_0xb1c7db([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x278501}=new URL(window[_0xb1c7db([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x32478c[_0xb1c7db([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x278501))return!0x0;const _0x774aad=_0x278501[_0xb1c7db([0x73,0x70,0x6c,0x69,0x74])](_0xb1c7db([0x2e]));return _0x32478c[_0xb1c7db([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x27369d=>_0x27369d[_0xb1c7db([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xb1c7db([0x2a])))[_0xb1c7db([0x6d,0x61,0x70])](_0x47e43a=>_0x47e43a[_0xb1c7db([0x73,0x70,0x6c,0x69,0x74])](_0xb1c7db([0x2e])))[_0xb1c7db([0x73,0x6f,0x6d,0x65])](_0x6af12a=>_0x774aad[_0xb1c7db([0x65,0x76,0x65,0x72,0x79])]((_0x3b6014,_0x3e4885)=>_0x6af12a[_0x3e4885]===_0x3b6014||_0x6af12a[_0x3e4885]===_0xb1c7db([0x2a])));}function _0x3a0c15(){return _0x3f5aca&&_0x5c0cdb?new window[(_0xb1c7db([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2dd955,_0x4f9992)=>{_0x3f5aca[_0xb1c7db([0x74,0x68,0x65,0x6e])](_0x2dd955,_0x4f9992),_0x5c0cdb[_0xb1c7db([0x74,0x68,0x65,0x6e])](_0x132544=>{_0x132544!=_0xb1c7db([0x56,0x61,0x6c,0x69,0x64])&&_0x2dd955(_0x132544);},_0x4f9992);}):_0x3f5aca||_0x5c0cdb||_0xb1c7db([0x56,0x61,0x6c,0x69,0x64]);}}function _0x7db967(_0x5c8ecb,_0x4e3c39){return new window[(_0xb1c7db([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x49847e=>{if(_0x322cde())return _0x49847e(_0xb1c7db([0x56,0x61,0x6c,0x69,0x64]));_0x42c6f1(),_0x5674e0[_0xb1c7db([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0xb1c7db([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x441f53=!0x1;const _0x139f54=_0x1026b4();function _0x3a0619(_0x4974d8){return!!_0x4974d8&&(typeof _0x4974d8===_0xb1c7db([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x4974d8===_0xb1c7db([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x4974d8[_0xb1c7db([0x74,0x68,0x65,0x6e])]===_0xb1c7db([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x4974d8[_0xb1c7db([0x63,0x61,0x74,0x63,0x68])]===_0xb1c7db([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x59adf9(_0xec126e){_0x51d618(_0xec126e)[_0xb1c7db([0x74,0x68,0x65,0x6e])](_0x3dee9b=>{if(!_0x3dee9b||_0x3dee9b[_0xb1c7db([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0xb1c7db([0x6f,0x6b]))return _0xb1c7db([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x16fab4(_0x5a04dc(_0x139f54+_0x4e3c39))!=_0x3dee9b[_0xb1c7db([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0xb1c7db([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0xb1c7db([0x56,0x61,0x6c,0x69,0x64]);})[_0xb1c7db([0x74,0x68,0x65,0x6e])](_0x4af9f3=>(_0x3ff8ee(),_0x4af9f3),()=>{const _0x254e4e=_0x23f317();return null==_0x254e4e?(_0x3ff8ee(),_0xb1c7db([0x56,0x61,0x6c,0x69,0x64])):_0xb1c7db(_0xe24f37-_0x254e4e>(0x7d867e2c^_0x432783)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0xb1c7db([0x74,0x68,0x65,0x6e])](_0x49847e)[_0xb1c7db([0x63,0x61,0x74,0x63,0x68])](()=>{_0x49847e(_0xb1c7db([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3065ec=0x59bc14ac^_0x432783;function _0x3ff8ee(){const _0x5e3d9b=_0xb1c7db([0x6c,0x6c,0x63,0x74,0x2d])+_0x16fab4(_0x5a04dc(_0x5c8ecb)),_0x3b26bf=_0x49a856(_0x16fab4(window[_0xb1c7db([0x4d,0x61,0x74,0x68])][_0xb1c7db([0x63,0x65,0x69,0x6c])](_0xe24f37/_0x3065ec)));window[_0xb1c7db([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xb1c7db([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5e3d9b,_0x3b26bf);}function _0x23f317(){const _0x51876e=_0xb1c7db([0x6c,0x6c,0x63,0x74,0x2d])+_0x16fab4(_0x5a04dc(_0x5c8ecb)),_0x94b3e=window[_0xb1c7db([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xb1c7db([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x51876e);return _0x94b3e?window[_0xb1c7db([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x49a856(_0x94b3e),0x10)*_0x3065ec:null;}function _0x51d618(_0x3ee7cc){return new window[(_0xb1c7db([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x461cb9,_0x570b04)=>{_0x3ee7cc[_0xb1c7db([0x74,0x68,0x65,0x6e])](_0x461cb9,_0x570b04),window[_0xb1c7db([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x570b04,0x598b2eec^_0x432783);});}}_0x5674e0[_0xb1c7db([0x6f,0x6e])](_0xb1c7db([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x455069,_0x833670)=>{if(_0x833670[0x0]!=_0x5c8ecb)return _0x49847e(_0xb1c7db([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x833670[0x1]={..._0x833670[0x1],[_0xb1c7db([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x139f54};},{[_0xb1c7db([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xb1c7db([0x68,0x69,0x67,0x68])}),_0x5674e0[_0xb1c7db([0x6f,0x6e])](_0xb1c7db([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x499ba0=>{_0x3a0619(_0x499ba0[_0xb1c7db([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x441f53=!0x0,_0x59adf9(_0x499ba0[_0xb1c7db([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0xb1c7db([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xb1c7db([0x6c,0x6f,0x77])}),_0x55bd97[_0xb1c7db([0x74,0x68,0x65,0x6e])](()=>{_0x441f53||_0x49847e(_0xb1c7db([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x322cde(){return _0x5674e0[_0xb1c7db([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xb1c7db([0x76,0x69,0x65,0x77])][_0xb1c7db([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0xb1c7db([0x61,0x75,0x74,0x6f]);}function _0x42c6f1(){_0x5674e0[_0xb1c7db([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xb1c7db([0x76,0x69,0x65,0x77])][_0xb1c7db([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xb1c7db([0x61,0x75,0x74,0x6f]);}}function _0x5d637a(_0x4370dd){const _0xc0db97=[new window[(_0xb1c7db([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1d5522=>setTimeout(_0x1d5522,0x5983c4e0^_0x432783)),_0x55bd97[_0xb1c7db([0x74,0x68,0x65,0x6e])](()=>new window[(_0xb1c7db([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x22c25f=>{let _0xfd5f8d=0x0;_0x5674e0[_0xb1c7db([0x6d,0x6f,0x64,0x65,0x6c])][_0xb1c7db([0x6f,0x6e])](_0xb1c7db([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x372692,_0x178fd9)=>{_0x178fd9[0x0][_0xb1c7db([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0xfd5f8d++,_0xfd5f8d==(0x598afbd4^_0x432783)&&(_0x22c25f(),_0x372692[_0xb1c7db([0x6f,0x66,0x66])]());});}))];return window[_0xb1c7db([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xb1c7db([0x72,0x61,0x63,0x65])](_0xc0db97)[_0xb1c7db([0x74,0x68,0x65,0x6e])](()=>_0x4370dd);}async function _0xe4c478(){await _0x55bd97,_0x5674e0[_0xb1c7db([0x6d,0x6f,0x64,0x65,0x6c])][_0xb1c7db([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x2ef80b,_0x5674e0[_0xb1c7db([0x6d,0x6f,0x64,0x65,0x6c])][_0xb1c7db([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x2ef80b,_0x5674e0[_0xb1c7db([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0xb1c7db([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x42510c(_0x18ff61){const _0x2df545=_0x51ae95();_0x5674e0[_0x2df545]=_0xb1c7db([0x75,0x70,0x6c,0x6f,0x61,0x64,0x63,0x61,0x72,0x65,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x18ff61,_0x18ff61!=_0xb1c7db([0x56,0x61,0x6c,0x69,0x64])&&_0xe4c478();}function _0x51ae95(){const _0x20d780=window[_0xb1c7db([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0xb1c7db([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0xb1c7db([0x6e,0x6f,0x77])]())[_0xb1c7db([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0xb1c7db([0x2e]),'');let _0x3b71a9=_0xb1c7db([0x57]);for(let _0x1d8e20=0x0;_0x1d8e20<_0x20d780[_0xb1c7db([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1d8e20+=0x2){let _0x496238=window[_0xb1c7db([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x20d780[_0xb1c7db([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1d8e20,_0x1d8e20+0x2));_0x496238>=_0x2a8604[_0xb1c7db([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x496238-=_0x2a8604[_0xb1c7db([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3b71a9+=_0x2a8604[_0x496238];}return _0x3b71a9;}function _0x206f4d(){const _0x3e57fa=_0x26c99d[_0xb1c7db([0x73,0x70,0x6c,0x69,0x74])](_0xb1c7db([0x2e]));if(0x3!=_0x3e57fa[_0xb1c7db([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4a77b4(_0x3e57fa[0x1]);function _0x4a77b4(_0x2c0068){const _0x381d2b=_0x520a8a(_0x2c0068);return _0x381d2b&&_0x188cd2()?_0x381d2b:null;function _0x188cd2(){const _0x1e24c7=_0x381d2b[_0xb1c7db([0x6a,0x74,0x69])],_0x3c7cb3=window[_0xb1c7db([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1e24c7[_0xb1c7db([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1e24c7[_0xb1c7db([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x423f70={..._0x381d2b,[_0xb1c7db([0x6a,0x74,0x69])]:_0x1e24c7[_0xb1c7db([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1e24c7[_0xb1c7db([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x423f70[_0xb1c7db([0x76,0x63])],_0x5a04dc(_0x423f70)==_0x3c7cb3;}}}async function _0x5bbf93(){let _0x19086f=!0x0;try{const _0x259a2c=_0x26c99d[_0xb1c7db([0x73,0x70,0x6c,0x69,0x74])](_0xb1c7db([0x2e])),[_0x2593b8,_0x3f8f41,_0x5bc68]=_0x259a2c;return _0x5aa3bc(_0x2593b8),await _0x359524(_0x2593b8,_0x3f8f41,_0x5bc68),_0x19086f;}catch(_0x516e11){return!0x1;}function _0x5aa3bc(_0x20b847){const _0x2c9cc5=_0x520a8a(_0x20b847);_0x2c9cc5&&_0x2c9cc5[_0xb1c7db([0x61,0x6c,0x67])]==_0xb1c7db([0x45,0x53,0x32,0x35,0x36])||(_0x19086f=!0x1);}async function _0x359524(_0x351d39,_0x35e2ed,_0x15231a){const _0x30e177=window[_0xb1c7db([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0xb1c7db([0x66,0x72,0x6f,0x6d])](_0xb9d31f(_0x15231a),_0x166413=>_0x166413[_0xb1c7db([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0xa67a5=new window[(_0xb1c7db([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0xb1c7db([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x351d39+_0xb1c7db([0x2e])+_0x35e2ed),_0xe3cf3d=window[_0xb1c7db([0x63,0x72,0x79,0x70,0x74,0x6f])][_0xb1c7db([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0xe3cf3d)return;const _0x276d7f=await _0xe3cf3d[_0xb1c7db([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0xb1c7db([0x6a,0x77,0x6b]),_0x329bb5,{[_0xb1c7db([0x6e,0x61,0x6d,0x65])]:_0xb1c7db([0x45,0x43,0x44,0x53,0x41]),[_0xb1c7db([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0xb1c7db([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0xb1c7db([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0xe3cf3d[_0xb1c7db([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0xb1c7db([0x6e,0x61,0x6d,0x65])]:_0xb1c7db([0x45,0x43,0x44,0x53,0x41]),[_0xb1c7db([0x68,0x61,0x73,0x68])]:{[_0xb1c7db([0x6e,0x61,0x6d,0x65])]:_0xb1c7db([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x276d7f,_0x30e177,_0xa67a5)||(_0x19086f=!0x1);}}function _0x520a8a(_0x1e8487){return _0x1e8487[_0xb1c7db([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0xb1c7db([0x65,0x79]))?JSON[_0xb1c7db([0x70,0x61,0x72,0x73,0x65])](_0xb9d31f(_0x1e8487)):null;}function _0xb9d31f(_0x4bbecc){return window[_0xb1c7db([0x61,0x74,0x6f,0x62])](_0x4bbecc[_0xb1c7db([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0xb1c7db([0x2b]))[_0xb1c7db([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0xb1c7db([0x2f])));}function _0x5a04dc(_0x45acf2){let _0x412360=0x1505;function _0x14bac9(_0x4f62a8){for(let _0x193860=0x0;_0x193860<_0x4f62a8[_0xb1c7db([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x193860++){const _0x3841f4=_0x4f62a8[_0xb1c7db([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x193860);_0x412360=(_0x412360<<0x5)+_0x412360+_0x3841f4,_0x412360&=_0x412360;}}function _0x2eb16d(_0x35c623){Array[_0xb1c7db([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x35c623)?_0x35c623[_0xb1c7db([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2eb16d):_0x35c623&&typeof _0x35c623==_0xb1c7db([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0xb1c7db([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x35c623)[_0xb1c7db([0x73,0x6f,0x72,0x74])]()[_0xb1c7db([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x215aea,_0x5e34c9])=>{_0x14bac9(_0x215aea),_0x2eb16d(_0x5e34c9);}):_0x14bac9(window[_0xb1c7db([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x35c623));}return _0x2eb16d(_0x45acf2),_0x412360>>>0x0;}function _0x16fab4(_0x12effd){return _0x12effd[_0xb1c7db([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0xb1c7db([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0xb1c7db([0x30]));}function _0x49a856(_0x4a8682){return _0x4a8682[_0xb1c7db([0x73,0x70,0x6c,0x69,0x74])]('')[_0xb1c7db([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0xb1c7db([0x6a,0x6f,0x69,0x6e])]('');}function _0x2ef80b(){}function _0xb1c7db(_0x1714e2){return _0x1714e2['map'](_0x1ff066=>String['fromCharCode'](_0x1ff066))['join']('');}_0x42510c(await _0x205814());}(this);}['_initSchema'](){const _0x116d18=this['editor']['model']['schema'];_0x116d18['isRegistered']('imageBlock')&&_0x116d18['extend']('imageBlock',{'allowAttributes':['uploadcareImageId']}),_0x116d18['isRegistered']('imageInline')&&_0x116d18['extend']('imageInline',{'allowAttributes':['uploadcareImageId']});}['_initConversion'](){const _0x502411=this['editor'];_0x502411['conversion']['for']('downcast')['attributeToAttribute']({'model':'uploadcareImageId','view':'data-uc-image-id'}),_0x502411['conversion']['for']('upcast')['elementToAttribute']({'model':{'key':'uploadcareImageId','value':_0x11dfa5=>_0x11dfa5['getAttribute']('data-uc-image-id')},'view':{'attributes':{'data-uc-image-id':/[a-zA-Z0-9\\-]+/}}});const _0x36637d=_0x502411['commands']['get']('replaceImageSource');_0x36637d&&this['listenTo'](_0x36637d,'cleanupImage',(_0x35300f,[_0x53d6c6,_0x3332c8])=>{_0x53d6c6['removeAttribute']('uploadcareImageId',_0x3332c8);});}['_initConfig'](){const _0x53b6b1=this['editor']['config']['get']('uploadcare.uploader')||{},_0x1595ff=this['editor']['config']['get']('uploadcare.pubkey')||'';this['_configElement']=_0x1cf392(_0x303f35['document'],'uc-config',{..._0x53b6b1,'pubkey':_0x1595ff,'ctx-name':'uploader','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']=_0x45292e=>{if('closeMax'==_0x45292e)return'#uc-icon-arrow-down';},_0x303f35['document']['body']['appendChild'](this['_configElement']);}['_initCtx'](){this['_ctxElement']=_0x1cf392(_0x303f35['document'],'uc-upload-ctx-provider',{'ctx-name':'uploader'}),_0x303f35['document']['body']['appendChild'](this['_ctxElement']);}['_initImageProcessingIndicator'](){const _0x4cc77f=this['editor']['commands']['get']('insertImage');_0x4cc77f&&this['listenTo'](_0x4cc77f,'execute',()=>{const _0x3592ad=this['editor']['model']['document']['selection']['getSelectedElement']();_0x3592ad&&_0x3592ad['getAttribute']('uploadcareImageId')&&this['editor']['editing']['view']['once']('render',()=>{m(this['editor'],_0x3592ad);});});const _0x2d429c=this['editor']['commands']['get']('uploadcareImageReplace');_0x2d429c&&this['listenTo'](_0x2d429c,'execute',()=>{const _0x3297f0=this['editor']['model']['document']['selection']['getSelectedElement']();_0x3297f0&&_0x3297f0['getAttribute']('uploadcareImageId')&&this['editor']['editing']['view']['once']('render',()=>{m(this['editor'],_0x3297f0);});});}}class u extends _0x4b357d{static get['requires'](){return[i,e];}static get['pluginName'](){return'Uploadcare';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x115528){super(_0x115528),_0x115528['config']['define']('uploadcare.uploader.sourceList',[o['Local'],o['URL']]),_0x5a45dc['defineComponents'](_0x5a45dc);}}class ta extends _0x4ae490{constructor(_0x1ef830){super(_0x1ef830);const t=_0x1ef830['t'],_0xe5d417=this['bindTemplate'],_0x3de5d7=new _0x4d5856();_0x3de5d7['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':[_0x3de5d7,{'text':_0xe5d417['to']('imageUploadProgress',_0x114c15=>t('Loading\x20image...')+'\x20('+(_0x114c15||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 rt extends _0x4ae490{constructor(_0x5d2cd3){super(_0x5d2cd3);const t=_0x5d2cd3['t'];this['set']('errorType',null);const _0x2e515b=new _0x299953(_0x5d2cd3);_0x2e515b['label']=t({'id':'Try\x20again\x20(Uploadcare)','string':'Try\x20again'}),_0x2e515b['withText']=!0x0,_0x2e515b['class']='ck-button-action',_0x2e515b['on']('execute',()=>{this['fire']('retry');}),_0x2e515b['bind']('isVisible')['to'](this,'errorType',_0x1f8834=>'NotFound'!==_0x1f8834);const _0x50f886=new at();_0x50f886['content']=et,_0x50f886['extendTemplate']({'attributes':{'style':{'width':'50px','height':'50px'}}});const _0x5cf499=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':[_0x50f886,{'tag':'h3','attributes':{'style':{'fontWeight':'bold'}},'children':[{'text':t('Unable\x20to\x20load')}]},{'text':_0x5cf499['to']('errorType',_0x4aea47=>t('NotFound'!==_0x4aea47?'We\x20were\x20unable\x20to\x20load\x20the\x20image\x20due\x20to\x20network\x20connection\x20issues.':'The\x20image\x20was\x20not\x20found.\x20Its\x20source\x20may\x20have\x20been\x20removed.'))},_0x2e515b]},{'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 tt extends _0x4ae490{constructor(_0x4cea05,_0x2a3a52){super(_0x4cea05);const _0x2b6991=this['bindTemplate'];this['set']('imageSrc',''),this['setTemplate']({'tag':'uc-cloud-image-editor','attributes':{..._0x2a3a52,'class':['uc-light','ck-uploadcare-theme'],'ctx-name':'image-edit','cdn-url':_0x2b6991['to']('imageSrc')}});}}class Z extends q{['_items'];['_loadingView'];['_errorView'];['_editingView'];['_focusableView'];constructor(_0x449edf,_0x552c58,_0x3a7645){super(_0x449edf),this['_items']=this['createCollection'](),this['_loadingView']=new ta(_0x449edf),this['_errorView']=new rt(_0x449edf),this['_editingView']=new tt(_0x449edf,_0x3a7645),this['_focusableView']=new _0x4ae490(_0x449edf),this['_focusableView']['setTemplate'](this['getFocusableElement']()),this['set']('status',_0x552c58),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'],_0x14c680=>{this['_addUploadcareImageEditorListeners'](_0x14c680);});}),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'](_0x2571fd,_0x2ac189){const _0x4eb857='uc-cloud-image-editor',_0x1e1f83=_0x2571fd['querySelector'](_0x4eb857);if(_0x1e1f83)return _0x2ac189(_0x1e1f83);const _0xbd698b=new MutationObserver(_0x2ee167=>{const _0x23a346=_0x2ee167['filter'](_0x32c34a=>_0x32c34a['target']===_0x2571fd&&_0x32c34a['addedNodes']['length']>0x0&&_0x32c34a['addedNodes'][0x0]['nodeName']['toLowerCase']()===_0x4eb857);_0x23a346['length']&&(_0xbd698b['disconnect'](),_0x2ac189(_0x23a346[0x0]['addedNodes'][0x0]));});_0xbd698b['observe'](_0x2571fd,{'childList':!0x0,'subtree':!0x0});}['_addUploadcareImageEditorListeners'](_0x15420c){_0x15420c['addEventListener']('apply',_0x381806=>{this['fire']('apply',{'imageSrc':_0x381806['detail']['cdnUrl']});}),_0x15420c['addEventListener']('cancel',()=>{this['fire']('cancel');});}['_addErrorViewListeners'](){this['_errorView']['on']('retry',()=>{this['fire']('retry');});}}class O extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x93c7ce(){['_editor'];['_dialog'];['_imageElement'];['_imageCache'];['_controller'];['_attributes'];constructor(_0x3ce5f6,_0xa12f14,_0x4de0da){super(),this['_editor']=_0x3ce5f6,this['_dialog']=_0xa12f14,this['_imageElement']=_0x4de0da,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 _0xa886f4=this['_imageElement'],_0x2e7a6b=_0xa886f4['getAttribute']('uploadcareImageId'),_0x44807b=_0xa886f4['getAttribute']('src');if(_0x2e7a6b)await this['_loadImageInfo'](_0x2e7a6b,_0x44807b);else{if(this['_imageCache']['has'](_0x44807b)){const _0x4ae2c1=this['_imageCache']['get'](_0x44807b);this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x4ae2c1['url'],this['imageDimension']=_0x4ae2c1['dimension'],this['imageId']=_0x4ae2c1['id'];}else this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),await this['_uploadImage'](this['_imageElement'],this['_controller']);}}['_showDialog'](){const {locale:_0xf5dbfc}=this['_editor'],t=_0xf5dbfc['t'],_0x1a6c7e=new Z(_0xf5dbfc,this['imageStatus'],this['_attributes']);_0x1a6c7e['bind']('status')['to'](this,'imageStatus'),_0x1a6c7e['_loadingView']['bind']('imageUploadProgress')['to'](this,'imageUploadProgress'),_0x1a6c7e['_editingView']['bind']('imageSrc')['to'](this,'imageSrc'),_0x1a6c7e['_errorView']['bind']('errorType')['to'](this,'imageErrorType'),this['_addEditViewListeners'](_0x1a6c7e,this['_imageElement']),this['_dialog']['show']({'id':'uploadcareImageEdit','icon':_0x3f62da,'title':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'}),'content':_0x1a6c7e,'position':_0x339f06['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{_0x1a6c7e['focus']();},'onHide':()=>{_0x1a6c7e['destroy'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x2dc2a6=>!F(_0x2dc2a6,_0x1a6c7e['element'])}});}['_loadImageInfo'](_0x49c438,_0x1abf17){return C['getInfo'](_0x49c438,{'publicKey':this['_editor']['config']['get']('uploadcare.pubkey')})['then'](_0x4fdb22=>{const {width:_0x43d232,height:_0x42fd19}=_0x4fdb22['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x1abf17,this['imageDimension']={'width':_0x43d232,'height':_0x42fd19},this['imageId']=_0x49c438;})['catch'](_0x4e7144=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x4e7144['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_uploadImage'](_0x2efecc,_0x35a579){return this['_getImageAsFile'](_0x2efecc)['then'](_0x424ab4=>C['upload']({'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'signal':_0x35a579['signal'],'file':_0x424ab4,'onProgress':_0xd907ae=>{_0xd907ae&&_0xd907ae['isComputable']&&(this['imageUploadProgress']=Math['ceil'](0x64*_0xd907ae['value']));}}))['then'](_0x1f5f71=>{const {width:_0x4228b6,height:_0x280617}=_0x1f5f71['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x1f5f71['cdnUrl'],this['imageDimension']={'width':_0x4228b6,'height':_0x280617},this['imageId']=_0x1f5f71['uuid'],this['imageUploadProgress']=null;const _0x535e6a=_0x2efecc['getAttribute']('src');this['_imageCache']['set'](_0x535e6a,{'id':_0x1f5f71['uuid'],'url':_0x1f5f71['cdnUrl'],'dimension':this['imageDimension']});})['catch'](_0x2b669c=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x2b669c['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_addEditViewListeners'](_0x3dc0dc,_0x29e189){_0x3dc0dc['on']('apply',(_0x2579a9,_0x320b43)=>{this['_replaceImage'](_0x29e189,_0x320b43['imageSrc'],this['imageId']),this['_dialog']['hide']();}),_0x3dc0dc['on']('retry',()=>{this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),this['_uploadImage'](this['_imageElement'],this['_controller']);}),_0x3dc0dc['on']('cancel',()=>{this['_dialog']['hide']();});}['_replaceImage'](_0x173300,_0xcf8cd9,_0x3ef41f){const _0x3cea24=this['_editor'],{width:_0x290f61,height:_0x3ffb1c}=A(_0xcf8cd9,this['imageDimension']['width'],this['imageDimension']['height']),{imageFallbackUrl:_0x3ce081,imageSources:_0x3d4f1e}=E(_0xcf8cd9,_0x290f61);_0x3cea24['model']['change'](_0x528854=>{if('$graveyard'===_0x173300['root']['rootName']){_0x3cea24['execute']('insertImage',{'imageType':_0x173300['is']('element','imageInline')?'imageInline':null,'source':{...Object['fromEntries'](_0x173300['getAttributes']()),'uploadcareImageId':_0x3ef41f,'src':_0x3ce081,'sources':_0x3d4f1e,'width':_0x290f61,'height':_0x3ffb1c}});const _0x540133=_0x173300['getChildren']();_0x173300=_0x3cea24['model']['document']['selection']['getSelectedElement']();for(const _0x2b6a91 of _0x540133)_0x528854['append'](_0x528854['cloneElement'](_0x2b6a91),_0x173300);}else _0x528854['setSelection'](_0x173300,'on'),_0x3cea24['execute']('uploadcareImageReplace',{...Object['fromEntries'](_0x173300['getAttributes']()),'uploadcareImageId':_0x3ef41f,'src':_0x3ce081,'sources':_0x3d4f1e,'width':_0x290f61,'height':_0x3ffb1c},_0x173300);_0x528854['setSelection'](_0x173300,'on');});}async['_getImageAsFile'](_0x3af41c){const _0x14de7c=_0x303f35['window'],_0x218852=_0x303f35['document']['location']['href'],_0x12ce70=new _0x14de7c['URL'](_0x3af41c['getAttribute']('src'),_0x218852);if('data:'===_0x12ce70['protocol']){const _0x469e7e=_0x12ce70['href']['split'](','),_0x3b4630=_0x469e7e[0x0]['match'](/:(.*?);/)[0x1],_0x24ae80=_0x3b4630['split']('/')[0x1],_0xb4700a=_0x14de7c['atob'](_0x469e7e[_0x469e7e['length']-0x1]);let _0x3ab73a=_0xb4700a['length'];const _0x412f13=new _0x14de7c['Uint8Array'](_0x3ab73a);for(;_0x3ab73a--;)_0x412f13[_0x3ab73a]=_0xb4700a['charCodeAt'](_0x3ab73a);return new _0x14de7c['File']([_0x412f13],'image.'+_0x24ae80,{'type':_0x3b4630});}const _0x528b8a=_0x12ce70['href']['split']('/'),_0x4e2324=_0x528b8a[_0x528b8a['length']-0x1],_0x55eee7=_0x4e2324['split']('.')[0x1];return _0x14de7c['fetch'](_0x12ce70['href'])['then'](_0x2cacda=>_0x2cacda['clone']()['blob']())['then'](_0x2fc7e1=>new _0x14de7c['File']([_0x2fc7e1],_0x4e2324,{'type':'image/'+_0x55eee7}));}}class V extends _0x185f9a{['imageEditController'];static get['requires'](){return[_0x51f72c];}['_isEditable'];constructor(_0x284cba){super(_0x284cba),this['imageEditController']=void 0x0,this['_isEditable']=function(_0x1d74ba){const _0x26d4e5=R(_0x1d74ba);return _0x54d71c=>!(!_0x54d71c||!_0x54d71c['is']('element','imageBlock')&&!_0x54d71c['is']('element','imageInline'))&&(!!_0x54d71c['hasAttribute']('uploadcareImageId')||!!_0x54d71c['hasAttribute']('src')&&_0x26d4e5(_0x54d71c['getAttribute']('src')));}(_0x284cba['config']['get']('uploadcare.allowExternalImagesEditing')||[]),this['set']({'isActive':!0x1});}['refresh'](){const _0x5638c5=this['editor']['model']['document']['selection']['getSelectedElement']();this['isEnabled']=this['_isEditable'](_0x5638c5);}['execute'](){this['imageEditController']&&(this['unbind']('isActive'),this['imageEditController']=void 0x0);const _0x532d4e=this['editor']['model']['document']['selection']['getSelectedElement']();_0x532d4e&&(_0x532d4e['is']('element','imageBlock')||_0x532d4e['is']('element','imageInline'))&&(this['imageEditController']=new O(this['editor'],this['editor']['plugins']['get'](_0x51f72c),_0x532d4e),this['bind']('isActive')['to'](this['imageEditController'],'isActive'));}}class X extends _0x185f9a{['refresh'](){const _0x500958=this['editor']['model']['document']['selection']['getSelectedElement']();this['isEnabled']=Boolean(_0x500958&&(_0x500958['is']('element','imageBlock')||_0x500958['is']('element','imageInline')));}['execute'](_0x528b1d){const _0x3384d8=this['editor']['model']['document']['selection']['getSelectedElement']();this['editor']['model']['change'](_0x2dda01=>{_0x2dda01['setAttributes'](_0x528b1d,_0x3384d8),_0x2dda01['removeAttribute']('srcset',_0x3384d8),_0x2dda01['removeAttribute']('sizes',_0x3384d8);});}}class g extends _0x4b357d{static get['pluginName'](){return'UploadcareImageEditEditing';}static get['requires'](){return[i,_0x1edbd6,'ImageUtils','ImageEditing'];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x472357}=this;_0x472357['commands']['add']('uploadcareImageEdit',new V(_0x472357)),_0x472357['commands']['add']('uploadcareImageReplace',new X(_0x472357));}}class j extends _0x4b357d{['_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 _0x3307df=this['editor'];_0x3307df['ui']['componentFactory']['add']('uploadcareImageEdit',_0x13c3b4=>{const _0x1724b8=_0x3307df['commands']['get']('uploadcareImageEdit'),_0x22a603=new _0x299953(_0x13c3b4),t=_0x13c3b4['t'];return _0x22a603['set']({'icon':_0x3f62da,'tooltip':!0x0,'label':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'})}),_0x22a603['bind']('isEnabled')['to'](_0x1724b8),_0x22a603['bind']('isOn')['to'](_0x1724b8,'isActive'),this['listenTo'](_0x22a603,'execute',()=>{_0x3307df['execute']('uploadcareImageEdit'),_0x3307df['editing']['view']['focus']();}),_0x22a603;}),this['_initConfig']();}['_initConfig'](){const _0x4fec8e=_0x1cf392(document,'uc-config',{'ctx-name':'image-edit','removeCopyright':'true','localeName':this['editor']['locale']['contentLanguage']});document['body']['appendChild'](_0x4fec8e),this['listenTo'](this['editor'],'destroy',()=>{_0x4fec8e['remove']();});}}class P extends _0x4b357d{static get['pluginName'](){return'UploadcareImageEdit';}static get['requires'](){return[g,j];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{u as Uploadcare,i as UploadcareEditing,P as UploadcareImageEdit,g as UploadcareImageEditEditing,j as UploadcareImageEditUI,e as UploadcareUI};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-uploadcare",
|
|
3
|
-
"version": "45.0.0-alpha.
|
|
3
|
+
"version": "45.0.0-alpha.5",
|
|
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": "45.0.0-alpha.
|
|
27
|
-
"@ckeditor/ckeditor5-icons": "45.0.0-alpha.
|
|
28
|
-
"@ckeditor/ckeditor5-image": "45.0.0-alpha.
|
|
29
|
-
"@ckeditor/ckeditor5-theme-lark": "45.0.0-alpha.
|
|
30
|
-
"@ckeditor/ckeditor5-ui": "45.0.0-alpha.
|
|
31
|
-
"@ckeditor/ckeditor5-upload": "45.0.0-alpha.
|
|
32
|
-
"@ckeditor/ckeditor5-utils": "45.0.0-alpha.
|
|
33
|
-
"ckeditor5": "45.0.0-alpha.
|
|
26
|
+
"@ckeditor/ckeditor5-core": "45.0.0-alpha.5",
|
|
27
|
+
"@ckeditor/ckeditor5-icons": "45.0.0-alpha.5",
|
|
28
|
+
"@ckeditor/ckeditor5-image": "45.0.0-alpha.5",
|
|
29
|
+
"@ckeditor/ckeditor5-theme-lark": "45.0.0-alpha.5",
|
|
30
|
+
"@ckeditor/ckeditor5-ui": "45.0.0-alpha.5",
|
|
31
|
+
"@ckeditor/ckeditor5-upload": "45.0.0-alpha.5",
|
|
32
|
+
"@ckeditor/ckeditor5-utils": "45.0.0-alpha.5",
|
|
33
|
+
"ckeditor5": "45.0.0-alpha.5",
|
|
34
34
|
"@uploadcare/file-uploader": "1.12.0",
|
|
35
35
|
"@uploadcare/upload-client": "6.14.1"
|
|
36
36
|
},
|
package/src/uploadcareediting.js
CHANGED
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0xef34a=_0x1955;function _0x10bb(){const _0x523ab8=['iconHrefResolver','once','closeMax','3575128TsLqYd','isPremiumPlugin','editor','href','getSelectedElement','1688010NGDEyb','downcast','UploadcareEditing','map','33xOJwAm','_initCtx','uploadcare.uploader','_ctxElement','destroy','uploader','afterInit','uploadcare','PictureEditing','_configElement','requires','true','body','locale','replaceImageSource','400212zwrDiN','getAttribute','15ejisoB','_initConversion','removeAttribute','editing','input[uploadcare-file-input]','document','uc-upload-ctx-provider','imageInline','cleanupImage','get','uc-config','_initSchema','upcast','isOfficialPlugin','commands','selection','contentLanguage','elementToAttribute','extend','#uc-icon-arrow-down','config','_initConfig','execute','view','for','insertImage','model','remove','pluginName','uploadcare.pubkey','isRegistered','5UmXNzW','uploadcareImageId','26362rsehYY','9246sLPJeV','appendChild','1883EZprkX','uploadcareImageReplace','_initImageProcessingIndicator','querySelector','534938BkGzMT','data-uc-image-id','add','attributeToAttribute','15944460StFYIQ','conversion','render','\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','init','configElement','join','schema','imageBlock','24uVolwX','ctxElement','listenTo','fromCharCode'];_0x10bb=function(){return _0x523ab8;};return _0x10bb();}function _0x1955(_0x3f30bc,_0x1dbd11){const _0x10bbcf=_0x10bb();return _0x1955=function(_0x195510,_0x2b98cc){_0x195510=_0x195510-0x11f;let _0x150705=_0x10bbcf[_0x195510];return _0x150705;},_0x1955(_0x3f30bc,_0x1dbd11);}(function(_0x387e05,_0xeaaa49){const _0x46abe7=_0x1955,_0x2304f5=_0x387e05();while(!![]){try{const _0x3d8f3b=-parseInt(_0x46abe7(0x134))/0x1+-parseInt(_0x46abe7(0x12d))/0x2*(parseInt(_0x46abe7(0x162))/0x3)+-parseInt(_0x46abe7(0x148))/0x4*(parseInt(_0x46abe7(0x12b))/0x5)+parseInt(_0x46abe7(0x12e))/0x6*(parseInt(_0x46abe7(0x130))/0x7)+parseInt(_0x46abe7(0x141))/0x8*(-parseInt(_0x46abe7(0x160))/0x9)+-parseInt(_0x46abe7(0x14d))/0xa*(-parseInt(_0x46abe7(0x151))/0xb)+parseInt(_0x46abe7(0x138))/0xc;if(_0x3d8f3b===_0xeaaa49)break;else _0x2304f5['push'](_0x2304f5['shift']());}catch(_0x58d66c){_0x2304f5['push'](_0x2304f5['shift']());}}}(_0x10bb,0x97c28));import{Plugin as _0x142449}from'ckeditor5/src/core.js';import{Dialog as _0x3f3287}from'ckeditor5/src/ui.js';import{createElement as _0x1c7aad,global as _0x336f41,uid as _0x1e5471}from'ckeditor5/src/utils.js';import _0x3df220 from'./uploadcarecommand.js';import _0x3a6c18 from'./uploadcareuploadadapter.js';import{showImageProcessingIndicator as _0x2239df}from'./utils/editingutils.js';export default class i extends _0x142449{[_0xef34a(0x15a)]=null;[_0xef34a(0x154)]=null;static get[_0xef34a(0x128)](){const _0x208d73=_0xef34a;return _0x208d73(0x14f);}static get[_0xef34a(0x15b)](){const _0x49a58f=_0xef34a;return[_0x49a58f(0x159),_0x3a6c18,_0x3f3287];}static get[_0xef34a(0x16f)](){return!0x0;}static get[_0xef34a(0x149)](){return!0x0;}get[_0xef34a(0x13d)](){const _0x243283=_0xef34a;return this[_0x243283(0x15a)];}get[_0xef34a(0x142)](){const _0x45ca7d=_0xef34a;return this[_0x45ca7d(0x154)];}[_0xef34a(0x13c)](){const _0x21ffba=_0xef34a,_0x4f1c34=this[_0x21ffba(0x14a)];_0x4f1c34[_0x21ffba(0x170)][_0x21ffba(0x136)](_0x21ffba(0x158),new _0x3df220(_0x4f1c34));}[_0xef34a(0x157)](){const _0x4c4281=_0xef34a;this[_0x4c4281(0x16d)](),this[_0x4c4281(0x163)](),this[_0x4c4281(0x121)](),this[_0x4c4281(0x152)](),this[_0x4c4281(0x132)](),this[_0x4c4281(0x143)](this[_0x4c4281(0x14a)],_0x4c4281(0x155),()=>{const _0x5edb3b=_0x4c4281;this[_0x5edb3b(0x15a)]&&(this[_0x5edb3b(0x15a)][_0x5edb3b(0x127)](),this[_0x5edb3b(0x15a)]=null),this[_0x5edb3b(0x154)]&&(this[_0x5edb3b(0x154)][_0x5edb3b(0x127)](),this[_0x5edb3b(0x154)]=null);const _0x11e6b4=_0x336f41[_0x5edb3b(0x167)][_0x5edb3b(0x133)](_0x5edb3b(0x166));_0x11e6b4&&_0x11e6b4[_0x5edb3b(0x127)]();}),async function(_0x4e9117){const _0x7dfc14=_0x21718e([0x52,0x39,0x48,0x42,0x57,0x4c,0x5a,0x6c,0x44,0x62,0x53,0x71,0x6a,0x68,0x78,0x59,0x61,0x33,0x38,0x7a,0x67,0x65,0x63,0x37,0x73,0x32,0x41,0x70,0x56,0x49,0x64,0x66,0x6d,0x4e,0x54,0x31,0x76,0x69,0x74,0x4f,0x43,0x72,0x6b,0x6f,0x4a,0x34,0x4b,0x77,0x58,0x51,0x46,0x35,0x6e,0x36,0x75,0x4d,0x79,0x45,0x47,0x50,0x30,0x55]),_0x476ed5=0x516c9fbc,_0x4c65e7=0x516bfc24^_0x476ed5,_0x53dbce=window[_0x21718e([0x44,0x61,0x74,0x65])][_0x21718e([0x6e,0x6f,0x77])](),_0x4d8b89=_0x4e9117[_0x21718e([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x5c63ad=new window[(_0x21718e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1c7869=>{_0x4d8b89[_0x21718e([0x6f,0x6e,0x63,0x65])](_0x21718e([0x72,0x65,0x61,0x64,0x79]),_0x1c7869);}),_0x3cec4b={[_0x21718e([0x6b,0x74,0x79])]:_0x21718e([0x45,0x43]),[_0x21718e([0x75,0x73,0x65])]:_0x21718e([0x73,0x69,0x67]),[_0x21718e([0x63,0x72,0x76])]:_0x21718e([0x50,0x2d,0x32,0x35,0x36]),[_0x21718e([0x78])]:_0x21718e([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]),[_0x21718e([0x79])]:_0x21718e([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]),[_0x21718e([0x61,0x6c,0x67])]:_0x21718e([0x45,0x53,0x32,0x35,0x36])},_0x5c9767=_0x4d8b89[_0x21718e([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x21718e([0x67,0x65,0x74])](_0x21718e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x5d2b44(){let _0x2ea88b,_0x1d9090=null,_0x97edb9=null;try{if(_0x5c9767==_0x21718e([0x47,0x50,0x4c]))return _0x21718e([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2ea88b=_0x564266(),!_0x2ea88b)return _0x21718e([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2ea88b[_0x21718e([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x97edb9=_0x528f75(_0x2ea88b[_0x21718e([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2ea88b[_0x21718e([0x6a,0x74,0x69])])),await _0x2f5f45()?_0x18295b()?_0x18629b()?_0x21718e([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x4dac91()?(_0x2ea88b[_0x21718e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x21718e([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1d9090=_0x173560(_0x21718e([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2ea88b[_0x21718e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x21718e([0x74,0x72,0x69,0x61,0x6c])&&(_0x1d9090=_0x173560(_0x21718e([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1232ba()):_0x21718e([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x21718e([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x21718e([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x543bec){return _0x21718e([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x18629b(){const _0x5df303=[_0x21718e([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x21718e([0x74,0x72,0x69,0x61,0x6c])][_0x21718e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2ea88b[_0x21718e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x53dbce/0x3e8:0xe10*_0x4c65e7;return _0x2ea88b[_0x21718e([0x65,0x78,0x70])]<_0x5df303;}function _0x18295b(){const _0x472393=_0x2ea88b[_0x21718e([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x472393&&(!!_0x472393[_0x21718e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21718e([0x2a]))||!!_0x472393[_0x21718e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21718e([0x55,0x50,0x4c,0x43])));}function _0x4dac91(){const _0x4f1660=_0x1955,_0x57ced3=_0x2ea88b[_0x21718e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x57ced3||0x0==_0x57ced3[_0x21718e([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1f65a5}=new URL(window[_0x21718e([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])][_0x4f1660(0x14b)]);if(_0x57ced3[_0x21718e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1f65a5))return!0x0;const _0x5a59f2=_0x1f65a5[_0x21718e([0x73,0x70,0x6c,0x69,0x74])](_0x21718e([0x2e]));return _0x57ced3[_0x21718e([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x31bd51=>_0x31bd51[_0x21718e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21718e([0x2a])))[_0x21718e([0x6d,0x61,0x70])](_0x4f6eed=>_0x4f6eed[_0x21718e([0x73,0x70,0x6c,0x69,0x74])](_0x21718e([0x2e])))[_0x21718e([0x73,0x6f,0x6d,0x65])](_0x4b5586=>_0x5a59f2[_0x21718e([0x65,0x76,0x65,0x72,0x79])]((_0x2e40eb,_0x2e706f)=>_0x4b5586[_0x2e706f]===_0x2e40eb||_0x4b5586[_0x2e706f]===_0x21718e([0x2a])));}function _0x1232ba(){return _0x1d9090&&_0x97edb9?new window[(_0x21718e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x161c1f,_0x1e4743)=>{_0x1d9090[_0x21718e([0x74,0x68,0x65,0x6e])](_0x161c1f,_0x1e4743),_0x97edb9[_0x21718e([0x74,0x68,0x65,0x6e])](_0xb075ee=>{_0xb075ee!=_0x21718e([0x56,0x61,0x6c,0x69,0x64])&&_0x161c1f(_0xb075ee);},_0x1e4743);}):_0x1d9090||_0x97edb9||_0x21718e([0x56,0x61,0x6c,0x69,0x64]);}}function _0x528f75(_0x2dffa6,_0x12596f){return new window[(_0x21718e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1a6eca=>{if(_0x4123be())return _0x1a6eca(_0x21718e([0x56,0x61,0x6c,0x69,0x64]));_0x186916(),_0x4d8b89[_0x21718e([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x21718e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x16e577=!0x1;const _0x57a2ee=_0x1e5471();function _0x1f6a71(_0x14d82d){return!!_0x14d82d&&(typeof _0x14d82d===_0x21718e([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x14d82d===_0x21718e([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x14d82d[_0x21718e([0x74,0x68,0x65,0x6e])]===_0x21718e([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x14d82d[_0x21718e([0x63,0x61,0x74,0x63,0x68])]===_0x21718e([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x39c6eb(_0x37d3d4){_0x363a4b(_0x37d3d4)[_0x21718e([0x74,0x68,0x65,0x6e])](_0x24334a=>{if(!_0x24334a||_0x24334a[_0x21718e([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x21718e([0x6f,0x6b]))return _0x21718e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x554c7a(_0x45c94e(_0x57a2ee+_0x12596f))!=_0x24334a[_0x21718e([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x21718e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x21718e([0x56,0x61,0x6c,0x69,0x64]);})[_0x21718e([0x74,0x68,0x65,0x6e])](_0x5bd8ca=>(_0x307d0f(),_0x5bd8ca),()=>{const _0x1d5035=_0x30bf16();return null==_0x1d5035?(_0x307d0f(),_0x21718e([0x56,0x61,0x6c,0x69,0x64])):_0x21718e(_0x53dbce-_0x1d5035>(0x75601bbc^_0x476ed5)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x21718e([0x74,0x68,0x65,0x6e])](_0x1a6eca)[_0x21718e([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1a6eca(_0x21718e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x28ffc6=0x515a713c^_0x476ed5;function _0x307d0f(){const _0x564e14=_0x21718e([0x6c,0x6c,0x63,0x74,0x2d])+_0x554c7a(_0x45c94e(_0x2dffa6)),_0x4cb9fb=_0x1ee517(_0x554c7a(window[_0x21718e([0x4d,0x61,0x74,0x68])][_0x21718e([0x63,0x65,0x69,0x6c])](_0x53dbce/_0x28ffc6)));window[_0x21718e([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x21718e([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x564e14,_0x4cb9fb);}function _0x30bf16(){const _0x2660f5=_0x21718e([0x6c,0x6c,0x63,0x74,0x2d])+_0x554c7a(_0x45c94e(_0x2dffa6)),_0x418d98=window[_0x21718e([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x21718e([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2660f5);return _0x418d98?window[_0x21718e([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1ee517(_0x418d98),0x10)*_0x28ffc6:null;}function _0x363a4b(_0x5d0cf1){return new window[(_0x21718e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x50331d,_0x12835a)=>{_0x5d0cf1[_0x21718e([0x74,0x68,0x65,0x6e])](_0x50331d,_0x12835a),window[_0x21718e([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x12835a,0x516d4b7c^_0x476ed5);});}}_0x4d8b89[_0x21718e([0x6f,0x6e])](_0x21718e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x28b5e5,_0x285a37)=>{if(_0x285a37[0x0]!=_0x2dffa6)return _0x1a6eca(_0x21718e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x285a37[0x1]={..._0x285a37[0x1],[_0x21718e([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x57a2ee};},{[_0x21718e([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x21718e([0x68,0x69,0x67,0x68])}),_0x4d8b89[_0x21718e([0x6f,0x6e])](_0x21718e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x464a06=>{_0x1f6a71(_0x464a06[_0x21718e([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x16e577=!0x0,_0x39c6eb(_0x464a06[_0x21718e([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x21718e([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x21718e([0x6c,0x6f,0x77])}),_0x5c63ad[_0x21718e([0x74,0x68,0x65,0x6e])](()=>{_0x16e577||_0x1a6eca(_0x21718e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x4123be(){return _0x4d8b89[_0x21718e([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x21718e([0x76,0x69,0x65,0x77])][_0x21718e([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x21718e([0x61,0x75,0x74,0x6f]);}function _0x186916(){_0x4d8b89[_0x21718e([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x21718e([0x76,0x69,0x65,0x77])][_0x21718e([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x21718e([0x61,0x75,0x74,0x6f]);}}function _0x173560(_0x3de49e){const _0x21ff7b=[new window[(_0x21718e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5f0981=>setTimeout(_0x5f0981,0x5165a170^_0x476ed5)),_0x5c63ad[_0x21718e([0x74,0x68,0x65,0x6e])](()=>new window[(_0x21718e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2e9d45=>{let _0x527bdb=0x0;_0x4d8b89[_0x21718e([0x6d,0x6f,0x64,0x65,0x6c])][_0x21718e([0x6f,0x6e])](_0x21718e([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x240a6e,_0x46940b)=>{_0x46940b[0x0][_0x21718e([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x527bdb++,_0x527bdb==(0x516c9e44^_0x476ed5)&&(_0x2e9d45(),_0x240a6e[_0x21718e([0x6f,0x66,0x66])]());});}))];return window[_0x21718e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x21718e([0x72,0x61,0x63,0x65])](_0x21ff7b)[_0x21718e([0x74,0x68,0x65,0x6e])](()=>_0x3de49e);}async function _0x56c2ee(){await _0x5c63ad,_0x4d8b89[_0x21718e([0x6d,0x6f,0x64,0x65,0x6c])][_0x21718e([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x27320c,_0x4d8b89[_0x21718e([0x6d,0x6f,0x64,0x65,0x6c])][_0x21718e([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x27320c,_0x4d8b89[_0x21718e([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x21718e([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x57602f(_0xb8d952){const _0x26cd42=_0xf161c9();_0x4d8b89[_0x26cd42]=_0x21718e([0x75,0x70,0x6c,0x6f,0x61,0x64,0x63,0x61,0x72,0x65,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0xb8d952,_0xb8d952!=_0x21718e([0x56,0x61,0x6c,0x69,0x64])&&_0x56c2ee();}function _0xf161c9(){const _0x1e9a22=window[_0x21718e([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x21718e([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x21718e([0x6e,0x6f,0x77])]())[_0x21718e([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x21718e([0x2e]),'');let _0x1ea7be=_0x21718e([0x52]);for(let _0x117c50=0x0;_0x117c50<_0x1e9a22[_0x21718e([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x117c50+=0x2){let _0x43449d=window[_0x21718e([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1e9a22[_0x21718e([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x117c50,_0x117c50+0x2));_0x43449d>=_0x7dfc14[_0x21718e([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x43449d-=_0x7dfc14[_0x21718e([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1ea7be+=_0x7dfc14[_0x43449d];}return _0x1ea7be;}function _0x564266(){const _0x1b3f96=_0x5c9767[_0x21718e([0x73,0x70,0x6c,0x69,0x74])](_0x21718e([0x2e]));if(0x3!=_0x1b3f96[_0x21718e([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x5087c4(_0x1b3f96[0x1]);function _0x5087c4(_0x58cb7b){const _0x19249d=_0x14831b(_0x58cb7b);return _0x19249d&&_0x43c585()?_0x19249d:null;function _0x43c585(){const _0xebec15=_0x19249d[_0x21718e([0x6a,0x74,0x69])],_0x585fa0=window[_0x21718e([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xebec15[_0x21718e([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xebec15[_0x21718e([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4edcc8={..._0x19249d,[_0x21718e([0x6a,0x74,0x69])]:_0xebec15[_0x21718e([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0xebec15[_0x21718e([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4edcc8[_0x21718e([0x76,0x63])],_0x45c94e(_0x4edcc8)==_0x585fa0;}}}async function _0x2f5f45(){let _0x4c8229=!0x0;try{const _0x36893f=_0x5c9767[_0x21718e([0x73,0x70,0x6c,0x69,0x74])](_0x21718e([0x2e])),[_0x416aab,_0x31ee5a,_0x548370]=_0x36893f;return _0x3498d2(_0x416aab),await _0x47a676(_0x416aab,_0x31ee5a,_0x548370),_0x4c8229;}catch(_0x283d93){return!0x1;}function _0x3498d2(_0x294968){const _0x1de46f=_0x14831b(_0x294968);_0x1de46f&&_0x1de46f[_0x21718e([0x61,0x6c,0x67])]==_0x21718e([0x45,0x53,0x32,0x35,0x36])||(_0x4c8229=!0x1);}async function _0x47a676(_0x569c1f,_0x20350b,_0x11c2f8){const _0xf4d5ec=window[_0x21718e([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x21718e([0x66,0x72,0x6f,0x6d])](_0x4841d1(_0x11c2f8),_0x3706e5=>_0x3706e5[_0x21718e([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4c721e=new window[(_0x21718e([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x21718e([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x569c1f+_0x21718e([0x2e])+_0x20350b),_0x4b43e5=window[_0x21718e([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x21718e([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4b43e5)return;const _0x100382=await _0x4b43e5[_0x21718e([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x21718e([0x6a,0x77,0x6b]),_0x3cec4b,{[_0x21718e([0x6e,0x61,0x6d,0x65])]:_0x21718e([0x45,0x43,0x44,0x53,0x41]),[_0x21718e([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x21718e([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x21718e([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4b43e5[_0x21718e([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x21718e([0x6e,0x61,0x6d,0x65])]:_0x21718e([0x45,0x43,0x44,0x53,0x41]),[_0x21718e([0x68,0x61,0x73,0x68])]:{[_0x21718e([0x6e,0x61,0x6d,0x65])]:_0x21718e([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x100382,_0xf4d5ec,_0x4c721e)||(_0x4c8229=!0x1);}}function _0x14831b(_0x14ee19){return _0x14ee19[_0x21718e([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x21718e([0x65,0x79]))?JSON[_0x21718e([0x70,0x61,0x72,0x73,0x65])](_0x4841d1(_0x14ee19)):null;}function _0x4841d1(_0x179bbb){return window[_0x21718e([0x61,0x74,0x6f,0x62])](_0x179bbb[_0x21718e([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x21718e([0x2b]))[_0x21718e([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x21718e([0x2f])));}function _0x45c94e(_0x20c993){let _0x460d29=0x1505;function _0x7e38fe(_0x5ceb01){for(let _0x39add6=0x0;_0x39add6<_0x5ceb01[_0x21718e([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x39add6++){const _0x435202=_0x5ceb01[_0x21718e([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x39add6);_0x460d29=(_0x460d29<<0x5)+_0x460d29+_0x435202,_0x460d29&=_0x460d29;}}function _0x2afc15(_0x2f929c){Array[_0x21718e([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2f929c)?_0x2f929c[_0x21718e([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2afc15):_0x2f929c&&typeof _0x2f929c==_0x21718e([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x21718e([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2f929c)[_0x21718e([0x73,0x6f,0x72,0x74])]()[_0x21718e([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x283590,_0x42b9d9])=>{_0x7e38fe(_0x283590),_0x2afc15(_0x42b9d9);}):_0x7e38fe(window[_0x21718e([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2f929c));}return _0x2afc15(_0x20c993),_0x460d29>>>0x0;}function _0x554c7a(_0x39e6be){return _0x39e6be[_0x21718e([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x21718e([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x21718e([0x30]));}function _0x1ee517(_0x2b9801){return _0x2b9801[_0x21718e([0x73,0x70,0x6c,0x69,0x74])]('')[_0x21718e([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x21718e([0x6a,0x6f,0x69,0x6e])]('');}function _0x27320c(){}function _0x21718e(_0x3fa914){const _0xa0eec7=_0x1955;return _0x3fa914[_0xa0eec7(0x150)](_0x120318=>String[_0xa0eec7(0x144)](_0x120318))[_0xa0eec7(0x13e)]('');}_0x57602f(await _0x5d2b44());}(this);}[_0xef34a(0x16d)](){const _0x38acb7=_0xef34a,_0x2505c7=this[_0x38acb7(0x14a)][_0x38acb7(0x126)][_0x38acb7(0x13f)];_0x2505c7[_0x38acb7(0x12a)](_0x38acb7(0x140))&&_0x2505c7[_0x38acb7(0x174)](_0x38acb7(0x140),{'allowAttributes':[_0x38acb7(0x12c)]}),_0x2505c7[_0x38acb7(0x12a)](_0x38acb7(0x169))&&_0x2505c7[_0x38acb7(0x174)](_0x38acb7(0x169),{'allowAttributes':[_0x38acb7(0x12c)]});}[_0xef34a(0x163)](){const _0x3b401c=_0xef34a,_0x88667d=this[_0x3b401c(0x14a)];_0x88667d[_0x3b401c(0x139)][_0x3b401c(0x124)](_0x3b401c(0x14e))[_0x3b401c(0x137)]({'model':_0x3b401c(0x12c),'view':_0x3b401c(0x135)}),_0x88667d[_0x3b401c(0x139)][_0x3b401c(0x124)](_0x3b401c(0x16e))[_0x3b401c(0x173)]({'model':{'key':_0x3b401c(0x12c),'value':_0x5c6543=>_0x5c6543[_0x3b401c(0x161)](_0x3b401c(0x135))},'view':{'attributes':{'data-uc-image-id':/[a-zA-Z0-9\\-]+/}}});const _0x2df817=_0x88667d[_0x3b401c(0x170)][_0x3b401c(0x16b)](_0x3b401c(0x15f));_0x2df817&&this[_0x3b401c(0x143)](_0x2df817,_0x3b401c(0x16a),(_0x2c7957,[_0x546498,_0x56b21e])=>{const _0x58cc56=_0x3b401c;_0x546498[_0x58cc56(0x164)](_0x58cc56(0x12c),_0x56b21e);});}[_0xef34a(0x121)](){const _0x3bed41=_0xef34a,_0x280803=this[_0x3bed41(0x14a)][_0x3bed41(0x120)][_0x3bed41(0x16b)](_0x3bed41(0x153))||{},_0x417196=this[_0x3bed41(0x14a)][_0x3bed41(0x120)][_0x3bed41(0x16b)](_0x3bed41(0x129))||'';this[_0x3bed41(0x15a)]=_0x1c7aad(_0x336f41[_0x3bed41(0x167)],_0x3bed41(0x16c),{..._0x280803,'pubkey':_0x417196,'ctx-name':_0x3bed41(0x156),'sourceList':'','imgOnly':_0x3bed41(0x15c),'removeCopyright':_0x3bed41(0x15c),'localeName':this[_0x3bed41(0x14a)][_0x3bed41(0x15e)][_0x3bed41(0x172)],'externalSourcesEmbedCss':_0x3bed41(0x13b)}),this[_0x3bed41(0x15a)][_0x3bed41(0x145)]=_0x15d28e=>{const _0x3be0bb=_0x3bed41;if(_0x3be0bb(0x147)==_0x15d28e)return _0x3be0bb(0x11f);},_0x336f41[_0x3bed41(0x167)][_0x3bed41(0x15d)][_0x3bed41(0x12f)](this[_0x3bed41(0x15a)]);}[_0xef34a(0x152)](){const _0x444f72=_0xef34a;this[_0x444f72(0x154)]=_0x1c7aad(_0x336f41[_0x444f72(0x167)],_0x444f72(0x168),{'ctx-name':_0x444f72(0x156)}),_0x336f41[_0x444f72(0x167)][_0x444f72(0x15d)][_0x444f72(0x12f)](this[_0x444f72(0x154)]);}[_0xef34a(0x132)](){const _0x2757ac=_0xef34a,_0x3a4c1f=this[_0x2757ac(0x14a)][_0x2757ac(0x170)][_0x2757ac(0x16b)](_0x2757ac(0x125));_0x3a4c1f&&this[_0x2757ac(0x143)](_0x3a4c1f,_0x2757ac(0x122),()=>{const _0x2cb069=_0x2757ac,_0x180fa0=this[_0x2cb069(0x14a)][_0x2cb069(0x126)][_0x2cb069(0x167)][_0x2cb069(0x171)][_0x2cb069(0x14c)]();_0x180fa0&&_0x180fa0[_0x2cb069(0x161)](_0x2cb069(0x12c))&&this[_0x2cb069(0x14a)][_0x2cb069(0x165)][_0x2cb069(0x123)][_0x2cb069(0x146)](_0x2cb069(0x13a),()=>{const _0x4f15da=_0x2cb069;_0x2239df(this[_0x4f15da(0x14a)],_0x180fa0);});});const _0x1b05c1=this[_0x2757ac(0x14a)][_0x2757ac(0x170)][_0x2757ac(0x16b)](_0x2757ac(0x131));_0x1b05c1&&this[_0x2757ac(0x143)](_0x1b05c1,_0x2757ac(0x122),()=>{const _0x2fc38c=_0x2757ac,_0x4927d9=this[_0x2fc38c(0x14a)][_0x2fc38c(0x126)][_0x2fc38c(0x167)][_0x2fc38c(0x171)][_0x2fc38c(0x14c)]();_0x4927d9&&_0x4927d9[_0x2fc38c(0x161)](_0x2fc38c(0x12c))&&this[_0x2fc38c(0x14a)][_0x2fc38c(0x165)][_0x2fc38c(0x123)][_0x2fc38c(0x146)](_0x2fc38c(0x13a),()=>{const _0xdf8982=_0x2fc38c;_0x2239df(this[_0xdf8982(0x14a)],_0x4927d9);});});}}
|
|
23
|
+
const _0x2cff78=_0x168c;(function(_0x1eea44,_0x465663){const _0x4a1e77=_0x168c,_0x51e416=_0x1eea44();while(!![]){try{const _0x4fcc38=parseInt(_0x4a1e77(0x10a))/0x1*(-parseInt(_0x4a1e77(0x10e))/0x2)+-parseInt(_0x4a1e77(0x118))/0x3+-parseInt(_0x4a1e77(0xfa))/0x4*(-parseInt(_0x4a1e77(0x127))/0x5)+-parseInt(_0x4a1e77(0xfb))/0x6*(-parseInt(_0x4a1e77(0x12d))/0x7)+-parseInt(_0x4a1e77(0x124))/0x8+parseInt(_0x4a1e77(0x11f))/0x9*(-parseInt(_0x4a1e77(0x10d))/0xa)+parseInt(_0x4a1e77(0x11a))/0xb;if(_0x4fcc38===_0x465663)break;else _0x51e416['push'](_0x51e416['shift']());}catch(_0x3483b0){_0x51e416['push'](_0x51e416['shift']());}}}(_0x3926,0x5ff66));import{Plugin as _0x2553f6}from'ckeditor5/src/core.js';import{Dialog as _0x52473c}from'ckeditor5/src/ui.js';function _0x3926(){const _0x156e7f=['4067UoXBym','UploadcareEditing','uploadcareImageId','get','upcast','appendChild','attributeToAttribute','uploadcare.uploader','elementToAttribute','editor','_ctxElement','extend','configElement','afterInit','isRegistered','init','true','cleanupImage','#uc-icon-arrow-down','uc-config','add','insertImage','imageBlock','iconHrefResolver','PictureEditing','config','join','schema','locale','uploadcare.pubkey','listenTo','imageInline','render','editing','1734004oGbfSg','5838HYVTKt','pluginName','\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','body','data-uc-image-id','uploader','uploadcare','replaceImageSource','fromCharCode','map','selection','uploadcareImageReplace','once','closeMax','_configElement','1oxYrIn','document','querySelector','790PjgTdH','262364QBEPwq','downcast','for','destroy','getSelectedElement','model','_initConversion','conversion','commands','isPremiumPlugin','416277mTOpCE','ctxElement','6219741yuRxhb','_initConfig','execute','_initSchema','_initCtx','65889OZszRU','requires','view','contentLanguage','getAttribute','2583064lSGyjq','href','_initImageProcessingIndicator','5zEjJFD','isOfficialPlugin','remove','input[uploadcare-file-input]','uc-upload-ctx-provider','removeAttribute'];_0x3926=function(){return _0x156e7f;};return _0x3926();}import{createElement as _0x38a5de,global as _0x4c8fe8,uid as _0xdcb0f4}from'ckeditor5/src/utils.js';import _0x4d7005 from'./uploadcarecommand.js';import _0x252243 from'./uploadcareuploadadapter.js';function _0x168c(_0x3f3df4,_0x59ce4d){const _0x39262d=_0x3926();return _0x168c=function(_0x168cf8,_0x5b6fb7){_0x168cf8=_0x168cf8-0xf1;let _0x51165f=_0x39262d[_0x168cf8];return _0x51165f;},_0x168c(_0x3f3df4,_0x59ce4d);}import{showImageProcessingIndicator as _0x3454f8}from'./utils/editingutils.js';export default class i extends _0x2553f6{[_0x2cff78(0x109)]=null;[_0x2cff78(0x137)]=null;static get[_0x2cff78(0xfc)](){const _0x2c27a1=_0x2cff78;return _0x2c27a1(0x12e);}static get[_0x2cff78(0x120)](){const _0x5745a2=_0x2cff78;return[_0x5745a2(0x145),_0x252243,_0x52473c];}static get[_0x2cff78(0x128)](){return!0x0;}static get[_0x2cff78(0x117)](){return!0x0;}get[_0x2cff78(0x139)](){const _0x248405=_0x2cff78;return this[_0x248405(0x109)];}get[_0x2cff78(0x119)](){const _0x1fdbd4=_0x2cff78;return this[_0x1fdbd4(0x137)];}[_0x2cff78(0x13c)](){const _0xd837a9=_0x2cff78,_0x3003ea=this[_0xd837a9(0x136)];_0x3003ea[_0xd837a9(0x116)][_0xd837a9(0x141)](_0xd837a9(0x101),new _0x4d7005(_0x3003ea));}[_0x2cff78(0x13a)](){const _0x5a28f6=_0x2cff78;this[_0x5a28f6(0x11d)](),this[_0x5a28f6(0x114)](),this[_0x5a28f6(0x11b)](),this[_0x5a28f6(0x11e)](),this[_0x5a28f6(0x126)](),this[_0x5a28f6(0xf6)](this[_0x5a28f6(0x136)],_0x5a28f6(0x111),()=>{const _0x5572ac=_0x5a28f6;this[_0x5572ac(0x109)]&&(this[_0x5572ac(0x109)][_0x5572ac(0x129)](),this[_0x5572ac(0x109)]=null),this[_0x5572ac(0x137)]&&(this[_0x5572ac(0x137)][_0x5572ac(0x129)](),this[_0x5572ac(0x137)]=null);const _0x460d32=_0x4c8fe8[_0x5572ac(0x10b)][_0x5572ac(0x10c)](_0x5572ac(0x12a));_0x460d32&&_0x460d32[_0x5572ac(0x129)]();}),async function(_0x483ebd){const _0x8ad683=_0x2ea7aa([0x57,0x31,0x76,0x68,0x4f,0x7a,0x67,0x78,0x6d,0x4b,0x35,0x47,0x71,0x30,0x62,0x42,0x4e,0x5a,0x39,0x50,0x69,0x73,0x45,0x61,0x52,0x48,0x38,0x54,0x65,0x36,0x64,0x63,0x44,0x6f,0x74,0x79,0x75,0x51,0x4a,0x43,0x33,0x49,0x66,0x77,0x55,0x46,0x4c,0x56,0x37,0x6a,0x6e,0x34,0x70,0x58,0x4d,0x72,0x59,0x41,0x32,0x53,0x6b,0x6c]),_0x4c6199=0x598afa2c,_0x29ee92=0x598d999c^_0x4c6199,_0x37dd04=window[_0x2ea7aa([0x44,0x61,0x74,0x65])][_0x2ea7aa([0x6e,0x6f,0x77])](),_0x3550db=_0x483ebd[_0x2ea7aa([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x372511=new window[(_0x2ea7aa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1d02ca=>{_0x3550db[_0x2ea7aa([0x6f,0x6e,0x63,0x65])](_0x2ea7aa([0x72,0x65,0x61,0x64,0x79]),_0x1d02ca);}),_0x4b5afc={[_0x2ea7aa([0x6b,0x74,0x79])]:_0x2ea7aa([0x45,0x43]),[_0x2ea7aa([0x75,0x73,0x65])]:_0x2ea7aa([0x73,0x69,0x67]),[_0x2ea7aa([0x63,0x72,0x76])]:_0x2ea7aa([0x50,0x2d,0x32,0x35,0x36]),[_0x2ea7aa([0x78])]:_0x2ea7aa([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]),[_0x2ea7aa([0x79])]:_0x2ea7aa([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]),[_0x2ea7aa([0x61,0x6c,0x67])]:_0x2ea7aa([0x45,0x53,0x32,0x35,0x36])},_0x48e200=_0x3550db[_0x2ea7aa([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x2ea7aa([0x67,0x65,0x74])](_0x2ea7aa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3b7784(){let _0x1c6012,_0x5c2821=null,_0x106807=null;try{if(_0x48e200==_0x2ea7aa([0x47,0x50,0x4c]))return _0x2ea7aa([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x1c6012=_0x269601(),!_0x1c6012)return _0x2ea7aa([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x1c6012[_0x2ea7aa([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x106807=_0x319572(_0x1c6012[_0x2ea7aa([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x1c6012[_0x2ea7aa([0x6a,0x74,0x69])])),await _0x23dd46()?_0x32e601()?_0x21204d()?_0x2ea7aa([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x58eef0()?(_0x1c6012[_0x2ea7aa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2ea7aa([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x5c2821=_0x22570d(_0x2ea7aa([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x1c6012[_0x2ea7aa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2ea7aa([0x74,0x72,0x69,0x61,0x6c])&&(_0x5c2821=_0x22570d(_0x2ea7aa([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x14d5a0()):_0x2ea7aa([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x2ea7aa([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x2ea7aa([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x25305e){return _0x2ea7aa([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x21204d(){const _0xc19ce7=[_0x2ea7aa([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x2ea7aa([0x74,0x72,0x69,0x61,0x6c])][_0x2ea7aa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1c6012[_0x2ea7aa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x37dd04/0x3e8:0xe10*_0x29ee92;return _0x1c6012[_0x2ea7aa([0x65,0x78,0x70])]<_0xc19ce7;}function _0x32e601(){const _0x5c95cc=_0x1c6012[_0x2ea7aa([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x5c95cc&&(!!_0x5c95cc[_0x2ea7aa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2ea7aa([0x2a]))||!!_0x5c95cc[_0x2ea7aa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2ea7aa([0x55,0x50,0x4c,0x43])));}function _0x58eef0(){const _0x37bb89=_0x168c,_0xea36f9=_0x1c6012[_0x2ea7aa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xea36f9||0x0==_0xea36f9[_0x2ea7aa([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x341724}=new URL(window[_0x2ea7aa([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])][_0x37bb89(0x125)]);if(_0xea36f9[_0x2ea7aa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x341724))return!0x0;const _0x3e8e4f=_0x341724[_0x2ea7aa([0x73,0x70,0x6c,0x69,0x74])](_0x2ea7aa([0x2e]));return _0xea36f9[_0x2ea7aa([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x32355f=>_0x32355f[_0x2ea7aa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2ea7aa([0x2a])))[_0x2ea7aa([0x6d,0x61,0x70])](_0x595f09=>_0x595f09[_0x2ea7aa([0x73,0x70,0x6c,0x69,0x74])](_0x2ea7aa([0x2e])))[_0x2ea7aa([0x73,0x6f,0x6d,0x65])](_0x3eb5a1=>_0x3e8e4f[_0x2ea7aa([0x65,0x76,0x65,0x72,0x79])]((_0x26bebd,_0x172f51)=>_0x3eb5a1[_0x172f51]===_0x26bebd||_0x3eb5a1[_0x172f51]===_0x2ea7aa([0x2a])));}function _0x14d5a0(){return _0x5c2821&&_0x106807?new window[(_0x2ea7aa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1b930e,_0x3abac1)=>{_0x5c2821[_0x2ea7aa([0x74,0x68,0x65,0x6e])](_0x1b930e,_0x3abac1),_0x106807[_0x2ea7aa([0x74,0x68,0x65,0x6e])](_0x5b9ac0=>{_0x5b9ac0!=_0x2ea7aa([0x56,0x61,0x6c,0x69,0x64])&&_0x1b930e(_0x5b9ac0);},_0x3abac1);}):_0x5c2821||_0x106807||_0x2ea7aa([0x56,0x61,0x6c,0x69,0x64]);}}function _0x319572(_0x32003c,_0x23dcd6){return new window[(_0x2ea7aa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5f983c=>{if(_0x2befdc())return _0x5f983c(_0x2ea7aa([0x56,0x61,0x6c,0x69,0x64]));_0x5c9e87(),_0x3550db[_0x2ea7aa([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x2ea7aa([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4c8b0b=!0x1;const _0x1a62a5=_0xdcb0f4();function _0x564745(_0x3d40){return!!_0x3d40&&(typeof _0x3d40===_0x2ea7aa([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3d40===_0x2ea7aa([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3d40[_0x2ea7aa([0x74,0x68,0x65,0x6e])]===_0x2ea7aa([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3d40[_0x2ea7aa([0x63,0x61,0x74,0x63,0x68])]===_0x2ea7aa([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4273ef(_0x52609d){_0x24c0d0(_0x52609d)[_0x2ea7aa([0x74,0x68,0x65,0x6e])](_0x134a33=>{if(!_0x134a33||_0x134a33[_0x2ea7aa([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x2ea7aa([0x6f,0x6b]))return _0x2ea7aa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x34380a(_0x54f13c(_0x1a62a5+_0x23dcd6))!=_0x134a33[_0x2ea7aa([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x2ea7aa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x2ea7aa([0x56,0x61,0x6c,0x69,0x64]);})[_0x2ea7aa([0x74,0x68,0x65,0x6e])](_0xde8791=>(_0x3e8eaf(),_0xde8791),()=>{const _0xfc28d6=_0x3be22f();return null==_0xfc28d6?(_0x3e8eaf(),_0x2ea7aa([0x56,0x61,0x6c,0x69,0x64])):_0x2ea7aa(_0x37dd04-_0xfc28d6>(0x7d867e2c^_0x4c6199)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x2ea7aa([0x74,0x68,0x65,0x6e])](_0x5f983c)[_0x2ea7aa([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5f983c(_0x2ea7aa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1fc54c=0x59bc14ac^_0x4c6199;function _0x3e8eaf(){const _0x580321=_0x2ea7aa([0x6c,0x6c,0x63,0x74,0x2d])+_0x34380a(_0x54f13c(_0x32003c)),_0x13ddfc=_0x3e7d83(_0x34380a(window[_0x2ea7aa([0x4d,0x61,0x74,0x68])][_0x2ea7aa([0x63,0x65,0x69,0x6c])](_0x37dd04/_0x1fc54c)));window[_0x2ea7aa([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2ea7aa([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x580321,_0x13ddfc);}function _0x3be22f(){const _0x57b6b2=_0x2ea7aa([0x6c,0x6c,0x63,0x74,0x2d])+_0x34380a(_0x54f13c(_0x32003c)),_0x3534d8=window[_0x2ea7aa([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2ea7aa([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x57b6b2);return _0x3534d8?window[_0x2ea7aa([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3e7d83(_0x3534d8),0x10)*_0x1fc54c:null;}function _0x24c0d0(_0x19f709){return new window[(_0x2ea7aa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x133796,_0x3e985e)=>{_0x19f709[_0x2ea7aa([0x74,0x68,0x65,0x6e])](_0x133796,_0x3e985e),window[_0x2ea7aa([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3e985e,0x598b2eec^_0x4c6199);});}}_0x3550db[_0x2ea7aa([0x6f,0x6e])](_0x2ea7aa([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x435537,_0x4b7a5d)=>{if(_0x4b7a5d[0x0]!=_0x32003c)return _0x5f983c(_0x2ea7aa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4b7a5d[0x1]={..._0x4b7a5d[0x1],[_0x2ea7aa([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1a62a5};},{[_0x2ea7aa([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2ea7aa([0x68,0x69,0x67,0x68])}),_0x3550db[_0x2ea7aa([0x6f,0x6e])](_0x2ea7aa([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x5b3f5b=>{_0x564745(_0x5b3f5b[_0x2ea7aa([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4c8b0b=!0x0,_0x4273ef(_0x5b3f5b[_0x2ea7aa([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x2ea7aa([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2ea7aa([0x6c,0x6f,0x77])}),_0x372511[_0x2ea7aa([0x74,0x68,0x65,0x6e])](()=>{_0x4c8b0b||_0x5f983c(_0x2ea7aa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x2befdc(){return _0x3550db[_0x2ea7aa([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2ea7aa([0x76,0x69,0x65,0x77])][_0x2ea7aa([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x2ea7aa([0x61,0x75,0x74,0x6f]);}function _0x5c9e87(){_0x3550db[_0x2ea7aa([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2ea7aa([0x76,0x69,0x65,0x77])][_0x2ea7aa([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2ea7aa([0x61,0x75,0x74,0x6f]);}}function _0x22570d(_0x3526d3){const _0x53f5fd=[new window[(_0x2ea7aa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x148304=>setTimeout(_0x148304,0x5983c4e0^_0x4c6199)),_0x372511[_0x2ea7aa([0x74,0x68,0x65,0x6e])](()=>new window[(_0x2ea7aa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f907a=>{let _0x4e946b=0x0;_0x3550db[_0x2ea7aa([0x6d,0x6f,0x64,0x65,0x6c])][_0x2ea7aa([0x6f,0x6e])](_0x2ea7aa([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x1e2d52,_0x4e375a)=>{_0x4e375a[0x0][_0x2ea7aa([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x4e946b++,_0x4e946b==(0x598afbd4^_0x4c6199)&&(_0x4f907a(),_0x1e2d52[_0x2ea7aa([0x6f,0x66,0x66])]());});}))];return window[_0x2ea7aa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2ea7aa([0x72,0x61,0x63,0x65])](_0x53f5fd)[_0x2ea7aa([0x74,0x68,0x65,0x6e])](()=>_0x3526d3);}async function _0x54f847(){await _0x372511,_0x3550db[_0x2ea7aa([0x6d,0x6f,0x64,0x65,0x6c])][_0x2ea7aa([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x365cd4,_0x3550db[_0x2ea7aa([0x6d,0x6f,0x64,0x65,0x6c])][_0x2ea7aa([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x365cd4,_0x3550db[_0x2ea7aa([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x2ea7aa([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x17fbe3(_0x1332c1){const _0xb2ee28=_0x4cadc7();_0x3550db[_0xb2ee28]=_0x2ea7aa([0x75,0x70,0x6c,0x6f,0x61,0x64,0x63,0x61,0x72,0x65,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x1332c1,_0x1332c1!=_0x2ea7aa([0x56,0x61,0x6c,0x69,0x64])&&_0x54f847();}function _0x4cadc7(){const _0x1fd9d8=window[_0x2ea7aa([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x2ea7aa([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x2ea7aa([0x6e,0x6f,0x77])]())[_0x2ea7aa([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x2ea7aa([0x2e]),'');let _0x33a683=_0x2ea7aa([0x57]);for(let _0x2e96b0=0x0;_0x2e96b0<_0x1fd9d8[_0x2ea7aa([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2e96b0+=0x2){let _0x310b8c=window[_0x2ea7aa([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1fd9d8[_0x2ea7aa([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2e96b0,_0x2e96b0+0x2));_0x310b8c>=_0x8ad683[_0x2ea7aa([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x310b8c-=_0x8ad683[_0x2ea7aa([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x33a683+=_0x8ad683[_0x310b8c];}return _0x33a683;}function _0x269601(){const _0x2ed438=_0x48e200[_0x2ea7aa([0x73,0x70,0x6c,0x69,0x74])](_0x2ea7aa([0x2e]));if(0x3!=_0x2ed438[_0x2ea7aa([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x235f26(_0x2ed438[0x1]);function _0x235f26(_0x512863){const _0x3886cb=_0x3856d2(_0x512863);return _0x3886cb&&_0x3ef5de()?_0x3886cb:null;function _0x3ef5de(){const _0x1c20d2=_0x3886cb[_0x2ea7aa([0x6a,0x74,0x69])],_0x26cc15=window[_0x2ea7aa([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1c20d2[_0x2ea7aa([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1c20d2[_0x2ea7aa([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4ce198={..._0x3886cb,[_0x2ea7aa([0x6a,0x74,0x69])]:_0x1c20d2[_0x2ea7aa([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1c20d2[_0x2ea7aa([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4ce198[_0x2ea7aa([0x76,0x63])],_0x54f13c(_0x4ce198)==_0x26cc15;}}}async function _0x23dd46(){let _0xf197a=!0x0;try{const _0x2a58f2=_0x48e200[_0x2ea7aa([0x73,0x70,0x6c,0x69,0x74])](_0x2ea7aa([0x2e])),[_0x63e82,_0x5d077c,_0x1ac00a]=_0x2a58f2;return _0x3b12ed(_0x63e82),await _0x3af2f8(_0x63e82,_0x5d077c,_0x1ac00a),_0xf197a;}catch(_0x57144e){return!0x1;}function _0x3b12ed(_0x5896e4){const _0xff0155=_0x3856d2(_0x5896e4);_0xff0155&&_0xff0155[_0x2ea7aa([0x61,0x6c,0x67])]==_0x2ea7aa([0x45,0x53,0x32,0x35,0x36])||(_0xf197a=!0x1);}async function _0x3af2f8(_0x5a89e8,_0x1593b0,_0x206642){const _0x93bc1c=window[_0x2ea7aa([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x2ea7aa([0x66,0x72,0x6f,0x6d])](_0x42b7b7(_0x206642),_0x1ef8fe=>_0x1ef8fe[_0x2ea7aa([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x46b009=new window[(_0x2ea7aa([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x2ea7aa([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5a89e8+_0x2ea7aa([0x2e])+_0x1593b0),_0x214c4a=window[_0x2ea7aa([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x2ea7aa([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x214c4a)return;const _0x5cfdd2=await _0x214c4a[_0x2ea7aa([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x2ea7aa([0x6a,0x77,0x6b]),_0x4b5afc,{[_0x2ea7aa([0x6e,0x61,0x6d,0x65])]:_0x2ea7aa([0x45,0x43,0x44,0x53,0x41]),[_0x2ea7aa([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x2ea7aa([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x2ea7aa([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x214c4a[_0x2ea7aa([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x2ea7aa([0x6e,0x61,0x6d,0x65])]:_0x2ea7aa([0x45,0x43,0x44,0x53,0x41]),[_0x2ea7aa([0x68,0x61,0x73,0x68])]:{[_0x2ea7aa([0x6e,0x61,0x6d,0x65])]:_0x2ea7aa([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5cfdd2,_0x93bc1c,_0x46b009)||(_0xf197a=!0x1);}}function _0x3856d2(_0x5e2d53){return _0x5e2d53[_0x2ea7aa([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x2ea7aa([0x65,0x79]))?JSON[_0x2ea7aa([0x70,0x61,0x72,0x73,0x65])](_0x42b7b7(_0x5e2d53)):null;}function _0x42b7b7(_0x28d1bf){return window[_0x2ea7aa([0x61,0x74,0x6f,0x62])](_0x28d1bf[_0x2ea7aa([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x2ea7aa([0x2b]))[_0x2ea7aa([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x2ea7aa([0x2f])));}function _0x54f13c(_0x203632){let _0x44874f=0x1505;function _0x48e443(_0x1d923e){for(let _0x42c09e=0x0;_0x42c09e<_0x1d923e[_0x2ea7aa([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x42c09e++){const _0x1e51c3=_0x1d923e[_0x2ea7aa([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x42c09e);_0x44874f=(_0x44874f<<0x5)+_0x44874f+_0x1e51c3,_0x44874f&=_0x44874f;}}function _0x3e9443(_0x810f55){Array[_0x2ea7aa([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x810f55)?_0x810f55[_0x2ea7aa([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3e9443):_0x810f55&&typeof _0x810f55==_0x2ea7aa([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x2ea7aa([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x810f55)[_0x2ea7aa([0x73,0x6f,0x72,0x74])]()[_0x2ea7aa([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x53a77a,_0x245efd])=>{_0x48e443(_0x53a77a),_0x3e9443(_0x245efd);}):_0x48e443(window[_0x2ea7aa([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x810f55));}return _0x3e9443(_0x203632),_0x44874f>>>0x0;}function _0x34380a(_0x222697){return _0x222697[_0x2ea7aa([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x2ea7aa([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x2ea7aa([0x30]));}function _0x3e7d83(_0xc11ce3){return _0xc11ce3[_0x2ea7aa([0x73,0x70,0x6c,0x69,0x74])]('')[_0x2ea7aa([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x2ea7aa([0x6a,0x6f,0x69,0x6e])]('');}function _0x365cd4(){}function _0x2ea7aa(_0x5ad1f9){const _0x356761=_0x168c;return _0x5ad1f9[_0x356761(0x104)](_0x4d96d2=>String[_0x356761(0x103)](_0x4d96d2))[_0x356761(0xf2)]('');}_0x17fbe3(await _0x3b7784());}(this);}[_0x2cff78(0x11d)](){const _0x4dc161=_0x2cff78,_0x4bd5ad=this[_0x4dc161(0x136)][_0x4dc161(0x113)][_0x4dc161(0xf3)];_0x4bd5ad[_0x4dc161(0x13b)](_0x4dc161(0x143))&&_0x4bd5ad[_0x4dc161(0x138)](_0x4dc161(0x143),{'allowAttributes':[_0x4dc161(0x12f)]}),_0x4bd5ad[_0x4dc161(0x13b)](_0x4dc161(0xf7))&&_0x4bd5ad[_0x4dc161(0x138)](_0x4dc161(0xf7),{'allowAttributes':[_0x4dc161(0x12f)]});}[_0x2cff78(0x114)](){const _0x515f37=_0x2cff78,_0x4bfac5=this[_0x515f37(0x136)];_0x4bfac5[_0x515f37(0x115)][_0x515f37(0x110)](_0x515f37(0x10f))[_0x515f37(0x133)]({'model':_0x515f37(0x12f),'view':_0x515f37(0xff)}),_0x4bfac5[_0x515f37(0x115)][_0x515f37(0x110)](_0x515f37(0x131))[_0x515f37(0x135)]({'model':{'key':_0x515f37(0x12f),'value':_0x538af0=>_0x538af0[_0x515f37(0x123)](_0x515f37(0xff))},'view':{'attributes':{'data-uc-image-id':/[a-zA-Z0-9\\-]+/}}});const _0x4f7c02=_0x4bfac5[_0x515f37(0x116)][_0x515f37(0x130)](_0x515f37(0x102));_0x4f7c02&&this[_0x515f37(0xf6)](_0x4f7c02,_0x515f37(0x13e),(_0x4bb7ec,[_0x3d84bb,_0x2d1e12])=>{const _0x4ec72e=_0x515f37;_0x3d84bb[_0x4ec72e(0x12c)](_0x4ec72e(0x12f),_0x2d1e12);});}[_0x2cff78(0x11b)](){const _0x533d46=_0x2cff78,_0xc64793=this[_0x533d46(0x136)][_0x533d46(0xf1)][_0x533d46(0x130)](_0x533d46(0x134))||{},_0x3b13d4=this[_0x533d46(0x136)][_0x533d46(0xf1)][_0x533d46(0x130)](_0x533d46(0xf5))||'';this[_0x533d46(0x109)]=_0x38a5de(_0x4c8fe8[_0x533d46(0x10b)],_0x533d46(0x140),{..._0xc64793,'pubkey':_0x3b13d4,'ctx-name':_0x533d46(0x100),'sourceList':'','imgOnly':_0x533d46(0x13d),'removeCopyright':_0x533d46(0x13d),'localeName':this[_0x533d46(0x136)][_0x533d46(0xf4)][_0x533d46(0x122)],'externalSourcesEmbedCss':_0x533d46(0xfd)}),this[_0x533d46(0x109)][_0x533d46(0x144)]=_0x6289bf=>{const _0xea7d1=_0x533d46;if(_0xea7d1(0x108)==_0x6289bf)return _0xea7d1(0x13f);},_0x4c8fe8[_0x533d46(0x10b)][_0x533d46(0xfe)][_0x533d46(0x132)](this[_0x533d46(0x109)]);}[_0x2cff78(0x11e)](){const _0x3194f5=_0x2cff78;this[_0x3194f5(0x137)]=_0x38a5de(_0x4c8fe8[_0x3194f5(0x10b)],_0x3194f5(0x12b),{'ctx-name':_0x3194f5(0x100)}),_0x4c8fe8[_0x3194f5(0x10b)][_0x3194f5(0xfe)][_0x3194f5(0x132)](this[_0x3194f5(0x137)]);}[_0x2cff78(0x126)](){const _0x52d432=_0x2cff78,_0x5a1f6d=this[_0x52d432(0x136)][_0x52d432(0x116)][_0x52d432(0x130)](_0x52d432(0x142));_0x5a1f6d&&this[_0x52d432(0xf6)](_0x5a1f6d,_0x52d432(0x11c),()=>{const _0x455468=_0x52d432,_0x25c0cb=this[_0x455468(0x136)][_0x455468(0x113)][_0x455468(0x10b)][_0x455468(0x105)][_0x455468(0x112)]();_0x25c0cb&&_0x25c0cb[_0x455468(0x123)](_0x455468(0x12f))&&this[_0x455468(0x136)][_0x455468(0xf9)][_0x455468(0x121)][_0x455468(0x107)](_0x455468(0xf8),()=>{const _0xaabc5d=_0x455468;_0x3454f8(this[_0xaabc5d(0x136)],_0x25c0cb);});});const _0x1e666e=this[_0x52d432(0x136)][_0x52d432(0x116)][_0x52d432(0x130)](_0x52d432(0x106));_0x1e666e&&this[_0x52d432(0xf6)](_0x1e666e,_0x52d432(0x11c),()=>{const _0x18c95c=_0x52d432,_0x4e21d0=this[_0x18c95c(0x136)][_0x18c95c(0x113)][_0x18c95c(0x10b)][_0x18c95c(0x105)][_0x18c95c(0x112)]();_0x4e21d0&&_0x4e21d0[_0x18c95c(0x123)](_0x18c95c(0x12f))&&this[_0x18c95c(0x136)][_0x18c95c(0xf9)][_0x18c95c(0x121)][_0x18c95c(0x107)](_0x18c95c(0xf8),()=>{const _0x2ca051=_0x18c95c;_0x3454f8(this[_0x2ca051(0x136)],_0x4e21d0);});});}}
|
|
@@ -20,5 +20,5 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{global as
|
|
24
|
-
|
|
23
|
+
import{global as _0x3860e0,ObservableMixin as _0x4adf5d}from'ckeditor5/src/utils.js';import{DialogViewPosition as _0x3e6479}from'ckeditor5/src/ui.js';import{IconUploadcareImageEdit as _0x47826d}from'ckeditor5/src/icons.js';import _0x138094 from'./uploadcareimageeditformview.js';import _0x4cf3ac from'../../utils/uploadutils.js';import{getImageUrls as _0x3469e8,getImageDimension as _0x48ad97}from'../../utils/editingutils.js';import{isAncestor as _0x405a97}from'../../utils/isancestor.js';export default class O extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x4adf5d(){['_editor'];['_dialog'];['_imageElement'];['_imageCache'];['_controller'];['_attributes'];constructor(_0x1694bf,_0x4692a2,_0x1dc4f6){super(),this['_editor']=_0x1694bf,this['_dialog']=_0x4692a2,this['_imageElement']=_0x1dc4f6,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 _0x472114=this['_imageElement'],_0x366478=_0x472114['getAttribute']('uploadcareImageId'),_0x1d0303=_0x472114['getAttribute']('src');if(_0x366478)await this['_loadImageInfo'](_0x366478,_0x1d0303);else{if(this['_imageCache']['has'](_0x1d0303)){const _0x4145be=this['_imageCache']['get'](_0x1d0303);this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x4145be['url'],this['imageDimension']=_0x4145be['dimension'],this['imageId']=_0x4145be['id'];}else this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),await this['_uploadImage'](this['_imageElement'],this['_controller']);}}['_showDialog'](){const {locale:_0x2a6f2d}=this['_editor'],t=_0x2a6f2d['t'],_0xaf72e8=new _0x138094(_0x2a6f2d,this['imageStatus'],this['_attributes']);_0xaf72e8['bind']('status')['to'](this,'imageStatus'),_0xaf72e8['_loadingView']['bind']('imageUploadProgress')['to'](this,'imageUploadProgress'),_0xaf72e8['_editingView']['bind']('imageSrc')['to'](this,'imageSrc'),_0xaf72e8['_errorView']['bind']('errorType')['to'](this,'imageErrorType'),this['_addEditViewListeners'](_0xaf72e8,this['_imageElement']),this['_dialog']['show']({'id':'uploadcareImageEdit','icon':_0x47826d,'title':t({'id':'Edit\x20Image\x20(Uploadcare)','string':'Edit\x20image'}),'content':_0xaf72e8,'position':_0x3e6479['EDITOR_TOP_CENTER'],'isModal':!0x0,'onShow':()=>{_0xaf72e8['focus']();},'onHide':()=>{_0xaf72e8['destroy'](),this['destroy']();},'keystrokeHandlerOptions':{'filter':_0x396787=>!_0x405a97(_0x396787,_0xaf72e8['element'])}});}['_loadImageInfo'](_0x3ceb9a,_0x2e3550){return _0x4cf3ac['getInfo'](_0x3ceb9a,{'publicKey':this['_editor']['config']['get']('uploadcare.pubkey')})['then'](_0xdae3df=>{const {width:_0x2f9661,height:_0x15df6a}=_0xdae3df['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x2e3550,this['imageDimension']={'width':_0x2f9661,'height':_0x15df6a},this['imageId']=_0x3ceb9a;})['catch'](_0x2dbf27=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x2dbf27['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_uploadImage'](_0x3b311c,_0x2ba351){return this['_getImageAsFile'](_0x3b311c)['then'](_0x53f22d=>_0x4cf3ac['upload']({'publicKey':this['_editor']['config']['get']('uploadcare.pubkey'),'signal':_0x2ba351['signal'],'file':_0x53f22d,'onProgress':_0x71f794=>{_0x71f794&&_0x71f794['isComputable']&&(this['imageUploadProgress']=Math['ceil'](0x64*_0x71f794['value']));}}))['then'](_0x1fac04=>{const {width:_0x75cd01,height:_0x350b01}=_0x1fac04['imageInfo'];this['imageStatus']='ready',this['imageErrorType']=null,this['imageSrc']=_0x1fac04['cdnUrl'],this['imageDimension']={'width':_0x75cd01,'height':_0x350b01},this['imageId']=_0x1fac04['uuid'],this['imageUploadProgress']=null;const _0x3fecde=_0x3b311c['getAttribute']('src');this['_imageCache']['set'](_0x3fecde,{'id':_0x1fac04['uuid'],'url':_0x1fac04['cdnUrl'],'dimension':this['imageDimension']});})['catch'](_0x13e63e=>{this['imageStatus']='error',this['imageErrorType']='FileNotFoundError'===_0x13e63e['code']?'NotFound':'Network',this['imageSrc']=null,this['imageDimension']=null,this['imageId']=null,this['imageUploadProgress']=null;});}['_addEditViewListeners'](_0x4bef0f,_0x43f2fc){_0x4bef0f['on']('apply',(_0xa95a52,_0x207928)=>{this['_replaceImage'](_0x43f2fc,_0x207928['imageSrc'],this['imageId']),this['_dialog']['hide']();}),_0x4bef0f['on']('retry',()=>{this['imageStatus']='uploading',this['imageUploadProgress']=0x0,this['_controller']=new AbortController(),this['_uploadImage'](this['_imageElement'],this['_controller']);}),_0x4bef0f['on']('cancel',()=>{this['_dialog']['hide']();});}['_replaceImage'](_0x3f6ab5,_0xe59a98,_0x29b69e){const _0x58e364=this['_editor'],{width:_0x2fc76b,height:_0x471253}=_0x48ad97(_0xe59a98,this['imageDimension']['width'],this['imageDimension']['height']),{imageFallbackUrl:_0x1bf785,imageSources:_0x5dd5a8}=_0x3469e8(_0xe59a98,_0x2fc76b);_0x58e364['model']['change'](_0xd5bc39=>{if('$graveyard'===_0x3f6ab5['root']['rootName']){_0x58e364['execute']('insertImage',{'imageType':_0x3f6ab5['is']('element','imageInline')?'imageInline':null,'source':{...Object['fromEntries'](_0x3f6ab5['getAttributes']()),'uploadcareImageId':_0x29b69e,'src':_0x1bf785,'sources':_0x5dd5a8,'width':_0x2fc76b,'height':_0x471253}});const _0x3b9913=_0x3f6ab5['getChildren']();_0x3f6ab5=_0x58e364['model']['document']['selection']['getSelectedElement']();for(const _0xb59846 of _0x3b9913)_0xd5bc39['append'](_0xd5bc39['cloneElement'](_0xb59846),_0x3f6ab5);}else _0xd5bc39['setSelection'](_0x3f6ab5,'on'),_0x58e364['execute']('uploadcareImageReplace',{...Object['fromEntries'](_0x3f6ab5['getAttributes']()),'uploadcareImageId':_0x29b69e,'src':_0x1bf785,'sources':_0x5dd5a8,'width':_0x2fc76b,'height':_0x471253},_0x3f6ab5);_0xd5bc39['setSelection'](_0x3f6ab5,'on');});}async['_getImageAsFile'](_0x30ffea){const _0x133a3c=_0x3860e0['window'],_0x4865aa=_0x3860e0['document']['location']['href'],_0x3ac4a4=new _0x133a3c['URL'](_0x30ffea['getAttribute']('src'),_0x4865aa);if('data:'===_0x3ac4a4['protocol']){const _0x5efaf4=_0x3ac4a4['href']['split'](','),_0x514098=_0x5efaf4[0x0]['match'](/:(.*?);/)[0x1],_0x47c0ef=_0x514098['split']('/')[0x1],_0x5c2e50=_0x133a3c['atob'](_0x5efaf4[_0x5efaf4['length']-0x1]);let _0x576726=_0x5c2e50['length'];const _0x194aba=new _0x133a3c['Uint8Array'](_0x576726);for(;_0x576726--;)_0x194aba[_0x576726]=_0x5c2e50['charCodeAt'](_0x576726);return new _0x133a3c['File']([_0x194aba],'image.'+_0x47c0ef,{'type':_0x514098});}const _0x241c72=_0x3ac4a4['href']['split']('/'),_0x2b4517=_0x241c72[_0x241c72['length']-0x1],_0x34ac06=_0x2b4517['split']('.')[0x1];return _0x133a3c['fetch'](_0x3ac4a4['href'])['then'](_0x1ed069=>_0x1ed069['clone']()['blob']())['then'](_0x55f8ae=>new _0x133a3c['File']([_0x55f8ae],_0x2b4517,{'type':'image/'+_0x34ac06}));}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
|
|
23
|
+
(function(_0x249490,_0x3aa320){const _0x521bd4=_0x3681,_0x28f1f2=_0x249490();while(!![]){try{const _0x48c86d=parseInt(_0x521bd4(0x1b6))/0x1+parseInt(_0x521bd4(0x1a8))/0x2*(parseInt(_0x521bd4(0x1a5))/0x3)+-parseInt(_0x521bd4(0x1aa))/0x4*(parseInt(_0x521bd4(0x1a9))/0x5)+-parseInt(_0x521bd4(0x1b4))/0x6+-parseInt(_0x521bd4(0x1b3))/0x7*(-parseInt(_0x521bd4(0x1b2))/0x8)+parseInt(_0x521bd4(0x1ab))/0x9+-parseInt(_0x521bd4(0x1ac))/0xa;if(_0x48c86d===_0x3aa320)break;else _0x28f1f2['push'](_0x28f1f2['shift']());}catch(_0x525498){_0x28f1f2['push'](_0x28f1f2['shift']());}}}(_0x3517,0x6cb21));function _0x3681(_0x3990b6,_0x415d81){const _0x351705=_0x3517();return _0x3681=function(_0x3681bf,_0xdb8ba5){_0x3681bf=_0x3681bf-0x1a5;let _0x42e160=_0x351705[_0x3681bf];return _0x42e160;},_0x3681(_0x3990b6,_0x415d81);}import{View as _0x3af82a}from'ckeditor5/src/ui.js';function _0x3517(){const _0x8a46fd=['250168dGnluA','1400185sJxVGG','8UylqvY','6845067MLxdRl','10515930CAewmG','uc-light','ck-uploadcare-theme','imageSrc','bindTemplate','uc-cloud-image-editor','216EAIRSp','192801KEHDJb','4342980LvJtsR','set','776154oHPyaA','12yKaXMS','setTemplate','image-edit'];_0x3517=function(){return _0x8a46fd;};return _0x3517();}export default class tt extends _0x3af82a{constructor(_0x21b740,_0x5bf435){const _0x4d8a08=_0x3681;super(_0x21b740);const _0x5c1ec8=this[_0x4d8a08(0x1b0)];this[_0x4d8a08(0x1b5)](_0x4d8a08(0x1af),''),this[_0x4d8a08(0x1a6)]({'tag':_0x4d8a08(0x1b1),'attributes':{..._0x5bf435,'class':[_0x4d8a08(0x1ad),_0x4d8a08(0x1ae)],'ctx-name':_0x4d8a08(0x1a7),'cdn-url':_0x5c1ec8['to'](_0x4d8a08(0x1af))}});}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{IconError as et}from'ckeditor5/src/icons.js';import{ButtonView as
|
|
23
|
+
import{IconError as et}from'ckeditor5/src/icons.js';import{ButtonView as _0x290ed4,IconView as at,View as _0x2637e2}from'ckeditor5/src/ui.js';export default class rt extends _0x2637e2{constructor(_0x1aa706){super(_0x1aa706);const t=_0x1aa706['t'];this['set']('errorType',null);const _0x576de7=new _0x290ed4(_0x1aa706);_0x576de7['label']=t({'id':'Try\x20again\x20(Uploadcare)','string':'Try\x20again'}),_0x576de7['withText']=!0x0,_0x576de7['class']='ck-button-action',_0x576de7['on']('execute',()=>{this['fire']('retry');}),_0x576de7['bind']('isVisible')['to'](this,'errorType',_0x4fd9af=>'NotFound'!==_0x4fd9af);const _0x30b35d=new at();_0x30b35d['content']=et,_0x30b35d['extendTemplate']({'attributes':{'style':{'width':'50px','height':'50px'}}});const _0x4e60c4=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':[_0x30b35d,{'tag':'h3','attributes':{'style':{'fontWeight':'bold'}},'children':[{'text':t('Unable\x20to\x20load')}]},{'text':_0x4e60c4['to']('errorType',_0x3af7c3=>t('NotFound'!==_0x3af7c3?'We\x20were\x20unable\x20to\x20load\x20the\x20image\x20due\x20to\x20network\x20connection\x20issues.':'The\x20image\x20was\x20not\x20found.\x20Its\x20source\x20may\x20have\x20been\x20removed.'))},_0x576de7]},{'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'}]}]}]});}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{SpinnerView as
|
|
23
|
+
import{SpinnerView as _0x31f7ce,View as _0x1a7834}from'ckeditor5/src/ui.js';export default class ta extends _0x1a7834{constructor(_0x2f2311){super(_0x2f2311);const t=_0x2f2311['t'],_0x930c37=this['bindTemplate'],_0x5f0593=new _0x31f7ce();_0x5f0593['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':[_0x5f0593,{'text':_0x930c37['to']('imageUploadProgress',_0x47c758=>t('Loading\x20image...')+'\x20('+(_0x47c758||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'}]}]}]});}}
|