jsdom / cssstyle

A Node.js implementation of the CSS Object Model CSSStyleDeclaration interface
MIT License
109 stars 70 forks source link

width and height value of auto is not supported #40

Closed dpvc closed 8 years ago

dpvc commented 8 years ago

Setting a style of auto for width or height doesn't work. This is because the use of parseMeasurement() in the set method doesn't pass auto, so nothing is done.

Here is an example:

var cssstyle = require("./lib/CSSStyleDeclaration");
var style = new cssstyle.CSSStyleDeclaration();
style.width = "auto";
console.log(style);
console.log(style.width);
console.log(style.cssText);

This prints three blank lines rather than the expected two lines of auto followed by width: auto;.

chad3814 commented 8 years ago

published in cssstyle@0.2.36; sorry I missed the issue and PR