-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.min.js
1 lines (1 loc) · 3.34 KB
/
main.min.js
1
function openNav(){var e=document.getElementById("sidebar-wrapper"),t=document.getElementById("fbt-content-overlay"),n=document.querySelector("body");e.classList.add("openSidebar"),t.classList.add("activeOverlay"),e.classList.remove("closeSidebar"),n.classList.add("sidebar-visible")}function closeNav(){var e=document.getElementById("sidebar-wrapper"),t=document.getElementById("fbt-content-overlay"),n=document.querySelector("body");e.classList.remove("openSidebar"),t.classList.remove("activeOverlay"),n.classList.remove("sidebar-visible")}if(!function(e){"use strict";if(Modernizr.mq("(min-width: 0px)")?t=function(e){return Modernizr.mq("(min-width: "+e+"px)")}:minWidth=function(e){return $window.width()>=e},e("#page-content-navigation").length)var t,n,a,s,i,o=e("#page-content-navigation").height();e(window).scroll(function(){var t=e(window).scrollTop();if(t>300?e(".fbt_sticky_nav").addClass("sticky__nav"):e(".fbt_sticky_nav").removeClass("sticky__nav"),t>400?e(".fbt_sticky_nav").addClass("nav_offset"):e(".fbt_sticky_nav").removeClass("nav_offset"),t>500?e(".fbt_sticky_nav").addClass("scrolling_nav"):e(".fbt_sticky_nav").removeClass("scrolling_nav"),e("#page-content-navigation").length){var n=e("#page-content-navigation").scrollTop();t>Number(n)+500?(e("#page-content-navigation").addClass("sticky"),e(".post-body.post-content.post-entry").css("margin-top",o+"px")):(e("#page-content-navigation").removeClass("sticky"),e(".post-body.post-content.post-entry").css("margin-top",0))}}),e(".search-trigger").on("click",function(){e("#search").addClass("active").find(".search").focus()}),e("#search").on("click",function(){e(this).find(".search").focus()}),e("#close").on("click",function(){e("#search").removeClass("active")}),n=e(".fbt-comment-button, .fbt_bottom_toogle"),a=e(".fbt-comment-button").find("span"),s=e(".fbt_bottom_toogle").find("span"),i=e(".comment-list"),n.on("click",function(e){e.preventDefault(),a.toggleClass("fbt-close-icon"),s.toggleClass("fbt_hide_comments"),i.slideToggle()}),e(".blog-category-carousel").length&&e(".blog-category-carousel").owlCarousel({loop:!1,nav:!1,lazyLoad:!0,margin:5,responsive:{0:{items:1},600:{items:2},1e3:{items:3},1200:{items:3},1360:{items:4}}})}(jQuery),!function(e){var t=e("#TopSliderPosts");t.carousel().on("slide.bs.carousel slid.bs.carousel",function n(){e(".slider-title").hide(),t.find(".active").find(".slider-title").addClass("animated fadeIn").one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend",function(){e(this).removeClass("animated fadeIn")}).slideToggle()}).trigger("slide.bs.carousel").on("slide.bs.carousel slid.bs.carousel",function n(){e(".slider-button").hide(),t.find(".active").find(".slider-button").addClass("animated fadeIn").one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend",function(){e(this).removeClass("animated fadeIn")}).slideToggle()}).trigger("slide.bs.carousel")}(jQuery),(document.documentMode||/Edge/.test(navigator.userAgent))&&jQuery(".fbt-post-thumbnail a img, .PopularPosts a img, .RecentPosts a img, .FeaturedPost a img, .fbt-item-thumbnail img").addClass("d-none").each(function(){var e=jQuery(this),t="url("+e.attr("data-src")+")",n=e.parent(),a=jQuery('<div class="fbt-resize"></div>');n.append(a),a.css({"background-image":t}),e.hide()}),void 0===t){let e=lozad();e.observe();var t=!0}else if(!1==t){let n=lozad();n.observe();var t=!0}