index.tsx 1.37 KB
Newer Older
陈帅's avatar
陈帅 committed
1
import { Col, Row } from 'antd';
陈帅's avatar
陈帅 committed
2
import GGEditor, { Koni } from 'gg-editor';
陈帅's avatar
陈帅 committed
3

陈帅's avatar
陈帅 committed
4
import { PageHeaderWrapper } from '@ant-design/pro-layout';
陈帅's avatar
陈帅 committed
5
import React from 'react';
陈帅's avatar
陈帅 committed
6
import { formatMessage } from 'umi-plugin-react/locale';
陈帅's avatar
陈帅 committed
7 8 9
import EditorMinimap from './components/EditorMinimap';
import { KoniContextMenu } from './components/EditorContextMenu';
import { KoniDetailPanel } from './components/EditorDetailPanel';
陈帅's avatar
陈帅 committed
10 11
import { KoniItemPanel } from './components/EditorItemPanel';
import { KoniToolbar } from './components/EditorToolbar';
陈帅's avatar
陈帅 committed
12 13 14 15
import styles from './index.less';

GGEditor.setTrackable(false);

陈帅's avatar
陈帅 committed
16
export default () => (
陈帅's avatar
陈帅 committed
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
  <PageHeaderWrapper
    content={formatMessage({
      id: 'BLOCK_NAME.description',
      defaultMessage: 'description',
    })}
  >
    <GGEditor className={styles.editor}>
      <Row type="flex" className={styles.editorHd}>
        <Col span={24}>
          <KoniToolbar />
        </Col>
      </Row>
      <Row type="flex" className={styles.editorBd}>
        <Col span={2} className={styles.editorSidebar}>
          <KoniItemPanel />
        </Col>
        <Col span={16} className={styles.editorContent}>
          <Koni className={styles.koni} />
        </Col>
        <Col span={6} className={styles.editorSidebar}>
          <KoniDetailPanel />
          <EditorMinimap />
        </Col>
      </Row>
      <KoniContextMenu />
    </GGEditor>
  </PageHeaderWrapper>
);