@ckeditor/ckeditor5-ai 48.0.1 → 48.1.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/ckeditor5-metadata.json +1 -1
- package/dist/aiballoon/aiballoon.d.ts +8 -1
- package/dist/aichat/aichatcontroller.d.ts +15 -2
- package/dist/aichat/aichatui.d.ts +4 -3
- package/dist/aichat/model/aichatcontext.d.ts +99 -1
- package/dist/aichat/model/aichatconversation.d.ts +25 -3
- package/dist/aichat/model/aichatinteraction.d.ts +9 -0
- package/dist/aichat/ui/aichatfeedview.d.ts +12 -11
- package/dist/aichat/ui/aichatview.d.ts +3 -2
- package/dist/aichat/ui/controls/resources/aichatcontextresourcesview.d.ts +1 -1
- package/dist/aichat/ui/feed/aichatfeedsuggestionitemview.d.ts +1 -2
- package/dist/aichat/utils/eventnames.d.ts +1 -1
- package/dist/aichat/utils/promisequeue.d.ts +0 -3
- package/dist/aichathistory/aichathistoryui.d.ts +1 -6
- package/dist/aichathistory/ui/aichathistorylistitemview.d.ts +1 -0
- package/dist/aichathistory/ui/aichathistoryview.d.ts +3 -11
- package/dist/aiconfig.d.ts +8 -0
- package/dist/aicore/aiconnector.d.ts +37 -0
- package/dist/aicore/aiediting.d.ts +25 -12
- package/dist/aicore/model/aicontext.d.ts +18 -0
- package/dist/aicore/model/aiinteraction.d.ts +11 -3
- package/dist/aicore/model/aimodels.d.ts +6 -0
- package/dist/aicore/model/aireply.d.ts +25 -4
- package/dist/aicore/pipeline/airesponseapplier.d.ts +13 -0
- package/dist/{aichat/ui/aichatheaderview.d.ts → aicore/ui/aiheaderview.d.ts} +11 -9
- package/dist/aicore/ui/aiskeleton.d.ts +4 -0
- package/dist/aicore/ui/suggestioncontainer/aisuggestionbodyview.d.ts +11 -3
- package/dist/aicore/ui/suggestioncontainer/aisuggestioncontainerview.d.ts +1 -2
- package/dist/aicore/ui/suggestioncontainer/aisuggestioncontentpartview.d.ts +1 -3
- package/dist/aicore/utils/abortabletimeout.d.ts +16 -0
- package/dist/aicore/utils/createstartconversationbutton.d.ts +11 -0
- package/dist/aicore/utils/geteditorfromcontext.d.ts +13 -0
- package/dist/aicore/utils/getoperationsfromreply.d.ts +3 -1
- package/dist/aicore/utils/htmlstreamer.d.ts +10 -10
- package/dist/aicore/utils/scrollmanager.d.ts +5 -1
- package/dist/aiquickactions/aiquickactions.d.ts +7 -14
- package/dist/aiquickactions/aiquickactionsui.d.ts +1 -1
- package/dist/aiquickactions/ui/balloon/aiactionsballoonview.d.ts +1 -1
- package/dist/aireviewcore/aireviewcoreediting.d.ts +29 -3
- package/dist/aireviewcore/model/aireviewcheckrun.d.ts +2 -0
- package/dist/aitabs/aitabs.d.ts +1 -5
- package/dist/aitabs/tabs/aitabsview.d.ts +36 -0
- package/dist/aitranslate/ui/aitranslatecheckresultsview.d.ts +1 -1
- package/dist/index-content.css +1 -0
- package/dist/index-editor.css +258 -235
- package/dist/index.css +258 -235
- package/dist/index.d.ts +8 -8
- package/dist/index.js +6 -6
- 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.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- 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.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- 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.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- 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.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- 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.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- 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.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- 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.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- 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.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- 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.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- 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/package.json +12 -12
|
@@ -2,9 +2,13 @@
|
|
|
2
2
|
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
4
|
*/
|
|
5
|
+
/**
|
|
6
|
+
* @module ai/aicore/model/aiinteraction
|
|
7
|
+
* @publicApi
|
|
8
|
+
*/
|
|
9
|
+
import { type Locale } from '@ckeditor/ckeditor5-utils';
|
|
5
10
|
import { type AIConnector } from '../aiconnector.js';
|
|
6
11
|
import { AIReply } from './aireply.js';
|
|
7
|
-
import { type Editor } from '@ckeditor/ckeditor5-core';
|
|
8
12
|
declare const AIInteraction_base: {
|
|
9
13
|
new (): import("@ckeditor/ckeditor5-utils").Emitter;
|
|
10
14
|
prototype: import("@ckeditor/ckeditor5-utils").Emitter;
|
|
@@ -33,7 +37,7 @@ export declare abstract class AIInteraction extends /* #__PURE__ */ AIInteractio
|
|
|
33
37
|
* from the AI endpoint.
|
|
34
38
|
*/
|
|
35
39
|
currentReply?: AIReply;
|
|
36
|
-
constructor({ connector,
|
|
40
|
+
constructor({ connector, locale }: AIInteractionOptions);
|
|
37
41
|
/**
|
|
38
42
|
* Stops the interaction. It marks the last reply as done and aborts the current request to the AI endpoint.
|
|
39
43
|
*
|
|
@@ -65,7 +69,11 @@ export declare abstract class AIInteraction extends /* #__PURE__ */ AIInteractio
|
|
|
65
69
|
}
|
|
66
70
|
export type AIInteractionOptions = {
|
|
67
71
|
connector: AIConnector;
|
|
68
|
-
|
|
72
|
+
/**
|
|
73
|
+
* Locale used to translate user-facing strings produced internally by replies (e.g. the placeholder shown in place of
|
|
74
|
+
* removed content while change groups are computed).
|
|
75
|
+
*/
|
|
76
|
+
locale?: Locale;
|
|
69
77
|
};
|
|
70
78
|
export type AIToolData = {
|
|
71
79
|
/**
|
|
@@ -23,6 +23,12 @@ export interface AIModelsConfig {
|
|
|
23
23
|
/**
|
|
24
24
|
* Decides whether the model selector UI is visible across all AI features (Chat and Review Mode).
|
|
25
25
|
*
|
|
26
|
+
* When `true`:
|
|
27
|
+
* * If multiple models are available, the model selector dropdown is shown.
|
|
28
|
+
* * If only one model is available, the model name is displayed instead of the selector.
|
|
29
|
+
*
|
|
30
|
+
* When `false`, the model UI will not be shown no matter how many models are available.
|
|
31
|
+
*
|
|
26
32
|
* @default true
|
|
27
33
|
*/
|
|
28
34
|
showModelSelector?: boolean;
|
|
@@ -2,10 +2,15 @@
|
|
|
2
2
|
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
4
|
*/
|
|
5
|
+
/**
|
|
6
|
+
* @module ai/aicore/model/aireply
|
|
7
|
+
* @publicApi
|
|
8
|
+
*/
|
|
9
|
+
import { type Locale } from '@ckeditor/ckeditor5-utils';
|
|
5
10
|
import { Element, Document } from '../utils/htmlparser.js';
|
|
6
|
-
import { type Editor } from '@ckeditor/ckeditor5-core';
|
|
7
11
|
import { type AISuggestionContentPartDefinition } from '../utils/getsuggestionpartsfromreply.js';
|
|
8
12
|
import type { AISource } from '../aiconnector.js';
|
|
13
|
+
import type { AIDataIdDocumentSource } from './aicontext.js';
|
|
9
14
|
/**
|
|
10
15
|
* The type of the reply. It can be one of the following:
|
|
11
16
|
*
|
|
@@ -56,22 +61,38 @@ export declare class AIReply extends /* #__PURE__ */ AIReply_base {
|
|
|
56
61
|
parsedContent: Document;
|
|
57
62
|
/**
|
|
58
63
|
* Whether the reply is done. The reply is done once the AI endpoint emitted the last chunk of the content
|
|
59
|
-
* that matches the reply's type.
|
|
64
|
+
* that matches the reply's type or the reply was interrupted (user stop, error, connection drop).
|
|
65
|
+
*
|
|
66
|
+
* See {@link #isComplete} for more information about the reply's completion state.
|
|
60
67
|
*
|
|
61
68
|
* @observable
|
|
62
69
|
*/
|
|
63
70
|
isDone: boolean;
|
|
71
|
+
/**
|
|
72
|
+
* Whether the reply finished organically, i.e. the stream ran out of chunks naturally.
|
|
73
|
+
*
|
|
74
|
+
* This is `false` while streaming, and also `false` if the reply was stopped or errored before the stream ended.
|
|
75
|
+
*
|
|
76
|
+
* See {@link #isDone} for more information.
|
|
77
|
+
*
|
|
78
|
+
* @observable
|
|
79
|
+
*/
|
|
80
|
+
isComplete: boolean;
|
|
64
81
|
/**
|
|
65
82
|
* @inheritDoc
|
|
66
83
|
*/
|
|
67
|
-
constructor({ type, content, isDone, interactionId, areActionsDisabled, documentContextContent,
|
|
84
|
+
constructor({ type, content, isDone, isComplete, interactionId, areActionsDisabled, isFromHistory, documentContextContent, dataIdDocumentSources, documentId, locale, id }: {
|
|
68
85
|
type: AIReplyType;
|
|
69
86
|
interactionId: string;
|
|
70
87
|
areActionsDisabled?: boolean;
|
|
88
|
+
isFromHistory?: boolean;
|
|
71
89
|
content?: string;
|
|
72
90
|
isDone?: boolean;
|
|
91
|
+
isComplete?: boolean;
|
|
73
92
|
documentContextContent?: string;
|
|
74
|
-
|
|
93
|
+
dataIdDocumentSources?: ReadonlyMap<string, AIDataIdDocumentSource>;
|
|
94
|
+
documentId?: string;
|
|
95
|
+
locale?: Locale;
|
|
75
96
|
id?: string;
|
|
76
97
|
});
|
|
77
98
|
/**
|
|
@@ -61,6 +61,11 @@ export declare class AIResponseApplier extends /* #__PURE__ -- @preserve */ AIRe
|
|
|
61
61
|
* of the `contentPart` are processed. Nested elements are not processed directly, but as a children
|
|
62
62
|
* of the top level nodes they are included in the merge process.
|
|
63
63
|
*
|
|
64
|
+
* Note: "existing document" comments and "removed" comments are only meaningful at the top level of the `contentPart`.
|
|
65
|
+
* If an existing (kept) element contains such comments inside its children, they are ignored (stripped) — the entire
|
|
66
|
+
* element is replaced with the `contentPart` version as-is. This means that partial replacement inside a kept parent
|
|
67
|
+
* is not supported: the LLM must provide the full content of any existing element it returns.
|
|
68
|
+
*
|
|
64
69
|
* The algorithm iterates over the `contentPart` top level nodes and tries to find a position (directly or via reference node)
|
|
65
70
|
* for any element which should be merged into the `content`.
|
|
66
71
|
*
|
|
@@ -281,6 +286,14 @@ export type MergeResult = {
|
|
|
281
286
|
newNodeIds: Array<string>;
|
|
282
287
|
modifiedNodeIds: Array<string>;
|
|
283
288
|
removedNodeIds: Array<string>;
|
|
289
|
+
/**
|
|
290
|
+
* Maps each newly-inserted top-level node id to the `data-id` of the existing element the merger picked as its anchor (the
|
|
291
|
+
* preceding or following existing element the AI's stream attached the new node to). Lets consumers route a new node to the
|
|
292
|
+
* correct source document when neighbour positions in the merged tree are ambiguous — e.g. "prepend at the start of doc B"
|
|
293
|
+
* produces the same merged tree as "append at the end of doc A", but only the AI's anchor disambiguates which doc owns the new
|
|
294
|
+
* node.
|
|
295
|
+
*/
|
|
296
|
+
newAnchorIds: ReadonlyMap<string, string>;
|
|
284
297
|
};
|
|
285
298
|
export type MergeOptions = {
|
|
286
299
|
cutAfterLastChange?: boolean;
|
|
@@ -3,22 +3,18 @@
|
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
4
|
*/
|
|
5
5
|
/**
|
|
6
|
-
* @module ai/
|
|
6
|
+
* @module ai/aicore/ui/aiheaderview
|
|
7
7
|
*/
|
|
8
8
|
import { type Locale } from '@ckeditor/ckeditor5-utils';
|
|
9
|
-
import { ButtonView, FormHeaderView } from '@ckeditor/ckeditor5-ui';
|
|
9
|
+
import { type ButtonView, FormHeaderView, type View } from '@ckeditor/ckeditor5-ui';
|
|
10
10
|
import '../../../theme/common/aiheader.css';
|
|
11
|
-
export declare class
|
|
12
|
-
/**
|
|
13
|
-
* The button to start a new conversation.
|
|
14
|
-
*/
|
|
15
|
-
readonly conversationStartButton: ButtonView;
|
|
11
|
+
export declare class AIHeaderView extends FormHeaderView {
|
|
16
12
|
/**
|
|
17
13
|
* The button to resize the chat view.
|
|
18
14
|
*/
|
|
19
15
|
readonly resizeButton?: ButtonView;
|
|
20
16
|
/**
|
|
21
|
-
* Indicates whether the
|
|
17
|
+
* Indicates whether the resize button shows maximized state.
|
|
22
18
|
*
|
|
23
19
|
* @observable
|
|
24
20
|
*/
|
|
@@ -26,5 +22,11 @@ export declare class AIChatHeaderView extends FormHeaderView {
|
|
|
26
22
|
/**
|
|
27
23
|
* @inheritDoc
|
|
28
24
|
*/
|
|
29
|
-
constructor(locale: Locale,
|
|
25
|
+
constructor(locale: Locale, options: {
|
|
26
|
+
label: string;
|
|
27
|
+
icon: string;
|
|
28
|
+
class: string;
|
|
29
|
+
content?: View;
|
|
30
|
+
showResizeButton: boolean;
|
|
31
|
+
});
|
|
30
32
|
}
|
|
@@ -9,6 +9,10 @@ import { View } from '@ckeditor/ckeditor5-ui';
|
|
|
9
9
|
import { type Locale } from '@ckeditor/ckeditor5-utils';
|
|
10
10
|
import '../../../theme/common/aiskeleton.css';
|
|
11
11
|
export declare class AISkeletonView extends View {
|
|
12
|
+
/**
|
|
13
|
+
* Controls the visibility of the skeleton view.
|
|
14
|
+
*/
|
|
15
|
+
isVisible: boolean;
|
|
12
16
|
/**
|
|
13
17
|
* @inheritDoc
|
|
14
18
|
*/
|
|
@@ -8,7 +8,6 @@
|
|
|
8
8
|
import { type Locale } from '@ckeditor/ckeditor5-utils';
|
|
9
9
|
import { type BodyCollection, View } from '@ckeditor/ckeditor5-ui';
|
|
10
10
|
import { AISuggestionBodyViewContentPartView } from './aisuggestioncontentpartview.js';
|
|
11
|
-
import { type AIContentRenderingStrategy } from './aisuggestionstreamablecontentview.js';
|
|
12
11
|
import { type AISuggestionContentPartDefinition } from '../../utils/getsuggestionpartsfromreply.js';
|
|
13
12
|
import { type AISuggestionActionName } from '../../../aichat/ui/feed/aichatfeedsuggestionitemactionsview.js';
|
|
14
13
|
import { type AIReplyChangeGroupState } from '../../model/aireply.js';
|
|
@@ -33,6 +32,10 @@ export declare class AISuggestionBodyView extends View<HTMLDivElement> {
|
|
|
33
32
|
availableActions: Array<AISuggestionActionName>;
|
|
34
33
|
bodyCollection: BodyCollection;
|
|
35
34
|
});
|
|
35
|
+
/**
|
|
36
|
+
* @inheritDoc
|
|
37
|
+
*/
|
|
38
|
+
destroy(): void;
|
|
36
39
|
/**
|
|
37
40
|
* Gets the number of content parts in the suggestion.
|
|
38
41
|
*/
|
|
@@ -40,10 +43,15 @@ export declare class AISuggestionBodyView extends View<HTMLDivElement> {
|
|
|
40
43
|
/**
|
|
41
44
|
* Updates the content parts of the suggestion.
|
|
42
45
|
*/
|
|
43
|
-
updateContentParts({ parts,
|
|
46
|
+
updateContentParts({ parts, abortSignal, skipLoadingEffects }: {
|
|
44
47
|
parts: Array<AISuggestionContentPartDefinition>;
|
|
45
|
-
renderingStrategy: AIContentRenderingStrategy;
|
|
46
48
|
abortSignal?: AbortSignal;
|
|
49
|
+
/**
|
|
50
|
+
* When `true`, all loading-state UI (skeleton, debounce timers) is bypassed and content
|
|
51
|
+
* parts are inserted immediately. Use for content that is already complete and should
|
|
52
|
+
* appear without any progressive-reveal delay (e.g. conversation history replays).
|
|
53
|
+
*/
|
|
54
|
+
skipLoadingEffects?: boolean;
|
|
47
55
|
}): Promise<void>;
|
|
48
56
|
/**
|
|
49
57
|
* Updates the state of a content part by its index.
|
|
@@ -8,7 +8,6 @@
|
|
|
8
8
|
import { type Locale } from '@ckeditor/ckeditor5-utils';
|
|
9
9
|
import { View, type BodyCollection } from '@ckeditor/ckeditor5-ui';
|
|
10
10
|
import { type AISuggestionContentPartDefinition } from '../../utils/getsuggestionpartsfromreply.js';
|
|
11
|
-
import { type AIContentRenderingStrategy } from './aisuggestionstreamablecontentview.js';
|
|
12
11
|
import { type AISource } from '../../aiconnector.js';
|
|
13
12
|
import { type AISuggestionActionName } from '../../../aichat/ui/feed/aichatfeedsuggestionitemactionsview.js';
|
|
14
13
|
import '../../../../theme/aichat/aisuggestioncontainer.css';
|
|
@@ -30,8 +29,8 @@ export declare class AISuggestionContainerView extends View<HTMLDivElement> {
|
|
|
30
29
|
constructor(locale: Locale, options: AISuggestionContainerViewOptions, bodyCollection: BodyCollection);
|
|
31
30
|
updateContent(options: {
|
|
32
31
|
parts: Array<AISuggestionContentPartDefinition>;
|
|
33
|
-
renderingStrategy: AIContentRenderingStrategy;
|
|
34
32
|
abortSignal?: AbortSignal;
|
|
33
|
+
skipLoadingEffects?: boolean;
|
|
35
34
|
}): Promise<void>;
|
|
36
35
|
/**
|
|
37
36
|
* Updates the web sources of the suggestion.
|
|
@@ -10,7 +10,6 @@ import { View } from '@ckeditor/ckeditor5-ui';
|
|
|
10
10
|
import { type AISuggestionContentPartDefinition } from '../../utils/getsuggestionpartsfromreply.js';
|
|
11
11
|
import { type AIReplyChangeGroupState } from '../../model/aireply.js';
|
|
12
12
|
import { type AISuggestionActionName } from '../../../aichat/ui/feed/aichatfeedsuggestionitemactionsview.js';
|
|
13
|
-
import { type AIContentRenderingStrategy } from './aisuggestionstreamablecontentview.js';
|
|
14
13
|
/**
|
|
15
14
|
* A view that displays a single part in the suggestion content.
|
|
16
15
|
*/
|
|
@@ -52,9 +51,8 @@ export declare class AISuggestionBodyViewContentPartView extends View<HTMLDivEle
|
|
|
52
51
|
/**
|
|
53
52
|
* Updates the content of the content part.
|
|
54
53
|
*/
|
|
55
|
-
updateContent({ part,
|
|
54
|
+
updateContent({ part, showUnchangedParts, abortSignal }: {
|
|
56
55
|
part: AISuggestionContentPartDefinition;
|
|
57
|
-
renderingStrategy: AIContentRenderingStrategy;
|
|
58
56
|
showUnchangedParts?: boolean;
|
|
59
57
|
abortSignal?: AbortSignal;
|
|
60
58
|
}): Promise<void>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* @module ai/aicore/utils/abortabletimeout
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Creates a promise that resolves after `delay` ms and an `AbortController` that can cancel it early.
|
|
10
|
+
*
|
|
11
|
+
* The promise rejects if the abort controller is signalled before the timeout fires.
|
|
12
|
+
*/
|
|
13
|
+
export declare function createAbortableTimeout(delay: number): {
|
|
14
|
+
promise: Promise<void>;
|
|
15
|
+
abortController: AbortController;
|
|
16
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* @module ai/aicore/utils/createstartconversationbutton
|
|
7
|
+
*/
|
|
8
|
+
import type { Locale } from '@ckeditor/ckeditor5-utils';
|
|
9
|
+
import { ButtonView, type View } from '@ckeditor/ckeditor5-ui';
|
|
10
|
+
import '../../../theme/common/aiheader.css';
|
|
11
|
+
export declare function createStartConversationButton<T extends View>(locale: Locale, view: T): ButtonView;
|
|
@@ -3,4 +3,17 @@
|
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
4
|
*/
|
|
5
5
|
import { type ContextInterface, Editor } from '@ckeditor/ckeditor5-core';
|
|
6
|
+
/**
|
|
7
|
+
* Returns all editor instances registered on the context. For a single editor passed as `context`, returns `[ context ]`.
|
|
8
|
+
* Returns an empty array when the context has no editors yet.
|
|
9
|
+
*/
|
|
10
|
+
export declare function getEditorsFromContext(context: ContextInterface | null | undefined): Array<Editor>;
|
|
11
|
+
/**
|
|
12
|
+
* Returns the editor that should drive user-driven AI operations when several editors share a {@link module:core/context~Context Context}:
|
|
13
|
+
* the one with UI focus if any, otherwise the last editor that had UI focus (tracked by {@link module:ai/aicore/aiediting~AIEditing}),
|
|
14
|
+
* otherwise the first editor in registration order.
|
|
15
|
+
*
|
|
16
|
+
* For a single editor passed as `context`, returns that editor.
|
|
17
|
+
*/
|
|
18
|
+
export declare function getTargetEditorFromContext(context: ContextInterface): Editor;
|
|
6
19
|
export declare function getEditorFromContext(context: ContextInterface): Editor;
|
|
@@ -8,9 +8,10 @@
|
|
|
8
8
|
import { type DocumentCompare, type DocumentCompareOptions } from '@ckeditor/ckeditor5-collaboration-core';
|
|
9
9
|
import { type Operation } from '@ckeditor/ckeditor5-engine';
|
|
10
10
|
import { type AIInteraction } from '../model/aiinteraction.js';
|
|
11
|
+
import type { AIDocumentContextSlice } from '../model/aicontext.js';
|
|
11
12
|
import type { AIReply, AIReplyChangeGroup } from '../model/aireply.js';
|
|
12
13
|
import { type Editor } from '@ckeditor/ckeditor5-core';
|
|
13
|
-
export declare function getOperationsFromReply({ editor, interaction, reply, groups, transform, documentCompare, documentCompareOptions }: {
|
|
14
|
+
export declare function getOperationsFromReply({ editor, interaction, reply, groups, transform, documentCompare, documentCompareOptions, documentContextSlice }: {
|
|
14
15
|
editor: Editor;
|
|
15
16
|
interaction: AIInteraction;
|
|
16
17
|
reply: AIReply;
|
|
@@ -18,5 +19,6 @@ export declare function getOperationsFromReply({ editor, interaction, reply, gro
|
|
|
18
19
|
groups: Array<AIReplyChangeGroup>;
|
|
19
20
|
documentCompare: DocumentCompare;
|
|
20
21
|
documentCompareOptions: DocumentCompareOptions;
|
|
22
|
+
documentContextSlice?: AIDocumentContextSlice;
|
|
21
23
|
}): Array<Operation>;
|
|
22
24
|
export declare function fixMarkerOperationOldRange(editor: Editor, operation: Operation): void;
|
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
4
|
*/
|
|
5
5
|
import { type Document } from './htmlparser.js';
|
|
6
|
+
/**
|
|
7
|
+
* The default animation for text nodes. It is a smooth fade-in animation from 0 to 1 opacity.
|
|
8
|
+
*/
|
|
9
|
+
export declare const DEFAULT_FADE_IN_ANIMATION = "animation: ck-html-streamer-fade-in .3s";
|
|
6
10
|
/**
|
|
7
11
|
* A class that streams arbitrary HTML content into a target DOM element in an incremental manner.
|
|
8
12
|
*
|
|
@@ -12,7 +16,7 @@ export declare class HTMLStreamer {
|
|
|
12
16
|
/**
|
|
13
17
|
* Creates an instance of HTMLStreamer.
|
|
14
18
|
*/
|
|
15
|
-
constructor(options
|
|
19
|
+
constructor(options?: HTMLStreamerOptions);
|
|
16
20
|
/**
|
|
17
21
|
* Incrementally streams the HTML string into provided target DOM element.
|
|
18
22
|
*
|
|
@@ -32,19 +36,19 @@ export declare class HTMLStreamer {
|
|
|
32
36
|
* await htmlStreamer.stream( { document } );
|
|
33
37
|
* ```
|
|
34
38
|
*
|
|
35
|
-
* after
|
|
39
|
+
* after 10ms will stream:
|
|
36
40
|
*
|
|
37
41
|
* ```html
|
|
38
42
|
* <p></p>
|
|
39
43
|
* ```
|
|
40
44
|
*
|
|
41
|
-
* and after
|
|
45
|
+
* and after 20ms:
|
|
42
46
|
*
|
|
43
47
|
* ```html
|
|
44
48
|
* <p><span data-ck-html-streamer-word-chunk="" style="animation: my-animation .5s">foo </span></p>
|
|
45
49
|
* ```
|
|
46
50
|
*
|
|
47
|
-
* and after
|
|
51
|
+
* and after 30ms:
|
|
48
52
|
*
|
|
49
53
|
* ```html
|
|
50
54
|
* <p>
|
|
@@ -74,16 +78,12 @@ export declare class HTMLStreamer {
|
|
|
74
78
|
*/
|
|
75
79
|
interface HTMLStreamerOptions {
|
|
76
80
|
/**
|
|
77
|
-
* Delay between `stream()` updates in milliseconds. Default is
|
|
81
|
+
* Delay between `stream()` updates in milliseconds. Default is 10ms.
|
|
78
82
|
*/
|
|
79
83
|
delay?: number;
|
|
80
84
|
/**
|
|
81
85
|
* The `style` attribute value for `<span>` elements that wrap text nodes.
|
|
82
86
|
*/
|
|
83
|
-
textNodeStyle
|
|
84
|
-
/**
|
|
85
|
-
* Callback to be called every time the stream is updated.
|
|
86
|
-
*/
|
|
87
|
-
onStreamUpdate?: () => void;
|
|
87
|
+
textNodeStyle?: string;
|
|
88
88
|
}
|
|
89
89
|
export {};
|
|
@@ -10,8 +10,12 @@ export declare class ScrollManager {
|
|
|
10
10
|
constructor(element: HTMLElement);
|
|
11
11
|
/**
|
|
12
12
|
* Starts the auto-scrolling.
|
|
13
|
+
*
|
|
14
|
+
* @param options.smooth When `false`, the scroll jumps instantly instead of animating. Defaults to `true`.
|
|
13
15
|
*/
|
|
14
|
-
start(
|
|
16
|
+
start({ smooth }?: {
|
|
17
|
+
smooth?: boolean;
|
|
18
|
+
}): void;
|
|
15
19
|
/**
|
|
16
20
|
* Stops the auto-scrolling.
|
|
17
21
|
*/
|
|
@@ -220,25 +220,16 @@ export interface AIQuickActionCustomBaseDefinition {
|
|
|
220
220
|
*/
|
|
221
221
|
readonly prompt: string;
|
|
222
222
|
/**
|
|
223
|
-
* The model to use for the action.
|
|
223
|
+
* The AI model to use for the action. For `'action'` type, if not specified, the default model will be used.
|
|
224
|
+
* For `'chat'` type, if not specified, the model currently selected in the AI Chat will be used.
|
|
224
225
|
*/
|
|
225
226
|
readonly model?: string;
|
|
226
227
|
}
|
|
227
228
|
/**
|
|
228
229
|
* A custom AI quick action definition.
|
|
229
230
|
*
|
|
230
|
-
* An example of an action that inserts content in the editor
|
|
231
|
-
*
|
|
232
|
-
* ```ts
|
|
233
|
-
* {
|
|
234
|
-
* id: 'add-random-cat-fact',
|
|
235
|
-
* label: 'Add cat fact.',
|
|
236
|
-
* prompt: 'Add a random fact about cats to the document.',
|
|
237
|
-
* type: 'action',
|
|
238
|
-
* }
|
|
239
|
-
* ```
|
|
240
|
-
*
|
|
241
|
-
* Optionally, action can have an AI model specified that it will use when run:
|
|
231
|
+
* An example of an action that inserts content in the editor. The `model` property is optional — if not specified,
|
|
232
|
+
* the default model (from `ai.models.defaultModelId` configuration or the first available model) will be used:
|
|
242
233
|
*
|
|
243
234
|
* ```ts
|
|
244
235
|
* {
|
|
@@ -256,7 +247,9 @@ export interface AIQuickActionCustomActionDefinition extends AIQuickActionCustom
|
|
|
256
247
|
/**
|
|
257
248
|
* A custom AI quick action definition that interacts with {@link module:ai/aichat/aichat~AIChat AI Chat}.
|
|
258
249
|
*
|
|
259
|
-
* It will open the {@link module:ai/aichat/aichat~AIChat AI Chat} interface for interactive conversations
|
|
250
|
+
* It will open the {@link module:ai/aichat/aichat~AIChat AI Chat} interface for interactive conversations.
|
|
251
|
+
* If `model` is specified, it will be selected for the new chat conversation. Otherwise, the model currently
|
|
252
|
+
* selected in the AI Chat will be used:
|
|
260
253
|
*
|
|
261
254
|
* ```ts
|
|
262
255
|
* {
|
|
@@ -44,7 +44,7 @@ export declare class AIQuickActionsUI extends Plugin {
|
|
|
44
44
|
* Sets up the default quick actions configuration and creates all necessary
|
|
45
45
|
* UI components and commands for the quick actions functionality.
|
|
46
46
|
*
|
|
47
|
-
* @
|
|
47
|
+
* See {@link module:core/plugin~PluginInterface#init}.
|
|
48
48
|
*/
|
|
49
49
|
init(): Promise<void>;
|
|
50
50
|
/**
|
|
@@ -90,7 +90,7 @@ export declare class AIActionsBalloonView extends AIBalloonView implements ViewW
|
|
|
90
90
|
* Updates the main content view of the balloon.
|
|
91
91
|
* This method replaces the current main view with a new one without recreating the entire balloon.
|
|
92
92
|
*
|
|
93
|
-
* @param
|
|
93
|
+
* @param options The content update options.
|
|
94
94
|
*/
|
|
95
95
|
updateContent(options: {
|
|
96
96
|
part: AISuggestionContentPartDefinition;
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
import { InsertOperation, MarkerOperation, ModelDocumentFragment, ModelPosition, ModelRange, type Operation } from '@ckeditor/ckeditor5-engine';
|
|
9
9
|
import { type Emitter } from '@ckeditor/ckeditor5-utils';
|
|
10
|
-
import {
|
|
10
|
+
import { ContextPlugin, Editor, type Context } from '@ckeditor/ckeditor5-core';
|
|
11
11
|
import { DocumentCompare } from '@ckeditor/ckeditor5-collaboration-core';
|
|
12
12
|
import { type AIReviewCheckResultChange } from './model/aireviewcheckresultchange.js';
|
|
13
13
|
import { AIEditing } from '../aicore/aiediting.js';
|
|
@@ -109,7 +109,7 @@ export declare class AIReviewCoreEditing extends ContextPlugin {
|
|
|
109
109
|
*
|
|
110
110
|
* The context and content is equal so both functions return the entire initial content.
|
|
111
111
|
*/
|
|
112
|
-
diffContent(contentInitial: string, contentNew: string, asSingleGroup?: boolean): Array<AIReviewCoreChangeData>;
|
|
112
|
+
diffContent(editor: Editor, contentInitial: string, contentNew: string, asSingleGroup?: boolean): Array<AIReviewCoreChangeData>;
|
|
113
113
|
markChangePositionInEditorContent(changes: Array<AIReviewCheckResultChange>, documentData: AIDocumentData): void;
|
|
114
114
|
clearAllMarkers(): void;
|
|
115
115
|
switchToReadOnly(): void;
|
|
@@ -117,6 +117,14 @@ export declare class AIReviewCoreEditing extends ContextPlugin {
|
|
|
117
117
|
applyChange(changeIds: Array<string>): void;
|
|
118
118
|
rejectChange(changeId: string): void;
|
|
119
119
|
getEditor(): Editor;
|
|
120
|
+
/**
|
|
121
|
+
* All editors attached to this context (same order as {@link module:ai/aicore/utils/geteditorfromcontext~getEditorsFromContext}).
|
|
122
|
+
*/
|
|
123
|
+
getEditors(): Array<Editor>;
|
|
124
|
+
/**
|
|
125
|
+
* Returns the editor that hosts markers for the given change, when known.
|
|
126
|
+
*/
|
|
127
|
+
getEditorForChange(changeId: string): Editor | undefined;
|
|
120
128
|
getMarkerElementForChange(changeId: string): {
|
|
121
129
|
modelRange: ModelRange;
|
|
122
130
|
getElement: () => HTMLElement | null;
|
|
@@ -146,12 +154,29 @@ export declare class AIReviewCoreEditing extends ContextPlugin {
|
|
|
146
154
|
setAllMarkersAsInactive(): void;
|
|
147
155
|
}
|
|
148
156
|
export type AIDocumentDataElement = {
|
|
157
|
+
/**
|
|
158
|
+
* Editor instance this element's model belongs to.
|
|
159
|
+
*/
|
|
160
|
+
editor: Editor;
|
|
161
|
+
/**
|
|
162
|
+
* Name of the model root this element belongs to (e.g. `main`, `root1` in multi-root editors).
|
|
163
|
+
*/
|
|
164
|
+
rootName: string;
|
|
165
|
+
/**
|
|
166
|
+
* Path to the element in the model.
|
|
167
|
+
*/
|
|
149
168
|
path: Array<number>;
|
|
169
|
+
/**
|
|
170
|
+
* Model document version when this element map was captured (per-editor).
|
|
171
|
+
*/
|
|
172
|
+
documentVersion: number;
|
|
150
173
|
getContent: () => string;
|
|
151
174
|
};
|
|
152
175
|
export type AIDocumentData = {
|
|
176
|
+
/**
|
|
177
|
+
* Single string passed to review API: roots serialized in model order, concatenated.
|
|
178
|
+
*/
|
|
153
179
|
content: string;
|
|
154
|
-
version: number;
|
|
155
180
|
elements: Map<string, AIDocumentDataElement>;
|
|
156
181
|
};
|
|
157
182
|
export type AIDiffResult = {
|
|
@@ -172,6 +197,7 @@ export type AIReviewCoreMarkerInsertData = AIReviewCoreMarkerBaseData & {
|
|
|
172
197
|
};
|
|
173
198
|
export type AIReviewCoreMarkerData = AIReviewCoreMarkerBaseData & {
|
|
174
199
|
id: string;
|
|
200
|
+
editor: Editor;
|
|
175
201
|
};
|
|
176
202
|
export type AIReviewCoreMarkerType = 'insert' | 'remove-text' | 'remove-only' | 'remove-context';
|
|
177
203
|
export type AIReviewCoreChangeRange = {
|
|
@@ -7,6 +7,7 @@ import { AIReviewCheckResultChange } from './aireviewcheckresultchange.js';
|
|
|
7
7
|
import { type AIReviewCheck } from './aireviewcheck.js';
|
|
8
8
|
import { type AIReviewCoreChangeData, type AIDocumentData } from '../aireviewcoreediting.js';
|
|
9
9
|
import { type AIConnector } from '../../aicore/aiconnector.js';
|
|
10
|
+
import { type Editor } from '@ckeditor/ckeditor5-core';
|
|
10
11
|
declare const AIReviewCheckRun_base: {
|
|
11
12
|
new (): import("@ckeditor/ckeditor5-utils").Observable;
|
|
12
13
|
prototype: import("@ckeditor/ckeditor5-utils").Observable;
|
|
@@ -119,6 +120,7 @@ export type AIReviewCheckResultAddedEvent = {
|
|
|
119
120
|
{
|
|
120
121
|
result: AIReviewCheckResult;
|
|
121
122
|
source: AIReviewCheckRun;
|
|
123
|
+
editor: Editor;
|
|
122
124
|
}
|
|
123
125
|
];
|
|
124
126
|
};
|
package/dist/aitabs/aitabs.d.ts
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*/
|
|
9
9
|
import { type Context, ContextPlugin, Editor } from '@ckeditor/ckeditor5-core';
|
|
10
10
|
import { AITabsMainView } from './aitabsmainview.js';
|
|
11
|
-
import {
|
|
11
|
+
import type { AIContainerSide, AIContainerType } from '../aiconfig.js';
|
|
12
12
|
/**
|
|
13
13
|
* The AI Tabs plugin. It delivers the tabs view that hosts AI-powered features in the editor
|
|
14
14
|
* such as {@link module:ai/aichat/aichat~AIChat AI Chat}, {@link module:ai/aiquickactions/aiquickactions~AIQuickActions AI Quick Actions},
|
|
@@ -74,10 +74,6 @@ export declare class AITabs extends ContextPlugin {
|
|
|
74
74
|
* See {@link module:ai/aiconfig~AIConfig#container} to learn more about possible sides.
|
|
75
75
|
*/
|
|
76
76
|
switchSide(side: AIContainerSide): void;
|
|
77
|
-
/**
|
|
78
|
-
* Toggles the resizing of the tabs view.
|
|
79
|
-
*/
|
|
80
|
-
resize(): void;
|
|
81
77
|
/**
|
|
82
78
|
* @inheritDoc
|
|
83
79
|
*/
|
|
@@ -53,6 +53,16 @@ export declare class AITabsView extends View {
|
|
|
53
53
|
* @observable
|
|
54
54
|
*/
|
|
55
55
|
isMaximized: boolean;
|
|
56
|
+
/**
|
|
57
|
+
* Indicates whether clicking the active tab button collapses the panel.
|
|
58
|
+
*
|
|
59
|
+
* When `true`, clicking the active tab button deactivates the tab and adds the
|
|
60
|
+
* `ck-ai-tabs_collapsed` class to the view. When `false`, clicking the active tab
|
|
61
|
+
* button is a no-op.
|
|
62
|
+
*
|
|
63
|
+
* @observable
|
|
64
|
+
*/
|
|
65
|
+
collapsible: boolean;
|
|
56
66
|
/**
|
|
57
67
|
* Creates a new AITabsView instance.
|
|
58
68
|
*/
|
|
@@ -104,6 +114,16 @@ export declare class AITabsView extends View {
|
|
|
104
114
|
* without the standard deprecation policy. Check the changelog for migration guidance.
|
|
105
115
|
*/
|
|
106
116
|
activateTab(id: string | null): void;
|
|
117
|
+
/**
|
|
118
|
+
* Toggles the active state of a tab. If the tab is active, it becomes inactive
|
|
119
|
+
* (the `ck-ai-tabs_collapsed` class is added to the view). Otherwise it becomes active.
|
|
120
|
+
*
|
|
121
|
+
* Has no effect when {@link #collapsible} is `false` and the tab is already active.
|
|
122
|
+
*
|
|
123
|
+
* The collapsed state is handled by built-in styles. You may target the
|
|
124
|
+
* `ck-ai-tabs_collapsed` class to customize the appearance.
|
|
125
|
+
*/
|
|
126
|
+
toggleTabPanel(id: string): void;
|
|
107
127
|
/**
|
|
108
128
|
* Shows the tab of a specific id.
|
|
109
129
|
*
|
|
@@ -123,6 +143,16 @@ export declare class AITabsView extends View {
|
|
|
123
143
|
*/
|
|
124
144
|
hideTab(id: string): void;
|
|
125
145
|
}
|
|
146
|
+
/**
|
|
147
|
+
* The event that fires when a tab is activated.
|
|
148
|
+
*/
|
|
149
|
+
export type AITabsActivateTabEvent = {
|
|
150
|
+
name: 'activateTab' | `activateTab:${string}`;
|
|
151
|
+
args: [{
|
|
152
|
+
newTab: string | null;
|
|
153
|
+
oldTab: string | null;
|
|
154
|
+
}];
|
|
155
|
+
};
|
|
126
156
|
/**
|
|
127
157
|
* The options for the `AITabsView#addTab()` method.
|
|
128
158
|
*/
|
|
@@ -164,4 +194,10 @@ export type AITabsViewOptions = {
|
|
|
164
194
|
* An additional CSS class added to the {@link module:ai/aitabs/tabs/aitabsview~AITabsView#element}.
|
|
165
195
|
*/
|
|
166
196
|
class?: ArrayOrItem<string>;
|
|
197
|
+
/**
|
|
198
|
+
* Whether clicking the active tab button collapses the panel.
|
|
199
|
+
*
|
|
200
|
+
* Defaults to `false`.
|
|
201
|
+
*/
|
|
202
|
+
collapsible?: boolean;
|
|
167
203
|
};
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
4
|
*/
|
|
5
5
|
/**
|
|
6
|
-
* @module ai/aitranslate/
|
|
6
|
+
* @module ai/aitranslate/ui/aitranslatecheckresultsview
|
|
7
7
|
*/
|
|
8
8
|
import { type Locale } from '@ckeditor/ckeditor5-utils';
|
|
9
9
|
import { AIReviewCoreUICheckResultsView, type AIReviewCoreUICheckResultsViewContents } from '../../aireviewcore/ui/aireviewcoreuicheckresultsview.js';
|