hyperscript
Advanced tools
Comparing version 2.0.1 to 2.0.2
22
index.js
var split = require('browser-split') | ||
var ClassList = require('class-list') | ||
var htmlElement = require('html-element'); | ||
var document = htmlElement.document || window.document; | ||
var Text = htmlElement.Text || window.Text; | ||
var w = typeof window === 'undefined' ? require('html-element') : window | ||
var document = w.document | ||
var Text = w.Text | ||
@@ -94,6 +94,16 @@ function context () { | ||
} else | ||
e.style.setProperty(s, l[k][s]) | ||
var match = l[k][s].match(/(.*)\W+!important\W*$/); | ||
if (match) { | ||
e.style.setProperty(s, match[1], 'important') | ||
} else { | ||
e.style.setProperty(s, l[k][s]) | ||
} | ||
})(s, l[k][s]) | ||
} | ||
} else if (k.substr(0, 5) === "data-") { | ||
} else if(k === 'attrs') { | ||
for (var v in l[k]) { | ||
e.setAttribute(v, l[k][v]) | ||
} | ||
} | ||
else if (k.substr(0, 5) === "data-") { | ||
e.setAttribute(k, l[k]) | ||
@@ -150,1 +160,3 @@ } else { | ||
} | ||
{ | ||
"name": "hyperscript", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"homepage": "https://github.com/dominictarr/hyperscript", | ||
@@ -5,0 +5,0 @@ "repository": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
47838
283