Files
twenty/front/src/modules/ui/layout/components/PageHotkeys.tsx
T
brendanlaschke fa33506b96 New page structure (#1377)
* - new page structure

* - removed unecessary task changes

* - handleClick -> onClick
2023-08-30 15:10:16 +02:00

15 lines
394 B
TypeScript

import { TableHotkeyScope } from '@/ui/table/types/TableHotkeyScope';
import { useScopedHotkeys } from '@/ui/utilities/hotkey/hooks/useScopedHotkeys';
type OwnProps = {
onAddButtonClick?: () => void;
};
export function PageHotkeys({ onAddButtonClick }: OwnProps) {
useScopedHotkeys('c', () => onAddButtonClick?.(), TableHotkeyScope.Table, [
onAddButtonClick,
]);
return <></>;
}