UNPKG

just-hotkeys

Version:

A declarative keyboard shortcut manager for JavaScript and TypeScript - framework agnostic with React support

15 lines (14 loc) 507 B
import { ParsedShortcut } from './types'; /** * Parse a keyboard shortcut string into its components */ export declare function parseShortcut(shortcut: string): ParsedShortcut; /** * Check if a keyboard event matches a parsed shortcut */ export declare function matchesShortcut(event: KeyboardEvent, parsed: ParsedShortcut): boolean; /** * Normalize shortcut string for consistent comparison */ export declare function normalizeShortcut(shortcut: string): string; //# sourceMappingURL=parser.d.ts.map