Add toggle to mute videos by default - #61
Conversation
|
The UX for this seems really well thought out. Many vibe coded PRs get submitted to this repo and I don't have the time to sort through which are good and which are garbage. If you can clean up any problems, rebase, and test it thoroughly, I'd be happy to review and merge it! |
|
Thanks! I will follow up on this one and prepare a more complete implementation. |
|
@sudonym1 Wanted to give you a heads up that I just pushed a big rewrite of the media viewer, so you'll need to account for those changes. |
|
This would be an awesome feature to have! |
Add a default-mute setting and a mute button to full-screen videos, remembering the choice until the app returns to the foreground. Unmute on media-volume changes in either direction and native unmute signals where supported, including at volume limits. Keep listeners scoped to the focused, foreground viewer and release owned audio-session mute state on cleanup.
|
Alright, I took another pass at this. I got a little carried away solving the "volume up at 100% volume doesn't register an event problem" which required a native module to resolve. I am fine to remove it, though I do think it improves the UX a bit. Please let me know what next step you would like me to take. |
|
Thanks! Don't have time to do a deep dive into this today, but I'll take a deeper look tomorrow. A few questions before I do so: I try to avoid unnecessary dependencies when possible. Did you test this on both iOS and Android? If you don't have devices to test with, I have both and I'm happy to test for you. |
No rush. Thanks for your time.
Depends - we can avoid the native module entirely if we limit to handling volume changes only. Less code is always nice. If we keep the functionality in, then I can see the value in rolling it all together. Lets leave this one as open feedback. Once I collect the rest of your feedback I can try both ways.
Nope. I don't have a device. If its easy enough for you, I would appreciate your help testing this. |
tested on android emulator, found out I was attached to an unavailable event.
Ok. This has now been tested on a real iOS 26 iphone 16 pro max, the iOS simulator, and on the android emulator. It was broken on Android, and I pushed a fixup. I still need some help testing on a real Android device. |
I sent my agents after a feature I felt was missing from Hydra - that is a toggle to default videos to mute their audio. I borrowed the details from Apollo. When this setting is enabled, videos open muted by default. Pressing Volume Up unmutes. Once one video is unmuted, the next videos are also unmuted as well. Pressing the mute button (under the playback speed button) re-enables mute across videos. Exiting the app and opening it again also re-enables mute.
I have reviewed the code to the best of my ability, but I am not an expert in typescript, or iOS development. I would appreciate your review. If you ever find yourself in a situation where you need C++, Linux kernel code, or networking related software reviewed, please hit me up.
Some decisions left to make:
I will also test this out on android, but I don't personally own an android device. If you can take a look at the general code, I can then try this out on the android simulator.