John,

>Everyone: I really discourage against making plugins rely on step:
>right now - it's an undocumented function that was going to be removed
>from jQuery. However, since people are using it now, that means that
>its API will have to be adapted to work with the upcoming jQuery 1.2
>animation changes.
>
>Namely, step will now be passed a decimal representing a number 0 to 1
>(1 means that the animation is complete). So just a big word of
>warning, I wouldn't adapt too many accordion plugins to use it yet,
>since the change is imminent.

What technique would you suggest fixing the bump in v1.2?

Right now, you're using the step because it returns the current height of
the item being hidden. This allows you to offset how much of the newly
visible panel should be shown.

Were you planning in v1.2 to have a property callback function that could be
used in a similar manor?

This does seem like a useful feature--but maybe it should be called "onstep"
instead.

I could see why you might want to adjust other elements based on the current
animation status.

How would you recommend fixing this code for 1.2+?

I can easily "future proof" this plug-in now--that way there's no need to
update when the next version of jQuery comes out.

-Dan

Reply via email to