@ckeditor/ckeditor5-heading 47.3.0-alpha.7 → 47.4.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 +1 -1
- package/build/heading.js +2 -2
- package/dist/index-content.css +1 -1
- package/dist/index-editor.css +1 -1
- package/dist/index.css +2 -2
- package/dist/index.css.map +1 -1
- package/dist/index.js +53 -23
- package/dist/index.js.map +1 -1
- package/dist/translations/af.d.ts +1 -1
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.d.ts +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.d.ts +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.d.ts +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.d.ts +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.d.ts +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.d.ts +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.d.ts +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.d.ts +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.d.ts +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.d.ts +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.d.ts +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.d.ts +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.d.ts +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.d.ts +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.d.ts +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.d.ts +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.d.ts +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.d.ts +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.d.ts +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.d.ts +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.d.ts +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.d.ts +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.d.ts +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.d.ts +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.d.ts +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.d.ts +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.d.ts +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.d.ts +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.d.ts +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.d.ts +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.d.ts +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.d.ts +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.d.ts +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.d.ts +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.d.ts +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.d.ts +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.d.ts +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.d.ts +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.d.ts +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.d.ts +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.d.ts +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.d.ts +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.d.ts +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.d.ts +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.d.ts +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.d.ts +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.d.ts +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.d.ts +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.d.ts +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.d.ts +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.d.ts +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.d.ts +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.d.ts +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.d.ts +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.d.ts +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.d.ts +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.d.ts +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.d.ts +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.d.ts +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.d.ts +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.d.ts +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.d.ts +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.d.ts +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.d.ts +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.d.ts +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.d.ts +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.d.ts +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.d.ts +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.d.ts +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.d.ts +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.d.ts +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.d.ts +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/lang/translations/af.po +1 -1
- package/lang/translations/ar.po +1 -1
- package/lang/translations/ast.po +1 -1
- package/lang/translations/az.po +1 -1
- package/lang/translations/be.po +1 -1
- package/lang/translations/bg.po +1 -1
- package/lang/translations/bn.po +1 -1
- package/lang/translations/bs.po +1 -1
- package/lang/translations/ca.po +1 -1
- package/lang/translations/cs.po +1 -1
- package/lang/translations/da.po +1 -1
- package/lang/translations/de-ch.po +1 -1
- package/lang/translations/de.po +1 -1
- package/lang/translations/el.po +1 -1
- package/lang/translations/en-au.po +1 -1
- package/lang/translations/en-gb.po +1 -1
- package/lang/translations/en.po +1 -1
- package/lang/translations/eo.po +1 -1
- package/lang/translations/es-co.po +1 -1
- package/lang/translations/es.po +1 -1
- package/lang/translations/et.po +1 -1
- package/lang/translations/eu.po +1 -1
- package/lang/translations/fa.po +1 -1
- package/lang/translations/fi.po +1 -1
- package/lang/translations/fr.po +1 -1
- package/lang/translations/gl.po +1 -1
- package/lang/translations/gu.po +1 -1
- package/lang/translations/he.po +1 -1
- package/lang/translations/hi.po +1 -1
- package/lang/translations/hr.po +1 -1
- package/lang/translations/hu.po +1 -1
- package/lang/translations/hy.po +1 -1
- package/lang/translations/id.po +1 -1
- package/lang/translations/it.po +1 -1
- package/lang/translations/ja.po +1 -1
- package/lang/translations/jv.po +1 -1
- package/lang/translations/kk.po +1 -1
- package/lang/translations/km.po +1 -1
- package/lang/translations/kn.po +1 -1
- package/lang/translations/ko.po +1 -1
- package/lang/translations/ku.po +1 -1
- package/lang/translations/lt.po +1 -1
- package/lang/translations/lv.po +1 -1
- package/lang/translations/ms.po +1 -1
- package/lang/translations/nb.po +1 -1
- package/lang/translations/ne.po +1 -1
- package/lang/translations/nl.po +1 -1
- package/lang/translations/no.po +1 -1
- package/lang/translations/oc.po +1 -1
- package/lang/translations/pl.po +1 -1
- package/lang/translations/pt-br.po +1 -1
- package/lang/translations/pt.po +1 -1
- package/lang/translations/ro.po +1 -1
- package/lang/translations/ru.po +1 -1
- package/lang/translations/si.po +1 -1
- package/lang/translations/sk.po +1 -1
- package/lang/translations/sl.po +1 -1
- package/lang/translations/sq.po +1 -1
- package/lang/translations/sr-latn.po +1 -1
- package/lang/translations/sr.po +1 -1
- package/lang/translations/sv.po +1 -1
- package/lang/translations/th.po +1 -1
- package/lang/translations/ti.po +1 -1
- package/lang/translations/tk.po +1 -1
- package/lang/translations/tr.po +1 -1
- package/lang/translations/tt.po +1 -1
- package/lang/translations/ug.po +1 -1
- package/lang/translations/uk.po +1 -1
- package/lang/translations/ur.po +1 -1
- package/lang/translations/uz.po +1 -1
- package/lang/translations/vi.po +1 -1
- package/lang/translations/zh-cn.po +1 -1
- package/lang/translations/zh.po +1 -1
- package/package.json +9 -9
- package/src/augmentation.d.ts +1 -1
- package/src/augmentation.js +1 -1
- package/src/heading.d.ts +1 -1
- package/src/heading.js +1 -1
- package/src/headingbuttonsui.d.ts +1 -1
- package/src/headingbuttonsui.js +1 -1
- package/src/headingcommand.d.ts +1 -1
- package/src/headingcommand.js +1 -1
- package/src/headingconfig.d.ts +1 -1
- package/src/headingconfig.js +1 -1
- package/src/headingediting.d.ts +1 -1
- package/src/headingediting.js +1 -1
- package/src/headingui.d.ts +1 -1
- package/src/headingui.js +1 -1
- package/src/index.d.ts +1 -1
- package/src/index.js +1 -1
- package/src/title.d.ts +5 -5
- package/src/title.js +53 -22
- package/src/utils.d.ts +1 -1
- package/src/utils.js +1 -1
- package/theme/heading.css +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-heading",
|
|
3
|
-
"version": "47.
|
|
3
|
+
"version": "47.4.0-alpha.0",
|
|
4
4
|
"description": "Headings feature for CKEditor 5.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ckeditor",
|
|
@@ -13,13 +13,13 @@
|
|
|
13
13
|
"type": "module",
|
|
14
14
|
"main": "src/index.js",
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@ckeditor/ckeditor5-core": "47.
|
|
17
|
-
"@ckeditor/ckeditor5-engine": "47.
|
|
18
|
-
"@ckeditor/ckeditor5-icons": "47.
|
|
19
|
-
"@ckeditor/ckeditor5-paragraph": "47.
|
|
20
|
-
"@ckeditor/ckeditor5-ui": "47.
|
|
21
|
-
"@ckeditor/ckeditor5-utils": "47.
|
|
22
|
-
"ckeditor5": "47.
|
|
16
|
+
"@ckeditor/ckeditor5-core": "47.4.0-alpha.0",
|
|
17
|
+
"@ckeditor/ckeditor5-engine": "47.4.0-alpha.0",
|
|
18
|
+
"@ckeditor/ckeditor5-icons": "47.4.0-alpha.0",
|
|
19
|
+
"@ckeditor/ckeditor5-paragraph": "47.4.0-alpha.0",
|
|
20
|
+
"@ckeditor/ckeditor5-ui": "47.4.0-alpha.0",
|
|
21
|
+
"@ckeditor/ckeditor5-utils": "47.4.0-alpha.0",
|
|
22
|
+
"ckeditor5": "47.4.0-alpha.0"
|
|
23
23
|
},
|
|
24
24
|
"author": "CKSource (http://cksource.com/)",
|
|
25
25
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
@@ -63,4 +63,4 @@
|
|
|
63
63
|
"./ckeditor5-metadata.json": "./ckeditor5-metadata.json",
|
|
64
64
|
"./package.json": "./package.json"
|
|
65
65
|
}
|
|
66
|
-
}
|
|
66
|
+
}
|
package/src/augmentation.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
import type { Heading, HeadingCommand, HeadingConfig, HeadingEditing, HeadingTitleConfig, HeadingUI, Title } from './index.js';
|
package/src/augmentation.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
export {};
|
package/src/heading.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/heading.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/headingbuttonsui.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/headingcommand.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/headingcommand.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/headingconfig.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/headingconfig.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
export {};
|
package/src/headingediting.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/headingediting.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/headingui.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/headingui.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/title.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
|
@@ -35,10 +35,10 @@ export declare class Title extends Plugin {
|
|
|
35
35
|
init(): void;
|
|
36
36
|
/**
|
|
37
37
|
* Returns the title of the document. Note that because this plugin does not allow any formatting inside
|
|
38
|
-
* the title element, the output of this method will be a plain text, with no HTML tags.
|
|
38
|
+
* the `title` element, the output of this method will be a plain text, with no HTML tags.
|
|
39
39
|
*
|
|
40
40
|
* It is not recommended to use this method together with features that insert markers to the
|
|
41
|
-
* data output, like comments or track changes features. If such markers start in the title and end in the
|
|
41
|
+
* data output, like comments or track changes features. If such markers start in the `title` and end in the
|
|
42
42
|
* body, the result of this method might be incorrect.
|
|
43
43
|
*
|
|
44
44
|
* @param options Additional configuration passed to the conversion process.
|
|
@@ -68,8 +68,8 @@ export declare class Title extends Plugin {
|
|
|
68
68
|
*/
|
|
69
69
|
private _fixTitleContent;
|
|
70
70
|
/**
|
|
71
|
-
* Model post-fixer callback that creates a title element when it is missing,
|
|
72
|
-
* takes care of the correct position of it and removes additional title elements.
|
|
71
|
+
* Model post-fixer callback that creates a `title` element when it is missing,
|
|
72
|
+
* takes care of the correct position of it and removes additional `title` elements.
|
|
73
73
|
*/
|
|
74
74
|
private _fixTitleElement;
|
|
75
75
|
/**
|
package/src/title.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
|
@@ -9,7 +9,7 @@ import { Plugin } from 'ckeditor5/src/core.js';
|
|
|
9
9
|
import { first } from 'ckeditor5/src/utils.js';
|
|
10
10
|
import { ViewDowncastWriter, enableViewPlaceholder, hideViewPlaceholder, needsViewPlaceholder, showViewPlaceholder } from 'ckeditor5/src/engine.js';
|
|
11
11
|
// A list of element names that should be treated by the Title plugin as title-like.
|
|
12
|
-
// This means that an element of a type from this list will be changed to a title element
|
|
12
|
+
// This means that an element of a type from this list will be changed to a `title` element
|
|
13
13
|
// when it is the first element in the root.
|
|
14
14
|
const titleLikeElements = new Set(['paragraph', 'heading1', 'heading2', 'heading3', 'heading4', 'heading5', 'heading6']);
|
|
15
15
|
/**
|
|
@@ -47,7 +47,7 @@ export class Title extends Plugin {
|
|
|
47
47
|
init() {
|
|
48
48
|
const editor = this.editor;
|
|
49
49
|
const model = editor.model;
|
|
50
|
-
// To use the schema for disabling some features when the selection is inside the title element
|
|
50
|
+
// To use the schema for disabling some features when the selection is inside the `title` element
|
|
51
51
|
// it is needed to create the following structure:
|
|
52
52
|
//
|
|
53
53
|
// <title>
|
|
@@ -58,13 +58,13 @@ export class Title extends Plugin {
|
|
|
58
58
|
model.schema.register('title', { isBlock: true, allowIn: '$root' });
|
|
59
59
|
model.schema.register('title-content', { isBlock: true, allowIn: 'title', allowAttributes: ['alignment'] });
|
|
60
60
|
model.schema.extend('$text', { allowIn: 'title-content' });
|
|
61
|
-
// Disallow all attributes in `title-content`.
|
|
61
|
+
// Disallow all attributes in `title-content` `$text`.
|
|
62
62
|
model.schema.addAttributeCheck(context => {
|
|
63
63
|
if (context.endsWith('title-content $text')) {
|
|
64
64
|
return false;
|
|
65
65
|
}
|
|
66
66
|
});
|
|
67
|
-
// Because `title` is represented by two elements in the model
|
|
67
|
+
// Because `title` is represented by two elements (`title` and `title-content`) in the model
|
|
68
68
|
// but only one in the view, it is needed to adjust Mapper.
|
|
69
69
|
editor.editing.mapper.on('modelToViewPosition', mapModelPositionToView(editor.editing.view));
|
|
70
70
|
editor.data.mapper.on('modelToViewPosition', mapModelPositionToView(editor.editing.view));
|
|
@@ -73,6 +73,37 @@ export class Title extends Plugin {
|
|
|
73
73
|
editor.conversion.for('downcast').add(dispatcher => dispatcher.on('insert:title', (evt, data, conversionApi) => {
|
|
74
74
|
conversionApi.consumable.consume(data.item, evt.name);
|
|
75
75
|
}));
|
|
76
|
+
// This converter intercepts attribute changes on `title` and redirects them to `title-content`.
|
|
77
|
+
//
|
|
78
|
+
// The `title` element in the model doesn't have a corresponding view element, only `title-content`
|
|
79
|
+
// is converted to `<h1>`. Setting an attribute on `title` would cause a downcast conversion error
|
|
80
|
+
// because there's no view element to apply it to.
|
|
81
|
+
editor.conversion.for('downcast').add(dispatcher => {
|
|
82
|
+
dispatcher.on('attribute', (evt, data, conversionApi) => {
|
|
83
|
+
// Only process if the attribute change is on a `title` element.
|
|
84
|
+
if (!data.item.is('element', 'title')) {
|
|
85
|
+
return;
|
|
86
|
+
}
|
|
87
|
+
const titleElement = data.item;
|
|
88
|
+
if (!conversionApi.consumable.consume(titleElement, evt.name)) {
|
|
89
|
+
return;
|
|
90
|
+
}
|
|
91
|
+
const titleContentElement = titleElement.getChild(0);
|
|
92
|
+
// Ensure the `title-content` element is converted to view first.
|
|
93
|
+
// This is needed because attribute conversion might run before insert conversion.
|
|
94
|
+
conversionApi.convertItem(titleContentElement);
|
|
95
|
+
const viewElement = conversionApi.mapper.toViewElement(titleContentElement);
|
|
96
|
+
const attributeKey = data.attributeKey;
|
|
97
|
+
const attributeNewValue = data.attributeNewValue;
|
|
98
|
+
// Apply the attribute to the view element.
|
|
99
|
+
if (attributeNewValue !== null) {
|
|
100
|
+
conversionApi.writer.setAttribute(attributeKey, attributeNewValue, viewElement);
|
|
101
|
+
}
|
|
102
|
+
else {
|
|
103
|
+
conversionApi.writer.removeAttribute(attributeKey, viewElement);
|
|
104
|
+
}
|
|
105
|
+
});
|
|
106
|
+
});
|
|
76
107
|
// Custom converter is used for data v -> m conversion to avoid calling post-fixer when setting data.
|
|
77
108
|
// See https://github.com/ckeditor/ckeditor5/issues/2036.
|
|
78
109
|
editor.data.upcastDispatcher.on('element:h1', dataViewModelH1Insertion, { priority: 'high' });
|
|
@@ -93,10 +124,10 @@ export class Title extends Plugin {
|
|
|
93
124
|
}
|
|
94
125
|
/**
|
|
95
126
|
* Returns the title of the document. Note that because this plugin does not allow any formatting inside
|
|
96
|
-
* the title element, the output of this method will be a plain text, with no HTML tags.
|
|
127
|
+
* the `title` element, the output of this method will be a plain text, with no HTML tags.
|
|
97
128
|
*
|
|
98
129
|
* It is not recommended to use this method together with features that insert markers to the
|
|
99
|
-
* data output, like comments or track changes features. If such markers start in the title and end in the
|
|
130
|
+
* data output, like comments or track changes features. If such markers start in the `title` and end in the
|
|
100
131
|
* body, the result of this method might be incorrect.
|
|
101
132
|
*
|
|
102
133
|
* @param options Additional configuration passed to the conversion process.
|
|
@@ -144,7 +175,7 @@ export class Title extends Plugin {
|
|
|
144
175
|
data.mapper.clearBindings();
|
|
145
176
|
data.mapper.bindElements(root, viewDocumentFragment);
|
|
146
177
|
data.downcastDispatcher.convert(rootRange, markers, viewWriter, options);
|
|
147
|
-
// Remove title element from view.
|
|
178
|
+
// Remove `title` element from view.
|
|
148
179
|
viewWriter.remove(viewWriter.createRangeOn(viewDocumentFragment.getChild(0)));
|
|
149
180
|
// view -> data
|
|
150
181
|
return editor.data.processor.toData(viewDocumentFragment);
|
|
@@ -185,8 +216,8 @@ export class Title extends Plugin {
|
|
|
185
216
|
return changed;
|
|
186
217
|
}
|
|
187
218
|
/**
|
|
188
|
-
* Model post-fixer callback that creates a title element when it is missing,
|
|
189
|
-
* takes care of the correct position of it and removes additional title elements.
|
|
219
|
+
* Model post-fixer callback that creates a `title` element when it is missing,
|
|
220
|
+
* takes care of the correct position of it and removes additional `title` elements.
|
|
190
221
|
*/
|
|
191
222
|
_fixTitleElement(writer) {
|
|
192
223
|
let changed = false;
|
|
@@ -195,7 +226,7 @@ export class Title extends Plugin {
|
|
|
195
226
|
const titleElements = Array.from(modelRoot.getChildren()).filter(isTitle);
|
|
196
227
|
const firstTitleElement = titleElements[0];
|
|
197
228
|
const firstRootChild = modelRoot.getChild(0);
|
|
198
|
-
// When title element is at the beginning of the document then try to fix additional title elements (if there are any).
|
|
229
|
+
// When `title` element is at the beginning of the document then try to fix additional `title` elements (if there are any).
|
|
199
230
|
if (firstRootChild.is('element', 'title')) {
|
|
200
231
|
if (titleElements.length > 1) {
|
|
201
232
|
fixAdditionalTitleElements(titleElements, writer, model);
|
|
@@ -213,11 +244,11 @@ export class Title extends Plugin {
|
|
|
213
244
|
continue;
|
|
214
245
|
}
|
|
215
246
|
if (titleLikeElements.has(firstRootChild.name)) {
|
|
216
|
-
// Change the first element in the document to the title if it can be changed (is title-like).
|
|
247
|
+
// Change the first element in the document to the `title` if it can be changed (is title-like).
|
|
217
248
|
changeElementToTitle(firstRootChild, writer, model);
|
|
218
249
|
}
|
|
219
250
|
else {
|
|
220
|
-
// Otherwise, move the first occurrence of the title element to the beginning of the document.
|
|
251
|
+
// Otherwise, move the first occurrence of the `title` element to the beginning of the document.
|
|
221
252
|
writer.move(writer.createRangeOn(firstTitleElement), modelRoot, 0);
|
|
222
253
|
}
|
|
223
254
|
fixAdditionalTitleElements(titleElements, writer, model);
|
|
@@ -271,7 +302,7 @@ export class Title extends Plugin {
|
|
|
271
302
|
const bodyPlaceholder = editor.config.get('placeholder') ||
|
|
272
303
|
sourceElement && sourceElement.tagName.toLowerCase() === 'textarea' && sourceElement.getAttribute('placeholder') ||
|
|
273
304
|
t('Type or paste your content here.');
|
|
274
|
-
// Attach placeholder to the view title element.
|
|
305
|
+
// Attach placeholder to the view `title-content` element.
|
|
275
306
|
editor.editing.downcastDispatcher.on('insert:title-content', (evt, data, conversionApi) => {
|
|
276
307
|
const element = conversionApi.mapper.toViewElement(data.item);
|
|
277
308
|
element.placeholder = titlePlaceholder;
|
|
@@ -281,8 +312,8 @@ export class Title extends Plugin {
|
|
|
281
312
|
keepOnFocus: true
|
|
282
313
|
});
|
|
283
314
|
});
|
|
284
|
-
// Attach placeholder to first element after a title element and remove it if it's not needed anymore.
|
|
285
|
-
// First element after title can change, so we need to observe all changes keep placeholder in sync.
|
|
315
|
+
// Attach placeholder to first element after a `title` element and remove it if it's not needed anymore.
|
|
316
|
+
// First element after `title` can change, so we need to observe all changes keep placeholder in sync.
|
|
286
317
|
const bodyViewElements = new Map();
|
|
287
318
|
// This post-fixer runs after the model post-fixer, so we can assume that the second child in view root will always exist.
|
|
288
319
|
view.document.registerPostFixer(writer => {
|
|
@@ -358,7 +389,7 @@ export class Title extends Plugin {
|
|
|
358
389
|
}
|
|
359
390
|
}
|
|
360
391
|
/**
|
|
361
|
-
* A view-to-model converter for the h1 that appears at the beginning of the document (a title element).
|
|
392
|
+
* A view-to-model converter for the `h1` that appears at the beginning of the document (a `title` element).
|
|
362
393
|
*
|
|
363
394
|
* @see module:engine/conversion/upcastdispatcher~UpcastDispatcher#event:element
|
|
364
395
|
* @param evt An object containing information about the fired event.
|
|
@@ -408,7 +439,7 @@ function isTitle(element) {
|
|
|
408
439
|
return element.is('element', 'title');
|
|
409
440
|
}
|
|
410
441
|
/**
|
|
411
|
-
* Changes the given element to the title element.
|
|
442
|
+
* Changes the given element to the `title` element.
|
|
412
443
|
*/
|
|
413
444
|
function changeElementToTitle(element, writer, model) {
|
|
414
445
|
const title = writer.createElement('title');
|
|
@@ -418,7 +449,7 @@ function changeElementToTitle(element, writer, model) {
|
|
|
418
449
|
model.schema.removeDisallowedAttributes([element], writer);
|
|
419
450
|
}
|
|
420
451
|
/**
|
|
421
|
-
* Loops over the list of title elements and fixes additional ones.
|
|
452
|
+
* Loops over the list of `title` elements and fixes additional ones.
|
|
422
453
|
*
|
|
423
454
|
* @returns Returns true when there was any change. Returns false otherwise.
|
|
424
455
|
*/
|
|
@@ -433,12 +464,12 @@ function fixAdditionalTitleElements(titleElements, writer, model) {
|
|
|
433
464
|
return hasChanged;
|
|
434
465
|
}
|
|
435
466
|
/**
|
|
436
|
-
* Changes given title element to a paragraph or removes it when it is empty.
|
|
467
|
+
* Changes given `title` element to a paragraph or removes it when it is empty.
|
|
437
468
|
*/
|
|
438
469
|
function fixTitleElement(title, writer, model) {
|
|
439
470
|
const child = title.getChild(0);
|
|
440
|
-
// Empty title should be removed.
|
|
441
|
-
// It is created as a result of pasting to the title element.
|
|
471
|
+
// Empty `title` should be removed.
|
|
472
|
+
// It is created as a result of pasting to the `title` element.
|
|
442
473
|
if (child.isEmpty) {
|
|
443
474
|
writer.remove(title);
|
|
444
475
|
return;
|
package/src/utils.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/src/utils.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Copyright (c) 2003-
|
|
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
5
|
/**
|
package/theme/heading.css
CHANGED