12 lines
488 B
TypeScript
12 lines
488 B
TypeScript
import type { MaybeRef } from 'vue';
|
|
import type { KeyOptions } from '../../shared/index.js';
|
|
/**
|
|
* Register keyboard event listeners for hotkeys
|
|
*
|
|
* 为热键注册键盘事件监听器
|
|
*
|
|
* @param hotKeys - Array of key configurations / 键配置数组
|
|
* @param action - Action to execute when hotkey is pressed / 按下热键时执行的操作
|
|
*/
|
|
export declare const useKeys: (hotKeys: MaybeRef<(KeyOptions | string)[] | undefined>, action: () => Promise<void> | void) => void;
|