|
|
@@ -6,14 +6,14 @@ import React, {
|
|
|
import type EventEmitter from 'events';
|
|
|
import nodePath from 'path';
|
|
|
|
|
|
-import { type IPageHasId, Origin } from '@growi/core';
|
|
|
+import { Origin } from '@growi/core';
|
|
|
+import type { IPageHasId } from '@growi/core/dist/interfaces';
|
|
|
import { pathUtils } from '@growi/core/dist/utils';
|
|
|
import { GlobalCodeMirrorEditorKey } from '@growi/editor';
|
|
|
import { CodeMirrorEditorMain } from '@growi/editor/dist/client/components/CodeMirrorEditorMain';
|
|
|
import { useCodeMirrorEditorIsolated } from '@growi/editor/dist/client/stores/codemirror-editor';
|
|
|
import { useResolvedThemeForEditor } from '@growi/editor/dist/client/stores/use-resolved-theme';
|
|
|
import { useRect } from '@growi/ui/dist/utils';
|
|
|
-import type { ReactCodeMirrorProps } from '@uiw/react-codemirror';
|
|
|
import detectIndent from 'detect-indent';
|
|
|
import { useTranslation } from 'next-i18next';
|
|
|
import { throttle, debounce } from 'throttle-debounce';
|
|
|
@@ -267,7 +267,7 @@ export const PageEditor = React.memo((props: Props): JSX.Element => {
|
|
|
}, [codeMirrorEditor, pageId]);
|
|
|
|
|
|
|
|
|
- const cmProps = useMemo<ReactCodeMirrorProps>(() => ({
|
|
|
+ const cmProps = useMemo(() => ({
|
|
|
onChange: (value: string) => {
|
|
|
setMarkdownPreviewWithDebounce(value);
|
|
|
},
|