Skip to content
This repository has been archived by the owner on Oct 15, 2020. It is now read-only.

boston.com #95

Closed
wants to merge 2 commits into from
Closed

boston.com #95

wants to merge 2 commits into from

Conversation

yourduskquibbles
Copy link
Contributor

@yourduskquibbles yourduskquibbles commented Mar 2, 2020

Better mirror intended site design for boston.com (check via web inspector) so site doesn't break unexpectedly with other filter lists loaded (e.g. Web Annoyances Ultralist)

With webannoyances ultralist, Page title heading is no longer hidden on example link with updated filter: https://www.boston.com/news/health/2020/03/01/coronavirus-may-have-spread-undetected-for-weeks-in-u-s

Related: #67 (comment)

Better mirror intended site design for `boston.com` so it doesn't break unexpectedly with other filter lists (e.g. Web Annoyances Ultralist)

Related: #67 (comment)
@jspenguin2017 jspenguin2017 changed the title Update boston.com filter boston.com Mar 2, 2020
@jspenguin2017 jspenguin2017 self-assigned this Mar 2, 2020
@jspenguin2017
Copy link
Member

jspenguin2017 commented Mar 2, 2020

It looks like your rule requires UserCSS.

@yourduskquibbles
Copy link
Contributor Author

yourduskquibbles commented Mar 2, 2020

The rule being updated/replaced also required UserCSS? If you don't want UserCSS rules in nano-contrib, possible to just remove the original rule boston.com##.site-container:style(margin-top: -100px !important;) that is causing issues with Web Annoyances Ultralist?

Example link: https://www.boston.com/news/health/2020/03/01/coronavirus-may-have-spread-undetected-for-weeks-in-u-s

This is how article page looks with Web Annoyances Ultralist and Nano Contrib Filter - Placeholder Buster​ both enabled.

badcss

Notice content-header dom element gets pushed under the sticky header causing page to be missing the Title and Subtitle due to using a negative margin offset with boston.com##.site-container:style(margin-top: -100px !important;).

Updated filter in PR removes the same adblock white space has no visual change to how the site is presented if only using Nano Contrib Filter - Placeholder Buster​.

@jspenguin2017
Copy link
Member

The current rule works correctly as per my tests. Your rule does not work because it requires UserCSS.

Although I would like this filter list to be compatible with other ones, removing rules is not an acceptable way to achieve that.

@yourduskquibbles
Copy link
Contributor Author

I don't understand your rationale for not wanting to pull this when you're swapping one offset for a more robust offset that adjusts the ##body padding which is how the site design is creating the white space for the adbox in the first place. (Use inspector and look at the ##body element and padding-top being set to 200px by the site). You're using a negative margin offset to compensate for this when you could just change the padding of body and be better off for all users.
Or am I missing something with your usercss comment? Is the ##body element somehow different than ##site-container when it comes to CSS injection?

I'll just fix in Web Annoyances Ultralist, but the fix suggested here was at the very worst visually neutral for users of only Nano Contrib Filter - Placeholder Buster​ list.

yourduskquibbles added a commit to yourduskquibbles/webannoyances that referenced this pull request Mar 3, 2020
Fixing site design breakage caused by bad filter in Nano Contrib Filter - Placeholder Buster when used with Web Annoyances Ultralist to pin sticky header.

Related discussion: NanoAdblockerLab/NanoContrib#95
@jspenguin2017
Copy link
Member

jspenguin2017 commented Mar 3, 2020

Or am I missing something with your usercss comment?

Yes, with .site-container, pseudo-UserCSS is able to enforce the rule, but with body, the site's CSS takes over pseudo-UserCSS. The real UserCSS is needed to enforce the rule using body.

but the fix suggested here was at the very worst visually neutral

I have personally tested your rule, and it does NOT work with pseudo-UserCSS.

@jspenguin2017
Copy link
Member

This is what the website looks like with your rule under pseudo-UserCSS:
image

@yourduskquibbles
Copy link
Contributor Author

Thx for explaining and sorry if rude with my response on it not being worse off for anyone. So I take it Nano Adblocker doesn't use UserCSS but uBlock Origin does? Is their a design rationale for not wanting to use UserCSS? Seems to give users more control if they want it?

Future updates I suggest I make I'll make sure to also test in Nano Adblocker, not just uBO.

@jspenguin2017
Copy link
Member

jspenguin2017 commented Mar 3, 2020

That's right, Nano Adblocker on Chromium does not use the real UserCSS. uBlock Origin always use the real UserCSS.

I chose to not enable the real UserCSS on Chromium because it is not possible to remove injected styles on Chromium, breaking the DOM Inspector.

@jspenguin2017
Copy link
Member

jspenguin2017 commented Mar 3, 2020

I do want to have a way to force certain rules to use the real UserCSS regardless of platform, however, I have yet to be able to find time to implement that.

NanoAdblocker/NanoCore#243

@yourduskquibbles
Copy link
Contributor Author

OK thanks for explaining.

@github-actions github-actions bot added the archived This thread was archived, open new pull requests for similar problems. label Aug 23, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Aug 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
archived This thread was archived, open new pull requests for similar problems. REJECTED
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants