Last modified: 2008-02-08 17:20:32 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 12869 - Magnify icon alignment should be adjusted using linked CSS
Magnify icon alignment should be adjusted using linked CSS
Product: MediaWiki
Classification: Unclassified
Interface (Other open bugs)
All All
: Normal enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
Depends on:
  Show dependency treegraph
Reported: 2008-02-01 22:44 UTC by Huji
Modified: 2008-02-08 17:20 UTC (History)
0 users

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


Description Huji 2008-02-01 22:44:47 UTC
In Linker.php we have a line like this:

$magnifyalign = $wgContLang->isRTL() ? 'left' : 'right';

which will result in a "float" style to be added to the magnify icon for images. The above means, the icon will appear to the right on LTR wikis. That "is" a problem for wikis like Meta or Wikimediafoundation where the wiki is generally LTR but has some RTL pages on it too.

If there is no objection, I'm going to modify that part and let Common.css to define the float of such objects. That way, CSS hacks can be used to move the icon to left/right as desired, and the option is in the hand of Wiki admins, not hardcoded.
Comment 1 Brion Vibber 2008-02-02 00:52:26 UTC
Sounds good.
Comment 2 Huji 2008-02-02 20:12:32 UTC
In order to make sure current wikis will work fine (i.e. don't need to update their MediaWiki:Common.css to put the magnify icon to where it was), yet let there be a way to modify the style (when needed) through MediaWiki:Common.css, I suppose this is the best solution:

* The above said "float" style is removed from the <div> tag which contains the magnifiy icon.
* A section is added to the appropriate css file in Common skin, setting the float to right (as is for LTR wikis).
* A similar section s added to another css file in Common skin (I propose common_rtl.css) which sets the float to left (to be suitable for RTL wikis), along with other required changes (setting the text to appear right-aligned, etc).

That idea works "in theory", because (1) common_rtl.css is only loaded with $wgContLang->isRTL() is true, and (2) MediaWiki:Common.css is loaded after both Common skin CSS files, and can add tweaks for bi-directional wikis. However, I'm not sure if it works in act, specifically because I don't see "common_rtl.css" to be loaded on Wikimedia's RTL wikis (and I don't know why), although it seems to be called in Skin.php

Do you think I should touch Skin.php to load that file?
Comment 3 Huji 2008-02-08 17:20:32 UTC
Fixed with a much simpler approach in r30716.

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