@ckeditor/ckeditor5-ai 0.0.1 → 40.0.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/CHANGELOG.md +4 -0
- package/LICENSE.md +7 -7
- package/README.md +32 -3
- package/build/ai.js +5 -0
- package/build/translations/af.js +1 -0
- package/build/translations/ar.js +1 -0
- package/build/translations/bg.js +1 -0
- package/build/translations/bn.js +1 -0
- package/build/translations/bs.js +1 -0
- package/build/translations/ca.js +1 -0
- package/build/translations/cs.js +1 -0
- package/build/translations/da.js +1 -0
- package/build/translations/de-ch.js +1 -0
- package/build/translations/de.js +1 -0
- package/build/translations/el.js +1 -0
- package/build/translations/en-au.js +1 -0
- package/build/translations/es-co.js +1 -0
- package/build/translations/es.js +1 -0
- package/build/translations/et.js +1 -0
- package/build/translations/fa.js +1 -0
- package/build/translations/fi.js +1 -0
- package/build/translations/fr.js +1 -0
- package/build/translations/gl.js +1 -0
- package/build/translations/he.js +1 -0
- package/build/translations/hi.js +1 -0
- package/build/translations/hr.js +1 -0
- package/build/translations/hu.js +1 -0
- package/build/translations/id.js +1 -0
- package/build/translations/it.js +1 -0
- package/build/translations/ja.js +1 -0
- package/build/translations/jv.js +1 -0
- package/build/translations/ko.js +1 -0
- package/build/translations/lt.js +1 -0
- package/build/translations/lv.js +1 -0
- package/build/translations/ms.js +1 -0
- package/build/translations/nl.js +1 -0
- package/build/translations/no.js +1 -0
- package/build/translations/pl.js +1 -0
- package/build/translations/pt-br.js +1 -0
- package/build/translations/pt.js +1 -0
- package/build/translations/ro.js +1 -0
- package/build/translations/ru.js +1 -0
- package/build/translations/sk.js +1 -0
- package/build/translations/sr-latn.js +1 -0
- package/build/translations/sr.js +1 -0
- package/build/translations/sv.js +1 -0
- package/build/translations/th.js +1 -0
- package/build/translations/tk.js +1 -0
- package/build/translations/tr.js +1 -0
- package/build/translations/ug.js +1 -0
- package/build/translations/uk.js +1 -0
- package/build/translations/ur.js +1 -0
- package/build/translations/vi.js +1 -0
- package/build/translations/zh-cn.js +1 -0
- package/build/translations/zh.js +1 -0
- package/ckeditor5-metadata.json +23 -0
- package/lang/contexts.json +53 -0
- package/lang/translations/af.po +182 -0
- package/lang/translations/ar.po +182 -0
- package/lang/translations/bg.po +182 -0
- package/lang/translations/bn.po +182 -0
- package/lang/translations/bs.po +182 -0
- package/lang/translations/ca.po +182 -0
- package/lang/translations/cs.po +182 -0
- package/lang/translations/da.po +182 -0
- package/lang/translations/de-ch.po +182 -0
- package/lang/translations/de.po +182 -0
- package/lang/translations/el.po +182 -0
- package/lang/translations/en-au.po +182 -0
- package/lang/translations/en.po +182 -0
- package/lang/translations/es-co.po +182 -0
- package/lang/translations/es.po +182 -0
- package/lang/translations/et.po +182 -0
- package/lang/translations/fa.po +182 -0
- package/lang/translations/fi.po +182 -0
- package/lang/translations/fr.po +182 -0
- package/lang/translations/gl.po +182 -0
- package/lang/translations/he.po +182 -0
- package/lang/translations/hi.po +182 -0
- package/lang/translations/hr.po +182 -0
- package/lang/translations/hu.po +182 -0
- package/lang/translations/id.po +182 -0
- package/lang/translations/it.po +182 -0
- package/lang/translations/ja.po +182 -0
- package/lang/translations/jv.po +182 -0
- package/lang/translations/ko.po +182 -0
- package/lang/translations/lt.po +182 -0
- package/lang/translations/lv.po +182 -0
- package/lang/translations/ms.po +182 -0
- package/lang/translations/nl.po +182 -0
- package/lang/translations/no.po +182 -0
- package/lang/translations/pl.po +182 -0
- package/lang/translations/pt-br.po +182 -0
- package/lang/translations/pt.po +182 -0
- package/lang/translations/ro.po +182 -0
- package/lang/translations/ru.po +182 -0
- package/lang/translations/sk.po +182 -0
- package/lang/translations/sr-latn.po +182 -0
- package/lang/translations/sr.po +182 -0
- package/lang/translations/sv.po +182 -0
- package/lang/translations/th.po +182 -0
- package/lang/translations/tk.po +182 -0
- package/lang/translations/tr.po +182 -0
- package/lang/translations/ug.po +182 -0
- package/lang/translations/uk.po +182 -0
- package/lang/translations/ur.po +182 -0
- package/lang/translations/vi.po +182 -0
- package/lang/translations/zh-cn.po +182 -0
- package/lang/translations/zh.po +182 -0
- package/package.json +38 -7
- package/src/aiassistant.d.ts +419 -0
- package/src/aiassistant.js +23 -0
- package/src/aiassistantediting.d.ts +45 -0
- package/src/aiassistantediting.js +23 -0
- package/src/aiassistantui.d.ts +46 -0
- package/src/aiassistantui.js +23 -0
- package/src/aiconnector.d.ts +44 -0
- package/src/aiconnector.js +23 -0
- package/src/augmentation.d.ts +26 -0
- package/src/augmentation.js +23 -0
- package/src/index.d.ts +9 -0
- package/src/index.js +23 -0
- package/src/ui/aiassistantcontroller.d.ts +59 -0
- package/src/ui/aiassistantcontroller.js +23 -0
- package/src/ui/dropdown/aicommandslistview.d.ts +22 -0
- package/src/ui/dropdown/aicommandslistview.js +23 -0
- package/src/ui/dropdown/buttonlabelwithhighlightview.d.ts +29 -0
- package/src/ui/dropdown/buttonlabelwithhighlightview.js +23 -0
- package/src/ui/form/aiformcontentarea.d.ts +48 -0
- package/src/ui/form/aiformcontentarea.js +23 -0
- package/src/ui/form/aiformerrorview.d.ts +26 -0
- package/src/ui/form/aiformerrorview.js +23 -0
- package/src/ui/form/aiformpromptview.d.ts +46 -0
- package/src/ui/form/aiformpromptview.js +23 -0
- package/src/ui/form/aiformtoolbarview.d.ts +41 -0
- package/src/ui/form/aiformtoolbarview.js +23 -0
- package/src/ui/form/aiformview.d.ts +131 -0
- package/src/ui/form/aiformview.js +23 -0
- package/src/ui/form/aihistorylistitemview.d.ts +18 -0
- package/src/ui/form/aihistorylistitemview.js +23 -0
- package/src/ui/form/aihistorylistview.d.ts +35 -0
- package/src/ui/form/aihistorylistview.js +23 -0
- package/src/ui/form/prompthistory.d.ts +20 -0
- package/src/ui/form/prompthistory.js +23 -0
- package/src/ui/showaiassistantcommand.d.ts +26 -0
- package/src/ui/showaiassistantcommand.js +23 -0
- package/src/utils/common-translations.d.ts +9 -0
- package/src/utils/common-translations.js +23 -0
- package/theme/ai-dropdown.css +37 -0
- package/theme/ai-form.css +203 -0
- package/theme/ai.css +98 -0
- package/theme/icons/copy.svg +1 -0
- package/theme/icons/error.svg +1 -0
- package/theme/icons/magic-wand.svg +1 -0
- package/theme/icons/robot-pencil.svg +1 -0
- package/theme/icons/submit.svg +1 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
*
|
|
5
|
+
*
|
|
6
|
+
*
|
|
7
|
+
* +---------------------------------------------------------------------------------+
|
|
8
|
+
* | |
|
|
9
|
+
* | Hello stranger! |
|
|
10
|
+
* | |
|
|
11
|
+
* | |
|
|
12
|
+
* | What you're currently looking at is the source code of a legally protected, |
|
|
13
|
+
* | proprietary software. Any attempts to deobfuscate / disassemble this code |
|
|
14
|
+
* | are forbidden and will result in legal consequences. |
|
|
15
|
+
* | |
|
|
16
|
+
* | |
|
|
17
|
+
* +---------------------------------------------------------------------------------+
|
|
18
|
+
*
|
|
19
|
+
*
|
|
20
|
+
*
|
|
21
|
+
*
|
|
22
|
+
*/
|
|
23
|
+
export function getTranslation(_0x3d8e36,_0x3cb3a2,_0x5fe0cd){const t=_0x3d8e36['t'];switch(_0x3cb3a2){case'Edit\x20or\x20review':return t('Edit\x20or\x20review');case'Improve\x20writing':return t('Improve\x20writing');case'Make\x20shorter':return t('Make\x20shorter');case'Make\x20longer':return t('Make\x20longer');case'Simplify\x20language':return t('Simplify\x20language');case'Generate\x20from\x20selection':return t('Generate\x20from\x20selection');case'Summarize':return t('Summarize');case'Continue':return t('Continue');case'Change\x20tone':return t('Change\x20tone');case'Professional':return t('Professional');case'Casual':return t('Casual');case'Direct':return t('Direct');case'Confident':return t('Confident');case'Friendly':return t('Friendly');case'Change\x20style':return t('Change\x20style');case'Business':return t('Business');case'Legal':return t('Legal');case'Journalism':return t('Journalism');case'Poetic':return t('Poetic');case'Translate':return t('Translate');case'Translate\x20to\x20%0':return t('Translate\x20to\x20%0',_0x5fe0cd);case'English':return t('English');case'Spanish':return t('Spanish');case'German':return t('German');case'Portuguese':return t('Portuguese');case'French':return t('French');case'Simplified\x20Chinese':return t('Simplified\x20Chinese');case'Hindi':return t('Hindi');case'Arabic':return t('Arabic');case'AI\x20Assistant':return t('AI\x20Assistant');case'AI\x20Commands':return t('AI\x20Commands');case'Ask\x20AI\x20to\x20edit\x20or\x20generate':return t('Ask\x20AI\x20to\x20edit\x20or\x20generate');case'Ask\x20AI\x20to\x20improve\x20generated\x20text':return t('Ask\x20AI\x20to\x20improve\x20generated\x20text');case'Copy':return t('Copy');case'Submit':return t('Submit');case'Insert\x20below':return t('Insert\x20below');case'Try\x20again':return t('Try\x20again');case'Stop':return t('Stop');case'AI\x20is\x20writing...':return t('AI\x20is\x20writing...');case'History':return t('History');case'Empty\x20history':return t('Empty\x20history');case'Ask\x20AI\x20and\x20your\x20prompts\x20will\x20be\x20listed\x20here\x20for\x20you\x20to\x20use\x20later.':return t('Ask\x20AI\x20and\x20your\x20prompts\x20will\x20be\x20listed\x20here\x20for\x20you\x20to\x20use\x20later.');case'Prompt\x20history':return t('Prompt\x20history');case'Search\x20AI\x20command':return t('Search\x20AI\x20command');case'No\x20commands\x20found':return t('No\x20commands\x20found');case'No\x20commands\x20available':return t('No\x20commands\x20available');case'Clear':return t('Clear');case'AI_REPLACE_CONTENT':return t({'id':'AI_REPLACE_CONTENT','string':'Replace'});case'AI_ERROR_AUTH_REQUEST':return t({'id':'AI_ERROR_AUTH_REQUEST','string':'Authorization\x20request\x20failed'});case'AI_ERROR_CONTEXT_LENGTH':return t({'id':'AI_ERROR_CONTEXT_LENGTH','string':'Selected\x20content\x20is\x20too\x20long'});case'AI_ERROR_MODERATION':return t({'id':'AI_ERROR_MODERATION','string':'Requested\x20query\x20does\x20not\x20pass\x20moderation\x20rules'});case'AI_ERROR_FAILED':return t({'id':'AI_ERROR_FAILED','string':'Failed\x20to\x20communicate\x20with\x20the\x20AI\x20service'});default:return'';}}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* What you're currently looking at is the source code of a legally protected, proprietary software.
|
|
3
|
+
* CKEditor 5 Collaboration is licensed under a commercial license and protected by copyright law. Where not otherwise indicated,
|
|
4
|
+
* all CKEditor 5 Collaboration content is authored by CKSource engineers and consists of CKSource-owned intellectual property.
|
|
5
|
+
*
|
|
6
|
+
* Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";
|
|
11
|
+
@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";
|
|
12
|
+
|
|
13
|
+
:root {
|
|
14
|
+
--ck-ai-dropdown-view-width: 250px;
|
|
15
|
+
--ck-ai-dropdown-view-list-max-height: 250px;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.ck.ck-ai-commands-search {
|
|
19
|
+
width: var(--ck-ai-dropdown-view-width);
|
|
20
|
+
|
|
21
|
+
& > .ck-labeled-field-view {
|
|
22
|
+
padding: var(--ck-spacing-large);
|
|
23
|
+
|
|
24
|
+
& .ck-input {
|
|
25
|
+
min-width: unset;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
& > .ck-search__results {
|
|
30
|
+
border-top: 1px solid var(--ck-color-base-border);
|
|
31
|
+
|
|
32
|
+
& > .ck-list {
|
|
33
|
+
max-height: var(--ck-ai-dropdown-view-list-max-height);
|
|
34
|
+
overflow: auto;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* What you're currently looking at is the source code of a legally protected, proprietary software.
|
|
3
|
+
* CKEditor 5 Collaboration is licensed under a commercial license and protected by copyright law. Where not otherwise indicated,
|
|
4
|
+
* all CKEditor 5 Collaboration content is authored by CKSource engineers and consists of CKSource-owned intellectual property.
|
|
5
|
+
*
|
|
6
|
+
* Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";
|
|
11
|
+
@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";
|
|
12
|
+
|
|
13
|
+
:root {
|
|
14
|
+
--ck-ai-form-view-width: 470px;
|
|
15
|
+
--ck-ai-form-content-height: 126px;
|
|
16
|
+
--ck-ai-form-content-background: hsl(0, 0%, 98%);
|
|
17
|
+
--ck-ai-form-history-font-size: .9em;
|
|
18
|
+
|
|
19
|
+
/* TODO: Move this color to CKE5 */
|
|
20
|
+
--ck-ai-form-error-background: hsl(0, 100%, 90%);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/* Note: This class name is mentioned in the guide and acts like a public API. */
|
|
24
|
+
.ck .ck-ai-form {
|
|
25
|
+
width: var(--ck-ai-form-view-width);
|
|
26
|
+
|
|
27
|
+
@mixin ck-media-phone {
|
|
28
|
+
--ck-ai-form-view-width: 350px;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
& .ck-ai-form-content {
|
|
32
|
+
padding: var(--ck-spacing-large);
|
|
33
|
+
width: 100%;
|
|
34
|
+
|
|
35
|
+
& .ck-input {
|
|
36
|
+
width: 100%;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
& .ck-ai-form__content-area-wrapper {
|
|
40
|
+
width: 100%;
|
|
41
|
+
max-height: var(--ck-ai-form-content-height);
|
|
42
|
+
overflow-y: auto;
|
|
43
|
+
border: 1px solid var(--ck-color-base-border);
|
|
44
|
+
border-radius: 2px;
|
|
45
|
+
|
|
46
|
+
&:focus {
|
|
47
|
+
outline: none;
|
|
48
|
+
border: var(--ck-focus-ring);
|
|
49
|
+
box-shadow: var(--ck-focus-outer-shadow), 0 0;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
& .ck-ai-form__content-area {
|
|
54
|
+
display: flex;
|
|
55
|
+
background-color: var(--ck-ai-form-content-background);
|
|
56
|
+
|
|
57
|
+
&.ck-ai-form__content-area--processing {
|
|
58
|
+
--ck-color-text: var(--ck-color-input-disabled-text);
|
|
59
|
+
background-color: var(--ck-color-input-disabled-background);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/* Note: This class name is mentioned in the guide and acts like a public API */
|
|
63
|
+
& .ck-ai-form__content-field {
|
|
64
|
+
width: 100%;
|
|
65
|
+
white-space: normal;
|
|
66
|
+
padding: var(--ck-spacing-tiny) var(--ck-spacing-medium);
|
|
67
|
+
padding-right: 0;
|
|
68
|
+
min-height: calc( var(--ck-line-height-base) * var(--ck-font-size-base) );
|
|
69
|
+
box-sizing: content-box;
|
|
70
|
+
|
|
71
|
+
& > * {
|
|
72
|
+
white-space: normal;
|
|
73
|
+
color: inherit;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
& .ck-spinner-container {
|
|
78
|
+
margin-right: var(--ck-spacing-medium);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
& .ck-ai-form__copy-button-wrapper {
|
|
82
|
+
display: flex;
|
|
83
|
+
flex-direction: column-reverse;
|
|
84
|
+
padding-left: 2px;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
& .ck-ai-form__copy-button {
|
|
88
|
+
position: sticky;
|
|
89
|
+
right: 1px;
|
|
90
|
+
bottom: 1px;
|
|
91
|
+
padding: 4px;
|
|
92
|
+
min-height: unset;
|
|
93
|
+
min-width: unset;
|
|
94
|
+
|
|
95
|
+
& svg {
|
|
96
|
+
--ck-icon-size: 16px;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
&.ck-ai-form__copy-button--copied {
|
|
100
|
+
color: inherit;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
& .ck-ai-form__toolbar {
|
|
106
|
+
border: none;
|
|
107
|
+
padding: 0;
|
|
108
|
+
margin-top: var(--ck-spacing-medium);
|
|
109
|
+
margin-bottom: calc( 2 * var(--ck-spacing-medium) );
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
& .ck-ai-form__loader {
|
|
113
|
+
display: flex;
|
|
114
|
+
align-items: center;
|
|
115
|
+
|
|
116
|
+
& .ck-spinner {
|
|
117
|
+
box-sizing: border-box;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
& .ck-autocomplete {
|
|
122
|
+
display: flex;
|
|
123
|
+
justify-content: space-between;
|
|
124
|
+
|
|
125
|
+
& > .ck-labeled-field-view {
|
|
126
|
+
flex-grow: 1;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
& > .ck.ck-button {
|
|
130
|
+
margin-left: var(--ck-spacing-medium);
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
& > .ck-labeled-field-view .ck-button {
|
|
134
|
+
position: absolute;
|
|
135
|
+
font-size: var(--ck-font-size-tiny);
|
|
136
|
+
right: var(--ck-spacing-medium);
|
|
137
|
+
bottom: var(--ck-spacing-small);
|
|
138
|
+
top: var(--ck-spacing-small);
|
|
139
|
+
padding: 4px;
|
|
140
|
+
min-height: unset;
|
|
141
|
+
min-width: unset;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
& .ck-textarea {
|
|
145
|
+
padding-right: 30px;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
/* Prompt history group */
|
|
149
|
+
& .ck-search__results .ck-list .ck-list__group {
|
|
150
|
+
display: grid;
|
|
151
|
+
grid-template-columns: auto 1fr;
|
|
152
|
+
grid-template-rows: auto;
|
|
153
|
+
grid-column-gap: 0px;
|
|
154
|
+
grid-row-gap: 0px;
|
|
155
|
+
|
|
156
|
+
/* History group label */
|
|
157
|
+
& > span {
|
|
158
|
+
grid-area: 1 / 1 / 2 / 2;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
/* Clear button in the history */
|
|
162
|
+
& > .ck-button {
|
|
163
|
+
padding: 0;
|
|
164
|
+
min-height: auto;
|
|
165
|
+
grid-area: 1 / 2 / 2 / 3;
|
|
166
|
+
font-size: var(--ck-ai-form-history-font-size);
|
|
167
|
+
justify-self: start;
|
|
168
|
+
background: none;
|
|
169
|
+
|
|
170
|
+
&:hover .ck-button__label {
|
|
171
|
+
text-decoration: underline;
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
& > .ck-list {
|
|
176
|
+
grid-area: 2 / 1 / 3 / 3;
|
|
177
|
+
|
|
178
|
+
/* Prompts can be very long. We need to display them whole. */
|
|
179
|
+
& .ck-list__item .ck-button .ck-button__label {
|
|
180
|
+
white-space: nowrap;
|
|
181
|
+
overflow: hidden;
|
|
182
|
+
max-width: 100%;
|
|
183
|
+
text-overflow: ellipsis;
|
|
184
|
+
font-size: var(--ck-ai-form-history-font-size);
|
|
185
|
+
line-height: var(--ck-line-height-base);
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
& .ck-ai-form__error {
|
|
193
|
+
display: flex;
|
|
194
|
+
justify-content: center;
|
|
195
|
+
align-items: center;
|
|
196
|
+
padding: var(--ck-spacing-medium);
|
|
197
|
+
background-color: var(--ck-ai-form-error-background);
|
|
198
|
+
color: var(--ck-color-base-text);
|
|
199
|
+
border-radius: 2px;
|
|
200
|
+
margin-bottom: var(--ck-spacing-medium);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
|
package/theme/ai.css
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* What you're currently looking at is the source code of a legally protected, proprietary software.
|
|
3
|
+
* CKEditor 5 Collaboration is licensed under a commercial license and protected by copyright law. Where not otherwise indicated,
|
|
4
|
+
* all CKEditor 5 Collaboration content is authored by CKSource engineers and consists of CKSource-owned intellectual property.
|
|
5
|
+
*
|
|
6
|
+
* Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
/*
|
|
11
|
+
* These definitions bring violet accents (tint) across the AI UI.
|
|
12
|
+
*/
|
|
13
|
+
.ck-ai-assistant-ui {
|
|
14
|
+
--ck-color-button-default-hover-background: hsl(262.1,100%,96.3%);
|
|
15
|
+
--ck-color-button-default-active-background: hsl(262.1,100%,96.3%);
|
|
16
|
+
|
|
17
|
+
--ck-color-button-on-background: hsl(262.1,100%,96.3%);
|
|
18
|
+
--ck-color-button-on-hover-background: hsl(262.5,60%,92.2%);
|
|
19
|
+
--ck-color-button-on-active-background: hsl(262.1,100%,96.3%);
|
|
20
|
+
--ck-color-button-on-disabled-background: hsl(262.1,100%,96.3%);
|
|
21
|
+
--ck-color-button-on-color: hsl(263.2,59.2%,52%);
|
|
22
|
+
|
|
23
|
+
--ck-color-button-action-background: hsl(263.2,59.2%,52%);
|
|
24
|
+
--ck-color-button-action-hover-background: hsl(262.6,58.9%,49.6%);
|
|
25
|
+
--ck-color-button-action-active-background: hsl(262.6,58.9%,49.6%);
|
|
26
|
+
--ck-color-button-action-disabled-background: hsl(263.8,59.3%,75.9%);
|
|
27
|
+
|
|
28
|
+
--ck-color-list-button-hover-background: hsl(262.1,100%,96.3%);
|
|
29
|
+
|
|
30
|
+
--ck-ai-form-content-background: hsl(0,0%,97.6%);
|
|
31
|
+
|
|
32
|
+
& .ck-ai-form__submit {
|
|
33
|
+
border-color: var(--ck-color-button-action-background);
|
|
34
|
+
color: var(--ck-color-button-action-background);
|
|
35
|
+
|
|
36
|
+
&.ck-disabled {
|
|
37
|
+
border-color: var(--ck-color-button-action-disabled-background);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
&.ck-ai-commands-dropdown > .ck-button:hover,
|
|
42
|
+
&.ck-ai-assistant-button:hover {
|
|
43
|
+
color: var(--ck-color-button-on-color);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
/*
|
|
49
|
+
* Classes used by the "fake visual selection" displayed in the content when an input
|
|
50
|
+
* in the AI UI has focus (the browser does not render the native selection in this state).
|
|
51
|
+
*
|
|
52
|
+
* Narrow down to <span> to prevent changing background for widgets and nested editables.
|
|
53
|
+
*/
|
|
54
|
+
.ck span.ck-fake-ai-selection {
|
|
55
|
+
background: var(--ck-color-link-fake-selection);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
/* A collapsed fake visual selection. */
|
|
59
|
+
.ck .ck-fake-ai-selection_collapsed {
|
|
60
|
+
height: 100%;
|
|
61
|
+
border-right: 1px solid var(--ck-color-base-text);
|
|
62
|
+
margin-right: -1px;
|
|
63
|
+
outline: solid 1px hsla(0, 0%, 100%, .5);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/*
|
|
67
|
+
* Styles of the AI response field. The margins, font sizes and line-heights have been reduced
|
|
68
|
+
* to save space.
|
|
69
|
+
*
|
|
70
|
+
* Note: This class name is mentioned in the guide and acts like a public API.
|
|
71
|
+
*/
|
|
72
|
+
.ck.ck-content.ck-ai-form__content-field {
|
|
73
|
+
& h2 {
|
|
74
|
+
font-size: 1.3em;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
& h3 {
|
|
78
|
+
font-size: 1.2em;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
& h4, & h5, & h6 {
|
|
82
|
+
font-size: 1.1em;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
& h2, & h3, & h4, & h5, & h6, & p, & ul, & ol {
|
|
86
|
+
margin-block-start: .5em;
|
|
87
|
+
margin-block-end: .5em;
|
|
88
|
+
line-height: 1.7em;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
& > :first-child {
|
|
92
|
+
margin-top: 0;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
& > :last-child {
|
|
96
|
+
margin-bottom: 0;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M5 2.801a.7.7 0 0 0-.7.7v11.5a.8.8 0 0 1-1.6 0v-11.5a2.3 2.3 0 0 1 2.3-2.3h6.5a.8.8 0 0 1 0 1.6H5Zm.7 3.7a2.3 2.3 0 0 1 2.3-2.3h7a2.3 2.3 0 0 1 2.3 2.3v10a2.3 2.3 0 0 1-2.3 2.3H8a2.3 2.3 0 0 1-2.3-2.3v-10Zm2.3-.7a.7.7 0 0 0-.7.7v10a.7.7 0 0 0 .7.7h7a.7.7 0 0 0 .7-.7v-10a.7.7 0 0 0-.7-.7H8Z"/></svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M9.9 4.385a1.2 1.2 0 0 0-.44.44h.002l-5.284 9.15a1.2 1.2 0 0 0 1.04 1.8h10.564a1.2 1.2 0 0 0 1.04-1.8l-5.282-9.15a1.2 1.2 0 0 0-1.64-.44Zm.05 8.363a.301.301 0 0 1 .115-.023h.9a.301.301 0 0 1 .3.3v.9a.3.3 0 0 1-.3.3h-.9a.3.3 0 0 1-.3-.3v-.9a.3.3 0 0 1 .185-.277Zm-.185-4.723a.3.3 0 0 1 .3-.3h.9a.3.3 0 0 1 .3.3v3.4a.3.3 0 0 1-.3.3h-.9a.301.301 0 0 1-.3-.3v-3.4Z"/></svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M15.346 9.422a.151.151 0 0 1 .284 0l.548 1.484a.152.152 0 0 0 .09.089l1.483.549a.151.151 0 0 1 0 .284l-1.483.548a.151.151 0 0 0-.09.09l-.548 1.483a.152.152 0 0 1-.142.1.151.151 0 0 1-.142-.1l-.549-1.483a.15.15 0 0 0-.09-.09l-1.483-.548a.15.15 0 0 1 0-.284l1.484-.549a.152.152 0 0 0 .089-.09l.549-1.483Z"/><path d="M16.306 1.742a.151.151 0 0 1 .284 0l.549 1.483a.15.15 0 0 0 .089.09l1.483.548a.151.151 0 0 1 .072.229.151.151 0 0 1-.072.055l-1.483.549a.15.15 0 0 0-.09.09l-.548 1.482a.151.151 0 0 1-.284 0l-.549-1.483a.15.15 0 0 0-.09-.09l-1.483-.548a.151.151 0 0 1 0-.284l1.484-.549a.152.152 0 0 0 .09-.089l.548-1.483Z"/><path d="M7.665 1.742a.151.151 0 0 1 .284 0l.549 1.483a.151.151 0 0 0 .09.09l1.482.548a.151.151 0 0 1 .072.229.151.151 0 0 1-.072.055l-1.483.549a.151.151 0 0 0-.09.09L7.95 6.267a.151.151 0 0 1-.284 0l-.549-1.483a.151.151 0 0 0-.089-.09l-1.483-.548a.151.151 0 0 1 0-.284l1.483-.549a.151.151 0 0 0 .09-.089l.548-1.483-.001.001Z"/><path d="M14.72 7.946a.848.848 0 0 0 .25-.591.824.824 0 0 0-.241-.588l-1.943-1.938a.812.812 0 0 0-.588-.241.838.838 0 0 0-.591.25l-1.545 1.539 3.115 3.115 1.542-1.546h.001Z"/><path clip-rule="evenodd" d="M1.19 15.636a.96.96 0 0 1 .281-.679l7.835-7.834 3.121 3.12-7.834 7.835a.959.959 0 0 1-1.358 0l-1.764-1.764a.96.96 0 0 1-.28-.678Zm9.22-5.391-1.121-1.12-6.479 6.478 1.121 1.121 6.479-6.479Z"/></svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M9.61 2.66a1.406 1.406 0 1 0-1.407 0v.891H3.28a2.11 2.11 0 0 0-2.11 2.11v10.312a2.11 2.11 0 0 0 2.11 2.109h5.684l-.054-1.157.18-.25H3.28a.703.703 0 0 1-.703-.702V5.66c0-.389.315-.704.703-.704h11.25c.388 0 .703.315.703.704v2.484l.358-.497a2.492 2.492 0 0 1 1.048-.84V5.66a2.11 2.11 0 0 0-2.11-2.11H9.61v-.89Z"/><path d="M5.625 10.817c.518 0 .937-.63.937-1.407 0-.776-.42-1.406-.937-1.406-.518 0-.938.63-.938 1.406 0 .777.42 1.407.938 1.407Z"/><path d="M13.125 9.41c0 .777-.42 1.407-.938 1.407s-.937-.63-.937-1.407c0-.776.42-1.406.937-1.406.518 0 .938.63.938 1.406Z"/><path d="M.937 8.004A.937.937 0 0 0 0 8.942v1.875c0 .517.42.937.937.937v-3.75Z"/><path d="M6.128 12.51a.782.782 0 0 1 1.085.216c.272.408.907.707 1.693.707s1.421-.3 1.693-.707a.782.782 0 0 1 1.302.868c-.666 1-1.906 1.403-2.995 1.403-1.089 0-2.329-.404-2.995-1.403a.782.782 0 0 1 .217-1.085Z"/><path d="m16.987 8.91-.622.864 2.879 2.074.622-.864a.71.71 0 0 0-.161-.99l-1.728-1.245a.71.71 0 0 0-.99.161Z"/><path d="M11.635 19.951a.355.355 0 0 1-.449-.31l-.214-2.38 4.978-6.911 2.88 2.074-4.978 6.91-2.217.617Z"/></svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M15.875 4.419a.75.75 0 0 0-1.5 0v7.25H6.818l2.33-1.955a.75.75 0 0 0-.963-1.15l-3.792 3.182a.75.75 0 0 0-.17.945c.046.11.118.208.21.284l3.788 3.18a.75.75 0 1 0 .965-1.149l-2.19-1.837h7.629c.69 0 1.25-.56 1.25-1.25v-7.5Z"/></svg>
|