fix(ci): устранить ошибки eslint, блокировавшие CI
Refs EventHub/EventHubFrontAdmin#32 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -141,17 +141,3 @@ export function CommandPalette({ open, onOpenChange }: CommandPaletteProps) {
|
||||
</Dialog>
|
||||
);
|
||||
}
|
||||
|
||||
/** Глобальный хоткей Ctrl/⌘+K */
|
||||
export function useCommandPaletteHotkey(onOpen: () => void) {
|
||||
useEffect(() => {
|
||||
const handler = (e: KeyboardEvent) => {
|
||||
if ((e.metaKey || e.ctrlKey) && e.key.toLowerCase() === 'k') {
|
||||
e.preventDefault();
|
||||
onOpen();
|
||||
}
|
||||
};
|
||||
window.addEventListener('keydown', handler);
|
||||
return () => window.removeEventListener('keydown', handler);
|
||||
}, [onOpen]);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user