Last modified: 2014-07-22 01:37:58 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T45406, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 43406 - [Regression] CSS selector for vector menu label is not generic enough
[Regression] CSS selector for vector menu label is not generic enough
Status: RESOLVED FIXED
Product: MediaWiki skins
Classification: Unclassified
Vector (Other open bugs)
unspecified
All All
: Normal normal
: ---
Assigned To: Bartosz Dziewoński
: code-update-regression
Depends on:
Blocks: 44881
  Show dependency treegraph
 
Reported: 2012-12-25 12:16 UTC by Helder
Modified: 2014-07-22 01:37 UTC (History)
6 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Helder 2012-12-25 12:16:50 UTC
The gerrit change I9a2ebd50, to the CSS which is applied to vector menus with labels (currently only the "variants" menu, from LanguageConverter), do not scale for other similar menus. Anyone wanting to add a new vector menu with a visible title analogous to the "variants" will have to duplicate the CSS because the new CSS is now only for the "#p-variants #mw-vector-current-variant".

I noticed this because the formatting of a menu like that added by one of my user scripts changed after I replaced the h4 by an h3 [1], and the reason is that this selector doesn't apply to it anymore. Gadgets such as [2] might have the same kind of problems.

Consider changing the selector to something like
div.vectorMenu .vectorMenuLabel
or
div.vectorMenu h3.vectorMenuLabel
(and updating the code which generates the menu accordingly).

[1] https://pt.wikibooks.org/w/index.php?diff=242001
[2] https://en.wikipedia.org/wiki/Special:PrefixIndex/MediaWiki:Gadget-MenuTabsToggle
Comment 1 Bartosz Dziewoński 2012-12-25 12:28:39 UTC
You have a point. I didn't really know how to do it well (per the commit message: "I changed the bonkers structure to two <h3>s, one with id=mw-vector-current-variant. This is still broken, but I don't really know how to do it properly.").

If you know how to make this structure less crazy, please do. :) Right now there are two consecutive headings, which makes absolutely no sense at all. Either it should just be one heading (with one label), or a heading and a div or something. It could also use one heading with contents such as "zh-cn (Variants)", where the "(Variants)" part is the generic heading and would be hidden with CSS, and "zh-cn" is the label.

(Also, the breaking changes caused by this change were advertised on wikitech and wikitech-ambassadors.)
Comment 2 Bartosz Dziewoński 2014-06-09 17:28:18 UTC
The way I did the "Variants" menu here was the root cause for bug 66364. Let's get rid of it at last. One label is enough.

As for the original complaint, now both of Vector's dropdown menus include a text label by default (as requested per bug 44591).
Comment 3 Gerrit Notification Bot 2014-06-09 17:30:27 UTC
Change 138368 had a related patch set uploaded by Bartosz Dziewoński:
Stop using a retarded structure for Vector's variants menu

https://gerrit.wikimedia.org/r/138368
Comment 4 Gerrit Notification Bot 2014-06-09 17:30:32 UTC
Change 138369 had a related patch set uploaded by Bartosz Dziewoński:
Stop using a retarded structure for Vector's variants menu (cont.)

https://gerrit.wikimedia.org/r/138369
Comment 5 Gerrit Notification Bot 2014-07-21 18:30:12 UTC
Change 138368 merged by jenkins-bot:
Stop using a suboptimal structure for Vector's variants menu

https://gerrit.wikimedia.org/r/138368
Comment 6 Bartosz Dziewoński 2014-07-22 01:37:12 UTC
All fixed!
Comment 7 Bartosz Dziewoński 2014-07-22 01:37:58 UTC
(Note that you'll need to wait for HTML cache to expire before you stop seeing the old structure in pages, up to 30 days after the change is deployed.)

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links