FiltersCompiler
FiltersCompiler copied to clipboard
`^script:has-text` is not converted to AdGuard syntax
Related to ##^script:has-text
Updated AdGuard $$ syntax:
https://adguard.com/kb/general/ad-filtering/create-own-filters/#html-filtering-rules
For example, AdGuard for Windows converts uBO's HTML filtering rule
forbes.com##^script:has-text(scriptTag)
to AdGuard's
forbes.com$$script[tag-content="scriptTag"][max-length="262144"]
But conversion is not applied to unblocking rules
forbes.com#@#^script:has-text(scriptTag)
This causes the error during compiling filters:
Error: Invalid selector: '^script:has-text(responseText)' -- Error: unable to select by '^script' — '^script' is not a valid selector in rule: mail.walla.co.il#@#^script:has-text(responseText)