src/hft/scripts/misc/misc.js
function(selector) {
    for (var ii = 0; ii < document.styleSheets.length; ++ii) {
      var styleSheet = document.styleSheets[ii];
      var rules = styleSheet.cssRules || styleSheet.rules;
      if (rules) {
        for (var rr = 0; rr < rules.length; ++rr) {
          var rule = rules[rr];
          if (rule.selectorText === selector) {
            return rule;
          }
        }
      }
    }
  }
function(selector) {
    for (var ii = 0; ii < document.styleSheets.length; ++ii) {
      var styleSheet = document.styleSheets[ii];
      var rules = styleSheet.cssRules || styleSheet.rules;
      if (rules) {
        for (var rr = 0; rr < rules.length; ++rr) {
          var rule = rules[rr];
          if (rule.selectorText === selector) {
            return rule;
          }
        }
      }
    }
  }
function ( selector ) { for ( var ii = 0 ; ii < document . styleSheets . length ; ++ ii ) { var styleSheet = document . styleSheets [ ii ] ; var rules = styleSheet . cssRules || styleSheet . rules ; if ( rules ) { for ( var rr = 0 ; rr < rules . length ; ++ rr ) { var rule = rules [ rr ] ; if ( rule . selectorText === selector ) { return rule ; } } } } }
finds a CSS rule.
@param {string} selector
@return {Rule?} matching css rule
@memberOf module:Misc
finds a CSS rule .