mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-10-02 08:06:38 +08:00
Merge remote-tracking branch 'upstream/main' into dev
# Conflicts: # app/api/common.ts # app/components/settings.tsx # app/store/access.ts
This commit is contained in:
commit
c53ee2f065
@ -50,9 +50,9 @@ export async function requestOpenai(
|
|||||||
"/api/openai/",
|
"/api/openai/",
|
||||||
"",
|
"",
|
||||||
);
|
);
|
||||||
let baseUrl = isAzure
|
|
||||||
? serverConfig.azureUrl
|
let baseUrl =
|
||||||
: serverConfig.baseUrl || OPENAI_BASE_URL;
|
(isAzure ? serverConfig.azureUrl : serverConfig.baseUrl) || OPENAI_BASE_URL;
|
||||||
|
|
||||||
if (!baseUrl.startsWith("http")) {
|
if (!baseUrl.startsWith("http")) {
|
||||||
baseUrl = `https://${baseUrl}`;
|
baseUrl = `https://${baseUrl}`;
|
||||||
@ -110,10 +110,9 @@ export async function requestOpenai(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// const fetchUrl = `${baseUrl}/${path}`;
|
|
||||||
const jsonBody = await req.json();
|
|
||||||
const fetchUrl = cloudflareAIGatewayUrl(`${baseUrl}/${path}`);
|
const fetchUrl = cloudflareAIGatewayUrl(`${baseUrl}/${path}`);
|
||||||
console.log("fetchUrl", fetchUrl);
|
console.log("fetchUrl", fetchUrl);
|
||||||
|
const jsonBody = await req.json();
|
||||||
const fetchOptions: RequestInit = {
|
const fetchOptions: RequestInit = {
|
||||||
headers: {
|
headers: {
|
||||||
"Content-Type": "application/json",
|
"Content-Type": "application/json",
|
||||||
|
@ -967,290 +967,289 @@ export function Settings() {
|
|||||||
{/* </Select>*/}
|
{/* </Select>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
|
|
||||||
{/* {accessStore.provider === ServiceProvider.OpenAI && (*/}
|
{/*{accessStore.provider === ServiceProvider.OpenAI && (*/}
|
||||||
{/* <>*/}
|
{/* <>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.OpenAI.Endpoint.Title}*/}
|
{/* title={Locale.Settings.Access.OpenAI.Endpoint.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.OpenAI.Endpoint.SubTitle*/}
|
{/* Locale.Settings.Access.OpenAI.Endpoint.SubTitle*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <input*/}
|
{/* <input*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* value={accessStore.openaiUrl}*/}
|
{/* value={accessStore.openaiUrl}*/}
|
||||||
{/* placeholder={OPENAI_BASE_URL}*/}
|
{/* placeholder={OPENAI_BASE_URL}*/}
|
||||||
{/* onChange={(e) =>*/}
|
{/* onChange={(e) =>*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.openaiUrl = e.currentTarget.value),*/}
|
{/* (access.openaiUrl = e.currentTarget.value),*/}
|
||||||
{/* )*/}
|
{/* )*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* ></input>*/}
|
{/* ></input>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.OpenAI.ApiKey.Title}*/}
|
{/* title={Locale.Settings.Access.OpenAI.ApiKey.Title}*/}
|
||||||
{/* subTitle={Locale.Settings.Access.OpenAI.ApiKey.SubTitle}*/}
|
{/* subTitle={Locale.Settings.Access.OpenAI.ApiKey.SubTitle}*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <PasswordInput*/}
|
{/* <PasswordInput*/}
|
||||||
{/* value={accessStore.openaiApiKey}*/}
|
{/* value={accessStore.openaiApiKey}*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* placeholder={*/}
|
{/* placeholder={*/}
|
||||||
{/* Locale.Settings.Access.OpenAI.ApiKey.Placeholder*/}
|
{/* Locale.Settings.Access.OpenAI.ApiKey.Placeholder*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* onChange={(e) => {*/}
|
{/* onChange={(e) => {*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.openaiApiKey = e.currentTarget.value),*/}
|
{/* (access.openaiApiKey = e.currentTarget.value),*/}
|
||||||
{/* );*/}
|
{/* );*/}
|
||||||
{/* }}*/}
|
{/* }}*/}
|
||||||
{/* />*/}
|
{/* />*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* </>*/}
|
{/* </>*/}
|
||||||
{/* )}*/}
|
{/*)}*/}
|
||||||
{/* {accessStore.provider === ServiceProvider.Azure && (*/}
|
{/*{accessStore.provider === ServiceProvider.Azure && (*/}
|
||||||
{/* <>*/}
|
{/* <>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Azure.Endpoint.Title}*/}
|
{/* title={Locale.Settings.Access.Azure.Endpoint.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.Azure.Endpoint.SubTitle +*/}
|
{/* Locale.Settings.Access.Azure.Endpoint.SubTitle +*/}
|
||||||
{/* Azure.ExampleEndpoint*/}
|
{/* Azure.ExampleEndpoint*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <input*/}
|
{/* <input*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* value={accessStore.azureUrl}*/}
|
{/* value={accessStore.azureUrl}*/}
|
||||||
{/* placeholder={Azure.ExampleEndpoint}*/}
|
{/* placeholder={Azure.ExampleEndpoint}*/}
|
||||||
{/* onChange={(e) =>*/}
|
{/* onChange={(e) =>*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.azureUrl = e.currentTarget.value),*/}
|
{/* (access.azureUrl = e.currentTarget.value),*/}
|
||||||
{/* )*/}
|
{/* )*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* ></input>*/}
|
{/* ></input>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Azure.ApiKey.Title}*/}
|
{/* title={Locale.Settings.Access.Azure.ApiKey.Title}*/}
|
||||||
{/* subTitle={Locale.Settings.Access.Azure.ApiKey.SubTitle}*/}
|
{/* subTitle={Locale.Settings.Access.Azure.ApiKey.SubTitle}*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <PasswordInput*/}
|
{/* <PasswordInput*/}
|
||||||
{/* value={accessStore.azureApiKey}*/}
|
{/* value={accessStore.azureApiKey}*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* placeholder={*/}
|
{/* placeholder={*/}
|
||||||
{/* Locale.Settings.Access.Azure.ApiKey.Placeholder*/}
|
{/* Locale.Settings.Access.Azure.ApiKey.Placeholder*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* onChange={(e) => {*/}
|
{/* onChange={(e) => {*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.azureApiKey = e.currentTarget.value),*/}
|
{/* (access.azureApiKey = e.currentTarget.value),*/}
|
||||||
{/* );*/}
|
{/* );*/}
|
||||||
{/* }}*/}
|
{/* }}*/}
|
||||||
{/* />*/}
|
{/* />*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Azure.ApiVerion.Title}*/}
|
{/* title={Locale.Settings.Access.Azure.ApiVerion.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.Azure.ApiVerion.SubTitle*/}
|
{/* Locale.Settings.Access.Azure.ApiVerion.SubTitle*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <input*/}
|
{/* <input*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* value={accessStore.azureApiVersion}*/}
|
{/* value={accessStore.azureApiVersion}*/}
|
||||||
{/* placeholder="2023-08-01-preview"*/}
|
{/* placeholder="2023-08-01-preview"*/}
|
||||||
{/* onChange={(e) =>*/}
|
{/* onChange={(e) =>*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.azureApiVersion =*/}
|
{/* (access.azureApiVersion =*/}
|
||||||
{/* e.currentTarget.value),*/}
|
{/* e.currentTarget.value),*/}
|
||||||
{/* )*/}
|
{/* )*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* ></input>*/}
|
{/* ></input>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* </>*/}
|
{/* </>*/}
|
||||||
{/* )}*/}
|
{/*)}*/}
|
||||||
{/* {accessStore.provider === ServiceProvider.Google && (*/}
|
{/*{accessStore.provider === ServiceProvider.Google && (*/}
|
||||||
{/* <>*/}
|
{/* <>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Google.Endpoint.Title}*/}
|
{/* title={Locale.Settings.Access.Google.Endpoint.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.Google.Endpoint.SubTitle +*/}
|
{/* Locale.Settings.Access.Google.Endpoint.SubTitle +*/}
|
||||||
{/* Google.ExampleEndpoint*/}
|
{/* Google.ExampleEndpoint*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <input*/}
|
{/* <input*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* value={accessStore.googleUrl}*/}
|
{/* value={accessStore.googleUrl}*/}
|
||||||
{/* placeholder={Google.ExampleEndpoint}*/}
|
{/* placeholder={Google.ExampleEndpoint}*/}
|
||||||
{/* onChange={(e) =>*/}
|
{/* onChange={(e) =>*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.googleUrl = e.currentTarget.value),*/}
|
{/* (access.googleUrl = e.currentTarget.value),*/}
|
||||||
{/* )*/}
|
{/* )*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* ></input>*/}
|
{/* ></input>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Google.ApiKey.Title}*/}
|
{/* title={Locale.Settings.Access.Google.ApiKey.Title}*/}
|
||||||
{/* subTitle={Locale.Settings.Access.Google.ApiKey.SubTitle}*/}
|
{/* subTitle={Locale.Settings.Access.Google.ApiKey.SubTitle}*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <PasswordInput*/}
|
{/* <PasswordInput*/}
|
||||||
{/* value={accessStore.googleApiKey}*/}
|
{/* value={accessStore.googleApiKey}*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* placeholder={*/}
|
{/* placeholder={*/}
|
||||||
{/* Locale.Settings.Access.Google.ApiKey.Placeholder*/}
|
{/* Locale.Settings.Access.Google.ApiKey.Placeholder*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* onChange={(e) => {*/}
|
{/* onChange={(e) => {*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.googleApiKey = e.currentTarget.value),*/}
|
{/* (access.googleApiKey = e.currentTarget.value),*/}
|
||||||
{/* );*/}
|
{/* );*/}
|
||||||
{/* }}*/}
|
{/* }}*/}
|
||||||
{/* />*/}
|
{/* />*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Google.ApiVersion.Title}*/}
|
{/* title={Locale.Settings.Access.Google.ApiVersion.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.Google.ApiVersion.SubTitle*/}
|
{/* Locale.Settings.Access.Google.ApiVersion.SubTitle*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <input*/}
|
{/* <input*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* value={accessStore.googleApiVersion}*/}
|
{/* value={accessStore.googleApiVersion}*/}
|
||||||
{/* placeholder="2023-08-01-preview"*/}
|
{/* placeholder="2023-08-01-preview"*/}
|
||||||
{/* onChange={(e) =>*/}
|
{/* onChange={(e) =>*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.googleApiVersion =*/}
|
{/* (access.googleApiVersion =*/}
|
||||||
{/* e.currentTarget.value),*/}
|
{/* e.currentTarget.value),*/}
|
||||||
{/* )*/}
|
{/* )*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* ></input>*/}
|
{/* ></input>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* </>*/}
|
{/* </>*/}
|
||||||
{/* )}*/}
|
{/*)}*/}
|
||||||
{/* {accessStore.provider === ServiceProvider.Anthropic && (*/}
|
{/*{accessStore.provider === ServiceProvider.Anthropic && (*/}
|
||||||
{/* <>*/}
|
{/* <>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Anthropic.Endpoint.Title}*/}
|
{/* title={Locale.Settings.Access.Anthropic.Endpoint.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.Anthropic.Endpoint.SubTitle +*/}
|
{/* Locale.Settings.Access.Anthropic.Endpoint.SubTitle +*/}
|
||||||
{/* Anthropic.ExampleEndpoint*/}
|
{/* Anthropic.ExampleEndpoint*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <input*/}
|
{/* <input*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* value={accessStore.anthropicUrl}*/}
|
{/* value={accessStore.anthropicUrl}*/}
|
||||||
{/* placeholder={Anthropic.ExampleEndpoint}*/}
|
{/* placeholder={Anthropic.ExampleEndpoint}*/}
|
||||||
{/* onChange={(e) =>*/}
|
{/* onChange={(e) =>*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.anthropicUrl = e.currentTarget.value),*/}
|
{/* (access.anthropicUrl = e.currentTarget.value),*/}
|
||||||
{/* )*/}
|
{/* )*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* ></input>*/}
|
{/* ></input>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Anthropic.ApiKey.Title}*/}
|
{/* title={Locale.Settings.Access.Anthropic.ApiKey.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.Anthropic.ApiKey.SubTitle*/}
|
{/* Locale.Settings.Access.Anthropic.ApiKey.SubTitle*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <PasswordInput*/}
|
{/* <PasswordInput*/}
|
||||||
{/* value={accessStore.anthropicApiKey}*/}
|
{/* value={accessStore.anthropicApiKey}*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* placeholder={*/}
|
{/* placeholder={*/}
|
||||||
{/* Locale.Settings.Access.Anthropic.ApiKey.Placeholder*/}
|
{/* Locale.Settings.Access.Anthropic.ApiKey.Placeholder*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* onChange={(e) => {*/}
|
{/* onChange={(e) => {*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.anthropicApiKey =*/}
|
{/* (access.anthropicApiKey =*/}
|
||||||
{/* e.currentTarget.value),*/}
|
{/* e.currentTarget.value),*/}
|
||||||
{/* );*/}
|
{/* );*/}
|
||||||
{/* }}*/}
|
{/* }}*/}
|
||||||
{/* />*/}
|
{/* />*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Anthropic.ApiVerion.Title}*/}
|
{/* title={Locale.Settings.Access.Anthropic.ApiVerion.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.Anthropic.ApiVerion.SubTitle*/}
|
{/* Locale.Settings.Access.Anthropic.ApiVerion.SubTitle*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* >*/}
|
{/* >*/}
|
||||||
{/* <input*/}
|
{/* <input*/}
|
||||||
{/* type="text"*/}
|
{/* type="text"*/}
|
||||||
{/* value={accessStore.anthropicApiVersion}*/}
|
{/* value={accessStore.anthropicApiVersion}*/}
|
||||||
{/* placeholder={Anthropic.Vision}*/}
|
{/* placeholder={Anthropic.Vision}*/}
|
||||||
{/* onChange={(e) =>*/}
|
{/* onChange={(e) =>*/}
|
||||||
{/* accessStore.update(*/}
|
{/* accessStore.update(*/}
|
||||||
{/* (access) =>*/}
|
{/* (access) =>*/}
|
||||||
{/* (access.anthropicApiVersion =*/}
|
{/* (access.anthropicApiVersion =*/}
|
||||||
{/* e.currentTarget.value),*/}
|
{/* e.currentTarget.value),*/}
|
||||||
{/* )*/}
|
{/* )*/}
|
||||||
{/* }*/}
|
{/* }*/}
|
||||||
{/* ></input>*/}
|
{/* ></input>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </ListItem>*/}
|
||||||
{/* </>*/}
|
{/* </>*/}
|
||||||
{/* )}*/}
|
{/*)}*/}
|
||||||
{/* {accessStore.provider === ServiceProvider.Baidu && (*/}
|
{/*{accessStore.provider === ServiceProvider.Baidu && (*/}
|
||||||
{/* <>*/}
|
{/* <>*/}
|
||||||
{/* <ListItem*/}
|
{/* <ListItem*/}
|
||||||
{/* title={Locale.Settings.Access.Baidu.Endpoint.Title}*/}
|
{/* title={Locale.Settings.Access.Baidu.Endpoint.Title}*/}
|
||||||
{/* subTitle={*/}
|
{/* subTitle={*/}
|
||||||
{/* Locale.Settings.Access.Anthropic.Endpoint.SubTitle +*/}
|
{/* Locale.Settings.Access.Baidu.Endpoint.SubTitle*/}
|
||||||
{/* Baidu.ExampleEndpoint*/}
|
{/* }*/}
|
||||||
{/* }*/}
|
{/* >*/}
|
||||||
{/* >*/}
|
{/* <input*/}
|
||||||
{/* <input*/}
|
{/* type="text"*/}
|
||||||
{/* type="text"*/}
|
{/* value={accessStore.baiduUrl}*/}
|
||||||
{/* value={accessStore.baiduUrl}*/}
|
{/* placeholder={Baidu.ExampleEndpoint}*/}
|
||||||
{/* placeholder={Baidu.ExampleEndpoint}*/}
|
{/* onChange={(e) =>*/}
|
||||||
{/* onChange={(e) =>*/}
|
{/* accessStore.update(*/}
|
||||||
{/* accessStore.update(*/}
|
{/* (access) =>*/}
|
||||||
{/* (access) =>*/}
|
{/* (access.baiduUrl = e.currentTarget.value),*/}
|
||||||
{/* (access.baiduUrl = e.currentTarget.value),*/}
|
{/* )*/}
|
||||||
{/* )*/}
|
{/* }*/}
|
||||||
{/* }*/}
|
{/* ></input>*/}
|
||||||
{/* ></input>*/}
|
{/* </ListItem>*/}
|
||||||
{/* </ListItem>*/}
|
{/* <ListItem*/}
|
||||||
{/* <ListItem*/}
|
{/* title={Locale.Settings.Access.Baidu.ApiKey.Title}*/}
|
||||||
{/* title={Locale.Settings.Access.Baidu.ApiKey.Title}*/}
|
{/* subTitle={Locale.Settings.Access.Baidu.ApiKey.SubTitle}*/}
|
||||||
{/* subTitle={Locale.Settings.Access.Baidu.ApiKey.SubTitle}*/}
|
{/* >*/}
|
||||||
{/* >*/}
|
{/* <PasswordInput*/}
|
||||||
{/* <PasswordInput*/}
|
{/* value={accessStore.baiduApiKey}*/}
|
||||||
{/* value={accessStore.baiduApiKey}*/}
|
{/* type="text"*/}
|
||||||
{/* type="text"*/}
|
{/* placeholder={*/}
|
||||||
{/* placeholder={*/}
|
{/* Locale.Settings.Access.Baidu.ApiKey.Placeholder*/}
|
||||||
{/* Locale.Settings.Access.Baidu.ApiKey.Placeholder*/}
|
{/* }*/}
|
||||||
{/* }*/}
|
{/* onChange={(e) => {*/}
|
||||||
{/* onChange={(e) => {*/}
|
{/* accessStore.update(*/}
|
||||||
{/* accessStore.update(*/}
|
{/* (access) =>*/}
|
||||||
{/* (access) =>*/}
|
{/* (access.baiduApiKey = e.currentTarget.value),*/}
|
||||||
{/* (access.baiduApiKey = e.currentTarget.value),*/}
|
{/* );*/}
|
||||||
{/* );*/}
|
{/* }}*/}
|
||||||
{/* }}*/}
|
{/* />*/}
|
||||||
{/* />*/}
|
{/* </ListItem>*/}
|
||||||
{/* </ListItem>*/}
|
{/* <ListItem*/}
|
||||||
{/* <ListItem*/}
|
{/* title={Locale.Settings.Access.Baidu.SecretKey.Title}*/}
|
||||||
{/* title={Locale.Settings.Access.Baidu.SecretKey.Title}*/}
|
{/* subTitle={*/}
|
||||||
{/* subTitle={*/}
|
{/* Locale.Settings.Access.Baidu.SecretKey.SubTitle*/}
|
||||||
{/* Locale.Settings.Access.Baidu.SecretKey.SubTitle*/}
|
{/* }*/}
|
||||||
{/* }*/}
|
{/* >*/}
|
||||||
{/* >*/}
|
{/* <PasswordInput*/}
|
||||||
{/* <PasswordInput*/}
|
{/* value={accessStore.baiduSecretKey}*/}
|
||||||
{/* value={accessStore.baiduSecretKey}*/}
|
{/* type="text"*/}
|
||||||
{/* type="text"*/}
|
{/* placeholder={*/}
|
||||||
{/* placeholder={*/}
|
{/* Locale.Settings.Access.Baidu.SecretKey.Placeholder*/}
|
||||||
{/* Locale.Settings.Access.Baidu.SecretKey.Placeholder*/}
|
{/* }*/}
|
||||||
{/* }*/}
|
{/* onChange={(e) => {*/}
|
||||||
{/* onChange={(e) => {*/}
|
{/* accessStore.update(*/}
|
||||||
{/* accessStore.update(*/}
|
{/* (access) =>*/}
|
||||||
{/* (access) =>*/}
|
{/* (access.baiduSecretKey = e.currentTarget.value),*/}
|
||||||
{/* (access.baiduSecretKey = e.currentTarget.value),*/}
|
{/* );*/}
|
||||||
{/* );*/}
|
{/* }}*/}
|
||||||
{/* }}*/}
|
{/* />*/}
|
||||||
{/* />*/}
|
{/* </ListItem>*/}
|
||||||
{/* </ListItem>*/}
|
{/* </>*/}
|
||||||
{/* </>*/}
|
{/*)}*/}
|
||||||
{/* )}*/}
|
|
||||||
|
|
||||||
{/* {accessStore.provider === ServiceProvider.ByteDance && (*/}
|
{/* {accessStore.provider === ServiceProvider.ByteDance && (*/}
|
||||||
{/* <>*/}
|
{/* <>*/}
|
||||||
|
@ -38,7 +38,7 @@ const DEFAULT_ALIBABA_URL = isApp
|
|||||||
? DEFAULT_API_HOST + "/api/proxy/alibaba"
|
? DEFAULT_API_HOST + "/api/proxy/alibaba"
|
||||||
: ApiPath.Alibaba;
|
: ApiPath.Alibaba;
|
||||||
|
|
||||||
// console.log("DEFAULT_ANTHROPIC_URL", DEFAULT_ANTHROPIC_URL);
|
console.log("DEFAULT_ANTHROPIC_URL", DEFAULT_ANTHROPIC_URL);
|
||||||
|
|
||||||
const DEFAULT_ACCESS_STATE = {
|
const DEFAULT_ACCESS_STATE = {
|
||||||
accessCode: "",
|
accessCode: "",
|
||||||
|
Loading…
Reference in New Issue
Block a user