import { CodeEditorView } from 'officerdev';
import { Widget } from 'widgets/Widget';

export const CodeEditor = () => (
  <div className="h-full w-full flex items-center justify-center">
    <Widget title="Code Editor" className="h-[70vh] w-[70vw] overflow-hidden" resizable moveable>
      {/* The screen is the one editor that owns the address bar, so the open file is `?file=`. The panel
          wrapper deliberately does not pass this: a dashboard can hold two editors. */}
      <CodeEditorView className="h-full w-full" urlState />
    </Widget>
  </div>
);
