I wonder what the the part ::-webkit-search-decoration
do in the CSS selector for input[type="search"]::-webkit-search-decoration
?
And why is this causing en DOM Exception error?
function is(selector, element) {
var div = document.createElement("div"),
matchesSelector = div.webkitMatchesSelector;
return typeof selector == "string" ? matchesSelector.call(element, selector) : selector === element;
}
is('input[type="search"]::-webkit-search-decoration', document.body);
"::-webkit-search-decoration"
part of the selector."::-webkit-progress-value"
. I guess that certain webkit-specific pseudo-elements simply cannot be used with.webkitMatchesSelector()
.