"use strict";
(function ($) {
    $.view_blog_category = function (element, options) {
        let defaults = {
            number_slider:0
            
        }
        let plugin = this;
        plugin.settings = {}
        let $element = $(element);
        plugin.init = function () {
            plugin.settings = $.extend({}, defaults, options);
            let number_slider= plugin.settings.number_slider;
            for (let i = 1;  i<= number_slider; i++ ) {
                let $wrapper_slider = $element.find(`.wrapper-slider-${i}`);
                $element.find(`.block-slider-${i}`).slick({
                    slidesToShow: 1,
                    slidesToScroll: 1,
                    dots: false,
                    prevArrow: $wrapper_slider.find('.prev'),
                    nextArrow: $wrapper_slider.find('.next')
                });
            }


        };
        plugin.example_function = function () {
        };
        plugin.init();
    }
    $.fn.view_blog_category = function (options) {
        return this.each(function () {
            if (undefined == $(this).data('view_blog_category')) {
                let plugin = new $.view_blog_category(this, options);
                $(this).data('view_blog_category', plugin);
            }
        });
    }
})(jQuery);
