Closed
Bug 1498860
Opened 6 years ago
Closed 6 years ago
Consider implementing window.screenLeft and window.screenTop
Categories
(Core :: DOM: CSS Object Model, enhancement, P3)
Core
DOM: CSS Object Model
Tracking
()
RESOLVED
FIXED
mozilla64
Tracking | Status | |
---|---|---|
firefox64 | --- | fixed |
People
(Reporter: emilio, Assigned: emilio)
Details
(Keywords: dev-doc-complete)
Attachments
(1 file)
Looks like other browsers support it as basically aliases of screenX / screenY, and that they're not willing to remove them, see: * https://github.com/w3c/csswg-drafts/issues/1091 * https://bugs.chromium.org/p/chromium/issues/detail?id=695572
Assignee | ||
Comment 1•6 years ago
|
||
Boris, would you have anything against doing this, provided relevant spec changes are made?
Flags: needinfo?(bzbarsky)
Comment 2•6 years ago
|
||
given that there are also other weird aliases for other coordinates, it is somewhat hard to argue why not do this.
Assignee | ||
Comment 3•6 years ago
|
||
Alright, I can implement this once the tests and the spec are sorted out.
Assignee: nobody → emilio
Flags: needinfo?(emilio)
I'd also argue that screenLeft and screenTop are *better* names than screenX and screenY since they make the coordinate system clearer. (For RTL use cases you might even want screenRight...)
Updated•6 years ago
|
Priority: -- → P3
Assignee | ||
Comment 6•6 years ago
|
||
Tests are at https://github.com/web-platform-tests/wpt/pull/13543. Spec is waiting on those, but this matches all other browsers.
Assignee | ||
Updated•6 years ago
|
Flags: needinfo?(emilio)
Pushed by emilio@crisal.io: https://hg.mozilla.org/integration/autoland/rev/7b427b166742 Add window.screenLeft / window.screenTop as aliases of screenX / screenY. r=smaug
Comment 8•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/7b427b166742
Status: NEW → RESOLVED
Closed: 6 years ago
status-firefox64:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
Updated•6 years ago
|
Flags: webcompat+
Updated•6 years ago
|
Keywords: dev-doc-needed
Updated•6 years ago
|
Flags: qe-verify-
Comment 9•5 years ago
|
||
Note to docs team: I have added a note to the Fx 64 rel notes to cover this: https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Releases/64#APIs The ref pages will both need writing, and compat data updating, when this is documented.
Comment 10•5 years ago
|
||
Documented: I added new pages for the new properties, and also improved the pages for screenX/screenY: https://developer.mozilla.org/en-US/docs/Web/API/Window/screenLeft https://developer.mozilla.org/en-US/docs/Web/API/Window/screenTop https://developer.mozilla.org/en-US/docs/Web/API/Window/screenX https://developer.mozilla.org/en-US/docs/Web/API/Window/screenY The pages link to a fun little demo I wrote to demonstrate how the properties work: https://mdn.github.io/dom-examples/screenleft-screentop/ I also added the relevant compat data: https://github.com/mdn/browser-compat-data/pull/3106 Let me know if this looks OK. Thanks!
Keywords: dev-doc-needed → dev-doc-complete
You need to log in
before you can comment on or make changes to this bug.
Description
•