@ckeditor/ckeditor5-typing 41.3.0-alpha.4 → 41.3.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/package.json +4 -5
- package/dist/content-index.css +0 -4
- package/dist/editor-index.css +0 -4
- package/dist/index.css +0 -4
- package/dist/types/augmentation.d.ts +0 -31
- package/dist/types/delete.d.ts +0 -36
- package/dist/types/deletecommand.d.ts +0 -87
- package/dist/types/deleteobserver.d.ts +0 -59
- package/dist/types/index.d.ts +0 -28
- package/dist/types/input.d.ts +0 -25
- package/dist/types/inserttextcommand.d.ts +0 -80
- package/dist/types/inserttextobserver.d.ts +0 -63
- package/dist/types/texttransformation.d.ts +0 -37
- package/dist/types/textwatcher.d.ts +0 -142
- package/dist/types/twostepcaretmovement.d.ts +0 -236
- package/dist/types/typing.d.ts +0 -27
- package/dist/types/typingconfig.d.ts +0 -208
- package/dist/types/utils/changebuffer.d.ts +0 -107
- package/dist/types/utils/findattributerange.d.ts +0 -37
- package/dist/types/utils/getlasttextline.d.ts +0 -53
- package/dist/types/utils/inlinehighlight.d.ts +0 -37
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2024, 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
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
8
|
-
*/
|
|
9
|
-
import type { Editor } from '@ckeditor/ckeditor5-core';
|
|
10
|
-
/**
|
|
11
|
-
* Adds a visual highlight style to an attribute element in which the selection is anchored.
|
|
12
|
-
* Together with two-step caret movement, they indicate that the user is typing inside the element.
|
|
13
|
-
*
|
|
14
|
-
* Highlight is turned on by adding the given class to the attribute element in the view:
|
|
15
|
-
*
|
|
16
|
-
* * The class is removed before the conversion has started, as callbacks added with the `'highest'` priority
|
|
17
|
-
* to {@link module:engine/conversion/downcastdispatcher~DowncastDispatcher} events.
|
|
18
|
-
* * The class is added in the view post fixer, after other changes in the model tree were converted to the view.
|
|
19
|
-
*
|
|
20
|
-
* This way, adding and removing the highlight does not interfere with conversion.
|
|
21
|
-
*
|
|
22
|
-
* Usage:
|
|
23
|
-
*
|
|
24
|
-
* ```ts
|
|
25
|
-
* import inlineHighlight from '@ckeditor/ckeditor5-typing/src/utils/inlinehighlight';
|
|
26
|
-
*
|
|
27
|
-
* // Make `ck-link_selected` class be applied on an `a` element
|
|
28
|
-
* // whenever the corresponding `linkHref` attribute element is selected.
|
|
29
|
-
* inlineHighlight( editor, 'linkHref', 'a', 'ck-link_selected' );
|
|
30
|
-
* ```
|
|
31
|
-
*
|
|
32
|
-
* @param editor The editor instance.
|
|
33
|
-
* @param attributeName The attribute name to check.
|
|
34
|
-
* @param tagName The tagName of a view item.
|
|
35
|
-
* @param className The class name to apply in the view.
|
|
36
|
-
*/
|
|
37
|
-
export default function inlineHighlight(editor: Editor, attributeName: string, tagName: string, className: string): void;
|