Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider supporting mixed if-domain / unless-domain for cosmetic rules #66

Open
ameshkov opened this issue Dec 15, 2024 · 1 comment
Open
Labels
enhancement New feature or request

Comments

@ameshkov
Copy link
Member

Here's the idea:

example.org,~sub.example.org##.banner

Could be converted to something like that:

{
    "url-filter": "example.org",
    "unless-domain": ["*sub.example.org"]
}
@ameshkov
Copy link
Member Author

This approach is confirmed to be working.

Here's an example:

agrd.dev,~httpbin.agrd.dev##body

Can be converted to this:

[
  {
    "action" : {
      "type" : "css-display-none",
      "selector": "body"
    },
    "trigger" : {
      "url-filter" : "^[htpsw]+:\\\/\\\/([a-z0-9-]+\\.)?agrd.dev([\\\/:&\\?].*)?",
      "unless-domain": ["*httpbin.agrd.dev"]
    }
  }
]
  • httpbin.agrd.dev -- nothing is hidden
  • testcases.agrd.dev -- body is hidden

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant