PageSourceSearch

https://nylive.org/_static/??-eJyFjMEOgyAQRH+oYDQN1UPTbzHbja7IirBI…2H2WxCYESyGO71UcVGWpIIf925Nb7p+eJnnD7odR6w=

js nylive.org collected 2026-10-04 21:39:00 UTC 113,423 bytes, 3,352 lines download raw bytes

1/*! jQuery Migrate v3.4.1 | (c) OpenJS Foundation and other contributors | jquery.org/license */
2"undefined"==typeof jQuery.migrateMute&&(jQuery.migrateMute=!0),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],function(e){return t(e,window)}):"object"==typeof module&&module.exports?module.exports=t(require("jquery"),window):t(jQuery,window)}(function(s,n){"use strict";function e(e){return 0<=function(e,t){for(var r=/^(\d+)\.(\d+)\.(\d+)/,n=r.exec(e)||[],o=r.exec(t)||[],a=1;a<=3;a++){if(+o[a]<+n[a])return 1;if(+n[a]<+o[a])return-1}return 0}(s.fn.jquery,e)}s.migrateVersion="3.4.1";var t=Object.create(null);s.migrateDisablePatches=function(){for(var e=0;e<arguments.length;e++)t[arguments[e]]=!0},s.migrateEnablePatches=function(){for(var e=0;e<arguments.length;e++)delete t[arguments[e]]},s.migrateIsPatchEnabled=function(e){return!t[e]},n.console&&n.console.log&&(s&&e("3.0.0")&&!e("5.0.0")||n.console.log("JQMIGRATE: jQuery 3.x-4.x REQUIRED"),s.migrateWarnings&&n.console.log("JQMIGRATE: Migrate plugin loaded multiple times"),n.console.log("JQMIGRATE: Migrate is installed"+(s.migrateMute?"":" with logging active")+", version "+s.migrateVersion));var o={};function u(e,t){var r=n.console;!s.migrateIsPatchEnabled(e)||s.migrateDeduplicateWarnings&&o[t]||(o[t]=!0,s.migrateWarnings.push(t+" ["+e+"]"),r&&r.warn&&!s.migrateMute&&(r.warn("JQMIGRATE: "+t),s.migrateTrace&&r.trace&&r.trace()))}function r(e,t,r,n,o){Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){return u(n,o),r},set:function(e){u(n,o),r=e}})}function a(e,t,r,n,o){var a=e[t];e[t]=function(){return o&&u(n,o),(s.migrateIsPatchEnabled(n)?r:a||s.noop).apply(this,arguments)}}function c(e,t,r,n,o){if(!o)throw new Error("No warning message provided");return a(e,t,r,n,o),0}function i(e,t,r,n){return a(e,t,r,n),0}s.migrateDeduplicateWarnings=!0,s.migrateWarnings=[],void 0===s.migrateTrace&&(s.migrateTrace=!0),s.migrateReset=function(){o={},s.migrateWarnings.length=0},"BackCompat"===n.document.compatMode&&u("quirks","jQuery is not compatible with Quirks Mode");var d,l,p,f={},m=s.fn.init,y=s.find,h=/\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/,g=/\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/g,v=/^[\s\uFEFF\xA0]+|([^\s\uFEFF\xA0])[\s\uFEFF\xA0]+$/g;for(d in i(s.fn,"init",function(e){var t=Array.prototype.slice.call(arguments);return s.migrateIsPatchEnabled("selector-empty-id")&&"string"==typeof e&&"#"===e&&(u("selector-empty-id","jQuery( '#' ) is not a valid selector"),t[0]=[]),m.apply(this,t)},"selector-empty-id"),s.fn.init.prototype=s.fn,i(s,"find",function(t){var r=Array.prototype.slice.call(arguments);if("string"==typeof t&&h.test(t))try{n.document.querySelector(t)}catch(e){t=t.replace(g,function(e,t,r,n){return"["+t+r+'"'+n+'"]'});try{n.document.querySelector(t),u("selector-hash","Attribute selector with '#' must be quoted: "+r[0]),r[0]=t}catch(e){u("selector-hash","Attribute selector with '#' was not fixed: "+r[0])}}return y.apply(this,r)},"selector-hash"),y)Object.prototype.hasOwnProperty.call(y,d)&&(s.find[d]=y[d]);c(s.fn,"size",function(){return this.length},"size","jQuery.fn.size() is deprecated and removed; use the .length property"),c(s,"parseJSON",function(){return JSON.parse.apply(null,arguments)},"parseJSON","jQuery.parseJSON is deprecated; use JSON.parse"),c(s,"holdReady",s.holdReady,"holdReady","jQuery.holdReady is deprecated"),c(s,"unique",s.uniqueSort,"unique","jQuery.unique is deprecated; use jQuery.uniqueSort"),r(s.expr,"filters",s.expr.pseudos,"expr-pre-pseudos","jQuery.expr.filters is deprecated; use jQuery.expr.pseudos"),r(s.expr,":",s.expr.pseudos,"expr-pre-pseudos","jQuery.expr[':'] is deprecated; use jQuery.expr.pseudos"),e("3.1.1")&&c(s,"trim",function(e){return null==e?"":(e+"").replace(v,"$1")},"trim","jQuery.trim is deprecated; use String.prototype.trim"),e("3.2.0")&&(c(s,"nodeName",function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},"nodeName","jQuery.nodeName is deprecated"),c(s,"isArray",Array.isArray,"isArray","jQuery.isArray is deprecated; use Array.isArray")),e("3.3.0")&&(c(s,"isNumeric",function(e){var t=typeof e;return("number"==t||"string"==t)&&!isNaN(e-parseFloat(e))},"isNumeric","jQuery.isNumeric() is deprecated"),s.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){f["[object "+t+"]"]=t.toLowerCase()}),c(s,"type",function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?f[Object.prototype.toString.call(e)]||"object":typeof e},"type","jQuery.type is deprecated"),c(s,"isFunction",function(e){return"function"==typeof e},"isFunction","jQuery.isFunction() is deprecated"),c(s,"isWindow",function(e){return null!=e&&e===e.window}
2,"isWindow","jQuery.isWindow() is deprecated")),s.ajax&&(l=s.ajax,p=/(=)\?(?=&|$)|\?\?/,i(s,"ajax",function(){var e=l.apply(this,arguments);return e.promise&&(c(e,"success",e.done,"jqXHR-methods","jQXHR.success is deprecated and removed"),c(e,"error",e.fail,"jqXHR-methods","jQXHR.error is deprecated and removed"),c(e,"complete",e.always,"jqXHR-methods","jQXHR.complete is deprecated and removed")),e},"jqXHR-methods"),e("4.0.0")||s.ajaxPrefilter("+json",function(e){!1!==e.jsonp&&(p.test(e.url)||"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&p.test(e.data))&&u("jsonp-promotion","JSON-to-JSONP auto-promotion is deprecated")}));var j=s.fn.removeAttr,b=s.fn.toggleClass,w=/\S+/g;function x(e){return e.replace(/-([a-z])/g,function(e,t){return t.toUpperCase()})}i(s.fn,"removeAttr",function(e){var r=this,n=!1;return s.each(e.match(w),function(e,t){s.expr.match.bool.test(t)&&r.each(function(){if(!1!==s(this).prop(t))return!(n=!0)}),n&&(u("removeAttr-bool","jQuery.fn.removeAttr no longer sets boolean properties: "+t),r.prop(t,!1))}),j.apply(this,arguments)},"removeAttr-bool"),i(s.fn,"toggleClass",function(t){return void 0!==t&&"boolean"!=typeof t?b.apply(this,arguments):(u("toggleClass-bool","jQuery.fn.toggleClass( boolean ) is deprecated"),this.each(function(){var e=this.getAttribute&&this.getAttribute("class")||"";e&&s.data(this,"__className__",e),this.setAttribute&&this.setAttribute("class",!e&&!1!==t&&s.data(this,"__className__")||"")}))},"toggleClass-bool");var Q,A,R=!1,C=/^[a-z]/,N=/^(?:Border(?:Top|Right|Bottom|Left)?(?:Width|)|(?:Margin|Padding)?(?:Top|Right|Bottom|Left)?|(?:Min|Max)?(?:Width|Height))$/;s.swap&&s.each(["height","width","reliableMarginRight"],function(e,t){var r=s.cssHooks[t]&&s.cssHooks[t].get;r&&(s.cssHooks[t].get=function(){var e;return R=!0,e=r.apply(this,arguments),R=!1,e})}),i(s,"swap",function(e,t,r,n){var o,a,i={};for(a in R||u("swap","jQuery.swap() is undocumented and deprecated"),t)i[a]=e.style[a],e.style[a]=t[a];for(a in o=r.apply(e,n||[]),t)e.style[a]=i[a];return o},"swap"),e("3.4.0")&&"undefined"!=typeof Proxy&&(s.cssProps=new Proxy(s.cssProps||{},{set:function(){return u("cssProps","jQuery.cssProps is deprecated"),Reflect.set.apply(this,arguments)}})),e("4.0.0")?(A={animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},"undefined"!=typeof Proxy?s.cssNumber=new Proxy(A,{get:function(){return u("css-number","jQuery.cssNumber is deprecated"),Reflect.get.apply(this,arguments)},set:function(){return u("css-number","jQuery.cssNumber is deprecated"),Reflect.set.apply(this,arguments)}}):s.cssNumber=A):A=s.cssNumber,Q=s.fn.css,i(s.fn,"css",function(e,t){var r,n,o=this;return e&&"object"==typeof e&&!Array.isArray(e)?(s.each(e,function(e,t){s.fn.css.call(o,e,t)}),this):("number"==typeof t&&(r=x(e),n=r,C.test(n)&&N.test(n[0].toUpperCase()+n.slice(1))||A[r]||u("css-number",'Number-typed values are deprecated for jQuery.fn.css( "'+e+'", value )')),Q.apply(this,arguments))},"css-number");var S,P,k,H,E=s.data;i(s,"data",function(e,t,r){var n,o,a;if(t&&"object"==typeof t&&2===arguments.length){for(a in n=s.hasData(e)&&E.call(this,e),o={},t)a!==x(a)?(u("data-camelCase","jQuery.data() always sets/gets camelCased names: "+a),n[a]=t[a]):o[a]=t[a];return E.call(this,e,o),t}return t&&"string"==typeof t&&t!==x(t)&&(n=s.hasData(e)&&E.call(this,e))&&t in n?(u("data-camelCase","jQuery.data() always sets/gets camelCased names: "+t),2<arguments.length&&(n[t]=r),n[t]):E.apply(this,arguments)},"data-camelCase"),s.fx&&(k=s.Tween.prototype.run,H=function(e){return e},i(s.Tween.prototype,"run",function(){1<s.easing[this.easing].length&&(u("easing-one-arg","'jQuery.easing."+this.easing.toString()+"' should use only one argument"),s.easing[this.easing]=H),k.apply(this,arguments)},"easing-one-arg"),S=s.fx.interval,P="jQuery.fx.interval is deprecated",n.requestAnimationFrame&&Object.defineProperty(s.fx,"interval",{configurable:!0,enumerable:!0,get:function(){return n.document.hidden||u("fx-interval",P),s.migrateIsPatchEnabled("fx-interval")&&void 0===S?13:S},set:function(e){u("fx-interval",P),S=e}}));var M=s.fn.load,q=s.event.add,O=s.event.fix;s.event.props=[],s.event.fixHooks={}
2,r(s.event.props,"concat",s.event.props.concat,"event-old-patch","jQuery.event.props.concat() is deprecated and removed"),i(s.event,"fix",function(e){var t,r=e.type,n=this.fixHooks[r],o=s.event.props;if(o.length){u("event-old-patch","jQuery.event.props are deprecated and removed: "+o.join());while(o.length)s.event.addProp(o.pop())}if(n&&!n._migrated_&&(n._migrated_=!0,u("event-old-patch","jQuery.event.fixHooks are deprecated and removed: "+r),(o=n.props)&&o.length))while(o.length)s.event.addProp(o.pop());return t=O.call(this,e),n&&n.filter?n.filter(t,e):t},"event-old-patch"),i(s.event,"add",function(e,t){return e===n&&"load"===t&&"complete"===n.document.readyState&&u("load-after-event","jQuery(window).on('load'...) called after load event occurred"),q.apply(this,arguments)},"load-after-event"),s.each(["load","unload","error"],function(e,t){i(s.fn,t,function(){var e=Array.prototype.slice.call(arguments,0);return"load"===t&&"string"==typeof e[0]?M.apply(this,e):(u("shorthand-removed-v3","jQuery.fn."+t+"() is deprecated"),e.splice(0,0,t),arguments.length?this.on.apply(this,e):(this.triggerHandler.apply(this,e),this))},"shorthand-removed-v3")}),s.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,r){c(s.fn,r,function(e,t){return 0<arguments.length?this.on(r,null,e,t):this.trigger(r)},"shorthand-deprecated-v3","jQuery.fn."+r+"() event shorthand is deprecated")}),s(function(){s(n.document).triggerHandler("ready")}),s.event.special.ready={setup:function(){this===n.document&&u("ready-event","'ready' event is deprecated")}},c(s.fn,"bind",function(e,t,r){return this.on(e,null,t,r)},"pre-on-methods","jQuery.fn.bind() is deprecated"),c(s.fn,"unbind",function(e,t){return this.off(e,null,t)},"pre-on-methods","jQuery.fn.unbind() is deprecated"),c(s.fn,"delegate",function(e,t,r,n){return this.on(t,e,r,n)},"pre-on-methods","jQuery.fn.delegate() is deprecated"),c(s.fn,"undelegate",function(e,t,r){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",r)},"pre-on-methods","jQuery.fn.undelegate() is deprecated"),c(s.fn,"hover",function(e,t){return this.on("mouseenter",e).on("mouseleave",t||e)},"pre-on-methods","jQuery.fn.hover() is deprecated");function T(e){var t=n.document.implementation.createHTMLDocument("");return t.body.innerHTML=e,t.body&&t.body.innerHTML}var F=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi;s.UNSAFE_restoreLegacyHtmlPrefilter=function(){s.migrateEnablePatches("self-closed-tags")},i(s,"htmlPrefilter",function(e){var t,r;return(r=(t=e).replace(F,"<$1></$2>"))!==t&&T(t)!==T(r)&&u("self-closed-tags","HTML tags must be properly nested and closed: "+t),e.replace(F,"<$1></$2>")},"self-closed-tags"),s.migrateDisablePatches("self-closed-tags");var D,W,_,I=s.fn.offset;return i(s.fn,"offset",function(){var e=this[0];return!e||e.nodeType&&e.getBoundingClientRect?I.apply(this,arguments):(u("offset-valid-elem","jQuery.fn.offset() requires a valid DOM element"),arguments.length?this:void 0)},"offset-valid-elem"),s.ajax&&(D=s.param,i(s,"param",function(e,t){var r=s.ajaxSettings&&s.ajaxSettings.traditional;return void 0===t&&r&&(u("param-ajax-traditional","jQuery.param() no longer uses jQuery.ajaxSettings.traditional"),t=r),D.call(this,e,t)},"param-ajax-traditional")),c(s.fn,"andSelf",s.fn.addBack,"andSelf","jQuery.fn.andSelf() is deprecated and removed, use jQuery.fn.addBack()"),s.Deferred&&(W=s.Deferred,_=[["resolve","done",s.Callbacks("once memory"),s.Callbacks("once memory"),"resolved"],["reject","fail",s.Callbacks("once memory"),s.Callbacks("once memory"),"rejected"],["notify","progress",s.Callbacks("memory"),s.Callbacks("memory")]],i(s,"Deferred",function(e){var a=W(),i=a.promise();function t(){var o=arguments;return s.Deferred(function(n){s.each(_,function(e,t){var r="function"==typeof o[e]&&o[e];a[t[1]](function(){var e=r&&r.apply(this,arguments);e&&"function"==typeof e.promise?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[t[0]+"With"](this===i?n.promise():this,r?[e]:arguments)})}),o=null}).promise()}return c(a,"pipe",t,"deferred-pipe","deferred.pipe() is deprecated"),c(i,"pipe",t,"deferred-pipe","deferred.pipe() is deprecated"),e&&e.call(a,a),a},"deferred-pipe"),s.Deferred.exceptionHook=W.exceptionHook),s});
3;
4/*
5     _ _      _       _
6 ___| (_) ___| | __  (_)___
7/ __| | |/ __| |/ /  | / __|
8\__ \ | | (__|   < _ | \__ \
9|___/_|_|\___|_|\_(_)/ |___/
10                   |__/
11
12 Version: 1.6.0
13  Author: Ken Wheeler
14 Website: http://kenwheeler.github.io
15    Docs: http://kenwheeler.github.io/slick
16    Repo: http://github.com/kenwheeler/slick
17  Issues: http://github.com/kenwheeler/slick/issues
18
19 */
20/* global window, document, define, jQuery, setInterval, clearInterval */
21(function(factory) {
22    'use strict';
23    if (typeof define === 'function' && define.amd) {
24        define(['jquery'], factory);
25    } else if (typeof exports !== 'undefined') {
26        module.exports = factory(require('jquery'));
27    } else {
28        factory(jQuery);
29    }
30
31}(function($) {
32    'use strict';
33    var Slick = window.Slick || {};
34
35    Slick = (function() {
36
37        var instanceUid = 0;
38
39        function Slick(element, settings) {
40
41            var _ = this, dataSettings;
42
43            _.defaults = {
44                accessibility: true,
45                adaptiveHeight: false,
46                appendArrows: $(element),
47                appendDots: $(element),
48                arrows: true,
49                asNavFor: null,
50                prevArrow: '<button type="button" data-role="none" class="slick-prev" aria-label="Previous" tabindex="0" role="button">Previous</button>',
51                nextArrow: '<button type="button" data-role="none" class="slick-next" aria-label="Next" tabindex="0" role="button">Next</button>',
52                autoplay: false,
53                autoplaySpeed: 3000,
54                centerMode: false,
55                centerPadding: '50px',
56                cssEase: 'ease',
57                customPaging: function(slider, i) {
58                    return $('<button type="button" data-role="none" role="button" tabindex="0" />').text(i + 1);
59                },
60                dots: false,
61                dotsClass: 'slick-dots',
62                draggable: true,
63                easing: 'linear',
64                edgeFriction: 0.35,
65                fade: false,
66                focusOnSelect: false,
67                infinite: true,
68                initialSlide: 0,
69                lazyLoad: 'ondemand',
70                mobileFirst: false,
71                pauseOnHover: true,
72                pauseOnFocus: true,
73                pauseOnDotsHover: false,
74                respondTo: 'window',
75                responsive: null,
76                rows: 1,
77                rtl: false,
78                slide: '',
79                slidesPerRow: 1,
80                slidesToShow: 1,
81                slidesToScroll: 1,
82                speed: 500,
83                swipe: true,
84                swipeToSlide: false,
85                touchMove: true,
86                touchThreshold: 5,
87                useCSS: true,
88                useTransform: true,
89                variableWidth: false,
90                vertical: false,
91                verticalSwiping: false,
92                waitForAnimate: true,
93                zIndex: 1000
94            };
95
96            _.initials = {
97                animating: false,
98                dragging: false,
99                autoPlayTimer: null,
100                currentDirection: 0,
101                currentLeft: null,
102                currentSlide: 0,
103                direction: 1,
104                $dots: null,
105                listWidth: null,
106                listHeight: null,
107                loadIndex: 0,
108                $nextArrow: null,
109                $prevArrow: null,
110                slideCount: null,
111                slideWidth: null,
112                $slideTrack: null,
113                $slides: null,
114                sliding: false,
115                slideOffset: 0,
116                swipeLeft: null
vendor: 11,177 bytes, lines 116-499
116,
117                $list: null,
118                touchObject: {},
119                transformsEnabled: false,
120                unslicked: false
121            };
122
123            $.extend(_, _.initials);
124
125            _.activeBreakpoint = null;
126            _.animType = null;
127            _.animProp = null;
128            _.breakpoints = [];
129            _.breakpointSettings = [];
130            _.cssTransitions = false;
131            _.focussed = false;
132            _.interrupted = false;
133            _.hidden = 'hidden';
134            _.paused = true;
135            _.positionProp = null;
136            _.respondTo = null;
137            _.rowCount = 1;
138            _.shouldClick = true;
139            _.$slider = $(element);
140            _.$slidesCache = null;
141            _.transformType = null;
142            _.transitionType = null;
143            _.visibilityChange = 'visibilitychange';
144            _.windowWidth = 0;
145            _.windowTimer = null;
146
147            dataSettings = $(element).data('slick') || {};
148
149            _.options = $.extend({}, _.defaults, settings, dataSettings);
150
151            _.currentSlide = _.options.initialSlide;
152
153            _.originalSettings = _.options;
154
155            if (typeof document.mozHidden !== 'undefined') {
156                _.hidden = 'mozHidden';
157                _.visibilityChange = 'mozvisibilitychange';
158            } else if (typeof document.webkitHidden !== 'undefined') {
159                _.hidden = 'webkitHidden';
160                _.visibilityChange = 'webkitvisibilitychange';
161            }
162
163            _.autoPlay = $.proxy(_.autoPlay, _);
164            _.autoPlayClear = $.proxy(_.autoPlayClear, _);
165            _.autoPlayIterator = $.proxy(_.autoPlayIterator, _);
166            _.changeSlide = $.proxy(_.changeSlide, _);
167            _.clickHandler = $.proxy(_.clickHandler, _);
168            _.selectHandler = $.proxy(_.selectHandler, _);
169            _.setPosition = $.proxy(_.setPosition, _);
170            _.swipeHandler = $.proxy(_.swipeHandler, _);
171            _.dragHandler = $.proxy(_.dragHandler, _);
172            _.keyHandler = $.proxy(_.keyHandler, _);
173
174            _.instanceUid = instanceUid++;
175
176            // A simple way to check for HTML strings
177            // Strict HTML recognition (must start with <)
178            // Extracted from jQuery v1.11 source
179            _.htmlExpr = /^(?:\s*(<[\w\W]+>)[^>]*)$/;
180
181
182            _.registerBreakpoints();
183            _.init(true);
184
185        }
186
187        return Slick;
188
189    }());
190
191    Slick.prototype.activateADA = function() {
192        var _ = this;
193
194        _.$slideTrack.find('.slick-active').attr({
195            'aria-hidden': 'false'
196        }).find('a, input, button, select').attr({
197            'tabindex': '0'
198        });
199
200    };
201
202    Slick.prototype.addSlide = Slick.prototype.slickAdd = function(markup, index, addBefore) {
203
204        var _ = this;
205
206        if (typeof(index) === 'boolean') {
207            addBefore = index;
208            index = null;
209        } else if (index < 0 || (index >= _.slideCount)) {
210            return false;
211        }
212
213        _.unload();
214
215        if (typeof(index) === 'number') {
216            if (index === 0 && _.$slides.length === 0) {
217                $(markup).appendTo(_.$slideTrack);
218            } else if (addBefore) {
219                $(markup).insertBefore(_.$slides.eq(index));
220            } else {
221                $(markup).insertAfter(_.$slides.eq(index));
222            }
223        } else {
224            if (addBefore === true) {
225                $(markup).prependTo(_.$slideTrack);
226            } else {
227                $(markup).appendTo(_.$slideTrack);
228            }
229        }
230
231        _.$slides = _.$slideTrack.children(this.options.slide);
232
233        _.$slideTrack.children(this.options.slide).detach();
234
235        _.$slideTrack.append(_.$slides);
236
237        _.$slides.each(function(index, element) {
238            $(element).attr('data-slick-index', index);
239        });
240
241        _.$slidesCache = _.$slides;
242
243        _.reinit();
244
245    };
246
247    Slick.prototype.animateHeight = function() {
248        var _ = this;
249        if (_.options.slidesToShow === 1 && _.options.adaptiveHeight === true && _.options.vertical === false) {
250            var targetHeight = _.$slides.eq(_.currentSlide).outerHeight(true);
251            _.$list.animate({
252                height: targetHeight
253            }, _.options.speed);
254        }
255    };
256
257    Slick.prototype.animateSlide = function(targetLeft, callback) {
258
259        var animProps = {},
260            _ = this;
261
262        _.animateHeight();
263
264        if (_.options.rtl === true && _.options.vertical === false) {
265            targetLeft = -targetLeft;
266        }
267        if (_.transformsEnabled === false) {
268            if (_.options.vertical === false) {
269                _.$slideTrack.animate({
270                    left: targetLeft
271                }, _.options.speed, _.options.easing, callback);
272            } else {
273                _.$slideTrack.animate({
274                    top: targetLeft
275                }, _.options.speed, _.options.easing, callback);
276            }
277
278        } else {
279
280            if (_.cssTransitions === false) {
281                if (_.options.rtl === true) {
282                    _.currentLeft = -(_.currentLeft);
283                }
284                $({
285                    animStart: _.currentLeft
286                }).animate({
287                    animStart: targetLeft
288                }, {
289                    duration: _.options.speed,
290                    easing: _.options.easing,
291                    step: function(now) {
292                        now = Math.ceil(now);
293                        if (_.options.vertical === false) {
294                            animProps[_.animType] = 'translate(' +
295                                now + 'px, 0px)';
296                            _.$slideTrack.css(animProps);
297                        } else {
298                            animProps[_.animType] = 'translate(0px,' +
299                                now + 'px)';
300                            _.$slideTrack.css(animProps);
301                        }
302                    },
303                    complete: function() {
304                        if (callback) {
305                            callback.call();
306                        }
307                    }
308                });
309
310            } else {
311
312                _.applyTransition();
313                targetLeft = Math.ceil(targetLeft);
314
315                if (_.options.vertical === false) {
316                    animProps[_.animType] = 'translate3d(' + targetLeft + 'px, 0px, 0px)';
317                } else {
318                    animProps[_.animType] = 'translate3d(0px,' + targetLeft + 'px, 0px)';
319                }
320                _.$slideTrack.css(animProps);
321
322                if (callback) {
323                    setTimeout(function() {
324
325                        _.disableTransition();
326
327                        callback.call();
328                    }, _.options.speed);
329                }
330
331            }
332
333        }
334
335    };
336
337    Slick.prototype.getNavTarget = function() {
338
339        var _ = this,
340            asNavFor = _.options.asNavFor;
341
342        if ( asNavFor && asNavFor !== null ) {
343            asNavFor = $(asNavFor).not(_.$slider);
344        }
345
346        return asNavFor;
347
348    };
349
350    Slick.prototype.asNavFor = function(index) {
351
352        var _ = this,
353            asNavFor = _.getNavTarget();
354
355        if ( asNavFor !== null && typeof asNavFor === 'object' ) {
356            asNavFor.each(function() {
357                var target = $(this).slick('getSlick');
358                if(!target.unslicked) {
359                    target.slideHandler(index, true);
360                }
361            });
362        }
363
364    };
365
366    Slick.prototype.applyTransition = function(slide) {
367
368        var _ = this,
369            transition = {};
370
371        if (_.options.fade === false) {
372            transition[_.transitionType] = _.transformType + ' ' + _.options.speed + 'ms ' + _.options.cssEase;
373        } else {
374            transition[_.transitionType] = 'opacity ' + _.options.speed + 'ms ' + _.options.cssEase;
375        }
376
377        if (_.options.fade === false) {
378            _.$slideTrack.css(transition);
379        } else {
380            _.$slides.eq(slide).css(transition);
381        }
382
383    };
384
385    Slick.prototype.autoPlay = function() {
386
387        var _ = this;
388
389        _.autoPlayClear();
390
391        if ( _.slideCount > _.options.slidesToShow ) {
392            _.autoPlayTimer = setInterval( _.autoPlayIterator, _.options.autoplaySpeed );
393        }
394
395    };
396
397    Slick.prototype.autoPlayClear = function() {
398
399        var _ = this;
400
401        if (_.autoPlayTimer) {
402            clearInterval(_.autoPlayTimer);
403        }
404
405    };
406
407    Slick.prototype.autoPlayIterator = function() {
408
409        var _ = this,
410            slideTo = _.currentSlide + _.options.slidesToScroll;
411
412        if ( !_.paused && !_.interrupted && !_.focussed ) {
413
414            if ( _.options.infinite === false ) {
415
416                if ( _.direction === 1 && ( _.currentSlide + 1 ) === ( _.slideCount - 1 )) {
417                    _.direction = 0;
418                }
419
420                else if ( _.direction === 0 ) {
421
422                    slideTo = _.currentSlide - _.options.slidesToScroll;
423
424                    if ( _.currentSlide - 1 === 0 ) {
425                        _.direction = 1;
426                    }
427
428                }
429
430            }
431
432            _.slideHandler( slideTo );
433
434        }
435
436    };
437
438    Slick.prototype.buildArrows = function() {
439
440        var _ = this;
441
442        if (_.options.arrows === true ) {
443
444            _.$prevArrow = $(_.options.prevArrow).addClass('slick-arrow');
445            _.$nextArrow = $(_.options.nextArrow).addClass('slick-arrow');
446
447            if( _.slideCount > _.options.slidesToShow ) {
448
449                _.$prevArrow.removeClass('slick-hidden').removeAttr('aria-hidden tabindex');
450                _.$nextArrow.removeClass('slick-hidden').removeAttr('aria-hidden tabindex');
451
452                if (_.htmlExpr.test(_.options.prevArrow)) {
453                    _.$prevArrow.prependTo(_.options.appendArrows);
454                }
455
456                if (_.htmlExpr.test(_.options.nextArrow)) {
457                    _.$nextArrow.appendTo(_.options.appendArrows);
458                }
459
460                if (_.options.infinite !== true) {
461                    _.$prevArrow
462                        .addClass('slick-disabled')
463                        .attr('aria-disabled', 'true');
464                }
465
466            } else {
467
468                _.$prevArrow.add( _.$nextArrow )
469
470                    .addClass('slick-hidden')
471                    .attr({
472                        'aria-disabled': 'true',
473                        'tabindex': '-1'
474                    });
475
476            }
477
478        }
479
480    };
481
482    Slick.prototype.buildDots = function() {
483
484        var _ = this,
485            i, dot;
486
487        if (_.options.dots === true && _.slideCount > _.options.slidesToShow) {
488
489            _.$slider.addClass('slick-dotted');
490
491            dot = $('<ul />').addClass(_.options.dotsClass);
492
493            for (i = 0; i <= _.getDotCount(); i += 1) {
494                dot.append($('<li />').append(_.options.customPaging.call(this, _, i)));
495            }
496
497            _.$dots = dot.appendTo(_.options.appendDots);
498
499            _.$dots.find('li').first().addClass('slick-active')
vendor: 18,779 bytes, lines 499-1108
499.attr('aria-hidden', 'false');
500
501        }
502
503    };
504
505    Slick.prototype.buildOut = function() {
506
507        var _ = this;
508
509        _.$slides =
510            _.$slider
511                .children( _.options.slide + ':not(.slick-cloned)')
512                .addClass('slick-slide');
513
514        _.slideCount = _.$slides.length;
515
516        _.$slides.each(function(index, element) {
517            $(element)
518                .attr('data-slick-index', index)
519                .data('originalStyling', $(element).attr('style') || '');
520        });
521
522        _.$slider.addClass('slick-slider');
523
524        _.$slideTrack = (_.slideCount === 0) ?
525            $('<div class="slick-track"/>').appendTo(_.$slider) :
526            _.$slides.wrapAll('<div class="slick-track"/>').parent();
527
528        _.$list = _.$slideTrack.wrap(
529            '<div aria-live="polite" class="slick-list"/>').parent();
530        _.$slideTrack.css('opacity', 0);
531
532        if (_.options.centerMode === true || _.options.swipeToSlide === true) {
533            _.options.slidesToScroll = 1;
534        }
535
536        $('img[data-lazy]', _.$slider).not('[src]').addClass('slick-loading');
537
538        _.setupInfinite();
539
540        _.buildArrows();
541
542        _.buildDots();
543
544        _.updateDots();
545
546
547        _.setSlideClasses(typeof _.currentSlide === 'number' ? _.currentSlide : 0);
548
549        if (_.options.draggable === true) {
550            _.$list.addClass('draggable');
551        }
552
553    };
554
555    Slick.prototype.buildRows = function() {
556
557        var _ = this, a, b, c, newSlides, numOfSlides, originalSlides,slidesPerSection;
558
559        newSlides = document.createDocumentFragment();
560        originalSlides = _.$slider.children();
561
562        if(_.options.rows > 1) {
563
564            slidesPerSection = _.options.slidesPerRow * _.options.rows;
565            numOfSlides = Math.ceil(
566                originalSlides.length / slidesPerSection
567            );
568
569            for(a = 0; a < numOfSlides; a++){
570                var slide = document.createElement('div');
571                for(b = 0; b < _.options.rows; b++) {
572                    var row = document.createElement('div');
573                    for(c = 0; c < _.options.slidesPerRow; c++) {
574                        var target = (a * slidesPerSection + ((b * _.options.slidesPerRow) + c));
575                        if (originalSlides.get(target)) {
576                            row.appendChild(originalSlides.get(target));
577                        }
578                    }
579                    slide.appendChild(row);
580                }
581                newSlides.appendChild(slide);
582            }
583
584            _.$slider.empty().append(newSlides);
585            _.$slider.children().children().children()
586                .css({
587                    'width':(100 / _.options.slidesPerRow) + '%',
588                    'display': 'inline-block'
589                });
590
591        }
592
593    };
594
595    Slick.prototype.checkResponsive = function(initial, forceUpdate) {
596
597        var _ = this,
598            breakpoint, targetBreakpoint, respondToWidth, triggerBreakpoint = false;
599        var sliderWidth = _.$slider.width();
600        var windowWidth = window.innerWidth || $(window).width();
601
602        if (_.respondTo === 'window') {
603            respondToWidth = windowWidth;
604        } else if (_.respondTo === 'slider') {
605            respondToWidth = sliderWidth;
606        } else if (_.respondTo === 'min') {
607            respondToWidth = Math.min(windowWidth, sliderWidth);
608        }
609
610        if ( _.options.responsive &&
611            _.options.responsive.length &&
612            _.options.responsive !== null) {
613
614            targetBreakpoint = null;
615
616            for (breakpoint in _.breakpoints) {
617                if (_.breakpoints.hasOwnProperty(breakpoint)) {
618                    if (_.originalSettings.mobileFirst === false) {
619                        if (respondToWidth < _.breakpoints[breakpoint]) {
620                            targetBreakpoint = _.breakpoints[breakpoint];
621                        }
622                    } else {
623                        if (respondToWidth > _.breakpoints[breakpoint]) {
624                            targetBreakpoint = _.breakpoints[breakpoint];
625                        }
626                    }
627                }
628            }
629
630            if (targetBreakpoint !== null) {
631                if (_.activeBreakpoint !== null) {
632                    if (targetBreakpoint !== _.activeBreakpoint || forceUpdate) {
633                        _.activeBreakpoint =
634                            targetBreakpoint;
635                        if (_.breakpointSettings[targetBreakpoint] === 'unslick') {
636                            _.unslick(targetBreakpoint);
637                        } else {
638                            _.options = $.extend({}, _.originalSettings,
639                                _.breakpointSettings[
640                                    targetBreakpoint]);
641                            if (initial === true) {
642                                _.currentSlide = _.options.initialSlide;
643                            }
644                            _.refresh(initial);
645                        }
646                        triggerBreakpoint = targetBreakpoint;
647                    }
648                } else {
649                    _.activeBreakpoint = targetBreakpoint;
650                    if (_.breakpointSettings[targetBreakpoint] === 'unslick') {
651                        _.unslick(targetBreakpoint);
652                    } else {
653                        _.options = $.extend({}, _.originalSettings,
654                            _.breakpointSettings[
655                                targetBreakpoint]);
656                        if (initial === true) {
657                            _.currentSlide = _.options.initialSlide;
658                        }
659                        _.refresh(initial);
660                    }
661                    triggerBreakpoint = targetBreakpoint;
662                }
663            } else {
664                if (_.activeBreakpoint !== null) {
665                    _.activeBreakpoint = null;
666                    _.options = _.originalSettings;
667                    if (initial === true) {
668                        _.currentSlide = _.options.initialSlide;
669                    }
670                    _.refresh(initial);
671                    triggerBreakpoint = targetBreakpoint;
672                }
673            }
674
675            // only trigger breakpoints during an actual break. not on initialize.
676            if( !initial && triggerBreakpoint !== false ) {
677                _.$slider.trigger('breakpoint', [_, triggerBreakpoint]);
678            }
679        }
680
681    };
682
683    Slick.prototype.changeSlide = function(event, dontAnimate) {
684
685        var _ = this,
686            $target = $(event.currentTarget),
687            indexOffset, slideOffset, unevenOffset;
688
689        // If target is a link, prevent default action.
690        if($target.is('a')) {
691            event.preventDefault();
692        }
693
694        // If target is not the <li> element (ie: a child), find the <li>.
695        if(!$target.is('li')) {
696            $target = $target.closest('li');
697        }
698
699        unevenOffset = (_.slideCount % _.options.slidesToScroll !== 0);
700        indexOffset = unevenOffset ? 0 : (_.slideCount - _.currentSlide) % _.options.slidesToScroll;
701
702        switch (event.data.message) {
703
704            case 'previous':
705                slideOffset = indexOffset === 0 ? _.options.slidesToScroll : _.options.slidesToShow - indexOffset;
706                if (_.slideCount > _.options.slidesToShow) {
707                    _.slideHandler(_.currentSlide - slideOffset, false, dontAnimate);
708                }
709                break;
710
711            case 'next':
712                slideOffset = indexOffset === 0 ? _.options.slidesToScroll : indexOffset;
713                if (_.slideCount > _.options.slidesToShow) {
714                    _.slideHandler(_.currentSlide + slideOffset, false, dontAnimate);
715                }
716                break;
717
718            case 'index':
719                var index = event.data.index === 0 ? 0 :
720                    event.data.index || $target.index() * _.options.slidesToScroll;
721
722                _.slideHandler(_.checkNavigable(index), false, dontAnimate);
723                $target.children().trigger('focus');
724                break;
725
726            default:
727                return;
728        }
729
730    };
731
732    Slick.prototype.checkNavigable = function(index) {
733
734        var _ = this,
735            navigables, prevNavigable;
736
737        navigables = _.getNavigableIndexes();
738        prevNavigable = 0;
739        if (index > navigables[navigables.length - 1]) {
740            index = navigables[navigables.length - 1];
741        } else {
742            for (var n in navigables) {
743                if (index < navigables[n]) {
744                    index = prevNavigable;
745                    break;
746                }
747                prevNavigable = navigables[n];
748            }
749        }
750
751        return index;
752    };
753
754    Slick.prototype.cleanUpEvents = function() {
755
756        var _ = this;
757
758        if (_.options.dots && _.$dots !== null) {
759
760            $('li', _.$dots)
761                .off('click.slick', _.changeSlide)
762                .off('mouseenter.slick', $.proxy(_.interrupt, _, true))
763                .off('mouseleave.slick', $.proxy(_.interrupt, _, false));
764
765        }
766
767        _.$slider.off('focus.slick blur.slick');
768
769        if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) {
770            _.$prevArrow && _.$prevArrow.off('click.slick', _.changeSlide);
771            _.$nextArrow && _.$nextArrow.off('click.slick', _.changeSlide);
772        }
773
774        _.$list.off('touchstart.slick mousedown.slick', _.swipeHandler);
775        _.$list.off('touchmove.slick mousemove.slick', _.swipeHandler);
776        _.$list.off('touchend.slick mouseup.slick', _.swipeHandler);
777        _.$list.off('touchcancel.slick mouseleave.slick', _.swipeHandler);
778
779        _.$list.off('click.slick', _.clickHandler);
780
781        $(document).off(_.visibilityChange, _.visibility);
782
783        _.cleanUpSlideEvents();
784
785        if (_.options.accessibility === true) {
786            _.$list.off('keydown.slick', _.keyHandler);
787        }
788
789        if (_.options.focusOnSelect === true) {
790            $(_.$slideTrack).children().off('click.slick', _.selectHandler);
791        }
792
793        $(window).off('orientationchange.slick.slick-' + _.instanceUid, _.orientationChange);
794
795        $(window).off('resize.slick.slick-' + _.instanceUid, _.resize);
796
797        $('[draggable!=true]', _.$slideTrack).off('dragstart', _.preventDefault);
798
799        $(window).off('load.slick.slick-' + _.instanceUid, _.setPosition);
800        $(document).off('ready.slick.slick-' + _.instanceUid, _.setPosition);
801
802    };
803
804    Slick.prototype.cleanUpSlideEvents = function() {
805
806        var _ = this;
807
808        _.$list.off('mouseenter.slick', $.proxy(_.interrupt, _, true));
809        _.$list.off('mouseleave.slick', $.proxy(_.interrupt, _, false));
810
811    };
812
813    Slick.prototype.cleanUpRows = function() {
814
815        var _ = this, originalSlides;
816
817        if(_.options.rows > 1) {
818            originalSlides = _.$slides.children().children();
819            originalSlides.removeAttr('style');
820            _.$slider.empty().append(originalSlides);
821        }
822
823    };
824
825    Slick.prototype.clickHandler = function(event) {
826
827        var _ = this;
828
829        if (_.shouldClick === false) {
830            event.stopImmediatePropagation();
831            event.stopPropagation();
832            event.preventDefault();
833        }
834
835    };
836
837    Slick.prototype.destroy = function(refresh) {
838
839        var _ = this;
840
841        _.autoPlayClear();
842
843        _.touchObject = {};
844
845        _.cleanUpEvents();
846
847        $('.slick-cloned', _.$slider).detach();
848
849        if (_.$dots) {
850            _.$dots.remove();
851        }
852
853
854        if ( _.$prevArrow && _.$prevArrow.length ) {
855
856            _.$prevArrow
857                .removeClass('slick-disabled slick-arrow slick-hidden')
858                .removeAttr('aria-hidden aria-disabled tabindex')
859                .css('display','');
860
861            if ( _.htmlExpr.test( _.options.prevArrow )) {
862                _.$prevArrow.remove();
863            }
864        }
865
866        if ( _.$nextArrow && _.$nextArrow.length ) {
867
868            _.$nextArrow
869                .removeClass('slick-disabled slick-arrow slick-hidden')
870                .removeAttr('aria-hidden aria-disabled tabindex')
871                .css('display','');
872
873            if ( _.htmlExpr.test( _.options.nextArrow )) {
874                _.$nextArrow.remove();
875            }
876
877        }
878
879
880        if (_.$slides) {
881
882            _.$slides
883                .removeClass('slick-slide slick-active slick-center slick-visible slick-current')
884                .removeAttr('aria-hidden')
885                .removeAttr('data-slick-index')
886                .each(function(){
887                    $(this).attr('style', $(this).data('originalStyling'));
888                });
889
890            _.$slideTrack.children(this.options.slide).detach();
891
892            _.$slideTrack.detach();
893
894            _.$list.detach();
895
896            _.$slider.append(_.$slides);
897        }
898
899        _.cleanUpRows();
900
901        _.$slider.removeClass('slick-slider');
902        _.$slider.removeClass('slick-initialized');
903        _.$slider.removeClass('slick-dotted');
904
905        _.unslicked = true;
906
907        if(!refresh) {
908            _.$slider.trigger('destroy', [_]);
909        }
910
911    };
912
913    Slick.prototype.disableTransition = function(slide) {
914
915        var _ = this,
916            transition = {};
917
918        transition[_.transitionType] = '';
919
920        if (_.options.fade === false) {
921            _.$slideTrack.css(transition);
922        } else {
923            _.$slides.eq(slide).css(transition);
924        }
925
926    };
927
928    Slick.prototype.fadeSlide = function(slideIndex, callback) {
929
930        var _ = this;
931
932        if (_.cssTransitions === false) {
933
934            _.$slides.eq(slideIndex).css({
935                zIndex: _.options.zIndex
936            });
937
938            _.$slides.eq(slideIndex).animate({
939                opacity: 1
940            }, _.options.speed, _.options.easing, callback);
941
942        } else {
943
944            _.applyTransition(slideIndex);
945
946            _.$slides.eq(slideIndex).css({
947                opacity: 1,
948                zIndex: _.options.zIndex
949            });
950
951            if (callback) {
952                setTimeout(function() {
953
954                    _.disableTransition(slideIndex);
955
956                    callback.call();
957                }, _.options.speed);
958            }
959
960        }
961
962    };
963
964    Slick.prototype.fadeSlideOut = function(slideIndex) {
965
966        var _ = this;
967
968        if (_.cssTransitions === false) {
969
970            _.$slides.eq(slideIndex).animate({
971                opacity: 0,
972                zIndex: _.options.zIndex - 2
973            }, _.options.speed, _.options.easing);
974
975        } else {
976
977            _.applyTransition(slideIndex);
978
979            _.$slides.eq(slideIndex).css({
980                opacity: 0,
981                zIndex: _.options.zIndex - 2
982            });
983
984        }
985
986    };
987
988    Slick.prototype.filterSlides = Slick.prototype.slickFilter = function(filter) {
989
990        var _ = this;
991
992        if (filter !== null) {
993
994            _.$slidesCache = _.$slides;
995
996            _.unload();
997
998            _.$slideTrack.children(this.options.slide).detach();
999
1000            _.$slidesCache.filter(filter).appendTo(_.$slideTrack);
1001
1002            _.reinit();
1003
1004        }
1005
1006    };
1007
1008    Slick.prototype.focusHandler = function() {
1009
1010        var _ = this;
1011
1012        _.$slider
1013            .off('focus.slick blur.slick')
1014            .on('focus.slick blur.slick',
1015                '*:not(.slick-arrow)', function(event) {
1016
1017            event.stopImmediatePropagation();
1018            var $sf = $(this);
1019
1020            setTimeout(function() {
1021
1022                if( _.options.pauseOnFocus ) {
1023                    _.focussed = $sf.is(':focus');
1024                    _.autoPlay();
1025                }
1026
1027            }, 0);
1028
1029        });
1030    };
1031
1032    Slick.prototype.getCurrent = Slick.prototype.slickCurrentSlide = function() {
1033
1034        var _ = this;
1035        return _.currentSlide;
1036
1037    };
1038
1039    Slick.prototype.getDotCount = function() {
1040
1041        var _ = this;
1042
1043        var breakPoint = 0;
1044        var counter = 0;
1045        var pagerQty = 0;
1046
1047        if (_.options.infinite === true) {
1048            while (breakPoint < _.slideCount) {
1049                ++pagerQty;
1050                breakPoint = counter + _.options.slidesToScroll;
1051                counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow;
1052            }
1053        } else if (_.options.centerMode === true) {
1054            pagerQty = _.slideCount;
1055        } else if(!_.options.asNavFor) {
1056            pagerQty = 1 + Math.ceil((_.slideCount - _.options.slidesToShow) / _.options.slidesToScroll);
1057        }else {
1058            while (breakPoint < _.slideCount) {
1059                ++pagerQty;
1060                breakPoint = counter + _.options.slidesToScroll;
1061                counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow;
1062            }
1063        }
1064
1065        return pagerQty - 1;
1066
1067    };
1068
1069    Slick.prototype.getLeft = function(slideIndex) {
1070
1071        var _ = this,
1072            targetLeft,
1073            verticalHeight,
1074            verticalOffset = 0,
1075            targetSlide;
1076
1077        _.slideOffset = 0;
1078        verticalHeight = _.$slides.first().outerHeight(true);
1079
1080        if (_.options.infinite === true) {
1081            if (_.slideCount > _.options.slidesToShow) {
1082                _.slideOffset = (_.slideWidth * _.options.slidesToShow) * -1;
1083                verticalOffset = (verticalHeight * _.options.slidesToShow) * -1;
1084            }
1085            if (_.slideCount % _.options.slidesToScroll !== 0) {
1086                if (slideIndex + _.options.slidesToScroll > _.slideCount && _.slideCount > _.options.slidesToShow) {
1087                    if (slideIndex > _.slideCount) {
1088                        _.slideOffset = ((_.options.slidesToShow - (slideIndex - _.slideCount)) * _.slideWidth) * -1;
1089                        verticalOffset = ((_.options.slidesToShow - (slideIndex - _.slideCount)) * verticalHeight) * -1;
1090                    } else {
1091                        _.slideOffset = ((_.slideCount % _.options.slidesToScroll) * _.slideWidth) * -1;
1092                        verticalOffset = ((_.slideCount % _.options.slidesToScroll) * verticalHeight) * -1;
1093                    }
1094                }
1095            }
1096        } else {
1097            if (slideIndex + _.options.slidesToShow > _.slideCount) {
1098                _.slideOffset = ((slideIndex + _.options.slidesToShow) - _.slideCount) * _.slideWidth;
1099                verticalOffset = ((slideIndex + _.options.slidesToShow) - _.slideCount) * verticalHeight;
1100            }
1101        }
1102
1103        if (_.slideCount <= _.options.slidesToShow) {
1104            _.slideOffset = 0;
1105            verticalOffset = 0;
1106        }
1107
1108       
vendor: 5,167 bytes, lines 1108-1281
1108 if (_.options.centerMode === true && _.options.infinite === true) {
1109            _.slideOffset += _.slideWidth * Math.floor(_.options.slidesToShow / 2) - _.slideWidth;
1110        } else if (_.options.centerMode === true) {
1111            _.slideOffset = 0;
1112            _.slideOffset += _.slideWidth * Math.floor(_.options.slidesToShow / 2);
1113        }
1114
1115        if (_.options.vertical === false) {
1116            targetLeft = ((slideIndex * _.slideWidth) * -1) + _.slideOffset;
1117        } else {
1118            targetLeft = ((slideIndex * verticalHeight) * -1) + verticalOffset;
1119        }
1120
1121        if (_.options.variableWidth === true) {
1122
1123            if (_.slideCount <= _.options.slidesToShow || _.options.infinite === false) {
1124                targetSlide = _.$slideTrack.children('.slick-slide').eq(slideIndex);
1125            } else {
1126                targetSlide = _.$slideTrack.children('.slick-slide').eq(slideIndex + _.options.slidesToShow);
1127            }
1128
1129            if (_.options.rtl === true) {
1130                if (targetSlide[0]) {
1131                    targetLeft = (_.$slideTrack.width() - targetSlide[0].offsetLeft - targetSlide.width()) * -1;
1132                } else {
1133                    targetLeft =  0;
1134                }
1135            } else {
1136                targetLeft = targetSlide[0] ? targetSlide[0].offsetLeft * -1 : 0;
1137            }
1138
1139            if (_.options.centerMode === true) {
1140                if (_.slideCount <= _.options.slidesToShow || _.options.infinite === false) {
1141                    targetSlide = _.$slideTrack.children('.slick-slide').eq(slideIndex);
1142                } else {
1143                    targetSlide = _.$slideTrack.children('.slick-slide').eq(slideIndex + _.options.slidesToShow + 1);
1144                }
1145
1146                if (_.options.rtl === true) {
1147                    if (targetSlide[0]) {
1148                        targetLeft = (_.$slideTrack.width() - targetSlide[0].offsetLeft - targetSlide.width()) * -1;
1149                    } else {
1150                        targetLeft =  0;
1151                    }
1152                } else {
1153                    targetLeft = targetSlide[0] ? targetSlide[0].offsetLeft * -1 : 0;
1154                }
1155
1156                targetLeft += (_.$list.width() - targetSlide.outerWidth()) / 2;
1157            }
1158        }
1159
1160        return targetLeft;
1161
1162    };
1163
1164    Slick.prototype.getOption = Slick.prototype.slickGetOption = function(option) {
1165
1166        var _ = this;
1167
1168        return _.options[option];
1169
1170    };
1171
1172    Slick.prototype.getNavigableIndexes = function() {
1173
1174        var _ = this,
1175            breakPoint = 0,
1176            counter = 0,
1177            indexes = [],
1178            max;
1179
1180        if (_.options.infinite === false) {
1181            max = _.slideCount;
1182        } else {
1183            breakPoint = _.options.slidesToScroll * -1;
1184            counter = _.options.slidesToScroll * -1;
1185            max = _.slideCount * 2;
1186        }
1187
1188        while (breakPoint < max) {
1189            indexes.push(breakPoint);
1190            breakPoint = counter + _.options.slidesToScroll;
1191            counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow;
1192        }
1193
1194        return indexes;
1195
1196    };
1197
1198    Slick.prototype.getSlick = function() {
1199
1200        return this;
1201
1202    };
1203
1204    Slick.prototype.getSlideCount = function() {
1205
1206        var _ = this,
1207            slidesTraversed, swipedSlide, centerOffset;
1208
1209        centerOffset = _.options.centerMode === true ? _.slideWidth * Math.floor(_.options.slidesToShow / 2) : 0;
1210
1211        if (_.options.swipeToSlide === true) {
1212            _.$slideTrack.find('.slick-slide').each(function(index, slide) {
1213                if (slide.offsetLeft - centerOffset + ($(slide).outerWidth() / 2) > (_.swipeLeft * -1)) {
1214                    swipedSlide = slide;
1215                    return false;
1216                }
1217            });
1218
1219            slidesTraversed = Math.abs($(swipedSlide).attr('data-slick-index') - _.currentSlide) || 1;
1220
1221            return slidesTraversed;
1222
1223        } else {
1224            return _.options.slidesToScroll;
1225        }
1226
1227    };
1228
1229    Slick.prototype.goTo = Slick.prototype.slickGoTo = function(slide, dontAnimate) {
1230
1231        var _ = this;
1232
1233        _.changeSlide({
1234            data: {
1235                message: 'index',
1236                index: parseInt(slide)
1237            }
1238        }, dontAnimate);
1239
1240    };
1241
1242    Slick.prototype.init = function(creation) {
1243
1244        var _ = this;
1245
1246        if (!$(_.$slider).hasClass('slick-initialized')) {
1247
1248            $(_.$slider).addClass('slick-initialized');
1249
1250            _.buildRows();
1251            _.buildOut();
1252            _.setProps();
1253            _.startLoad();
1254            _.loadSlider();
1255            _.initializeEvents();
1256            _.updateArrows();
1257            _.updateDots();
1258            _.checkResponsive(true);
1259            _.focusHandler();
1260
1261        }
1262
1263        if (creation) {
1264            _.$slider.trigger('init', [_]);
1265        }
1266
1267        if (_.options.accessibility === true) {
1268            _.initADA();
1269        }
1270
1271        if ( _.options.autoplay ) {
1272
1273            _.paused = false;
1274            _.autoPlay();
1275
1276        }
1277
1278    };
1279
1280    Slick.prototype.initADA = function() {
1281        var _ = this
1281;
1282        _.$slides.add(_.$slideTrack.find('.slick-cloned')).attr({
1283            'aria-hidden': 'true',
1284            'tabindex': '-1'
1285        }).find('a, input, button, select').attr({
1286            'tabindex': '-1'
1287        });
1288
1289        _.$slideTrack.attr('role', 'listbox');
1290
1291        _.$slides.not(_.$slideTrack.find('.slick-cloned')).each(function(i) {
1292            $(this).attr('role', 'option');
1293            
1294            //Evenly distribute aria-describedby tags through available dots.
1295            var describedBySlideId = _.options.centerMode ? i : Math.floor(i / _.options.slidesToShow);
1296            
1297            if (_.options.dots === true) {
1298                $(this).attr('aria-describedby', 'slick-slide' + _.instanceUid + describedBySlideId + '');
1299            }
1300        });
1301
1302        if (_.$dots !== null) {
1303            _.$dots.attr('role', 'tablist').find('li').each(function(i) {
1304                $(this).attr({
1305                    'role': 'presentation',
1306                    'aria-selected': 'false',
1307                    'aria-controls': 'navigation' + _.instanceUid + i + '',
1308                    'id': 'slick-slide' + _.instanceUid + i + ''
1309                });
1310            })
1311                .first().attr('aria-selected', 'true').end()
1312                .find('button').attr('role', 'button').end()
1313                .closest('div').attr('role', 'toolbar');
1314        }
1315        _.activateADA();
1316
1317    };
1318
1319    Slick.prototype.initArrowEvents = function() {
1320
1321        var _ = this;
1322
1323        if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) {
1324            _.$prevArrow
1325               .off('click.slick')
1326               .on('click.slick', {
1327                    message: 'previous'
1328               }, _.changeSlide);
1329            _.$nextArrow
1330               .off('click.slick')
1331               .on('click.slick', {
1332                    message: 'next'
1333               }, _.changeSlide);
1334        }
1335
1336    };
1337
1338    Slick.prototype.initDotEvents = function() {
1339
1340        var _ = this;
1341
1342        if (_.options.dots === true && _.slideCount > _.options.slidesToShow) {
1343            $('li', _.$dots).on('click.slick', {
1344                message: 'index'
1345            }, _.changeSlide);
1346        }
1347
1348        if ( _.options.dots === true && _.options.pauseOnDotsHover === true ) {
1349
1350            $('li', _.$dots)
1351                .on('mouseenter.slick', $.proxy(_.interrupt, _, true))
1352                .on('mouseleave.slick', $.proxy(_.interrupt, _, false));
1353
1354        }
1355
1356    };
1357
1358    Slick.prototype.initSlideEvents = function() {
1359
1360        var _ = this;
1361
1362        if ( _.options.pauseOnHover ) {
1363
1364            _.$list.on('mouseenter.slick', $.proxy(_.interrupt, _, true));
1365            _.$list.on('mouseleave.slick', $.proxy(_.interrupt, _, false));
1366
1367        }
1368
1369    };
1370
1371    Slick.prototype.initializeEvents = function() {
1372
1373        var _ = this;
1374
1375        _.initArrowEvents();
1376
1377        _.initDotEvents();
1378        _.initSlideEvents();
1379
1380        _.$list.on('touchstart.slick mousedown.slick', {
1381            action: 'start'
1382        }, _.swipeHandler);
1383        _.$list.on('touchmove.slick mousemove.slick', {
1384            action: 'move'
1385        }, _.swipeHandler);
1386        _.$list.on('touchend.slick mouseup.slick', {
1387            action: 'end'
1388        }, _.swipeHandler);
vendor: 10,240 bytes, lines 1389-1766
1389        _.$list.on('touchcancel.slick mouseleave.slick', {
1390            action: 'end'
1391        }, _.swipeHandler);
1392
1393        _.$list.on('click.slick', _.clickHandler);
1394
1395        $(document).on(_.visibilityChange, $.proxy(_.visibility, _));
1396
1397        if (_.options.accessibility === true) {
1398            _.$list.on('keydown.slick', _.keyHandler);
1399        }
1400
1401        if (_.options.focusOnSelect === true) {
1402            $(_.$slideTrack).children().on('click.slick', _.selectHandler);
1403        }
1404
1405        $(window).on('orientationchange.slick.slick-' + _.instanceUid, $.proxy(_.orientationChange, _));
1406
1407        $(window).on('resize.slick.slick-' + _.instanceUid, $.proxy(_.resize, _));
1408
1409        $('[draggable!=true]', _.$slideTrack).on('dragstart', _.preventDefault);
1410
1411        $(window).on('load.slick.slick-' + _.instanceUid, _.setPosition);
1412        $(document).on('ready.slick.slick-' + _.instanceUid, _.setPosition);
1413
1414    };
1415
1416    Slick.prototype.initUI = function() {
1417
1418        var _ = this;
1419
1420        if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) {
1421
1422            _.$prevArrow.show();
1423            _.$nextArrow.show();
1424
1425        }
1426
1427        if (_.options.dots === true && _.slideCount > _.options.slidesToShow) {
1428
1429            _.$dots.show();
1430
1431        }
1432
1433    };
1434
1435    Slick.prototype.keyHandler = function(event) {
1436
1437        var _ = this;
1438         //Dont slide if the cursor is inside the form fields and arrow keys are pressed
1439        if(!event.target.tagName.match('TEXTAREA|INPUT|SELECT')) {
1440            if (event.keyCode === 37 && _.options.accessibility === true) {
1441                _.changeSlide({
1442                    data: {
1443                        message: _.options.rtl === true ? 'next' :  'previous'
1444                    }
1445                });
1446            } else if (event.keyCode === 39 && _.options.accessibility === true) {
1447                _.changeSlide({
1448                    data: {
1449                        message: _.options.rtl === true ? 'previous' : 'next'
1450                    }
1451                });
1452            }
1453        }
1454
1455    };
1456
1457    Slick.prototype.lazyLoad = function() {
1458
1459        var _ = this,
1460            loadRange, cloneRange, rangeStart, rangeEnd;
1461
1462        function loadImages(imagesScope) {
1463
1464            $('img[data-lazy]', imagesScope).each(function() {
1465
1466                var image = $(this),
1467                    imageSource = $(this).attr('data-lazy'),
1468                    imageToLoad = document.createElement('img');
1469
1470                imageToLoad.onload = function() {
1471
1472                    image
1473                        .animate({ opacity: 0 }, 100, function() {
1474                            image
1475                                .attr('src', imageSource)
1476                                .animate({ opacity: 1 }, 200, function() {
1477                                    image
1478                                        .removeAttr('data-lazy')
1479                                        .removeClass('slick-loading');
1480                                });
1481                            _.$slider.trigger('lazyLoaded', [_, image, imageSource]);
1482                        });
1483
1484                };
1485
1486                imageToLoad.onerror = function() {
1487
1488                    image
1489                        .removeAttr( 'data-lazy' )
1490                        .removeClass( 'slick-loading' )
1491                        .addClass( 'slick-lazyload-error' );
1492
1493                    _.$slider.trigger('lazyLoadError', [ _, image, imageSource ]);
1494
1495                };
1496
1497                imageToLoad.src = imageSource;
1498
1499            });
1500
1501        }
1502
1503        if (_.options.centerMode === true) {
1504            if (_.options.infinite === true) {
1505                rangeStart = _.currentSlide + (_.options.slidesToShow / 2 + 1);
1506                rangeEnd = rangeStart + _.options.slidesToShow + 2;
1507            } else {
1508                rangeStart = Math.max(0, _.currentSlide - (_.options.slidesToShow / 2 + 1));
1509                rangeEnd = 2 + (_.options.slidesToShow / 2 + 1) + _.currentSlide;
1510            }
1511        } else {
1512            rangeStart = _.options.infinite ? _.options.slidesToShow + _.currentSlide : _.currentSlide;
1513            rangeEnd = Math.ceil(rangeStart + _.options.slidesToShow);
1514            if (_.options.fade === true) {
1515                if (rangeStart > 0) rangeStart--;
1516                if (rangeEnd <= _.slideCount) rangeEnd++;
1517            }
1518        }
1519
1520        loadRange = _.$slider.find('.slick-slide').slice(rangeStart, rangeEnd);
1521        loadImages(loadRange);
1522
1523        if (_.slideCount <= _.options.slidesToShow) {
1524            cloneRange = _.$slider.find('.slick-slide');
1525            loadImages(cloneRange);
1526        } else
1527        if (_.currentSlide >= _.slideCount - _.options.slidesToShow) {
1528            cloneRange = _.$slider.find('.slick-cloned').slice(0, _.options.slidesToShow);
1529            loadImages(cloneRange);
1530        } else if (_.currentSlide === 0) {
1531            cloneRange = _.$slider.find('.slick-cloned').slice(_.options.slidesToShow * -1);
1532            loadImages(cloneRange);
1533        }
1534
1535    };
1536
1537    Slick.prototype.loadSlider = function() {
1538
1539        var _ = this;
1540
1541        _.setPosition();
1542
1543        _.$slideTrack.css({
1544            opacity: 1
1545        });
1546
1547        _.$slider.removeClass('slick-loading');
1548
1549        _.initUI();
1550
1551        if (_.options.lazyLoad === 'progressive') {
1552            _.progressiveLazyLoad();
1553        }
1554
1555    };
1556
1557    Slick.prototype.next = Slick.prototype.slickNext = function() {
1558
1559        var _ = this;
1560
1561        _.changeSlide({
1562            data: {
1563                message: 'next'
1564            }
1565        });
1566
1567    };
1568
1569    Slick.prototype.orientationChange = function() {
1570
1571        var _ = this;
1572
1573        _.checkResponsive();
1574        _.setPosition();
1575
1576    };
1577
1578    Slick.prototype.pause = Slick.prototype.slickPause = function() {
1579
1580        var _ = this;
1581
1582        _.autoPlayClear();
1583        _.paused = true;
1584
1585    };
1586
1587    Slick.prototype.play = Slick.prototype.slickPlay = function() {
1588
1589        var _ = this;
1590
1591        _.autoPlay();
1592        _.options.autoplay = true;
1593        _.paused = false;
1594        _.focussed = false;
1595        _.interrupted = false;
1596
1597    };
1598
1599    Slick.prototype.postSlide = function(index) {
1600
1601        var _ = this;
1602
1603        if( !_.unslicked ) {
1604
1605            _.$slider.trigger('afterChange', [_, index]);
1606
1607            _.animating = false;
1608
1609            _.setPosition();
1610
1611            _.swipeLeft = null;
1612
1613            if ( _.options.autoplay ) {
1614                _.autoPlay();
1615            }
1616
1617            if (_.options.accessibility === true) {
1618                _.initADA();
1619            }
1620
1621        }
1622
1623    };
1624
1625    Slick.prototype.prev = Slick.prototype.slickPrev = function() {
1626
1627        var _ = this;
1628
1629        _.changeSlide({
1630            data: {
1631                message: 'previous'
1632            }
1633        });
1634
1635    };
1636
1637    Slick.prototype.preventDefault = function(event) {
1638
1639        event.preventDefault();
1640
1641    };
1642
1643    Slick.prototype.progressiveLazyLoad = function( tryCount ) {
1644
1645        tryCount = tryCount || 1;
1646
1647        var _ = this,
1648            $imgsToLoad = $( 'img[data-lazy]', _.$slider ),
1649            image,
1650            imageSource,
1651            imageToLoad;
1652
1653        if ( $imgsToLoad.length ) {
1654
1655            image = $imgsToLoad.first();
1656            imageSource = image.attr('data-lazy');
1657            imageToLoad = document.createElement('img');
1658
1659            imageToLoad.onload = function() {
1660
1661                image
1662                    .attr( 'src', imageSource )
1663                    .removeAttr('data-lazy')
1664                    .removeClass('slick-loading');
1665
1666                if ( _.options.adaptiveHeight === true ) {
1667                    _.setPosition();
1668                }
1669
1670                _.$slider.trigger('lazyLoaded', [ _, image, imageSource ]);
1671                _.progressiveLazyLoad();
1672
1673            };
1674
1675            imageToLoad.onerror = function() {
1676
1677                if ( tryCount < 3 ) {
1678
1679                    /**
1680                     * try to load the image 3 times,
1681                     * leave a slight delay so we don't get
1682                     * servers blocking the request.
1683                     */
1684                    setTimeout( function() {
1685                        _.progressiveLazyLoad( tryCount + 1 );
1686                    }, 500 );
1687
1688                } else {
1689
1690                    image
1691                        .removeAttr( 'data-lazy' )
1692                        .removeClass( 'slick-loading' )
1693                        .addClass( 'slick-lazyload-error' );
1694
1695                    _.$slider.trigger('lazyLoadError', [ _, image, imageSource ]);
1696
1697                    _.progressiveLazyLoad();
1698
1699                }
1700
1701            };
1702
1703            imageToLoad.src = imageSource;
1704
1705        } else {
1706
1707            _.$slider.trigger('allImagesLoaded', [ _ ]);
1708
1709        }
1710
1711    };
1712
1713    Slick.prototype.refresh = function( initializing ) {
1714
1715        var _ = this, currentSlide, lastVisibleIndex;
1716
1717        lastVisibleIndex = _.slideCount - _.options.slidesToShow;
1718
1719        // in non-infinite sliders, we don't want to go past the
1720        // last visible index.
1721        if( !_.options.infinite && ( _.currentSlide > lastVisibleIndex )) {
1722            _.currentSlide = lastVisibleIndex;
1723        }
1724
1725        // if less slides than to show, go to start.
1726        if ( _.slideCount <= _.options.slidesToShow ) {
1727            _.currentSlide = 0;
1728
1729        }
1730
1731        currentSlide = _.currentSlide;
1732
1733        _.destroy(true);
1734
1735        $.extend(_, _.initials, { currentSlide: currentSlide });
1736
1737        _.init();
1738
1739        if( !initializing ) {
1740
1741            _.changeSlide({
1742                data: {
1743                    message: 'index',
1744                    index: currentSlide
1745                }
1746            }, false);
1747
1748        }
1749
1750    };
1751
1752    Slick.prototype.registerBreakpoints = function() {
1753
1754        var _ = this, breakpoint, currentBreakpoint, l,
1755            responsiveSettings = _.options.responsive || null;
1756
1757        if ( $.type(responsiveSettings) === 'array' && responsiveSettings.length ) {
1758
1759            _.respondTo = _.options.respondTo || 'window';
1760
1761            for ( breakpoint in responsiveSettings ) {
1762
1763                l = _.breakpoints.length-1;
1764                currentBreakpoint = responsiveSettings[breakpoint].breakpoint;
1765
1766                if (responsiveSettings.hasOwnProperty(breakpoint)) {
vendor: 12,466 bytes, lines 1766-2199
1766
1767
1768                    // loop through the breakpoints and cut out any existing
1769                    // ones with the same breakpoint number, we don't want dupes.
1770                    while( l >= 0 ) {
1771                        if( _.breakpoints[l] && _.breakpoints[l] === currentBreakpoint ) {
1772                            _.breakpoints.splice(l,1);
1773                        }
1774                        l--;
1775                    }
1776
1777                    _.breakpoints.push(currentBreakpoint);
1778                    _.breakpointSettings[currentBreakpoint] = responsiveSettings[breakpoint].settings;
1779
1780                }
1781
1782            }
1783
1784            _.breakpoints.sort(function(a, b) {
1785                return ( _.options.mobileFirst ) ? a-b : b-a;
1786            });
1787
1788        }
1789
1790    };
1791
1792    Slick.prototype.reinit = function() {
1793
1794        var _ = this;
1795
1796        _.$slides =
1797            _.$slideTrack
1798                .children(_.options.slide)
1799                .addClass('slick-slide');
1800
1801        _.slideCount = _.$slides.length;
1802
1803        if (_.currentSlide >= _.slideCount && _.currentSlide !== 0) {
1804            _.currentSlide = _.currentSlide - _.options.slidesToScroll;
1805        }
1806
1807        if (_.slideCount <= _.options.slidesToShow) {
1808            _.currentSlide = 0;
1809        }
1810
1811        _.registerBreakpoints();
1812
1813        _.setProps();
1814        _.setupInfinite();
1815        _.buildArrows();
1816        _.updateArrows();
1817        _.initArrowEvents();
1818        _.buildDots();
1819        _.updateDots();
1820        _.initDotEvents();
1821        _.cleanUpSlideEvents();
1822        _.initSlideEvents();
1823
1824        _.checkResponsive(false, true);
1825
1826        if (_.options.focusOnSelect === true) {
1827            $(_.$slideTrack).children().on('click.slick', _.selectHandler);
1828        }
1829
1830        _.setSlideClasses(typeof _.currentSlide === 'number' ? _.currentSlide : 0);
1831
1832        _.setPosition();
1833        _.focusHandler();
1834
1835        _.paused = !_.options.autoplay;
1836        _.autoPlay();
1837
1838        _.$slider.trigger('reInit', [_]);
1839
1840    };
1841
1842    Slick.prototype.resize = function() {
1843
1844        var _ = this;
1845
1846        if ($(window).width() !== _.windowWidth) {
1847            clearTimeout(_.windowDelay);
1848            _.windowDelay = window.setTimeout(function() {
1849                _.windowWidth = $(window).width();
1850                _.checkResponsive();
1851                if( !_.unslicked ) { _.setPosition(); }
1852            }, 50);
1853        }
1854    };
1855
1856    Slick.prototype.removeSlide = Slick.prototype.slickRemove = function(index, removeBefore, removeAll) {
1857
1858        var _ = this;
1859
1860        if (typeof(index) === 'boolean') {
1861            removeBefore = index;
1862            index = removeBefore === true ? 0 : _.slideCount - 1;
1863        } else {
1864            index = removeBefore === true ? --index : index;
1865        }
1866
1867        if (_.slideCount < 1 || index < 0 || index > _.slideCount - 1) {
1868            return false;
1869        }
1870
1871        _.unload();
1872
1873        if (removeAll === true) {
1874            _.$slideTrack.children().remove();
1875        } else {
1876            _.$slideTrack.children(this.options.slide).eq(index).remove();
1877        }
1878
1879        _.$slides = _.$slideTrack.children(this.options.slide);
1880
1881        _.$slideTrack.children(this.options.slide).detach();
1882
1883        _.$slideTrack.append(_.$slides);
1884
1885        _.$slidesCache = _.$slides;
1886
1887        _.reinit();
1888
1889    };
1890
1891    Slick.prototype.setCSS = function(position) {
1892
1893        var _ = this,
1894            positionProps = {},
1895            x, y;
1896
1897        if (_.options.rtl === true) {
1898            position = -position;
1899        }
1900        x = _.positionProp == 'left' ? Math.ceil(position) + 'px' : '0px';
1901        y = _.positionProp == 'top' ? Math.ceil(position) + 'px' : '0px';
1902
1903        positionProps[_.positionProp] = position;
1904
1905        if (_.transformsEnabled === false) {
1906            _.$slideTrack.css(positionProps);
1907        } else {
1908            positionProps = {};
1909            if (_.cssTransitions === false) {
1910                positionProps[_.animType] = 'translate(' + x + ', ' + y + ')';
1911                _.$slideTrack.css(positionProps);
1912            } else {
1913                positionProps[_.animType] = 'translate3d(' + x + ', ' + y + ', 0px)';
1914                _.$slideTrack.css(positionProps);
1915            }
1916        }
1917
1918    };
1919
1920    Slick.prototype.setDimensions = function() {
1921
1922        var _ = this;
1923
1924        if (_.options.vertical === false) {
1925            if (_.options.centerMode === true) {
1926                _.$list.css({
1927                    padding: ('0px ' + _.options.centerPadding)
1928                });
1929            }
1930        } else {
1931            _.$list.height(_.$slides.first().outerHeight(true) * _.options.slidesToShow);
1932            if (_.options.centerMode === true) {
1933                _.$list.css({
1934                    padding: (_.options.centerPadding + ' 0px')
1935                });
1936            }
1937        }
1938
1939        _.listWidth = _.$list.width();
1940        _.listHeight = _.$list.height();
1941
1942
1943        if (_.options.vertical === false && _.options.variableWidth === false) {
1944            _.slideWidth = Math.ceil(_.listWidth / _.options.slidesToShow);
1945            _.$slideTrack.width(Math.ceil((_.slideWidth * _.$slideTrack.children('.slick-slide').length)));
1946
1947        } else if (_.options.variableWidth === true) {
1948            _.$slideTrack.width(5000 * _.slideCount);
1949        } else {
1950            _.slideWidth = Math.ceil(_.listWidth);
1951            _.$slideTrack.height(Math.ceil((_.$slides.first().outerHeight(true) * _.$slideTrack.children('.slick-slide').length)));
1952        }
1953
1954        var offset = _.$slides.first().outerWidth(true) - _.$slides.first().width();
1955        if (_.options.variableWidth === false) _.$slideTrack.children('.slick-slide').width(_.slideWidth - offset);
1956
1957    };
1958
1959    Slick.prototype.setFade = function() {
1960
1961        var _ = this,
1962            targetLeft;
1963
1964        _.$slides.each(function(index, element) {
1965            targetLeft = (_.slideWidth * index) * -1;
1966            if (_.options.rtl === true) {
1967                $(element).css({
1968                    position: 'relative',
1969                    right: targetLeft,
1970                    top: 0,
1971                    zIndex: _.options.zIndex - 2,
1972                    opacity: 0
1973                });
1974            } else {
1975                $(element).css({
1976                    position: 'relative',
1977                    left: targetLeft,
1978                    top: 0,
1979                    zIndex: _.options.zIndex - 2,
1980                    opacity: 0
1981                });
1982            }
1983        });
1984
1985        _.$slides.eq(_.currentSlide).css({
1986            zIndex: _.options.zIndex - 1,
1987            opacity: 1
1988        });
1989
1990    };
1991
1992    Slick.prototype.setHeight = function() {
1993
1994        var _ = this;
1995
1996        if (_.options.slidesToShow === 1 && _.options.adaptiveHeight === true && _.options.vertical === false) {
1997            var targetHeight = _.$slides.eq(_.currentSlide).outerHeight(true);
1998            _.$list.css('height', targetHeight);
1999        }
2000
2001    };
2002
2003    Slick.prototype.setOption =
2004    Slick.prototype.slickSetOption = function() {
2005
2006        /**
2007         * accepts arguments in format of:
2008         *
2009         *  - for changing a single option's value:
2010         *     .slick("setOption", option, value, refresh )
2011         *
2012         *  - for changing a set of responsive options:
2013         *     .slick("setOption", 'responsive', [{}, ...], refresh )
2014         *
2015         *  - for updating multiple values at once (not responsive)
2016         *     .slick("setOption", { 'option': value, ... }, refresh )
2017         */
2018
2019        var _ = this, l, item, option, value, refresh = false, type;
2020
2021        if( $.type( arguments[0] ) === 'object' ) {
2022
2023            option =  arguments[0];
2024            refresh = arguments[1];
2025            type = 'multiple';
2026
2027        } else if ( $.type( arguments[0] ) === 'string' ) {
2028
2029            option =  arguments[0];
2030            value = arguments[1];
2031            refresh = arguments[2];
2032
2033            if ( arguments[0] === 'responsive' && $.type( arguments[1] ) === 'array' ) {
2034
2035                type = 'responsive';
2036
2037            } else if ( typeof arguments[1] !== 'undefined' ) {
2038
2039                type = 'single';
2040
2041            }
2042
2043        }
2044
2045        if ( type === 'single' ) {
2046
2047            _.options[option] = value;
2048
2049
2050        } else if ( type === 'multiple' ) {
2051
2052            $.each( option , function( opt, val ) {
2053
2054                _.options[opt] = val;
2055
2056            });
2057
2058
2059        } else if ( type === 'responsive' ) {
2060
2061            for ( item in value ) {
2062
2063                if( $.type( _.options.responsive ) !== 'array' ) {
2064
2065                    _.options.responsive = [ value[item] ];
2066
2067                } else {
2068
2069                    l = _.options.responsive.length-1;
2070
2071                    // loop through the responsive object and splice out duplicates.
2072                    while( l >= 0 ) {
2073
2074                        if( _.options.responsive[l].breakpoint === value[item].breakpoint ) {
2075
2076                            _.options.responsive.splice(l,1);
2077
2078                        }
2079
2080                        l--;
2081
2082                    }
2083
2084                    _.options.responsive.push( value[item] );
2085
2086                }
2087
2088            }
2089
2090        }
2091
2092        if ( refresh ) {
2093
2094            _.unload();
2095            _.reinit();
2096
2097        }
2098
2099    };
2100
2101    Slick.prototype.setPosition = function() {
2102
2103        var _ = this;
2104
2105        _.setDimensions();
2106
2107        _.setHeight();
2108
2109        if (_.options.fade === false) {
2110            _.setCSS(_.getLeft(_.currentSlide));
2111        } else {
2112            _.setFade();
2113        }
2114
2115        _.$slider.trigger('setPosition', [_]);
2116
2117    };
2118
2119    Slick.prototype.setProps = function() {
2120
2121        var _ = this,
2122            bodyStyle = document.body.style;
2123
2124        _.positionProp = _.options.vertical === true ? 'top' : 'left';
2125
2126        if (_.positionProp === 'top') {
2127            _.$slider.addClass('slick-vertical');
2128        } else {
2129            _.$slider.removeClass('slick-vertical');
2130        }
2131
2132        if (bodyStyle.WebkitTransition !== undefined ||
2133            bodyStyle.MozTransition !== undefined ||
2134            bodyStyle.msTransition !== undefined) {
2135            if (_.options.useCSS === true) {
2136                _.cssTransitions = true;
2137            }
2138        }
2139
2140        if ( _.options.fade ) {
2141            if ( typeof _.options.zIndex === 'number' ) {
2142                if( _.options.zIndex < 3 ) {
2143                    _.options.zIndex = 3;
2144                }
2145            } else {
2146                _.options.zIndex = _.defaults.zIndex;
2147            }
2148        }
2149
2150        if (bodyStyle.OTransform !== undefined) {
2151            _.animType = 'OTransform';
2152            _.transformType = '-o-transform';
2153            _.transitionType = 'OTransition';
2154            if (bodyStyle.perspectiveProperty === undefined && bodyStyle.webkitPerspective === undefined) _.animType = false;
2155        }
2156        if (bodyStyle.MozTransform !== undefined) {
2157            _.animType = 'MozTransform';
2158            _.transformType = '-moz-transform';
2159            _.transitionType = 'MozTransition';
2160            if (bodyStyle.perspectiveProperty === undefined && bodyStyle.MozPerspective === undefined) _.animType = false;
2161        }
2162        if (bodyStyle.webkitTransform !== undefined) {
2163            _.animType = 'webkitTransform';
2164            _.transformType = '-webkit-transform';
2165            _.transitionType = 'webkitTransition';
2166            if (bodyStyle.perspectiveProperty === undefined && bodyStyle.webkitPerspective === undefined) _.animType = false;
2167        }
2168        if (bodyStyle.msTransform !== undefined) {
2169            _.animType = 'msTransform';
2170            _.transformType = '-ms-transform';
2171            _.transitionType = 'msTransition';
2172            if (bodyStyle.msTransform === undefined) _.animType = false;
2173        }
2174        if (bodyStyle.transform !== undefined && _.animType !== false) {
2175            _.animType = 'transform';
2176            _.transformType = 'transform';
2177            _.transitionType = 'transition';
2178        }
2179        _.transformsEnabled = _.options.useTransform && (_.animType !== null && _.animType !== false);
2180    };
2181
2182
2183    Slick.prototype.setSlideClasses = function(index) {
2184
2185        var _ = this,
2186            centerOffset, allSlides, indexOffset, remainder;
2187
2188        allSlides = _.$slider
2189            .find('.slick-slide')
2190            .removeClass('slick-active slick-center slick-current')
2191            .attr('aria-hidden', 'true');
2192
2193        _.$slides
2194            .eq(index)
2195            .addClass('slick-current');
2196
2197        if (_.options.centerMode === true) {
2198
2199            
vendor: 17,874 bytes, lines 2199-2825
2199centerOffset = Math.floor(_.options.slidesToShow / 2);
2200
2201            if (_.options.infinite === true) {
2202
2203                if (index >= centerOffset && index <= (_.slideCount - 1) - centerOffset) {
2204
2205                    _.$slides
2206                        .slice(index - centerOffset, index + centerOffset + 1)
2207                        .addClass('slick-active')
2208                        .attr('aria-hidden', 'false');
2209
2210                } else {
2211
2212                    indexOffset = _.options.slidesToShow + index;
2213                    allSlides
2214                        .slice(indexOffset - centerOffset + 1, indexOffset + centerOffset + 2)
2215                        .addClass('slick-active')
2216                        .attr('aria-hidden', 'false');
2217
2218                }
2219
2220                if (index === 0) {
2221
2222                    allSlides
2223                        .eq(allSlides.length - 1 - _.options.slidesToShow)
2224                        .addClass('slick-center');
2225
2226                } else if (index === _.slideCount - 1) {
2227
2228                    allSlides
2229                        .eq(_.options.slidesToShow)
2230                        .addClass('slick-center');
2231
2232                }
2233
2234            }
2235
2236            _.$slides
2237                .eq(index)
2238                .addClass('slick-center');
2239
2240        } else {
2241
2242            if (index >= 0 && index <= (_.slideCount - _.options.slidesToShow)) {
2243
2244                _.$slides
2245                    .slice(index, index + _.options.slidesToShow)
2246                    .addClass('slick-active')
2247                    .attr('aria-hidden', 'false');
2248
2249            } else if (allSlides.length <= _.options.slidesToShow) {
2250
2251                allSlides
2252                    .addClass('slick-active')
2253                    .attr('aria-hidden', 'false');
2254
2255            } else {
2256
2257                remainder = _.slideCount % _.options.slidesToShow;
2258                indexOffset = _.options.infinite === true ? _.options.slidesToShow + index : index;
2259
2260                if (_.options.slidesToShow == _.options.slidesToScroll && (_.slideCount - index) < _.options.slidesToShow) {
2261
2262                    allSlides
2263                        .slice(indexOffset - (_.options.slidesToShow - remainder), indexOffset + remainder)
2264                        .addClass('slick-active')
2265                        .attr('aria-hidden', 'false');
2266
2267                } else {
2268
2269                    allSlides
2270                        .slice(indexOffset, indexOffset + _.options.slidesToShow)
2271                        .addClass('slick-active')
2272                        .attr('aria-hidden', 'false');
2273
2274                }
2275
2276            }
2277
2278        }
2279
2280        if (_.options.lazyLoad === 'ondemand') {
2281            _.lazyLoad();
2282        }
2283
2284    };
2285
2286    Slick.prototype.setupInfinite = function() {
2287
2288        var _ = this,
2289            i, slideIndex, infiniteCount;
2290
2291        if (_.options.fade === true) {
2292            _.options.centerMode = false;
2293        }
2294
2295        if (_.options.infinite === true && _.options.fade === false) {
2296
2297            slideIndex = null;
2298
2299            if (_.slideCount > _.options.slidesToShow) {
2300
2301                if (_.options.centerMode === true) {
2302                    infiniteCount = _.options.slidesToShow + 1;
2303                } else {
2304                    infiniteCount = _.options.slidesToShow;
2305                }
2306
2307                for (i = _.slideCount; i > (_.slideCount -
2308                        infiniteCount); i -= 1) {
2309                    slideIndex = i - 1;
2310                    $(_.$slides[slideIndex]).clone(true).attr('id', '')
2311                        .attr('data-slick-index', slideIndex - _.slideCount)
2312                        .prependTo(_.$slideTrack).addClass('slick-cloned');
2313                }
2314                for (i = 0; i < infiniteCount; i += 1) {
2315                    slideIndex = i;
2316                    $(_.$slides[slideIndex]).clone(true).attr('id', '')
2317                        .attr('data-slick-index', slideIndex + _.slideCount)
2318                        .appendTo(_.$slideTrack).addClass('slick-cloned');
2319                }
2320                _.$slideTrack.find('.slick-cloned').find('[id]').each(function() {
2321                    $(this).attr('id', '');
2322                });
2323
2324            }
2325
2326        }
2327
2328    };
2329
2330    Slick.prototype.interrupt = function( toggle ) {
2331
2332        var _ = this;
2333
2334        if( !toggle ) {
2335            _.autoPlay();
2336        }
2337        _.interrupted = toggle;
2338
2339    };
2340
2341    Slick.prototype.selectHandler = function(event) {
2342
2343        var _ = this;
2344
2345        var targetElement =
2346            $(event.target).is('.slick-slide') ?
2347                $(event.target) :
2348                $(event.target).parents('.slick-slide');
2349
2350        var index = parseInt(targetElement.attr('data-slick-index'));
2351
2352        if (!index) index = 0;
2353
2354        if (_.slideCount <= _.options.slidesToShow) {
2355
2356            _.setSlideClasses(index);
2357            _.asNavFor(index);
2358            return;
2359
2360        }
2361
2362        _.slideHandler(index);
2363
2364    };
2365
2366    Slick.prototype.slideHandler = function(index, sync, dontAnimate) {
2367
2368        var targetSlide, animSlide, oldSlide, slideLeft, targetLeft = null,
2369            _ = this, navTarget;
2370
2371        sync = sync || false;
2372
2373        if (_.animating === true && _.options.waitForAnimate === true) {
2374            return;
2375        }
2376
2377        if (_.options.fade === true && _.currentSlide === index) {
2378            return;
2379        }
2380
2381        if (_.slideCount <= _.options.slidesToShow) {
2382            return;
2383        }
2384
2385        if (sync === false) {
2386            _.asNavFor(index);
2387        }
2388
2389        targetSlide = index;
2390        targetLeft = _.getLeft(targetSlide);
2391        slideLeft = _.getLeft(_.currentSlide);
2392
2393        _.currentLeft = _.swipeLeft === null ? slideLeft : _.swipeLeft;
2394
2395        if (_.options.infinite === false && _.options.centerMode === false && (index < 0 || index > _.getDotCount() * _.options.slidesToScroll)) {
2396            if (_.options.fade === false) {
2397                targetSlide = _.currentSlide;
2398                if (dontAnimate !== true) {
2399                    _.animateSlide(slideLeft, function() {
2400                        _.postSlide(targetSlide);
2401                    });
2402                } else {
2403                    _.postSlide(targetSlide);
2404                }
2405            }
2406            return;
2407        } else if (_.options.infinite === false && _.options.centerMode === true && (index < 0 || index > (_.slideCount - _.options.slidesToScroll))) {
2408            if (_.options.fade === false) {
2409                targetSlide = _.currentSlide;
2410                if (dontAnimate !== true) {
2411                    _.animateSlide(slideLeft, function() {
2412                        _.postSlide(targetSlide);
2413                    });
2414                } else {
2415                    _.postSlide(targetSlide);
2416                }
2417            }
2418            return;
2419        }
2420
2421        if ( _.options.autoplay ) {
2422            clearInterval(_.autoPlayTimer);
2423        }
2424
2425        if (targetSlide < 0) {
2426            if (_.slideCount % _.options.slidesToScroll !== 0) {
2427                animSlide = _.slideCount - (_.slideCount % _.options.slidesToScroll);
2428            } else {
2429                animSlide = _.slideCount + targetSlide;
2430            }
2431        } else if (targetSlide >= _.slideCount) {
2432            if (_.slideCount % _.options.slidesToScroll !== 0) {
2433                animSlide = 0;
2434            } else {
2435                animSlide = targetSlide - _.slideCount;
2436            }
2437        } else {
2438            animSlide = targetSlide;
2439        }
2440
2441        _.animating = true;
2442
2443        _.$slider.trigger('beforeChange', [_, _.currentSlide, animSlide]);
2444
2445        oldSlide = _.currentSlide;
2446        _.currentSlide = animSlide;
2447
2448        _.setSlideClasses(_.currentSlide);
2449
2450        if ( _.options.asNavFor ) {
2451
2452            navTarget = _.getNavTarget();
2453            navTarget = navTarget.slick('getSlick');
2454
2455            if ( navTarget.slideCount <= navTarget.options.slidesToShow ) {
2456                navTarget.setSlideClasses(_.currentSlide);
2457            }
2458
2459        }
2460
2461        _.updateDots();
2462        _.updateArrows();
2463
2464        if (_.options.fade === true) {
2465            if (dontAnimate !== true) {
2466
2467                _.fadeSlideOut(oldSlide);
2468
2469                _.fadeSlide(animSlide, function() {
2470                    _.postSlide(animSlide);
2471                });
2472
2473            } else {
2474                _.postSlide(animSlide);
2475            }
2476            _.animateHeight();
2477            return;
2478        }
2479
2480        if (dontAnimate !== true) {
2481            _.animateSlide(targetLeft, function() {
2482                _.postSlide(animSlide);
2483            });
2484        } else {
2485            _.postSlide(animSlide);
2486        }
2487
2488    };
2489
2490    Slick.prototype.startLoad = function() {
2491
2492        var _ = this;
2493
2494        if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) {
2495
2496            _.$prevArrow.hide();
2497            _.$nextArrow.hide();
2498
2499        }
2500
2501        if (_.options.dots === true && _.slideCount > _.options.slidesToShow) {
2502
2503            _.$dots.hide();
2504
2505        }
2506
2507        _.$slider.addClass('slick-loading');
2508
2509    };
2510
2511    Slick.prototype.swipeDirection = function() {
2512
2513        var xDist, yDist, r, swipeAngle, _ = this;
2514
2515        xDist = _.touchObject.startX - _.touchObject.curX;
2516        yDist = _.touchObject.startY - _.touchObject.curY;
2517        r = Math.atan2(yDist, xDist);
2518
2519        swipeAngle = Math.round(r * 180 / Math.PI);
2520        if (swipeAngle < 0) {
2521            swipeAngle = 360 - Math.abs(swipeAngle);
2522        }
2523
2524        if ((swipeAngle <= 45) && (swipeAngle >= 0)) {
2525            return (_.options.rtl === false ? 'left' : 'right');
2526        }
2527        if ((swipeAngle <= 360) && (swipeAngle >= 315)) {
2528            return (_.options.rtl === false ? 'left' : 'right');
2529        }
2530        if ((swipeAngle >= 135) && (swipeAngle <= 225)) {
2531            return (_.options.rtl === false ? 'right' : 'left');
2532        }
2533        if (_.options.verticalSwiping === true) {
2534            if ((swipeAngle >= 35) && (swipeAngle <= 135)) {
2535                return 'down';
2536            } else {
2537                return 'up';
2538            }
2539        }
2540
2541        return 'vertical';
2542
2543    };
2544
2545    Slick.prototype.swipeEnd = function(event) {
2546
2547        var _ = this,
2548            slideCount,
2549            direction;
2550
2551        _.dragging = false;
2552        _.interrupted = false;
2553        _.shouldClick = ( _.touchObject.swipeLength > 10 ) ? false : true;
2554
2555        if ( _.touchObject.curX === undefined ) {
2556            return false;
2557        }
2558
2559        if ( _.touchObject.edgeHit === true ) {
2560            _.$slider.trigger('edge', [_, _.swipeDirection() ]);
2561        }
2562
2563        if ( _.touchObject.swipeLength >= _.touchObject.minSwipe ) {
2564
2565            direction = _.swipeDirection();
2566
2567            switch ( direction ) {
2568
2569                case 'left':
2570                case 'down':
2571
2572                    slideCount =
2573                        _.options.swipeToSlide ?
2574                            _.checkNavigable( _.currentSlide + _.getSlideCount() ) :
2575                            _.currentSlide + _.getSlideCount();
2576
2577                    _.currentDirection = 0;
2578
2579                    break;
2580
2581                case 'right':
2582                case 'up':
2583
2584                    slideCount =
2585                        _.options.swipeToSlide ?
2586                            _.checkNavigable( _.currentSlide - _.getSlideCount() ) :
2587                            _.currentSlide - _.getSlideCount();
2588
2589                    _.currentDirection = 1;
2590
2591                    break;
2592
2593                default:
2594
2595
2596            }
2597
2598            if( direction != 'vertical' ) {
2599
2600                _.slideHandler( slideCount );
2601                _.touchObject = {};
2602                _.$slider.trigger('swipe', [_, direction ]);
2603
2604            }
2605
2606        } else {
2607
2608            if ( _.touchObject.startX !== _.touchObject.curX ) {
2609
2610                _.slideHandler( _.currentSlide );
2611                _.touchObject = {};
2612
2613            }
2614
2615        }
2616
2617    };
2618
2619    Slick.prototype.swipeHandler = function(event) {
2620
2621        var _ = this;
2622
2623        if ((_.options.swipe === false) || ('ontouchend' in document && _.options.swipe === false)) {
2624            return;
2625        } else if (_.options.draggable === false && event.type.indexOf('mouse') !== -1) {
2626            return;
2627        }
2628
2629        _.touchObject.fingerCount = event.originalEvent && event.originalEvent.touches !== undefined ?
2630            event.originalEvent.touches.length : 1;
2631
2632        _.touchObject.minSwipe = _.listWidth / _.options
2633            .touchThreshold;
2634
2635        if (_.options.verticalSwiping === true) {
2636            _.touchObject.minSwipe = _.listHeight / _.options
2637                .touchThreshold;
2638        }
2639
2640        switch (event.data.action) {
2641
2642            case 'start':
2643                _.swipeStart(event);
2644                break;
2645
2646            case 'move':
2647                _.swipeMove(event);
2648                break;
2649
2650            case 'end':
2651                _.swipeEnd(event);
2652                break;
2653
2654        }
2655
2656    };
2657
2658    Slick.prototype.swipeMove = function(event) {
2659
2660        var _ = this,
2661            edgeWasHit = false,
2662            curLeft, swipeDirection, swipeLength, positionOffset, touches;
2663
2664        touches = event.originalEvent !== undefined ? event.originalEvent.touches : null;
2665
2666        if (!_.dragging || touches && touches.length !== 1) {
2667            return false;
2668        }
2669
2670        curLeft = _.getLeft(_.currentSlide);
2671
2672        _.touchObject.curX = touches !== undefined ? touches[0].pageX : event.clientX;
2673        _.touchObject.curY = touches !== undefined ? touches[0].pageY : event.clientY;
2674
2675        _.touchObject.swipeLength = Math.round(Math.sqrt(
2676            Math.pow(_.touchObject.curX - _.touchObject.startX, 2)));
2677
2678        if (_.options.verticalSwiping === true) {
2679            _.touchObject.swipeLength = Math.round(Math.sqrt(
2680                Math.pow(_.touchObject.curY - _.touchObject.startY, 2)));
2681        }
2682
2683        swipeDirection = _.swipeDirection();
2684
2685        if (swipeDirection === 'vertical') {
2686            return;
2687        }
2688
2689        if (event.originalEvent !== undefined && _.touchObject.swipeLength > 4) {
2690            event.preventDefault();
2691        }
2692
2693        positionOffset = (_.options.rtl === false ? 1 : -1) * (_.touchObject.curX > _.touchObject.startX ? 1 : -1);
2694        if (_.options.verticalSwiping === true) {
2695            positionOffset = _.touchObject.curY > _.touchObject.startY ? 1 : -1;
2696        }
2697
2698
2699        swipeLength = _.touchObject.swipeLength;
2700
2701        _.touchObject.edgeHit = false;
2702
2703        if (_.options.infinite === false) {
2704            if ((_.currentSlide === 0 && swipeDirection === 'right') || (_.currentSlide >= _.getDotCount() && swipeDirection === 'left')) {
2705                swipeLength = _.touchObject.swipeLength * _.options.edgeFriction;
2706                _.touchObject.edgeHit = true;
2707            }
2708        }
2709
2710        if (_.options.vertical === false) {
2711            _.swipeLeft = curLeft + swipeLength * positionOffset;
2712        } else {
2713            _.swipeLeft = curLeft + (swipeLength * (_.$list.height() / _.listWidth)) * positionOffset;
2714        }
2715        if (_.options.verticalSwiping === true) {
2716            _.swipeLeft = curLeft + swipeLength * positionOffset;
2717        }
2718
2719        if (_.options.fade === true || _.options.touchMove === false) {
2720            return false;
2721        }
2722
2723        if (_.animating === true) {
2724            _.swipeLeft = null;
2725            return false;
2726        }
2727
2728        _.setCSS(_.swipeLeft);
2729
2730    };
2731
2732    Slick.prototype.swipeStart = function(event) {
2733
2734        var _ = this,
2735            touches;
2736
2737        _.interrupted = true;
2738
2739        if (_.touchObject.fingerCount !== 1 || _.slideCount <= _.options.slidesToShow) {
2740            _.touchObject = {};
2741            return false;
2742        }
2743
2744        if (event.originalEvent !== undefined && event.originalEvent.touches !== undefined) {
2745            touches = event.originalEvent.touches[0];
2746        }
2747
2748        _.touchObject.startX = _.touchObject.curX = touches !== undefined ? touches.pageX : event.clientX;
2749        _.touchObject.startY = _.touchObject.curY = touches !== undefined ? touches.pageY : event.clientY;
2750
2751        _.dragging = true;
2752
2753    };
2754
2755    Slick.prototype.unfilterSlides = Slick.prototype.slickUnfilter = function() {
2756
2757        var _ = this;
2758
2759        if (_.$slidesCache !== null) {
2760
2761            _.unload();
2762
2763            _.$slideTrack.children(this.options.slide).detach();
2764
2765            _.$slidesCache.appendTo(_.$slideTrack);
2766
2767            _.reinit();
2768
2769        }
2770
2771    };
2772
2773    Slick.prototype.unload = function() {
2774
2775        var _ = this;
2776
2777        $('.slick-cloned', _.$slider).remove();
2778
2779        if (_.$dots) {
2780            _.$dots.remove();
2781        }
2782
2783        if (_.$prevArrow && _.htmlExpr.test(_.options.prevArrow)) {
2784            _.$prevArrow.remove();
2785        }
2786
2787        if (_.$nextArrow && _.htmlExpr.test(_.options.nextArrow)) {
2788            _.$nextArrow.remove();
2789        }
2790
2791        _.$slides
2792            .removeClass('slick-slide slick-active slick-visible slick-current')
2793            .attr('aria-hidden', 'true')
2794            .css('width', '');
2795
2796    };
2797
2798    Slick.prototype.unslick = function(fromBreakpoint) {
2799
2800        var _ = this;
2801        _.$slider.trigger('unslick', [_, fromBreakpoint]);
2802        _.destroy();
2803
2804    };
2805
2806    Slick.prototype.updateArrows = function() {
2807
2808        var _ = this,
2809            centerOffset;
2810
2811        centerOffset = Math.floor(_.options.slidesToShow / 2);
2812
2813        if ( _.options.arrows === true &&
2814            _.slideCount > _.options.slidesToShow &&
2815            !_.options.infinite ) {
2816
2817            _.$prevArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
2818            _.$nextArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
2819
2820            if (_.currentSlide === 0) {
2821
2822                _.$prevArrow.addClass('slick-disabled').attr('aria-disabled', 'true');
2823                _.$nextArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
2824
2825            } else if (_.currentSlide >
2825= _.slideCount - _.options.slidesToShow && _.options.centerMode === false) {
2826
2827                _.$nextArrow.addClass('slick-disabled').attr('aria-disabled', 'true');
2828                _.$prevArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
2829
2830            } else if (_.currentSlide >= _.slideCount - 1 && _.options.centerMode === true) {
2831
2832                _.$nextArrow.addClass('slick-disabled').attr('aria-disabled', 'true');
2833                _.$prevArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
2834
2835            }
2836
2837        }
2838
2839    };
2840
2841    Slick.prototype.updateDots = function() {
2842
2843        var _ = this;
2844
2845        if (_.$dots !== null) {
2846
2847            _.$dots
2848                .find('li')
2849                .removeClass('slick-active')
2850                .attr('aria-hidden', 'true');
2851
2852            _.$dots
2853                .find('li')
2854                .eq(Math.floor(_.currentSlide / _.options.slidesToScroll))
2855                .addClass('slick-active')
2856                .attr('aria-hidden', 'false');
2857
2858        }
2859
2860    };
2861
2862    Slick.prototype.visibility = function() {
2863
2864        var _ = this;
2865
2866        if ( _.options.autoplay ) {
2867
2868            if ( document[_.hidden] ) {
2869
2870                _.interrupted = true;
2871
2872            } else {
2873
2874                _.interrupted = false;
2875
2876            }
2877
2878        }
2879
2880    };
2881
2882    $.fn.slick = function() {
2883        var _ = this,
2884            opt = arguments[0],
2885            args = Array.prototype.slice.call(arguments, 1),
2886            l = _.length,
2887            i,
2888            ret;
2889        for (i = 0; i < l; i++) {
2890            if (typeof opt == 'object' || typeof opt == 'undefined')
2891                _[i].slick = new Slick(_[i], opt);
2892            else
2893                ret = _[i].slick[opt].apply(_[i].slick, args);
2894            if (typeof ret != 'undefined') return ret;
2895        }
2896        return _;
2897    };
2898
2899}));
2900;
2901/*
2902		The MIT License (MIT)
2903
2904		Copyright (c) 2014 Dirk Groenen
2905
2906		Permission is hereby granted, free of charge, to any person obtaining a copy of
2907		this software and associated documentation files (the "Software"), to deal in
2908		the Software without restriction, including without limitation the rights to
2909		use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
2910		the Software, and to permit persons to whom the Software is furnished to do so,
2911		subject to the following conditions:
2912
2913		The above copyright notice and this permission notice shall be included in all
2914		copies or substantial portions of the Software.
2915*/
2916
2917(function($){
2918		$.fn.viewportChecker = function(useroptions){
2919				// Define options and extend with user
2920				var options = {
2921						classToAdd: 'visible',
2922						classToRemove : 'invisible',
2923						classToAddForFullView : 'full-visible',
2924						removeClassAfterAnimation: false,
2925						offset: 100,
2926						repeat: false,
2927						invertBottomOffset: true,
2928						callbackFunction: function(elem, action){},
2929						scrollHorizontal: false,
2930						scrollBox: window
2931				};
2932				$.extend(options, useroptions);
2933
2934				// Cache the given element and height of the browser
2935				var $elem = this,
2936						boxSize = {height: $(options.scrollBox).height(), width: $(options.scrollBox).width()};
2937
2938				/*
2939				 * Main method that checks the elements and adds or removes the class(es)
2940				 */
2941				this.checkElements = function(){
2942						var viewportStart, viewportEnd;
2943
2944						// Set some vars to check with
2945						if (!options.scrollHorizontal){
2946								viewportStart = Math.max(
2947										$('html').scrollTop(),
2948										$('body').scrollTop(),
2949										$(window).scrollTop()
2950								);
2951								viewportEnd = (viewportStart + boxSize.height);
2952						}
2953						else{
2954								viewportStart = Math.max(
2955										$('html').scrollLeft(),
2956										$('body').scrollLeft(),
2957										$(window).scrollLeft()
2958								);
2959								viewportEnd = (viewportStart + boxSize.width);
2960						}
2961
2962						// Loop through all given dom elements
2963						$elem.each(function(){
2964								var $obj = $(this),
2965										objOptions = {},
2966										attrOptions = {};
2967
2968								//  Get any individual attribution data
2969								if ($obj.data('vp-add-class'))
2970										attrOptions.classToAdd = $obj.data('vp-add-class');
2971								if ($obj.data('vp-remove-class'))
2972										attrOptions.classToRemove = $obj.data('vp-remove-class');
2973								if ($obj.data('vp-add-class-full-view'))
2974										attrOptions.classToAddForFullView = $obj.data('vp-add-class-full-view');
2975								if ($obj.data('vp-keep-add-class'))
2976										attrOptions.removeClassAfterAnimation = $obj.data('vp-remove-after-animation');
2977								if ($obj.data('vp-offset'))
2978										attrOptions.offset = $obj.data('vp-offset');
2979								if ($obj.data('vp-repeat'))
2980										attrOptions.repeat = $obj.data('vp-repeat');
2981								if ($obj.data('vp-scrollHorizontal'))
2982										attrOptions.scrollHorizontal = $obj.data('vp-scrollHorizontal');
2983								if ($obj.data('vp-invertBottomOffset'))
2984										attrOptions.scrollHorizontal = $obj.data('vp-invertBottomOffset');
2985
2986								// Extend objOptions with data attributes and default options
2987								$.extend(objOptions, options);
2988								$.extend(objOptions, attrOptions);
2989
2990								// If class already exists; quit
2991								if ($obj.data('vp-animated') && !objOptions.repeat){
2992										return;
2993								}
2994
2995								// Check if the offset is percentage based
2996								if (String(objOptions.offset).indexOf("%") > 0)
2997										objOptions.offset = (parseInt(objOptions.offset) / 100) * boxSize.height;
2998
2999								// Get the raw start and end positions
3000								var rawStart = (!objOptions.scrollHorizontal) ? $obj.offset().top : $obj.offset().left,
3001										rawEnd = (!objOptions.scrollHorizontal) ? rawStart + $obj.height() : rawStart + $obj.width();
3002
3003								// Add the defined offset
3004								var elemStart = Math.round( rawStart ) + objOptions.offset,
3005										elemEnd = (!objOptions.scrollHorizontal) ? elemStart + $obj.height() : elemStart + $obj.width();
3006
3007								if (objOptions.invertBottomOffset)
3008										elemEnd -= (objOptions.offset * 2);
3009
3010								// Add class if in viewport
3011								if ((elemStart < viewportEnd) && (elemEnd > viewportStart)){
3012
3013										// Remove class
3014										$obj.removeClass(objOptions.classToRemove);
3015										$obj.addClass(objOptions.classToAdd);
3016
3017										// Do the callback function. Callback wil send the jQuery object as parameter
3018										objOptions.callbackFunction($obj, "add");
3019
3020										// Check if full element is in view
3021										if (rawEnd <= viewportEnd && rawStart >= viewportStart)
3022												$obj.addClass(objOptions.classToAddForFullView);
3023										else
3024												$obj.removeClass(objOptions.classToAddForFullView);
3025
3026										// Set element as already animated
3027										$obj.data('vp-animated', true);
3028
3029										if (objOptions.removeClassAfterAnimation) {
3030												$obj.one('webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend', function(){
3031														$obj.removeClass(objOptions.classToAdd);
3032												});
3033										}
3034
3035								// Remove class if not in viewport and repeat is true
3036								} else if ($obj.hasClass(objOptions.classToAdd) && (objOptions.repeat)){
3037										$obj.removeClass(objOptions.classToAdd + " " + objOptions.classToAddForFullView);
3038
3039										// Do the callback function.
3040										objOptions.callbackFunction($obj, "remove");
3041
3042										// Remove already-animated-flag
3043										$obj.data('vp-animated', false);
3044								}
3045						});
3046
3047				};
3048
3049				/**
3050				 * Binding the correct event listener is still a tricky thing.
3051				 * People have expierenced sloppy scrolling when both scroll and touch
3052				 * events are added, but to make sure devices with both scroll and touch
3053				 * are handles too we always have to add the window.scroll event
3054				 *
vendor: 9,474 bytes, lines 3055-3352
3055				 * @see  https://github.com/dirkgroenen/jQuery-viewport-checker/issues/25
3056				 * @see  https://github.com/dirkgroenen/jQuery-viewport-checker/issues/27
3057				 */
3058
3059				// Select the correct events
3060				if( 'ontouchstart' in window || 'onmsgesturechange' in window ){
3061						// Device with touchscreen
3062						$(document).bind("touchmove MSPointerMove pointermove", this.checkElements);
3063				}
3064
3065				// Always load on window load
3066				$(options.scrollBox).bind("load scroll", this.checkElements);
3067
3068				// On resize change the height var
3069				$(window).resize(function(e){
3070						boxSize = {height: $(options.scrollBox).height(), width: $(options.scrollBox).width()};
3071						$elem.checkElements();
3072				});
3073
3074				// trigger inital check if elements already visible
3075				this.checkElements();
3076
3077				// Default jquery plugin behaviour
3078				return this;
3079		};
3080})(jQuery);
3081;
3082// Generated by CoffeeScript 1.6.2
3083/**
3084@license Sticky-kit v1.1.3 | MIT | Leaf Corcoran 2015 | http://leafo.net
3085*/
3086
3087
3088(function() {
3089  var $, win;
3090
3091  $ = this.jQuery || window.jQuery;
3092
3093  win = $(window);
3094
3095  $.fn.stick_in_parent = function(opts) {
3096    var doc, elm, enable_bottoming, inner_scrolling, manual_spacer, offset_top, outer_width, parent_selector, recalc_every, sticky_class, _fn, _i, _len;
3097
3098    if (opts == null) {
3099      opts = {};
3100    }
3101    sticky_class = opts.sticky_class, inner_scrolling = opts.inner_scrolling, recalc_every = opts.recalc_every, parent_selector = opts.parent, offset_top = opts.offset_top, manual_spacer = opts.spacer, enable_bottoming = opts.bottoming;
3102    if (offset_top == null) {
3103      offset_top = 0;
3104    }
3105    if (parent_selector == null) {
3106      parent_selector = void 0;
3107    }
3108    if (inner_scrolling == null) {
3109      inner_scrolling = true;
3110    }
3111    if (sticky_class == null) {
3112      sticky_class = "is_stuck";
3113    }
3114    doc = $(document);
3115    if (enable_bottoming == null) {
3116      enable_bottoming = true;
3117    }
3118    outer_width = function(el) {
3119      var computed, w, _el;
3120
3121      if (window.getComputedStyle) {
3122        _el = el[0];
3123        computed = window.getComputedStyle(el[0]);
3124        w = parseFloat(computed.getPropertyValue("width")) + parseFloat(computed.getPropertyValue("margin-left")) + parseFloat(computed.getPropertyValue("margin-right"));
3125        if (computed.getPropertyValue("box-sizing") !== "border-box") {
3126          w += parseFloat(computed.getPropertyValue("border-left-width")) + parseFloat(computed.getPropertyValue("border-right-width")) + parseFloat(computed.getPropertyValue("padding-left")) + parseFloat(computed.getPropertyValue("padding-right"));
3127        }
3128        return w;
3129      } else {
3130        return el.outerWidth(true);
3131      }
3132    };
3133    _fn = function(elm, padding_bottom, parent_top, parent_height, top, height, el_float, detached) {
3134      var bottomed, detach, fixed, last_pos, last_scroll_height, offset, parent, recalc, recalc_and_tick, recalc_counter, spacer, tick;
3135
3136      if (elm.data("sticky_kit")) {
3137        return;
3138      }
3139      elm.data("sticky_kit", true);
3140      last_scroll_height = doc.height();
3141      parent = elm.parent();
3142      if (parent_selector != null) {
3143        parent = parent.closest(parent_selector);
3144      }
3145      if (!parent.length) {
3146        throw "failed to find stick parent";
3147      }
3148      fixed = false;
3149      bottomed = false;
3150      spacer = manual_spacer != null ? manual_spacer && elm.closest(manual_spacer) : $("<div />");
3151      if (spacer) {
3152        spacer.css('position', elm.css('position'));
3153      }
3154      recalc = function() {
3155        var border_top, padding_top, restore;
3156
3157        if (detached) {
3158          return;
3159        }
3160        last_scroll_height = doc.height();
3161        border_top = parseInt(parent.css("border-top-width"), 10);
3162        padding_top = parseInt(parent.css("padding-top"), 10);
3163        padding_bottom = parseInt(parent.css("padding-bottom"), 10);
3164        parent_top = parent.offset().top + border_top + padding_top;
3165        parent_height = parent.height();
3166        if (fixed) {
3167          fixed = false;
3168          bottomed = false;
3169          if (manual_spacer == null) {
3170            elm.insertAfter(spacer);
3171            spacer.detach();
3172          }
3173          elm.css({
3174            position: "",
3175            top: "",
3176            width: "",
3177            bottom: ""
3178          }).removeClass(sticky_class);
3179          restore = true;
3180        }
3181        top = elm.offset().top - (parseInt(elm.css("margin-top"), 10) || 0) - offset_top;
3182        height = elm.outerHeight(true);
3183        el_float = elm.css("float");
3184        if (spacer) {
3185          spacer.css({
3186            width: outer_width(elm),
3187            height: height,
3188            display: elm.css("display"),
3189            "vertical-align": elm.css("vertical-align"),
3190            "float": el_float
3191          });
3192        }
3193        if (restore) {
3194          return tick();
3195        }
3196      };
3197      recalc();
3198      if (height === parent_height) {
3199        return;
3200      }
3201      last_pos = void 0;
3202      offset = offset_top;
3203      recalc_counter = recalc_every;
3204      tick = function() {
3205        var css, delta, recalced, scroll, will_bottom, win_height;
3206
3207        if (detached) {
3208          return;
3209        }
3210        recalced = false;
3211        if (recalc_counter != null) {
3212          recalc_counter -= 1;
3213          if (recalc_counter <= 0) {
3214            recalc_counter = recalc_every;
3215            recalc();
3216            recalced = true;
3217          }
3218        }
3219        if (!recalced && doc.height() !== last_scroll_height) {
3220          recalc();
3221          recalced = true;
3222        }
3223        scroll = win.scrollTop();
3224        if (last_pos != null) {
3225          delta = scroll - last_pos;
3226        }
3227        last_pos = scroll;
3228        if (fixed) {
3229          if (enable_bottoming) {
3230            will_bottom = scroll + height + offset > parent_height + parent_top;
3231            if (bottomed && !will_bottom) {
3232              bottomed = false;
3233              elm.css({
3234                position: "fixed",
3235                bottom: "",
3236                top: offset
3237              }).trigger("sticky_kit:unbottom");
3238            }
3239          }
3240          if (scroll < top) {
3241            fixed = false;
3242            offset = offset_top;
3243            if (manual_spacer == null) {
3244              if (el_float === "left" || el_float === "right") {
3245                elm.insertAfter(spacer);
3246              }
3247              spacer.detach();
3248            }
3249            css = {
3250              position: "",
3251              width: "",
3252              top: ""
3253            };
3254            elm.css(css).removeClass(sticky_class).trigger("sticky_kit:unstick");
3255          }
3256          if (inner_scrolling) {
3257            win_height = win.height();
3258            if (height + offset_top > win_height) {
3259              if (!bottomed) {
3260                offset -= delta;
3261                offset = Math.max(win_height - height, offset);
3262                offset = Math.min(offset_top, offset);
3263                if (fixed) {
3264                  elm.css({
3265                    top: offset + "px"
3266                  });
3267                }
3268              }
3269            }
3270          }
3271        } else {
3272          if (scroll > top) {
3273            fixed = true;
3274            css = {
3275              position: "fixed",
3276              top: offset
3277            };
3278            css.width = elm.css("box-sizing") === "border-box" ? elm.outerWidth() + "px" : elm.width() + "px";
3279            elm.css(css).addClass(sticky_class);
3280            if (manual_spacer == null) {
3281              elm.after(spacer);
3282              if (el_float === "left" || el_float === "right") {
3283                spacer.append(elm);
3284              }
3285            }
3286            elm.trigger("sticky_kit:stick");
3287          }
3288        }
3289        if (fixed && enable_bottoming) {
3290          if (will_bottom == null) {
3291            will_bottom = scroll + height + offset > parent_height + parent_top;
3292          }
3293          if (!bottomed && will_bottom) {
3294            bottomed = true;
3295            if (parent.css("position") === "static") {
3296              parent.css({
3297                position: "relative"
3298              });
3299            }
3300            return elm.css({
3301              position: "absolute",
3302              bottom: padding_bottom,
3303              top: "auto"
3304            }).trigger("sticky_kit:bottom");
3305          }
3306        }
3307      };
3308      recalc_and_tick = function() {
3309        recalc();
3310        return tick();
3311      };
3312      detach = function() {
3313        detached = true;
3314        win.off("touchmove", tick);
3315        win.off("scroll", tick);
3316        win.off("resize", recalc_and_tick);
3317        $(document.body).off("sticky_kit:recalc", recalc_and_tick);
3318        elm.off("sticky_kit:detach", detach);
3319        elm.removeData("sticky_kit");
3320        elm.css({
3321          position: "",
3322          bottom: "",
3323          top: "",
3324          width: ""
3325        });
3326        parent.position("position", "");
3327        if (fixed) {
3328          if (manual_spacer == null) {
3329            if (el_float === "left" || el_float === "right") {
3330              elm.insertAfter(spacer);
3331            }
3332            spacer.remove();
3333          }
3334          return elm.removeClass(sticky_class);
3335        }
3336      };
3337      win.on("touchmove", tick);
3338      win.on("scroll", tick);
3339      win.on("resize", recalc_and_tick);
3340      $(document.body).on("sticky_kit:recalc", recalc_and_tick);
3341      elm.on("sticky_kit:detach", detach);
3342      return setTimeout(tick, 0);
3343    };
3344    for (_i = 0, _len = this.length; _i < _len; _i++) {
3345      elm = this[_i];
3346      _fn($(elm));
3347    }
3348    return this;
3349  };
3350
3351}).call(this);
3352;

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.