Skip to content

Releases: hirbod/react-native-volume-manager

Release 2.0.7

15 Dec 21:40
Compare
Choose a tag to compare

2.0.7 (2024-12-15)

Features

  • Added web platform support via no-op implementations
  • All methods now have web-safe fallbacks that return appropriate default values or undefined or null
  • Added development-mode warning when methods are called on web platform

Release 2.0.6

15 Dec 20:27
Compare
Choose a tag to compare

2.0.6 (2024-12-15)

Changelog

💥 Breaking Changes

  • Renamed isRingerListenerEnabled to isAndroidDeviceSilent to better reflect its functionality

Asynchronously checks if the device is in a silent state on Android (including silent mode, vibrate mode, or muted volume / do not disturb mode).

  • iOS returns null

Migration Guide

If you were previously using isRingerListenerEnabled(), you'll need to:

  1. Update the function name to isAndroidDeviceSilent()
  2. Add iOS platform check if used in cross-platform code

Release 2.0.5

15 Dec 18:51
Compare
Choose a tag to compare

[2.0.5](v2.0.4...v2.0.5) (2024-12-15)

Fixes (Android)

Turns out Android is, once again, a real PITA. The VolumeKeyListener was initially registered on the rootView, which somehow gets removed when you background the app and return. I changed the listener to the contentView, but this broke functionality when opening a modal. To address this, I updated the listener to attach to the correct view, which worked fine—until an input field was focused.

To handle this edge case, I added a tree observer to detect when an input is focused and when that focus is lost, allowing the listener to be restored by reassigning the appropriate window focus.

I believe this is now a reliable and functional solution. The tradeoff—volume button listeners not working when a dialog (alert) or input is focused—should be acceptable and not interfere with most app behaviors.

Release 2.0.4

15 Dec 17:21
Compare
Choose a tag to compare

2.0.4 (2024-12-15)

Bugfixes

  • Fixed a crash on Android caused by a race condition by moving checks to the same thread.
  • Correctly restored toast volume suppression on Android when the app returns to the foreground after being backgrounded.

Release 2.0.3

15 Dec 16:28
Compare
Choose a tag to compare

2.0.3 (2024-12-15)

  • Silence unused param warning in Kotlin file, since we need it

Release 2.0.2

15 Dec 16:14
Compare
Choose a tag to compare

2.0.2 (2024-12-15)

Bugfixes

  • Fixed an issue on Android, where VolumeManager.enable() requires a second parameter
  • Added namespace to build.gradle

Release 2.0.1

15 Dec 13:39
Compare
Choose a tag to compare

2.0.1 (2024-12-15)

New

  • Added support for the new architecture (thanks @hrastnik).

Breaking Changes

  • Requires React Native 0.76+.
  • Minimum supported iOS version is now 15+.
  • Volume Listener (Android): Only reports the changed volume type and includes the type in the callback.

Bug Fixes

Android

  • Fixed RingerMode listener triggering on volume change.
  • Resolved Null Pointer Exception when setting up key listeners.
  • Volume listener now reports only the changed volume type instead of sending events for all volumes (previously 7 events).
  • Properly set up and remove listeners.

iOS

  • Removed deprecated code.
  • Refactored how native toast is set up and suppressed.
  • Improved detection of the top-most view.
  • Removed an incorrectly exported method that caused crashes with the new architecture.

Full Changelog: v1.10.0...v2.0.1

Release 1.10.0

11 Jul 15:48
Compare
Choose a tag to compare

1.10.0 (2023-07-11)

Bug Fixes

  • add simulator quirks back to README (074804d)
  • update kotlin version to 1.8.0 (#19) (9a20f64)

Features

Release 1.8.1

23 Jun 09:26
Compare
Choose a tag to compare

1.8.1 (2023-06-23)

Better API docs

Release 1.8.0

23 Jun 09:04
Compare
Choose a tag to compare

1.8.0 (2023-06-23)

Bug Fixes

Features