CSS-Tricks / MovingBoxes

Simple horizontal slider which grows up the current box when it's in focus (image, title & text) and back down when it's not in focus.
http://css-tricks.github.io/MovingBoxes/
GNU Lesser General Public License v3.0
280 stars 147 forks source link

stoping images to auto expand when changing width of slider #87

Closed sido74 closed 12 years ago

sido74 commented 12 years ago

Hi there, I want to expand the width of the slider so i can show more images but when i do this the images auto expand and the height gets bigger to. Is there anyway of setting the images to a constrained size so that when expanding the width of the slider more images will show.

thanks

Mottie commented 12 years ago

Check out this demo

If you change the size of the #slider but leave the #slider li width alone, it will make the view port bigger without resizing the panels.

#slider {
    width: 300px;
}
#slider li {
    width: 150px;
}​

Is that what you wanted?

sido74 commented 12 years ago

Yea that was what i was after, although the images when enlarged distort a lot, is there anyway to prevent his?

Mottie commented 12 years ago

I'm guessing that I answered your question in issue #88. If you continue to have problems, please feel free to post your question in the CSS-Tricks forums.