paytonshaltis / freighter

🚂 Freighter is a highly-customizable HTML carousel library featuring a number of dynamic properties affecting carousel items and transitions. Most prominently, it gives complete control over the resizing method (for responsive layouts) as well as the wrapping method (for content display).
https://paytonshaltis.github.io/freighter
MIT License
1 stars 0 forks source link

Add sizing carousel #18

Closed paytonshaltis closed 1 year ago

paytonshaltis commented 1 year ago

Closes #15.

Implements the following resize methods for carousels, whose specifications were described in issue #15: -none -stretch -stretch-gap -stretch-scale

Discovered an odd quirk of the carousels: because the height of a stretch-scale carousel can sometimes add a scrollbar to the page, it means that calculations won't always work correctly when trying to resize items. There are a few fixes for this issue:

These solutions should work well for most people, and there are other ways of getting around the scrollbar issue in CSS.