@lobehub/chat 1.93.2 → 1.93.3

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.93.3](https://github.com/lobehub/lobe-chat/compare/v1.93.2...v1.93.3)
6
+
7
+ <sup>Released on **2025-06-10**</sup>
8
+
9
+ #### ♻ Code Refactoring
10
+
11
+ - **misc**: Refactor branding info.
12
+
13
+ <br/>
14
+
15
+ <details>
16
+ <summary><kbd>Improvements and Fixes</kbd></summary>
17
+
18
+ #### Code refactoring
19
+
20
+ - **misc**: Refactor branding info, closes [#8134](https://github.com/lobehub/lobe-chat/issues/8134) ([3baa966](https://github.com/lobehub/lobe-chat/commit/3baa966))
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.93.2](https://github.com/lobehub/lobe-chat/compare/v1.93.1...v1.93.2)
6
31
 
7
32
  <sup>Released on **2025-06-09**</sup>
package/changelog/v1.json CHANGED
@@ -1,4 +1,13 @@
1
1
  [
2
+ {
3
+ "children": {
4
+ "improvements": [
5
+ "Refactor branding info."
6
+ ]
7
+ },
8
+ "date": "2025-06-10",
9
+ "version": "1.93.3"
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.93.2",
3
+ "version": "1.93.3",
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",
@@ -7,8 +7,8 @@ import { useTranslation } from 'react-i18next';
7
7
  import { Flexbox } from 'react-layout-kit';
8
8
  import urlJoin from 'url-join';
9
9
 
10
- import { BRANDING_NAME } from '@/const/branding';
11
- import { OFFICIAL_SITE, X } from '@/const/url';
10
+ import { BRANDING_NAME, SOCIAL_URL } from '@/const/branding';
11
+ import { OFFICIAL_SITE } from '@/const/url';
12
12
 
13
13
  import GridLayout from './GridLayout';
14
14
 
@@ -28,7 +28,7 @@ const Hero = memo(() => {
28
28
  {t('actions.versions')}
29
29
  </Link>
30
30
  <div style={{ color: theme.colorInfo }}>·</div>
31
- <Link href={X} target={'_blank'}>
31
+ <Link href={SOCIAL_URL.x} target={'_blank'}>
32
32
  {t('actions.followOnX')}
33
33
  </Link>
34
34
  </Flexbox>
@@ -8,20 +8,8 @@ import { memo } from 'react';
8
8
  import { useTranslation } from 'react-i18next';
9
9
  import { Flexbox } from 'react-layout-kit';
10
10
 
11
- import { BRANDING_NAME } from '@/const/branding';
12
- import {
13
- BLOG,
14
- DISCORD,
15
- EMAIL_BUSINESS,
16
- EMAIL_SUPPORT,
17
- GITHUB,
18
- MEDIDUM,
19
- OFFICIAL_SITE,
20
- PRIVACY_URL,
21
- TERMS_URL,
22
- X,
23
- mailTo,
24
- } from '@/const/url';
11
+ import { BRANDING_EMAIL, BRANDING_NAME, SOCIAL_URL } from '@/const/branding';
12
+ import { BLOG, OFFICIAL_SITE, PRIVACY_URL, TERMS_URL, mailTo } from '@/const/url';
25
13
  import { useServerConfigStore } from '@/store/serverConfig';
26
14
  import { serverConfigSelectors } from '@/store/serverConfig/selectors';
27
15
 
@@ -65,12 +53,12 @@ const Page = memo<{ mobile?: boolean }>(({ mobile }) => {
65
53
  value: 'officialSite',
66
54
  },
67
55
  {
68
- href: mailTo(EMAIL_SUPPORT),
56
+ href: mailTo(BRANDING_EMAIL.support),
69
57
  label: t('mail.support'),
70
58
  value: 'support',
71
59
  },
72
60
  {
73
- href: mailTo(EMAIL_BUSINESS),
61
+ href: mailTo(BRANDING_EMAIL.business),
74
62
  label: t('mail.business'),
75
63
  value: 'business',
76
64
  },
@@ -89,26 +77,26 @@ const Page = memo<{ mobile?: boolean }>(({ mobile }) => {
89
77
  value: 'blog',
90
78
  },
91
79
  {
92
- href: GITHUB,
80
+ href: SOCIAL_URL.github,
93
81
  icon: SiGithub,
94
82
  label: 'GitHub',
95
83
  value: 'feedback',
96
84
  },
97
85
  {
98
- href: DISCORD,
86
+ href: SOCIAL_URL.discord,
99
87
  icon: SiDiscord,
100
88
  label: 'Discord',
101
89
  value: 'discord',
102
90
  },
103
91
  {
104
- href: X,
92
+ href: SOCIAL_URL.x,
105
93
  icon: SiX as any,
106
94
  label: 'X / Twitter',
107
95
  value: 'x',
108
96
  },
109
97
 
110
98
  {
111
- href: MEDIDUM,
99
+ href: SOCIAL_URL.medium,
112
100
  icon: SiMedium,
113
101
  label: 'Medium',
114
102
  value: 'medium',
@@ -14,3 +14,16 @@ export const BRANDING_URL = {
14
14
  privacy: undefined,
15
15
  terms: undefined,
16
16
  };
17
+
18
+ export const SOCIAL_URL = {
19
+ discord: 'https://discord.gg/AYFPHvv2jT',
20
+ github: 'https://github.com/lobehub',
21
+ medium: 'https://medium.com/@lobehub',
22
+ x: 'https://x.com/lobehub',
23
+ youtube: 'https://www.youtube.com/@lobehub',
24
+ };
25
+
26
+ export const BRANDING_EMAIL = {
27
+ business: 'hello@lobehub.com',
28
+ support: 'support@lobehub.com',
29
+ };
@@ -1,10 +1,9 @@
1
1
  import urlJoin from 'url-join';
2
2
 
3
+ import { BRANDING_EMAIL } from '@/const/branding';
3
4
  import {
4
5
  BLOG,
5
6
  DOCKER_IMAGE,
6
- EMAIL_BUSINESS,
7
- EMAIL_SUPPORT,
8
7
  GITHUB,
9
8
  OFFICIAL_PREVIEW_URL,
10
9
  OFFICIAL_SITE,
@@ -70,8 +69,8 @@ In the response, please try to pick and include the relevant links below, and if
70
69
  - Usage Documentation: ${USAGE_DOCUMENTS}
71
70
  - Self-Hosting Documentation: ${SELF_HOSTING_DOCUMENTS}
72
71
  - Development Guide: ${WIKI}
73
- - Email Support: ${EMAIL_SUPPORT}
74
- - Business Inquiries: ${EMAIL_BUSINESS}
72
+ - Email Support: ${BRANDING_EMAIL.support}
73
+ - Business Inquiries: ${BRANDING_EMAIL.business}
75
74
 
76
75
  ## Workflow
77
76
 
package/src/const/url.ts CHANGED
@@ -37,7 +37,6 @@ export const BLOG = urlJoin(OFFICIAL_SITE, 'blog');
37
37
 
38
38
  export const ABOUT = OFFICIAL_SITE;
39
39
  export const FEEDBACK = pkg.bugs.url;
40
- export const DISCORD = 'https://discord.gg/AYFPHvv2jT';
41
40
  export const PRIVACY_URL = urlJoin(OFFICIAL_SITE, '/privacy');
42
41
  export const TERMS_URL = urlJoin(OFFICIAL_SITE, '/terms');
43
42
 
@@ -61,11 +60,7 @@ export const SESSION_CHAT_URL = (id: string = INBOX_SESSION_ID, mobile?: boolean
61
60
  export const imageUrl = (filename: string) => withBasePath(`/images/${filename}`);
62
61
 
63
62
  export const LOBE_URL_IMPORT_NAME = 'settings';
64
- export const EMAIL_SUPPORT = 'support@lobehub.com';
65
- export const EMAIL_BUSINESS = 'hello@lobehub.com';
66
63
 
67
- export const MEDIDUM = 'https://medium.com/@lobehub';
68
- export const X = 'https://x.com/lobehub';
69
64
  export const RELEASES_URL = urlJoin(GITHUB, 'releases');
70
65
 
71
66
  export const mailTo = (email: string) => `mailto:${email}`;
@@ -8,7 +8,8 @@ import { memo } from 'react';
8
8
  import { useTranslation } from 'react-i18next';
9
9
  import { Flexbox } from 'react-layout-kit';
10
10
 
11
- import { DISCORD, GITHUB, MEDIDUM, X } from '@/const/url';
11
+ import { SOCIAL_URL } from '@/const/branding';
12
+ import { GITHUB } from '@/const/url';
12
13
 
13
14
  const useStyles = createStyles(({ css, token }) => {
14
15
  return {
@@ -38,17 +39,17 @@ const Follow = memo(() => {
38
39
  title={t('follow', { name: 'GitHub' })}
39
40
  />
40
41
  </Link>
41
- <Link href={X} rel="noreferrer" target={'_blank'}>
42
+ <Link href={SOCIAL_URL.x} rel="noreferrer" target={'_blank'}>
42
43
  <ActionIcon className={styles.icon} icon={SiX as any} title={t('follow', { name: 'X' })} />
43
44
  </Link>
44
- <Link href={DISCORD} rel="noreferrer" target={'_blank'}>
45
+ <Link href={SOCIAL_URL.discord} rel="noreferrer" target={'_blank'}>
45
46
  <ActionIcon
46
47
  className={styles.icon}
47
48
  icon={SiDiscord as any}
48
49
  title={t('follow', { name: 'Discord' })}
49
50
  />
50
51
  </Link>
51
- <Link href={MEDIDUM} rel="noreferrer" target={'_blank'}>
52
+ <Link href={SOCIAL_URL.medium} rel="noreferrer" target={'_blank'}>
52
53
  <ActionIcon
53
54
  className={styles.icon}
54
55
  icon={SiMedium as any}
@@ -22,13 +22,11 @@ import { Flexbox } from 'react-layout-kit';
22
22
 
23
23
  import type { MenuProps } from '@/components/Menu';
24
24
  import { enableAuth } from '@/const/auth';
25
- import { LOBE_CHAT_CLOUD } from '@/const/branding';
25
+ import { BRANDING_EMAIL, LOBE_CHAT_CLOUD, SOCIAL_URL } from '@/const/branding';
26
26
  import { DEFAULT_HOTKEY_CONFIG } from '@/const/settings';
27
27
  import {
28
28
  CHANGELOG,
29
- DISCORD,
30
29
  DOCUMENTS_REFER_URL,
31
- EMAIL_SUPPORT,
32
30
  GITHUB_ISSUES,
33
31
  OFFICIAL_URL,
34
32
  UTM_SOURCE,
@@ -171,7 +169,7 @@ export const useMenu = () => {
171
169
  icon: <Icon icon={DiscordIcon} />,
172
170
  key: 'discord',
173
171
  label: (
174
- <Link href={DISCORD} target={'_blank'}>
172
+ <Link href={SOCIAL_URL.discord} target={'_blank'}>
175
173
  {t('userPanel.discord')}
176
174
  </Link>
177
175
  ),
@@ -180,7 +178,7 @@ export const useMenu = () => {
180
178
  icon: <Icon icon={Mail} />,
181
179
  key: 'email',
182
180
  label: (
183
- <Link href={mailTo(EMAIL_SUPPORT)} target={'_blank'}>
181
+ <Link href={mailTo(BRANDING_EMAIL.support)} target={'_blank'}>
184
182
  {t('userPanel.email')}
185
183
  </Link>
186
184
  ),
@@ -248,7 +248,11 @@ const transformOpenAIStream = (
248
248
  id: chunk.id,
249
249
  type: 'grounding',
250
250
  },
251
- { data: thinkingContent, id: chunk.id, type: streamContext?.thinkingInContent ? 'reasoning' : 'text' },
251
+ {
252
+ data: thinkingContent,
253
+ id: chunk.id,
254
+ type: streamContext?.thinkingInContent ? 'reasoning' : 'text',
255
+ },
252
256
  ];
253
257
  }
254
258
  }
package/src/server/ld.ts CHANGED
@@ -1,9 +1,9 @@
1
1
  import qs from 'query-string';
2
2
  import urlJoin from 'url-join';
3
3
 
4
- import { BRANDING_NAME } from '@/const/branding';
4
+ import { BRANDING_EMAIL, BRANDING_NAME, SOCIAL_URL } from '@/const/branding';
5
5
  import { DEFAULT_LANG } from '@/const/locale';
6
- import { EMAIL_BUSINESS, EMAIL_SUPPORT, OFFICIAL_SITE, OFFICIAL_URL, X } from '@/const/url';
6
+ import { OFFICIAL_SITE, OFFICIAL_URL } from '@/const/url';
7
7
  import { Locales } from '@/locales/resources';
8
8
  import { getCanonicalUrl } from '@/server/utils/url';
9
9
 
@@ -90,11 +90,11 @@ export class Ld {
90
90
  'contactPoint': {
91
91
  '@type': 'ContactPoint',
92
92
  'contactType': 'customer support',
93
- 'email': EMAIL_SUPPORT,
93
+ 'email': BRANDING_EMAIL.support,
94
94
  },
95
95
  'description':
96
96
  'We are a group of e/acc design-engineers, hoping to provide modern design components and tools for AIGC, and creating a technology-driven forum, fostering knowledge interaction and the exchange of ideas that may culminate in mutual inspiration and collaborative innovation.',
97
- 'email': EMAIL_BUSINESS,
97
+ 'email': BRANDING_EMAIL.business,
98
98
  'founders': [this.getAuthors(['arvinxx']), this.getAuthors(['canisminor'])],
99
99
  'image': urlJoin(OFFICIAL_SITE, '/icon-512x512.png'),
100
100
  'logo': {
@@ -104,12 +104,7 @@ export class Ld {
104
104
  'width': 512,
105
105
  },
106
106
  'name': 'LobeHub',
107
- 'sameAs': [
108
- X,
109
- 'https://github.com/lobehub',
110
- 'https://medium.com/@lobehub',
111
- 'https://www.youtube.com/@lobehub',
112
- ],
107
+ 'sameAs': [SOCIAL_URL.x, SOCIAL_URL.github, SOCIAL_URL.medium, SOCIAL_URL.youtube],
113
108
  'url': OFFICIAL_SITE,
114
109
  };
115
110
  }