Set steps output schema in a recoil family state (#10688)
- Create a workflow version component family state for each workflow version : `stepId` => `StepOutputSchema` - Populate this state when reaching the workflow visualizer of the workflow version - Wrap the right drawer when in edit mode with the context. It is the only one who needs this schema Next step: - read this state from the variables
This commit is contained in:
@ -0,0 +1,4 @@
|
||||
import { createComponentInstanceContext } from '@/ui/utilities/state/component-state/utils/createComponentInstanceContext';
|
||||
|
||||
export const WorkflowVersionComponentInstanceContext =
|
||||
createComponentInstanceContext();
|
||||
@ -0,0 +1,10 @@
|
||||
import { createComponentFamilyStateV2 } from '@/ui/utilities/state/component-state/utils/createComponentFamilyStateV2';
|
||||
import { WorkflowVersionComponentInstanceContext } from '@/workflow/states/context/WorkflowVersionComponentInstanceContext';
|
||||
import { StepOutputSchema } from '@/workflow/workflow-variables/types/StepOutputSchema';
|
||||
|
||||
export const stepsOutputSchemaComponentFamilyState =
|
||||
createComponentFamilyStateV2<StepOutputSchema | null, string>({
|
||||
key: 'stepsOutputSchemaComponentFamilyState',
|
||||
defaultValue: null,
|
||||
componentInstanceContext: WorkflowVersionComponentInstanceContext,
|
||||
});
|
||||
Reference in New Issue
Block a user