Add video attachments with in-browser compression and playback

Videos are compressed with Mediabunny to 360p at 4 fps (HEVC when the
device can encode it, H.264 otherwise) with mono 32 kbps AAC, then
stored as video_url data URLs. Frames are resized after the frame-rate
drop, and rotation is baked in during that same step, so phone videos
stay on the fast path.

The attach badge shows compression progress, sending waits for pending
compressions, and "Clear all attachments" cancels them. Messages show
video thumbnails that open a fullscreen player.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-12 18:57:48 +00:00
co-authored by Claude Opus 5.5
parent 3c26bda123
commit e027cf96f0
5 changed files with 104 additions and 11 deletions
+4
View File
@@ -12,5 +12,9 @@
"vite": "8.0.*",
"vite-plugin-html-inject": "1.1.*",
"vite-plugin-pwa": "1.2.*"
},
"dependencies": {
"@mediabunny/aac-encoder": "1.61.*",
"mediabunny": "1.61.*"
}
}