From ca32d9dc6e41b83f60009128c1435d2e9fa10dcf Mon Sep 17 00:00:00 2001 From: Fangdun Tsai Date: Mon, 21 Oct 2024 20:44:36 +0800 Subject: [PATCH] feat: init PDF Viewer --- .../component/src/components/pdf-viewer/index.tsx | 10 ++++++++++ .../src/desktop/pages/workspace/attachment/index.tsx | 7 ++++--- 2 files changed, 14 insertions(+), 3 deletions(-) create mode 100644 packages/frontend/component/src/components/pdf-viewer/index.tsx diff --git a/packages/frontend/component/src/components/pdf-viewer/index.tsx b/packages/frontend/component/src/components/pdf-viewer/index.tsx new file mode 100644 index 0000000000000..edc511868a62c --- /dev/null +++ b/packages/frontend/component/src/components/pdf-viewer/index.tsx @@ -0,0 +1,10 @@ +import type { ReactElement } from 'react'; + +export const PDFViewer = (): ReactElement => { + return ( + <> +
{'PDF Viewer'}
+
{'PDF ...'}
+ + ); +}; diff --git a/packages/frontend/core/src/desktop/pages/workspace/attachment/index.tsx b/packages/frontend/core/src/desktop/pages/workspace/attachment/index.tsx index eb3752f0e3060..b586df4586b5f 100644 --- a/packages/frontend/core/src/desktop/pages/workspace/attachment/index.tsx +++ b/packages/frontend/core/src/desktop/pages/workspace/attachment/index.tsx @@ -1,14 +1,15 @@ +import { PDFViewer } from '@affine/component/pdf-viewer'; import type { ReactElement } from 'react'; -export const AttachmentViewer = (): ReactElement => { +export const AttachmentPage = (): ReactElement => { return ( <>
{'Attachment Viewer'}
-
{'Attachment Viewer'}
+ ); }; export const Component = () => { - return ; + return ; };