chore: replace all cn comments of fe to en version by volc api (#320)
This commit is contained in:
@@ -22,7 +22,7 @@ import { getExpirationTime } from '@/utils/time';
|
||||
|
||||
export const columnExpireAtConf: () => ColumnProps<PersonalAccessToken> =
|
||||
() => ({
|
||||
title: I18n.t('expire_time_1'), // 状态
|
||||
title: I18n.t('expire_time_1'), // state
|
||||
dataIndex: 'expire_at',
|
||||
render: (expireTime: number) => getExpirationTime(expireTime),
|
||||
});
|
||||
|
||||
@@ -37,7 +37,7 @@ interface ResultProps {
|
||||
onOk: () => void;
|
||||
}
|
||||
|
||||
// 新建编辑 PAT
|
||||
// New Edit PAT
|
||||
export const ResultModal = ({ visible, onOk, data }: ResultProps) => {
|
||||
const doCopyAsync = useMemoizedFn(() => {
|
||||
const targetKey = data?.token;
|
||||
|
||||
@@ -18,10 +18,10 @@ import dayjs from 'dayjs';
|
||||
import { I18n, type I18nKeysNoOptionsType } from '@coze-arch/i18n';
|
||||
|
||||
const MAX_EXPIRATION_DAYS = 30;
|
||||
// 1-30天有效期
|
||||
// 1-30 days valid period
|
||||
export const disabledDate = (date?: Date) => {
|
||||
const today = dayjs().startOf('day'); // 当天的开始时间
|
||||
const thirtyDaysLater = today.add(MAX_EXPIRATION_DAYS, 'day'); // 30天后的日期
|
||||
const today = dayjs().startOf('day'); // Start time of the day
|
||||
const thirtyDaysLater = today.add(MAX_EXPIRATION_DAYS, 'day'); // Date in 30 days
|
||||
|
||||
return (
|
||||
dayjs(date).isBefore(today, 'day') ||
|
||||
|
||||
@@ -40,16 +40,16 @@ export default defineConfig(
|
||||
'src/components/**',
|
||||
'src/pages/**',
|
||||
'src/constants/**',
|
||||
'src/utils/public-private-keys.ts', // window 提供的 api
|
||||
'src/utils/docs.ts', // 线上未使用 仅 boe使用 即将删除
|
||||
'src/utils/time.ts', // dayjs api 的调用
|
||||
'src/utils/public-private-keys.ts', // Windows API
|
||||
'src/utils/docs.ts', // Unused online, only boe used, about to be deleted
|
||||
'src/utils/time.ts', // Dayjs API calls
|
||||
'src/utils//analytics/index.ts',
|
||||
'src/utils//analytics/chart.ts', // 有图表 dom 相关内容
|
||||
'src/hooks/pat/action/**', // 操作类 hook
|
||||
'src/hooks/oauth-app/action/**', // 操作类 hook
|
||||
'src/hooks/use-arcosite.ts', // 线上未使用 仅 boe使用
|
||||
'src/hooks/use-show-mask.ts', // 主要为获取 dom 的 scrollTop
|
||||
'src/hooks/use-docs-path.ts', // useNavigate 相关内容
|
||||
'src/hooks/pat/action/**', // Action class hook
|
||||
'src/hooks/oauth-app/action/**', // Action class hook
|
||||
'src/hooks/use-arcosite.ts', // Not used online, only boe used
|
||||
'src/hooks/use-show-mask.ts', // Mainly scrollTop for getting dom
|
||||
'src/hooks/use-docs-path.ts', // useNavigate related content
|
||||
],
|
||||
},
|
||||
},
|
||||
|
||||
@@ -22,9 +22,9 @@ export enum Layout {
|
||||
}
|
||||
|
||||
export interface HeaderConfig {
|
||||
isShow?: boolean; //是否显示header, 默认是true
|
||||
isNeedClose?: boolean; //是否需要关闭按钮, 默认是true
|
||||
extra?: ReactNode | false; // 用于站位的,默认无
|
||||
isShow?: boolean; //Whether to display headers, the default is true
|
||||
isNeedClose?: boolean; //Whether you need the close button, the default is true.
|
||||
extra?: ReactNode | false; // For standing, default none
|
||||
}
|
||||
|
||||
export interface DebugProps {
|
||||
|
||||
@@ -34,12 +34,12 @@ export interface IWorkflow {
|
||||
export interface IProject {
|
||||
id: string;
|
||||
type: 'app' | 'bot';
|
||||
mode: 'draft' | 'release' | 'websdk' | 'audit'; // 草稿模式 | 发布模式 | webSdk发布
|
||||
mode: 'draft' | 'release' | 'websdk' | 'audit'; // Draft Mode | Publish Mode | webSdk Publish
|
||||
caller?: 'UI_BUILDER' | 'CANVAS';
|
||||
connectorId?: string;
|
||||
conversationName?: string; // project的话,必须填写
|
||||
conversationId?: string; // type 为bot的话,必须填写
|
||||
sectionId?: string; // type 为bot的话,必须填写
|
||||
conversationName?: string; // Project must be filled in
|
||||
conversationId?: string; // If the type is bot, it must be filled in
|
||||
sectionId?: string; // If the type is bot, it must be filled in
|
||||
name?: string;
|
||||
defaultName?: string;
|
||||
defaultIconUrl?: string;
|
||||
@@ -68,28 +68,28 @@ export interface IBuilderChatProps {
|
||||
eventCallbacks?: IEventCallbacks;
|
||||
userInfo: IChatFlowProps['userInfo'];
|
||||
areaUi: {
|
||||
isDisabled?: boolean; // 默认 false
|
||||
uploadable?: boolean; // 默认 true
|
||||
isNeedClearContext?: boolean; // 是否显示 clearContext按钮
|
||||
isNeedClearMessage?: boolean; // 是否显示 clearMessage按钮
|
||||
isDisabled?: boolean; // Default false
|
||||
uploadable?: boolean; // Default true
|
||||
isNeedClearContext?: boolean; // Whether to display the clearContext button
|
||||
isNeedClearMessage?: boolean; // Whether to display the clearMessage button
|
||||
|
||||
//isShowHeader?: boolean; // 默认 false
|
||||
//isShowFooter?: boolean; // 默认 false
|
||||
//isShowHeader?: boolean;//default false
|
||||
//isShowFooter?: boolean;//default false
|
||||
input?: {
|
||||
placeholder?: string;
|
||||
renderChatInputTopSlot?: (isChatError?: boolean) => React.ReactNode;
|
||||
isShow?: boolean; //默认 true
|
||||
isShow?: boolean; //Default true
|
||||
defaultText?: string;
|
||||
isNeedAudio?: boolean; // 是否需要语音输入,默认是false
|
||||
isNeedAudio?: boolean; // Whether voice input is required, the default is false
|
||||
isNeedTaskMessage?: boolean;
|
||||
};
|
||||
header?: HeaderConfig; // 默认是
|
||||
header?: HeaderConfig; // Default is
|
||||
footer?: FooterConfig;
|
||||
uiTheme?: 'uiBuilder' | 'chatFlow'; // uiBuilder 的主题
|
||||
uiTheme?: 'uiBuilder' | 'chatFlow'; // Theme for uiBuilder
|
||||
renderLoading?: () => React.ReactNode;
|
||||
};
|
||||
auth?: {
|
||||
type: 'external' | 'internal'; // 内部: cookie换token, 外部: internal
|
||||
type: 'external' | 'internal'; // Internal: cookie for token, external: internal
|
||||
token?: string;
|
||||
refreshToken?: () => Promise<string> | string;
|
||||
};
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
/**
|
||||
* 依赖 treeShaking 去除无关配置(Argus)
|
||||
* Dependency treeShaking Removes Extraneous Configuration (Argus)
|
||||
*/
|
||||
const sdkRegion = 'cn';
|
||||
export const iframeAppHost = '';
|
||||
@@ -28,7 +28,7 @@ export const openApiCdnUrlByRegion = IS_OVERSEA
|
||||
: // cp-disable-next-line
|
||||
'https://lf3-static.bytednsdoc.com/obj/eden-cn/rkzild_lgvj/ljhwZthlaukjlkulzlp/';
|
||||
|
||||
// 用户需要修改此处baseurl,用于开放平台接口的域名配置
|
||||
// The user needs to modify the baseurl here to open the domain name configuration of the API interface
|
||||
export const openApiHostByRegion =
|
||||
typeof location !== 'undefined' ? location.origin : 'https://api.xxx.com';
|
||||
export const openApiHostByRegionWithToken = openApiHostByRegion;
|
||||
|
||||
Reference in New Issue
Block a user