@lobehub/chat 1.49.9 → 1.49.10

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 1.49.10](https://github.com/lobehub/lobe-chat/compare/v1.49.9...v1.49.10)
6
+
7
+ <sup>Released on **2025-02-02**</sup>
8
+
9
+ #### 🐛 Bug Fixes
10
+
11
+ - **misc**: Fix `<think>` tag crash with special markdown content.
12
+
13
+ <br/>
14
+
15
+ <details>
16
+ <summary><kbd>Improvements and Fixes</kbd></summary>
17
+
18
+ #### What's fixed
19
+
20
+ - **misc**: Fix `<think>` tag crash with special markdown content, closes [#5670](https://github.com/lobehub/lobe-chat/issues/5670) ([b719522](https://github.com/lobehub/lobe-chat/commit/b719522))
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 1.49.9](https://github.com/lobehub/lobe-chat/compare/v1.49.8...v1.49.9)
6
31
 
7
32
  <sup>Released on **2025-02-01**</sup>
package/changelog/v1.json CHANGED
@@ -1,4 +1,13 @@
1
1
  [
2
+ {
3
+ "children": {
4
+ "fixes": [
5
+ "Fix <think> tag crash with special markdown content."
6
+ ]
7
+ },
8
+ "date": "2025-02-02",
9
+ "version": "1.49.10"
10
+ },
2
11
  {
3
12
  "children": {
4
13
  "improvements": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/chat",
3
- "version": "1.49.9",
3
+ "version": "1.49.10",
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",
@@ -32,7 +32,14 @@ export const createRemarkCustomTagPlugin = (tag: string) => () => {
32
32
 
33
33
  // 转换为 Markdown 字符串
34
34
  const content = contentNodes
35
- .map((n: any) => toMarkdown(n))
35
+ .map((n: any) => {
36
+ // fix https://github.com/lobehub/lobe-chat/issues/5668
37
+ if (n.type === 'paragraph') {
38
+ return n.children.map((child: any) => child.value).join('');
39
+ }
40
+
41
+ return toMarkdown(n);
42
+ })
36
43
  .join('\n\n')
37
44
  .trim();
38
45