I was thinking that the accordian could do one of two things.
I like the second suggestion, as it would maintain a constant tranisition time, though yeah, I see whereyou are coming from with the wobble. Its a tricky one, compounded by the fact that a requirement is that the accordian takes up the majority of the page - you might be able to get away with small wobbles etc. if it were a smaller picture, but as its to be the focal point of the page it has to be perfect. Some code bashing to do tommorrow methinks.
Assuming we have panel A, B and C stacked vertically with A currently
the 'expanded' panel and the user has clicked on B.
1) Shrink A one pixel at a time while expanding B one pixel at a time.
When either one hits the limit, then only modify the remaining panel.
So if A is taller than B, then B will be fully displayed while A is
still shrinking.
2) Calculate the ratio of heights between A and B and scale the
shrinking/growth accordingly. So if A is 100px high and B 50px,
shrink A 2 pixels for every 1 pixels that B has. However, due to
rounding we could see a 1 pixel "wobble". The effect might also be
particularly annoying where the ratio is exaggerated -- picture a 20:1
change...
_______________________________________________ Rails-spinoffs mailing list [email protected] http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
