| import React, { useEffect } from 'react'; |
| import { useIntl } from '@umijs/max'; |
| import { Modal, Tabs } from 'antd'; |
| import type { TabsProps } from 'antd'; |
| import Highlight from 'react-highlight'; |
| import 'highlight.js/styles/base16/material.css'; |
| interface PreviewTableProps { |
| const PreviewTableCode: React.FC<PreviewTableProps> = (props) => { |
| const keys = Object.keys(props.data); |
| label: key.substring(key.lastIndexOf('/') + 1, key.indexOf('.vm')), |
| children: <Highlight className="java">{props.data[key]}</Highlight>, |
| title={intl.formatMessage({ |
| <Tabs defaultActiveKey="1" items={panes}></Tabs> |
| export default PreviewTableCode; |