-
Notifications
You must be signed in to change notification settings - Fork 7.4k
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
Fix/time tooltip overflow #8530
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #8530 +/- ##
==========================================
- Coverage 82.65% 82.64% -0.02%
==========================================
Files 113 113
Lines 7605 7605
Branches 1828 1830 +2
==========================================
- Hits 6286 6285 -1
- Misses 1319 1320 +1 ☔ View full report in Codecov by Sentry. |
830d8dc
to
72b0c27
Compare
@amtins, just a quick feedback re out of bounds: at the moment the tooltips do not go out of bounds of the container, but they also do not go out of bounds of the seekbar. I think the boundary should still be the container. |
TL;DR: It's a complex case with a multitude of edge cases @phloxic thanks for your feedback, that's exactly what I'm trying to determine/understand. If I summarize, I see 3 cases: 1. The experience currently proposed by
If we want to keep this experience regardless of the various problems reported by the different issues. I think we can easily simplify the code. This is exactly what commits 37f6acb and b28bf97 do, where css is preferred to javascript to center the timeTooltip. Technically it's debatable as this type of positioning prevents the application of a transform scale. However, I don't see this as a regression, as However, I'd like to reiterate that there may be use cases that I've missed. 2. The This is the experience offered by this PR. Personally, I don't really have an opinion/preference as to whether it's a good or bad experience. What I do notice is that it would greatly simplify the code base. However, as you rightly point out, there is a edge case due to the fact that the 3. The I have the impression that this is the experience you're proposing, don't hesitate to correct me if I'm wrong. With this approach, the If I explore this path, I see a potential problem: If the calculation reference point becomes the A potential solution would therefore be to take only the
In conclusion, now I'm beginning to understand the complexity of the subject. I was a little too naive in my approach. 😅 |
I tried to explore option 3 without success. However, I created an example page with option 2 without the bug described below:
Test page: https://amtins.github.io/bug-free-noodles/ Unfortunately I'm afraid that's the best solution I can come up with. |
I'm not 100% sure I understand. If it comes to centering, in my view the tooltips are centered over the relevant position (current time or mouse respectively) in the timeline (be that playProgressBar or seekBar). I believe this makes sense from the user perspective, and it should be the case as much as possible. The problem is: where are the limits for what one considers as "possible".
At least in the stage I tested, the limits of what is possible have shrunk compared to the current release. On both sides the tooltips are 'de-centered' when the play-head or the cursor/mouse-time are nearer to the end of the playProgress than half their width.
I do have an opinion ;-) As above my opinion is that the cases where the toolips are 'de-centered' should be reduced as much as possible. Their connection to their reference point is 'stretched' and the viewer has a moment of: Oh, what's happening, ah, ok, there is some kind of limit, tooltip banged at door frame (hehe) ...
Yes, I thought it was related to the lack of smooth seeking (I 'backported' smooth seeking immediately to v7 in my deployments).
Indeed. It is also the current behaviour, or was, until it was changed (or rather disabled) for the right side because of eac77b4 – which is why I wanted to revert it.
Can one make the controlBar shorter than the player? If yes, then I am for
I don't understand exactly, sorry.
Regardless of coding problems, this would make the most sense to me.
Massive tooltip speech bubbles?! ;-) But yes, all these elements are dependent of the player, especially the tooltips. In principle they should stay in there (my door frame analogy). – That being said, when I experimented with applying scale to the player the boundary was gone on both sides .
Nevermind, only teething problems.
Welcome to the club. 😅 |
Thanks for that. I like the CSS approach.
It's certainly more consistent than the current state. And I obviously have no problem with examples 3 and 4 because the progress bar spans the entire width of the player. |
@phloxic I think I have a solution that might meet your preference and also solve the problem when a transform scale is applied to the player. Please see https://amtins.github.io/bug-free-noodles/scale.html |
@amtins - almost there. Great. From the viewer's perspective it makes sense structurally and aesthetically to use the player boundaries as tooltip boundaries. I don't think the intended behaviour should be changed. My test page. The non-scaled version seems to be there. And of course it requires smooth-seeking. Which is fine by me, but may be an issue for others. Test of current behaviour for comparison. |
Description
Specific Changes proposed
Requirements Checklist