mirror of
				https://github.com/lingble/twenty.git
				synced 2025-10-30 20:27:55 +00:00 
			
		
		
		
	Set initial step if only one root step (#8617)
This commit is contained in:
		| @@ -43,9 +43,14 @@ const SearchVariablesDropdown = ({ | |||||||
|   const availableVariablesInWorkflowStep = |   const availableVariablesInWorkflowStep = | ||||||
|     useAvailableVariablesInWorkflowStep(); |     useAvailableVariablesInWorkflowStep(); | ||||||
|  |  | ||||||
|  |   const initialStep = | ||||||
|  |     availableVariablesInWorkflowStep.length === 1 | ||||||
|  |       ? availableVariablesInWorkflowStep[0] | ||||||
|  |       : undefined; | ||||||
|  |  | ||||||
|   const [selectedStep, setSelectedStep] = useState< |   const [selectedStep, setSelectedStep] = useState< | ||||||
|     StepOutputSchema | undefined |     StepOutputSchema | undefined | ||||||
|   >(undefined); |   >(initialStep); | ||||||
|  |  | ||||||
|   const insertVariableTag = (variable: string) => { |   const insertVariableTag = (variable: string) => { | ||||||
|     editor.commands.insertVariableTag(variable); |     editor.commands.insertVariableTag(variable); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 martmull
					martmull