Page MenuHomePhabricator

"Mobile sidebar preview" gadget on en.wp misses Toggle icon in horizontal toolbar
Closed, InvalidPublic


Greetings, At Preferences, Gadgets, ''Mobile sidebar preview'' is checked ON. and Icon does not show on toolbar. Using Skin, Modern. Tested with Win7 & Chromodo browser; also tested with LInux & Firefox browser. Same problem on both.

Event Timeline

JoeHebda raised the priority of this task from to Medium.
JoeHebda updated the task description. (Show Details)
JoeHebda subscribed.

Cannot reproduce the problem on Firefox 44 on Fedora Linux:

foo.png (513×1 px, 209 KB)

You might want to disable other potentially interfering gadgets and check your browser's developer console for any error output. Also note that gadget issues are on-wiki and might not receive support in Phabricator.

Aklapper renamed this task from English wikipedia - Gadgets, "Mobile sidebar preview", toggle Icon missing on horiz. toolbar to "Mobile sidebar preview" gadget on en.wp misses Toggle icon in horizontal toolbar.Feb 11 2016, 10:49 AM
Aklapper raised the priority of this task from Medium to Needs Triage.
Aklapper added a project: Community-Tech.
Aklapper set Security to None.

Only works with Vector skin. At Pref-Appearance-Skins, I did ''Preview'' on all of them & fails on all except Vector. ~~~~

See the developer console of any web browser, after enabling a different skin than Vector (e.g. Modern):

TypeError: $content.position(...) is undefined

Hence the line

var top = $content.position().top,

in (which is called from ) needs to be fixed by anybody interested in fixing this.

As that is a personal script by a user hosted on-wiki, this is unfortunately out of scope for Phabricator. You could contact the author or commented on the discussion page of the script.

Found here:

Mobile Sidebar not showing up in Modern skin

Hi Brion and {{ping|Brion Vibber (WMF)}}.


We are having trouble displaying the Mobile Sidebar using the 'Modern' skin. Works fine in 'Vector'.

We want to roll it out as a [[:en:Wikipedia talk:TOTD|Wikipedia Tip-of-the-Day]] soon for folks to try out. Got any ideas? Ping me back on the English Wikipedia. Cheers! [[User:Checkingfax|Checkingfax]] ([[User talk:Checkingfax|talk]]) 21:04, 11 February 2016 (UTC)

:this may or may not be the source of this specific problem, but the script has this line:

<syntaxhighlight lang=javascript>var $content = $('#content');</syntaxhighlight>

as far as i understand, what you want to do there is

<syntaxhighlight lang=javascript>var $content = mw.util.$content;</syntaxhighlight>

peace - [[User:קיפודנחש|קיפודנחש]] ([[User talk:קיפודנחש|talk]]) 20:31, 15 February 2016 (UTC)

::on further reading: $content is not used for anything useful - its only use is to calculate top, which in turn is not used. so the real fix is to remove those two variables. peace - [[User:קיפודנחש|קיפודנחש]] ([[User talk:קיפודנחש|talk]]) 01:28, 16 February 2016 (UTC)

:::on further further reading, $content is indeed not used, but it should be, to replace all the


in the code... peace - [[User:קיפודנחש|קיפודנחש]] ([[User talk:קיפודנחש|talk]]) 01:54, 16 February 2016 (UTC)

I'm going to keep this on my short list but I've got too many things in play to commit to self-assigning it until I finish a few others. If anyone else can work on this before, feel free to take the bug and ping me if necessary for questions/advice!

@brion :
please read your user page on meta. i created a patched version of your script that works with all skins, although i could not fit the icon sanely on the non-vector ones, so i resorted to text.

in addition to the non-vector issue, there's also a small issue with RTL.
both are discussed in your meta talk page. i will be glad to throw my patched version away and use the original when it's not needed.


Removing MediaWiki-extensions-Gadgets as this task is not about the PHP extension.

Closing as invalid as on-wiki content needs to be handled on-wiki: User scripts, gadgets and templates are local features and managed independently on each wiki. Phabricator/Maniphest is used for MediaWiki, MediaWiki extensions, or server configuration. In this case you could contact the author of the script/gadget (see "View History").
I was hoping the Community-Tech team might be able to take a look if their time allows, but the last comments imply that they cannot. So this becomes a matter to discuss and fix on the local wiki and not handled in Phabricator/Maniphest until gets solved...