Skip to content

Commit

Permalink
feat: 增加自定义 meta description; (#1246)
Browse files Browse the repository at this point in the history
* feat: 增加自定义 meta description;

* fix: 环境变量使用错误;

---------

Co-authored-by: junshun.mq <[email protected]>
  • Loading branch information
maquannene and junshun.mq authored Apr 28, 2024
1 parent 59ece44 commit 5ca4049
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
1 change: 1 addition & 0 deletions docSite/content/docs/development/sealos.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ FastGPT 商业版共包含了2个应用(fastgpt, fastgpt-plus)和2个数据

```
SYSTEM_NAME=FastGPT
SYSTEM_DESCRIPTION=
SYSTEM_FAVICON=/favicon.ico
HOME_URL=/app/list
```
Expand Down
1 change: 1 addition & 0 deletions packages/global/common/system/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ export type FastGPTFeConfigsType = {
chatbotUrl?: string;
openAPIDocUrl?: string;
systemTitle?: string;
systemDescription?: string;
googleClientVerKey?: string;
isPlus?: boolean;
show_phoneLogin?: boolean;
Expand Down
6 changes: 5 additions & 1 deletion projects/app/src/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@ function App({ Component, pageProps }: AppProps) {
<title>{title}</title>
<meta
name="description"
content={`${title} 是一个大模型应用编排系统,提供开箱即用的数据处理、模型调用等能力,可以快速的构建知识库并通过 Flow 可视化进行工作流编排,实现复杂的知识库场景!`}
content={
feConfigs?.systemDescription ||
process.env.SYSTEM_DESCRIPTION ||
`${title} 是一个大模型应用编排系统,提供开箱即用的数据处理、模型调用等能力,可以快速的构建知识库并通过 Flow 可视化进行工作流编排,实现复杂的知识库场景!`
}
/>
<meta
name="viewport"
Expand Down
2 changes: 1 addition & 1 deletion projects/app/src/web/common/system/api.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { GET, POST, PUT, DELETE } from '@/web/common/api/request';
import type { InitDateResponse } from '@/global/common/api/systemRes';
import { GET } from '@/web/common/api/request';

export const getSystemInitData = () => GET<InitDateResponse>('/common/system/getInitData');

0 comments on commit 5ca4049

Please sign in to comment.