refactor(url): remove automatic trailing slash stripping from base URL inputs

- Remove `.replace(/\/+$/, "")` from all base URL handlers in useBaseUrlState.ts
- Remove trailing slash stripping in useCodexConfigState.ts
- Remove trailing slash normalization in providerConfigUtils.ts setCodexBaseUrl()
- Update i18n hints (en/ja/zh) to instruct users to avoid trailing slashes

This gives users explicit control over URL format rather than silently modifying input.
This commit is contained in:
Jason
2025-11-29 20:52:29 +08:00
parent 526c7406fa
commit 3bf37cf0ff
6 changed files with 10 additions and 11 deletions
@@ -162,7 +162,7 @@ export function useCodexConfigState({ initialData }: UseCodexConfigStateProps) {
// 处理 Codex Base URL 变化
const handleCodexBaseUrlChange = useCallback(
(url: string) => {
const sanitized = url.trim().replace(/\/+$/, "");
const sanitized = url.trim();
setCodexBaseUrl(sanitized);
if (!sanitized) {