@lobehub/chat 0.142.8 → 0.142.9

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.142.9](https://github.com/lobehub/lobe-chat/compare/v0.142.8...v0.142.9)
6
+
7
+ <sup>Released on **2024-03-28**</sup>
8
+
9
+ #### 🐛 Bug Fixes
10
+
11
+ - **misc**: Fix Add agent and Converse button not jump.
12
+
13
+ <br/>
14
+
15
+ <details>
16
+ <summary><kbd>Improvements and Fixes</kbd></summary>
17
+
18
+ #### What's fixed
19
+
20
+ - **misc**: Fix Add agent and Converse button not jump, closes [#1785](https://github.com/lobehub/lobe-chat/issues/1785) ([a52799c](https://github.com/lobehub/lobe-chat/commit/a52799c))
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.142.8](https://github.com/lobehub/lobe-chat/compare/v0.142.7...v0.142.8)
6
31
 
7
32
  <sup>Released on **2024-03-28**</sup>
package/README.md CHANGED
@@ -227,7 +227,7 @@ In addition, these plugins are not limited to news aggregation, but can also ext
227
227
  | [Bilibili](https://chat-preview.lobehub.com/settings/agent)<br/><sup>By **LobeHub** on **2024-01-27**</sup> | Dive into Bilibili's vast content with features like keyword video search, replay access, interactive danmaku, trending video recommendations, and hot-search insights, all at your fingertips.<br/>`video` `bilibili` `search` |
228
228
  | [Steam](https://chat-preview.lobehub.com/settings/agent)<br/><sup>By **LobeHub** on **2024-01-27**</sup> | Obtain game information and user reviews from Steam.<br/>`steam` `game` |
229
229
 
230
- > 📊 Total plugins: [<kbd>**57**</kbd>](https://github.com/lobehub/lobe-chat-plugins)
230
+ > 📊 Total plugins: [<kbd>**55**</kbd>](https://github.com/lobehub/lobe-chat-plugins)
231
231
 
232
232
  <!-- PLUGIN LIST -->
233
233
 
@@ -259,14 +259,14 @@ Our marketplace is not just a showcase platform but also a collaborative space.
259
259
 
260
260
  <!-- AGENT LIST -->
261
261
 
262
- | Recent Submits | Description |
263
- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
264
- | [Girlfriend Subtext Expert](https://chat-preview.lobehub.com/market?agent=girlfriend-subtext)<br/><sup>By **[vayron](https://github.com/vayron)** on **2024-03-26**</sup> | Decipher the 'subtext' behind girls' words, sharp and witty, respond with strength! 🔥<br/>`girlfriend` `girls` `subtext` `fierce` `strong` `decipher` |
265
- | [Interview Question Refinement Assistant](https://chat-preview.lobehub.com/market?agent=question-extraction-assistant)<br/><sup>By **[couldnice](https://github.com/couldnice)** on **2024-03-26**</sup> | Interview question generation assistant, generates targeted interview questions based on article content and job descriptions.<br/>`interview-questions` `customized-service` `java-engineer` `data-collection` `interview-preparation` |
266
- | [Claim Analyzer](https://chat-preview.lobehub.com/market?agent=fact-checking)<br/><sup>By **[pedroespecial101](https://github.com/pedroespecial101)** on **2024-03-25**</sup> | Detailed truth analyzer (from <https://github.com/danielmiessler/fabric>)<br/>`https-github-com-danielmiessler-fabric` |
267
- | [Rap Lyric Master](https://chat-preview.lobehub.com/market?agent=rap-writer)<br/><sup>By **[aoocar](https://github.com/aoocar)** on **2024-03-25**</sup> | Match lyrics in the form of rap lyrics, and create rap lyrics according to the reference format<br/>`rap` `lyrics` |
262
+ | Recent Submits | Description |
263
+ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
264
+ | [Blood Test Analyst](https://chat-preview.lobehub.com/market?agent=blood-analyst)<br/><sup>By **[SimoMay](https://github.com/SimoMay)** on **2024-03-27**</sup> | Skilled in analysing blood test results, providing clear feedback using emojis for easy understanding.<br/>`healthcare` `analysis` `results` `consulting` `summary` |
265
+ | [High EQ Flattery Assistant](https://chat-preview.lobehub.com/market?agent=gpts-big-fart-chat)<br/><sup>By **[MapleEve](https://github.com/MapleEve)** on **2024-03-27**</sup> | An expert in precise chat compliments, providing suitable praise and flattery<br/>`compliments` `eq` `chat` |
266
+ | [Suno.ai Music Creation Assistant](https://chat-preview.lobehub.com/market?agent=suno-music-creator)<br/><sup>By **[MapleEve](https://github.com/MapleEve)** on **2024-03-27**</sup> | Song creation and translation based on SunoAI<br/>`suno` `lyricist` `lyrics` `music-production` |
267
+ | [Image Recognition Xiaohongshu Copywriting](https://chat-preview.lobehub.com/market?agent=xiaonghongshu-vision)<br/><sup>By **[HansKing98](https://github.com/HansKing98)** on **2024-03-27**</sup> | You can use this agent combined with a multimodal model to upload images and generate Xiaohongshu-style copywriting.<br/>`vision` |
268
268
 
269
- > 📊 Total agents: [<kbd>**220**</kbd> ](https://github.com/lobehub/lobe-chat-agents)
269
+ > 📊 Total agents: [<kbd>**224**</kbd> ](https://github.com/lobehub/lobe-chat-agents)
270
270
 
271
271
  <!-- AGENT LIST -->
272
272
 
package/README.zh-CN.md CHANGED
@@ -219,7 +219,7 @@ LobeChat 的插件生态系统是其核心功能的重要扩展,它极大地
219
219
  | [哔哩哔哩](https://chat-preview.lobehub.com/settings/agent)<br/><sup>By **LobeHub** on **2024-01-27**</sup> | 通过关键词视频搜索、回放访问、互动弹幕、热门视频推荐和热搜洞察等功能,深入体验哔哩哔哩丰富的内容,尽在您的指尖。<br/>`视频` `哔哩哔哩` `搜索` |
220
220
  | [Steam](https://chat-preview.lobehub.com/settings/agent)<br/><sup>By **LobeHub** on **2024-01-27**</sup> | 从 Steam 获取游戏信息和用户评论。<br/>`steam` `game` |
221
221
 
222
- > 📊 Total plugins: [<kbd>**57**</kbd>](https://github.com/lobehub/lobe-chat-plugins)
222
+ > 📊 Total plugins: [<kbd>**55**</kbd>](https://github.com/lobehub/lobe-chat-plugins)
223
223
 
224
224
  <!-- PLUGIN LIST -->
225
225
 
@@ -247,14 +247,14 @@ LobeChat 的插件生态系统是其核心功能的重要扩展,它极大地
247
247
 
248
248
  <!-- AGENT LIST -->
249
249
 
250
- | 最近新增 | 助手说明 |
251
- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
252
- | [女朋友潜台词专家](https://chat-preview.lobehub.com/market?agent=girlfriend-subtext)<br/><sup>By **[vayron](https://github.com/vayron)** on **2024-03-26**</sup> | 解读女生话背后的「潜台词」,尖酸刻薄,强势回复!🔥<br/>`女朋友` `女生` `潜台词` `彪悍` `强势` `解读` |
253
- | [面试问题提炼助手](https://chat-preview.lobehub.com/market?agent=question-extraction-assistant)<br/><sup>By **[couldnice](https://github.com/couldnice)** on **2024-03-26**</sup> | 面试问题生成助手,根据文章内容和职位描述生成针对性面试问题。<br/>`面试问题` `定制服务` `java工程师` `资料收集` `面试准备` |
254
- | [索赔分析器](https://chat-preview.lobehub.com/market?agent=fact-checking)<br/><sup>By **[pedroespecial101](https://github.com/pedroespecial101)** on **2024-03-25**</sup> | 详细的真相分析器(来自 <https://github.com/danielmiessler/fabric)><br/>`https-github-com-danielmiessler-fabric` |
255
- | [Rap 说唱歌词大师](https://chat-preview.lobehub.com/market?agent=rap-writer)<br/><sup>By **[aoocar](https://github.com/aoocar)** on **2024-03-25**</sup> | 将歌词以 rap 歌词的形式进行匹配,按照参考格式进行 rap 歌词创作<br/>`说唱` `歌词` |
250
+ | 最近新增 | 助手说明 |
251
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------- |
252
+ | [血液检测分析师](https://chat-preview.lobehub.com/market?agent=blood-analyst)<br/><sup>By **[SimoMay](https://github.com/SimoMay)** on **2024-03-27**</sup> | 擅长分析血液检测结果,使用表情符号提供清晰反馈,便于理解。<br/>`医疗保健` `分析` `结果` `咨询` `摘要` |
253
+ | [高情商马屁助手](https://chat-preview.lobehub.com/market?agent=gpts-big-fart-chat)<br/><sup>By **[MapleEve](https://github.com/MapleEve)** on **2024-03-27**</sup> | 精准的聊天夸赞专家,适宜的赞美和吹捧<br/>`夸赞` `情商` `聊天` |
254
+ | [Suno.ai 音乐创作助手](https://chat-preview.lobehub.com/market?agent=suno-music-creator)<br/><sup>By **[MapleEve](https://github.com/MapleEve)** on **2024-03-27**</sup> | 基于 SunoAI 的歌曲创作与翻译<br/>`suno` `作词` `歌词` `音乐制作` |
255
+ | [识图小红书文案](https://chat-preview.lobehub.com/market?agent=xiaonghongshu-vision)<br/><sup>By **[HansKing98](https://github.com/HansKing98)** on **2024-03-27**</sup> | 你可以用这么 agent 结合多模态的模型,进行上传图片,生成小红书格式文案。<br/>`vision` |
256
256
 
257
- > 📊 Total agents: [<kbd>**220**</kbd> ](https://github.com/lobehub/lobe-chat-agents)
257
+ > 📊 Total agents: [<kbd>**224**</kbd> ](https://github.com/lobehub/lobe-chat-agents)
258
258
 
259
259
  <!-- AGENT LIST -->
260
260
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/chat",
3
- "version": "0.142.8",
3
+ "version": "0.142.9",
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",
@@ -1,10 +1,13 @@
1
1
  import { Avatar, Tag } from '@lobehub/ui';
2
2
  import { App, Button, Typography } from 'antd';
3
3
  import { startCase } from 'lodash-es';
4
+ import { useRouter } from 'next/navigation';
4
5
  import { memo } from 'react';
5
6
  import { useTranslation } from 'react-i18next';
6
7
  import { Center } from 'react-layout-kit';
7
8
 
9
+ import { SESSION_CHAT_URL } from '@/const/url';
10
+ import { useIsMobile } from '@/hooks/useIsMobile';
8
11
  import { agentMarketSelectors, useMarketStore } from '@/store/market';
9
12
  import { useSessionStore } from '@/store/session';
10
13
 
@@ -13,6 +16,7 @@ import { useStyles } from './style';
13
16
  const { Link } = Typography;
14
17
 
15
18
  const Header = memo(() => {
19
+ const router = useRouter();
16
20
  const { t } = useTranslation('market');
17
21
  const { styles, theme } = useStyles();
18
22
  const createSession = useSessionStore((s) => s.createSession);
@@ -22,6 +26,23 @@ const Header = memo(() => {
22
26
  const { meta, createAt, author, homepage, config } = agentItem;
23
27
  const { avatar, title, description, tags, backgroundColor } = meta;
24
28
 
29
+ const isMobile = useIsMobile();
30
+
31
+ const handleAddAgentAndConverse = async () => {
32
+ if (!agentItem) return;
33
+
34
+ const session = await createSession({ config, meta });
35
+ message.success(t('addAgentSuccess'));
36
+ router.push(SESSION_CHAT_URL(session, isMobile));
37
+ };
38
+
39
+ const handleAddAgent = () => {
40
+ if (!agentItem) return;
41
+
42
+ createSession({ config, meta }, false);
43
+ message.success(t('addAgentSuccess'));
44
+ };
45
+
25
46
  return (
26
47
  <Center className={styles.container} gap={16}>
27
48
  <Avatar
@@ -47,26 +68,10 @@ const Header = memo(() => {
47
68
  <Link aria-label={author} className={styles.author} href={homepage} target={'_blank'}>
48
69
  @{author}
49
70
  </Link>
50
- <Button
51
- block
52
- onClick={() => {
53
- if (!agentItem) return;
54
-
55
- createSession({ config, meta });
56
- }}
57
- type={'primary'}
58
- >
71
+ <Button block onClick={handleAddAgentAndConverse} type={'primary'}>
59
72
  {t('addAgentAndConverse')}
60
73
  </Button>
61
- <Button
62
- block
63
- onClick={() => {
64
- if (!agentItem) return;
65
-
66
- createSession({ config, meta }, false);
67
- message.success(t('addAgentSuccess'));
68
- }}
69
- >
74
+ <Button block onClick={handleAddAgent}>
70
75
  {t('addAgent')}
71
76
  </Button>
72
77
  <div className={styles.date}>{createAt}</div>