@progress/kendo-editor-common 1.11.8 → 1.11.9-dev.202411210753
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/dist/cdn/js/kendo-editor-common.js +1 -1
- package/dist/cdn/main.js +1 -1
- package/dist/es/lists.js +1 -1
- package/dist/es2015/DOMSerializer.js +15 -15
- package/dist/es2015/lists.js +1 -1
- package/dist/npm/DOMSerializer.d.ts +1 -1
- package/dist/npm/lists.d.ts +1 -1
- package/dist/npm/lists.js +1 -1
- package/dist/npm/types/command.d.ts +1 -1
- package/dist/npm/types/dispatchFn.d.ts +1 -1
- package/dist/npm/types/predicate.d.ts +1 -1
- package/dist/systemjs/kendo-editor-common.js +1 -1
- package/package.json +2 -3
package/dist/es/lists.js
CHANGED
|
@@ -192,7 +192,7 @@ function liftListItems(options) {
|
|
|
192
192
|
var sel = new NodeSelection(tr.doc.resolve(tr.mapping.map(pos)));
|
|
193
193
|
var range = sel.$from.blockRange(sel.$to);
|
|
194
194
|
if (!range || sel.$from.parent.type !== state.schema.nodes[options.listItem]) {
|
|
195
|
-
return
|
|
195
|
+
return;
|
|
196
196
|
}
|
|
197
197
|
var target = range && liftTarget(range);
|
|
198
198
|
if (target === undefined || target === null) {
|
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
import { setAttribute } from './utils';
|
|
2
2
|
export class DOMSerializer {
|
|
3
|
+
/// Create a serializer. `nodes` should map node names to functions
|
|
4
|
+
/// that take a node and return a description of the corresponding
|
|
5
|
+
/// DOM. `marks` does the same for mark names, but also gets an
|
|
6
|
+
/// argument that tells it whether the mark's content is block or
|
|
7
|
+
/// inline content (for typical use, it'll always be inline). A mark
|
|
8
|
+
/// serializer may be `null` to indicate that marks of that type
|
|
9
|
+
/// should not be serialized.
|
|
10
|
+
constructor(
|
|
11
|
+
/// The node serialization functions.
|
|
12
|
+
nodes,
|
|
13
|
+
/// The mark serialization functions.
|
|
14
|
+
marks) {
|
|
15
|
+
this.nodes = nodes;
|
|
16
|
+
this.marks = marks;
|
|
17
|
+
}
|
|
3
18
|
/// Render an [output spec](#model.DOMOutputSpec) to a DOM node. If
|
|
4
19
|
/// the spec has a hole (zero) in it, `contentDOM` will point at the
|
|
5
20
|
/// node with the hole.
|
|
@@ -75,21 +90,6 @@ export class DOMSerializer {
|
|
|
75
90
|
static marksFromSchema(schema) {
|
|
76
91
|
return gatherToDOM(schema.marks);
|
|
77
92
|
}
|
|
78
|
-
/// Create a serializer. `nodes` should map node names to functions
|
|
79
|
-
/// that take a node and return a description of the corresponding
|
|
80
|
-
/// DOM. `marks` does the same for mark names, but also gets an
|
|
81
|
-
/// argument that tells it whether the mark's content is block or
|
|
82
|
-
/// inline content (for typical use, it'll always be inline). A mark
|
|
83
|
-
/// serializer may be `null` to indicate that marks of that type
|
|
84
|
-
/// should not be serialized.
|
|
85
|
-
constructor(
|
|
86
|
-
/// The node serialization functions.
|
|
87
|
-
nodes,
|
|
88
|
-
/// The mark serialization functions.
|
|
89
|
-
marks) {
|
|
90
|
-
this.nodes = nodes;
|
|
91
|
-
this.marks = marks;
|
|
92
|
-
}
|
|
93
93
|
/// Serialize the content of this fragment to a DOM fragment. When
|
|
94
94
|
/// not in the browser, the `document` option, containing a DOM
|
|
95
95
|
/// document, should be passed so that the serializer can create
|
package/dist/es2015/lists.js
CHANGED
|
@@ -191,7 +191,7 @@ function liftListItems(options) {
|
|
|
191
191
|
const sel = new NodeSelection(tr.doc.resolve(tr.mapping.map(pos)));
|
|
192
192
|
const range = sel.$from.blockRange(sel.$to);
|
|
193
193
|
if (!range || sel.$from.parent.type !== state.schema.nodes[options.listItem]) {
|
|
194
|
-
return
|
|
194
|
+
return;
|
|
195
195
|
}
|
|
196
196
|
const target = range && liftTarget(range);
|
|
197
197
|
if (target === undefined || target === null) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DOMOutputSpec, Fragment, Mark, Node, Schema } from 'prosemirror-model';
|
|
2
|
-
type DOMNode = InstanceType<typeof window.Node>;
|
|
2
|
+
declare type DOMNode = InstanceType<typeof window.Node>;
|
|
3
3
|
export declare class DOMSerializer {
|
|
4
4
|
readonly nodes: {
|
|
5
5
|
[node: string]: (node: Node) => DOMOutputSpec;
|
package/dist/npm/lists.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { NodeType, Node } from 'prosemirror-model';
|
|
|
2
2
|
import { EditorState, Transaction } from 'prosemirror-state';
|
|
3
3
|
import { EditorView } from 'prosemirror-view';
|
|
4
4
|
import { Command } from './types/command';
|
|
5
|
-
type ListOptions = {
|
|
5
|
+
declare type ListOptions = {
|
|
6
6
|
listType: string;
|
|
7
7
|
orderedList: string;
|
|
8
8
|
bulletList: string;
|
package/dist/npm/lists.js
CHANGED
|
@@ -195,7 +195,7 @@ function liftListItems(options) {
|
|
|
195
195
|
var sel = new prosemirror_state_1.NodeSelection(tr.doc.resolve(tr.mapping.map(pos)));
|
|
196
196
|
var range = sel.$from.blockRange(sel.$to);
|
|
197
197
|
if (!range || sel.$from.parent.type !== state.schema.nodes[options.listItem]) {
|
|
198
|
-
return
|
|
198
|
+
return;
|
|
199
199
|
}
|
|
200
200
|
var target = range && (0, prosemirror_transform_1.liftTarget)(range);
|
|
201
201
|
if (target === undefined || target === null) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { EditorState } from 'prosemirror-state';
|
|
2
2
|
import { EditorView } from 'prosemirror-view';
|
|
3
3
|
import { DispatchFn } from './dispatchFn';
|
|
4
|
-
export type Command = (state: EditorState, dispatch: DispatchFn, view?: EditorView) => boolean | void;
|
|
4
|
+
export declare type Command = (state: EditorState, dispatch: DispatchFn, view?: EditorView) => boolean | void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { Transaction } from 'prosemirror-state';
|
|
2
|
-
export type DispatchFn = (tr: Transaction) => void;
|
|
2
|
+
export declare type DispatchFn = (tr: Transaction) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type Predicate<T = any> = (condition: T) => boolean;
|
|
1
|
+
export declare type Predicate<T = any> = (condition: T) => boolean;
|