forked from lobehub/lobe-chat
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🐛 fix: Fix intercepting-routes on mobile
- Loading branch information
1 parent
8853f63
commit abe228c
Showing
39 changed files
with
295 additions
and
206 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
'use client'; | ||
|
||
import { useLayoutEffect } from 'react'; | ||
|
||
import { useQueryRoute } from '@/hooks/useQueryRoute'; | ||
|
||
export default () => { | ||
const router = useQueryRoute(); | ||
|
||
useLayoutEffect(() => { | ||
router.replace('/chat/settings'); | ||
}, []); | ||
|
||
return null; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import { Logo, Tag } from '@lobehub/ui'; | ||
import { Flexbox } from 'react-layout-kit'; | ||
|
||
import Follow from '@//features/Follow'; | ||
import AboutList from '@/app/(main)/settings//about/features/AboutList'; | ||
import Analytics from '@/app/(main)/settings/about/features/Analytics'; | ||
import { getServerConfig } from '@/config/server'; | ||
import { CURRENT_VERSION } from '@/const/version'; | ||
|
||
const enabledTelemetryChat = getServerConfig().ENABLE_LANGFUSE; | ||
|
||
const COPYRIGHT = `© 2023-${new Date().getFullYear()} LobeHub, LLC`; | ||
|
||
const Page = ({ mobile }: { mobile?: boolean }) => { | ||
return ( | ||
<Flexbox align={'center'} gap={12} paddingBlock={36} width={'100%'}> | ||
<Logo size={mobile ? 100 : 120} /> | ||
<h1 style={{ fontSize: mobile ? 32 : 36, fontWeight: 900, lineHeight: 1, marginBottom: 0 }}> | ||
LobeChat | ||
</h1> | ||
<Tag>v{CURRENT_VERSION}</Tag> | ||
<Flexbox gap={24} style={{ marginBlock: 48 }} width={'100%'}> | ||
<AboutList /> | ||
{enabledTelemetryChat && <Analytics />} | ||
</Flexbox> | ||
<Follow /> | ||
<div>Empowering your AI dreams by LobeHub</div> | ||
<div style={{ fontWeight: 400, opacity: 0.33 }}>{COPYRIGHT}</div> | ||
</Flexbox> | ||
); | ||
}; | ||
|
||
Page.displayName = 'AboutSetting'; | ||
|
||
export default Page; |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import { getServerConfig } from '@/config/server'; | ||
|
||
import Common from './features/Common'; | ||
import Theme from './features/Theme'; | ||
|
||
const { SHOW_ACCESS_CODE_CONFIG, ENABLE_OAUTH_SSO } = getServerConfig(); | ||
|
||
const Page = () => { | ||
return ( | ||
<> | ||
<Theme /> | ||
<Common showAccessCodeConfig={SHOW_ACCESS_CODE_CONFIG} showOAuthLogin={ENABLE_OAUTH_SSO} /> | ||
</> | ||
); | ||
}; | ||
|
||
Page.displayName = 'CommonSetting'; | ||
|
||
export default Page; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,10 @@ | ||
import { getServerConfig } from '@/config/server'; | ||
import { translation } from '@/server/translation'; | ||
|
||
import Common from './features/Common'; | ||
import Theme from './features/Theme'; | ||
|
||
export const generateMetadata = async () => { | ||
const { t } = await translation('setting'); | ||
return { | ||
title: t('tab.common'), | ||
}; | ||
}; | ||
|
||
const Page = () => { | ||
const { SHOW_ACCESS_CODE_CONFIG, ENABLE_OAUTH_SSO } = getServerConfig(); | ||
return ( | ||
<> | ||
<Theme /> | ||
<Common showAccessCodeConfig={SHOW_ACCESS_CODE_CONFIG} showOAuthLogin={ENABLE_OAUTH_SSO} /> | ||
</> | ||
); | ||
}; | ||
|
||
Page.displayName = 'CommonSetting'; | ||
|
||
export default Page; | ||
export { default } from './index'; |
Oops, something went wrong.