I am attempting to insert a rule into a stylesheet. The rule is valid (I think) and is taken from normalize.css (https://github.com/necolas/normalize.css/blob/master/normalize.css#L206-L212) my code is:
var styleEl = document.createElement('style');
document.head.appendChild(styleEl);
var styleSheet = styleEl.sheet;
styleSheet.insertRule('button::-moz-focus-inner, [type="button"]::-moz-focus-inner, [type="reset"]::-moz-focus-inner, [type="submit"]::-moz-focus-inner{border-style: none;padding: 0;}');
Chrome (75.0.3770.100) throws the error:
VM381:1 Uncaught DOMException: Failed to execute 'insertRule' on 'CSSStyleSheet': Failed to parse the rule 'button::-moz-focus-inner, [type="button"]::-moz-focus-inner, [type="reset"]::-moz-focus-inner, [type="submit"]::-moz-focus-inner{border-style: none;padding: 0;}'.
at <anonymous>:1:12
The code above is used to insert other rules and works fine. It's just this rule that fails. Is this a malformed rule in normalize.css?