优化Editor组件类型

master
LiuJiaNan 2025-12-06 15:48:29 +08:00
parent b934bbffda
commit 3cbbbd411a
1 changed files with 2 additions and 2 deletions

View File

@ -1,4 +1,4 @@
import type { Editor as WangEditorInstance } from "@wangeditor/editor";
import type { IDomEditor } from "@wangeditor/editor";
import type { ForwardRefExoticComponent, RefAttributes } from "react";
export interface EditorProps {
@ -12,7 +12,7 @@ export interface EditorProps {
export interface EditorRef {
/** 获取编辑器实例 */
getEditorInstance: () => WangEditorInstance | null;
getEditorInstance: () => IDomEditor | null;
/** 获取HTML内容 */
getHtml: () => string | undefined;
/** 设置HTML内容 */