Remove workflow context + clean action config (#13919)

- Remove create related version and runs from workflow action config
- Remove WorkflowStepContextProvider. Use states instead
This commit is contained in:
Thomas Trompette
2025-08-14 12:17:07 +02:00
committed by GitHub
parent 08bf7b6dca
commit 50c4c50169
14 changed files with 118 additions and 112 deletions
@@ -0,0 +1,15 @@
import { useRecoilComponentValue } from '@/ui/utilities/state/component-state/hooks/useRecoilComponentValue';
import { workflowVisualizerWorkflowVersionIdComponentState } from '@/workflow/states/workflowVisualizerWorkflowVersionIdComponentState';
import { isDefined } from 'twenty-shared/utils';
export const useWorkflowVersionIdOrThrow = () => {
const workflowVersionId = useRecoilComponentValue(
workflowVisualizerWorkflowVersionIdComponentState,
);
if (!isDefined(workflowVersionId)) {
throw new Error('Expected the workflow version ID to be defined');
}
return workflowVersionId;
};