@ckeditor/ckeditor5-ai 0.0.0-nightly-20231214.0 → 0.0.0-nightly-20231216.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/ai.js +1 -1
- package/package.json +4 -3
- package/src/adapters/aiadapter.d.ts +2 -2
- package/src/adapters/aiadapter.js +1 -1
- package/src/adapters/aitextadapter.d.ts +2 -2
- package/src/adapters/aitextadapter.js +1 -1
- package/src/adapters/awstextadapter.d.ts +2 -2
- package/src/adapters/awstextadapter.js +1 -1
- package/src/adapters/openaitextadapter.d.ts +2 -2
- package/src/adapters/openaitextadapter.js +1 -1
- package/src/aiassistant.d.ts +4 -4
- package/src/aiassistant.js +1 -1
- package/src/aiassistantediting.d.ts +2 -2
- package/src/aiassistantediting.js +1 -1
- package/src/aiassistantui.d.ts +4 -4
- package/src/aiassistantui.js +1 -1
- package/src/aiconfig.d.ts +3 -3
- package/src/augmentation.d.ts +6 -6
- package/src/index.d.ts +6 -6
- package/src/index.js +1 -1
- package/src/ui/aiassistantcontroller.d.ts +6 -6
- package/src/ui/aiassistantcontroller.js +1 -1
- package/src/ui/dropdown/aicommandslistview.d.ts +1 -1
- package/src/ui/dropdown/aicommandslistview.js +1 -1
- package/src/ui/dropdown/buttonlabelwithhighlightview.d.ts +1 -1
- package/src/ui/dropdown/buttonlabelwithhighlightview.js +1 -1
- package/src/ui/dropdown/labelwithhighlightview.d.ts +1 -1
- package/src/ui/dropdown/labelwithhighlightview.js +1 -1
- package/src/ui/form/aiformcontentarea.d.ts +2 -2
- package/src/ui/form/aiformcontentarea.js +1 -1
- package/src/ui/form/aiformerrorview.d.ts +2 -2
- package/src/ui/form/aiformerrorview.js +1 -1
- package/src/ui/form/aiformpromptview.d.ts +2 -2
- package/src/ui/form/aiformpromptview.js +1 -1
- package/src/ui/form/aiformtoolbarview.d.ts +2 -2
- package/src/ui/form/aiformtoolbarview.js +1 -1
- package/src/ui/form/aiformview.d.ts +6 -6
- package/src/ui/form/aiformview.js +1 -1
- package/src/ui/form/aihistorylistitemview.d.ts +2 -2
- package/src/ui/form/aihistorylistitemview.js +1 -1
- package/src/ui/form/aihistorylistview.d.ts +2 -2
- package/src/ui/form/aihistorylistview.js +1 -1
- package/src/ui/form/prompthistory.d.ts +1 -1
- package/src/ui/form/prompthistory.js +1 -1
- package/src/ui/showaiassistantcommand.d.ts +1 -1
- package/src/ui/showaiassistantcommand.js +1 -1
- package/src/utils/common-translations.d.ts +1 -1
- package/src/utils/common-translations.js +1 -1
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module ai/ui/aiformcontentarea
|
|
7
7
|
*/
|
|
8
|
-
import { type Locale } from 'ckeditor5/src/utils';
|
|
9
|
-
import { View, ButtonView } from 'ckeditor5/src/ui';
|
|
8
|
+
import { type Locale } from 'ckeditor5/src/utils.js';
|
|
9
|
+
import { View, ButtonView } from 'ckeditor5/src/ui.js';
|
|
10
10
|
/**
|
|
11
11
|
* A class representing the text area view of the AI assistant.
|
|
12
12
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x3bf0=['ck-ai-form__copy-button-wrapper','ck-ai-form__content-area--processing','getSelection','position','querySelector','mousedown','ck-content','_copyHTMLToClipboard','listenTo','ck-ai-form__copy-button','icon','_createLoader','absolute','isEnabled','innerHTML','change:isProcessing','createElement','_createCopyButton','execCommand','body','clipboard','text/plain','value','lastElementChild','addRange','div','isProcessing','element','isVisible','ck-ai-form__loader','execute','class','contentFieldView','style','AI\x20is\x20writing...','setTemplate','ck-ai-form__content-area-wrapper','setStartAfter','setContent','write','-9999px','createRange','copyButtonView','left','locale','\x20ck-ai-form__copy-button--copied','loaderView','.ck-ai-form__loader','scrollTo','ck-reset_all-excluded','check','<span>[</span>','scrollHeight','ck-ai-form__content-field','change:value','removeAllRanges','render','bind','appendChild','focus','smooth','ck-hidden','appendLoader','firstElementChild','remove','<span>]</span>'];(function(_0x3fc9a9,_0x3bf0b3){const _0x2802c4=function(_0x16ea2f){while(--_0x16ea2f){_0x3fc9a9['push'](_0x3fc9a9['shift']());}};_0x2802c4(++_0x3bf0b3);}(_0x3bf0,0x170));const _0x2802=function(_0x3fc9a9,_0x3bf0b3){_0x3fc9a9=_0x3fc9a9-0x0;let _0x2802c4=_0x3bf0[_0x3fc9a9];return _0x2802c4;};import{global as _0x3ec3ed}from'ckeditor5/src/utils.js';import{View as _0x354e49,ButtonView as _0x1ae60a,SpinnerView as _0x216b2f}from'ckeditor5/src/ui.js';import _0x2a0ca1 from'../../../theme/icons/copy.svg';import{getTranslation as _0xc5dde0}from'../../utils/common-translations.js';import{icons as _0x61ac51}from'ckeditor5/src/core.js';export default class Z extends _0x354e49{constructor(_0x21b738,_0x3746bf=''){super(_0x21b738),this['set']({'value':null,'isVisible':!0x1,'isProcessing':!0x1});const _0x319d34=this['bindTemplate'];this[_0x2802('0x3c')]=new ContentFieldView(_0x21b738,_0x3746bf),this[_0x2802('0x4')]=this['_createCopyButton'](),this[_0x2802('0x3f')]({'tag':_0x2802('0x35'),'attributes':{'class':['ck',_0x2802('0x40'),_0x319d34['if'](_0x2802('0x38'),_0x2802('0x17'),_0x25ca36=>!_0x25ca36)],'tabindex':'-1'},'children':[{'tag':'div','attributes':{'class':['ck','ck-ai-form__content-area',_0x319d34['if'](_0x2802('0x36'),_0x2802('0x1d'))]},'children':[this[_0x2802('0x3c')],{'tag':'div','attributes':{'class':['ck',_0x2802('0x1c')]},'children':[this['copyButtonView']]}]}]});}[_0x2802('0x12')](){super[_0x2802('0x12')](),this['value']&&this[_0x2802('0x3c')]['setContent'](this[_0x2802('0x32')]);let _0x515567=!0x1;this['on'](_0x2802('0x10'),(_0x2585d2,_0x50b9b9,_0x101a7d)=>{const _0x345b3e=!this['contentFieldView'][_0x2802('0x37')][_0x2802('0x20')](_0x2802('0x9'));this[_0x2802('0x3c')][_0x2802('0x0')](_0x101a7d),this[_0x2802('0x36')]&&_0x345b3e&&!_0x515567&&this[_0x2802('0x37')][_0x2802('0xa')]({'top':this['element'][_0x2802('0xe')],'behavior':_0x2802('0x16')});}),this['on'](_0x2802('0x2b'),(_0x1dc142,_0xa2a3bc,_0xd3868a)=>{_0x515567=!0x1,_0xd3868a?(this[_0x2802('0x32')]=null,this[_0x2802('0x3c')]['appendLoader']()):this['value']||this['contentFieldView'][_0x2802('0x0')]('');}),this[_0x2802('0x24')](this[_0x2802('0x37')],'wheel',()=>{_0x515567=!0x0;}),this[_0x2802('0x24')](this[_0x2802('0x37')],_0x2802('0x21'),()=>{_0x515567=!0x0;});}[_0x2802('0x15')](){this[_0x2802('0x37')]['focus']();}[_0x2802('0x2d')](){const _0x3a657a=this[_0x2802('0x6')],_0x335f2e=new _0x1ae60a(this[_0x2802('0x6')]),_0x440e46=_0x2802('0x25');return _0x335f2e['set']({'label':_0xc5dde0(_0x3a657a,'Copy'),'icon':_0x2a0ca1,'class':_0x440e46,'tooltip':!0x0}),_0x335f2e[_0x2802('0x13')](_0x2802('0x38'))['to'](this,_0x2802('0x32'),_0x357315=>!!_0x357315),_0x335f2e[_0x2802('0x13')](_0x2802('0x29'))['to'](this,_0x2802('0x36'),_0x5b29da=>!_0x5b29da),_0x335f2e['on'](_0x2802('0x3a'),()=>{this[_0x2802('0x23')](this['contentFieldView'][_0x2802('0x37')]),_0x335f2e[_0x2802('0x26')]=_0x61ac51[_0x2802('0xc')],_0x335f2e[_0x2802('0x3b')]=_0x440e46+_0x2802('0x7'),this[_0x2802('0x15')](),setTimeout(()=>{_0x335f2e[_0x2802('0x26')]=_0x2a0ca1,_0x335f2e[_0x2802('0x3b')]=_0x440e46;},0x3e8);}),_0x335f2e;}['_copyHTMLToClipboard'](_0x82b1d5){const {window:_0x25a2a4,document:_0x34413a}=_0x3ec3ed;if(_0x25a2a4['ClipboardItem']){const {Blob:_0x1e1be8,ClipboardItem:_0xb1dc63}=_0x25a2a4,_0x4aae1f=[new _0xb1dc63({'text/html':new _0x1e1be8([_0x82b1d5['innerHTML']],{'type':'text/html'}),'text/plain':new _0x1e1be8([_0x82b1d5['textContent']||''],{'type':_0x2802('0x31')})})];navigator[_0x2802('0x30')][_0x2802('0x1')](_0x4aae1f);}else{const _0x43dd07=_0x34413a[_0x2802('0x2c')]('div');_0x43dd07[_0x2802('0x3d')][_0x2802('0x1f')]=_0x2802('0x28'),_0x43dd07['style'][_0x2802('0x5')]=_0x2802('0x2'),_0x43dd07[_0x2802('0x2a')]=_0x2802('0xd')+_0x82b1d5['innerHTML']+_0x2802('0x1b'),_0x34413a[_0x2802('0x2f')][_0x2802('0x14')](_0x43dd07);const _0x25c1d3=_0x34413a[_0x2802('0x3')]();_0x25c1d3[_0x2802('0x41')](_0x43dd07[_0x2802('0x19')]),_0x25c1d3['setEndBefore'](_0x43dd07[_0x2802('0x33')]);const _0x4f30b0=_0x25a2a4[_0x2802('0x1e')]();_0x4f30b0[_0x2802('0x11')](),_0x4f30b0[_0x2802('0x34')](_0x25c1d3),_0x34413a[_0x2802('0x2e')]('copy'),_0x43dd07[_0x2802('0x1a')]();}}}export class ContentFieldView extends _0x354e49{constructor(_0x5a2c48,_0x118f40=''){super(_0x5a2c48),this[_0x2802('0x8')]=this['_createLoader'](),this[_0x2802('0x3f')]({'tag':_0x2802('0x35'),'attributes':{'class':['ck',_0x2802('0x22'),_0x118f40,_0x2802('0xb'),_0x2802('0xf')]}});}[_0x2802('0x0')](_0x5a8f5a){this[_0x2802('0x37')][_0x2802('0x2a')]=_0x5a8f5a;}[_0x2802('0x18')](){this[_0x2802('0x37')]['appendChild'](this[_0x2802('0x8')]['element']);}[_0x2802('0x27')](){const _0x2a21d9=new _0x354e49(),_0x4f5587=this[_0x2802('0x6')],_0x4fb38a=new _0x216b2f();return _0x4fb38a[_0x2802('0x38')]=!0x0,_0x2a21d9[_0x2802('0x3f')]({'tag':_0x2802('0x35'),'attributes':{'class':['ck',_0x2802('0x39')]},'children':[_0x4fb38a,{'text':_0xc5dde0(_0x4f5587,_0x2802('0x3e'))}]}),_0x2a21d9[_0x2802('0x12')](),_0x2a21d9;}}
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module ai/ui/aiformerrorview
|
|
7
7
|
*/
|
|
8
|
-
import type { Locale } from 'ckeditor5/src/utils';
|
|
9
|
-
import { View } from 'ckeditor5/src/ui';
|
|
8
|
+
import type { Locale } from 'ckeditor5/src/utils.js';
|
|
9
|
+
import { View } from 'ckeditor5/src/ui.js';
|
|
10
10
|
/**
|
|
11
11
|
* A class representing the error view of the AI assistant.
|
|
12
12
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0xbc9f=['ck-ai-form__error','setTemplate','bindTemplate','div','text','content'];(function(_0x20efd3,_0xbc9f5a){const _0x2755e1=function(_0x5841a8){while(--_0x5841a8){_0x20efd3['push'](_0x20efd3['shift']());}};_0x2755e1(++_0xbc9f5a);}(_0xbc9f,0xee));const _0x2755=function(_0x20efd3,_0xbc9f5a){_0x20efd3=_0x20efd3-0x0;let _0x2755e1=_0xbc9f[_0x20efd3];return _0x2755e1;};import{View as _0xe8c9fa,IconView as _0x44fc48}from'ckeditor5/src/ui.js';import _0x2e486c from'../../../theme/icons/error.svg';export default class et extends _0xe8c9fa{constructor(_0x517570,_0x444a2e=''){super(_0x517570);const _0x3ce87d=new _0x44fc48(),_0x204f13=this[_0x2755('0x4')];this['set'](_0x2755('0x0'),_0x444a2e),_0x3ce87d[_0x2755('0x1')]=_0x2e486c,this[_0x2755('0x3')]({'tag':_0x2755('0x5'),'attributes':{'class':['ck',_0x2755('0x2')]},'children':[_0x3ce87d,{'text':_0x204f13['to']('text')}]});}}
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module ai/ui/aiformpromptview
|
|
7
7
|
*/
|
|
8
|
-
import { type Locale } from 'ckeditor5/src/utils';
|
|
9
|
-
import { AutocompleteView, ButtonView, type TextareaView, type AutocompleteViewConfig } from 'ckeditor5/src/ui';
|
|
8
|
+
import { type Locale } from 'ckeditor5/src/utils.js';
|
|
9
|
+
import { AutocompleteView, ButtonView, type TextareaView, type AutocompleteViewConfig } from 'ckeditor5/src/ui.js';
|
|
10
10
|
/**
|
|
11
11
|
* A textarea field allowing to ask AI.
|
|
12
12
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x4d05=['focusCycler','render','rtl','showHistoryButtonView','requestAnimationFrame','enter','queryView','minRows','isEnabled','right','maxRows','window','set','bind','ck-ai-form__submit','execute','isEmpty','excludeScrollbarsAndBorders','resultsView','_createShowHistoryButton','width','add','focusableChildren','submit','isVisible','update','left','fieldView','element','submitButtonView','history','filteredView','ck-ai-form__toggle-history','uiLanguageDirection','locale','focus','fieldWrapperChildren','style'];(function(_0x3871a2,_0x4d051e){const _0x51a60b=function(_0x501207){while(--_0x501207){_0x3871a2['push'](_0x3871a2['shift']());}};_0x51a60b(++_0x4d051e);}(_0x4d05,0x151));const _0x51a6=function(_0x3871a2,_0x4d051e){_0x3871a2=_0x3871a2-0x0;let _0x51a60b=_0x4d05[_0x3871a2];return _0x51a60b;};import{Rect as _0x293d28,global as _0x466960,isVisible as _0x5e192d}from'ckeditor5/src/utils.js';import{AutocompleteView as _0x18e358,ButtonView as _0x24e415}from'ckeditor5/src/ui.js';import{icons as _0x4a69a6}from'ckeditor5/src/core.js';import{getTranslation as _0x2a64b3}from'../../utils/common-translations.js';import _0xeceddd from'../../../theme/icons/submit.svg';export default class ht extends _0x18e358{constructor(_0x55cd69,_0x43c59d){super(_0x55cd69,_0x43c59d),this['queryView'][_0x51a6('0x20')][_0x51a6('0xc')]=0x1,this['queryView'][_0x51a6('0x20')][_0x51a6('0xf')]=0x3,this['submitButtonView']=this['_createSubmitButton'](),this[_0x51a6('0x8')]=this['_createShowHistoryButton'](),this[_0x51a6('0x1b')][_0x51a6('0x1a')](this[_0x51a6('0x8')],0x1),this['focusableChildren'][_0x51a6('0x1a')](this[_0x51a6('0x22')]);}[_0x51a6('0x6')](){super['render'](),this['queryView'][_0x51a6('0x3')][_0x51a6('0x1a')](this[_0x51a6('0x8')]),this['children'][_0x51a6('0x1a')](this[_0x51a6('0x22')]),this['keystrokes'][_0x51a6('0x11')](_0x51a6('0xa'),(_0x50e13c,_0x4dfe0a)=>{_0x50e13c['target']==this['queryView'][_0x51a6('0x20')][_0x51a6('0x21')]&&(this['submit'](),_0x4dfe0a());});}['_createSubmitButton'](){const _0x3b4eb2=new _0x24e415(this[_0x51a6('0x1')]),_0x168ce5=this['locale'];return _0x3b4eb2['set']({'icon':_0xeceddd,'label':_0x2a64b3(_0x168ce5,'Submit'),'isVisible':!0x0,'tooltip':!0x0,'class':_0x51a6('0x13')}),_0x3b4eb2['on'](_0x51a6('0x14'),()=>{this[_0x51a6('0x1c')]();}),_0x3b4eb2[_0x51a6('0x12')](_0x51a6('0xd'))['to'](this[_0x51a6('0xb')][_0x51a6('0x20')],_0x51a6('0x15'),this,_0x51a6('0xd'),(_0x29d530,_0x532130)=>!_0x29d530&&_0x532130),_0x3b4eb2;}[_0x51a6('0x18')](){const _0x5ef713=new _0x24e415(this[_0x51a6('0x1')]),_0x2946a2=this[_0x51a6('0x17')],_0x2a0abf=this['locale'];_0x5ef713['set']({'label':_0x2a64b3(_0x2a0abf,'History'),'withText':!0x1,'icon':_0x4a69a6[_0x51a6('0x23')],'tooltip':!0x0,'tooltipPosition':'sw','class':_0x51a6('0x25')}),_0x5ef713[_0x51a6('0x12')]('isOn')['to'](_0x2946a2,_0x51a6('0x1d')),_0x5ef713[_0x51a6('0x12')](_0x51a6('0xd'))['to'](this,'isEnabled'),_0x5ef713['on']('execute',()=>{_0x2946a2[_0x51a6('0x1d')]=!_0x2946a2[_0x51a6('0x1d')],_0x2946a2[_0x51a6('0x1d')]?this[_0x51a6('0x24')][_0x51a6('0x2')]():this[_0x51a6('0x2')]();});const _0x5e9518=()=>{_0x466960[_0x51a6('0x10')][_0x51a6('0x9')](()=>{if(_0x5e192d(this[_0x51a6('0x21')])){const _0xb43802=new _0x293d28(this[_0x51a6('0xb')]['fieldView'][_0x51a6('0x21')]),_0x42b7eb=_0xb43802[_0x51a6('0x19')],_0x362f97=_0x51a6('0x7')===_0x2a0abf[_0x51a6('0x0')]?_0x51a6('0x1f'):_0x51a6('0xe');_0xb43802[_0x51a6('0x16')](),_0x5ef713['element'][_0x51a6('0x4')][_0x362f97]=_0x42b7eb-_0xb43802[_0x51a6('0x19')]+0x1+'px';}});};return this[_0x51a6('0xb')][_0x51a6('0x20')]['on'](_0x51a6('0x1e'),_0x5e9518),this['on'](_0x51a6('0x6'),_0x5e9518),_0x5ef713;}[_0x51a6('0x1c')](){const _0xc9e6d5=this[_0x51a6('0xb')][_0x51a6('0x20')]['element']['value'];this['fire']('submit',_0xc9e6d5);}[_0x51a6('0x2')](_0x4254e7){-0x1===_0x4254e7?this[_0x51a6('0x5')]['focusLast']():this['focusCycler']['focusFirst']();}}
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module ai/ui/aiformtoolbarview
|
|
7
7
|
*/
|
|
8
|
-
import type { Locale } from 'ckeditor5/src/utils';
|
|
9
|
-
import { ToolbarView, ButtonView } from 'ckeditor5/src/ui';
|
|
8
|
+
import type { Locale } from 'ckeditor5/src/utils.js';
|
|
9
|
+
import { ToolbarView, ButtonView } from 'ckeditor5/src/ui.js';
|
|
10
10
|
/**
|
|
11
11
|
* The action name affecting the label of {@link ~AIFormToolbarView#replaceButton}.
|
|
12
12
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x1662=['label','ck-button-action','_createButton','isVisible','Insert\x20below','addMany','Try\x20again','_CONTENT','insertButton','bind','items','tryAgainButton','REPLACE','INSERT','replace','locale','replaceButton','bindTemplate','stopButton','toUpperCase','set','insert','extendTemplate','ck-ai-form__toolbar'];(function(_0x31d825,_0x16627b){const _0x29d438=function(_0x498ec1){while(--_0x498ec1){_0x31d825['push'](_0x31d825['shift']());}};_0x29d438(++_0x16627b);}(_0x1662,0x135));const _0x29d4=function(_0x31d825,_0x16627b){_0x31d825=_0x31d825-0x0;let _0x29d438=_0x1662[_0x31d825];return _0x29d438;};import{ToolbarView as _0x38c639,ButtonView as _0x535cfe}from'ckeditor5/src/ui.js';import{getTranslation as _0x1c3eed}from'../../utils/common-translations.js';export var AIFormToolbarViewMainActionLabel;!function(_0x1683ee){_0x1683ee[_0x29d4('0xf')]=_0x29d4('0x11'),_0x1683ee[_0x29d4('0x10')]=_0x29d4('0x0');}(AIFormToolbarViewMainActionLabel||(AIFormToolbarViewMainActionLabel={}));export default class ti extends _0x38c639{constructor(_0x30a512){super(_0x30a512),this['set'](_0x29d4('0x6'),!0x1),this[_0x29d4('0x17')]('mainAction',AIFormToolbarViewMainActionLabel[_0x29d4('0xf')]),this[_0x29d4('0x13')]=this['_createButton']('',_0x29d4('0x4')),this[_0x29d4('0x13')][_0x29d4('0xc')](_0x29d4('0x3'))['to'](this,'mainAction',_0x3f0c55=>_0x1c3eed(_0x30a512,'AI_'+_0x3f0c55[_0x29d4('0x16')]()+_0x29d4('0xa'))),this[_0x29d4('0xb')]=this[_0x29d4('0x5')](_0x1c3eed(_0x30a512,_0x29d4('0x7'))),this[_0x29d4('0xe')]=this['_createButton'](_0x1c3eed(_0x30a512,_0x29d4('0x9'))),this[_0x29d4('0x15')]=this[_0x29d4('0x5')](_0x1c3eed(_0x30a512,'Stop'));const _0x26666b=this[_0x29d4('0x14')];this[_0x29d4('0x1')]({'attributes':{'class':[_0x29d4('0x2'),_0x26666b['if'](_0x29d4('0x6'),'ck-hidden',_0xfaa859=>!_0xfaa859)]}}),this[_0x29d4('0xd')][_0x29d4('0x8')]([this[_0x29d4('0x13')],this[_0x29d4('0xb')],this[_0x29d4('0xe')],this[_0x29d4('0x15')]]);}[_0x29d4('0x5')](_0x4ee36a,_0x3cb987){const _0x3b9140=new _0x535cfe(this[_0x29d4('0x12')]);return _0x3b9140[_0x29d4('0x17')]({'label':_0x4ee36a,'class':_0x3cb987||'','isVisible':!0x0,'withText':!0x0}),_0x3b9140;}}
|
|
@@ -5,12 +5,12 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module ai/ui/aiformview
|
|
7
7
|
*/
|
|
8
|
-
import { FocusTracker, KeystrokeHandler, type Locale } from 'ckeditor5/src/utils';
|
|
9
|
-
import { View, FormHeaderView } from 'ckeditor5/src/ui';
|
|
10
|
-
import AIFormToolbarView, { AIFormToolbarViewMainActionLabel } from './aiformtoolbarview';
|
|
11
|
-
import AIFormContentArea from './aiformcontentarea';
|
|
12
|
-
import AIFormErrorView from './aiformerrorview';
|
|
13
|
-
import AIFormPromptView from './aiformpromptview';
|
|
8
|
+
import { FocusTracker, KeystrokeHandler, type Locale } from 'ckeditor5/src/utils.js';
|
|
9
|
+
import { View, FormHeaderView } from 'ckeditor5/src/ui.js';
|
|
10
|
+
import AIFormToolbarView, { AIFormToolbarViewMainActionLabel } from './aiformtoolbarview.js';
|
|
11
|
+
import AIFormContentArea from './aiformcontentarea.js';
|
|
12
|
+
import AIFormErrorView from './aiformerrorview.js';
|
|
13
|
+
import AIFormPromptView from './aiformpromptview.js';
|
|
14
14
|
/**
|
|
15
15
|
* A class representing the form view of the AI assistant.
|
|
16
16
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x16bc=['clear','Empty\x20history','isEnabled','locale','reset','promptView','ck-ai-form','clearHistory','focus','startProcessing','execute','stopProcessing','items','_createToolbar','delegate','label','div','AI\x20Assistant','text','Ask\x20AI\x20to\x20improve\x20generated\x20text','handleError','listenTo','element','add','isError','toolbar','historyGroupView','tryAgainEvent','focusCycler','submitPrompt','bindTo','REPLACE','set','_promptHistory','insertButton','_focusables','focusPrevious','replaceContent','_createPromptView','keystrokes','replaceButton','ck-hidden','Ask\x20AI\x20and\x20your\x20prompts\x20will\x20be\x20listed\x20here\x20for\x20you\x20to\x20use\x20later.','errorView','focusTracker','high','forwardCycle','copyButtonView','submit','contentArea','mainAction','tab','Ask\x20AI\x20to\x20edit\x20or\x20generate','_focusCycler','ck-ai-form-content','setTemplate','prompt','header','isProcessing','AI_ERROR_FAILED','focusNext','bindTemplate','fieldView','value','bind','stopButton','createCollection','backwardCycle','search','shift\x20+\x20tab','stop','tryAgainButton','fire','queryView','isVisible','finishProcessing','trim'];(function(_0x4b377e,_0x16bce7){const _0x435b1a=function(_0x54f358){while(--_0x54f358){_0x4b377e['push'](_0x4b377e['shift']());}};_0x435b1a(++_0x16bce7);}(_0x16bc,0x1a0));const _0x435b=function(_0x4b377e,_0x16bce7){_0x4b377e=_0x4b377e-0x0;let _0x435b1a=_0x16bc[_0x4b377e];return _0x435b1a;};import{FocusTracker as _0x27aa5b,KeystrokeHandler as _0x441e8f}from'ckeditor5/src/utils.js';import{View as _0x37b29f,FocusCycler as _0x41b0e9,createLabeledTextarea as _0x1515c3,FormHeaderView as _0x597e6e}from'ckeditor5/src/ui.js';import _0x3105c9,{AIFormToolbarViewMainActionLabel as _0x9f60f1}from'./aiformtoolbarview.js';import _0x28a901 from'./aiformcontentarea.js';import _0x2bf552 from'./aiformerrorview.js';import _0x3f0237 from'./aiformpromptview.js';import _0x183f18 from'./aihistorylistview.js';import _0x4e8a13 from'./aihistorylistitemview.js';import _0x247839 from'./prompthistory.js';import{getTranslation as _0x861c55}from'../../utils/common-translations.js';import{escape as _0x4970fd}from'lodash-es';import _0x531217 from'../../../theme/icons/robot-pencil.svg';export default class v extends _0x37b29f{constructor(_0x12afab,_0x47fc84,_0x53aa5f=''){super(_0x12afab),this[_0x435b('0x1')]('isEnabled',!0x0),this[_0x435b('0x1')](_0x435b('0x1b'),!0x1),this[_0x435b('0x1')](_0x435b('0x19'),''),this[_0x435b('0x1')](_0x435b('0x20'),''),this[_0x435b('0x1')]('isError',!0x1),this['set'](_0x435b('0x13'),_0x9f60f1[_0x435b('0x0')]),this[_0x435b('0x2')]=new _0x247839(),this[_0x435b('0xc')]=new _0x2bf552(_0x12afab),this[_0x435b('0x1a')]=new _0x597e6e(_0x12afab,{'label':_0x861c55(_0x12afab,_0x435b('0x3f')),'icon':_0x531217}),this[_0x435b('0x12')]=new _0x28a901(_0x12afab,_0x53aa5f),this['contentArea']['bind'](_0x435b('0x1b'))['to'](this),this['contentArea'][_0x435b('0x21')](_0x435b('0x20'))['to'](this),this[_0x435b('0x47')]=this[_0x435b('0x3b')](),this[_0x435b('0x47')][_0x435b('0x21')](_0x435b('0x13'))['to'](this),this[_0x435b('0x33')]=this[_0x435b('0x7')](),this[_0x435b('0xd')]=new _0x27aa5b(),this[_0x435b('0x8')]=new _0x441e8f(),this[_0x435b('0x4')]=this[_0x435b('0x23')]([this[_0x435b('0x12')],this['contentArea'][_0x435b('0x10')],this[_0x435b('0x47')],this['promptView']]),this[_0x435b('0x16')]=new _0x41b0e9({'focusables':this[_0x435b('0x4')],'focusTracker':this[_0x435b('0xd')],'keystrokeHandler':this[_0x435b('0x8')],'actions':{'focusPrevious':_0x435b('0x26'),'focusNext':_0x435b('0x14')}}),this[_0x435b('0x33')][_0x435b('0x4a')]['on'](_0x435b('0xf'),_0xcdc61e=>{this[_0x435b('0x16')][_0x435b('0x1d')](),_0xcdc61e[_0x435b('0x27')]();}),this[_0x435b('0x33')][_0x435b('0x4a')]['on'](_0x435b('0x24'),_0x5e5742=>{this[_0x435b('0x16')][_0x435b('0x5')](),_0x5e5742[_0x435b('0x27')]();}),this[_0x435b('0x33')][_0x435b('0x2a')][_0x435b('0x1f')][_0x435b('0x21')]('value')['to'](this,_0x435b('0x19'));const _0x471d27=this[_0x435b('0x1e')];this[_0x435b('0x18')]({'tag':_0x435b('0x3e'),'attributes':{'class':['ck',_0x435b('0x34'),_0x47fc84],'tabindex':'-1'},'children':[this['header'],{'tag':'div','attributes':{'class':['ck',_0x435b('0x17')]},'children':[{'tag':_0x435b('0x3e'),'attributes':{'class':[_0x471d27['if']('isError',_0x435b('0xa'),_0x4e7ca4=>!_0x4e7ca4)]},'children':[this[_0x435b('0xc')]]},this[_0x435b('0x12')],this['toolbar'],this[_0x435b('0x33')]]}]});}['render'](){super['render'](),this[_0x435b('0xd')][_0x435b('0x45')](this[_0x435b('0x12')]['element']),this[_0x435b('0xd')][_0x435b('0x45')](this[_0x435b('0x12')][_0x435b('0x10')][_0x435b('0x44')]),this[_0x435b('0xd')][_0x435b('0x45')](this[_0x435b('0x47')][_0x435b('0x44')]),this[_0x435b('0xd')]['add'](this['promptView'][_0x435b('0x44')]),this[_0x435b('0x8')][_0x435b('0x43')](this[_0x435b('0x44')]);}[_0x435b('0x36')](){this[_0x435b('0x16')]['focusFirst']();}[_0x435b('0x32')](){this[_0x435b('0x19')]='',this[_0x435b('0x20')]='',this[_0x435b('0x46')]=!0x1,this[_0x435b('0x33')][_0x435b('0x32')](),this['contentArea']['isVisible']=!0x1,this[_0x435b('0x47')][_0x435b('0x2b')]=!0x1;}[_0x435b('0x7')](){const _0xfd6dc4=this[_0x435b('0x31')],_0x30a541=new _0x3f0237(_0xfd6dc4,{'queryView':{'label':_0x861c55(_0xfd6dc4,_0x435b('0x15')),'creator':_0x1515c3,'showIcon':!0x1,'showResetButton':!0x1},'infoView':{'text':{'noSearchableItems':{'primary':_0x861c55(_0xfd6dc4,_0x435b('0x2f')),'secondary':_0x861c55(_0xfd6dc4,_0x435b('0xb'))}}},'filteredView':this['_createHistoryView'](),'queryMinChars':0x1/0x0,'resetOnBlur':!0x1});return _0x30a541[_0x435b('0x21')](_0x435b('0x30'))['to'](this,'isEnabled',this,_0x435b('0x1b'),(_0x353240,_0x574b06)=>_0x353240&&!_0x574b06),this[_0x435b('0x43')](_0x30a541,_0x435b('0x11'),(_0x20583d,_0x4f7af3)=>{this[_0x435b('0x19')]=_0x4f7af3;const _0x5621ea=_0x4970fd(_0x4f7af3);this[_0x435b('0x29')](_0x435b('0x4b'),_0x5621ea),_0x4f7af3[_0x435b('0x2d')]()&&this[_0x435b('0x2')]['add']({'prompt':_0x5621ea},0x0);},{'priority':_0x435b('0xe')}),_0x30a541;}['_createHistoryView'](){const _0x48fac8=new _0x183f18(this[_0x435b('0x31')]);return _0x48fac8[_0x435b('0x48')][_0x435b('0x3a')][_0x435b('0x4c')](this[_0x435b('0x2')])['as'](_0x4e8a13),_0x48fac8['on'](_0x435b('0x35'),()=>{this['_promptHistory'][_0x435b('0x2e')](),this[_0x435b('0x33')][_0x435b('0x25')](''),this['promptView']['focus']();}),_0x48fac8;}[_0x435b('0x3b')](){const _0xfdcacb=new _0x3105c9(this['locale']);return _0xfdcacb[_0x435b('0x9')][_0x435b('0x21')](_0x435b('0x30'))['to'](this,_0x435b('0x30'),this,'isProcessing',this,_0x435b('0x20'),(_0x1d111a,_0x5540f1,_0x28c65d)=>_0x1d111a&&!_0x5540f1&&!!_0x28c65d),_0xfdcacb[_0x435b('0x9')][_0x435b('0x3c')](_0x435b('0x38'))['to'](this,_0x435b('0x6')),_0xfdcacb[_0x435b('0x3')][_0x435b('0x21')]('isEnabled')['to'](this,_0x435b('0x30'),this,'isProcessing',this,'value',(_0x128c8e,_0x2bc622,_0x18a478)=>_0x128c8e&&!_0x2bc622&&!!_0x18a478),_0xfdcacb[_0x435b('0x3')][_0x435b('0x3c')](_0x435b('0x38'))['to'](this,'insertContentBelow'),_0xfdcacb[_0x435b('0x28')][_0x435b('0x21')](_0x435b('0x30'))['to'](this,_0x435b('0x30'),this,_0x435b('0x1b'),(_0x1c0eb0,_0x4deefc)=>_0x1c0eb0&&!_0x4deefc),_0xfdcacb[_0x435b('0x28')][_0x435b('0x3c')](_0x435b('0x38'))['to'](this,_0x435b('0x49')),_0xfdcacb['stopButton']['bind']('isEnabled')['to'](this,_0x435b('0x1b')),_0xfdcacb[_0x435b('0x22')][_0x435b('0x3c')](_0x435b('0x38'))['to'](this,_0x435b('0x39')),_0xfdcacb;}[_0x435b('0x37')](){this[_0x435b('0x20')]='',this['isError']=!0x1,this[_0x435b('0x1b')]=!0x0,this[_0x435b('0x12')][_0x435b('0x2b')]=!0x0,this[_0x435b('0x47')]['isVisible']=!0x0,this[_0x435b('0x12')][_0x435b('0x36')]();}['finishProcessing'](){const _0x3f3096=this[_0x435b('0x31')];this[_0x435b('0x1b')]=!0x1,this[_0x435b('0x19')]='',this[_0x435b('0x33')][_0x435b('0x32')](),this[_0x435b('0x20')]&&(this[_0x435b('0x33')]['queryView'][_0x435b('0x3d')]=_0x861c55(_0x3f3096,_0x435b('0x41')));}[_0x435b('0x42')](_0x12e6d4){const _0x5232fa=this['locale'];this[_0x435b('0x2c')](),this[_0x435b('0x46')]=!0x0,this[_0x435b('0xc')][_0x435b('0x40')]=_0x12e6d4||_0x861c55(_0x5232fa,_0x435b('0x1c')),this[_0x435b('0x20')]||(this['contentArea'][_0x435b('0x2b')]=!0x1);}}
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module ai/ui/aihistorylistitemview
|
|
7
7
|
*/
|
|
8
|
-
import { ListItemView } from 'ckeditor5/src/ui';
|
|
9
|
-
import type { PromptHistoryEntry } from './prompthistory';
|
|
8
|
+
import { ListItemView } from 'ckeditor5/src/ui.js';
|
|
9
|
+
import type { PromptHistoryEntry } from './prompthistory.js';
|
|
10
10
|
/**
|
|
11
11
|
* A list item view that displays a historical prompt
|
|
12
12
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x1636=['prompt','add','children','fire','locale','execute','set'];(function(_0x150a23,_0x1636d1){const _0x36e097=function(_0x3f389a){while(--_0x3f389a){_0x150a23['push'](_0x150a23['shift']());}};_0x36e097(++_0x1636d1);}(_0x1636,0x69));const _0x36e0=function(_0x150a23,_0x1636d1){_0x150a23=_0x150a23-0x0;let _0x36e097=_0x1636[_0x150a23];return _0x36e097;};import{ListItemView as _0x96b59a,ButtonView as _0x3d883a}from'ckeditor5/src/ui.js';import _0xd4776d from'../dropdown/buttonlabelwithhighlightview.js';import{unescape as _0x5977c9}from'lodash-es';export default class os extends _0x96b59a{constructor(_0x35ca90){super();const _0xe043de=new _0xd4776d(),_0x577a5a=new _0x3d883a(this[_0x36e0('0x4')],_0xe043de);this[_0x36e0('0x2')][_0x36e0('0x1')](_0x577a5a),_0x577a5a[_0x36e0('0x6')]({'label':_0x35ca90[_0x36e0('0x0')],'withText':!0x0}),_0x577a5a['on']('execute',()=>{this[_0x36e0('0x3')](_0x36e0('0x5'),{'value':_0x5977c9(_0x35ca90['prompt'])});});}}
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module ai/ui/aihistorylistview
|
|
7
7
|
*/
|
|
8
|
-
import { ListView, ListItemGroupView, ButtonView, type FilteredView } from 'ckeditor5/src/ui';
|
|
9
|
-
import type { Locale } from 'ckeditor5/src/utils';
|
|
8
|
+
import { ListView, ListItemGroupView, ButtonView, type FilteredView } from 'ckeditor5/src/ui.js';
|
|
9
|
+
import type { Locale } from 'ckeditor5/src/utils.js';
|
|
10
10
|
/**
|
|
11
11
|
* A list view that displays a list of AI prompts with filter pass-through.
|
|
12
12
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x5988=['Prompt\x20history','add','_createClearHistoryButton','delegate','items','children','length','filter','clearHistoryButton','fire','historyGroupView','label','clearHistory','locale'];(function(_0x402e44,_0x598877){const _0x656b36=function(_0x38475f){while(--_0x38475f){_0x402e44['push'](_0x402e44['shift']());}};_0x656b36(++_0x598877);}(_0x5988,0x171));const _0x656b=function(_0x402e44,_0x598877){_0x402e44=_0x402e44-0x0;let _0x656b36=_0x5988[_0x402e44];return _0x656b36;};import{ListView as _0x39ab4f,ListItemGroupView as _0x1aab47,ButtonView as _0x3cfe53}from'ckeditor5/src/ui.js';import{getTranslation as _0x1ab027}from'../../utils/common-translations.js';export default class hs extends _0x39ab4f{constructor(_0x8c2e57){super(_0x8c2e57),this[_0x656b('0x3')]=this[_0x656b('0xb')](),this[_0x656b('0x5')]=new _0x1aab47(),this[_0x656b('0x5')][_0x656b('0x0')][_0x656b('0xa')](this[_0x656b('0x3')],0x1),this['historyGroupView'][_0x656b('0x6')]=_0x1ab027(_0x8c2e57,_0x656b('0x9')),this[_0x656b('0x5')][_0x656b('0xd')][_0x656b('0xc')]('execute')['to'](this),this['items'][_0x656b('0xa')](this['historyGroupView']);}[_0x656b('0x2')](){let _0x437605=0x0;for(const _0x2e57fd of this['items'])_0x437605+=_0x2e57fd[_0x656b('0xd')][_0x656b('0x1')];return{'resultsCount':_0x437605,'totalItemsCount':_0x437605};}['_createClearHistoryButton'](){const _0x4b488f=this[_0x656b('0x8')],_0x30b905=new _0x3cfe53(this[_0x656b('0x8')]);return _0x30b905['set']({'label':'('+_0x1ab027(_0x4b488f,'Clear')+')','withText':!0x0}),_0x30b905['on']('execute',()=>this[_0x656b('0x4')](_0x656b('0x7'))),_0x30b905;}}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
4
|
*/
|
|
5
|
-
import { Collection } from 'ckeditor5/src/utils';
|
|
5
|
+
import { Collection } from 'ckeditor5/src/utils.js';
|
|
6
6
|
/**
|
|
7
7
|
* A collection that stores the prompt history in the session storage as a side effect.
|
|
8
8
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x5bbe=['setItem','addMany','add','trim','parse','last','getItem','length','map','prompt','remove','stringify','toLowerCase','_saveToSessionStorage'];(function(_0x47fd66,_0x5bbe21){const _0x4d7be0=function(_0x3a1b65){while(--_0x3a1b65){_0x47fd66['push'](_0x47fd66['shift']());}};_0x4d7be0(++_0x5bbe21);}(_0x5bbe,0x192));const _0x4d7b=function(_0x47fd66,_0x5bbe21){_0x47fd66=_0x47fd66-0x0;let _0x4d7be0=_0x5bbe[_0x47fd66];return _0x4d7be0;};import{Collection as _0x7fe4b8}from'ckeditor5/src/utils.js';const Ss='CKEditor/AIFormView/PromptHistory';export default class ns extends _0x7fe4b8{constructor(){super(),this['_loadFromSessionStorage'](),this['on'](_0x4d7b('0x6'),(_0x5f1f81,_0x50c1c2)=>{const _0x430f15=ds(_0x50c1c2[_0x4d7b('0xd')]);for(const _0xeada01 of this)if(_0xeada01!=_0x50c1c2&&ds(_0xeada01[_0x4d7b('0xd')])===_0x430f15){this[_0x4d7b('0x0')](_0xeada01);break;}this[_0x4d7b('0xb')]>0x14&&this[_0x4d7b('0x0')](this[_0x4d7b('0x9')]),this['_saveToSessionStorage']();}),this['on']('remove',()=>{this[_0x4d7b('0x3')]();});}['_loadFromSessionStorage'](){const _0x51f5dc=sessionStorage[_0x4d7b('0xa')](Ss)||'[]';this[_0x4d7b('0x5')](JSON[_0x4d7b('0x8')](_0x51f5dc));}[_0x4d7b('0x3')](){sessionStorage[_0x4d7b('0x4')](Ss,JSON[_0x4d7b('0x1')](this[_0x4d7b('0xc')](_0x487e41=>_0x487e41)));}}function ds(_0x464d07){return _0x464d07[_0x4d7b('0x2')]()[_0x4d7b('0x7')]();}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x3a56=['config','refresh','getRanges','model','name','includes','getItems','editor','isEnabled','showUI','element','custom','execute','selection'];(function(_0x50eade,_0x3a562c){const _0x520f69=function(_0x5a8ee7){while(--_0x5a8ee7){_0x50eade['push'](_0x50eade['shift']());}};_0x520f69(++_0x3a562c);}(_0x3a56,0x1b8));const _0x520f=function(_0x50eade,_0x3a562c){_0x50eade=_0x50eade-0x0;let _0x520f69=_0x3a56[_0x50eade];return _0x520f69;};import{Command as _0x128fe8}from'ckeditor5/src/core.js';import _0x141326 from'../aiassistantui.js';export default class I extends _0x128fe8{[_0x520f('0x9')](){const _0x150156=this['editor'][_0x520f('0xb')]['document'][_0x520f('0x7')],_0xc042c9=this[_0x520f('0x1')][_0x520f('0x8')]['get']('ai.aiAssistant.disabledElements');for(const _0xc5fb2c of _0x150156[_0x520f('0xa')]())for(const _0x1f4779 of _0xc5fb2c[_0x520f('0x0')]())if(_0x1f4779['is'](_0x520f('0x4'))&&_0xc042c9[_0x520f('0xd')](_0x1f4779[_0x520f('0xc')]))return void(this[_0x520f('0x2')]=!0x1);this[_0x520f('0x2')]=!0x0;}[_0x520f('0x6')](_0x283a7c='',_0x1cdf15='',_0x276626=_0x520f('0x5')){this['editor']['plugins']['get'](_0x141326)[_0x520f('0x3')](_0x283a7c,_0x1cdf15,_0x276626);}}
|
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module ai/utils/common-translations
|
|
7
7
|
*/
|
|
8
|
-
import type { Locale } from 'ckeditor5/src/utils';
|
|
8
|
+
import type { Locale } from 'ckeditor5/src/utils.js';
|
|
9
9
|
export declare function getTranslation(locale: Locale, id: string, values?: string | Array<string> | number): string;
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
export function getTranslation(
|
|
23
|
+
export function getTranslation(_0x2f6204,_0x5f31aa,_0x11c002){const t=_0x2f6204['t'];switch(_0x5f31aa){case'Edit\x20or\x20review':return t('Edit\x20or\x20review');case'Improve\x20writing':return t('Improve\x20writing');case'Make\x20shorter':return t('Make\x20shorter');case'Make\x20longer':return t('Make\x20longer');case'Simplify\x20language':return t('Simplify\x20language');case'Generate\x20from\x20selection':return t('Generate\x20from\x20selection');case'Summarize':return t('Summarize');case'Continue':return t('Continue');case'Change\x20tone':return t('Change\x20tone');case'Professional':return t('Professional');case'Casual':return t('Casual');case'Direct':return t('Direct');case'Confident':return t('Confident');case'Friendly':return t('Friendly');case'Change\x20style':return t('Change\x20style');case'Business':return t('Business');case'Legal':return t('Legal');case'Journalism':return t('Journalism');case'Poetic':return t('Poetic');case'Translate':return t('Translate');case'Translate\x20to\x20%0':return t('Translate\x20to\x20%0',_0x11c002);case'English':return t('English');case'Spanish':return t('Spanish');case'German':return t('German');case'Portuguese':return t('Portuguese');case'French':return t('French');case'Simplified\x20Chinese':return t('Simplified\x20Chinese');case'Hindi':return t('Hindi');case'Arabic':return t('Arabic');case'AI\x20Assistant':return t('AI\x20Assistant');case'AI\x20Commands':return t('AI\x20Commands');case'Ask\x20AI\x20to\x20edit\x20or\x20generate':return t('Ask\x20AI\x20to\x20edit\x20or\x20generate');case'Ask\x20AI\x20to\x20improve\x20generated\x20text':return t('Ask\x20AI\x20to\x20improve\x20generated\x20text');case'Copy':return t('Copy');case'Submit':return t('Submit');case'Insert\x20below':return t('Insert\x20below');case'Try\x20again':return t('Try\x20again');case'Stop':return t('Stop');case'AI\x20is\x20writing...':return t('AI\x20is\x20writing...');case'History':return t('History');case'Empty\x20history':return t('Empty\x20history');case'Ask\x20AI\x20and\x20your\x20prompts\x20will\x20be\x20listed\x20here\x20for\x20you\x20to\x20use\x20later.':return t('Ask\x20AI\x20and\x20your\x20prompts\x20will\x20be\x20listed\x20here\x20for\x20you\x20to\x20use\x20later.');case'Prompt\x20history':return t('Prompt\x20history');case'Search\x20AI\x20command':return t('Search\x20AI\x20command');case'No\x20commands\x20found':return t('No\x20commands\x20found');case'No\x20commands\x20available':return t('No\x20commands\x20available');case'Clear':return t('Clear');case'AI_REPLACE_CONTENT':return t({'id':'AI_REPLACE_CONTENT','string':'Replace'});case'AI_INSERT_CONTENT':return t({'id':'AI_INSERT_CONTENT','string':'Insert'});case'AI_ERROR_GET_HEADERS':return t({'id':'AI_ERROR_GET_HEADERS','string':'Preparing\x20request\x20headers\x20failed'});case'AI_ERROR_GET_PARAMETERS':return t({'id':'AI_ERROR_GET_PARAMETERS','string':'Preparing\x20request\x20parameters\x20failed'});case'AI_ERROR_UNSUPPORTED_MODEL':return t({'id':'AI_ERROR_UNSUPPORTED_MODEL','string':'The\x20requested\x20AI\x20model\x20(\x22%0\x22)\x20is\x20not\x20supported'},_0x11c002);case'AI_ERROR_CONTEXT_LENGTH':return t({'id':'AI_ERROR_CONTEXT_LENGTH','string':'Selected\x20content\x20is\x20too\x20long'});case'AI_ERROR_MODERATION':return t({'id':'AI_ERROR_MODERATION','string':'Requested\x20query\x20does\x20not\x20pass\x20moderation\x20rules'});case'AI_ERROR_FAILED':return t({'id':'AI_ERROR_FAILED','string':'Failed\x20to\x20communicate\x20with\x20the\x20AI\x20service'});default:return _0x5f31aa;}}
|