@ckeditor/ckeditor5-basic-styles 0.0.0-internal-20260121.0 → 0.0.0-internal-20260224.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/LICENSE.md +5 -2
- package/README.md +5 -2
- package/ckeditor5-metadata.json +7 -7
- package/{src → dist}/attributecommand.d.ts +1 -1
- package/{src → dist}/bold/boldediting.d.ts +1 -1
- package/{src → dist}/bold/boldui.d.ts +1 -1
- package/{src → dist}/bold.d.ts +1 -1
- package/{src → dist}/code/codeediting.d.ts +2 -2
- package/{src → dist}/code/codeui.d.ts +1 -1
- package/{src → dist}/code.d.ts +1 -1
- package/dist/index.js +12 -3
- package/dist/index.js.map +1 -1
- package/{src → dist}/italic/italicediting.d.ts +1 -1
- package/{src → dist}/italic/italicui.d.ts +1 -1
- package/{src → dist}/italic.d.ts +1 -1
- package/{src → dist}/strikethrough/strikethroughediting.d.ts +1 -1
- package/{src → dist}/strikethrough/strikethroughui.d.ts +1 -1
- package/{src → dist}/strikethrough.d.ts +1 -1
- package/{src → dist}/subscript/subscriptediting.d.ts +1 -1
- package/{src → dist}/subscript/subscriptui.d.ts +1 -1
- package/{src → dist}/subscript.d.ts +1 -1
- package/{src → dist}/superscript/superscriptediting.d.ts +1 -1
- package/{src → dist}/superscript/superscriptui.d.ts +1 -1
- package/{src → dist}/superscript.d.ts +1 -1
- package/{src → dist}/underline/underlineediting.d.ts +1 -1
- package/{src → dist}/underline/underlineui.d.ts +1 -1
- package/{src → dist}/underline.d.ts +1 -1
- package/{src → dist}/utils.d.ts +2 -2
- package/package.json +24 -47
- package/build/basic-styles.js +0 -5
- package/build/translations/af.js +0 -1
- package/build/translations/ar.js +0 -1
- package/build/translations/ast.js +0 -1
- package/build/translations/az.js +0 -1
- package/build/translations/be.js +0 -1
- package/build/translations/bg.js +0 -1
- package/build/translations/bn.js +0 -1
- package/build/translations/bs.js +0 -1
- package/build/translations/ca.js +0 -1
- package/build/translations/cs.js +0 -1
- package/build/translations/da.js +0 -1
- package/build/translations/de-ch.js +0 -1
- package/build/translations/de.js +0 -1
- package/build/translations/el.js +0 -1
- package/build/translations/en-au.js +0 -1
- package/build/translations/en-gb.js +0 -1
- package/build/translations/eo.js +0 -1
- package/build/translations/es-co.js +0 -1
- package/build/translations/es.js +0 -1
- package/build/translations/et.js +0 -1
- package/build/translations/eu.js +0 -1
- package/build/translations/fa.js +0 -1
- package/build/translations/fi.js +0 -1
- package/build/translations/fr.js +0 -1
- package/build/translations/gl.js +0 -1
- package/build/translations/gu.js +0 -1
- package/build/translations/he.js +0 -1
- package/build/translations/hi.js +0 -1
- package/build/translations/hr.js +0 -1
- package/build/translations/hu.js +0 -1
- package/build/translations/hy.js +0 -1
- package/build/translations/id.js +0 -1
- package/build/translations/it.js +0 -1
- package/build/translations/ja.js +0 -1
- package/build/translations/jv.js +0 -1
- package/build/translations/kk.js +0 -1
- package/build/translations/km.js +0 -1
- package/build/translations/kn.js +0 -1
- package/build/translations/ko.js +0 -1
- package/build/translations/ku.js +0 -1
- package/build/translations/lt.js +0 -1
- package/build/translations/lv.js +0 -1
- package/build/translations/ms.js +0 -1
- package/build/translations/nb.js +0 -1
- package/build/translations/ne.js +0 -1
- package/build/translations/nl.js +0 -1
- package/build/translations/no.js +0 -1
- package/build/translations/oc.js +0 -1
- package/build/translations/pl.js +0 -1
- package/build/translations/pt-br.js +0 -1
- package/build/translations/pt.js +0 -1
- package/build/translations/ro.js +0 -1
- package/build/translations/ru.js +0 -1
- package/build/translations/si.js +0 -1
- package/build/translations/sk.js +0 -1
- package/build/translations/sl.js +0 -1
- package/build/translations/sq.js +0 -1
- package/build/translations/sr-latn.js +0 -1
- package/build/translations/sr.js +0 -1
- package/build/translations/sv.js +0 -1
- package/build/translations/th.js +0 -1
- package/build/translations/ti.js +0 -1
- package/build/translations/tk.js +0 -1
- package/build/translations/tr.js +0 -1
- package/build/translations/tt.js +0 -1
- package/build/translations/ug.js +0 -1
- package/build/translations/uk.js +0 -1
- package/build/translations/ur.js +0 -1
- package/build/translations/uz.js +0 -1
- package/build/translations/vi.js +0 -1
- package/build/translations/zh-cn.js +0 -1
- package/build/translations/zh.js +0 -1
- package/lang/contexts.json +0 -14
- package/lang/translations/af.po +0 -60
- package/lang/translations/ar.po +0 -60
- package/lang/translations/ast.po +0 -60
- package/lang/translations/az.po +0 -60
- package/lang/translations/be.po +0 -60
- package/lang/translations/bg.po +0 -60
- package/lang/translations/bn.po +0 -60
- package/lang/translations/bs.po +0 -60
- package/lang/translations/ca.po +0 -60
- package/lang/translations/cs.po +0 -60
- package/lang/translations/da.po +0 -60
- package/lang/translations/de-ch.po +0 -60
- package/lang/translations/de.po +0 -60
- package/lang/translations/el.po +0 -60
- package/lang/translations/en-au.po +0 -60
- package/lang/translations/en-gb.po +0 -60
- package/lang/translations/en.po +0 -60
- package/lang/translations/eo.po +0 -60
- package/lang/translations/es-co.po +0 -60
- package/lang/translations/es.po +0 -60
- package/lang/translations/et.po +0 -60
- package/lang/translations/eu.po +0 -60
- package/lang/translations/fa.po +0 -60
- package/lang/translations/fi.po +0 -60
- package/lang/translations/fr.po +0 -60
- package/lang/translations/gl.po +0 -60
- package/lang/translations/gu.po +0 -60
- package/lang/translations/he.po +0 -60
- package/lang/translations/hi.po +0 -60
- package/lang/translations/hr.po +0 -60
- package/lang/translations/hu.po +0 -60
- package/lang/translations/hy.po +0 -60
- package/lang/translations/id.po +0 -60
- package/lang/translations/it.po +0 -60
- package/lang/translations/ja.po +0 -60
- package/lang/translations/jv.po +0 -60
- package/lang/translations/kk.po +0 -60
- package/lang/translations/km.po +0 -60
- package/lang/translations/kn.po +0 -60
- package/lang/translations/ko.po +0 -60
- package/lang/translations/ku.po +0 -60
- package/lang/translations/lt.po +0 -60
- package/lang/translations/lv.po +0 -60
- package/lang/translations/ms.po +0 -60
- package/lang/translations/nb.po +0 -60
- package/lang/translations/ne.po +0 -60
- package/lang/translations/nl.po +0 -60
- package/lang/translations/no.po +0 -60
- package/lang/translations/oc.po +0 -60
- package/lang/translations/pl.po +0 -60
- package/lang/translations/pt-br.po +0 -60
- package/lang/translations/pt.po +0 -60
- package/lang/translations/ro.po +0 -60
- package/lang/translations/ru.po +0 -60
- package/lang/translations/si.po +0 -60
- package/lang/translations/sk.po +0 -60
- package/lang/translations/sl.po +0 -60
- package/lang/translations/sq.po +0 -60
- package/lang/translations/sr-latn.po +0 -60
- package/lang/translations/sr.po +0 -60
- package/lang/translations/sv.po +0 -60
- package/lang/translations/th.po +0 -60
- package/lang/translations/ti.po +0 -60
- package/lang/translations/tk.po +0 -60
- package/lang/translations/tr.po +0 -60
- package/lang/translations/tt.po +0 -60
- package/lang/translations/ug.po +0 -60
- package/lang/translations/uk.po +0 -60
- package/lang/translations/ur.po +0 -60
- package/lang/translations/uz.po +0 -60
- package/lang/translations/vi.po +0 -60
- package/lang/translations/zh-cn.po +0 -60
- package/lang/translations/zh.po +0 -60
- package/src/attributecommand.js +0 -109
- package/src/augmentation.js +0 -5
- package/src/bold/boldediting.js +0 -78
- package/src/bold/boldui.js +0 -47
- package/src/bold.js +0 -39
- package/src/code/codeediting.js +0 -73
- package/src/code/codeui.js +0 -47
- package/src/code.js +0 -40
- package/src/index.js +0 -31
- package/src/italic/italicediting.js +0 -68
- package/src/italic/italicui.js +0 -47
- package/src/italic.js +0 -39
- package/src/strikethrough/strikethroughediting.js +0 -70
- package/src/strikethrough/strikethroughui.js +0 -47
- package/src/strikethrough.js +0 -39
- package/src/subscript/subscriptediting.js +0 -56
- package/src/subscript/subscriptui.js +0 -46
- package/src/subscript.js +0 -36
- package/src/superscript/superscriptediting.js +0 -56
- package/src/superscript/superscriptui.js +0 -46
- package/src/superscript.js +0 -36
- package/src/underline/underlineediting.js +0 -65
- package/src/underline/underlineui.js +0 -47
- package/src/underline.js +0 -39
- package/src/utils.js +0 -40
- package/theme/code.css +0 -14
- /package/{src → dist}/augmentation.d.ts +0 -0
- /package/{src → dist}/index.d.ts +0 -0
package/LICENSE.md
CHANGED
|
@@ -4,9 +4,12 @@ Software License Agreement
|
|
|
4
4
|
**CKEditor 5 Basic styles feature** (https://github.com/ckeditor/ckeditor5)<br>
|
|
5
5
|
Copyright (c) 2003–2026, [CKSource Holding sp. z o.o.](https://cksource.com) All rights reserved.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Licensed under a dual-license model, this software is available under:
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
* the [GNU General Public License Version 2 or later](https://www.gnu.org/licenses/gpl.html),
|
|
10
|
+
* or commercial license terms from CKSource Holding sp. z o.o.
|
|
11
|
+
|
|
12
|
+
For more information, see: [https://ckeditor.com/legal/ckeditor-licensing-options](https://ckeditor.com/legal/ckeditor-licensing-options).
|
|
10
13
|
|
|
11
14
|
Sources of Intellectual Property Included in CKEditor 5
|
|
12
15
|
------------------------------------------------------------
|
package/README.md
CHANGED
|
@@ -29,6 +29,9 @@ See the [`@ckeditor/ckeditor5-basic-styles` package](https://ckeditor.com/docs/c
|
|
|
29
29
|
|
|
30
30
|
## License
|
|
31
31
|
|
|
32
|
-
|
|
32
|
+
Licensed under a dual-license model, this software is available under:
|
|
33
33
|
|
|
34
|
-
|
|
34
|
+
* the [GNU General Public License Version 2 or later](https://www.gnu.org/licenses/gpl.html),
|
|
35
|
+
* or commercial license terms from CKSource Holding sp. z o.o.
|
|
36
|
+
|
|
37
|
+
For more information, see: [https://ckeditor.com/legal/ckeditor-licensing-options](https://ckeditor.com/legal/ckeditor-licensing-options).
|
package/ckeditor5-metadata.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"className": "Bold",
|
|
6
6
|
"description": "Implements bold formatting support. It is a part of the basic text styles package.",
|
|
7
7
|
"docs": "features/basic-styles.html",
|
|
8
|
-
"path": "src/bold.
|
|
8
|
+
"path": "src/bold.ts",
|
|
9
9
|
"uiComponents": [
|
|
10
10
|
{
|
|
11
11
|
"type": "Button",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"className": "Code",
|
|
25
25
|
"description": "Implements inline code formatting support. It is a part of the basic text styles package.",
|
|
26
26
|
"docs": "features/basic-styles.html",
|
|
27
|
-
"path": "src/code.
|
|
27
|
+
"path": "src/code.ts",
|
|
28
28
|
"uiComponents": [
|
|
29
29
|
{
|
|
30
30
|
"type": "Button",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"className": "Italic",
|
|
44
44
|
"description": "Implements italic formatting support. It is a part of the basic text styles package.",
|
|
45
45
|
"docs": "features/basic-styles.html",
|
|
46
|
-
"path": "src/italic.
|
|
46
|
+
"path": "src/italic.ts",
|
|
47
47
|
"uiComponents": [
|
|
48
48
|
{
|
|
49
49
|
"type": "Button",
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
"className": "Strikethrough",
|
|
63
63
|
"description": "Implements strikethrough formatting support. It is a part of the basic text styles package.",
|
|
64
64
|
"docs": "features/basic-styles.html",
|
|
65
|
-
"path": "src/strikethrough.
|
|
65
|
+
"path": "src/strikethrough.ts",
|
|
66
66
|
"uiComponents": [
|
|
67
67
|
{
|
|
68
68
|
"type": "Button",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"className": "Subscript",
|
|
82
82
|
"description": "Implements subscript formatting support. It is a part of the basic text styles package.",
|
|
83
83
|
"docs": "features/basic-styles.html",
|
|
84
|
-
"path": "src/subscript.
|
|
84
|
+
"path": "src/subscript.ts",
|
|
85
85
|
"uiComponents": [
|
|
86
86
|
{
|
|
87
87
|
"type": "Button",
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
"className": "Superscript",
|
|
101
101
|
"description": "Implements superscript formatting support. It is a part of the basic text styles package.",
|
|
102
102
|
"docs": "features/basic-styles.html",
|
|
103
|
-
"path": "src/superscript.
|
|
103
|
+
"path": "src/superscript.ts",
|
|
104
104
|
"uiComponents": [
|
|
105
105
|
{
|
|
106
106
|
"type": "Button",
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
"className": "Underline",
|
|
120
120
|
"description": "Implements underline formatting support. It is a part of the basic text styles package.",
|
|
121
121
|
"docs": "features/basic-styles.html",
|
|
122
|
-
"path": "src/underline.
|
|
122
|
+
"path": "src/underline.ts",
|
|
123
123
|
"uiComponents": [
|
|
124
124
|
{
|
|
125
125
|
"type": "Button",
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module basic-styles/attributecommand
|
|
7
7
|
*/
|
|
8
|
-
import { Command, type Editor } from 'ckeditor5
|
|
8
|
+
import { Command, type Editor } from '@ckeditor/ckeditor5-core';
|
|
9
9
|
/**
|
|
10
10
|
* An extension of the base {@link module:core/command~Command} class, which provides utilities for a command
|
|
11
11
|
* that toggles a single attribute on a text or an element.
|
package/{src → dist}/bold.d.ts
RENAMED
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module basic-styles/code/codeediting
|
|
7
7
|
*/
|
|
8
|
-
import { Plugin } from 'ckeditor5
|
|
9
|
-
import { TwoStepCaretMovement } from 'ckeditor5
|
|
8
|
+
import { Plugin } from '@ckeditor/ckeditor5-core';
|
|
9
|
+
import { TwoStepCaretMovement } from '@ckeditor/ckeditor5-typing';
|
|
10
10
|
/**
|
|
11
11
|
* The code editing feature.
|
|
12
12
|
*
|
package/{src → dist}/code.d.ts
RENAMED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @module basic-styles/code
|
|
7
7
|
*/
|
|
8
|
-
import { Plugin } from 'ckeditor5
|
|
8
|
+
import { Plugin } from '@ckeditor/ckeditor5-core';
|
|
9
9
|
import { CodeEditing } from './code/codeediting.js';
|
|
10
10
|
import { CodeUI } from './code/codeui.js';
|
|
11
11
|
import '../theme/code.css';
|
package/dist/index.js
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
4
|
*/
|
|
5
5
|
import { Command, Plugin } from '@ckeditor/ckeditor5-core/dist/index.js';
|
|
6
|
+
import { ModelDocumentSelection } from '@ckeditor/ckeditor5-engine/dist/index.js';
|
|
6
7
|
import { IconBold, IconCode, IconItalic, IconStrikethrough, IconSubscript, IconSuperscript, IconUnderline } from '@ckeditor/ckeditor5-icons/dist/index.js';
|
|
7
8
|
import { MenuBarMenuListItemButtonView, ButtonView } from '@ckeditor/ckeditor5-ui/dist/index.js';
|
|
8
9
|
import { TwoStepCaretMovement, inlineHighlight } from '@ckeditor/ckeditor5-typing/dist/index.js';
|
|
@@ -66,12 +67,20 @@ import { TwoStepCaretMovement, inlineHighlight } from '@ckeditor/ckeditor5-typin
|
|
|
66
67
|
writer.removeSelectionAttribute(this.attributeKey);
|
|
67
68
|
}
|
|
68
69
|
} else {
|
|
69
|
-
const ranges = model.schema.getValidRanges(selection.getRanges(), this.attributeKey
|
|
70
|
+
const ranges = model.schema.getValidRanges(selection.getRanges(), this.attributeKey, {
|
|
71
|
+
includeEmptyRanges: true
|
|
72
|
+
});
|
|
70
73
|
for (const range of ranges){
|
|
74
|
+
let itemOrRange = range;
|
|
75
|
+
let attributeKey = this.attributeKey;
|
|
76
|
+
if (range.isCollapsed) {
|
|
77
|
+
itemOrRange = range.start.parent;
|
|
78
|
+
attributeKey = ModelDocumentSelection._getStoreAttributeKey(this.attributeKey);
|
|
79
|
+
}
|
|
71
80
|
if (value) {
|
|
72
|
-
writer.setAttribute(
|
|
81
|
+
writer.setAttribute(attributeKey, value, itemOrRange);
|
|
73
82
|
} else {
|
|
74
|
-
writer.removeAttribute(
|
|
83
|
+
writer.removeAttribute(attributeKey, itemOrRange);
|
|
75
84
|
}
|
|
76
85
|
}
|
|
77
86
|
}
|