@lobehub/chat 1.88.6 → 1.88.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 CHANGED
@@ -2,6 +2,33 @@
2
2
 
3
3
  # Changelog
4
4
 
5
+ ### [Version 1.88.7](https://github.com/lobehub/lobe-chat/compare/v1.88.6...v1.88.7)
6
+
7
+ <sup>Released on **2025-05-26**</sup>
8
+
9
+ #### 🐛 Bug Fixes
10
+
11
+ - **DragUpload**: Resolve issue with pasting clipboard images in Safari.
12
+ - **misc**: Fix chat header in the desktop.
13
+
14
+ <br/>
15
+
16
+ <details>
17
+ <summary><kbd>Improvements and Fixes</kbd></summary>
18
+
19
+ #### What's fixed
20
+
21
+ - **DragUpload**: Resolve issue with pasting clipboard images in Safari, closes [#7961](https://github.com/lobehub/lobe-chat/issues/7961) ([3c3cc75](https://github.com/lobehub/lobe-chat/commit/3c3cc75))
22
+ - **misc**: Fix chat header in the desktop, closes [#7973](https://github.com/lobehub/lobe-chat/issues/7973) ([63c3a71](https://github.com/lobehub/lobe-chat/commit/63c3a71))
23
+
24
+ </details>
25
+
26
+ <div align="right">
27
+
28
+ [![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)
29
+
30
+ </div>
31
+
5
32
  ### [Version 1.88.6](https://github.com/lobehub/lobe-chat/compare/v1.88.5...v1.88.6)
6
33
 
7
34
  <sup>Released on **2025-05-25**</sup>
package/changelog/v1.json CHANGED
@@ -1,4 +1,13 @@
1
1
  [
2
+ {
3
+ "children": {
4
+ "fixes": [
5
+ "Fix chat header in the desktop."
6
+ ]
7
+ },
8
+ "date": "2025-05-26",
9
+ "version": "1.88.7"
10
+ },
2
11
  {
3
12
  "children": {
4
13
  "fixes": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/chat",
3
- "version": "1.88.6",
3
+ "version": "1.88.7",
4
4
  "description": "Lobe Chat - an open-source, high-performance chatbot framework that supports speech synthesis, multimodal, and extensible Function Call plugin system. Supports one-click free deployment of your private ChatGPT/LLM web application.",
5
5
  "keywords": [
6
6
  "framework",
@@ -5,10 +5,21 @@ import { ChatHeader } from '@lobehub/ui/chat';
5
5
  import { useGlobalStore } from '@/store/global';
6
6
  import { systemStatusSelectors } from '@/store/global/selectors';
7
7
 
8
+ import HeaderAction from './HeaderAction';
9
+ import Main from './Main';
10
+
8
11
  const Header = () => {
9
12
  const showHeader = useGlobalStore(systemStatusSelectors.showChatHeader);
10
13
 
11
- return showHeader && <ChatHeader style={{ paddingInline: 8, position: 'initial', zIndex: 11 }} />;
14
+ return (
15
+ showHeader && (
16
+ <ChatHeader
17
+ left={<Main />}
18
+ right={<HeaderAction />}
19
+ style={{ paddingInline: 8, position: 'initial', zIndex: 11 }}
20
+ />
21
+ )
22
+ );
12
23
  };
13
24
 
14
25
  export default Header;
@@ -37,18 +37,22 @@ const getFileListFromDataTransferItems = async (items: DataTransferItem[]) => {
37
37
  const filePromises: Promise<File[]>[] = [];
38
38
  for (const item of items) {
39
39
  if (item.kind === 'file') {
40
- const entry = item.webkitGetAsEntry();
41
- if (entry) {
42
- filePromises.push(processEntry(entry));
40
+ // Safari browser may throw error when using FileSystemFileEntry.file()
41
+ // So we prioritize using getAsFile() method first for better browser compatibility
42
+ const file = item.getAsFile();
43
+
44
+ if (file) {
45
+ filePromises.push(
46
+ new Promise((resolve) => {
47
+ resolve([file]);
48
+ }),
49
+ );
43
50
  } else {
44
- const file = item.getAsFile();
45
-
46
- if (file)
47
- filePromises.push(
48
- new Promise((resolve) => {
49
- resolve([file]);
50
- }),
51
- );
51
+ const entry = item.webkitGetAsEntry();
52
+
53
+ if (entry) {
54
+ filePromises.push(processEntry(entry));
55
+ }
52
56
  }
53
57
  }
54
58
  }