slideToggle() bug?

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

slideToggle() bug?

ScottChiefBaker
See the following mock up:

http://jsbin.com/ovemo

toggle('slow') and slideToggle('slow') both do the same thing. Is this
somehow related to "display: block" on the sliding image? Is there
another way to slide in and out the last cell of the table? Or is this
an actual bug?

--
You received this message because you are subscribed to the Google Groups "jQuery Development" group.
To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].
For more options, visit this group at http://groups.google.com/group/jquery-dev?hl=en.


Reply | Threaded
Open this post in threaded view
|

Re: slideToggle() bug?

Scott Sauyet-2
On Fri, Jan 15, 2010 at 5:59 PM, ScottChiefBaker <[hidden email]> wrote:
> http://jsbin.com/ovemo
>
> toggle('slow') and slideToggle('slow') both do the same thing. Is this
> somehow related to "display: block" on the sliding image? Is there
> another way to slide in and out the last cell of the table? Or is this
> an actual bug?

I think what you'll find is just that animating table rows is very difficult:

    http://tinyurl.com/y8esbgw

You may find animating the opacity on the row an acceptable substitute.

If you're determined to slide up and down, you probably need to work
with the visible state yourself, add a wrapper element to the content
of each TD in the row, and slide that up or down, hiding or showing
the row itself at the appropriate time.  Here is a version that works
in FF, Chrome, Safari, and Opera:

    http://jsbin.com/edoqa

But it doesn't work in IE, which really does not like these sorts of
manipulations of table rows.  I don't know if there's an easy fix to
that.

But I personally don't like the extra wrappers needed to make it work.
 If fading opacity is acceptable to you, that should be easy to
implement.

Good luck,

  -- Scott

--
You received this message because you are subscribed to the Google Groups "jQuery Development" group.
To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].
For more options, visit this group at http://groups.google.com/group/jquery-dev?hl=en.


Reply | Threaded
Open this post in threaded view
|

Re: slideToggle() bug?

Dan G. Switzer, II
But it doesn't work in IE, which really does not like these sorts of
manipulations of table rows.  I don't know if there's an easy fix to
that.


IE needs you to hide all the TD elements in order to actually hide a TR element.

-Dan 

--
You received this message because you are subscribed to the Google Groups "jQuery Development" group.
To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].
For more options, visit this group at http://groups.google.com/group/jquery-dev?hl=en.