@ckeditor/ckeditor5-case-change
Version:
Case change feature for CKEditor 5.
23 lines • 20.4 kB
JavaScript
/*
* Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
*
*
*
*
* +---------------------------------------------------------------------------------+
* | |
* | Hello stranger! |
* | |
* | |
* | What you're currently looking at is the source code of a legally protected, |
* | proprietary software. Any attempts to deobfuscate / disassemble this code |
* | are forbidden and will result in legal consequences. |
* | |
* | |
* +---------------------------------------------------------------------------------+
*
*
*
*
*/
import{Command as _0x2b17f3,Plugin as _0x2cd011}from'@ckeditor/ckeditor5-core';import{Collection as _0x3f3e91,uid as _0x1cc2bb}from'@ckeditor/ckeditor5-utils';import{MenuBarMenuListItemButtonView as _0x24baec,MenuBarMenuListItemView as _0x1ac65c,MenuBarMenuListView as _0x112b0c,MenuBarMenuView as _0x1533e,UIModel as _0x291158,addListToDropdown as _0x3aa6c0,createDropdown as _0xfcfb2f}from'@ckeditor/ckeditor5-ui';import{IconCaseChange as _0x5d143e}from'@ckeditor/ckeditor5-icons';var h=class extends _0x2b17f3{['_transformCallback'];constructor(_0x27d946,_0x405326){super(_0x27d946),this['_transformCallback']=_0x405326;}['execute'](){const _0x2bac34=this['editor']['model'],_0x2f1a38=Array['from'](this['_getAffectedRanges']()),_0x135ad7=Array['from'](_0x2bac34['document']['selection']['getRanges']());_0x2bac34['change'](_0x36fcab=>{for(const _0x204667 of _0x2f1a38)this['_modifyContent'](_0x204667,_0x36fcab);_0x36fcab['setSelection'](_0x135ad7);});}['refresh'](){for(const _0x58b192 of this['_getAffectedRanges']())for(const _0x13bfc0 of _0x58b192)if(_0x13bfc0['item']['is']('$textProxy'))return void(this['isEnabled']=!0x0);this['isEnabled']=!0x1;}['_getAffectedRanges'](){const _0x5a7644=this['editor']['model'],_0x168860=_0x5a7644['document']['selection'];if(_0x168860['isCollapsed']){const _0x3e00c3=this['_findAncestorTextBlock'](_0x168860['getFirstPosition']()['parent']);return _0x3e00c3?[_0x5a7644['createRangeIn'](_0x3e00c3)]:[];}return _0x168860['getRanges']();}['_modifyContent'](_0x4e6ead,_0x438283){for(const _0x48e238 of this['_getElementsAllowingText'](_0x4e6ead)){const _0x174d40=this['_getElementTextContent'](_0x48e238),_0x55e83e=this['_transformCallback'](_0x174d40);for(const _0x1c3d23 of this['_getTextNodesRangeLimited'](_0x48e238,_0x4e6ead))this['_replaceTextNodeData'](_0x1c3d23,_0x55e83e,_0x438283);}}['_findAncestorTextBlock'](_0x153118){const _0x2179f7=this['editor']['model']['schema'];if(_0x153118['is']('element')&&_0x2179f7['checkChild'](_0x153118,'$text'))return _0x153118;const _0x82b2bc=_0x153118['parent'];return!_0x82b2bc||_0x2179f7['isLimit'](_0x153118)?null:this['_findAncestorTextBlock'](_0x82b2bc);}*['_getElementsAllowingText'](_0xd5feb8){const _0x222968=new Set();for(const {item:_0x26a00c}of _0xd5feb8['getWalker']()){const _0xe75e11=this['_findAncestorTextBlock'](_0x26a00c);_0xe75e11&&!_0x222968['has'](_0xe75e11)&&(_0x222968['add'](_0xe75e11),yield _0xe75e11);}}['_getElementTextContent'](_0x30ed70){return Array['from'](_0x30ed70['getChildren']())['reduce']((_0x41d7c8,_0x10f564)=>_0x41d7c8+(_0x10f564['is']('$text')?_0x10f564['data']:'\x20'),'');}*['_getTextNodesRangeLimited'](_0x1261ab,_0x5e7aa3){const _0x586c66=_0x5e7aa3['getIntersection'](this['editor']['model']['createRangeIn'](_0x1261ab));if(_0x586c66){for(const _0x2f5b91 of _0x586c66['getItems']())_0x2f5b91['is']('$textProxy')&&_0x2f5b91['parent']==_0x1261ab&&(yield _0x2f5b91);}}['_replaceTextNodeData'](_0x2851f9,_0x54bdd3,_0x3d064f){const _0x320c6a=_0x54bdd3['substring'](_0x2851f9['startOffset'],_0x2851f9['endOffset']);if(_0x320c6a===_0x2851f9['data'])return;const _0x32ed9a=_0x2851f9['getAttributes']();this['editor']['model']['insertContent'](_0x3d064f['createText'](_0x320c6a,_0x32ed9a),_0x3d064f['createSelection'](_0x3d064f['createRangeOn'](_0x2851f9)));}};function w(_0x354676,_0x4108df,..._0x3f97a2){const t=_0x354676['t'];switch(_0x4108df){case'Case\x20change':return t('Case\x20change');case'UPPERCASE':return t('UPPERCASE');case'lowercase':return t('lowercase');case'Title\x20Case':return t('Title\x20Case');case'Change\x20text\x20case':return t('Change\x20text\x20case');case'Changed\x20case\x20to\x20%0':return t('Changed\x20case\x20to\x20%0',..._0x3f97a2);default:return _0x4108df;}}var g=class extends _0x2cd011{['_currentCommandIndex']=0x0;static get['pluginName'](){return'CaseChangeEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const _0x1ec372=this['editor'],_0x338585=_0x1ec372['locale']['contentLanguage'],_0x55ff9d=function(_0x58ae72=[]){return'function'==typeof _0x58ae72?_0x58ae72:(_0x4c758c,{wordIndex:_0x464d23})=>_0x464d23>0x0&&_0x58ae72['includes'](_0x4c758c);}(_0x1ec372['config']['get']('caseChange.titleCase.excludeWords')),_0x259c82={'changeCaseUpper':new h(_0x1ec372,_0x4ab416=>_0x4ab416['toLocaleUpperCase'](_0x338585)),'changeCaseLower':new h(_0x1ec372,_0x50a119=>_0x50a119['toLocaleLowerCase'](_0x338585)),'changeCaseTitle':new h(_0x1ec372,_0x265174=>function(_0x285e4d,_0xe89c8f,_0x2010aa){return function(_0x5dd44c,_0x5c89b6){let _0x320337='',_0x1600bd=0x0,_0x5741e1=0x0;for(const _0x39efbb of _0x5dd44c['matchAll'](/ +/g)){const _0x543abd=_0x39efbb['index'],_0x3124d6=_0x5dd44c['substring'](_0x1600bd,_0x543abd);_0x3124d6['length']&&(_0x320337+=_0x5c89b6(_0x3124d6,_0x1600bd,_0x5741e1++)),_0x320337+=_0x39efbb[0x0],_0x1600bd=_0x543abd+_0x39efbb[0x0]['length'];}const _0x1ea716=_0x5dd44c['substring'](_0x1600bd);return _0x1ea716['length']&&(_0x320337+=_0x5c89b6(_0x1ea716,_0x1600bd,_0x5741e1)),_0x320337;}(_0x285e4d,(_0x2f0841,_0x1b4423,_0x281d85)=>{const _0x3bd025=_0x2f0841['toLocaleLowerCase'](_0x2010aa);return _0xe89c8f(_0x3bd025,{'charOffset':_0x1b4423,'wordIndex':_0x281d85,'blockText':_0x285e4d})?_0x3bd025:_0x3bd025['replace'](/(?:^|[^\p{L}\d'])\p{L}/gu,_0x2c8adb=>_0x2c8adb['toLocaleUpperCase'](_0x2010aa));});}(_0x265174,_0x55ff9d,_0x338585))};for(const [_0xf48699,_0x427d08]of Object['entries'](_0x259c82))_0x1ec372['commands']['add'](_0xf48699,_0x427d08),_0x427d08['on']('execute',()=>{this['_announceCaseChangeOperation'](_0xf48699);});this['listenTo'](_0x1ec372['editing']['view']['document'],'selectionChange',()=>{this['_currentCommandIndex']=0x0;}),_0x1ec372['keystrokes']['set']('shift+f3',(_0xbc8696,_0x25da65)=>{const _0x355713=m(this['editor']['locale']),_0x39ff16=_0x355713[this['_currentCommandIndex']%_0x355713['length']]['commandName'];_0x1ec372['execute'](_0x39ff16),this['_currentCommandIndex']++,_0x25da65();});}['afterInit'](){!async function(_0x1db585){const _0x41ef05='EMDS3dsLoJY0nbe9cmlCrXyaZ8zpPqN6jxThf7gwBi2KFOVUWRAG14HQIkut5v',_0x8649fc=0x78fc0,_0x1e0081=window['Date']['now'](),_0x11457a=_0x1db585['editor'],_0x598fc6=new window['Promise'](_0x2a8612=>{_0x11457a['once']('ready',_0x2a8612);}),_0x1a5e9b={'kty':'EC','use':'sig','crv':'P-256','x':'iCjOCvDFI6lQHHT18jVwRfkfHQ2a_MymT35LQVoFSAI','y':'kXIyJ4evtCEFRmxKSUpK9fDW459vXOvVrhf6uQAeOio','alg':'ES256'},_0xd65078=_0x11457a['config']['get']('licenseKey');async function _0x304f3e(){let _0xe7e62a,_0x2d0561=null,_0xa85a6f=null;try{return'GPL'==_0xd65078?'NotAllowed':(_0xe7e62a=_0xf711c8(),_0xe7e62a?(_0xe7e62a['usageEndpoint']&&(_0xa85a6f=_0x1384ab(_0xe7e62a['usageEndpoint'],_0xe7e62a['jti'])),await _0x685f2d()?_0x5e6e7f()?_0x325940()?'Expired':_0x3f1702()?('evaluation'==_0xe7e62a['licenseType']&&(_0x2d0561=_0x1f0add('EvaluationLimit')),await _0x4a1c05()):'DomainLimit':'NotAllowed':'Invalid'):'Invalid');}catch{return'Invalid';}function _0x325940(){const _0x560dd8=['evaluation','trial']['includes'](_0xe7e62a['licenseType'])?_0x1e0081/0x3e8:0xe10*_0x8649fc;return _0xe7e62a['exp']<_0x560dd8;}function _0x5e6e7f(){const _0x30a652=_0xe7e62a['features'];return!!_0x30a652&&(!!_0x30a652['includes']('*')||(!!_0x30a652['includes']('CC')||!!_0x30a652['includes']('PP')));}function _0x3f1702(){const _0x3cb3d6=_0xe7e62a['licensedHosts'];if(!_0x3cb3d6||0x0==_0x3cb3d6['length'])return!0x0;const {hostname:_0x3ce11f}=new URL(window['location']['href']);if(_0x3cb3d6['includes'](_0x3ce11f))return!0x0;const _0xc0a70f=_0x3ce11f['split']('.');return _0x3cb3d6['filter'](_0x197b9c=>_0x197b9c['includes']('*'))['map'](_0x77407a=>_0x77407a['split']('.'))['filter'](_0x4c5428=>_0x4c5428['length']<=_0xc0a70f['length'])['map'](_0x5e7b42=>Array(_0xc0a70f['length']-_0x5e7b42['length'])['fill']('*'===_0x5e7b42[0x0]?'*':'')['concat'](_0x5e7b42))['some'](_0x3f95f7=>_0xc0a70f['every']((_0x2fb2f7,_0x5af52a)=>_0x3f95f7[_0x5af52a]===_0x2fb2f7||'*'===_0x3f95f7[_0x5af52a]));}function _0x4a1c05(){return _0x2d0561&&_0xa85a6f?new window['Promise']((_0x47cca5,_0x24324e)=>{_0x2d0561['then'](_0x47cca5,_0x24324e),_0xa85a6f['then'](_0x4a4fa9=>{'Valid'!=_0x4a4fa9&&_0x47cca5(_0x4a4fa9);},_0x24324e);}):_0x2d0561||_0xa85a6f||'Valid';}}function _0x1384ab(_0x19e235,_0x43eb05){return new window['Promise'](_0x58b02d=>{if(_0x18ae97())return _0x58b02d('Valid');_0x50da4b(),_0x11457a['decorate']('_sendUsageRequest');let _0x914abf=!0x1;const _0x539c52=_0x1cc2bb();function _0x32e05d(_0x295ff2){return!!_0x295ff2&&('object'==typeof _0x295ff2||'function'==typeof _0x295ff2)&&'function'==typeof _0x295ff2['then']&&'function'==typeof _0x295ff2['catch'];}function _0x361448(_0x5816d7){_0x538ca9(_0x5816d7)['then'](_0x11b11f=>_0x11b11f&&'ok'==_0x11b11f['status']?_0x2f45b0(_0x210c60(_0x539c52+_0x43eb05))!=_0x11b11f['verification']?'UsageLimit':'Valid':'UsageLimit')['then'](_0x347a05=>(_0x160d83(),_0x347a05),()=>{const _0x47c52d=_0x193814();return null==_0x47c52d?(_0x160d83(),'Valid'):_0x1e0081-_0x47c52d>0x240c8400?'UsageLimit':'Valid';})['then'](_0x58b02d)['catch'](()=>{_0x58b02d('UsageLimit');});const _0xd44a41=0x36ee80;function _0x160d83(){const _0x18f2f5='llct-'+_0x2f45b0(_0x210c60(_0x19e235)),_0xfd9f61=_0x343d73(_0x2f45b0(window['Math']['ceil'](_0x1e0081/_0xd44a41)));window['localStorage']['setItem'](_0x18f2f5,_0xfd9f61);}function _0x193814(){const _0x514c35='llct-'+_0x2f45b0(_0x210c60(_0x19e235)),_0x5505ad=window['localStorage']['getItem'](_0x514c35);return _0x5505ad?window['parseInt'](_0x343d73(_0x5505ad),0x10)*_0xd44a41:null;}function _0x538ca9(_0x4197c9){return new window['Promise']((_0x29c0e3,_0x545941)=>{_0x4197c9['then'](_0x29c0e3,_0x545941),window['setTimeout'](_0x545941,0x1d4c0);});}}_0x11457a['on']('_sendUsageRequest',(_0x99353e,_0x9a9697)=>{if(_0x9a9697[0x0]!=_0x19e235)return _0x58b02d('UsageLimit');_0x9a9697[0x1]={..._0x9a9697[0x1],'requestId':_0x539c52};},{'priority':'high'}),_0x11457a['on']('_sendUsageRequest',_0x13364e=>{_0x32e05d(_0x13364e['return'])&&(_0x914abf=!0x0,_0x361448(_0x13364e['return']));},{'priority':'low'}),_0x598fc6['then'](()=>{_0x914abf||_0x58b02d('UsageLimit');});});function _0x18ae97(){return'auto'==_0x11457a['editing']['view']['_overlayModeHint'];}function _0x50da4b(){_0x11457a['editing']['view']['_overlayModeHint']='auto';}}function _0x1f0add(_0x24b0a7){const _0xaeb54=[new window['Promise'](_0x55fd8e=>setTimeout(_0x55fd8e,0x93ecc)),_0x598fc6['then'](()=>new window['Promise'](_0xd8619=>{let _0xf033fd=0x0;_0x11457a['model']['on']('applyOperation',(_0x7da91e,_0x140bc5)=>{_0x140bc5[0x0]['isDocumentOperation']&&_0xf033fd++,0x5e8==_0xf033fd&&(_0xd8619(),_0x7da91e['off']());});}))];return window['Promise']['race'](_0xaeb54)['then'](()=>_0x24b0a7);}async function _0x2fa2e5(){await _0x598fc6,_0x11457a['model']['change']=_0x2996ad,_0x11457a['model']['enqueueChange']=_0x2996ad,_0x11457a['enableReadOnlyMode']('model');}function _0x8d65af(_0x28e266){const _0x553194=_0x39b9bd();_0x11457a[_0x553194]='caseChangeLicenseKey'+_0x28e266,'Valid'!=_0x28e266&&_0x2fa2e5();}function _0x39b9bd(){const _0x2cd5e5=window['String'](window['performance']['now']())['replace']('.','');let _0x5316fc='E';for(let _0x306324=0x0;_0x306324<_0x2cd5e5['length'];_0x306324+=0x2){let _0x53cfd4=window['parseInt'](_0x2cd5e5['substring'](_0x306324,_0x306324+0x2));_0x53cfd4>=0x3e&&(_0x53cfd4-=0x3e),_0x5316fc+=_0x41ef05[_0x53cfd4];}return _0x5316fc;}function _0xf711c8(){const _0x3cf85a=_0xd65078['split']('.');if(0x3!=_0x3cf85a['length'])return null;return _0x3f5f42(_0x3cf85a[0x1]);function _0x3f5f42(_0x25ba14){const _0x40e0b3=_0x585ed4(_0x25ba14);return _0x40e0b3&&_0x30d73b()?_0x40e0b3:null;function _0x30d73b(){const _0x315c9=_0x40e0b3['jti'],_0x38665f=window['parseInt'](_0x315c9['substring'](_0x315c9['length']-0x8),0x10),_0x2df5c6={..._0x40e0b3,'jti':_0x315c9['substring'](0x0,_0x315c9['length']-0x8)};return delete _0x2df5c6['vc'],_0x210c60(_0x2df5c6)==_0x38665f;}}}async function _0x685f2d(){let _0x1b0430=!0x0;try{const [_0x3735bf,_0x6e3307,_0x3874b2]=_0xd65078['split']('.');return _0x348770(_0x3735bf),await _0x2dd4e9(_0x3735bf,_0x6e3307,_0x3874b2),_0x1b0430;}catch{return!0x1;}function _0x348770(_0x3b8d67){const _0x487d7f=_0x585ed4(_0x3b8d67);_0x487d7f&&'ES256'==_0x487d7f['alg']||(_0x1b0430=!0x1);}async function _0x2dd4e9(_0x5393a2,_0xc0b817,_0x308a15){const _0x24cb6a=window['Uint8Array']['from'](_0x1179b5(_0x308a15),_0x245b35=>_0x245b35['charCodeAt'](0x0)),_0xcb81b2=new window['TextEncoder']()['encode'](_0x5393a2+'.'+_0xc0b817),_0xc12ad6=window['crypto']['subtle'];if(!_0xc12ad6)return;const _0x42ed12=await _0xc12ad6['importKey']('jwk',_0x1a5e9b,{'name':'ECDSA','namedCurve':'P-256'},!0x1,['verify']);await _0xc12ad6['verify']({'name':'ECDSA','hash':{'name':'SHA-256'}},_0x42ed12,_0x24cb6a,_0xcb81b2)||(_0x1b0430=!0x1);}}function _0x585ed4(_0x3e0c98){return _0x3e0c98['startsWith']('ey')?JSON['parse'](_0x1179b5(_0x3e0c98)):null;}function _0x1179b5(_0x2bd410){return window['atob'](_0x2bd410['replace'](/-/g,'+')['replace'](/_/g,'/'));}function _0x210c60(_0x1e044f){let _0x12b06e=0x1505;function _0x1ad9dd(_0x503d13){for(let _0x4fa5b2=0x0;_0x4fa5b2<_0x503d13['length'];_0x4fa5b2++){const _0x444838=_0x503d13['charCodeAt'](_0x4fa5b2);_0x12b06e=(_0x12b06e<<0x5)+_0x12b06e+_0x444838,_0x12b06e&=_0x12b06e;}}function _0x58faeb(_0x1a8637){Array['isArray'](_0x1a8637)?_0x1a8637['forEach'](_0x58faeb):_0x1a8637&&'object'==typeof _0x1a8637?Object['entries'](_0x1a8637)['sort']()['forEach'](([_0x7d982c,_0x291292])=>{_0x1ad9dd(_0x7d982c),_0x58faeb(_0x291292);}):_0x1ad9dd(window['String'](_0x1a8637));}return _0x58faeb(_0x1e044f),_0x12b06e>>>0x0;}function _0x2f45b0(_0x349bae){return _0x349bae['toString'](0x10)['padStart'](0x8,'0');}function _0x343d73(_0x171f3b){return _0x171f3b['split']('')['reverse']()['join']('');}function _0x2996ad(){}_0x8d65af(await _0x304f3e());}(this);}['_announceCaseChangeOperation'](_0x9516d7){const {ui:_0x483d62,locale:_0x3dae47}=this['editor'],_0x40f952=m(_0x3dae47)['find'](_0x1c49b7=>_0x1c49b7['commandName']===_0x9516d7)['label']['toLowerCase']();_0x483d62['ariaLiveAnnouncer']['announce'](w(_0x3dae47,'Changed\x20case\x20to\x20%0',_0x40f952));}};function m(_0x2f7783){return[{'label':w(_0x2f7783,'UPPERCASE'),'commandName':'changeCaseUpper'},{'label':w(_0x2f7783,'lowercase'),'commandName':'changeCaseLower'},{'label':w(_0x2f7783,'Title\x20Case'),'commandName':'changeCaseTitle'}];}var C=class extends _0x2cd011{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CaseChangeUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const _0x3a0632=this['editor'];this['_registerComponents'](),_0x3a0632['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':w(_0x3a0632['locale'],'Change\x20text\x20case'),'keystroke':'Shift+f3','mayRequireFn':!0x0}]}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4e1872=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x113984;for(const _0x52386b in _0x4e1872){const _0x46041f=_0x52386b,_0xf00559=_0x4e1872[_0x46041f];if('caseChangeLicenseKeyValid'==_0xf00559||'caseChangeLicenseKeyInvalid'==_0xf00559||'caseChangeLicenseKeyExpired'==_0xf00559||'caseChangeLicenseKeyDomainLimit'==_0xf00559||'caseChangeLicenseKeyNotAllowed'==_0xf00559||'caseChangeLicenseKeyEvaluationLimit'==_0xf00559||'caseChangeLicenseKeyUsageLimit'==_0xf00559){delete _0x4e1872[_0x46041f],_0x113984=_0xf00559,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'caseChangeLicenseKeyInvalid'==_0x113984&&_0x4e1872['_showLicenseError']('invalid'),'caseChangeLicenseKeyExpired'==_0x113984&&_0x4e1872['_showLicenseError']('expired'),'caseChangeLicenseKeyDomainLimit'==_0x113984&&_0x4e1872['_showLicenseError']('domainLimit'),'caseChangeLicenseKeyNotAllowed'==_0x113984&&_0x4e1872['_showLicenseError']('featureNotAllowed','CaseChange'),'caseChangeLicenseKeyEvaluationLimit'==_0x113984&&_0x4e1872['_showLicenseError']('evaluationLimit'),'caseChangeLicenseKeyUsageLimit'==_0x113984&&_0x4e1872['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_registerComponents'](){const _0x39fa71=this['editor'],{itemDefinitions:_0x1f50a3,commands:_0x3fc68f}=this['_getListItemDefinitionsAndCommands']();_0x39fa71['ui']['componentFactory']['add']('caseChange',()=>this['_createDropdownView'](_0x1f50a3,_0x3fc68f)),_0x39fa71['ui']['componentFactory']['add']('menuBar:caseChange',()=>this['_createMenuBarMenuView'](_0x1f50a3,_0x3fc68f));}['_createMenuBarMenuView'](_0x5f3bf8,_0xe1cc70){const _0x5801e1=this['editor'],_0x1fb527=_0x5801e1['locale'],_0x473cbe=new _0x1533e(_0x1fb527),_0xd795cd=new _0x112b0c(_0x1fb527);_0xd795cd['set']({'ariaLabel':w(_0x1fb527,'Case\x20change'),'role':'menu'}),this['_setButtonProperties'](_0x473cbe['buttonView']),_0x473cbe['bind']('isEnabled')['toMany'](_0xe1cc70,'isEnabled',(..._0x6e58bc)=>_0x6e58bc['some'](_0x354a64=>_0x354a64));for(const _0xa8fc1e of _0x5f3bf8){const _0x241344=new _0x1ac65c(_0x1fb527,_0x473cbe),_0x173bec=new _0x24baec(_0x1fb527);_0x173bec['delegate']('execute')['to'](_0x473cbe),_0x173bec['bind'](...Object['keys'](_0xa8fc1e['model']))['to'](_0xa8fc1e['model']),_0x173bec['on']('execute',()=>{_0x5801e1['execute'](_0xa8fc1e['model']['commandName']),_0x5801e1['editing']['view']['focus']();}),_0x241344['children']['add'](_0x173bec),_0xd795cd['items']['add'](_0x241344);}return _0x473cbe['panelView']['children']['add'](_0xd795cd),_0x473cbe;}['_createDropdownView'](_0x330507,_0x295813){const _0x4eeeca=this['editor'],_0x44f221=_0xfcfb2f(_0x4eeeca['locale']);return this['_setButtonProperties'](_0x44f221['buttonView']),_0x44f221['buttonView']['set']({'tooltip':!0x0}),_0x44f221['extendTemplate']({'attributes':{'class':['ck-case-change-dropdown']}}),_0x3aa6c0(_0x44f221,_0x330507,{'ariaLabel':w(_0x4eeeca['locale'],'Case\x20change'),'role':'menu'}),_0x44f221['bind']('isEnabled')['toMany'](_0x295813,'isEnabled',(..._0x221e85)=>_0x221e85['some'](_0x184c42=>_0x184c42)),this['listenTo'](_0x44f221,'execute',_0x226d2c=>{_0x4eeeca['execute'](_0x226d2c['source']['commandName']),_0x4eeeca['editing']['view']['focus']();}),_0x44f221;}['_setButtonProperties'](_0x54e242){const _0x4107b7=this['editor'];_0x54e242['set']({'label':w(_0x4107b7['locale'],'Case\x20change'),'icon':_0x5d143e,'keystroke':'Shift+F3'});}['_getListItemDefinitionsAndCommands'](){const _0x1f19a1=new _0x3f3e91(),_0x216430=[];for(const _0x251088 of m(this['editor']['locale'])){const _0x3e4975=this['editor']['commands']['get'](_0x251088['commandName']),_0x5268c3=new _0x291158({'commandName':_0x251088['commandName'],'label':_0x251088['label'],'role':'menuitemradio','withText':!0x0});_0x5268c3['bind']('isEnabled')['to'](_0x3e4975,'isEnabled'),_0x1f19a1['add']({'type':'button','model':_0x5268c3}),_0x216430['push'](_0x3e4975);}return{'itemDefinitions':_0x1f19a1,'commands':_0x216430};}},y=class extends _0x2cd011{static get['requires'](){return[g,C];}static get['pluginName'](){return'CaseChange';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}};export{y as CaseChange,h as CaseChangeCommand,g as CaseChangeEditing,C as CaseChangeUI};