|
|
/** * ThemeMountain Timber Framework * Version: 1.1.4 * URL: @ThemeMountain */
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) })(window,document,'script','//www.google-analytics.com/analytics.js','ga'); ga('create', 'UA-54904032-4', 'auto'); ga('send', 'pageview');
$( function(){
"use strict";
// Version
var versionNumber = 'v.1.1.5'; $( '.version-number' ).each( function(){ var text = $( this ).text(); $( this ).text( text + ' ' + versionNumber ); });
// download link
$( '.download-link' ).attr( 'href', 'http://download.thememountain.com/framework/framework_download_'+ versionNumber + '.zip');
// Code blocks
$( '.code-snippet' ).each( function( i ){
// Some variables
var pre = $( this ).find( 'pre' ); var code = $( this ).find( 'code' ); var content = code.html(); var ctcButton; var copyCode;
// Create and append ctc button
ctcButton = $( '<button data-clipboard-target="#snippet-' + i + '" class="button rounded small bkg-charcoal color-white bkg-hover-charcoal-light color-hover-white copy-to-clipboard">Copy</button>' ); code.attr( 'id', 'snippet-' + i ); ctcButton.appendTo( pre );
// Add clipboard event
copyCode = new Clipboard( '.copy-to-clipboard' ); copyCode.on( 'success', function(event) { event.clearSelection(); event.trigger.textContent = 'Copied'; window.setTimeout(function() { event.trigger.textContent = 'Copy'; }, 2000 ); }); copyCode.on('error', function(event) { event.trigger.textContent = 'Press "Ctrl + C" to copy'; window.setTimeout(function() { event.trigger.textContent = 'Copy'; }, 2000 ); });
// Format code
// Check script or link tags are already escaped
if ( code.text().indexOf( 'script' ) >= 0 || code.text().indexOf( 'link' ) >= 0 ) code.addClass( 'escaped' ); // Escape and handle indentation
var tabs = content.match( /\s*\n[\t\s]*/ ); code.html( content.replace( new RegExp( tabs, 'g' ), '\n' ) ); code.html( escapeHtml( code.html() ) ); function escapeHtml( text ) { var chars = { '&': '&', '<': '<', '>': '>', '`': '>', '"': '"', "'": ''' }; return text.replace( /[&<>`"']/g, function( m ) { return chars[m]; }); }
// Format escaped sections
if ( code.hasClass( 'escaped' ) ){ var scriptTag = $( '<div/>' ).html( code.text() ).text(); code.text( scriptTag ); } }); });
/** * Swipe Plugin * Version: 1.0 */ !function(t){"use strict";t.fn.swipeIt=function(i){var e=t.extend({swipeThreshold:40,scrollThreshold:10,draggable:!1,preventTouchOn:"",onSwipeMove:null,onSwipeEnd:null},i),a=this,n=0,s=0,o=e.swipeThreshold,r="ontouchend"in document,d=r?"touchstart":"pointerdown",c=r?"touchmove":"pointermove",l=r?"touchend":"pointermove",u=function(t){t.stopPropagation(),n=t.originalEvent.touches?t.originalEvent.touches[0].pageX:t,a.on(c,h)},h=function(i){if(!t(i.target).closest(e.preventTouchOn).length||""===e.preventTouchOn){if(s=i.originalEvent.touches?i.originalEvent.touches[0].pageX:i,Math.abs(n-s)>e.scrollThreshold&&i.preventDefault(),e.draggable){var o;o=-(n-s),e.onSwipeMove(o)}if(s===n)return!1;a.on(l,p)}},p=function(){var t;Math.abs(s-n)>o&&(t=s>n?"left":"right",e.onSwipeEnd(t)),a.off(c,h),a.off(l,p)};return a.on(d,u),this}}(jQuery); /** * Timber * Version: 1.1.4 */ $(document).ready(function(){"use strict";var a,b=ea?"touchstart":"click",c=".wrapper",d=".element-reveal-left",e=".element-reveal-right",f=".side-navigation-wrapper",g=".side-nav-show, a.side-nav-show",h=".side-nav-hide a",i=".no-scroll",j=".element-show-left",k=".element-show-right",l="easeInOutQuint",m={init:function(){if(!$(f).length)return!1;$("body").data("aux-nav",!1);var a=$(f).data("animation")?$(f).data("animation"):"no-transition",n=$(f).is("[data-no-scrollbar]")?"no-scrollbar":"scrollbar";"no-transition"===a&&$(c).addClass(a+"-reset"),$(c).addClass("reveal-side-navigation"),$(f).addClass(a+"-reset "+n);var o=$(f).hasClass("enter-right")?"right":"left";_?p="left"===o?d:e:(p="left"===o?j:k,$(f).addClass("hide"));var p=p.split(".").join("");i=i.split(".").join(""),$(g).on(b,function(d){if(d.preventDefault(),$(f).hasClass("active"))m.closeNav(p,a);else{A.state(!0),y.state(!0),$("body").data("aux-nav",!0),$("html, body").addClass(i);var e=$(window).scrollTop();ea||$(".header-inner").css({top:e+"px"}),_?($(c).addClass(p+" inactive "+a).css({transitionTimingFunction:da[l]}),$(f).addClass("active "+a).css({transitionTimingFunction:da[l]})):($(c).addClass(p),$(f).removeClass("hide").addClass("active")),$(c).on(ca,function(c){return c.target===$(this)[0]&&(c.stopPropagation(),$(this).off(ca),void $(".reveal-side-navigation").on(b,function(c){$(".reveal-side-navigation").off(b),m.closeNav(p,a)}))})}}),$(h).on(b,function(c){c.preventDefault(),$(".reveal-side-navigation").off(b),m.closeNav(p,a)}),$(window).on("resize",function(){$("body").data("aux-nav")?y.state(!0):y.state(!1)})},closeNav:function(a,b){_?(A.state(!0),$(c).removeClass(a+" "+b),$(f).removeClass(b),"no-transition"===b&&($("html, body").removeClass(i),$(c).removeClass("inactive"),$(f).removeClass("active")),$(c).on(ca,function(a){return a.target===$(this)[0]&&(a.stopPropagation(),y.state(!1),$(this).off(ca),$("html, body").removeClass(i),$(c).removeClass("inactive"),$(f).removeClass("active"),void(ea||$(".header-inner").css({top:0})))})):($(c).removeClass(a+" "+b),$(f).addClass("hide").removeClass("active")),$("body").data("aux-nav",!1)}},n=".overlay-navigation-wrapper",o=".overlay-navigation-inner",p=".overlay-nav-show a, a.overlay-nav-show",q=".overlay-nav-hide a, .one-page-nav .overlay-navigation .scroll-link",r=".no-scroll",s="easeInOutQuint",t={init:function(){if(!$(n).length)return!1;var a=$(n).data("animation")?$(n).data("animation"):"no-transition",c=$(n).is("[data-no-scrollbar]")?"no-scrollbar":"scrollbar";$(n).addClass(a+"-reset "+c),r=r.split(".").join(""),$(p).on(b,function(b){b.preventDefault(),$(n).hasClass("active")?t.closeNav(a):($("body").data("aux-nav",!0),$("html, body").addClass(r),_?$(n).addClass("active "+a).css({transitionTimingFunction:da[s]}):$(n).addClass("active"),$(n).on(ca,function(a){return a.target===$(this)[0]&&(a.stopPropagation(),y.state(!0),void $(this).off(ca))}))}),$(o).on(b,function(b){b.target===this&&t.closeNav(a)}),$(q).on(b,function(b){b.preventDefault(),t.closeNav(a)}),$(window).on("resize",function(){$("body").data("aux-nav")?y.state(!0):y.state(!1)})},closeNav:function(a){_?($(n).removeClass(a),"no-transition"===a&&($("html, body").removeClass(r),$(n).removeClass("active")),$(n).on(ca,function(a){return a.target===$(this)[0]&&(a.stopPropagation(),y.state(!1),$(this).off(ca),$("html, body").removeClass(r),void $(n).removeClass("active"))})):$(n).removeClass("active").css({top:"-100%"}),$("body").data("aux-nav",!1)}},u=".side-navigation-wrapper, .overlay-navigation-wrapper",v=".sub-menu",w=".contains-sub-menu",x={init:function(){$(u).find(w).each(function(){var a,c;$(this).parent().hasClass("current")&&(a=$(this).siblings(v).children(),c=0,a.each(function(){c+=$(this).outerHeight()}),$(this).siblings(v).addClass("open").css({height:c+"px"})),$(this).on(b,function(b){b.preventDefault(),$(this).parent().hasClass("current")?$(u).find("nav").children("ul").children().removeClass("current"):($(u).find("nav").children("ul").children().removeClass("current"),$(this).parent().addClass("current")),A.state(!0),a=$(this).sibl /** * Avalanche Slider * Version: 1.2.0 */ !function(a,b,c,d){"use strict";function e(b){b.find(".tms-caption").each(function(){function b(){a.each(d,function(a,b){b=b.split(":");var d=b[0],e=b[1];"opacity"===d&&c.data("o",e),"scale"===d&&c.data("s",e),"easing"===d&&c.data("e",e),"transX"===d&&c.data("tx",parseFloat(e)),"transY"===d&&c.data("ty",parseFloat(e)),"transZ"===d&&c.data("tz",parseFloat(e)),"rotateX"===d&&c.data("rx",parseFloat(e)),"rotateY"===d&&c.data("ry",parseFloat(e)),"rotateZ"===d&&c.data("rz",parseFloat(e)),"transOrigX"===d&&c.data("ox",e),"transOrigY"===d&&c.data("oy",e),"duration"===d&&c.data("du",parseFloat(e)),"delay"===d&&c.data("de",parseFloat(e))})}var c=a(this),d=String(c.data("animate-in")).split(";");c.is("[data-no-scale]")?c.addClass("no-scale"):c.addClass("scale"),c.parent().addClass("tms-perspective"),a.inArray("preset",String(d).split(":"))!=-1?d.filter(function(c){if("preset"===c.split(":")[0]){d.splice(a.inArray(c,d),1);var e=String(K[c.split(":")[1]]).split(";");d=a.merge(e,d).filter(Boolean),b()}}):b(),c.data("w",parseFloat(c.css("width"))),c.data("h",parseFloat(c.css("height"))),c.data("fs",parseFloat(c.css("font-size"))),c.data("lh",parseFloat(c.css("line-height"))),c.data("pt",parseFloat(c.css("padding-top"))),c.data("pr",parseFloat(c.css("padding-right"))),c.data("pb",parseFloat(c.css("padding-bottom"))),c.data("pl",parseFloat(c.css("padding-left"))),c.data("mt",parseFloat(c.css("margin-top"))),c.data("mr",parseFloat(c.css("margin-right"))),c.data("mb",parseFloat(c.css("margin-bottom"))),c.data("ml",parseFloat(c.css("margin-left"))),c.data("bt",parseFloat(c.css("border-top-width"))),c.data("br",parseFloat(c.css("border-right-width"))),c.data("bb",parseFloat(c.css("border-bottom-width"))),c.data("bl",parseFloat(c.css("border-left-width")))})}function f(b,d,e){var f=b.find(".tms-slide"),h=0;f.each(function(){var f=a(this),i=f.find("img").length,j=f.find("iframe, video").length;f.children(".tms-caption").length;u(f,d);var k=a('<div class="tm-loader"><div id="circle" /></div>');if(i>0&&(d.lazyLoad?k.appendTo(f):a(b).find(".tm-loader").length||k.appendTo(b)),j){L&&f.is("[data-video-bkg]")&&f.children("video").css({display:"none"});var l=f.find("iframe, video");z(b,l,d),s(f,d),r(b,d)}i?f.find("img").each(function(b,j){if(!a(this).attr("srcset")){j=a(this).data("src");var k=j,l=j.substr(j.lastIndexOf("."));(c.isRetinaDevice()&&d.retinaSupport||c.isRetinaDevice()&&a(this).is("[data-retina]"))&&(!L&&!d.retinaSupportMobile||L&&d.retinaSupportMobile)&&(j.match(/\.(svg)/i)||(j=a(this).data("retina")?a(this).data("retina"):a(this).data("src").replace(l,d.retinaSuffix+l)))}if(f.data("overlay-bkg-color")&&!f.find(".tms-overlay").length)var m=f.data("overlay-bkg-color").replace("#",""),n=f.data("overlay-bkg-opacity")?f.data("overlay-bkg-opacity"):.5,o=parseInt(m.substring(0,2),16),p=parseInt(m.substring(2,4),16),q=parseInt(m.substring(4,6),16),r="rgba( "+o+","+p+","+q+","+n/1+" )",s=a('<div class="tms-overlay" />').css({backgroundColor:r,opacity:0}).appendTo(f);a(this).css({opacity:0}).attr("src",j).one("error",function(){a(this).attr("src",k),console.log("Error src:"+j)}).one("load",function(){f.css({transition:"none",opacity:0}),f.find(s).css({opacity:1}),a(this).data("loaded",!0).css({opacity:1}),b++,b===i&&(h++,g(f,h,d,e))})}):(h++,r(b,d),g(f,h,d,e))})}function g(b,c,d,e){var f=b.closest(".tm-slider-container"),g=f.find(".tms-slides"),i=f.find("li.active"),j=null,k=null,l=!(!b.is("[data-video-bkg-youtube]")&&!b.is("[data-video-bkg-vimeo]"));if(b.find(".no-transition").css({visibility:"visible"}),f.data("setup",!0),f.data("first-load",!1),f.data("animate-first-slide",!0),b.is("[data-as-bkg-image]")||b.is("[data-video-bkg]")||l){var n=b.children("img").attr("src"),p=b.data("image-wrapper")?b.data("image-wrapper"):b;b.data("image-wrapper")?b.find("."+p).css({"background-image":"url("+n+")"}):b.css({"background-image":"url("+n+")"}),b.children("img").hide()}if(0===f.height()&&!f.data("height")&&b.hasClass("active")){i.children("img").css({maxHeight:"none"});var q=i.children("img").height();f.data("refH",q),f.css({height:q+"px"}),i.children helicopterOut:"opacity:0;scale: 1.4;rotateZ: -360deg;easing:easeFastSlow;",signSwingTop:"opacity:0;rotateX:-60deg;transOrigX:top;transOrigY:center;easing:easeSwingInOut;",signSwingRight:"opacity:0;rotateY:-60deg;transOrigX:right;transOrigY:center;easing:easeSwingInOut;",signSwingBottom:"opacity:0;rotateX:-60deg;transOrigX:bottom;transOrigY:center;easing:easeSwingInOut;",signSwingLeft:"opacity:0;rotateY:-60deg;transOrigX:left;transOrigY:center;easing:easeSwingInOut;",wiggleX:"opacity:0;rotateX:-90deg;transOrigX:center;transOrigY:center;easing:easeSwingInOut;",wiggleY:"opacity:0;rotateY:-90deg;transOrigX:center;transOrigY:center;easing:easeSwingInOut;",dropUp:"opacity:0;transY: 250px;rotateZ:60deg;transOrigX:left;transOrigY:top;easing:easeBounceBackHard;",dropDown:"opacity:0;transY: -250px;rotateZ:-60deg;transOrigX:left;transOrigY:top;easing:easeBounceBackHard;",rollInLeft:"opacity:0;transX: -250px;transY: 200px;rotateZ: -120px;transOrigX:left;transOrigY:top;easing:easeFastSlow;",rollInRight:"opacity:0;transX: 250px;transY: 200px;rotateZ: 120px;transOrigX:right;transOrigY:top;easing:easeFastSlow;",turnInRight:"opacity:0;transX: 250px;rotateX:20deg;rotateY:75deg;transOrigX:left;transOrigY:top;easing:easeBounceBack;",turnInLeft:"opacity:0;transX: -250px;rotateX:20deg;rotateY:-75deg;transOrigX:right;transOrigY:top;easing:easeBounceBack;"},L=!1;(navigator.userAgent.match(/Android/i)||navigator.userAgent.match(/webOS/i)||navigator.userAgent.match(/iPhone/i)||navigator.userAgent.match(/iPad/i)||navigator.userAgent.match(/iPod/i)||navigator.userAgent.match(/BlackBerry/i)||navigator.userAgent.match(/Windows Phone/i))&&(L=!0),function(){for(var a=0,b=["ms","moz","webkit","o"],d=0;d<b.length&&!c.requestAnimationFrame;++d)c.requestAnimationFrame=c[b[d]+"RequestAnimationFrame"],c.cancelAnimationFrame=c[b[d]+"CancelAnimationFrame"]||c[b[d]+"CancelRequestAnimationFrame"];c.requestAnimationFrame||(c.requestAnimationFrame=function(b,d){var e=(new Date).getTime(),f=Math.max(0,16-(e-a)),g=c.setTimeout(function(){b(e+f)},f);return a=e+f,g}),c.cancelAnimationFrame||(c.cancelAnimationFrame=function(a){clearTimeout(a)})}(),a.fn.avalancheSlider=function(b){return this.each(function(){var c=a(this);if(!c.data("avalancheSlider")){var d=new i(this,b);c.data("avalancheSlider",d)}})},a.fn.avalancheSlider.tmsOpts={animation:"slide",scaleFactor:.2,parallax:!1,easing:"easeInOutQuint",easingFallback:"easeInOutQuint",speed:700,parallaxSpeed:.2,parallaxScale:!1,parallaxFadeOut:!1,navArrows:!0,navPagination:!0,navShowOnHover:!0,paginationType:"bullets",navKeyboard:!0,forceFit:!1,fullwidth:!1,fullscreen:!1,fsUseHeightOf:"",externalPadding:0,scaleUnder:1140,scaleMinHeight:214,captionScaling:!0,carousel:!1,carouselVisible:1,carouselScaleHeight:!1,autoAdvance:!0,showProgressBar:!0,interval:6e3,pauseOnHover:!0,useVideoAPI:!0,autoPlay:!0,replayOnEnd:!0,respectRatio:!0,muteBkgVideo:!1,lazyLoad:!0,retinaSupport:!0,retinaSupportMobile:!1,retinaSuffix:"@2x",onSetup:null,onLoadEnd:null,onSlideBefore:null,onSlideAfter:null,onSlideshowStart:null,onSlideshowPause:null,onSlideshowEnd:null}}(jQuery,document,window); /** * Summit Lightbox * Version: 1.0.5 */ !function(t,a,i,e){"use strict";var n=function(a,e){var n=t.extend({},t.fn.summitLightbox.tmlOpts,e),d=t(a),c=this,p=[];d.on("click",function(a){a.preventDefault(),t(d).data("group")&&(p=o(d)),t(this).addClass("tml-active"),n.lightboxAnimation=t(this).data("lightbox-animation")?t(this).data("lightbox-animation"):n.lightboxAnimation,n.contentAnimation=t(this).data("content-animation")?t(this).data("content-animation"):n.contentAnimation,n.contentMargin=t(this).data("content-margin")?t(this).data("content-margin"):n.contentMargin,n.navExit=t(this).is('[data-nav-exit="false"]')?!1:n.navExit,n.videoRatio=t(this).data("video-ratio")?t(this).data("video-ratio"):n.videoRatio,n.auxClasses=t(this).data("aux-classes")?t(this).data("aux-classes"):n.auxClasses,s(p,n,d,c)}),t(i).on("resize",function(){m(n)}),c.nextContent=function(){var a=t("#tml-content");if(a.data("loading"))return!1;h(0,n);var i=t(".tml-active"),e=o(i),r=e[t.inArray(i.attr("id"),e)+1];r=t.inArray(r,e)+1===0?e[0]:r,i.removeClass("tml-active"),r=t("#"+r).addClass("tml-active"),l(r,"next",n),e.length=0},c.prevContent=function(){var a=t("#tml-content");if(a.data("loading"))return!1;h(0,n);var i=t(".tml-active"),e=o(i),r=e[t.inArray(i.attr("id"),e)-1];r=t.inArray(r,e)+1===0?e[e.length-1]:r,i.removeClass("tml-active"),r=t("#"+r).addClass("tml-active"),l(r,"prev",n),e.length=0},c.destroyLightbox=function(){var a=t("#tm-lightbox"),i=t("#tml-content"),e=null;t("body").removeClass("modal-open");var o=r(a,n);if(b){if(a.data("transitioning"))return!1;a.children().css({transition:"none"}),i.css({transition:"none"}),a.one(w,function(){clearTimeout(e),e=setTimeout(function(){a.find("iframe").attr("src",""),a.remove(),a=null},50)}),u(a,0,o.x,o.y,n)}else{if(a.is(":animated"))return!1;i.remove(),a.animate({opacity:0,left:o.x+"px",top:o.y+"px"},n.speed,n.easing,function(){a.find("iframe").attr("src",""),a.remove(),a=null})}p.length=0,t(".tml-active").removeClass("tml-active"),n.onExit&&n.onExit()}},o=function(a){if(t(a).is("[data-group]")){var i=t(a).data("group"),e=[];return t('[data-group="'+i+'"]').each(function(a){a++,t(this).attr("id")?e.push(t(this).attr("id")):(t(this).attr("id",i+"-tml-thumb-"+a),e.push(t(this).attr("id")))}),e}},r=function(a,e){var n=e.lightboxAnimation,o="slideInLeft"===n||"slideInTop"===n?-1:"slideInRight"===n||"slideInBottom"===n?1:0,r="slideInLeft"===n||"slideInRight"===n?t(i).width()*o:0,s="slideInTop"===n||"slideInBottom"===n?t(i).height()*o:0;return{x:r,y:s}},s=function(e,n,o,s){if(t("#tm-lightbox").length)return!1;t("body").append('<div id="tm-lightbox" class="tm-lightbox"><div id="tml-content-wrapper" ><div id="tml-content" /></div><div id="tml-caption" /></div>');var l=t("#tm-lightbox"),c=t("#tml-content-wrapper"),h=t("#tml-content"),p=null;l.addClass(n.auxClasses.replace(/,/g," ")),o.is("[data-modal-mode]")&&(l.addClass("tml-modal-mode"),h.addClass("modal-dialog"),t("body").addClass("modal-open"),o.data("modal-width")&&l.data("modal-width",o.data("modal-width")),o.data("modal-height")&&l.data("modal-height",o.data("modal-height"))),l.data("initLoad",!0);var v=n.contentMargin;if(c.css({top:v+"%",right:v+"%",bottom:v+"%",left:v+"%"}),e.length<2||h.swipeIt({preventTouchOn:".scrollable-content",onSwipeMove:function(t){h.css({left:t+"px"})},onSwipeEnd:function(t){"left"===t?s.prevContent():s.nextContent()}}),n.overlay||l.css({background:"none"}),n.navArrows&&e.length>=2){var f=t('<a href="#" />').attr("id","tml-prev").addClass("tml-nav").appendTo(l),g=t('<a href="#" />').attr("id","tml-next").addClass("tml-nav").appendTo(l);f.on("click",function(t){t.preventDefault(),s.prevContent()}),g.on("click",function(t){t.preventDefault(),s.nextContent()})}if(n.navExit){var x;x=t('<a href="" id="tml-exit" class="tml-nav" />').appendTo(l.hasClass("tml-modal-mode")?h:l),x.on("click",function(t){t.preventDefault(),s.destroyLightbox()})}if(n.navToolbar){var y,C,z,k=600,T=400,A=t(i).height()/2-T/2,I=t(i).width()/2-k/2,S=t(location).attr("href"),O=t('<div id="tml-tool-bar" />').appendTo(l),L=(o.data("toolbar")+"").split(";");if(n.navZoom=o.is("[data-toolbar]")?t.inAr /** * Snowbridge Parallax * Version: 1.0.2 */ !function(a,t,e,i){"use strict";function n(t,i){var n=a('<div class="tm-parallax" />').prependTo(a(t));v&&n.css({height:""}).addClass("tmp-mobile");var r=a('<div class="tm-loader"><div id="circle" /></div>');r.appendTo(n);var o=t.data("src"),l=o.substr(o.lastIndexOf("."));(e.isRetinaDevice()&&i.retinaSupport||e.isRetinaDevice()&&t.is("[data-retina]"))&&(!v&&!i.retinaSupportMobile||v&&i.retinaSupportMobile)&&(o.match(/\.(svg)/i)||(o=t.data("retina")?t.data("retina"):t.data("src").replace(l,i.retinaSuffix+l))),a('<img class="tmp-media"/>').attr("src",o).one("load",function(){a(this).attr("src",o).appendTo(n),n.find(".tm-loader").remove(),s(t,i)}).on("error",function(){console.log("Error src:"+o)})}function s(t,i){var n=t.find(".tmp-media");n.data("refW",n.width()).data("refH",n.height()),n.css({opacity:0}),l(t,i),d(t,i),f&&c(t)?n.css({visibility:"visible",transitionProperty:"opacity",transitionDuration:"1000ms",opacity:1}):n.css({visibility:"visible"}).animate({opacity:1}),a(e).on("resize",function(){l(t,i),o(t,i)}),a(e).on("scroll",function(){o(t,i)}),i.onLoaded&&i.onLoaded()}var r=function(t,e){var i=a.extend({},a.fn.snowBridge.tmpOpts,e),s=a(t),r=i.scaleContainer?i.scaleUnder:s.width();s.data("animating",!1).data("setup",!1).data("refW",r).data("refH",s.height()),i.fadeInOut=s.is('[data-fade-in-out="false"]')?!1:i.fadeInOut,i.scaleContainer=s.is('[data-scale="false"]')?!1:i.scaleContainer,i.scaleUnder=s.data("scale-under")?s.data("scale-under"):i.scaleUnder,i.scaleMinHeight=s.data("scale-min-height")?s.data("scale-min-height"):i.scaleMinHeight,l(s,i),i.fullscreen&&(i.scaleContainer=!0),i.parallaxFactor>1&&(i.parallaxFactor=1),s.data("setup",!0),n(s,i)},o=function(a,t){a.data("animating")||(e.requestAnimationFrame(function(){d(a,t)}),a.data("animating",!0))},l=function(t,i){var n=a(e).width(),s=a(e).height(),r=t.data("refW"),o=t.data("refH"),l=i.fullscreen?n/s:r/o,d=i.fullscreen?s:n/l>o?o:n/l;if((i.fullscreen||i.scaleContainer)&&(t.css({width:n+"px",height:Math.round(d)>i.scaleMinHeight?Math.round(d)+"px":i.scaleMinHeight+"px"}),d=Math.round(d)>i.scaleMinHeight?d:i.scaleMinHeight),!t.data("setup"))return!1;var c=t.find(".tmp-media"),u=c.data("refW"),h=c.data("refH"),p=u/h,f=i.fullscreen?s+s*i.parallaxFactor:i.scaleContainer?d+d*i.parallaxFactor:o+o*i.parallaxFactor,m=f*p,g=s+d,b=v?-((f-d)/2):0;c.css(i.fullscreen||i.scaleContainer?m>n?{width:Math.round(m)+"px",height:Math.round(f)+"px",left:-Math.round((m-n)/2)+"px",top:b+"px"}:{width:n+"px",height:Math.round(n/p)+"px",left:0,top:b+"px"}:m>n?{width:Math.round(f*p)+"px",height:Math.round(f)+"px",left:-Math.round((f*p-n)/2)+"px",top:b+"px"}:{width:n+"px",height:Math.round(n/p)+"px",left:0,top:b+"px"}),t.data("scrollDistContainer",g)},d=function(t,i){var n=t.find(".tmp-media");if(c(t)){if(v)return!1;var s=t.height()+t.offset().top-a(e).scrollTop(),r=t.offset().top-a(e).scrollTop(),o=0-n.height()/2,l=o*(s/t.data("scrollDistContainer"))*i.parallaxFactor;if(n.css(f?{transform:"translate3d( 0px, "+l+"px, 0px)",visibility:"visible"}:{top:l+"px",visibility:"visible"}),i.fadeInOut){var d,u=a(e).height(),h=i.fadeThreshold>1?.5*t.height():t.height()*i.fadeThreshold;r>h||(d=Math.abs(s/h)>1?1:Math.abs(s/h)),r>u||u-h>r||(d=(u-r)/h>1?1:(u-r)/h),n.parent().css({opacity:(Math.ceil(100*d)/100).toFixed(2)})}}else v||n.css({visibility:"hidden"});t.data("animating",!1)},c=function(t){var i=a(e).scrollTop(),n=i+a(e).height(),s=t.offset().top,r=s+t.outerHeight();return n>=s&&r>=i};e.isRetinaDevice=function(){var a="(-webkit-min-device-pixel-ratio: 1.5), (min--moz-device-pixel-ratio: 1.5), (-o-min-device-pixel-ratio: 3/2), (min-resolution: 1.5dppx)";return this.devicePixelRatio>1||this.matchMedia&&this.matchMedia(a).matches?!0:!1};var u,h=t.body||t.documentElement,p=h.style,f=p.transition!==i||p.WebkitTransition!==i||p.MozTransition!==i||p.MsTransition!==i||p.OTransition!==i,m=["WebkitTransform","MozTransform","OTransform","msTransform"];for(var g in m)p[m[g]]!==i&&(u="-"+m[g].replace("Transform","").toLowerCase());var v=!1;(navigator.userAgent.match(/Android/i)||navigator.userAgent.match(/webOS /** * Horizon * Version: 1.0.4 */ !function(a,e,t,i){"use strict";var n,r=function(e,n){function r(){a.each(g,function(a,t){t=t.split(":");var i=t[0],n=t[1],r=n.indexOf("px")<0?n.indexOf("%")<0?"px":"%":"px";n=isNaN(parseFloat(n))?n:parseFloat(n),c.parallax?("direction"===i&&e.data("pd",n),"speed"===i&&e.data("ps",n),"rotate"===i&&e.data("pr",n),"opacity"===i&&e.data("po",n)):("opacity"===i&&e.data("o",n),"scale"===i&&e.data("s",n),"easing"===i&&e.data("e",n),"transX"===i&&e.data("tx",n+r),"transY"===i&&e.data("ty",n+r),"transZ"===i&&e.data("tz",n+r),"rotateX"===i&&e.data("rx",n+"deg"),"rotateY"===i&&e.data("ry",n+"deg"),"rotateZ"===i&&e.data("rz",n+"deg"),"transOrigX"===i&&e.data("ox",n+"%"),"transOrigY"===i&&e.data("oy",n+"%"),"duration"===i&&e.data("du",n+"ms"),"delay"===i&&e.data("de",n+"ms"))})}var c=a.extend({},a.fn.horizon.tmhOpts,n);e=a(e),w&&e.css({opacity:1,visibility:"visible"}),e.data("scrolling",!1).css("-webkit-backface-visibility","hidden");var g;e.is("[data-parallax]")||c.parallax?(c.parallax=!0,c.threshold=0,e.data("threshold",0),e.parent().addClass("tmh-perspective-parallax"),e.addClass("tmh-parallax-item"),g=(e.data("parallax")+"").split(";"),o(e,c,!0)):(e.parent().addClass("tmh-perspective"),g=(e.data("animate-in")+"").split(";")),-1!=a.inArray("preset",(g+"").split(":"))?g.filter(function(e){if("preset"===e.split(":")[0]){g.splice(a.inArray(e,g),1);var t=(O[e.split(":")[1]]+"").split(";");g=a.merge(t,g).filter(Boolean),i!==g[0]&&r()}}):(g=g.filter(Boolean),"undefined"!==g[0]&&r()),a(t).on("scroll",function(){s(e,c,!1)}),a(t).on("resize",function(){s(e,c,!1)}),c.parallax||d(e,c),s(e,c)},s=function(a,e,t){a.data("scrolling")||(requestAnimationFrame(function(){o(a,e,t)}),a.data("scrolling",!0))},o=function(e,i,n){if(c(e,i)||n)if(i.parallax){if(w)return!1;{var r=e.data("pd")?e.data("pd"):"vertical",s=e.data("ps")?e.data("ps"):i.parallaxSpeed,o=e.data("pr")?e.data("pr"):"none",d=e.data("po")?e.data("po"):"none",u=a(t),p=u.scrollTop(),b=e.offset().top,h=u.height()*s,f=e.parent().height()+e.parent().offset().top-p,y=-((b-p-u.height())*s)-h,O="horizontal"===r?y+"px":0,x="vertical"===r?y+"px":0;-(.1*(b-p-u.height()))-h}o="clockwise"===o?.02*-y+"deg":"anticlockwise"===o?.02*y+"deg":0,d="fade"===d?f/e.parent().height():1,l&&(u.width()<768?g(e,1,0,0,0,0,0,0,1,0,0,"100ms",0,"swing",i):g(e,d.toFixed(2),O,x,0,o,o,o,1,"50%","50%",0,0,"ease-out",i))}else{var I=e.data("ox")?e.data("ox"):"50%",z=e.data("oy")?e.data("oy"):"50%",S=e.data("du")?e.data("du"):i.speed,F=e.data("de")?e.data("de"):0,X=e.data("e")?m[e.data("e")]:m[i.easing];l?g(e,1,0,0,0,0,0,0,1,I,z,S,F,X,i):e.css({visibility:"visible"}).stop().animate({opacity:1},i.speed,i.easingFallback,function(){i.inView&&i.inView()})}e.data("scrolling",!1)},c=function(e,i){var n=a(t).scrollTop(),r=n+a(t).height(),s=e.data("threshold")?parseFloat(e.data("threshold")):i.threshold,o=e.data("ty")?parseFloat(e.data("ty")):0,c=e.offset().top,g=e.offset().top-o,u=g+e.outerHeight()-e.outerHeight()*s,p=g+e.outerHeight()*s;return(c-n>a(t).height()||c-n<-e.outerHeight())&&(i.recurring&&d(e,i),i.outOfView&&i.outOfView()),r>=p&&u>=n},d=function(a){if(w)return!1;var e=a.data("o")?a.data("o"):0,t=a.data("tx")?a.data("tx"):0,i=a.data("ty")?a.data("ty"):0,n=a.data("tz")?a.data("tz"):0,r=a.data("rx")?a.data("rx"):0,s=a.data("ry")?a.data("ry"):0,o=a.data("rz")?a.data("rz"):0,c=a.data("s")?a.data("s"):1;a.css(l?{transition:"none",transform:"translate3d("+t+", "+i+", "+n+" )rotateX("+r+") rotateY("+s+") rotateZ("+o+") scale3d("+c+", "+c+", "+c+")",opacity:e,visibility:"hidden"}:{opacity:0})},g=function(e,t,i,n,r,s,o,c,d,g,u,p,l,b,h){var m={};m.transform="translate3d("+i+", "+n+", "+r+") rotateX("+s+") rotateY("+o+") rotateZ("+c+") scale3d("+d+", "+d+", "+d+")",m.transitionProperty=f+", opacity",m.transformOrigin=g+" "+u+" 0",m.transitionDuration=p,m.transitionDelay=l,m.transitionTimingFunction=b,m.visibility="visible",m.opacity=t,e.css(m).on(y,function(e){e.stopPropagation(),a(this).off(y),h.inView&&h.inView()})},u=e.body||e.documentElement,p=u.style,l=p.transition!==i||p.WebkitTransition!==i||p.MozTransition!==i||p.MsTransit /** * Retina replacement Plugin * Version: 1.0 */ !function(i){"use strict";i.fn.retinizeImages=function(e){var t=i.extend({retinaSupportMobile:!1,retinaSuffix:"@2x"},e),a=function(){var e,a=i(this);if(a.is("img"))e=a.attr("src");else if("none"!==a.css("background-image"))e=a.css("background-image").replace(/^url\(["']?/,"").replace(/["']?\)$/,"");else{if(!a.is("[data-2x]"))return!1;e=a.data("2x")}if(n&&!t.retinaSupportMobile&&!a.is("[data-retina-mobile]")||a.is("[data-no-retina]")||e.match(/\.(svg)/i)||e.indexOf(t.retinaSuffix)>=0)return!1;if(window.isRetinaDevice()){var r=e.substr(e.lastIndexOf("."));e=e.replace(r,t.retinaSuffix+r),i.ajax({type:"GET",url:e,success:function(){i("<img/>").attr("src",e).one("load",function(){a.is("img")?a.attr("src",e):a.css("background-image","url("+e+")")})}})}};window.isRetinaDevice=function(){var i="(-webkit-min-device-pixel-ratio: 1.5), (min--moz-device-pixel-ratio: 1.5), (-o-min-device-pixel-ratio: 3/2), (min-resolution: 1.5dppx)";return this.devicePixelRatio>1||this.matchMedia&&this.matchMedia(i).matches?!0:!1};var n=!1;return(navigator.userAgent.match(/Android/i)||navigator.userAgent.match(/webOS/i)||navigator.userAgent.match(/iPhone/i)||navigator.userAgent.match(/iPad/i)||navigator.userAgent.match(/iPod/i)||navigator.userAgent.match(/BlackBerry/i)||navigator.userAgent.match(/Windows Phone/i))&&(n=!0),this.each(a)}}(jQuery); /** * Equalize * Version: 1.0 */ !function(e){"use strict";var t=function(t,i){var s=e.extend({},e.fn.equalizeHeights.tmeOpts,i),a=e(t),h=this,u=0,n=0,o=0,r=[],c=0,d=a.children(),g=a.data("leader"),l=e('[data-follow="'+g+'"]');h.updateHeights=function(){o=0,s.equalizeByGroup?d.each(function(){n=e(this).position().top,e(this).attr("class",function(e,t){return t.replace(/row-\d+/,"")}).css({height:"auto"}),n!==u&&(o++,c=0,r.length=0),0===o&&(o=1,c=0),r.push(e(this)),c=c>e(this).outerHeight()?c:e(this).outerHeight(),e.each(r,function(e){r[e].addClass("row-"+o).css({height:c+"px"})}),u=n}):(e(this).css({height:"auto"}),c=0,c=a.outerHeight(),l.css({height:c+"px"}))},h.clearHeights=function(){s.equalizeByGroup?d.css({height:"auto"}):l.css({height:"auto"})},e(window).on("resize",function(){return s.updateOnResize?void(e(window).width()>s.clearUnder?h.updateHeights():h.clearHeights()):!1}),h.updateHeights()};e.fn.equalizeHeights=function(i){return this.each(function(){var s=e(this);if(!s.data("equalizeHeights")){var a=new t(this,i);s.data("equalizeHeights",a)}})},e.fn.equalizeHeights.tmeOpts={equalizeByGroup:!0,updateOnResize:!0,clearUnder:479}}(jQuery); /** * Counter * Version: 1.0 */ !function(t){"use strict";var a=function(a,n){function o(t){return(""+t).replace(/(\d)(?=(\d{3})+$)/g,"$1,")}var r,e=t.extend({},t.fn.counter.tmcOpts,n),u=t(a),c=this;c.startCounter=function(){c.clearCounter();var t=u.data("count-from")?parseFloat(u.data("count-from")):e.from,a=u.data("count-to")?parseFloat(u.data("count-to")):e.to,n=u.data("count-interval")?parseFloat(u.data("count-interval")):e.interval,l=t>a?"down":"up";r=setInterval(function(){(t===a||isNaN(t)||isNaN(a))&&(clearInterval(r),e.onComplete&&e.onComplete()),u.text(o(t)),"up"===l?t++:t--},n)},c.clearCounter=function(){clearInterval(r);var t=u.data("count-from")?parseFloat(u.data("count-from")):e.from;u.html(t)},e.autoStart&&c.startCounter()};t.fn.counter=function(n){return this.each(function(){var o=t(this);if(!o.data("counter")){var r=new a(this,n);o.data("counter",r)}})},t.fn.counter.tmcOpts={autoStart:!0,from:500,to:100,interval:20,onComplete:null}}(jQuery); /** * Component editor */ $(document).ready(function(){"use strict";var a={init:function(){function a(a){$(j).children().addClass("hide");var c=$(n).find("#"+p).children().clone(!0);$(j).children().html(c).removeClass("hide"),b(a)}function b(a){a.find(i).parent().addClass("hide"),a.find(h).parent().addClass("hide"),a.find(i).find(".current").removeClass("current"),a.find(m).html("");var b=$(n).find("#"+p).find(".style-element").data("class-support");if(!b)return!1;var d=String(b).split(";");$.each(d,function(b,c){c=c.split(":");var d=c[0],e=c[1];if(d){a.find("#"+d).removeClass("hide");var f=e?a.find(l).find("#"+d).find('[data-class="'+e+'"]').parent():a.find(l).find("#"+d).find("li:first-child");e?r.indexOf(d)>-1&&f.addClass("current"):f.addClass("current"),f.closest(i).find("button span:first-child").text(f.text())}}),c(a)}function c(a){$(n).find("#"+p).clone().html();$(o).html("");var b=a.find(j).children().clone();b.find("*").each(function(){$(this).attr("data-class-support")&&$(this).attr("data-class-support",""),$(this).attr("style")&&$(this).attr("style",""),$(this).removeClass("style-element")}),b=b.html().replace(/<span class="code-break"><\s*[\/]?span>|<br\s*[\/]?>/g,"\n").replace(' data-class-support=""',"").replace(' style=""',"").replace(' class=""',"").replace(/</g,"<").replace(/>/g,">").replace(/\t\t\t\t\t\t\t/g,""),$(o).append('<code><pre><span class="tag">'+b+"</span></pre></code>")}function d(a,b){a.find(i).removeClass("disabled");var c=String(b).split(";");$.each(c,function(a,b){b=b.split(":");var c=b[0];c&&$("#"+c).find(i).addClass("disabled")})}var e=".demo-editor",f=".button-update",g=".dropdown-components",h=".dropdown-elements",i=".dropdown-classes",j=".style-element-wrapper",k=".style-element",l=".class-options",m=".class-field",n=".component-group",o=".html-example",p="typography",q="style-element columns-2 icon-check",r=["size","bkg-color","bkg-hover-color","border-style","corner","border-color","border-hover-color","text-align","font-weight","color","color-hover"];$(e).each(function(){var b=$(this),c=!0;a(b),$(this).find(m).focus(function(){b.addClass("active")}),$(this).find(m).blur(function(){b.removeClass("active")}),$(this).find(f).on("click",function(){s(b.find(m))}),c&&(b.find(o).css({display:"none"}),b.find(".hide-html").text("Show HTML")),$(this).find(".hide-html").on("click",function(a){a.preventDefault(),c?(b.find(o).css({display:"block"}),$(this).text("Hide HTML"),c=!1):(b.find(o).css({display:"none"}),$(this).text("Show HTML"),c=!0)}),$(this).find(g).find("li:first-child").addClass("current"),$(this).find(g).find("button span:first-child").text($(this).find(g).find(".current a").text()),p=$(this).find(g).find(".current").data("component"),$(this).find(g).find("li a").on("click",function(){if($(this).closest(g).find(".current").removeClass("current"),$(this).parent().addClass("current"),p=$(this).data("component"),a(b),$(this).closest(g).find("button span:first-child").text($(this).text()),b.find(i).removeClass("disabled"),!$(this).data("element"))return!1;var c="#"+$(this).data("element");$(c).find("li").removeClass("current"),$(c).find("li:first-child").addClass("current");var e=$(c).find("li:first-child a").data("disable");d(b,e)}),$(this).closest(h).find("button span:first-child").text($(this).find(h).find(".current a").text()),$(this).find(h).each(function(){$(this).find("li a").on("click",function(){b.find(m).html(""),$(this).closest(h).find(".current").removeClass("current"),$(this).parent().addClass("current");var a=$(this).data("class");$(this).closest(b).find(j).find(".style-element").removeClass("style-element"),$(this).closest(b).find(j).find("."+a).addClass("style-element");var c=$(this).closest(b).find("."+a).clone().removeClass(q);c=c.attr("class").replace(a,""),b.find(m).html(c),s(b,!0),$(this).closest(h).find("button span:first-child").text($(this).text()),d(b,$(this).data("disable"))})}),$(this).find(i).each(function(){$(this).find("li a").on("click",function(){if($(this).closest(i).hasClass("disabled"))return!1;var a=b.find(m),c=$(this).closest(i).find(".current a").attr("data-class" /* Site specific third party plugins */ /** * Highlights.js * Version: 9.7.0 * BSD3 License */ !function(e){var n="object"==typeof window&&window||"object"==typeof self&&self;"undefined"!=typeof exports?e(exports):n&&(n.hljs=e({}),"function"==typeof define&&define.amd&&define([],function(){return n.hljs}))}(function(e){function n(e){return e.replace(/[&<>]/gm,function(e){return I[e]})}function t(e){return e.nodeName.toLowerCase()}function r(e,n){var t=e&&e.exec(n);return t&&0===t.index}function a(e){return k.test(e)}function i(e){var n,t,r,i,o=e.className+" ";if(o+=e.parentNode?e.parentNode.className:"",t=B.exec(o))return R(t[1])?t[1]:"no-highlight";for(o=o.split(/\s+/),n=0,r=o.length;r>n;n++)if(i=o[n],a(i)||R(i))return i}function o(e,n){var t,r={};for(t in e)r[t]=e[t];if(n)for(t in n)r[t]=n[t];return r}function u(e){var n=[];return function r(e,a){for(var i=e.firstChild;i;i=i.nextSibling)3===i.nodeType?a+=i.nodeValue.length:1===i.nodeType&&(n.push({event:"start",offset:a,node:i}),a=r(i,a),t(i).match(/br|hr|img|input/)||n.push({event:"stop",offset:a,node:i}));return a}(e,0),n}function c(e,r,a){function i(){return e.length&&r.length?e[0].offset!==r[0].offset?e[0].offset<r[0].offset?e:r:"start"===r[0].event?e:r:e.length?e:r}function o(e){function r(e){return" "+e.nodeName+'="'+n(e.value)+'"'}l+="<"+t(e)+w.map.call(e.attributes,r).join("")+">"}function u(e){l+="</"+t(e)+">"}function c(e){("start"===e.event?o:u)(e.node)}for(var s=0,l="",f=[];e.length||r.length;){var g=i();if(l+=n(a.substr(s,g[0].offset-s)),s=g[0].offset,g===e){f.reverse().forEach(u);do c(g.splice(0,1)[0]),g=i();while(g===e&&g.length&&g[0].offset===s);f.reverse().forEach(o)}else"start"===g[0].event?f.push(g[0].node):f.pop(),c(g.splice(0,1)[0])}return l+n(a.substr(s))}function s(e){function n(e){return e&&e.source||e}function t(t,r){return new RegExp(n(t),"m"+(e.cI?"i":"")+(r?"g":""))}function r(a,i){if(!a.compiled){if(a.compiled=!0,a.k=a.k||a.bK,a.k){var u={},c=function(n,t){e.cI&&(t=t.toLowerCase()),t.split(" ").forEach(function(e){var t=e.split("|");u[t[0]]=[n,t[1]?Number(t[1]):1]})};"string"==typeof a.k?c("keyword",a.k):E(a.k).forEach(function(e){c(e,a.k[e])}),a.k=u}a.lR=t(a.l||/\w+/,!0),i&&(a.bK&&(a.b="\\b("+a.bK.split(" ").join("|")+")\\b"),a.b||(a.b=/\B|\b/),a.bR=t(a.b),a.e||a.eW||(a.e=/\B|\b/),a.e&&(a.eR=t(a.e)),a.tE=n(a.e)||"",a.eW&&i.tE&&(a.tE+=(a.e?"|":"")+i.tE)),a.i&&(a.iR=t(a.i)),null==a.r&&(a.r=1),a.c||(a.c=[]);var s=[];a.c.forEach(function(e){e.v?e.v.forEach(function(n){s.push(o(e,n))}):s.push("self"===e?a:e)}),a.c=s,a.c.forEach(function(e){r(e,a)}),a.starts&&r(a.starts,i);var l=a.c.map(function(e){return e.bK?"\\.?("+e.b+")\\.?":e.b}).concat([a.tE,a.i]).map(n).filter(Boolean);a.t=l.length?t(l.join("|"),!0):{exec:function(){return null}}}}r(e)}function l(e,t,a,i){function o(e,n){var t,a;for(t=0,a=n.c.length;a>t;t++)if(r(n.c[t].bR,e))return n.c[t]}function u(e,n){if(r(e.eR,n)){for(;e.endsParent&&e.parent;)e=e.parent;return e}return e.eW?u(e.parent,n):void 0}function c(e,n){return!a&&r(n.iR,e)}function g(e,n){var t=N.cI?n[0].toLowerCase():n[0];return e.k.hasOwnProperty(t)&&e.k[t]}function h(e,n,t,r){var a=r?"":y.classPrefix,i='<span class="'+a,o=t?"":C;return i+=e+'">',i+n+o}function p(){var e,t,r,a;if(!E.k)return n(B);for(a="",t=0,E.lR.lastIndex=0,r=E.lR.exec(B);r;)a+=n(B.substr(t,r.index-t)),e=g(E,r),e?(M+=e[1],a+=h(e[0],n(r[0]))):a+=n(r[0]),t=E.lR.lastIndex,r=E.lR.exec(B);return a+n(B.substr(t))}function d(){var e="string"==typeof E.sL;if(e&&!x[E.sL])return n(B);var t=e?l(E.sL,B,!0,L[E.sL]):f(B,E.sL.length?E.sL:void 0);return E.r>0&&(M+=t.r),e&&(L[E.sL]=t.top),h(t.language,t.value,!1,!0)}function b(){k+=null!=E.sL?d():p(),B=""}function v(e){k+=e.cN?h(e.cN,"",!0):"",E=Object.create(e,{parent:{value:E}})}function m(e,n){if(B+=e,null==n)return b(),0;var t=o(n,E);if(t)return t.skip?B+=n:(t.eB&&(B+=n),b(),t.rB||t.eB||(B=n)),v(t,n),t.rB?0:n.length;var r=u(E,n);if(r){var a=E;a.skip?B+=n:(a.rE||a.eE||(B+=n),b(),a.eE&&(B=n));do E.cN&&(k+=C),E.skip||(M+=E.r),E=E.parent;while(E!==r.parent);return r.starts&&v(r.starts,""),a.rE?0:n.length}if(c(n,E))throw new Error('Illegal lexeme "'+n+'" for mode "'+(E.cN||"<unnamed>")+'"');return B+=n,n.length||1}v hljs.initHighlightingOnLoad();
/* * Clipboard.js v1.5.12 * https://zenorocha.github.io/clipboard.js
* Licensed MIT © Zeno Rocha */ !function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,e.Clipboard=t()}}(function(){var t,e,n;return function t(e,n,o){function i(a,c){if(!n[a]){if(!e[a]){var s="function"==typeof require&&require;if(!c&&s)return s(a,!0);if(r)return r(a,!0);var l=new Error("Cannot find module '"+a+"'");throw l.code="MODULE_NOT_FOUND",l}var u=n[a]={exports:{}};e[a][0].call(u.exports,function(t){var n=e[a][1][t];return i(n?n:t)},u,u.exports,t,e,n,o)}return n[a].exports}for(var r="function"==typeof require&&require,a=0;a<o.length;a++)i(o[a]);return i}({1:[function(t,e,n){var o=t("matches-selector");e.exports=function(t,e,n){for(var i=n?t:t.parentNode;i&&i!==document;){if(o(i,e))return i;i=i.parentNode}}},{"matches-selector":5}],2:[function(t,e,n){function o(t,e,n,o,r){var a=i.apply(this,arguments);return t.addEventListener(n,a,r),{destroy:function(){t.removeEventListener(n,a,r)}}}function i(t,e,n,o){return function(n){n.delegateTarget=r(n.target,e,!0),n.delegateTarget&&o.call(t,n)}}var r=t("closest");e.exports=o},{closest:1}],3:[function(t,e,n){n.node=function(t){return void 0!==t&&t instanceof HTMLElement&&1===t.nodeType},n.nodeList=function(t){var e=Object.prototype.toString.call(t);return void 0!==t&&("[object NodeList]"===e||"[object HTMLCollection]"===e)&&"length"in t&&(0===t.length||n.node(t[0]))},n.string=function(t){return"string"==typeof t||t instanceof String},n.fn=function(t){var e=Object.prototype.toString.call(t);return"[object Function]"===e}},{}],4:[function(t,e,n){function o(t,e,n){if(!t&&!e&&!n)throw new Error("Missing required arguments");if(!c.string(e))throw new TypeError("Second argument must be a String");if(!c.fn(n))throw new TypeError("Third argument must be a Function");if(c.node(t))return i(t,e,n);if(c.nodeList(t))return r(t,e,n);if(c.string(t))return a(t,e,n);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}function i(t,e,n){return t.addEventListener(e,n),{destroy:function(){t.removeEventListener(e,n)}}}function r(t,e,n){return Array.prototype.forEach.call(t,function(t){t.addEventListener(e,n)}),{destroy:function(){Array.prototype.forEach.call(t,function(t){t.removeEventListener(e,n)})}}}function a(t,e,n){return s(document.body,t,e,n)}var c=t("./is"),s=t("delegate");e.exports=o},{"./is":3,delegate:2}],5:[function(t,e,n){function o(t,e){if(r)return r.call(t,e);for(var n=t.parentNode.querySelectorAll(e),o=0;o<n.length;++o)if(n[o]==t)return!0;return!1}var i=Element.prototype,r=i.matchesSelector||i.webkitMatchesSelector||i.mozMatchesSelector||i.msMatchesSelector||i.oMatchesSelector;e.exports=o},{}],6:[function(t,e,n){function o(t){var e;if("INPUT"===t.nodeName||"TEXTAREA"===t.nodeName)t.focus(),t.setSelectionRange(0,t.value.length),e=t.value;else{t.hasAttribute("contenteditable")&&t.focus();var n=window.getSelection(),o=document.createRange();o.selectNodeContents(t),n.removeAllRanges(),n.addRange(o),e=n.toString()}return e}e.exports=o},{}],7:[function(t,e,n){function o(){}o.prototype={on:function(t,e,n){var o=this.e||(this.e={});return(o[t]||(o[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){function o(){i.off(t,o),e.apply(n,arguments)}var i=this;return o._=e,this.on(t,o,n)},emit:function(t){var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),o=0,i=n.length;for(o;i>o;o++)n[o].fn.apply(n[o].ctx,e);return this},off:function(t,e){var n=this.e||(this.e={}),o=n[t],i=[];if(o&&e)for(var r=0,a=o.length;a>r;r++)o[r].fn!==e&&o[r].fn._!==e&&i.push(o[r]);return i.length?n[t]=i:delete n[t],this}},e.exports=o},{}],8:[function(e,n,o){!function(i,r){if("function"==typeof t&&t.amd)t(["module","select"],r);else if("undefined"!=typeof o)r(n,e("select"));else{var a={exports:{}};r(a,i.select),i.clipboardAction=a.exports}}(this,function(t,e){"use strict";function n(t){return t&&t.__esModule?t:{"default":t}}function o(t,e){if(!(t instanceof e))throw new TypeErr
|