Add Song Details to Album view

This commit is contained in:
Deluan
2020-04-14 14:59:16 -04:00
parent da45bcf448
commit f0d18d2cb3
4 changed files with 32 additions and 20 deletions
+26
View File
@@ -0,0 +1,26 @@
import React from 'react'
import {
Show,
SimpleShowLayout,
BooleanField,
DateField,
TextField
} from 'react-admin'
import { BitrateField } from './index'
const SongDetails = (props) => {
return (
<Show {...props} title=" ">
<SimpleShowLayout>
<TextField source="path" />
<TextField source="albumArtist" />
<TextField source="genre" />
<BooleanField source="compilation" />
<BitrateField source="bitRate" />
<DateField source="updatedAt" showTime />
</SimpleShowLayout>
</Show>
)
}
export default SongDetails
+2
View File
@@ -5,6 +5,7 @@ import Pagination from './Pagination'
import PlayButton from './PlayButton'
import SimpleList from './SimpleList'
import RangeField, { formatRange } from './RangeField'
import SongDetails from './SongDetails'
export {
Title,
@@ -14,5 +15,6 @@ export {
PlayButton,
SimpleList,
RangeField,
SongDetails,
formatRange
}