/** * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * */ import '@iconify/iconify'; import './index.css'; import './style/editable.css'; import { EditorState, Klass, LexicalEditor, LexicalNode } from 'lexical'; import React, { MutableRefObject, ReactNode, type JSX } from 'react'; export interface BlockletEditorProps extends Omit, HTMLDivElement>, 'placeholder' | 'onChange'> { placeholder?: ReactNode; editable?: boolean; editorState?: string; children?: ReactNode; prepend?: ReactNode; nodes?: ReadonlyArray>; onChange?: (editorState: EditorState, editor: LexicalEditor) => void; autoFocus?: boolean; showToolbar?: boolean; editorRef?: React.RefCallback | MutableRefObject; onReady?: () => void; enableHeadingsIdPlugin?: boolean; markdown?: boolean; } export default function BlockletEditor({ editorState, nodes, editable, markdown, ...props }: BlockletEditorProps): JSX.Element;