feat: search modal
This commit is contained in:
@@ -36,7 +36,8 @@
|
||||
showSettings,
|
||||
showChangelog,
|
||||
temporaryChatEnabled,
|
||||
toolServers
|
||||
toolServers,
|
||||
showSearch
|
||||
} from '$lib/stores';
|
||||
|
||||
import Sidebar from '$lib/components/layout/Sidebar.svelte';
|
||||
@@ -121,6 +122,13 @@
|
||||
// Check if the Shift key is pressed
|
||||
const isShiftPressed = event.shiftKey;
|
||||
|
||||
// Check if Ctrl + K is pressed
|
||||
if (isCtrlPressed && event.key.toLowerCase() === 'k') {
|
||||
event.preventDefault();
|
||||
console.log('search');
|
||||
showSearch.set(!$showSearch);
|
||||
}
|
||||
|
||||
// Check if Ctrl + Shift + O is pressed
|
||||
if (isCtrlPressed && isShiftPressed && event.key.toLowerCase() === 'o') {
|
||||
event.preventDefault();
|
||||
|
||||
Reference in New Issue
Block a user