Add command-palette entries to reach hidden sidebar views (#153)

This commit is contained in:
Yuri Karamian committed 2026-06-22 13:28:24 +02:00
1 parent 69330bf23c
commit 04dee78b27
1 file changed
+3 -5
+3 -5
View File
@@ -10,6 +10,7 @@
import type { ImportResult, BackupEntry } from '$lib/types'; import type { ImportResult, BackupEntry } from '$lib/types';
const isMobile = /android|iphone|ipad|ipod/i.test(navigator.userAgent); const isMobile = /android|iphone|ipad|ipod/i.test(navigator.userAgent);
const modKey = navigator.platform.startsWith('Mac') ? '⌘' : 'Ctrl';
type Tab = 'general' | 'editor' | 'styling' | 'import' | 'backup' | 'ai' | 'sync' | 'updates'; type Tab = 'general' | 'editor' | 'styling' | 'import' | 'backup' | 'ai' | 'sync' | 'updates';
let activeTab = $state<Tab>('styling'); let activeTab = $state<Tab>('styling');
@@ -912,7 +913,7 @@
{#if !isMobile} {#if !isMobile}
<div class="settings-section"> <div class="settings-section">
<h3>Sidebar</h3> <h3>Sidebar</h3>
<p class="setting-desc" style="margin: 0 0 10px;">Hide navigation items you don't use. The notebook tree always stays.</p> <p class="setting-desc" style="margin: 0 0 10px;">Hide navigation items you don't use, leaving search and the notebook tree. Any item you hide stays reachable from the command palette ({modKey}+P).</p>
<label class="setting-toggle"> <label class="setting-toggle">
<span class="setting-label"><span class="setting-name">All Notes</span></span> <span class="setting-label"><span class="setting-name">All Notes</span></span>
<button class="toggle-switch" class:on={showAllNotes} onclick={() => { showAllNotes = !showAllNotes; saveGeneralSettings(); }}> <button class="toggle-switch" class:on={showAllNotes} onclick={() => { showAllNotes = !showAllNotes; saveGeneralSettings(); }}>
@@ -938,10 +939,7 @@
</button> </button>
</label> </label>
<label class="setting-toggle"> <label class="setting-toggle">
<span class="setting-label"> <span class="setting-label"><span class="setting-name">Trash</span></span>
<span class="setting-name">Trash</span>
<span class="setting-desc">Deleted notes stay recoverable from the command palette (Ctrl/Cmd+P → Open Trash).</span>
</span>
<button class="toggle-switch" class:on={showTrash} onclick={() => { showTrash = !showTrash; saveGeneralSettings(); }}> <button class="toggle-switch" class:on={showTrash} onclick={() => { showTrash = !showTrash; saveGeneralSettings(); }}>
<span class="toggle-knob"></span> <span class="toggle-knob"></span>
</button> </button>