MV3 improvements - #2820
Merged
Merged
MV3 improvements#2820
Conversation
Invert block rules from every enabled list EXCEPT a malware/badware/ anti-adblock/social keep-block set (so easylist, easyprivacy, etc. are allowed and ads load to be collected). Stamp keep-block lists' block rules at priority 30 so they outrank adn-allow (20) and can never be overridden.
Complete enables generic cosmetic filtering everywhere by default, so all ads are hidden and the parser (registered for optimal+complete) runs on every site.
…t guards - Use opacity:0!important (not display:none) for generic + procedural paths, so hidden ads stay rendered/collectable. - Publish the resolved ad selectors to self.adnAdSelectors so the parser can scan exactly the elements uBlock hides. - Guard chrome.runtime.sendMessage against an invalidated extension context.
…ttling - Resolve images from <picture>, srcset (largest), bg-image, and nearby ancestors/iframe; port MV2-level coverage. - Strip <script>/<style> from text and reject JS-as-text for title/text. - Scan self.adnAdSelectors (published by cosmetic scripts) plus fallbacks. - Throttled reprocessing (canProcess/markProcessed) so rotating ad slots are re-examined without a runaway loop; guard invalidated context. - 'Pending' title fallback so a real title can be resolved on visit.
…Style default - looksLikeCode() rejects JS titles/text in validate(). - O(1) duplicate detection by targetUrl OR image src path via a lazily-built index, invalidated on removal/bulk change. - Post-visit title resolves only when still 'Pending' (MV2 parity). - Default hidingStyle: 'opacity' setting.
…te strict - Enable adn-allow unconditionally at startup (was toggled off per-site). - applyHidingStyle() swaps opacity:0 -> display:none for cosmetic CSS when the hidingStyle option is set, at the insertCSS/removeCSS chokepoint. - Per-site "strict": a session rule (priority 25, initiatorDomains-scoped, curated ad domains) re-blocks ad requests on strict sites while collection keeps running; setAdnStrict/getAdnStrict handlers + startup apply.
…able - Toggle the recent-ads class so recent ads lay out correctly (+ css rule). - Open the uBO Lite menu inline in the popup instead of a new tab. - Map Active/Strict to Complete and wire Strict to the per-site re-block overlay; detect strict state on open (resolves Active/Strict ambiguity).
…ding Referer/Upgrade-Insecure-Requests are forbidden headers (silently ignored); removing them clears the console warning. Post-visit title is applied only when the ad title is still 'Pending'.
…asset
- Fix duplicated dashboard header/nav and the missing settings <section>.
- Add a Behaviour toggle ("hide with display:none") wired via options.js.
- Add the missing placeholder.svg used as the ad-thumbnail fallback.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.