closure/goog/html/cssspecificity.js
function replaceWithPlainText(selector, regex) {
  return selector.replace(regex, function(match) {
    return Array(match.length + 1).join('A');
  });
}
function replaceWithPlainText(selector, regex) {
  return selector.replace(regex, function(match) {
    return Array(match.length + 1).join('A');
  });
}
function replaceWithPlainText ( selector , regex ) { return selector . replace ( regex , function ( match ) { return Array ( match . length + 1 ) . join ( 'A' ) ; } ) ; }
Replace escaped characters with plain text, using the "A" character.
@see https://www.w3.org/TR/CSS21/syndata.html#characters
@param {string} selector
@param {!RegExp} regex
@return {string}
Replace escaped characters with plain text using the A character .