This spec defines "" to mean the "user-agent default device", e.g. status quo without this spec.
At least on macOS this OS default is dynamic and may change live. As such, these differ:
await element.setSinkId(""); // Follow the dynamic OS default
await element.setSinkId(defaultDeviceId); // Stop following the dynamic OS default
With the second one, the element stops responding to user changes in the OS.
The problem is the spec right now implies both of these may be called without consent, which seems wrong: "If the application is not permitted to play audio through the device identified by sinkId, reject p ", and: "The specification adds no permission requirement to the default audio output device.".
We propose changing the spec here to require consent for anything other than "", since it allows JS to stop following the (potentially changing) OS default, and instead track the physical device that was default at the time of the call.
This spec defines
""
to mean the "user-agent default device", e.g. status quo without this spec.At least on macOS this OS default is dynamic and may change live. As such, these differ:
With the second one, the element stops responding to user changes in the OS.
The problem is the spec right now implies both of these may be called without consent, which seems wrong: "If the application is not permitted to play audio through the device identified by sinkId, reject p ", and: "The specification adds no permission requirement to the default audio output device.".
We propose changing the spec here to require consent for anything other than
""
, since it allows JS to stop following the (potentially changing) OS default, and instead track the physical device that was default at the time of the call.