Reformat code with Prettier's new rules.

This commit is contained in:
Caio Cotts
2023-12-18 14:56:03 -05:00
parent 735d670a5b
commit 86757663d6
82 changed files with 236 additions and 222 deletions
+3 -3
View File
@@ -59,7 +59,7 @@ const PlaylistActions = ({ className, ids, data, record, ...rest }) => {
.then((res) => {
const data = res.data.reduce(
(acc, curr) => ({ ...acc, [curr.id]: curr }),
{}
{},
)
dispatch(action(data))
})
@@ -67,7 +67,7 @@ const PlaylistActions = ({ className, ids, data, record, ...rest }) => {
notify('ra.page.error', 'warning')
})
},
[dataProvider, dispatch, record, data, ids, notify]
[dataProvider, dispatch, record, data, ids, notify],
)
const handlePlay = React.useCallback(() => {
@@ -108,7 +108,7 @@ const PlaylistActions = ({ className, ids, data, record, ...rest }) => {
link.click()
link.parentNode.removeChild(link)
}),
[record]
[record],
)
return (
+1 -1
View File
@@ -38,7 +38,7 @@ const useStyles = makeStyles(
}),
{
name: 'NDPlaylistDetails',
}
},
)
const PlaylistDetails = (props) => {
+2 -2
View File
@@ -65,7 +65,7 @@ const TogglePublicInput = ({ resource, source }) => {
console.log(error)
notify('ra.page.error', 'warning')
},
}
},
)
const handleClick = (e) => {
@@ -108,7 +108,7 @@ const PlaylistList = (props) => {
),
comment: <TextField source="comment" />,
}),
[isDesktop, isXsmall]
[isDesktop, isXsmall],
)
const columns = useSelectedFields({
+1 -1
View File
@@ -20,7 +20,7 @@ const useStyles = makeStyles(
}),
{
name: 'NDPlaylistShow',
}
},
)
const PlaylistShowLayout = (props) => {
+4 -4
View File
@@ -72,7 +72,7 @@ const useStyles = makeStyles(
visibility: (props) => (props.isDesktop ? 'hidden' : 'visible'),
},
}),
{ name: 'RaList' }
{ name: 'RaList' },
)
const ReorderableList = ({ readOnly, children, ...rest }) => {
@@ -99,7 +99,7 @@ const PlaylistSongs = ({ playlistId, readOnly, actions, ...props }) => {
refetch()
}
},
[playlistId, refetch]
[playlistId, refetch],
)
const reorder = useCallback(
@@ -117,7 +117,7 @@ const PlaylistSongs = ({ playlistId, readOnly, actions, ...props }) => {
notify('ra.page.error', 'warning')
})
},
[dataProvider, notify, refetch]
[dataProvider, notify, refetch],
)
const handleDragEnd = useCallback(
@@ -126,7 +126,7 @@ const PlaylistSongs = ({ playlistId, readOnly, actions, ...props }) => {
const fromId = ids[from]
reorder(playlistId, fromId, toId)
},
[playlistId, reorder, ids]
[playlistId, reorder, ids],
)
const toggleableFields = useMemo(() => {