@ckeditor/ckeditor5-typing 32.0.0 → 34.1.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 +2 -2
- package/README.md +2 -1
- package/package.json +16 -16
- package/src/deletecommand.js +7 -2
package/LICENSE.md
CHANGED
|
@@ -2,7 +2,7 @@ Software License Agreement
|
|
|
2
2
|
==========================
|
|
3
3
|
|
|
4
4
|
**CKEditor 5 typing feature** – https://github.com/ckeditor/ckeditor5-typing <br>
|
|
5
|
-
Copyright (c) 2003-2022, [CKSource
|
|
5
|
+
Copyright (c) 2003-2022, [CKSource Holding sp. z o.o.](https://cksource.com) All rights reserved.
|
|
6
6
|
|
|
7
7
|
Licensed under the terms of [GNU General Public License Version 2 or later](http://www.gnu.org/licenses/gpl.html).
|
|
8
8
|
|
|
@@ -14,4 +14,4 @@ Where not otherwise indicated, all CKEditor content is authored by CKSource engi
|
|
|
14
14
|
Trademarks
|
|
15
15
|
----------
|
|
16
16
|
|
|
17
|
-
**CKEditor** is a trademark of [CKSource
|
|
17
|
+
**CKEditor** is a trademark of [CKSource Holding sp. z o.o.](https://cksource.com) All other brand and product names are trademarks, registered trademarks or service marks of their respective holders.
|
package/README.md
CHANGED
|
@@ -3,7 +3,8 @@ CKEditor 5 typing feature
|
|
|
3
3
|
|
|
4
4
|
[](https://www.npmjs.com/package/@ckeditor/ckeditor5-typing)
|
|
5
5
|
[](https://coveralls.io/github/ckeditor/ckeditor5?branch=master)
|
|
6
|
-
[](https://travis-ci.com/ckeditor/ckeditor5)
|
|
6
|
+
[](https://app.travis-ci.com/github/ckeditor/ckeditor5)
|
|
7
|
+

|
|
7
8
|
|
|
8
9
|
This package implements support for typing (inputting and deleting text) in CKEditor 5. It also includes the automatic text transformations (autocorrect) feature that lets you automatically turn predefined snippets into their improved forms.
|
|
9
10
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-typing",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "34.1.0",
|
|
4
4
|
"description": "Typing feature for CKEditor 5.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ckeditor",
|
|
@@ -12,24 +12,24 @@
|
|
|
12
12
|
],
|
|
13
13
|
"main": "src/index.js",
|
|
14
14
|
"dependencies": {
|
|
15
|
-
"@ckeditor/ckeditor5-core": "^
|
|
16
|
-
"@ckeditor/ckeditor5-engine": "^
|
|
17
|
-
"@ckeditor/ckeditor5-utils": "^
|
|
15
|
+
"@ckeditor/ckeditor5-core": "^34.1.0",
|
|
16
|
+
"@ckeditor/ckeditor5-engine": "^34.1.0",
|
|
17
|
+
"@ckeditor/ckeditor5-utils": "^34.1.0",
|
|
18
18
|
"lodash-es": "^4.17.15"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
|
-
"@ckeditor/ckeditor5-basic-styles": "^
|
|
22
|
-
"@ckeditor/ckeditor5-block-quote": "^
|
|
23
|
-
"@ckeditor/ckeditor5-editor-classic": "^
|
|
24
|
-
"@ckeditor/ckeditor5-enter": "^
|
|
25
|
-
"@ckeditor/ckeditor5-essentials": "^
|
|
26
|
-
"@ckeditor/ckeditor5-heading": "^
|
|
27
|
-
"@ckeditor/ckeditor5-image": "^
|
|
28
|
-
"@ckeditor/ckeditor5-link": "^
|
|
29
|
-
"@ckeditor/ckeditor5-list": "^
|
|
30
|
-
"@ckeditor/ckeditor5-paragraph": "^
|
|
31
|
-
"@ckeditor/ckeditor5-undo": "^
|
|
32
|
-
"@ckeditor/ckeditor5-code-block": "^
|
|
21
|
+
"@ckeditor/ckeditor5-basic-styles": "^34.1.0",
|
|
22
|
+
"@ckeditor/ckeditor5-block-quote": "^34.1.0",
|
|
23
|
+
"@ckeditor/ckeditor5-editor-classic": "^34.1.0",
|
|
24
|
+
"@ckeditor/ckeditor5-enter": "^34.1.0",
|
|
25
|
+
"@ckeditor/ckeditor5-essentials": "^34.1.0",
|
|
26
|
+
"@ckeditor/ckeditor5-heading": "^34.1.0",
|
|
27
|
+
"@ckeditor/ckeditor5-image": "^34.1.0",
|
|
28
|
+
"@ckeditor/ckeditor5-link": "^34.1.0",
|
|
29
|
+
"@ckeditor/ckeditor5-list": "^34.1.0",
|
|
30
|
+
"@ckeditor/ckeditor5-paragraph": "^34.1.0",
|
|
31
|
+
"@ckeditor/ckeditor5-undo": "^34.1.0",
|
|
32
|
+
"@ckeditor/ckeditor5-code-block": "^34.1.0"
|
|
33
33
|
},
|
|
34
34
|
"engines": {
|
|
35
35
|
"node": ">=14.0.0",
|
package/src/deletecommand.js
CHANGED
|
@@ -63,7 +63,8 @@ export default class DeleteCommand extends Command {
|
|
|
63
63
|
*
|
|
64
64
|
* @fires execute
|
|
65
65
|
* @param {Object} [options] The command options.
|
|
66
|
-
* @param {'character'} [options.unit='character']
|
|
66
|
+
* @param {'character'|'codePoint'|'word'} [options.unit='character']
|
|
67
|
+
* See {@link module:engine/model/utils/modifyselection~modifySelection}'s options.
|
|
67
68
|
* @param {Number} [options.sequence=1] A number describing which subsequent delete event it is without the key being released.
|
|
68
69
|
* See the {@link module:engine/view/document~Document#event:delete} event data.
|
|
69
70
|
* @param {module:engine/model/selection~Selection} [options.selection] Selection to remove. If not set, current model selection
|
|
@@ -88,7 +89,11 @@ export default class DeleteCommand extends Command {
|
|
|
88
89
|
|
|
89
90
|
// Try to extend the selection in the specified direction.
|
|
90
91
|
if ( selection.isCollapsed ) {
|
|
91
|
-
model.modifySelection( selection, {
|
|
92
|
+
model.modifySelection( selection, {
|
|
93
|
+
direction: this.direction,
|
|
94
|
+
unit: options.unit,
|
|
95
|
+
treatEmojiAsSingleUnit: true
|
|
96
|
+
} );
|
|
92
97
|
}
|
|
93
98
|
|
|
94
99
|
// Check if deleting in an empty editor. See #61.
|