mirror of
https://github.com/claude-code-best/claude-code.git
synced 2026-06-22 16:25:51 +00:00
ConsoleOAuthFlow: 添加 base_url URL 格式验证
This commit is contained in:
@@ -19,6 +19,7 @@ import { Select } from './CustomSelect/select.js'
|
|||||||
import { KeyboardShortcutHint } from './design-system/KeyboardShortcutHint.js'
|
import { KeyboardShortcutHint } from './design-system/KeyboardShortcutHint.js'
|
||||||
import { Spinner } from './Spinner.js'
|
import { Spinner } from './Spinner.js'
|
||||||
import TextInput from './TextInput.js'
|
import TextInput from './TextInput.js'
|
||||||
|
import { fi } from 'zod/v4/locales'
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
onDone(): void
|
onDone(): void
|
||||||
@@ -659,11 +660,11 @@ function OAuthStatusMessage({
|
|||||||
message: 'Failed to save settings. Please try again.',
|
message: 'Failed to save settings. Please try again.',
|
||||||
toRetry: {
|
toRetry: {
|
||||||
state: 'custom_platform',
|
state: 'custom_platform',
|
||||||
baseUrl: '',
|
baseUrl: finalVals.base_url ?? '',
|
||||||
apiKey: '',
|
apiKey: finalVals.api_key ?? '',
|
||||||
haikuModel: '',
|
haikuModel: finalVals.haiku_model ?? '',
|
||||||
sonnetModel: '',
|
sonnetModel: finalVals.sonnet_model ?? '',
|
||||||
opusModel: '',
|
opusModel: finalVals.opus_model ?? '',
|
||||||
activeField: 'base_url',
|
activeField: 'base_url',
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
@@ -878,11 +879,11 @@ function OAuthStatusMessage({
|
|||||||
message: 'Failed to save settings. Please try again.',
|
message: 'Failed to save settings. Please try again.',
|
||||||
toRetry: {
|
toRetry: {
|
||||||
state: 'openai_chat_api',
|
state: 'openai_chat_api',
|
||||||
baseUrl: '',
|
baseUrl: finalVals.base_url ?? '',
|
||||||
apiKey: '',
|
apiKey: finalVals.api_key ?? '',
|
||||||
haikuModel: '',
|
haikuModel: finalVals.haiku_model ?? '',
|
||||||
sonnetModel: '',
|
sonnetModel: finalVals.sonnet_model ?? '',
|
||||||
opusModel: '',
|
opusModel: finalVals.opus_model ?? '',
|
||||||
activeField: 'base_url',
|
activeField: 'base_url',
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user