diff --git a/packages/twenty-front/src/modules/action-menu/actions/components/Action.tsx b/packages/twenty-front/src/modules/action-menu/actions/components/Action.tsx deleted file mode 100644 index 7be79eb22a..0000000000 --- a/packages/twenty-front/src/modules/action-menu/actions/components/Action.tsx +++ /dev/null @@ -1,32 +0,0 @@ -import { ActionDisplay } from '@/action-menu/actions/display/components/ActionDisplay'; -import { ActionConfigContext } from '@/action-menu/contexts/ActionConfigContext'; -import { useCloseActionMenu } from '@/action-menu/hooks/useCloseActionMenu'; -import { useContext } from 'react'; - -export const Action = ({ - onClick, - closeSidePanelOnShowPageOptionsActionExecution = false, - closeSidePanelOnCommandMenuListActionExecution = true, -}: { - onClick: () => void; - closeSidePanelOnShowPageOptionsActionExecution?: boolean; - closeSidePanelOnCommandMenuListActionExecution?: boolean; -}) => { - const actionConfig = useContext(ActionConfigContext); - - const { closeActionMenu } = useCloseActionMenu({ - closeSidePanelOnShowPageOptionsActionExecution, - closeSidePanelOnCommandMenuListActionExecution, - }); - - if (!actionConfig) { - return null; - } - - const handleClick = () => { - closeActionMenu(); - onClick(); - }; - - return ; -}; diff --git a/packages/twenty-front/src/modules/action-menu/actions/components/ActionLink.tsx b/packages/twenty-front/src/modules/action-menu/actions/components/ActionLink.tsx deleted file mode 100644 index a2c5c956c0..0000000000 --- a/packages/twenty-front/src/modules/action-menu/actions/components/ActionLink.tsx +++ /dev/null @@ -1,21 +0,0 @@ -import { ActionDisplay } from '@/action-menu/actions/display/components/ActionDisplay'; -import { useCloseActionMenu } from '@/action-menu/hooks/useCloseActionMenu'; -import { type PathParam } from 'react-router-dom'; -import { type AppPath } from 'twenty-shared/types'; -import { getAppPath } from 'twenty-shared/utils'; - -export const ActionLink = ({ - to, - params, - queryParams, -}: { - to: T; - params?: { [key in PathParam]: string | null }; - queryParams?: Record; -}) => { - const { closeActionMenu } = useCloseActionMenu(); - - const path = getAppPath(to, params, queryParams); - - return ; -}; diff --git a/packages/twenty-front/src/modules/action-menu/actions/display/components/ActionButton.tsx b/packages/twenty-front/src/modules/action-menu/actions/display/components/ActionButton.tsx deleted file mode 100644 index d862f50c96..0000000000 --- a/packages/twenty-front/src/modules/action-menu/actions/display/components/ActionButton.tsx +++ /dev/null @@ -1,68 +0,0 @@ -import { type ActionDisplayProps } from '@/action-menu/actions/display/components/ActionDisplay'; -import { getActionLabel } from '@/action-menu/utils/getActionLabel'; -import { styled } from '@linaria/react'; -import { isDefined } from 'twenty-shared/utils'; -import { AppTooltip, TooltipDelay, TooltipPosition } from 'twenty-ui/display'; -import { Button, IconButton } from 'twenty-ui/input'; -import { themeCssVariables } from 'twenty-ui/theme-constants'; - -const StyledWrapper = styled.div` - font-size: ${themeCssVariables.font.size.md}; -`; - -export const ActionButton = ({ - action, - onClick, - to, -}: { - action: ActionDisplayProps; - onClick?: (event?: React.MouseEvent) => void; - to?: string; -}) => { - const label = getActionLabel(action.label); - - const shortLabel = isDefined(action.shortLabel) - ? getActionLabel(action.shortLabel) - : undefined; - - const buttonAccent = action.isPrimaryCTA ? 'blue' : 'default'; - - return ( - <> - {isDefined(action.shortLabel) ? ( -