Opened 8 years ago
Closed 8 years ago
#15159 closed bug (migrated)
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...
Change History (2)
comment:1 Changed 8 years ago by
Component: | unfiled → effects |
---|---|
Priority: | undecided → low |
Status: | new → open |
Version: | 2.1.0 → 1.11.1 |
comment:2 Changed 8 years ago by
Resolution: | → migrated |
---|---|
Status: | open → closed |
Migrated to https://github.com/jquery/jquery/issues/1774
We have entirely too much magic up in here.