PageSourceSearch

https://www.danon.org.il/wp-content/cache/min/1/wp-content/themes/Danon/assets/js/main.js?ver=1786101634

js danon.org.il collected 2026-10-07 06:08:04 UTC 5,291 bytes, 20 lines download raw bytes

1$=jQuery.noConflict();jQuery(document).ready(function($){$('#accessibilityWidget').on('click',()=>{$('#vplugin-toggler').click()})
2const floatBar=$('.floating-bar');function moblieFloatingBar(){if(window.innerWidth<1025){window.addEventListener('scroll',function(){if(window.scrollY>0){floatBar.fadeIn()}else{floatBar.fadeOut()}})}}
3moblieFloatingBar();window.addEventListener("resize",function(){moblieFloatingBar()});$('.show-number').on('click',()=>{$('.phone-slide').toggleClass('open')})
4if(!$('#contact-form').length){$('#floating-form-link').attr('href','/contact-us/')}
5const faqItemButtons=$('.qna-row .qna-button');if(faqItemButtons.length){console.log(faqItemButtons.length);faqItemButtons.on('click',function(){const btn=$(this);const content=btn.siblings('.qna-answer');if(btn.hasClass('opened')){btn.removeClass('opened');content.slideUp()}else{btn.addClass('opened');content.slideDown()}})}});function onResizeFinish(callback){let resizeTimer;$(window).on('resize',function(){clearTimeout(resizeTimer);resizeTimer=setTimeout(callback,100)})}
6function setResponsiveVideo(video){let startWidth=$(window).width();onResizeFinish(function(){if(isScreenWidthChange(startWidth,768)){video.pause();video.load();video.play()}
7startWidth=$(window).width()})}
8function isInViewport(el){const elementTop=el.offset().top;const elementBottom=elementTop+el.outerHeight();const viewportTop=$(window).scrollTop();const viewportBottom=viewportTop+$(window).innerHeight();return(viewportBottom>elementTop)&&(viewportTop<elementBottom)}
9function isScreenWidthChange(start,point){return(start>=point&&$(window).width()<point)||(start<point&&$(window).width()>=point)}
10HTMLVideoElement.prototype.playBackwards=function(){this.pause();let video=this;let fps=25;let intervalRewind=setInterval(function(){if(video.currentTime<=0){clearInterval(intervalRewind);video.pause()}else{video.currentTime-=1/fps}},1000/fps)};jQuery.fn.laptopAnimation=function(){const _this=this;const video=_this.find('video')[0];let status='closed';let lastScrollTop=$(window).scrollTop();let startWidth=$(window).width();_this.runOpeningAnimation=async function(){await video.pause();status='opening';function setOpenedStatus(){status='opened';video.removeEventListener('ended',setOpenedStatus)}
11video.addEventListener('ended',setOpenedStatus);video.play()}
12_this.runClosingAnimation=async function(){await video.pause();status='closing';function setClosedStatus(event){if(event.target.currentTime){status='closed';video.removeEventListener('timeupdate',setClosedStatus)}}
13video.addEventListener('timeupdate',setClosedStatus);video.playBackwards()}
14_this.animation=function(){const scrollDelta=$(window).scrollTop()-lastScrollTop;lastScrollTop=$(window).scrollTop();const screenTop=$(window).scrollTop();const screenBottom=$(window).scrollTop()+$(window).innerHeight();const elTop=_this.offset().top;const elBottom=_this.offset().top+_this.outerHeight();const openingAnimationConditions=[scrollDelta>0,status==='closed'||status==='closing',screenBottom>elBottom,];const closingAnimationConditions=[scrollDelta<0,status==='opened'||status==='opening',elTop-screenTop>=screenBottom-elBottom,];if(openingAnimationConditions.every((condition)=>condition)){_this.runOpeningAnimation();return}
15if(closingAnimationConditions.every((condition)=>condition)){_this.runClosingAnimation();return}};_this.toggleAnimation=function(){if(_this.is(':visible')){$(window).on('scroll',_this.animation)}else{$(window).off('scroll',_this.animation)}}
16_this.toggleAnimation();onResizeFinish(function(){if(isScreenWidthChange(startWidth,768)){_this.toggleAnimation()}
17startWidth=$(window).width()});return _this};function initTestimonialsSlider(el){if(!el.length)return;el.slick({autoplay:!1,autoplaySpeed:4000,arrows:!1,dots:!0,infinite:!1,speed:1000,rtl:!0,rows:2,slidesToShow:2,slidesToScroll:2,appendDots:$('.testimonials-slider-nav .dots'),responsive:[{breakpoint:1300,settings:{slidesToShow:2,slidesToScroll:2,}},{breakpoint:767,settings:{slidesToShow:1,slidesToScroll:1,}},],})}
18function initGraduatesSlider(el){if(!el.length)return;el.slick({autoplay:!1,autoplaySpeed:4000,centerMode:!1,centerPadding:'0px',arrows:!1,dots:!0,infinite:!1,speed:800,rtl:!0,slidesToShow:3,slidesToScroll:3,appendDots:$('.graduates-slider-nav .dots'),responsive:[{breakpoint:767,settings:{centerMode:!0,slidesToShow:2,slidesToScroll:1,}},{breakpoint:550,settings:{centerMode:!1,slidesToShow:1,slidesToScroll:1,}},{breakpoint:450,settings:{centerMode:!1,slidesToShow:1,slidesToScroll:1,}},],})}
19const siteNavigation=document.getElementById('site-navigation');const menu=siteNavigation.getElementsByTagName('ul')[0];const linksWithChildren=siteNavigation.querySelectorAll('.menu-item-has-children > a');for(const linkel of linksWithChildren){linkel.addEventListener('click',toggleFocus,!1);linkel.addEventListener('blur',toggleFocus,!0)}
20function toggleFocus(){if(event.type==='click'&&(window.innerWidth<1024)){event.preventDefault();$(this).parent().toggleClass('focus');$(this).parent().siblings('li').not($(this).parent()).removeClass('focus');$(this).parent().siblings('li').not($(this).parent()).children('.sub-menu').slideUp({duration:200});$(this).siblings('.sub-menu').slideToggle({duration:200,start:function(){jQuery(this).css({display:"flex"})},})}}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.