HomePhabricator

Smarter setting of the "gravity" of tooltips
6ec834fd93e9Unpublished

Authored by WMDE-leszek on Jul 22 2016, 1:00 PM.

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

Smarter setting of the "gravity" of tooltips

This adjusts the position of the tooltip depending on what is the
position of the related revision bar in the plot, and on the
size of the contents of the tooltip.

Among other things this makes the tooltip be displayed below
the revision plot if the tooltip would not be entirely visible
if it was displayed above the plot.
Also now it is checked if there is enough space on the left and right
side of the browser window to display the tooltip centered horizontally.
If not, this adjusts the horizontal position of the tooltip so that
it does not get shown outside of the window.
The latter in particular improves displaying of longer edit
summaries in RTL mode. Apparently LTR-centered browsers took care
of not showing the tooltip outside the right edge of the window
but in the case of left edge the tooltip could run outside of the window
leaving a part of summary not visible to the user without scrolling.

Bug: T141071
Bug: T141093
Change-Id: I8d519c5fd42d8403b527fa97d72a5c46991fc27b

Details

Committed
WMDE-leszekJul 22 2016, 1:16 PM
Parents
rERSL23348bae7457: Fix naming issues in some messages
Branches
Unknown
Tags
Unknown
References
refs/changes/41/300541/1
ChangeId
I8d519c5fd42d8403b527fa97d72a5c46991fc27b