@ckeditor/ckeditor5-style 44.3.0-alpha.7 → 45.0.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/LICENSE.md +4 -0
- package/build/style.js +1 -1
- package/build/translations/be.js +1 -0
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/translations/be.d.ts +8 -0
- package/dist/translations/be.js +5 -0
- package/dist/translations/be.umd.js +11 -0
- package/lang/translations/be.po +28 -0
- package/package.json +10 -10
- package/src/integrations/link.js +2 -0
- package/src/integrations/list.js +3 -0
- package/src/integrations/table.js +2 -0
- package/src/stylecommand.js +8 -0
- package/src/styleutils.js +2 -1
- package/src/ui/stylegridbuttonview.js +8 -0
- package/src/ui/stylegridview.js +12 -0
- package/src/ui/stylegroupview.js +8 -0
- package/src/ui/stylepanelview.js +28 -0
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2025, 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
|
+
import type { Translations } from '@ckeditor/ckeditor5-utils';
|
|
7
|
+
declare const translations: Translations;
|
|
8
|
+
export default translations;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2025, 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
|
+
export default {"be":{"dictionary":{"Styles":"Стылі","Multiple styles":"Некалькі стыляў","Block styles":"Стылі для блокаў","Text styles":"Стылі для тэксту"},getPluralForm(n){return (n % 10 == 1 && n % 100 != 11 ? 0 : n % 10 >= 2 && n % 10 <= 4 && (n % 100 < 10 || n % 100 >= 20) ? 1 : 2);}}}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2025, 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
|
+
( e => {
|
|
7
|
+
const { [ 'be' ]: { dictionary, getPluralForm } } = {"be":{"dictionary":{"Styles":"Стылі","Multiple styles":"Некалькі стыляў","Block styles":"Стылі для блокаў","Text styles":"Стылі для тэксту"},getPluralForm(n){return (n % 10 == 1 && n % 100 != 11 ? 0 : n % 10 >= 2 && n % 10 <= 4 && (n % 100 < 10 || n % 100 >= 20) ? 1 : 2);}}};
|
|
8
|
+
e[ 'be' ] ||= { dictionary: {}, getPluralForm: null };
|
|
9
|
+
e[ 'be' ].dictionary = Object.assign( e[ 'be' ].dictionary, dictionary );
|
|
10
|
+
e[ 'be' ].getPluralForm = getPluralForm;
|
|
11
|
+
} )( window.CKEDITOR_TRANSLATIONS ||= {} );
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
|
|
2
|
+
#
|
|
3
|
+
# Want to contribute to this file? Submit your changes via a GitHub Pull Request.
|
|
4
|
+
#
|
|
5
|
+
# Check out the official contributor's guide:
|
|
6
|
+
# https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
|
|
7
|
+
#
|
|
8
|
+
msgid ""
|
|
9
|
+
msgstr ""
|
|
10
|
+
"Language: be\n"
|
|
11
|
+
"Plural-Forms: nplurals=3; plural=(n % 10 == 1 && n % 100 != 11 ? 0 : n % 10 >= 2 && n % 10 <= 4 && (n % 100 < 10 || n % 100 >= 20) ? 1 : 2);\n"
|
|
12
|
+
"Content-Type: text/plain; charset=UTF-8\n"
|
|
13
|
+
|
|
14
|
+
msgctxt "The label of the styles dropdown button in the toolbar displayed when no style is currently active."
|
|
15
|
+
msgid "Styles"
|
|
16
|
+
msgstr "Стылі"
|
|
17
|
+
|
|
18
|
+
msgctxt "The label of the styles dropdown button in the toolbar displayed when multiple styles are currently active."
|
|
19
|
+
msgid "Multiple styles"
|
|
20
|
+
msgstr "Некалькі стыляў"
|
|
21
|
+
|
|
22
|
+
msgctxt "The label of the group in the styles dropdown containing styles applicable to blocks only (paragraphs, headings, etc.)."
|
|
23
|
+
msgid "Block styles"
|
|
24
|
+
msgstr "Стылі для блокаў"
|
|
25
|
+
|
|
26
|
+
msgctxt "The label of the group in the styles dropdown containing inline applicable to text only."
|
|
27
|
+
msgid "Text styles"
|
|
28
|
+
msgstr "Стылі для тэксту"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-style",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "45.0.0-alpha.0",
|
|
4
4
|
"description": "Style feature for CKEditor 5.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ckeditor",
|
|
@@ -13,15 +13,15 @@
|
|
|
13
13
|
"type": "module",
|
|
14
14
|
"main": "src/index.js",
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@ckeditor/ckeditor5-core": "
|
|
17
|
-
"@ckeditor/ckeditor5-html-support": "
|
|
18
|
-
"@ckeditor/ckeditor5-list": "
|
|
19
|
-
"@ckeditor/ckeditor5-table": "
|
|
20
|
-
"@ckeditor/ckeditor5-typing": "
|
|
21
|
-
"@ckeditor/ckeditor5-ui": "
|
|
22
|
-
"@ckeditor/ckeditor5-utils": "
|
|
23
|
-
"ckeditor5": "
|
|
24
|
-
"
|
|
16
|
+
"@ckeditor/ckeditor5-core": "45.0.0-alpha.0",
|
|
17
|
+
"@ckeditor/ckeditor5-html-support": "45.0.0-alpha.0",
|
|
18
|
+
"@ckeditor/ckeditor5-list": "45.0.0-alpha.0",
|
|
19
|
+
"@ckeditor/ckeditor5-table": "45.0.0-alpha.0",
|
|
20
|
+
"@ckeditor/ckeditor5-typing": "45.0.0-alpha.0",
|
|
21
|
+
"@ckeditor/ckeditor5-ui": "45.0.0-alpha.0",
|
|
22
|
+
"@ckeditor/ckeditor5-utils": "45.0.0-alpha.0",
|
|
23
|
+
"ckeditor5": "45.0.0-alpha.0",
|
|
24
|
+
"es-toolkit": "1.32.0"
|
|
25
25
|
},
|
|
26
26
|
"author": "CKSource (http://cksource.com/)",
|
|
27
27
|
"license": "SEE LICENSE IN LICENSE.md",
|
package/src/integrations/link.js
CHANGED
|
@@ -9,6 +9,8 @@ import { Plugin } from 'ckeditor5/src/core.js';
|
|
|
9
9
|
import { findAttributeRange, findAttributeRangeBound } from 'ckeditor5/src/typing.js';
|
|
10
10
|
import StyleUtils from '../styleutils.js';
|
|
11
11
|
export default class LinkStyleSupport extends Plugin {
|
|
12
|
+
_styleUtils;
|
|
13
|
+
_htmlSupport;
|
|
12
14
|
/**
|
|
13
15
|
* @inheritDoc
|
|
14
16
|
*/
|
package/src/integrations/list.js
CHANGED
package/src/stylecommand.js
CHANGED
|
@@ -11,6 +11,14 @@ import StyleUtils from './styleutils.js';
|
|
|
11
11
|
* Applies and removes styles from selection and elements.
|
|
12
12
|
*/
|
|
13
13
|
export default class StyleCommand extends Command {
|
|
14
|
+
/**
|
|
15
|
+
* Normalized definitions of the styles.
|
|
16
|
+
*/
|
|
17
|
+
_styleDefinitions;
|
|
18
|
+
/**
|
|
19
|
+
* The StyleUtils plugin.
|
|
20
|
+
*/
|
|
21
|
+
_styleUtils;
|
|
14
22
|
/**
|
|
15
23
|
* Creates an instance of the command.
|
|
16
24
|
*
|
package/src/styleutils.js
CHANGED
|
@@ -6,13 +6,14 @@
|
|
|
6
6
|
* @module style/styleutils
|
|
7
7
|
*/
|
|
8
8
|
import { Plugin } from 'ckeditor5/src/core.js';
|
|
9
|
-
import { isObject } from '
|
|
9
|
+
import { isObject } from 'es-toolkit/compat';
|
|
10
10
|
// These are intermediate element names that can't be rendered as style preview because they don't make sense standalone.
|
|
11
11
|
const NON_PREVIEWABLE_ELEMENT_NAMES = [
|
|
12
12
|
'caption', 'colgroup', 'dd', 'dt', 'figcaption', 'legend', 'li', 'optgroup', 'option', 'rp',
|
|
13
13
|
'rt', 'summary', 'tbody', 'td', 'tfoot', 'th', 'thead', 'tr'
|
|
14
14
|
];
|
|
15
15
|
export default class StyleUtils extends Plugin {
|
|
16
|
+
_htmlSupport;
|
|
16
17
|
/**
|
|
17
18
|
* @inheritDoc
|
|
18
19
|
*/
|
|
@@ -7,6 +7,14 @@ import { ButtonView, View } from 'ckeditor5/src/ui.js';
|
|
|
7
7
|
* A class representing an individual button (style) in the grid. Renders a rich preview of the style.
|
|
8
8
|
*/
|
|
9
9
|
export default class StyleGridButtonView extends ButtonView {
|
|
10
|
+
/**
|
|
11
|
+
* Definition of the style the button will apply when executed.
|
|
12
|
+
*/
|
|
13
|
+
styleDefinition;
|
|
14
|
+
/**
|
|
15
|
+
* The view rendering the preview of the style.
|
|
16
|
+
*/
|
|
17
|
+
previewView;
|
|
10
18
|
/**
|
|
11
19
|
* Creates an instance of the {@link module:style/ui/stylegridbuttonview~StyleGridButtonView} class.
|
|
12
20
|
*
|
package/src/ui/stylegridview.js
CHANGED
|
@@ -14,6 +14,18 @@ import '../../theme/stylegrid.css';
|
|
|
14
14
|
* Allows users to select a style.
|
|
15
15
|
*/
|
|
16
16
|
export default class StyleGridView extends View {
|
|
17
|
+
/**
|
|
18
|
+
* Tracks information about the DOM focus in the view.
|
|
19
|
+
*/
|
|
20
|
+
focusTracker;
|
|
21
|
+
/**
|
|
22
|
+
* An instance of the {@link module:utils/keystrokehandler~KeystrokeHandler}.
|
|
23
|
+
*/
|
|
24
|
+
keystrokes;
|
|
25
|
+
/**
|
|
26
|
+
* A collection of style {@link module:style/ui/stylegridbuttonview~StyleGridButtonView buttons}.
|
|
27
|
+
*/
|
|
28
|
+
children;
|
|
17
29
|
/**
|
|
18
30
|
* Creates an instance of the {@link module:style/ui/stylegridview~StyleGridView} class.
|
|
19
31
|
*
|
package/src/ui/stylegroupview.js
CHANGED
|
@@ -14,6 +14,14 @@ import '../../theme/stylegroup.css';
|
|
|
14
14
|
* Renders a {@link module:style/ui/stylegridview~StyleGridView style grid} and a label.
|
|
15
15
|
*/
|
|
16
16
|
export default class StyleGroupView extends View {
|
|
17
|
+
/**
|
|
18
|
+
* The styles grid of the group.
|
|
19
|
+
*/
|
|
20
|
+
gridView;
|
|
21
|
+
/**
|
|
22
|
+
* The label of the group.
|
|
23
|
+
*/
|
|
24
|
+
labelView;
|
|
17
25
|
/**
|
|
18
26
|
* Creates an instance of the {@link module:style/ui/stylegroupview~StyleGroupView} class.
|
|
19
27
|
*
|
package/src/ui/stylepanelview.js
CHANGED
|
@@ -14,6 +14,34 @@ import '../../theme/stylepanel.css';
|
|
|
14
14
|
* in categories.
|
|
15
15
|
*/
|
|
16
16
|
export default class StylePanelView extends View {
|
|
17
|
+
/**
|
|
18
|
+
* Tracks information about DOM focus in the panel.
|
|
19
|
+
*/
|
|
20
|
+
focusTracker;
|
|
21
|
+
/**
|
|
22
|
+
* An instance of the {@link module:utils/keystrokehandler~KeystrokeHandler}.
|
|
23
|
+
*/
|
|
24
|
+
keystrokes;
|
|
25
|
+
/**
|
|
26
|
+
* A collection of panel children.
|
|
27
|
+
*/
|
|
28
|
+
children;
|
|
29
|
+
/**
|
|
30
|
+
* A view representing block styles group.
|
|
31
|
+
*/
|
|
32
|
+
blockStylesGroupView;
|
|
33
|
+
/**
|
|
34
|
+
* A view representing inline styles group
|
|
35
|
+
*/
|
|
36
|
+
inlineStylesGroupView;
|
|
37
|
+
/**
|
|
38
|
+
* A collection of views that can be focused in the panel.
|
|
39
|
+
*/
|
|
40
|
+
_focusables;
|
|
41
|
+
/**
|
|
42
|
+
* Helps cycling over {@link #_focusables} in the panel.
|
|
43
|
+
*/
|
|
44
|
+
_focusCycler;
|
|
17
45
|
/**
|
|
18
46
|
* Creates an instance of the {@link module:style/ui/stylegroupview~StyleGroupView} class.
|
|
19
47
|
*
|