Skip to content

🎧 Your Personal Streaming Service

Enable autoPlay in React Player

Deluan3a9324c6efbe
diff --git a/ui/src/audioplayer/Player.js b/ui/src/audioplayer/Player.js
index b648edd85..2f365806b 100644
--- a/ui/src/audioplayer/Player.js
+++ b/ui/src/audioplayer/Player.js
@@ -28,7 +28,7 @@ const Player = () => {
to={`/album/${audioInfo.albumId}/show`}
className={classes.audioTitle}
>
- {`${audioInfo.name} - ${audioInfo.singer}`}
+ {audioInfo.name ? `${audioInfo.name} - ${audioInfo.singer}` : ''}
</Link>
)
@@ -36,7 +36,7 @@ const Player = () => {
theme: playerTheme,
bounds: 'body',
mode: 'full',
- autoPlay: false,
+ autoPlay: true,
preload: true,
autoPlayInitLoadPlayList: true,
loadAudioErrorPlayNext: false,
@@ -83,7 +83,6 @@ const Player = () => {
const addQueueToOptions = (queue) => {
return {
...defaultOptions,
- autoPlay: false,
clearPriorAudioLists: queue.clear,
audioLists: queue.queue.map((item) => item),
}