Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Device or permission "in use" event #2428

Open
RendijsSmukulis opened this issue May 6, 2022 · 8 comments
Open

Feature request: Device or permission "in use" event #2428

RendijsSmukulis opened this issue May 6, 2022 · 8 comments
Assignees
Labels
feature request feature request priority-low We have considered this issue and decided that we will not be able to address it in the near future. tracked We are tracking this work internally.

Comments

@RendijsSmukulis
Copy link

RendijsSmukulis commented May 6, 2022

We currently have no good way to indicate to a user when some sensitive API is in use by a page, e.g. the page has access to the camera or the microphone that's currently recording.

It would be great to see an event that signals when these APIs are being actively used by site:

  • Geolocation
  • Camera
  • Microphone

With events fired when these are enabled and then later disabled.

AB#39484085

@RendijsSmukulis RendijsSmukulis added the feature request feature request label May 6, 2022
@RendijsSmukulis RendijsSmukulis changed the title Device or permission "in use" event Feature request: Device or permission "in use" event May 6, 2022
@victorthoang victorthoang added the tracked We are tracking this work internally. label May 9, 2022
@champnic champnic added tracked We are tracking this work internally. and removed tracked We are tracking this work internally. labels May 9, 2022
@victorthoang
Copy link

Thanks for the feedback RendijsSmukulis! We've added this as a scenario on our backlog!

@champnic champnic added tracked We are tracking this work internally. and removed tracked We are tracking this work internally. labels May 9, 2022
@nishitha-burman
Copy link
Collaborator

Hi @RendijsSmukulis,

Can you expand more on the scenario you are trying to achieve here? For these events is it sufficient to be able to query the value set for these permissions?

Thank you

@q71114
Copy link

q71114 commented Sep 5, 2022

Hi @nishitha-burman

In this case we want to display an indicator to the user that a permission is in use AND we also want to give them the ability to pause / resume usage. This means apart from being able to query the value we need to be able to disable / re-enable the outgoing audio / video stream temporarily. For example at JS level this means setting MediaStreamTrack.enabled to false (and then back to true for resuming).

@vickiez
Copy link
Contributor

vickiez commented Jan 21, 2023

@RendijsSmukulis and @q71114, can you check if the new experimental Permission Management APIs meet your needs? #2427 (comment) Thanks!

@q71114
Copy link

q71114 commented Jan 23, 2023

@RendijsSmukulis and @q71114, can you check if the new experimental permission management APIs meet your needs? #2427 (comment) Thanks!

Hi @vickiez,

Thanks for the info, we'll check it out. Looking at the new APIs I don't see anything that provides "in use" status (eg. camera is recording). Are those APIs in a separate document?

@vickiez
Copy link
Contributor

vickiez commented Jan 23, 2023

@q71114 we haven't added an "in use" event but you may be able to accomplish what you need in a couple ways:

Will either of these options work for your case?

@q71114
Copy link

q71114 commented Jan 25, 2023

@vickiez thanks for the suggestion, but it doesn't offer enough support for all the cases that we want to cover I'm afraid.

We only display these "in use" indicators when they are actually being in use, so GetNonDefaultPermissionSettings won't work.

Using PermissionRequested with SavesInProfile property won't cover everything either because for example audio / video streams can be paused (muted) and they don't trigger PermissionRequested event, which is fine because they are not new request, but we still need to be able to display proper "in use" statuses for those scenarios. You can check it out here: https://jsfiddle.net/jib1/3ykab1e2/39/

@vickiez
Copy link
Contributor

vickiez commented Jan 25, 2023

I see, thanks for sharing the example! This request is relatively low priority on our backlog, but we are starting to work on #2440, which may be your preferred approach anyway. :)

@victorhuangwq victorhuangwq self-assigned this Aug 15, 2023
@github-actions github-actions bot added the priority-low We have considered this issue and decided that we will not be able to address it in the near future. label Mar 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request feature request priority-low We have considered this issue and decided that we will not be able to address it in the near future. tracked We are tracking this work internally.
Projects
None yet
Development

No branches or pull requests

7 participants