undo
描述
在菜单栏/工具栏中点击"撤销"按钮或通过 Event Bus 方法触发时触发
用法
"undo": () => boolean | void;
信息
如需处理内部事件,您可以使用 Event Bus 方法
示例
// 初始化 RichText
const editor = new richtext.Richtext("#root", {
// 配置属性
});
// 订阅 "undo" 事件
editor.api.on("undo", () => {
console.log("Undo operation was performed");
});
更新日志: 该事件在 v2.0 中添加