sykpcomposer 1.19.74 → 1.19.76

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.
@@ -1,11 +1,16 @@
1
1
  import { TextNode, SerializedTextNode, EditorConfig } from "lexical";
2
+ interface ExtendedSerializedTextNode extends SerializedTextNode {
3
+ id: any;
4
+ color?: string;
5
+ backgroundColor?: string;
6
+ }
2
7
  export declare class DividerTextNode extends TextNode {
3
8
  static getType(): string;
4
9
  static clone(node: DividerTextNode): DividerTextNode;
5
10
  constructor(text?: string, key?: string);
6
11
  createDOM(config: EditorConfig): HTMLElement;
7
12
  updateDOM(prevNode: DividerTextNode, dom: HTMLElement, config: EditorConfig): boolean;
8
- exportJSON(): SerializedTextNode;
13
+ exportJSON(): ExtendedSerializedTextNode;
9
14
  static importJSON(serializedNode: SerializedTextNode): DividerTextNode;
10
15
  exportDOM(): {
11
16
  element: HTMLElement;
@@ -18,6 +23,56 @@ export declare class DividerTextNode extends TextNode {
18
23
  priority: 2;
19
24
  } | null;
20
25
  };
26
+ toCodoxNode(): {
27
+ type: string;
28
+ text: string;
29
+ format: number;
30
+ style: string;
31
+ detail: number;
32
+ version: number;
33
+ /**
34
+ * extension: codox_metadata should hold immutables:
35
+ * - required: your extended node type, e.g. 'warning'
36
+ * - optional: any immutable properties of an original node - these fields are not merged and synchronized.
37
+ */
38
+ codox_metadata: {
39
+ type: string;
40
+ id: any;
41
+ };
42
+ };
43
+ /**
44
+ * Implement the following API methods to interoperate with Codox
45
+ * Codox -> Lexical Node
46
+ * Converts synchronized codox json node to lexical json node
47
+ * must be class 'static' method
48
+ */
49
+ static fromCodoxNode(codoxNode: {
50
+ style: string;
51
+ codox_metadata: {
52
+ type: any;
53
+ id: any;
54
+ };
55
+ text: any;
56
+ format: any;
57
+ mode: any;
58
+ detail: any;
59
+ version: any;
60
+ }): {
61
+ type: any;
62
+ text: any;
63
+ format: any;
64
+ mode: any;
65
+ detail: any;
66
+ version: any;
67
+ style: string;
68
+ /**
69
+ * set custom attributes
70
+ */
71
+ id: any;
72
+ color: string;
73
+ backgroundColor: string;
74
+ };
21
75
  }
22
76
  export declare function $createDividerTextNode(): DividerTextNode;
23
77
  export declare function $isDividerTextNode(node: any): node is DividerTextNode;
78
+ export {};
@@ -11,6 +11,9 @@ export declare class EndNoteNode extends TextNode {
11
11
  contentKey: string;
12
12
  type: string;
13
13
  version: number;
14
+ color: string;
15
+ backgroundColor: string;
16
+ id: string;
14
17
  detail: number;
15
18
  format: number;
16
19
  mode: import("lexical").TextModeType;
@@ -30,26 +33,39 @@ export declare class EndNoteNode extends TextNode {
30
33
  /**
31
34
  * Convert the EndNoteNode to a Codox-compatible node
32
35
  */
33
- toCodoxNode(): {
34
- type: string;
35
- text: string;
36
- format: number;
37
- mode: import("lexical").TextModeType;
38
- detail: number;
39
- version: number;
36
+ toCodoxNode(): any;
37
+ /**
38
+ * Implement the following API methods to interoperate with Codox
39
+ * Codox -> Lexical Node
40
+ * Converts synchronized codox json node to lexical json node
41
+ * must be class 'static' method
42
+ */
43
+ static fromCodoxNode(codoxNode: {
40
44
  style: string;
41
45
  codox_metadata: {
42
- type: string;
43
- number: number;
44
- contentKey: string;
46
+ type: any;
47
+ id: any;
45
48
  };
49
+ text: any;
50
+ format: any;
51
+ mode: any;
52
+ detail: any;
53
+ version: any;
54
+ }): {
55
+ type: any;
56
+ text: any;
57
+ format: any;
58
+ mode: any;
59
+ detail: any;
60
+ version: any;
61
+ style: string;
62
+ /**
63
+ * set custom attributes
64
+ */
65
+ id: any;
66
+ color: string;
67
+ backgroundColor: string;
46
68
  };
47
- /**
48
- * Convert a Codox node to an EndNoteNode
49
- * @param codoxNode The Codox node to convert
50
- * @returns The corresponding EndNoteNode
51
- */
52
- static fromCodoxNode(codoxNode: any): EndNoteNode;
53
69
  }
54
70
  export declare function $createEndNoteNode(number: number, contentKey?: string): EndNoteNode;
55
71
  export declare function $isEndNoteNode(node: any): node is EndNoteNode;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "sykpcomposer",
3
3
  "description": "code for captions",
4
4
  "private": false,
5
- "version": "1.19.74",
5
+ "version": "1.19.76",
6
6
  "type": "module",
7
7
  "main": "dist/index.umd.js",
8
8
  "module": "dist/index.es.js",