@lobehub/chat 0.79.5 → 0.79.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +50 -0
- package/docs/Home.md +1 -1
- package/package.json +7 -7
- package/src/app/layout.tsx +1 -1
- package/src/app/metadata.ts +1 -1
- package/src/hooks/useIsPWA.ts +15 -0
- package/src/layout/AppLayout.tsx +9 -1
- package/src/styles/global.ts +1 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,56 @@
|
|
|
2
2
|
|
|
3
3
|
# Changelog
|
|
4
4
|
|
|
5
|
+
### [Version 0.79.7](https://github.com/lobehub/lobe-chat/compare/v0.79.6...v0.79.7)
|
|
6
|
+
|
|
7
|
+
<sup>Released on **2023-09-27**</sup>
|
|
8
|
+
|
|
9
|
+
#### ♻ Code Refactoring
|
|
10
|
+
|
|
11
|
+
- **misc**: Use hook to check PWA env.
|
|
12
|
+
|
|
13
|
+
<br/>
|
|
14
|
+
|
|
15
|
+
<details>
|
|
16
|
+
<summary><kbd>Improvements and Fixes</kbd></summary>
|
|
17
|
+
|
|
18
|
+
#### Code refactoring
|
|
19
|
+
|
|
20
|
+
- **misc**: Use hook to check PWA env ([b4234db](https://github.com/lobehub/lobe-chat/commit/b4234db))
|
|
21
|
+
|
|
22
|
+
</details>
|
|
23
|
+
|
|
24
|
+
<div align="right">
|
|
25
|
+
|
|
26
|
+
[](#readme-top)
|
|
27
|
+
|
|
28
|
+
</div>
|
|
29
|
+
|
|
30
|
+
### [Version 0.79.6](https://github.com/lobehub/lobe-chat/compare/v0.79.5...v0.79.6)
|
|
31
|
+
|
|
32
|
+
<sup>Released on **2023-09-27**</sup>
|
|
33
|
+
|
|
34
|
+
#### 💄 Styles
|
|
35
|
+
|
|
36
|
+
- **misc**: Optmize PWA style and scroll effect.
|
|
37
|
+
|
|
38
|
+
<br/>
|
|
39
|
+
|
|
40
|
+
<details>
|
|
41
|
+
<summary><kbd>Improvements and Fixes</kbd></summary>
|
|
42
|
+
|
|
43
|
+
#### Styles
|
|
44
|
+
|
|
45
|
+
- **misc**: Optmize PWA style and scroll effect ([0ae05b8](https://github.com/lobehub/lobe-chat/commit/0ae05b8))
|
|
46
|
+
|
|
47
|
+
</details>
|
|
48
|
+
|
|
49
|
+
<div align="right">
|
|
50
|
+
|
|
51
|
+
[](#readme-top)
|
|
52
|
+
|
|
53
|
+
</div>
|
|
54
|
+
|
|
5
55
|
### [Version 0.79.5](https://github.com/lobehub/lobe-chat/compare/v0.79.4...v0.79.5)
|
|
6
56
|
|
|
7
57
|
<sup>Released on **2023-09-26**</sup>
|
package/docs/Home.md
CHANGED
|
@@ -16,7 +16,7 @@ LobeChat is a open-source, extensible ([Function Calling][fc-url]), high-perform
|
|
|
16
16
|
|
|
17
17
|
- [Environment Variables](Environment-Variable) | [环境变量](Environment-Variable.zh-CN)
|
|
18
18
|
- [Maintaining Updates with LobeChat Self-Deployment](Upstream-Sync) | [自部署保持更新](Upstream-Sync.zh-CN)
|
|
19
|
-
- [Deploying with Azure OpenAI](Deploy-with-Azure-OpenAI) | [
|
|
19
|
+
- [Deploying with Azure OpenAI](Deploy-with-Azure-OpenAI) | [使用 Azure OpenAI 部署](Deploy-with-Azure-OpenAI.zh-CN)
|
|
20
20
|
|
|
21
21
|
---
|
|
22
22
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lobehub/chat",
|
|
3
|
-
"version": "0.79.
|
|
3
|
+
"version": "0.79.7",
|
|
4
4
|
"description": "An open-source, extensible (Function Calling), high-performance chatbot framework. It supports one-click free deployment of your private ChatGPT/LLM web application",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"chatbot",
|
|
@@ -68,8 +68,8 @@
|
|
|
68
68
|
"@emoji-mart/data": "^1",
|
|
69
69
|
"@emoji-mart/react": "^1",
|
|
70
70
|
"@icons-pack/react-simple-icons": "^9",
|
|
71
|
-
"@lobehub/chat-plugin-sdk": "
|
|
72
|
-
"@lobehub/chat-plugins-gateway": "
|
|
71
|
+
"@lobehub/chat-plugin-sdk": "latest",
|
|
72
|
+
"@lobehub/chat-plugins-gateway": "latest",
|
|
73
73
|
"@lobehub/ui": "latest",
|
|
74
74
|
"@vercel/analytics": "^1",
|
|
75
75
|
"ahooks": "^3",
|
|
@@ -88,16 +88,16 @@
|
|
|
88
88
|
"lucide-react": "latest",
|
|
89
89
|
"nanoid": "^5",
|
|
90
90
|
"next": "^13.5.3",
|
|
91
|
-
"openai": "^4
|
|
91
|
+
"openai": "^4",
|
|
92
92
|
"polished": "^4",
|
|
93
93
|
"react": "^18",
|
|
94
94
|
"react-dom": "^18",
|
|
95
95
|
"react-hotkeys-hook": "^4",
|
|
96
96
|
"react-i18next": "^13",
|
|
97
97
|
"react-intersection-observer": "^9",
|
|
98
|
-
"react-layout-kit": "^1
|
|
98
|
+
"react-layout-kit": "^1",
|
|
99
99
|
"swr": "^2",
|
|
100
|
-
"systemjs": "^6
|
|
100
|
+
"systemjs": "^6",
|
|
101
101
|
"ts-md5": "^1",
|
|
102
102
|
"url-join": "^5",
|
|
103
103
|
"use-merge-value": "^1",
|
|
@@ -118,7 +118,7 @@
|
|
|
118
118
|
"@types/node": "^20",
|
|
119
119
|
"@types/react": "^18",
|
|
120
120
|
"@types/react-dom": "^18",
|
|
121
|
-
"@types/systemjs": "^6
|
|
121
|
+
"@types/systemjs": "^6",
|
|
122
122
|
"@types/uuid": "^9",
|
|
123
123
|
"@umijs/lint": "^4",
|
|
124
124
|
"@vitest/coverage-v8": "latest",
|
package/src/app/layout.tsx
CHANGED
package/src/app/metadata.ts
CHANGED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { useEffect, useState } from 'react';
|
|
2
|
+
|
|
3
|
+
export const useIsPWA = () => {
|
|
4
|
+
const [isPWA, setIsPWA] = useState(false);
|
|
5
|
+
|
|
6
|
+
useEffect(() => {
|
|
7
|
+
const isInStandaloneMode = () =>
|
|
8
|
+
'standalone' in window.navigator && window.navigator['standalone'];
|
|
9
|
+
if (isInStandaloneMode()) {
|
|
10
|
+
setIsPWA(true);
|
|
11
|
+
}
|
|
12
|
+
}, []);
|
|
13
|
+
|
|
14
|
+
return isPWA;
|
|
15
|
+
};
|
package/src/layout/AppLayout.tsx
CHANGED
|
@@ -1,11 +1,19 @@
|
|
|
1
|
+
import { useTheme } from 'antd-style';
|
|
1
2
|
import { PropsWithChildren, memo } from 'react';
|
|
2
3
|
import { Flexbox } from 'react-layout-kit';
|
|
3
4
|
|
|
4
5
|
import SideBar from '@/features/SideBar';
|
|
6
|
+
import { useIsPWA } from '@/hooks/useIsPWA';
|
|
5
7
|
|
|
6
8
|
const AppLayout = memo<PropsWithChildren>(({ children }) => {
|
|
9
|
+
const isPWA = useIsPWA();
|
|
10
|
+
const theme = useTheme();
|
|
7
11
|
return (
|
|
8
|
-
<Flexbox
|
|
12
|
+
<Flexbox
|
|
13
|
+
horizontal
|
|
14
|
+
style={isPWA ? { borderTop: `1px solid ${theme.colorBorder}` } : {}}
|
|
15
|
+
width={'100%'}
|
|
16
|
+
>
|
|
9
17
|
<SideBar />
|
|
10
18
|
{children}
|
|
11
19
|
</Flexbox>
|