mirror of
https://github.com/emuplace/folium.emuplace.app.git
synced 2024-11-22 02:12:48 +01:00
Fix duplicate audio issue
This commit is contained in:
parent
f32f2c1a0c
commit
d683b92130
@ -10,8 +10,11 @@ import { theme } from '../theme';
|
|||||||
export default function NextCore() {
|
export default function NextCore() {
|
||||||
const date = new Date();
|
const date = new Date();
|
||||||
|
|
||||||
|
const audio = new Audio("https://quicksounds.com/uploads/tracks/528054973_948104858_1761723949.mp3")
|
||||||
function play() {
|
function play() {
|
||||||
new Audio("https://quicksounds.com/uploads/tracks/528054973_948104858_1761723949.mp3").play()
|
if (audio.duration <= 0 && audio.paused) {
|
||||||
|
audio.play()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
Loading…
Reference in New Issue
Block a user