Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { NodeSelection, Selection, TextSelection } from 'prosemirror-state';
import { SlashMenuPluginKey } from '@extensions/slash-menu/slash-menu.js';
import { CellSelection } from 'prosemirror-tables';
import type { EditorState, Transaction } from 'prosemirror-state';
import type { Node as ProseMirrorNode, Mark } from 'prosemirror-model';
Expand Down Expand Up @@ -3367,8 +3368,10 @@ export class PresentationEditor extends EventEmitter {

const activeEditor = this.getActiveEditor();
const hasFocus = activeEditor?.view?.hasFocus?.() ?? false;
// Keep selection visible when context menu (SlashMenu) is open
const slashMenuOpen = activeEditor?.state ? !!SlashMenuPluginKey.getState(activeEditor.state)?.open : false;

if (!hasFocus) {
if (!hasFocus && !slashMenuOpen) {
try {
this.#clearSelectedFieldAnnotationClass();
this.#localSelectionLayer.innerHTML = '';
Expand Down
Loading