editate 0.6.5 → 0.6.6
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/lib/doc/edit.d.ts +4 -4
- package/lib/dom/index.d.ts +1 -1
- package/lib/index.cjs +227 -218
- package/lib/index.cjs.map +1 -1
- package/lib/index.js +253 -244
- package/lib/index.js.map +1 -1
- package/package.json +1 -1
package/lib/doc/edit.d.ts
CHANGED
|
@@ -16,9 +16,9 @@ type InsertNodeOperation = Readonly<{
|
|
|
16
16
|
at: number;
|
|
17
17
|
fragment: Fragment;
|
|
18
18
|
}>;
|
|
19
|
-
declare const
|
|
20
|
-
type
|
|
21
|
-
type: typeof
|
|
19
|
+
declare const OP_FORMAT = "format";
|
|
20
|
+
type FormatOperation = Readonly<{
|
|
21
|
+
type: typeof OP_FORMAT;
|
|
22
22
|
range: Range;
|
|
23
23
|
key: string;
|
|
24
24
|
value: unknown;
|
|
@@ -30,7 +30,7 @@ type SetNodeAttrOperation = Readonly<{
|
|
|
30
30
|
key: string;
|
|
31
31
|
value: unknown;
|
|
32
32
|
}>;
|
|
33
|
-
export type Operation = DeleteOperation | InsertTextOperation | InsertNodeOperation |
|
|
33
|
+
export type Operation = DeleteOperation | InsertTextOperation | InsertNodeOperation | FormatOperation | SetNodeAttrOperation;
|
|
34
34
|
export declare const getNodeSize: (node: Node) => number;
|
|
35
35
|
export declare const offsetToPosition: (node: DocNode | BlockNode, offset: number) => DomPosition;
|
|
36
36
|
export declare const rebase: (position: number, ops: readonly Operation[]) => number;
|
package/lib/dom/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { createParser } from "./parser.js";
|
|
2
|
-
export { defaultIsBlockNode
|
|
2
|
+
export { defaultIsBlockNode } from "./default.js";
|