mirror of
https://github.com/open-webui/open-webui
synced 2025-05-30 10:32:53 +00:00
refac: notification sound behaviour
This commit is contained in:
parent
6b3be4bb5b
commit
996ade9090
@ -12,6 +12,10 @@
|
|||||||
export let content: string;
|
export let content: string;
|
||||||
|
|
||||||
onMount(() => {
|
onMount(() => {
|
||||||
|
if (!navigator.userActivation.hasBeenActive) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if ($settings?.notificationSound ?? true) {
|
if ($settings?.notificationSound ?? true) {
|
||||||
const audio = new Audio(`/audio/notification.mp3`);
|
const audio = new Audio(`/audio/notification.mp3`);
|
||||||
audio.play();
|
audio.play();
|
||||||
|
Loading…
Reference in New Issue
Block a user