/** * Copyright 2024 LÍNEA GRÁFICA E.C.E S.L. * * @author Línea Gráfica E.C.E. S.L. * @copyright Lineagrafica.es - Línea Gráfica E.C.E. S.L. all rights reserved. * @license https://www.apache.org/licenses/LICENSE-2.0 * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * https://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ window.addEventListener('load',function(){ $('.lggooglereviews-owl.owl-carousel').each(function( index ) { var name = "lggooglereviews_owl_"+$(this).data('id'); if(typeof name != 'undefined'){ var value = eval(name); } else{ var value = 4; } // console.log(value); $(this).owlCarousel({ nav: true, items: value, loop: true, responsiveClass: true, margin: 10, autoplay: true, autoplayTimeout: 5000, autoplayHoverPause: true, dots: false, navElement: 'div', responsive: { 0: { items: 1, }, 576: { items: 2, }, 768: { items: 3, }, 992: { items: value, } } }) // console.log($(this)); }); });