mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-16 01:26:37 +08:00
Feat/land page (#391)
* feat: update landing page * feat: update landing page * fix: react warning * feat(route): rename variables * feat(route): better refresh * fix: update logo and i18n * feat(code): remove unused comment * refactor(workspace): rename workspaceId * refactor(page): rename pageId * feat(edit): more robust editing experience * fix: landing page mobile * fix: landing page mobile Co-authored-by: tzhangchi <terry.zhangchi@outlook.com> Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
This commit is contained in:
@@ -2,8 +2,8 @@ import { useNavigate, useParams } from 'react-router-dom';
|
||||
import { Descendant } from 'slate';
|
||||
|
||||
// eslint-disable-next-line @nrwl/nx/enforce-module-boundaries
|
||||
import { BlockSearchItem } from '@toeverything/datasource/jwt';
|
||||
import { styled } from '@toeverything/components/ui';
|
||||
import { BlockSearchItem } from '@toeverything/datasource/jwt';
|
||||
|
||||
import { BlockPreview } from '../../block-preview';
|
||||
|
||||
@@ -26,14 +26,14 @@ type InlineRefLinkProps = {
|
||||
};
|
||||
|
||||
export const InlineRefLink = ({ block, pageId }: InlineRefLinkProps) => {
|
||||
const { workspace_id } = useParams();
|
||||
const { workspaceId } = useParams();
|
||||
const navigate = useNavigate();
|
||||
|
||||
if (block) {
|
||||
return (
|
||||
<BlockPreviewContainer
|
||||
block={block}
|
||||
onClick={() => navigate(`/${workspace_id}/${pageId}`)}
|
||||
onClick={() => navigate(`/${workspaceId}/${pageId}`)}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user