@lobehub/editor 4.11.0 → 4.13.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/es/index.d.ts CHANGED
@@ -350,7 +350,18 @@ interface AutoCompletePluginOptions {
350
350
  editor: IEditor;
351
351
  input: string;
352
352
  selectionType: string;
353
+ suggestionId?: string;
353
354
  }) => Promise<string | null>;
355
+ onSuggestionAccepted?: (info: {
356
+ acceptedText: string;
357
+ suggestionId: string;
358
+ visibleMs: number;
359
+ }) => void;
360
+ onSuggestionRejected?: (info: {
361
+ reason: 'cursor-move' | 'typing' | 'esc' | 'blur' | 'other';
362
+ suggestionId: string;
363
+ visibleMs: number;
364
+ }) => void;
354
365
  theme?: {
355
366
  placeholderBlock?: string;
356
367
  placeholderInline?: string;
@@ -367,7 +378,18 @@ interface ReactAutoCompletePluginProps {
367
378
  editor: IEditor;
368
379
  input: string;
369
380
  selectionType: string;
381
+ suggestionId?: string;
370
382
  }) => Promise<string | null>;
383
+ onSuggestionAccepted?: (info: {
384
+ acceptedText: string;
385
+ suggestionId: string;
386
+ visibleMs: number;
387
+ }) => void;
388
+ onSuggestionRejected?: (info: {
389
+ reason: 'cursor-move' | 'typing' | 'esc' | 'blur' | 'other';
390
+ suggestionId: string;
391
+ visibleMs: number;
392
+ }) => void;
371
393
  }
372
394
  //#endregion
373
395
  //#region src/plugins/auto-complete/react/ReactAutoCompletePlugin.d.ts
@@ -579,782 +601,322 @@ interface ReactCodemirrorPluginProps {
579
601
  //#region src/plugins/codemirror-block/react/ReactCodemirrorNode.d.ts
580
602
  declare const ReactCodemirrorPlugin: FC<ReactCodemirrorPluginProps>;
581
603
  //#endregion
582
- //#region src/plugins/file/command/index.d.ts
583
- declare const INSERT_FILE_COMMAND: _$lexical.LexicalCommand<{
584
- file: File;
585
- }>;
586
- //#endregion
587
- //#region src/plugins/file/node/FileNode.d.ts
588
- type SerializedFileNode = Spread<{
589
- fileUrl?: string;
590
- message?: string;
591
- name: string;
592
- size?: number;
593
- status?: 'pending' | 'uploaded' | 'error';
594
- }, SerializedLexicalNode>;
595
- declare class FileNode extends DecoratorNode<any> {
596
- static getType(): string;
597
- static clone(node: FileNode): FileNode;
598
- static importJSON(serializedNode: SerializedFileNode): FileNode;
599
- static importDOM(): DOMConversionMap | null;
600
- __name: string;
601
- __fileUrl: string | undefined;
602
- __size: number | undefined;
603
- __status: 'pending' | 'uploaded' | 'error';
604
- __message?: string;
605
- get name(): string;
606
- get fileUrl(): string | undefined;
607
- get size(): number | undefined;
608
- get status(): 'pending' | 'uploaded' | 'error';
609
- get message(): string | undefined;
610
- constructor(name: string, fileUrl?: string, size?: number, status?: 'pending' | 'uploaded' | 'error', message?: string, key?: string);
611
- setUploaded(url: string): void;
612
- setError(message: string): void;
613
- exportDOM(): DOMExportOutput;
614
- createDOM(config: EditorConfig): HTMLElement;
615
- exportJSON(): SerializedFileNode;
616
- updateFromJSON(serializedNode: LexicalUpdateJSON<SerializedFileNode>): this;
617
- getTextContent(): string;
618
- updateDOM(): boolean;
619
- decorate(editor: LexicalEditor): any;
604
+ //#region node_modules/.pnpm/@types+unist@3.0.3/node_modules/@types/unist/index.d.ts
605
+ // ## Interfaces
606
+ /**
607
+ * Info associated with nodes by the ecosystem.
608
+ *
609
+ * This space is guaranteed to never be specified by unist or specifications
610
+ * implementing unist.
611
+ * But you can use it in utilities and plugins to store data.
612
+ *
613
+ * This type can be augmented to register custom data.
614
+ * For example:
615
+ *
616
+ * ```ts
617
+ * declare module 'unist' {
618
+ * interface Data {
619
+ * // `someNode.data.myId` is typed as `number | undefined`
620
+ * myId?: number | undefined
621
+ * }
622
+ * }
623
+ * ```
624
+ */
625
+ interface Data$1 {}
626
+ /**
627
+ * One place in a source file.
628
+ */
629
+ interface Point {
630
+ /**
631
+ * Line in a source file (1-indexed integer).
632
+ */
633
+ line: number;
634
+ /**
635
+ * Column in a source file (1-indexed integer).
636
+ */
637
+ column: number;
638
+ /**
639
+ * Character in a source file (0-indexed integer).
640
+ */
641
+ offset?: number | undefined;
620
642
  }
621
- //#endregion
622
- //#region src/plugins/file/plugin/index.d.ts
623
- interface FilePluginOptions {
624
- decorator: (node: FileNode, editor: LexicalEditor) => any;
625
- handleUpload: (file: File) => Promise<{
626
- url: string;
627
- }>;
628
- markdownWriter?: (file: FileNode) => string;
629
- theme?: {
630
- file?: string;
631
- };
643
+ /**
644
+ * Position of a node in a source document.
645
+ *
646
+ * A position is a range between two points.
647
+ */
648
+ interface Position {
649
+ /**
650
+ * Place of the first character of the parsed source region.
651
+ */
652
+ start: Point;
653
+ /**
654
+ * Place of the first character after the parsed source region.
655
+ */
656
+ end: Point;
632
657
  }
633
- declare const FilePlugin: IEditorPluginConstructor<FilePluginOptions>;
634
- //#endregion
635
- //#region src/plugins/file/react/type.d.ts
636
- interface ReactFilePluginProps {
637
- className?: string;
638
- handleUpload: (file: File) => Promise<{
639
- url: string;
640
- }>;
641
- locale?: Partial<Record<keyof ILocaleKeys, string>>;
642
- markdownWriter?: (file: FileNode) => string;
643
- theme?: {
644
- file?: string;
645
- };
658
+ /**
659
+ * Abstract unist node.
660
+ *
661
+ * The syntactic unit in unist syntax trees are called nodes.
662
+ *
663
+ * This interface is supposed to be extended.
664
+ * If you can use {@link Literal} or {@link Parent}, you should.
665
+ * But for example in markdown, a `thematicBreak` (`***`), is neither literal
666
+ * nor parent, but still a node.
667
+ */
668
+ interface Node$2 {
669
+ /**
670
+ * Node type.
671
+ */
672
+ type: string;
673
+ /**
674
+ * Info from the ecosystem.
675
+ */
676
+ data?: Data$1 | undefined;
677
+ /**
678
+ * Position of a node in a source document.
679
+ *
680
+ * Nodes that are generated (not in the original source document) must not
681
+ * have a position.
682
+ */
683
+ position?: Position | undefined;
646
684
  }
647
685
  //#endregion
648
- //#region src/plugins/file/react/ReactFilePlugin.d.ts
649
- declare const ReactFilePlugin: FC<ReactFilePluginProps>;
650
- //#endregion
651
- //#region src/plugins/hr/command/index.d.ts
652
- declare const INSERT_HORIZONTAL_RULE_COMMAND: _$lexical.LexicalCommand<unknown>;
653
- //#endregion
654
- //#region src/plugins/hr/node/HorizontalRuleNode.d.ts
655
- type SerializedHorizontalRuleNode = SerializedLexicalNode;
656
- declare class HorizontalRuleNode extends DecoratorNode<any> {
657
- static getType(): string;
658
- static clone(node: HorizontalRuleNode): HorizontalRuleNode;
659
- static importJSON(serializedNode: SerializedHorizontalRuleNode): HorizontalRuleNode;
660
- static importDOM(): DOMConversionMap | null;
661
- exportDOM(): DOMExportOutput;
662
- createDOM(config: EditorConfig): HTMLElement;
663
- getTextContent(): string;
664
- isInline(): false;
665
- updateDOM(): boolean;
666
- decorate(editor: LexicalEditor): any;
686
+ //#region node_modules/.pnpm/@types+mdast@4.0.4/node_modules/@types/mdast/index.d.ts
687
+ // ## Enumeration
688
+ /**
689
+ * How phrasing content is aligned
690
+ * ({@link https://drafts.csswg.org/css-text/ | [CSSTEXT]}).
691
+ *
692
+ * * `'left'`: See the
693
+ * {@link https://drafts.csswg.org/css-text/#valdef-text-align-left | left}
694
+ * value of the `text-align` CSS property
695
+ * * `'right'`: See the
696
+ * {@link https://drafts.csswg.org/css-text/#valdef-text-align-right | right}
697
+ * value of the `text-align` CSS property
698
+ * * `'center'`: See the
699
+ * {@link https://drafts.csswg.org/css-text/#valdef-text-align-center | center}
700
+ * value of the `text-align` CSS property
701
+ * * `null`: phrasing content is aligned as defined by the host environment
702
+ *
703
+ * Used in GFM tables.
704
+ */
705
+ type AlignType = "center" | "left" | "right" | null;
706
+ /**
707
+ * Explicitness of a reference.
708
+ *
709
+ * `'shortcut'`: the reference is implicit, its identifier inferred from its
710
+ * content
711
+ * `'collapsed'`: the reference is explicit, its identifier inferred from its
712
+ * content
713
+ * `'full'`: the reference is explicit, its identifier explicitly set
714
+ */
715
+ type ReferenceType = "shortcut" | "collapsed" | "full";
716
+ // ## Mixin
717
+ /**
718
+ * Node with a fallback.
719
+ */
720
+ interface Alternative {
721
+ /**
722
+ * Equivalent content for environments that cannot represent the node as
723
+ * intended.
724
+ */
725
+ alt?: string | null | undefined;
667
726
  }
668
- //#endregion
669
- //#region src/plugins/hr/plugin/index.d.ts
670
- interface HRPluginOptions {
671
- decorator: (node: HorizontalRuleNode, editor: LexicalEditor) => any;
672
- theme?: string;
727
+ /**
728
+ * Internal relation from one node to another.
729
+ *
730
+ * Whether the value of `identifier` is expected to be a unique identifier or
731
+ * not depends on the type of node including the Association.
732
+ * An example of this is that they should be unique on {@link Definition},
733
+ * whereas multiple {@link LinkReference}s can be non-unique to be associated
734
+ * with one definition.
735
+ */
736
+ interface Association {
737
+ /**
738
+ * Relation of association.
739
+ *
740
+ * `identifier` is a source value: character escapes and character
741
+ * references are not parsed.
742
+ *
743
+ * It can match another node.
744
+ *
745
+ * Its value must be normalized.
746
+ * To normalize a value, collapse markdown whitespace (`[\t\n\r ]+`) to a space,
747
+ * trim the optional initial and/or final space, and perform Unicode-aware
748
+ * case-folding.
749
+ */
750
+ identifier: string;
751
+ /**
752
+ * Relation of association, in parsed form.
753
+ *
754
+ * `label` is a `string` value: it works just like `title` on {@link Link}
755
+ * or a `lang` on {@link Code}: character escapes and character references
756
+ * are parsed.
757
+ *
758
+ * It can match another node.
759
+ */
760
+ label?: string | null | undefined;
673
761
  }
674
- declare const HRPlugin: IEditorPluginConstructor<HRPluginOptions>;
675
- //#endregion
676
- //#region src/plugins/hr/react/type.d.ts
677
- interface ReactHRPluginProps {
678
- className?: string;
762
+ /**
763
+ * Marker that is associated to another node.
764
+ */
765
+ interface Reference extends Association {
766
+ /**
767
+ * Explicitness of the reference.
768
+ */
769
+ referenceType: ReferenceType;
679
770
  }
680
- //#endregion
681
- //#region src/plugins/hr/react/ReactHRPlugin.d.ts
682
- declare const ReactHRPlugin: FC<ReactHRPluginProps>;
683
- //#endregion
684
- //#region src/plugins/image/command/index.d.ts
685
- declare const INSERT_IMAGE_COMMAND: _$lexical.LexicalCommand<{
686
- block?: boolean;
687
- file: File;
688
- maxWidth?: number;
689
- range?: Range | null;
690
- }>;
691
- //#endregion
692
- //#region src/plugins/image/node/basie-image-node.d.ts
693
- type SerializedImageNode = Spread<{
694
- altText: string;
695
- height?: number;
696
- maxWidth: number;
697
- src: string;
698
- status?: 'uploaded' | 'loading' | 'error';
699
- width?: number;
700
- }, SerializedLexicalNode>;
701
- declare class BaseImageNode extends DecoratorNode<any> {
702
- __src: string;
703
- __altText: string;
704
- __width: 'inherit' | number;
705
- __height: 'inherit' | number;
706
- __maxWidth: number;
707
- static clone(node: BaseImageNode): BaseImageNode;
708
- static importJSON(serializedNode: SerializedImageNode): BaseImageNode;
709
- static getType(): string;
710
- updateFromJSON(serializedNode: LexicalUpdateJSON<SerializedImageNode>): this;
711
- exportDOM(): DOMExportOutput;
712
- constructor(src: string, altText: string, maxWidth: number, width?: 'inherit' | number, height?: 'inherit' | number, key?: NodeKey);
713
- exportJSON(): SerializedImageNode;
714
- setWidthAndHeight(width: 'inherit' | number, height: 'inherit' | number): void;
715
- isInline(): boolean;
716
- createDOM(config: EditorConfig): HTMLElement;
717
- updateDOM(): false;
718
- getSrc(): string;
719
- getAltText(): string;
720
- }
721
- //#endregion
722
- //#region src/plugins/image/node/block-image-node.d.ts
723
- declare class BlockImageNode extends BaseImageNode {
724
- private static _decorate;
725
- static setDecorate(decorate: (node: BlockImageNode) => any): void;
726
- static getType(): string;
727
- private __loading;
728
- private __status;
729
- private __message;
730
- private __extra;
731
- get isLoading(): boolean;
732
- get status(): 'uploaded' | 'loading' | 'error';
733
- get message(): string | null;
734
- get src(): string;
735
- get altText(): string;
736
- get maxWidth(): number;
737
- get width(): number | string;
738
- get height(): number | string;
739
- constructor(opt: {
740
- altText: string;
741
- height?: 'inherit' | number;
742
- key?: NodeKey;
743
- maxWidth: number;
744
- src: string;
745
- status?: 'uploaded' | 'loading' | 'error';
746
- width?: 'inherit' | number;
747
- });
748
- isInline(): boolean;
749
- setMaxWidth(maxWidth: number): void;
750
- setWidth(width: number): void;
751
- setStatus(status: 'uploaded' | 'loading' | 'error'): void;
752
- setUploaded(url: string): void;
753
- setError(message: string): void;
754
- static clone(node: BlockImageNode): BlockImageNode;
755
- static importJSON(serializedNode: SerializedImageNode): BlockImageNode;
756
- static importDOM(): DOMConversionMap | null;
757
- decorate(): any;
758
- createDOM(config: EditorConfig): HTMLElement;
759
- }
760
- //#endregion
761
- //#region src/plugins/image/node/image-node.d.ts
762
- declare class ImageNode extends BaseImageNode {
763
- private static _decorate;
764
- static setDecorate(decorate: (node: ImageNode) => any): void;
765
- static getType(): string;
766
- private __loading;
767
- private __status;
768
- private __message;
769
- private __extra;
770
- constructor(opt: {
771
- altText: string;
772
- height?: 'inherit' | number;
773
- key?: NodeKey;
774
- maxWidth: number;
775
- src: string;
776
- status?: 'uploaded' | 'loading' | 'error';
777
- width?: 'inherit' | number;
778
- });
779
- get isLoading(): boolean;
780
- get status(): 'uploaded' | 'loading' | 'error';
781
- get message(): string | null;
782
- get src(): string;
783
- get altText(): string;
784
- get maxWidth(): number;
785
- get width(): number | string;
786
- get height(): number | string;
787
- setMaxWidth(maxWidth: number): void;
788
- setStatus(status: 'uploaded' | 'loading' | 'error'): void;
789
- setWidth(width: number): void;
790
- setUploaded(url: string): void;
791
- setError(message: string): void;
792
- static clone(node: ImageNode): ImageNode;
793
- static importJSON(serializedNode: SerializedImageNode): ImageNode;
794
- static importDOM(): DOMConversionMap | null;
795
- decorate(): any;
796
- }
797
- //#endregion
798
- //#region src/plugins/image/plugin/index.d.ts
799
- interface ImagePluginOptions {
800
- defaultBlockImage?: boolean;
801
- handleRehost?: (url: string) => Promise<{
802
- url: string;
803
- }>;
804
- handleUpload: (file: File) => Promise<{
805
- url: string;
806
- }>;
807
- needRehost?: (url: string) => boolean;
808
- renderImage: (node: ImageNode | BlockImageNode) => JSX.Element | null;
809
- theme?: {
810
- blockImage?: string;
811
- image?: string;
812
- };
813
- }
814
- declare const ImagePlugin: IEditorPluginConstructor<ImagePluginOptions>;
815
- //#endregion
816
- //#region src/plugins/image/react/type.d.ts
817
- interface ReactImagePluginProps {
818
- className?: string;
819
- defaultBlockImage?: boolean;
820
- handleRehost?: (url: string) => Promise<{
821
- url: string;
822
- }>;
823
- handleUpload?: (file: File) => Promise<{
824
- url: string;
825
- }>;
826
- needRehost?: (url: string) => boolean;
827
- /**
828
- * Custom file picker for environments where programmatic input.click() is blocked (e.g. Electron).
829
- * When provided, this will be called instead of triggering the hidden file input.
830
- */
831
- onPickFile?: () => Promise<File | null>;
832
- theme?: {
833
- blockImage?: string;
834
- image?: string;
835
- };
836
- }
837
- //#endregion
838
- //#region src/plugins/image/react/ReactImagePlugin.d.ts
839
- declare const ReactImagePlugin: FC<ReactImagePluginProps>;
840
- //#endregion
841
- //#region src/plugins/inode/plugin/index.d.ts
842
771
  /**
843
- * NodePluginOptions - Configuration options for the Node plugin
772
+ * Reference to resource.
844
773
  */
845
- interface INodePluginOptions {
774
+ interface Resource {
846
775
  /**
847
- * Enable or disable the node data source
848
- * @default true
776
+ * URL to the referenced resource.
849
777
  */
850
- enabled?: boolean;
778
+ url: string;
779
+ /**
780
+ * Advisory information for the resource, such as would be appropriate for
781
+ * a tooltip.
782
+ */
783
+ title?: string | null | undefined;
851
784
  }
785
+ // ## Interfaces
852
786
  /**
853
- * LitexmlPlugin - A plugin that provides XML-based data source support
854
- * Allows converting between Lexical editor state and XML format
787
+ * Info associated with mdast nodes by the ecosystem.
788
+ *
789
+ * This space is guaranteed to never be specified by unist or mdast.
790
+ * But you can use it in utilities and plugins to store data.
791
+ *
792
+ * This type can be augmented to register custom data.
793
+ * For example:
794
+ *
795
+ * ```ts
796
+ * declare module 'mdast' {
797
+ * interface Data {
798
+ * // `someNode.data.myId` is typed as `number | undefined`
799
+ * myId?: number | undefined
800
+ * }
801
+ * }
802
+ * ```
855
803
  */
856
- declare const INodePlugin: IEditorPluginConstructor<INodePluginOptions>;
857
- //#endregion
858
- //#region src/plugins/inode/react/index.d.ts
859
- declare const ReactNodePlugin: FC<void>;
860
- //#endregion
861
- //#region src/plugins/inode/service/index.d.ts
862
- interface INodeService {
863
- processNodeTree(inode: {
864
- root: IRootNode;
865
- }): void;
866
- registerProcessNodeTree(process: (inode: {
867
- root: IRootNode;
868
- }) => void): void;
804
+ interface Data extends Data$1 {}
805
+ // ## Content maps
806
+ /**
807
+ * Union of registered mdast nodes that can occur where block content is
808
+ * expected.
809
+ *
810
+ * To register custom mdast nodes, add them to {@link BlockContentMap}.
811
+ * They will be automatically added here.
812
+ */
813
+ type BlockContent = BlockContentMap[keyof BlockContentMap];
814
+ /**
815
+ * Registry of all mdast nodes that can occur where {@link BlockContent} is
816
+ * expected.
817
+ *
818
+ * This interface can be augmented to register custom node types:
819
+ *
820
+ * ```ts
821
+ * declare module 'mdast' {
822
+ * interface BlockContentMap {
823
+ * // Allow using MDX ESM nodes defined by `remark-mdx`.
824
+ * mdxjsEsm: MdxjsEsm;
825
+ * }
826
+ * }
827
+ * ```
828
+ *
829
+ * For a union of all block content, see {@link RootContent}.
830
+ */
831
+ interface BlockContentMap {
832
+ blockquote: Blockquote;
833
+ code: Code;
834
+ heading: Heading;
835
+ html: Html;
836
+ list: List;
837
+ paragraph: Paragraph;
838
+ table: Table;
839
+ thematicBreak: ThematicBreak;
869
840
  }
870
841
  /**
871
- * Service ID for Node service
842
+ * Union of registered mdast nodes that can occur where definition content is
843
+ * expected.
844
+ *
845
+ * To register custom mdast nodes, add them to {@link DefinitionContentMap}.
846
+ * They will be automatically added here.
872
847
  */
873
- declare const INodeService: IServiceID<INodeService>;
874
- //#endregion
875
- //#region src/plugins/link/command/index.d.ts
876
- declare const INSERT_LINK_COMMAND: _$lexical.LexicalCommand<{
877
- title?: string;
878
- url?: string;
879
- }>;
880
- //#endregion
881
- //#region src/plugins/link/node/LinkNode.d.ts
882
- type LinkAttributes = {
883
- rel?: null | string;
884
- target?: null | string;
885
- title?: null | string;
886
- };
887
- //#endregion
888
- //#region src/plugins/link/plugin/index.d.ts
889
- interface LinkPluginOptions {
890
- attributes?: LinkAttributes;
891
- enableHotkey?: boolean;
892
- linkRegex?: RegExp;
893
- theme?: {
894
- link?: string;
895
- };
896
- validateUrl?: (url: string) => boolean;
897
- }
898
- declare const LinkPlugin: IEditorPluginConstructor<LinkPluginOptions>;
899
- //#endregion
900
- //#region src/plugins/link/react/type.d.ts
901
- interface ReactLinkPluginProps {
902
- attributes?: LinkAttributes;
903
- className?: string;
904
- enableHotkey?: boolean;
905
- theme?: {
906
- link?: string;
907
- };
908
- validateUrl?: (url: string) => boolean;
909
- }
910
- //#endregion
911
- //#region src/plugins/link/react/ReactLinkPlugin.d.ts
912
- declare const ReactLinkPlugin: FC<ReactLinkPluginProps>;
913
- //#endregion
914
- //#region src/plugins/link/service/i-link-service.d.ts
915
- interface ILinkService {
916
- setLinkToolbar(enable: boolean): void;
917
- }
918
- declare const ILinkService: IServiceID<ILinkService>;
919
- //#endregion
920
- //#region src/plugins/link-highlight/command/index.d.ts
921
- declare const INSERT_LINK_HIGHLIGHT_COMMAND: _$lexical.LexicalCommand<undefined>;
922
- declare function registerLinkHighlightCommand(editor: LexicalEditor): () => void;
923
- //#endregion
924
- //#region src/plugins/link-highlight/plugin/index.d.ts
925
- interface LinkHighlightPluginOptions {
926
- enableHotkey?: boolean;
927
- /**
928
- * Enable auto-highlight when pasting URLs
929
- * @default true
930
- */
931
- enablePasteAutoHighlight?: boolean;
932
- theme?: string;
933
- /**
934
- * Custom URL validation regex
935
- */
936
- urlRegex?: RegExp;
937
- }
938
- declare const LinkHighlightPlugin: IEditorPluginConstructor<LinkHighlightPluginOptions>;
939
- //#endregion
940
- //#region src/plugins/link-highlight/react/type.d.ts
941
- interface ReactLinkHighlightPluginProps {
942
- className?: string;
943
- /**
944
- * Enable keyboard shortcut (Ctrl+K / Cmd+K)
945
- * @default true
946
- */
947
- enableHotkey?: boolean;
948
- /**
949
- * Enable auto-highlight when pasting URLs
950
- * @default true
951
- */
952
- enablePasteAutoHighlight?: boolean;
953
- }
954
- //#endregion
955
- //#region src/plugins/link-highlight/react/ReactLinkHighlightPlugin.d.ts
956
- declare const ReactLinkHighlightPlugin: FC<ReactLinkHighlightPluginProps>;
957
- //#endregion
958
- //#region src/plugins/list/plugin/checkList.d.ts
959
- declare const INSERT_CHECK_LIST_COMMAND: LexicalCommand<void>;
960
- //#endregion
961
- //#region src/plugins/list/plugin/index.d.ts
962
- interface ListPluginOptions {
963
- enableHotkey?: boolean;
964
- theme?: string;
965
- }
966
- declare const ListPlugin: IEditorPluginConstructor<ListPluginOptions>;
967
- //#endregion
968
- //#region src/plugins/list/react/type.d.ts
969
- interface ReactListPluginProps {
970
- className?: string;
971
- enableHotkey?: boolean;
972
- }
973
- //#endregion
974
- //#region src/plugins/list/react/ReactListPlugin.d.ts
975
- declare const ReactListPlugin: FC<ReactListPluginProps>;
976
- //#endregion
977
- //#region src/plugins/litexml/command/diffCommand.d.ts
978
- declare enum DiffAction {
979
- Reject = 0,
980
- Accept = 1
981
- }
982
- declare const LITEXML_DIFFNODE_COMMAND: _$lexical.LexicalCommand<{
983
- action: DiffAction;
984
- nodeKey: string;
985
- }>;
986
- declare const LITEXML_DIFFNODE_ALL_COMMAND: _$lexical.LexicalCommand<{
987
- action: DiffAction;
988
- }>;
989
- //#endregion
990
- //#region src/plugins/litexml/node/DiffNode.d.ts
991
- type DiffType = 'add' | 'remove' | 'modify' | 'unchanged' | 'listItemModify' | 'listItemRemove' | 'listItemAdd';
992
- type SerializedDiffNode = Spread<{
993
- diffType: DiffType;
994
- }, SerializedElementNode>;
995
- /** DiffNode - contains two block children: original and modified */
996
- declare class DiffNode extends CardLikeElementNode {
997
- static getType(): string;
998
- static clone(node: DiffNode): DiffNode;
999
- static importJSON(serializedNode: SerializedDiffNode): DiffNode;
1000
- static importDOM(): null;
1001
- private __diffType;
1002
- constructor(type: DiffType, key?: string);
1003
- get diffType(): DiffType;
1004
- setDiffType(type: DiffType): this;
1005
- updateFromJSON(serializedNode: LexicalUpdateJSON<SerializedDiffNode>): this;
1006
- exportJSON(): SerializedDiffNode;
1007
- exportDOM(editor: LexicalEditor): DOMExportOutput;
1008
- createDOM(config: EditorConfig, editor: LexicalEditor): HTMLDivElement;
1009
- updateDOM(_prevNode: unknown, _dom: HTMLElement, _config: EditorConfig): boolean;
1010
- getDOMSlot(element: HTMLElement): ElementDOMSlot<HTMLElement>;
1011
- isInline(): boolean;
1012
- isCardLike(): boolean;
1013
- }
1014
- //#endregion
1015
- //#region src/plugins/litexml/plugin/index.d.ts
848
+ type DefinitionContent = DefinitionContentMap[keyof DefinitionContentMap];
1016
849
  /**
1017
- * LitexmlPluginOptions - Configuration options for the Litexml plugin
850
+ * Registry of all mdast nodes that can occur where {@link DefinitionContent}
851
+ * is expected.
852
+ *
853
+ * This interface can be augmented to register custom node types:
854
+ *
855
+ * ```ts
856
+ * declare module 'mdast' {
857
+ * interface DefinitionContentMap {
858
+ * custom: Custom;
859
+ * }
860
+ * }
861
+ * ```
862
+ *
863
+ * For a union of all definition content, see {@link RootContent}.
1018
864
  */
1019
- interface LitexmlPluginOptions {
1020
- decorator: (node: DiffNode, editor: LexicalEditor) => any;
1021
- /**
1022
- * Enable or disable the litexml data source
1023
- * @default true
1024
- */
1025
- enabled?: boolean;
1026
- theme?: string;
865
+ interface DefinitionContentMap {
866
+ definition: Definition;
867
+ footnoteDefinition: FootnoteDefinition;
1027
868
  }
1028
869
  /**
1029
- * LitexmlPlugin - A plugin that provides XML-based data source support
1030
- * Allows converting between Lexical editor state and XML format
870
+ * Union of registered mdast nodes that can occur where list content is
871
+ * expected.
872
+ *
873
+ * To register custom mdast nodes, add them to {@link ListContentMap}.
874
+ * They will be automatically added here.
1031
875
  */
1032
- declare const LitexmlPlugin: IEditorPluginConstructor<LitexmlPluginOptions>;
1033
- //#endregion
1034
- //#region src/plugins/litexml/react/index.d.ts
1035
- declare const ReactLiteXmlPlugin: FC<void>;
1036
- //#endregion
1037
- //#region src/plugins/litexml/react/hooks/useHasDiffNode.d.ts
1038
- declare function useHasDiffNode(editor?: IEditor): {
1039
- hasDiff: boolean;
1040
- };
1041
- //#endregion
1042
- //#region node_modules/.pnpm/@types+unist@3.0.3/node_modules/@types/unist/index.d.ts
1043
- // ## Interfaces
876
+ type ListContent = ListContentMap[keyof ListContentMap];
1044
877
  /**
1045
- * Info associated with nodes by the ecosystem.
1046
- *
1047
- * This space is guaranteed to never be specified by unist or specifications
1048
- * implementing unist.
1049
- * But you can use it in utilities and plugins to store data.
878
+ * Registry of all mdast nodes that can occur where {@link ListContent}
879
+ * is expected.
1050
880
  *
1051
- * This type can be augmented to register custom data.
1052
- * For example:
881
+ * This interface can be augmented to register custom node types:
1053
882
  *
1054
883
  * ```ts
1055
- * declare module 'unist' {
1056
- * interface Data {
1057
- * // `someNode.data.myId` is typed as `number | undefined`
1058
- * myId?: number | undefined
884
+ * declare module 'mdast' {
885
+ * interface ListContentMap {
886
+ * custom: Custom;
1059
887
  * }
1060
888
  * }
1061
889
  * ```
890
+ *
891
+ * For a union of all list content, see {@link RootContent}.
1062
892
  */
1063
- interface Data$1 {}
1064
- /**
1065
- * One place in a source file.
1066
- */
1067
- interface Point {
1068
- /**
1069
- * Line in a source file (1-indexed integer).
1070
- */
1071
- line: number;
1072
- /**
1073
- * Column in a source file (1-indexed integer).
1074
- */
1075
- column: number;
1076
- /**
1077
- * Character in a source file (0-indexed integer).
1078
- */
1079
- offset?: number | undefined;
893
+ interface ListContentMap {
894
+ listItem: ListItem;
1080
895
  }
1081
896
  /**
1082
- * Position of a node in a source document.
897
+ * Union of registered mdast nodes that can occur where phrasing content is
898
+ * expected.
1083
899
  *
1084
- * A position is a range between two points.
900
+ * To register custom mdast nodes, add them to {@link PhrasingContentMap}.
901
+ * They will be automatically added here.
1085
902
  */
1086
- interface Position {
1087
- /**
1088
- * Place of the first character of the parsed source region.
1089
- */
1090
- start: Point;
1091
- /**
1092
- * Place of the first character after the parsed source region.
1093
- */
1094
- end: Point;
1095
- }
903
+ type PhrasingContent = PhrasingContentMap[keyof PhrasingContentMap];
1096
904
  /**
1097
- * Abstract unist node.
905
+ * Registry of all mdast nodes that can occur where {@link PhrasingContent}
906
+ * is expected.
1098
907
  *
1099
- * The syntactic unit in unist syntax trees are called nodes.
908
+ * This interface can be augmented to register custom node types:
1100
909
  *
1101
- * This interface is supposed to be extended.
1102
- * If you can use {@link Literal} or {@link Parent}, you should.
1103
- * But for example in markdown, a `thematicBreak` (`***`), is neither literal
1104
- * nor parent, but still a node.
1105
- */
1106
- interface Node$2 {
1107
- /**
1108
- * Node type.
1109
- */
1110
- type: string;
1111
- /**
1112
- * Info from the ecosystem.
1113
- */
1114
- data?: Data$1 | undefined;
1115
- /**
1116
- * Position of a node in a source document.
1117
- *
1118
- * Nodes that are generated (not in the original source document) must not
1119
- * have a position.
1120
- */
1121
- position?: Position | undefined;
1122
- }
1123
- //#endregion
1124
- //#region node_modules/.pnpm/@types+mdast@4.0.4/node_modules/@types/mdast/index.d.ts
1125
- // ## Enumeration
1126
- /**
1127
- * How phrasing content is aligned
1128
- * ({@link https://drafts.csswg.org/css-text/ | [CSSTEXT]}).
1129
- *
1130
- * * `'left'`: See the
1131
- * {@link https://drafts.csswg.org/css-text/#valdef-text-align-left | left}
1132
- * value of the `text-align` CSS property
1133
- * * `'right'`: See the
1134
- * {@link https://drafts.csswg.org/css-text/#valdef-text-align-right | right}
1135
- * value of the `text-align` CSS property
1136
- * * `'center'`: See the
1137
- * {@link https://drafts.csswg.org/css-text/#valdef-text-align-center | center}
1138
- * value of the `text-align` CSS property
1139
- * * `null`: phrasing content is aligned as defined by the host environment
1140
- *
1141
- * Used in GFM tables.
1142
- */
1143
- type AlignType = "center" | "left" | "right" | null;
1144
- /**
1145
- * Explicitness of a reference.
1146
- *
1147
- * `'shortcut'`: the reference is implicit, its identifier inferred from its
1148
- * content
1149
- * `'collapsed'`: the reference is explicit, its identifier inferred from its
1150
- * content
1151
- * `'full'`: the reference is explicit, its identifier explicitly set
1152
- */
1153
- type ReferenceType = "shortcut" | "collapsed" | "full";
1154
- // ## Mixin
1155
- /**
1156
- * Node with a fallback.
1157
- */
1158
- interface Alternative {
1159
- /**
1160
- * Equivalent content for environments that cannot represent the node as
1161
- * intended.
1162
- */
1163
- alt?: string | null | undefined;
1164
- }
1165
- /**
1166
- * Internal relation from one node to another.
1167
- *
1168
- * Whether the value of `identifier` is expected to be a unique identifier or
1169
- * not depends on the type of node including the Association.
1170
- * An example of this is that they should be unique on {@link Definition},
1171
- * whereas multiple {@link LinkReference}s can be non-unique to be associated
1172
- * with one definition.
1173
- */
1174
- interface Association {
1175
- /**
1176
- * Relation of association.
1177
- *
1178
- * `identifier` is a source value: character escapes and character
1179
- * references are not parsed.
1180
- *
1181
- * It can match another node.
1182
- *
1183
- * Its value must be normalized.
1184
- * To normalize a value, collapse markdown whitespace (`[\t\n\r ]+`) to a space,
1185
- * trim the optional initial and/or final space, and perform Unicode-aware
1186
- * case-folding.
1187
- */
1188
- identifier: string;
1189
- /**
1190
- * Relation of association, in parsed form.
1191
- *
1192
- * `label` is a `string` value: it works just like `title` on {@link Link}
1193
- * or a `lang` on {@link Code}: character escapes and character references
1194
- * are parsed.
1195
- *
1196
- * It can match another node.
1197
- */
1198
- label?: string | null | undefined;
1199
- }
1200
- /**
1201
- * Marker that is associated to another node.
1202
- */
1203
- interface Reference extends Association {
1204
- /**
1205
- * Explicitness of the reference.
1206
- */
1207
- referenceType: ReferenceType;
1208
- }
1209
- /**
1210
- * Reference to resource.
1211
- */
1212
- interface Resource {
1213
- /**
1214
- * URL to the referenced resource.
1215
- */
1216
- url: string;
1217
- /**
1218
- * Advisory information for the resource, such as would be appropriate for
1219
- * a tooltip.
1220
- */
1221
- title?: string | null | undefined;
1222
- }
1223
- // ## Interfaces
1224
- /**
1225
- * Info associated with mdast nodes by the ecosystem.
1226
- *
1227
- * This space is guaranteed to never be specified by unist or mdast.
1228
- * But you can use it in utilities and plugins to store data.
1229
- *
1230
- * This type can be augmented to register custom data.
1231
- * For example:
1232
- *
1233
- * ```ts
1234
- * declare module 'mdast' {
1235
- * interface Data {
1236
- * // `someNode.data.myId` is typed as `number | undefined`
1237
- * myId?: number | undefined
1238
- * }
1239
- * }
1240
- * ```
1241
- */
1242
- interface Data extends Data$1 {}
1243
- // ## Content maps
1244
- /**
1245
- * Union of registered mdast nodes that can occur where block content is
1246
- * expected.
1247
- *
1248
- * To register custom mdast nodes, add them to {@link BlockContentMap}.
1249
- * They will be automatically added here.
1250
- */
1251
- type BlockContent = BlockContentMap[keyof BlockContentMap];
1252
- /**
1253
- * Registry of all mdast nodes that can occur where {@link BlockContent} is
1254
- * expected.
1255
- *
1256
- * This interface can be augmented to register custom node types:
1257
- *
1258
- * ```ts
1259
- * declare module 'mdast' {
1260
- * interface BlockContentMap {
1261
- * // Allow using MDX ESM nodes defined by `remark-mdx`.
1262
- * mdxjsEsm: MdxjsEsm;
1263
- * }
1264
- * }
1265
- * ```
1266
- *
1267
- * For a union of all block content, see {@link RootContent}.
1268
- */
1269
- interface BlockContentMap {
1270
- blockquote: Blockquote;
1271
- code: Code;
1272
- heading: Heading;
1273
- html: Html;
1274
- list: List;
1275
- paragraph: Paragraph;
1276
- table: Table;
1277
- thematicBreak: ThematicBreak;
1278
- }
1279
- /**
1280
- * Union of registered mdast nodes that can occur where definition content is
1281
- * expected.
1282
- *
1283
- * To register custom mdast nodes, add them to {@link DefinitionContentMap}.
1284
- * They will be automatically added here.
1285
- */
1286
- type DefinitionContent = DefinitionContentMap[keyof DefinitionContentMap];
1287
- /**
1288
- * Registry of all mdast nodes that can occur where {@link DefinitionContent}
1289
- * is expected.
1290
- *
1291
- * This interface can be augmented to register custom node types:
1292
- *
1293
- * ```ts
1294
- * declare module 'mdast' {
1295
- * interface DefinitionContentMap {
1296
- * custom: Custom;
1297
- * }
1298
- * }
1299
- * ```
1300
- *
1301
- * For a union of all definition content, see {@link RootContent}.
1302
- */
1303
- interface DefinitionContentMap {
1304
- definition: Definition;
1305
- footnoteDefinition: FootnoteDefinition;
1306
- }
1307
- /**
1308
- * Union of registered mdast nodes that can occur where list content is
1309
- * expected.
1310
- *
1311
- * To register custom mdast nodes, add them to {@link ListContentMap}.
1312
- * They will be automatically added here.
1313
- */
1314
- type ListContent = ListContentMap[keyof ListContentMap];
1315
- /**
1316
- * Registry of all mdast nodes that can occur where {@link ListContent}
1317
- * is expected.
1318
- *
1319
- * This interface can be augmented to register custom node types:
1320
- *
1321
- * ```ts
1322
- * declare module 'mdast' {
1323
- * interface ListContentMap {
1324
- * custom: Custom;
1325
- * }
1326
- * }
1327
- * ```
1328
- *
1329
- * For a union of all list content, see {@link RootContent}.
1330
- */
1331
- interface ListContentMap {
1332
- listItem: ListItem;
1333
- }
1334
- /**
1335
- * Union of registered mdast nodes that can occur where phrasing content is
1336
- * expected.
1337
- *
1338
- * To register custom mdast nodes, add them to {@link PhrasingContentMap}.
1339
- * They will be automatically added here.
1340
- */
1341
- type PhrasingContent = PhrasingContentMap[keyof PhrasingContentMap];
1342
- /**
1343
- * Registry of all mdast nodes that can occur where {@link PhrasingContent}
1344
- * is expected.
1345
- *
1346
- * This interface can be augmented to register custom node types:
1347
- *
1348
- * ```ts
1349
- * declare module 'mdast' {
1350
- * interface PhrasingContentMap {
1351
- * // Allow using MDX JSX (text) nodes defined by `remark-mdx`.
1352
- * mdxJsxTextElement: MDXJSXTextElement;
1353
- * }
1354
- * }
1355
- * ```
1356
- *
1357
- * For a union of all phrasing content, see {@link RootContent}.
910
+ * ```ts
911
+ * declare module 'mdast' {
912
+ * interface PhrasingContentMap {
913
+ * // Allow using MDX JSX (text) nodes defined by `remark-mdx`.
914
+ * mdxJsxTextElement: MDXJSXTextElement;
915
+ * }
916
+ * }
917
+ * ```
918
+ *
919
+ * For a union of all phrasing content, see {@link RootContent}.
1358
920
  */
1359
921
  interface PhrasingContentMap {
1360
922
  break: Break;
@@ -1854,338 +1416,865 @@ interface List extends Parent {
1854
1416
  */
1855
1417
  data?: ListData | undefined;
1856
1418
  }
1857
- /**
1858
- * Info associated with mdast list nodes by the ecosystem.
1859
- */
1860
- interface ListData extends Data {}
1861
- /**
1862
- * Markdown list item.
1863
- */
1864
- interface ListItem extends Parent {
1865
- /**
1866
- * Node type of mdast list item.
1867
- */
1868
- type: "listItem";
1869
- /**
1870
- * Whether the item is a tasklist item (when `boolean`).
1871
- *
1872
- * When `true`, the item is complete.
1873
- * When `false`, the item is incomplete.
1874
- */
1875
- checked?: boolean | null | undefined;
1876
- /**
1877
- * Whether one or more of the children are separated with a blank line from
1878
- * its siblings (when `true`), or not (when `false` or not present).
1879
- */
1880
- spread?: boolean | null | undefined;
1881
- /**
1882
- * Children of list item.
1883
- */
1884
- children: Array<BlockContent | DefinitionContent>;
1885
- /**
1886
- * Data associated with the mdast list item.
1887
- */
1888
- data?: ListItemData | undefined;
1419
+ /**
1420
+ * Info associated with mdast list nodes by the ecosystem.
1421
+ */
1422
+ interface ListData extends Data {}
1423
+ /**
1424
+ * Markdown list item.
1425
+ */
1426
+ interface ListItem extends Parent {
1427
+ /**
1428
+ * Node type of mdast list item.
1429
+ */
1430
+ type: "listItem";
1431
+ /**
1432
+ * Whether the item is a tasklist item (when `boolean`).
1433
+ *
1434
+ * When `true`, the item is complete.
1435
+ * When `false`, the item is incomplete.
1436
+ */
1437
+ checked?: boolean | null | undefined;
1438
+ /**
1439
+ * Whether one or more of the children are separated with a blank line from
1440
+ * its siblings (when `true`), or not (when `false` or not present).
1441
+ */
1442
+ spread?: boolean | null | undefined;
1443
+ /**
1444
+ * Children of list item.
1445
+ */
1446
+ children: Array<BlockContent | DefinitionContent>;
1447
+ /**
1448
+ * Data associated with the mdast list item.
1449
+ */
1450
+ data?: ListItemData | undefined;
1451
+ }
1452
+ /**
1453
+ * Info associated with mdast list item nodes by the ecosystem.
1454
+ */
1455
+ interface ListItemData extends Data {}
1456
+ /**
1457
+ * Markdown paragraph.
1458
+ */
1459
+ interface Paragraph extends Parent {
1460
+ /**
1461
+ * Node type of mdast paragraph.
1462
+ */
1463
+ type: "paragraph";
1464
+ /**
1465
+ * Children of paragraph.
1466
+ */
1467
+ children: PhrasingContent[];
1468
+ /**
1469
+ * Data associated with the mdast paragraph.
1470
+ */
1471
+ data?: ParagraphData | undefined;
1472
+ }
1473
+ /**
1474
+ * Info associated with mdast paragraph nodes by the ecosystem.
1475
+ */
1476
+ interface ParagraphData extends Data {}
1477
+ /**
1478
+ * Document fragment or a whole document.
1479
+ *
1480
+ * Should be used as the root of a tree and must not be used as a child.
1481
+ */
1482
+ interface Root extends Parent {
1483
+ /**
1484
+ * Node type of mdast root.
1485
+ */
1486
+ type: "root";
1487
+ /**
1488
+ * Data associated with the mdast root.
1489
+ */
1490
+ data?: RootData | undefined;
1491
+ }
1492
+ /**
1493
+ * Info associated with mdast root nodes by the ecosystem.
1494
+ */
1495
+ interface RootData extends Data {}
1496
+ /**
1497
+ * Markdown strong.
1498
+ */
1499
+ interface Strong extends Parent {
1500
+ /**
1501
+ * Node type of mdast strong.
1502
+ */
1503
+ type: "strong";
1504
+ /**
1505
+ * Children of strong.
1506
+ */
1507
+ children: PhrasingContent[];
1508
+ /**
1509
+ * Data associated with the mdast strong.
1510
+ */
1511
+ data?: StrongData | undefined;
1512
+ }
1513
+ /**
1514
+ * Info associated with mdast strong nodes by the ecosystem.
1515
+ */
1516
+ interface StrongData extends Data {}
1517
+ /**
1518
+ * Markdown GFM table.
1519
+ */
1520
+ interface Table extends Parent {
1521
+ /**
1522
+ * Node type of mdast GFM table.
1523
+ */
1524
+ type: "table";
1525
+ /**
1526
+ * How cells in columns are aligned.
1527
+ */
1528
+ align?: AlignType[] | null | undefined;
1529
+ /**
1530
+ * Children of GFM table.
1531
+ */
1532
+ children: TableContent[];
1533
+ /**
1534
+ * Data associated with the mdast GFM table.
1535
+ */
1536
+ data?: TableData | undefined;
1537
+ }
1538
+ /**
1539
+ * Info associated with mdast GFM table nodes by the ecosystem.
1540
+ */
1541
+ interface TableData extends Data {}
1542
+ /**
1543
+ * Markdown GFM table row.
1544
+ */
1545
+ interface TableRow extends Parent {
1546
+ /**
1547
+ * Node type of mdast GFM table row.
1548
+ */
1549
+ type: "tableRow";
1550
+ /**
1551
+ * Children of GFM table row.
1552
+ */
1553
+ children: RowContent[];
1554
+ /**
1555
+ * Data associated with the mdast GFM table row.
1556
+ */
1557
+ data?: TableRowData | undefined;
1558
+ }
1559
+ /**
1560
+ * Info associated with mdast GFM table row nodes by the ecosystem.
1561
+ */
1562
+ interface TableRowData extends Data {}
1563
+ /**
1564
+ * Markdown GFM table cell.
1565
+ */
1566
+ interface TableCell extends Parent {
1567
+ /**
1568
+ * Node type of mdast GFM table cell.
1569
+ */
1570
+ type: "tableCell";
1571
+ /**
1572
+ * Children of GFM table cell.
1573
+ */
1574
+ children: PhrasingContent[];
1575
+ /**
1576
+ * Data associated with the mdast GFM table cell.
1577
+ */
1578
+ data?: TableCellData | undefined;
1579
+ }
1580
+ /**
1581
+ * Info associated with mdast GFM table cell nodes by the ecosystem.
1582
+ */
1583
+ interface TableCellData extends Data {}
1584
+ /**
1585
+ * Markdown text.
1586
+ */
1587
+ interface Text extends Literal {
1588
+ /**
1589
+ * Node type of mdast text.
1590
+ */
1591
+ type: "text";
1592
+ /**
1593
+ * Data associated with the mdast text.
1594
+ */
1595
+ data?: TextData | undefined;
1596
+ }
1597
+ /**
1598
+ * Info associated with mdast text nodes by the ecosystem.
1599
+ */
1600
+ interface TextData extends Data {}
1601
+ /**
1602
+ * Markdown thematic break (horizontal rule).
1603
+ */
1604
+ interface ThematicBreak extends Node$1 {
1605
+ /**
1606
+ * Node type of mdast thematic break.
1607
+ */
1608
+ type: "thematicBreak";
1609
+ /**
1610
+ * Data associated with the mdast thematic break.
1611
+ */
1612
+ data?: ThematicBreakData | undefined;
1613
+ }
1614
+ /**
1615
+ * Info associated with mdast thematic break nodes by the ecosystem.
1616
+ */
1617
+ interface ThematicBreakData extends Data {}
1618
+ /**
1619
+ * Markdown YAML.
1620
+ */
1621
+ interface Yaml extends Literal {
1622
+ /**
1623
+ * Node type of mdast YAML.
1624
+ */
1625
+ type: "yaml";
1626
+ /**
1627
+ * Data associated with the mdast YAML.
1628
+ */
1629
+ data?: YamlData | undefined;
1630
+ }
1631
+ /**
1632
+ * Info associated with mdast YAML nodes by the ecosystem.
1633
+ */
1634
+ interface YamlData extends Data {}
1635
+ //#endregion
1636
+ //#region src/plugins/markdown/data-source/markdown/parse.d.ts
1637
+ type MarkdownReadNode = INode | ITextNode | IElementNode;
1638
+ type MarkdownNode = Root | RootContent | PhrasingContent;
1639
+ type MarkdownReaderFunc<K> = (node: Extract<MarkdownNode, {
1640
+ type: K;
1641
+ }>, children: MarkdownReadNode[], index: number) => MarkdownReadNode | MarkdownReadNode[] | false;
1642
+ type TransformerRecord = { [K in MarkdownNode['type']]?: MarkdownReaderFunc<K> | Array<MarkdownReaderFunc<K>> };
1643
+ //#endregion
1644
+ //#region src/plugins/markdown/service/transformers.d.ts
1645
+ type TextFormatTransformer = Readonly<{
1646
+ format?: ReadonlyArray<TextFormatType>;
1647
+ intraword?: boolean;
1648
+ process?: (selection: RangeSelection) => boolean | void;
1649
+ tag: string;
1650
+ type: 'text-format';
1651
+ }>;
1652
+ type TextMatchTransformer = Readonly<{
1653
+ /**
1654
+ * For import operations, this function can be used to determine the end index of the match, after `importRegExp` has matched.
1655
+ * Without this function, the end index will be determined by the length of the match from `importRegExp`. Manually determining the end index can be useful if
1656
+ * the match from `importRegExp` is not the entire text content of the node. That way, `importRegExp` can be used to match only the start of the node, and `getEndIndex`
1657
+ * can be used to match the end of the node.
1658
+ *
1659
+ * @returns The end index of the match, or false if the match was unsuccessful and a different transformer should be tried.
1660
+ */
1661
+ getEndIndex?: (node: TextNode, match: RegExpMatchArray) => number | false;
1662
+ /**
1663
+ * This regex determines what text is matched during markdown imports
1664
+ */
1665
+ importRegExp?: RegExp;
1666
+ /**
1667
+ * This regex determines what text is matched for markdown shortcuts while typing in the editor
1668
+ */
1669
+ regExp: RegExp;
1670
+ /**
1671
+ * Determines how the matched markdown text should be transformed into a node during the markdown import process
1672
+ *
1673
+ * @returns nothing, or a TextNode that may be a child of the new node that is created.
1674
+ * If a TextNode is returned, text format matching will be applied to it (e.g. bold, italic, etc.)
1675
+ */
1676
+ replace?: (node: TextNode, match: RegExpMatchArray) => void | TextNode;
1677
+ /**
1678
+ * Single character that allows the transformer to trigger when typed in the editor. This does not affect markdown imports outside of the markdown shortcut plugin.
1679
+ * If the trigger is matched, the `regExp` will be used to match the text in the second step.
1680
+ */
1681
+ trigger?: string;
1682
+ type: 'text-match';
1683
+ }>;
1684
+ type ElementTransformer = {
1685
+ regExp: RegExp;
1686
+ /**
1687
+ * `replace` is called when markdown is imported or typed in the editor
1688
+ *
1689
+ * @return return false to cancel the transform, even though the regex matched. Lexical will then search for the next transformer.
1690
+ */
1691
+ replace: (parentNode: ElementNode, children: Array<LexicalNode>, match: Array<string>,
1692
+ /**
1693
+ * Whether the match is from an import operation (e.g. through `$convertFromMarkdownString`) or not (e.g. through typing in the editor).
1694
+ */
1695
+
1696
+ isImport: boolean) => boolean | void;
1697
+ trigger?: 'enter';
1698
+ type: 'element';
1699
+ };
1700
+ type Transformer = ElementTransformer | TextFormatTransformer | TextMatchTransformer;
1701
+ //#endregion
1702
+ //#region src/plugins/markdown/service/shortcut.d.ts
1703
+ interface IMarkdownWriterContext {
1704
+ /**
1705
+ * Add processor
1706
+ * @param processor
1707
+ */
1708
+ addProcessor(processor: (before: string, content: string, after: string) => string): void;
1709
+ /**
1710
+ * Direct output
1711
+ * @param line
1712
+ * @returns
1713
+ */
1714
+ appendLine: (line: string) => void;
1715
+ /**
1716
+ * Control child node to markdown
1717
+ * @param parentCtx
1718
+ * @param child
1719
+ * @returns
1720
+ */
1721
+ processChild: (parentCtx: IMarkdownWriterContext, child: LexicalNode) => void;
1722
+ /**
1723
+ * Wrap child elements
1724
+ * @param before
1725
+ * @param after
1726
+ * @returns
1727
+ */
1728
+ wrap: (before: string, after: string) => void;
1729
+ }
1730
+ declare const MARKDOWN_WRITER_LEVEL_MAX = 0;
1731
+ declare const MARKDOWN_READER_LEVEL_HIGH = 1;
1732
+ declare const MARKDOWN_READER_LEVEL_NORMAL = 2;
1733
+ type MARKDOWN_READER_LEVEL = typeof MARKDOWN_READER_LEVEL_HIGH | typeof MARKDOWN_READER_LEVEL_NORMAL | typeof MARKDOWN_WRITER_LEVEL_MAX;
1734
+ interface IMarkdownShortCutService {
1735
+ insertIRootNode(editor: LexicalEditor, root: IRootNode, selection: BaseSelection): void;
1736
+ parseMarkdownToLexical(markdown: string): IRootNode;
1737
+ /**
1738
+ * Register Markdown reader
1739
+ */
1740
+ registerMarkdownReader<K extends keyof TransformerRecord>(type: K, reader: MarkdownReaderFunc<K>, level?: MARKDOWN_READER_LEVEL): void;
1741
+ registerMarkdownShortCut(transformer: Transformer): void;
1742
+ registerMarkdownShortCuts(transformers: Transformer[]): void;
1743
+ /**
1744
+ * Register Markdown writer
1745
+ * @param type Lexical Node type
1746
+ * @param writer
1747
+ */
1748
+ registerMarkdownWriter(type: string, writer: (ctx: IMarkdownWriterContext, node: LexicalNode) => void | boolean): void;
1749
+ }
1750
+ declare const IMarkdownShortCutService: IServiceID<IMarkdownShortCutService>;
1751
+ //#endregion
1752
+ //#region src/plugins/content-blocks/types.d.ts
1753
+ interface TextContentBlock {
1754
+ text: string;
1755
+ type: 'text';
1756
+ }
1757
+ interface ImageContentBlock {
1758
+ alt: string;
1759
+ height?: number;
1760
+ type: 'image';
1761
+ url: string;
1762
+ width?: number;
1763
+ }
1764
+ interface FileContentBlock {
1765
+ name: string;
1766
+ size?: number;
1767
+ type: 'file';
1768
+ url: string;
1769
+ }
1770
+ type ContentBlock = TextContentBlock | ImageContentBlock | FileContentBlock;
1771
+ interface ExtractContentBlocksOptions {
1772
+ /**
1773
+ * When an image/file is in `loading` / `pending` / `error` state and thus has no
1774
+ * usable URL, emit a textual placeholder into the surrounding text block instead
1775
+ * of dropping the node silently.
1776
+ * @default true
1777
+ */
1778
+ emitPlaceholderForUnuploaded?: boolean;
1779
+ }
1780
+ interface ImageListItem {
1781
+ alt: string;
1782
+ id: string;
1783
+ url: string;
1784
+ }
1785
+ interface FileListItem {
1786
+ fileType: string;
1787
+ id: string;
1788
+ name: string;
1789
+ size: number;
1790
+ url: string;
1791
+ }
1792
+ interface MediaLists {
1793
+ fileList: FileListItem[];
1794
+ imageList: ImageListItem[];
1795
+ }
1796
+ declare const CONTENT_BLOCKS_DATA_TYPE = "content-blocks";
1797
+ //#endregion
1798
+ //#region src/plugins/content-blocks/data-source/content-blocks-data-source.d.ts
1799
+ declare class ContentBlocksDataSource extends DataSource {
1800
+ private getMarkdownService;
1801
+ private defaultOptions;
1802
+ constructor(getMarkdownService: () => IMarkdownShortCutService | null, defaultOptions?: ExtractContentBlocksOptions);
1803
+ read(): void;
1804
+ write(editor: LexicalEditor): ContentBlock[];
1805
+ }
1806
+ //#endregion
1807
+ //#region src/plugins/content-blocks/plugin/index.d.ts
1808
+ interface ContentBlocksPluginOptions {
1809
+ defaultOptions?: ExtractContentBlocksOptions;
1810
+ }
1811
+ declare const ContentBlocksPlugin: IEditorPluginConstructor<ContentBlocksPluginOptions>;
1812
+ //#endregion
1813
+ //#region src/plugins/content-blocks/utils/extract.d.ts
1814
+ declare const extractContentBlocks: (editor: LexicalEditor, service: IMarkdownShortCutService, options?: ExtractContentBlocksOptions) => ContentBlock[];
1815
+ //#endregion
1816
+ //#region src/plugins/content-blocks/utils/extract-media-lists.d.ts
1817
+ declare const extractMediaLists: (blocks: ContentBlock[]) => MediaLists;
1818
+ //#endregion
1819
+ //#region src/plugins/file/command/index.d.ts
1820
+ declare const INSERT_FILE_COMMAND: _$lexical.LexicalCommand<{
1821
+ file: File;
1822
+ }>;
1823
+ //#endregion
1824
+ //#region src/plugins/file/node/FileNode.d.ts
1825
+ type SerializedFileNode = Spread<{
1826
+ fileUrl?: string;
1827
+ message?: string;
1828
+ name: string;
1829
+ size?: number;
1830
+ status?: 'pending' | 'uploaded' | 'error';
1831
+ }, SerializedLexicalNode>;
1832
+ declare class FileNode extends DecoratorNode<any> {
1833
+ static getType(): string;
1834
+ static clone(node: FileNode): FileNode;
1835
+ static importJSON(serializedNode: SerializedFileNode): FileNode;
1836
+ static importDOM(): DOMConversionMap | null;
1837
+ __name: string;
1838
+ __fileUrl: string | undefined;
1839
+ __size: number | undefined;
1840
+ __status: 'pending' | 'uploaded' | 'error';
1841
+ __message?: string;
1842
+ get name(): string;
1843
+ get fileUrl(): string | undefined;
1844
+ get size(): number | undefined;
1845
+ get status(): 'pending' | 'uploaded' | 'error';
1846
+ get message(): string | undefined;
1847
+ constructor(name: string, fileUrl?: string, size?: number, status?: 'pending' | 'uploaded' | 'error', message?: string, key?: string);
1848
+ setUploaded(url: string): void;
1849
+ setError(message: string): void;
1850
+ exportDOM(): DOMExportOutput;
1851
+ createDOM(config: EditorConfig): HTMLElement;
1852
+ exportJSON(): SerializedFileNode;
1853
+ updateFromJSON(serializedNode: LexicalUpdateJSON<SerializedFileNode>): this;
1854
+ getTextContent(): string;
1855
+ updateDOM(): boolean;
1856
+ decorate(editor: LexicalEditor): any;
1857
+ }
1858
+ //#endregion
1859
+ //#region src/plugins/file/plugin/index.d.ts
1860
+ interface FilePluginOptions {
1861
+ decorator: (node: FileNode, editor: LexicalEditor) => any;
1862
+ handleUpload: (file: File) => Promise<{
1863
+ url: string;
1864
+ }>;
1865
+ markdownWriter?: (file: FileNode) => string;
1866
+ theme?: {
1867
+ file?: string;
1868
+ };
1869
+ }
1870
+ declare const FilePlugin: IEditorPluginConstructor<FilePluginOptions>;
1871
+ //#endregion
1872
+ //#region src/plugins/file/react/type.d.ts
1873
+ interface ReactFilePluginProps {
1874
+ className?: string;
1875
+ handleUpload: (file: File) => Promise<{
1876
+ url: string;
1877
+ }>;
1878
+ locale?: Partial<Record<keyof ILocaleKeys, string>>;
1879
+ markdownWriter?: (file: FileNode) => string;
1880
+ theme?: {
1881
+ file?: string;
1882
+ };
1883
+ }
1884
+ //#endregion
1885
+ //#region src/plugins/file/react/ReactFilePlugin.d.ts
1886
+ declare const ReactFilePlugin: FC<ReactFilePluginProps>;
1887
+ //#endregion
1888
+ //#region src/plugins/hr/command/index.d.ts
1889
+ declare const INSERT_HORIZONTAL_RULE_COMMAND: _$lexical.LexicalCommand<unknown>;
1890
+ //#endregion
1891
+ //#region src/plugins/hr/node/HorizontalRuleNode.d.ts
1892
+ type SerializedHorizontalRuleNode = SerializedLexicalNode;
1893
+ declare class HorizontalRuleNode extends DecoratorNode<any> {
1894
+ static getType(): string;
1895
+ static clone(node: HorizontalRuleNode): HorizontalRuleNode;
1896
+ static importJSON(serializedNode: SerializedHorizontalRuleNode): HorizontalRuleNode;
1897
+ static importDOM(): DOMConversionMap | null;
1898
+ exportDOM(): DOMExportOutput;
1899
+ createDOM(config: EditorConfig): HTMLElement;
1900
+ getTextContent(): string;
1901
+ isInline(): false;
1902
+ updateDOM(): boolean;
1903
+ decorate(editor: LexicalEditor): any;
1904
+ }
1905
+ //#endregion
1906
+ //#region src/plugins/hr/plugin/index.d.ts
1907
+ interface HRPluginOptions {
1908
+ decorator: (node: HorizontalRuleNode, editor: LexicalEditor) => any;
1909
+ theme?: string;
1910
+ }
1911
+ declare const HRPlugin: IEditorPluginConstructor<HRPluginOptions>;
1912
+ //#endregion
1913
+ //#region src/plugins/hr/react/type.d.ts
1914
+ interface ReactHRPluginProps {
1915
+ className?: string;
1916
+ }
1917
+ //#endregion
1918
+ //#region src/plugins/hr/react/ReactHRPlugin.d.ts
1919
+ declare const ReactHRPlugin: FC<ReactHRPluginProps>;
1920
+ //#endregion
1921
+ //#region src/plugins/image/command/index.d.ts
1922
+ declare const INSERT_IMAGE_COMMAND: _$lexical.LexicalCommand<{
1923
+ block?: boolean;
1924
+ file: File;
1925
+ maxWidth?: number;
1926
+ range?: Range | null;
1927
+ }>;
1928
+ //#endregion
1929
+ //#region src/plugins/image/node/basie-image-node.d.ts
1930
+ type SerializedImageNode = Spread<{
1931
+ altText: string;
1932
+ height?: number;
1933
+ maxWidth: number;
1934
+ src: string;
1935
+ status?: 'uploaded' | 'loading' | 'error';
1936
+ width?: number;
1937
+ }, SerializedLexicalNode>;
1938
+ declare class BaseImageNode extends DecoratorNode<any> {
1939
+ __src: string;
1940
+ __altText: string;
1941
+ __width: 'inherit' | number;
1942
+ __height: 'inherit' | number;
1943
+ __maxWidth: number;
1944
+ static clone(node: BaseImageNode): BaseImageNode;
1945
+ static importJSON(serializedNode: SerializedImageNode): BaseImageNode;
1946
+ static getType(): string;
1947
+ updateFromJSON(serializedNode: LexicalUpdateJSON<SerializedImageNode>): this;
1948
+ exportDOM(): DOMExportOutput;
1949
+ constructor(src: string, altText: string, maxWidth: number, width?: 'inherit' | number, height?: 'inherit' | number, key?: NodeKey);
1950
+ exportJSON(): SerializedImageNode;
1951
+ setWidthAndHeight(width: 'inherit' | number, height: 'inherit' | number): void;
1952
+ isInline(): boolean;
1953
+ createDOM(config: EditorConfig): HTMLElement;
1954
+ updateDOM(): false;
1955
+ getSrc(): string;
1956
+ getAltText(): string;
1957
+ }
1958
+ //#endregion
1959
+ //#region src/plugins/image/node/block-image-node.d.ts
1960
+ declare class BlockImageNode extends BaseImageNode {
1961
+ private static _decorate;
1962
+ static setDecorate(decorate: (node: BlockImageNode) => any): void;
1963
+ static getType(): string;
1964
+ private __loading;
1965
+ private __status;
1966
+ private __message;
1967
+ private __extra;
1968
+ get isLoading(): boolean;
1969
+ get status(): 'uploaded' | 'loading' | 'error';
1970
+ get message(): string | null;
1971
+ get src(): string;
1972
+ get altText(): string;
1973
+ get maxWidth(): number;
1974
+ get width(): number | string;
1975
+ get height(): number | string;
1976
+ constructor(opt: {
1977
+ altText: string;
1978
+ height?: 'inherit' | number;
1979
+ key?: NodeKey;
1980
+ maxWidth: number;
1981
+ src: string;
1982
+ status?: 'uploaded' | 'loading' | 'error';
1983
+ width?: 'inherit' | number;
1984
+ });
1985
+ isInline(): boolean;
1986
+ setMaxWidth(maxWidth: number): void;
1987
+ setWidth(width: number): void;
1988
+ setStatus(status: 'uploaded' | 'loading' | 'error'): void;
1989
+ setUploaded(url: string): void;
1990
+ setError(message: string): void;
1991
+ static clone(node: BlockImageNode): BlockImageNode;
1992
+ static importJSON(serializedNode: SerializedImageNode): BlockImageNode;
1993
+ static importDOM(): DOMConversionMap | null;
1994
+ decorate(): any;
1995
+ createDOM(config: EditorConfig): HTMLElement;
1996
+ }
1997
+ //#endregion
1998
+ //#region src/plugins/image/node/image-node.d.ts
1999
+ declare class ImageNode extends BaseImageNode {
2000
+ private static _decorate;
2001
+ static setDecorate(decorate: (node: ImageNode) => any): void;
2002
+ static getType(): string;
2003
+ private __loading;
2004
+ private __status;
2005
+ private __message;
2006
+ private __extra;
2007
+ constructor(opt: {
2008
+ altText: string;
2009
+ height?: 'inherit' | number;
2010
+ key?: NodeKey;
2011
+ maxWidth: number;
2012
+ src: string;
2013
+ status?: 'uploaded' | 'loading' | 'error';
2014
+ width?: 'inherit' | number;
2015
+ });
2016
+ get isLoading(): boolean;
2017
+ get status(): 'uploaded' | 'loading' | 'error';
2018
+ get message(): string | null;
2019
+ get src(): string;
2020
+ get altText(): string;
2021
+ get maxWidth(): number;
2022
+ get width(): number | string;
2023
+ get height(): number | string;
2024
+ setMaxWidth(maxWidth: number): void;
2025
+ setStatus(status: 'uploaded' | 'loading' | 'error'): void;
2026
+ setWidth(width: number): void;
2027
+ setUploaded(url: string): void;
2028
+ setError(message: string): void;
2029
+ static clone(node: ImageNode): ImageNode;
2030
+ static importJSON(serializedNode: SerializedImageNode): ImageNode;
2031
+ static importDOM(): DOMConversionMap | null;
2032
+ decorate(): any;
2033
+ }
2034
+ //#endregion
2035
+ //#region src/plugins/image/plugin/index.d.ts
2036
+ interface ImagePluginOptions {
2037
+ defaultBlockImage?: boolean;
2038
+ handleRehost?: (url: string) => Promise<{
2039
+ url: string;
2040
+ }>;
2041
+ handleUpload: (file: File) => Promise<{
2042
+ url: string;
2043
+ }>;
2044
+ needRehost?: (url: string) => boolean;
2045
+ renderImage: (node: ImageNode | BlockImageNode) => JSX.Element | null;
2046
+ theme?: {
2047
+ blockImage?: string;
2048
+ image?: string;
2049
+ };
1889
2050
  }
1890
- /**
1891
- * Info associated with mdast list item nodes by the ecosystem.
1892
- */
1893
- interface ListItemData extends Data {}
1894
- /**
1895
- * Markdown paragraph.
1896
- */
1897
- interface Paragraph extends Parent {
1898
- /**
1899
- * Node type of mdast paragraph.
1900
- */
1901
- type: "paragraph";
1902
- /**
1903
- * Children of paragraph.
1904
- */
1905
- children: PhrasingContent[];
2051
+ declare const ImagePlugin: IEditorPluginConstructor<ImagePluginOptions>;
2052
+ //#endregion
2053
+ //#region src/plugins/image/react/type.d.ts
2054
+ interface ReactImagePluginProps {
2055
+ className?: string;
2056
+ defaultBlockImage?: boolean;
2057
+ handleRehost?: (url: string) => Promise<{
2058
+ url: string;
2059
+ }>;
2060
+ handleUpload?: (file: File) => Promise<{
2061
+ url: string;
2062
+ }>;
2063
+ needRehost?: (url: string) => boolean;
1906
2064
  /**
1907
- * Data associated with the mdast paragraph.
2065
+ * Custom file picker for environments where programmatic input.click() is blocked (e.g. Electron).
2066
+ * When provided, this will be called instead of triggering the hidden file input.
1908
2067
  */
1909
- data?: ParagraphData | undefined;
2068
+ onPickFile?: () => Promise<File | null>;
2069
+ theme?: {
2070
+ blockImage?: string;
2071
+ image?: string;
2072
+ };
1910
2073
  }
2074
+ //#endregion
2075
+ //#region src/plugins/image/react/ReactImagePlugin.d.ts
2076
+ declare const ReactImagePlugin: FC<ReactImagePluginProps>;
2077
+ //#endregion
2078
+ //#region src/plugins/inode/plugin/index.d.ts
1911
2079
  /**
1912
- * Info associated with mdast paragraph nodes by the ecosystem.
1913
- */
1914
- interface ParagraphData extends Data {}
1915
- /**
1916
- * Document fragment or a whole document.
1917
- *
1918
- * Should be used as the root of a tree and must not be used as a child.
2080
+ * NodePluginOptions - Configuration options for the Node plugin
1919
2081
  */
1920
- interface Root extends Parent {
1921
- /**
1922
- * Node type of mdast root.
1923
- */
1924
- type: "root";
2082
+ interface INodePluginOptions {
1925
2083
  /**
1926
- * Data associated with the mdast root.
2084
+ * Enable or disable the node data source
2085
+ * @default true
1927
2086
  */
1928
- data?: RootData | undefined;
2087
+ enabled?: boolean;
1929
2088
  }
1930
2089
  /**
1931
- * Info associated with mdast root nodes by the ecosystem.
1932
- */
1933
- interface RootData extends Data {}
1934
- /**
1935
- * Markdown strong.
2090
+ * LitexmlPlugin - A plugin that provides XML-based data source support
2091
+ * Allows converting between Lexical editor state and XML format
1936
2092
  */
1937
- interface Strong extends Parent {
1938
- /**
1939
- * Node type of mdast strong.
1940
- */
1941
- type: "strong";
1942
- /**
1943
- * Children of strong.
1944
- */
1945
- children: PhrasingContent[];
1946
- /**
1947
- * Data associated with the mdast strong.
1948
- */
1949
- data?: StrongData | undefined;
2093
+ declare const INodePlugin: IEditorPluginConstructor<INodePluginOptions>;
2094
+ //#endregion
2095
+ //#region src/plugins/inode/react/index.d.ts
2096
+ declare const ReactNodePlugin: FC<void>;
2097
+ //#endregion
2098
+ //#region src/plugins/inode/service/index.d.ts
2099
+ interface INodeService {
2100
+ processNodeTree(inode: {
2101
+ root: IRootNode;
2102
+ }): void;
2103
+ registerProcessNodeTree(process: (inode: {
2104
+ root: IRootNode;
2105
+ }) => void): void;
1950
2106
  }
1951
2107
  /**
1952
- * Info associated with mdast strong nodes by the ecosystem.
1953
- */
1954
- interface StrongData extends Data {}
1955
- /**
1956
- * Markdown GFM table.
2108
+ * Service ID for Node service
1957
2109
  */
1958
- interface Table extends Parent {
1959
- /**
1960
- * Node type of mdast GFM table.
1961
- */
1962
- type: "table";
1963
- /**
1964
- * How cells in columns are aligned.
1965
- */
1966
- align?: AlignType[] | null | undefined;
1967
- /**
1968
- * Children of GFM table.
1969
- */
1970
- children: TableContent[];
1971
- /**
1972
- * Data associated with the mdast GFM table.
1973
- */
1974
- data?: TableData | undefined;
2110
+ declare const INodeService: IServiceID<INodeService>;
2111
+ //#endregion
2112
+ //#region src/plugins/link/command/index.d.ts
2113
+ declare const INSERT_LINK_COMMAND: _$lexical.LexicalCommand<{
2114
+ title?: string;
2115
+ url?: string;
2116
+ }>;
2117
+ //#endregion
2118
+ //#region src/plugins/link/node/LinkNode.d.ts
2119
+ type LinkAttributes = {
2120
+ rel?: null | string;
2121
+ target?: null | string;
2122
+ title?: null | string;
2123
+ };
2124
+ //#endregion
2125
+ //#region src/plugins/link/plugin/index.d.ts
2126
+ interface LinkPluginOptions {
2127
+ attributes?: LinkAttributes;
2128
+ enableHotkey?: boolean;
2129
+ linkRegex?: RegExp;
2130
+ theme?: {
2131
+ link?: string;
2132
+ };
2133
+ validateUrl?: (url: string) => boolean;
1975
2134
  }
1976
- /**
1977
- * Info associated with mdast GFM table nodes by the ecosystem.
1978
- */
1979
- interface TableData extends Data {}
1980
- /**
1981
- * Markdown GFM table row.
1982
- */
1983
- interface TableRow extends Parent {
1984
- /**
1985
- * Node type of mdast GFM table row.
1986
- */
1987
- type: "tableRow";
1988
- /**
1989
- * Children of GFM table row.
1990
- */
1991
- children: RowContent[];
1992
- /**
1993
- * Data associated with the mdast GFM table row.
1994
- */
1995
- data?: TableRowData | undefined;
2135
+ declare const LinkPlugin: IEditorPluginConstructor<LinkPluginOptions>;
2136
+ //#endregion
2137
+ //#region src/plugins/link/react/type.d.ts
2138
+ interface ReactLinkPluginProps {
2139
+ attributes?: LinkAttributes;
2140
+ className?: string;
2141
+ enableHotkey?: boolean;
2142
+ theme?: {
2143
+ link?: string;
2144
+ };
2145
+ validateUrl?: (url: string) => boolean;
1996
2146
  }
1997
- /**
1998
- * Info associated with mdast GFM table row nodes by the ecosystem.
1999
- */
2000
- interface TableRowData extends Data {}
2001
- /**
2002
- * Markdown GFM table cell.
2003
- */
2004
- interface TableCell extends Parent {
2005
- /**
2006
- * Node type of mdast GFM table cell.
2007
- */
2008
- type: "tableCell";
2009
- /**
2010
- * Children of GFM table cell.
2011
- */
2012
- children: PhrasingContent[];
2013
- /**
2014
- * Data associated with the mdast GFM table cell.
2015
- */
2016
- data?: TableCellData | undefined;
2147
+ //#endregion
2148
+ //#region src/plugins/link/react/ReactLinkPlugin.d.ts
2149
+ declare const ReactLinkPlugin: FC<ReactLinkPluginProps>;
2150
+ //#endregion
2151
+ //#region src/plugins/link/service/i-link-service.d.ts
2152
+ interface ILinkService {
2153
+ setLinkToolbar(enable: boolean): void;
2017
2154
  }
2018
- /**
2019
- * Info associated with mdast GFM table cell nodes by the ecosystem.
2020
- */
2021
- interface TableCellData extends Data {}
2022
- /**
2023
- * Markdown text.
2024
- */
2025
- interface Text extends Literal {
2155
+ declare const ILinkService: IServiceID<ILinkService>;
2156
+ //#endregion
2157
+ //#region src/plugins/link-highlight/command/index.d.ts
2158
+ declare const INSERT_LINK_HIGHLIGHT_COMMAND: _$lexical.LexicalCommand<undefined>;
2159
+ declare function registerLinkHighlightCommand(editor: LexicalEditor): () => void;
2160
+ //#endregion
2161
+ //#region src/plugins/link-highlight/plugin/index.d.ts
2162
+ interface LinkHighlightPluginOptions {
2163
+ enableHotkey?: boolean;
2026
2164
  /**
2027
- * Node type of mdast text.
2165
+ * Enable auto-highlight when pasting URLs
2166
+ * @default true
2028
2167
  */
2029
- type: "text";
2168
+ enablePasteAutoHighlight?: boolean;
2169
+ theme?: string;
2030
2170
  /**
2031
- * Data associated with the mdast text.
2171
+ * Custom URL validation regex
2032
2172
  */
2033
- data?: TextData | undefined;
2173
+ urlRegex?: RegExp;
2034
2174
  }
2035
- /**
2036
- * Info associated with mdast text nodes by the ecosystem.
2037
- */
2038
- interface TextData extends Data {}
2039
- /**
2040
- * Markdown thematic break (horizontal rule).
2041
- */
2042
- interface ThematicBreak extends Node$1 {
2175
+ declare const LinkHighlightPlugin: IEditorPluginConstructor<LinkHighlightPluginOptions>;
2176
+ //#endregion
2177
+ //#region src/plugins/link-highlight/react/type.d.ts
2178
+ interface ReactLinkHighlightPluginProps {
2179
+ className?: string;
2043
2180
  /**
2044
- * Node type of mdast thematic break.
2181
+ * Enable keyboard shortcut (Ctrl+K / Cmd+K)
2182
+ * @default true
2045
2183
  */
2046
- type: "thematicBreak";
2184
+ enableHotkey?: boolean;
2047
2185
  /**
2048
- * Data associated with the mdast thematic break.
2186
+ * Enable auto-highlight when pasting URLs
2187
+ * @default true
2049
2188
  */
2050
- data?: ThematicBreakData | undefined;
2189
+ enablePasteAutoHighlight?: boolean;
2051
2190
  }
2052
- /**
2053
- * Info associated with mdast thematic break nodes by the ecosystem.
2054
- */
2055
- interface ThematicBreakData extends Data {}
2056
- /**
2057
- * Markdown YAML.
2058
- */
2059
- interface Yaml extends Literal {
2060
- /**
2061
- * Node type of mdast YAML.
2062
- */
2063
- type: "yaml";
2064
- /**
2065
- * Data associated with the mdast YAML.
2066
- */
2067
- data?: YamlData | undefined;
2191
+ //#endregion
2192
+ //#region src/plugins/link-highlight/react/ReactLinkHighlightPlugin.d.ts
2193
+ declare const ReactLinkHighlightPlugin: FC<ReactLinkHighlightPluginProps>;
2194
+ //#endregion
2195
+ //#region src/plugins/list/plugin/checkList.d.ts
2196
+ declare const INSERT_CHECK_LIST_COMMAND: LexicalCommand<void>;
2197
+ //#endregion
2198
+ //#region src/plugins/list/plugin/index.d.ts
2199
+ interface ListPluginOptions {
2200
+ enableHotkey?: boolean;
2201
+ theme?: string;
2068
2202
  }
2069
- /**
2070
- * Info associated with mdast YAML nodes by the ecosystem.
2071
- */
2072
- interface YamlData extends Data {}
2203
+ declare const ListPlugin: IEditorPluginConstructor<ListPluginOptions>;
2073
2204
  //#endregion
2074
- //#region src/plugins/markdown/data-source/markdown/parse.d.ts
2075
- type MarkdownReadNode = INode | ITextNode | IElementNode;
2076
- type MarkdownNode = Root | RootContent | PhrasingContent;
2077
- type MarkdownReaderFunc<K> = (node: Extract<MarkdownNode, {
2078
- type: K;
2079
- }>, children: MarkdownReadNode[], index: number) => MarkdownReadNode | MarkdownReadNode[] | false;
2080
- type TransformerRecord = { [K in MarkdownNode['type']]?: MarkdownReaderFunc<K> | Array<MarkdownReaderFunc<K>> };
2205
+ //#region src/plugins/list/react/type.d.ts
2206
+ interface ReactListPluginProps {
2207
+ className?: string;
2208
+ enableHotkey?: boolean;
2209
+ }
2081
2210
  //#endregion
2082
- //#region src/plugins/markdown/service/transformers.d.ts
2083
- type TextFormatTransformer = Readonly<{
2084
- format?: ReadonlyArray<TextFormatType>;
2085
- intraword?: boolean;
2086
- process?: (selection: RangeSelection) => boolean | void;
2087
- tag: string;
2088
- type: 'text-format';
2211
+ //#region src/plugins/list/react/ReactListPlugin.d.ts
2212
+ declare const ReactListPlugin: FC<ReactListPluginProps>;
2213
+ //#endregion
2214
+ //#region src/plugins/litexml/command/diffCommand.d.ts
2215
+ declare enum DiffAction {
2216
+ Reject = 0,
2217
+ Accept = 1
2218
+ }
2219
+ declare const LITEXML_DIFFNODE_COMMAND: _$lexical.LexicalCommand<{
2220
+ action: DiffAction;
2221
+ nodeKey: string;
2089
2222
  }>;
2090
- type TextMatchTransformer = Readonly<{
2091
- /**
2092
- * For import operations, this function can be used to determine the end index of the match, after `importRegExp` has matched.
2093
- * Without this function, the end index will be determined by the length of the match from `importRegExp`. Manually determining the end index can be useful if
2094
- * the match from `importRegExp` is not the entire text content of the node. That way, `importRegExp` can be used to match only the start of the node, and `getEndIndex`
2095
- * can be used to match the end of the node.
2096
- *
2097
- * @returns The end index of the match, or false if the match was unsuccessful and a different transformer should be tried.
2098
- */
2099
- getEndIndex?: (node: TextNode, match: RegExpMatchArray) => number | false;
2100
- /**
2101
- * This regex determines what text is matched during markdown imports
2102
- */
2103
- importRegExp?: RegExp;
2104
- /**
2105
- * This regex determines what text is matched for markdown shortcuts while typing in the editor
2106
- */
2107
- regExp: RegExp;
2108
- /**
2109
- * Determines how the matched markdown text should be transformed into a node during the markdown import process
2110
- *
2111
- * @returns nothing, or a TextNode that may be a child of the new node that is created.
2112
- * If a TextNode is returned, text format matching will be applied to it (e.g. bold, italic, etc.)
2113
- */
2114
- replace?: (node: TextNode, match: RegExpMatchArray) => void | TextNode;
2115
- /**
2116
- * Single character that allows the transformer to trigger when typed in the editor. This does not affect markdown imports outside of the markdown shortcut plugin.
2117
- * If the trigger is matched, the `regExp` will be used to match the text in the second step.
2118
- */
2119
- trigger?: string;
2120
- type: 'text-match';
2223
+ declare const LITEXML_DIFFNODE_ALL_COMMAND: _$lexical.LexicalCommand<{
2224
+ action: DiffAction;
2121
2225
  }>;
2122
- type ElementTransformer = {
2123
- regExp: RegExp;
2124
- /**
2125
- * `replace` is called when markdown is imported or typed in the editor
2126
- *
2127
- * @return return false to cancel the transform, even though the regex matched. Lexical will then search for the next transformer.
2128
- */
2129
- replace: (parentNode: ElementNode, children: Array<LexicalNode>, match: Array<string>,
2130
- /**
2131
- * Whether the match is from an import operation (e.g. through `$convertFromMarkdownString`) or not (e.g. through typing in the editor).
2132
- */
2133
-
2134
- isImport: boolean) => boolean | void;
2135
- trigger?: 'enter';
2136
- type: 'element';
2137
- };
2138
- type Transformer = ElementTransformer | TextFormatTransformer | TextMatchTransformer;
2139
2226
  //#endregion
2140
- //#region src/plugins/markdown/service/shortcut.d.ts
2141
- interface IMarkdownWriterContext {
2142
- /**
2143
- * Add processor
2144
- * @param processor
2145
- */
2146
- addProcessor(processor: (before: string, content: string, after: string) => string): void;
2147
- /**
2148
- * Direct output
2149
- * @param line
2150
- * @returns
2151
- */
2152
- appendLine: (line: string) => void;
2153
- /**
2154
- * Control child node to markdown
2155
- * @param parentCtx
2156
- * @param child
2157
- * @returns
2158
- */
2159
- processChild: (parentCtx: IMarkdownWriterContext, child: LexicalNode) => void;
2160
- /**
2161
- * Wrap child elements
2162
- * @param before
2163
- * @param after
2164
- * @returns
2165
- */
2166
- wrap: (before: string, after: string) => void;
2227
+ //#region src/plugins/litexml/node/DiffNode.d.ts
2228
+ type DiffType = 'add' | 'remove' | 'modify' | 'unchanged' | 'listItemModify' | 'listItemRemove' | 'listItemAdd';
2229
+ type SerializedDiffNode = Spread<{
2230
+ diffType: DiffType;
2231
+ }, SerializedElementNode>;
2232
+ /** DiffNode - contains two block children: original and modified */
2233
+ declare class DiffNode extends CardLikeElementNode {
2234
+ static getType(): string;
2235
+ static clone(node: DiffNode): DiffNode;
2236
+ static importJSON(serializedNode: SerializedDiffNode): DiffNode;
2237
+ static importDOM(): null;
2238
+ private __diffType;
2239
+ constructor(type: DiffType, key?: string);
2240
+ get diffType(): DiffType;
2241
+ setDiffType(type: DiffType): this;
2242
+ updateFromJSON(serializedNode: LexicalUpdateJSON<SerializedDiffNode>): this;
2243
+ exportJSON(): SerializedDiffNode;
2244
+ exportDOM(editor: LexicalEditor): DOMExportOutput;
2245
+ createDOM(config: EditorConfig, editor: LexicalEditor): HTMLDivElement;
2246
+ updateDOM(_prevNode: unknown, _dom: HTMLElement, _config: EditorConfig): boolean;
2247
+ getDOMSlot(element: HTMLElement): ElementDOMSlot<HTMLElement>;
2248
+ isInline(): boolean;
2249
+ isCardLike(): boolean;
2167
2250
  }
2168
- declare const MARKDOWN_WRITER_LEVEL_MAX = 0;
2169
- declare const MARKDOWN_READER_LEVEL_HIGH = 1;
2170
- declare const MARKDOWN_READER_LEVEL_NORMAL = 2;
2171
- type MARKDOWN_READER_LEVEL = typeof MARKDOWN_READER_LEVEL_HIGH | typeof MARKDOWN_READER_LEVEL_NORMAL | typeof MARKDOWN_WRITER_LEVEL_MAX;
2172
- interface IMarkdownShortCutService {
2173
- insertIRootNode(editor: LexicalEditor, root: IRootNode, selection: BaseSelection): void;
2174
- parseMarkdownToLexical(markdown: string): IRootNode;
2175
- /**
2176
- * Register Markdown reader
2177
- */
2178
- registerMarkdownReader<K extends keyof TransformerRecord>(type: K, reader: MarkdownReaderFunc<K>, level?: MARKDOWN_READER_LEVEL): void;
2179
- registerMarkdownShortCut(transformer: Transformer): void;
2180
- registerMarkdownShortCuts(transformers: Transformer[]): void;
2251
+ //#endregion
2252
+ //#region src/plugins/litexml/plugin/index.d.ts
2253
+ /**
2254
+ * LitexmlPluginOptions - Configuration options for the Litexml plugin
2255
+ */
2256
+ interface LitexmlPluginOptions {
2257
+ decorator: (node: DiffNode, editor: LexicalEditor) => any;
2181
2258
  /**
2182
- * Register Markdown writer
2183
- * @param type Lexical Node type
2184
- * @param writer
2259
+ * Enable or disable the litexml data source
2260
+ * @default true
2185
2261
  */
2186
- registerMarkdownWriter(type: string, writer: (ctx: IMarkdownWriterContext, node: LexicalNode) => void | boolean): void;
2262
+ enabled?: boolean;
2263
+ theme?: string;
2187
2264
  }
2188
- declare const IMarkdownShortCutService: IServiceID<IMarkdownShortCutService>;
2265
+ /**
2266
+ * LitexmlPlugin - A plugin that provides XML-based data source support
2267
+ * Allows converting between Lexical editor state and XML format
2268
+ */
2269
+ declare const LitexmlPlugin: IEditorPluginConstructor<LitexmlPluginOptions>;
2270
+ //#endregion
2271
+ //#region src/plugins/litexml/react/index.d.ts
2272
+ declare const ReactLiteXmlPlugin: FC<void>;
2273
+ //#endregion
2274
+ //#region src/plugins/litexml/react/hooks/useHasDiffNode.d.ts
2275
+ declare function useHasDiffNode(editor?: IEditor): {
2276
+ hasDiff: boolean;
2277
+ };
2189
2278
  //#endregion
2190
2279
  //#region src/plugins/markdown/command/index.d.ts
2191
2280
  declare const INSERT_MARKDOWN_COMMAND: _$lexical.LexicalCommand<{
@@ -2976,4 +3065,4 @@ declare function enableHotReload(): void;
2976
3065
  */
2977
3066
  declare function disableHotReload(): void;
2978
3067
  //#endregion
2979
- export { $closest, $closestNodeType, $createCursorNode, $getNearestNodeFromDOMNode, $getNodeFromDOMNode, $isCardLikeElementNode, $isCursorNode, AutoCompletePlugin, type BlockDragTarget, BlockMenuService, BlockMovePayload, BlockPlugin, BlockPluginOptions, CardLikeElementNode, CodePlugin, CodeblockPlugin, CodeblockPluginOptions, CodemirrorPlugin, CodemirrorPluginOptions, CommonPlugin, CommonPluginOptions, DEFAULT_HEADLESS_EDITOR_PLUGINS, DOM_DOCUMENT_FRAGMENT_TYPE, DOM_DOCUMENT_TYPE, DOM_ELEMENT_TYPE, DOM_TEXT_TYPE, DataSource, DiffAction, EDITOR_THEME_KEY, FilePlugin, FilePluginOptions, GET_MARKDOWN_SELECTION_COMMAND, HIDE_TOOLBAR_COMMAND, HOVER_COMMAND, HRPlugin, HRPluginOptions, HeadlessDocumentType, HeadlessEditor, HeadlessEditorExport, HeadlessEditorExportOptions, HeadlessEditorHydrationInput, HeadlessEditorOptions, HeadlessLiteXMLBatchOperation, HeadlessLiteXMLInsertOperation, HeadlessLiteXMLOperation, HeadlessLiteXMLRemoveOperation, HeadlessLiteXMLReplaceOperation, HotkeyEnum, HotkeyId, HotkeyItem, HotkeyScopeEnum, HotkeyScopeId, IBlockActionButton, IBlockActionButtonIcon, IBlockMenuItem, IBlockMenuRenderContext, IBlockMenuService, type IEditor, ILinkService, ILitexmlService, IMarkdownShortCutService, INSERT_CHECK_LIST_COMMAND, INSERT_CODEINLINE_COMMAND, INSERT_CODEMIRROR_COMMAND, INSERT_FILE_COMMAND, INSERT_HEADING_COMMAND, INSERT_HORIZONTAL_RULE_COMMAND, INSERT_IMAGE_COMMAND, INSERT_LINK_COMMAND, INSERT_LINK_HIGHLIGHT_COMMAND, INSERT_MARKDOWN_COMMAND, INSERT_MATH_COMMAND, INSERT_MENTION_COMMAND, INSERT_ORDERED_LIST_COMMAND, INSERT_QUOTE_COMMAND, INSERT_TABLE_COMMAND, INSERT_UNORDERED_LIST_COMMAND, INodePlugin, INodePluginOptions, INodeService, ISlashMenuOption, ISlashOption, ISlashService, ITriggerContext, IUploadService, ImagePlugin, ImagePluginOptions, Kernel, KeyEnum, LITEXML_APPLY_COMMAND, LITEXML_DIFFNODE_ALL_COMMAND, LITEXML_DIFFNODE_COMMAND, LITEXML_INSERT_COMMAND, LITEXML_MODIFY_COMMAND, LITEXML_REMOVE_COMMAND, LexicalErrorBoundary, LexicalPortalContainer, LinkHighlightPlugin, LinkHighlightPluginOptions, LinkPlugin, LinkPluginOptions, ListPlugin, ListPluginOptions, LitexmlDataSource, LitexmlPlugin, type LitexmlPluginOptions, LitexmlService, type MARKDOWN_READER_LEVEL, MARKDOWN_READER_LEVEL_HIGH, MARKDOWN_READER_LEVEL_NORMAL, MARKDOWN_WRITER_LEVEL_MAX, MOVE_BLOCK_COMMAND, MarkdownPlugin, MathPlugin, MentionPlugin, MentionPluginOptions, MenuRenderProps, ModifierCombination, REMOVE_LIST_COMMAND, ReactAutoCompletePlugin, ReactBlockPlugin, type ReactBlockPluginProps, ReactCodePlugin, ReactCodeblockPlugin, ReactCodeblockPluginProps, ReactCodemirrorPlugin, ReactEditor, ReactEditorContent, ReactEditorContentProps, ReactFilePlugin, ReactFilePluginProps, ReactHRPlugin, ReactHRPluginProps, ReactImagePlugin, ReactImagePluginProps, ReactLinkHighlightPlugin, ReactLinkPlugin, ReactLinkPluginProps, ReactListPlugin, ReactListPluginProps, ReactLiteXmlPlugin, ReactMarkdownPlugin, ReactMathPlugin, ReactMentionPlugin, ReactMentionPluginProps, ReactNodePlugin, ReactPlainText, ReactPlainTextProps, ReactSlashOption, ReactSlashOptionProps, ReactSlashPlugin, ReactSlashPluginProps, ReactTablePlugin, ReactToolbarPlugin, ReactVirtualBlockPlugin, SELECT_AFTER_CODEMIRROR_COMMAND, SELECT_BEFORE_CODEMIRROR_COMMAND, SELECT_TABLE_COMMAND, SHOW_TOOLBAR_COMMAND, type SerializedMentionNode, SlashMenu, SlashMenuProps, SlashOptions, SlashPlugin, SlashPluginOptions, TablePlugin, TablePluginOptions, ToolbarCommandOptions, UPDATE_CODEBLOCK_LANG, UPDATE_LIST_START_COMMAND, UPLOAD_PRIORITY_HIGH, UPLOAD_PRIORITY_LOW, UPLOAD_PRIORITY_MEDIUM, UploadPlugin, UploadPluginOptions, VirtualBlockPlugin, VirtualBlockPluginOptions, type XMLReaderFunc, type XMLReaderRecord, type XMLWriterFunc, type XMLWriterRecord, assert, browserDebug, bundledLanguagesInfo, compareNodeOrder, createDebugLogger, createEmptyEditorState, createHeadlessEditor, cursorNodeSerialized, debugLogger, debugLoggers, detectCodeLanguage, detectLanguage, devConsole, disableHotReload, enableHotReload, genServiceId, generateEditorId, getHotkeyById, getKernelFromEditor, getKernelFromEditorConfig, getNodeKeyFromDOMNode, getParentElement, isDOMNode, isDocumentFragment, isPunctuationChar, isPureUrl, isValidUrl, moment, noop, prodSafeLogger, reconcileDecorator, registerBlockMoveCommand, registerEditorKernel, registerLinkHighlightCommand, registerToolbarCommand, resetRandomKey, scrollIntoView, unregisterEditorKernel, useHasDiffNode, useLexicalComposerContext, useLexicalEditor };
3068
+ export { $closest, $closestNodeType, $createCursorNode, $getNearestNodeFromDOMNode, $getNodeFromDOMNode, $isCardLikeElementNode, $isCursorNode, AutoCompletePlugin, type BlockDragTarget, BlockMenuService, BlockMovePayload, BlockPlugin, BlockPluginOptions, CONTENT_BLOCKS_DATA_TYPE, CardLikeElementNode, CodePlugin, CodeblockPlugin, CodeblockPluginOptions, CodemirrorPlugin, CodemirrorPluginOptions, CommonPlugin, CommonPluginOptions, type ContentBlock, ContentBlocksDataSource, ContentBlocksPlugin, type ContentBlocksPluginOptions, DEFAULT_HEADLESS_EDITOR_PLUGINS, DOM_DOCUMENT_FRAGMENT_TYPE, DOM_DOCUMENT_TYPE, DOM_ELEMENT_TYPE, DOM_TEXT_TYPE, DataSource, DiffAction, EDITOR_THEME_KEY, type ExtractContentBlocksOptions, type FileContentBlock, type FileListItem, FilePlugin, FilePluginOptions, GET_MARKDOWN_SELECTION_COMMAND, HIDE_TOOLBAR_COMMAND, HOVER_COMMAND, HRPlugin, HRPluginOptions, HeadlessDocumentType, HeadlessEditor, HeadlessEditorExport, HeadlessEditorExportOptions, HeadlessEditorHydrationInput, HeadlessEditorOptions, HeadlessLiteXMLBatchOperation, HeadlessLiteXMLInsertOperation, HeadlessLiteXMLOperation, HeadlessLiteXMLRemoveOperation, HeadlessLiteXMLReplaceOperation, HotkeyEnum, HotkeyId, HotkeyItem, HotkeyScopeEnum, HotkeyScopeId, IBlockActionButton, IBlockActionButtonIcon, IBlockMenuItem, IBlockMenuRenderContext, IBlockMenuService, type IEditor, ILinkService, ILitexmlService, IMarkdownShortCutService, INSERT_CHECK_LIST_COMMAND, INSERT_CODEINLINE_COMMAND, INSERT_CODEMIRROR_COMMAND, INSERT_FILE_COMMAND, INSERT_HEADING_COMMAND, INSERT_HORIZONTAL_RULE_COMMAND, INSERT_IMAGE_COMMAND, INSERT_LINK_COMMAND, INSERT_LINK_HIGHLIGHT_COMMAND, INSERT_MARKDOWN_COMMAND, INSERT_MATH_COMMAND, INSERT_MENTION_COMMAND, INSERT_ORDERED_LIST_COMMAND, INSERT_QUOTE_COMMAND, INSERT_TABLE_COMMAND, INSERT_UNORDERED_LIST_COMMAND, INodePlugin, INodePluginOptions, INodeService, ISlashMenuOption, ISlashOption, ISlashService, ITriggerContext, IUploadService, type ImageContentBlock, type ImageListItem, ImagePlugin, ImagePluginOptions, Kernel, KeyEnum, LITEXML_APPLY_COMMAND, LITEXML_DIFFNODE_ALL_COMMAND, LITEXML_DIFFNODE_COMMAND, LITEXML_INSERT_COMMAND, LITEXML_MODIFY_COMMAND, LITEXML_REMOVE_COMMAND, LexicalErrorBoundary, LexicalPortalContainer, LinkHighlightPlugin, LinkHighlightPluginOptions, LinkPlugin, LinkPluginOptions, ListPlugin, ListPluginOptions, LitexmlDataSource, LitexmlPlugin, type LitexmlPluginOptions, LitexmlService, type MARKDOWN_READER_LEVEL, MARKDOWN_READER_LEVEL_HIGH, MARKDOWN_READER_LEVEL_NORMAL, MARKDOWN_WRITER_LEVEL_MAX, MOVE_BLOCK_COMMAND, MarkdownPlugin, MathPlugin, type MediaLists, MentionPlugin, MentionPluginOptions, MenuRenderProps, ModifierCombination, REMOVE_LIST_COMMAND, ReactAutoCompletePlugin, ReactBlockPlugin, type ReactBlockPluginProps, ReactCodePlugin, ReactCodeblockPlugin, ReactCodeblockPluginProps, ReactCodemirrorPlugin, ReactEditor, ReactEditorContent, ReactEditorContentProps, ReactFilePlugin, ReactFilePluginProps, ReactHRPlugin, ReactHRPluginProps, ReactImagePlugin, ReactImagePluginProps, ReactLinkHighlightPlugin, ReactLinkPlugin, ReactLinkPluginProps, ReactListPlugin, ReactListPluginProps, ReactLiteXmlPlugin, ReactMarkdownPlugin, ReactMathPlugin, ReactMentionPlugin, ReactMentionPluginProps, ReactNodePlugin, ReactPlainText, ReactPlainTextProps, ReactSlashOption, ReactSlashOptionProps, ReactSlashPlugin, ReactSlashPluginProps, ReactTablePlugin, ReactToolbarPlugin, ReactVirtualBlockPlugin, SELECT_AFTER_CODEMIRROR_COMMAND, SELECT_BEFORE_CODEMIRROR_COMMAND, SELECT_TABLE_COMMAND, SHOW_TOOLBAR_COMMAND, type SerializedMentionNode, SlashMenu, SlashMenuProps, SlashOptions, SlashPlugin, SlashPluginOptions, TablePlugin, TablePluginOptions, type TextContentBlock, ToolbarCommandOptions, UPDATE_CODEBLOCK_LANG, UPDATE_LIST_START_COMMAND, UPLOAD_PRIORITY_HIGH, UPLOAD_PRIORITY_LOW, UPLOAD_PRIORITY_MEDIUM, UploadPlugin, UploadPluginOptions, VirtualBlockPlugin, VirtualBlockPluginOptions, type XMLReaderFunc, type XMLReaderRecord, type XMLWriterFunc, type XMLWriterRecord, assert, browserDebug, bundledLanguagesInfo, compareNodeOrder, createDebugLogger, createEmptyEditorState, createHeadlessEditor, cursorNodeSerialized, debugLogger, debugLoggers, detectCodeLanguage, detectLanguage, devConsole, disableHotReload, enableHotReload, extractContentBlocks, extractMediaLists, genServiceId, generateEditorId, getHotkeyById, getKernelFromEditor, getKernelFromEditorConfig, getNodeKeyFromDOMNode, getParentElement, isDOMNode, isDocumentFragment, isPunctuationChar, isPureUrl, isValidUrl, moment, noop, prodSafeLogger, reconcileDecorator, registerBlockMoveCommand, registerEditorKernel, registerLinkHighlightCommand, registerToolbarCommand, resetRandomKey, scrollIntoView, unregisterEditorKernel, useHasDiffNode, useLexicalComposerContext, useLexicalEditor };