fix(slideover): opening the editor closes Settings (was hidden underneath)
Ctrl+Shift+A with Settings open created the entry panel BELOW the Settings panel — invisible. openSlideOver now closes Settings first (root fix: covers every editor-open path, not just the hotkey), placed after the discard guard so cancelling keeps Settings. The inverse — opening Settings over the editor — stays as-is by design (Esc: Settings first, editor second). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -3850,6 +3850,14 @@ async function openSlideOver(id, opts) {
|
||||
}
|
||||
if (!isNew && !e) return;
|
||||
|
||||
// The editor must be visible when it opens: Settings sits ABOVE the
|
||||
// slideover, so a hotkey (Ctrl+Shift+A) fired with Settings open left
|
||||
// the new-entry panel hidden underneath. Close Settings — placed AFTER
|
||||
// the discard guard so cancelling it keeps Settings untouched. The
|
||||
// inverse (opening Settings over the editor) is deliberate and stays:
|
||||
// Esc closes Settings first, then handles the editor.
|
||||
if ($('#settingsPanel').classList.contains('is-open')) closeSettings();
|
||||
|
||||
state.selectedId = isNew ? null : id;
|
||||
if (!isNew) touchEntry(id);
|
||||
// Templates: resolve a preset bundle of {kind, title, customFields,
|
||||
|
||||
Reference in New Issue
Block a user