Page MenuHomePhabricator

Unclosed decorative div tags on talk pages causing problems with rendering on mobile
Open, Needs TriagePublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • I have a talk page with unclosed div tags, as used for decoration.

What happens?:

  • The entire talk page shows up in the "Learn more about this page" blurb on mobile.

What should have happened instead?:

  • Only the first section before the first talk page discussion should have shown there.

Software version (skip for WMF-hosted wikis like Wikipedia):

Other information (browser name/version, screenshots, etc.):
Problem diff 1: https://en.m.wikipedia.org/w/index.php?title=User_talk:Awesome_Aasim&oldid=1214033684
Problem diff 2 (not my talk page): https://en.m.wikipedia.org/w/index.php?title=User_talk:Cyberpower678&oldid=1214191474
Problem diff 3 (also not my talk page): https://en.m.wikipedia.org/w/index.php?title=User_talk:Oshwah&oldid=1214171073

Mobile is not properly excerpting the first section either on some other talk pages like here: https://en.m.wikipedia.org/wiki/User_talk:Redrose64 On that talk page, the content before the first section is visible even though it should be under "learn more about this talk page" and hidden hidden.

So far I have only found this talk page to have the learn more about this talk page function correctly on mobile https://en.m.wikipedia.org/wiki/User_talk:EEng

Event Timeline

What's supposed to go inside that "learn more" dialog is the page's lede section if there's no comments within it. (That's why Redrose64's talk page doesn't have it hidden -- it has that "welcome" message that's signed.)

The entire page being wrapped in a div is presumably confusing the parser either by:

  1. having it think the entire page is the lede section and there's no comments in it
  2. having the part that's pulling out the lede section get confused and expand out to extract the covering tag

I think the only correct think we can do here is skip putting things into the "learn more" popup when there's markup like this. (Working out what tags are crossing sections and extracting just the bit inside the container before the first heading feels like a recipe for rendering issues. Closing-and-reopening the tags also feels like a recipe for rendering issues.)