mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-02-01 20:23:36 +00:00
feat: Add Cursor setup step to UI setup wizard
- Introduced a new `CursorSetupStep` component for optional Cursor CLI configuration during the setup process. - Updated `SetupView` to include the cursor step in the setup flow, allowing users to skip or proceed with Cursor CLI setup. - Enhanced state management to track Cursor CLI installation and authentication status. - Updated Electron API to support fetching Cursor CLI status. - Marked completion of the UI setup wizard phase in the integration plan.
This commit is contained in:
@@ -5,6 +5,7 @@ import {
|
||||
ThemeStep,
|
||||
CompleteStep,
|
||||
ClaudeSetupStep,
|
||||
CursorSetupStep,
|
||||
GitHubSetupStep,
|
||||
} from './setup-view/steps';
|
||||
import { useNavigate } from '@tanstack/react-router';
|
||||
@@ -14,12 +15,13 @@ export function SetupView() {
|
||||
const { currentStep, setCurrentStep, completeSetup, setSkipClaudeSetup } = useSetupStore();
|
||||
const navigate = useNavigate();
|
||||
|
||||
const steps = ['welcome', 'theme', 'claude', 'github', 'complete'] as const;
|
||||
const steps = ['welcome', 'theme', 'claude', 'cursor', 'github', 'complete'] as const;
|
||||
type StepName = (typeof steps)[number];
|
||||
const getStepName = (): StepName => {
|
||||
if (currentStep === 'claude_detect' || currentStep === 'claude_auth') return 'claude';
|
||||
if (currentStep === 'welcome') return 'welcome';
|
||||
if (currentStep === 'theme') return 'theme';
|
||||
if (currentStep === 'cursor') return 'cursor';
|
||||
if (currentStep === 'github') return 'github';
|
||||
return 'complete';
|
||||
};
|
||||
@@ -37,6 +39,10 @@ export function SetupView() {
|
||||
setCurrentStep('claude_detect');
|
||||
break;
|
||||
case 'claude':
|
||||
console.log('[Setup Flow] Moving to cursor step');
|
||||
setCurrentStep('cursor');
|
||||
break;
|
||||
case 'cursor':
|
||||
console.log('[Setup Flow] Moving to github step');
|
||||
setCurrentStep('github');
|
||||
break;
|
||||
@@ -56,15 +62,23 @@ export function SetupView() {
|
||||
case 'claude':
|
||||
setCurrentStep('theme');
|
||||
break;
|
||||
case 'github':
|
||||
case 'cursor':
|
||||
setCurrentStep('claude_detect');
|
||||
break;
|
||||
case 'github':
|
||||
setCurrentStep('cursor');
|
||||
break;
|
||||
}
|
||||
};
|
||||
|
||||
const handleSkipClaude = () => {
|
||||
console.log('[Setup Flow] Skipping Claude setup');
|
||||
setSkipClaudeSetup(true);
|
||||
setCurrentStep('cursor');
|
||||
};
|
||||
|
||||
const handleSkipCursor = () => {
|
||||
console.log('[Setup Flow] Skipping Cursor setup');
|
||||
setCurrentStep('github');
|
||||
};
|
||||
|
||||
@@ -114,6 +128,14 @@ export function SetupView() {
|
||||
/>
|
||||
)}
|
||||
|
||||
{currentStep === 'cursor' && (
|
||||
<CursorSetupStep
|
||||
onNext={() => handleNext('cursor')}
|
||||
onBack={() => handleBack('cursor')}
|
||||
onSkip={handleSkipCursor}
|
||||
/>
|
||||
)}
|
||||
|
||||
{currentStep === 'github' && (
|
||||
<GitHubSetupStep
|
||||
onNext={() => handleNext('github')}
|
||||
|
||||
Reference in New Issue
Block a user