@lobehub/chat 0.107.10 → 0.107.11

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,31 @@
2
2
 
3
3
  # Changelog
4
4
 
5
+ ### [Version 0.107.11](https://github.com/lobehub/lobe-chat/compare/v0.107.10...v0.107.11)
6
+
7
+ <sup>Released on **2023-12-01**</sup>
8
+
9
+ #### 🐛 Bug Fixes
10
+
11
+ - **misc**: Fix switch model don't work on mobile.
12
+
13
+ <br/>
14
+
15
+ <details>
16
+ <summary><kbd>Improvements and Fixes</kbd></summary>
17
+
18
+ #### What's fixed
19
+
20
+ - **misc**: Fix switch model don't work on mobile, closes [#541](https://github.com/lobehub/lobe-chat/issues/541) ([609f505](https://github.com/lobehub/lobe-chat/commit/609f505))
21
+
22
+ </details>
23
+
24
+ <div align="right">
25
+
26
+ [![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)
27
+
28
+ </div>
29
+
5
30
  ### [Version 0.107.10](https://github.com/lobehub/lobe-chat/compare/v0.107.9...v0.107.10)
6
31
 
7
32
  <sup>Released on **2023-11-30**</sup>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/chat",
3
- "version": "0.107.10",
3
+ "version": "0.107.11",
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",
@@ -4,18 +4,27 @@ import dynamic from 'next/dynamic';
4
4
  import { memo } from 'react';
5
5
  import { Flexbox } from 'react-layout-kit';
6
6
 
7
+ import { useSessionStore } from '@/store/session';
8
+
7
9
  import Conversation from '../../features/Conversation';
8
10
  import ChatInput from '../features/ChatInput';
9
11
  import Layout from './layout.mobile';
10
12
 
11
13
  const TopicList = dynamic(() => import('../features/TopicList'));
12
14
 
13
- const Chat = memo(() => (
14
- <Layout>
15
- <Flexbox height={'calc(100% - 44px)'} horizontal>
16
- <Conversation chatInput={<ChatInput />} mobile />
17
- <TopicList />
18
- </Flexbox>
19
- </Layout>
20
- ));
15
+ const Chat = memo(() => {
16
+ // due to mobile side don't have sessionList, so we need to fetch sessions here
17
+ // refs: https://github.com/lobehub/lobe-chat/pull/541
18
+ const useFetchSessions = useSessionStore((s) => s.useFetchSessions);
19
+ useFetchSessions();
20
+
21
+ return (
22
+ <Layout>
23
+ <Flexbox height={'calc(100% - 44px)'} horizontal>
24
+ <Conversation chatInput={<ChatInput />} mobile />
25
+ <TopicList />
26
+ </Flexbox>
27
+ </Layout>
28
+ );
29
+ });
21
30
  export default Chat;