Last modified: 2014-04-30 23:39:03 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 T66607, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 64607 - Parsoid style should target mobile as well as desktop
Parsoid style should target mobile as well as desktop
Status: RESOLVED FIXED
Product: Parsoid
Classification: Unclassified
General (Other open bugs)
unspecified
All All
: Highest normal
: ---
Assigned To: James Forrester
: browser-test-bug
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-04-29 14:43 UTC by Chris McMahon
Modified: 2014-04-30 23:39 UTC (History)
9 users (show)

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


Attachments

Description Chris McMahon 2014-04-29 14:43:08 UTC
as a logged in user with alpha mode set, attempt to edit a page.

the VE controls never appear, user sees only a spinner forever.
Comment 1 Bingle 2014-04-29 14:45:11 UTC
Prioritization and scheduling of this bug is tracked on Trello card https://trello.com/c/lTCoRTO5
Comment 2 Chris McMahon 2014-04-29 14:46:25 UTC
no fatal errors appear in the logs on beta labs
Comment 3 Jon 2014-04-29 17:24:16 UTC
There is a JavaScript error

Error: Unknown dependency: ext.parsoid.styles 
Error {stack: (...), message: "Unknown dependency: ext.parsoid.styles"}


Looks like ext.parsoid.styles needs to be set with target mobile.
Comment 4 Gerrit Notification Bot 2014-04-29 17:29:22 UTC
Change 130388 had a related patch set uploaded by Jforrester:
Load Parsoid style module for mobile as well as desktop

https://gerrit.wikimedia.org/r/130388
Comment 5 Gerrit Notification Bot 2014-04-29 17:31:04 UTC
Change 130388 merged by jenkins-bot:
Load Parsoid style module for mobile as well as desktop

https://gerrit.wikimedia.org/r/130388
Comment 6 Jon 2014-04-29 17:41:50 UTC
It's not entirely clear to me why Parsoid needs its own styles...
http://git.wikimedia.org/blob/mediawiki%2Fextensions%2FParsoid/770ec8594626e0d8d8851adb4a2520ff34f18f24/php%2Fmodules%2Fparsoid.styles.css

Shouldn't this be decided by the skin..?
Comment 7 James Forrester 2014-04-29 17:43:33 UTC
(In reply to Jon from comment #6)
> It's not entirely clear to me why Parsoid needs its own styles...
> http://git.wikimedia.org/blob/mediawiki%2Fextensions%2FParsoid/
> 770ec8594626e0d8d8851adb4a2520ff34f18f24/php%2Fmodules%2Fparsoid.styles.css
> 
> Shouldn't this be decided by the skin..?

These are replacing the styles inside MediaWiki; long-term this module will be moved into MediaWiki core as part of the skin refactor.
Comment 8 Gabriel Wicke 2014-04-29 17:45:32 UTC
For now the goal is to have a central place to develop Parsoid-specific content style tweaks that can be used by all Parsoid users (VE, Flow, Content Translation, offline tools etc).
Comment 9 Jon 2014-04-29 17:48:32 UTC
This actually causes a CSS regression on mobile.

These Parsoid styles slightly impact the look and feel for references in the Minerva skin after VE has been loaded. These styles shrink them, making the touch area smaller and virtually unclickable.

Why not put it straight into core or even better specific to Vector skin? All these moving parts make things super complicated.

Also James, please link me to what "the skin refactor" is. It's not clear to me what you are referring to...
Comment 10 James Forrester 2014-04-29 17:59:30 UTC
(In reply to Jon from comment #9)
> Also James, please link me to what "the skin refactor" is. It's not clear to
> me what you are referring to...

No idea; I'm not doing it. I'm just fixing things.
Comment 11 Gabriel Wicke 2014-04-29 18:05:05 UTC
(In reply to Jon from comment #9)
> This actually causes a CSS regression on mobile.
> 
> These Parsoid styles slightly impact the look and feel for references in the
> Minerva skin after VE has been loaded. These styles shrink them, making the
> touch area smaller and virtually unclickable.

We might need to add media queries to handle mobile-specific styling for Parsoid-specific content. Could you add a patch for this?

> Why not put it straight into core or even better specific to Vector skin?
> All these moving parts make things super complicated.

I'm not opposed to this, but there is still some value in developing the Parsoid styles somewhat independently for a while. Folks are hesitant to merge styles that are not yet used for normal page views, but that will change with broader Parsoid content use.
Comment 12 Jon 2014-04-29 18:10:31 UTC
> We might need to add media queries to handle mobile-specific styling for
> Parsoid-specific content. Could you add a patch for this?
A better approach might be to simply wrap them in a media query that targets larger screens (e.g. take a mobile first approach) - this would solve the issue with mobile as the existing styles will kick in - sadly however this will mean the rules are loaded unnecessarily on mobile.

My main worry is this file getting even more bloaty. Would it not make sense to use skinStyles on this module so that the styles only apply to Vector/Monobook?

> I'm not opposed to this, but there is still some value in developing the
> Parsoid styles somewhat independently for a while. Folks are hesitant to
> merge styles that are not yet used for normal page views, but that will
> change with broader Parsoid content use.


Yeh I'm aware of this anti-pattern in the MediaWiki community :-). Personally I don't think this sandboxed approach works but I understand this is a bigger problem than this and this is the current status quo.
Comment 13 Gabriel Wicke 2014-04-30 23:39:03 UTC
(In reply to Jon from comment #12)
> > We might need to add media queries to handle mobile-specific styling for
> > Parsoid-specific content. Could you add a patch for this?
> A better approach might be to simply wrap them in a media query that targets
> larger screens (e.g. take a mobile first approach) - this would solve the
> issue with mobile as the existing styles will kick in - sadly however this
> will mean the rules are loaded unnecessarily on mobile.
> 
> My main worry is this file getting even more bloaty. Would it not make sense
> to use skinStyles on this module so that the styles only apply to
> Vector/Monobook?

We are moving this to core now: https://gerrit.wikimedia.org/r/#/c/130770/

Without those styles figures etc are completely unstyled. For this reason we'll add this as a styles.common.* module. Individual skins can further tweak the rendering if needed.

Re bloat: The intention is to keep these styles minimal, and only load them on request in a separate RL module.

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


Navigation
Links