Widgets 4x4 ad: Show a 4x4 sponsored card in the Widgets row
Categories
(Firefox :: New Tab Page, task, P1)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox158 | --- | fixed |
People
(Reporter: dgrant, Assigned: dgrant)
References
(Blocks 2 open bugs)
Details
(Whiteboard: [hnt][hnt-wattle])
Attachments
(1 file)
Behind the widgets-ad-large page layout variant, render a sponsored content card in one large cell of the widgets row, to the design on HNT-3082.
Updated•10 days ago
|
Recording the product decisions behind this variant, since they were made in Slack and are not written down anywhere a reviewer can check.
Placement. The sponsored card always holds the last slot of the first widget row, in both the collapsed and the expanded "Show more widgets" states. By card column count that is slot 2 at two columns, slot 3 at three, slot 4 at four and slot 5 at five. A widget overflows to the next row rather than the card being pushed off the end. At one card column a row holds a single card, so the card cannot share the first row with a widget; it sits second instead, directly under the first widget.
Dismissal. Dismissing hides the card and leaves the slot empty. It does not advance to the next ad. The row already takes the first ad off the Stories set, so advancing would cost Stories a second ad for one dismissal. selectWidgetsRowAd returns null when the first eligible ad is blocked. A test pins that, asserting null even with a second eligible ad in the set.
Card size. The card stays at the large size even when the widgets row is minimized, because there is no half height sponsored card yet. Starting an experiment with every widget at large is the accepted consequence. The 4x2 treatment is out of scope here and needs design work before it can be built.
Where the card comes from was decided separately and is already recorded in bug 2071409 comment 1. The row takes the first ad from the existing Stories set, so there is no AdsFeed change. The accepted tradeoff is that Stories can lose its last ad when the set is exactly as long as the Stories slots.
Behind the widgets-ad-large page layout variant, the widgets row gives its last slot to a sponsored card, to the design on HNT-3082.
The card is the first ad off the existing Stories set, so the Stories fill drops that exact object and every story ad shifts up one. Both sides call selectWidgetsRowAd so they cannot disagree about which ad the row took. Ads preferred this to a dedicated placement.
Placement is by grid-column per container width, which makes widgets flow around the ad rather than push it off the end. One card column stacks everything, so the spot comes from the markup instead. A drag preview puts an inline order on every widget that would beat a stylesheet one, so the card renders after whichever widget the preview shows first.
Rendering reuses DSCard and nova-section-card-medium. The card forwards attribution and is_ad_eligible_position, without which NewTabAttributionFeed reports no view or click. The cell never drags, resizes or shows up in the customize panel.
Impressions carry the widgets_row_ad source next to pos 0, so the row's ad stays separable from the story sitting in the first grid position. There is no half-height sponsored card yet, so a minimized row holding this one keeps the large card's height.
Keyboard order does not match visual order for the card from three card columns up, and from two when small widgets sit ahead of it. Accessibility triaged that S3 and it is tracked in bug 2072338.
Validation: mach format, mach lint, stylelint and 3989 jest pass. Checked in a local build against live sponsored content, including the one card column drag and the about:home startup cache path.
Description
•