vendor: 7,645 bytes, lines 1-13
1 2/*----------------------------------------------------------*/ 3/* Jquery Waypoints */ 4/*----------------------------------------------------------*/ 5 6// Generated by CoffeeScript 1.4.0 7/* 8jQuery Waypoints - v2.0.2 9Copyright (c) 2011-2013 Caleb Troughton 10Dual licensed under the MIT license and GPL license. 11https://github.com/imakewebthings/jquery-waypoints/blob/master/licenses.txt 12*/ 13(function(){var t=[].indexOf||function(t){for(var e=0,n=this.length;e<n;e++){if(e in this&&this[e]===t)return e}return-1},e=[].slice;(function(t,e){if(typeof define==="function"&&define.amd){return define("waypoints",["jquery"],function(n){return e(n,t)})}else{return e(t.jQuery,t)}})(this,function(n,r){var i,o,l,s,f,u,a,c,h,d,p,y,v,w,g,m;i=n(r);c=t.call(r,"ontouchstart")>=0;s={horizontal:{},vertical:{}};f=1;a={};u="waypoints-context-id";p="resize.waypoints";y="scroll.waypoints";v=1;w="waypoints-waypoint-ids";g="waypoint";m="waypoints";o=function(){function t(t){var e=this;this.$element=t;this.element=t[0];this.didResize=false;this.didScroll=false;this.id="context"+f++;this.oldScroll={x:t.scrollLeft(),y:t.scrollTop()};this.waypoints={horizontal:{},vertical:{}};t.data(u,this.id);a[this.id]=this;t.bind(y,function(){var t;if(!(e.didScroll||c)){e.didScroll=true;t=function(){e.doScroll();return e.didScroll=false};return r.setTimeout(t,n[m].settings.scrollThrottle)}});t.bind(p,function(){var t;if(!e.didResize){e.didResize=true;t=function(){n[m]("refresh");return e.didResize=false};return r.setTimeout(t,n[m].settings.resizeThrottle)}})}t.prototype.doScroll=function(){var t,e=this;t={horizontal:{newScroll:this.$element.scrollLeft(),oldScroll:this.oldScroll.x,forward:"right",backward:"left"},vertical:{newScroll:this.$element.scrollTop(),oldScroll:this.oldScroll.y,forward:"down",backward:"up"}};if(c&&(!t.vertical.oldScroll||!t.vertical.newScroll)){n[m]("refresh")}n.each(t,function(t,r){var i,o,l;l=[];o=r.newScroll>r.oldScroll;i=o?r.forward:r.backward;n.each(e.waypoints[t],function(t,e){var n,i;if(r.oldScroll<(n=e.offset)&&n<=r.newScroll){return l.push(e)}else if(r.newScroll<(i=e.offset)&&i<=r.oldScroll){return l.push(e)}});l.sort(function(t,e){return t.offset-e.offset});if(!o){l.reverse()}return n.each(l,function(t,e){if(e.options.continuous||t===l.length-1){return e.trigger([i])}})});return this.oldScroll={x:t.horizontal.newScroll,y:t.vertical.newScroll}};t.prototype.refresh=function(){var t,e,r,i=this;r=n.isWindow(this.element);e=this.$element.offset();this.doScroll();t={horizontal:{contextOffset:r?0:e.left,contextScroll:r?0:this.oldScroll.x,contextDimension:this.$element.width(),oldScroll:this.oldScroll.x,forward:"right",backward:"left",offsetProp:"left"},vertical:{contextOffset:r?0:e.top,contextScroll:r?0:this.oldScroll.y,contextDimension:r?n[m]("viewportHeight"):this.$element.height(),oldScroll:this.oldScroll.y,forward:"down",backward:"up",offsetProp:"top"}};return n.each(t,function(t,e){return n.each(i.waypoints[t],function(t,r){var i,o,l,s,f;i=r.options.offset;l=r.offset;o=n.isWindow(r.element)?0:r.$element.offset()[e.offsetProp];if(n.isFunction(i)){i=i.apply(r.element)}else if(typeof i==="string"){i=parseFloat(i);if(r.options.offset.indexOf("%")>-1){i=Math.ceil(e.contextDimension*i/100)}}r.offset=o-e.contextOffset+e.contextScroll-i;if(r.options.onlyOnScroll&&l!=null||!r.enabled){return}if(l!==null&&l<(s=e.oldScroll)&&s<=r.offset){return r.trigger([e.backward])}else if(l!==null&&l>(f=e.oldScroll)&&f>=r.offset){return r.trigger([e.forward])}else if(l===null&&e.oldScroll>=r.offset){return r.trigger([e.forward])}})})};t.prototype.checkEmpty=function(){if(n.isEmptyObject(this.waypoints.horizontal)&&n.isEmptyObject(this.waypoints.vertical)){this.$element.unbind([p,y].join(" "));return delete a[this.id]}};return t}();l=function(){function t(t,e,r){var i,o;r=n.extend({},n.fn[g].defaults,r);if(r.offset==="bottom-in-view"){r.offset=function(){var t;t=n[m]("viewportHeight");if(!n.isWindow(e.element)){t=e.$element.height()}return t-n(this).outerHeight()}}this.$element=t;this.element=t[0];this.axis=r.horizontal?"horizontal":"vertical";this.callback=r.handler;this.context=e;this.enabled=r.enabled;this.id="waypoints"+v++;this.offset=null;this.options=r;e.waypoints[this.axis][this.id]=this;s[this.axis][this.id]=this;i=(o=t.data(w))!=null?o:[];i.push(this.id);t.data(w,i)}t.prototype.trigger=function(t){if(!this.enabled){return}if(this.callback!=null){this.callback.apply(this.element,t)}if(this.options.triggerOnce){return this.destroy()}};t.prototype.disable=function(){return this.enabled=false};t.prototype.enable=function(){this.context.refresh();return this.enabled=true};t.prototype.destroy=function(){delete s[this.axis][this.id];delete this.context.waypoints[this.axis][this.id];return this.context.checkEmpty()};t.getWaypointsByElement=function(t){var e,r;r=n(t).data(w);if(!r){return[]}e=n.extend({},s.horizontal,s.vertical);return n.map(r,function(t){return e[t]})};return t}();d={init:function(t,e){var r;if(e==null){e={}}if((r=e.handler)==null){e.handler=t}this.each(function(){var t,r,i,s;t=n(this);i=(s=e.context)!=null?s:n.fn[g].defaults.context;if(!n.isWindow(i)){i=t.closest(i)}i=n(i);r=a[i.data(u)];if(!r){r=new o(i)}return new l(t,r,e)});n[m]("refresh");return this},disable:function(){return d._invoke(this,"disable")},enable:function(){return d._invoke(this,"enable")},destroy:function(){return d._invoke(this,"destroy")},prev:function(t,e){return d._traverse.call(this,t,e,function(t,e,n){if(e>0){return t.push(n[e-1])}})},next:function(t,e){return d._traverse.call(this,t,e,function(t,e,n){if(e<n.length-1){return t.push(n[e+1])}})},_traverse:function(t,e,i){var o,l;if(t==null){t="vertical"}if(e==null){e=r}l=h.aggregate(e);o=[];this.each(function(){var e;e=n.inArray(this,l[t]);return i(o,e,l[t])});return this.pushStack(o)},_invoke:function(t,e){t.each(function(){var t;t=l.getWaypointsByElement(this);return n.each(t,function(t,n){n[e]();return true})});return this}};n.fn[g]=function(){var t,r;r=arguments[0],t=2<=arguments.length?e.call(arguments,1):[];if(d[r]){return d[r].apply(this,t)}else if(n.isFunction(r)){return d.init.apply(this,arguments)}else if(n.isPlainObject(r)){return d.init.apply(this,[null,r])}else if(!r){return n.error("jQuery Waypoints needs a callback function or handler option.")}else{return n.error("The "+r+" method does not exist in jQuery Waypoints.")}};n.fn[g].defaults={context:r,continuous:true,enabled:true,horizontal:false,offset:0,triggerOnce:false};h={refresh:function(){return n.each(a,function(t,e){return e.refresh()})},viewportHeight:function(){var t;return(t=r.innerHeight)!=null?t:i.height()},aggregate:function(t){var e,r,i;e=s;if(t){e=(i=a[n(t).data(u)])!=null?i.waypoints:void 0}if(!e){return[]}r={horizontal:[],vertical:[]};n.each(r,function(t,i){n.each(e[t],function(t,e){return i.push(e)});i.sort(function(t,e){return t.offset-e.offset});r[t]=n.map(i,function(t){return t.element});return r[t]=n.unique(r[t])});return r},above:function(t){if(t==null){t=r}return h._filter(t,"vertical",function(t,e){return e.offset<=t.oldScroll.y})},below:function(t){if(t==null){t=r}return h._filter(t,"vertical",function(t,e){return e.offset>t.oldScroll.y})},left:function(t){if(t==null){t=r}return h._filter(t,"horizontal",function(t,e){return e.offset<=t.oldScroll.x})},right:function(t){if(t==null){t=r}return h._filter(t,"horizontal",function(t,e){return e.offset>t.oldScroll.x})},enable:function(){return h._invoke("enable")},disable:function(){return h._invoke("disable")},destroy:function(){return h._invoke("destroy")},extendFn:function(t,e){return d[t]=e},_invoke:function(t){var e;e=n.extend({},s.vertical,s.horizontal);
13return n.each(e,function(e,n){n[t]();return true})},_filter:function(t,e,r){var i,o;i=a[n(t).data(u)];if(!i){return[]}o=[];n.each(i.waypoints[e],function(t,e){if(r(i,e)){return o.push(e)}});o.sort(function(t,e){return t.offset-e.offset});return n.map(o,function(t){return t.element})}};n[m]=function(){var t,n;n=arguments[0],t=2<=arguments.length?e.call(arguments,1):[];if(h[n]){return h[n].apply(null,t)}else{return h.aggregate.call(null,n)}};n[m].settings={resizeThrottle:100,scrollThrottle:30};return i.load(function(){return n[m]("refresh")})})}).call(this); 14 15 16/*---------------------------------------------------*/ 17/* Jquery Waypoints Sticky 18/*---------------------------------------------------*/ 19 20// Generated by CoffeeScript 1.6.2 21/* 22Sticky Elements Shortcut for jQuery Waypoints - v2.0.3 23Copyright (c) 2011-2013 Caleb Troughton 24Dual licensed under the MIT license and GPL license. 25https://github.com/imakewebthings/jquery-waypoints/blob/master/licenses.txt 26*/ 27 28 29(function() { 30 (function(root, factory) { 31 if (typeof define === 'function' && define.amd) { 32 return define(['jquery', 'waypoints'], factory); 33 } else { 34 return factory(root.jQuery); 35 } 36 })(this, function($) { 37 var defaults, wrap; 38 39 defaults = { 40 wrapper: '<div class="sticky-wrapper" />', 41 stuckClass: 'stuck' 42 }; 43 wrap = function($elements, options) { 44 $elements.wrap(options.wrapper); 45 return $elements.parent(); 46 }; 47 $.waypoints('extendFn', 'sticky', function(opt) { 48 var $wrap, options, originalHandler; 49 50 options = $.extend({}, $.fn.waypoint.defaults, defaults, opt); 51 $wrap = wrap(this, options); 52 originalHandler = options.handler; 53 options.handler = function(direction) { 54 var $sticky, shouldBeStuck; 55 56 $sticky = $(this).children(':first'); 57 shouldBeStuck = direction === 'down' || direction === 'right'; 58 $sticky.toggleClass(options.stuckClass, shouldBeStuck); 59 $wrap.height(shouldBeStuck ? $sticky.outerHeight() : ''); 60 if (originalHandler != null) { 61 return originalHandler.call(this, direction); 62 } 63 }; 64 $wrap.waypoint(options); 65 return this.data('stuckClass', options.stuckClass); 66 }); 67 return $.waypoints('extendFn', 'unsticky', function() { 68 this.parent().waypoint('destroy'); 69 this.unwrap(); 70 return this.removeClass(this.data('stuckClass')); 71 }); 72 }); 73 74}).call(this); 75 76 77 78 79/*---------------------------------------------------------*/ 80/* Jquery Placeholder 81/*---------------------------------------------------------*/ 82 83/*! http://mths.be/placeholder v2.0.7 by @mathias */ 84;(function(window, document, $) { 85 86 var isInputSupported = 'placeholder' in document.createElement('input'); 87 var isTextareaSupported = 'placeholder' in document.createElement('textarea'); 88 var prototype = $.fn; 89 var valHooks = $.valHooks; 90 var propHooks = $.propHooks; 91 var hooks; 92 var placeholder; 93 94 if (isInputSupported && isTextareaSupported) { 95 96 placeholder = prototype.placeholder = function() { 97 return this; 98 }; 99 100 placeholder.input = placeholder.textarea = true; 101 102 } else { 103 104 placeholder = prototype.placeholder = function() { 105 var $this = this; 106 $this 107 .filter((isInputSupported ? 'textarea' : ':input') + '[placeholder]') 108 .not('.placeholder') 109 .bind({ 110 'focus.placeholder': clearPlaceholder, 111 'blur.placeholder': setPlaceholder 112 }) 113 .data('placeholder-enabled', true) 114 .trigger('blur.placeholder'); 115 return $this; 116 }; 117 118 placeholder.input = isInputSupported; 119 placeholder.textarea = isTextareaSupported; 120 121 hooks = { 122 'get': function(element) { 123 var $element = $(element); 124 125 var $passwordInput = $element.data('placeholder-password'); 126 if ($passwordInput) { 127 return $passwordInput[0].value; 128 } 129 130 return $element.data('placeholder-enabled') && $element.hasClass('placeholder') ? '' : element.value; 131 }, 132 'set': function(element, value) { 133 var $element = $(element); 134 135 var $passwordInput = $element.data('placeholder-password'); 136 if ($passwordInput) { 137 return $passwordInput[0].value = value; 138 } 139 140 if (!$element.data('placeholder-enabled')) { 141 return element.value = value; 142 } 143 if (value == '') { 144 element.value = value; 145 // Issue #56: Setting the placeholder causes problems if the element continues to have focus. 146 if (element != safeActiveElement()) { 147 // We can't use `triggerHandler` here because of dummy text/password inputs :( 148 setPlaceholder.call(element); 149 } 150 } else if ($element.hasClass('placeholder')) { 151 clearPlaceholder.call(element, true, value) || (element.value = value); 152 } else { 153 element.value = value; 154 } 155 // `set` can not return `undefined`; see http://jsapi.info/jquery/1.7.1/val#L2363 156 return $element; 157 } 158 }; 159 160 if (!isInputSupported) { 161 valHooks.input = hooks; 162 propHooks.value = hooks; 163 } 164 if (!isTextareaSupported) { 165 valHooks.textarea = hooks; 166 propHooks.value = hooks; 167 } 168 169 $(function() { 170 // Look for forms 171 $(document).delegate('form', 'submit.placeholder', function() { 172 // Clear the placeholder values so they don't get submitted
173 var $inputs = $('.placeholder', this).each(clearPlaceholder); 174 setTimeout(function() { 175 $inputs.each(setPlaceholder); 176 }, 10); 177 }); 178 }); 179 180 // Clear placeholder values upon page reload 181 $(window).bind('beforeunload.placeholder', function() { 182 $('.placeholder').each(function() { 183 this.value = ''; 184 }); 185 }); 186 187 } 188 189 function args(elem) { 190 // Return an object of element attributes 191 var newAttrs = {}; 192 var rinlinejQuery = /^jQuery\d+$/; 193 $.each(elem.attributes, function(i, attr) { 194 if (attr.specified && !rinlinejQuery.test(attr.name)) { 195 newAttrs[attr.name] = attr.value; 196 } 197 }); 198 return newAttrs; 199 } 200 201 function clearPlaceholder(event, value) { 202 var input = this; 203 var $input = $(input); 204 if (input.value == $input.attr('placeholder') && $input.hasClass('placeholder')) { 205 if ($input.data('placeholder-password')) { 206 $input = $input.hide().next().show().attr('id', $input.removeAttr('id').data('placeholder-id')); 207 // If `clearPlaceholder` was called from `$.valHooks.input.set` 208 if (event === true) { 209 return $input[0].value = value; 210 } 211 $input.focus(); 212 } else { 213 input.value = ''; 214 $input.removeClass('placeholder'); 215 input == safeActiveElement() && input.select(); 216 } 217 } 218 } 219 220 function setPlaceholder() { 221 var $replacement; 222 var input = this; 223 var $input = $(input); 224 var id = this.id; 225 if (input.value == '') { 226 if (input.type == 'password') { 227 if (!$input.data('placeholder-textinput')) { 228 try { 229 $replacement = $input.clone().attr({ 'type': 'text' }); 230 } catch(e) { 231 $replacement = $('<input>').attr($.extend(args(this), { 'type': 'text' })); 232 } 233 $replacement 234 .removeAttr('name') 235 .data({ 236 'placeholder-password': $input, 237 'placeholder-id': id 238 }) 239 .bind('focus.placeholder', clearPlaceholder); 240 $input 241 .data({ 242 'placeholder-textinput': $replacement, 243 'placeholder-id': id 244 }) 245 .before($replacement); 246 } 247 $input = $input.removeAttr('id').hide().prev().attr('id', id).show(); 248 // Note: `$input[0] != input` now! 249 } 250 $input.addClass('placeholder'); 251 $input[0].value = $input.attr('placeholder'); 252 } else { 253 $input.removeClass('placeholder'); 254 } 255 } 256 257 function safeActiveElement() { 258 // Avoid IE9 `document.activeElement` of death 259 // https://github.com/mathiasbynens/jquery-placeholder/pull/99 260 try { 261 return document.activeElement; 262 } catch (err) {} 263 } 264 265}(this, document, jQuery)); 266 267 268/*----------------------------------------------------------*/ 269/* Bx Slider Plugin */ 270/*----------------------------------------------------------*/ 271 272/** 273 * BxSlider v4.1.1 - Fully loaded, responsive content slider 274 * http://bxslider.com 275 * 276 * Copyright 2013, Steven Wanderski - http://stevenwanderski.com - http://bxcreative.com 277 * Written while drinking Belgian ales and listening to jazz 278 * 279 * Released under the MIT license - http://opensource.org/licenses/MIT 280 */ 281!function(t){var e={},s={mode:"horizontal",slideSelector:"",infiniteLoop:!0,hideControlOnEnd:!1,speed:500,easing:null,slideMargin:0,startSlide:0,randomStart:!1,captions:!1,ticker:!1,tickerHover:!1,adaptiveHeight:!1,adaptiveHeightSpeed:500,video:!1,useCSS:!0,preloadImages:"visible",responsive:!0,touchEnabled:!0,swipeThreshold:50,oneToOneTouch:!0,preventDefaultSwipeX:!0,preventDefaultSwipeY:!1,pager:!0,pagerType:"full",pagerShortSeparator:" / ",pagerSelector:null,buildPager:null,pagerCustom:null,controls:!0,nextText:"Next",prevText:"Prev",nextSelector:null,prevSelector:null,autoControls:!1,startText:"Start",stopText:"Stop",autoControlsCombine:!1,autoControlsSelector:null,auto:!1,pause:4e3,autoStart:!0,autoDirection:"next",autoHover:!1,autoDelay:0,minSlides:1,maxSlides:1,moveSlides:0,slideWidth:0,onSliderLoad:function(){},onSlideBefore:function(){},onSlideAfter:function(){},onSlideNext:function(){},onSlidePrev:function(){}};t.fn.bxSlider=function(n){if(0==this.length)return this;if(this.length>1)return this.each(function(){t(this).bxSlider(n)}),this;var o={},r=this;e.el=this;var a=t(window).width(),l=t(window).height(),d=function(){o.settings=t.extend({},s,n),o.settings.slideWidth=parseInt(o.settings.slideWidth),o.children=r.children(o.settings.slideSelector),o.children.length<o.settings.minSlides&&(o.settings.minSlides=o.children.length),o.children.length<o.settings.maxSlides&&(o.settings.maxSlides=o.children.length),o.settings.randomStart&&(o.settings.startSlide=Math.floor(Math.random()*o.children.length)),o.active={index:o.settings.startSlide},o.carousel=o.settings.minSlides>1||o.settings.maxSlides>1,o.carousel&&(o.settings.preloadImages="all"),o.minThreshold=o.settings.minSlides*o.settings.slideWidth+(o.settings.minSlides-1)*o.settings.slideMargin,o.maxThreshold=o.settings.maxSlides*o.settings.slideWidth+(o.settings.maxSlides-1)*o.settings.slideMargin,o.working=!1,o.controls={},o.interval=null,o.animProp="vertical"==o.settings.mode?"top":"left",o.usingCSS=o.settings.useCSS&&"fade"!=o.settings.mode&&function(){var t=document.createElement("div"),e=["WebkitPerspective","MozPerspective","OPerspective","msPerspective"];for(var i in e)if(void 0!==t.style[e[i]])return o.cssPrefix=e[i].replace("Perspective","").toLowerCase(),o.animProp="-"+o.cssPrefix+"-transform",!0;return!1}(),"vertical"==o.settings.mode&&(o.settings.maxSlides=o.settings.minSlides),r.data("origStyle",r.attr("style")),r.children(o.settings.slideSelector).each(function(){t(this).data("origStyle",t(this).attr("style"))}),c()},c=function(){r.wrap('<div class="bx-wrapper"><div class="bx-viewport"></div></div>'),o.viewport=r.parent(),o.loader=t('<div class="bx-loading" />'),o.viewport.prepend(o.loader),r.css({width:"horizontal"==o.settings.mode?100*o.children.length+215+"%":"auto",position:"relative"}),o.usingCSS&&o.settings.easing?r.css("-"+o.cssPrefix+"-transition-timing-function",o.settings.easing):o.settings.easing||(o.settings.easing="swing"),f(),o.viewport.css({width:"100%",overflow:"hidden",position:"relative"}),o.viewport.parent().css({maxWidth:v()}),o.settings.pager||o.viewport.parent().css({margin:"0 auto 0px"}
281),o.children.css({"float":"horizontal"==o.settings.mode?"left":"none",listStyle:"none",position:"relative"}),o.children.css("width",u()),"horizontal"==o.settings.mode&&o.settings.slideMargin>0&&o.children.css("marginRight",o.settings.slideMargin),"vertical"==o.settings.mode&&o.settings.slideMargin>0&&o.children.css("marginBottom",o.settings.slideMargin),"fade"==o.settings.mode&&(o.children.css({position:"absolute",zIndex:0,display:"none"}),o.children.eq(o.settings.startSlide).css({zIndex:50,display:"block"})),o.controls.el=t('<div class="bx-controls" />'),o.settings.captions&&P(),o.active.last=o.settings.startSlide==x()-1,o.settings.video&&r.fitVids();var e=o.children.eq(o.settings.startSlide);"all"==o.settings.preloadImages&&(e=o.children),o.settings.ticker?o.settings.pager=!1:(o.settings.pager&&T(),o.settings.controls&&C(),o.settings.auto&&o.settings.autoControls&&E(),(o.settings.controls||o.settings.autoControls||o.settings.pager)&&o.viewport.after(o.controls.el)),g(e,h)},g=function(e,i){var s=e.find("img, iframe").length;if(0==s)return i(),void 0;var n=0;e.find("img, iframe").each(function(){t(this).one("load",function(){++n==s&&i()}).each(function(){this.complete&&t(this).load()})})},h=function(){if(o.settings.infiniteLoop&&"fade"!=o.settings.mode&&!o.settings.ticker){var e="vertical"==o.settings.mode?o.settings.minSlides:o.settings.maxSlides,i=o.children.slice(0,e).clone().addClass("bx-clone"),s=o.children.slice(-e).clone().addClass("bx-clone");r.append(i).prepend(s)}o.loader.remove(),S(),"vertical"==o.settings.mode&&(o.settings.adaptiveHeight=!0),o.viewport.height(p()),r.redrawSlider(),o.settings.onSliderLoad(o.active.index),o.initialized=!0,o.settings.responsive&&t(window).bind("resize",B),o.settings.auto&&o.settings.autoStart&&H(),o.settings.ticker&&L(),o.settings.pager&&I(o.settings.startSlide),o.settings.controls&&W(),o.settings.touchEnabled&&!o.settings.ticker&&O()},p=function(){var e=0,s=t();if("vertical"==o.settings.mode||o.settings.adaptiveHeight)if(o.carousel){var n=1==o.settings.moveSlides?o.active.index:o.active.index*m();for(s=o.children.eq(n),i=1;i<=o.settings.maxSlides-1;i++)s=n+i>=o.children.length?s.add(o.children.eq(i-1)):s.add(o.children.eq(n+i))}else s=o.children.eq(o.active.index);else s=o.children;return"vertical"==o.settings.mode?(s.each(function(){e+=t(this).outerHeight()}),o.settings.slideMargin>0&&(e+=o.settings.slideMargin*(o.settings.minSlides-1))):e=Math.max.apply(Math,s.map(function(){return t(this).outerHeight(!1)}).get()),e},v=function(){var t="100%";return o.settings.slideWidth>0&&(t="horizontal"==o.settings.mode?o.settings.maxSlides*o.settings.slideWidth+(o.settings.maxSlides-1)*o.settings.slideMargin:o.settings.slideWidth),t},u=function(){var t=o.settings.slideWidth,e=o.viewport.width();return 0==o.settings.slideWidth||o.settings.slideWidth>e&&!o.carousel||"vertical"==o.settings.mode?t=e:o.settings.maxSlides>1&&"horizontal"==o.settings.mode&&(e>o.maxThreshold||e<o.minThreshold&&(t=(e-o.settings.slideMargin*(o.settings.minSlides-1))/o.settings.minSlides)),t},f=function(){var t=1;if("horizontal"==o.settings.mode&&o.settings.slideWidth>0)if(o.viewport.width()<o.minThreshold)t=o.settings.minSlides;else if(o.viewport.width()>o.maxThreshold)t=o.settings.maxSlides;else{var e=o.children.first().width();t=Math.floor(o.viewport.width()/e)}else"vertical"==o.settings.mode&&(t=o.settings.minSlides);return t},x=function(){var t=0;if(o.settings.moveSlides>0)if(o.settings.infiniteLoop)t=o.children.length/m();else for(var e=0,i=0;e<o.children.length;)++t,e=i+f(),i+=o.settings.moveSlides<=f()?o.settings.moveSlides:f();else t=Math.ceil(o.children.length/f());return t},m=function(){return o.settings.moveSlides>0&&o.settings.moveSlides<=f()?o.settings.moveSlides:f()},S=function(){if(o.children.length>o.settings.maxSlides&&o.active.last&&!o.settings.infiniteLoop){if("horizontal"==o.settings.mode){var t=o.children.last(),e=t.position();b(-(e.left-(o.viewport.width()-t.width())),"reset",0)}else if("vertical"==o.settings.mode){var i=o.children.length-o.settings.minSlides,e=o.children.eq(i).position();b(-e.top,"reset",0)}}else{var e=o.children.eq(o.active.index*m()).position();o.active.index==x()-1&&(o.active.last=!0),void 0!=e&&("horizontal"==o.settings.mode?b(-e.left,"reset",0):"vertical"==o.settings.mode&&b(-e.top,"reset",0))}}
281,b=function(t,e,i,s){if(o.usingCSS){var n="vertical"==o.settings.mode?"translate3d(0, "+t+"px, 0)":"translate3d("+t+"px, 0, 0)";r.css("-"+o.cssPrefix+"-transition-duration",i/1e3+"s"),"slide"==e?(r.css(o.animProp,n),r.bind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd",function(){r.unbind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd"),D()})):"reset"==e?r.css(o.animProp,n):"ticker"==e&&(r.css("-"+o.cssPrefix+"-transition-timing-function","linear"),r.css(o.animProp,n),r.bind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd",function(){r.unbind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd"),b(s.resetValue,"reset",0),N()}))}else{var a={};a[o.animProp]=t,"slide"==e?r.animate(a,i,o.settings.easing,function(){D()}):"reset"==e?r.css(o.animProp,t):"ticker"==e&&r.animate(a,speed,"linear",function(){b(s.resetValue,"reset",0),N()})}},w=function(){for(var e="",i=x(),s=0;i>s;s++){var n="";o.settings.buildPager&&t.isFunction(o.settings.buildPager)?(n=o.settings.buildPager(s),o.pagerEl.addClass("bx-custom-pager")):(n=s+1,o.pagerEl.addClass("bx-default-pager")),e+='<div class="bx-pager-item"><a href="" data-slide-index="'+s+'" class="bx-pager-link">'+n+"</a></div>"}o.pagerEl.html(e)},T=function(){o.settings.pagerCustom?o.pagerEl=t(o.settings.pagerCustom):(o.pagerEl=t('<div class="bx-pager" />'),o.settings.pagerSelector?t(o.settings.pagerSelector).html(o.pagerEl):o.controls.el.addClass("bx-has-pager").append(o.pagerEl),w()),o.pagerEl.delegate("a","click",q)},C=function(){o.controls.next=t('<a class="bx-next" href="">'+o.settings.nextText+"</a>"),o.controls.prev=t('<a class="bx-prev" href="">'+o.settings.prevText+"</a>"),o.controls.next.bind("click",y),o.controls.prev.bind("click",z),o.settings.nextSelector&&t(o.settings.nextSelector).append(o.controls.next),o.settings.prevSelector&&t(o.settings.prevSelector).append(o.controls.prev),o.settings.nextSelector||o.settings.prevSelector||(o.controls.directionEl=t('<div class="bx-controls-direction" />'),o.controls.directionEl.append(o.controls.prev).append(o.controls.next),o.controls.el.addClass("bx-has-controls-direction").append(o.controls.directionEl))},E=function(){o.controls.start=t('<div class="bx-controls-auto-item"><a class="bx-start" href="">'+o.settings.startText+"</a></div>"),o.controls.stop=t('<div class="bx-controls-auto-item"><a class="bx-stop" href="">'+o.settings.stopText+"</a></div>"),o.controls.autoEl=t('<div class="bx-controls-auto" />'),o.controls.autoEl.delegate(".bx-start","click",k),o.controls.autoEl.delegate(".bx-stop","click",M),o.settings.autoControlsCombine?o.controls.autoEl.append(o.controls.start):o.controls.autoEl.append(o.controls.start).append(o.controls.stop),o.settings.autoControlsSelector?t(o.settings.autoControlsSelector).html(o.controls.autoEl):o.controls.el.addClass("bx-has-controls-auto").append(o.controls.autoEl),A(o.settings.autoStart?"stop":"start")},P=function(){o.children.each(function(){var e=t(this).find("img:first").attr("title");void 0!=e&&(""+e).length&&t(this).append('<div class="bx-caption"><span>'+e+"</span></div>")})},y=function(t){o.settings.auto&&r.stopAuto(),r.goToNextSlide(),t.preventDefault()},z=function(t){o.settings.auto&&r.stopAuto(),r.goToPrevSlide(),t.preventDefault()},k=function(t){r.startAuto(),t.preventDefault()},M=function(t){r.stopAuto(),t.preventDefault()},q=function(e){o.settings.auto&&r.stopAuto();var i=t(e.currentTarget),s=parseInt(i.attr("data-slide-index"));s!=o.active.index&&r.goToSlide(s),e.preventDefault()},I=function(e){var i=o.children.length;return"short"==o.settings.pagerType?(o.settings.maxSlides>1&&(i=Math.ceil(o.children.length/o.settings.maxSlides)),o.pagerEl.html(e+1+o.settings.pagerShortSeparator+i),void 0):(o.pagerEl.find("a").removeClass("active"),o.pagerEl.each(function(i,s){t(s).find("a").eq(e).addClass("active")}),void 0)},D=function(){if(o.settings.infiniteLoop){var t="";0==o.active.index?t=o.children.eq(0).position():o.active.index==x()-1&&o.carousel?t=o.children.eq((x()-1)*m()).position():o.active.index==o.children.length-1&&(t=o.children.eq(o.children.length-1).position()),"horizontal"==o.settings.mode?b(-t.left,"reset",0):"vertical"==o.settings.mode&&b(-t.top,"reset",0)}o.working=!1,o.settings.onSlideAfter(o.children.eq(o.active.index),o.oldIndex,o.active.index)},A=function(t){o.settings.autoControlsCombine?o.controls.autoEl.html(o.controls[t]):(o.controls.autoEl.find("a").removeClass("active"),o.controls.autoEl.find("a:not(.bx-"+t+")").addClass("active"))},W=function(){1==x()?(o.controls.prev.addClass("disabled"),o.controls.next.addClass("disabled")):!o.settings.infiniteLoop&&o.settings.hideControlOnEnd&&(0==o.active.index?(o.controls.prev.addClass("disabled"),o.controls.next.removeClass("disabled")):o.active.index==x()-1?(o.controls.next.addClass("disabled"),o.controls.prev.removeClass("disabled")):(o.controls.prev.removeClass("disabled"),o.controls.next.removeClass("disabled")))},H=function(){o.settings.autoDelay>0?setTimeout(r.startAuto,o.settings.autoDelay):r.startAuto(),o.settings.autoHover&&r.hover(function(){o.interval&&(r.stopAuto(!0),o.autoPaused=!0)},function(){o.autoPaused&&(r.startAuto(!0),o.autoPaused=null)})},L=function(){var e=0;if("next"==o.settings.autoDirection)r.append(o.children.clone().addClass("bx-clone"));else{r.prepend(o.children.clone().addClass("bx-clone"));var i=o.children.first().position();e="horizontal"==o.settings.mode?-i.left:-i.top}b(e,"reset",0),o.settings.pager=!1,o.settings.controls=!1,o.settings.autoControls=!1,o.settings.tickerHover&&!o.usingCSS&&o.viewport.hover(function(){r.stop()},function(){var e=0;o.children.each(function(){e+="horizontal"==o.settings.mode?t(this).outerWidth(!0):t(this).outerHeight(!0)});
281var i=o.settings.speed/e,s="horizontal"==o.settings.mode?"left":"top",n=i*(e-Math.abs(parseInt(r.css(s))));N(n)}),N()},N=function(t){speed=t?t:o.settings.speed;var e={left:0,top:0},i={left:0,top:0};"next"==o.settings.autoDirection?e=r.find(".bx-clone").first().position():i=o.children.first().position();var s="horizontal"==o.settings.mode?-e.left:-e.top,n="horizontal"==o.settings.mode?-i.left:-i.top,a={resetValue:n};b(s,"ticker",speed,a)},O=function(){o.touch={start:{x:0,y:0},end:{x:0,y:0}},o.viewport.bind("touchstart",X)},X=function(t){if(o.working)t.preventDefault();else{o.touch.originalPos=r.position();var e=t.originalEvent;o.touch.start.x=e.changedTouches[0].pageX,o.touch.start.y=e.changedTouches[0].pageY,o.viewport.bind("touchmove",Y),o.viewport.bind("touchend",V)}},Y=function(t){var e=t.originalEvent,i=Math.abs(e.changedTouches[0].pageX-o.touch.start.x),s=Math.abs(e.changedTouches[0].pageY-o.touch.start.y);if(3*i>s&&o.settings.preventDefaultSwipeX?t.preventDefault():3*s>i&&o.settings.preventDefaultSwipeY&&t.preventDefault(),"fade"!=o.settings.mode&&o.settings.oneToOneTouch){var n=0;if("horizontal"==o.settings.mode){var r=e.changedTouches[0].pageX-o.touch.start.x;n=o.touch.originalPos.left+r}else{var r=e.changedTouches[0].pageY-o.touch.start.y;n=o.touch.originalPos.top+r}b(n,"reset",0)}},V=function(t){o.viewport.unbind("touchmove",Y);var e=t.originalEvent,i=0;if(o.touch.end.x=e.changedTouches[0].pageX,o.touch.end.y=e.changedTouches[0].pageY,"fade"==o.settings.mode){var s=Math.abs(o.touch.start.x-o.touch.end.x);s>=o.settings.swipeThreshold&&(o.touch.start.x>o.touch.end.x?r.goToNextSlide():r.goToPrevSlide(),r.stopAuto())}else{var s=0;"horizontal"==o.settings.mode?(s=o.touch.end.x-o.touch.start.x,i=o.touch.originalPos.left):(s=o.touch.end.y-o.touch.start.y,i=o.touch.originalPos.top),!o.settings.infiniteLoop&&(0==o.active.index&&s>0||o.active.last&&0>s)?b(i,"reset",200):Math.abs(s)>=o.settings.swipeThreshold?(0>s?r.goToNextSlide():r.goToPrevSlide(),r.stopAuto()):b(i,"reset",200)}o.viewport.unbind("touchend",V)},B=function(){var e=t(window).width(),i=t(window).height();(a!=e||l!=i)&&(a=e,l=i,r.redrawSlider())};return r.goToSlide=function(e,i){if(!o.working&&o.active.index!=e)if(o.working=!0,o.oldIndex=o.active.index,o.active.index=0>e?x()-1:e>=x()?0:e,o.settings.onSlideBefore(o.children.eq(o.active.index),o.oldIndex,o.active.index),"next"==i?o.settings.onSlideNext(o.children.eq(o.active.index),o.oldIndex,o.active.index):"prev"==i&&o.settings.onSlidePrev(o.children.eq(o.active.index),o.oldIndex,o.active.index),o.active.last=o.active.index>=x()-1,o.settings.pager&&I(o.active.index),o.settings.controls&&W(),"fade"==o.settings.mode)o.settings.adaptiveHeight&&o.viewport.height()!=p()&&o.viewport.animate({height:p()},o.settings.adaptiveHeightSpeed),o.children.filter(":visible").fadeOut(o.settings.speed).css({zIndex:0}),o.children.eq(o.active.index).css("zIndex",51).fadeIn(o.settings.speed,function(){t(this).css("zIndex",50),D()});else{o.settings.adaptiveHeight&&o.viewport.height()!=p()&&o.viewport.animate({height:p()},o.settings.adaptiveHeightSpeed);var s=0,n={left:0,top:0};if(!o.settings.infiniteLoop&&o.carousel&&o.active.last)if("horizontal"==o.settings.mode){var a=o.children.eq(o.children.length-1);n=a.position(),s=o.viewport.width()-a.outerWidth()}else{var l=o.children.length-o.settings.minSlides;n=o.children.eq(l).position()}else if(o.carousel&&o.active.last&&"prev"==i){var d=1==o.settings.moveSlides?o.settings.maxSlides-m():(x()-1)*m()-(o.children.length-o.settings.maxSlides),a=r.children(".bx-clone").eq(d);n=a.position()}else if("next"==i&&0==o.active.index)n=r.find("> .bx-clone").eq(o.settings.maxSlides).position(),o.active.last=!1;else if(e>=0){var c=e*m();n=o.children.eq(c).position()}if("undefined"!=typeof n){var g="horizontal"==o.settings.mode?-(n.left-s):-n.top;b(g,"slide",o.settings.speed)}}},r.goToNextSlide=function(){if(o.settings.infiniteLoop||!o.active.last){var t=parseInt(o.active.index)+1;r.goToSlide(t,"next")}},r.goToPrevSlide=function(){if(o.settings.infiniteLoop||0!=o.active.index){var t=parseInt(o.active.index)-1;r.goToSlide(t,"prev")}},r.startAuto=function(t){o.interval||(o.interval=setInterval(function(){"next"==o.settings.autoDirection?r.goToNextSlide():r.goToPrevSlide()},o.settings.pause),o.settings.autoControls&&1!=t&&A("stop"))},r.stopAuto=function(t){o.interval&&(clearInterval(o.interval),o.interval=null,o.settings.autoControls&&1!=t&&A("start"))},r.getCurrentSlide=function(){return o.active.index},r.getSlideCount=function(){return o.children.length},r.redrawSlider=function(){o.children.add(r.find(".bx-clone")).outerWidth(u()),o.viewport.css("height",p()),o.settings.ticker||S(),o.active.last&&(o.active.index=x()-1),o.active.index>=x()&&(o.active.last=!0),o.settings.pager&&!o.settings.pagerCustom&&(w(),I(o.active.index))},r.destroySlider=function(){o.initialized&&(o.initialized=!1,t(".bx-clone",this).remove(),o.children.each(function(){void 0!=t(this).data("origStyle")?t(this).attr("style",t(this).data("origStyle")):t(this).removeAttr("style")}),void 0!=t(this).data("origStyle")?this.attr("style",t(this).data("origStyle")):t(this).removeAttr("style"),t(this).unwrap().unwrap(),o.controls.el&&o.controls.el.remove(),o.controls.next&&o.controls.next.remove(),o.controls.prev&&o.controls.prev.remove(),o.pagerEl&&o.pagerEl.remove(),t(".bx-caption",this).remove(),o.controls.autoEl&&o.controls.autoEl.remove(),clearInterval(o.interval),o.settings.responsive&&t(window).unbind("resize",B))},r.reloadSlider=function(t){void 0!=t&&(n=t),r.destroySlider(),d()},d(),this}}(jQuery); 282 283 284/*-----------------------------------------------*/ 285/* jQuery CounTo */ 286/*-----------------------------------------------*/ 287 288(function(a){a.fn.countTo=function(g){g=g||{};return a(this).each(function(){function e(a){a=b.formatter.call(h,a,b);f.html(a)}var b=a.extend({},a.fn.countTo.defaults,{from:a(this).data("from"),to:a(this).data("to"),speed:a(this).data("speed"),refreshInterval:a(this).data("refresh-interval"),decimals:a(this).data("decimals")},g),j=Math.ceil(b.speed/b.refreshInterval),l=(b.to-b.from)/j,h=this,f=a(this),k=0,c=b.from,d=f.data("countTo")||{};f.data("countTo",d);d.interval&&clearInterval(d.interval);d.interval= 289setInterval(function(){c+=l;k++;e(c);"function"==typeof b.onUpdate&&b.onUpdate.call(h,c);k>
289=j&&(f.removeData("countTo"),clearInterval(d.interval),c=b.to,"function"==typeof b.onComplete&&b.onComplete.call(h,c))},b.refreshInterval);e(c)})};a.fn.countTo.defaults={from:0,to:0,speed:1E3,refreshInterval:100,decimals:0,formatter:function(a,e){return a.toFixed(e.decimals)},onUpdate:null,onComplete:null}})(jQuery); 290 291 292/*-----------------------------------------------------*/ 293/* swipe plugin 294/*-----------------------------------------------------*/ 295 296(function(d){var m="left",l="right",c="up",s="down",b="in",t="out",j="none",o="auto",i="swipe",p="pinch",u="tap",x="horizontal",q="vertical",g="all",e="start",h="move",f="end",n="cancel",a="ontouchstart" in window,v="TouchSwipe";var k={fingers:1,threshold:75,cancelThreshold:25,pinchThreshold:20,maxTimeThreshold:null,fingerReleaseThreshold:250,swipe:null,swipeLeft:null,swipeRight:null,swipeUp:null,swipeDown:null,swipeStatus:null,pinchIn:null,pinchOut:null,pinchStatus:null,click:null,tap:null,triggerOnTouchEnd:true,triggerOnTouchLeave:false,allowPageScroll:"auto",fallbackToMouseEvents:true,excludedElements:"button, input, select, textarea, a, .noSwipe"};d.fn.swipe=function(A){var z=d(this),y=z.data(v);if(y&&typeof A==="string"){if(y[A]){return y[A].apply(this,Array.prototype.slice.call(arguments,1))}else{d.error("Method "+A+" does not exist on jQuery.swipe")}}else{if(!y&&(typeof A==="object"||!A)){return r.apply(this,arguments)}}return z};d.fn.swipe.defaults=k;d.fn.swipe.phases={PHASE_START:e,PHASE_MOVE:h,PHASE_END:f,PHASE_CANCEL:n};d.fn.swipe.directions={LEFT:m,RIGHT:l,UP:c,DOWN:s,IN:b,OUT:t};d.fn.swipe.pageScroll={NONE:j,HORIZONTAL:x,VERTICAL:q,AUTO:o};d.fn.swipe.fingers={ONE:1,TWO:2,THREE:3,ALL:g};function r(y){if(y&&(y.allowPageScroll===undefined&&(y.swipe!==undefined||y.swipeStatus!==undefined))){y.allowPageScroll=j}if(y.click!==undefined&&y.tap===undefined){y.tap=y.click}if(!y){y={}}y=d.extend({},d.fn.swipe.defaults,y);return this.each(function(){var A=d(this);var z=A.data(v);if(!z){z=new w(this,y);A.data(v,z)}})}function w(S,ag){var aJ=(a||!ag.fallbackToMouseEvents),az=aJ?"touchstart":"mousedown",U=aJ?"touchmove":"mousemove",av=aJ?"touchend":"mouseup",D=aJ?null:"mouseleave",R="touchcancel";var ad=0,N=null,ah=0,aF=0,A=0,aj=1,aA=0,aN=0,Z=null;var H=d(S);var O="start";var aI=0;var ai=null;var I=0,Y=0,aD=0,aP=0;try{H.bind(az,at);H.bind(R,L)}catch(aG){d.error("events not supported "+az+","+R+" on jQuery.swipe")}this.enable=function(){H.bind(az,at);H.bind(R,L);return H};this.disable=function(){Q();return H};this.destroy=function(){Q();H.data(v,null);return H};this.option=function(aR,aQ){if(ag[aR]!==undefined){if(aQ===undefined){return ag[aR]}else{ag[aR]=aQ}}else{d.error("Option "+aR+" does not exist on jQuery.swipe.options")}};function at(aS){if(X()){return}if(d(aS.target).closest(ag.excludedElements,H).length>0){return}var aT=aS.originalEvent?aS.originalEvent:aS;var aR,aQ=a?aT.touches[0]:aT;O=e;if(a){aI=aT.touches.length}else{aS.preventDefault()}ad=0;N=null;aN=null;ah=0;aF=0;A=0;aj=1;aA=0;ai=T();Z=aE();z();if(!a||(aI===ag.fingers||ag.fingers===g)||ap()){aO(0,aQ);I=B();if(aI==2){aO(1,aT.touches[1]);aF=A=aa(ai[0].start,ai[1].start)}if(ag.swipeStatus||ag.pinchStatus){aR=aH(aT,O)}}else{aR=false}if(aR===false){O=n;aH(aT,O);return aR}else{ak(true)}}function P(aT){var aW=aT.originalEvent?aT.originalEvent:aT;if(O===f||O===n||af()){return}var aS,aR=a?aW.touches[0]:aW;var aU=V(aR);Y=B();if(a){aI=aW.touches.length}O=h;if(aI==2){if(aF==0){aO(1,aW.touches[1]);aF=A=aa(ai[0].start,ai[1].start)}else{V(aW.touches[1]);A=aa(ai[0].end,ai[1].end);aN=ao(ai[0].end,ai[1].end)}aj=y(aF,A);aA=Math.abs(aF-A)}if((aI===ag.fingers||ag.fingers===g)||!a||ap()){N=ar(aU.start,aU.end);C(aT,N);ad=G(aU.start,aU.end);ah=K();aK(N,ad);if(ag.swipeStatus||ag.pinchStatus){aS=aH(aW,O)}if(!ag.triggerOnTouchEnd||ag.triggerOnTouchLeave){var aQ=true;if(ag.triggerOnTouchLeave){var aV=au(this);aQ=aC(aU.end,aV)}if(!ag.triggerOnTouchEnd&&aQ){O=aM(h)}else{if(ag.triggerOnTouchLeave&&!aQ){O=aM(f)}}if(O==n||O==f){aH(aW,O)}}}else{O=n;aH(aW,O)}if(aS===false){O=n;aH(aW,O)}}function ab(aS){var aU=aS.originalEvent;if(a){if(aU.touches.length>0){aw();return true}}if(af()){aI=aP}aS.preventDefault();Y=B();if(ag.triggerOnTouchEnd||(ag.triggerOnTouchEnd==false&&O===h)){O=f;var aR=((aI===ag.fingers||ag.fingers===g)||!a);var aQ=ai[0].end.x!==0;var aT=aR&&aQ&&(an()||aB());if(aT){aH(aU,O)}else{O=n;aH(aU,O)}}else{if(!ag.triggerOnTouchEnd&&ay()){O=f;am(aU,O,u)}else{if(O===h){O=n;aH(aU,O)}}}ak(false)}function L(){aI=0;Y=0;I=0;aF=0;A=0;aj=1;z();ak(false)}function W(aQ){var aR=aQ.originalEvent;if(ag.triggerOnTouchLeave){O=aM(f);aH(aR,O)}}function Q(){H.unbind(az,at);H.unbind(R,L);H.unbind(U,P);H.unbind(av,ab);if(D){H.unbind(D,W)}ak(false)}function aM(aT){var aS=aT;var aR=aq();var aQ=ae();if(!aR){aS=n}else{if(aQ&&aT==h&&(!ag.triggerOnTouchEnd||ag.triggerOnTouchLeave)){aS=f}else{if(!aQ&&aT==f&&ag.triggerOnTouchLeave){aS=n}}}return aS}function aH(aS,aQ){var aR=undefined;if(ac()){aR=am(aS,aQ,i)}if(ap()&&aR!==false){aR=am(aS,aQ,p)}
vendor: 5,011 bytes, lines 296-304
296if(ay()&&aR!==false){aR=am(aS,aQ,u)}if(aQ===n){L(aS)}if(aQ===f){if(a){if(aS.touches.length==0){L(aS)}}else{L(aS)}}return aR}function am(aT,aQ,aS){var aR=undefined;if(aS==i){H.trigger("swipeStatus",[aQ,N||null,ad||0,ah||0,aI]);if(ag.swipeStatus){aR=ag.swipeStatus.call(H,aT,aQ,N||null,ad||0,ah||0,aI);if(aR===false){return false}}if(aQ==f&&aB()){H.trigger("swipe",[N,ad,ah,aI]);if(ag.swipe){aR=ag.swipe.call(H,aT,N,ad,ah,aI);if(aR===false){return false}}switch(N){case m:H.trigger("swipeLeft",[N,ad,ah,aI]);if(ag.swipeLeft){aR=ag.swipeLeft.call(H,aT,N,ad,ah,aI)}break;case l:H.trigger("swipeRight",[N,ad,ah,aI]);if(ag.swipeRight){aR=ag.swipeRight.call(H,aT,N,ad,ah,aI)}break;case c:H.trigger("swipeUp",[N,ad,ah,aI]);if(ag.swipeUp){aR=ag.swipeUp.call(H,aT,N,ad,ah,aI)}break;case s:H.trigger("swipeDown",[N,ad,ah,aI]);if(ag.swipeDown){aR=ag.swipeDown.call(H,aT,N,ad,ah,aI)}break}}}if(aS==p){H.trigger("pinchStatus",[aQ,aN||null,aA||0,ah||0,aI,aj]);if(ag.pinchStatus){aR=ag.pinchStatus.call(H,aT,aQ,aN||null,aA||0,ah||0,aI,aj);if(aR===false){return false}}if(aQ==f&&an()){switch(aN){case b:H.trigger("pinchIn",[aN||null,aA||0,ah||0,aI,aj]);if(ag.pinchIn){aR=ag.pinchIn.call(H,aT,aN||null,aA||0,ah||0,aI,aj)}break;case t:H.trigger("pinchOut",[aN||null,aA||0,ah||0,aI,aj]);if(ag.pinchOut){aR=ag.pinchOut.call(H,aT,aN||null,aA||0,ah||0,aI,aj)}break}}}if(aS==u){if(aQ===n||aQ===f){if((aI===1||!a)&&(isNaN(ad)||ad===0)){H.trigger("tap",[aT.target]);if(ag.tap){aR=ag.tap.call(H,aT,aT.target)}}}}return aR}function ae(){var aQ=true;if(ag.threshold!==null){aQ=ad>=ag.threshold}if(aQ&&ag.cancelThreshold!==null){aQ=(M(N)-ad)<ag.cancelThreshold}return aQ}function al(){if(ag.pinchThreshold!==null){return aA>=ag.pinchThreshold}return true}function aq(){var aQ;if(ag.maxTimeThreshold){if(ah>=ag.maxTimeThreshold){aQ=false}else{aQ=true}}else{aQ=true}return aQ}function C(aQ,aR){if(ag.allowPageScroll===j||ap()){aQ.preventDefault()}else{var aS=ag.allowPageScroll===o;switch(aR){case m:if((ag.swipeLeft&&aS)||(!aS&&ag.allowPageScroll!=x)){aQ.preventDefault()}break;case l:if((ag.swipeRight&&aS)||(!aS&&ag.allowPageScroll!=x)){aQ.preventDefault()}break;case c:if((ag.swipeUp&&aS)||(!aS&&ag.allowPageScroll!=q)){aQ.preventDefault()}break;case s:if((ag.swipeDown&&aS)||(!aS&&ag.allowPageScroll!=q)){aQ.preventDefault()}break}}}function an(){return al()}function ap(){return !!(ag.pinchStatus||ag.pinchIn||ag.pinchOut)}function ax(){return !!(an()&&ap())}function aB(){var aQ=aq();var aS=ae();var aR=aS&&aQ;return aR}function ac(){return !!(ag.swipe||ag.swipeStatus||ag.swipeLeft||ag.swipeRight||ag.swipeUp||ag.swipeDown)}function E(){return !!(aB()&&ac())}function ay(){return !!(ag.tap)}function aw(){aD=B();aP=event.touches.length+1}function z(){aD=0;aP=0}function af(){var aQ=false;if(aD){var aR=B()-aD;if(aR<=ag.fingerReleaseThreshold){aQ=true}}return aQ}function X(){return !!(H.data(v+"_intouch")===true)}function ak(aQ){if(aQ===true){H.bind(U,P);H.bind(av,ab);if(D){H.bind(D,W)}}else{H.unbind(U,P,false);H.unbind(av,ab,false);if(D){H.unbind(D,W,false)}}H.data(v+"_intouch",aQ===true)}function aO(aR,aQ){var aS=aQ.identifier!==undefined?aQ.identifier:0;ai[aR].identifier=aS;ai[aR].start.x=ai[aR].end.x=aQ.pageX||aQ.clientX;ai[aR].start.y=ai[aR].end.y=aQ.pageY||aQ.clientY;return ai[aR]}function V(aQ){var aS=aQ.identifier!==undefined?aQ.identifier:0;var aR=J(aS);aR.end.x=aQ.pageX||aQ.clientX;aR.end.y=aQ.pageY||aQ.clientY;return aR}function J(aR){for(var aQ=0;aQ<ai.length;aQ++){if(ai[aQ].identifier==aR){return ai[aQ]}}}function T(){var aQ=[];for(var aR=0;aR<=5;aR++){aQ.push({start:{x:0,y:0},end:{x:0,y:0},identifier:0})}return aQ}function aK(aQ,aR){aR=Math.max(aR,M(aQ));Z[aQ].distance=aR}function M(aQ){return Z[aQ].distance}function aE(){var aQ={};aQ[m]=aL(m);aQ[l]=aL(l);aQ[c]=aL(c);aQ[s]=aL(s);return aQ}function aL(aQ){return{direction:aQ,distance:0}}function K(){return Y-I}function aa(aT,aS){var aR=Math.abs(aT.x-aS.x);var aQ=Math.abs(aT.y-aS.y);return Math.round(Math.sqrt(aR*aR+aQ*aQ))}function y(aQ,aR){var aS=(aR/aQ)*1;return aS.toFixed(2)}function ao(){if(aj<1){return t}else{return b}}function G(aR,aQ){return Math.round(Math.sqrt(Math.pow(aQ.x-aR.x,2)+Math.pow(aQ.y-aR.y,2)))}function F(aT,aR){var aQ=aT.x-aR.x;var aV=aR.y-aT.y;var aS=Math.atan2(aV,aQ);var aU=Math.round(aS*180/Math.PI);if(aU<0){aU=360-Math.abs(aU)}return aU}function ar(aR,aQ){var aS=F(aR,aQ);if((aS<=45)&&(aS>=0)){return m}else{if((aS<=360)&&(aS>=315)){return m}else{if((aS>=135)&&(aS<=225)){return l}else{if((aS>45)&&(aS<135)){return s}else{return c}}}}}function B(){var aQ=new Date();return aQ.getTime()}function au(aQ){aQ=d(aQ);var aS=aQ.offset();var aR={left:aS.left,right:aS.left+aQ.outerWidth(),top:aS.top,bottom:aS.top+aQ.outerHeight()};return aR}function aC(aQ,aR){return(aQ.x>aR.left&&aQ.x<aR.right&&aQ.y>aR.top&&aQ.y<aR.bottom)}}})(jQuery); 297 298/*-------------------------------------------------------*/ 299/* Easy Pie Chart 300/*-------------------------------------------------------*/ 301 302// Generated by CoffeeScript 1.4.0 303 304/*
305Easy pie chart is a jquery plugin to display simple animated pie charts for only one value 306 307Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) 308and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses. 309 310Built on top of the jQuery library (http://jquery.com) 311 312@source: http://github.com/rendro/easy-pie-chart/ 313@autor: Robert Fleischmann 314@version: 1.0.1 315 316Inspired by: http://dribbble.com/shots/631074-Simple-Pie-Charts-II?list=popular&offset=210 317Thanks to Philip Thrasher for the jquery plugin boilerplate for coffee script 318*/ 319 320 321(function() { 322 323 (function($) { 324 $.easyPieChart = function(el, options) { 325 var addScaleLine, animateLine, drawLine, easeInOutQuad, renderBackground, renderScale, renderTrack, 326 _this = this; 327 this.el = el; 328 this.$el = $(el); 329 this.$el.data("easyPieChart", this); 330 this.init = function() { 331 var percent; 332 _this.options = $.extend({}, $.easyPieChart.defaultOptions, options); 333 percent = parseInt(_this.$el.data('percent'), 10); 334 _this.percentage = 0; 335 _this.canvas = $("<canvas width='" + _this.options.size + "' height='" + _this.options.size + "'></canvas>").get(0); 336 _this.$el.append(_this.canvas); 337 if (typeof G_vmlCanvasManager !== "undefined" && G_vmlCanvasManager !== null) { 338 G_vmlCanvasManager.initElement(_this.canvas); 339 } 340 _this.ctx = _this.canvas.getContext('2d'); 341 if (window.devicePixelRatio > 1.5) { 342 $(_this.canvas).css({ 343 width: _this.options.size, 344 height: _this.options.size 345 }); 346 _this.canvas.width *= 2; 347 _this.canvas.height *= 2; 348 _this.ctx.scale(2, 2); 349 } 350 _this.ctx.translate(_this.options.size / 2, _this.options.size / 2); 351 _this.$el.addClass('easyPieChart'); 352 _this.$el.css({ 353 width: _this.options.size, 354 height: _this.options.size, 355 lineHeight: "" + _this.options.size + "px" 356 }); 357 _this.update(percent); 358 return _this; 359 }; 360 this.update = function(percent) { 361 if (_this.options.animate === false) { 362 return drawLine(percent); 363 } else { 364 return animateLine(_this.percentage, percent); 365 } 366 }; 367 renderScale = function() { 368 var i, _i, _results; 369 _this.ctx.fillStyle = _this.options.scaleColor; 370 _this.ctx.lineWidth = 1; 371 _results = []; 372 for (i = _i = 0; _i <= 24; i = ++_i) { 373 _results.push(addScaleLine(i)); 374 } 375 return _results; 376 }; 377 addScaleLine = function(i) { 378 var offset; 379 offset = i % 6 === 0 ? 0 : _this.options.size * 0.017; 380 _this.ctx.save(); 381 _this.ctx.rotate(i * Math.PI / 12); 382 _this.ctx.fillRect(_this.options.size / 2 - offset, 0, -_this.options.size * 0.05 + offset, 1); 383 return _this.ctx.restore(); 384 }; 385 renderTrack = function() { 386 var offset; 387 offset = _this.options.size / 2 - _this.options.lineWidth / 2; 388 if (_this.options.scaleColor !== false) { 389 offset -= _this.options.size * 0.08; 390 } 391 _this.ctx.beginPath(); 392 _this.ctx.arc(0, 0, offset, 0, Math.PI * 2, true); 393 _this.ctx.closePath(); 394 _this.ctx.strokeStyle = _this.options.trackColor; 395 _this.ctx.lineWidth = _this.options.lineWidth; 396 return _this.ctx.stroke(); 397 }; 398 renderBackground = function() { 399 if (_this.options.scaleColor !== false) { 400 renderScale(); 401 } 402 if (_this.options.trackColor !== false) { 403 return renderTrack(); 404 } 405 }; 406 drawLine = function(percent) { 407 var offset; 408 renderBackground(); 409 _this.ctx.strokeStyle = $.isFunction(_this.options.barColor) ? _this.options.barColor(percent) : _this.options.barColor; 410 _this.ctx.lineCap = _this.options.lineCap; 411 _this.ctx.lineWidth = _this.options.lineWidth; 412 offset = _this.options.size / 2 - _this.options.lineWidth / 2; 413 if (_this.options.scaleColor !== false) { 414 offset -= _this.options.size * 0.08; 415 } 416 _this.ctx.save(); 417 _this.ctx.rotate(-Math.PI / 2); 418 _this.ctx.beginPath(); 419 _this.ctx.arc(0, 0, offset, 0, Math.PI * 2 * percent / 100, false); 420 _this.ctx.stroke();
421 return _this.ctx.restore(); 422 }; 423 animateLine = function(from, to) { 424 var currentStep, fps, steps; 425 fps = 30; 426 steps = fps * _this.options.animate / 1000; 427 currentStep = 0; 428 _this.options.onStart.call(_this); 429 _this.percentage = to; 430 if (_this.animation) { 431 clearInterval(_this.animation); 432 _this.animation = false; 433 } 434 return _this.animation = setInterval(function() { 435 _this.ctx.clearRect(-_this.options.size / 2, -_this.options.size / 2, _this.options.size, _this.options.size); 436 renderBackground.call(_this); 437 drawLine.call(_this, [easeInOutQuad(currentStep, from, to - from, steps)]); 438 currentStep++; 439 if ((currentStep / steps) > 1) { 440 clearInterval(_this.animation); 441 _this.animation = false; 442 return _this.options.onStop.call(_this); 443 } 444 }, 1000 / fps); 445 }; 446 easeInOutQuad = function(t, b, c, d) { 447 var easeIn, easing; 448 easeIn = function(t) { 449 return Math.pow(t, 2); 450 }; 451 easing = function(t) { 452 if (t < 1) { 453 return easeIn(t); 454 } else { 455 return 2 - easeIn((t / 2) * -2 + 2); 456 } 457 }; 458 t /= d / 2; 459 return c / 2 * easing(t) + b; 460 }; 461 return this.init(); 462 }; 463 $.easyPieChart.defaultOptions = { 464 barColor: '#ef1e25', 465 trackColor: '#f2f2f2', 466 scaleColor: '#dfe0e0', 467 lineCap: 'round', 468 size: 110, 469 lineWidth: 3, 470 animate: false, 471 onStart: $.noop, 472 onStop: $.noop 473 }; 474 $.fn.easyPieChart = function(options) { 475 return $.each(this, function(i, el) { 476 var $el; 477 $el = $(el); 478 if (!$el.data('easyPieChart')) { 479 return $el.data('easyPieChart', new $.easyPieChart(el, options)); 480 } 481 }); 482 }; 483 return void 0; 484 })(jQuery); 485 486}).call(this); 487 488 489/*--------------------------------------------------------*/ 490/* Hover intent /* 491/*--------------------------------------------------------*/ 492 493/*! 494 * hoverIntent r7 // 2013.03.11 // jQuery 1.9.1+ 495 * http://cherne.net/brian/resources/jquery.hoverIntent.html 496 * 497 * You may use hoverIntent under the terms of the MIT license. 498 * Copyright 2007, 2013 Brian Cherne 499 */ 500(function(e){e.fn.hoverIntent=function(t,n,r){var i={interval:100,sensitivity:7,timeout:0};if(typeof t==="object"){i=e.extend(i,t)}else if(e.isFunction(n)){i=e.extend(i,{over:t,out:n,selector:r})}else{i=e.extend(i,{over:t,out:t,selector:n})}var s,o,u,a;var f=function(e){s=e.pageX;o=e.pageY};var l=function(t,n){n.hoverIntent_t=clearTimeout(n.hoverIntent_t);if(Math.abs(u-s)+Math.abs(a-o)<i.sensitivity){e(n).off("mousemove.hoverIntent",f);n.hoverIntent_s=1;return i.over.apply(n,[t])}else{u=s;a=o;n.hoverIntent_t=setTimeout(function(){l(t,n)},i.interval)}};var c=function(e,t){t.hoverIntent_t=clearTimeout(t.hoverIntent_t);t.hoverIntent_s=0;return i.out.apply(t,[e])};var h=function(t){var n=jQuery.extend({},t);var r=this;if(r.hoverIntent_t){r.hoverIntent_t=clearTimeout(r.hoverIntent_t)}if(t.type=="mouseenter"){u=n.pageX;a=n.pageY;e(r).on("mousemove.hoverIntent",f);if(r.hoverIntent_s!=1){r.hoverIntent_t=setTimeout(function(){l(n,r)},i.interval)}}else{e(r).off("mousemove.hoverIntent",f);if(r.hoverIntent_s==1){r.hoverIntent_t=setTimeout(function(){c(n,r)},i.timeout)}}};return this.on({"mouseenter.hoverIntent":h,"mouseleave.hoverIntent":h},i.selector)}})(jQuery) 501 502 503/* =========================================================== 504 * bootstrap-tooltip.js v2.3.2 505 * http://getbootstrap.com/2.3.2/javascript.html#tooltips 506 * Inspired by the original jQuery.tipsy by Jason Frame 507 * =========================================================== 508 * Copyright 2013 Twitter, Inc. 509 * 510 * Licensed under the Apache License, Version 2.0 (the "License"); 511 * you may not use this file except in compliance with the License. 512 * You may obtain a copy of the License at 513 * 514 * http://www.apache.org/licenses/LICENSE-2.0 515 * 516 * Unless required by applicable law or agreed to in writing, softw
516are 517 * distributed under the License is distributed on an "AS IS" BASIS, 518 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 519 * See the License for the specific language governing permissions and 520 * limitations under the License. 521 * ========================================================== */ 522 523 524!function ($) { 525 526 "use strict"; // jshint ;_; 527 528 529 /* TOOLTIP PUBLIC CLASS DEFINITION 530 * =============================== */ 531 532 var Tooltip = function (element, options) { 533 this.init('tooltip', element, options) 534 } 535 536 Tooltip.prototype = { 537 538 constructor: Tooltip 539 540 , init: function (type, element, options) { 541 var eventIn 542 , eventOut 543 , triggers 544 , trigger 545 , i 546 547 this.type = type 548 this.$element = $(element) 549 this.options = this.getOptions(options) 550 this.enabled = true 551 552 triggers = this.options.trigger.split(' ') 553 554 for (i = triggers.length; i--;) { 555 trigger = triggers[i] 556 if (trigger == 'click') { 557 this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this)) 558 } else if (trigger != 'manual') { 559 eventIn = trigger == 'hover' ? 'mouseenter' : 'focus' 560 eventOut = trigger == 'hover' ? 'mouseleave' : 'blur' 561 this.$element.on(eventIn + '.' + this.type, this.options.selector, $.proxy(this.enter, this)) 562 this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this)) 563 } 564 } 565 566 this.options.selector ? 567 (this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) : 568 this.fixTitle() 569 } 570 571 , getOptions: function (options) { 572 options = $.extend({}, $.fn[this.type].defaults, this.$element.data(), options) 573 574 if (options.delay && typeof options.delay == 'number') { 575 options.delay = { 576 show: options.delay 577 , hide: options.delay 578 } 579 } 580 581 return options 582 } 583 584 , enter: function (e) { 585 var defaults = $.fn[this.type].defaults 586 , options = {} 587 , self 588 589 this._options && $.each(this._options, function (key, value) { 590 if (defaults[key] != value) options[key] = value 591 }, this) 592 593 self = $(e.currentTarget)[this.type](options).data(this.type) 594 595 if (!self.options.delay || !self.options.delay.show) return self.show() 596 597 clearTimeout(this.timeout) 598 self.hoverState = 'in' 599 this.timeout = setTimeout(function() { 600 if (self.hoverState == 'in') self.show() 601 }, self.options.delay.show) 602 } 603 604 , leave: function (e) { 605 var self = $(e.currentTarget)[this.type](this._options).data(this.type) 606 607 if (this.timeout) clearTimeout(this.timeout) 608 if (!self.options.delay || !self.options.delay.hide) return self.hide() 609 610 self.hoverState = 'out' 611 this.timeout = setTimeout(function() { 612 if (self.hoverState == 'out') self.hide() 613 }, self.options.delay.hide) 614 } 615 616 , show: function () { 617 var $tip 618 , pos 619 , actualWidth 620 , actualHeight 621 , placement 622 , tp 623 , e = $.Event('show') 624 625 if (this.hasContent() && this.enabled) { 626 this.$element.trigger(e) 627 if (e.isDefaultPrevented()) return 628 $tip = this.tip() 629 this.setContent() 630 631 if (this.options.animation) { 632 $tip.addClass('fade') 633 } 634 635 placement = typeof this.options.placement == 'function' ? 636 this.options.placement.call(this, $tip[0], this.$element[0]) : 637 this.options.placement 638 639 $tip 640 .detach() 641 .css({ top: 0, left: 0, display: 'block' }) 642 643 this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element) 644 645 pos = this.getPosition() 646 647 actualWidth = $tip[0].offsetWidth 648 actualHeight = $tip[0].offsetHeight 649 650 switch (placement) { 651 case 'bottom': 652 tp = {top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2} 653 break 654 case 'top': 655 tp = {top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2} 656 break 657 case 'left': 658 tp = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth} 659 break 660 case 'right': 661 tp = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width} 662 break 663 } 664 665 this.applyPlacement(tp, placement) 666 this.$element.trigger('shown') 667 } 668 } 669 670 , applyPlacement: function(offset, placement){ 671 var $tip = this.tip() 672 , width = $tip[0].offsetWidth 673 , height = $tip[0].offsetHeight 674 , actualWidth 675 , actualHeight 676 , delta 677 , replace 678 679 $tip 680 .offset(offset) 681 .addClass(placement) 682 .addClass('in') 683 684 actualWidth = $tip[0].offsetWidth 685 actualHeight = $tip[0].offsetHeight 686 687 if (placement == 'top' && actualHeight != height) { 688 offset.top = offset.top + height - actualHeight 689 replace = true 690 } 691 692 if (placement == 'bottom' || placement == 'top') { 693 delta = 0 694 695 if (offset.left < 0){ 696 delta = offset.left * -2 697 offset.left = 0 698 $tip.offset(offset) 699 actualWidth = $tip[0].offsetWidth 700 actualHeight = $tip[0].offsetHeight 701 } 702 703 this.replaceArrow(delta - width + actualWidth, actualWidth, 'left') 704 } else { 705 this.replaceArrow(actualHeight - height, actualHeight, 'top') 706 } 707 708 if (replace) $tip.offset(offset) 709 } 710 711 , replaceArrow: function(delta, dimension, position){ 712 this 713 .arrow() 714 .css(position, delta ? (50 * (1 - delta / dimension) + "%") : '') 715 } 716 717 , setContent: function () { 718 var $tip = this.tip() 719 , title = this.getTitle() 720 721 $tip.find('.tooltip-inner')[this.options.html ? 'html' : 'text'](title) 722 $tip.removeClass('fade in top bottom left right') 723 } 724 725 , hide: function () { 726 var that = this 727 , $tip = this.tip() 728 , e = $.Event('hide') 729 730 this.$element.trigger(e) 731 if (e.isDefaultPrevented()) return 732 733 $tip.removeClass('in') 734 735 function removeWithAnimation() { 736 var timeout = setTimeout(function () {
737 $tip.off($.support.transition.end).detach() 738 }, 500) 739 740 $tip.one($.support.transition.end, function () { 741 clearTimeout(timeout) 742 $tip.detach() 743 }) 744 } 745 746 $.support.transition && this.$tip.hasClass('fade') ? 747 removeWithAnimation() : 748 $tip.detach() 749 750 this.$element.trigger('hidden') 751 752 return this 753 } 754 755 , fixTitle: function () { 756 var $e = this.$element 757 if ($e.attr('title') || typeof($e.attr('data-original-title')) != 'string') { 758 $e.attr('data-original-title', $e.attr('title') || '').attr('title', '') 759 } 760 } 761 762 , hasContent: function () { 763 return this.getTitle() 764 } 765 766 , getPosition: function () { 767 var el = this.$element[0] 768 return $.extend({}, (typeof el.getBoundingClientRect == 'function') ? el.getBoundingClientRect() : { 769 width: el.offsetWidth 770 , height: el.offsetHeight 771 }, this.$element.offset()) 772 } 773 774 , getTitle: function () { 775 776 var title 777 , $e = this.$element 778 , o = this.options 779 780 title = $e.attr('data-original-title') 781 || (typeof o.title == 'function' ? o.title.call($e[0]) : o.title) 782 783 return title 784 } 785 786 , tip: function () { 787 return this.$tip = this.$tip || $(this.options.template) 788 } 789 790 , arrow: function(){ 791 return this.$arrow = this.$arrow || this.tip().find(".tooltip-arrow") 792 } 793 794 , validate: function () { 795 if (!this.$element[0].parentNode) { 796 this.hide() 797 this.$element = null 798 this.options = null 799 } 800 } 801 802 , enable: function () { 803 this.enabled = true 804 } 805 806 , disable: function () { 807 this.enabled = false 808 } 809 810 , toggleEnabled: function () { 811 this.enabled = !this.enabled 812 } 813 814 , toggle: function (e) { 815 var self = e ? $(e.currentTarget)[this.type](this._options).data(this.type) : this 816 self.tip().hasClass('in') ? self.hide() : self.show() 817 } 818 819 , destroy: function () { 820 this.hide().$element.off('.' + this.type).removeData(this.type) 821 } 822 823 } 824 825 826 /* TOOLTIP PLUGIN DEFINITION 827 * ========================= */ 828 829 var old = $.fn.tooltip 830 831 $.fn.tooltip = function ( option ) { 832 return this.each(function () { 833 var $this = $(this) 834 , data = $this.data('tooltip') 835 , options = typeof option == 'object' && option 836 if (!data) $this.data('tooltip', (data = new Tooltip(this, options))) 837 if (typeof option == 'string') data[option]() 838 }) 839 } 840 841 $.fn.tooltip.Constructor = Tooltip 842 843 $.fn.tooltip.defaults = { 844 animation: true 845 , placement: 'top' 846 , selector: false 847 , template: '<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>' 848 , trigger: 'hover focus' 849 , title: '' 850 , delay: 0 851 , html: false 852 , container: false 853 } 854 855 856 /* TOOLTIP NO CONFLICT 857 * =================== */ 858 859 $.fn.tooltip.noConflict = function () { 860 $.fn.tooltip = old 861 return this 862 } 863 864}(window.jQuery); 865 866 867/*----------------------------------------------------*/ 868/* EQUALHEIGHTS PLUGIN 869/*----------------------------------------------------*/ 870 871(function($) { 872 873 // USE STRICT 874 "use strict"; 875 876 $.fn.equalHeights = function(px) { 877 878 $(this).each(function(){ 879 880 var currentTallest = 0; 881 $(this).children().each(function(){ 882 if ($(this).height() > currentTallest) { currentTallest = $(this).height(); } 883 884 }); 885 if (!px && Number.prototype.pxToEm) { 886 currentTallest = currentTallest.pxToEm(); //use ems unless px is specified 887 } 888 // for ie6, set height since min-height isn't supported 889 if ($.browser.msie && $.browser.version === 6.0) { 890 (this).children().css({'height': currentTallest}); 891 } 892 $(this).children().css({'min-height': currentTallest}); 893 }); 894 return this; 895 }; 896})(jQuery); 897 898 899/*--------------------------------------------------*/ 900/* Fitvids 901/*--------------------------------------------------*/ 902 903/*global jQuery */ 904/*! 905* FitVids 1.0 906*
907* Copyright 2011, Chris Coyier - http://css-tricks.com + Dave Rupert - http://daverupert.com 908* Credit to Thierry Koblentz - http://www.alistapart.com/articles/creating-intrinsic-ratios-for-video/ 909* Released under the WTFPL license - http://sam.zoy.org/wtfpl/ 910* 911* Date: Thu Sept 01 18:00:00 2011 -0500 912*/ 913 914(function( $ ){ 915 916 $.fn.fitVids = function( options ) { 917 var settings = { 918 customSelector: null 919 } 920 921 var div = document.createElement('div'), 922 ref = document.getElementsByTagName('base')[0] || document.getElementsByTagName('script')[0]; 923 924 div.className = 'fit-vids-style'; 925 div.innerHTML = '­<style> \ 926 .fluid-width-video-wrapper { \ 927 width: 100%; \ 928 position: relative; \ 929 padding: 0; \ 930 } \ 931 \ 932 .fluid-width-video-wrapper iframe, \ 933 .fluid-width-video-wrapper object, \ 934 .fluid-width-video-wrapper embed { \ 935 position: absolute; \ 936 top: 0; \ 937 left: 0; \ 938 width: 100%; \ 939 height: 100%; \ 940 } \ 941 </style>'; 942 943 ref.parentNode.insertBefore(div,ref); 944 945 if ( options ) { 946 $.extend( settings, options ); 947 } 948 949 return this.each(function(){ 950 var selectors = [ 951 "iframe[src*='player.vimeo.com']", 952 "iframe[src*='www.youtube.com']", 953 "iframe[src*='www.kickstarter.com']", 954 "object", 955 "embed" 956 ]; 957 958 if (settings.customSelector) { 959 selectors.push(settings.customSelector); 960 } 961 962 var $allVideos = $(this).find(selectors.join(',')); 963 964 $allVideos.each(function(){ 965 var $this = $(this); 966 if (this.tagName.toLowerCase() == 'embed' && $this.parent('object').length || $this.parent('.fluid-width-video-wrapper').length) { return; } 967 var height = this.tagName.toLowerCase() == 'object' ? $this.attr('height') : $this.height(), 968 aspectRatio = height / $this.width(); 969 if(!$this.attr('id')){ 970 var videoID = 'fitvid' + Math.floor(Math.random()*999999); 971 $this.attr('id', videoID); 972 } 973 $this.wrap('<div class="fluid-width-video-wrapper"></div>').parent('.fluid-width-video-wrapper').css('padding-top', (aspectRatio * 100)+"%"); 974 $this.removeAttr('height').removeAttr('width'); 975 }); 976 }); 977 978 } 979})( jQuery ); 980 981/*! 982 * imagesLoaded PACKAGED v3.1.4 983 * JavaScript is all like "You images are done yet or what?" 984 * MIT License 985 */ 986 987(function(){function e(){}function t(e,t){for(var n=e.length;n--;)if(e[n].listener===t)return n;return-1}function n(e){return function(){return this[e].apply(this,arguments)}}var i=e.prototype,r=this,o=r.EventEmitter;i.getListeners=function(e){var t,n,i=this._getEvents();if("object"==typeof e){t={};for(n in i)i.hasOwnProperty(n)&&e.test(n)&&(t[n]=i[n])}else t=i[e]||(i[e]=[]);return t},i.flattenListeners=function(e){var t,n=[];for(t=0;e.length>t;t+=1)n.push(e[t].listener);return n},i.getListenersAsObject=function(e){var t,n=this.getListeners(e);return n instanceof Array&&(t={},t[e]=n),t||n},i.addListener=function(e,n){var i,r=this.getListenersAsObject(e),o="object"==typeof n;for(i in r)r.hasOwnProperty(i)&&-1===t(r[i],n)&&r[i].push(o?n:{listener:n,once:!1});return this},i.on=n("addListener"),i.addOnceListener=function(e,t){return this.addListener(e,{listener:t,once:!0})},i.once=n("addOnceListener"),i.defineEvent=function(e){return this.getListeners(e),this},i.defineEvents=function(e){for(var t=0;e.length>t;t+=1)this.defineEvent(e[t]);return this},i.removeListener=function(e,n){var i,r,o=this.getListenersAsObject(e);for(r in o)o.hasOwnProperty(r)&&(i=t(o[r],n),-1!==i&&o[r].splice(i,1));return this},i.off=n("removeListener"),i.addListeners=function(e,t){return this.manipulateListeners(!1,e,t)},i.removeListeners=function(e,t){return this.manipulateListeners(!0,e,t)},i.manipulateListeners=function(e,t,n){var i,r,o=e?this.removeListener:this.addListener,s=e?this.removeListeners:this.addListeners;if("object"!=typeof t||t instanceof RegExp)for(i=n.length;i--;)o.call(this,t,n[i]);else for(i in t)t.hasOwnProperty(i)&&(r=t[i])&&("function"==typeof r?o.call(this,i,r):s.call(this,i,r));return this},i.removeEvent=function(e){var t,n=typeof e,i=this._getEvents();if("string"===n)delete i[e];else if("object"===n)for(t in i)i.hasOwnProperty(t)&&e.test(t)&&delete i[t];else delete this._events;return this},i.removeAllListeners=n("removeEvent"),i.emitEvent=function(e,t){var n,i,r,o,s=this.getListenersAsObject(e);for(r in s)if(s.hasOwnProperty(r))for(i=s[r].length;i--;)n=s[r][i],n.once===!0&&this.removeListener(e,n.listener),o=n.listener.apply(this,t||[]),o===this._getOnceReturnValue()&&this.removeListener(e,n.listener);return this},i.trigger=n("emitEvent"),i.emit=function(e){var t=Array.prototype.slice.call(arguments,1
987);return this.emitEvent(e,t)},i.setOnceReturnValue=function(e){return this._onceReturnValue=e,this},i._getOnceReturnValue=function(){return this.hasOwnProperty("_onceReturnValue")?this._onceReturnValue:!0},i._getEvents=function(){return this._events||(this._events={})},e.noConflict=function(){return r.EventEmitter=o,e},"function"==typeof define&&define.amd?define("eventEmitter/EventEmitter",[],function(){return e}):"object"==typeof module&&module.exports?module.exports=e:this.EventEmitter=e}).call(this),function(e){function t(t){var n=e.event;return n.target=n.target||n.srcElement||t,n}var n=document.documentElement,i=function(){};n.addEventListener?i=function(e,t,n){e.addEventListener(t,n,!1)}:n.attachEvent&&(i=function(e,n,i){e[n+i]=i.handleEvent?function(){var n=t(e);i.handleEvent.call(i,n)}:function(){var n=t(e);i.call(e,n)},e.attachEvent("on"+n,e[n+i])});var r=function(){};n.removeEventListener?r=function(e,t,n){e.removeEventListener(t,n,!1)}:n.detachEvent&&(r=function(e,t,n){e.detachEvent("on"+t,e[t+n]);try{delete e[t+n]}catch(i){e[t+n]=void 0}});var o={bind:i,unbind:r};"function"==typeof define&&define.amd?define("eventie/eventie",o):e.eventie=o}(this),function(e,t){"function"==typeof define&&define.amd?define(["eventEmitter/EventEmitter","eventie/eventie"],function(n,i){return t(e,n,i)}):"object"==typeof exports?module.exports=t(e,require("eventEmitter"),require("eventie")):e.imagesLoaded=t(e,e.EventEmitter,e.eventie)}(this,function(e,t,n){function i(e,t){for(var n in t)e[n]=t[n];return e}function r(e){return"[object Array]"===d.call(e)}function o(e){var t=[];if(r(e))t=e;else if("number"==typeof e.length)for(var n=0,i=e.length;i>n;n++)t.push(e[n]);else t.push(e);return t}function s(e,t,n){if(!(this instanceof s))return new s(e,t);"string"==typeof e&&(e=document.querySelectorAll(e)),this.elements=o(e),this.options=i({},this.options),"function"==typeof t?n=t:i(this.options,t),n&&this.on("always",n),this.getImages(),a&&(this.jqDeferred=new a.Deferred);var r=this;setTimeout(function(){r.check()})}function c(e){this.img=e}function f(e){this.src=e,v[e]=this}var a=e.jQuery,u=e.console,h=u!==void 0,d=Object.prototype.toString;s.prototype=new t,s.prototype.options={},s.prototype.getImages=function(){this.images=[];for(var e=0,t=this.elements.length;t>e;e++){var n=this.elements[e];"IMG"===n.nodeName&&this.addImage(n);for(var i=n.querySelectorAll("img"),r=0,o=i.length;o>r;r++){var s=i[r];this.addImage(s)}}},s.prototype.addImage=function(e){var t=new c(e);this.images.push(t)},s.prototype.check=function(){function e(e,r){return t.options.debug&&h&&u.log("confirm",e,r),t.progress(e),n++,n===i&&t.complete(),!0}var t=this,n=0,i=this.images.length;if(this.hasAnyBroken=!1,!i)return this.complete(),void 0;for(var r=0;i>r;r++){var o=this.images[r];o.on("confirm",e),o.check()}},s.prototype.progress=function(e){this.hasAnyBroken=this.hasAnyBroken||!e.isLoaded;var t=this;setTimeout(function(){t.emit("progress",t,e),t.jqDeferred&&t.jqDeferred.notify&&t.jqDeferred.notify(t,e)})},s.prototype.complete=function(){var e=this.hasAnyBroken?"fail":"done";this.isComplete=!0;var t=this;setTimeout(function(){if(t.emit(e,t),t.emit("always",t),t.jqDeferred){var n=t.hasAnyBroken?"reject":"resolve";t.jqDeferred[n](t)}})},a&&(a.fn.imagesLoaded=function(e,t){var n=new s(this,e,t);return n.jqDeferred.promise(a(this))}),c.prototype=new t,c.prototype.check=function(){var e=v[this.img.src]||new f(this.img.src);if(e.isConfirmed)return this.confirm(e.isLoaded,"cached was confirmed"),void 0;if(this.img.complete&&void 0!==this.img.naturalWidth)return this.confirm(0!==this.img.naturalWidth,"naturalWidth"),void 0;var t=this;e.on("confirm",function(e,n){return t.confirm(e.isLoaded,n),!0}),e.check()},c.prototype.confirm=function(e,t){this.isLoaded=e,this.emit("confirm",this,t)};var v={};return f.prototype=new t,f.prototype.check=function(){if(!this.isChecked){var e=new Image;n.bind(e,"load",this),n.bind(e,"error",this),e.src=this.src,this.isChecked=!0}},f.prototype.handleEvent=function(e){var t="on"+e.type;this[t]&&this[t](e)},f.prototype.onload=function(e){this.confirm(!0,"onload"),this.unbindProxyEvents(e)},f.prototype.onerror=function(e){this.confirm(!1,"onerror"),this.unbindProxyEvents(e)},f.prototype.confirm=function(e,t){this.isConfirmed=!0,this.isLoaded=e,this.emit
vendor: 5,154 bytes, lines 987-1053
987("confirm",this,t)},f.prototype.unbindProxyEvents=function(e){n.unbind(e.target,"load",this),n.unbind(e.target,"error",this)},s}); 988 989 990/*------------------------------------------*/ 991/* Debounce resize 992/*-------------------------------------------*/ 993/* 994 * debouncedresize: special jQuery event that happens once after a window resize 995 * 996 * latest version and complete README available on Github: 997 * https://github.com/louisremi/jquery-smartresize 998 * 999 * Copyright 2012 @louis_remi 1000 * Licensed under the MIT license. 1001 * 1002 * This saved you an hour of work? 1003 * Send me music http://www.amazon.co.uk/wishlist/HNTU0468LQON 1004 */ 1005(function($) { 1006 1007var $event = $.event, 1008 $special, 1009 resizeTimeout; 1010 1011$special = $event.special.debouncedresize = { 1012 setup: function() { 1013 $( this ).on( "resize", $special.handler ); 1014 }, 1015 teardown: function() { 1016 $( this ).off( "resize", $special.handler ); 1017 }, 1018 handler: function( event, execAsap ) { 1019 // Save the context 1020 var context = this, 1021 args = arguments, 1022 dispatch = function() { 1023 // set correct event type 1024 event.type = "debouncedresize"; 1025 $event.dispatch.apply( context, args ); 1026 }; 1027 1028 if ( resizeTimeout ) { 1029 clearTimeout( resizeTimeout ); 1030 } 1031 1032 execAsap ? 1033 dispatch() : 1034 resizeTimeout = setTimeout( dispatch, $special.threshold ); 1035 }, 1036 threshold: 150 1037}; 1038 1039})(jQuery); 1040 1041 1042/*-------------------------------------------*/ 1043/* Jquery Easing 1044/*-------------------------------------------*/ 1045 1046/* 1047* jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ 1048* 1049* Uses the built in easing capabilities added In jQuery 1.1 1050* to offer multiple easing options 1051*/ 1052 1053jQuery.easing["jswing"]=jQuery.easing["swing"];jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(a,b,c,d,e){return jQuery.easing[jQuery.easing.def](a,b,c,d,e)},easeInQuad:function(a,b,c,d,e){return d*(b/=e)*b+c},easeOutQuad:function(a,b,c,d,e){return-d*(b/=e)*(b-2)+c},easeInOutQuad:function(a,b,c,d,e){if((b/=e/2)<1)return d/2*b*b+c;return-d/2*(--b*(b-2)-1)+c},easeInCubic:function(a,b,c,d,e){return d*(b/=e)*b*b+c},easeOutCubic:function(a,b,c,d,e){return d*((b=b/e-1)*b*b+1)+c},easeInOutCubic:function(a,b,c,d,e){if((b/=e/2)<1)return d/2*b*b*b+c;return d/2*((b-=2)*b*b+2)+c},easeInQuart:function(a,b,c,d,e){return d*(b/=e)*b*b*b+c},easeOutQuart:function(a,b,c,d,e){return-d*((b=b/e-1)*b*b*b-1)+c},easeInOutQuart:function(a,b,c,d,e){if((b/=e/2)<1)return d/2*b*b*b*b+c;return-d/2*((b-=2)*b*b*b-2)+c},easeInQuint:function(a,b,c,d,e){return d*(b/=e)*b*b*b*b+c},easeOutQuint:function(a,b,c,d,e){return d*((b=b/e-1)*b*b*b*b+1)+c},easeInOutQuint:function(a,b,c,d,e){if((b/=e/2)<1)return d/2*b*b*b*b*b+c;return d/2*((b-=2)*b*b*b*b+2)+c},easeInSine:function(a,b,c,d,e){return-d*Math.cos(b/e*(Math.PI/2))+d+c},easeOutSine:function(a,b,c,d,e){return d*Math.sin(b/e*(Math.PI/2))+c},easeInOutSine:function(a,b,c,d,e){return-d/2*(Math.cos(Math.PI*b/e)-1)+c},easeInExpo:function(a,b,c,d,e){return b==0?c:d*Math.pow(2,10*(b/e-1))+c},easeOutExpo:function(a,b,c,d,e){return b==e?c+d:d*(-Math.pow(2,-10*b/e)+1)+c},easeInOutExpo:function(a,b,c,d,e){if(b==0)return c;if(b==e)return c+d;if((b/=e/2)<1)return d/2*Math.pow(2,10*(b-1))+c;return d/2*(-Math.pow(2,-10*--b)+2)+c},easeInCirc:function(a,b,c,d,e){return-d*(Math.sqrt(1-(b/=e)*b)-1)+c},easeOutCirc:function(a,b,c,d,e){return d*Math.sqrt(1-(b=b/e-1)*b)+c},easeInOutCirc:function(a,b,c,d,e){if((b/=e/2)<1)return-d/2*(Math.sqrt(1-b*b)-1)+c;return d/2*(Math.sqrt(1-(b-=2)*b)+1)+c},easeInElastic:function(a,b,c,d,e){var f=1.70158;var g=0;var h=d;if(b==0)return c;if((b/=e)==1)return c+d;if(!g)g=e*.3;if(h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);return-(h*Math.pow(2,10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g))+c},easeOutElastic:function(a,b,c,d,e){var f=1.70158;var g=0;var h=d;if(b==0)return c;if((b/=e)==1)return c+d;if(!g)g=e*.3;if(h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);return h*Math.pow(2,-10*b)*Math.sin((b*e-f)*2*Math.PI/g)+d+c},easeInOutElastic:function(a,b,c,d,e){var f=1.70158;var g=0;var h=d;if(b==0)return c;if((b/=e/2)==2)return c+d;if(!g)g=e*.3*1.5;if(h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);if(b<1)return-.5*h*Math.pow(2,10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g)+c;return h*Math.pow(2,-10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g)*.5+d+c},easeInBack:function(a,b,c,d,e,f){if(f==undefined)f=1.70158;return d*(b/=e)*b*((f+1)*b-f)+c},easeOutBack:function(a,b,c,d,e,f){if(f==undefined)f=1.70158;return d*((b=b/e-1)*b*((f+1)*b+f)+1)+c},easeInOutBack:function(a,b,c,d,e,f){if(f==undefined)f=1.70158;if((b/=e/2)<1)return d/2*b*b*(((f*=1.525)+1)*b-f)+c;return d/2*((b-=2)*b*(((f*=1.525)+1)*b+f)+2)+c},easeInBounce:function(a,b,c,d,e){return d-jQuery.easing.easeOutBounce(a,e-b,0,d,e)+c}
1053,easeOutBounce:function(a,b,c,d,e){if((b/=e)<1/2.75){return d*7.5625*b*b+c}else if(b<2/2.75){return d*(7.5625*(b-=1.5/2.75)*b+.75)+c}else if(b<2.5/2.75){return d*(7.5625*(b-=2.25/2.75)*b+.9375)+c}else{return d*(7.5625*(b-=2.625/2.75)*b+.984375)+c}},easeInOutBounce:function(a,b,c,d,e){if(b<e/2)return jQuery.easing.easeInBounce(a,b*2,0,d,e)*.5+c;return jQuery.easing.easeOutBounce(a,b*2-e,0,d,e)*.5+d*.5+c}}); 1054 1055 1056/*-------------------------------------------*/ 1057/* Jquery Tabset 1058/*-------------------------------------------*/ 1059 1060(function ($) {$.fn.tabset = function () { var $tabsets = $(this); $tabsets.each(function (i) { var $tabs = $('li.tab a', this); $tabs.click(function (e) { var $this = $(this); panels = $.map($tabs, function (val, i) { return $(val).attr('href');}); $(panels.join(',')).hide(); $tabs.removeClass('selected');$this.addClass('selected').blur(); $($this.attr('href')).show(); e.preventDefault(); return false; }).first().triggerHandler('click');});};})(jQuery);
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.