| | |
| | | import React, {Component} from 'react' |
| | | import PropTypes from 'prop-types' |
| | | import { Button } from 'antd' |
| | | import { CloseOutlined } from '@ant-design/icons' |
| | | import './index.scss' |
| | | |
| | | class Preview extends Component { |
| | |
| | | <div> |
| | | {this.state.url && this.props.template && |
| | | <div className={'preview-box ' + (this.state.show ? 'active' : '')} onClick={this.close}> |
| | | <Button shape="circle" icon="close"></Button> |
| | | <Button shape="circle"><CloseOutlined /></Button> |
| | | <Button type="primary" onClick={() => {this.props.confirm(this.props.template, type)}}>使用模板</Button> |
| | | {this.state.url && <img src={this.state.url} alt=""/>} |
| | | </div> |