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

Multiple hints on the same components when pressing 'f' #4635

Open
0xmzn opened this issue Feb 14, 2025 · 1 comment
Open

Multiple hints on the same components when pressing 'f' #4635

0xmzn opened this issue Feb 14, 2025 · 1 comment

Comments

@0xmzn
Copy link

0xmzn commented Feb 14, 2025

Describe the bug

Since I started using vimium, I noticed a weird behavior across multiple sites that goes as follows: whenever I press f, I would see that some parts of the web page have multiple hint (sometimes overlaying that you can't actually see the complete key sequence). See the screenshots below for examples. I am not sure if this is the intended behavior,

To Reproduce

Steps to reproduce the behavior:

  1. Go to any YouTube Video URL 'https://youtu.be/jeRSReSbxjw?si=NbvmJiXL_r7y-MXN'
  2. Press f to view the hints.

NOTE: I am not sure that it's reproducible or not because I remember using Vimium on a friend's machine I didn't have these issues.

Include a screenshot if applicable.

YouTube example:
Image

Github example (check the top part):
Image

Browser and Vimium version

Chrome Version: 132.0.6834.196 (Official Build) (64-bit) (cohort: Control)
Vimium Version: 2.1.2

@0xmzn
Copy link
Author

0xmzn commented Feb 14, 2025

Trying to understand why this behavior happens, I checked the HTML code for the fullscreen button on youtube:

Image

And found out that the code for it looks like this:

<button class="ytp-fullscreen-button ytp-button" aria-keyshortcuts="f" data-priority="11" data-title-no-tooltip="Full screen" aria-label="Full screen keyboard shortcut f" title="Full screen (f)">
   <svg height="100%" version="1.1" viewBox="0 0 36 36" width="100%">
      <g class="ytp-fullscreen-button-corner-0">
         <use class="ytp-svg-shadow" xlink:href="#ytp-id-907"></use>
         <path class="ytp-svg-fill" d="m 10,16 2,0 0,-4 4,0 0,-2 L 10,10 l 0,6 0,0 z" id="ytp-id-907"></path>
      </g>
      <g class="ytp-fullscreen-button-corner-1">
         <use class="ytp-svg-shadow" xlink:href="#ytp-id-908"></use>
         <path class="ytp-svg-fill" d="m 20,10 0,2 4,0 0,4 2,0 L 26,10 l -6,0 0,0 z" id="ytp-id-908"></path>
      </g>
      <g class="ytp-fullscreen-button-corner-2">
         <use class="ytp-svg-shadow" xlink:href="#ytp-id-909"></use>
         <path class="ytp-svg-fill" d="m 24,24 -4,0 0,2 L 26,26 l 0,-6 -2,0 0,4 0,0 z" id="ytp-id-909"></path>
      </g>
      <g class="ytp-fullscreen-button-corner-3">
         <use class="ytp-svg-shadow" xlink:href="#ytp-id-910"></use>
         <path class="ytp-svg-fill" d="M 12,20 10,20 10,26 l 6,0 0,-2 -4,0 0,-4 0,0 z" id="ytp-id-910"></path>
      </g>
   </svg>
</button>

I suppose the correct behavior for Vimium in this case is to only give me a hint for the top level element only and ignore its children, i.e. It should only show key hints for the Button but instead it shows one for the button and one for each <g>...</g> tag underneath it.

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

No branches or pull requests

1 participant