feat: add page setting atom (#2725)

(cherry picked from commit 9f129075dd)
This commit is contained in:
Himself65
2023-06-09 00:58:46 +08:00
committed by Alex Yang
parent 2ca5ad6509
commit c3bfc16d27
14 changed files with 119 additions and 275 deletions
@@ -12,7 +12,6 @@ import { useCallback } from 'react';
import { getUIAdapter } from '../../../adapters/workspace';
import { rootCurrentWorkspaceAtom } from '../../../atoms/root';
import { useCurrentWorkspace } from '../../../hooks/current/use-current-workspace';
import { useSyncRecentViewsWithRouter } from '../../../hooks/use-recent-views';
import { useRouterHelper } from '../../../hooks/use-router-helper';
import { WorkspaceLayout } from '../../../layouts/workspace-layout';
import type { NextPageWithLayout } from '../../../shared';
@@ -25,7 +24,6 @@ const WorkspaceDetail: React.FC = () => {
assertExists(currentWorkspace);
assertExists(currentPageId);
const blockSuiteWorkspace = currentWorkspace.blockSuiteWorkspace;
useSyncRecentViewsWithRouter(router, blockSuiteWorkspace);
const onLoad = useCallback(
(page: Page, editor: EditorContainer) => {