function equalHeight(containerId, divClass, screenWidthMin){
if(!screenWidthMin){
screenWidthMin = 768
}
if(window.screen.width > screenWidthMin){
var maxHeight = 0;
jQuery(`#${containerId} .${divClass}`).each(function(){
if (jQuery(this).height() > maxHeight) {
maxHeight = jQuery(this).height();
}
});
jQuery(`#${containerId} .${divClass}`).each(function(){
jQuery(this).height(maxHeight);
});
}
}
jQuery(document).ready(function(){
jQuery('.owl-carousel-4').owlCarousel({
mouseDrag: false,
touchDrag: true,
dots: false,
margin: 10,
nav: true,
navText: ["
", "
"],
responsive: {
0: {
items: 2
},
768: {
items: 2
},
991.98: {
items: 4
},
1280: {
items: 4
},
}
});
jQuery('.owl-carousel-4-1').owlCarousel({
mouseDrag: false,
touchDrag: true,
dots: false,
margin: 10,
nav: true,
navText: ["
", "
"],
responsive: {
0: {
items: 1
},
768: {
items: 2
},
991.98: {
items: 3
},
1280: {
items: 4
},
}
});
setTimeout(() => {
equalHeight("flashSaleProductList", "promotion-product-image2", 1)
//equalHeight("flashSaleProductList", "oet", 1)
equalHeight("flashSaleProductList", "promotion-product-name", 1)
//equalHeight("flashSaleProductList", "promotion", 1)
}, 1000)
})