Last modified: 2014-11-17 10:35:54 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 T33832, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 31832 - Collapsing mw-collapsible tables is notably delayed (broken animation) in all browsers
Collapsing mw-collapsible tables is notably delayed (broken animation) in all...
Status: RESOLVED DUPLICATE of bug 34876
Product: MediaWiki
Classification: Unclassified
JavaScript (Other open bugs)
1.21.x
All All
: Normal normal with 3 votes (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-10-19 22:15 UTC by TMg
Modified: 2014-11-17 10:35 UTC (History)
7 users (show)

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


Attachments

Description TMg 2011-10-19 22:15:49 UTC
With class="mw-collapsible" it's possible to create collapsible tables and more. This works in the Opera webbrowser (current 11.51). But there is a strange delay when collapsing the table. It feels like there should be an animation but it is missing for some reason.

When I click "expand" ("Ausklappen" in the German Wikipedia) everything is displayed immediately in the moment I clicked. This is what I expect.

When I click "collapse" ("Einklappen" in the German Wikipedia) the toggle changes to "expand" but the table does not collapse. It collapses about a second later.

What I request is: Collapse the table immediately or at least very fast. I don't care about animations. Animations are always very annoying to me. When I click something it should *do* what I want in the moment I click.
Comment 1 Brion Vibber 2011-10-19 23:15:16 UTC
Sample URL?
Comment 2 TMg 2011-10-20 21:20:33 UTC
Everything with class="mw-collapsible". For example
http://de.wikipedia.org/wiki/Hilfe:Tabellen#mw-collapsible
Comment 3 Krinkle 2011-10-20 21:25:19 UTC
I don't see how this is related to Opera. When I open that URL in Opera 11.0, by the time it auto-jumps to that section it's already initialized, pre-collapsed and everything for me.

Does it go fast for you in Firefox or Chrome ?
Comment 4 TMg 2011-10-21 14:22:24 UTC
You are right, same bug in all web browsers (tested with Opera 11, Opera 12, Firefox 7, IE 8). When clicking "collapse" there is a 1 second delay before it collapses.

When clicking "expand" it expands immediately in all browsers.

I'm afraid the delay is by purpose. In Firefox I can see some graphical clutter that probably should "mimic" an animation. The text in the table fades out tediously slow. This does not make any sense (from my point of view) because the table itself is not affected. Only the text fades out. At the end of this fading animation the table is hidden without an animation. I find this very annoying.

Please remove this broken, time wasting animation. It does not work at all in most browsers and is broken in Firefox. It does not make sense to fade out text when the user wants to collapse a table. Fading out letters is no substitution to collapsing a block.

If you insist of using an animation, please, please make it very fast (0.2 seconds or faster).
Comment 5 Mark A. Hershberger 2011-10-21 15:45:06 UTC
Think solving Bug 30401 would solve this.

*** This bug has been marked as a duplicate of bug 30401 ***
Comment 6 TMg 2011-10-23 23:04:39 UTC
An option to turn of all the annoying animations (they are annoying for me) would be nice but does not fix this bug. Animating tables does not work as described if animations are turned on.
Comment 7 Krinkle 2011-10-23 23:21:58 UTC
Indeed. Making an option to disable animations does not fix the problems that animations are bugging.

Anyway, these are standard jQuery animations and they are working fine for me. I guess the animations are a come heavier depending on the computer graphics performance. Perhaps an upstream issue to look at for the jQuery folks.

Alternatively we could go fancy and use CSS3 for these animation. Which means:
* old browsers will have no animations = no lagging animations, as they do not support css3
* modern browsers will have very smooth animations (smoother as with javascript).
Comment 8 Erwin Dokter 2011-10-24 10:39:10 UTC
The way the tables are animated is wrong. Slower machines (especially IE) barely show the fade-in effect, making it appear as if nothing is happening. Fades should only be used (if at all) on elements with a static size. A more appropriate animation for(un)collapsing tables is the ('height', 'show/hide') method.
Comment 9 Brion Vibber 2011-10-26 00:16:15 UTC
So if I understand, the situation is:

* bug reporter sees either missing or broken fade-out animation
** no fade-out on Opera
*** it does delay for a bit as if it were doing a fade-out animation
** very slow fade-out on Firefox

IMO this fade-out looks like crap anyway -- hide/show like this usually should be done with a roll-up -- and should not be used here.

But it seems a bit odd that the fade just _doesn't work_ on Opera, unless something is interfering.
Comment 10 Erwin Dokter 2011-10-26 07:33:58 UTC
jQuery animates elements by manipulating their CSS properties in 'realtime'. It is not just the speed if the javascript engine that matters, but also the speed of the browser's rendering engine, which is very dependent on the machine's capabilities. Old video cards/drivers are prone to stalling while rendering the animations. Perhaps Opera has trouble calculating the opacity to render the fade effect.

I agree that tables should simply slide up/down in 200ms ('fast').
Comment 11 Daniel Friesen 2011-10-26 08:00:21 UTC
jQuery doesn't even bother to use requestAnimationFrame yet. There was a bug on it (which was supposedly marked fixed , and a pull request, but it doesn't look like the code has even made it into HEAD of master much less a stable release yet.
Comment 12 TMg 2011-10-26 08:21:36 UTC
(In reply to comment #9)
> But it seems a bit odd that the fade just _doesn't work_ on Opera

No, it does not work in ALL browsers. Nothing is animated in Internet Explorer, nothing is animated in Opera. In Firefox the WRONG property is animated (the color) as explained above multiple times.

This is true for tables. The situation is a bit better for DIV elements, but not much. The animation is also horribly slow, useless, wasting time, and depending on the situation where it's used it's often misplaced, does not make sense, creates graphical clutter, is distracting, flickering, ...

I think you get it. The main reason for adding an animation to mw-collapsible elements is the animation itself. "Look, we are so cool, we can abuse JavaScript to make parts of the site you are reading float around."
Comment 13 Krinkle 2012-08-29 14:44:38 UTC

*** This bug has been marked as a duplicate of bug 34876 ***
Comment 14 TMg 2012-12-31 00:17:44 UTC
Why do you think this is a duplicate? Bug 34876 is about performance, this bug is about broken animations.

Create a simple table.

{| class="mw-collapsible"
! Example
|-
| Example
|}

Click "collapse". Nothing happens for about a second. A second later the table collapses. Expanding the same table is not delayed.

My proposed solution is: Simply remove the broken animation code. This will remove the useless delay.
Comment 15 Erwin Dokter 2012-12-31 19:25:29 UTC
They are both a result of the same cause; the jQuery MakeCollapsible plugin. Therefore closing again, let's keep it central.

*** This bug has been marked as a duplicate of bug 34876 ***
Comment 16 TMg 2013-01-08 13:22:51 UTC
These are two completely different bugs. Why do you think a bug about bad performance with many collapsible elements is the same as a bug about a broken animation for a single table row?
Comment 17 Erwin Dokter 2013-01-08 20:25:06 UTC
Because thay are both caused by the same code. Which means that once that code is fixed, BOTH issues will be fixed. Please stop reopening this bug.

*** This bug has been marked as a duplicate of bug 34876 ***
Comment 18 TMg 2013-01-08 21:22:15 UTC
From what I see in the changesets the broken animation code is not removed.

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


Navigation
Links