Andrei | фикс бага js при первом добавлении товара с открытием корзины

pull/36/head
parent 60bcacea61
commit 4096f8a8d5
  1. 6
      wp-content/themes/cosmopet/modules/shop/components/cart/assets/js/cart.js

@ -229,11 +229,9 @@ jQuery(document).ready(function($) {
var width = $basket[0] ? $basket[0].clientWidth : 600; var width = $basket[0] ? $basket[0].clientWidth : 600;
setTimeout(function() { setTimeout(function() {
if (device <= 720) { if (device <= 720) {
$aside.css('width', device + 'px'); $aside.addClass('active')
console.log('[openBasketOnFirstAdd] aside width:', device + 'px');
} else { } else {
$aside.css('width', width + 'px'); $aside.addClass('active')
console.log('[openBasketOnFirstAdd] aside width:', width + 'px');
} }
}, 10); }, 10);
setCookie('basket_popup_shown', '1', 30); setCookie('basket_popup_shown', '1', 30);

Loading…
Cancel
Save