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

feat: add blind and mute options while autojoining #2

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

uragirii
Copy link

@uragirii uragirii commented Jun 15, 2023

Description

  • Adds two more settings to mute and turn camera off while auto-joining for obvious reasons
  • I search the buttons by aria-labels as they can be more reliable as compared to class names
  • Fixes Suggestion Auto join: auto select pref. #1

Testing

  • Check auto join setting and two more settings should open
  • Select and check if they work correctly

Todo

  • Update screenshot
  • Update Readme

@giacomocerquone
Copy link
Owner

giacomocerquone commented Jun 15, 2023

this is lit, give me a few days to give it a check and then we'll be good to go

@lotarbo
Copy link

lotarbo commented Jul 12, 2023

@giacomocerquone is there any hope for a merge?)

@giacomocerquone
Copy link
Owner

Hey there, I just pulled your branch and the feature doesn't work. If I enable one or both of the two options you've added, it won't join.

I just had a quick look but I'm afraid it has something to do with the selector you've chosen

@giacomocerquone
Copy link
Owner

As I suspected this has to do with how you're targeting the camera button which is unreliable due to meet's localization.
Precisely, this one: element.ariaLabel.startsWith('Turn')) we're trying to release the functionality on every user.

If you want to keep on going with this PR @uragirii let me know, otherwise I can push it further 🙂

@uragirii
Copy link
Author

As I suspected this has to do with how you're targeting the camera button which is unreliable due to meet's localization. Precisely, this one: element.ariaLabel.startsWith('Turn')) we're trying to release the functionality on every user.

If you want to keep on going with this PR @uragirii let me know, otherwise I can push it further 🙂

Sorry, I forgot to comment, thanks for checking it. I can try to find a different selector to use for camera and mic buttons

@giacomocerquone
Copy link
Owner

As I suspected this has to do with how you're targeting the camera button which is unreliable due to meet's localization. Precisely, this one: element.ariaLabel.startsWith('Turn')) we're trying to release the functionality on every user.
If you want to keep on going with this PR @uragirii let me know, otherwise I can push it further 🙂

Sorry, I forgot to comment, thanks for checking it. I can try to find a different selector to use for camera and mic buttons

Happy to hear that!
I've noticed the following:

  1. 1a.
    Both the camera and the mic button have the following className attached: U26fgb JRY2Pb mUbCce kpROve yBiuPb y1zVCf HNeRed M9Bg4d
    1.b
    The className illustrated at 1.a can't be used sadly since it's used both by the camera and the mic. So we could target a child with a unique value to the mic (and another one unique to the camera) and then ramp up to the first parent that has the previously illustrated className.
    As a last resort, if no unique class name can be found between the children, the SVG path of the icon would be the unique value (this is the one of the mic for example: M11 5c0-.55.45-1 1-1s1 .45 1 1v5.17l1.82 1.82c.11-.31.18-.64.18-.99V5c0-1.66-1.34-3-3-3S9 3.34 9 5v1.17l2 2V5zM2.81 2.81L1.39 4.22l11.65 11.65c-.33.08-.68.13-1.04.13-2.76 0-5-2.24-5-5H5c0 3.53 2.61 6.43 6 6.92V21h2v-3.08c.57-.08 1.12-.24 1.64-.46l5.14 5.14 1.41-1.41L2.81 2.81zM19 11h-2c0 .91-.26 1.75-.69 2.48l1.46 1.46A6.921 6.921 0 0 0 19 11z).

  2. Instead of doing this: btn.ariaLabel.includes('on'), please check the data-is-muted attribute of the HTML element targeted by the className of point 1.a. (when true, it means the device is disabled)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Suggestion Auto join: auto select pref.
3 participants