mirror of
https://github.com/remvze/moodist.git
synced 2025-12-17 00:44:14 +00:00
feat: add media session (wip)
This commit is contained in:
parent
cf4870b0d6
commit
34d3f07581
1 changed files with 1 additions and 1 deletions
|
|
@ -96,6 +96,7 @@ export function App() {
|
|||
Howler.masterGain.connect(dest);
|
||||
|
||||
if (audioElement.current) {
|
||||
audioElement.current.volume = 0;
|
||||
audioElement.current.srcObject = dest.stream;
|
||||
}
|
||||
}, []);
|
||||
|
|
@ -113,7 +114,6 @@ export function App() {
|
|||
useEffect(() => {
|
||||
if (isPlaying) {
|
||||
audioElement.current?.play().then(() => {
|
||||
audioElement.current!.volume = 1;
|
||||
navigator.mediaSession.metadata = new MediaMetadata({
|
||||
title: 'Moodist',
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue