feat: add download ZIP and push to GitHub features, fix code overflow in chat
This commit is contained in:
@@ -34,6 +34,7 @@ interface AppState {
|
||||
refreshToken?: string;
|
||||
expiresAt?: number;
|
||||
} | null;
|
||||
githubToken?: string | null;
|
||||
isProcessing: boolean;
|
||||
error: string | null;
|
||||
history: {
|
||||
@@ -65,6 +66,7 @@ interface AppState {
|
||||
setAvailableModels: (provider: ModelProvider, models: string[]) => void;
|
||||
setApiKey: (provider: ModelProvider, key: string) => void;
|
||||
setQwenTokens: (tokens?: { accessToken: string; refreshToken?: string; expiresAt?: number } | null) => void;
|
||||
setGithubToken: (token: string | null) => void;
|
||||
setProcessing: (processing: boolean) => void;
|
||||
setError: (error: string | null) => void;
|
||||
addToHistory: (prompt: string) => void;
|
||||
@@ -107,6 +109,7 @@ const useStore = create<AppState>((set) => ({
|
||||
ollama: "",
|
||||
zai: "",
|
||||
},
|
||||
githubToken: null,
|
||||
isProcessing: false,
|
||||
error: null,
|
||||
history: [],
|
||||
@@ -174,6 +177,7 @@ const useStore = create<AppState>((set) => ({
|
||||
apiKeys: { ...state.apiKeys, [provider]: key },
|
||||
})),
|
||||
setQwenTokens: (tokens) => set({ qwenTokens: tokens }),
|
||||
setGithubToken: (token) => set({ githubToken: token }),
|
||||
setProcessing: (processing) => set({ isProcessing: processing }),
|
||||
setError: (error) => set({ error }),
|
||||
addToHistory: (prompt) =>
|
||||
|
||||
Reference in New Issue
Block a user