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

Change how "Preview" works (when blocking element manually) #286

Closed
ameshkov opened this issue Jul 15, 2016 · 0 comments

Comments

Projects
None yet
2 participants
@ameshkov
Copy link
Member

commented Jul 15, 2016

Currently we simply hide selected element. The problem is that rule can cover more than one element and you can't see it in preview.

We should add a style instead, something like that:
<style id="adguard-preview" type="text/css">CSS rule</style>

Remove that style when user clicks "cancel preview" or selects another element.

For "URL" blocking rules use the old way with hiding an element at first. Add one more step after that: hide all elements with the same "src" as in selected element. Something like that:
$('[src="' + url + '"]:visible').addClass('adguard-preview-hidden').hide()

This logic should be used for both "Assistant" module and dev tools.

@ameshkov ameshkov added this to the 2.4 milestone Jul 15, 2016

Mizzick added a commit that referenced this issue Jul 16, 2016

Mizzick added a commit that referenced this issue Jul 16, 2016

Mizzick added a commit that referenced this issue Jul 16, 2016

Mizzick added a commit that referenced this issue Jul 16, 2016

Mizzick added a commit that referenced this issue Jul 18, 2016

@Mizzick Mizzick closed this Jul 18, 2016

Mizzick added a commit that referenced this issue Jul 18, 2016

ameshkov pushed a commit that referenced this issue Dec 28, 2018

Maxim Topciu
Merge pull request #286 in EXTENSIONS/browser-extension from feature/…
…1158 to feature/redesign

* commit '3f5629bf557e9a01243b817541fa080921184399':
  feature/1158 check if stealth mode is disabled
  feature/1158 fix link
  feature/1158 generate link for reporter considering stealth disabled setting
  feature/1158 refactoring
  add memo
  feature/1158 change default stealth settings
  feature/1158 take in consideration global stealth mode setting
  feature/1158 add setting template
  feature/1158 rename privacy to stealth mode
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.