Page MenuHomePhabricator

Vector legacy tabs can expand/collapse forever if they have a border/margin
Closed, ResolvedPublicBUG REPORT

Description

This can happen at particular resolutions when Vector legacy tabs have a custom CSS border/margin:

Switching from width() to outerWidth(true) will output the same value for the default Vector legacy CSS. But for wikis which have customized their CSS to give the tabs a border and/or margin, this will fix the issue where the tab is expanded and collapsed forever at particular resolutions.

Event Timeline

Change 962023 had a related patch set uploaded (by Porplemontage; author: Porplemontage):

[mediawiki/skins/Vector@master] Prevent legacy tab expand/collapse infinite loop if they have a border/margin

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

This issue has recurred in many forms (see T71729) suggesting the code here is quite brittle.

Which wikis are setting border/margin? I'd like to understand those use cases better before committing to this solution.

The issue was noticed on Pikipedia.

Note that the proposed change has already been applied to the site's local copy of collapsibleTabs.js.

Change 962023 merged by jenkins-bot:

[mediawiki/skins/Vector@master] Prevent legacy tab expand/collapse infinite loop if they have a border/margin

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

Porplemontage triaged this task as Low priority.