diff --git a/components/container/post-container.tsx b/components/container/post-container.tsx index 34983c7e2..38c178c1e 100644 --- a/components/container/post-container.tsx +++ b/components/container/post-container.tsx @@ -1,21 +1,18 @@ import { FC, useMemo } from 'react' // TODO: Maybe can custom import 'highlight.js/styles/zenburn.css' -import { useEditorTheme } from 'components/editor/theme' -import classNames from 'classnames' -import useI18n from 'libs/web/hooks/use-i18n' import UIState from 'libs/web/state/ui' import InnerHTML from 'dangerously-set-html-content' import { NoteModel } from 'libs/shared/note' import pupa from 'pupa' +import MainEditor from 'components/editor/main-editor' + +const MAX_WIDTH = 900 export const PostContainer: FC<{ - post?: string small?: boolean note?: NoteModel -}> = ({ post = '', small = false, note }) => { - const { t } = useI18n() - const editorTheme = useEditorTheme() +}> = ({ small = false, note }) => { const { settings: { settings: { injection }, @@ -29,134 +26,22 @@ export const PostContainer: FC<{ }) }, [injection, note]) - const articleClassName = useMemo( - () => - classNames('prose mx-auto pb-10 prose-sm px-4 md:px-0', { - 'md:prose-2xl': !small, - }), - [small] - ) + const className = 'pt-10 px-6 m-auto max-w-full w-[900px]' return ( <> -
-
-

{note?.title ?? t('Untitled')}

-
-
- -
+ {small ? null : ( <> {injection ? ( ) : null} -