Last modified: 2014-06-03 06:42:47 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 T32405, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 30405 - MobileFrontend extension should stop special-casing main page
MobileFrontend extension should stop special-casing main page
Status: REOPENED
Product: MobileFrontend
Classification: Unclassified
Feature requests (Other open bugs)
unspecified
All All
: Normal enhancement
: ---
Assigned To: Nobody - You can work on this!
:
: 32583 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-08-16 19:28 UTC by MZMcBride
Modified: 2014-06-03 06:42 UTC (History)
16 users (show)

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


Attachments

Description MZMcBride 2011-08-16 19:28:00 UTC
The MobileFrontend extension shouldn't special-case the main page. Currently a lot of the logic and infrastructure is based on a { if isMainPage() } { else ... } model, which is silly and unnecessary. The extension code should be flexible and adaptable to any page. A few tweaks might be necessary for the main page, but there doesn't need to be a completely different system in place for it.
Comment 1 Max Semenik 2012-03-29 19:33:44 UTC
The problem with main pages is that they have complex formatting, usually with two-column tables that will not fit into mobile devices' tiny displays. Of course, it's theoretiaclly possible to extract these tables' content - but such task would be close to telepathy.
Comment 2 Jon 2012-04-04 17:01:34 UTC
I think pages should be allowed to special case themselves in this way.
There are various other pages where things just will not work on mobile (see bug 20030 for instance) - it would be good if these pages were able to turn on this special casing to hide certain content. This would make the home page special casing more generic and useful. Thoughts?
Comment 3 Tomasz Finc 2012-04-04 17:25:36 UTC
+1 on Jon's comment

We need to get to a point where an editor is able to designate mobile/non mobile content. We have this functionality on the main page but its a hyper specific example. As we move forward with moving mobile frontend into core we need to look at explicitly in wikitext saying what belongs on mobile (or vice versa) what does not.
Comment 4 Krinkle 2012-04-07 20:36:47 UTC
Random idea:

MediaWiki has an i18n setting "mainpage" that takes a full page name which it uses to link to the main page in the logo and other places. Maybe it would make sense to ( - instead of forcing the main page to be in a specific format and apply a fragile conversion to it for mobile - ), instead have an actual wiki page be the mobile main page. An interface message like "mobilefrontend-mainpage" (empty by default, which setup will fallback to the "mainpage" msg) would be used for it.

The reason for this is that, although wmf wikis have the (arguably unfortunate) habit of creating complex main pages that uses dozens-of-level-deep nested tables with at least 2 columns, I know many (non-wmf) wikis that don't. And it is exactly these "complex mainpages" that are in need of a mobile version. The simple main pages that other wikis have don't need this conversion per se.

Since (AFAIK) all complex-mainpage-having wikis use tranclusion to include the content into their main page sections, it would be fairly trivial to create a mobile version (as a wikipage) that re-uses the same content in a different, mobile-friendly, format.

That way there are no requirements and wikis can make the mobile version just the way they want them to be.

They could even come up with a design that would work for both desktop and mobile, if they want to. And have no limitations or restrictions if they come up with a new section that perhaps the extension doesn't recognize yet.
Comment 5 Platonides 2012-04-08 22:31:26 UTC
Seems a good idea. Moreover an empty mobile-mainpage would lead to the old one, being the perfect default.
Comment 6 Tomasz Finc 2012-04-09 18:25:19 UTC
This isn't just a problem with main pages. Portal pages and others have the exact same issues. We need a solution that doesn't duplicate all of our content work.
Comment 7 Jon 2012-05-01 11:56:21 UTC
Also see bug 32583 which discusses the method for which titles are extracted on the main page.

Whatever solution we come to should also deal with this in a satisfying way
Comment 8 Jon 2012-05-01 11:57:26 UTC
*** Bug 32583 has been marked as a duplicate of this bug. ***
Comment 9 Gerrit Notification Bot 2013-04-19 00:59:56 UTC
https://gerrit.wikimedia.org/r/59722 (Gerrit Change I444b061796b3e3344852327cf26b48e83381f457) | change APPROVED and MERGED [by JGonera]
Comment 10 Jon 2013-04-24 03:41:55 UTC
rabbit hole open on alpha but nowhere near fixed :)
Comment 11 Jon 2013-06-28 20:07:03 UTC
So many years later people are still getting confused about how to special case the homepage.

Looking at the page in question I noticed it had no need for special casing.

I now believe should be turned off by default and enabled on a per wiki basis where needed.
Comment 12 Jon 2013-07-03 01:04:11 UTC
https://gerrit.wikimedia.org/r/71749 change defaults to no special casing. Let's try and reverse the trend of fixing up broken layouts and try to encourage better use of classes and non-table based layouts.
Comment 13 Jon 2014-04-18 17:32:22 UTC
Is this ever realistically going to get fixed? I hear that most wiki projects are moving to DIV based layouts and with good use of the nomobile class there is really no excuse for not being able to optimise the main pages without us doing anything.

Is it time to be more brutal and deprecate this main page special casing?

I could imagine the following approach:
* Add a JavaScript warning on mobile pages that are special cased saying that "This page has been special cased. We are deprecating this functionality. If you are seeing this warning, you need to act now"
* Identify all special cased main pages and throw a message on the main talk page telling them to act now with a link to how to make a good mobile optimised page.


Now we have useskin=minerva there is no reason why editors cannot easily fix their main page. See https://en.wikipedia.org/?useskin=minerva

If we don't want to take this approach I suggest we WONTFIX this bug as this is not realistically going to happen without a brute force approach.

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


Navigation
Links