Page MenuHomePhabricator

Infinite collapse/uncollapse of "Edit" tab for some screen sizes (doesn't happen frequently)
Open, LowPublic

Description

Under some circumstances the Vector tabs collaps and uncollaps in an infinite loop. I could reproduce with

  • Firefox
  • window.innerWidth === 1027
  • enabled VisualEditor
  • on page with pending changes
  • a German interface

The loop is:

  • "Lesen", "Ungesichtete Änderungen", and "Bearbeiten" are visible
  • "Quelltext bearbeiten" starts to uncollaps
  • When "Quelltext be" is visible, the right tabs drop down (like it is on very narrow screens)
  • "Quelltext bearbeiten" starts to collaps, the right tabs move up again
  • When it is fully collapsed, the cycle begins again.

At no time the "Quelltext bearbeiten" tab is moved into the "more" dropdown.


See also T71729: [collapsibleTabs] If a tab's width changes after initial page load, endless animation loop can happen

Event Timeline

Schnark raised the priority of this task from to Needs Triage.
Schnark updated the task description. (Show Details)
Schnark subscribed.
Krinkle renamed this task from Infinite collapsing/uncollapsing of tabs to Infinite collapsing/uncollapsing of VisualEditor's Edit tab.Aug 10 2015, 8:33 PM

Focussing this task on VisualEditor's instance of this bug. The general issue is T71729 (which is likely wont-fix).

I suspect that we just need to update VisualEditor to call the relevant Vector method so that it knows the contents have changed. It doesn't (and can't feasibly do) support changes to its DOM without notification. Instead VE must notify Vector of its actions and call Vector's change handler.

Jdforrester-WMF renamed this task from Infinite collapsing/uncollapsing of VisualEditor's Edit tab to Infinite collapsing/uncollapsing of VisualEditor's Edit tab (?)when FlaggedRevs is also installed.Aug 10 2015, 9:54 PM
Jdforrester-WMF subscribed.

I can't reproduce testing without FlaggedRevs.

Jdforrester-WMF changed the task status from Open to Stalled.Aug 11 2015, 6:51 PM

I can reproduce on https://ru.wikipedia.org/wiki/%D0%AF%D0%BD%D0%B4%D0%B5%D0%BA%D1%81 resizing my browser window to 1024 pixels width (see video on T111601).

I can't reproduce testing without FlaggedRevs.

FlaggedRevs has nothing to do with it, except that maybe it was increasing the quantity of visible tabs and then causing the problem on your screen resolution.

The cause is Visual Editor changing the text of the source edit tab with JavaScript after page load

Ciencia_Al_Poder renamed this task from Infinite collapsing/uncollapsing of VisualEditor's Edit tab (?)when FlaggedRevs is also installed to Infinite collapsing/uncollapsing of VisualEditor's Edit tab on some screen resolutions.Sep 5 2015, 1:52 PM
Jdforrester-WMF renamed this task from Infinite collapsing/uncollapsing of VisualEditor's Edit tab on some screen resolutions to Infinite collapsing/uncollapsing of VisualEditor's Edit tab on some screen resolutions when tabs are inserted by JS (which doen't happen frequently).Sep 8 2015, 7:09 PM
Jdforrester-WMF triaged this task as Low priority.
Jdforrester-WMF moved this task from To Triage to Freezer on the VisualEditor board.

@Jdforrester-WMF that's not accurate. The tab is not inserted by JS, it's already there if you disable JS. What JS does is to change the text of the link.

The cause is Visual Editor changing the text of the source edit tab with JavaScript after page load

But that doesn't happen (unless there's a cache invalidity)…

The cause is Visual Editor changing the text of the source edit tab with JavaScript after page load

But that doesn't happen (unless there's a cache invalidity)…

Then something (=FlaggedRevs ?) is broken:

HTML before JS execution

<div id="p-views" role="navigation" class="vectorTabs" aria-labelledby="p-views-label">
 <h3 id="p-views-label">Ansichten</h3>
 <ul>
  <li id="ca-view" class="collapsible"><span><a href="/w/index.php?title=Steinplatte&amp;stable=1" >Lesen</a></span></li>
  <li id="ca-current" class="collapsible collapsible selected"><span><a href="/w/index.php?title=Steinplatte&amp;stable=0&amp;redirect=no"  title="Die unmarkieren Änderungen dieser Seite ansehen [v]" accesskey="v">Ungesichtete Änderungen</a></span></li>
  <li id="ca-ve-edit"><span><a href="/w/index.php?title=Steinplatte&amp;veaction=edit"  title="Diese Seite mit dem VisualEditor bearbeiten [v]" accesskey="v">Bearbeiten</a></span></li>
  <li id="ca-edit" class=" collapsible"><span><a href="/w/index.php?title=Steinplatte&amp;action=edit"  title="Diese Seite bearbeiten [e]" accesskey="e">Bearbeiten</a></span></li>
  <li id="ca-history" class="collapsible"><span><a href="/w/index.php?title=Steinplatte&amp;action=history"  title="Frühere Versionen dieser Seite [h]" accesskey="h">Versionsgeschichte</a></span></li>
  <li id="ca-watch" class="icon"><span><a href="/w/index.php?title=Steinplatte&amp;action=watch&amp;token=redacted"  title="Diese Seite zur persönlichen Beobachtungsliste hinzufügen [w]" accesskey="w">Beobachten</a></span></li>
 </ul>
</div>

after

<div id="p-views" role="navigation" class="vectorTabs" aria-labelledby="p-views-label">
 <h3 id="p-views-label">Ansichten</h3>
  <ul>
   <li id="ca-view" class="collapsible"><span><a href="/w/index.php?title=Steinplatte&amp;stable=1">Lesen</a></span></li>
   <li id="ca-current" class="collapsible collapsible selected"><span><a href="/w/index.php?title=Steinplatte&amp;stable=0&amp;redirect=no" title="Die unmarkieren Änderungen dieser Seite ansehen [Alt+Umschalt+v]" accesskey="v">Ungesichtete Änderungen</a></span></li>
   <li id="ca-ve-edit"><span><a href="/w/index.php?title=Steinplatte&amp;veaction=edit" title="Diese Seite mit dem VisualEditor bearbeiten [Alt+Umschalt+v]" accesskey="v">Bearbeiten</a></span></li>
   <li style="display: block;" id="ca-edit" class="collapsible"><span><a href="/w/index.php?title=Steinplatte&amp;action=edit" title="Diese Seite bearbeiten [Alt+Umschalt+e]" accesskey="e">Quelltext bearbeiten</a></span></li>
   <li style="display: block;" id="ca-history" class="collapsible"><span><a href="/w/index.php?title=Steinplatte&amp;action=history" title="Frühere Versionen dieser Seite [Alt+Umschalt+h]" accesskey="h">Versionsgeschichte</a></span></li>
   <li id="ca-watch" class="icon"><span><a href="/w/index.php?title=Steinplatte&amp;action=watch&amp;token=redacted" title="Diese Seite zur persönlichen Beobachtungsliste hinzufügen [Alt+Umschalt+w]" accesskey="w">Beobachten</a></span></li>
 </ul>
</div>

Note that the normal edit tab is labeled "Bearbeiten" in HTML and gets changed to "Quelltext bearbeiten" only by JS.

Krinkle renamed this task from Infinite collapsing/uncollapsing of VisualEditor's Edit tab on some screen resolutions when tabs are inserted by JS (which doen't happen frequently) to Infinite collapse/uncollapse of "Edit" tab for some screen sizes (doesn't happen frequently).Jul 11 2016, 10:36 PM
Krinkle unsubscribed.