From c9102ca1579aaed5b19241f92614c89cdb454f5a Mon Sep 17 00:00:00 2001 From: Abhishek Kumar Date: Wed, 8 Apr 2026 20:18:22 +0530 Subject: [PATCH] chore: fix dataReady for settings page --- ui/src/app/workflow/[workflowId]/settings/page.tsx | 7 +------ ui/src/app/workflow/[workflowId]/stores/workflowStore.ts | 4 ++-- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/ui/src/app/workflow/[workflowId]/settings/page.tsx b/ui/src/app/workflow/[workflowId]/settings/page.tsx index 46acabd..93afc43 100644 --- a/ui/src/app/workflow/[workflowId]/settings/page.tsx +++ b/ui/src/app/workflow/[workflowId]/settings/page.tsx @@ -759,11 +759,6 @@ function WorkflowSettingsContent({ return () => observer.disconnect(); }, []); - // Sections are gated on configurations being present in the store. - // After mount, initializeWorkflow runs in a useEffect — the first render - // may still have stale store data, but the next tick corrects it. - const dataReady = !!workflowConfigurations; - return (
{/* Sticky header */} @@ -785,7 +780,7 @@ function WorkflowSettingsContent({
{/* Sections */}
- {dataReady && ( + {workflowConfigurations && ( <> {/* General */} ((set, get) => ({ isAddNodePanelOpen: false, workflowValidationErrors: [], templateContextVariables: {}, - workflowConfigurations: DEFAULT_WORKFLOW_CONFIGURATIONS, + workflowConfigurations: null, dictionary: '', rfInstance: null, @@ -393,7 +393,7 @@ export const useWorkflowStore = create((set, get) => ({ isAddNodePanelOpen: false, workflowValidationErrors: [], templateContextVariables: {}, - workflowConfigurations: DEFAULT_WORKFLOW_CONFIGURATIONS, + workflowConfigurations: null, dictionary: '', rfInstance: null, });