mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-24 05:06:02 +08:00
hotkeys interface supports both string and string[] for combos
This commit is contained in:
@@ -22,4 +22,9 @@ hotkeyProvider.bindTo(scope)
|
||||
description: 'blah blah',
|
||||
callback: function() {}
|
||||
});
|
||||
.add({
|
||||
combo: ['w', 'mod+w'],
|
||||
description: 'blah blah',
|
||||
callback: function() {}
|
||||
});
|
||||
|
||||
|
||||
2
angular-hotkeys/angular-hotkeys.d.ts
vendored
2
angular-hotkeys/angular-hotkeys.d.ts
vendored
@@ -40,7 +40,7 @@ declare module ng.hotkeys {
|
||||
}
|
||||
|
||||
interface Hotkey {
|
||||
combo: string;
|
||||
combo: string | string[];
|
||||
description?: string;
|
||||
callback: (event: Event, hotkey: ng.hotkeys.Hotkey) => void;
|
||||
action?: string;
|
||||
|
||||
Reference in New Issue
Block a user