import React, { PureComponent, createElement } from 'react'; import PropTypes from 'prop-types'; import { Button } from 'antd'; import styles from './index.less'; // TODO: 添加逻辑 class EditableLinkGroup extends PureComponent { static defaultProps = { links: [], onAdd: () => {}, linkElement: 'a', }; static propTypes = { links: PropTypes.array, onAdd: PropTypes.func, linkElement: PropTypes.oneOfType([PropTypes.func, PropTypes.string]), }; render() { const { links, linkElement, onAdd } = this.props; return (