diff --git a/src/components/dashboard/DualColumnEditor.tsx b/src/components/dashboard/DualColumnEditor.tsx index 12178e1357..ca47d370f4 100644 --- a/src/components/dashboard/DualColumnEditor.tsx +++ b/src/components/dashboard/DualColumnEditor.tsx @@ -1,36 +1,19 @@ import { useDebounceEffect } from "ahooks" import type { Root } from "mdast" import { useTranslations } from "next-intl" -import dynamic from "next/dynamic" import { useCallback, useEffect, useMemo, useRef, useState } from "react" import { EditorView } from "@codemirror/view" +import PageContent from "~/components/common/PageContent" import { toolbarShortcuts } from "~/components/dashboard/toolbars" import { editorUpload } from "~/components/dashboard/toolbars/Multimedia" +import CodeMirror from "~/components/ui/CodeMirror" import { useIsMobileLayout } from "~/hooks/useMobileLayout" import { useUploadFile } from "~/hooks/useUploadFile" import { cn } from "~/lib/utils" import { Rendered, renderPageContent } from "~/markdown" -import { Loading } from "../common/Loading" - -const DynamicCodeMirrorEditor = dynamic( - () => import("~/components/ui/CodeMirror"), - { - ssr: false, - loading: () => , - }, -) - -const DynamicPageContent = dynamic( - () => import("~/components/common/PageContent"), - { - ssr: false, - loading: () => , - }, -) - export default function DualColumnEditor({ initialContent, onChange, @@ -215,7 +198,7 @@ export default function DualColumnEditor({ return (
{!(isMobileLayout && isRendering) && ( - )} {isRendering && ( -