Skip to main content

Bug Tracker

Side navigation

#15159 closed bug (migrated)

Opened June 21, 2014 03:22AM UTC

Closed October 21, 2014 12:40AM UTC

Show animations, like $.show() $.toggle() and $.slideDown(), don't respect css display property if initial state is display:none;

Reported by: nicholasbg Owned by:
Priority: low Milestone: None
Component: effects Version: 1.11.1
Keywords: display inline block none style default show toggle slide animation Cc:
Blocked by: Blocking:
Description

When an element that has a class with a css display property that is not its default (for example a <span> with "display:block"), and has an inline style (like "display:none"), setting it to be displayed with something like $.toggle(200) will cause it to not use the class's display property, while $.toggle() will work properly. Even $.toggle(0) will exhibit this behaviour.

From what I can tell this bug was introduced in 1.11.0/2.1.0

This jsFiddle will demonstrate the bug...

http://jsfiddle.net/e8kpg/

You can see it working normally if you change the jQuery version to something before 1.11.0/2.1.0 or remove the 200 from .toggle(200).

This is a very similar case to...

Ticket #14824

http://bugs.jquery.com/ticket/14824

Attachments (0)
Change History (2)

Changed June 22, 2014 11:22PM UTC by dmethvin comment:1

component: unfiledeffects
priority: undecidedlow
status: newopen
version: 2.1.01.11.1

We have entirely too much magic up in here.

Changed October 21, 2014 12:40AM UTC by m_gol comment:2

resolution: → migrated
status: openclosed