!function( e ){"use strict"; e( document ).ready( function( e ){e( "a" ).on( "click", function( ){e( this ).blur( )} ); var a = e( "#secondary" ); if ( "function" == typeof e.fn.theiaStickySidebar && a.theiaStickySidebar( {additionalMarginTop:126} ), "function" == typeof e.fn.slick && ( e( ".blogito-featured-slider" ).slick( {infinite:!0, autoplay:!0, autoplaySpeed:3e3, speed:1e3, slidesToShow:Number( blogito.home_page_slider_img_number ), slidesToScroll:1, responsive:[{breakpoint:800, settings:{slidesToShow:1, slidesToScroll:1}}]} ), "" !== blogito.galleryClass ) ){var i = e( blogito.galleryClass ), n = e( ".blogito-featured-slider-wrapper" ); n.show( ), i.slick( {infinite:!0, speed:1e3, slidesToShow:1, slidesToScroll:1, responsive:[{breakpoint:480, settings:{slidesToShow:1, slidesToScroll:1}}]} )}"function" == typeof e.fn.magnificPopup && ( e( ".gallery" ).each( function( ){e( this ).magnificPopup( {delegate:'.gallery-item:not(.slick-cloned) a[href*=".jpg"], .gallery-item:not(.slick-cloned) a[href*=".jpeg"], .gallery-item:not(.slick-cloned) a[href*=".png"], .gallery-item:not(.slick-cloned) a[href*=".gif"]', type:"image", gallery:{enabled:!0}, image:{titleSrc:function( e ){return e.el.parents( ".gallery-item" ).text( )}, cursor:null}} )} ), e( 'a[href*=".jpg"], a[href*=".jpeg"], a[href*=".png"], a[href*=".gif"]' ).each( function( ){0 === e( this ).parents( ".gallery" ).length && e( this ).magnificPopup( {type:"image", image:{titleSrc:function( e ){return e.el.parent( ".wp-caption" ).children( ".wp-caption-text" ).text( )}, cursor:null}} )} ) ); var t = e( ".blogito-search-panel" ), l = e( ".search-toggle" ); l.on( "click", function( ){t.slideToggle( 250 ).css( "z-index", "1001" ), e( this ).attr( "aria-expanded", "true" )} ), e( ".blogito-search-panel-close" ).on( "click", function( ){t.slideToggle( 250 ).css( "z-index", "" ), l.attr( "aria-expanded", "false" )} ); var o = e( "#top-navigation" ), r = 0; e( window ).scroll( function( ){var a = e( this ).scrollTop( ); a > 70 && a > r?o.slideUp( 100 ):o.slideDown( 200 ), r = a} ); var s, c, g, d; s = e( "#left-navbar-toggle" ), d = e( ".left-sidebar-bg" ), g = e( "#left-sidebar" ), c = e( ".left-sidebar-close" ), s.on( "click", function( ){p( )} ), c.on( "click", function( ){p( )} ), d.on( "click", function( ){p( )} ); var p = function( ){g.is( ":visible" )?s.attr( "aria-expanded", "false" ):s.attr( "aria-expanded", "true" ), g.toggle( "slide", {direction:"left"}, 500, "linear" ), d.fadeToggle( 500 )}, h = e( "#site-navigation .expand-submenu" ); h.on( "click", function( ){e( this ).hasClass( "submenu-expanded" )?( e( this ).css( {transform:"none"} ).removeClass( "submenu-expanded" ).prop( "title", blogito.expandText ), e( this ).parent( ).children( "ul" ).slideToggle( ) ):( e( this ).css( {transform:"rotate(45deg)"} ).addClass( "submenu-expanded" ).prop( "title", blogito.closeText ), e( this ).parent( ).children( "ul" ).slideToggle( ) )} ); var f = new Date, u = f.getDate( ), m = f.getFullYear( ), y = blogito.days[f.getDay( )], b = blogito.months[f.getMonth( )], v = y + ", " + b + " " + u + ", " + m; e( "#today-date" ).append( v ), e( ".posts-navigation" ).hide( ); var x = e( ".masonry-container" ); if ( "function" == typeof Masonry && imagesLoaded( document.querySelector( ".masonry-container" ), function( ){e( function( ){x.imagesLoaded( function( ){x.masonry( {itemSelector:".masonry"} )} )} )} ), "infinite" === blogito.pagination && "function" == typeof e.infinitescroll && x.infinitescroll( {navSelector:".posts-navigation", nextSelector:".nav-previous > a", itemSelector:".masonry", loading:{finished:void 0, finishedMsg:"", img:blogito.getTemplateDirectoryUri + "/slick/ajax-loader.gif", msg:null, msgText:blogito.loadingText, selector:null, speed:"fast", start:void 0}}, function( a ){var i = e( a ).css( {opacity:0} ); i.imagesLoaded( function( ){i.animate( {opacity:1} ), x.masonry( "appended", i, !0 )} )} ), "ajax" === blogito.pagination ){var k = parseInt( blogito.startPage, 10 ) + 1, T = parseInt( blogito.maxPages, 10 ), S = blogito.nextLink; T >= k && ( e( "#primary" ).append( '
" ), e( ".navigation" ).remove( ) ); var j = e( "#blogito-load-more a" ); j.on( "click", function( ){return T >= k?( e( this ).css( "opacity", "0" ).css( "transition", "0" ), e.ajax( {url:S, cache:!1, dataType:"html", success:function( i ){var n = e( i ).find( ".masonry" ); "function" == typeof Masonry && ( n = e( n ).css( {opacity:0} ), x.append( n ).imagesLoaded( function( ){n.animate( {opacity:1} ), x.masonry( "appended", n, !0 ), "function" == typeof e.fn.theiaStickySidebar && a.theiaStickySidebar( {additionalMarginTop:105} ), k++, S = S.replace( /\/page\/[0-9]*/, "/page/" + k ).replace( /paged=[0-9]*/, "paged=" + k ), T >= k?j.css( "opacity", "1" ).text( blogito.loadMoreText ):j.css( "opacity", "1" ).text( blogito.noMorePostsText )} ) )}} ) ):j.append( "" ), !1} )}x.on( "click", ".blogito-jp-sharing-toggle", function( ){e( this ).siblings( ".comments-link" ).toggle( ), e( this ).toggle( ).siblings( ".blogito-jp-sharing" ).toggle( "slide", {direction:"right"}, 400, "linear" ).siblings( ".blogito-jp-sharing-close" ).toggle( ), e( this ).siblings( ".blogito-jp-sharing-close" ).toggle( )} ), x.on( "click", ".blogito-jp-sharing-close", function( ){e( this ).toggle( ).siblings( ".blogito-jp-sharing" ).toggle( "slide", {direction:"right"}, 400, "linear" ), e( this ).siblings( ".blogito-jp-sharing-toggle" ).toggle( ), e( this ).siblings( ".comments-link" ).fadeToggle( 1e3 )} )} )}( jQuery );