Ticket #4267 (closed bug: notabug)

Opened 4 years ago

Last modified 3 years ago

Accordion height problems under a varierty of conditions

Reported by: Thaddeus Owned by:
Priority: major Milestone: 1.8
Component: ui.accordion Version: 1.6rc6
Keywords: Cc:
Blocking: Blocked by:

Description

I logged this earlier, but it got tagged as ui.core, which the link to report on is broken. Now correctly logged.

Autoheight works and fillspace works - on intialization, but adding more items changes the overall size, thus overflowing the container div that has an absolute height. I have 8 items in my accordion .

I tried to use the clearstyle option with fillspace hoping the height would dynamically reset itself, but it seems to trigger the fillspace first, then clears the style after... so fillspace flickers on, then ends up getting ignored. I think it should do the opposite. Clearstyle then set fillspace.

the sizing of this plugin (in 1.6) seems difficult to set and/or maintain.

Attachments

accordionbug.html Download (3.7 KB) - added by Thaddeus 4 years ago.
Sample height problem

Change History

Changed 4 years ago by Thaddeus

Sample height problem

comment:1 in reply to: ↑ description Changed 4 years ago by Thaddeus

Replying to Thaddeus:

I logged this earlier, but it got tagged as ui.core, which the link to report on is broken. Now correctly logged.

Autoheight works and fillspace works - on intialization, but adding more items changes the overall size, thus overflowing the container div that has an absolute height. I have 8 items in my accordion .

I tried to use the clearstyle option with fillspace hoping the height would dynamically reset itself, but it seems to trigger the fillspace first, then clears the style after... so fillspace flickers on, then ends up getting ignored. I think it should do the opposite. Clearstyle then set fillspace.

the sizing of this plugin (in 1.6) seems difficult to set and/or maintain.

Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10.5; en-US; rv:1.9.0.6) Gecko/2009011912 Firefox/3.0.6

comment:2 Changed 4 years ago by trip

After doing some investigation, on the fillSpace option, it looks like the accordion spills below the container divs bottom position of 0 because there's a top-margin setting of 1px (found in the theme roller css file). The top-margin setting is required to create a space between each of the panels. So for each panel in the accordion; 1 px will overflow.... This can be fixed by changing the bottom position of the container div from 0px; to 8px; or rather whatever number of panels you happen to have in your accordion. This doesn't solve the problem completely since dynamically adding new panels or 'zooming' via the browser will still cause incremental spillover. I would suggest the plugin should be changed so that the fillpace sizing accounts for the number of panels.

comment:3 Changed 4 years ago by rdworth

  • Milestone changed from TBD to 1.8

comment:4 Changed 4 years ago by joern.zaefferer

Using .resize() after changing the accordion content could fix the issue, but in case content should shrink, wouldn't work. For that .resize() would have to remove previous inline-heights first.

comment:5 Changed 4 years ago by joern.zaefferer

  • Status changed from new to closed
  • Resolution set to invalid

Unable to reproduce this based on  http://jquery-ui.googlecode.com/svn/trunk/tests/visual/accordion/accordion_option_fillSpace_true.html

May be partially fixed by #4695, which still leaves some issues unresolved.

Please reopen with a testpage based on 1.7.2 or 1.8.x.

Note: See TracTickets for help on using tickets.