7001.replace(/\[\[imgsource\]\]/g, element.img)7002.replace(/\[\[imgalttext\]\]/g, t_catalog_escapeQuote(element.alt));7003} else {7004oneBulletTpl = t_catalog_get_productcard_thumbsGallery_html(7005options,7006galleryArr.length,7007maxThumbsCount7008);7009oneBulletStr = oneBulletTpl7010.replace('[[activeClass]]', index === 0 ? 't-slds__bullet_active' : '')7011// TODO ST-2949_5: assignability, arguments, calls, return types (TS2345, TS2322, TS2554, TS2769, TS2740, TS2739, TS2353, TS2349, TS2355, TS2366, TS2774, TS18046)
// @ts-expect-error ST-2949_5 .replace(/\[\[index\]\]/g, index + 1) .replace(/\[\[imgsource_lazy\]\]/g, t_catalog_getLazyUrl(options, element.img)) .replace(/\[\[imgsource\]\]/g, element.img) .replace(/\[\[imgalttext\]\]/g, t_catalog_escapeQuote(element.alt)); } strBullets += oneBulletStr; } } else { oneBulletTpl = t_catalog_get_productcard_oneSliderBullet_html(options); oneBulletStr = oneBulletTpl .replace( '[[videoPlayIcon]]', element.video ? '<div class="t-slds__play_icon">' + t_catalog__svgVideoIcon(options) + '</div>' : '' ) .replace('[[activeClass]]', index === 0 ? 't-slds__bullet_active' : '') // TODO ST-2949_5: assignability, arguments, calls, return types (TS2345, TS2322, TS2554, TS2769, TS2740, TS2739, TS2353, TS2349, TS2355, TS2366, TS2774, TS18046) // @ts-expect-error ST-2949_5 .replace(/\[\[index\]\]/g, index + 1) .replace(/\[\[imgsource_lazy\]\]/g, t_catalog_getLazyUrl(options, element.img)) .replace(/\[\[imgsource\]\]/g, element.img) .replace(/\[\[imgalttext\]\]/g, t_catalog_escapeQuote(element.alt)); strBullets += oneBulletStr; } } }); str = str.replace('[[slides]]', strSlides); if (hasBullets) { str = str.replace('[[bullets]]', strBullets); } var prodSlider = el_popup.querySelector('.js-catalog-prod-slider'); if (prodSlider) prodSlider.innerHTML = str; var templateProductRoot = el_popup.hasAttribute('data-catalog-product-template') ? el_popup : null; t_catalog_galleryVideoHandle(recid, templateProductRoot); var controlsSelStr = '.t-slds__arrow_container, .t-slds__bullet_wrapper, .t-slds__thumbsbullet-wrapper'; var controlsElements = el_popup.querySelectorAll(controlsSelStr); if (controlsElements) { if (galleryArr.length === 1) { Array.prototype.forEach.call(controlsElements, function (el) { el.style.display = 'none'; }); } else { Array.prototype.forEach.call(controlsElements, function (el) { el.style.display = ''; }); } } // TODO ST-2949_2: implicit any on params, vars, this, and index access (TS7006, TS7005, TS7008, TS7034, TS2683, TS7053, TS7015) // @ts-expect-error ST-2949_2 var sliderOptions; if (options.sliderthumbsside === 'l') { sliderOptions = { thumbsbulletGallery: true, storeOptions: options, }; } // ожидаем 200 мс до полного окончания анимации появления попапа setTimeout(function () { t_catalog_onFuncLoad('t_sldsInit', function () { // TODO ST-2949_2: implicit any on params, vars, this, and index access (TS7006, TS7005, TS7008, TS7034, TS2683, TS7053, TS7015) // @ts-expect-error ST-2949_2 t_sldsInit(templateProductRoot || recid + ' .js-catalog-product', sliderOptions); t_catalog__addSlideChangeListener(recid, templateProductRoot); t_catalog__syncProductGallerySlider(recid, templateProductRoot); }); }, 200);}// TODO ST-2949_2: implicit any on params, vars, this, and index access (TS7006, TS7005, TS7008, TS7034, TS2683, TS7053, TS7015)// @ts-expect-error ST-2949_2function t_catalog_galleryVideoHandle(recid, productRoot) { const recEl = productRoot || document.getElementById('rec' + recid); if (!recEl) return; const playButtons = recEl.querySelectorAll('.t-slds__play_icon');