Skip to content

fix(nelson): increase content width to accommodate 728px ads#2716

Open
faisalahammad wants to merge 1 commit into
Automattic:trunkfrom
faisalahammad:fix/1527-nelson-content-width
Open

fix(nelson): increase content width to accommodate 728px ads#2716
faisalahammad wants to merge 1 commit into
Automattic:trunkfrom
faisalahammad:fix/1527-nelson-content-width

Conversation

@faisalahammad
Copy link
Copy Markdown
Contributor

@faisalahammad faisalahammad commented May 15, 2026

Summary

Newspack Nelson's #primary has extra horizontal padding (3rem per side at desktop) that narrows the content area to ~702px, preventing 728px wide ads from fitting. Reducing desktop padding to 2rem per side brings the content width to >= 728px.

Fixes #1527

Changes

newspack-nelson/sass/style.scss

Before:

@include utilities.media( desktop ) {
    padding-left: #{3 * structure.$size__spacing-unit};
    padding-right: #{3 * structure.$size__spacing-unit};
}

After:

@include utilities.media( desktop ) {
    padding-left: #{2 * structure.$size__spacing-unit};
    padding-right: #{2 * structure.$size__spacing-unit};
}

Why: 3rem (48px) padding per side at desktop was Nelson-specific — no other child theme adds padding to #primary. Reducing to 2rem (32px) matches the tablet breakpoint value and gives .main-content enough width for 728px ads while keeping the visual difference minimal.

Testing

  1. Activate Newspack Nelson theme
  2. Open a single post with sidebar at desktop viewport (>= 1200px)
  3. Inspect .main-content — computed width should be >= 728px
  4. Verify tablet/mobile padding unchanged (2rem at tablet, 0 at mobile)

Build

newspack-nelson-fix-1527.zip available for manual testing. Install via WP Admin -> Appearance -> Themes -> Upload Theme.

Reduce #primary desktop padding from 3rem to 2rem per side so
.main-content reaches >= 728px width for ad placements.

Fixes Automattic#1527
@faisalahammad faisalahammad requested a review from a team as a code owner May 15, 2026 19:31
@laurelfulford laurelfulford added the [Status] Needs Review The issue or pull request needs to be reviewed label May 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Status] Needs Review The issue or pull request needs to be reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Newspack Nelson: Update content width to be at least 728px

2 participants