@ckeditor/ckeditor5-html-support 40.0.0 → 40.2.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 -4
- package/build/html-support.js +1 -1
- package/package.json +2 -2
- package/src/augmentation.d.ts +33 -33
- package/src/augmentation.js +5 -5
- package/src/converters.d.ts +60 -60
- package/src/converters.js +180 -180
- package/src/datafilter.d.ts +304 -304
- package/src/datafilter.js +749 -720
- package/src/dataschema.d.ts +183 -183
- package/src/dataschema.js +196 -196
- package/src/fullpage.d.ts +21 -21
- package/src/fullpage.js +80 -80
- package/src/generalhtmlsupport.d.ts +98 -98
- package/src/generalhtmlsupport.js +240 -240
- package/src/generalhtmlsupportconfig.d.ts +77 -77
- package/src/generalhtmlsupportconfig.js +5 -5
- package/src/htmlcomment.d.ts +71 -71
- package/src/htmlcomment.js +218 -218
- package/src/htmlpagedataprocessor.d.ts +22 -22
- package/src/htmlpagedataprocessor.js +67 -67
- package/src/index.d.ts +25 -25
- package/src/index.js +14 -14
- package/src/integrations/codeblock.d.ts +23 -23
- package/src/integrations/codeblock.js +101 -101
- package/src/integrations/customelement.d.ts +27 -27
- package/src/integrations/customelement.js +156 -146
- package/src/integrations/documentlist.d.ts +27 -27
- package/src/integrations/documentlist.js +178 -178
- package/src/integrations/dualcontent.d.ts +45 -45
- package/src/integrations/dualcontent.js +119 -119
- package/src/integrations/heading.d.ts +31 -31
- package/src/integrations/heading.js +60 -60
- package/src/integrations/image.d.ts +26 -26
- package/src/integrations/image.js +189 -189
- package/src/integrations/integrationutils.d.ts +15 -15
- package/src/integrations/integrationutils.js +21 -21
- package/src/integrations/mediaembed.d.ts +26 -26
- package/src/integrations/mediaembed.js +119 -119
- package/src/integrations/script.d.ts +26 -26
- package/src/integrations/script.js +59 -59
- package/src/integrations/style.d.ts +26 -26
- package/src/integrations/style.js +59 -59
- package/src/integrations/table.d.ts +23 -23
- package/src/integrations/table.js +163 -163
- package/src/schemadefinitions.d.ts +13 -13
- package/src/schemadefinitions.js +953 -956
- package/src/utils.d.ts +72 -72
- package/src/utils.js +139 -139
- package/build/html-support.js.map +0 -1
|
@@ -1,98 +1,98 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* @module html-support/generalhtmlsupport
|
|
7
|
-
*/
|
|
8
|
-
import { Plugin } from 'ckeditor5/src/core';
|
|
9
|
-
import { type ArrayOrItem } from 'ckeditor5/src/utils';
|
|
10
|
-
import DataFilter from './datafilter';
|
|
11
|
-
import CodeBlockElementSupport from './integrations/codeblock';
|
|
12
|
-
import DualContentModelElementSupport from './integrations/dualcontent';
|
|
13
|
-
import HeadingElementSupport from './integrations/heading';
|
|
14
|
-
import ImageElementSupport from './integrations/image';
|
|
15
|
-
import MediaEmbedElementSupport from './integrations/mediaembed';
|
|
16
|
-
import ScriptElementSupport from './integrations/script';
|
|
17
|
-
import TableElementSupport from './integrations/table';
|
|
18
|
-
import StyleElementSupport from './integrations/style';
|
|
19
|
-
import DocumentListElementSupport from './integrations/documentlist';
|
|
20
|
-
import CustomElementSupport from './integrations/customelement';
|
|
21
|
-
import type { Selectable } from 'ckeditor5/src/engine';
|
|
22
|
-
/**
|
|
23
|
-
* The General HTML Support feature.
|
|
24
|
-
*
|
|
25
|
-
* This is a "glue" plugin which initializes the {@link module:html-support/datafilter~DataFilter data filter} configuration
|
|
26
|
-
* and features integration with the General HTML Support.
|
|
27
|
-
*/
|
|
28
|
-
export default class GeneralHtmlSupport extends Plugin {
|
|
29
|
-
/**
|
|
30
|
-
* @inheritDoc
|
|
31
|
-
*/
|
|
32
|
-
static get pluginName(): "GeneralHtmlSupport";
|
|
33
|
-
/**
|
|
34
|
-
* @inheritDoc
|
|
35
|
-
*/
|
|
36
|
-
static get requires(): readonly [typeof DataFilter, typeof CodeBlockElementSupport, typeof DualContentModelElementSupport, typeof HeadingElementSupport, typeof ImageElementSupport, typeof MediaEmbedElementSupport, typeof ScriptElementSupport, typeof TableElementSupport, typeof StyleElementSupport, typeof DocumentListElementSupport, typeof CustomElementSupport];
|
|
37
|
-
/**
|
|
38
|
-
* @inheritDoc
|
|
39
|
-
*/
|
|
40
|
-
init(): void;
|
|
41
|
-
/**
|
|
42
|
-
* Returns a GHS model attribute name related to a given view element name.
|
|
43
|
-
*
|
|
44
|
-
* @internal
|
|
45
|
-
* @param viewElementName A view element name.
|
|
46
|
-
*/
|
|
47
|
-
getGhsAttributeNameForElement(viewElementName: string): string;
|
|
48
|
-
/**
|
|
49
|
-
* Updates GHS model attribute for a specified view element name, so it includes the given class name.
|
|
50
|
-
*
|
|
51
|
-
* @internal
|
|
52
|
-
* @param viewElementName A view element name.
|
|
53
|
-
* @param className The css class to add.
|
|
54
|
-
* @param selectable The selection or element to update.
|
|
55
|
-
*/
|
|
56
|
-
addModelHtmlClass(viewElementName: string, className: ArrayOrItem<string>, selectable: Selectable): void;
|
|
57
|
-
/**
|
|
58
|
-
* Updates GHS model attribute for a specified view element name, so it does not include the given class name.
|
|
59
|
-
*
|
|
60
|
-
* @internal
|
|
61
|
-
* @param viewElementName A view element name.
|
|
62
|
-
* @param className The css class to remove.
|
|
63
|
-
* @param selectable The selection or element to update.
|
|
64
|
-
*/
|
|
65
|
-
removeModelHtmlClass(viewElementName: string, className: ArrayOrItem<string>, selectable: Selectable): void;
|
|
66
|
-
/**
|
|
67
|
-
* Updates GHS model attribute for a specified view element name, so it includes the given attribute.
|
|
68
|
-
*
|
|
69
|
-
* @param viewElementName A view element name.
|
|
70
|
-
* @param attributes The object with attributes to set.
|
|
71
|
-
* @param selectable The selection or element to update.
|
|
72
|
-
*/
|
|
73
|
-
private setModelHtmlAttributes;
|
|
74
|
-
/**
|
|
75
|
-
* Updates GHS model attribute for a specified view element name, so it does not include the given attribute.
|
|
76
|
-
*
|
|
77
|
-
* @param viewElementName A view element name.
|
|
78
|
-
* @param attributeName The attribute name (or names) to remove.
|
|
79
|
-
* @param selectable The selection or element to update.
|
|
80
|
-
*/
|
|
81
|
-
private removeModelHtmlAttributes;
|
|
82
|
-
/**
|
|
83
|
-
* Updates GHS model attribute for a specified view element name, so it includes a given style.
|
|
84
|
-
*
|
|
85
|
-
* @param viewElementName A view element name.
|
|
86
|
-
* @param styles The object with styles to set.
|
|
87
|
-
* @param selectable The selection or element to update.
|
|
88
|
-
*/
|
|
89
|
-
private setModelHtmlStyles;
|
|
90
|
-
/**
|
|
91
|
-
* Updates GHS model attribute for a specified view element name, so it does not include a given style.
|
|
92
|
-
*
|
|
93
|
-
* @param viewElementName A view element name.
|
|
94
|
-
* @param properties The style (or styles list) to remove.
|
|
95
|
-
* @param selectable The selection or element to update.
|
|
96
|
-
*/
|
|
97
|
-
private removeModelHtmlStyles;
|
|
98
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* @module html-support/generalhtmlsupport
|
|
7
|
+
*/
|
|
8
|
+
import { Plugin } from 'ckeditor5/src/core';
|
|
9
|
+
import { type ArrayOrItem } from 'ckeditor5/src/utils';
|
|
10
|
+
import DataFilter from './datafilter';
|
|
11
|
+
import CodeBlockElementSupport from './integrations/codeblock';
|
|
12
|
+
import DualContentModelElementSupport from './integrations/dualcontent';
|
|
13
|
+
import HeadingElementSupport from './integrations/heading';
|
|
14
|
+
import ImageElementSupport from './integrations/image';
|
|
15
|
+
import MediaEmbedElementSupport from './integrations/mediaembed';
|
|
16
|
+
import ScriptElementSupport from './integrations/script';
|
|
17
|
+
import TableElementSupport from './integrations/table';
|
|
18
|
+
import StyleElementSupport from './integrations/style';
|
|
19
|
+
import DocumentListElementSupport from './integrations/documentlist';
|
|
20
|
+
import CustomElementSupport from './integrations/customelement';
|
|
21
|
+
import type { Selectable } from 'ckeditor5/src/engine';
|
|
22
|
+
/**
|
|
23
|
+
* The General HTML Support feature.
|
|
24
|
+
*
|
|
25
|
+
* This is a "glue" plugin which initializes the {@link module:html-support/datafilter~DataFilter data filter} configuration
|
|
26
|
+
* and features integration with the General HTML Support.
|
|
27
|
+
*/
|
|
28
|
+
export default class GeneralHtmlSupport extends Plugin {
|
|
29
|
+
/**
|
|
30
|
+
* @inheritDoc
|
|
31
|
+
*/
|
|
32
|
+
static get pluginName(): "GeneralHtmlSupport";
|
|
33
|
+
/**
|
|
34
|
+
* @inheritDoc
|
|
35
|
+
*/
|
|
36
|
+
static get requires(): readonly [typeof DataFilter, typeof CodeBlockElementSupport, typeof DualContentModelElementSupport, typeof HeadingElementSupport, typeof ImageElementSupport, typeof MediaEmbedElementSupport, typeof ScriptElementSupport, typeof TableElementSupport, typeof StyleElementSupport, typeof DocumentListElementSupport, typeof CustomElementSupport];
|
|
37
|
+
/**
|
|
38
|
+
* @inheritDoc
|
|
39
|
+
*/
|
|
40
|
+
init(): void;
|
|
41
|
+
/**
|
|
42
|
+
* Returns a GHS model attribute name related to a given view element name.
|
|
43
|
+
*
|
|
44
|
+
* @internal
|
|
45
|
+
* @param viewElementName A view element name.
|
|
46
|
+
*/
|
|
47
|
+
getGhsAttributeNameForElement(viewElementName: string): string;
|
|
48
|
+
/**
|
|
49
|
+
* Updates GHS model attribute for a specified view element name, so it includes the given class name.
|
|
50
|
+
*
|
|
51
|
+
* @internal
|
|
52
|
+
* @param viewElementName A view element name.
|
|
53
|
+
* @param className The css class to add.
|
|
54
|
+
* @param selectable The selection or element to update.
|
|
55
|
+
*/
|
|
56
|
+
addModelHtmlClass(viewElementName: string, className: ArrayOrItem<string>, selectable: Selectable): void;
|
|
57
|
+
/**
|
|
58
|
+
* Updates GHS model attribute for a specified view element name, so it does not include the given class name.
|
|
59
|
+
*
|
|
60
|
+
* @internal
|
|
61
|
+
* @param viewElementName A view element name.
|
|
62
|
+
* @param className The css class to remove.
|
|
63
|
+
* @param selectable The selection or element to update.
|
|
64
|
+
*/
|
|
65
|
+
removeModelHtmlClass(viewElementName: string, className: ArrayOrItem<string>, selectable: Selectable): void;
|
|
66
|
+
/**
|
|
67
|
+
* Updates GHS model attribute for a specified view element name, so it includes the given attribute.
|
|
68
|
+
*
|
|
69
|
+
* @param viewElementName A view element name.
|
|
70
|
+
* @param attributes The object with attributes to set.
|
|
71
|
+
* @param selectable The selection or element to update.
|
|
72
|
+
*/
|
|
73
|
+
private setModelHtmlAttributes;
|
|
74
|
+
/**
|
|
75
|
+
* Updates GHS model attribute for a specified view element name, so it does not include the given attribute.
|
|
76
|
+
*
|
|
77
|
+
* @param viewElementName A view element name.
|
|
78
|
+
* @param attributeName The attribute name (or names) to remove.
|
|
79
|
+
* @param selectable The selection or element to update.
|
|
80
|
+
*/
|
|
81
|
+
private removeModelHtmlAttributes;
|
|
82
|
+
/**
|
|
83
|
+
* Updates GHS model attribute for a specified view element name, so it includes a given style.
|
|
84
|
+
*
|
|
85
|
+
* @param viewElementName A view element name.
|
|
86
|
+
* @param styles The object with styles to set.
|
|
87
|
+
* @param selectable The selection or element to update.
|
|
88
|
+
*/
|
|
89
|
+
private setModelHtmlStyles;
|
|
90
|
+
/**
|
|
91
|
+
* Updates GHS model attribute for a specified view element name, so it does not include a given style.
|
|
92
|
+
*
|
|
93
|
+
* @param viewElementName A view element name.
|
|
94
|
+
* @param properties The style (or styles list) to remove.
|
|
95
|
+
* @param selectable The selection or element to update.
|
|
96
|
+
*/
|
|
97
|
+
private removeModelHtmlStyles;
|
|
98
|
+
}
|