Add Playlist action

This commit is contained in:
Deluan
2020-05-15 18:53:33 -04:00
committed by Deluan Quintão
parent f881e2a54b
commit fd49ae319f
7 changed files with 73 additions and 27 deletions
+3 -3
View File
@@ -8,7 +8,7 @@ import PlayArrowIcon from '@material-ui/icons/PlayArrow'
import ShuffleIcon from '@material-ui/icons/Shuffle'
import React from 'react'
import { useDispatch } from 'react-redux'
import { playAlbum, shuffleAlbum } from '../audioplayer'
import { playTracks, shuffleTracks } from '../audioplayer'
const AlbumActions = ({
className,
@@ -25,7 +25,7 @@ const AlbumActions = ({
<TopToolbar className={className} {...sanitizeListRestProps(rest)}>
<Button
onClick={() => {
dispatch(playAlbum(data, ids))
dispatch(playTracks(data, ids))
}}
label={translate('resources.album.actions.playAll')}
>
@@ -33,7 +33,7 @@ const AlbumActions = ({
</Button>
<Button
onClick={() => {
dispatch(shuffleAlbum(data, ids))
dispatch(shuffleTracks(data, ids))
}}
label={translate('resources.album.actions.shuffle')}
>