Datalayer VS Code Extension - v0.0.9
    Preparing search index...

    Lexical state interface

    Defines the complete state structure for the Lexical editor store, including document properties, editor settings, collaboration state, and action methods.

    interface LexicalState {
        collaborationConfig: CollaborationConfig;
        content: string;
        documentUri: string;
        isEditable: boolean;
        isInitialLoad: boolean;
        isReady: boolean;
        lexicalId: string;
        navigationTarget: string;
        reset: () => void;
        setCollaborationConfig: (config: CollaborationConfig) => void;
        setContent: (content: string) => void;
        setDocumentUri: (uri: string) => void;
        setIsEditable: (editable: boolean) => void;
        setIsInitialLoad: (isInitial: boolean) => void;
        setIsReady: (ready: boolean) => void;
        setLexicalId: (id: string) => void;
        setNavigationTarget: (itemId: string) => void;
        setTheme: (theme: "light" | "dark") => void;
        theme: "light" | "dark";
    }
    Index

    Properties

    collaborationConfig: CollaborationConfig

    Configuration for real-time collaboration features

    content: string

    Current content of the Lexical document

    documentUri: string

    Full URI of the document (used for outline and navigation context)

    isEditable: boolean

    Whether the document is in edit mode (true) or read-only (false)

    isInitialLoad: boolean

    Whether this is the first load of the document

    isReady: boolean

    Whether the Lexical editor has been initialized and is ready to render

    lexicalId: string

    Lexical document ID for tool execution context and tracking

    navigationTarget: string

    ID of outline item to navigate to (null if no pending navigation)

    reset: () => void

    Resets the entire store to initial state

    setCollaborationConfig: (config: CollaborationConfig) => void

    Updates the collaboration configuration

    Type Declaration

    setContent: (content: string) => void

    Updates the document content

    Type Declaration

      • (content: string): void
      • Parameters

        • content: string

          The new document content

        Returns void

    setDocumentUri: (uri: string) => void

    Updates the document URI

    Type Declaration

      • (uri: string): void
      • Parameters

        • uri: string

          The new document URI

        Returns void

    setIsEditable: (editable: boolean) => void

    Updates the editable state of the document

    Type Declaration

      • (editable: boolean): void
      • Parameters

        • editable: boolean

          True for edit mode, false for read-only

        Returns void

    setIsInitialLoad: (isInitial: boolean) => void

    Updates the initial load flag

    Type Declaration

      • (isInitial: boolean): void
      • Parameters

        • isInitial: boolean

          True for the first load, false after initial rendering

        Returns void

    setIsReady: (ready: boolean) => void

    Updates the ready state of the editor

    Type Declaration

      • (ready: boolean): void
      • Parameters

        • ready: boolean

          True when editor has initialized and is ready to render

        Returns void

    setLexicalId: (id: string) => void

    Updates the Lexical document ID

    Type Declaration

      • (id: string): void
      • Parameters

        • id: string

          The new Lexical document ID

        Returns void

    setNavigationTarget: (itemId: string) => void

    Updates the navigation target outline item

    Type Declaration

      • (itemId: string): void
      • Parameters

        • itemId: string

          The ID of the outline item to navigate to, or null to clear

        Returns void

    setTheme: (theme: "light" | "dark") => void

    Updates the editor theme

    Type Declaration

      • (theme: "light" | "dark"): void
      • Parameters

        • theme: "light" | "dark"

          The new theme: 'light' or 'dark'

        Returns void

    theme: "light" | "dark"

    Current editor theme: 'light' or 'dark'