refactor(infra): move currentPageAtom to core (#5332)

Remove `currentPageAtom` from `infra` to `frontend/core.`
This commit is contained in:
EYHN
2023-12-25 03:34:28 +00:00
parent e1bd13a018
commit 9493bd99f9
8 changed files with 10 additions and 11 deletions

View File

@@ -1,8 +1,9 @@
import { waitForCurrentWorkspaceAtom } from '@affine/workspace/atom';
import { useBlockSuiteWorkspacePage } from '@toeverything/hooks/use-block-suite-workspace-page';
import { currentPageIdAtom } from '@toeverything/infra/atom';
import { useAtomValue } from 'jotai';
import { currentPageIdAtom } from '../../atoms/mode';
export const useCurrentPage = () => {
const currentPageId = useAtomValue(currentPageIdAtom);
const currentWorkspace = useAtomValue(waitForCurrentWorkspaceAtom);