diff --git a/assets/sounds/README.md b/assets/sounds/README.md new file mode 100644 index 0000000..7a66a85 --- /dev/null +++ b/assets/sounds/README.md @@ -0,0 +1,17 @@ +# Build uncompressed webm + +``` +ffmpeg -i notification.mp3 -c:a libopus notification.webm +``` + +## Build compressed webm + +``` +ffmpeg -i notification.mp3 -c:a libopus -vn -b:a 48K notification.webm +``` + +## To create a base64 blob of the sound file + +``` +echo "data:audio/webm;base64,`base64 -b 80 notification.webm`" +``` diff --git a/assets/sounds/notification.mp3 b/assets/sounds/notification.mp3 new file mode 100644 index 0000000..53c1c19 Binary files /dev/null and b/assets/sounds/notification.mp3 differ diff --git a/assets/sounds/notification.webm b/assets/sounds/notification.webm new file mode 100644 index 0000000..1963776 Binary files /dev/null and b/assets/sounds/notification.webm differ diff --git a/static/sounds/README.md b/static/sounds/README.md new file mode 100644 index 0000000..7a66a85 --- /dev/null +++ b/static/sounds/README.md @@ -0,0 +1,17 @@ +# Build uncompressed webm + +``` +ffmpeg -i notification.mp3 -c:a libopus notification.webm +``` + +## Build compressed webm + +``` +ffmpeg -i notification.mp3 -c:a libopus -vn -b:a 48K notification.webm +``` + +## To create a base64 blob of the sound file + +``` +echo "data:audio/webm;base64,`base64 -b 80 notification.webm`" +``` diff --git a/static/sounds/notification.mp3 b/static/sounds/notification.mp3 new file mode 100644 index 0000000..53c1c19 Binary files /dev/null and b/static/sounds/notification.mp3 differ diff --git a/static/sounds/notification.webm b/static/sounds/notification.webm new file mode 100644 index 0000000..1963776 Binary files /dev/null and b/static/sounds/notification.webm differ diff --git a/vite.config.js b/vite.config.js index 438fc11..0dc2920 100644 --- a/vite.config.js +++ b/vite.config.js @@ -39,6 +39,10 @@ export default defineConfig({ src: "./assets/img/**", dest: "static/img", }, + { + src: "./assets/sounds/**", + dest: "static/sounds", + }, ], hook: "writeBundle", }),