mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-19 02:56:23 +08:00
feat(mobile): use mobile fallback for index, open home when workspace changed (#9106)
This commit is contained in:
@@ -61,7 +61,7 @@ const WorkspaceList = ({
|
||||
const toggleWorkspace = useCallback(
|
||||
(id: string) => {
|
||||
if (id !== currentWorkspace.id) {
|
||||
jumpToPage(id, 'all');
|
||||
jumpToPage(id, 'home');
|
||||
}
|
||||
onClose?.();
|
||||
},
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
import { Component as IndexComponent } from '@affine/core/desktop/pages/index';
|
||||
|
||||
import { AppFallback } from '../components/app-fallback';
|
||||
|
||||
// Default route fallback for mobile
|
||||
|
||||
export const Component = () => {
|
||||
// TODO: replace with a mobile version
|
||||
return <IndexComponent defaultIndexRoute={'home'} />;
|
||||
return (
|
||||
<IndexComponent defaultIndexRoute={'home'} fallback={<AppFallback />} />
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user