Last modified: 2013-08-02 05:58:38 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 T52542, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 50542 - VisualEditor: Tab layout should be done from a top-loading module
VisualEditor: Tab layout should be done from a top-loading module
Status: RESOLVED FIXED
Product: VisualEditor
Classification: Unclassified
MediaWiki integration (Other open bugs)
unspecified
All All
: High normal
: VE-deploy-2013-08-15
Assigned To: Roan Kattouw
:
Depends on: 50612
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-02 00:43 UTC by Erik Moeller
Modified: 2013-08-02 05:58 UTC (History)
9 users (show)

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


Attachments

Description Erik Moeller 2013-07-02 00:43:46 UTC
The "Edit source" tab loads/renders a little bit after the "Edit" tab, sometimes more noticeably so, sometimes less. Relatedly, clicking the "Edit" tab very early on sometimes invokes the wikitext editor. 

It would be preferable for both tabs to be rendered simultaneously with the correct default behavior.
Comment 1 Maggie Dennis 2013-07-02 01:38:19 UTC
Should this be merged in some way with Bug 50540?
Comment 2 Erik Moeller 2013-07-02 01:39:18 UTC
No, this bug is about the tabs at the top of the page (Read/Edit/Edit source), while bug 50540 is about the section-level edit links.
Comment 3 James Forrester 2013-07-03 02:14:18 UTC
Re-titling slightly per discussion; the suggestion is now:

* VisualEditor (?in PHP for efficiency/simplicity) hooks into the page before display
* On this hook,
** we add the VE edit tab ("edit")
** we switch out the WT edit tab with a new label and tool-tip ("edit source")
** we display:none the former if the user doesn't pass the blacklist code
Comment 4 Eduard Braun 2013-07-03 02:37:26 UTC
Sounds good. This could also fix bug 50402 at the same time I think?

What do you mean by "we display:none the former if the user doesn't pass the blacklist code"? What is the "blacklist code"?
Comment 5 T. H. Kelly (Pink&) 2013-07-03 11:48:29 UTC
(In reply to comment #4)

> What do you mean by "we display:none the former if the user doesn't pass the
> blacklist code"? What is the "blacklist code"?

I believe James is referring to the part of VE that checks a user's browser and compares it against a "blacklist" of non-supported browsers. "display:none"-ing the VE edit tab thereby stops people from using VE if their browser's not going to let them.

One of y'all devs can correct me if I'm wrong here.
Comment 6 Eduard Braun 2013-07-03 14:12:15 UTC
Shouldn't blacklisting occur much earlier (before actually messing around with any buttons at all?). Before having done *anything* actually?

I'm hoping for a definite answer by James (or another dev involved).
Comment 7 James Forrester 2013-07-03 20:27:39 UTC
(In reply to comment #6)
> Shouldn't blacklisting occur much earlier (before actually messing around
> with any buttons at all?). Before having done *anything* actually?
> 
> I'm hoping for a definite answer by James (or another dev involved).

Yes; that's bug 50608. We're re-working a whole bunch of items around the initialisation and integration code for VisualEditor right now - bug 50612 tracks that.
Comment 8 Roan Kattouw 2013-07-03 20:30:12 UTC
Ideally we'd alter the HTML using a PHP hook, then have a top-loading module that just conditionally adds some CSS to make the HTML generated by the PHP hook display correctly. That should allow us to get rid of the flashing tab behavior.
Comment 9 Gerrit Notification Bot 2013-07-03 22:16:26 UTC
Change 71929 had a related patch set uploaded by Krinkle:
Split off setup from the rest of mw.ViewPageTarget

https://gerrit.wikimedia.org/r/71929
Comment 10 Gerrit Notification Bot 2013-07-03 23:26:57 UTC
Change 71929 merged by jenkins-bot:
Split off setup from the rest of mw.ViewPageTarget

https://gerrit.wikimedia.org/r/71929
Comment 11 Roan Kattouw 2013-07-03 23:30:34 UTC
(In reply to comment #10)
> Change 71929 merged by jenkins-bot:
> Split off setup from the rest of mw.ViewPageTarget
> 
> https://gerrit.wikimedia.org/r/71929
This introduces a top-loading module, but still does the tab layout from document ready, which means there's probably still is a flash. What we should really do is change the HTML from PHP, per comment 8.
Comment 12 Gerrit Notification Bot 2013-08-02 03:31:02 UTC
Change 77165 had a related patch set uploaded by Catrope:
Move edit tab generation into PHP and make it more configurable

https://gerrit.wikimedia.org/r/77165
Comment 13 James Forrester 2013-08-02 05:58:38 UTC
This is now done, and deployed.

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


Navigation
Links