css-displayrunin.js 402 B

123456789101112131415161718
  1. // by alanhogan
  2. // https://github.com/Modernizr/Modernizr/issues/198
  3. // http://css-tricks.com/596-run-in/
  4. Modernizr.testStyles(' #modernizr { display: run-in; } ', function(elem, rule){
  5. var ret = (window.getComputedStyle ?
  6. getComputedStyle(elem, null).getPropertyValue('display') :
  7. elem.currentStyle['display']);
  8. Modernizr.addTest('display-runin', ret == 'run-in');
  9. });