selectCssRuleWithSelector function
Returns a list of CssRule with targetSelector
patterns.
Implementation
List<CssRule> selectCssRuleWithSelector(Pattern targetSelector) {
var sheets = getAllCssStyleSheet();
var rules = sheets
.map((s) => getAllCssRuleBySelector(targetSelector, s))
.expand((e) => e)
.toList();
return rules;
}