feat: enhance provider setup and authentication flow

- Refactored ProvidersSetupStep component to improve the UI and streamline provider status checks for Claude, Cursor, Codex, and OpenCode.
- Introduced auto-verification for CLI authentication and improved error handling for authentication states.
- Added loading indicators for provider status checks and enhanced user feedback for installation and authentication processes.
- Updated setup store to manage verification states and ensure accurate representation of provider statuses.

These changes enhance the user experience by providing clearer feedback and a more efficient setup process for AI providers.
This commit is contained in:
webdevcody
2026-01-09 11:03:01 -05:00
parent a695d0db7b
commit 4f0f56a7ba
2 changed files with 641 additions and 416 deletions

View File

@@ -132,6 +132,7 @@ export interface SetupState {
claudeCliStatus: CliStatus | null;
claudeAuthStatus: ClaudeAuthStatus | null;
claudeInstallProgress: InstallProgress;
claudeIsVerifying: boolean;
// GitHub CLI state
ghCliStatus: GhCliStatus | null;
@@ -164,6 +165,7 @@ export interface SetupActions {
setClaudeAuthStatus: (status: ClaudeAuthStatus | null) => void;
setClaudeInstallProgress: (progress: Partial<InstallProgress>) => void;
resetClaudeInstallProgress: () => void;
setClaudeIsVerifying: (isVerifying: boolean) => void;
// GitHub CLI
setGhCliStatus: (status: GhCliStatus | null) => void;
@@ -202,6 +204,7 @@ const initialState: SetupState = {
claudeCliStatus: null,
claudeAuthStatus: null,
claudeInstallProgress: { ...initialInstallProgress },
claudeIsVerifying: false,
ghCliStatus: null,
cursorCliStatus: null,
@@ -255,6 +258,8 @@ export const useSetupStore = create<SetupState & SetupActions>()((set, get) => (
claudeInstallProgress: { ...initialInstallProgress },
}),
setClaudeIsVerifying: (isVerifying) => set({ claudeIsVerifying: isVerifying }),
// GitHub CLI
setGhCliStatus: (status) => set({ ghCliStatus: status }),