fix: FindAndReplace does not update to reflect changing between readOnly/editable

This commit is contained in:
Tom Moor
2023-12-05 21:38:54 -05:00
parent 9fbe256807
commit 8d65b13b3d
4 changed files with 6 additions and 6 deletions

View File

@@ -7,7 +7,7 @@ import { Editor } from "../../../app/editor";
export type CommandFactory = (attrs?: Record<string, Primitive>) => Command;
export type WidgetProps = { rtl: boolean };
export type WidgetProps = { rtl: boolean; readOnly: boolean | undefined };
export default class Extension {
options: any;

View File

@@ -44,7 +44,7 @@ export default class ExtensionManager {
get widgets() {
return this.extensions
.filter((extension) => extension.widget({ rtl: false }))
.filter((extension) => extension.widget({ rtl: false, readOnly: false }))
.reduce(
(nodes, node: Node) => ({
...nodes,