@ckeditor/ckeditor5-ai
Version:
AI Assistant feature for CKEditor 5.
23 lines • 4.17 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 _0x46c07=_0x4038;(function(_0x4f48f1,_0x3743a1){const _0x5255d1=_0x4038,_0x4d75b6=_0x4f48f1();while(!![]){try{const _0x5b0a7f=parseInt(_0x5255d1(0x13f))/0x1*(parseInt(_0x5255d1(0x155))/0x2)+-parseInt(_0x5255d1(0x144))/0x3+-parseInt(_0x5255d1(0x14b))/0x4*(-parseInt(_0x5255d1(0x14d))/0x5)+-parseInt(_0x5255d1(0x151))/0x6+parseInt(_0x5255d1(0x139))/0x7*(-parseInt(_0x5255d1(0x154))/0x8)+parseInt(_0x5255d1(0x138))/0x9+parseInt(_0x5255d1(0x152))/0xa*(parseInt(_0x5255d1(0x156))/0xb);if(_0x5b0a7f===_0x3743a1)break;else _0x4d75b6['push'](_0x4d75b6['shift']());}catch(_0x3aa69a){_0x4d75b6['push'](_0x4d75b6['shift']());}}}(_0x4788,0x525a0));function _0x4038(_0x35d02b,_0x3f8cca){const _0x4788a9=_0x4788();return _0x4038=function(_0x40382a,_0x16c4af){_0x40382a=_0x40382a-0x135;let _0x8b4b92=_0x4788a9[_0x40382a];return _0x8b4b92;},_0x4038(_0x35d02b,_0x3f8cca);}import{ToolbarView as _0x92de80,ButtonView as _0x35e576}from'ckeditor5/src/ui.js';import{getTranslation as _0x1725ad}from'../../utils/common-translations.js';function _0x4788(){const _0x2f223d=['items','mainAction','label','683388SUBxbI','_CONTENT','5RbOZfe','bindTemplate','tryAgainButton','ck-hidden','2530266eCMMzF','1923820ZyfjqR','insertButton','8fhIogk','55444ARPYkM','22mkpPsX','replace','Try\x20again','stopButton','extendTemplate','isVisible','Stop','REPLACE','210879ATjYOQ','2016273PucOms','set','ck-ai-form__toolbar','replaceButton','AI_','addMany','22aeCACY','toUpperCase','insert','Insert\x20below','ck-button-action','425592sALwrC','_createButton','bind','locale'];_0x4788=function(){return _0x2f223d;};return _0x4788();}export const AIFormToolbarViewMainActionLabel={'REPLACE':_0x46c07(0x157),'INSERT':_0x46c07(0x141)};export default class at extends _0x92de80{constructor(_0xb43710){const _0x251681=_0x46c07;super(_0xb43710),this[_0x251681(0x13a)](_0x251681(0x135),!0x1),this[_0x251681(0x13a)](_0x251681(0x149),AIFormToolbarViewMainActionLabel[_0x251681(0x137)]),this[_0x251681(0x13c)]=this[_0x251681(0x145)]('',_0x251681(0x143)),this[_0x251681(0x13c)][_0x251681(0x146)](_0x251681(0x14a))['to'](this,_0x251681(0x149),_0x5fa7f8=>_0x1725ad(_0xb43710,_0x251681(0x13d)+_0x5fa7f8[_0x251681(0x140)]()+_0x251681(0x14c))),this[_0x251681(0x153)]=this[_0x251681(0x145)](_0x1725ad(_0xb43710,_0x251681(0x142))),this[_0x251681(0x14f)]=this[_0x251681(0x145)](_0x1725ad(_0xb43710,_0x251681(0x158))),this[_0x251681(0x159)]=this[_0x251681(0x145)](_0x1725ad(_0xb43710,_0x251681(0x136)));const _0x2aeb17=this[_0x251681(0x14e)];this[_0x251681(0x15a)]({'attributes':{'class':[_0x251681(0x13b),_0x2aeb17['if'](_0x251681(0x135),_0x251681(0x150),_0x1283b2=>!_0x1283b2)]}}),this[_0x251681(0x148)][_0x251681(0x13e)]([this[_0x251681(0x13c)],this[_0x251681(0x153)],this[_0x251681(0x14f)],this[_0x251681(0x159)]]);}[_0x46c07(0x145)](_0x59278a,_0x4a3ebb){const _0x1d0baf=_0x46c07,_0x5ccb48=new _0x35e576(this[_0x1d0baf(0x147)]);return _0x5ccb48[_0x1d0baf(0x13a)]({'label':_0x59278a,'class':_0x4a3ebb||'','isVisible':!0x0,'withText':!0x0}),_0x5ccb48;}}