Каталог файловtilda-feed-1.0.js
1901 window.history.pushState(popupState, null, window.location.origin + window.location.pathname + anchor);1902 });1903 });1904}1905 1906function t_feed_addPostPopupGallery(recid, post) {1907 if (post.mediadata !== '' && JSON.parse(post.mediadata).length > 0) {1908 t_feed_setGalleryImageHeight(recid);1909 1910 t_feed_onFuncLoad('t_sldsInit', function () {1911 t_sldsInit(recid + ' .t-feed__post-popup');1912
История файла и сравнение версий
if (window.lazy === 'y' || document.querySelector('#allrecords').getAttribute('data-tilda-lazy') === 'yes') {
1913 t_feed_onFuncLoad('t_lazyload_update', function () { 1914 t_lazyload_update(); 1918 t_feed_onFuncLoad('t_slds_updateSlider', function () { 1919 t_slds_updateSlider(recid + ' .t-feed__post-popup'); 1922 t_feed_onFuncLoad('t_slds_UpdateSliderHeight', function () { 1923 t_slds_UpdateSliderHeight(recid + ' .t-feed__post-popup'); 1926 t_feed_onFuncLoad('t_slds_UpdateSliderArrowsHeight', function () { 1927 t_slds_UpdateSliderArrowsHeight(recid + ' .t-feed__post-popup'); 1934 * Add skeleton for popup elements on slow load 1936function t_feed_addPostPopupLoader() { 1938 for (var i = 0; i < 20; i++) { 1939 loader += '<div class="t-feed__post-popup__text-loader"></div>'; 1941 document.querySelector('.js-feed-post-text').innerHTML = loader; 1945 * Add zoom for images in popup if zoom setting is on 1947function t_feed_addZoom() { 1948 var images = document.querySelectorAll('.js-feed-post-text img'); 1949 Array.prototype.forEach.call(images, function (image) { 1950 image.classList.add('t-zoomable'); 1951 image.setAttribute('data-zoomable', 'yes'); 1952 image.setAttribute('data-img-zoom-url', image.getAttribute('src')); 1956function t_feed_showPopup(recid, post, opts) { 1957 var rec = document.querySelector('#rec' + recid); 1958 var popup = rec.querySelector('.t-feed__post-popup.t-popup'); 1959 var arrowTop = popup.querySelector('.t-feed__post-popup__arrow-top'); 1960 var currentUrl = window.location.href; 1961 popup.style.display = 'block'; 1962 popup.classList.add('t-popup_show'); 1964 setTimeout(function () { 1965 popup.querySelector('.t-popup__container').classList.remove('t-feed__post-popup__container_loading'); 1967 t_feed__trapFocus(popup); 1968 // a11y: add class to the trigger button for focus 1969 t_feed__addClassOnTriggerButton(); 1972 setTimeout(function () { 1973 popup.querySelector('.t-popup__container').classList.add('t-popup__container-animated'); 1974 if (window.lazy === 'y' || document.querySelector('#allrecords').getAttribute('data-tilda-lazy') === 'yes') { 1975 t_feed_onFuncLoad('t_lazyload_update', function () { 1976 t_lazyload_update(); 1982 ttable.init_ttable(); 1985 document.body.classList.add('t-body_popupshowed'); 1986 t_feed_getCountOfViews(popup); 1989 popup.addEventListener('scroll', function () { 1990 t_feed_addPostPopupArrowTop(this, arrowTop); 1993 arrowTop.addEventListener('click', function () { 1994 t_feed_scrollTo(popup, 0, 300); 1998 t_feed_openShare(popup); 1999 t_feed_sendDataToAnalytics(popup, post);