Draft
Conversation
|
Contributor
|
Size Change: +278 B (+0.11%) Total Size: 243 kB
ℹ️ View Unchanged
|
Contributor
8929b67 to
fed3891
Compare
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.
What does this change?
Introduce a number of checks and changes to get spacefinder working on interactives on desktop.
content--interactive-gridelement is >= that of the viewport, do not insert right rail ads, this is an indicator of the interactive behaving very different to a regular article, so don't even try. (example interactive):scope > :not(p)as elements in interactives are a bit of a wild west, anddata-spacefinder-roleis not enough to determine if an element expands to the right.The styles (in DCR) will be updated to:
.ad-slot-container--offset-rightis now only added if the article body isn't full width AKA all articles and a few interactive.Why?
For most interactives the article body is the full width of the grid, with paragrahs restricted to 620px and positioned in the body using a left margin, for these cases we don't want to apply the negative right margin that we apply for normal articles (and some interactives), we just need to
float: right, so I've split the class into two so that negative margins aren't applied for these cases.Visual of the the parent element of paragraphs to hopefully demonstrate the scenarios:
Normal articles with the body positioned using grid:

Interactives with full width article body:
