import { IEditorPluginConstructor } from "../../../types/kernel.js"; import "../../../types/index.js"; import { LinkCardNode } from "../node/LinkCardNode.js"; import { LinkIframeNode } from "../node/LinkIframeNode.js"; import { LinkAttributes } from "../node/LinkNode.js"; import { SchemaNode } from "../node/SchemaNode.js"; import { LinkEmbedRule, LinkLabels, LinkToolbarAction, SchemaLinkRendererConfig, SchemaRule } from "../service/i-link-service.js"; import { normalizeSchemaLinkNode } from "../normalization/index.js"; import { LexicalEditor } from "lexical"; interface LinkPluginOptions { allowedProtocols?: string[]; /** Registration-time option. Recreate LinkPlugin to apply changes. */ attributes?: LinkAttributes; decoratorCard?: (node: LinkCardNode, editor: LexicalEditor) => any; decoratorIframe?: (node: LinkIframeNode, editor: LexicalEditor) => any; decoratorSchema?: (node: SchemaNode, editor: LexicalEditor) => any; /** Registration-time option. Recreate LinkPlugin to apply changes. */ enableHotkey?: boolean; labels?: Partial; linkEmbedRules?: LinkEmbedRule[]; /** Registration-time option. Recreate LinkPlugin to apply changes. */ linkRegex?: RegExp; /** Registration-time normalization strategy. Defaults to true for legacy compatibility. */ normalizeSchemaLinks?: boolean; schemaLinkRenderers?: SchemaLinkRendererConfig[]; schemaRules?: SchemaRule[]; /** Registration-time option. Recreate LinkPlugin to apply changes. */ theme?: { link?: string; linkCard?: string; linkIframe?: string; schemaLink?: string; }; toolbarActions?: LinkToolbarAction[]; /** Registration-time option. Recreate LinkPlugin to apply changes. */ validateUrl?: (url: string) => boolean; } declare const LinkPlugin: IEditorPluginConstructor; export { LinkPlugin, LinkPluginOptions, normalizeSchemaLinkNode };