Renames in Frontend

This commit is contained in:
Qstick
2020-05-15 23:32:52 -04:00
committed by ta264
parent ee4e44b81a
commit ee43ccf620
387 changed files with 4036 additions and 4364 deletions
@@ -10,11 +10,11 @@ import ModalBody from 'Components/Modal/ModalBody';
import ModalFooter from 'Components/Modal/ModalFooter';
import Alert from 'Components/Alert';
function formatAlbumFiles(items, album) {
function formatBookFiles(items, book) {
return (
<div key={album.id}>
<b> {album.title} </b>
<div key={book.id}>
<b> {book.title} </b>
<ul>
{
_.sortBy(items, 'path').map((item) => {
@@ -54,7 +54,7 @@ class ConfirmImportModalContent extends Component {
render() {
const {
albums,
books,
items,
onConfirmImportPress,
onModalClose,
@@ -87,14 +87,14 @@ class ConfirmImportModalContent extends Component {
!isFetching && isPopulated &&
<div>
<Alert>
You already have files imported for the albums listed below. If you continue, the existing files <b>will be deleted</b> and the new files imported in their place.
You already have files imported for the books listed below. If you continue, the existing files <b>will be deleted</b> and the new files imported in their place.
To avoid deleting existing files, press 'Cancel' and use the 'Combine with existing files' option.
</Alert>
{ _.chain(items)
.groupBy('bookId')
.mapValues((value, key) => formatAlbumFiles(value, _.find(albums, (a) => a.id === parseInt(key))))
.mapValues((value, key) => formatBookFiles(value, _.find(books, (a) => a.id === parseInt(key))))
.values()
.value() }
</div>
@@ -124,7 +124,7 @@ class ConfirmImportModalContent extends Component {
}
ConfirmImportModalContent.propTypes = {
albums: PropTypes.arrayOf(PropTypes.object).isRequired,
books: PropTypes.arrayOf(PropTypes.object).isRequired,
items: PropTypes.arrayOf(PropTypes.object).isRequired,
isFetching: PropTypes.bool.isRequired,
isPopulated: PropTypes.bool.isRequired,