Light Gallery youtubeThumbSize 不起作用

Light Gallery youtubeThumbSize not working

我正在为 YouTube 视频使用 LightGallery。我正在尝试更改默认缩略图,但它不起作用。

视图中我有:

<div class="video-gallery">
    <div id="lightgallery">

        <span class="video" data-src="https://www.youtube.com/watch?v=meBbDqAXago">
            <a href="">
                <img class="img-responsive" src="http://img.youtube.com/vi/meBbDqAXago/0.jpg" style="width: 100%;">
            </a>
        </span>
        <i data-src="https://www.youtube.com/watch?v=Pq9yPrLWMyU"></i>

    </div>
</div>

javascript

$('#video-gallery').lightGallery({
    loadYoutubeThumbnail: true,
    youtubeThumbSize: 0,
});

并且我有以下脚本并且 css 已加载

{!! HTML::style('css/web/lightgallery.css') !!}
{!! HTML::style('css/web/lg-video.css') !!}

{!! HTML::script('js/web/lightgallery.min.js') !!}
{!! HTML::script('js/web/lg-thumbnail.min.js') !!}
{!! HTML::script('js/web/lg-fullscreen.min.js') !!}
{!! HTML::script('js/web/lg-video.min.js') !!}

youtubeThumbSize 应该是选择您想在图库中显示的缩略图。我曾尝试使用 0 或 2,但始终使用默认值 1。我怎样才能使用另一个缩略图?哪里不对?

已解决我添加了散列插件,因为我需要在同一页面中创建多个视频库,并且以这种方式工作。这些是更改:

视图中:

<div class="video-gallery">
<div id="hash1">

    <span class="video" data-src="https://www.youtube.com/watch?v=meBbDqAXago">
        <a href="">
            <img class="img-responsive" src="http://img.youtube.com/vi/meBbDqAXago/0.jpg" style="width: 100%;">
        </a>
    </span>
    <i data-src="https://www.youtube.com/watch?v=Pq9yPrLWMyU"></i>

</div>

javascript:

$("#hash1").lightGallery({
    hash: true,
    galleryId: 1,
    loadYoutubeThumbnail: true,
    youtubeThumbSize: 0,
});

而且我还添加了 LightGallery 的 插件

{!! HTML::script('js/web/lg-hash.min.js') !!}