video.js icon indicating copy to clipboard operation
video.js copied to clipboard

Fix mouse time tooltip when moved to far right of progress bar

Open PikachuEXE opened this issue 3 years ago • 9 comments

Description

Fix mouse time tooltip when moved to far right of progress bar

Linked issue: #7248

Specific Changes proposed

Please list the specific changes involved in this pull request.

Requirements Checklist

  • [x] Bug fixed
  • [ ] If necessary, more likely in a feature request than a bug fix
    • [x] Change has been verified in an actual browser (FreeTube dev version)
    • [ ] Unit Tests updated or fixed
    • [ ] Docs/guides updated
    • [ ] Example created (starter template on JSBin)
  • [ ] Reviewed by Two Core Contributors

PikachuEXE avatar Jul 06 '21 03:07 PikachuEXE

💖 Thanks for opening this pull request! 💖

Things that will help get your PR across the finish line:

  • Run npm run lint -- --errors locally to catch formatting errors earlier.
  • Include tests when adding/changing behavior.
  • Include screenshots and animated GIFs whenever possible.

We get a lot of pull requests on this repo, so please be patient and we will get back to you as soon as we can.

welcome[bot] avatar Jul 06 '21 03:07 welcome[bot]

I have this problem too.

peepo5 avatar Jul 06 '21 07:07 peepo5

Unfortunately, this change basically reverts the change from #5773 which fixes #6726 and #1102. With this change, if you set transform: scale(1.5) for example, the mouse tooltip positions don't align properly. We'd love to get #7248 fixed but we wouldn't want it to break other usecases.

gkatsev avatar Jul 28 '21 21:07 gkatsev

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jan 08 '22 23:01 stale[bot]

Unfortunately, this change basically reverts the change from #5773 which fixes #6726 and #1102. With this change, if you set transform: scale(1.5) for example, the mouse tooltip positions don't align properly. We'd love to get #7248 fixed but we wouldn't want it to break other usecases.

@gkatsev - I can repro the alignment issues with 7.9.3, however it looks like the fix/reversal could be applied in current versions. I did some quick tests with v7.21.4 and v8.3.0 (patch applied) and transform: scale(1.5) and do not see the alignment issues.

phloxic avatar May 12 '23 14:05 phloxic

Codecov Report

Merging #7308 (c5fdd46) into main (a8a5e02) will increase coverage by 2.90%. The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main    #7308      +/-   ##
==========================================
+ Coverage   79.45%   82.36%   +2.90%     
==========================================
  Files         115      112       -3     
  Lines        7266     7483     +217     
  Branches     1746     1804      +58     
==========================================
+ Hits         5773     6163     +390     
+ Misses       1493     1320     -173     
Impacted Files Coverage Δ
...s/control-bar/progress-control/progress-control.js 26.66% <0.00%> (ø)

... and 72 files with indirect coverage changes

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

codecov[bot] avatar May 19 '23 13:05 codecov[bot]

@mister-ben, @gkatsev imho this is still needed.

phloxic avatar Nov 25 '23 07:11 phloxic

@phloxic to help me understand, is the transform: scale(1.5) applied to the whole player?

.video-js {
  transform: scale(1.5);
}

amtins avatar Dec 15 '23 19:12 amtins

@amtins, thanks for insisting. Indeed I applied the scale to the tooltip instead of the container, duh. It did not help that with video.js in 9.3 I saw misaligned tooltips when scaling them. These do not appear in more recent versions, "fix" or no "fix". So, yes, something is needed when the container is transformed, but also something is needed to avoid the tooltip sticking out on the right side, the same way as on the left side. This backout change helps with symmetric behaviour, but apparently brings back problem with transformed containers. As an aside: When the container is scaled, the tooltip(s) may stick out both sides.

phloxic avatar Dec 15 '23 21:12 phloxic