AdguardTeam / AdguardAssistant

Adguard Assistant userscript
GNU General Public License v3.0
147 stars 19 forks source link

Dynamic divs aren't blocked #364

Closed AlKulagin23 closed 2 years ago

AlKulagin23 commented 2 years ago

The ad blocking function in the assistant no longer works. When you use the 'block ads on this website' function, dynamic div's reappear after restarting the browser on all sites.

E.g. you can check on mail.ru by hiding PULSE or any other ad block with dynamic divs

-

Ublock uses a rule to block 'PULSE': mail.ru##.pulse-lenta

We create the rule: mail.ru###grid\:middle > div.uTJd8A1.svelte-8o68oz:nth-child(2) > div:nth-child(4) > div.pulse-lenta:first-child > div.pl_a > div.pl_a4.pulse-lenta-layout.pl_a5

Tested in Chrome, Opera, Firefox

ameshkov commented 2 years ago

I am not sure where's a bug here.

In the Assistant, we create rules that block exactly the selected element and not ALL elements that have a similar class. Of course, this approach has some limitations as in this example, but I still find it better for a casual user.

PS: You can create broader rules using Assistant as well: image