diff --git a/frontend/src/components/domain/onboarding/UnifiedOnboardingWizard.tsx b/frontend/src/components/domain/onboarding/UnifiedOnboardingWizard.tsx index dfb6cd90..eb898e41 100644 --- a/frontend/src/components/domain/onboarding/UnifiedOnboardingWizard.tsx +++ b/frontend/src/components/domain/onboarding/UnifiedOnboardingWizard.tsx @@ -205,6 +205,7 @@ const OnboardingWizardContent: React.FC = () => { const isNewTenant = searchParams.get('new') === 'true'; const [currentStepIndex, setCurrentStepIndex] = useState(0); const [isInitialized, setIsInitialized] = useState(isNewTenant); + const [canContinue, setCanContinue] = useState(true); // Track if current step allows continuation useTenantInitializer(); @@ -407,6 +408,11 @@ const OnboardingWizardContent: React.FC = () => { }; const handleStepUpdate = (data?: any) => { + // Handle canContinue state updates from setup wizard steps + if (data?.canContinue !== undefined) { + setCanContinue(data.canContinue); + } + // Handle intermediate updates without marking step complete if (currentStep.id === 'bakery-type-selection' && data?.bakeryType) { wizardContext.updateBakeryType(data.bakeryType as BakeryType); @@ -538,6 +544,48 @@ const OnboardingWizardContent: React.FC = () => { isLastStep={currentStepIndex === VISIBLE_STEPS.length - 1} /> + + {/* Navigation Footer - Only for setup wizard steps that don't render their own buttons */} + {['suppliers-setup', 'inventory-setup', 'recipes-setup', 'quality-setup', 'team-setup', 'setup-review'].includes(currentStep.id) && ( +