@ckeditor/ckeditor5-ai
Version:
AI features for CKEditor 5.
23 lines • 6.34 kB
JavaScript
/*
* Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
*
*
*
*
* +---------------------------------------------------------------------------------+
* | |
* | Hello stranger! |
* | |
* | |
* | What you're currently looking at is the source code of a legally protected, |
* | proprietary software. Any attempts to deobfuscate / disassemble this code |
* | are forbidden and will result in legal consequences. |
* | |
* | |
* +---------------------------------------------------------------------------------+
*
*
*
*
*/
const _0x4d3fd6=_0x3fb6;(function(_0x4e6f89,_0x671930){const _0x6c62f5=_0x3fb6,_0x4303dd=_0x4e6f89();while(!![]){try{const _0x29c581=parseInt(_0x6c62f5(0x12c))/0x1+parseInt(_0x6c62f5(0x14e))/0x2*(parseInt(_0x6c62f5(0x142))/0x3)+parseInt(_0x6c62f5(0x141))/0x4*(parseInt(_0x6c62f5(0x13e))/0x5)+parseInt(_0x6c62f5(0x150))/0x6+parseInt(_0x6c62f5(0x13a))/0x7+parseInt(_0x6c62f5(0x146))/0x8+parseInt(_0x6c62f5(0x129))/0x9*(-parseInt(_0x6c62f5(0x138))/0xa);if(_0x29c581===_0x671930)break;else _0x4303dd['push'](_0x4303dd['shift']());}catch(_0x40c2e4){_0x4303dd['push'](_0x4303dd['shift']());}}}(_0x5586,0x84c10));function _0x5586(){const _0x1948d9=['set','loadSourceResources','2920VbLNmO','length','_resourcesListView','_searchInputVisibleFrom','loadResources','locale','render','extendTemplate','4cDGiVI','_skeletonLoader','1067784UpSzxI','isLoading','ck-hidden','setResources','_searchView','aiChatResources','searchInputVisibleFrom','delegate','_searchSection','setTemplate','ck\x20ck-search','1482039UKJYHw','add','source','520374PrnHUE','bindTemplate','_source','fire','_createResourcesListView','_latestLoadResourcesUid','updateResourceState','has','search','_createSearchSection','highlightText','getQuery','150LDTJFi','addResourceToContext','6626830zOntem','ck-ai-chat-resources','useDefaultFiltering','div','2865550hTqghT','children','_createSkeletonView','4filEFT','1192983HEuGCL','_createSearchView'];_0x5586=function(){return _0x1948d9;};return _0x5586();}import{View as _0x203b9e,ViewCollection as _0x1e405f}from'ckeditor5/src/ui.js';import{uid as _0x1b5b9f}from'ckeditor5/src/utils.js';function _0x3fb6(_0x49ec0b,_0x2fccf8){const _0x558628=_0x5586();return _0x3fb6=function(_0x3fb6b4,_0x252907){_0x3fb6b4=_0x3fb6b4-0x125;let _0x1adcba=_0x558628[_0x3fb6b4];return _0x1adcba;},_0x3fb6(_0x49ec0b,_0x2fccf8);}import{AIChatContextResourcesListView as _0x41b213}from'./aichatcontextresourceslistview.js';import{AIChatContextResourcesSearchInputView as _0x9dc211}from'./aichatresourcessearchinputview.js';import{AISkeletonView as _0x3fbf92,SKELETON_DEFINITIONS as _0x29d84c}from'../../../../aicore/ui/aiskeleton.js';export class AIChatContextResourcesView extends _0x203b9e{[_0x4d3fd6(0x154)];[_0x4d3fd6(0x126)];[_0x4d3fd6(0x149)];[_0x4d3fd6(0x148)];[_0x4d3fd6(0x14f)];[_0x4d3fd6(0x12e)];[_0x4d3fd6(0x13f)];[_0x4d3fd6(0x131)]=null;constructor(_0x22b92c,_0x50ff48){const _0x4bdc0a=_0x4d3fd6;super(_0x22b92c),this[_0x4bdc0a(0x12e)]=_0x50ff48[_0x4bdc0a(0x12b)],this[_0x4bdc0a(0x149)]=_0x50ff48[_0x4bdc0a(0x156)]??0x7,this[_0x4bdc0a(0x144)](_0x4bdc0a(0x151),!0x0),this[_0x4bdc0a(0x154)]=this[_0x4bdc0a(0x143)](),this[_0x4bdc0a(0x126)]=this[_0x4bdc0a(0x135)](),this[_0x4bdc0a(0x148)]=this[_0x4bdc0a(0x130)](),this[_0x4bdc0a(0x14f)]=this[_0x4bdc0a(0x140)](),this[_0x4bdc0a(0x13f)]=new _0x1e405f([this[_0x4bdc0a(0x14f)],this[_0x4bdc0a(0x148)]]),this[_0x4bdc0a(0x127)]({'tag':_0x4bdc0a(0x13d),'attributes':{'class':_0x4bdc0a(0x13b)},'children':this[_0x4bdc0a(0x13f)]});}[_0x4d3fd6(0x143)](){const _0x36588b=_0x4d3fd6;return new _0x9dc211(this[_0x36588b(0x14b)]);}[_0x4d3fd6(0x135)](){const _0x2be483=_0x4d3fd6,_0x200d05=new _0x203b9e(this[_0x2be483(0x14b)]);return _0x200d05[_0x2be483(0x127)]({'tag':_0x2be483(0x13d),'attributes':{'class':_0x2be483(0x128)},'children':[this[_0x2be483(0x154)]]}),this[_0x2be483(0x154)]['on'](_0x2be483(0x134),(_0xe4fa82,_0x575807)=>{const _0x4154eb=_0x2be483;this[_0x4154eb(0x14a)](_0x575807),this[_0x4154eb(0x12e)][_0x4154eb(0x13c)]&&this[_0x4154eb(0x148)][_0x4154eb(0x136)](_0x575807);}),_0x200d05;}[_0x4d3fd6(0x130)](){const _0x472720=_0x4d3fd6,_0x353309=new _0x41b213(this[_0x472720(0x14b)],this[_0x472720(0x12e)]);return _0x353309[_0x472720(0x125)](_0x472720(0x139))['to'](this),_0x353309[_0x472720(0x14d)]({'attributes':{'class':this[_0x472720(0x12d)]['if'](_0x472720(0x151),_0x472720(0x152))}}),_0x353309;}[_0x4d3fd6(0x140)](){const _0x44af5e=_0x4d3fd6,_0x31e388=new _0x3fbf92(this[_0x44af5e(0x14b)],_0x29d84c[_0x44af5e(0x155)]);return _0x31e388[_0x44af5e(0x14d)]({'attributes':{'class':[this[_0x44af5e(0x12d)]['if'](_0x44af5e(0x151),_0x44af5e(0x152),_0x5422c2=>!_0x5422c2)]}}),_0x31e388;}[_0x4d3fd6(0x14c)](){const _0x37a6f0=_0x4d3fd6;super[_0x37a6f0(0x14c)](),this[_0x37a6f0(0x14a)]('');}[_0x4d3fd6(0x14a)](_0x14a0b9){const _0x1df013=_0x4d3fd6,_0x4c9ef8=_0x1b5b9f();this[_0x1df013(0x131)]=_0x4c9ef8,this[_0x1df013(0x12f)](_0x1df013(0x145),{'sourceId':this[_0x1df013(0x12e)]['id'],'query':_0x14a0b9,'uid':_0x4c9ef8}),this[_0x1df013(0x151)]=!0x0;}[_0x4d3fd6(0x153)](_0x8ab31d,_0x12e68a){const _0x21f230=_0x4d3fd6;if(_0x12e68a&&_0x12e68a!==this[_0x21f230(0x131)])return;const _0x2f9fe=this[_0x21f230(0x12e)][_0x21f230(0x13c)]?this[_0x21f230(0x154)][_0x21f230(0x137)]():'';this[_0x21f230(0x148)][_0x21f230(0x153)](_0x8ab31d,_0x2f9fe),_0x8ab31d[_0x21f230(0x147)]>=this[_0x21f230(0x149)]&&!this[_0x21f230(0x13f)][_0x21f230(0x133)](this[_0x21f230(0x126)])&&this[_0x21f230(0x13f)][_0x21f230(0x12a)](this[_0x21f230(0x126)],0x0),requestAnimationFrame(()=>{const _0x2b165e=_0x21f230;this[_0x2b165e(0x151)]=!0x1;});}[_0x4d3fd6(0x132)](_0x4fcdd9,_0x2e71a7){const _0x2047ac=_0x4d3fd6;this[_0x2047ac(0x148)][_0x2047ac(0x132)](_0x4fcdd9,_0x2e71a7);}}