DotaNoobs main site.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

3 lines
24 KiB

/*! UIkit 1.0.1 | http://www.getuikit.com | (c) 2013 YOOtheme | MIT License */
(function(t,i){"use strict";var e=t.UIkit||{};e.fn||(e.fn=function(i,n){var o=arguments,s=i.match(/^([a-z\-]+)(?:\.([a-z]+))?/i),a=s[1],r=s[2];return e[a]?this.each(function(){var i=t(this),s=i.data(a);s||i.data(a,s=new e[a](this,r?void 0:n)),r&&s[r].apply(s,Array.prototype.slice.call(o,1))}):(t.error("UIkit component ["+a+"] does not exist."),this)},e.support={},e.support.transition=function(){var t=function(){var t,e=i.body||i.documentElement,n={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(t in n)if(void 0!==e.style[t])return n[t]}();return t&&{end:t}}(),e.Utils={},e.Utils.debounce=function(t,i,e){var n;return function(){var o=this,s=arguments,a=function(){n=null,e||t.apply(o,s)},r=e&&!n;clearTimeout(n),n=setTimeout(a,i),r&&t.apply(o,s)}},e.Utils.options=function(i){if(t.isPlainObject(i))return i;var e=i.indexOf("{"),n={};if(-1!=e)try{n=Function("","var json = "+i.substr(e)+"; return JSON.parse(JSON.stringify(json));")()}catch(o){}return n},t.UIkit=e,t.fn.uk=e.fn,t.UIkit.langdirection="rtl"==t("html").attr("dir")?"right":"left")})(jQuery,document),function(t){function i(t){return"tagName"in t?t:t.parentNode}function e(t,i,e,n){var o=Math.abs(t-i),s=Math.abs(e-n);return o>=s?t-i>0?"Left":"Right":e-n>0?"Up":"Down"}function n(){u=null,c.last&&(c.el.trigger("longTap"),c={})}function o(){u&&clearTimeout(u),u=null}function s(){a&&clearTimeout(a),r&&clearTimeout(r),l&&clearTimeout(l),u&&clearTimeout(u),a=r=l=u=null,c={}}var a,r,l,u,c={},h=750;t(document).ready(function(){var d,p;t(document.body).bind("touchstart",function(e){d=Date.now(),p=d-(c.last||d),c.el=t(i(e.originalEvent.touches[0].target)),a&&clearTimeout(a),c.x1=e.originalEvent.touches[0].pageX,c.y1=e.originalEvent.touches[0].pageY,p>0&&250>=p&&(c.isDoubleTap=!0),c.last=d,u=setTimeout(n,h)}).bind("touchmove",function(t){o(),c.x2=t.originalEvent.touches[0].pageX,c.y2=t.originalEvent.touches[0].pageY}).bind("touchend",function(){o(),c.x2&&Math.abs(c.x1-c.x2)>30||c.y2&&Math.abs(c.y1-c.y2)>30?l=setTimeout(function(){c.el.trigger("swipe"),c.el.trigger("swipe"+e(c.x1,c.x2,c.y1,c.y2)),c={}},0):"last"in c&&(r=setTimeout(function(){var i=t.Event("tap");i.cancelTouch=s,c.el.trigger(i),c.isDoubleTap?(c.el.trigger("doubleTap"),c={}):a=setTimeout(function(){a=null,c.el.trigger("singleTap"),c={}},250)},0))}).bind("touchcancel",s),t(window).bind("scroll",s)}),["swipe","swipeLeft","swipeRight","swipeUp","swipeDown","doubleTap","tap","singleTap","longTap"].forEach(function(i){t.fn[i]=function(t){return this.bind(i,t)}})}(jQuery),function(t,i){"use strict";var e=function(i,e){var n=this;this.options=t.extend({},this.options,e),this.element=t(i).on("click",this.options.trigger,function(t){t.preventDefault(),n.close()})};t.extend(e.prototype,{options:{fade:!0,duration:200,trigger:".uk-alert-close"},close:function(){function t(){i.trigger("closed").remove()}var i=this.element.trigger("close");this.options.fade?i.css("overflow","hidden").css("max-height",i.height()).animate({height:0,opacity:0,"padding-top":0,"padding-bottom":0,"margin-top":0,"margin-bottom":0},this.options.duration,t):t()}}),i.alert=e,t(document).on("click.alert.uikit","[data-uk-alert]",function(n){n.preventDefault();var o=t(this);o.data("alert")||(o.data("alert",new e(o,i.Utils.options(o.data("uk-alert")))),t(n.target).is(o.data("alert").options.trigger)&&o.data("alert").close())})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=function(i,e){var n=this,o=t(i);this.options=t.extend({},this.options,e),this.element=o.on("click",this.options.target,function(i){i.preventDefault(),o.find(n.options.target).not(this).removeClass("uk-active").blur(),o.trigger("change",[t(this).addClass("uk-active")])})};t.extend(e.prototype,{options:{target:".uk-button"},getSelected:function(){this.element.find(".uk-active")}});var n=function(i,e){var n=t(i);this.options=t.extend({},this.options,e),this.element=n.on("click",this.options.target,function(i){i.preventDefault(),n.trigger("change",[t(this).toggleClass("uk-active").blur()])})};t.extend(n.prototype,{options:{target:".uk-button"},getSelected:function(){this.element.find(".uk-active")}});var o=function(i){var e=this;this.element=t(i).on("click",function(t){t.preventDefault(),e.toggle(),e.element.blur()})};t.extend(o.prototype,{toggle:function(){this.element.toggleClass("uk-active")}}),i.button=o,i["button-checkbox"]=n,i["button-radio"]=e,t(document).on("click.button-radio.uikit","[data-uk-button-radio]",function(n){var o=t(this);o.data("button-radio")||(o.data("button-radio",new e(o,i.Utils.options(o.data("uk-button-radio")))),t(n.target).is(o.data("button-radio").options.target)&&t(n.target).trigger("click"))}),t(document).on("click.button-checkbox.uikit","[data-uk-button-checkbox]",function(e){var o=t(this);o.data("button-checkbox")||(o.data("button-checkbox",new n(o,i.Utils.options(o.data("uk-button-checkbox")))),t(e.target).is(o.data("button-checkbox").options.target)&&t(e.target).trigger("click"))}),t(document).on("click.button.uikit","[data-uk-button]",function(){var i=t(this);i.data("button")||i.data("button",new o(i,i.data("uk-button"))).trigger("click")})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=!1,n=function(i,n){var o=this;this.options=t.extend({},this.options,n),this.element=t(i),this.dropdown=this.element.find(".uk-dropdown"),this.centered=this.dropdown.hasClass("uk-dropdown-center"),this.justified=this.options.justify?t(this.options.justify):!1,"click"==this.options.mode?this.element.on("click",function(i){t(i.target).parents(".uk-dropdown").length||i.preventDefault(),e&&e[0]!=o.element[0]&&e.removeClass("uk-open"),o.element.hasClass("uk-open")?(t(i.target).is("a")||!o.element.find(".uk-dropdown").find(i.target).length)&&(o.element.removeClass("uk-open"),e=!1):(o.checkDimensions(),o.element.addClass("uk-open"),e=o.element,t(document).off("click.outer.dropdown"),setTimeout(function(){t(document).on("click.outer.dropdown",function(i){!e||e[0]!=o.element[0]||!t(i.target).is("a")&&o.element.find(".uk-dropdown").find(i.target).length||(e.removeClass("uk-open"),t(document).off("click.outer.dropdown"))})},10))}):this.element.on("mouseenter",function(){o.remainIdle&&clearTimeout(o.remainIdle),e&&e[0]!=o.element[0]&&e.removeClass("uk-open"),o.checkDimensions(),o.element.addClass("uk-open"),e=o.element}).on("mouseleave",function(){o.remainIdle=setTimeout(function(){o.element.removeClass("uk-open"),o.remainIdle=!1,e&&e[0]==o.element[0]&&(e=!1)},o.options.remaintime)})};t.extend(n.prototype,{remainIdle:!1,options:{mode:"hover",remaintime:800,justify:!1},checkDimensions:function(){var i=this.dropdown.css("margin-"+t.UIkit.langdirection,"").css("min-width",""),e=i.show().offset(),n=i.outerWidth();if(this.centered&&(i.css("margin-"+t.UIkit.langdirection,-1*(parseFloat(n)/2-i.parent().width()/2)),e=i.offset(),(n+e.left>window.innerWidth||0>e.left)&&(i.css("margin-"+t.UIkit.langdirection,""),e=i.offset())),this.justified&&this.justified.length){var o=this.justified.outerWidth();if(i.css("min-width",o),"right"==t.UIkit.langdirection){var s=t(window).width(),a=s-(this.justified.offset().left+o),r=s-(i.offset().left+i.outerWidth());i.css("margin-right",a-r)}else i.css("margin-left",this.justified.offset().left-e.left);e=i.offset()}n+e.left>window.innerWidth&&(i.addClass("uk-dropdown-flip"),e=i.offset()),0>e.left&&i.addClass("uk-dropdown-stack"),i.css("display","")}}),i.dropdown=n,t(document).on("mouseenter.dropdown.uikit","[data-uk-dropdown]",function(){var e=t(this);e.data("dropdown")||(e.data("dropdown",new n(e,i.Utils.options(e.data("uk-dropdown")))),"hover"==e.data("dropdown").options.mode&&e.trigger("mouseenter"))})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=t(window),n="resize orientationchange",o=function(o,s){var a=this;this.options=t.extend({},this.options,s),this.element=t(o),this.columns=this.element.children(),this.elements=this.options.target?this.element.find(this.options.target):this.columns,this.columns.length&&e.bind(n,function(){var n=function(){a.match()};return t(function(){n(),e.on("load",n)}),i.Utils.debounce(n,150)}())};t.extend(o.prototype,{options:{target:!1},match:function(){this.revert();var i=this.columns.filter(":visible:first");if(i.length){var e=Math.ceil(100*parseFloat(i.css("width"))/parseFloat(i.parent().css("width")))>=100?!0:!1,n=0,o=this;if(!e)return this.elements.each(function(){n=Math.max(n,t(this).outerHeight())}).each(function(i){var e=t(this),s="border-box"==e.css("box-sizing")?"outerHeight":"height",a=o.columns.eq(i),r=e.height()+(n-a[s]());e.css("min-height",r+"px")}),this}},revert:function(){return this.elements.css("min-height",""),this}});var s=function(o){var s=this;this.element=t(o),this.columns=this.element.children(),this.columns.length&&e.bind(n,function(){var n=function(){s.process()};return t(function(){n(),e.on("load",n)}),i.Utils.debounce(n,150)}())};t.extend(s.prototype,{process:function(){this.revert();var i=!1,e=this.columns.filter(":visible:first"),n=e.length?e.offset().top:!1;if(n!==!1)return this.columns.each(function(){var e=t(this);e.is(":visible")&&(i?e.addClass("uk-grid-margin"):e.offset().top!=n&&(e.addClass("uk-grid-margin"),i=!0))}),this},revert:function(){return this.columns.removeClass("uk-grid-margin"),this}}),i["grid-match"]=o,i["grid-margin"]=s,t(function(){t("[data-uk-grid-match],[data-uk-grid-margin]").each(function(){var e=t(this);e.is("[data-uk-grid-match]")&&!e.data("grid-match")&&e.data("grid-match",new o(e,i.Utils.options(e.data("uk-grid-match")))),e.is("[data-uk-grid-margin]")&&!e.data("grid-margin")&&e.data("grid-margin",new s(e,i.Utils.options(e.data("uk-grid-margin"))))})})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=!1,n=t("html"),o=function(n,o){var s=this;this.element=t(n),this.options=t.extend({keyboard:!0,show:!1,bgclose:!0},o),this.transition=i.support.transition,this.element.on("click",".uk-modal-close",function(t){t.preventDefault(),s.hide()}).on("click",function(i){var e=t(i.target);e[0]==s.element[0]&&s.options.bgclose&&s.hide()}),this.options.keyboard&&t(document).on("keyup.ui.modal.escape",function(t){e&&27==t.which&&s.isActive()&&s.hide()})};t.extend(o.prototype,{transition:!1,toggle:function(){this[this.isActive()?"hide":"show"]()},show:function(){var t=this;this.isActive()||(e&&e.hide(),this.element.removeClass("uk-open").show(),e=this,n.addClass("uk-modal-page").height(),t.element.addClass("uk-open"))},hide:function(){if(this.isActive())if(i.support.transition){var t=this;this.element.one(i.support.transition.end,function(){t._hide()}).removeClass("uk-open")}else this._hide()},_hide:function(){this.element.hide().removeClass("uk-open"),n.removeClass("uk-modal-page"),e=!1},isActive:function(){return e==this}});var s=function(i,e){var n=this,s=t(i);this.options=t.extend({target:s.is("a")?s.attr("href"):!1},e),this.element=s,this.modal=new o(this.options.target,e),s.on("click",function(t){t.preventDefault(),n.show()}),t.each(["show","hide","isActive"],function(t,i){n[i]=function(){return n.modal[i]()}})};s.Modal=o,i.modal=s,t(document).on("click.modal.uikit","[data-uk-modal]",function(){var e=t(this);e.data("modal")||(e.data("modal",new s(e,i.Utils.options(e.data("uk-modal")))),e.data("modal").show())})}(jQuery,jQuery.UIkit),function(t,i,e){"use strict";("ontouchstart"in window||window.DocumentTouch&&document instanceof e)&&t("html").addClass("uk-touch");var n={show:function(i){if(i=t(i),i.length){var e=t("html"),o=i.find(".uk-offcanvas-bar:first"),s=o.hasClass("uk-offcanvas-bar-flip")?-1:1,a=-1==s&&t(window).width()<window.innerWidth?window.innerWidth-t(window).width():0,r={x:window.scrollX,y:window.scrollY};i.addClass("uk-active"),e.css("width",e.outerWidth()).addClass("uk-offcanvas-page").width(),e.css("margin-"+t.UIkit.langdirection,(o.width()-a)*s),window.scrollTo(r.x,r.y),o.css("left"==t.UIkit.langdirection?-1==s?"right":"left":-1==s?"left":"right",0),i.off(".ukoffcanvas").on("click.ukoffcanvas swipeRight.ukoffcanvas swipeLeft.ukoffcanvas",function(i){var e=t(i.target);if(!i.type.match(/swipe/)){if(e.hasClass("uk-offcanvas-bar"))return;if(e.parents(".uk-offcanvas-bar:first").length)return}i.stopImmediatePropagation(),n.hide()}),t(document).on("keydown.offcanvas",function(t){27===t.keyCode&&n.hide()})}},hide:function(i){var e=t("html"),n=t(".uk-offcanvas.uk-active"),o=n.find(".uk-offcanvas-bar:first");n.length&&(t.UIkit.support.transition&&!i?(e.one(t.UIkit.support.transition.end,function(){e.removeClass("uk-offcanvas-page").css("width","")}).css("margin-"+t.UIkit.langdirection,0),setTimeout(function(){o.one(t.UIkit.support.transition.end,function(){n.removeClass("uk-active")}).css({left:"",right:""})},150)):(e.removeClass("uk-offcanvas-page").css("width","").css("margin-"+t.UIkit.langdirection,""),n.removeClass("uk-active"),o.css({left:"",right:""})),n.off(".ukoffcanvas"),t(document).off(".ukoffcanvas"))}},o=function(i,e){var o=this,s=t(i);this.options=t.extend({target:s.is("a")?s.attr("href"):!1},e),this.element=s,s.on("click",function(t){t.preventDefault(),n.show(o.options.target)})};o.offcanvas=n,i.offcanvas=o,t(document).on("click.offcanvas.uikit","[data-uk-offcanvas]",function(e){e.preventDefault();var n=t(this);n.data("offcanvas")||(n.data("offcanvas",new o(n,i.Utils.options(n.data("uk-offcanvas")))),n.trigger("click"))})}(jQuery,jQuery.UIkit,window.DocumentTouch),function(t,i){"use strict";function e(i){var e=t(i),n="auto";if(e.is(":visible"))n=e.outerHeight();else{var o={position:e.css("position"),visibility:e.css("visibility"),display:e.css("display")};n=e.css({position:"absolute",visibility:"hidden",display:"block"}).outerHeight(),e.css(o)}return n}var n=function(i,e){var n=this;this.options=t.extend({},this.options,e),this.element=t(i).on("click",this.options.toggler,function(i){i.preventDefault();var e=t(this);n.open(e.parent()[0]==n.element[0]?e:e.parent("li"))}),this.element.find(this.options.lists).each(function(){var i=t(this),e=i.parent(),o=e.hasClass("uk-active");i.wrap('<div style="overflow:hidden;height:0;position:relative;"></div>'),e.data("list-container",i.parent()),o&&n.open(e,!0)})};t.extend(n.prototype,{options:{toggler:">li.uk-parent > a[href='#']",lists:">li.uk-parent > ul",multiple:!1},open:function(i,n){var o=this.element,s=t(i);this.options.multiple||o.children(".uk-open").not(i).each(function(){t(this).data("list-container")&&t(this).data("list-container").stop().animate({height:0},function(){t(this).parent().removeClass("uk-open")})}),s.toggleClass("uk-open"),s.data("list-container")&&(n?s.data("list-container").stop().height(s.hasClass("uk-open")?"auto":0):s.data("list-container").stop().animate({height:s.hasClass("uk-open")?e(s.data("list-container").find("ul:first")):0}))}}),i.nav=n,t(function(){t("[data-uk-nav]").each(function(){var e=t(this);e.data("nav")||e.data("nav",new n(e,i.Utils.options(e.data("uk-nav"))))})})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=function(i,e){var n=this;this.element=t(i),this.options=t.extend({},this.options,e),this.element.on("mouseenter",this.options.toggler,function(){n.element.find(n.options.toggler).not(this).removeClass("uk-open")})};t.extend(e.prototype,{options:{toggler:".uk-navbar-nav > li",remaintime:800}}),i.navbar=e,t(function(){t("[data-uk-navbar]").each(function(){var n=t(this);n.data("navbar")||n.data("navbar",new e(n,i.Utils.options(n.data("uk-navbar"))))})})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e,n=function(i,e){var n=this;this.options=t.extend({},this.options,e),this.element=t(i).on({focus:function(){n.show()},blur:function(){n.hide()},mouseenter:function(){n.show()},mouseleave:function(){n.hide()}}),this.tip="function"==typeof this.options.src?this.options.src.call(this.element):this.options.src,this.element.attr("data-cached-title",this.element.attr("title")).attr("title","")};t.extend(n.prototype,{tip:"",options:{offset:5,pos:"top",src:function(){return this.attr("title")}},show:function(){if(this.tip.length){e.css({top:-2e3,visibility:"hidden"}).show(),e.html('<div class="uk-tooltip-inner">'+this.tip+"</div>");var i=t.extend({},this.element.offset(),{width:this.element[0].offsetWidth,height:this.element[0].offsetHeight}),n=e[0].offsetWidth,o=e[0].offsetHeight,s="function"==typeof this.options.offset?this.options.offset.call(this.element):this.options.offset,a="function"==typeof this.options.pos?this.options.pos.call(this.element):this.options.pos,r={display:"none",visibility:"visible",top:i.top+i.height+o,left:i.left},l=a.split("-");switch("left"!=l[0]&&"right"!=l[0]||"right"!=t.UIkit.langdirection||(l[0]="left"==l[0]?"right":"left"),l[0]){case"bottom":t.extend(r,{top:i.top+i.height+s,left:i.left+i.width/2-n/2});break;case"top":t.extend(r,{top:i.top-o-s,left:i.left+i.width/2-n/2});break;case"left":t.extend(r,{top:i.top+i.height/2-o/2,left:i.left-n-s});break;case"right":t.extend(r,{top:i.top+i.height/2-o/2,left:i.left+i.width+s})}2==l.length&&(r.left="left"==l[1]?i.left:i.left+i.width-n),e.css(r).attr("class","uk-tooltip uk-tooltip-"+a).show()}},hide:function(){this.element.is("input")&&this.element[0]===document.activeElement||e.hide()},content:function(){return this.tip}}),i.tooltip=n,t(function(){e=t('<div class="uk-tooltip"></div>').appendTo("body")}),t(document).on("mouseenter.tooltip.uikit focus.tooltip.uikit","[data-uk-tooltip]",function(){var e=t(this);e.data("tooltip")||e.data("tooltip",new n(e,i.Utils.options(e.data("uk-tooltip")))).trigger("mouseenter")})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=function(i,e){var n=this;if(this.options=t.extend({},this.options,e),this.element=t(i).on("click",this.options.toggler,function(t){t.preventDefault(),n.show(this)}),this.options.connect){this.connect=t(this.options.connect).find(".uk-active").removeClass(".uk-active").end();var o=this.element.find(this.options.toggler).filter(".uk-active");o.length&&this.show(o)}};t.extend(e.prototype,{options:{connect:!1,toggler:">*"},show:function(i){i=isNaN(i)?t(i):this.element.find(this.options.toggler).eq(i);var e=i;if(!e.hasClass("uk-disabled")){if(this.element.find(this.options.toggler).filter(".uk-active").removeClass("uk-active"),e.addClass("uk-active"),this.options.connect&&this.connect.length){var n=this.element.find(this.options.toggler).index(e);this.connect.children().removeClass("uk-active").eq(n).addClass("uk-active")}this.element.trigger("ui.switcher.show",[e])}}}),i.switcher=e,t(function(){t("[data-uk-switcher]").each(function(){var n=t(this);n.data("switcher")||n.data("switcher",new e(n,i.Utils.options(n.data("uk-switcher"))))})})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=function(i,e){this.element=t(i),this.options=t.extend({connect:!1},this.options,e),this.options.connect&&(this.connect=t(this.options.connect));var n=t("<li></li>").addClass("uk-tab-responsive uk-active").append('<a href="javascript:void(0);"> <i class="uk-icon-caret-down"></i></a>'),o=n.find("a:first"),s=t('<div class="uk-dropdown uk-dropdown-small"><ul class="uk-nav uk-nav-dropdown"></ul><div>'),a=s.find("ul");o.text(this.element.find("li.uk-active:first").find("a").text()),this.element.hasClass("uk-tab-bottom")&&s.addClass("uk-dropdown-up"),this.element.hasClass("uk-tab-flip")&&s.addClass("uk-dropdown-flip"),this.element.find("a").each(function(){var i=t(this),e=t('<li><a href="#">'+i.text()+"</a></li>").on("click",function(t){t.preventDefault(),i.parent().trigger("click"),n.removeClass("uk-open")});i.parents(".uk-disabled:first").length||a.append(e)}),this.element.uk("switcher",{toggler:">li:not(.uk-tab-responsive)",connect:this.options.connect}),n.append(s).uk("dropdown"),this.element.append(n).data({dropdown:n.data("dropdown"),mobilecaption:o}).on("ui.switcher.show",function(t,i){n.addClass("uk-active"),o.text(i.find("a").text())})};i.tab=e,t(function(){t("[data-uk-tab]").each(function(){var n=t(this);n.data("tab")||n.data("tab",new e(n,i.Utils.options(n.data("uk-tab"))))})})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=function(i,e){var n=this;this.options=t.extend({},this.options,e),this.element=t(i),this.timer=null,this.value=null,this.input=this.element.find(".uk-search-field"),this.form=this.input.length?t(this.input.get(0).form):t(),this.input.attr("autocomplete","off"),this.input.on({keydown:function(t){if(n.form[n.input.val()?"addClass":"removeClass"](n.options.filledClass),t&&t.which&&!t.shiftKey)switch(t.which){case 13:n.done(n.selected),t.preventDefault();break;case 38:n.pick("prev"),t.preventDefault();break;case 40:n.pick("next"),t.preventDefault();break;case 27:case 9:n.hide();break;default:}},keyup:function(){n.trigger()},blur:function(t){setTimeout(function(){n.hide(t)},200)}}),this.form.find("button[type=reset]").bind("click",function(){n.form.removeClass("uk-open").removeClass("uk-loading").removeClass("uk-active"),n.value=null,n.input.focus()}),this.dropdown=t('<div class="uk-dropdown uk-dropdown-search"><ul class="uk-nav uk-nav-search"></ul></div>').appendTo(this.form).find(".uk-nav-search")};t.extend(e.prototype,{options:{source:!1,param:"search",method:"post",minLength:3,delay:300,match:":not(.uk-skip)",skipClass:"uk-skip",loadingClass:"uk-loading",filledClass:"uk-active",resultsHeaderClass:"uk-nav-header",moreResultsClass:"",noResultsClass:"",listClass:"results",hoverClass:"uk-active",msgResultsHeader:"Search Results",msgMoreResults:"More Results",msgNoResults:"No results found",onSelect:function(t){window.location=t.data("choice").url},onLoadedResults:function(t){return t}},request:function(i){var e=this;this.form.addClass(this.options.loadingClass),this.options.source?t.ajax(t.extend({url:this.options.source,type:this.options.method,dataType:"json",success:function(t){t=e.options.onLoadedResults.apply(this,[t]),e.form.removeClass(e.options.loadingClass),e.suggest(t)}},i)):this.form.removeClass(e.options.loadingClass)},pick:function(t){var i=!1;if("string"==typeof t||t.hasClass(this.options.skipClass)||(i=t),"next"==t||"prev"==t){var e=this.dropdown.children().filter(this.options.match);if(this.selected){var n=e.index(this.selected);i="next"==t?e.eq(e.length>n+1?n+1:0):e.eq(0>n-1?e.length-1:n-1)}else i=e["next"==t?"first":"last"]()}i&&i.length&&(this.selected=i,this.dropdown.children().removeClass(this.options.hoverClass),this.selected.addClass(this.options.hoverClass))},done:function(t){return t?(t.hasClass(this.options.moreResultsClass)?this.form.submit():t.data("choice")&&this.options.onSelect.apply(this,[t]),this.hide(),void 0):(this.form.submit(),void 0)},trigger:function(){var t=this,i=this.value,e={};return this.value=this.input.val(),this.value.length<this.options.minLength?this.hide():(this.value!=i&&(this.timer&&window.clearTimeout(this.timer),this.timer=window.setTimeout(function(){e[t.options.param]=t.value,t.request({data:e})},this.options.delay,this)),this)},suggest:function(i){if(i){var e=this,n={mouseover:function(){e.pick(t(this).parent())},click:function(i){i.preventDefault(),e.done(t(this).parent())}};i===!1?this.hide():(this.selected=null,this.dropdown.empty(),this.options.msgResultsHeader&&t("<li>").addClass(this.options.resultsHeaderClass+" "+this.options.skipClass).html(this.options.msgResultsHeader).appendTo(this.dropdown),i.results&&i.results.length>0?(t(i.results).each(function(){var i=t('<li><a href="#">'+this.title+"</a></li>").data("choice",this);this.text&&i.find("a").append("<div>"+this.text+"</div>"),e.dropdown.append(i)}),this.options.msgMoreResults&&(t("<li>").addClass("uk-nav-divider "+e.options.skipClass).appendTo(e.dropdown),t("<li>").addClass(e.options.moreResultsClass).html('<a href="#">'+e.options.msgMoreResults+"</a>").appendTo(e.dropdown).on(n)),e.dropdown.find("li>a").on(n)):this.options.msgNoResults&&t("<li>").addClass(this.options.noResultsClass+" "+this.options.skipClass).html("<a>"+this.options.msgNoResults+"</a>").appendTo(this.dropdown),this.show())}},show:function(){this.visible||(this.visible=!0,this.form.addClass("uk-open"))},hide:function(){this.visible&&(this.visible=!1,this.form.removeClass(this.options.loadingClass).removeClass("uk-open"))}}),i.search=e,t(document).on("focus.search.uikit","[data-uk-search]",function(){var n=t(this);n.data("search")||n.data("search",new e(n,i.Utils.options(n.data("uk-search"))))})}(jQuery,jQuery.UIkit),function(t,i){"use strict";var e=function(i,e){var n=this;this.options=t.extend({duration:1e3,transition:"easeOutExpo"},e),this.element=t(i).on("click",function(){var i=(t(this.hash).length?t(this.hash):t("body")).offset().top,e=t(document).height(),o=t(window).height();return i+o>e&&(i=i-o+50),t("html,body").stop().animate({scrollTop:i},n.options.duration,n.options.transition),!1})};i["smooth-scroll"]=e,t.easing.easeOutExpo||(t.easing.easeOutExpo=function(t,i,e,n,o){return i==o?e+n:n*(-Math.pow(2,-10*i/o)+1)+e}),t(document).on("click.smooth-scroll.uikit","[data-uk-smooth-scroll]",function(){var n=t(this);n.data("smooth-scroll")||n.data("smooth-scroll",new e(n,i.Utils.options(n.data("uk-smooth-scroll")))).trigger("click")})}(jQuery,jQuery.UIkit);