import { lazy, Suspense } from 'react' export type Language = 'python' | 'json' | 'toml' | 'css' | 'text' export interface CodeEditorProps { value: string onChange?: (value: string) => void language?: Language readOnly?: boolean height?: string minHeight?: string maxHeight?: string placeholder?: string theme?: 'light' | 'dark' className?: string } const CodeEditorImpl = lazy(() => import('./CodeEditorImpl')) function CodeEditorFallback({ height, minHeight, maxHeight, className = '', }: Pick) { return (
) } export function CodeEditor(props: CodeEditorProps) { const { height = '400px', minHeight, maxHeight, className = '' } = props return ( } > ) } export default CodeEditor