Files
twenty/packages/twenty-front/src/modules/action-menu/contexts/ActionMenuContext.ts
Raphaël Bosi d08075f610 Command menu actions fixes (#9169)
- Fix command menu not closing after executing an action
- Add delete and favorite actions to workflow and workflow versions
2024-12-20 13:42:01 +00:00

14 lines
439 B
TypeScript

import { createContext } from 'react';
type ActionMenuContextType = {
isInRightDrawer: boolean;
onActionStartedCallback?: (action: { key: string }) => Promise<void> | void;
onActionExecutedCallback?: (action: { key: string }) => Promise<void> | void;
};
export const ActionMenuContext = createContext<ActionMenuContextType>({
isInRightDrawer: false,
onActionStartedCallback: () => {},
onActionExecutedCallback: () => {},
});