var vcGridStyleAll; ! function ($) { vcGridStyleAll = function (grid) { this.grid = grid, this.settings = grid.settings, this.filterValue = null, this.$el = !1, this.$content = !1, this.isLoading = !1, this.$loader = $('
'), this.init() }, vcGridStyleAll.prototype.init = function () { _.bindAll(this, "addItems", "showItems") }, vcGridStyleAll.prototype.render = function () { this.$el = this.grid.$el, this.$content = this.$el, this.setIsLoading(), this.grid.ajax({}, this.addItems) }, vcGridStyleAll.prototype.setIsLoading = function () { this.$content.append(this.$loader), this.isLoading = !0 }, vcGridStyleAll.prototype.unsetIsLoading = function () { this.isLoading = !1, this.$loader && this.$loader.remove() }, vcGridStyleAll.prototype.filter = function (filter) { if (filter = _.isUndefined(filter) || "*" === filter ? "" : filter, this.filterValue == filter) return !1; var animation = this.$content.closest(".vc_grid-container").data("initial-loading-animation"); vcGridSettings.addItemsAnimation = animation, this.$content.find(".vc_visible-item").removeClass("vc_visible-item " + vcGridSettings.addItemsAnimation + " animated"), this.filterValue = filter, _.defer(this.showItems) }, vcGridStyleAll.prototype.showItems = function () { var $els = this.$content.find(".vc_grid-item" + this.filterValue); this.setIsLoading(); var animation = this.$content.closest(".vc_grid-container").data("initial-loading-animation"); vcGridSettings.addItemsAnimation = animation, $els.addClass("vc_visible-item " + ("none" !== vcGridSettings.addItemsAnimation ? vcGridSettings.addItemsAnimation + " animated" : "")), this.unsetIsLoading(), $(window).trigger("grid:items:added", this.$el) }, vcGridStyleAll.prototype.addItems = function (html) { var els = $(html); this.$el.append(els), this.unsetIsLoading(), this.$content = els.find('[data-vc-grid-content="true"]'), this.grid.initFilter(), this.filter(), window.vc_prettyPhoto() } }(window.jQuery); var vcGridStyleLoadMore = null; ! function ($) { vcGridStyleLoadMore = function (grid) { this.grid = grid, this.settings = grid.settings, this.$loadMoreBtn = !1, this.$el = !1, this.filterValue = null, this.$content = !1, this.isLoading = !1, this.$loader = $(''), this.init() }, vcGridStyleLoadMore.prototype.setIsLoading = function () { this.$loadMoreBtn && this.$loadMoreBtn.hide(), this.isLoading = !0 }, vcGridStyleLoadMore.prototype.unsetIsLoading = function () { this.isLoading = !1, this.setLoadMoreBtn() }, vcGridStyleLoadMore.prototype.init = function () { _.bindAll(this, "addItems") }, vcGridStyleLoadMore.prototype.render = function () { this.$el = this.grid.$el, this.$content = this.$el, this.setIsLoading(), this.$content.append(this.$loader), this.grid.ajax({}, this.addItems) }, vcGridStyleLoadMore.prototype.showItems = function () { var $els = this.$content.find(".vc_grid_filter-item:not(.vc_visible-item):lt(" + this.settings.items_per_page + ")"); this.setIsLoading(); var animation = this.$content.closest(".vc_grid-container").data("initial-loading-animation"); vcGridSettings.addItemsAnimation = animation, $els.addClass("vc_visible-item " + vcGridSettings.addItemsAnimation + " animated"), this.unsetIsLoading(), $(window).trigger("grid:items:added", this.$el) }, vcGridStyleLoadMore.prototype.filter = function (filter) { if (filter = _.isUndefined(filter) || "*" === filter ? "" : filter, this.filterValue == filter) return !1; this.$content.closest(".vc_grid-container").data("initial-loading-animation"); this.$content.find(".vc_visible-item, .vc_grid_filter-item").removeClass("vc_visible-item vc_grid_filter-item "), this.filterValue = filter, this.$content.find(".vc_grid-item" + this.filterValue).addClass("vc_grid_filter-item"), this.showItems() }, vcGridStyleLoadMore.prototype.addItems = function (html) { var els = $(html); this.$el.append(els), this.unsetIsLoading(), this.$content = els.find('[data-vc-grid-content="true"]'), this.$loadMoreBtn = els.find('[data-vc-grid-load-more-btn="true"] .vc_btn3'), this.$loadMoreBtn.length || (this.$loadMoreBtn = els.find('[data-vc-grid-load-more-btn="true"] .vc_btn')); var self = this; this.$loadMoreBtn.click(function (e) { e.preventDefault(), self.showItems() }), this.$loadMoreBtn.hide(), this.grid.initFilter(), this.filter(), this.$loader.remove(), window.vc_prettyPhoto() }, vcGridStyleLoadMore.prototype.setLoadMoreBtn = function () { $('.vc_grid_filter-item:not(".vc_visible-item")', this.$content).length && $(".vc_grid_filter-item", this.$content).length ? this.$loadMoreBtn && this.$loadMoreBtn.show() : this.$loadMoreBtn && this.$loadMoreBtn.hide() } }(window.jQuery); var vcGridStyleLazy = null; ! function ($) { $.waypoints("extendFn", "vc_grid-infinite", function (options) { var opts, el = this; return opts = $.extend({}, $.fn.waypoint.defaults, { container: "auto", items: ".infinite-item", offset: "bottom-in-view", handle: { load: function (opts) {} } }, options), "auto" === opts.container ? el : $(opts.container, el), opts.handler = function (direction) { var $this; "down" !== direction && "right" !== direction || ($this = $(this), $this.waypoint("destroy"), opts.handle.load.call(this, opts)) }, this.waypoint(opts) }), vcGridStyleLazy = function (grid) { this.grid = grid, this.settings = grid.settings, this.$el = !1, this.filterValue = null, this.$content = !1, this.isLoading = !1, this.$loader = $(''), this.init() }, vcGridStyleLazy.prototype.setIsLoading = function () { this.$content.append(this.$loader), this.isLoading = !0 }, vcGridStyleLazy.prototype.unsetIsLoading = function () { this.isLoading = !1, this.$loader && this.$loader.remove() }, vcGridStyleLazy.prototype.init = function () { _.bindAll(this, "addItems", "showItems") }, vcGridStyleLazy.prototype.render = function () { this.$el = this.grid.$el, this.$content = this.$el, this.setIsLoading(), this.grid.ajax({}, this.addItems) }, vcGridStyleLazy.prototype.showItems = function () { var $els = this.$content.find(".vc_grid_filter-item:not(.vc_visible-item):lt(" + this.settings.items_per_page + ")"); this.setIsLoading(); var animation = this.$content.closest(".vc_grid-container").data("initial-loading-animation"); vcGridSettings.addItemsAnimation = animation, $els.addClass("vc_visible-item " + vcGridSettings.addItemsAnimation + " animated"), this.unsetIsLoading(), $(window).trigger("grid:items:added", this.$el) }, vcGridStyleLazy.prototype.filter = function (filter) { if (filter = _.isUndefined(filter) || "*" === filter ? "" : filter, this.filterValue == filter) return !1; var animation = this.$content.closest(".vc_grid-container").data("initial-loading-animation"); vcGridSettings.addItemsAnimation = animation, this.$content.find(".vc_visible-item, .vc_grid_filter-item").removeClass("vc_visible-item vc_grid_filter-item " + ("none" !== vcGridSettings.addItemsAnimation ? vcGridSettings.addItemsAnimation + " animated" : "")), this.filterValue = filter, this.$content.find(".vc_grid-item" + this.filterValue).addClass("vc_grid_filter-item"), _.defer(this.showItems), this.initScroll() }, vcGridStyleLazy.prototype.addItems = function (html) { var els = $(html); this.$el.append(els), this.unsetIsLoading(), this.$content = els.find('[data-vc-grid-content="true"]'), this.grid.initFilter(), this.filter(), window.vc_prettyPhoto() }, vcGridStyleLazy.prototype.initScroll = function () { var self = this; this.$content.unbind("waypoint").waypoint("vc_grid-infinite", { container: "auto", items: ".vc_grid-item", handle: { load: function (opts) { self.showItems(), self.checkNext(opts) } } }) }, vcGridStyleLazy.prototype.checkNext = function (opts) { if (this.$content.find('.vc_grid_filter-item:not(".vc_visible-item")').length) { var fn, self = this; fn = function () { return self.$content.waypoint(opts) }, _.defer(fn) } } }(window.jQuery); var vcGridStylePagination = null; ! function ($) { vcGridStylePagination = function (grid) { this.grid = grid, this.settings = grid.settings, this.$el = !1, this.$content = !1, this.filterValue = null, this.isLoading = !1, this.htmlCache = !1, this.$loader = $(''), this.$firstSlideItems, this.init() }, vcGridStylePagination.prototype.init = function () { _.bindAll(this, "addItems", "initCarousel") }, vcGridStylePagination.prototype.setIsLoading = function () { this.$loader.show(), this.isLoading = !0 }, vcGridStylePagination.prototype.unsetIsLoading = function () { this.isLoading = !1, this.$loader.hide() }, vcGridStylePagination.prototype.render = function () { this.$el = this.grid.$el, this.$content = this.$el, this.$content.append(this.$loader), this.setIsLoading(), this.grid.ajax({}, this.addItems) }, vcGridStylePagination.prototype.filter = function (filter) { if (filter = _.isUndefined(filter) || "*" === filter ? "" : filter, this.filterValue == filter) return !1; var $html; this.$content.data("owl.vccarousel") && (this.$content.off("initialized.owl.vccarousel"), this.$content.off("changed.owl.vccarousel"), this.$content.data("vcPagination") && this.$content.data("vcPagination").twbsPagination("destroy"), this.$content.data("owl.vccarousel").destroy()), this.$content.empty(), $html = $(".vc_grid-item", this.htmlCache), "" !== filter && ($html = $html.filter(filter)), this.filterValue = filter, this.buildSlides($html.addClass("vc_visible-item")) }, vcGridStylePagination.prototype.buildSlides = function ($html) { var i, j, tempArray, chunk = parseInt(this.settings.items_per_page); for (i = 0, j = $html.length; i < j; i += chunk) tempArray = $html.slice(i, i + chunk), $('