mirror of
https://github.com/ant-design/ant-design.git
synced 2025-08-06 07:56:28 +08:00
parent
37cf2a3d5e
commit
dc191a321b
@ -100,23 +100,31 @@ export default class UploadList extends React.Component {
|
|||||||
file.url
|
file.url
|
||||||
? (
|
? (
|
||||||
<a
|
<a
|
||||||
onClick={(e) => this.handlePreview(file, e)}
|
href={file.url}
|
||||||
href={file.url} target="_blank"
|
target="_blank"
|
||||||
className={`${prefixCls}-list-item-name`}
|
className={`${prefixCls}-list-item-name`}
|
||||||
|
onClick={e => this.handlePreview(file, e)}
|
||||||
>
|
>
|
||||||
{file.name}
|
{file.name}
|
||||||
</a>
|
</a>
|
||||||
) : <span className={`${prefixCls}-list-item-name`}>{file.name}</span>
|
) : (
|
||||||
|
<span
|
||||||
|
className={`${prefixCls}-list-item-name`}
|
||||||
|
onClick={e => this.handlePreview(file, e)}
|
||||||
|
>
|
||||||
|
{file.name}
|
||||||
|
</span>
|
||||||
|
)
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
this.props.listType === 'picture-card' && file.status !== 'uploading'
|
this.props.listType === 'picture-card' && file.status !== 'uploading'
|
||||||
? (
|
? (
|
||||||
<span>
|
<span>
|
||||||
<a
|
<a
|
||||||
onClick={(e) => this.handlePreview(file, e)}
|
|
||||||
href={file.url}
|
href={file.url}
|
||||||
target="_blank"
|
target="_blank"
|
||||||
style={{ pointerEvents: file.url ? '' : 'none' }}
|
style={{ pointerEvents: file.url ? '' : 'none' }}
|
||||||
|
onClick={e => this.handlePreview(file, e)}
|
||||||
>
|
>
|
||||||
<Icon type="eye-o" />
|
<Icon type="eye-o" />
|
||||||
</a>
|
</a>
|
||||||
|
Loading…
Reference in New Issue
Block a user