Add list of files being deleted to delete modal (#3299)
Shows the first 15 file names being deleted. If more then 15, the first 15 will be shown then the last line will be ` + ## other(s)`
This commit is contained in:
parent
bd5472e2e6
commit
3898e40fa4
1 changed files with 12 additions and 1 deletions
|
@ -74,7 +74,18 @@ const MassActionsBar = () => {
|
||||||
onConfirmed={onClickConfirmDeletion}
|
onConfirmed={onClickConfirmDeletion}
|
||||||
onModalDismissed={() => setShowConfirm(false)}
|
onModalDismissed={() => setShowConfirm(false)}
|
||||||
>
|
>
|
||||||
Deleting files is a permanent operation, you cannot undo this action.
|
Are you sure you want to delete {selectedFiles.length} file(s)?
|
||||||
|
<br/>
|
||||||
|
Deleting the file(s) listed below is a permanent operation, you cannot undo this action.
|
||||||
|
<br/>
|
||||||
|
<code>
|
||||||
|
{ selectedFiles.slice(0, 15).map(file => (
|
||||||
|
<li key={file}>{file}<br/></li>))
|
||||||
|
}
|
||||||
|
{ selectedFiles.length > 15 &&
|
||||||
|
<li> + {selectedFiles.length - 15} other(s) </li>
|
||||||
|
}
|
||||||
|
</code>
|
||||||
</ConfirmationModal>
|
</ConfirmationModal>
|
||||||
{showMove &&
|
{showMove &&
|
||||||
<RenameFileModal
|
<RenameFileModal
|
||||||
|
|
Loading…
Reference in a new issue