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

Modernizr.boxshadow returns true on webOS though box-shadow is not supported. #145

Closed
typeoneerror opened this issue Nov 16, 2010 · 7 comments

Comments

@typeoneerror
Copy link

Not sure if this is a bug or not, but I'm testing for box-shadow support on the webOS emulator, and it returns true, though box-shadow is not supported:

if (Modernizr.boxshadow)
{
    alert("box shadow is supported");
}
@paulirish
Copy link
Member

well that sucks. :(

@paulirish
Copy link
Member

typeonerror, if you had some time to see if there is another detect that works on webos that'd be great.

but this probably means

elem.style.webkitBoxShadow === '' // true
'webkitBoxShadow' in elem.style // true

i wonder if setting the value and seeing if it comes back correctly will work.. (probably)

@typeoneerror
Copy link
Author

typeonerror, if you had some time to see if there is another detect
that works on webos that'd be great.

This detect works as expected (alerts):

if (Modernizr.borderradius)
{
    alert("works");
}

Not sure if that's what you mean. I'm working with webOS emulator all week so let me know if there's anything you want to test explicitly. To note, this alerts "false" on webOS, so perhaps they have an incomplete implementation of box-shadow. It says it's not supported, and definitely doesn't work when applied via CSS:

alert(document.getElementById("test").style.webkitBoxShadow === undefined);

@typeoneerror
Copy link
Author

This also does not work:

document.getElementById("test").style.webkitBoxShadow = "5px 5px 5px #000";

@KuraFire
Copy link
Member

By "does not work", what do you mean?

What we would like to know is a way wherein the test sets a box shadow, returns false on webOS emulator, but still returns true in e.g. Safari or Chrome.

@typeoneerror
Copy link
Author

@KuraFire box shadow is not supported on webOS as far as I can tell. So setting it does nothing visually. But Modernizr reports that it is available. It seems to me more like a webOS bug than Modernizr.

@paulirish
Copy link
Member

webos false positives on the boxshadow test. closed by b5790ae

paulirish added a commit to SlexAxton/Modernizr that referenced this issue May 26, 2011
patrickkettner pushed a commit to patrickkettner/Modernizr that referenced this issue Feb 22, 2015
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants