The pager container does not get the correct width set on page load until a resize event occurs. The pager width is too narrow to allow items to sit in a single row.

Comments

mwestoncti’s picture

Status: Active » Needs review
StatusFileSize
new3.61 KB

I wrapped the entire pager initialisation in a window.load function which has fixed my problem.

jomarocas’s picture

Issue summary: View changes

patch number #1 works for me

fearlsgroove’s picture

Status: Needs review » Needs work

I'm not sure it makes sense to plug this into a window.load event within a behavior. For content loaded via ajax, that won't ever get fired. If anything we might wrap that in window.setTimeout, but that has downsides too.

You might be able to fix this by ensuring that your CSS is assigning the correct width explicitly or earlier to prevent the hacky workaround from being necessary. If someone could link to a live demo of this issue that would be very helpful in getting it fixed.

netw3rker’s picture

Status: Needs work » Closed (won't fix)

After thinking more about this, Fearlsgroove's suggestion is the right way to run with this. CSS is the right way to set the container width of the pager, not jquery. One thing that isn't packaged with the 7.x-1.x line of this module is a set of basic CSS guidelines because it relies on the 'skins' that come with 0.2.9 jcarousel.

If someone could submit/suggest a decent set of css guidelines that work w/in the jquery.cycle plugin's skins (which is also required for the 7.x-1.x line of this module due to views slideshow's dependency on it) I'll accept the patch, but for now, I'm going to mark this as "not going to fix" because the fix is really in your own css implementation right now. Also the 7.x-2.x line comes with better width controls that might be worth looking into.

Thanks for the submission though.