[RTL] Mirror the new Picture-in-Picture icons
Categories
(Toolkit :: Video/Audio Controls, defect, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox72 | --- | verified |
People
(Reporter: itiel_yn8, Assigned: mconley)
References
Details
(Keywords: rtl)
Attachments
(1 file)
In RTL the default location of the PiP window is on the bottom left, so the new icons should be mirrored.
Some of the places where it should be mirrored:
https://searchfox.org/mozilla-central/rev/3483fb259b4edbe4594cfcc3911db97d5441b67d/toolkit/themes/shared/media/videocontrols.css#433
https://searchfox.org/mozilla-central/rev/3483fb259b4edbe4594cfcc3911db97d5441b67d/toolkit/themes/shared/media/videocontrols.css#459
https://searchfox.org/mozilla-central/rev/3483fb259b4edbe4594cfcc3911db97d5441b67d/browser/themes/shared/tabs.inc.css#403
https://searchfox.org/mozilla-central/rev/3483fb259b4edbe4594cfcc3911db97d5441b67d/toolkit/themes/shared/pictureinpicture/player.css#130
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Comment 1•5 years ago
|
||
Updated•5 years ago
|
Assignee | ||
Comment 2•5 years ago
|
||
In order to test this, I:
- Set
intl.uidirection
to 1 - Visited a YouTube video, and manually set the
dir
property on the<body>
element tortl
.
Pushed by mconley@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b967fa56b86e Mirror the Picture-in-Picture icons for RTL locales. r=mstriemer
Comment 4•5 years ago
|
||
bugherder |
This is not 100% fixed on latest Nightly. Specifically, these two are not applied:
https://searchfox.org/mozilla-central/rev/cce8b90aece0f42e5025e45282de16066eeaa662/toolkit/themes/shared/media/videocontrols.css#472-473
Changing them to use -moz-locale-dir(rtl)
doesn't work, but dir(ltr)
and -moz-locale-dir(ltr)
does. Not sure why :-(
(And regardless, shouldn't them both use -moz-locale-dir
instead?)
Assignee | ||
Comment 6•5 years ago
|
||
(In reply to Itiel from comment #5)
This is not 100% fixed on latest Nightly. Specifically, these two are not applied:
https://searchfox.org/mozilla-central/rev/cce8b90aece0f42e5025e45282de16066eeaa662/toolkit/themes/shared/media/videocontrols.css#472-473
Changing them to use-moz-locale-dir(rtl)
doesn't work, butdir(ltr)
and-moz-locale-dir(ltr)
does. Not sure why :-(
What sites did you test them on? These selectors will only apply if the document itself is set to render in RTL.
(And regardless, shouldn't them both use
-moz-locale-dir
instead?)
I'm afraid that in content processes, -moz-locale-dir
is unreliable - see https://developer.mozilla.org/en-US/docs/Web/CSS/:-moz-locale-dir(rtl) - specifically:
This selector does not work properly from HTML; it never matches, no matter whether the UI locale is left-to-right or right-to-left.
(In reply to Mike Conley (:mconley) (:⚙️) (Wayyyy behind on needinfos) from comment #6)
What sites did you test them on? These selectors will only apply if the document itself is set to render in RTL.
The RTL Hebrew version of YouTube, and 9gag.
But.. re-testing, this now works (on YouTube).
(And regardless, shouldn't them both use
-moz-locale-dir
instead?)I'm afraid that in content processes,
-moz-locale-dir
is unreliable - see https://developer.mozilla.org/en-US/docs/Web/CSS/:-moz-locale-dir(rtl) - specifically:This selector does not work properly from HTML; it never matches, no matter whether the UI locale is left-to-right or right-to-left.
Hmm I see.
The icons should still be mirrored regardless of the direction set on the document.
Is there a workaround for this, besides serving a pre-mirrored version of the SVG for RTL?
Assignee | ||
Comment 8•5 years ago
|
||
(In reply to Itiel from comment #7)
Is there a workaround for this, besides serving a pre-mirrored version of the SVG for RTL?
Not that I'm aware of, no.
Comment 9•4 years ago
|
||
Build ID 20191202091209
User Agent Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0
Verified as fixed on the latest version of Firefox Nightly (72.0a1) on Windows 10.
Description
•