@lobehub/chat 0.84.0-beta.2 → 0.85.0
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/.github/workflows/lighthouse-badger-advanced.yml +74 -0
- package/.github/workflows/pre-welcome.yml +22 -0
- package/.github/workflows/release.yml +0 -3
- package/.github/workflows/sync.yml +11 -2
- package/.i18nrc.js +1 -2
- package/.releaserc.js +1 -14
- package/CHANGELOG.md +47 -10
- package/README.md +21 -0
- package/README.zh-CN.md +21 -0
- package/docs/Home.md +1 -0
- package/docs/Lighthouse.md +65 -0
- package/docs/Lighthouse.zh-CN.md +65 -0
- package/docs/_Sidebar.md +1 -0
- package/locales/en_US/common.json +5 -0
- package/locales/ja_JP/common.json +103 -0
- package/locales/ja_JP/empty.json +6 -0
- package/locales/ja_JP/error.json +42 -0
- package/locales/ja_JP/market.json +16 -0
- package/locales/ja_JP/plugin.json +107 -0
- package/locales/ja_JP/setting.json +225 -0
- package/locales/ja_JP/welcome.json +14 -0
- package/locales/ko_KR/common.json +103 -0
- package/locales/ko_KR/empty.json +6 -0
- package/locales/ko_KR/error.json +42 -0
- package/locales/ko_KR/market.json +16 -0
- package/locales/ko_KR/plugin.json +107 -0
- package/locales/ko_KR/setting.json +225 -0
- package/locales/ko_KR/welcome.json +14 -0
- package/locales/ru_RU/common.json +5 -0
- package/locales/zh_CN/common.json +5 -0
- package/locales/zh_TW/common.json +5 -0
- package/next.config.mjs +0 -3
- package/package.json +4 -4
- package/public/icons/maskable-icon-192x192.png +0 -0
- package/public/icons/maskable-icon-512x512.png +0 -0
- package/public/manifest.json +34 -5
- package/public/screenshots/screenshot-1.png +0 -0
- package/public/screenshots/screenshot-2.png +0 -0
- package/public/screenshots/screenshot-3.png +0 -0
- package/public/screenshots/screenshot-4.png +0 -0
- package/src/app/chat/(desktop)/features/{ChatHeader/Desktop.tsx → ChatHeader.tsx} +2 -2
- package/src/app/chat/(desktop)/features/{ChatInput/Desktop.tsx → ChatInput.tsx} +5 -7
- package/src/app/chat/(desktop)/features/{SessionHeader/Desktop.tsx → SessionHeader.tsx} +1 -1
- package/src/app/chat/(desktop)/features/{SessionList/Desktop.tsx → SessionList.tsx} +5 -4
- package/src/app/chat/(desktop)/features/{SideBar/Desktop.tsx → SideBar.tsx} +5 -4
- package/src/app/chat/(desktop)/index.tsx +14 -8
- package/src/app/chat/(desktop)/{layout/Desktop.tsx → layout.desktop.tsx} +7 -8
- package/src/app/chat/(desktop)/layout.responsive.tsx +12 -0
- package/src/app/chat/(mobile)/features/ChatHeader.tsx +54 -1
- package/src/app/chat/(mobile)/features/ChatInput.tsx +28 -8
- package/src/app/chat/(mobile)/features/SessionList.tsx +13 -8
- package/src/app/chat/{components/Inspector/Mobile.tsx → (mobile)/features/TopicList.tsx} +6 -4
- package/src/app/chat/(mobile)/index.tsx +3 -5
- package/src/app/chat/(mobile)/layout.mobile.tsx +17 -0
- package/src/app/chat/(mobile)/mobile/index.tsx +19 -0
- package/src/app/chat/(mobile)/mobile/layout.mobile.tsx +11 -0
- package/src/app/chat/(mobile)/mobile/page.tsx +2 -20
- package/src/app/chat/{components → features}/ChatHeader/ShareButton/Preview.tsx +25 -9
- package/src/app/chat/{components → features}/ChatHeader/ShareButton/style.ts +7 -7
- package/src/app/chat/{components/ChatInput → features/ChatInputContent}/Footer/SaveTopic.tsx +1 -1
- package/src/app/chat/{components/ChatInput → features/ChatInputContent}/index.tsx +3 -1
- package/src/app/chat/{components/SessionList → features/SessionListContent}/Inbox/index.tsx +7 -5
- package/src/app/chat/{components/SessionList → features/SessionListContent}/index.tsx +3 -1
- package/src/app/chat/{components/Inspector → features/TopicListContent}/index.tsx +3 -1
- package/src/app/chat/page.tsx +3 -1
- package/src/app/chat/settings/(desktop)/index.tsx +14 -0
- package/src/app/chat/settings/(desktop)/layout.desktop.tsx +10 -15
- package/src/app/chat/settings/(desktop)/layout.responsive.tsx +12 -0
- package/src/app/chat/settings/(mobile)/index.tsx +14 -0
- package/src/app/chat/settings/(mobile)/layout.mobile.tsx +4 -8
- package/src/app/chat/settings/features/EditPage.tsx +38 -0
- package/src/app/chat/settings/page.tsx +9 -33
- package/src/app/market/(desktop)/{AgentDetail/Desktop.tsx → features/AgentDetail.tsx} +5 -3
- package/src/app/market/(desktop)/index.tsx +12 -0
- package/src/app/market/(desktop)/{layout/Desktop.tsx → layout.desktop.tsx} +5 -5
- package/src/app/market/(desktop)/layout.responsive.tsx +16 -0
- package/src/app/market/{components/AgentDetail/Mobile.tsx → (mobile)/features/AgentDetail.tsx} +6 -4
- package/src/app/market/(mobile)/index.tsx +12 -0
- package/src/app/market/(mobile)/layout.mobile.tsx +5 -5
- package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/Header.tsx +1 -0
- package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/index.tsx +3 -1
- package/src/app/market/features/TagList/index.tsx +2 -1
- package/src/app/market/page.tsx +8 -5
- package/src/app/settings/{features/Header/Desktop.tsx → (desktop)/features/Header.tsx} +2 -2
- package/src/app/settings/(desktop)/index.tsx +17 -0
- package/src/app/settings/{layout.desktop/Desktop.tsx → (desktop)/layout.desktop.tsx} +10 -9
- package/src/app/settings/(desktop)/layout.responsive.tsx +14 -0
- package/src/app/settings/{mobile → (mobile)/features}/ExtraList.tsx +1 -1
- package/src/app/settings/(mobile)/features/Header/Home.tsx +8 -0
- package/src/app/settings/{features/Header/Mobile.tsx → (mobile)/features/Header/index.tsx} +1 -0
- package/src/app/settings/(mobile)/index.tsx +3 -0
- package/src/app/settings/(mobile)/layout.mobile.tsx +19 -0
- package/src/app/settings/{mobile → (mobile)/mobile}/index.tsx +9 -9
- package/src/app/settings/(mobile)/mobile/layout.mobile.tsx +14 -0
- package/src/app/settings/agent/Agent.tsx +30 -0
- package/src/app/settings/agent/index.tsx +23 -0
- package/src/app/settings/agent/layout.tsx +1 -0
- package/src/app/settings/agent/page.tsx +2 -31
- package/src/app/settings/common/index.tsx +23 -0
- package/src/app/settings/common/layout.tsx +1 -0
- package/src/app/settings/common/page.tsx +2 -14
- package/src/app/settings/features/SideBar/index.tsx +2 -0
- package/src/app/settings/features/UpgradeAlert.tsx +32 -0
- package/src/app/settings/layout.server.tsx +12 -0
- package/src/app/settings/llm/index.tsx +23 -0
- package/src/app/settings/llm/layout.tsx +1 -0
- package/src/app/settings/llm/page.tsx +2 -14
- package/src/app/settings/page.tsx +14 -1
- package/src/app/welcome/{features/Footer/index.tsx → (desktop)/features/Footer.tsx} +14 -3
- package/src/app/welcome/(desktop)/features/Showcase.tsx +23 -0
- package/src/app/welcome/(desktop)/index.tsx +19 -0
- package/src/app/welcome/{DesktopLayout/Desktop.tsx → (desktop)/layout.desktop.tsx} +5 -8
- package/src/app/welcome/(desktop)/layout.responsive.tsx +14 -0
- package/src/app/welcome/(mobile)/features/Header.tsx +6 -0
- package/src/app/welcome/(mobile)/features/Showcase.tsx +16 -0
- package/src/app/welcome/(mobile)/index.tsx +10 -0
- package/src/app/welcome/(mobile)/layout.mobile.tsx +20 -0
- package/src/app/welcome/features/Banner/Hero.tsx +2 -3
- package/src/app/welcome/features/Banner/index.tsx +34 -31
- package/src/app/welcome/features/Banner/style.ts +10 -1
- package/src/app/welcome/page.tsx +9 -7
- package/src/components/ResponsiveIndex.tsx +17 -0
- package/src/const/url.ts +2 -1
- package/src/const/version.ts +6 -0
- package/src/features/MobileTabBar/index.tsx +1 -1
- package/src/features/SideBar/BottomActions.tsx +107 -81
- package/src/layout/{AppLayout.tsx → AppLayout.desktop.tsx} +2 -2
- package/src/layout/{AppMobileLayout.tsx → AppLayout.mobile.tsx} +2 -2
- package/src/layout/GlobalLayout/AppTheme.tsx +3 -3
- package/src/layout/GlobalLayout/Locale.tsx +2 -2
- package/src/layout/GlobalLayout/StoreHydration.tsx +15 -1
- package/src/layout/ResponsiveLayout.client.tsx +18 -0
- package/src/{components/ResponsiveLayout.tsx → layout/ResponsiveLayout.server.tsx} +4 -3
- package/src/locales/default/common.ts +5 -0
- package/src/locales/options.ts +8 -1
- package/src/locales/resources/index.ts +4 -0
- package/src/locales/resources/ja_JP.ts +19 -0
- package/src/locales/resources/ko_KR.ts +19 -0
- package/src/services/latestVersion.ts +11 -1
- package/src/store/global/initialState.ts +11 -9
- package/src/store/global/slices/common.ts +12 -0
- package/src/store/session/slices/session/initialState.ts +2 -2
- package/src/utils/VersionController.ts +1 -1
- package/src/utils/responsive.ts +1 -1
- package/.dockerignore +0 -10
- package/Dockerfile +0 -47
- package/src/app/chat/(desktop)/features/ChatHeader/index.tsx +0 -14
- package/src/app/chat/(desktop)/features/ChatInput/index.tsx +0 -22
- package/src/app/chat/(desktop)/features/SessionHeader/index.tsx +0 -14
- package/src/app/chat/(desktop)/features/SessionList/index.tsx +0 -20
- package/src/app/chat/(desktop)/features/SideBar/index.tsx +0 -20
- package/src/app/chat/(desktop)/layout/index.tsx +0 -25
- package/src/app/chat/(mobile)/features/Topics.tsx +0 -12
- package/src/app/chat/(mobile)/layout.tsx +0 -15
- package/src/app/chat/components/ChatHeader/Mobile.tsx +0 -54
- package/src/app/chat/components/ChatInput/Mobile.tsx +0 -35
- package/src/app/chat/components/SessionList/Mobile.tsx +0 -16
- package/src/app/chat/layout.tsx +0 -15
- package/src/app/chat/settings/layout.tsx +0 -14
- package/src/app/market/(desktop)/AgentDetail/index.tsx +0 -16
- package/src/app/market/(desktop)/Header/index.tsx +0 -13
- package/src/app/market/(desktop)/layout/index.tsx +0 -17
- package/src/app/market/(mobile)/AgentDetail.tsx +0 -12
- package/src/app/market/layout.tsx +0 -13
- package/src/app/settings/features/Header/index.tsx +0 -14
- package/src/app/settings/layout.desktop/index.tsx +0 -32
- package/src/app/settings/layout.mobile.tsx +0 -16
- package/src/app/settings/layout.tsx +0 -15
- package/src/app/settings/mobile/page.tsx +0 -7
- package/src/app/welcome/DesktopLayout/index.tsx +0 -15
- package/src/app/welcome/MobileLayout.tsx +0 -23
- package/src/app/welcome/layout.tsx +0 -22
- /package/src/app/chat/{components → features}/ChatHeader/PluginTag/PluginStatus.tsx +0 -0
- /package/src/app/chat/{components → features}/ChatHeader/PluginTag/index.tsx +0 -0
- /package/src/app/chat/{components → features}/ChatHeader/ShareButton/Inner.tsx +0 -0
- /package/src/app/chat/{components → features}/ChatHeader/ShareButton/index.tsx +0 -0
- /package/src/app/chat/{components/ChatInput → features/ChatInputContent}/ActionBar/ActionLeft.tsx +0 -0
- /package/src/app/chat/{components/ChatInput → features/ChatInputContent}/ActionBar/ActionRight.tsx +0 -0
- /package/src/app/chat/{components/ChatInput → features/ChatInputContent}/ActionBar/Token.tsx +0 -0
- /package/src/app/chat/{components/ChatInput → features/ChatInputContent}/Footer/index.tsx +0 -0
- /package/src/app/chat/features/{PageTitle.tsx → PageTitle/index.tsx} +0 -0
- /package/src/app/chat/{components/SessionList → features/SessionListContent}/CollapseGroup/index.tsx +0 -0
- /package/src/app/chat/{components/SessionList → features/SessionListContent}/List/AddButton.tsx +0 -0
- /package/src/app/chat/{components/SessionList → features/SessionListContent}/List/Item/Actions.tsx +0 -0
- /package/src/app/chat/{components/SessionList → features/SessionListContent}/List/Item/index.tsx +0 -0
- /package/src/app/chat/{components/SessionList → features/SessionListContent}/List/SkeletonList.tsx +0 -0
- /package/src/app/chat/{components/SessionList → features/SessionListContent}/List/index.tsx +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/SystemRole/Header.tsx +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/SystemRole/index.tsx +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/SystemRole/style.ts +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/DefaultContent.tsx +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/SkeletonList.tsx +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/TopicContent.tsx +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/TopicItem.tsx +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/index.tsx +0 -0
- /package/src/app/chat/{components/Inspector → features/TopicListContent}/TopicSearchBar/index.tsx +0 -0
- /package/src/app/market/(desktop)/{Header/Desktop.tsx → features/Header.tsx} +0 -0
- /package/src/app/market/(mobile)/{Header.tsx → features/Header.tsx} +0 -0
- /package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/Comment.tsx +0 -0
- /package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/Loading.tsx +0 -0
- /package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/TokenTag.tsx +0 -0
- /package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/index.tsx +0 -0
- /package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/style.ts +0 -0
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { useResponsive } from 'antd-style';
|
|
2
|
-
import { memo } from 'react';
|
|
3
|
-
|
|
4
|
-
import { SessionListContent } from '../../../components/SessionList';
|
|
5
|
-
import Mobile from '../../../components/SessionList/Mobile';
|
|
6
|
-
import Desktop from './Desktop';
|
|
7
|
-
|
|
8
|
-
const ResponsiveSessionList = memo(() => {
|
|
9
|
-
const { mobile } = useResponsive();
|
|
10
|
-
|
|
11
|
-
const Wrapper = mobile ? Mobile : Desktop;
|
|
12
|
-
|
|
13
|
-
return (
|
|
14
|
-
<Wrapper>
|
|
15
|
-
<SessionListContent />
|
|
16
|
-
</Wrapper>
|
|
17
|
-
);
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
export default ResponsiveSessionList;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { useResponsive } from 'antd-style';
|
|
2
|
-
import { memo } from 'react';
|
|
3
|
-
|
|
4
|
-
import { InspectorContent } from '../../../components/Inspector';
|
|
5
|
-
import Mobile from '../../../components/Inspector/Mobile';
|
|
6
|
-
import Desktop from './Desktop';
|
|
7
|
-
|
|
8
|
-
const SideBar = memo(() => {
|
|
9
|
-
const { mobile } = useResponsive();
|
|
10
|
-
|
|
11
|
-
const Render = mobile ? Mobile : Desktop;
|
|
12
|
-
|
|
13
|
-
return (
|
|
14
|
-
<Render>
|
|
15
|
-
<InspectorContent />
|
|
16
|
-
</Render>
|
|
17
|
-
);
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
export default SideBar;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import { useResponsive } from 'antd-style';
|
|
4
|
-
import { PropsWithChildren, memo } from 'react';
|
|
5
|
-
|
|
6
|
-
import { useEffectAfterSessionHydrated } from '@/store/session/hooks';
|
|
7
|
-
|
|
8
|
-
import MobileLayout from '../../(mobile)/layout';
|
|
9
|
-
import DesktopLayout from './Desktop';
|
|
10
|
-
|
|
11
|
-
const Chat = memo<PropsWithChildren>(({ children }) => {
|
|
12
|
-
const { mobile } = useResponsive();
|
|
13
|
-
|
|
14
|
-
const RenderLayout = mobile ? MobileLayout : DesktopLayout;
|
|
15
|
-
|
|
16
|
-
useEffectAfterSessionHydrated(
|
|
17
|
-
(store) => {
|
|
18
|
-
store.setState({ isMobile: mobile });
|
|
19
|
-
},
|
|
20
|
-
[mobile],
|
|
21
|
-
);
|
|
22
|
-
|
|
23
|
-
return <RenderLayout>{children}</RenderLayout>;
|
|
24
|
-
});
|
|
25
|
-
export default Chat;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { memo } from 'react';
|
|
2
|
-
|
|
3
|
-
import { InspectorContent } from '../../components/Inspector';
|
|
4
|
-
import Mobile from '../../components/Inspector/Mobile';
|
|
5
|
-
|
|
6
|
-
const Topics = memo(() => (
|
|
7
|
-
<Mobile>
|
|
8
|
-
<InspectorContent />
|
|
9
|
-
</Mobile>
|
|
10
|
-
));
|
|
11
|
-
|
|
12
|
-
export default Topics;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import { PropsWithChildren, memo } from 'react';
|
|
4
|
-
|
|
5
|
-
import { useEffectAfterSessionHydrated } from '@/store/session';
|
|
6
|
-
|
|
7
|
-
const ChatMobileLayout = memo<PropsWithChildren>(({ children }) => {
|
|
8
|
-
useEffectAfterSessionHydrated((store) => {
|
|
9
|
-
store.setState({ isMobile: true });
|
|
10
|
-
}, []);
|
|
11
|
-
|
|
12
|
-
return children;
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
export default ChatMobileLayout;
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { ActionIcon, MobileNavBar, MobileNavBarTitle } from '@lobehub/ui';
|
|
2
|
-
import { LayoutList, Settings } from 'lucide-react';
|
|
3
|
-
import { useRouter } from 'next/navigation';
|
|
4
|
-
import { memo } from 'react';
|
|
5
|
-
import { useTranslation } from 'react-i18next';
|
|
6
|
-
|
|
7
|
-
import { MOBILE_HEADER_ICON_SIZE } from '@/const/layoutTokens';
|
|
8
|
-
import { useGlobalStore } from '@/store/global';
|
|
9
|
-
import { useSessionStore } from '@/store/session';
|
|
10
|
-
import { agentSelectors, sessionSelectors } from '@/store/session/selectors';
|
|
11
|
-
import { pathString } from '@/utils/url';
|
|
12
|
-
|
|
13
|
-
import ShareButton from './ShareButton';
|
|
14
|
-
|
|
15
|
-
const MobileHeader = memo(() => {
|
|
16
|
-
const { t } = useTranslation('common');
|
|
17
|
-
const router = useRouter();
|
|
18
|
-
|
|
19
|
-
const [isInbox, title] = useSessionStore((s) => [
|
|
20
|
-
sessionSelectors.isInboxSession(s),
|
|
21
|
-
agentSelectors.currentAgentTitle(s),
|
|
22
|
-
]);
|
|
23
|
-
|
|
24
|
-
const [toggleConfig] = useGlobalStore((s) => [s.toggleMobileTopic]);
|
|
25
|
-
|
|
26
|
-
const displayTitle = isInbox ? t('inbox.title') : title;
|
|
27
|
-
|
|
28
|
-
return (
|
|
29
|
-
<MobileNavBar
|
|
30
|
-
center={<MobileNavBarTitle title={displayTitle} />}
|
|
31
|
-
onBackClick={() => router.push('/chat')}
|
|
32
|
-
right={
|
|
33
|
-
<>
|
|
34
|
-
<ShareButton />
|
|
35
|
-
<ActionIcon
|
|
36
|
-
icon={LayoutList}
|
|
37
|
-
onClick={() => toggleConfig()}
|
|
38
|
-
size={MOBILE_HEADER_ICON_SIZE}
|
|
39
|
-
/>
|
|
40
|
-
{!isInbox && (
|
|
41
|
-
<ActionIcon
|
|
42
|
-
icon={Settings}
|
|
43
|
-
onClick={() => router.push(pathString('/chat/settings', { hash: location.hash }))}
|
|
44
|
-
size={MOBILE_HEADER_ICON_SIZE}
|
|
45
|
-
/>
|
|
46
|
-
)}
|
|
47
|
-
</>
|
|
48
|
-
}
|
|
49
|
-
showBackButton
|
|
50
|
-
/>
|
|
51
|
-
);
|
|
52
|
-
});
|
|
53
|
-
|
|
54
|
-
export default MobileHeader;
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { createStyles } from 'antd-style';
|
|
2
|
-
import { ReactNode, memo } from 'react';
|
|
3
|
-
|
|
4
|
-
import SafeSpacing from '@/components/SafeSpacing';
|
|
5
|
-
import { CHAT_TEXTAREA_HEIGHT_MOBILE } from '@/const/layoutTokens';
|
|
6
|
-
|
|
7
|
-
const useStyles = createStyles(
|
|
8
|
-
({ css, token }) => css`
|
|
9
|
-
position: fixed;
|
|
10
|
-
right: 0;
|
|
11
|
-
bottom: 0;
|
|
12
|
-
left: 0;
|
|
13
|
-
|
|
14
|
-
width: 100vw;
|
|
15
|
-
|
|
16
|
-
background: ${token.colorBgLayout};
|
|
17
|
-
`,
|
|
18
|
-
);
|
|
19
|
-
|
|
20
|
-
interface ChatInputMobileLayoutProps {
|
|
21
|
-
children: ReactNode;
|
|
22
|
-
expand?: boolean;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
const ChatInputMobileLayout = memo<ChatInputMobileLayoutProps>(({ children }) => {
|
|
26
|
-
const { styles } = useStyles();
|
|
27
|
-
return (
|
|
28
|
-
<>
|
|
29
|
-
<SafeSpacing height={CHAT_TEXTAREA_HEIGHT_MOBILE} mobile position={'bottom'} />
|
|
30
|
-
<div className={styles}>{children}</div>
|
|
31
|
-
</>
|
|
32
|
-
);
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
export default ChatInputMobileLayout;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { ReactNode, memo } from 'react';
|
|
2
|
-
|
|
3
|
-
import SessionSearchBar from '../../features/SessionSearchBar';
|
|
4
|
-
|
|
5
|
-
const Sessions = memo<{ children: ReactNode }>(({ children }) => {
|
|
6
|
-
return (
|
|
7
|
-
<>
|
|
8
|
-
<div style={{ padding: '8px 16px' }}>
|
|
9
|
-
<SessionSearchBar />
|
|
10
|
-
</div>
|
|
11
|
-
{children}
|
|
12
|
-
</>
|
|
13
|
-
);
|
|
14
|
-
});
|
|
15
|
-
|
|
16
|
-
export default Sessions;
|
package/src/app/chat/layout.tsx
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
2
|
-
|
|
3
|
-
import ResponsiveLayout from '@/components/ResponsiveLayout';
|
|
4
|
-
import { isMobileDevice } from '@/utils/responsive';
|
|
5
|
-
|
|
6
|
-
import Desktop from './(desktop)/layout';
|
|
7
|
-
import Mobile from './(mobile)/layout';
|
|
8
|
-
|
|
9
|
-
const Layout = ({ children }: PropsWithChildren) => (
|
|
10
|
-
<ResponsiveLayout Desktop={Desktop} Mobile={Mobile} isMobile={isMobileDevice}>
|
|
11
|
-
{children}
|
|
12
|
-
</ResponsiveLayout>
|
|
13
|
-
);
|
|
14
|
-
|
|
15
|
-
export default Layout;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
2
|
-
|
|
3
|
-
import { isMobileDevice } from '@/utils/responsive';
|
|
4
|
-
|
|
5
|
-
import Desktop from './(desktop)/layout.desktop';
|
|
6
|
-
import Mobile from './(mobile)/layout.mobile';
|
|
7
|
-
|
|
8
|
-
const Layout = ({ children }: PropsWithChildren) => {
|
|
9
|
-
const mobile = isMobileDevice();
|
|
10
|
-
|
|
11
|
-
return mobile ? <Mobile>{children}</Mobile> : <Desktop>{children}</Desktop>;
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
export default Layout;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { memo } from 'react';
|
|
2
|
-
|
|
3
|
-
import Mobile from '@/app/market/components/AgentDetail/Mobile';
|
|
4
|
-
import ResponsiveLayout from '@/components/ResponsiveLayout';
|
|
5
|
-
import { useIsMobile } from '@/hooks/useIsMobile';
|
|
6
|
-
|
|
7
|
-
import { AgentDetailContent } from '../../components/AgentDetail';
|
|
8
|
-
import Desktop from './Desktop';
|
|
9
|
-
|
|
10
|
-
const AgentDetail = memo(() => (
|
|
11
|
-
<ResponsiveLayout Desktop={Desktop} Mobile={Mobile} isMobile={useIsMobile}>
|
|
12
|
-
<AgentDetailContent />
|
|
13
|
-
</ResponsiveLayout>
|
|
14
|
-
));
|
|
15
|
-
|
|
16
|
-
export default AgentDetail;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { memo } from 'react';
|
|
2
|
-
|
|
3
|
-
import ResponsiveLayout from '@/components/ResponsiveLayout';
|
|
4
|
-
import { useIsMobile } from '@/hooks/useIsMobile';
|
|
5
|
-
|
|
6
|
-
import Mobile from '../../(mobile)/Header';
|
|
7
|
-
import Desktop from './Desktop';
|
|
8
|
-
|
|
9
|
-
const Header = memo(() => (
|
|
10
|
-
<ResponsiveLayout Desktop={Desktop} Mobile={Mobile} isMobile={useIsMobile} />
|
|
11
|
-
));
|
|
12
|
-
|
|
13
|
-
export default Header;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import { PropsWithChildren } from 'react';
|
|
4
|
-
|
|
5
|
-
import ResponsiveLayout from '@/components/ResponsiveLayout';
|
|
6
|
-
import { useIsMobile } from '@/hooks/useIsMobile';
|
|
7
|
-
|
|
8
|
-
import Mobile from '../../(mobile)/layout.mobile';
|
|
9
|
-
import Desktop from './Desktop';
|
|
10
|
-
|
|
11
|
-
const Market = ({ children }: PropsWithChildren) => (
|
|
12
|
-
<ResponsiveLayout Desktop={Desktop} Mobile={Mobile} isMobile={useIsMobile}>
|
|
13
|
-
{children}
|
|
14
|
-
</ResponsiveLayout>
|
|
15
|
-
);
|
|
16
|
-
|
|
17
|
-
export default Market;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { memo } from 'react';
|
|
2
|
-
|
|
3
|
-
import { AgentDetailContent } from '../components/AgentDetail';
|
|
4
|
-
import Mobile from '../components/AgentDetail/Mobile';
|
|
5
|
-
|
|
6
|
-
const AgentDetail = memo(() => (
|
|
7
|
-
<Mobile>
|
|
8
|
-
<AgentDetailContent />
|
|
9
|
-
</Mobile>
|
|
10
|
-
));
|
|
11
|
-
|
|
12
|
-
export default AgentDetail;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
2
|
-
|
|
3
|
-
import ResponsiveLayout from '@/components/ResponsiveLayout';
|
|
4
|
-
import { isMobileDevice } from '@/utils/responsive';
|
|
5
|
-
|
|
6
|
-
import Desktop from './(desktop)/layout';
|
|
7
|
-
import Mobile from './(mobile)/layout.mobile';
|
|
8
|
-
|
|
9
|
-
export default ({ children }: PropsWithChildren) => (
|
|
10
|
-
<ResponsiveLayout Desktop={Desktop} Mobile={Mobile} isMobile={isMobileDevice}>
|
|
11
|
-
{children}
|
|
12
|
-
</ResponsiveLayout>
|
|
13
|
-
);
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { useResponsive } from 'antd-style';
|
|
2
|
-
import { memo } from 'react';
|
|
3
|
-
|
|
4
|
-
import Desktop from './Desktop';
|
|
5
|
-
import Mobile from './Mobile';
|
|
6
|
-
|
|
7
|
-
const Header = memo(() => {
|
|
8
|
-
const { mobile } = useResponsive();
|
|
9
|
-
const Render = mobile ? Mobile : Desktop;
|
|
10
|
-
|
|
11
|
-
return <Render />;
|
|
12
|
-
});
|
|
13
|
-
|
|
14
|
-
export default Header;
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import { PropsWithChildren } from 'react';
|
|
4
|
-
import { useTranslation } from 'react-i18next';
|
|
5
|
-
|
|
6
|
-
import PageTitle from '@/components/PageTitle';
|
|
7
|
-
import ResponsiveLayout from '@/components/ResponsiveLayout';
|
|
8
|
-
import { useIsMobile } from '@/hooks/useIsMobile';
|
|
9
|
-
import { useSwitchSideBarOnInit } from '@/store/global';
|
|
10
|
-
import { SidebarTabKey } from '@/store/global/initialState';
|
|
11
|
-
import { genSiteHeadTitle } from '@/utils/genSiteHeadTitle';
|
|
12
|
-
|
|
13
|
-
import MobileLayout from '../layout.mobile';
|
|
14
|
-
import DesktopLayout from './Desktop';
|
|
15
|
-
|
|
16
|
-
const Setting = ({ children }: PropsWithChildren) => {
|
|
17
|
-
const { t } = useTranslation('setting');
|
|
18
|
-
const pageTitle = genSiteHeadTitle(t('header.global'));
|
|
19
|
-
|
|
20
|
-
useSwitchSideBarOnInit(SidebarTabKey.Setting);
|
|
21
|
-
|
|
22
|
-
return (
|
|
23
|
-
<>
|
|
24
|
-
<PageTitle title={pageTitle} />
|
|
25
|
-
<ResponsiveLayout Desktop={DesktopLayout} Mobile={MobileLayout} isMobile={useIsMobile}>
|
|
26
|
-
{children}
|
|
27
|
-
</ResponsiveLayout>
|
|
28
|
-
</>
|
|
29
|
-
);
|
|
30
|
-
};
|
|
31
|
-
|
|
32
|
-
export default Setting;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import { PropsWithChildren } from 'react';
|
|
4
|
-
import { Flexbox } from 'react-layout-kit';
|
|
5
|
-
|
|
6
|
-
import AppMobileLayout from '@/layout/AppMobileLayout';
|
|
7
|
-
|
|
8
|
-
import Header from './features/Header';
|
|
9
|
-
|
|
10
|
-
const SettingLayout = ({ children }: PropsWithChildren) => (
|
|
11
|
-
<AppMobileLayout navBar={<Header />}>
|
|
12
|
-
<Flexbox style={{ overflow: 'auto' }}>{children}</Flexbox>
|
|
13
|
-
</AppMobileLayout>
|
|
14
|
-
);
|
|
15
|
-
|
|
16
|
-
export default SettingLayout;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
2
|
-
|
|
3
|
-
import ResponsiveLayout from '@/components/ResponsiveLayout';
|
|
4
|
-
import { isMobileDevice } from '@/utils/responsive';
|
|
5
|
-
|
|
6
|
-
import Desktop from './layout.desktop';
|
|
7
|
-
import Mobile from './layout.mobile';
|
|
8
|
-
|
|
9
|
-
const Layout = ({ children }: PropsWithChildren) => (
|
|
10
|
-
<ResponsiveLayout Desktop={Desktop} Mobile={Mobile} isMobile={isMobileDevice}>
|
|
11
|
-
{children}
|
|
12
|
-
</ResponsiveLayout>
|
|
13
|
-
);
|
|
14
|
-
|
|
15
|
-
export default Layout;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import { useResponsive } from 'antd-style';
|
|
4
|
-
import { PropsWithChildren, memo } from 'react';
|
|
5
|
-
|
|
6
|
-
import Mobile from '../MobileLayout';
|
|
7
|
-
import Desktop from './Desktop';
|
|
8
|
-
|
|
9
|
-
const ResponsiveLayout = memo<PropsWithChildren>(({ children }) => {
|
|
10
|
-
const { mobile } = useResponsive();
|
|
11
|
-
|
|
12
|
-
return mobile ? <Mobile>{children}</Mobile> : <Desktop>{children}</Desktop>;
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
export default ResponsiveLayout;
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import { Logo, MobileNavBar } from '@lobehub/ui';
|
|
4
|
-
import { useTheme } from 'antd-style';
|
|
5
|
-
import { PropsWithChildren, memo } from 'react';
|
|
6
|
-
|
|
7
|
-
import AppMobileLayout from '@/layout/AppMobileLayout';
|
|
8
|
-
|
|
9
|
-
const MobileLayout = memo<PropsWithChildren>(({ children }) => {
|
|
10
|
-
const theme = useTheme();
|
|
11
|
-
|
|
12
|
-
return (
|
|
13
|
-
<AppMobileLayout
|
|
14
|
-
navBar={<MobileNavBar center={<Logo type={'text'} />} />}
|
|
15
|
-
showTabBar
|
|
16
|
-
style={{ background: theme.colorBgLayout }}
|
|
17
|
-
>
|
|
18
|
-
{children}
|
|
19
|
-
</AppMobileLayout>
|
|
20
|
-
);
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
export default MobileLayout;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
2
|
-
|
|
3
|
-
import { isMobileDevice } from '@/utils/responsive';
|
|
4
|
-
|
|
5
|
-
import Desktop from './DesktopLayout';
|
|
6
|
-
import Mobile from './MobileLayout';
|
|
7
|
-
import Footer from './features/Footer';
|
|
8
|
-
|
|
9
|
-
const Layout = ({ children }: PropsWithChildren) => {
|
|
10
|
-
const mobile = isMobileDevice();
|
|
11
|
-
|
|
12
|
-
return mobile ? (
|
|
13
|
-
<Mobile>{children}</Mobile>
|
|
14
|
-
) : (
|
|
15
|
-
<Desktop>
|
|
16
|
-
{children}
|
|
17
|
-
<Footer />
|
|
18
|
-
</Desktop>
|
|
19
|
-
);
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
export default Layout;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/src/app/chat/{components/ChatInput → features/ChatInputContent}/ActionBar/ActionLeft.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/ChatInput → features/ChatInputContent}/ActionBar/ActionRight.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/ChatInput → features/ChatInputContent}/ActionBar/Token.tsx
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/src/app/chat/{components/SessionList → features/SessionListContent}/CollapseGroup/index.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/SessionList → features/SessionListContent}/List/AddButton.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/SessionList → features/SessionListContent}/List/Item/Actions.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/SessionList → features/SessionListContent}/List/Item/index.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/SessionList → features/SessionListContent}/List/SkeletonList.tsx
RENAMED
|
File without changes
|
|
File without changes
|
/package/src/app/chat/{components/Inspector → features/TopicListContent}/SystemRole/Header.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/Inspector → features/TopicListContent}/SystemRole/index.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/Inspector → features/TopicListContent}/SystemRole/style.ts
RENAMED
|
File without changes
|
/package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/DefaultContent.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/SkeletonList.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/TopicContent.tsx
RENAMED
|
File without changes
|
/package/src/app/chat/{components/Inspector → features/TopicListContent}/Topic/TopicItem.tsx
RENAMED
|
File without changes
|
|
File without changes
|
/package/src/app/chat/{components/Inspector → features/TopicListContent}/TopicSearchBar/index.tsx
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/Comment.tsx
RENAMED
|
File without changes
|
/package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/Loading.tsx
RENAMED
|
File without changes
|
|
File without changes
|
/package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/index.tsx
RENAMED
|
File without changes
|
/package/src/app/market/{components/AgentDetail → features/AgentDetailContent}/AgentInfo/style.ts
RENAMED
|
File without changes
|