Каталог файловtilda-cart-1.1.js
6501 cartIcon.classList.remove('t706__carticon_showed');6502 }6503 }6504 if (cartIconText) {6505 // TODO ST-2949_2: implicit any on params, vars, this, and index access (TS7006, TS7005, TS7008, TS7034, TS2683, TS7053, TS7015)6506 // @ts-expect-error ST-2949_26507 if (cart['amount'] > 0) {6508 // TODO ST-2949_1: missing properties on Window/DOM/data objects (TS2339, TS2551)6509 // @ts-expect-error ST-2949_16510 cartIconText.style.display = 'block';6511 } else {6512
История файла и сравнение версий
// @ts-expect-error ST-2949_1
6513 cartIconText.style.display = 'none'; 6517 tcart__delZeroquantity_inCartObj(); 6519 document.removeEventListener('keyup', tcart__keyUpFunc); 6521 if (cartFullscreen) { 6522 cartFullscreen.scrollTop = 0; 6523 // TODO ST-2949_1: missing properties on Window/DOM/data objects (TS2339, TS2551) 6524 // @ts-expect-error ST-2949_1 6525 cartFullscreen.style.transition = 'opacity .3s'; 6526 // @ts-expect-error ST-2949_1 6527 cartFullscreen.style.opacity = 0; 6529 setTimeout(function () { 6530 // TODO ST-2949_3: null / undefined (TS18047, TS18048, TS2531, TS2722, TS2454, TS2538) 6531 // @ts-expect-error ST-2949_3 6532 cartFullscreen.classList.remove('t706__cartpage_showed'); 6535 window.tcart_issecondstep = false; 6536 tcart__updateDelivery(); 6539 // TODO ST-2949_1: missing properties on Window/DOM/data objects (TS2339, TS2551) 6540 // @ts-expect-error ST-2949_1 6541 if (window.tcart_success === 'yes') { 6542 window.location.reload(); 6547 * It opens the cart sidebar 6549function tcart__openCartSidebar(skip = false) { 6550 // TODO ST-2949_1: missing properties on Window/DOM/data objects (TS2339, TS2551) 6551 if (window.tcart_isMobile || skip) { 6552 tcart__openCartFullscreen(); 6556 t_triggerEvent(document.body, 'popupShowed'); 6557 // TODO ST-2949_3: null / undefined (TS18047, TS18048, TS2531, TS2722, TS2454, TS2538) 6558 // @ts-expect-error ST-2949_3 6559 document.querySelector('body').classList.add('t706__body_cartsidebarshowed'); 6561 tcart__syncProductsObject__LStoObj(); 6562 // TODO ST-2949_5: assignability, arguments, calls, return types (TS2345, TS2322, TS2554, TS2769, TS2740, TS2739, TS2353, TS2349, TS2355, TS2366, TS2774, TS18046) 6563 // @ts-expect-error ST-2949_5 6564 tcart__updateProductsPrice(); 6566 var cartWindow = document.querySelector('.t706__sidebar'); 6567 var contentEl = document.querySelector('.t706__sidebar-content'); 6569 // TODO ST-2949_1: missing properties on Window/DOM/data objects (TS2339, TS2551) 6570 // @ts-expect-error ST-2949_1 6571 cartWindow.style.display = ''; 6573 // @ts-expect-error ST-2949_1 6574 cartWindow.style.opacity = 0; 6575 // @ts-expect-error ST-2949_1 6576 cartWindow.style.transition = 'opacity .3s'; 6577 // TODO ST-2949_3: null / undefined (TS18047, TS18048, TS2531, TS2722, TS2454, TS2538) 6578 // @ts-expect-error ST-2949_3 6579 cartWindow.classList.add('t706__sidebar_showed'); 6581 // фикс для анимации 6582 setTimeout(function () { 6583 // TODO ST-2949_3: null / undefined (TS18047, TS18048, TS2531, TS2722, TS2454, TS2538) 6584 // @ts-expect-error ST-2949_3 6585 contentEl.scrollTop = 0; 6586 // TODO ST-2949_1: missing properties on Window/DOM/data objects (TS2339, TS2551) 6587 // @ts-expect-error ST-2949_1 6588 cartWindow.style.opacity = 1; 6589 // TODO ST-2949_3: null / undefined (TS18047, TS18048, TS2531, TS2722, TS2454, TS2538) 6590 // @ts-expect-error ST-2949_3 6591 contentEl.classList.add('t706__sidebar-content_showed'); 6592 tcart__updateLazyload(); 6595 tcart__syncProductsObject__LStoObj(); 6596 // TODO ST-2949_5: assignability, arguments, calls, return types (TS2345, TS2322, TS2554, TS2769, TS2740, TS2739, TS2353, TS2349, TS2355, TS2366, TS2774, TS18046) 6597 // @ts-expect-error ST-2949_5 6598 tcart__updateProductsPrice(); 6599 tcart__reDrawProducts(); 6600 tcart__reDrawTotal();