diff --git a/public/pages/workflow_detail/component_details/input_fields/text_field.tsx b/public/pages/workflow_detail/component_details/input_fields/text_field.tsx index a510f691..d3866a7e 100644 --- a/public/pages/workflow_detail/component_details/input_fields/text_field.tsx +++ b/public/pages/workflow_detail/component_details/input_fields/text_field.tsx @@ -48,6 +48,10 @@ export function TextField(props: TextFieldProps) { compressed={false} value={field.value || getInitialValue(props.field.type)} onChange={(e) => form.setFieldValue(formField, e.target.value)} + // This is a design decision to only trigger form updates onBlur() instead + // of onChange(). This is to rate limit the number of updates & re-renders made, as users + // typically rapidly type things into a text box, which would consequently trigger + // onChange() much more often. onBlur={() => props.onFormChange()} /> diff --git a/public/pages/workflow_detail/workspace/resizable_workspace.tsx b/public/pages/workflow_detail/workspace/resizable_workspace.tsx index 43bc5d5b..b827fdc9 100644 --- a/public/pages/workflow_detail/workspace/resizable_workspace.tsx +++ b/public/pages/workflow_detail/workspace/resizable_workspace.tsx @@ -102,7 +102,8 @@ export function ResizableWorkspace(props: ResizableWorkspaceProps) { }); // Hook to update the workflow's flow state, if applicable. It may not exist if - // it is a backend-only-created workflow, or a new, unsaved workflow + // it is a backend-only-created workflow, or a new, unsaved workflow. If so, + // generate a default one based on the 'workflows' JSON field. useEffect(() => { const workflowCopy = { ...props.workflow } as Workflow; if (workflowCopy) {