fix: fullscreen width + docs for single creative format#70
Conversation
Fixes fullscreen width on publishers that apply max-width to the iframe (e.g. tv2.no's max-width: 1920px). Also fixes :host positioning in padded ad containers.
|
Hey @pattan, noticed that the single creative format doesn't go full-width on publishers that set |
|
Thanks for the report @NicolayKjarnet My spontaneous thoughts are that this should lives into publishers integration (tv2), rather than in the format. |
|
@NicolayKjarnet I just got confirmation from the TV 2 team that max-width are now removed. |
Thanks for the update! Removed the maxWidth override and host positioning, rest is only docs. Ready for review |
Description
Fixes an issue where
DOUBLE_MIDSCROLL_SINGLE_CREATIVEdidn't fill the full viewport width on publishers that applymax-widthconstraints to the iframe (e.g. tv2.no'smax-width: 1920px).Changes:
max-widthwith inline style so the creative always goes full-width:hostpositioning in padded ad containers withmargin-left: calc((100% - 100vw) / 2)Why this is needed:
The standard
DOUBLE_MIDSCROLLavoids this because its background iframe lives inside Shadow DOM, unreachable by page CSS. The single creative variant only has a foreground iframe, so it's subject to publisher constraints. The inline style override fixes this cleanly.Issues Resolved
N/A
By submitting this pull request, I confirm that my contribution is made under the terms of the AGPL-3.0 license.