diff options
author | bobzel <zzzman@gmail.com> | 2021-09-22 05:07:25 -0400 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2021-09-22 05:07:25 -0400 |
commit | 5e550b24c562a0fc35a734e99281a8f823ecbf15 (patch) | |
tree | 1baa372dc50c12b3d19a7973b2ca0ad82507d05b /src/client/views/nodes/formattedText/RichTextMenu.tsx | |
parent | cbd8f931480ecfdc9c22cd2daa633e9b80b5a6e2 (diff) |
fixes for fontcolor dropdown to be continuous as pointer moves.
Diffstat (limited to 'src/client/views/nodes/formattedText/RichTextMenu.tsx')
-rw-r--r-- | src/client/views/nodes/formattedText/RichTextMenu.tsx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/client/views/nodes/formattedText/RichTextMenu.tsx b/src/client/views/nodes/formattedText/RichTextMenu.tsx index 0a2a54aae..3efc46259 100644 --- a/src/client/views/nodes/formattedText/RichTextMenu.tsx +++ b/src/client/views/nodes/formattedText/RichTextMenu.tsx @@ -336,8 +336,9 @@ export class RichTextMenu extends AntimodeMenu<AntimodeMenuProps> { setColor(color: String, view: EditorView, dispatch: any) { if (this.view) { const colorMark = view.state.schema.mark(view.state.schema.marks.pFontColor, { color }); - view.focus(); this.setMark(colorMark, this.view.state, (tx: any) => this.view!.dispatch(tx.addStoredMark(colorMark)), true); + view.focus(); + this.updateMenu(this.view, undefined, this.props); } } |