carouFredSel responsive height

前端 未结 14 700
一整个雨季
一整个雨季 2021-01-30 11:46

i am having height problems of my responsive carousel using carouFredSel.

since the images are responsive and the carousel is also set to responsive.

It still ad

相关标签:
14条回答
  • 2021-01-30 12:40

    I had this same issue and did the following:

    Removed the lines from 3648 to 3652, these lines looks like:

    if (is_number(o.items[o.d[dim]]))
    {
        console.log(o.d[dim]);
        return o.items[o.d[dim]];
    }
    

    And this code is inside function ms_getLargestSize.

    This solved the List height problem. To solve the wrapper height I changed from true to false the param at line ~3609, the line looks like:

    var sz = cf_mapWrapperSizes(ms_getSizes($v, o, true), o, false);
    

    Change to:

    var sz = cf_mapWrapperSizes(ms_getSizes($v, o, false), o, false);
    

    After this, the slider is working fine when resized and isn't cropping the elements like divs anymore!

    I hope it helps, Rafael Angeline

    0 讨论(0)
  • 2021-01-30 12:41

    http://caroufredsel.dev7studios.com/examples/responsive-carousels.php the trick is to make the width and height inside items.

    $("#foo2").carouFredSel({
        responsive  : true,
        scroll      : {
            fx          : "crossfade"
        },
        items       : {
            visible     : 1,
            width       : 870,
            height      : "46%"
        }
    });
    

    Greetings Lars

    0 讨论(0)
提交回复
热议问题