@ckeditor/ckeditor5-ai 43.2.0-alpha.7 → 43.3.0-alpha.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/build/translations/ast.js +1 -0
- package/build/translations/az.js +1 -0
- package/build/translations/en-gb.js +1 -0
- package/build/translations/eo.js +1 -0
- package/build/translations/eu.js +1 -0
- package/build/translations/gu.js +1 -0
- package/build/translations/hy.js +1 -0
- package/build/translations/kk.js +1 -0
- package/build/translations/km.js +1 -0
- package/build/translations/kn.js +1 -0
- package/build/translations/ku.js +1 -0
- package/build/translations/nb.js +1 -0
- package/build/translations/ne.js +1 -0
- package/build/translations/oc.js +1 -0
- package/build/translations/si.js +1 -0
- package/build/translations/sl.js +1 -0
- package/build/translations/sq.js +1 -0
- package/dist/adapters/aiadapter.d.ts +8 -0
- package/dist/aiassistant.d.ts +12 -1
- package/dist/aiassistantediting.d.ts +8 -0
- package/dist/aiassistantui.d.ts +8 -0
- package/dist/index-editor.css +18 -22
- package/dist/index.css +18 -22
- package/dist/index.js +2 -2
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.d.ts +8 -0
- package/dist/translations/ast.js +23 -0
- package/dist/translations/ast.umd.js +23 -0
- package/dist/translations/az.d.ts +8 -0
- package/dist/translations/az.js +23 -0
- package/dist/translations/az.umd.js +23 -0
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.d.ts +8 -0
- package/dist/translations/en-gb.js +23 -0
- package/dist/translations/en-gb.umd.js +23 -0
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.d.ts +8 -0
- package/dist/translations/eo.js +23 -0
- package/dist/translations/eo.umd.js +23 -0
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.d.ts +8 -0
- package/dist/translations/eu.js +23 -0
- package/dist/translations/eu.umd.js +23 -0
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.d.ts +8 -0
- package/dist/translations/gu.js +23 -0
- package/dist/translations/gu.umd.js +23 -0
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.d.ts +8 -0
- package/dist/translations/hy.js +23 -0
- package/dist/translations/hy.umd.js +23 -0
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.d.ts +8 -0
- package/dist/translations/kk.js +23 -0
- package/dist/translations/kk.umd.js +23 -0
- package/dist/translations/km.d.ts +8 -0
- package/dist/translations/km.js +23 -0
- package/dist/translations/km.umd.js +23 -0
- package/dist/translations/kn.d.ts +8 -0
- package/dist/translations/kn.js +23 -0
- package/dist/translations/kn.umd.js +23 -0
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.d.ts +8 -0
- package/dist/translations/ku.js +23 -0
- package/dist/translations/ku.umd.js +23 -0
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.d.ts +8 -0
- package/dist/translations/nb.js +23 -0
- package/dist/translations/nb.umd.js +23 -0
- package/dist/translations/ne.d.ts +8 -0
- package/dist/translations/ne.js +23 -0
- package/dist/translations/ne.umd.js +23 -0
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.d.ts +8 -0
- package/dist/translations/oc.js +23 -0
- package/dist/translations/oc.umd.js +23 -0
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.d.ts +8 -0
- package/dist/translations/si.js +23 -0
- package/dist/translations/si.umd.js +23 -0
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.d.ts +8 -0
- package/dist/translations/sl.js +23 -0
- package/dist/translations/sl.umd.js +23 -0
- package/dist/translations/sq.d.ts +8 -0
- package/dist/translations/sq.js +23 -0
- package/dist/translations/sq.umd.js +23 -0
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/dist/utils/normalizecommandsconfig.d.ts +18 -0
- package/lang/contexts.json +1 -0
- package/lang/translations/af.po +7 -9
- package/lang/translations/ar.po +8 -10
- package/lang/translations/ast.po +228 -0
- package/lang/translations/az.po +228 -0
- package/lang/translations/bg.po +7 -9
- package/lang/translations/bn.po +7 -9
- package/lang/translations/bs.po +8 -10
- package/lang/translations/ca.po +7 -9
- package/lang/translations/cs.po +8 -10
- package/lang/translations/da.po +7 -9
- package/lang/translations/de-ch.po +7 -9
- package/lang/translations/de.po +7 -9
- package/lang/translations/el.po +7 -9
- package/lang/translations/en-au.po +7 -9
- package/lang/translations/en-gb.po +228 -0
- package/lang/translations/en.po +9 -11
- package/lang/translations/eo.po +228 -0
- package/lang/translations/es-co.po +8 -10
- package/lang/translations/es.po +8 -10
- package/lang/translations/et.po +7 -9
- package/lang/translations/eu.po +228 -0
- package/lang/translations/fa.po +8 -10
- package/lang/translations/fi.po +7 -9
- package/lang/translations/fr.po +8 -10
- package/lang/translations/gl.po +7 -9
- package/lang/translations/gu.po +228 -0
- package/lang/translations/he.po +8 -10
- package/lang/translations/hi.po +7 -9
- package/lang/translations/hr.po +8 -10
- package/lang/translations/hu.po +7 -9
- package/lang/translations/hy.po +228 -0
- package/lang/translations/id.po +7 -9
- package/lang/translations/it.po +8 -10
- package/lang/translations/ja.po +7 -9
- package/lang/translations/jv.po +8 -10
- package/lang/translations/kk.po +228 -0
- package/lang/translations/km.po +228 -0
- package/lang/translations/kn.po +228 -0
- package/lang/translations/ko.po +7 -9
- package/lang/translations/ku.po +228 -0
- package/lang/translations/lt.po +8 -10
- package/lang/translations/lv.po +8 -10
- package/lang/translations/ms.po +7 -9
- package/lang/translations/nb.po +228 -0
- package/lang/translations/ne.po +228 -0
- package/lang/translations/nl.po +7 -9
- package/lang/translations/no.po +7 -9
- package/lang/translations/oc.po +228 -0
- package/lang/translations/pl.po +8 -10
- package/lang/translations/pt-br.po +8 -10
- package/lang/translations/pt.po +8 -10
- package/lang/translations/ro.po +8 -10
- package/lang/translations/ru.po +8 -10
- package/lang/translations/si.po +228 -0
- package/lang/translations/sk.po +8 -10
- package/lang/translations/sl.po +228 -0
- package/lang/translations/sq.po +228 -0
- package/lang/translations/sr-latn.po +8 -10
- package/lang/translations/sr.po +8 -10
- package/lang/translations/sv.po +7 -9
- package/lang/translations/th.po +7 -9
- package/lang/translations/ti.po +7 -9
- package/lang/translations/tk.po +7 -9
- package/lang/translations/tr.po +7 -9
- package/lang/translations/tt.po +7 -9
- package/lang/translations/ug.po +8 -10
- package/lang/translations/uk.po +8 -10
- package/lang/translations/ur.po +7 -9
- package/lang/translations/uz.po +8 -10
- package/lang/translations/vi.po +7 -9
- package/lang/translations/zh-cn.po +7 -9
- package/lang/translations/zh.po +7 -9
- package/package.json +8 -8
- package/src/adapters/aiadapter.d.ts +8 -0
- package/src/adapters/aiadapter.js +1 -1
- package/src/adapters/aitextadapter.js +1 -1
- package/src/adapters/awstextadapter.js +1 -1
- package/src/adapters/openaitextadapter.js +1 -1
- package/src/aiassistant.d.ts +12 -1
- package/src/aiassistant.js +1 -1
- package/src/aiassistantediting.d.ts +8 -0
- package/src/aiassistantediting.js +1 -1
- package/src/aiassistantui.d.ts +8 -0
- package/src/aiassistantui.js +1 -1
- package/src/index.js +1 -1
- package/src/ui/aiassistantcontroller.js +2 -2
- package/src/ui/form/aiformcontentarea.js +1 -1
- package/src/ui/form/aiformerrorview.js +1 -1
- package/src/ui/form/aiformpromptview.js +1 -1
- package/src/ui/form/aiformtoolbarview.js +1 -1
- package/src/ui/form/aiformview.js +1 -1
- package/src/ui/form/aihistorylistitemview.js +1 -1
- package/src/ui/form/aihistorylistview.js +1 -1
- package/src/ui/form/prompthistory.js +1 -1
- package/src/ui/showaiassistantcommand.js +1 -1
- package/src/utils/common-translations.js +1 -1
- package/src/utils/normalizecommandsconfig.d.ts +14 -0
- package/src/utils/normalizecommandsconfig.js +23 -0
|
@@ -1,18 +1,12 @@
|
|
|
1
1
|
# Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
2
2
|
#
|
|
3
|
-
#
|
|
3
|
+
# Want to contribute to this file? Submit your changes via a GitHub Pull Request.
|
|
4
4
|
#
|
|
5
|
-
#
|
|
6
|
-
#
|
|
7
|
-
#
|
|
8
|
-
# To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
|
|
9
|
-
#
|
|
10
|
-
# To learn more, check out the official contributor's guide:
|
|
11
|
-
# https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
|
|
5
|
+
# Check out the official contributor's guide:
|
|
6
|
+
# https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
|
|
12
7
|
#
|
|
13
8
|
msgid ""
|
|
14
9
|
msgstr ""
|
|
15
|
-
"Language-Team: Chinese (China) (https://app.transifex.com/ckeditor/teams/11143/zh_CN/)\n"
|
|
16
10
|
"Language: zh_CN\n"
|
|
17
11
|
"Plural-Forms: nplurals=1; plural=0;\n"
|
|
18
12
|
"Content-Type: text/plain; charset=UTF-8\n"
|
|
@@ -228,3 +222,7 @@ msgstr "请求的查询不符合审查规则"
|
|
|
228
222
|
msgctxt "Generic error message displayed when the request failed for unspecified reason."
|
|
229
223
|
msgid "AI_ERROR_FAILED"
|
|
230
224
|
msgstr "跟 AI 服务通信失败"
|
|
225
|
+
|
|
226
|
+
msgctxt "The default label of the \"ungrouped\" commands group in the AI Commands list."
|
|
227
|
+
msgid "Other"
|
|
228
|
+
msgstr ""
|
package/lang/translations/zh.po
CHANGED
|
@@ -1,18 +1,12 @@
|
|
|
1
1
|
# Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
2
2
|
#
|
|
3
|
-
#
|
|
3
|
+
# Want to contribute to this file? Submit your changes via a GitHub Pull Request.
|
|
4
4
|
#
|
|
5
|
-
#
|
|
6
|
-
#
|
|
7
|
-
#
|
|
8
|
-
# To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
|
|
9
|
-
#
|
|
10
|
-
# To learn more, check out the official contributor's guide:
|
|
11
|
-
# https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
|
|
5
|
+
# Check out the official contributor's guide:
|
|
6
|
+
# https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
|
|
12
7
|
#
|
|
13
8
|
msgid ""
|
|
14
9
|
msgstr ""
|
|
15
|
-
"Language-Team: Chinese (Taiwan) (https://app.transifex.com/ckeditor/teams/11143/zh_TW/)\n"
|
|
16
10
|
"Language: zh_TW\n"
|
|
17
11
|
"Plural-Forms: nplurals=1; plural=0;\n"
|
|
18
12
|
"Content-Type: text/plain; charset=UTF-8\n"
|
|
@@ -228,3 +222,7 @@ msgstr "提交的要求未通過審核規則"
|
|
|
228
222
|
msgctxt "Generic error message displayed when the request failed for unspecified reason."
|
|
229
223
|
msgid "AI_ERROR_FAILED"
|
|
230
224
|
msgstr "與 AI 服務通訊失敗"
|
|
225
|
+
|
|
226
|
+
msgctxt "The default label of the \"ungrouped\" commands group in the AI Commands list."
|
|
227
|
+
msgid "Other"
|
|
228
|
+
msgstr ""
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-ai",
|
|
3
|
-
"version": "43.
|
|
3
|
+
"version": "43.3.0-alpha.0",
|
|
4
4
|
"description": "AI Assistant feature for CKEditor 5.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"author": "CKSource (http://cksource.com/)",
|
|
@@ -24,13 +24,13 @@
|
|
|
24
24
|
],
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@aws-sdk/client-bedrock-runtime": "3.621.0",
|
|
27
|
-
"@ckeditor/ckeditor5-clipboard": "43.
|
|
28
|
-
"@ckeditor/ckeditor5-core": "43.
|
|
29
|
-
"@ckeditor/ckeditor5-engine": "43.
|
|
30
|
-
"@ckeditor/ckeditor5-ui": "43.
|
|
31
|
-
"@ckeditor/ckeditor5-utils": "43.
|
|
32
|
-
"ckeditor5": "43.
|
|
33
|
-
"ckeditor5-collaboration": "43.
|
|
27
|
+
"@ckeditor/ckeditor5-clipboard": "43.3.0-alpha.0",
|
|
28
|
+
"@ckeditor/ckeditor5-core": "43.3.0-alpha.0",
|
|
29
|
+
"@ckeditor/ckeditor5-engine": "43.3.0-alpha.0",
|
|
30
|
+
"@ckeditor/ckeditor5-ui": "43.3.0-alpha.0",
|
|
31
|
+
"@ckeditor/ckeditor5-utils": "43.3.0-alpha.0",
|
|
32
|
+
"ckeditor5": "43.3.0-alpha.0",
|
|
33
|
+
"ckeditor5-collaboration": "43.3.0-alpha.0",
|
|
34
34
|
"lodash-es": "4.17.21"
|
|
35
35
|
},
|
|
36
36
|
"type": "module",
|
|
@@ -33,6 +33,14 @@ export default class AIAdapter extends Plugin {
|
|
|
33
33
|
* @inheritDoc
|
|
34
34
|
*/
|
|
35
35
|
static get pluginName(): "AIAdapter";
|
|
36
|
+
/**
|
|
37
|
+
* @inheritDoc
|
|
38
|
+
*/
|
|
39
|
+
static get isOfficialPlugin(): true;
|
|
40
|
+
/**
|
|
41
|
+
* @inheritDoc
|
|
42
|
+
*/
|
|
43
|
+
static get isPremiumPlugin(): true;
|
|
36
44
|
/**
|
|
37
45
|
* @inheritDoc
|
|
38
46
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
function
|
|
23
|
+
function _0x27f1(_0x5cc2d1,_0x53395b){var _0x3dc689=_0x3dc6();return _0x27f1=function(_0x27f15b,_0xdb55f8){_0x27f15b=_0x27f15b-0x133;var _0x250267=_0x3dc689[_0x27f15b];return _0x250267;},_0x27f1(_0x5cc2d1,_0x53395b);}var _0xeebbdb=_0x27f1;(function(_0x58c1cb,_0x3511ee){var _0x529171=_0x27f1,_0x43e311=_0x58c1cb();while(!![]){try{var _0x623510=-parseInt(_0x529171(0x139))/0x1*(-parseInt(_0x529171(0x143))/0x2)+parseInt(_0x529171(0x142))/0x3+parseInt(_0x529171(0x13b))/0x4*(-parseInt(_0x529171(0x135))/0x5)+-parseInt(_0x529171(0x144))/0x6+-parseInt(_0x529171(0x13d))/0x7*(parseInt(_0x529171(0x145))/0x8)+-parseInt(_0x529171(0x136))/0x9*(-parseInt(_0x529171(0x13c))/0xa)+parseInt(_0x529171(0x141))/0xb;if(_0x623510===_0x3511ee)break;else _0x43e311['push'](_0x43e311['shift']());}catch(_0x1ad6eb){_0x43e311['push'](_0x43e311['shift']());}}}(_0x3dc6,0xede87));import{Plugin as _0x2187ef}from'ckeditor5/src/core.js';import{CKEditorError as _0x24c62b}from'ckeditor5/src/utils.js';export default class y extends _0x2187ef{static get[_0xeebbdb(0x13a)](){var _0x47c132=_0xeebbdb;return _0x47c132(0x146);}static get[_0xeebbdb(0x138)](){return!0x0;}static get[_0xeebbdb(0x137)](){return!0x0;}[_0xeebbdb(0x140)](){var _0x5b3421=_0xeebbdb;if(!this[_0x5b3421(0x13e)])throw new _0x24c62b(_0x5b3421(0x133),null);}}export class AIRequestError extends Error{constructor(_0xc9cf1){var _0x5a5c99=_0xeebbdb;super(_0xc9cf1),this[_0x5a5c99(0x13f)]=_0x5a5c99(0x134);}}function _0x3dc6(){var _0x4e8fd6=['93864LukbfG','AIAdapter','aiadapter-text-adapter-not-set','AIRequestError','1181615kdlyYX','9WvOsbi','isPremiumPlugin','isOfficialPlugin','9XpZHaB','pluginName','12wUAtyC','10958500KDOQID','1050rQyRoy','textAdapter','name','afterInit','1925209SrXOEl','5782305LKmgar','182620iBcqan','3460224afmMPi'];_0x3dc6=function(){return _0x4e8fd6;};return _0x3dc6();}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x328554=_0x19ce;(function(_0x2e2549,_0x3aff56){const _0x4e39c0=_0x19ce,_0x2cfe4c=_0x2e2549();while(!![]){try{const _0x15c5d1=parseInt(_0x4e39c0(0x1cf))/0x1*(parseInt(_0x4e39c0(0x1e1))/0x2)+-parseInt(_0x4e39c0(0x1da))/0x3+-parseInt(_0x4e39c0(0x1db))/0x4*(-parseInt(_0x4e39c0(0x1d1))/0x5)+parseInt(_0x4e39c0(0x1d8))/0x6*(-parseInt(_0x4e39c0(0x1c8))/0x7)+-parseInt(_0x4e39c0(0x1cb))/0x8*(parseInt(_0x4e39c0(0x1e2))/0x9)+-parseInt(_0x4e39c0(0x1e4))/0xa+parseInt(_0x4e39c0(0x1d2))/0xb;if(_0x15c5d1===_0x3aff56)break;else _0x2cfe4c['push'](_0x2cfe4c['shift']());}catch(_0xbe78cb){_0x2cfe4c['push'](_0x2cfe4c['shift']());}}}(_0x5337,0x3c2cf));function _0x19ce(_0x223acc,_0x415d5d){const _0x5337b3=_0x5337();return _0x19ce=function(_0x19ceb7,_0x5c1786){_0x19ceb7=_0x19ceb7-0x1c8;let _0x23ee98=_0x5337b3[_0x19ceb7];return _0x23ee98;},_0x19ce(_0x223acc,_0x415d5d);}import{Plugin as _0x1cd28c}from'ckeditor5/src/core.js';import{CKEditorError as _0x5ac9aa}from'ckeditor5/src/utils.js';import{default as _0x397360,AIRequestError as _0x2a56ea}from'./aiadapter.js';function _0x5337(){const _0x4bb309=['2266105zKkUXQ','2412619TIQDqx','get','application/json','error','AI_ERROR_GET_PARAMETERS','editor','90IIHqMn','AbortError','520821zASMqF','4UaMobh','locale','signal','_prepareRequestHeaders','plugins','makeRequest','764378ctjYrA','117moeyBK','abort','4695200KPAcxq','requires','assign','resolve','catch','textAdapter','object','aitextadapter-send-request-failed','AI_ERROR_GET_HEADERS','aborted','10535aPqNAM','init','_prepareRequestParameters','87728jroxmV','reject','name','sendRequest','1KbndyM','abortController'];_0x5337=function(){return _0x4bb309;};return _0x5337();}import{getTranslation as _0x542d34}from'../utils/common-translations.js';export default class P extends _0x1cd28c{static get[_0x328554(0x1e5)](){return[_0x397360];}constructor(_0x381fd3){const _0x9731af=_0x328554;super(_0x381fd3),this[_0x9731af(0x1d0)]=new AbortController();}[_0x328554(0x1c9)](){const _0x32ed48=_0x328554;this[_0x32ed48(0x1d7)][_0x32ed48(0x1df)][_0x32ed48(0x1d3)](_0x397360)[_0x32ed48(0x1e9)]=this;}[_0x328554(0x1e3)](){const _0x1dbfaa=_0x328554;this[_0x1dbfaa(0x1d0)][_0x1dbfaa(0x1dd)][_0x1dbfaa(0x1ed)]||(this[_0x1dbfaa(0x1d0)][_0x1dbfaa(0x1e3)](),this[_0x1dbfaa(0x1d0)]=new AbortController());}async[_0x328554(0x1e0)](_0x2edd3b){const _0x1bcacd=_0x328554;return this[_0x1bcacd(0x1ce)](_0x2edd3b)[_0x1bcacd(0x1e8)](_0x2f2e4b=>{const _0x836d1e=_0x1bcacd;if(_0x2f2e4b instanceof _0x2a56ea)return Promise[_0x836d1e(0x1cc)](_0x2f2e4b);if(_0x836d1e(0x1d9)==_0x2f2e4b[_0x836d1e(0x1cd)])return Promise[_0x836d1e(0x1e7)]();throw console[_0x836d1e(0x1d5)](_0x2f2e4b),new _0x5ac9aa(_0x836d1e(0x1eb),null);});}async[_0x328554(0x1de)](_0x410534,_0xd3777b){const _0x18e5b6=_0x328554,_0x45ce68=this[_0x18e5b6(0x1d7)][_0x18e5b6(0x1dc)],_0x8655a={'Content-Type':_0x18e5b6(0x1d4)};if(_0x18e5b6(0x1ea)==typeof _0x410534)Object[_0x18e5b6(0x1e6)](_0x8655a,_0x410534);else{if(_0x410534)try{const _0x282936=await _0x410534(_0xd3777b);Object[_0x18e5b6(0x1e6)](_0x8655a,_0x282936);}catch(_0x3ed566){return Promise[_0x18e5b6(0x1cc)](new _0x2a56ea(_0x542d34(_0x45ce68,_0x18e5b6(0x1ec))));}}return _0x8655a;}async[_0x328554(0x1ca)](_0x54a57,_0x423d2c){const _0x27f61b=_0x328554,_0x1084f6=this[_0x27f61b(0x1d7)][_0x27f61b(0x1dc)];if(_0x27f61b(0x1ea)==typeof _0x54a57)return _0x54a57;try{return await _0x54a57(_0x423d2c);}catch(_0x1490e7){return Promise[_0x27f61b(0x1cc)](new _0x2a56ea(_0x542d34(_0x1084f6,_0x27f61b(0x1d6))));}}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x2d43a4=_0x8e84;function _0x4980(){const _0x469829=['meta.llama','_getGeneratedText','ai.aws.requestParameters','signal','ai21.j2','cohere.command','14SBfWPu','test','config','sendRequest','text','_prepareRequestHeaders','_readStreamableResponse','POST','2391465Tupgqk','get','anthropic.claude-v2','split','json','Human:\x0a','105YFKqQT','filter','\x0a[/INST]','define','read','AWSTextAdapter','\x0a<</SYS>>\x0a[INST]\x0a','ai.aws.apiUrl','_readStaticResponse','length','data','completion','send','map','5XlwqEw','_processProxyRequest','_requestHeaders','bedrock-2023-05-31','bytes','7127442HvFwhQ','generation','Instruction:\x0a','join','abortController','resolve','anthropic.claude','<<SYS>>\x0a','1276572SzbwLo','completions','preparePrompt','\x0aYou\x20must\x20keep\x20the\x20text\x20formatting.\x0a\x0aContent:\x0a','toString','_readAsyncIterableResponse','ai.aws.bedrockClientConfig','utf-8','from','4552miocJc','locale','generations','getModelFamily','editor','19380000uqBiti','Your\x20task\x20is\x20to\x20generate\x20HTML\x20content\x20accordingly\x20to\x20the\x20given\x20instruction.\x20Never\x20include\x20<img>\x20tag\x20in\x20your\x20response\x20even\x20if\x20asked\x20for.\x20Your\x20answer\x20must\x20be\x20a\x20well-structured\x20and\x20properly\x20formatted\x20HTML\x20code.\x20Answer\x20only\x20with\x20the\x20generated\x20HTML\x20content.\x20Do\x20not\x20add\x20any\x20additional\x20remarks\x20or\x20notes.\x20Do\x20not\x20act\x20like\x20a\x20chatbot\x20or\x20a\x20real\x20person.','ai.aws.requestHeaders','application/json','pluginName','\x0a\x0aAssistant:','Your\x20task\x20is\x20to\x20execute\x20the\x20instruction\x20using\x20the\x20provided\x20HTML\x20content.\x20Follow\x20the\x20instruction\x20closely.\x20Your\x20answer\x20must\x20be\x20a\x20properly\x20formatted\x20HTML\x20code.\x20Do\x20not\x20add\x20any\x20additional\x20remarks\x20or\x20notes.\x20Do\x20not\x20act\x20like\x20a\x20chatbot\x20or\x20a\x20real\x20person.','_apiUrl','_prepareRequestParameters','AI_ERROR_UNSUPPORTED_MODEL','30020QZDPdN','body','_bedrockClientConfig','_processAWSRequest','5279238mCTwqH','utf8','parse','chunk','getReader','stringify','decode','_requestParameters'];_0x4980=function(){return _0x469829;};return _0x4980();}(function(_0x4080b5,_0xfd5987){const _0x293faf=_0x8e84,_0x51bb9e=_0x4080b5();while(!![]){try{const _0x1bdf9f=-parseInt(_0x293faf(0x1a3))/0x1*(parseInt(_0x293faf(0x191))/0x2)+-parseInt(_0x293faf(0x1ab))/0x3+-parseInt(_0x293faf(0x1cc))/0x4+-parseInt(_0x293faf(0x1bf))/0x5*(parseInt(_0x293faf(0x195))/0x6)+parseInt(_0x293faf(0x1b1))/0x7*(-parseInt(_0x293faf(0x1d5))/0x8)+parseInt(_0x293faf(0x1c4))/0x9+parseInt(_0x293faf(0x1da))/0xa;if(_0x1bdf9f===_0xfd5987)break;else _0x51bb9e['push'](_0x51bb9e['shift']());}catch(_0x14c6ff){_0x51bb9e['push'](_0x51bb9e['shift']());}}}(_0x4980,0x7dc14));import{default as _0x4968c4}from'./aitextadapter.js';import{AIRequestError as _0x4ef70d}from'./aiadapter.js';import{BedrockRuntimeClient as _0x3ec238,InvokeModelCommand as _0x41cb08,InvokeModelWithResponseStreamCommand as _0x375b02}from'@aws-sdk/client-bedrock-runtime';function _0x8e84(_0x1ab2fc,_0x57621b){const _0x49809d=_0x4980();return _0x8e84=function(_0x8e8483,_0x346b8e){_0x8e8483=_0x8e8483-0x18b;let _0x3ec623=_0x49809d[_0x8e8483];return _0x3ec623;},_0x8e84(_0x1ab2fc,_0x57621b);}import{getTranslation as _0x48ba43}from'../utils/common-translations.js';export default class O extends _0x4968c4{static get[_0x2d43a4(0x18b)](){const _0x57b727=_0x2d43a4;return _0x57b727(0x1b6);}constructor(_0x2815c1){const _0x275586=_0x2d43a4;super(_0x2815c1),_0x2815c1[_0x275586(0x1a5)][_0x275586(0x1ac)](_0x275586(0x19f))||_0x2815c1[_0x275586(0x1a5)][_0x275586(0x1b4)](_0x275586(0x19f),{'model':_0x275586(0x1ad),'max_tokens_to_sample':0x7d0,'temperature':0x1,'top_p':0x1,'top_k':0xfa,'anthropic_version':_0x275586(0x1c2),'stream':!0x0}),this[_0x275586(0x18e)]=_0x2815c1[_0x275586(0x1a5)][_0x275586(0x1ac)](_0x275586(0x1b8)),this[_0x275586(0x193)]=_0x2815c1[_0x275586(0x1a5)][_0x275586(0x1ac)](_0x275586(0x1d2)),this[_0x275586(0x1c1)]=_0x2815c1[_0x275586(0x1a5)][_0x275586(0x1ac)](_0x275586(0x1dc)),this[_0x275586(0x19c)]=_0x2815c1[_0x275586(0x1a5)][_0x275586(0x1ac)](_0x275586(0x19f));}async[_0x2d43a4(0x1a6)]({query:_0x2026d1,context:_0x18f78f,onData:_0x45e4d5,actionId:_0xedf73e}){const _0x374f7a=_0x2d43a4,{model:_0x180876,stream:_0x4b5bf3,..._0x443989}=await this[_0x374f7a(0x18f)](this[_0x374f7a(0x19c)],_0xedf73e),_0x5a989a={'prompt':await this[_0x374f7a(0x1ce)](_0x2026d1,_0x18f78f,_0x180876,_0xedf73e),..._0x443989};this[_0x374f7a(0x18e)]?await this[_0x374f7a(0x1c0)](_0x5a989a,_0x180876,_0x4b5bf3,_0x45e4d5,_0xedf73e):await this[_0x374f7a(0x194)](_0x5a989a,_0x180876,_0x4b5bf3,_0x45e4d5);}async[_0x2d43a4(0x1ce)](_0x59255d,_0x144caa,_0x1fd628,_0x23970d){const _0x383fa0=_0x2d43a4;let _0x38c6cf,_0x555439;return _0x144caa?(_0x38c6cf=_0x383fa0(0x18d),_0x555439=_0x383fa0(0x1c6)+_0x59255d+_0x383fa0(0x1cf)+_0x144caa):(_0x38c6cf=_0x383fa0(0x1db),_0x555439=_0x59255d),_0x383fa0(0x19d)==this[_0x383fa0(0x1d8)](_0x1fd628)?_0x383fa0(0x1cb)+_0x38c6cf+_0x383fa0(0x1b7)+_0x555439+_0x383fa0(0x1b3):_0x383fa0(0x1b0)+_0x38c6cf+'\x0a'+_0x555439+_0x383fa0(0x18c);}[_0x2d43a4(0x1d8)](_0x163abf){const _0xff10e6=_0x2d43a4;if(/^anthropic\.claude/[_0xff10e6(0x1a4)](_0x163abf))return _0xff10e6(0x1ca);if(/^ai21\.j2/[_0xff10e6(0x1a4)](_0x163abf))return _0xff10e6(0x1a1);if(/^cohere\.command/[_0xff10e6(0x1a4)](_0x163abf))return _0xff10e6(0x1a2);if(/^meta\.llama/[_0xff10e6(0x1a4)](_0x163abf))return _0xff10e6(0x19d);throw new _0x4ef70d(_0x48ba43(this[_0xff10e6(0x1d9)][_0xff10e6(0x1d6)],_0xff10e6(0x190),_0x163abf));}async[_0x2d43a4(0x1c0)](_0x35cb3c,_0x1ac02e,_0x479021,_0x4f9784,_0x4e836e){const _0x17ad8d=_0x2d43a4,_0x1bf8ba={'method':_0x17ad8d(0x1aa),'headers':await this[_0x17ad8d(0x1a8)](this[_0x17ad8d(0x1c1)],_0x4e836e),'body':JSON[_0x17ad8d(0x19a)]({..._0x35cb3c,'model':_0x1ac02e,'stream':_0x479021}),'signal':this[_0x17ad8d(0x1c8)][_0x17ad8d(0x1a0)]},_0x31de27=await fetch(this[_0x17ad8d(0x18e)],_0x1bf8ba);_0x479021?await this[_0x17ad8d(0x1a9)](_0x31de27,_0x1ac02e,_0x4f9784):await this[_0x17ad8d(0x1b9)](_0x31de27,_0x1ac02e,_0x4f9784);}async[_0x2d43a4(0x194)](_0x3f91fe,_0x3a49e5,_0x589804,_0x193213){const _0x3c8180=_0x2d43a4,_0xa00e79=new _0x3ec238(this[_0x3c8180(0x193)]),_0x1afcb4={'body':JSON[_0x3c8180(0x19a)](_0x3f91fe),'contentType':_0x3c8180(0x1dd),'accept':_0x3c8180(0x1dd),'modelId':_0x3a49e5};let _0x17c8bf;if(_0x589804){const _0x25953f=new _0x375b02(_0x1afcb4);_0x17c8bf=await _0xa00e79[_0x3c8180(0x1bd)](_0x25953f,{'abortSignal':this[_0x3c8180(0x1c8)][_0x3c8180(0x1a0)]}),await this[_0x3c8180(0x1d1)](_0x17c8bf,_0x3a49e5,_0x193213);}else{const _0x4db3c7=new _0x41cb08(_0x1afcb4);_0x17c8bf=await _0xa00e79[_0x3c8180(0x1bd)](_0x4db3c7,{'abortSignal':this[_0x3c8180(0x1c8)][_0x3c8180(0x1a0)]}),await this[_0x3c8180(0x1b9)](_0x17c8bf,_0x3a49e5,_0x193213);}}async[_0x2d43a4(0x1d1)](_0x2fc005,_0x160fac,_0x290c1d){const _0x399b18=_0x2d43a4,_0x483991=_0x2fc005[_0x399b18(0x192)],_0x146a88=new TextDecoder(_0x399b18(0x1d3));let _0x5f0529='';for await(const _0x1d4738 of _0x483991)if(_0x1d4738[_0x399b18(0x198)]){const _0x43d54c=_0x146a88[_0x399b18(0x19b)](_0x1d4738[_0x399b18(0x198)][_0x399b18(0x1c3)]),_0x50fa01=JSON[_0x399b18(0x197)](_0x43d54c);_0x5f0529+=this[_0x399b18(0x19e)](_0x50fa01,_0x160fac),_0x290c1d(_0x5f0529);}return Promise[_0x399b18(0x1c9)]();}async[_0x2d43a4(0x1a9)](_0x2df95a,_0x4abaf0,_0x1b80a2){const _0x363bda=_0x2d43a4,_0x24a3c5=_0x2df95a[_0x363bda(0x192)],_0x3a7da2=new TextDecoder(_0x363bda(0x1d3)),_0x44f671=_0x24a3c5[_0x363bda(0x199)]();let _0x56a290='',_0x108071='',_0x20b2a8=!0x1;for(;!_0x20b2a8;){const {done:_0x331574,value:_0xe62bb1}=await _0x44f671[_0x363bda(0x1b5)]();if(_0x20b2a8=_0x331574,_0x20b2a8)break;const _0x50a66e=(_0x56a290+_0x3a7da2[_0x363bda(0x19b)](_0xe62bb1))[_0x363bda(0x1ae)]('\x0a')[_0x363bda(0x1be)](_0x24c902=>{const _0x3926c0=_0x363bda;try{return _0x56a290='',JSON[_0x3926c0(0x197)](_0x24c902);}catch(_0x4f5026){return _0x56a290=_0x24c902,null;}})[_0x363bda(0x1b2)](_0x1fd493=>null!==_0x1fd493);_0x50a66e[_0x363bda(0x1ba)]&&(_0x108071+=_0x50a66e[_0x363bda(0x1be)](_0x1cc972=>this[_0x363bda(0x19e)](_0x1cc972,_0x4abaf0))[_0x363bda(0x1c7)](''),_0x1b80a2(_0x108071));}return Promise[_0x363bda(0x1c9)]();}async[_0x2d43a4(0x1b9)](_0x216a4c,_0x1c3af7,_0x42cc2e){const _0x4ab36a=_0x2d43a4;let _0x2b740e;return _0x2b740e=_0x216a4c instanceof Response?await _0x216a4c[_0x4ab36a(0x1af)]():JSON[_0x4ab36a(0x197)](Buffer[_0x4ab36a(0x1d4)](_0x216a4c[_0x4ab36a(0x192)])[_0x4ab36a(0x1d0)](_0x4ab36a(0x196))),(_0x42cc2e(this[_0x4ab36a(0x19e)](_0x2b740e,_0x1c3af7)),Promise[_0x4ab36a(0x1c9)]());}[_0x2d43a4(0x19e)](_0x5c0a38,_0x10a1fd){const _0x4b26a9=_0x2d43a4;switch(this[_0x4b26a9(0x1d8)](_0x10a1fd)){case _0x4b26a9(0x1ca):return _0x5c0a38[_0x4b26a9(0x1bc)];case _0x4b26a9(0x1a1):return _0x5c0a38[_0x4b26a9(0x1cd)][0x0][_0x4b26a9(0x1bb)][_0x4b26a9(0x1a7)];case _0x4b26a9(0x1a2):return _0x5c0a38[_0x4b26a9(0x1d7)][0x0][_0x4b26a9(0x1a7)];case _0x4b26a9(0x19d):return _0x5c0a38[_0x4b26a9(0x1c5)];}}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
|
|
23
|
+
const _0x38a58b=_0x35b4;(function(_0x4eb4e5,_0x2839f1){const _0x15ea13=_0x35b4,_0x10ed93=_0x4eb4e5();while(!![]){try{const _0x219b04=-parseInt(_0x15ea13(0x144))/0x1*(parseInt(_0x15ea13(0x140))/0x2)+-parseInt(_0x15ea13(0x13f))/0x3+parseInt(_0x15ea13(0x164))/0x4+parseInt(_0x15ea13(0x15a))/0x5+-parseInt(_0x15ea13(0x129))/0x6+-parseInt(_0x15ea13(0x143))/0x7+parseInt(_0x15ea13(0x12a))/0x8*(parseInt(_0x15ea13(0x14e))/0x9);if(_0x219b04===_0x2839f1)break;else _0x10ed93['push'](_0x10ed93['shift']());}catch(_0x1f28d2){_0x10ed93['push'](_0x10ed93['shift']());}}}(_0x5025,0xc16cb));import{default as _0x4980af}from'./aitextadapter.js';import{AIRequestError as _0x5f31bf}from'./aiadapter.js';import{getTranslation as _0x34147c}from'../utils/common-translations.js';function _0x35b4(_0x2ef53d,_0x45a5b6){const _0x50259b=_0x5025();return _0x35b4=function(_0x35b479,_0x26e13a){_0x35b479=_0x35b479-0x124;let _0x58abcf=_0x50259b[_0x35b479];return _0x58abcf;},_0x35b4(_0x2ef53d,_0x45a5b6);}export default class H extends _0x4980af{static get[_0x38a58b(0x159)](){const _0x2740cb=_0x38a58b;return _0x2740cb(0x130);}constructor(_0x1e7e82){const _0x45f890=_0x38a58b;super(_0x1e7e82),_0x1e7e82[_0x45f890(0x131)][_0x45f890(0x133)](_0x45f890(0x156),_0x45f890(0x12b)),_0x1e7e82[_0x45f890(0x131)][_0x45f890(0x13a)](_0x45f890(0x152))||_0x1e7e82[_0x45f890(0x131)][_0x45f890(0x133)](_0x45f890(0x152),{'model':_0x45f890(0x148),'max_tokens':0x7d0,'temperature':0x1,'top_p':0x1,'stream':!0x0}),this[_0x45f890(0x137)]=_0x1e7e82[_0x45f890(0x131)][_0x45f890(0x13a)](_0x45f890(0x156)),this[_0x45f890(0x132)]=_0x1e7e82[_0x45f890(0x131)][_0x45f890(0x13a)](_0x45f890(0x155))||{},this[_0x45f890(0x151)]=_0x1e7e82[_0x45f890(0x131)][_0x45f890(0x13a)](_0x45f890(0x152));}async[_0x38a58b(0x12f)]({query:_0x27f094,context:_0x1eccc9,onData:_0xfed05f,actionId:_0x125933}){const _0x19c49d=_0x38a58b,_0x51870e=this[_0x19c49d(0x145)][_0x19c49d(0x146)],_0x31de8c=await this[_0x19c49d(0x154)](_0x27f094,_0x1eccc9,_0x125933),_0x557f22=await this[_0x19c49d(0x126)](this[_0x19c49d(0x132)],_0x125933),_0xb36415=await this[_0x19c49d(0x14a)](this[_0x19c49d(0x151)],_0x125933),_0x23695c={'messages':_0x31de8c,..._0xb36415},_0xcd75b3={'method':_0x19c49d(0x157),'headers':_0x557f22,'body':JSON[_0x19c49d(0x162)](_0x23695c),'signal':this[_0x19c49d(0x138)][_0x19c49d(0x168)]},_0x65d0d0=await fetch(this[_0x19c49d(0x137)],_0xcd75b3);if(_0x65d0d0['ok'])return _0xb36415[_0x19c49d(0x135)]?await this[_0x19c49d(0x147)](_0x65d0d0,_0xfed05f):await this[_0x19c49d(0x15e)](_0x65d0d0,_0xfed05f),Promise[_0x19c49d(0x13d)]();{const _0x1c8323=await _0x65d0d0[_0x19c49d(0x167)]();return _0x1c8323[_0x19c49d(0x158)](_0x19c49d(0x13e))?Promise[_0x19c49d(0x165)](new _0x5f31bf(_0x34147c(_0x51870e,_0x19c49d(0x134)))):_0x1c8323[_0x19c49d(0x158)](_0x19c49d(0x15c))?Promise[_0x19c49d(0x165)](new _0x5f31bf(_0x34147c(_0x51870e,_0x19c49d(0x128)))):Promise[_0x19c49d(0x165)](new Error(_0x1c8323));}}async[_0x38a58b(0x154)](_0x270fd3,_0x3d8037,_0x39152c){const _0x4c9001=_0x38a58b;let _0x3f9607,_0x5e42b1;return _0x3d8037?(_0x3f9607=_0x4c9001(0x136),_0x5e42b1=_0x4c9001(0x142)+_0x270fd3+_0x4c9001(0x150)+_0x3d8037):(_0x3f9607=_0x4c9001(0x163),_0x5e42b1=_0x270fd3),[{'role':_0x4c9001(0x14f),'content':_0x3f9607},{'role':_0x4c9001(0x139),'content':_0x5e42b1}];}async[_0x38a58b(0x147)](_0x133c91,_0x58ff9c){const _0x121e02=_0x38a58b,_0x8dd726=_0x133c91[_0x121e02(0x12d)][_0x121e02(0x149)](),_0x4f1141=new TextDecoder();let _0x57a28b='',_0x99629f='',_0x49b9b3='',_0xba6f0e=!0x1;for(;!_0xba6f0e;){const {done:_0x1d1dc1,value:_0x4cedbc}=await _0x8dd726[_0x121e02(0x12c)](),_0x43a7d4=_0x57a28b+_0x4f1141[_0x121e02(0x15b)](_0x4cedbc);let _0x1e1102='';_0xba6f0e=_0x1d1dc1;try{_0x1e1102=this[_0x121e02(0x141)](_0x43a7d4),_0x57a28b='';}catch(_0x1f17de){_0x57a28b=_0x43a7d4;continue;}_0x99629f+=_0x1e1102,!_0xba6f0e&&this[_0x121e02(0x12e)](_0x99629f)||_0x99629f&&(_0x49b9b3+=_0x99629f,_0x99629f='',_0x58ff9c(_0x49b9b3));}return Promise[_0x121e02(0x13d)]();}async[_0x38a58b(0x15e)](_0x12461b,_0x33f8b2){const _0x27f797=_0x38a58b;return _0x33f8b2((await _0x12461b[_0x27f797(0x153)]())[_0x27f797(0x13c)][0x0][_0x27f797(0x166)][_0x27f797(0x124)]),Promise[_0x27f797(0x13d)]();}[_0x38a58b(0x12e)](_0x3353b){const _0x2f07b1=_0x38a58b,_0x4ca896=_0x3353b[_0x2f07b1(0x15f)]('<')[_0x2f07b1(0x15d)]!==_0x3353b[_0x2f07b1(0x15f)]('>')[_0x2f07b1(0x15d)],_0x5be27b=_0x3353b[_0x2f07b1(0x15d)]<0x1e;return _0x4ca896&&_0x5be27b;}[_0x38a58b(0x141)](_0x1f2220){const _0x302699=_0x38a58b;return _0x1f2220[_0x302699(0x15f)](/\n(?![^{]*\})/g)[_0x302699(0x14c)](_0x5bbde1=>_0x5bbde1[_0x302699(0x160)](_0x302699(0x14d),''))[_0x302699(0x14b)](_0x1d1cf8=>_0x1d1cf8&&_0x1d1cf8[_0x302699(0x15d)]>0x0&&_0x302699(0x125)!==_0x1d1cf8)[_0x302699(0x14c)](_0x1e9cd5=>{const _0x6f12f2=_0x302699,{choices:_0x29ddf0}=JSON[_0x6f12f2(0x161)](_0x1e9cd5);if(_0x29ddf0[0x0]&&_0x29ddf0[0x0][_0x6f12f2(0x127)]&&_0x29ddf0[0x0][_0x6f12f2(0x127)][_0x6f12f2(0x124)])return _0x29ddf0[0x0][_0x6f12f2(0x127)][_0x6f12f2(0x124)];})[_0x302699(0x14b)](_0x2c2818=>_0x2c2818)[_0x302699(0x13b)]('');}}function _0x5025(){const _0x430ef2=['4WQOqxH','editor','locale','_readStreamableResponse','gpt-3.5-turbo','getReader','_prepareRequestParameters','filter','map','data:\x20','61794kSwVVs','system','\x0aYou\x20must\x20keep\x20the\x20text\x20formatting.\x0a\x0aContent:\x0a','_requestParameters','ai.openAI.requestParameters','json','prepareMessages','ai.openAI.requestHeaders','ai.openAI.apiUrl','POST','includes','pluginName','5727925sffzLm','decode','Moderation','length','_readStaticResponse','split','replace','parse','stringify','Your\x20task\x20is\x20to\x20generate\x20HTML\x20content\x20accordingly\x20to\x20the\x20given\x20instruction.\x20Never\x20include\x20<img>\x20tag\x20in\x20your\x20response\x20even\x20if\x20asked\x20for.\x20Your\x20answer\x20must\x20be\x20a\x20well-structured\x20and\x20properly\x20formatted\x20HTML\x20code.\x20Answer\x20only\x20with\x20the\x20generated\x20HTML\x20content.\x20Do\x20not\x20add\x20any\x20additional\x20remarks\x20or\x20notes.\x20Do\x20not\x20act\x20like\x20a\x20chatbot\x20or\x20a\x20real\x20person.','514556GZtMZm','reject','message','text','signal','content','[DONE]','_prepareRequestHeaders','delta','AI_ERROR_MODERATION','3570270ubmuuN','3448ffaLcw','https://api.openai.com/v1/chat/completions','read','body','_isBufferIncomplete','sendRequest','OpenAITextAdapter','config','_requestHeaders','define','AI_ERROR_CONTEXT_LENGTH','stream','Your\x20task\x20is\x20to\x20execute\x20the\x20instruction\x20using\x20the\x20provided\x20HTML\x20content.\x20Follow\x20the\x20instruction\x20closely.\x20Your\x20answer\x20must\x20be\x20a\x20properly\x20formatted\x20HTML\x20code.\x20Do\x20not\x20add\x20any\x20additional\x20remarks\x20or\x20notes.\x20Do\x20not\x20act\x20like\x20a\x20chatbot\x20or\x20a\x20real\x20person.','_apiUrl','abortController','user','get','join','choices','resolve','context_length_exceeded','3950460pYvnRa','524228HBOqox','_cleanUpData','Instruction:\x0a','3366174rwSvVT'];_0x5025=function(){return _0x430ef2;};return _0x5025();}
|
package/src/aiassistant.d.ts
CHANGED
|
@@ -27,6 +27,14 @@ export default class AIAssistant extends Plugin {
|
|
|
27
27
|
* @inheritDoc
|
|
28
28
|
*/
|
|
29
29
|
static get pluginName(): "AIAssistant";
|
|
30
|
+
/**
|
|
31
|
+
* @inheritDoc
|
|
32
|
+
*/
|
|
33
|
+
static get isOfficialPlugin(): true;
|
|
34
|
+
/**
|
|
35
|
+
* @inheritDoc
|
|
36
|
+
*/
|
|
37
|
+
static get isPremiumPlugin(): true;
|
|
30
38
|
/**
|
|
31
39
|
* @inheritDoc
|
|
32
40
|
*/
|
|
@@ -72,6 +80,9 @@ export interface AIAssistantConfig {
|
|
|
72
80
|
*
|
|
73
81
|
* Setting this property will overwrite the default list of predefined commands.
|
|
74
82
|
*
|
|
83
|
+
* You can avoid creating any groups by providing a list of command definitions directly. In this case,
|
|
84
|
+
* commands will render as a flat list in the user interface.
|
|
85
|
+
*
|
|
75
86
|
* The default configuration is as follows. It can be obtained through {@link ~getDefaultCommands}:
|
|
76
87
|
*
|
|
77
88
|
* ```json
|
|
@@ -225,7 +236,7 @@ export interface AIAssistantConfig {
|
|
|
225
236
|
* } ]
|
|
226
237
|
* ```
|
|
227
238
|
*/
|
|
228
|
-
commands?: Array<GroupDefinition>;
|
|
239
|
+
commands?: Array<GroupDefinition> | Array<CommandDefinition>;
|
|
229
240
|
/**
|
|
230
241
|
* A list of additional AI commands groups definitions that will extend
|
|
231
242
|
* {@link module:ai/aiassistant~AIAssistantConfig#commands default commands}.
|
package/src/aiassistant.js
CHANGED
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x52608b=_0x5c23;(function(_0xa7b896,_0x5c7d9b){const _0x20e55f=_0x5c23,_0x22707f=_0xa7b896();while(!![]){try{const _0x2d5491=-parseInt(_0x20e55f(0x1b1))/0x1+parseInt(_0x20e55f(0x1b7))/0x2*(-parseInt(_0x20e55f(0x196))/0x3)+-parseInt(_0x20e55f(0x1b9))/0x4*(parseInt(_0x20e55f(0x181))/0x5)+-parseInt(_0x20e55f(0x1b4))/0x6+parseInt(_0x20e55f(0x198))/0x7*(-parseInt(_0x20e55f(0x1a4))/0x8)+-parseInt(_0x20e55f(0x17e))/0x9+parseInt(_0x20e55f(0x166))/0xa*(parseInt(_0x20e55f(0x1b2))/0xb);if(_0x2d5491===_0x5c7d9b)break;else _0x22707f['push'](_0x22707f['shift']());}catch(_0x40bb7c){_0x22707f['push'](_0x22707f['shift']());}}}(_0x4d3b,0x7015d));import{CKEditorError as _0x1051de}from'ckeditor5/src/utils.js';import{Plugin as _0x181211}from'ckeditor5/src/core.js';import _0x502a8b from'./aiassistantui.js';function _0x4d3b(){const _0x5e09f5=['_licenseKeyCheckInterval','licenseKey','Business','editor','makeLonger','push','direct','Hindi','Fix\x20spelling\x20mistakes,\x20use\x20proper\x20grammar\x20and\x20apply\x20good\x20writing\x20practices.\x20Do\x20not\x20lose\x20the\x20original\x20meaning.','ai.aiAssistant.extraCommandGroups','Make\x20shorter','Improve\x20using\x20friendly,\x20comforting\x20language,\x20to\x20convey\x20understanding\x20and\x20empathy.','Arabic','includes','journalism','Friendly','translateChinese','Direct','Simplify\x20language','friendly','Start\x20with\x20the\x20provided\x20content\x20and\x20write\x20at\x20the\x20end\x20of\x20it\x20continuing\x20this\x20topic.\x20Keep\x20the\x20added\x20part\x20short.','Casual','Make\x20longer','Summarize\x20this\x20content\x20into\x20one\x20paragraph\x20of\x20text.\x20Include\x20only\x20the\x20key\x20ideas\x20and\x20conclusions.\x20Keep\x20it\x20short.\x20Do\x20not\x20keep\x20original\x20text\x20formatting.','Translate\x20the\x20content\x20to\x20Arabic\x20language.','Rewrite\x20this\x20content\x20as\x20a\x20poem\x20using\x20poetic\x20techniques\x20without\x20losing\x20the\x20original\x20meaning.','translateSpanish','translateFrench','poetic','filter','French','126310NgeVWX','Change\x20tone','Improve\x20using\x20direct\x20language,\x20using\x20only\x20the\x20essential\x20information.','changeStyle','Translate\x20the\x20content\x20to\x20German\x20language.','Portuguese','business','Poetic','aiLicenseKeyTrialLimit:operations','Improve\x20writing','Continue','Improve\x20using\x20polished,\x20formal,\x20and\x20respectful\x20language\x20to\x20convey\x20professional\x20expertise\x20and\x20competence.','Edit\x20or\x20review','Legal','simplifyLanguage','Translate\x20the\x20content\x20to\x20Portuguese\x20language.','pluginName','ai-trial-license-key-reached-limit-changes','Generate\x20from\x20selection','improveWriting','Rewrite\x20this\x20content\x20as\x20a\x20business\x20professional\x20with\x20formal\x20language.','editOrReview','Translate\x20the\x20content\x20to\x20Spanish\x20language.','translatePortuguese','6826878jQQhIi','ai-invalid-license-key','Improve\x20using\x20casual,\x20informal\x20language\x20to\x20convey\x20a\x20casual\x20conversation\x20with\x20a\x20real\x20person.','716995hhPYGS','ai.aiAssistant.removeCommands','aiLicenseKeyValid','Simplified\x20Chinese','requires','continue','Improve\x20using\x20compelling,\x20optimistic\x20language\x20to\x20convey\x20confidence\x20in\x20the\x20writing.','translateGerman','destroy','groupId','find','Confident','Summarize','AIAssistant','commands','German','makeShorter','You\x20are\x20using\x20the\x20trial\x20version\x20of\x20CKEditor\x205\x20ai\x20plugin\x20with\x20limited\x20usage.\x20Make\x20sure\x20you\x20will\x20not\x20use\x20it\x20in\x20the\x20production\x20environment.','Simplify\x20the\x20writing\x20style\x20of\x20this\x20content\x20and\x20reduce\x20the\x20complexity,\x20so\x20that\x20the\x20content\x20is\x20easy\x20to\x20understand.','changeTone','Remove\x20any\x20repetitive,\x20redundant,\x20or\x20non-essential\x20writing\x20in\x20this\x20content\x20without\x20changing\x20the\x20meaning\x20or\x20losing\x20any\x20key\x20information.','18QsjLMf','legal','63xVkGIw','confident','info','locale','aiLicenseKeyTrial','Translate\x20the\x20content\x20to\x20Hindi\x20language.','casual','forEach','Professional','Journalism','translateHindi','Rewrite\x20this\x20content\x20as\x20a\x20legal\x20professional\x20using\x20valid\x20legal\x20terminology.','677272MiYuEm','translate','define','Improve\x20this\x20content\x20by\x20using\x20descriptive\x20language\x20and\x20inserting\x20more\x20information\x20and\x20more\x20detailed\x20explanations.','summarize','Translate','English','init','set','get','professional','config','Translate\x20the\x20content\x20to\x20English\x20language.','894935pcBaUc','3839RWqBVw','generate','5332494HWMXpM','aiLicenseKeyInvalid','ai.aiAssistant.commands','71588igikGw','Translate\x20the\x20content\x20to\x20French\x20language.','12BPRDuk','Change\x20style','Rewrite\x20this\x20content\x20as\x20a\x20journalist\x20using\x20engaging\x20language\x20to\x20convey\x20the\x20importance\x20of\x20the\x20information.','Spanish','Translate\x20the\x20content\x20to\x20Simplified\x20Chinese\x20language.','concat','translateArabic','translateEnglish'];_0x4d3b=function(){return _0x5e09f5;};return _0x4d3b();}import _0x2ffe36 from'./aiassistantediting.js';import{getTranslation as _0x301871}from'./utils/common-translations.js';export default class r extends _0x181211{static get[_0x52608b(0x185)](){return[_0x502a8b,_0x2ffe36];}static get[_0x52608b(0x176)](){const _0x19ef9f=_0x52608b;return _0x19ef9f(0x18e);}constructor(_0x47b4f4){const _0x23332b=_0x52608b;super(_0x47b4f4);const _0x3bd876=_0x47b4f4[_0x23332b(0x1af)];_0x3bd876[_0x23332b(0x1a6)](_0x23332b(0x1b6),getDefaultCommands(_0x47b4f4[_0x23332b(0x19b)])),_0x3bd876[_0x23332b(0x1a6)](_0x23332b(0x1ca),[]),_0x3bd876[_0x23332b(0x1a6)](_0x23332b(0x182),[]);const _0x34e6ce=_0x3bd876[_0x23332b(0x1ad)](_0x23332b(0x1b6)),_0xf0cde1=_0x3bd876[_0x23332b(0x1ad)](_0x23332b(0x1ca)),_0x1e972b=_0x3bd876[_0x23332b(0x1ad)](_0x23332b(0x182));_0xf0cde1[_0x23332b(0x19f)](_0x14454f=>{const _0x16c60c=_0x23332b,_0x57a301=_0x34e6ce[_0x16c60c(0x18b)](_0x52e9e4=>_0x52e9e4[_0x16c60c(0x18a)]===_0x14454f[_0x16c60c(0x18a)]);_0x57a301?_0x57a301[_0x16c60c(0x18f)]=_0x57a301[_0x16c60c(0x18f)][_0x16c60c(0x1be)](_0x14454f[_0x16c60c(0x18f)]):_0x34e6ce[_0x16c60c(0x1c6)](_0x14454f);}),_0x34e6ce[_0x23332b(0x19f)](_0x5e62f0=>{const _0x5a16f8=_0x23332b;_0x5e62f0[_0x5a16f8(0x18f)]=_0x5e62f0[_0x5a16f8(0x18f)][_0x5a16f8(0x164)](_0x4b7844=>!_0x1e972b[_0x5a16f8(0x1ce)](_0x4b7844['id']));}),_0x3bd876[_0x23332b(0x1ac)](_0x23332b(0x1b6),_0x34e6ce);}[_0x52608b(0x1ab)](){const _0x56c7be=_0x52608b,_0x296cc6=this[_0x56c7be(0x1c4)];this[_0x56c7be(0x1c2)]=_0x296cc6[_0x56c7be(0x1af)][_0x56c7be(0x1ad)](_0x56c7be(0x1c2)),this[_0x56c7be(0x1c1)]=setInterval(()=>{const _0x2f5a8e=_0x56c7be;let _0x5f2531;for(const _0x2a0312 in _0x296cc6){const _0x1c88fb=_0x2a0312,_0x46eba1=_0x296cc6[_0x1c88fb];if(_0x2f5a8e(0x19c)===_0x46eba1||_0x2f5a8e(0x1b5)===_0x46eba1||_0x2f5a8e(0x183)===_0x46eba1||_0x2f5a8e(0x16e)===_0x46eba1){delete _0x296cc6[_0x1c88fb],_0x5f2531=_0x46eba1;break;}}if(_0x2f5a8e(0x1b5)===_0x5f2531)throw clearInterval(this[_0x2f5a8e(0x1c1)]),new _0x1051de(_0x2f5a8e(0x17f),null);if(_0x2f5a8e(0x19c)===_0x5f2531&&console[_0x2f5a8e(0x19a)](_0x2f5a8e(0x192)),_0x2f5a8e(0x16e)===_0x5f2531)throw clearInterval(this[_0x2f5a8e(0x1c1)]),new _0x1051de(_0x2f5a8e(0x177),null);_0x2f5a8e(0x183)===_0x5f2531&&clearInterval(this[_0x2f5a8e(0x1c1)]);},0x3e8);}[_0x52608b(0x189)](){const _0x35ca7a=_0x52608b;this[_0x35ca7a(0x1c1)]&&clearInterval(this[_0x35ca7a(0x1c1)]);}}function _0x5c23(_0x5435ca,_0x581f74){const _0x4d3b83=_0x4d3b();return _0x5c23=function(_0x5c23b3,_0x43ecab){_0x5c23b3=_0x5c23b3-0x161;let _0x3d3257=_0x4d3b83[_0x5c23b3];return _0x3d3257;},_0x5c23(_0x5435ca,_0x581f74);}export function getDefaultCommands(_0x3c562d){const _0x1f0d7b=_0x52608b;return[{'groupId':_0x1f0d7b(0x17b),'groupLabel':_0x301871(_0x3c562d,_0x1f0d7b(0x172)),'commands':[{'id':_0x1f0d7b(0x179),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x16f)),'prompt':_0x1f0d7b(0x1c9)},{'id':_0x1f0d7b(0x191),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1cb)),'prompt':_0x1f0d7b(0x195)},{'id':_0x1f0d7b(0x1c5),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1d7)),'prompt':_0x1f0d7b(0x1a7)},{'id':_0x1f0d7b(0x174),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1d3)),'prompt':_0x1f0d7b(0x193)}]},{'groupId':_0x1f0d7b(0x1b3),'groupLabel':_0x301871(_0x3c562d,_0x1f0d7b(0x178)),'commands':[{'id':_0x1f0d7b(0x1a8),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x18d)),'prompt':_0x1f0d7b(0x1d8)},{'id':_0x1f0d7b(0x186),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x170)),'prompt':_0x1f0d7b(0x1d5)}]},{'groupId':_0x1f0d7b(0x194),'groupLabel':_0x301871(_0x3c562d,_0x1f0d7b(0x167)),'commands':[{'id':_0x1f0d7b(0x1ae),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1a0)),'prompt':_0x1f0d7b(0x171)},{'id':_0x1f0d7b(0x19e),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1d6)),'prompt':_0x1f0d7b(0x180)},{'id':_0x1f0d7b(0x1c7),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1d2)),'prompt':_0x1f0d7b(0x168)},{'id':_0x1f0d7b(0x199),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x18c)),'prompt':_0x1f0d7b(0x187)},{'id':_0x1f0d7b(0x1d4),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1d0)),'prompt':_0x1f0d7b(0x1cc)}]},{'groupId':_0x1f0d7b(0x169),'groupLabel':_0x301871(_0x3c562d,_0x1f0d7b(0x1ba)),'commands':[{'id':_0x1f0d7b(0x16c),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1c3)),'prompt':_0x1f0d7b(0x17a)},{'id':_0x1f0d7b(0x197),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x173)),'prompt':_0x1f0d7b(0x1a3)},{'id':_0x1f0d7b(0x1cf),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1a1)),'prompt':_0x1f0d7b(0x1bb)},{'id':_0x1f0d7b(0x163),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x16d)),'prompt':_0x1f0d7b(0x1da)}]},{'groupId':_0x1f0d7b(0x1a5),'groupLabel':_0x301871(_0x3c562d,_0x1f0d7b(0x1a9)),'commands':[{'id':_0x1f0d7b(0x1c0),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1aa)),'prompt':_0x1f0d7b(0x1b0)},{'id':_0x1f0d7b(0x161),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1bc)),'prompt':_0x1f0d7b(0x17c)},{'id':_0x1f0d7b(0x17d),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x16b)),'prompt':_0x1f0d7b(0x175)},{'id':_0x1f0d7b(0x188),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x190)),'prompt':_0x1f0d7b(0x16a)},{'id':_0x1f0d7b(0x162),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x165)),'prompt':_0x1f0d7b(0x1b8)},{'id':_0x1f0d7b(0x1d1),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x184)),'prompt':_0x1f0d7b(0x1bd)},{'id':_0x1f0d7b(0x1a2),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1c8)),'prompt':_0x1f0d7b(0x19d)},{'id':_0x1f0d7b(0x1bf),'label':_0x301871(_0x3c562d,_0x1f0d7b(0x1cd)),'prompt':_0x1f0d7b(0x1d9)}]}];}
|
|
23
|
+
const _0x3422df=_0x31b7;(function(_0x5e3f75,_0x88d79d){const _0x4d427e=_0x31b7,_0x39be21=_0x5e3f75();while(!![]){try{const _0x5a4132=-parseInt(_0x4d427e(0x13c))/0x1+-parseInt(_0x4d427e(0xdd))/0x2+parseInt(_0x4d427e(0xd6))/0x3*(-parseInt(_0x4d427e(0x133))/0x4)+-parseInt(_0x4d427e(0x135))/0x5*(parseInt(_0x4d427e(0x107))/0x6)+parseInt(_0x4d427e(0xeb))/0x7+parseInt(_0x4d427e(0xff))/0x8+parseInt(_0x4d427e(0x106))/0x9;if(_0x5a4132===_0x88d79d)break;else _0x39be21['push'](_0x39be21['shift']());}catch(_0x1f6f55){_0x39be21['push'](_0x39be21['shift']());}}}(_0x1c31,0xaed7c));import{CKEditorError as _0x2273f3}from'ckeditor5/src/utils.js';import{Plugin as _0x98bb69}from'ckeditor5/src/core.js';import _0xa62153 from'./aiassistantui.js';import _0x4d7a36 from'./aiassistantediting.js';import{getTranslation as _0x43c268}from'./utils/common-translations.js';import{normalizeCommandsConfig as _0x40e6b3}from'./utils/normalizecommandsconfig.js';function _0x1c31(){const _0x1709be=['aiLicenseKeyValid','translateHindi','Change\x20tone','includes','aiLicenseKeyTrial','poetic','config','Edit\x20or\x20review','Translate\x20the\x20content\x20to\x20Hindi\x20language.','legal','Improve\x20using\x20direct\x20language,\x20using\x20only\x20the\x20essential\x20information.','simplifyLanguage','2170696nfICzg','English','Journalism','Simplify\x20language','ai.aiAssistant.commands','editor','Generate\x20from\x20selection','25809885rUkBtV','8141604RwLwMV','Summarize','Rewrite\x20this\x20content\x20as\x20a\x20business\x20professional\x20with\x20formal\x20language.','commands','translateEnglish','translatePortuguese','set','Casual','Improve\x20writing','ai-trial-license-key-reached-limit-changes','Rewrite\x20this\x20content\x20as\x20a\x20legal\x20professional\x20using\x20valid\x20legal\x20terminology.','Translate\x20the\x20content\x20to\x20English\x20language.','requires','Translate\x20the\x20content\x20to\x20Simplified\x20Chinese\x20language.','summarize','Improve\x20this\x20content\x20by\x20using\x20descriptive\x20language\x20and\x20inserting\x20more\x20information\x20and\x20more\x20detailed\x20explanations.','changeStyle','You\x20are\x20using\x20the\x20trial\x20version\x20of\x20CKEditor\x205\x20ai\x20plugin\x20with\x20limited\x20usage.\x20Make\x20sure\x20you\x20will\x20not\x20use\x20it\x20in\x20the\x20production\x20environment.','pluginName','find','Friendly','push','confident','Translate\x20the\x20content\x20to\x20German\x20language.','Rewrite\x20this\x20content\x20as\x20a\x20journalist\x20using\x20engaging\x20language\x20to\x20convey\x20the\x20importance\x20of\x20the\x20information.','business','Simplify\x20the\x20writing\x20style\x20of\x20this\x20content\x20and\x20reduce\x20the\x20complexity,\x20so\x20that\x20the\x20content\x20is\x20easy\x20to\x20understand.','Remove\x20any\x20repetitive,\x20redundant,\x20or\x20non-essential\x20writing\x20in\x20this\x20content\x20without\x20changing\x20the\x20meaning\x20or\x20losing\x20any\x20key\x20information.','French','professional','friendly','Hindi','concat','get','ai.aiAssistant.extraCommandGroups','Fix\x20spelling\x20mistakes,\x20use\x20proper\x20grammar\x20and\x20apply\x20good\x20writing\x20practices.\x20Do\x20not\x20lose\x20the\x20original\x20meaning.','Legal','isOfficialPlugin','direct','Translate\x20the\x20content\x20to\x20Arabic\x20language.','isPremiumPlugin','Translate\x20the\x20content\x20to\x20Spanish\x20language.','Translate\x20the\x20content\x20to\x20French\x20language.','Portuguese','23540lkuolo','makeShorter','5hOStdG','groupId','Summarize\x20this\x20content\x20into\x20one\x20paragraph\x20of\x20text.\x20Include\x20only\x20the\x20key\x20ideas\x20and\x20conclusions.\x20Keep\x20it\x20short.\x20Do\x20not\x20keep\x20original\x20text\x20formatting.','continue','Start\x20with\x20the\x20provided\x20content\x20and\x20write\x20at\x20the\x20end\x20of\x20it\x20continuing\x20this\x20topic.\x20Keep\x20the\x20added\x20part\x20short.','Spanish','German','1074720oeRqGL','generate','translateSpanish','Improve\x20using\x20friendly,\x20comforting\x20language,\x20to\x20convey\x20understanding\x20and\x20empathy.','info','aiLicenseKeyTrialLimit:operations','Rewrite\x20this\x20content\x20as\x20a\x20poem\x20using\x20poetic\x20techniques\x20without\x20losing\x20the\x20original\x20meaning.','Change\x20style','ai-invalid-license-key','translateGerman','init','Professional','Simplified\x20Chinese','journalism','translate','Confident','changeTone','translateArabic','makeLonger','Translate','3BIyiUW','Arabic','Make\x20shorter','locale','forEach','destroy','Poetic','1918746Tfwcnw','_licenseKeyCheckInterval','casual','Business','aiLicenseKeyInvalid','translateChinese','licenseKey','improveWriting','translateFrench','define','ai.aiAssistant.removeCommands','Improve\x20using\x20polished,\x20formal,\x20and\x20respectful\x20language\x20to\x20convey\x20professional\x20expertise\x20and\x20competence.','Continue','Improve\x20using\x20casual,\x20informal\x20language\x20to\x20convey\x20a\x20casual\x20conversation\x20with\x20a\x20real\x20person.','6817762DvyLCa','Improve\x20using\x20compelling,\x20optimistic\x20language\x20to\x20convey\x20confidence\x20in\x20the\x20writing.','Make\x20longer','editOrReview','filter','AIAssistant','Translate\x20the\x20content\x20to\x20Portuguese\x20language.','Direct'];_0x1c31=function(){return _0x1709be;};return _0x1c31();}function _0x31b7(_0x2ccbd8,_0x1fe511){const _0x1c3124=_0x1c31();return _0x31b7=function(_0x31b7af,_0x551888){_0x31b7af=_0x31b7af-0xcc;let _0x2ca068=_0x1c3124[_0x31b7af];return _0x2ca068;},_0x31b7(_0x2ccbd8,_0x1fe511);}export default class s extends _0x98bb69{static get[_0x3422df(0x113)](){return[_0xa62153,_0x4d7a36];}static get[_0x3422df(0x119)](){const _0x4c8fcf=_0x3422df;return _0x4c8fcf(0xf0);}static get[_0x3422df(0x12c)](){return!0x0;}static get[_0x3422df(0x12f)](){return!0x0;}constructor(_0x3c0fe3){const _0x563213=_0x3422df;super(_0x3c0fe3);const _0xdaabdf=_0x3c0fe3[_0x563213(0xf9)],_0xf28dd9=_0x3c0fe3[_0x563213(0xd9)];_0xdaabdf[_0x563213(0xe6)](_0x563213(0x103),getDefaultCommands(_0xf28dd9)),_0xdaabdf[_0x563213(0xe6)](_0x563213(0x129),[]),_0xdaabdf[_0x563213(0xe6)](_0x563213(0xe7),[]);const _0x40c8c8=_0x40e6b3(_0xdaabdf[_0x563213(0x128)](_0x563213(0x103)),_0xf28dd9),_0x1e08ea=_0xdaabdf[_0x563213(0x128)](_0x563213(0x129)),_0x31068e=_0xdaabdf[_0x563213(0x128)](_0x563213(0xe7));_0x1e08ea[_0x563213(0xda)](_0x3e0c9b=>{const _0x4a22b0=_0x563213,_0x2f1666=_0x40c8c8[_0x4a22b0(0x11a)](_0x292b98=>_0x292b98[_0x4a22b0(0x136)]===_0x3e0c9b[_0x4a22b0(0x136)]);_0x2f1666?_0x2f1666[_0x4a22b0(0x10a)]=_0x2f1666[_0x4a22b0(0x10a)][_0x4a22b0(0x127)](_0x3e0c9b[_0x4a22b0(0x10a)]):_0x40c8c8[_0x4a22b0(0x11c)](_0x3e0c9b);}),_0x40c8c8[_0x563213(0xda)](_0x1c9f4c=>{const _0x11f379=_0x563213;_0x1c9f4c[_0x11f379(0x10a)]=_0x1c9f4c[_0x11f379(0x10a)][_0x11f379(0xef)](_0x300255=>!_0x31068e[_0x11f379(0xf6)](_0x300255['id']));}),_0xdaabdf[_0x563213(0x10d)](_0x563213(0x103),_0x40c8c8);}[_0x3422df(0xcc)](){const _0xec4224=_0x3422df,_0x102048=this[_0xec4224(0x104)];this[_0xec4224(0xe3)]=_0x102048[_0xec4224(0xf9)][_0xec4224(0x128)](_0xec4224(0xe3)),this[_0xec4224(0xde)]=setInterval(()=>{const _0x4687d0=_0xec4224;let _0x2213ff;for(const _0x49e8db in _0x102048){const _0x6c0447=_0x49e8db,_0x161c47=_0x102048[_0x6c0447];if(_0x4687d0(0xf7)===_0x161c47||_0x4687d0(0xe1)===_0x161c47||_0x4687d0(0xf3)===_0x161c47||_0x4687d0(0x141)===_0x161c47){delete _0x102048[_0x6c0447],_0x2213ff=_0x161c47;break;}}if(_0x4687d0(0xe1)===_0x2213ff)throw clearInterval(this[_0x4687d0(0xde)]),new _0x2273f3(_0x4687d0(0x144),null);if(_0x4687d0(0xf7)===_0x2213ff&&console[_0x4687d0(0x140)](_0x4687d0(0x118)),_0x4687d0(0x141)===_0x2213ff)throw clearInterval(this[_0x4687d0(0xde)]),new _0x2273f3(_0x4687d0(0x110),null);_0x4687d0(0xf3)===_0x2213ff&&clearInterval(this[_0x4687d0(0xde)]);},0x3e8);}[_0x3422df(0xdb)](){const _0x39ec4c=_0x3422df;this[_0x39ec4c(0xde)]&&clearInterval(this[_0x39ec4c(0xde)]);}}export function getDefaultCommands(_0x272163){const _0x4383bd=_0x3422df;return[{'groupId':_0x4383bd(0xee),'groupLabel':_0x43c268(_0x272163,_0x4383bd(0xfa)),'commands':[{'id':_0x4383bd(0xe4),'label':_0x43c268(_0x272163,_0x4383bd(0x10f)),'prompt':_0x4383bd(0x12a)},{'id':_0x4383bd(0x134),'label':_0x43c268(_0x272163,_0x4383bd(0xd8)),'prompt':_0x4383bd(0x122)},{'id':_0x4383bd(0xd4),'label':_0x43c268(_0x272163,_0x4383bd(0xed)),'prompt':_0x4383bd(0x116)},{'id':_0x4383bd(0xfe),'label':_0x43c268(_0x272163,_0x4383bd(0x102)),'prompt':_0x4383bd(0x121)}]},{'groupId':_0x4383bd(0x13d),'groupLabel':_0x43c268(_0x272163,_0x4383bd(0x105)),'commands':[{'id':_0x4383bd(0x115),'label':_0x43c268(_0x272163,_0x4383bd(0x108)),'prompt':_0x4383bd(0x137)},{'id':_0x4383bd(0x138),'label':_0x43c268(_0x272163,_0x4383bd(0xe9)),'prompt':_0x4383bd(0x139)}]},{'groupId':_0x4383bd(0xd2),'groupLabel':_0x43c268(_0x272163,_0x4383bd(0xf5)),'commands':[{'id':_0x4383bd(0x124),'label':_0x43c268(_0x272163,_0x4383bd(0xcd)),'prompt':_0x4383bd(0xe8)},{'id':_0x4383bd(0xdf),'label':_0x43c268(_0x272163,_0x4383bd(0x10e)),'prompt':_0x4383bd(0xea)},{'id':_0x4383bd(0x12d),'label':_0x43c268(_0x272163,_0x4383bd(0xf2)),'prompt':_0x4383bd(0xfd)},{'id':_0x4383bd(0x11d),'label':_0x43c268(_0x272163,_0x4383bd(0xd1)),'prompt':_0x4383bd(0xec)},{'id':_0x4383bd(0x125),'label':_0x43c268(_0x272163,_0x4383bd(0x11b)),'prompt':_0x4383bd(0x13f)}]},{'groupId':_0x4383bd(0x117),'groupLabel':_0x43c268(_0x272163,_0x4383bd(0x143)),'commands':[{'id':_0x4383bd(0x120),'label':_0x43c268(_0x272163,_0x4383bd(0xe0)),'prompt':_0x4383bd(0x109)},{'id':_0x4383bd(0xfc),'label':_0x43c268(_0x272163,_0x4383bd(0x12b)),'prompt':_0x4383bd(0x111)},{'id':_0x4383bd(0xcf),'label':_0x43c268(_0x272163,_0x4383bd(0x101)),'prompt':_0x4383bd(0x11f)},{'id':_0x4383bd(0xf8),'label':_0x43c268(_0x272163,_0x4383bd(0xdc)),'prompt':_0x4383bd(0x142)}]},{'groupId':_0x4383bd(0xd0),'groupLabel':_0x43c268(_0x272163,_0x4383bd(0xd5)),'commands':[{'id':_0x4383bd(0x10b),'label':_0x43c268(_0x272163,_0x4383bd(0x100)),'prompt':_0x4383bd(0x112)},{'id':_0x4383bd(0x13e),'label':_0x43c268(_0x272163,_0x4383bd(0x13a)),'prompt':_0x4383bd(0x130)},{'id':_0x4383bd(0x10c),'label':_0x43c268(_0x272163,_0x4383bd(0x132)),'prompt':_0x4383bd(0xf1)},{'id':_0x4383bd(0x145),'label':_0x43c268(_0x272163,_0x4383bd(0x13b)),'prompt':_0x4383bd(0x11e)},{'id':_0x4383bd(0xe5),'label':_0x43c268(_0x272163,_0x4383bd(0x123)),'prompt':_0x4383bd(0x131)},{'id':_0x4383bd(0xe2),'label':_0x43c268(_0x272163,_0x4383bd(0xce)),'prompt':_0x4383bd(0x114)},{'id':_0x4383bd(0xf4),'label':_0x43c268(_0x272163,_0x4383bd(0x126)),'prompt':_0x4383bd(0xfb)},{'id':_0x4383bd(0xd3),'label':_0x43c268(_0x272163,_0x4383bd(0xd7)),'prompt':_0x4383bd(0x12e)}]}];}
|
|
@@ -15,6 +15,14 @@ export default class AIAssistantEditing extends Plugin {
|
|
|
15
15
|
* @inheritDoc
|
|
16
16
|
*/
|
|
17
17
|
static get pluginName(): "AIAssistantEditing";
|
|
18
|
+
/**
|
|
19
|
+
* @inheritDoc
|
|
20
|
+
*/
|
|
21
|
+
static get isOfficialPlugin(): true;
|
|
22
|
+
/**
|
|
23
|
+
* @inheritDoc
|
|
24
|
+
*/
|
|
25
|
+
static get isPremiumPlugin(): true;
|
|
18
26
|
/**
|
|
19
27
|
* @inheritDoc
|
|
20
28
|
*/
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x49ca75=_0x52ba;function _0x3548(){const _0x166d5b=['isContent','selection','isAtEnd','processor','insertContentBelow','insertContent','8DkNxdn','ai-ui','for','ck-fake-ai-selection','createPositionAfter','4469514UuCWnX','push','getLastPosition','markerToElement','updateMarker','pop','conversion','ck-ai-assistant-ui_theme','ck-fake-ai-selection_collapsed','canEditAt','getSelectedBlocks','config','addMarker','addClass','data','2343665RvutQR','schema','createRange','showFakeVisualSelection','AIAssistantEditing','createUIElement','has','end','toModel','hideFakeVisualSelection','document','start','init','get','model','518879Wwknml','toView','ai.useTheme','markerRange','isOfficialPlugin','span','1062052TrSPJS','getRange','editor','isCollapsed','isPremiumPlugin','change','pluginName','markerToHighlight','editingDowncast','2155952ykjIsh','getLastMatchingPosition','setSelection','4633517kiIPVT','removeMarker','length','markers','1189203IukNFW','from','createSelection','getFirstRange'];_0x3548=function(){return _0x166d5b;};return _0x3548();}function _0x52ba(_0x1d4a9d,_0x599bee){const _0x354867=_0x3548();return _0x52ba=function(_0x52ba2b,_0x3917f0){_0x52ba2b=_0x52ba2b-0x79;let _0x2c9d64=_0x354867[_0x52ba2b];return _0x2c9d64;},_0x52ba(_0x1d4a9d,_0x599bee);}(function(_0x406e97,_0x328f6b){const _0x4355d3=_0x52ba,_0x171e6f=_0x406e97();while(!![]){try{const _0x5c699c=-parseInt(_0x4355d3(0x79))/0x1+-parseInt(_0x4355d3(0x7f))/0x2+parseInt(_0x4355d3(0x8f))/0x3+parseInt(_0x4355d3(0x88))/0x4+parseInt(_0x4355d3(0xad))/0x5+parseInt(_0x4355d3(0x9e))/0x6+-parseInt(_0x4355d3(0x8b))/0x7*(parseInt(_0x4355d3(0x99))/0x8);if(_0x5c699c===_0x328f6b)break;else _0x171e6f['push'](_0x171e6f['shift']());}catch(_0x442b7e){_0x171e6f['push'](_0x171e6f['shift']());}}}(_0x3548,0x6abd5));import{Plugin as _0x2e481e}from'ckeditor5/src/core.js';const c=_0x49ca75(0x9a);export default class a extends _0x2e481e{static get[_0x49ca75(0x85)](){const _0x4f782c=_0x49ca75;return _0x4f782c(0xb1);}static get[_0x49ca75(0x7d)](){return!0x0;}static get[_0x49ca75(0x83)](){return!0x0;}[_0x49ca75(0xb9)](){const _0x5d0eea=_0x49ca75,{editor:_0x57d9f8}=this,_0x174439=[_0x5d0eea(0x9c)];_0x57d9f8[_0x5d0eea(0xa9)][_0x5d0eea(0xba)](_0x5d0eea(0x7b))&&_0x174439[_0x5d0eea(0x9f)](_0x5d0eea(0xa5)),_0x57d9f8[_0x5d0eea(0xa4)][_0x5d0eea(0x9b)](_0x5d0eea(0x87))[_0x5d0eea(0x86)]({'model':c,'view':{'classes':_0x174439,'priority':0xc}}),_0x57d9f8[_0x5d0eea(0xa4)][_0x5d0eea(0x9b)](_0x5d0eea(0x87))[_0x5d0eea(0xa1)]({'model':c,'view':(_0x13bd2a,{writer:_0x446728})=>{const _0x17eb8a=_0x5d0eea;if(!_0x13bd2a[_0x17eb8a(0x7c)][_0x17eb8a(0x82)])return null;const _0x57be35=_0x446728[_0x17eb8a(0xb2)](_0x17eb8a(0x7e));return _0x446728[_0x17eb8a(0xab)]([_0x17eb8a(0x9c),_0x17eb8a(0xa6)],_0x57be35),_0x57be35;}});}[_0x49ca75(0xb0)](){const _0x4bca50=_0x49ca75,_0x23dd4c=this[_0x4bca50(0x81)][_0x4bca50(0xbb)];_0x23dd4c[_0x4bca50(0x84)](_0xf03bcc=>{const _0x249048=_0x4bca50,_0x738d5a=_0x23dd4c[_0x249048(0xb7)][_0x249048(0x94)][_0x249048(0x92)]();if(_0x23dd4c[_0x249048(0x8e)][_0x249048(0xb3)](c))_0xf03bcc[_0x249048(0xa2)](c,{'range':_0x738d5a});else{if(_0x738d5a[_0x249048(0xb8)][_0x249048(0x95)]){const _0x5c5cea=_0x738d5a[_0x249048(0xb8)][_0x249048(0x89)](({item:_0x14c20d})=>!_0x23dd4c[_0x249048(0xae)][_0x249048(0x93)](_0x14c20d),{'boundaries':_0x738d5a});_0xf03bcc[_0x249048(0xaa)](c,{'usingOperation':!0x1,'affectsData':!0x1,'range':_0xf03bcc[_0x249048(0xaf)](_0x5c5cea,_0x738d5a[_0x249048(0xb4)])});}else _0xf03bcc[_0x249048(0xaa)](c,{'usingOperation':!0x1,'affectsData':!0x1,'range':_0x738d5a});}});}[_0x49ca75(0xb6)](){const _0x59c0fe=_0x49ca75,_0x27b66f=this[_0x59c0fe(0x81)][_0x59c0fe(0xbb)];_0x27b66f[_0x59c0fe(0x8e)][_0x59c0fe(0xb3)](c)&&_0x27b66f[_0x59c0fe(0x84)](_0x37224d=>{const _0x2020af=_0x59c0fe;_0x37224d[_0x2020af(0x8c)](c);});}[_0x49ca75(0x98)](_0x3009f4,_0x4c22f2){const _0x2e8a86=_0x49ca75,_0x523e1a=_0x4c22f2||this[_0x2e8a86(0x81)][_0x2e8a86(0xbb)][_0x2e8a86(0x8e)][_0x2e8a86(0xba)](c)[_0x2e8a86(0x80)]();if(!this[_0x2e8a86(0x81)][_0x2e8a86(0xbb)][_0x2e8a86(0xa7)](_0x523e1a))return;const _0x4fa8b3=this[_0x2e8a86(0x81)][_0x2e8a86(0xac)][_0x2e8a86(0x96)][_0x2e8a86(0x7a)](_0x3009f4),_0x5c7115=this[_0x2e8a86(0x81)][_0x2e8a86(0xac)][_0x2e8a86(0xb5)](_0x4fa8b3);this[_0x2e8a86(0x81)][_0x2e8a86(0xbb)][_0x2e8a86(0x84)](_0x3a8a1c=>{const _0x439b3e=_0x2e8a86;this[_0x439b3e(0xb6)]();const _0x34935c=this[_0x439b3e(0x81)][_0x439b3e(0xbb)][_0x439b3e(0x98)](_0x5c7115,_0x523e1a);_0x34935c&&_0x3a8a1c[_0x439b3e(0x8a)](_0x34935c);});}[_0x49ca75(0x97)](_0x5e0f9e){const _0x5cbba3=_0x49ca75,{model:_0x51ea8}=this[_0x5cbba3(0x81)],_0x1e553b=Array[_0x5cbba3(0x90)](_0x51ea8[_0x5cbba3(0x91)](this[_0x5cbba3(0x81)][_0x5cbba3(0xbb)][_0x5cbba3(0x8e)][_0x5cbba3(0xba)](c)[_0x5cbba3(0x80)]())[_0x5cbba3(0xa8)]()),_0x314637=_0x1e553b[_0x5cbba3(0x8d)]?_0x51ea8[_0x5cbba3(0x9d)](_0x1e553b[_0x5cbba3(0xa3)]()):_0x51ea8[_0x5cbba3(0xb7)][_0x5cbba3(0x94)][_0x5cbba3(0xa0)]();this[_0x5cbba3(0x98)](_0x5e0f9e,_0x314637);}}
|
package/src/aiassistantui.d.ts
CHANGED
|
@@ -22,6 +22,14 @@ export default class AIAssistantUI extends Plugin {
|
|
|
22
22
|
* @inheritDoc
|
|
23
23
|
*/
|
|
24
24
|
static get pluginName(): "AIAssistantUI";
|
|
25
|
+
/**
|
|
26
|
+
* @inheritDoc
|
|
27
|
+
*/
|
|
28
|
+
static get isOfficialPlugin(): true;
|
|
29
|
+
/**
|
|
30
|
+
* @inheritDoc
|
|
31
|
+
*/
|
|
32
|
+
static get isPremiumPlugin(): true;
|
|
25
33
|
/**
|
|
26
34
|
* @inheritDoc
|
|
27
35
|
*/
|