Skip to content
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

is there a way to implement element.offsetLeft and element.offsetTop #61

Closed
shimondoodkin opened this issue Oct 24, 2010 · 7 comments
Closed

Comments

@shimondoodkin
Copy link
Contributor

is there a way to implement element.offsetLeft and element.offsetTop

i want this to work:
http://github.com/shimondoodkin/nodejs-waze

@davglass
Copy link
Contributor

We could add default expandos for offsetLeft/offsetTop, but that's all they would be. The default would be 0 and if scripts set them they will be set (similar to style) but they will have no meaning.

@tmpvar
Copy link
Member

tmpvar commented Jun 19, 2011

work has begun on integrating the cssom

@jcollum
Copy link

jcollum commented May 10, 2013

Has there been any progress on this? I'm using jsdom to run some tests on handsontable and they're failing because elem.offsetLeft is null.

@domenic
Copy link
Member

domenic commented May 10, 2013

I think there's much better CSS support now but we haven't used it to implement offsetLeft and offsetTop. @chad3814 might have more insight (he did the CSS stuff).

@domenic
Copy link
Member

domenic commented May 10, 2013

Looking at the spec it seems extremely unlikely jsdom has the infrastructure to support implementing this. Things like "return the x-coordinate of the left border edge of the first CSS layout box associated with the element, relative to the initial containing block origin" are not at all something we're prepared to deal with.

@jcollum
Copy link

jcollum commented May 10, 2013

OK I'll just work around it in the handsontable source code.

On Fri, May 10, 2013 at 11:51 AM, Domenic Denicola <notifications@github.com

wrote:

Looking at the spec http://www.w3.org/TR/cssom-view/#offset-attributesit seems extremely unlikely jsdom has the infrastructure to support
implementing this. Things like "return the x-coordinate of the left border
edge of the first CSS layout box associated with the element, relative to
the initial containing block origin" are not at all something we're
prepared to deal with.


Reply to this email directly or view it on GitHubhttps://github.com//issues/61#issuecomment-17737915
.

@domenic
Copy link
Member

domenic commented Jul 9, 2014

Subsuming into #135.

@domenic domenic closed this as completed Jul 9, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants