Page MenuHomePhabricator

StickyHeaders: Introduce a new URL param feature flag to enable the prototype
Closed, ResolvedPublic2 Estimated Story Points

Description

Acceptance Criteria
  • Add a new Hook handler method in ReaderExperiments Hooks.php (onBeforePageDisplay most likely)
  • Test for the presence of a new URL param like stickyHeaders (or whatever name we decide on)
  • Apply the collapsible-headings-expanded class to the page body if present

In the future we'll also allow experiment participation to trigger this feature, just like how we've done for the ImageBrowsing prototype.

Event Timeline

egardner set the point value for this task to 2.Oct 23 2025, 4:23 PM
egardner moved this task from Needs Refinement to Ready on the Reader Growth Team board.
mfossati changed the task status from Open to In Progress.Oct 29 2025, 12:51 PM
mfossati renamed this task from MobileSections: Introduce a new URL param feature flag to enable the prototype to StickyHeaders: Introduce a new URL param feature flag to enable the prototype.Oct 31 2025, 3:39 PM

Change #1198165 had a related patch set uploaded (by Marco Fossati; author: Eric Gardner):

[mediawiki/extensions/ReaderExperiments@master] StickyHeaders: add URL parameter feature flag

https://gerrit.wikimedia.org/r/1198165

egardner updated the task description. (Show Details)

For QA purposes, this can be tested on Beta once the patch merged. The noticeable difference here will be that all sections are expanded by default instead of collapsed (sticky behavior is handled over at T408046, not here).

QA steps:

  1. Go to an article page on Beta Wikipedia, using the Minerva Skin. Use a mobile device or resize your viewport to phone size (sections are always expanded by default on larger viewports even in Minerva).
  2. Confirm that all sections are collapsed by default.
  3. Add the ?stickyHeaders=1 URL param
  4. Reload the page and confirm that all sections are now expanded by default.

Change #1198165 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] StickyHeaders: add URL parameter feature flag

https://gerrit.wikimedia.org/r/1198165

QA testing on Beta, 11/6

Using https://en.wikipedia.beta.wmcloud.org/wiki/World as a test article.

  1. Go to an article page on Beta Wikipedia, using the Minerva Skin. Use a mobile device or resize your viewport to phone size (sections are always expanded by default on larger viewports even in Minerva).
  2. Confirm all sections are collapsed by default

✅ Behaves as expected; sections remain collapsed on small viewports in mobile view

  1. Add the`?stickyHeaders=1` param
  2. Reload the page and confirm that all sections are now expanded by default.

✅ Behaves as expected, sections expand using the new param on small viewports in mobile view