Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: lib/filterClasses.js

Issue 29324599: Issue 2392/2393 - Created container for CSS property filters (Closed)
Patch Set: Created Aug. 25, 2015, 3:35 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: lib/filterClasses.js
===================================================================
--- a/lib/filterClasses.js
+++ b/lib/filterClasses.js
@@ -108,7 +108,7 @@
let ret;
let match = (text.indexOf("#") >= 0 ? Filter.elemhideRegExp.exec(text) : null);
if (match)
- ret = ElemHideBase.fromText(text, match[1], match[2], match[3], match[4], match[5]);
+ ret = ElemHideBase.fromText(text, match[1], !!match[2], match[3], match[4], match[5]);
else if (text[0] == "!")
ret = new CommentFilter(text);
else
@@ -862,11 +862,12 @@
/**
* Creates an element hiding filter from a pre-parsed text representation
*
- * @param {String} text same as in Filter()
- * @param {String} domain domain part of the text representation (can be empty)
- * @param {String} tagName tag name part (can be empty)
- * @param {String} attrRules attribute matching rules (can be empty)
- * @param {String} selector raw CSS selector (can be empty)
+ * @param {String} text same as in Filter()
+ * @param {String} domain domain part of the text representation (can be empty)
+ * @param {Boolean} isException exception rule indicator
+ * @param {String} tagName tag name part (can be empty)
+ * @param {String} attrRules attribute matching rules (can be empty)
+ * @param {String} selector raw CSS selector (can be empty)
* @return {ElemHideFilter|ElemHideException|CSSPropertyFilter|InvalidFilter}
*/
ElemHideBase.fromText = function(text, domain, isException, tagName, attrRules, selector)

Powered by Google App Engine
This is Rietveld