如何缩放博客幻灯片中的图像以适合滑动条?

时间:2021-03-13 19:39:55

I put a slideshow on my Blogger (I downloaded a theme with slideshow) and I want to edit this theme. I'm stuck on the picture size of this slide.

我在我的Blogger上放了一个幻灯片(我用幻灯片下载了一个主题),我想编辑这个主题。我被困在这张幻灯片的图片大小上。

I found this code:

我找到了这段代码:

var slider1 = new skewSlider('#main-slider', {
    height: 450,
    imgAlign: 'xMidYMid slice',
    slidePercent: 50,
    visibleSiblings: 1,
    navigationArrows: false,
    siblingsNavigation: true,
    navigationDots: false, 
    slideShow: 5000, 
    navigationArrows: true,
    slideMargin: 0,
    skew:-15,

    breakpoints: {
        tablet: {
            maxWidth : 1024,
            slidePercent : 60,
            height:350,
            showCaption: false,
            skew:0
        },
        phone: {
            maxWidth : 600,
            slidePercent : 70,
            height:300,
            skew:0
        }
    }
});

I found that the option slidePercent changes the size of photos in my slide show, but this is not everything I want. I need my slide to be scaled to fit in the slide bar, and this option only changes it to a percentage of the picture's full size.

我发现slidePercent选项会改变幻灯片中照片的大小,但这不是我想要的一切。我需要将我的幻灯片缩放以适合滑动条,此选项仅将其更改为图片的完整大小的百分比。

How do I do it so that it fits the slide bar?

我该怎么做才能适合滑动条?

1 个解决方案

#1


0  

I find what I need. On this:

我找到了我需要的东西。在这:

imgAlign: 'xMidYMid slice',

I put this:

我把它说:

imgAlign: 'xMidYFull slice',

and

slidePercent: 40

So. You can lock this. Thank you.

所以。你可以锁定它。谢谢。

#1


0  

I find what I need. On this:

我找到了我需要的东西。在这:

imgAlign: 'xMidYMid slice',

I put this:

我把它说:

imgAlign: 'xMidYFull slice',

and

slidePercent: 40

So. You can lock this. Thank you.

所以。你可以锁定它。谢谢。