PageSourceSearch

https://historywm.com/themes/historywm/assets/js/script.js?v=1.1

js historywm.com collected 2026-09-24 09:58:00 UTC 566,354 bytes, 15,388 lines download raw bytes

1(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
2'use strict';
3
4var requestAnimFrame = (function() {
5  return window.requestAnimationFrame ||
6    window.webkitRequestAnimationFrame ||
7    function (callback) {
8      window.setTimeout(callback, 1000 / 60);
9    };
10}());
11
12function decouple(node, event, fn) {
13  var eve,
14      tracking = false;
15
16  function captureEvent(e) {
17    eve = e;
18    track();
19  }
20
21  function track() {
22    if (!tracking) {
23      requestAnimFrame(update);
24      tracking = true;
25    }
26  }
27
28  function update() {
29    fn.call(node, eve);
30    tracking = false;
31  }
32
33  node.addEventListener(event, captureEvent, false);
34
35  return captureEvent;
36}
37
38/**
39 * Expose decouple
40 */
41module.exports = decouple;
42
43},{}],2:[function(require,module,exports){
44/**
45 * matchesSelector v2.0.2
46 * matchesSelector( element, '.selector' )
47 * MIT license
48 */
49
50/*jshint browser: true, strict: true, undef: true, unused: true */
51
52( function( window, factory ) {
53  /*global define: false, module: false */
54  'use strict';
55  // universal module definition
56  if ( typeof define == 'function' && define.amd ) {
57    // AMD
58    define( factory );
59  } else if ( typeof module == 'object' && module.exports ) {
60    // CommonJS
61    module.exports = factory();
62  } else {
63    // browser global
64    window.matchesSelector = factory();
65  }
66
67}( window, function factory() {
68  'use strict';
69
70  var matchesMethod = ( function() {
71    var ElemProto = window.Element.prototype;
72    // check for the standard method name first
73    if ( ElemProto.matches ) {
74      return 'matches';
75    }
76    // check un-prefixed
77    if ( ElemProto.matchesSelector ) {
78      return 'matchesSelector';
79    }
80    // check vendor prefixes
81    var prefixes = [ 'webkit', 'moz', 'ms', 'o' ];
82
83    for ( var i=0; i < prefixes.length; i++ ) {
84      var prefix = prefixes[i];
85      var method = prefix + 'MatchesSelector';
86      if ( ElemProto[ method ] ) {
87        return method;
88      }
89    }
90  })();
91
92  return function matchesSelector( elem, selector ) {
93    return elem[ matchesMethod ]( selector );
94  };
95
96}));
97
98},{}],3:[function(require,module,exports){
99"use strict";
100
101var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
102
103exports.__esModule = true;
104/**
105 * Creates a new instance of Emitter.
106 * @class
107 * @returns {Object} Returns a new instance of Emitter.
108 * @example
109 * // Creates a new instance of Emitter.
110 * var Emitter = require('emitter');
111 *
112 * var emitter = new Emitter();
113 */
114
115var Emitter = (function () {
116  function Emitter() {
117    _classCallCheck(this, Emitter);
118  }
119
120  /**
121   * Adds a listener to the collection for the specified event.
122   * @memberof! Emitter.prototype
123   * @function
124   * @param {String} event - The event name.
125   * @param {Function} listener - A listener function to add.
126   * @returns {Object} Returns an instance of Emitter.
127   * @example
128   * // Add an event listener to "foo" event.
129   * emitter.on('foo', listener);
130   */
131
132  Emitter.prototype.on = function on(event, listener) {
133    // Use the current collection or create it.
134    this._eventCollection = this._eventCollection || {};
135
136    // Use the current collection of an event or create it.
137    this._eventCollection[event] = this._eventCollection[event] || [];
138
139    // Appends the listener into the collection of the given event
140    this._eventCollection[event].push(listener);
141
142    return this;
143  };
144
145  /**
146   * Adds a listener to the collection for the specified event that will be called only once.
147   * @memberof! Emitter.prototype
148   * @function
149   * @param {String} event - The event name.
150   * @param {Function} listener - A listener function to add.
151   * @returns {Object} Returns an instance of Emitter.
152   * @example
153   * // Will add an event handler to "foo" event once.
154   * emitter.once('foo', listener);
155   */
156
157  Emitter.prototype.once = function once(event, listener) {
158    var self = this;
159
160    function fn() {
161      self.off(event, fn);
162      listener.apply(this, arguments);
163    }
164
165    fn.listener = listener;
166
167    this.on(event, fn);
168
169    return this;
170  };
171
172  /**
173   * Removes a listener from the collection for the specified event.
174   * @memberof! Emitter.prototype
175   * @function
176   * @param {String} event - The event name.
177   * @param {Function} listener - A listener function to remove.
178   * @returns {Object} Returns an instance of Emitter.
179   * @example
180   * // Remove a given listener.
181   * emitter.off('foo', listener);
182   */
183
184  Emitter.prototype.off = function off(event, listener) {
185
186    var listeners = undefined;
187
188    // Defines listeners value.
189    if (!this._eventCollection || !(listeners = this._eventCollection[event])) {
190      return this;
191    }
192
193    listeners.forEach(function (fn, i) {
194      if (fn === listener || fn.listener === listener) {
195        // Removes the given listener.
196        listeners.splice(i, 1);
197      }
198    });
199
200    // Removes an empty event collection.
201    if (listeners.length === 0) {
202      delete this._eventCollection[event];
203    }
204
205    return this;
206  };
207
208  /**
209   * Execute each item in the listener collection in order with the specified data.
210   * @memberof! Emitter.prototype
211   * @function
212   * @param {String} event - The name of the event you want to emit.
213   * @param {...Object} data - Data to pass to the listeners.
214   * @returns {Object} Returns an instance of Emitter.
215   * @example
216   * // Emits the "foo" event with 'param1' and 'param2' as arguments.
217   * emitter.emit('foo', 'param1', 'param2');
218   */
219
220  Emitter.prototype.emit = function emit(event) {
221    var _this = this;
222
223    for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
224      args[_key - 1] = arguments[_key];
225    }
226
227    var listeners = undefined;
228
229    // Defines listeners value.
230    if (!this._eventCollection || !(listeners = this._eventCollection[event])) {
231      return this;
232    }
233
234    // Clone listeners
235    listeners = listeners.slice(0);
236
237    listeners.forEach(function (fn) {
238      return fn.apply(_this, args);
239    });
240
241    return this;
242  };
243
244  return Emitter;
245})();
246
247/**
248 * Exports Emitter
249 */
250exports["default"] = Emitter;
251module.exports = exports["default"];
252},{}],4:[function(require,module,exports){
253/**
254 * EvEmitter v1.1.0
255 * Lil' event emitter
256 * MIT License
257 */
258
259/* jshint unused: true, undef: true, strict: true */
260
261( function( global, factory ) {
262  // universal module definition
263  /* jshint strict: false */ /* globals define, module, window */
264  if ( typeof define == 'function' && define.amd ) {
265    // AMD - RequireJS
266    define( factory );
267  } else if ( typeof module == 'object' && module.exports ) {
268    // CommonJS - Browserify, Webpack
269    module.exports = factory();
270  } else {
271    // Browser globals
272    global.EvEmitter = factory();
273  }
274
275}( typeof window != 'undefined' ? window : this, function() {
276
277"use strict";
278
279function EvEmitter() {}
280
281var proto = EvEmitter.prototype;
282
283proto.on = function( eventName, listener ) {
284  if ( !eventName || !listener ) {
285    return;
286  }
287  // set events hash
288  var events = this._events = this._events || {};
289  // set listeners array
290  var listeners = events[ eventName ] = events[ eventName ] || [];
291  // only add once
292  if ( listeners.indexOf( listener ) == -1 ) {
293    listeners.push( listener );
294  }
295
296  return this;
297};
298
299proto.once = function( eventName, listener ) {
300  if ( !eventName || !listener ) {
301    return;
302  }
303  // add event
304  this.on( eventName, listener );
305  // set once flag
306  // set onceEvents hash
307  var onceEvents = this._onceEvents = this._onceEvents || {};
308  // set onceListeners object
309  var onceListeners = onceEvents[ eventName ] = onceEvents[ eventName ] || {};
310  // set flag
311  onceListeners[ listener ] = true;
312
313  return this;
314};
315
316proto.off = function( eventName, listener ) {
317  var listeners = this._events && this._events[ eventName ];
318  if ( !listeners || !listeners.length ) {
319    return;
320  }
321  var index = listeners.indexOf( listener );
322  if ( index != -1 ) {
323    listeners.splice( index, 1 );
324  }
325
326  return this;
327};
328
329proto.emitEvent = function( eventName, args ) {
330  var listeners = this._events && this._events[ eventName ];
331  if ( !listeners || !listeners.length ) {
332    return;
333  }
334  // copy over to avoid interference if .off() in listener
335  listeners = listeners.slice(0);
336  args = args || [];
337  // once stuff
338  var onceListeners = this._onceEvents && this._onceEvents[ eventName ];
339
340  for ( var i=0; i < listeners.length; i++ ) {
341    var listener = listeners[i]
342    var isOnce = onceListeners && onceListeners[ listener ];
343    if ( isOnce ) {
344      // remove listener
345      // remove before trigger to prevent recursion
346      this.off( eventName, listener );
347      // unset once flag
348      delete onceListeners[ listener ];
349    }
350    // trigger listener
351    listener.apply( this, args );
352  }
353
354  return this;
355};
356
357proto.allOff = function() {
358  delete this._events;
359  delete this._onceEvents;
360};
361
362return EvEmitter;
363
364}));
365
366},{}],5:[function(require,module,exports){
367/**
368 * Fizzy UI utils v2.0.5
369 * MIT license
370 */
371
372/*jshint browser: true, undef: true, unused: true, strict: true */
373
374( function( window, factory ) {
375  // universal module definition
376  /*jshint strict: false */ /*globals define, module, require */
377
378  if ( typeof define == 'function' && define.amd ) {
379    // AMD
380    define( [
381      'desandro-matches-selector/matches-selector'
382    ], function( matchesSelector ) {
383      return factory( window, matchesSelector );
384    });
385  } else if ( typeof module == 'object' && module.exports ) {
386    // CommonJS
387    module.exports = factory(
388      window,
389      require('desandro-matches-selector')
390    );
391  } else {
392    // browser global
393    window.fizzyUIUtils = factory(
394      window,
395      window.matchesSelector
396    );
397  }
398
399}( window, function factory( window, matchesSelector ) {
400
401'use strict';
402
403var utils = {};
404
405// ----- extend ----- //
406
407// extends objects
408utils.extend = function( a, b ) {
409  for ( var prop in b ) {
410    a[ prop ] = b[ prop ];
411  }
412  return a;
413};
414
415// ----- modulo ----- //
416
417utils.modulo = function( num, div ) {
418  return ( ( num % div ) + div ) % div;
419};
420
421// ----- makeArray ----- //
422
423// turn element or nodeList into an array
424utils.makeArray = function( obj ) {
425  var ary = [];
426  if ( Array.isArray( obj ) ) {
427    // use object if already an array
428    ary = obj;
429  } else if ( obj && typeof obj == 'object' &&
430    typeof obj.length == 'number' ) {
431    // convert nodeList to array
432    for ( var i=0; i < obj.length; i++ ) {
433      ary.push( obj[i] );
434    }
435  } else {
436    // array of single index
437    ary.push( obj );
438  }
439  return ary;
440};
441
442// ----- removeFrom ----- //
443
444utils.removeFrom = function( ary, obj ) {
445  var index = ary.indexOf( obj );
446  if ( index != -1 ) {
447    ary.splice( index, 1 );
448  }
449};
450
451// ----- getParent ----- //
452
453utils.getParent = function( elem, selector ) {
454  while ( elem.parentNode && elem != document.body ) {
455    elem = elem.parentNode;
456    if ( matchesSelector( elem, selector ) ) {
457      return elem;
458    }
459  }
460};
461
462// ----- getQueryElement ----- //
463
464// use element as selector string
465utils.getQueryElement = function( elem ) {
466  if ( typeof elem == 'string' ) {
467    return document.querySelector( elem );
468  }
469  return elem;
470};
471
472// ----- handleEvent ----- //
473
474// enable .ontype to trigger from .addEventListener( elem, 'type' )
475utils.handleEvent = function( event ) {
476  var method = 'on' + event.type;
477  if ( this[ method ] ) {
478    this[ method ]( event );
479  }
480};
481
482// ----- filterFindElements ----- //
483
484utils.filterFindElements = function( elems, selector ) {
485  // make array of elems
486  elems = utils.makeArray( elems );
487  var ffElems = [];
488
489  elems.forEach( function( elem ) {
490    // check that elem is an actual element
491    if ( !( elem instanceof HTMLElement ) ) {
492      return;
493    }
494    // add elem if no selector
495    if ( !selector ) {
496      ffElems.push( elem );
497      return;
498    }
499    // filter & find items if we have a selector
500    // filter
501    if ( matchesSelector( elem, selector ) ) {
502      ffElems.push( elem );
503    }
504    // find children
505    var childElems = elem.querySelectorAll( selector );
506    // concat childElems to filterFound array
507    for ( var i=0; i < childElems.length; i++ ) {
508      ffElems.push( childElems[i] );
509    }
510  });
511
512  return ffElems;
513};
514
515// ----- debounceMethod ----- //
516
517utils.debounceMethod = function( _class, methodName, threshold ) {
518  // original method
519  var method = _class.prototype[ methodName ];
520  var timeoutName = methodName + 'Timeout';
521
522  _class.prototype[ methodName ] = function() {
523    var timeout = this[ timeoutName ];
524    if ( timeout ) {
525      clearTimeout( timeout );
526    }
527    var args = arguments;
528
529    var _this = this;
530    this[ timeoutName ] = setTimeout( function() {
531      method.apply( _this, args );
532      delete _this[ timeoutName ];
533    }, threshold || 100 );
534  };
535};
536
537// ----- docReady ----- //
538
539utils.docReady = function( callback ) {
540  var readyState = document.readyState;
541  if ( readyState == 'complete' || readyState == 'interactive' ) {
542    // do async to allow for other scripts to run. metafizzy/flickity#441
543    setTimeout( callback );
544  } else {
545    document.addEventListener( 'DOMContentLoaded', callback );
546  }
547};
548
549// ----- htmlInit ----- //
550
551// http://jamesroberts.name/blog/2010/02/22/string-functions-for-javascript-trim-to-camel-case-to-dashed-and-to-underscore/
552utils.toDashed = function( str ) {
553  return str.replace( /(.)([A-Z])/g, function( match, $1, $2 ) {
554    return $1 + '-' + $2;
555  }).toLowerCase();
556};
557
558var console = window.console;
559/**
560 * allow user to initialize classes via [data-namespace] or .js-namespace class
561 * htmlInit( Widget, 'widgetName' )
562 * options are parsed from data-namespace-options
563 */
564utils.htmlInit = function( WidgetClass, namespace ) {
565  utils.docReady( function() {
566    var dashedNamespace = utils.toDashed( namespace );
567    var dataAttr = 'data-' + dashedNamespace;
568    var dataAttrElems = document.querySelectorAll( '[' + dataAttr + ']' );
569    var jsDashElems = document.querySelectorAll( '.js-' + dashedNamespace );
570    var elems = utils.makeArray( dataAttrElems )
571      .concat( utils.makeArray( jsDashElems ) );
572    var dataOptionsAttr = dataAttr + '-options';
573    var jQuery = window.jQuery;
574
575    elems.forEach( function( elem ) {
576      var attr = elem.getAttribute( dataAttr ) ||
577        elem.getAttribute( dataOptionsAttr );
578      var options;
579      try {
580        options = attr && JSON.parse( attr );
581      } catch ( error ) {
582        // log error, do not initialize
583        if ( console ) {
584          console.error( 'Error parsing ' + dataAttr + ' on ' + elem.className +
585          ': ' + error );
586        }
587        return;
588      }
589      // initialize
590      var instance = new WidgetClass( elem, options );
591      // make available via $().data('namespace')
592      if ( jQuery ) {
593        jQuery.data( elem, namespace, instance );
594      }
595    });
596
597  });
598};
599
600// -----  ----- //
601
602return utils;
603
604}));
605
606},{"desandro-matches-selector":2}],6:[function(require,module,exports){
607// button
608( function( window, factory ) {
609  // universal module definition
610  /* globals define, module, require */
611  if ( typeof define == 'function' && define.amd ) {
612    // AMD
613    define( [
614      './core',
615      'fizzy-ui-utils/utils',
616    ], function( InfiniteScroll, utils ) {
617      return factory( window, InfiniteScroll, utils );
618    });
619  } else if ( typeof module == 'object' && module.exports ) {
620    // CommonJS
621    module.exports = factory(
622      window,
623      require('./core'),
624      require('fizzy-ui-utils')
625    );
626  } else {
627    // browser global
628    factory(
629      window,
630      window.InfiniteScroll,
631      window.fizzyUIUtils
632    );
633  }
634
635}( window, function factory( window, InfiniteScroll, utils ) {
636
637// InfiniteScroll.defaults.button = null;
638
639InfiniteScroll.create.button = function() {
640  var buttonElem = utils.getQueryElement( this.options.button );
641  if ( buttonElem ) {
642    this.button = new InfiniteScrollButton( buttonElem, this );
643    return;
644  }
645};
646
647InfiniteScroll.destroy.button = function() {
648  if ( this.button ) {
649    this.button.destroy();
650  }
651};
652
653// -------------------------- InfiniteScrollButton -------------------------- //
654
655function InfiniteScrollButton( element, infScroll ) {
656  this.element = element;
657  this.infScroll = infScroll;
658  // events
659  this.clickHandler = this.onClick.bind( this );
660  this.element.addEventListener( 'click', this.clickHandler );
661  infScroll.on( 'request', this.disable.bind( this ) );
662  infScroll.on( 'load', this.enable.bind( this ) );
663  infScroll.on( 'error', this.hide.bind( this ) );
664  infScroll.on( 'last', this.hide.bind( this ) );
665}
666
667InfiniteScrollButton.prototype.onClick = function( event ) {
668  event.preventDefault();
669  this.infScroll.loadNextPage();
670};
671
672InfiniteScrollButton.prototype.enable = function() {
673  this.element.removeAttribute('disabled');
674};
675
676InfiniteScrollButton.prototype.disable = function() {
677  this.element.disabled = 'disabled';
678};
679
680InfiniteScrollButton.prototype.hide = function() {
681  this.element.style.display = 'none';
682};
683
684InfiniteScrollButton.prototype.destroy = function() {
685  this.element.removeEventListener( 'click', this.clickHandler );
686};
687
688// --------------------------  -------------------------- //
689
690InfiniteScroll.Button = InfiniteScrollButton;
691
692return InfiniteScroll;
693
694}));
695
696},{"./core":7,"fizzy-ui-utils":5}],7:[function(require,module,exports){
697// core
698( function( window, factory ) {
699  // universal module definition
700  /* globals define, module, require */
701  if ( typeof define == 'function' && define.amd ) {
702    // AMD
703    define( [
704      'ev-emitter/ev-emitter',
705      'fizzy-ui-utils/utils',
706    ], function( EvEmitter, utils) {
707      return factory( window, EvEmitter, utils );
708    });
709  } else if ( typeof module == 'object' && module.exports ) {
710    // CommonJS
711    module.exports = factory(
712      window,
713      require('ev-emitter'),
714      require('fizzy-ui-utils')
715    );
716  } else {
717    // browser global
718    window.InfiniteScroll = factory(
719      window,
720      window.EvEmitter,
721      window.fizzyUIUtils
722    );
723  }
724
725}( window, function factory( window, EvEmitter, utils ) {
726
727var jQuery = window.jQuery;
728// internal store of all InfiniteScroll intances
729var instances = {};
730
731function InfiniteScroll( element, options ) {
732  var queryElem = utils.getQueryElement( element );
733
734  if ( !queryElem ) {
735    console.error( 'Bad element for InfiniteScroll: ' + ( queryElem || element ) );
736    return;
737  }
738  element = queryElem;
739  // do not initialize twice on same element
740  if ( element.infiniteScrollGUID ) {
741    var instance = instances[ element.infiniteScrollGUID ];
742    instance.option( options );
743    return instance;
744  }
745
746  this.element = element;
747  // options
748  this.options = utils.extend( {}, InfiniteScroll.defaults );
749  this.option( options );
750  // add jQuery
751  if ( jQuery ) {
752    this.$element = jQuery( this.element );
753  }
754
755  this.create();
756}
757
758// defaults
759InfiniteScroll.defaults = {
760  // path: null,
761  // hideNav: null,
762  // debug: false,
763};
764
765// create & destroy methods
766InfiniteScroll.create = {};
767InfiniteScroll.destroy = {};
768
769var proto = InfiniteScroll.prototype;
770// inherit EvEmitter
771utils.extend( proto, EvEmitter.prototype );
772
773// --------------------------  -------------------------- //
774
775// globally unique identifiers
776var GUID = 0;
777
778proto.create = function() {
779  // create core
780  // add id for InfiniteScroll.data
781  var id = this.guid = ++GUID;
782  this.element.infiniteScrollGUID = id; // expando
783  instances[ id ] = this; // associate via id
784  // properties
785  this.pageIndex = 1; // default to first page
786  this.loadCount = 0;
787  this.updateGetPath();
788  // bail if getPath not set
789  if ( !this.getPath ) {
790    console.error('Disabling InfiniteScroll');
791    return;
792  }
793  this.updateGetAbsolutePath();
794  this.log( 'initialized', [ this.element.className ] );
795  this.callOnInit();
796  // create features
797  for ( var method in InfiniteScroll.create ) {
798    InfiniteScroll.create[ method ].call( this );
799  }
800};
801
802proto.option = function( opts ) {
803  utils.extend( this.options, opts );
804};
805
806// call onInit option, used for binding events on init
807proto.callOnInit = function() {
808  var onInit = this.options.onInit;
809  if ( onInit ) {
810    onInit.call( this, this );
811  }
812};
813
814// ----- events ----- //
815
816proto.dispatchEvent = function( type, event, args ) {
817  this.log( type, args );
818  var emitArgs = event ? [ event ].concat( args ) : args;
819  this.emitEvent( type, emitArgs );
820  // trigger jQuery event
821  if ( !jQuery || !this.$element ) {
822    return;
823  }
824  // namespace jQuery event
825  type += '.infiniteScroll';
826  var $event = type;
827  if ( event ) {
828    // create jQuery event
829    var jQEvent = jQuery.Event( event );
830    jQEvent.type = type;
831    $event = jQEvent;
832  }
833  this.$element.trigger( $event, args );
834};
835
836var loggers = {
837  initialized: function( className ) {
838    return 'on ' + className;
839  },
840  request: function( path ) {
841    return 'URL: ' + path;
842  },
843  load: function( response, path ) {
844    return ( response.title || '' ) + '. URL: ' + path;
845  },
846  error: function( error, path ) {
847    return error + '. URL: ' + path;
848  },
849  append: function( response, path, items ) {
850    return items.length + ' items. URL: ' + path;
851  },
852  last: function( response, path ) {
853    return 'URL: ' + path;
854  },
855  history: function( title, path ) {
856    return 'URL: ' + path;
857  },
858  pageIndex: function( index, origin ) {
859    return 'current page determined to be: ' + index + ' from ' + origin;
860  },
861};
862
863// log events
864proto.log = function( type, args ) {
865  if ( !this.options.debug ) {
866    return;
867  }
868  var message = '[InfiniteScroll] ' + type;
869  var logger = loggers[ type ];
870  if ( logger ) {
871    message += '. ' + logger.apply( this, args );
872  }
873  console.log( message );
874};
875
876// -------------------------- methods used amoung features -------------------------- //
877
878proto.updateMeasurements = function() {
879  this.windowHeight = window.innerHeight;
880  var rect = this.element.getBoundingClientRect();
881  this.top = rect.top + window.pageYOffset;
882};
883
884proto.updateScroller = function() {
885  var elementScroll = this.options.elementScroll;
886  if ( !elementScroll ) {
887    // default, use window
888    this.scroller = window;
889    return;
890  }
891  // if true, set to element, otherwise use option
892  this.scroller = elementScroll === true ? this.element :
893    utils.getQueryElement( elementScroll );
894  if ( !this.scroller ) {
895    throw 'Unable to find elementScroll: ' + elementScroll;
896  }
897};
898
899// -------------------------- page path -------------------------- //
900
901proto.updateGetPath = function() {
902  var optPath = this.options.path;
903  if ( !optPath ) {
904    console.error( 'InfiniteScroll path option required. Set as: ' + optPath );
905    return;
906  }
907  // function
908  var type = typeof optPath;
909  if ( type == 'function' ) {
910    this.getPath = optPath;
911    return;
912  }
913  // template string: '/pages/{{#}}.html'
914  var templateMatch = type == 'string' && optPath.match('{{#}}');
915  if ( templateMatch ) {
916    this.updateGetPathTemplate( optPath );
917    return;
918  }
919  // selector: '.next-page-selector'
920  this.updateGetPathSelector( optPath );
921};
922
923proto.updateGetPathTemplate = function( optPath ) {
924  // set getPath with template string
925  this.getPath = function() {
926    var nextIndex = this.pageIndex + 1;
927    return optPath.replace( '{{#}}', nextIndex );
928  }.bind( this );
929  // get pageIndex from location
930  // convert path option into regex to look for pattern in location
931  var regexString = optPath.replace( '{{#}}', '(\\d\\d?\\d?)' );
932  var templateRe = new RegExp( regexString );
933  var match = location.href.match( templateRe );
934  if ( match ) {
935    this.pageIndex = parseInt( match[1], 10 );
936    this.log( 'pageIndex', this.pageIndex, 'template string' );
937  }
938};
939
940var pathRegexes = [
941  // WordPress & Tumblr - example.com/page/2
942  // Jekyll - example.com/page2
943  /^(.*?\/?page\/?)(\d\d?\d?)(.*?$)/,
944  // Drupal - example.com/?page=1
945  /^(.*?\/?\?page=)(\d\d?\d?)(.*?$)/,
946  // catch all, last occurence of a number
947  /(.*?)(\d\d?\d?)(?!.*\d)(.*?$)/,
948];
949
950proto.updateGetPathSelector = function( optPath ) {
951  // parse href of link: '.next-page-link'
952  var hrefElem = document.querySelector( optPath );
953  if ( !hrefElem ) {
954    console.error( 'Bad InfiniteScroll path option. Next link not found: ' +
955      optPath );
956    return;
957  }
958  var href = hrefElem.getAttribute('href');
959  // try matching href to pathRegexes patterns
960  var pathParts, regex;
961  for ( var i=0; href && i < pathRegexes.length; i++ ) {
962    regex = pathRegexes[i];
963    var match = href.match( regex );
964    if ( match ) {
965      pathParts = match.slice(1); // remove first part
966      break;
967    }
968  }
969  if ( !pathParts ) {
970    console.error( 'InfiniteScroll unable to parse next link href: ' + href );
971    return;
972  }
973  this.isPathSelector = true; // flag for checkLastPage()
974  this.getPath = function() {
975    var nextIndex = this.pageIndex + 1;
976    return pathParts[0] + nextIndex + pathParts[2];
977  }.bind( this );
978  // get pageIndex from href
979  this.pageIndex = parseInt( pathParts[1], 10 ) - 1;
980  this.log( 'pageIndex', [ this.pageIndex, 'next link' ] );
981};
982
983proto.updateGetAbsolutePath = function() {
984  var path = this.getPath();
985  // path doesn't start with http or /
986  var isAbsolute = path.match( /^http/ ) || path.match( /^\// );
987  if ( isAbsolute ) {
988    this.getAbsolutePath = this.getPath;
989    return;
990  }
991
992  var pathname = location.pathname;
993  // /foo/bar/index.html => /foo/bar
994  var directory = pathname.substring( 0, pathname.lastIndexOf('/') );
995
996  this.getAbsolutePath = function() {
997    return directory + '/' + this.getPath();
998  };
999};
1000
1001// -------------------------- nav -------------------------- //
1002
1003// hide navigation
1004InfiniteScroll.create.hideNav = function() {
1005  var nav = utils.getQueryElement( this.options.hideNav );
1006  if ( !nav ) {
1007    return;
1008  }
1009  nav.style.display = 'none';
1010  this.nav = nav;
1011};
1012
1013InfiniteScroll.destroy.hideNav = function() {
1014  if ( this.nav ) {
1015    this.nav.style.display = '';
1016  }
1017};
1018
1019// -------------------------- destroy -------------------------- //
1020
1021proto.destroy = function() {
1022  this.allOff(); // remove all event listeners
1023  // call destroy methods
1024  for ( var method in InfiniteScroll.destroy ) {
1025    InfiniteScroll.destroy[ method ].call( this );
1026  }
1027
1028  delete this.element.infiniteScrollGUID;
1029  delete instances[ this.guid ];
1030};
1031
1032// -------------------------- utilities -------------------------- //
1033
1034// https://remysharp.com/2010/07/21/throttling-function-calls
1035InfiniteScroll.throttle = function( fn, threshold ) {
1036  threshold = threshold || 200;
1037  var last, timeout;
1038
1039  return function() {
1040    var now = +new Date();
1041    var args = arguments;
1042    var trigger = function() {
1043      last = now;
1044      fn.apply( this, args );
1045    }.bind( this );
1046    if ( last && now < last + threshold ) {
1047      // hold on to it
1048      clearTimeout( timeout );
1049      timeout = setTimeout( trigger, threshold );
1050    } else {
1051      trigger();
1052    }
1053  };
1054};
1055
1056InfiniteScroll.data = function( elem ) {
1057  elem = utils.getQueryElement( elem );
1058  var id = elem && elem.infiniteScrollGUID;
1059  return id && instances[ id ];
1060};
1061
1062// set internal jQuery, for Webpack + jQuery v3
1063InfiniteScroll.setJQuery = function( $ ) {
1064  jQuery = $;
1065};
1066
1067// -------------------------- setup -------------------------- //
1068
1069utils.htmlInit( InfiniteScroll, 'infinite-scroll' );
1070
1071if ( jQuery && jQuery.bridget ) {
1072  jQuery.bridget( 'infiniteScroll', InfiniteScroll );
1073}
1074
1075// --------------------------  -------------------------- //
1076
1077return InfiniteScroll;
1078
1079}));
1080
1081},{"ev-emitter":4,"fizzy-ui-utils":5}],8:[function(require,module,exports){
1082// history
1083( function( window, factory ) {
1084  // universal module definition
1085  /* globals define, module, require */
1086  if ( typeof define == 'function' && define.amd ) {
1087    // AMD
1088    define( [
1089      './core',
1090      'fizzy-ui-utils/utils',
1091    ], function( InfiniteScroll, utils ) {
1092      return factory( window, InfiniteScroll, utils );
1093    });
1094  } else if ( typeof module == 'object' && module.exports ) {
1095    // CommonJS
1096    module.exports = factory(
1097      window,
1098      require('./core'),
1099      require('fizzy-ui-utils')
1100    );
1101  } else {
1102    // browser global
1103    factory(
1104      window,
1105      window.InfiniteScroll,
1106      window.fizzyUIUtils
1107    );
1108  }
1109
1110}( window, function factory( window, InfiniteScroll, utils ) {
1111
1112var proto = InfiniteScroll.prototype;
1113
1114InfiniteScroll.defaults.history = 'replace';
1115// InfiniteScroll.defaults.historyTitle = false;
1116
1117var link = document.createElement('a');
1118
1119// ----- create/destroy ----- //
1120
1121InfiniteScroll.create.history = function() {
1122  if ( !this.options.history ) {
1123    return;
1124  }
1125  // check for same origin
1126  link.href = this.getAbsolutePath();
1127  // MS Edge does not have origin on link https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/12236493/
1128  var linkOrigin = link.origin || link.protocol + '//' + link.host;
1129  var isSameOrigin = linkOrigin == location.origin;
1130  if ( !isSameOrigin ) {
1131    console.error( '[InfiniteScroll] cannot set history with different origin: ' +
1132      link.origin + ' on ' + location.origin +
1133      ' . History behavior disabled.' );
1134    return;
1135  }
1136
1137  // two ways to handle changing history
1138  if ( this.options.append ) {
1139    this.createHistoryAppend();
1140  } else {
1141    this.createHistoryPageLoad();
1142  }
1143};
1144
1145proto.createHistoryAppend = function() {
1146  this.updateMeasurements();
1147  this.updateScroller();
1148  // array of scroll positions of appended pages
1149  this.scrollPages = [
1150    {
1151      // first page
1152      top: 0,
1153      path: location.href,
1154      title: document.title,
1155    }
1156  ];
1157  this.scrollPageIndex = 0;
1158  // events
1159  this.scrollHistoryHandler = this.onScrollHistory.bind( this );
1160  this.unloadHandler = this.onUnload.bind( this );
1161  this.scroller.addEventListener( 'scroll', this.scrollHistoryHandler );
1162  this.on( 'append', this.onAppendHistory );
1163  this.bindHistoryAppendEvents( true );
1164};
1165
1166proto.bindHistoryAppendEvents = function( isBind ) {
1167  var addRemove = isBind ? 'addEventListener' : 'removeEventListener';
1168  this.scroller[ addRemove ]( 'scroll', this.scrollHistoryHandler );
1169  window[ addRemove ]( 'unload', this.unloadHandler );
1170};
1171
1172proto.createHistoryPageLoad = function() {
1173  this.on( 'load', this.onPageLoadHistory );
1174};
1175
1176InfiniteScroll.destroy.history =
1177proto.destroyHistory = function() {
1178  var isHistoryAppend = this.options.history && this.options.append;
1179  if ( isHistoryAppend ) {
1180    this.bindHistoryAppendEvents( false );
1181  }
1182};
1183
1184// ----- append history ----- //
1185
1186proto.onAppendHistory = function( response, path, items ) {
1187  var firstItem = items[0];
1188  var elemScrollY = this.getElementScrollY( firstItem );
1189  // resolve path
1190  link.href = path;
1191  // add page data to hash
1192  this.scrollPages.push({
1193    top: elemScrollY,
1194    path: link.href,
1195    title: response.title,
1196  });
1197};
1198
1199proto.getElementScrollY = function( elem ) {
1200  if ( this.options.elementScroll ) {
1201    return this.getElementElementScrollY( elem );
1202  } else {
1203    return this.getElementWindowScrollY( elem );
1204  }
1205};
1206
1207proto.getElementWindowScrollY = function( elem ) {
1208  var rect = elem.getBoundingClientRect();
1209  return rect.top + window.pageYOffset;
1210};
1211
1212// wow, stupid name
1213proto.getElementElementScrollY = function( elem ) {
1214  return elem.offsetTop - this.top;
1215};
1216
1217proto.onScrollHistory = function() {
1218  // cycle through positions, find biggest without going over
1219  var scrollViewY = this.getScrollViewY();
1220  var pageIndex, page;
1221  for ( var i=0; i < this.scrollPages.length; i++ ) {
1222    var scrollPage = this.scrollPages[i];
1223    if ( scrollPage.top >= scrollViewY ) {
1224      break;
1225    }
1226    pageIndex = i;
1227    page = scrollPage;
1228  }
1229  // set history if changed
1230  if ( pageIndex != this.scrollPageIndex ) {
1231    this.scrollPageIndex = pageIndex;
1232    this.setHistory( page.title, page.path );
1233  }
1234};
1235
1236utils.debounceMethod( InfiniteScroll, 'onScrollHistory', 150 );
1237
1238proto.getScrollViewY = function() {
1239  if ( this.options.elementScroll ) {
1240    return this.scroller.scrollTop + this.scroller.clientHeight/2;
1241  } else {
1242    return window.pageYOffset + this.windowHeight/2;
1243  }
1244};
1245
1246proto.setHistory = function( title, path ) {
1247  var optHistory = this.options.history;
1248  var historyMethod = optHistory && history[ optHistory + 'State' ];
1249  if ( !historyMethod ) {
1250    return;
1251  }
1252
1253  history[ optHistory + 'State' ]( null, title, path );
1254
1255  if ( this.options.historyTitle ) {
1256    document.title = title;
1257  }
1258
1259  this.dispatchEvent( 'history', null, [ title, path ] );
1260};
1261
1262// scroll to top to prevent initial scroll-reset after page refresh
1263// http://stackoverflow.com/a/18633915/182183
1264proto.onUnload = function() {
1265  var pageIndex = this.scrollPageIndex;
1266  if ( pageIndex === 0 ) {
1267    return;
1268  }
1269  // calculate where scroll position would be on refresh
1270  var scrollPage = this.scrollPages[ pageIndex ];
1271  var scrollY = window.pageYOffset - scrollPage.top + this.top;
1272  // disable scroll event before setting scroll #679
1273  this.destroyHistory();
1274  scrollTo( 0, scrollY );
1275};
1276
1277// ----- load history ----- //
1278
1279// update URL
1280proto.onPageLoadHistory = function( response, path ) {
1281  this.setHistory( response.title, path );
1282};
1283
1284// --------------------------  -------------------------- //
1285
1286return InfiniteScroll;
1287
1288}));
1289
1290},{"./core":7,"fizzy-ui-utils":5}],9:[function(require,module,exports){
1291/*!
1292 * Infinite Scroll v3.0.2
1293 * Automatically add next page
1294 *
1295 * Licensed GPLv3 for open source use
1296 * or Infinite Scroll Commercial License for commercial use
1297 *
1298 * https://infinite-scroll.com
1299 * Copyright 2017 Metafizzy
1300 */
1301
1302( function( window, factory ) {
1303  // universal module definition
1304  /* globals define, module, require */
1305  if ( typeof define == 'function' && define.amd ) {
1306    // AMD
1307    define( [
1308      './core',
1309      './page-load',
1310      './scroll-watch',
1311      './history',
1312      './button',
1313      './status',
1314    ], factory );
1315  } else if ( typeof module == 'object' && module.exports ) {
1316    // CommonJS
1317    module.exports = factory(
1318      require('./core'),
1319      require('./page-load'),
1320      require('./scroll-watch'),
1321      require('./history'),
1322      require('./button'),
1323      require('./status')
1324    );
1325  }
1326
1327})( window, function factory( InfiniteScroll ) {
1328  return InfiniteScroll;
1329});
1330
1331},{"./button":6,"./core":7,"./history":8,"./page-load":10,"./scroll-watch":11,"./status":12}],10:[function(require,module,exports){
1332// page-load
1333( function( window, factory ) {
1334  // universal module definition
1335  /* globals define, module, require */
1336  if ( typeof define == 'function' && define.amd ) {
1337    // AMD
1338    define( [
1339      './core',
1340    ], function( InfiniteScroll ) {
1341      return factory( window, InfiniteScroll );
1342    });
1343  } else if ( typeof module == 'object' && module.exports ) {
1344    // CommonJS
1345    module.exports = factory(
1346      window,
1347      require('./core')
1348    );
1349  } else {
1350    // browser global
1351    factory(
1352      window,
1353      window.InfiniteScroll
1354    );
1355  }
1356
1357}( window, function factory( window, InfiniteScroll ) {
1358
1359var proto = InfiniteScroll.prototype;
1360
1361// InfiniteScroll.defaults.append = false;
1362InfiniteScroll.defaults.loadOnScroll = true;
1363InfiniteScroll.defaults.checkLastPage = true;
1364InfiniteScroll.defaults.responseType = 'document';
1365// InfiniteScroll.defaults.prefill = false;
1366// InfiniteScroll.defaults.outlayer = null;
1367
1368InfiniteScroll.create.pageLoad = function() {
1369  this.canLoad = true;
1370  this.on( 'scrollThreshold', this.onScrollThresholdLoad );
1371  this.on( 'append', this.checkLastPage );
1372  if ( this.options.outlayer ) {
1373    this.on( 'append', this.onAppendOutlayer );
1374  }
1375};
1376
1377proto.onScrollThresholdLoad = function() {
1378  if ( this.options.loadOnScroll ) {
1379    this.loadNextPage();
1380  }
1381};
1382
1383proto.loadNextPage = function() {
1384  if ( this.isLoading || !this.canLoad ) {
1385    return;
1386  }
1387
1388  var path = this.getAbsolutePath();
1389  this.isLoading = true;
1390
1391  var onLoad = function( response ) {
1392    this.onPageLoad( response, path );
1393  }.bind( this );
1394
1395  var onError = function( error ) {
1396    this.onPageError( error, path );
1397  }.bind( this );
1398
1399  request( path, this.options.responseType, onLoad, onError );
1400  this.dispatchEvent( 'request', null, [ path ] );
1401};
1402
1403proto.onPageLoad = function( response, path ) {
1404  // done loading if not appending
1405  if ( !this.options.append ) {
1406    this.isLoading = false;
1407  }
1408  this.pageIndex++;
1409  this.loadCount++;
1410  this.dispatchEvent( 'load', null, [ response, path ] );
1411  this.appendNextPage( response, path );
1412  return response;
1413};
1414
1415proto.appendNextPage = function( response, path ) {
1416  var optAppend = this.options.append;
1417  // do not append json
1418  var isDocument = this.options.responseType == 'document';
1419  if ( !isDocument || !optAppend ) {
1420    return;
1421  }
1422
1423  var items = response.querySelectorAll( optAppend );
1424  var fragment = getItemsFragment( items );
1425  var appendReady = function () {
1426    this.appendItems( items, fragment );
1427    this.isLoading = false;
1428    this.dispatchEvent( 'append', null, [ response, path, items ] );
1429  }.bind( this );
1430
1431  // TODO add hook for option to trigger appendReady
1432  if ( this.options.outlayer ) {
1433    this.appendOutlayerItems( fragment, appendReady );
1434  } else {
1435    appendReady();
1436  }
1437};
1438
1439proto.appendItems = function( items, fragment ) {
1440  if ( !items || !items.length ) {
1441    return;
1442  }
1443  // get fragment if not provided
1444  fragment = fragment || getItemsFragment( items );
1445  refreshScripts( fragment );
1446  this.element.appendChild( fragment );
1447};
1448
1449function getItemsFragment( items ) {
1450  // add items to fragment
1451  var fragment = document.createDocumentFragment();
1452  for ( var i=0; items && i < items.length; i++ ) {
1453    fragment.appendChild( items[i] );
1454  }
1455  return fragment;
1456}
1457
1458// replace <script>s with copies so they load
1459// <script>s added by InfiniteScroll will not load
1460// similar to https://stackoverflow.com/questions/610995
1461function refreshScripts( fragment ) {
1462  var scripts = fragment.querySelectorAll('script');
1463  for ( var i=0; i < scripts.length; i++ ) {
1464    var script = scripts[i];
1465    var freshScript = document.createElement('script');
1466    copyAttributes( script, freshScript );
1467    script.parentNode.replaceChild( freshScript, script );
1468  }
1469}
1470
1471function copyAttributes( fromNode, toNode ) {
1472  var attrs = fromNode.attributes;
1473  for ( var i=0; i < attrs.length; i++ ) {
1474    var attr = attrs[i];
1475    toNode.setAttribute( attr.name, attr.value );
1476  }
1477}
1478
1479// ----- outlayer ----- //
1480
1481proto.appendOutlayerItems = function( fragment, appendReady ) {
1482  var imagesLoaded = InfiniteScroll.imagesLoaded || window.imagesLoaded;
1483  if ( !imagesLoaded ) {
1484    console.error('[InfiniteScroll] imagesLoaded required for outlayer option');
1485    this.isLoading = false;
1486    return;
1487  }
1488  // append once images loaded
1489  imagesLoaded( fragment, appendReady );
1490};
1491
1492proto.onAppendOutlayer = function( response, path, items ) {
1493  this.options.outlayer.appended( items );
1494};
1495
1496// ----- checkLastPage ----- //
1497
1498// check response for next element
1499proto.checkLastPage = function( response, path ) {
1500  var checkLastPage = this.options.checkLastPage;
1501  if ( !checkLastPage ) {
1502    return;
1503  }
1504
1505  var pathOpt = this.options.path;
1506  // if path is function, check if next path is truthy
1507  if ( typeof pathOpt == 'function' ) {
1508    var nextPath = this.getPath();
1509    if ( !nextPath ) {
1510      this.lastPageReached( response, path );
1511      return;
1512    }
1513  }
1514  // get selector from checkLastPage or path option
1515  var selector;
1516  if ( typeof checkLastPage == 'string' ) {
1517    selector = checkLastPage;
1518  } else if ( this.isPathSelector ) {
1519    // path option is selector string
1520    selector = pathOpt;
1521  }
1522  // check last page for selector
1523  // bail if no selector or not document response
1524  if ( !selector || !response.querySelector ) {
1525    return;
1526  }
1527  // check if response has selector
1528  var nextElem = response.querySelector( selector );
1529  if ( !nextElem ) {
1530    this.lastPageReached( response, path );
1531  }
1532};
1533
1534proto.lastPageReached = function( response, path ) {
1535  this.canLoad = false;
1536  this.dispatchEvent( 'last', null, [ response, path ] );
1537};
1538
1539// ----- error ----- //
1540
1541proto.onPageError = function( error, path ) {
1542  this.isLoading = false;
1543  this.canLoad = false;
1544  this.dispatchEvent( 'error', null, [ error, path ] );
1545  return error;
1546};
1547
1548// -------------------------- prefill -------------------------- //
1549
1550InfiniteScroll.create.prefill = function() {
1551  if ( !this.options.prefill ) {
1552    return;
1553  }
1554  var append = this.options.append;
1555  if ( !append ) {
1556    console.error( 'append option required for prefill. Set as :' + append );
1557    return;
1558  }
1559  this.updateMeasurements();
1560  this.updateScroller();
1561  this.isPrefilling = true;
1562  this.on( 'append', this.prefill );
1563  this.once( 'error', this.stopPrefill );
1564  this.once( 'last', this.stopPrefill );
1565  this.prefill();
1566};
1567
1568proto.prefill = function() {
1569  var distance = this.getPrefillDistance();
1570  this.isPrefilling = distance >= 0;
1571  if ( this.isPrefilling ) {
1572    this.log('prefill');
1573    this.loadNextPage();
1574  } else {
1575    this.stopPrefill();
1576  }
1577};
1578
1579proto.getPrefillDistance = function() {
1580  // element scroll
1581  if ( this.options.elementScroll ) {
1582    return this.scroller.clientHeight - this.scroller.scrollHeight;
1583  }
1584  // window
1585  return this.windowHeight - this.element.clientHeight;
1586};
1587
1588proto.stopPrefill = function() {
1589  console.log('stopping prefill');
1590  this.off( 'append', this.prefill );
1591};
1592
1593// -------------------------- request -------------------------- //
1594
1595function request( url, responseType, onLoad, onError ) {
1596  var req = new XMLHttpRequest();
1597  req.open( 'GET', url, true );
1598  // set responseType document to return DOM
1599  req.responseType = responseType || '';
1600
1601  // set X-Requested-With header to check that is ajax request
1602  req.setRequestHeader('X-Requested-With', 'XMLHttpRequest');
1603
1604  req.onload = function() {
1605    if ( req.status == 200 ) {
1606      onLoad( req.response );
1607    } else {
1608      // not 200 OK, error
1609      var error = new Error( req.statusText );
1610      onError( error );
1611    }
1612  };
1613
1614  // Handle network errors
1615  req.onerror = function() {
1616    var error = new Error( 'Network error requesting ' + url );
1617    onError( error );
1618  };
1619
1620  req.send();
1621}
1622
1623// --------------------------  -------------------------- //
1624
1625return InfiniteScroll;
1626
1627}));
1628
1629},{"./core":7}],11:[function(require,module,exports){
1630// scroll-watch
1631( function( window, factory ) {
1632  // universal module definition
1633  /* globals define, module, require */
1634  if ( typeof define == 'function' && define.amd ) {
1635    // AMD
1636    define( [
1637      './core',
1638      'fizzy-ui-utils/utils',
1639    ], function( InfiniteScroll, utils ) {
1640      return factory( window, InfiniteScroll, utils );
1641    });
1642  } else if ( typeof module == 'object' && module.exports ) {
1643    // CommonJS
1644    module.exports = factory(
1645      window,
1646      require('./core'),
1647      require('fizzy-ui-utils')
1648    );
1649  } else {
1650    // browser global
1651    factory(
1652      window,
1653      window.InfiniteScroll,
1654      window.fizzyUIUtils
1655    );
1656  }
1657
1658}( window, function factory( window, InfiniteScroll, utils ) {
1659
1660var proto = InfiniteScroll.prototype;
1661
1662// default options
1663InfiniteScroll.defaults.scrollThreshold = 400;
1664// InfiniteScroll.defaults.elementScroll = null;
1665
1666InfiniteScroll.create.scrollWatch = function() {
1667  // events
1668  this.pageScrollHandler = this.onPageScroll.bind( this );
1669  this.resizeHandler = this.onResize.bind( this );
1670
1671  var scrollThreshold = this.options.scrollThreshold;
1672  var isEnable = scrollThreshold || scrollThreshold === 0;
1673  if ( isEnable ) {
1674    this.enableScrollWatch();
1675  }
1676};
1677
1678InfiniteScroll.destroy.scrollWatch = function() {
1679  this.disableScrollWatch();
1680};
1681
1682proto.enableScrollWatch = function() {
1683  if ( this.isScrollWatching ) {
1684    return;
1685  }
1686  this.isScrollWatching = true;
1687  this.updateMeasurements();
1688  this.updateScroller();
1689  // TODO disable after error?
1690  this.on( 'last', this.disableScrollWatch );
1691  this.bindScrollWatchEvents( true );
1692};
1693
1694proto.disableScrollWatch = function() {
1695  if ( !this.isScrollWatching ) {
1696    return;
1697  }
1698  this.bindScrollWatchEvents( false );
1699  delete this.isScrollWatching;
1700};
1701
1702proto.bindScrollWatchEvents = function( isBind ) {
1703  var addRemove = isBind ? 'addEventListener' : 'removeEventListener';
1704  this.scroller[ addRemove ]( 'scroll', this.pageScrollHandler );
1705  window[ addRemove ]( 'resize', this.resizeHandler );
1706};
1707
1708proto.onPageScroll = InfiniteScroll.throttle( function() {
1709  var distance = this.getBottomDistance();
1710  if ( distance <= this.options.scrollThreshold ) {
1711    this.dispatchEvent('scrollThreshold');
1712  }
1713});
1714
1715proto.getBottomDistance = function() {
1716  if ( this.options.elementScroll ) {
1717    return this.getElementBottomDistance();
1718  } else {
1719    return this.getWindowBottomDistance();
1720  }
1721};
1722
1723proto.getWindowBottomDistance = function() {
1724  var bottom = this.top + this.element.clientHeight;
1725  var scrollY = window.pageYOffset + this.windowHeight;
1726  return bottom - scrollY;
1727};
1728
1729proto.getElementBottomDistance = function() {
1730  var bottom = this.scroller.scrollHeight;
1731  var scrollY = this.scroller.scrollTop + this.scroller.clientHeight;
1732  return bottom - scrollY;
1733};
1734
1735proto.onResize = function() {
1736  this.updateMeasurements();
1737};
1738
1739utils.debounceMethod( InfiniteScroll, 'onResize', 150 );
1740
1741// --------------------------  -------------------------- //
1742
1743return InfiniteScroll;
1744
1745}));
1746
1747},{"./core":7,"fizzy-ui-utils":5}],12:[function(require,module,exports){
1748// status
1749( function( window, factory ) {
1750  // universal module definition
1751  /* globals define, module, require */
1752  if ( typeof define == 'function' && define.amd ) {
1753    // AMD
1754    define( [
1755      './core',
1756      'fizzy-ui-utils/utils',
1757    ], function( InfiniteScroll, utils ) {
1758      return factory( window, InfiniteScroll, utils );
1759    });
1760  } else if ( typeof module == 'object' && module.exports ) {
1761    // CommonJS
1762    module.exports = factory(
1763      window,
1764      require('./core'),
1765      require('fizzy-ui-utils')
1766    );
1767  } else {
1768    // browser global
1769    factory(
1770      window,
1771      window.InfiniteScroll,
1772      window.fizzyUIUtils
1773    );
1774  }
1775
1776}( window, function factory( window, InfiniteScroll, utils ) { 
1777
1778var proto = InfiniteScroll.prototype;
1779
1780// InfiniteScroll.defaults.status = null;
1781
1782InfiniteScroll.create.status = function() {
1783  var statusElem = utils.getQueryElement( this.options.status );
1784  if ( !statusElem ) {
1785    return;
1786  }
1787  // elements
1788  this.statusElement = statusElem;
1789  this.statusEventElements = {
1790    request: statusElem.querySelector('.infinite-scroll-request'),
1791    error: statusElem.querySelector('.infinite-scroll-error'),
1792    last: statusElem.querySelector('.infinite-scroll-last'),
1793  };
1794  // events
1795  this.on( 'request', this.showRequestStatus );
1796  this.on( 'error', this.showErrorStatus );
1797  this.on( 'last', this.showLastStatus );
1798  this.bindHideStatus('on');
1799};
1800
1801proto.bindHideStatus = function( bindMethod ) {
1802  var hideEvent = this.options.append ? 'append' : 'load';
1803  this[ bindMethod ]( hideEvent, this.hideAllStatus );
1804};
1805
1806proto.showRequestStatus = function() {
1807  this.showStatus('request');
1808};
1809
1810proto.showErrorStatus = function() {
1811  this.showStatus('error');
1812};
1813
1814proto.showLastStatus = function() {
1815  this.showStatus('last');
1816  // prevent last then append event race condition from showing last status #706
1817  this.bindHideStatus('off');
1818};
1819
1820proto.showStatus = function( eventName ) {
1821  show( this.statusElement );
1822  this.hideStatusEventElements();
1823  var eventElem = this.statusEventElements[ eventName ];
1824  show( eventElem );
1825};
1826
1827proto.hideAllStatus = function() {
1828  hide( this.statusElement );
1829  this.hideStatusEventElements();
1830};
1831
1832proto.hideStatusEventElements = function() {
1833  for ( var type in this.statusEventElements ) {
1834    var eventElem = this.statusEventElements[ type ];
1835    hide( eventElem );
1836  }
1837};
1838
1839// --------------------------  -------------------------- //
1840
1841function hide( elem ) {
1842  setDisplay( elem, 'none' );
1843}
1844
1845function show( elem ) {
1846  setDisplay( elem, 'block' );
1847}
1848
1849function setDisplay( elem, value ) {
1850  if ( elem ) {
1851    elem.style.display = value;
1852  }
1853}
1854
1855// --------------------------  -------------------------- //
1856
1857return InfiniteScroll;
1858
1859}));
1860
1861},{"./core":7,"fizzy-ui-utils":5}],13:[function(require,module,exports){
1862/**
1863* jquery-match-height 0.7.2 by @liabru
1864* http://brm.io/jquery-match-height/
1865* License: MIT
1866*/
1867
1868;(function(factory) { // eslint-disable-line no-extra-semi
1869    'use strict';
1870    if (typeof define === 'function' && define.amd) {
1871        // AMD
1872        define(['jquery'], factory);
1873    } else if (typeof module !== 'undefined' && module.exports) {
1874        // CommonJS
1875        module.exports = factory(require('jquery'));
1876    } else {
1877        // Global
1878        factory(jQuery);
1879    }
1880})(function($) {
1881    /*
1882    *  internal
1883    */
1884
1885    var _previousResizeWidth = -1,
1886        _updateTimeout = -1;
1887
1888    /*
1889    *  _parse
1890    *  value parse utility function
1891    */
1892
1893    var _parse = function(value) {
1894        // parse value and convert NaN to 0
1895        return parseFloat(value) || 0;
1896    };
1897
1898    /*
1899    *  _rows
1900    *  utility function returns array of jQuery selections representing each row
1901    *  (as displayed after float wrapping applied by browser)
1902    */
1903
1904    var _rows = function(elements) {
1905        var tolerance = 1,
1906            $elements = $(elements),
1907            lastTop = null,
1908            rows = [];
1909
1910        // group elements by their top position
1911        $elements.each(function(){
1912            var $that = $(this),
1913                top = $that.offset().top - _parse($that.css('margin-top')),
1914                lastRow = rows.length > 0 ? rows[rows.length - 1] : null;
1915
1916            if (lastRow === null) {
1917                // first item on the row, so just push it
1918                rows.push($that);
1919            } else {
1920                // if the row top is the same, add to the row group
1921                if (Math.floor(Math.abs(lastTop - top)) <= tolerance) {
1922                    rows[rows.length - 1] = lastRow.add($that);
1923                } else {
1924                    // otherwise start a new row group
1925                    rows.push($that);
1926                }
1927            }
1928
1929            // keep track of the last row top
1930            lastTop = top;
1931        });
1932
1933        return rows;
1934    };
1935
1936    /*
1937    *  _parseOptions
1938    *  handle plugin options
1939    */
1940
1941    var _parseOptions = function(options) {
1942        var opts = {
1943            byRow: true,
1944            property: 'height',
1945            target: null,
1946            remove: false
1947        };
1948
1949        if (typeof options === 'object') {
1950            return $.extend(opts, options);
1951        }
1952
1953        if (typeof options === 'boolean') {
1954            opts.byRow = options;
1955        } else if (options === 'remove') {
1956            opts.remove = true;
1957        }
1958
1959        return opts;
1960    };
1961
1962    /*
1963    *  matchHeight
1964    *  plugin definition
1965    */
1966
1967    var matchHeight = $.fn.matchHeight = function(options) {
1968        var opts = _parseOptions(options);
1969
1970        // handle remove
1971        if (opts.remove) {
1972            var that = this;
1973
1974            // remove fixed height from all selected elements
1975            this.css(opts.property, '');
1976
1977            // remove selected elements from all groups
1978            $.each(matchHeight._groups, function(key, group) {
1979                group.elements = group.elements.not(that);
1980            });
1981
1982            // TODO: cleanup empty groups
1983
1984            return this;
1985        }
1986
1987        if (this.length <= 1 && !opts.target) {
1988            return this;
1989        }
1990
1991        // keep track of this group so we can re-apply later on load and resize events
1992        matchHeight._groups.push({
1993            elements: this,
1994            options: opts
1995        });
1996
1997        // match each element's height to the tallest element in the selection
1998        matchHeight._apply(this, opts);
1999
2000        return this;
2001    };
2002
2003    /*
2004    *  plugin global options
2005    */
2006
2007    matchHeight.version = '0.7.2';
2008    matchHeight._groups = [];
2009    matchHeight._throttle = 80;
2010    matchHeight._maintainScroll = false;
vendor: 11,279 bytes, lines 2011-2378
2011    matchHeight._beforeUpdate = null;
2012    matchHeight._afterUpdate = null;
2013    matchHeight._rows = _rows;
2014    matchHeight._parse = _parse;
2015    matchHeight._parseOptions = _parseOptions;
2016
2017    /*
2018    *  matchHeight._apply
2019    *  apply matchHeight to given elements
2020    */
2021
2022    matchHeight._apply = function(elements, options) {
2023        var opts = _parseOptions(options),
2024            $elements = $(elements),
2025            rows = [$elements];
2026
2027        // take note of scroll position
2028        var scrollTop = $(window).scrollTop(),
2029            htmlHeight = $('html').outerHeight(true);
2030
2031        // get hidden parents
2032        var $hiddenParents = $elements.parents().filter(':hidden');
2033
2034        // cache the original inline style
2035        $hiddenParents.each(function() {
2036            var $that = $(this);
2037            $that.data('style-cache', $that.attr('style'));
2038        });
2039
2040        // temporarily must force hidden parents visible
2041        $hiddenParents.css('display', 'block');
2042
2043        // get rows if using byRow, otherwise assume one row
2044        if (opts.byRow && !opts.target) {
2045
2046            // must first force an arbitrary equal height so floating elements break evenly
2047            $elements.each(function() {
2048                var $that = $(this),
2049                    display = $that.css('display');
2050
2051                // temporarily force a usable display value
2052                if (display !== 'inline-block' && display !== 'flex' && display !== 'inline-flex') {
2053                    display = 'block';
2054                }
2055
2056                // cache the original inline style
2057                $that.data('style-cache', $that.attr('style'));
2058
2059                $that.css({
2060                    'display': display,
2061                    'padding-top': '0',
2062                    'padding-bottom': '0',
2063                    'margin-top': '0',
2064                    'margin-bottom': '0',
2065                    'border-top-width': '0',
2066                    'border-bottom-width': '0',
2067                    'height': '100px',
2068                    'overflow': 'hidden'
2069                });
2070            });
2071
2072            // get the array of rows (based on element top position)
2073            rows = _rows($elements);
2074
2075            // revert original inline styles
2076            $elements.each(function() {
2077                var $that = $(this);
2078                $that.attr('style', $that.data('style-cache') || '');
2079            });
2080        }
2081
2082        $.each(rows, function(key, row) {
2083            var $row = $(row),
2084                targetHeight = 0;
2085
2086            if (!opts.target) {
2087                // skip apply to rows with only one item
2088                if (opts.byRow && $row.length <= 1) {
2089                    $row.css(opts.property, '');
2090                    return;
2091                }
2092
2093                // iterate the row and find the max height
2094                $row.each(function(){
2095                    var $that = $(this),
2096                        style = $that.attr('style'),
2097                        display = $that.css('display');
2098
2099                    // temporarily force a usable display value
2100                    if (display !== 'inline-block' && display !== 'flex' && display !== 'inline-flex') {
2101                        display = 'block';
2102                    }
2103
2104                    // ensure we get the correct actual height (and not a previously set height value)
2105                    var css = { 'display': display };
2106                    css[opts.property] = '';
2107                    $that.css(css);
2108
2109                    // find the max height (including padding, but not margin)
2110                    if ($that.outerHeight(false) > targetHeight) {
2111                        targetHeight = $that.outerHeight(false);
2112                    }
2113
2114                    // revert styles
2115                    if (style) {
2116                        $that.attr('style', style);
2117                    } else {
2118                        $that.css('display', '');
2119                    }
2120                });
2121            } else {
2122                // if target set, use the height of the target element
2123                targetHeight = opts.target.outerHeight(false);
2124            }
2125
2126            // iterate the row and apply the height to all elements
2127            $row.each(function(){
2128                var $that = $(this),
2129                    verticalPadding = 0;
2130
2131                // don't apply to a target
2132                if (opts.target && $that.is(opts.target)) {
2133                    return;
2134                }
2135
2136                // handle padding and border correctly (required when not using border-box)
2137                if ($that.css('box-sizing') !== 'border-box') {
2138                    verticalPadding += _parse($that.css('border-top-width')) + _parse($that.css('border-bottom-width'));
2139                    verticalPadding += _parse($that.css('padding-top')) + _parse($that.css('padding-bottom'));
2140                }
2141
2142                // set the height (accounting for padding and border)
2143                $that.css(opts.property, (targetHeight - verticalPadding) + 'px');
2144            });
2145        });
2146
2147        // revert hidden parents
2148        $hiddenParents.each(function() {
2149            var $that = $(this);
2150            $that.attr('style', $that.data('style-cache') || null);
2151        });
2152
2153        // restore scroll position if enabled
2154        if (matchHeight._maintainScroll) {
2155            $(window).scrollTop((scrollTop / htmlHeight) * $('html').outerHeight(true));
2156        }
2157
2158        return this;
2159    };
2160
2161    /*
2162    *  matchHeight._applyDataApi
2163    *  applies matchHeight to all elements with a data-match-height attribute
2164    */
2165
2166    matchHeight._applyDataApi = function() {
2167        var groups = {};
2168
2169        // generate groups by their groupId set by elements using data-match-height
2170        $('[data-match-height], [data-mh]').each(function() {
2171            var $this = $(this),
2172                groupId = $this.attr('data-mh') || $this.attr('data-match-height');
2173
2174            if (groupId in groups) {
2175                groups[groupId] = groups[groupId].add($this);
2176            } else {
2177                groups[groupId] = $this;
2178            }
2179        });
2180
2181        // apply matchHeight to each group
2182        $.each(groups, function() {
2183            this.matchHeight(true);
2184        });
2185    };
2186
2187    /*
2188    *  matchHeight._update
2189    *  updates matchHeight on all current groups with their correct options
2190    */
2191
2192    var _update = function(event) {
2193        if (matchHeight._beforeUpdate) {
2194            matchHeight._beforeUpdate(event, matchHeight._groups);
2195        }
2196
2197        $.each(matchHeight._groups, function() {
2198            matchHeight._apply(this.elements, this.options);
2199        });
2200
2201        if (matchHeight._afterUpdate) {
2202            matchHeight._afterUpdate(event, matchHeight._groups);
2203        }
2204    };
2205
2206    matchHeight._update = function(throttle, event) {
2207        // prevent update if fired from a resize event
2208        // where the viewport width hasn't actually changed
2209        // fixes an event looping bug in IE8
2210        if (event && event.type === 'resize') {
2211            var windowWidth = $(window).width();
2212            if (windowWidth === _previousResizeWidth) {
2213                return;
2214            }
2215            _previousResizeWidth = windowWidth;
2216        }
2217
2218        // throttle updates
2219        if (!throttle) {
2220            _update(event);
2221        } else if (_updateTimeout === -1) {
2222            _updateTimeout = setTimeout(function() {
2223                _update(event);
2224                _updateTimeout = -1;
2225            }, matchHeight._throttle);
2226        }
2227    };
2228
2229    /*
2230    *  bind events
2231    */
2232
2233    // apply on DOM ready event
2234    $(matchHeight._applyDataApi);
2235
2236    // use on or bind where supported
2237    var on = $.fn.on ? 'on' : 'bind';
2238
2239    // update heights on load and resize events
2240    $(window)[on]('load', function(event) {
2241        matchHeight._update(false, event);
2242    });
2243
2244    // throttled update heights on resize events
2245    $(window)[on]('resize orientationchange', function(event) {
2246        matchHeight._update(true, event);
2247    });
2248
2249});
2250
2251},{"jquery":14}],14:[function(require,module,exports){
2252/*!
2253 * jQuery JavaScript Library v2.2.4
2254 * http://jquery.com/
2255 *
2256 * Includes Sizzle.js
2257 * http://sizzlejs.com/
2258 *
2259 * Copyright jQuery Foundation and other contributors
2260 * Released under the MIT license
2261 * http://jquery.org/license
2262 *
2263 * Date: 2016-05-20T17:23Z
2264 */
2265
2266(function( global, factory ) {
2267
2268	if ( typeof module === "object" && typeof module.exports === "object" ) {
2269		// For CommonJS and CommonJS-like environments where a proper `window`
2270		// is present, execute the factory and get jQuery.
2271		// For environments that do not have a `window` with a `document`
2272		// (such as Node.js), expose a factory as module.exports.
2273		// This accentuates the need for the creation of a real `window`.
2274		// e.g. var jQuery = require("jquery")(window);
2275		// See ticket #14549 for more info.
2276		module.exports = global.document ?
2277			factory( global, true ) :
2278			function( w ) {
2279				if ( !w.document ) {
2280					throw new Error( "jQuery requires a window with a document" );
2281				}
2282				return factory( w );
2283			};
2284	} else {
2285		factory( global );
2286	}
2287
2288// Pass this if window is not defined yet
2289}(typeof window !== "undefined" ? window : this, function( window, noGlobal ) {
2290
2291// Support: Firefox 18+
2292// Can't be in strict mode, several libs including ASP.NET trace
2293// the stack via arguments.caller.callee and Firefox dies if
2294// you try to trace through "use strict" call chains. (#13335)
2295//"use strict";
2296var arr = [];
2297
2298var document = window.document;
2299
2300var slice = arr.slice;
2301
2302var concat = arr.concat;
2303
2304var push = arr.push;
2305
2306var indexOf = arr.indexOf;
2307
2308var class2type = {};
2309
2310var toString = class2type.toString;
2311
2312var hasOwn = class2type.hasOwnProperty;
2313
2314var support = {};
2315
2316
2317
2318var
2319	version = "2.2.4",
2320
2321	// Define a local copy of jQuery
2322	jQuery = function( selector, context ) {
2323
2324		// The jQuery object is actually just the init constructor 'enhanced'
2325		// Need init if jQuery is called (just allow error to be thrown if not included)
2326		return new jQuery.fn.init( selector, context );
2327	},
2328
2329	// Support: Android<4.1
2330	// Make sure we trim BOM and NBSP
2331	rtrim = /^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,
2332
2333	// Matches dashed string for camelizing
2334	rmsPrefix = /^-ms-/,
2335	rdashAlpha = /-([\da-z])/gi,
2336
2337	// Used by jQuery.camelCase as callback to replace()
2338	fcamelCase = function( all, letter ) {
2339		return letter.toUpperCase();
2340	};
2341
2342jQuery.fn = jQuery.prototype = {
2343
2344	// The current version of jQuery being used
2345	jquery: version,
2346
2347	constructor: jQuery,
2348
2349	// Start with an empty selector
2350	selector: "",
2351
2352	// The default length of a jQuery object is 0
2353	length: 0,
2354
2355	toArray: function() {
2356		return slice.call( this );
2357	},
2358
2359	// Get the Nth element in the matched element set OR
2360	// Get the whole matched element set as a clean array
2361	get: function( num ) {
2362		return num != null ?
2363
2364			// Return just the one element from the set
2365			( num < 0 ? this[ num + this.length ] : this[ num ] ) :
2366
2367			// Return all the elements in a clean array
2368			slice.call( this );
2369	},
2370
2371	// Take an array of elements and push it onto the stack
2372	// (returning the new matched element set)
2373	pushStack: function( elems ) {
2374
2375		// Build a new jQuery matched element set
2376		var ret = jQuery.merge( this.constructor(), elems );
2377
2378		// Add the old object onto the stack (as a reference)
2379		ret.prevObject = this;
2380		ret.context = this.context;
2381
2382		// Return the newly-formed element set
2383		return ret;
2384	},
2385
2386	// Execute a callback for every element in the matched set.
2387	each: function( callback ) {
2388		return jQuery.each( this, callback );
2389	},
2390
2391	map: function( callback ) {
2392		return this.pushStack( jQuery.map( this, function( elem, i ) {
2393			return callback.call( elem, i, elem );
2394		} ) );
2395	},
2396
2397	slice: function() {
2398		return this.pushStack( slice.apply( this, arguments ) );
2399	},
2400
2401	first: function() {
2402		return this.eq( 0 );
2403	},
2404
2405	last: function() {
2406		return this.eq( -1 );
2407	},
2408
2409	eq: function( i ) {
2410		var len = this.length,
2411			j = +i + ( i < 0 ? len : 0 );
2412		return this.pushStack( j >= 0 && j < len ? [ this[ j ] ] : [] );
2413	},
2414
2415	end: function() {
2416		return this.prevObject || this.constructor();
2417	},
2418
2419	// For internal use only.
2420	// Behaves like an Array's method, not like a jQuery method.
2421	push: push,
2422	sort: arr.sort,
2423	splice: arr.splice
2424};
2425
2426jQuery.extend = jQuery.fn.extend = function() {
2427	var options, name, src, copy, copyIsArray, clone,
2428		target = arguments[ 0 ] || {},
2429		i = 1,
2430		length = arguments.length,
2431		deep = false;
2432
2433	// Handle a deep copy situation
2434	if ( typeof target === "boolean" ) {
2435		deep = target;
2436
2437		// Skip the boolean and the target
2438		target = arguments[ i ] || {};
2439		i++;
2440	}
2441
2442	// Handle case when target is a string or something (possible in deep copy)
2443	if ( typeof target !== "object" && !jQuery.isFunction( target ) ) {
2444		target = {};
2445	}
2446
2447	// Extend jQuery itself if only one argument is passed
2448	if ( i === length ) {
2449		target = this;
2450		i--;
2451	}
2452
2453	for ( ; i < length; i++ ) {
2454
2455		// Only deal with non-null/undefined values
2456		if ( ( options = arguments[ i ] ) != null ) {
2457
2458			// Extend the base object
2459			for ( name in options ) {
2460				src = target[ name ];
2461				copy = options[ name ];
2462
2463				// Prevent never-ending loop
2464				if ( target === copy ) {
2465					continue;
2466				}
2467
2468				// Recurse if we're merging plain objects or arrays
2469				if ( deep && copy && ( jQuery.isPlainObject( copy ) ||
2470					( copyIsArray = jQuery.isArray( copy ) ) ) ) {
2471
2472					if ( copyIsArray ) {
2473						copyIsArray = false;
2474						clone = src && jQuery.isArray( src ) ? src : [];
2475
2476					} else {
2477						clone = src && jQuery.isPlainObject( src ) ? src : {};
2478					}
2479
2480					// Never move original objects, clone them
2481					target[ name ] = jQuery.extend( deep, clone, copy );
2482
2483				// Don't bring in undefined values
2484				} else if ( copy !== undefined ) {
2485					target[ name ] = copy;
2486				}
2487			}
2488		}
2489	}
2490
2491	// Return the modified object
2492	return target;
2493};
2494
2495jQuery.extend( {
2496
2497	// Unique for each copy of jQuery on the page
2498	expando: "jQuery" + ( version + Math.random() ).replace( /\D/g, "" ),
2499
2500	// Assume jQuery is ready without the ready module
2501	isReady: true,
2502
2503	error: function( msg ) {
2504		throw new Error( msg );
2505	},
2506
2507	noop: function() {},
2508
2509	isFunction: function( obj ) {
2510		return jQuery.type( obj ) === "function";
2511	},
2512
2513	isArray: Array.isArray,
2514
2515	isWindow: function( obj ) {
2516		return obj != null && obj === obj.window;
2517	},
2518
2519	isNumeric: function( obj ) {
2520
2521		// parseFloat NaNs numeric-cast false positives (null|true|false|"")
2522		// ...but misinterprets leading-number strings, particularly hex literals ("0x...")
2523		// subtraction forces infinities to NaN
2524		// adding 1 corrects loss of precision from parseFloat (#15100)
2525		var realStringObj = obj && obj.toString();
2526		return !jQuery.isArray( obj ) && ( realStringObj - parseFloat( realStringObj ) + 1 ) >= 0;
2527	},
2528
2529	isPlainObject: function( obj ) {
2530		var key;
2531
2532		// Not plain objects:
2533		// - Any object or value whose internal [[Class]] property is not "[object Object]"
2534		// - DOM nodes
2535		// - window
2536		if ( jQuery.type( obj ) !== "object" || obj.nodeType || jQuery.isWindow( obj ) ) {
2537			return false;
2538		}
2539
2540		// Not own constructor property must be Object
2541		if ( obj.constructor &&
2542				!hasOwn.call( obj, "constructor" ) &&
2543				!hasOwn.call( obj.constructor.prototype || {}, "isPrototypeOf" ) ) {
2544			return false;
2545		}
2546
2547		// Own properties are enumerated firstly, so to speed up,
2548		// if last one is own, then all properties are own
2549		for ( key in obj ) {}
2550
2551		return key === undefined || hasOwn.call( obj, key );
2552	},
2553
2554	isEmptyObject: function( obj ) {
2555		var name;
2556		for ( name in obj ) {
2557			return false;
2558		}
2559		return true;
2560	},
2561
2562	type: function( obj ) {
2563		if ( obj == null ) {
2564			return obj + "";
2565		}
2566
2567		// Support: Android<4.0, iOS<6 (functionish RegExp)
2568		return typeof obj === "object" || typeof obj === "function" ?
2569			class2type[ toString.call( obj ) ] || "object" :
2570			typeof obj;
2571	},
2572
2573	// Evaluates a script in a global context
2574	globalEval: function( code ) {
2575		var script,
2576			indirect = eval;
2577
2578		code = jQuery.trim( code );
2579
2580		if ( code ) {
2581
2582			// If the code includes a valid, prologue position
2583			// strict mode pragma, execute code by injecting a
2584			// script tag into the document.
2585			if ( code.indexOf( "use strict" ) === 1 ) {
2586				script = document.createElement( "script" );
2587				script.text = code;
2588				document.head.appendChild( script ).parentNode.removeChild( script );
2589			} else {
2590
2591				// Otherwise, avoid the DOM node creation, insertion
2592				// and removal by using an indirect global eval
2593
2594				indirect( code );
2595			}
2596		}
2597	},
2598
2599	// Convert dashed to camelCase; used by the css and data modules
2600	// Support: IE9-11+
2601	// Microsoft forgot to hump their vendor prefix (#9572)
2602	camelCase: function( string ) {
2603		return string.replace( rmsPrefix, "ms-" ).replace( rdashAlpha, fcamelCase );
2604	},
2605
vendor: 30,705 bytes, lines 2606-3715
2606	nodeName: function( elem, name ) {
2607		return elem.nodeName && elem.nodeName.toLowerCase() === name.toLowerCase();
2608	},
2609
2610	each: function( obj, callback ) {
2611		var length, i = 0;
2612
2613		if ( isArrayLike( obj ) ) {
2614			length = obj.length;
2615			for ( ; i < length; i++ ) {
2616				if ( callback.call( obj[ i ], i, obj[ i ] ) === false ) {
2617					break;
2618				}
2619			}
2620		} else {
2621			for ( i in obj ) {
2622				if ( callback.call( obj[ i ], i, obj[ i ] ) === false ) {
2623					break;
2624				}
2625			}
2626		}
2627
2628		return obj;
2629	},
2630
2631	// Support: Android<4.1
2632	trim: function( text ) {
2633		return text == null ?
2634			"" :
2635			( text + "" ).replace( rtrim, "" );
2636	},
2637
2638	// results is for internal usage only
2639	makeArray: function( arr, results ) {
2640		var ret = results || [];
2641
2642		if ( arr != null ) {
2643			if ( isArrayLike( Object( arr ) ) ) {
2644				jQuery.merge( ret,
2645					typeof arr === "string" ?
2646					[ arr ] : arr
2647				);
2648			} else {
2649				push.call( ret, arr );
2650			}
2651		}
2652
2653		return ret;
2654	},
2655
2656	inArray: function( elem, arr, i ) {
2657		return arr == null ? -1 : indexOf.call( arr, elem, i );
2658	},
2659
2660	merge: function( first, second ) {
2661		var len = +second.length,
2662			j = 0,
2663			i = first.length;
2664
2665		for ( ; j < len; j++ ) {
2666			first[ i++ ] = second[ j ];
2667		}
2668
2669		first.length = i;
2670
2671		return first;
2672	},
2673
2674	grep: function( elems, callback, invert ) {
2675		var callbackInverse,
2676			matches = [],
2677			i = 0,
2678			length = elems.length,
2679			callbackExpect = !invert;
2680
2681		// Go through the array, only saving the items
2682		// that pass the validator function
2683		for ( ; i < length; i++ ) {
2684			callbackInverse = !callback( elems[ i ], i );
2685			if ( callbackInverse !== callbackExpect ) {
2686				matches.push( elems[ i ] );
2687			}
2688		}
2689
2690		return matches;
2691	},
2692
2693	// arg is for internal usage only
2694	map: function( elems, callback, arg ) {
2695		var length, value,
2696			i = 0,
2697			ret = [];
2698
2699		// Go through the array, translating each of the items to their new values
2700		if ( isArrayLike( elems ) ) {
2701			length = elems.length;
2702			for ( ; i < length; i++ ) {
2703				value = callback( elems[ i ], i, arg );
2704
2705				if ( value != null ) {
2706					ret.push( value );
2707				}
2708			}
2709
2710		// Go through every key on the object,
2711		} else {
2712			for ( i in elems ) {
2713				value = callback( elems[ i ], i, arg );
2714
2715				if ( value != null ) {
2716					ret.push( value );
2717				}
2718			}
2719		}
2720
2721		// Flatten any nested arrays
2722		return concat.apply( [], ret );
2723	},
2724
2725	// A global GUID counter for objects
2726	guid: 1,
2727
2728	// Bind a function to a context, optionally partially applying any
2729	// arguments.
2730	proxy: function( fn, context ) {
2731		var tmp, args, proxy;
2732
2733		if ( typeof context === "string" ) {
2734			tmp = fn[ context ];
2735			context = fn;
2736			fn = tmp;
2737		}
2738
2739		// Quick check to determine if target is callable, in the spec
2740		// this throws a TypeError, but we will just return undefined.
2741		if ( !jQuery.isFunction( fn ) ) {
2742			return undefined;
2743		}
2744
2745		// Simulated bind
2746		args = slice.call( arguments, 2 );
2747		proxy = function() {
2748			return fn.apply( context || this, args.concat( slice.call( arguments ) ) );
2749		};
2750
2751		// Set the guid of unique handler to the same of original handler, so it can be removed
2752		proxy.guid = fn.guid = fn.guid || jQuery.guid++;
2753
2754		return proxy;
2755	},
2756
2757	now: Date.now,
2758
2759	// jQuery.support is not used in Core but other projects attach their
2760	// properties to it so it needs to exist.
2761	support: support
2762} );
2763
2764// JSHint would error on this code due to the Symbol not being defined in ES5.
2765// Defining this global in .jshintrc would create a danger of using the global
2766// unguarded in another place, it seems safer to just disable JSHint for these
2767// three lines.
2768/* jshint ignore: start */
2769if ( typeof Symbol === "function" ) {
2770	jQuery.fn[ Symbol.iterator ] = arr[ Symbol.iterator ];
2771}
2772/* jshint ignore: end */
2773
2774// Populate the class2type map
2775jQuery.each( "Boolean Number String Function Array Date RegExp Object Error Symbol".split( " " ),
2776function( i, name ) {
2777	class2type[ "[object " + name + "]" ] = name.toLowerCase();
2778} );
2779
2780function isArrayLike( obj ) {
2781
2782	// Support: iOS 8.2 (not reproducible in simulator)
2783	// `in` check used to prevent JIT error (gh-2145)
2784	// hasOwn isn't used here due to false negatives
2785	// regarding Nodelist length in IE
2786	var length = !!obj && "length" in obj && obj.length,
2787		type = jQuery.type( obj );
2788
2789	if ( type === "function" || jQuery.isWindow( obj ) ) {
2790		return false;
2791	}
2792
2793	return type === "array" || length === 0 ||
2794		typeof length === "number" && length > 0 && ( length - 1 ) in obj;
2795}
2796var Sizzle =
2797/*!
2798 * Sizzle CSS Selector Engine v2.2.1
2799 * http://sizzlejs.com/
2800 *
2801 * Copyright jQuery Foundation and other contributors
2802 * Released under the MIT license
2803 * http://jquery.org/license
2804 *
2805 * Date: 2015-10-17
2806 */
2807(function( window ) {
2808
2809var i,
2810	support,
2811	Expr,
2812	getText,
2813	isXML,
2814	tokenize,
2815	compile,
2816	select,
2817	outermostContext,
2818	sortInput,
2819	hasDuplicate,
2820
2821	// Local document vars
2822	setDocument,
2823	document,
2824	docElem,
2825	documentIsHTML,
2826	rbuggyQSA,
2827	rbuggyMatches,
2828	matches,
2829	contains,
2830
2831	// Instance-specific data
2832	expando = "sizzle" + 1 * new Date(),
2833	preferredDoc = window.document,
2834	dirruns = 0,
2835	done = 0,
2836	classCache = createCache(),
2837	tokenCache = createCache(),
2838	compilerCache = createCache(),
2839	sortOrder = function( a, b ) {
2840		if ( a === b ) {
2841			hasDuplicate = true;
2842		}
2843		return 0;
2844	},
2845
2846	// General-purpose constants
2847	MAX_NEGATIVE = 1 << 31,
2848
2849	// Instance methods
2850	hasOwn = ({}).hasOwnProperty,
2851	arr = [],
2852	pop = arr.pop,
2853	push_native = arr.push,
2854	push = arr.push,
2855	slice = arr.slice,
2856	// Use a stripped-down indexOf as it's faster than native
2857	// http://jsperf.com/thor-indexof-vs-for/5
2858	indexOf = function( list, elem ) {
2859		var i = 0,
2860			len = list.length;
2861		for ( ; i < len; i++ ) {
2862			if ( list[i] === elem ) {
2863				return i;
2864			}
2865		}
2866		return -1;
2867	},
2868
2869	booleans = "checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",
2870
2871	// Regular expressions
2872
2873	// http://www.w3.org/TR/css3-selectors/#whitespace
2874	whitespace = "[\\x20\\t\\r\\n\\f]",
2875
2876	// http://www.w3.org/TR/CSS21/syndata.html#value-def-identifier
2877	identifier = "(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",
2878
2879	// Attribute selectors: http://www.w3.org/TR/selectors/#attribute-selectors
2880	attributes = "\\[" + whitespace + "*(" + identifier + ")(?:" + whitespace +
2881		// Operator (capture 2)
2882		"*([*^$|!~]?=)" + whitespace +
2883		// "Attribute values must be CSS identifiers [capture 5] or strings [capture 3 or capture 4]"
2884		"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|(" + identifier + "))|)" + whitespace +
2885		"*\\]",
2886
2887	pseudos = ":(" + identifier + ")(?:\\((" +
2888		// To reduce the number of selectors needing tokenize in the preFilter, prefer arguments:
2889		// 1. quoted (capture 3; capture 4 or capture 5)
2890		"('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|" +
2891		// 2. simple (capture 6)
2892		"((?:\\\\.|[^\\\\()[\\]]|" + attributes + ")*)|" +
2893		// 3. anything else (capture 2)
2894		".*" +
2895		")\\)|)",
2896
2897	// Leading and non-escaped trailing whitespace, capturing some non-whitespace characters preceding the latter
2898	rwhitespace = new RegExp( whitespace + "+", "g" ),
2899	rtrim = new RegExp( "^" + whitespace + "+|((?:^|[^\\\\])(?:\\\\.)*)" + whitespace + "+$", "g" ),
2900
2901	rcomma = new RegExp( "^" + whitespace + "*," + whitespace + "*" ),
2902	rcombinators = new RegExp( "^" + whitespace + "*([>+~]|" + whitespace + ")" + whitespace + "*" ),
2903
2904	rattributeQuotes = new RegExp( "=" + whitespace + "*([^\\]'\"]*?)" + whitespace + "*\\]", "g" ),
2905
2906	rpseudo = new RegExp( pseudos ),
2907	ridentifier = new RegExp( "^" + identifier + "$" ),
2908
2909	matchExpr = {
2910		"ID": new RegExp( "^#(" + identifier + ")" ),
2911		"CLASS": new RegExp( "^\\.(" + identifier + ")" ),
2912		"TAG": new RegExp( "^(" + identifier + "|[*])" ),
2913		"ATTR": new RegExp( "^" + attributes ),
2914		"PSEUDO": new RegExp( "^" + pseudos ),
2915		"CHILD": new RegExp( "^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\(" + whitespace +
2916			"*(even|odd|(([+-]|)(\\d*)n|)" + whitespace + "*(?:([+-]|)" + whitespace +
2917			"*(\\d+)|))" + whitespace + "*\\)|)", "i" ),
2918		"bool": new RegExp( "^(?:" + booleans + ")$", "i" ),
2919		// For use in libraries implementing .is()
2920		// We use this for POS matching in `select`
2921		"needsContext": new RegExp( "^" + whitespace + "*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\(" +
2922			whitespace + "*((?:-\\d)?\\d*)" + whitespace + "*\\)|)(?=[^-]|$)", "i" )
2923	},
2924
2925	rinputs = /^(?:input|select|textarea|button)$/i,
2926	rheader = /^h\d$/i,
2927
2928	rnative = /^[^{]+\{\s*\[native \w/,
2929
2930	// Easily-parseable/retrievable ID or TAG or CLASS selectors
2931	rquickExpr = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,
2932
2933	rsibling = /[+~]/,
2934	rescape = /'|\\/g,
2935
2936	// CSS escapes http://www.w3.org/TR/CSS21/syndata.html#escaped-characters
2937	runescape = new RegExp( "\\\\([\\da-f]{1,6}" + whitespace + "?|(" + whitespace + ")|.)", "ig" ),
2938	funescape = function( _, escaped, escapedWhitespace ) {
2939		var high = "0x" + escaped - 0x10000;
2940		// NaN means non-codepoint
2941		// Support: Firefox<24
2942		// Workaround erroneous numeric interpretation of +"0x"
2943		return high !== high || escapedWhitespace ?
2944			escaped :
2945			high < 0 ?
2946				// BMP codepoint
2947				String.fromCharCode( high + 0x10000 ) :
2948				// Supplemental Plane codepoint (surrogate pair)
2949				String.fromCharCode( high >> 10 | 0xD800, high & 0x3FF | 0xDC00 );
2950	},
2951
2952	// Used for iframes
2953	// See setDocument()
2954	// Removing the function wrapper causes a "Permission Denied"
2955	// error in IE
2956	unloadHandler = function() {
2957		setDocument();
2958	};
2959
2960// Optimize for push.apply( _, NodeList )
2961try {
2962	push.apply(
2963		(arr = slice.call( preferredDoc.childNodes )),
2964		preferredDoc.childNodes
2965	);
2966	// Support: Android<4.0
2967	// Detect silently failing push.apply
2968	arr[ preferredDoc.childNodes.length ].nodeType;
2969} catch ( e ) {
2970	push = { apply: arr.length ?
2971
2972		// Leverage slice if possible
2973		function( target, els ) {
2974			push_native.apply( target, slice.call(els) );
2975		} :
2976
2977		// Support: IE<9
2978		// Otherwise append directly
2979		function( target, els ) {
2980			var j = target.length,
2981				i = 0;
2982			// Can't trust NodeList.length
2983			while ( (target[j++] = els[i++]) ) {}
2984			target.length = j - 1;
2985		}
2986	};
2987}
2988
2989function Sizzle( selector, context, results, seed ) {
2990	var m, i, elem, nid, nidselect, match, groups, newSelector,
2991		newContext = context && context.ownerDocument,
2992
2993		// nodeType defaults to 9, since context defaults to document
2994		nodeType = context ? context.nodeType : 9;
2995
2996	results = results || [];
2997
2998	// Return early from calls with invalid selector or context
2999	if ( typeof selector !== "string" || !selector ||
3000		nodeType !== 1 && nodeType !== 9 && nodeType !== 11 ) {
3001
3002		return results;
3003	}
3004
3005	// Try to shortcut find operations (as opposed to filters) in HTML documents
3006	if ( !seed ) {
3007
3008		if ( ( context ? context.ownerDocument || context : preferredDoc ) !== document ) {
3009			setDocument( context );
3010		}
3011		context = context || document;
3012
3013		if ( documentIsHTML ) {
3014
3015			// If the selector is sufficiently simple, try using a "get*By*" DOM method
3016			// (excepting DocumentFragment context, where the methods don't exist)
3017			if ( nodeType !== 11 && (match = rquickExpr.exec( selector )) ) {
3018
3019				// ID selector
3020				if ( (m = match[1]) ) {
3021
3022					// Document context
3023					if ( nodeType === 9 ) {
3024						if ( (elem = context.getElementById( m )) ) {
3025
3026							// Support: IE, Opera, Webkit
3027							// TODO: identify versions
3028							// getElementById can match elements by name instead of ID
3029							if ( elem.id === m ) {
3030								results.push( elem );
3031								return results;
3032							}
3033						} else {
3034							return results;
3035						}
3036
3037					// Element context
3038					} else {
3039
3040						// Support: IE, Opera, Webkit
3041						// TODO: identify versions
3042						// getElementById can match elements by name instead of ID
3043						if ( newContext && (elem = newContext.getElementById( m )) &&
3044							contains( context, elem ) &&
3045							elem.id === m ) {
3046
3047							results.push( elem );
3048							return results;
3049						}
3050					}
3051
3052				// Type selector
3053				} else if ( match[2] ) {
3054					push.apply( results, context.getElementsByTagName( selector ) );
3055					return results;
3056
3057				// Class selector
3058				} else if ( (m = match[3]) && support.getElementsByClassName &&
3059					context.getElementsByClassName ) {
3060
3061					push.apply( results, context.getElementsByClassName( m ) );
3062					return results;
3063				}
3064			}
3065
3066			// Take advantage of querySelectorAll
3067			if ( support.qsa &&
3068				!compilerCache[ selector + " " ] &&
3069				(!rbuggyQSA || !rbuggyQSA.test( selector )) ) {
3070
3071				if ( nodeType !== 1 ) {
3072					newContext = context;
3073					newSelector = selector;
3074
3075				// qSA looks outside Element context, which is not what we want
3076				// Thanks to Andrew Dupont for this workaround technique
3077				// Support: IE <=8
3078				// Exclude object elements
3079				} else if ( context.nodeName.toLowerCase() !== "object" ) {
3080
3081					// Capture the context ID, setting it first if necessary
3082					if ( (nid = context.getAttribute( "id" )) ) {
3083						nid = nid.replace( rescape, "\\$&" );
3084					} else {
3085						context.setAttribute( "id", (nid = expando) );
3086					}
3087
3088					// Prefix every selector in the list
3089					groups = tokenize( selector );
3090					i = groups.length;
3091					nidselect = ridentifier.test( nid ) ? "#" + nid : "[id='" + nid + "']";
3092					while ( i-- ) {
3093						groups[i] = nidselect + " " + toSelector( groups[i] );
3094					}
3095					newSelector = groups.join( "," );
3096
3097					// Expand context for sibling selectors
3098					newContext = rsibling.test( selector ) && testContext( context.parentNode ) ||
3099						context;
3100				}
3101
3102				if ( newSelector ) {
3103					try {
3104						push.apply( results,
3105							newContext.querySelectorAll( newSelector )
3106						);
3107						return results;
3108					} catch ( qsaError ) {
3109					} finally {
3110						if ( nid === expando ) {
3111							context.removeAttribute( "id" );
3112						}
3113					}
3114				}
3115			}
3116		}
3117	}
3118
3119	// All others
3120	return select( selector.replace( rtrim, "$1" ), context, results, seed );
3121}
3122
3123/**
3124 * Create key-value caches of limited size
3125 * @returns {function(string, object)} Returns the Object data after storing it on itself with
3126 *	property name the (space-suffixed) string and (if the cache is larger than Expr.cacheLength)
3127 *	deleting the oldest entry
3128 */
3129function createCache() {
3130	var keys = [];
3131
3132	function cache( key, value ) {
3133		// Use (key + " ") to avoid collision with native prototype properties (see Issue #157)
3134		if ( keys.push( key + " " ) > Expr.cacheLength ) {
3135			// Only keep the most recent entries
3136			delete cache[ keys.shift() ];
3137		}
3138		return (cache[ key + " " ] = value);
3139	}
3140	return cache;
3141}
3142
3143/**
3144 * Mark a function for special use by Sizzle
3145 * @param {Function} fn The function to mark
3146 */
3147function markFunction( fn ) {
3148	fn[ expando ] = true;
3149	return fn;
3150}
3151
3152/**
3153 * Support testing using an element
3154 * @param {Function} fn Passed the created div and expects a boolean result
3155 */
3156function assert( fn ) {
3157	var div = document.createElement("div");
3158
3159	try {
3160		return !!fn( div );
3161	} catch (e) {
3162		return false;
3163	} finally {
3164		// Remove from its parent by default
3165		if ( div.parentNode ) {
3166			div.parentNode.removeChild( div );
3167		}
3168		// release memory in IE
3169		div = null;
3170	}
3171}
3172
3173/**
3174 * Adds the same handler for all of the specified attrs
3175 * @param {String} attrs Pipe-separated list of attributes
3176 * @param {Function} handler The method that will be applied
3177 */
3178function addHandle( attrs, handler ) {
3179	var arr = attrs.split("|"),
3180		i = arr.length;
3181
3182	while ( i-- ) {
3183		Expr.attrHandle[ arr[i] ] = handler;
3184	}
3185}
3186
3187/**
3188 * Checks document order of two siblings
3189 * @param {Element} a
3190 * @param {Element} b
3191 * @returns {Number} Returns less than 0 if a precedes b, greater than 0 if a follows b
3192 */
3193function siblingCheck( a, b ) {
3194	var cur = b && a,
3195		diff = cur && a.nodeType === 1 && b.nodeType === 1 &&
3196			( ~b.sourceIndex || MAX_NEGATIVE ) -
3197			( ~a.sourceIndex || MAX_NEGATIVE );
3198
3199	// Use IE sourceIndex if available on both nodes
3200	if ( diff ) {
3201		return diff;
3202	}
3203
3204	// Check if b follows a
3205	if ( cur ) {
3206		while ( (cur = cur.nextSibling) ) {
3207			if ( cur === b ) {
3208				return -1;
3209			}
3210		}
3211	}
3212
3213	return a ? 1 : -1;
3214}
3215
3216/**
3217 * Returns a function to use in pseudos for input types
3218 * @param {String} type
3219 */
3220function createInputPseudo( type ) {
3221	return function( elem ) {
3222		var name = elem.nodeName.toLowerCase();
3223		return name === "input" && elem.type === type;
3224	};
3225}
3226
3227/**
3228 * Returns a function to use in pseudos for buttons
3229 * @param {String} type
3230 */
3231function createButtonPseudo( type ) {
3232	return function( elem ) {
3233		var name = elem.nodeName.toLowerCase();
3234		return (name === "input" || name === "button") && elem.type === type;
3235	};
3236}
3237
3238/**
3239 * Returns a function to use in pseudos for positionals
3240 * @param {Function} fn
3241 */
3242function createPositionalPseudo( fn ) {
3243	return markFunction(function( argument ) {
3244		argument = +argument;
3245		return markFunction(function( seed, matches ) {
3246			var j,
3247				matchIndexes = fn( [], seed.length, argument ),
3248				i = matchIndexes.length;
3249
3250			// Match elements found at the specified indexes
3251			while ( i-- ) {
3252				if ( seed[ (j = matchIndexes[i]) ] ) {
3253					seed[j] = !(matches[j] = seed[j]);
3254				}
3255			}
3256		});
3257	});
3258}
3259
3260/**
3261 * Checks a node for validity as a Sizzle context
3262 * @param {Element|Object=} context
3263 * @returns {Element|Object|Boolean} The input node if acceptable, otherwise a falsy value
3264 */
3265function testContext( context ) {
3266	return context && typeof context.getElementsByTagName !== "undefined" && context;
3267}
3268
3269// Expose support vars for convenience
3270support = Sizzle.support = {};
3271
3272/**
3273 * Detects XML nodes
3274 * @param {Element|Object} elem An element or a document
3275 * @returns {Boolean} True iff elem is a non-HTML XML node
3276 */
3277isXML = Sizzle.isXML = function( elem ) {
3278	// documentElement is verified for cases where it doesn't yet exist
3279	// (such as loading iframes in IE - #4833)
3280	var documentElement = elem && (elem.ownerDocument || elem).documentElement;
3281	return documentElement ? documentElement.nodeName !== "HTML" : false;
3282};
3283
3284/**
3285 * Sets document-related variables once based on the current document
3286 * @param {Element|Object} [doc] An element or document object to use to set the document
3287 * @returns {Object} Returns the current document
3288 */
3289setDocument = Sizzle.setDocument = function( node ) {
3290	var hasCompare, parent,
3291		doc = node ? node.ownerDocument || node : preferredDoc;
3292
3293	// Return early if doc is invalid or already selected
3294	if ( doc === document || doc.nodeType !== 9 || !doc.documentElement ) {
3295		return document;
3296	}
3297
3298	// Update global variables
3299	document = doc;
3300	docElem = document.documentElement;
3301	documentIsHTML = !isXML( document );
3302
3303	// Support: IE 9-11, Edge
3304	// Accessing iframe documents after unload throws "permission denied" errors (jQuery #13936)
3305	if ( (parent = document.defaultView) && parent.top !== parent ) {
3306		// Support: IE 11
3307		if ( parent.addEventListener ) {
3308			parent.addEventListener( "unload", unloadHandler, false );
3309
3310		// Support: IE 9 - 10 only
3311		} else if ( parent.attachEvent ) {
3312			parent.attachEvent( "onunload", unloadHandler );
3313		}
3314	}
3315
3316	/* Attributes
3317	---------------------------------------------------------------------- */
3318
3319	// Support: IE<8
3320	// Verify that getAttribute really returns attributes and not properties
3321	// (excepting IE8 booleans)
3322	support.attributes = assert(function( div ) {
3323		div.className = "i";
3324		return !div.getAttribute("className");
3325	});
3326
3327	/* getElement(s)By*
3328	---------------------------------------------------------------------- */
3329
3330	// Check if getElementsByTagName("*") returns only elements
3331	support.getElementsByTagName = assert(function( div ) {
3332		div.appendChild( document.createComment("") );
3333		return !div.getElementsByTagName("*").length;
3334	});
3335
3336	// Support: IE<9
3337	support.getElementsByClassName = rnative.test( document.getElementsByClassName );
3338
3339	// Support: IE<10
3340	// Check if getElementById returns elements by name
3341	// The broken getElementById methods don't pick up programatically-set names,
3342	// so use a roundabout getElementsByName test
3343	support.getById = assert(function( div ) {
3344		docElem.appendChild( div ).id = expando;
3345		return !document.getElementsByName || !document.getElementsByName( expando ).length;
3346	});
3347
3348	// ID find and filter
3349	if ( support.getById ) {
3350		Expr.find["ID"] = function( id, context ) {
3351			if ( typeof context.getElementById !== "undefined" && documentIsHTML ) {
3352				var m = context.getElementById( id );
3353				return m ? [ m ] : [];
3354			}
3355		};
3356		Expr.filter["ID"] = function( id ) {
3357			var attrId = id.replace( runescape, funescape );
3358			return function( elem ) {
3359				return elem.getAttribute("id") === attrId;
3360			};
3361		};
3362	} else {
3363		// Support: IE6/7
3364		// getElementById is not reliable as a find shortcut
3365		delete Expr.find["ID"];
3366
3367		Expr.filter["ID"] =  function( id ) {
3368			var attrId = id.replace( runescape, funescape );
3369			return function( elem ) {
3370				var node = typeof elem.getAttributeNode !== "undefined" &&
3371					elem.getAttributeNode("id");
3372				return node && node.value === attrId;
3373			};
3374		};
3375	}
3376
3377	// Tag
3378	Expr.find["TAG"] = support.getElementsByTagName ?
3379		function( tag, context ) {
3380			if ( typeof context.getElementsByTagName !== "undefined" ) {
3381				return context.getElementsByTagName( tag );
3382
3383			// DocumentFragment nodes don't have gEBTN
3384			} else if ( support.qsa ) {
3385				return context.querySelectorAll( tag );
3386			}
3387		} :
3388
3389		function( tag, context ) {
3390			var elem,
3391				tmp = [],
3392				i = 0,
3393				// By happy coincidence, a (broken) gEBTN appears on DocumentFragment nodes too
3394				results = context.getElementsByTagName( tag );
3395
3396			// Filter out possible comments
3397			if ( tag === "*" ) {
3398				while ( (elem = results[i++]) ) {
3399					if ( elem.nodeType === 1 ) {
3400						tmp.push( elem );
3401					}
3402				}
3403
3404				return tmp;
3405			}
3406			return results;
3407		};
3408
3409	// Class
3410	Expr.find["CLASS"] = support.getElementsByClassName && function( className, context ) {
3411		if ( typeof context.getElementsByClassName !== "undefined" && documentIsHTML ) {
3412			return context.getElementsByClassName( className );
3413		}
3414	};
3415
3416	/* QSA/matchesSelector
3417	---------------------------------------------------------------------- */
3418
3419	// QSA and matchesSelector support
3420
3421	// matchesSelector(:active) reports false when true (IE9/Opera 11.5)
3422	rbuggyMatches = [];
3423
3424	// qSa(:focus) reports false when true (Chrome 21)
3425	// We allow this because of a bug in IE8/9 that throws an error
3426	// whenever `document.activeElement` is accessed on an iframe
3427	// So, we allow :focus to pass through QSA all the time to avoid the IE error
3428	// See http://bugs.jquery.com/ticket/13378
3429	rbuggyQSA = [];
3430
3431	if ( (support.qsa = rnative.test( document.querySelectorAll )) ) {
3432		// Build QSA regex
3433		// Regex strategy adopted from Diego Perini
3434		assert(function( div ) {
3435			// Select is set to empty string on purpose
3436			// This is to test IE's treatment of not explicitly
3437			// setting a boolean content attribute,
3438			// since its presence should be enough
3439			// http://bugs.jquery.com/ticket/12359
3440			docElem.appendChild( div ).innerHTML = "<a id='" + expando + "'></a>" +
3441				"<select id='" + expando + "-\r\\' msallowcapture=''>" +
3442				"<option selected=''></option></select>";
3443
3444			// Support: IE8, Opera 11-12.16
3445			// Nothing should be selected when empty strings follow ^= or $= or *=
3446			// The test attribute must be unknown in Opera but "safe" for WinRT
3447			// http://msdn.microsoft.com/en-us/library/ie/hh465388.aspx#attribute_section
3448			if ( div.querySelectorAll("[msallowcapture^='']").length ) {
3449				rbuggyQSA.push( "[*^$]=" + whitespace + "*(?:''|\"\")" );
3450			}
3451
3452			// Support: IE8
3453			// Boolean attributes and "value" are not treated correctly
3454			if ( !div.querySelectorAll("[selected]").length ) {
3455				rbuggyQSA.push( "\\[" + whitespace + "*(?:value|" + booleans + ")" );
3456			}
3457
3458			// Support: Chrome<29, Android<4.4, Safari<7.0+, iOS<7.0+, PhantomJS<1.9.8+
3459			if ( !div.querySelectorAll( "[id~=" + expando + "-]" ).length ) {
3460				rbuggyQSA.push("~=");
3461			}
3462
3463			// Webkit/Opera - :checked should return selected option elements
3464			// http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked
3465			// IE8 throws error here and will not see later tests
3466			if ( !div.querySelectorAll(":checked").length ) {
3467				rbuggyQSA.push(":checked");
3468			}
3469
3470			// Support: Safari 8+, iOS 8+
3471			// https://bugs.webkit.org/show_bug.cgi?id=136851
3472			// In-page `selector#id sibing-combinator selector` fails
3473			if ( !div.querySelectorAll( "a#" + expando + "+*" ).length ) {
3474				rbuggyQSA.push(".#.+[+~]");
3475			}
3476		});
3477
3478		assert(function( div ) {
3479			// Support: Windows 8 Native Apps
3480			// The type and name attributes are restricted during .innerHTML assignment
3481			var input = document.createElement("input");
3482			input.setAttribute( "type", "hidden" );
3483			div.appendChild( input ).setAttribute( "name", "D" );
3484
3485			// Support: IE8
3486			// Enforce case-sensitivity of name attribute
3487			if ( div.querySelectorAll("[name=d]").length ) {
3488				rbuggyQSA.push( "name" + whitespace + "*[*^$|!~]?=" );
3489			}
3490
3491			// FF 3.5 - :enabled/:disabled and hidden elements (hidden elements are still enabled)
3492			// IE8 throws error here and will not see later tests
3493			if ( !div.querySelectorAll(":enabled").length ) {
3494				rbuggyQSA.push( ":enabled", ":disabled" );
3495			}
3496
3497			// Opera 10-11 does not throw on post-comma invalid pseudos
3498			div.querySelectorAll("*,:x");
3499			rbuggyQSA.push(",.*:");
3500		});
3501	}
3502
3503	if ( (support.matchesSelector = rnative.test( (matches = docElem.matches ||
3504		docElem.webkitMatchesSelector ||
3505		docElem.mozMatchesSelector ||
3506		docElem.oMatchesSelector ||
3507		docElem.msMatchesSelector) )) ) {
3508
3509		assert(function( div ) {
3510			// Check to see if it's possible to do matchesSelector
3511			// on a disconnected node (IE 9)
3512			support.disconnectedMatch = matches.call( div, "div" );
3513
3514			// This should fail with an exception
3515			// Gecko does not error, returns false instead
3516			matches.call( div, "[s!='']:x" );
3517			rbuggyMatches.push( "!=", pseudos );
3518		});
3519	}
3520
3521	rbuggyQSA = rbuggyQSA.length && new RegExp( rbuggyQSA.join("|") );
3522	rbuggyMatches = rbuggyMatches.length && new RegExp( rbuggyMatches.join("|") );
3523
3524	/* Contains
3525	---------------------------------------------------------------------- */
3526	hasCompare = rnative.test( docElem.compareDocumentPosition );
3527
3528	// Element contains another
3529	// Purposefully self-exclusive
3530	// As in, an element does not contain itself
3531	contains = hasCompare || rnative.test( docElem.contains ) ?
3532		function( a, b ) {
3533			var adown = a.nodeType === 9 ? a.documentElement : a,
3534				bup = b && b.parentNode;
3535			return a === bup || !!( bup && bup.nodeType === 1 && (
3536				adown.contains ?
3537					adown.contains( bup ) :
3538					a.compareDocumentPosition && a.compareDocumentPosition( bup ) & 16
3539			));
3540		} :
3541		function( a, b ) {
3542			if ( b ) {
3543				while ( (b = b.parentNode) ) {
3544					if ( b === a ) {
3545						return true;
3546					}
3547				}
3548			}
3549			return false;
3550		};
3551
3552	/* Sorting
3553	---------------------------------------------------------------------- */
3554
3555	// Document order sorting
3556	sortOrder = hasCompare ?
3557	function( a, b ) {
3558
3559		// Flag for duplicate removal
3560		if ( a === b ) {
3561			hasDuplicate = true;
3562			return 0;
3563		}
3564
3565		// Sort on method existence if only one input has compareDocumentPosition
3566		var compare = !a.compareDocumentPosition - !b.compareDocumentPosition;
3567		if ( compare ) {
3568			return compare;
3569		}
3570
3571		// Calculate position if both inputs belong to the same document
3572		compare = ( a.ownerDocument || a ) === ( b.ownerDocument || b ) ?
3573			a.compareDocumentPosition( b ) :
3574
3575			// Otherwise we know they are disconnected
3576			1;
3577
3578		// Disconnected nodes
3579		if ( compare & 1 ||
3580			(!support.sortDetached && b.compareDocumentPosition( a ) === compare) ) {
3581
3582			// Choose the first element that is related to our preferred document
3583			if ( a === document || a.ownerDocument === preferredDoc && contains(preferredDoc, a) ) {
3584				return -1;
3585			}
3586			if ( b === document || b.ownerDocument === preferredDoc && contains(preferredDoc, b) ) {
3587				return 1;
3588			}
3589
3590			// Maintain original order
3591			return sortInput ?
3592				( indexOf( sortInput, a ) - indexOf( sortInput, b ) ) :
3593				0;
3594		}
3595
3596		return compare & 4 ? -1 : 1;
3597	} :
3598	function( a, b ) {
3599		// Exit early if the nodes are identical
3600		if ( a === b ) {
3601			hasDuplicate = true;
3602			return 0;
3603		}
3604
3605		var cur,
3606			i = 0,
3607			aup = a.parentNode,
3608			bup = b.parentNode,
3609			ap = [ a ],
3610			bp = [ b ];
3611
3612		// Parentless nodes are either documents or disconnected
3613		if ( !aup || !bup ) {
3614			return a === document ? -1 :
3615				b === document ? 1 :
3616				aup ? -1 :
3617				bup ? 1 :
3618				sortInput ?
3619				( indexOf( sortInput, a ) - indexOf( sortInput, b ) ) :
3620				0;
3621
3622		// If the nodes are siblings, we can do a quick check
3623		} else if ( aup === bup ) {
3624			return siblingCheck( a, b );
3625		}
3626
3627		// Otherwise we need full lists of their ancestors for comparison
3628		cur = a;
3629		while ( (cur = cur.parentNode) ) {
3630			ap.unshift( cur );
3631		}
3632		cur = b;
3633		while ( (cur = cur.parentNode) ) {
3634			bp.unshift( cur );
3635		}
3636
3637		// Walk down the tree looking for a discrepancy
3638		while ( ap[i] === bp[i] ) {
3639			i++;
3640		}
3641
3642		return i ?
3643			// Do a sibling check if the nodes have a common ancestor
3644			siblingCheck( ap[i], bp[i] ) :
3645
3646			// Otherwise nodes in our document sort first
3647			ap[i] === preferredDoc ? -1 :
3648			bp[i] === preferredDoc ? 1 :
3649			0;
3650	};
3651
3652	return document;
3653};
3654
3655Sizzle.matches = function( expr, elements ) {
3656	return Sizzle( expr, null, null, elements );
3657};
3658
3659Sizzle.matchesSelector = function( elem, expr ) {
3660	// Set document vars if needed
3661	if ( ( elem.ownerDocument || elem ) !== document ) {
3662		setDocument( elem );
3663	}
3664
3665	// Make sure that attribute selectors are quoted
3666	expr = expr.replace( rattributeQuotes, "='$1']" );
3667
3668	if ( support.matchesSelector && documentIsHTML &&
3669		!compilerCache[ expr + " " ] &&
3670		( !rbuggyMatches || !rbuggyMatches.test( expr ) ) &&
3671		( !rbuggyQSA     || !rbuggyQSA.test( expr ) ) ) {
3672
3673		try {
3674			var ret = matches.call( elem, expr );
3675
3676			// IE 9's matchesSelector returns false on disconnected nodes
3677			if ( ret || support.disconnectedMatch ||
3678					// As well, disconnected nodes are said to be in a document
3679					// fragment in IE 9
3680					elem.document && elem.document.nodeType !== 11 ) {
3681				return ret;
3682			}
3683		} catch (e) {}
3684	}
3685
3686	return Sizzle( expr, document, null, [ elem ] ).length > 0;
3687};
3688
3689Sizzle.contains = function( context, elem ) {
3690	// Set document vars if needed
3691	if ( ( context.ownerDocument || context ) !== document ) {
3692		setDocument( context );
3693	}
3694	return contains( context, elem );
3695};
3696
3697Sizzle.attr = function( elem, name ) {
3698	// Set document vars if needed
3699	if ( ( elem.ownerDocument || elem ) !== document ) {
3700		setDocument( elem );
3701	}
3702
3703	var fn = Expr.attrHandle[ name.toLowerCase() ],
3704		// Don't get fooled by Object.prototype properties (jQuery #13807)
3705		val = fn && hasOwn.call( Expr.attrHandle, name.toLowerCase() ) ?
3706			fn( elem, name, !documentIsHTML ) :
3707			undefined;
3708
3709	return val !== undefined ?
3710		val :
3711		support.attributes || !documentIsHTML ?
3712			elem.getAttribute( name ) :
3713			(val = elem.getAttributeNode(name)) && val.specified ?
3714				val.value :
3715				null
vendor: 13,569 bytes, lines 3715-4185
3715;
3716};
3717
3718Sizzle.error = function( msg ) {
3719	throw new Error( "Syntax error, unrecognized expression: " + msg );
3720};
3721
3722/**
3723 * Document sorting and removing duplicates
3724 * @param {ArrayLike} results
3725 */
3726Sizzle.uniqueSort = function( results ) {
3727	var elem,
3728		duplicates = [],
3729		j = 0,
3730		i = 0;
3731
3732	// Unless we *know* we can detect duplicates, assume their presence
3733	hasDuplicate = !support.detectDuplicates;
3734	sortInput = !support.sortStable && results.slice( 0 );
3735	results.sort( sortOrder );
3736
3737	if ( hasDuplicate ) {
3738		while ( (elem = results[i++]) ) {
3739			if ( elem === results[ i ] ) {
3740				j = duplicates.push( i );
3741			}
3742		}
3743		while ( j-- ) {
3744			results.splice( duplicates[ j ], 1 );
3745		}
3746	}
3747
3748	// Clear input after sorting to release objects
3749	// See https://github.com/jquery/sizzle/pull/225
3750	sortInput = null;
3751
3752	return results;
3753};
3754
3755/**
3756 * Utility function for retrieving the text value of an array of DOM nodes
3757 * @param {Array|Element} elem
3758 */
3759getText = Sizzle.getText = function( elem ) {
3760	var node,
3761		ret = "",
3762		i = 0,
3763		nodeType = elem.nodeType;
3764
3765	if ( !nodeType ) {
3766		// If no nodeType, this is expected to be an array
3767		while ( (node = elem[i++]) ) {
3768			// Do not traverse comment nodes
3769			ret += getText( node );
3770		}
3771	} else if ( nodeType === 1 || nodeType === 9 || nodeType === 11 ) {
3772		// Use textContent for elements
3773		// innerText usage removed for consistency of new lines (jQuery #11153)
3774		if ( typeof elem.textContent === "string" ) {
3775			return elem.textContent;
3776		} else {
3777			// Traverse its children
3778			for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {
3779				ret += getText( elem );
3780			}
3781		}
3782	} else if ( nodeType === 3 || nodeType === 4 ) {
3783		return elem.nodeValue;
3784	}
3785	// Do not include comment or processing instruction nodes
3786
3787	return ret;
3788};
3789
3790Expr = Sizzle.selectors = {
3791
3792	// Can be adjusted by the user
3793	cacheLength: 50,
3794
3795	createPseudo: markFunction,
3796
3797	match: matchExpr,
3798
3799	attrHandle: {},
3800
3801	find: {},
3802
3803	relative: {
3804		">": { dir: "parentNode", first: true },
3805		" ": { dir: "parentNode" },
3806		"+": { dir: "previousSibling", first: true },
3807		"~": { dir: "previousSibling" }
3808	},
3809
3810	preFilter: {
3811		"ATTR": function( match ) {
3812			match[1] = match[1].replace( runescape, funescape );
3813
3814			// Move the given value to match[3] whether quoted or unquoted
3815			match[3] = ( match[3] || match[4] || match[5] || "" ).replace( runescape, funescape );
3816
3817			if ( match[2] === "~=" ) {
3818				match[3] = " " + match[3] + " ";
3819			}
3820
3821			return match.slice( 0, 4 );
3822		},
3823
3824		"CHILD": function( match ) {
3825			/* matches from matchExpr["CHILD"]
3826				1 type (only|nth|...)
3827				2 what (child|of-type)
3828				3 argument (even|odd|\d*|\d*n([+-]\d+)?|...)
3829				4 xn-component of xn+y argument ([+-]?\d*n|)
3830				5 sign of xn-component
3831				6 x of xn-component
3832				7 sign of y-component
3833				8 y of y-component
3834			*/
3835			match[1] = match[1].toLowerCase();
3836
3837			if ( match[1].slice( 0, 3 ) === "nth" ) {
3838				// nth-* requires argument
3839				if ( !match[3] ) {
3840					Sizzle.error( match[0] );
3841				}
3842
3843				// numeric x and y parameters for Expr.filter.CHILD
3844				// remember that false/true cast respectively to 0/1
3845				match[4] = +( match[4] ? match[5] + (match[6] || 1) : 2 * ( match[3] === "even" || match[3] === "odd" ) );
3846				match[5] = +( ( match[7] + match[8] ) || match[3] === "odd" );
3847
3848			// other types prohibit arguments
3849			} else if ( match[3] ) {
3850				Sizzle.error( match[0] );
3851			}
3852
3853			return match;
3854		},
3855
3856		"PSEUDO": function( match ) {
3857			var excess,
3858				unquoted = !match[6] && match[2];
3859
3860			if ( matchExpr["CHILD"].test( match[0] ) ) {
3861				return null;
3862			}
3863
3864			// Accept quoted arguments as-is
3865			if ( match[3] ) {
3866				match[2] = match[4] || match[5] || "";
3867
3868			// Strip excess characters from unquoted arguments
3869			} else if ( unquoted && rpseudo.test( unquoted ) &&
3870				// Get excess from tokenize (recursively)
3871				(excess = tokenize( unquoted, true )) &&
3872				// advance to the next closing parenthesis
3873				(excess = unquoted.indexOf( ")", unquoted.length - excess ) - unquoted.length) ) {
3874
3875				// excess is a negative index
3876				match[0] = match[0].slice( 0, excess );
3877				match[2] = unquoted.slice( 0, excess );
3878			}
3879
3880			// Return only captures needed by the pseudo filter method (type and argument)
3881			return match.slice( 0, 3 );
3882		}
3883	},
3884
3885	filter: {
3886
3887		"TAG": function( nodeNameSelector ) {
3888			var nodeName = nodeNameSelector.replace( runescape, funescape ).toLowerCase();
3889			return nodeNameSelector === "*" ?
3890				function() { return true; } :
3891				function( elem ) {
3892					return elem.nodeName && elem.nodeName.toLowerCase() === nodeName;
3893				};
3894		},
3895
3896		"CLASS": function( className ) {
3897			var pattern = classCache[ className + " " ];
3898
3899			return pattern ||
3900				(pattern = new RegExp( "(^|" + whitespace + ")" + className + "(" + whitespace + "|$)" )) &&
3901				classCache( className, function( elem ) {
3902					return pattern.test( typeof elem.className === "string" && elem.className || typeof elem.getAttribute !== "undefined" && elem.getAttribute("class") || "" );
3903				});
3904		},
3905
3906		"ATTR": function( name, operator, check ) {
3907			return function( elem ) {
3908				var result = Sizzle.attr( elem, name );
3909
3910				if ( result == null ) {
3911					return operator === "!=";
3912				}
3913				if ( !operator ) {
3914					return true;
3915				}
3916
3917				result += "";
3918
3919				return operator === "=" ? result === check :
3920					operator === "!=" ? result !== check :
3921					operator === "^=" ? check && result.indexOf( check ) === 0 :
3922					operator === "*=" ? check && result.indexOf( check ) > -1 :
3923					operator === "$=" ? check && result.slice( -check.length ) === check :
3924					operator === "~=" ? ( " " + result.replace( rwhitespace, " " ) + " " ).indexOf( check ) > -1 :
3925					operator === "|=" ? result === check || result.slice( 0, check.length + 1 ) === check + "-" :
3926					false;
3927			};
3928		},
3929
3930		"CHILD": function( type, what, argument, first, last ) {
3931			var simple = type.slice( 0, 3 ) !== "nth",
3932				forward = type.slice( -4 ) !== "last",
3933				ofType = what === "of-type";
3934
3935			return first === 1 && last === 0 ?
3936
3937				// Shortcut for :nth-*(n)
3938				function( elem ) {
3939					return !!elem.parentNode;
3940				} :
3941
3942				function( elem, context, xml ) {
3943					var cache, uniqueCache, outerCache, node, nodeIndex, start,
3944						dir = simple !== forward ? "nextSibling" : "previousSibling",
3945						parent = elem.parentNode,
3946						name = ofType && elem.nodeName.toLowerCase(),
3947						useCache = !xml && !ofType,
3948						diff = false;
3949
3950					if ( parent ) {
3951
3952						// :(first|last|only)-(child|of-type)
3953						if ( simple ) {
3954							while ( dir ) {
3955								node = elem;
3956								while ( (node = node[ dir ]) ) {
3957									if ( ofType ?
3958										node.nodeName.toLowerCase() === name :
3959										node.nodeType === 1 ) {
3960
3961										return false;
3962									}
3963								}
3964								// Reverse direction for :only-* (if we haven't yet done so)
3965								start = dir = type === "only" && !start && "nextSibling";
3966							}
3967							return true;
3968						}
3969
3970						start = [ forward ? parent.firstChild : parent.lastChild ];
3971
3972						// non-xml :nth-child(...) stores cache data on `parent`
3973						if ( forward && useCache ) {
3974
3975							// Seek `elem` from a previously-cached index
3976
3977							// ...in a gzip-friendly way
3978							node = parent;
3979							outerCache = node[ expando ] || (node[ expando ] = {});
3980
3981							// Support: IE <9 only
3982							// Defend against cloned attroperties (jQuery gh-1709)
3983							uniqueCache = outerCache[ node.uniqueID ] ||
3984								(outerCache[ node.uniqueID ] = {});
3985
3986							cache = uniqueCache[ type ] || [];
3987							nodeIndex = cache[ 0 ] === dirruns && cache[ 1 ];
3988							diff = nodeIndex && cache[ 2 ];
3989							node = nodeIndex && parent.childNodes[ nodeIndex ];
3990
3991							while ( (node = ++nodeIndex && node && node[ dir ] ||
3992
3993								// Fallback to seeking `elem` from the start
3994								(diff = nodeIndex = 0) || start.pop()) ) {
3995
3996								// When found, cache indexes on `parent` and break
3997								if ( node.nodeType === 1 && ++diff && node === elem ) {
3998									uniqueCache[ type ] = [ dirruns, nodeIndex, diff ];
3999									break;
4000								}
4001							}
4002
4003						} else {
4004							// Use previously-cached element index if available
4005							if ( useCache ) {
4006								// ...in a gzip-friendly way
4007								node = elem;
4008								outerCache = node[ expando ] || (node[ expando ] = {});
4009
4010								// Support: IE <9 only
4011								// Defend against cloned attroperties (jQuery gh-1709)
4012								uniqueCache = outerCache[ node.uniqueID ] ||
4013									(outerCache[ node.uniqueID ] = {});
4014
4015								cache = uniqueCache[ type ] || [];
4016								nodeIndex = cache[ 0 ] === dirruns && cache[ 1 ];
4017								diff = nodeIndex;
4018							}
4019
4020							// xml :nth-child(...)
4021							// or :nth-last-child(...) or :nth(-last)?-of-type(...)
4022							if ( diff === false ) {
4023								// Use the same loop as above to seek `elem` from the start
4024								while ( (node = ++nodeIndex && node && node[ dir ] ||
4025									(diff = nodeIndex = 0) || start.pop()) ) {
4026
4027									if ( ( ofType ?
4028										node.nodeName.toLowerCase() === name :
4029										node.nodeType === 1 ) &&
4030										++diff ) {
4031
4032										// Cache the index of each encountered element
4033										if ( useCache ) {
4034											outerCache = node[ expando ] || (node[ expando ] = {});
4035
4036											// Support: IE <9 only
4037											// Defend against cloned attroperties (jQuery gh-1709)
4038											uniqueCache = outerCache[ node.uniqueID ] ||
4039												(outerCache[ node.uniqueID ] = {});
4040
4041											uniqueCache[ type ] = [ dirruns, diff ];
4042										}
4043
4044										if ( node === elem ) {
4045											break;
4046										}
4047									}
4048								}
4049							}
4050						}
4051
4052						// Incorporate the offset, then check against cycle size
4053						diff -= last;
4054						return diff === first || ( diff % first === 0 && diff / first >= 0 );
4055					}
4056				};
4057		},
4058
4059		"PSEUDO": function( pseudo, argument ) {
4060			// pseudo-class names are case-insensitive
4061			// http://www.w3.org/TR/selectors/#pseudo-classes
4062			// Prioritize by case sensitivity in case custom pseudos are added with uppercase letters
4063			// Remember that setFilters inherits from pseudos
4064			var args,
4065				fn = Expr.pseudos[ pseudo ] || Expr.setFilters[ pseudo.toLowerCase() ] ||
4066					Sizzle.error( "unsupported pseudo: " + pseudo );
4067
4068			// The user may use createPseudo to indicate that
4069			// arguments are needed to create the filter function
4070			// just as Sizzle does
4071			if ( fn[ expando ] ) {
4072				return fn( argument );
4073			}
4074
4075			// But maintain support for old signatures
4076			if ( fn.length > 1 ) {
4077				args = [ pseudo, pseudo, "", argument ];
4078				return Expr.setFilters.hasOwnProperty( pseudo.toLowerCase() ) ?
4079					markFunction(function( seed, matches ) {
4080						var idx,
4081							matched = fn( seed, argument ),
4082							i = matched.length;
4083						while ( i-- ) {
4084							idx = indexOf( seed, matched[i] );
4085							seed[ idx ] = !( matches[ idx ] = matched[i] );
4086						}
4087					}) :
4088					function( elem ) {
4089						return fn( elem, 0, args );
4090					};
4091			}
4092
4093			return fn;
4094		}
4095	},
4096
4097	pseudos: {
4098		// Potentially complex pseudos
4099		"not": markFunction(function( selector ) {
4100			// Trim the selector passed to compile
4101			// to avoid treating leading and trailing
4102			// spaces as combinators
4103			var input = [],
4104				results = [],
4105				matcher = compile( selector.replace( rtrim, "$1" ) );
4106
4107			return matcher[ expando ] ?
4108				markFunction(function( seed, matches, context, xml ) {
4109					var elem,
4110						unmatched = matcher( seed, null, xml, [] ),
4111						i = seed.length;
4112
4113					// Match elements unmatched by `matcher`
4114					while ( i-- ) {
4115						if ( (elem = unmatched[i]) ) {
4116							seed[i] = !(matches[i] = elem);
4117						}
4118					}
4119				}) :
4120				function( elem, context, xml ) {
4121					input[0] = elem;
4122					matcher( input, null, xml, results );
4123					// Don't keep the element (issue #299)
4124					input[0] = null;
4125					return !results.pop();
4126				};
4127		}),
4128
4129		"has": markFunction(function( selector ) {
4130			return function( elem ) {
4131				return Sizzle( selector, elem ).length > 0;
4132			};
4133		}),
4134
4135		"contains": markFunction(function( text ) {
4136			text = text.replace( runescape, funescape );
4137			return function( elem ) {
4138				return ( elem.textContent || elem.innerText || getText( elem ) ).indexOf( text ) > -1;
4139			};
4140		}),
4141
4142		// "Whether an element is represented by a :lang() selector
4143		// is based solely on the element's language value
4144		// being equal to the identifier C,
4145		// or beginning with the identifier C immediately followed by "-".
4146		// The matching of C against the element's language value is performed case-insensitively.
4147		// The identifier C does not have to be a valid language name."
4148		// http://www.w3.org/TR/selectors/#lang-pseudo
4149		"lang": markFunction( function( lang ) {
4150			// lang value must be a valid identifier
4151			if ( !ridentifier.test(lang || "") ) {
4152				Sizzle.error( "unsupported lang: " + lang );
4153			}
4154			lang = lang.replace( runescape, funescape ).toLowerCase();
4155			return function( elem ) {
4156				var elemLang;
4157				do {
4158					if ( (elemLang = documentIsHTML ?
4159						elem.lang :
4160						elem.getAttribute("xml:lang") || elem.getAttribute("lang")) ) {
4161
4162						elemLang = elemLang.toLowerCase();
4163						return elemLang === lang || elemLang.indexOf( lang + "-" ) === 0;
4164					}
4165				} while ( (elem = elem.parentNode) && elem.nodeType === 1 );
4166				return false;
4167			};
4168		}),
4169
4170		// Miscellaneous
4171		"target": function( elem ) {
4172			var hash = window.location && window.location.hash;
4173			return hash && hash.slice( 1 ) === elem.id;
4174		},
4175
4176		"root": function( elem ) {
4177			return elem === docElem;
4178		},
4179
4180		"focus": function( elem ) {
4181			return elem === document.activeElement && (!document.hasFocus || document.hasFocus()) && !!(elem.type || elem.href || ~elem.tabIndex);
4182		},
4183
4184		// Boolean properties
4185		"enabled": 
vendor: 6,738 bytes, lines 4185-4436
4185function( elem ) {
4186			return elem.disabled === false;
4187		},
4188
4189		"disabled": function( elem ) {
4190			return elem.disabled === true;
4191		},
4192
4193		"checked": function( elem ) {
4194			// In CSS3, :checked should return both checked and selected elements
4195			// http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked
4196			var nodeName = elem.nodeName.toLowerCase();
4197			return (nodeName === "input" && !!elem.checked) || (nodeName === "option" && !!elem.selected);
4198		},
4199
4200		"selected": function( elem ) {
4201			// Accessing this property makes selected-by-default
4202			// options in Safari work properly
4203			if ( elem.parentNode ) {
4204				elem.parentNode.selectedIndex;
4205			}
4206
4207			return elem.selected === true;
4208		},
4209
4210		// Contents
4211		"empty": function( elem ) {
4212			// http://www.w3.org/TR/selectors/#empty-pseudo
4213			// :empty is negated by element (1) or content nodes (text: 3; cdata: 4; entity ref: 5),
4214			//   but not by others (comment: 8; processing instruction: 7; etc.)
4215			// nodeType < 6 works because attributes (2) do not appear as children
4216			for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {
4217				if ( elem.nodeType < 6 ) {
4218					return false;
4219				}
4220			}
4221			return true;
4222		},
4223
4224		"parent": function( elem ) {
4225			return !Expr.pseudos["empty"]( elem );
4226		},
4227
4228		// Element/input types
4229		"header": function( elem ) {
4230			return rheader.test( elem.nodeName );
4231		},
4232
4233		"input": function( elem ) {
4234			return rinputs.test( elem.nodeName );
4235		},
4236
4237		"button": function( elem ) {
4238			var name = elem.nodeName.toLowerCase();
4239			return name === "input" && elem.type === "button" || name === "button";
4240		},
4241
4242		"text": function( elem ) {
4243			var attr;
4244			return elem.nodeName.toLowerCase() === "input" &&
4245				elem.type === "text" &&
4246
4247				// Support: IE<8
4248				// New HTML5 attribute values (e.g., "search") appear with elem.type === "text"
4249				( (attr = elem.getAttribute("type")) == null || attr.toLowerCase() === "text" );
4250		},
4251
4252		// Position-in-collection
4253		"first": createPositionalPseudo(function() {
4254			return [ 0 ];
4255		}),
4256
4257		"last": createPositionalPseudo(function( matchIndexes, length ) {
4258			return [ length - 1 ];
4259		}),
4260
4261		"eq": createPositionalPseudo(function( matchIndexes, length, argument ) {
4262			return [ argument < 0 ? argument + length : argument ];
4263		}),
4264
4265		"even": createPositionalPseudo(function( matchIndexes, length ) {
4266			var i = 0;
4267			for ( ; i < length; i += 2 ) {
4268				matchIndexes.push( i );
4269			}
4270			return matchIndexes;
4271		}),
4272
4273		"odd": createPositionalPseudo(function( matchIndexes, length ) {
4274			var i = 1;
4275			for ( ; i < length; i += 2 ) {
4276				matchIndexes.push( i );
4277			}
4278			return matchIndexes;
4279		}),
4280
4281		"lt": createPositionalPseudo(function( matchIndexes, length, argument ) {
4282			var i = argument < 0 ? argument + length : argument;
4283			for ( ; --i >= 0; ) {
4284				matchIndexes.push( i );
4285			}
4286			return matchIndexes;
4287		}),
4288
4289		"gt": createPositionalPseudo(function( matchIndexes, length, argument ) {
4290			var i = argument < 0 ? argument + length : argument;
4291			for ( ; ++i < length; ) {
4292				matchIndexes.push( i );
4293			}
4294			return matchIndexes;
4295		})
4296	}
4297};
4298
4299Expr.pseudos["nth"] = Expr.pseudos["eq"];
4300
4301// Add button/input type pseudos
4302for ( i in { radio: true, checkbox: true, file: true, password: true, image: true } ) {
4303	Expr.pseudos[ i ] = createInputPseudo( i );
4304}
4305for ( i in { submit: true, reset: true } ) {
4306	Expr.pseudos[ i ] = createButtonPseudo( i );
4307}
4308
4309// Easy API for creating new setFilters
4310function setFilters() {}
4311setFilters.prototype = Expr.filters = Expr.pseudos;
4312Expr.setFilters = new setFilters();
4313
4314tokenize = Sizzle.tokenize = function( selector, parseOnly ) {
4315	var matched, match, tokens, type,
4316		soFar, groups, preFilters,
4317		cached = tokenCache[ selector + " " ];
4318
4319	if ( cached ) {
4320		return parseOnly ? 0 : cached.slice( 0 );
4321	}
4322
4323	soFar = selector;
4324	groups = [];
4325	preFilters = Expr.preFilter;
4326
4327	while ( soFar ) {
4328
4329		// Comma and first run
4330		if ( !matched || (match = rcomma.exec( soFar )) ) {
4331			if ( match ) {
4332				// Don't consume trailing commas as valid
4333				soFar = soFar.slice( match[0].length ) || soFar;
4334			}
4335			groups.push( (tokens = []) );
4336		}
4337
4338		matched = false;
4339
4340		// Combinators
4341		if ( (match = rcombinators.exec( soFar )) ) {
4342			matched = match.shift();
4343			tokens.push({
4344				value: matched,
4345				// Cast descendant combinators to space
4346				type: match[0].replace( rtrim, " " )
4347			});
4348			soFar = soFar.slice( matched.length );
4349		}
4350
4351		// Filters
4352		for ( type in Expr.filter ) {
4353			if ( (match = matchExpr[ type ].exec( soFar )) && (!preFilters[ type ] ||
4354				(match = preFilters[ type ]( match ))) ) {
4355				matched = match.shift();
4356				tokens.push({
4357					value: matched,
4358					type: type,
4359					matches: match
4360				});
4361				soFar = soFar.slice( matched.length );
4362			}
4363		}
4364
4365		if ( !matched ) {
4366			break;
4367		}
4368	}
4369
4370	// Return the length of the invalid excess
4371	// if we're just parsing
4372	// Otherwise, throw an error or return tokens
4373	return parseOnly ?
4374		soFar.length :
4375		soFar ?
4376			Sizzle.error( selector ) :
4377			// Cache the tokens
4378			tokenCache( selector, groups ).slice( 0 );
4379};
4380
4381function toSelector( tokens ) {
4382	var i = 0,
4383		len = tokens.length,
4384		selector = "";
4385	for ( ; i < len; i++ ) {
4386		selector += tokens[i].value;
4387	}
4388	return selector;
4389}
4390
4391function addCombinator( matcher, combinator, base ) {
4392	var dir = combinator.dir,
4393		checkNonElements = base && dir === "parentNode",
4394		doneName = done++;
4395
4396	return combinator.first ?
4397		// Check against closest ancestor/preceding element
4398		function( elem, context, xml ) {
4399			while ( (elem = elem[ dir ]) ) {
4400				if ( elem.nodeType === 1 || checkNonElements ) {
4401					return matcher( elem, context, xml );
4402				}
4403			}
4404		} :
4405
4406		// Check against all ancestor/preceding elements
4407		function( elem, context, xml ) {
4408			var oldCache, uniqueCache, outerCache,
4409				newCache = [ dirruns, doneName ];
4410
4411			// We can't set arbitrary data on XML nodes, so they don't benefit from combinator caching
4412			if ( xml ) {
4413				while ( (elem = elem[ dir ]) ) {
4414					if ( elem.nodeType === 1 || checkNonElements ) {
4415						if ( matcher( elem, context, xml ) ) {
4416							return true;
4417						}
4418					}
4419				}
4420			} else {
4421				while ( (elem = elem[ dir ]) ) {
4422					if ( elem.nodeType === 1 || checkNonElements ) {
4423						outerCache = elem[ expando ] || (elem[ expando ] = {});
4424
4425						// Support: IE <9 only
4426						// Defend against cloned attroperties (jQuery gh-1709)
4427						uniqueCache = outerCache[ elem.uniqueID ] || (outerCache[ elem.uniqueID ] = {});
4428
4429						if ( (oldCache = uniqueCache[ dir ]) &&
4430							oldCache[ 0 ] === dirruns && oldCache[ 1 ] === doneName ) {
4431
4432							// Assign to newCache so results back-propagate to previous elements
4433							return (newCache[ 2 ] = oldCache[ 2 ]);
4434						} else {
4435							// Reuse newcache so results back-propagate to previous elements
4436							uniqueCache[ dir
vendor: 12,959 bytes, lines 4436-4879
4436 ] = newCache;
4437
4438							// A match means we're done; a fail means we have to keep checking
4439							if ( (newCache[ 2 ] = matcher( elem, context, xml )) ) {
4440								return true;
4441							}
4442						}
4443					}
4444				}
4445			}
4446		};
4447}
4448
4449function elementMatcher( matchers ) {
4450	return matchers.length > 1 ?
4451		function( elem, context, xml ) {
4452			var i = matchers.length;
4453			while ( i-- ) {
4454				if ( !matchers[i]( elem, context, xml ) ) {
4455					return false;
4456				}
4457			}
4458			return true;
4459		} :
4460		matchers[0];
4461}
4462
4463function multipleContexts( selector, contexts, results ) {
4464	var i = 0,
4465		len = contexts.length;
4466	for ( ; i < len; i++ ) {
4467		Sizzle( selector, contexts[i], results );
4468	}
4469	return results;
4470}
4471
4472function condense( unmatched, map, filter, context, xml ) {
4473	var elem,
4474		newUnmatched = [],
4475		i = 0,
4476		len = unmatched.length,
4477		mapped = map != null;
4478
4479	for ( ; i < len; i++ ) {
4480		if ( (elem = unmatched[i]) ) {
4481			if ( !filter || filter( elem, context, xml ) ) {
4482				newUnmatched.push( elem );
4483				if ( mapped ) {
4484					map.push( i );
4485				}
4486			}
4487		}
4488	}
4489
4490	return newUnmatched;
4491}
4492
4493function setMatcher( preFilter, selector, matcher, postFilter, postFinder, postSelector ) {
4494	if ( postFilter && !postFilter[ expando ] ) {
4495		postFilter = setMatcher( postFilter );
4496	}
4497	if ( postFinder && !postFinder[ expando ] ) {
4498		postFinder = setMatcher( postFinder, postSelector );
4499	}
4500	return markFunction(function( seed, results, context, xml ) {
4501		var temp, i, elem,
4502			preMap = [],
4503			postMap = [],
4504			preexisting = results.length,
4505
4506			// Get initial elements from seed or context
4507			elems = seed || multipleContexts( selector || "*", context.nodeType ? [ context ] : context, [] ),
4508
4509			// Prefilter to get matcher input, preserving a map for seed-results synchronization
4510			matcherIn = preFilter && ( seed || !selector ) ?
4511				condense( elems, preMap, preFilter, context, xml ) :
4512				elems,
4513
4514			matcherOut = matcher ?
4515				// If we have a postFinder, or filtered seed, or non-seed postFilter or preexisting results,
4516				postFinder || ( seed ? preFilter : preexisting || postFilter ) ?
4517
4518					// ...intermediate processing is necessary
4519					[] :
4520
4521					// ...otherwise use results directly
4522					results :
4523				matcherIn;
4524
4525		// Find primary matches
4526		if ( matcher ) {
4527			matcher( matcherIn, matcherOut, context, xml );
4528		}
4529
4530		// Apply postFilter
4531		if ( postFilter ) {
4532			temp = condense( matcherOut, postMap );
4533			postFilter( temp, [], context, xml );
4534
4535			// Un-match failing elements by moving them back to matcherIn
4536			i = temp.length;
4537			while ( i-- ) {
4538				if ( (elem = temp[i]) ) {
4539					matcherOut[ postMap[i] ] = !(matcherIn[ postMap[i] ] = elem);
4540				}
4541			}
4542		}
4543
4544		if ( seed ) {
4545			if ( postFinder || preFilter ) {
4546				if ( postFinder ) {
4547					// Get the final matcherOut by condensing this intermediate into postFinder contexts
4548					temp = [];
4549					i = matcherOut.length;
4550					while ( i-- ) {
4551						if ( (elem = matcherOut[i]) ) {
4552							// Restore matcherIn since elem is not yet a final match
4553							temp.push( (matcherIn[i] = elem) );
4554						}
4555					}
4556					postFinder( null, (matcherOut = []), temp, xml );
4557				}
4558
4559				// Move matched elements from seed to results to keep them synchronized
4560				i = matcherOut.length;
4561				while ( i-- ) {
4562					if ( (elem = matcherOut[i]) &&
4563						(temp = postFinder ? indexOf( seed, elem ) : preMap[i]) > -1 ) {
4564
4565						seed[temp] = !(results[temp] = elem);
4566					}
4567				}
4568			}
4569
4570		// Add elements to results, through postFinder if defined
4571		} else {
4572			matcherOut = condense(
4573				matcherOut === results ?
4574					matcherOut.splice( preexisting, matcherOut.length ) :
4575					matcherOut
4576			);
4577			if ( postFinder ) {
4578				postFinder( null, results, matcherOut, xml );
4579			} else {
4580				push.apply( results, matcherOut );
4581			}
4582		}
4583	});
4584}
4585
4586function matcherFromTokens( tokens ) {
4587	var checkContext, matcher, j,
4588		len = tokens.length,
4589		leadingRelative = Expr.relative[ tokens[0].type ],
4590		implicitRelative = leadingRelative || Expr.relative[" "],
4591		i = leadingRelative ? 1 : 0,
4592
4593		// The foundational matcher ensures that elements are reachable from top-level context(s)
4594		matchContext = addCombinator( function( elem ) {
4595			return elem === checkContext;
4596		}, implicitRelative, true ),
4597		matchAnyContext = addCombinator( function( elem ) {
4598			return indexOf( checkContext, elem ) > -1;
4599		}, implicitRelative, true ),
4600		matchers = [ function( elem, context, xml ) {
4601			var ret = ( !leadingRelative && ( xml || context !== outermostContext ) ) || (
4602				(checkContext = context).nodeType ?
4603					matchContext( elem, context, xml ) :
4604					matchAnyContext( elem, context, xml ) );
4605			// Avoid hanging onto element (issue #299)
4606			checkContext = null;
4607			return ret;
4608		} ];
4609
4610	for ( ; i < len; i++ ) {
4611		if ( (matcher = Expr.relative[ tokens[i].type ]) ) {
4612			matchers = [ addCombinator(elementMatcher( matchers ), matcher) ];
4613		} else {
4614			matcher = Expr.filter[ tokens[i].type ].apply( null, tokens[i].matches );
4615
4616			// Return special upon seeing a positional matcher
4617			if ( matcher[ expando ] ) {
4618				// Find the next relative operator (if any) for proper handling
4619				j = ++i;
4620				for ( ; j < len; j++ ) {
4621					if ( Expr.relative[ tokens[j].type ] ) {
4622						break;
4623					}
4624				}
4625				return setMatcher(
4626					i > 1 && elementMatcher( matchers ),
4627					i > 1 && toSelector(
4628						// If the preceding token was a descendant combinator, insert an implicit any-element `*`
4629						tokens.slice( 0, i - 1 ).concat({ value: tokens[ i - 2 ].type === " " ? "*" : "" })
4630					).replace( rtrim, "$1" ),
4631					matcher,
4632					i < j && matcherFromTokens( tokens.slice( i, j ) ),
4633					j < len && matcherFromTokens( (tokens = tokens.slice( j )) ),
4634					j < len && toSelector( tokens )
4635				);
4636			}
4637			matchers.push( matcher );
4638		}
4639	}
4640
4641	return elementMatcher( matchers );
4642}
4643
4644function matcherFromGroupMatchers( elementMatchers, setMatchers ) {
4645	var bySet = setMatchers.length > 0,
4646		byElement = elementMatchers.length > 0,
4647		superMatcher = function( seed, context, xml, results, outermost ) {
4648			var elem, j, matcher,
4649				matchedCount = 0,
4650				i = "0",
4651				unmatched = seed && [],
4652				setMatched = [],
4653				contextBackup = outermostContext,
4654				// We must always have either seed elements or outermost context
4655				elems = seed || byElement && Expr.find["TAG"]( "*", outermost ),
4656				// Use integer dirruns iff this is the outermost matcher
4657				dirrunsUnique = (dirruns += contextBackup == null ? 1 : Math.random() || 0.1),
4658				len = elems.length;
4659
4660			if ( outermost ) {
4661				outermostContext = context === document || context || outermost;
4662			}
4663
4664			// Add elements passing elementMatchers directly to results
4665			// Support: IE<9, Safari
4666			// Tolerate NodeList properties (IE: "length"; Safari: <number>) matching elements by id
4667			for ( ; i !== len && (elem = elems[i]) != null; i++ ) {
4668				if ( byElement && elem ) {
4669					j = 0;
4670					if ( !context && elem.ownerDocument !== document ) {
4671						setDocument( elem );
4672						xml = !documentIsHTML;
4673					}
4674					while ( (matcher = elementMatchers[j++]) ) {
4675						if ( matcher( elem, context || document, xml) ) {
4676							results.push( elem );
4677							break;
4678						}
4679					}
4680					if ( outermost ) {
4681						dirruns = dirrunsUnique;
4682					}
4683				}
4684
4685				// Track unmatched elements for set filters
4686				if ( bySet ) {
4687					// They will have gone through all possible matchers
4688					if ( (elem = !matcher && elem) ) {
4689						matchedCount--;
4690					}
4691
4692					// Lengthen the array for every element, matched or not
4693					if ( seed ) {
4694						unmatched.push( elem );
4695					}
4696				}
4697			}
4698
4699			// `i` is now the count of elements visited above, and adding it to `matchedCount`
4700			// makes the latter nonnegative.
4701			matchedCount += i;
4702
4703			// Apply set filters to unmatched elements
4704			// NOTE: This can be skipped if there are no unmatched elements (i.e., `matchedCount`
4705			// equals `i`), unless we didn't visit _any_ elements in the above loop because we have
4706			// no element matchers and no seed.
4707			// Incrementing an initially-string "0" `i` allows `i` to remain a string only in that
4708			// case, which will result in a "00" `matchedCount` that differs from `i` but is also
4709			// numerically zero.
4710			if ( bySet && i !== matchedCount ) {
4711				j = 0;
4712				while ( (matcher = setMatchers[j++]) ) {
4713					matcher( unmatched, setMatched, context, xml );
4714				}
4715
4716				if ( seed ) {
4717					// Reintegrate element matches to eliminate the need for sorting
4718					if ( matchedCount > 0 ) {
4719						while ( i-- ) {
4720							if ( !(unmatched[i] || setMatched[i]) ) {
4721								setMatched[i] = pop.call( results );
4722							}
4723						}
4724					}
4725
4726					// Discard index placeholder values to get only actual matches
4727					setMatched = condense( setMatched );
4728				}
4729
4730				// Add matches to results
4731				push.apply( results, setMatched );
4732
4733				// Seedless set matches succeeding multiple successful matchers stipulate sorting
4734				if ( outermost && !seed && setMatched.length > 0 &&
4735					( matchedCount + setMatchers.length ) > 1 ) {
4736
4737					Sizzle.uniqueSort( results );
4738				}
4739			}
4740
4741			// Override manipulation of globals by nested matchers
4742			if ( outermost ) {
4743				dirruns = dirrunsUnique;
4744				outermostContext = contextBackup;
4745			}
4746
4747			return unmatched;
4748		};
4749
4750	return bySet ?
4751		markFunction( superMatcher ) :
4752		superMatcher;
4753}
4754
4755compile = Sizzle.compile = function( selector, match /* Internal Use Only */ ) {
4756	var i,
4757		setMatchers = [],
4758		elementMatchers = [],
4759		cached = compilerCache[ selector + " " ];
4760
4761	if ( !cached ) {
4762		// Generate a function of recursive functions that can be used to check each element
4763		if ( !match ) {
4764			match = tokenize( selector );
4765		}
4766		i = match.length;
4767		while ( i-- ) {
4768			cached = matcherFromTokens( match[i] );
4769			if ( cached[ expando ] ) {
4770				setMatchers.push( cached );
4771			} else {
4772				elementMatchers.push( cached );
4773			}
4774		}
4775
4776		// Cache the compiled function
4777		cached = compilerCache( selector, matcherFromGroupMatchers( elementMatchers, setMatchers ) );
4778
4779		// Save selector and tokenization
4780		cached.selector = selector;
4781	}
4782	return cached;
4783};
4784
4785/**
4786 * A low-level selection function that works with Sizzle's compiled
4787 *  selector functions
4788 * @param {String|Function} selector A selector or a pre-compiled
4789 *  selector function built with Sizzle.compile
4790 * @param {Element} context
4791 * @param {Array} [results]
4792 * @param {Array} [seed] A set of elements to match against
4793 */
4794select = Sizzle.select = function( selector, context, results, seed ) {
4795	var i, tokens, token, type, find,
4796		compiled = typeof selector === "function" && selector,
4797		match = !seed && tokenize( (selector = compiled.selector || selector) );
4798
4799	results = results || [];
4800
4801	// Try to minimize operations if there is only one selector in the list and no seed
4802	// (the latter of which guarantees us context)
4803	if ( match.length === 1 ) {
4804
4805		// Reduce context if the leading compound selector is an ID
4806		tokens = match[0] = match[0].slice( 0 );
4807		if ( tokens.length > 2 && (token = tokens[0]).type === "ID" &&
4808				support.getById && context.nodeType === 9 && documentIsHTML &&
4809				Expr.relative[ tokens[1].type ] ) {
4810
4811			context = ( Expr.find["ID"]( token.matches[0].replace(runescape, funescape), context ) || [] )[0];
4812			if ( !context ) {
4813				return results;
4814
4815			// Precompiled matchers will still verify ancestry, so step up a level
4816			} else if ( compiled ) {
4817				context = context.parentNode;
4818			}
4819
4820			selector = selector.slice( tokens.shift().value.length );
4821		}
4822
4823		// Fetch a seed set for right-to-left matching
4824		i = matchExpr["needsContext"].test( selector ) ? 0 : tokens.length;
4825		while ( i-- ) {
4826			token = tokens[i];
4827
4828			// Abort if we hit a combinator
4829			if ( Expr.relative[ (type = token.type) ] ) {
4830				break;
4831			}
4832			if ( (find = Expr.find[ type ]) ) {
4833				// Search, expanding context for leading sibling combinators
4834				if ( (seed = find(
4835					token.matches[0].replace( runescape, funescape ),
4836					rsibling.test( tokens[0].type ) && testContext( context.parentNode ) || context
4837				)) ) {
4838
4839					// If seed is empty or no tokens remain, we can return early
4840					tokens.splice( i, 1 );
4841					selector = seed.length && toSelector( tokens );
4842					if ( !selector ) {
4843						push.apply( results, seed );
4844						return results;
4845					}
4846
4847					break;
4848				}
4849			}
4850		}
4851	}
4852
4853	// Compile and execute a filtering function if one is not provided
4854	// Provide `match` to avoid retokenization if we modified the selector above
4855	( compiled || compile( selector, match ) )(
4856		seed,
4857		context,
4858		!documentIsHTML,
4859		results,
4860		!context || rsibling.test( selector ) && testContext( context.parentNode ) || context
4861	);
4862	return results;
4863};
4864
4865// One-time assignments
4866
4867// Sort stability
4868support.sortStable = expando.split("").sort( sortOrder ).join("") === expando;
4869
4870// Support: Chrome 14-35+
4871// Always assume duplicates if they aren't passed to the comparison function
4872support.detectDuplicates = !!hasDuplicate;
4873
4874// Initialize against the default document
4875setDocument();
4876
4877// Support: Webkit<537.32 - Safari 6.0.3/Chrome 25 (fixed in Chrome 27)
4878// Detached nodes confoundingly follow *each other*
4879support.sortDetached = assert(function( 
vendor: 3,544 bytes, lines 4879-5032
4879div1 ) {
4880	// Should return 1, but returns 4 (following)
4881	return div1.compareDocumentPosition( document.createElement("div") ) & 1;
4882});
4883
4884// Support: IE<8
4885// Prevent attribute/property "interpolation"
4886// http://msdn.microsoft.com/en-us/library/ms536429%28VS.85%29.aspx
4887if ( !assert(function( div ) {
4888	div.innerHTML = "<a href='#'></a>";
4889	return div.firstChild.getAttribute("href") === "#" ;
4890}) ) {
4891	addHandle( "type|href|height|width", function( elem, name, isXML ) {
4892		if ( !isXML ) {
4893			return elem.getAttribute( name, name.toLowerCase() === "type" ? 1 : 2 );
4894		}
4895	});
4896}
4897
4898// Support: IE<9
4899// Use defaultValue in place of getAttribute("value")
4900if ( !support.attributes || !assert(function( div ) {
4901	div.innerHTML = "<input/>";
4902	div.firstChild.setAttribute( "value", "" );
4903	return div.firstChild.getAttribute( "value" ) === "";
4904}) ) {
4905	addHandle( "value", function( elem, name, isXML ) {
4906		if ( !isXML && elem.nodeName.toLowerCase() === "input" ) {
4907			return elem.defaultValue;
4908		}
4909	});
4910}
4911
4912// Support: IE<9
4913// Use getAttributeNode to fetch booleans when getAttribute lies
4914if ( !assert(function( div ) {
4915	return div.getAttribute("disabled") == null;
4916}) ) {
4917	addHandle( booleans, function( elem, name, isXML ) {
4918		var val;
4919		if ( !isXML ) {
4920			return elem[ name ] === true ? name.toLowerCase() :
4921					(val = elem.getAttributeNode( name )) && val.specified ?
4922					val.value :
4923				null;
4924		}
4925	});
4926}
4927
4928return Sizzle;
4929
4930})( window );
4931
4932
4933
4934jQuery.find = Sizzle;
4935jQuery.expr = Sizzle.selectors;
4936jQuery.expr[ ":" ] = jQuery.expr.pseudos;
4937jQuery.uniqueSort = jQuery.unique = Sizzle.uniqueSort;
4938jQuery.text = Sizzle.getText;
4939jQuery.isXMLDoc = Sizzle.isXML;
4940jQuery.contains = Sizzle.contains;
4941
4942
4943
4944var dir = function( elem, dir, until ) {
4945	var matched = [],
4946		truncate = until !== undefined;
4947
4948	while ( ( elem = elem[ dir ] ) && elem.nodeType !== 9 ) {
4949		if ( elem.nodeType === 1 ) {
4950			if ( truncate && jQuery( elem ).is( until ) ) {
4951				break;
4952			}
4953			matched.push( elem );
4954		}
4955	}
4956	return matched;
4957};
4958
4959
4960var siblings = function( n, elem ) {
4961	var matched = [];
4962
4963	for ( ; n; n = n.nextSibling ) {
4964		if ( n.nodeType === 1 && n !== elem ) {
4965			matched.push( n );
4966		}
4967	}
4968
4969	return matched;
4970};
4971
4972
4973var rneedsContext = jQuery.expr.match.needsContext;
4974
4975var rsingleTag = ( /^<([\w-]+)\s*\/?>(?:<\/\1>|)$/ );
4976
4977
4978
4979var risSimple = /^.[^:#\[\.,]*$/;
4980
4981// Implement the identical functionality for filter and not
4982function winnow( elements, qualifier, not ) {
4983	if ( jQuery.isFunction( qualifier ) ) {
4984		return jQuery.grep( elements, function( elem, i ) {
4985			/* jshint -W018 */
4986			return !!qualifier.call( elem, i, elem ) !== not;
4987		} );
4988
4989	}
4990
4991	if ( qualifier.nodeType ) {
4992		return jQuery.grep( elements, function( elem ) {
4993			return ( elem === qualifier ) !== not;
4994		} );
4995
4996	}
4997
4998	if ( typeof qualifier === "string" ) {
4999		if ( risSimple.test( qualifier ) ) {
5000			return jQuery.filter( qualifier, elements, not );
5001		}
5002
5003		qualifier = jQuery.filter( qualifier, elements );
5004	}
5005
5006	return jQuery.grep( elements, function( elem ) {
5007		return ( indexOf.call( qualifier, elem ) > -1 ) !== not;
5008	} );
5009}
5010
5011jQuery.filter = function( expr, elems, not ) {
5012	var elem = elems[ 0 ];
5013
5014	if ( not ) {
5015		expr = ":not(" + expr + ")";
5016	}
5017
5018	return elems.length === 1 && elem.nodeType === 1 ?
5019		jQuery.find.matchesSelector( elem, expr ) ? [ elem ] : [] :
5020		jQuery.find.matches( expr, jQuery.grep( elems, function( elem ) {
5021			return elem.nodeType === 1;
5022		} ) );
5023};
5024
5025jQuery.fn.extend( {
5026	find: function( selector ) {
5027		var i,
5028			len = this.length,
5029			ret = [],
5030			self = this;
5031
5032		if ( typeof selector !== "string" ) {
5033			return this.pushStack( jQuery( selector ).filter( function() {
5034				for ( i = 0; i < len; i++ ) {
5035					if ( jQuery.contains( self[ i ], this ) ) {
5036						return true;
5037					}
5038				}
5039			} ) );
5040		}
5041
5042		for ( i = 0; i < len; i++ ) {
5043			jQuery.find( selector, self[ i ], ret );
5044		}
5045
5046		// Needed because $( selector, context ) becomes $( context ).find( selector )
5047		ret = this.pushStack( len > 1 ? jQuery.unique( ret ) : ret );
5048		ret.selector = this.selector ? this.selector + " " + selector : selector;
5049		return ret;
5050	},
5051	filter: function( selector ) {
5052		return this.pushStack( winnow( this, selector || [], false ) );
5053	},
5054	not: function( selector ) {
5055		return this.pushStack( winnow( this, selector || [], true ) );
5056	},
5057	is: function( selector ) {
5058		return !!winnow(
5059			this,
5060
5061			// If this is a positional/relative selector, check membership in the returned set
5062			// so $("p:first").is("p:last") won't return true for a doc with two "p".
5063			typeof selector === "string" && rneedsContext.test( selector ) ?
5064				jQuery( selector ) :
5065				selector || [],
5066			false
5067		).length;
5068	}
5069} );
5070
5071
5072// Initialize a jQuery object
5073
5074
5075// A central reference to the root jQuery(document)
5076var rootjQuery,
5077
5078	// A simple way to check for HTML strings
5079	// Prioritize #id over <tag> to avoid XSS via location.hash (#9521)
5080	// Strict HTML recognition (#11290: must start with <)
5081	rquickExpr = /^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,
5082
5083	init = jQuery.fn.init = function( selector, context, root ) {
5084		var match, elem;
5085
5086		// HANDLE: $(""), $(null), $(undefined), $(false)
5087		if ( !selector ) {
5088			return this;
5089		}
5090
5091		// Method init() accepts an alternate rootjQuery
5092		// so migrate can support jQuery.sub (gh-2101)
5093		root = root || rootjQuery;
5094
5095		// Handle HTML strings
5096		if ( typeof selector === "string" ) {
5097			if ( selector[ 0 ] === "<" &&
5098				selector[ selector.length - 1 ] === ">" &&
5099				selector.length >= 3 ) {
5100
5101				// Assume that strings that start and end with <> are HTML and skip the regex check
5102				match = [ null, selector, null ];
5103
5104			} else {
5105				match = rquickExpr.exec( selector );
5106			}
5107
5108			// Match html or make sure no context is specified for #id
5109			if ( match && ( match[ 1 ] || !context ) ) {
5110
5111				// HANDLE: $(html) -> $(array)
5112				if ( match[ 1 ] ) {
5113					context = context instanceof jQuery ? context[ 0 ] : context;
5114
5115					// Option to run scripts is true for back-compat
5116					// Intentionally let the error be thrown if parseHTML is not present
5117					jQuery.merge( this, jQuery.parseHTML(
5118						match[ 1 ],
5119						context && context.nodeType ? context.ownerDocument || context : document,
5120						true
5121					) );
5122
5123					// HANDLE: $(html, props)
5124					if ( rsingleTag.test( match[ 1 ] ) && jQuery.isPlainObject( context ) ) {
5125						for ( match in context ) {
5126
5127							// Properties of context are called as methods if possible
5128							if ( jQuery.isFunction( this[ match ] ) ) {
5129								this[ match ]( context[ match ] );
5130
5131							// ...and otherwise set as attributes
5132							} else {
5133								this.attr( match, context[ match ] );
5134							}
5135						}
5136					}
5137
5138					return this;
5139
5140				// HANDLE: $(#id)
5141				} else {
5142					elem = document.getElementById( match[ 2 ] );
5143
5144					// Support: Blackberry 4.6
5145					// gEBID returns nodes no longer in the document (#6963)
5146					if ( elem && elem.parentNode ) {
5147
5148						// Inject the element directly into the jQuery object
5149						this.length = 1;
5150						this[ 0 ] = elem;
5151					}
5152
5153					this.context = document;
5154					this.selector = selector;
5155					return this;
5156				}
5157
5158			// HANDLE: $(expr, $(...))
5159			} else if ( !context || context.jquery ) {
5160				return ( context || root ).find( selector );
5161
5162			// HANDLE: $(expr, context)
5163			// (which is just equivalent to: $(context).find(expr)
5164			} else {
5165				return this.constructor( context ).find( selector );
5166			}
5167
5168		// HANDLE: $(DOMElement)
5169		} else if ( selector.nodeType ) {
5170			this.context = this[ 0 ] = selector;
5171			this.length = 1;
5172			return this;
5173
5174		// HANDLE: $(function)
5175		// Shortcut for document ready
5176		} else if ( jQuery.isFunction( selector ) ) {
5177			return root.ready !== undefined ?
5178				root.ready( selector ) :
5179
5180				// Execute immediately if ready is not present
5181				selector( jQuery );
5182		}
5183
5184		if ( selector.selector !== undefined ) {
5185			this.selector = selector.selector;
5186			this.context = selector.context;
5187		}
5188
5189		return jQuery.makeArray( selector, this );
5190	};
5191
5192// Give the init function the jQuery prototype for later instantiation
5193init.prototype = jQuery.fn;
5194
5195// Initialize central reference
5196rootjQuery = jQuery( document );
5197
5198
5199var rparentsprev = /^(?:parents|prev(?:Until|All))/,
5200
5201	// Methods guaranteed to produce a unique set when starting from a unique set
5202	guaranteedUnique = {
5203		children: true,
5204		contents: true,
5205		next: true,
5206		prev: true
5207	};
5208
5209jQuery.fn.extend( {
5210	has: function( target ) {
5211		var targets = jQuery( target, this ),
5212			l = targets.length;
5213
5214		return this.filter( function() {
5215			var i = 0;
5216			for ( ; i < l; i++ ) {
5217				if ( jQuery.contains( this, targets[ i ] ) ) {
5218					return true;
5219				}
5220			}
5221		} );
5222	},
5223
5224	closest: function( selectors, context ) {
5225		var cur,
5226			i = 0,
5227			l = this.length,
5228			matched = [],
5229			pos = rneedsContext.test( selectors ) || typeof selectors !== "string" ?
vendor: 5,466 bytes, lines 5230-5443
5230				jQuery( selectors, context || this.context ) :
5231				0;
5232
5233		for ( ; i < l; i++ ) {
5234			for ( cur = this[ i ]; cur && cur !== context; cur = cur.parentNode ) {
5235
5236				// Always skip document fragments
5237				if ( cur.nodeType < 11 && ( pos ?
5238					pos.index( cur ) > -1 :
5239
5240					// Don't pass non-elements to Sizzle
5241					cur.nodeType === 1 &&
5242						jQuery.find.matchesSelector( cur, selectors ) ) ) {
5243
5244					matched.push( cur );
5245					break;
5246				}
5247			}
5248		}
5249
5250		return this.pushStack( matched.length > 1 ? jQuery.uniqueSort( matched ) : matched );
5251	},
5252
5253	// Determine the position of an element within the set
5254	index: function( elem ) {
5255
5256		// No argument, return index in parent
5257		if ( !elem ) {
5258			return ( this[ 0 ] && this[ 0 ].parentNode ) ? this.first().prevAll().length : -1;
5259		}
5260
5261		// Index in selector
5262		if ( typeof elem === "string" ) {
5263			return indexOf.call( jQuery( elem ), this[ 0 ] );
5264		}
5265
5266		// Locate the position of the desired element
5267		return indexOf.call( this,
5268
5269			// If it receives a jQuery object, the first element is used
5270			elem.jquery ? elem[ 0 ] : elem
5271		);
5272	},
5273
5274	add: function( selector, context ) {
5275		return this.pushStack(
5276			jQuery.uniqueSort(
5277				jQuery.merge( this.get(), jQuery( selector, context ) )
5278			)
5279		);
5280	},
5281
5282	addBack: function( selector ) {
5283		return this.add( selector == null ?
5284			this.prevObject : this.prevObject.filter( selector )
5285		);
5286	}
5287} );
5288
5289function sibling( cur, dir ) {
5290	while ( ( cur = cur[ dir ] ) && cur.nodeType !== 1 ) {}
5291	return cur;
5292}
5293
5294jQuery.each( {
5295	parent: function( elem ) {
5296		var parent = elem.parentNode;
5297		return parent && parent.nodeType !== 11 ? parent : null;
5298	},
5299	parents: function( elem ) {
5300		return dir( elem, "parentNode" );
5301	},
5302	parentsUntil: function( elem, i, until ) {
5303		return dir( elem, "parentNode", until );
5304	},
5305	next: function( elem ) {
5306		return sibling( elem, "nextSibling" );
5307	},
5308	prev: function( elem ) {
5309		return sibling( elem, "previousSibling" );
5310	},
5311	nextAll: function( elem ) {
5312		return dir( elem, "nextSibling" );
5313	},
5314	prevAll: function( elem ) {
5315		return dir( elem, "previousSibling" );
5316	},
5317	nextUntil: function( elem, i, until ) {
5318		return dir( elem, "nextSibling", until );
5319	},
5320	prevUntil: function( elem, i, until ) {
5321		return dir( elem, "previousSibling", until );
5322	},
5323	siblings: function( elem ) {
5324		return siblings( ( elem.parentNode || {} ).firstChild, elem );
5325	},
5326	children: function( elem ) {
5327		return siblings( elem.firstChild );
5328	},
5329	contents: function( elem ) {
5330		return elem.contentDocument || jQuery.merge( [], elem.childNodes );
5331	}
5332}, function( name, fn ) {
5333	jQuery.fn[ name ] = function( until, selector ) {
5334		var matched = jQuery.map( this, fn, until );
5335
5336		if ( name.slice( -5 ) !== "Until" ) {
5337			selector = until;
5338		}
5339
5340		if ( selector && typeof selector === "string" ) {
5341			matched = jQuery.filter( selector, matched );
5342		}
5343
5344		if ( this.length > 1 ) {
5345
5346			// Remove duplicates
5347			if ( !guaranteedUnique[ name ] ) {
5348				jQuery.uniqueSort( matched );
5349			}
5350
5351			// Reverse order for parents* and prev-derivatives
5352			if ( rparentsprev.test( name ) ) {
5353				matched.reverse();
5354			}
5355		}
5356
5357		return this.pushStack( matched );
5358	};
5359} );
5360var rnotwhite = ( /\S+/g );
5361
5362
5363
5364// Convert String-formatted options into Object-formatted ones
5365function createOptions( options ) {
5366	var object = {};
5367	jQuery.each( options.match( rnotwhite ) || [], function( _, flag ) {
5368		object[ flag ] = true;
5369	} );
5370	return object;
5371}
5372
5373/*
5374 * Create a callback list using the following parameters:
5375 *
5376 *	options: an optional list of space-separated options that will change how
5377 *			the callback list behaves or a more traditional option object
5378 *
5379 * By default a callback list will act like an event callback list and can be
5380 * "fired" multiple times.
5381 *
5382 * Possible options:
5383 *
5384 *	once:			will ensure the callback list can only be fired once (like a Deferred)
5385 *
5386 *	memory:			will keep track of previous values and will call any callback added
5387 *					after the list has been fired right away with the latest "memorized"
5388 *					values (like a Deferred)
5389 *
5390 *	unique:			will ensure a callback can only be added once (no duplicate in the list)
5391 *
5392 *	stopOnFalse:	interrupt callings when a callback returns false
5393 *
5394 */
5395jQuery.Callbacks = function( options ) {
5396
5397	// Convert options from String-formatted to Object-formatted if needed
5398	// (we check in cache first)
5399	options = typeof options === "string" ?
5400		createOptions( options ) :
5401		jQuery.extend( {}, options );
5402
5403	var // Flag to know if list is currently firing
5404		firing,
5405
5406		// Last fire value for non-forgettable lists
5407		memory,
5408
5409		// Flag to know if list was already fired
5410		fired,
5411
5412		// Flag to prevent firing
5413		locked,
5414
5415		// Actual callback list
5416		list = [],
5417
5418		// Queue of execution data for repeatable lists
5419		queue = [],
5420
5421		// Index of currently firing callback (modified by add/remove as needed)
5422		firingIndex = -1,
5423
5424		// Fire callbacks
5425		fire = function() {
5426
5427			// Enforce single-firing
5428			locked = options.once;
5429
5430			// Execute callbacks for all pending executions,
5431			// respecting firingIndex overrides and runtime changes
5432			fired = firing = true;
5433			for ( ; queue.length; firingIndex = -1 ) {
5434				memory = queue.shift();
5435				while ( ++firingIndex < list.length ) {
5436
5437					// Run callback and check for early termination
5438					if ( list[ firingIndex ].apply( memory[ 0 ], memory[ 1 ] ) === false &&
5439						options.stopOnFalse ) {
5440
5441						// Jump to end and forget the data so .add doesn't re-fire
5442						firingIndex = list.length;
5443						memory = false;
5444					}
5445				}
5446			}
5447
5448			// Forget the data if we're done with it
5449			if ( !options.memory ) {
5450				memory = false;
5451			}
5452
5453			firing = false;
5454
5455			// Clean up if we're done firing for good
5456			if ( locked ) {
5457
5458				// Keep an empty list if we have data for future add calls
5459				if ( memory ) {
5460					list = [];
5461
5462				// Otherwise, this object is spent
5463				} else {
5464					list = "";
5465				}
5466			}
5467		},
5468
5469		// Actual Callbacks object
5470		self = {
5471
5472			// Add a callback or a collection of callbacks to the list
5473			add: function() {
5474				if ( list ) {
5475
5476					// If we have memory from a past run, we should fire after adding
5477					if ( memory && !firing ) {
5478						firingIndex = list.length - 1;
5479						queue.push( memory );
5480					}
5481
5482					( function add( args ) {
5483						jQuery.each( args, function( _, arg ) {
5484							if ( jQuery.isFunction( arg ) ) {
5485								if ( !options.unique || !self.has( arg ) ) {
5486									list.push( arg );
5487								}
5488							} else if ( arg && arg.length && jQuery.type( arg ) !== "string" ) {
5489
5490								// Inspect recursively
5491								add( arg );
5492							}
5493						} );
5494					} )( arguments );
5495
5496					if ( memory && !firing ) {
5497						fire();
5498					}
5499				}
5500				return this;
5501			},
5502
5503			// Remove a callback from the list
5504			remove: function() {
5505				jQuery.each( arguments, function( _, arg ) {
5506					var index;
5507					while ( ( index = jQuery.inArray( arg, list, index ) ) > -1 ) {
5508						list.splice( index, 1 );
5509
5510						// Handle firing indexes
5511						if ( index <= firingIndex ) {
5512							firingIndex--;
5513						}
5514					}
5515				} );
5516				return this;
5517			},
5518
5519			// Check if a given callback is in the list.
5520			// If no argument is given, return whether or not list has callbacks attached.
5521			has: function( fn ) {
5522				return fn ?
5523					jQuery.inArray( fn, list ) > -1 :
5524					list.length > 0;
5525			},
5526
5527			// Remove all callbacks from the list
5528			empty: function() {
5529				if ( list ) {
5530					list = [];
5531				}
5532				return this;
5533			},
5534
5535			// Disable .fire and .add
5536			// Abort any current/pending executions
5537			// Clear all callbacks and values
5538			disable: function() {
5539				locked = queue = [];
5540				list = memory = "";
5541				return this;
5542			},
5543			disabled: function() {
5544				return !list;
5545			},
5546
5547			// Disable .fire
5548			// Also disable .add unless we have memory (since it would have no effect)
5549			// Abort any pending executions
5550			lock: function() {
5551				locked = queue = [];
5552				if ( !memory ) {
5553					list = memory = "";
5554				}
5555				return this;
5556			},
5557			locked: function() {
5558				return !!locked;
5559			},
5560
5561			// Call all callbacks with the given context and arguments
5562			fireWith: function( context, args ) {
5563				if ( !locked ) {
5564					args = args || [];
5565					args = [ context, args.slice ? args.slice() : args ];
5566					queue.push( args );
5567					if ( !firing ) {
5568						fire();
5569					}
5570				}
5571				return this;
5572			},
5573
5574			// Call all the callbacks with the given arguments
5575			fire: function() {
5576				self.fireWith( this, arguments );
5577				return this;
5578			},
5579
5580			// To know if the callbacks have already been called at least once
5581			fired: function() {
5582				return !!fired;
5583			}
5584		};
5585
5586	return self;
5587};
5588
5589
5590jQuery.extend( {
5591
5592	Deferred: function( func ) {
5593		var tuples = [
5594
5595				// action, add listener, listener list, final state
5596				[ "resolve", "done", jQuery.Callbacks( "once memory" ), "resolved" ],
5597				[ "reject", "fail", jQuery.Callbacks( "once memory" ), "rejected" ],
5598				[ "notify", "progress", jQuery.Callbacks( "memory" ) ]
5599			],
5600			state = "pending",
5601			promise = {
5602				state: function() {
5603					return state;
5604				},
5605				always: function() {
5606					deferred.done( arguments ).fail( arguments );
5607					return this;
5608				},
5609				then: function( /* fnDone, fnFail, fnProgress */ ) {
5610					var fns = arguments;
5611					return jQuery.Deferred( function( newDefer ) {
5612						jQuery.each( tuples, function( i, tuple ) {
5613							var fn = jQuery.isFunction( fns[ i ] ) && fns[ i ];
5614
5615							// deferred[ done | fail | progress ] for forwarding actions to newDefer
5616							deferred[ tuple[ 1 ] ]( function() {
5617								var returned = fn && fn.apply( this, arguments );
5618								if ( returned && jQuery.isFunction( returned.promise ) ) {
5619									returned.promise()
5620										.progress( newDefer.notify )
5621										.done( newDefer.resolve )
5622										.fail( newDefer.reject );
5623								} else {
5624									newDefer[ tuple[ 0 ] + "With" ](
5625										this === promise ? newDefer.promise() : this,
5626										fn ? [ returned ] : arguments
5627									);
5628								}
5629							} );
5630						} );
5631						fns = null;
5632					} ).promise();
5633				},
5634
5635				// Get a promise for this deferred
5636				// If obj is provided, the promise aspect is added to the object
5637				promise: function( obj ) {
5638					return obj != null ? jQuery.extend( obj, promise ) : promise;
5639				}
5640			},
5641			deferred = {};
5642
5643		// Keep pipe for back-compat
5644		promise.pipe = promise.then;
5645
5646		// Add list-specific methods
5647		jQuery.each( tuples, function( i, tuple ) {
5648			var list = tuple[ 2 ],
5649				stateString = tuple[ 3 ];
5650
5651			// promise[ done | fail | progress ] = list.add
5652			promise[ tuple[ 1 ] ] = list.add;
5653
5654			// Handle state
5655			if ( stateString ) {
5656				list.add( function() {
5657
5658					// state = [ resolved | rejected ]
5659					state = stateString;
5660
5661				// [ reject_list | resolve_list ].disable; progress_list.lock
5662				}, tuples[ i ^ 1 ][ 2 ].disable, tuples[ 2 ][ 2 ].lock );
5663			}
5664
5665			// deferred[ resolve | reject | notify ]
5666			deferred[ tuple[ 0 ] ] = function() {
5667				deferred[ tuple[ 0 ] + "With" ]( this === deferred ? promise : this, arguments );
5668				return this;
5669			};
5670			deferred[ tuple[ 0 ] + "With" ] = list.fireWith;
5671		} );
5672
5673		// Make the deferred a promise
5674		promise.promise( deferred );
5675
5676		// Call given func if any
5677		if ( func ) {
5678			func.call( deferred, deferred );
5679		}
5680
5681		// All done!
5682		return deferred;
5683	},
5684
5685	// Deferred helper
5686	when: function( subordinate /* , ..., subordinateN */ ) {
5687		var i = 0,
5688			resolveValues = slice.call( arguments ),
5689			length = resolveValues.length,
5690
5691			// the count of uncompleted subordinates
5692			remaining = length !== 1 ||
5693				( subordinate && jQuery.isFunction( subordinate.promise ) ) ? length : 0,
5694
5695			// the master Deferred.
5696			// If resolveValues consist of only a single Deferred, just use that.
5697			deferred = remaining === 1 ? subordinate : jQuery.Deferred(),
5698
5699			// Update function for both resolve and progress values
5700			updateFunc = function( i, contexts, values ) {
5701				return function( value ) {
5702					contexts[ i ] = this;
5703					values[ i ] = arguments.length > 1 ? slice.call( arguments ) : value;
5704					if ( values === progressValues ) {
5705						deferred.notifyWith( contexts, values );
5706					} else if ( !( --remaining ) ) {
5707						deferred.resolveWith( contexts, values );
5708					}
5709				};
5710			},
5711
5712			progressValues, progressContexts, resolveContexts;
5713
5714		// Add listeners to Deferred subordinates; treat others as resolved
5715		if ( length > 1 ) {
5716			progressValues = new Array( length );
5717			progressContexts = new Array( length );
5718			resolveContexts = new Array( length );
5719			for ( ; i < length; i++ ) {
5720				if ( resolveValues[ i ] && jQuery.isFunction( resolveValues[ i ].promise ) ) {
5721					resolveValues[ i ].promise()
5722						.progress( updateFunc( i, progressContexts, progressValues ) )
5723						.done( updateFunc( i, resolveContexts, resolveValues ) )
5724						.fail( deferred.reject );
5725				} else {
5726					--remaining;
5727				}
5728			}
5729		}
5730
5731		// If we're not waiting on anything, resolve the master
5732		if ( !remaining ) {
5733			deferred.resolveWith( resolveContexts, resolveValues );
5734		}
5735
5736		return deferred.promise();
5737	}
5738} );
5739
5740
5741// The deferred used on DOM ready
5742var readyList;
5743
5744jQuery.fn.ready = function( fn ) {
5745
5746	// Add the callback
5747	jQuery.ready.promise().done( fn );
5748
5749	return this;
5750};
5751
5752jQuery.extend( {
5753
5754	// Is the DOM ready to be used? Set to true once it occurs.
5755	isReady: false,
5756
5757	// A counter to track how many items to wait for before
5758	// the ready event fires. See #6781
5759	readyWait: 1,
5760
5761	// Hold (or release) the ready event
5762	holdReady: function( hold ) {
5763		if ( hold ) {
5764			jQuery.readyWait++;
5765		} else {
5766			jQuery.ready( true );
5767		}
5768	},
5769
5770	// Handle when the DOM is ready
5771	ready: function( wait ) {
5772
5773		// Abort if there are pending holds or we're already ready
5774		if ( wait === true ? --jQuery.readyWait : jQuery.isReady ) {
5775			return;
5776		}
5777
5778		// Remember that the DOM is ready
5779		jQuery.isReady = true;
5780
5781		// If a normal DOM Ready event fired, decrement, and wait if need be
5782		if ( wait !== true && --jQuery.readyWait > 0 ) {
5783			return;
5784		}
5785
5786		// If there are functions bound, to execute
5787		readyList.resolveWith( document, [ jQuery ] );
5788
5789		// Trigger any bound ready events
5790		if ( jQuery.fn.triggerHandler ) {
5791			jQuery( document ).triggerHandler( "ready" );
5792			jQuery( document ).off( "ready" );
5793		}
5794	}
5795} );
5796
5797/**
5798 * The ready event handler and self cleanup method
5799 */
5800function completed() {
5801	document.removeEventListener( "DOMContentLoaded", completed );
5802	window.removeEventListener( "load", completed );
5803	jQuery.ready();
5804}
5805
5806jQuery.ready.promise = function( obj ) {
5807	if ( !readyList ) {
5808
5809		readyList = jQuery.Deferred();
5810
5811		// Catch cases where $(document).ready() is called
5812		// after the browser event has already occurred.
5813		// Support: IE9-10 only
5814		// Older IE sometimes signals "interactive" too soon
5815		if ( document.readyState === "complete" ||
5816			( document.readyState !== "loading" && !document.documentElement.doScroll ) ) {
5817
5818			// Handle it asynchronously to allow scripts the opportunity to delay ready
5819			window.setTimeout( jQuery.ready );
5820
5821		} else {
5822
5823			// Use the handy event callback
5824			document.addEventListener( "DOMContentLoaded", completed );
5825
5826			// A fallback to window.onload, that will always work
5827			window.addEventListener( "load", completed );
5828		}
5829	}
5830	return readyList.promise( obj );
5831};
5832
5833// Kick off the DOM ready check even if the user does not
5834jQuery.ready.promise();
5835
5836
5837
5838
5839// Multifunctional method to get and set values of a collection
5840// The value/s can optionally be executed if it's a function
5841var access = function( elems, fn, key, value, chainable, emptyGet, raw ) {
5842	var i = 0,
5843		len = elems.length,
5844		bulk = key == null;
5845
5846	// Sets many values
5847	if ( jQuery.type( key ) === "object" ) {
5848		chainable = true;
5849		for ( i in key ) {
5850			access( elems, fn, i, key[ i ], true, emptyGet, raw );
5851		}
5852
5853	// Sets one value
5854	} else if ( value !== undefined ) {
5855		chainable = true;
5856
5857		if ( !jQuery.isFunction( value ) ) {
5858			raw = true;
5859		}
5860
5861		if ( bulk ) {
5862
5863			// Bulk operations run against the entire set
5864			if ( raw ) {
5865				fn.call( elems, value );
5866				fn = null;
5867
5868			// ...except when executing function values
5869			} else {
5870				bulk = fn;
5871				fn = function( elem, key, value ) {
5872					return bulk.call( jQuery( elem ), value );
5873				};
5874			}
5875		}
5876
5877		if ( fn ) {
5878			for ( ; i < len; i++ ) {
5879				fn(
5880					elems[ i ], key, raw ?
5881					value :
5882					value.call( elems[ i ], i, fn( elems[ i ], key ) )
5883				);
5884			}
5885		}
5886	}
5887
5888	return chainable ?
5889		elems :
5890
5891		// Gets
5892		bulk ?
5893			fn.call( elems ) :
5894			len ? fn( elems[ 0 ], key ) : emptyGet;
5895};
5896var acceptData = function( owner ) {
5897
5898	// Accepts only:
5899	//  - Node
5900	//    - Node.ELEMENT_NODE
5901	//    - Node.DOCUMENT_NODE
5902	//  - Object
5903	//    - Any
5904	/* jshint -W018 */
5905	return owner.nodeType === 1 || owner.nodeType === 9 || !( +owner.nodeType );
5906};
5907
5908
5909
5910
5911function Data() {
5912	this.expando = jQuery.expando + Data.uid++;
5913}
5914
5915Data.uid = 1;
5916
5917Data.prototype = {
5918
5919	register: function( owner, initial ) {
5920		var value = initial || {};
5921
5922		// If it is a node unlikely to be stringify-ed or looped over
5923		// use plain assignment
5924		if ( owner.nodeType ) {
5925			owner[ this.expando ] = value;
5926
5927		// Otherwise secure it in a non-enumerable, non-writable property
5928		// configurability must be true to allow the property to be
5929		// deleted with the delete operator
5930		} else {
5931			Object.defineProperty( owner, this.expando, {
5932				value: value,
5933				writable: true,
5934				configurable: true
5935			} );
5936		}
5937		return owner[ this.expando ];
5938	},
5939	cache: function( owner ) {
5940
5941		// We can accept data for non-element nodes in modern browsers,
5942		// but we should not, see #8335.
5943		// Always return an empty object.
5944		if ( !acceptData( owner ) ) {
5945			return {};
5946		}
5947
5948		// Check if the owner object already has a cache
5949		var value = owner[ this.expando ];
5950
5951		// If not, create one
5952		if ( !value ) {
5953			value = {};
5954
5955			// We can accept data for non-element nodes in modern browsers,
5956			// but we should not, see #8335.
5957			// Always return an empty object.
5958			if ( acceptData( owner ) ) {
5959
5960				// If it is a node unlikely to be stringify-ed or looped over
5961				// use plain assignment
5962				if ( owner.nodeType ) {
5963					owner[ this.expando ] = value;
5964
5965				// Otherwise secure it in a non-enumerable property
5966				// configurable must be true to allow the property to be
5967				// deleted when data is removed
5968				} else {
5969					Object.defineProperty( owner, this.expando, {
5970						value: value,
5971						configurable: true
5972					} );
5973				}
5974			}
5975		}
5976
5977		return value;
5978	},
5979	set: function( owner, data, value ) {
5980		var prop,
5981			cache = this.cache( owner );
5982
5983		// Handle: [ owner, key, value ] args
5984		if ( typeof data === "string" ) {
5985			cache[ data ] = value;
5986
5987		// Handle: [ owner, { properties } ] args
5988		} else {
5989
5990			// Copy the properties one-by-one to the cache object
5991			for ( prop in data ) {
5992				cache[ prop ] = data[ prop ];
5993			}
5994		}
5995		return cache;
5996	},
5997	get: function( owner, key ) {
5998		return key === undefined ?
5999			this.cache( owner ) :
6000			owner[ this.expando ] && owner[ this.expando ][ key ];
6001	},
6002	access: function( owner, key, value ) {
6003		var stored;
6004
6005		// In cases where either:
6006		//
6007		//   1. No key was specified
6008		//   2. A string key was specified, but no value provided
6009		//
6010		// Take the "read" path and allow the get method to determine
6011		// which value to return, respectively either:
6012		//
6013		//   1. The entire cache object
6014		//   2. The data stored at the key
6015		//
6016		if ( key === undefined ||
6017				( ( key && typeof key === "string" ) && value === undefined ) ) {
6018
6019			stored = this.get( owner, key );
6020
6021			return stored !== undefined ?
6022				stored : this.get( owner, jQuery.camelCase( key ) );
6023		}
6024
6025		// When the key is not a string, or both a key and value
6026		// are specified, set or extend (existing objects) with either:
6027		//
6028		//   1. An object of properties
6029		//   2. A key and value
6030		//
6031		this.set( owner, key, value );
6032
6033		// Since the "set" path can have two possible entry points
6034		// return the expected data based on which path was taken[*]
6035		return value !== undefined ? value : key;
6036	},
6037	remove: function( owner, key ) {
6038		var i, name, camel,
6039			cache = owner[ this.expando ];
6040
6041		if ( cache === undefined ) {
6042			return;
6043		}
6044
6045		if ( key === undefined ) {
6046			this.register( owner );
6047
6048		} else {
6049
6050			// Support array or space separated string of keys
6051			if ( jQuery.isArray( key ) ) {
6052
6053				// If "name" is an array of keys...
6054				// When data is initially created, via ("key", "val") signature,
6055				// keys will be converted to camelCase.
6056				// Since there is no way to tell _how_ a key was added, remove
6057				// both plain key and camelCase key. #12786
6058				// This will only penalize the array argument path.
6059				name = key.concat( key.map( jQuery.camelCase ) );
6060			} else {
6061				camel = jQuery.camelCase( key );
6062
6063				// Try the string as a key before any manipulation
6064				if ( key in cache ) {
6065					name = [ key, camel ];
6066				} else {
6067
6068					// If a key with the spaces exists, use it.
6069					// Otherwise, create an array by matching non-whitespace
6070					name = camel;
6071					name = name in cache ?
6072						[ name ] : ( name.match( rnotwhite ) || [] );
6073				}
6074			}
6075
6076			i = name.length;
6077
6078			while ( i-- ) {
6079				delete cache[ name[ i ] ];
6080			}
6081		}
6082
6083		// Remove the expando if there's no more data
6084		if ( key === undefined || jQuery.isEmptyObject( cache ) ) {
6085
6086			// Support: Chrome <= 35-45+
6087			// Webkit & Blink performance suffers when deleting properties
6088			// from DOM nodes, so set to undefined instead
6089			// https://code.google.com/p/chromium/issues/detail?id=378607
6090			if ( owner.nodeType ) {
6091				owner[ this.expando ] = undefined;
6092			} else {
6093				delete owner[ this.expando ];
6094			}
6095		}
6096	},
6097	hasData: function( owner ) {
6098		var cache = owner[ this.expando ];
6099		return cache !== undefined && !jQuery.isEmptyObject( cache );
6100	}
6101};
6102var dataPriv = new Data();
6103
6104var dataUser = new Data();
6105
6106
6107
6108//	Implementation Summary
6109//
6110//	1. Enforce API surface and semantic compatibility with 1.9.x branch
6111//	2. Improve the module's maintainability by reducing the storage
6112//		paths to a single mechanism.
6113//	3. Use the same single mechanism to support "private" and "user" data.
6114//	4. _Never_ expose "private" data to user code (TODO: Drop _data, _removeData)
6115//	5. Avoid exposing implementation details on user objects (eg. expando properties)
6116//	6. Provide a clear path for implementation upgrade to WeakMap in 2014
6117
6118var rbrace = /^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,
6119	rmultiDash = /[A-Z]/g;
6120
6121function dataAttr( elem, key, data ) {
6122	var name;
6123
6124	// If nothing was found internally, try to fetch any
6125	// data from the HTML5 data-* attribute
6126	if ( data === undefined && elem.nodeType === 1 ) {
6127		name = "data-" + key.replace( rmultiDash, "-$&" ).toLowerCase();
6128		data = elem.getAttribute( name );
6129
6130		if ( typeof data === "string" ) {
6131			try {
6132				data = data === "true" ? true :
6133					data === "false" ? false :
6134					data === "null" ? null :
6135
6136					// Only convert to a number if it doesn't change the string
6137					+data + "" === data ? +data :
6138					rbrace.test( data ) ? jQuery.parseJSON( data ) :
6139					data;
6140			} catch ( e ) {}
6141
6142			// Make sure we set the data so it isn't changed later
6143			dataUser.set( elem, key, data );
6144		} else {
6145			data = undefined;
6146		}
6147	}
6148	return data;
6149}
6150
6151jQuery.extend( {
6152	hasData: function( elem ) {
6153		return dataUser.hasData( elem ) || dataPriv.hasData( elem );
6154	},
6155
6156	data: function( elem, name, data ) {
6157		return dataUser.access( elem, name, data );
6158	},
6159
6160	removeData: function( elem, name ) {
6161		dataUser.remove( elem, name );
6162	},
6163
6164	// TODO: Now that all calls to _data and _removeData have been replaced
6165	// with direct calls to dataPriv methods, these can be deprecated.
6166	_data: function( elem, name, data ) {
6167		return dataPriv.access( elem, name, data );
6168	},
6169
6170	_removeData: function( elem, name ) {
6171		dataPriv.remove( elem, name );
6172	}
6173} );
6174
6175jQuery.fn.extend( {
6176	data: function( key, value ) {
6177		var i, name, data,
6178			elem = this[ 0 ],
6179			attrs = elem && elem.attributes;
6180
6181		// Gets all values
6182		if ( key === undefined ) {
6183			if ( this.length ) {
6184				data = dataUser.get( elem );
6185
6186				if ( elem.nodeType === 1 && !dataPriv.get( elem, "hasDataAttrs" ) ) {
6187					i = attrs.length;
6188					while ( i-- ) {
6189
6190						// Support: IE11+
6191						// The attrs elements can be null (#14894)
6192						if ( attrs[ i ] ) {
6193							name = attrs[ i ].name;
6194							if ( name.indexOf( "data-" ) === 0 ) {
6195								name = jQuery.camelCase( name.slice( 5 ) );
6196								dataAttr( elem, name, data[ name ] );
6197							}
6198						}
6199					}
6200					dataPriv.set( elem, "hasDataAttrs", true );
6201				}
6202			}
6203
6204			return data;
6205		}
6206
6207		// Sets multiple values
6208		if ( typeof key === "object" ) {
6209			return this.each( function() {
6210				dataUser.set( this, key );
6211			} );
6212		}
6213
6214		return access( this, function( value ) {
6215			var data, camelKey;
6216
6217			// The calling jQuery object (element matches) is not empty
6218			// (and therefore has an element appears at this[ 0 ]) and the
6219			// `value` parameter was not undefined. An empty jQuery object
6220			// will result in `undefined` for elem = this[ 0 ] which will
6221			// throw an exception if an attempt to read a data cache is made.
6222			if ( elem && value === undefined ) {
6223
6224				// Attempt to get data from the cache
6225				// with the key as-is
6226				data = dataUser.get( elem, key ) ||
6227
6228					// Try to find dashed key if it exists (gh-2779)
6229					// This is for 2.2.x only
6230					dataUser.get( elem, key.replace( rmultiDash, "-$&" ).toLowerCase() );
6231
6232				if ( data !== undefined ) {
6233					return data;
6234				}
6235
6236				camelKey = jQuery.camelCase( key );
6237
6238				// Attempt to get data from the cache
6239				// with the key camelized
6240				data = dataUser.get( elem, camelKey );
6241				if ( data !== undefined ) {
6242					return data;
6243				}
6244
6245				// Attempt to "discover" the data in
6246				// HTML5 custom data-* attrs
6247				data = dataAttr( elem, camelKey, undefined );
6248				if ( data !== undefined ) {
6249					return data;
6250				}
6251
6252				// We tried really hard, but the data doesn't exist.
6253				return;
6254			}
6255
6256			// Set the data...
6257			camelKey = jQuery.camelCase( key );
6258			this.each( function() {
6259
6260				// First, attempt to store a copy or reference of any
6261				// data that might've been store with a camelCased key.
6262				var data = dataUser.get( this, camelKey );
6263
6264				// For HTML5 data-* attribute interop, we have to
6265				// store property names with dashes in a camelCase form.
6266				// This might not apply to all properties...*
6267				dataUser.set( this, camelKey, value );
6268
6269				// *... In the case of properties that might _actually_
6270				// have dashes, we need to also store a copy of that
6271				// unchanged property.
6272				if ( key.indexOf( "-" ) > -1 && data !== undefined ) {
6273					dataUser.set( this, key, value );
6274				}
6275			} );
6276		}, null, value, arguments.length > 1, null, true );
6277	},
6278
6279	removeData: function( key ) {
6280		return this.each( function() {
6281			dataUser.remove( this, key );
6282		} );
6283	}
6284} );
6285
6286
6287jQuery.extend( {
6288	queue: function( elem, type, data ) {
6289		var queue;
6290
6291		if ( elem ) {
6292			type = ( type || "fx" ) + "queue";
6293			queue = dataPriv.get( elem, type );
6294
6295			// Speed up dequeue by getting out quickly if this is just a lookup
6296			if ( data ) {
6297				if ( !queue || jQuery.isArray( data ) ) {
6298					queue = dataPriv.access( elem, type, jQuery.makeArray( data ) );
6299				} else {
6300					queue.push( data );
6301				}
6302			}
6303			return queue || [];
6304		}
6305	},
6306
6307	dequeue: function( elem, type ) {
6308		type = type || "fx";
6309
6310		var queue = jQuery.queue( elem, type ),
6311			startLength = queue.length,
6312			fn = queue.shift(),
6313			hooks = jQuery._queueHooks( elem, type ),
6314			next = function() {
6315				jQuery.dequeue( elem, type );
6316			};
6317
6318		// If the fx queue is dequeued, always remove the progress sentinel
6319		if ( fn === "inprogress" ) {
6320			fn = queue.shift();
6321			startLength--;
6322		}
6323
6324		if ( fn ) {
6325
6326			// Add a progress sentinel to prevent the fx queue from being
6327			// automatically dequeued
6328			if ( type === "fx" ) {
6329				queue.unshift( "inprogress" );
6330			}
6331
6332			// Clear up the last queue stop function
6333			delete hooks.stop;
6334			fn.call( elem, next, hooks );
6335		}
6336
6337		if ( !startLength && hooks ) {
6338			hooks.empty.fire();
6339		}
6340	},
6341
6342	// Not public - generate a queueHooks object, or return the current one
6343	_queueHooks: function( elem, type ) {
6344		var key = type + "queueHooks";
6345		return dataPriv.get( elem, key ) || dataPriv.access( elem, key, {
6346			empty: jQuery.Callbacks( "once memory" ).add( function() {
vendor: 17,961 bytes, lines 6347-7018
6347				dataPriv.remove( elem, [ type + "queue", key ] );
6348			} )
6349		} );
6350	}
6351} );
6352
6353jQuery.fn.extend( {
6354	queue: function( type, data ) {
6355		var setter = 2;
6356
6357		if ( typeof type !== "string" ) {
6358			data = type;
6359			type = "fx";
6360			setter--;
6361		}
6362
6363		if ( arguments.length < setter ) {
6364			return jQuery.queue( this[ 0 ], type );
6365		}
6366
6367		return data === undefined ?
6368			this :
6369			this.each( function() {
6370				var queue = jQuery.queue( this, type, data );
6371
6372				// Ensure a hooks for this queue
6373				jQuery._queueHooks( this, type );
6374
6375				if ( type === "fx" && queue[ 0 ] !== "inprogress" ) {
6376					jQuery.dequeue( this, type );
6377				}
6378			} );
6379	},
6380	dequeue: function( type ) {
6381		return this.each( function() {
6382			jQuery.dequeue( this, type );
6383		} );
6384	},
6385	clearQueue: function( type ) {
6386		return this.queue( type || "fx", [] );
6387	},
6388
6389	// Get a promise resolved when queues of a certain type
6390	// are emptied (fx is the type by default)
6391	promise: function( type, obj ) {
6392		var tmp,
6393			count = 1,
6394			defer = jQuery.Deferred(),
6395			elements = this,
6396			i = this.length,
6397			resolve = function() {
6398				if ( !( --count ) ) {
6399					defer.resolveWith( elements, [ elements ] );
6400				}
6401			};
6402
6403		if ( typeof type !== "string" ) {
6404			obj = type;
6405			type = undefined;
6406		}
6407		type = type || "fx";
6408
6409		while ( i-- ) {
6410			tmp = dataPriv.get( elements[ i ], type + "queueHooks" );
6411			if ( tmp && tmp.empty ) {
6412				count++;
6413				tmp.empty.add( resolve );
6414			}
6415		}
6416		resolve();
6417		return defer.promise( obj );
6418	}
6419} );
6420var pnum = ( /[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/ ).source;
6421
6422var rcssNum = new RegExp( "^(?:([+-])=|)(" + pnum + ")([a-z%]*)$", "i" );
6423
6424
6425var cssExpand = [ "Top", "Right", "Bottom", "Left" ];
6426
6427var isHidden = function( elem, el ) {
6428
6429		// isHidden might be called from jQuery#filter function;
6430		// in that case, element will be second argument
6431		elem = el || elem;
6432		return jQuery.css( elem, "display" ) === "none" ||
6433			!jQuery.contains( elem.ownerDocument, elem );
6434	};
6435
6436
6437
6438function adjustCSS( elem, prop, valueParts, tween ) {
6439	var adjusted,
6440		scale = 1,
6441		maxIterations = 20,
6442		currentValue = tween ?
6443			function() { return tween.cur(); } :
6444			function() { return jQuery.css( elem, prop, "" ); },
6445		initial = currentValue(),
6446		unit = valueParts && valueParts[ 3 ] || ( jQuery.cssNumber[ prop ] ? "" : "px" ),
6447
6448		// Starting value computation is required for potential unit mismatches
6449		initialInUnit = ( jQuery.cssNumber[ prop ] || unit !== "px" && +initial ) &&
6450			rcssNum.exec( jQuery.css( elem, prop ) );
6451
6452	if ( initialInUnit && initialInUnit[ 3 ] !== unit ) {
6453
6454		// Trust units reported by jQuery.css
6455		unit = unit || initialInUnit[ 3 ];
6456
6457		// Make sure we update the tween properties later on
6458		valueParts = valueParts || [];
6459
6460		// Iteratively approximate from a nonzero starting point
6461		initialInUnit = +initial || 1;
6462
6463		do {
6464
6465			// If previous iteration zeroed out, double until we get *something*.
6466			// Use string for doubling so we don't accidentally see scale as unchanged below
6467			scale = scale || ".5";
6468
6469			// Adjust and apply
6470			initialInUnit = initialInUnit / scale;
6471			jQuery.style( elem, prop, initialInUnit + unit );
6472
6473		// Update scale, tolerating zero or NaN from tween.cur()
6474		// Break the loop if scale is unchanged or perfect, or if we've just had enough.
6475		} while (
6476			scale !== ( scale = currentValue() / initial ) && scale !== 1 && --maxIterations
6477		);
6478	}
6479
6480	if ( valueParts ) {
6481		initialInUnit = +initialInUnit || +initial || 0;
6482
6483		// Apply relative offset (+=/-=) if specified
6484		adjusted = valueParts[ 1 ] ?
6485			initialInUnit + ( valueParts[ 1 ] + 1 ) * valueParts[ 2 ] :
6486			+valueParts[ 2 ];
6487		if ( tween ) {
6488			tween.unit = unit;
6489			tween.start = initialInUnit;
6490			tween.end = adjusted;
6491		}
6492	}
6493	return adjusted;
6494}
6495var rcheckableType = ( /^(?:checkbox|radio)$/i );
6496
6497var rtagName = ( /<([\w:-]+)/ );
6498
6499var rscriptType = ( /^$|\/(?:java|ecma)script/i );
6500
6501
6502
6503// We have to close these tags to support XHTML (#13200)
6504var wrapMap = {
6505
6506	// Support: IE9
6507	option: [ 1, "<select multiple='multiple'>", "</select>" ],
6508
6509	// XHTML parsers do not magically insert elements in the
6510	// same way that tag soup parsers do. So we cannot shorten
6511	// this by omitting <tbody> or other required elements.
6512	thead: [ 1, "<table>", "</table>" ],
6513	col: [ 2, "<table><colgroup>", "</colgroup></table>" ],
6514	tr: [ 2, "<table><tbody>", "</tbody></table>" ],
6515	td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ],
6516
6517	_default: [ 0, "", "" ]
6518};
6519
6520// Support: IE9
6521wrapMap.optgroup = wrapMap.option;
6522
6523wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;
6524wrapMap.th = wrapMap.td;
6525
6526
6527function getAll( context, tag ) {
6528
6529	// Support: IE9-11+
6530	// Use typeof to avoid zero-argument method invocation on host objects (#15151)
6531	var ret = typeof context.getElementsByTagName !== "undefined" ?
6532			context.getElementsByTagName( tag || "*" ) :
6533			typeof context.querySelectorAll !== "undefined" ?
6534				context.querySelectorAll( tag || "*" ) :
6535			[];
6536
6537	return tag === undefined || tag && jQuery.nodeName( context, tag ) ?
6538		jQuery.merge( [ context ], ret ) :
6539		ret;
6540}
6541
6542
6543// Mark scripts as having already been evaluated
6544function setGlobalEval( elems, refElements ) {
6545	var i = 0,
6546		l = elems.length;
6547
6548	for ( ; i < l; i++ ) {
6549		dataPriv.set(
6550			elems[ i ],
6551			"globalEval",
6552			!refElements || dataPriv.get( refElements[ i ], "globalEval" )
6553		);
6554	}
6555}
6556
6557
6558var rhtml = /<|&#?\w+;/;
6559
6560function buildFragment( elems, context, scripts, selection, ignored ) {
6561	var elem, tmp, tag, wrap, contains, j,
6562		fragment = context.createDocumentFragment(),
6563		nodes = [],
6564		i = 0,
6565		l = elems.length;
6566
6567	for ( ; i < l; i++ ) {
6568		elem = elems[ i ];
6569
6570		if ( elem || elem === 0 ) {
6571
6572			// Add nodes directly
6573			if ( jQuery.type( elem ) === "object" ) {
6574
6575				// Support: Android<4.1, PhantomJS<2
6576				// push.apply(_, arraylike) throws on ancient WebKit
6577				jQuery.merge( nodes, elem.nodeType ? [ elem ] : elem );
6578
6579			// Convert non-html into a text node
6580			} else if ( !rhtml.test( elem ) ) {
6581				nodes.push( context.createTextNode( elem ) );
6582
6583			// Convert html into DOM nodes
6584			} else {
6585				tmp = tmp || fragment.appendChild( context.createElement( "div" ) );
6586
6587				// Deserialize a standard representation
6588				tag = ( rtagName.exec( elem ) || [ "", "" ] )[ 1 ].toLowerCase();
6589				wrap = wrapMap[ tag ] || wrapMap._default;
6590				tmp.innerHTML = wrap[ 1 ] + jQuery.htmlPrefilter( elem ) + wrap[ 2 ];
6591
6592				// Descend through wrappers to the right content
6593				j = wrap[ 0 ];
6594				while ( j-- ) {
6595					tmp = tmp.lastChild;
6596				}
6597
6598				// Support: Android<4.1, PhantomJS<2
6599				// push.apply(_, arraylike) throws on ancient WebKit
6600				jQuery.merge( nodes, tmp.childNodes );
6601
6602				// Remember the top-level container
6603				tmp = fragment.firstChild;
6604
6605				// Ensure the created nodes are orphaned (#12392)
6606				tmp.textContent = "";
6607			}
6608		}
6609	}
6610
6611	// Remove wrapper from fragment
6612	fragment.textContent = "";
6613
6614	i = 0;
6615	while ( ( elem = nodes[ i++ ] ) ) {
6616
6617		// Skip elements already in the context collection (trac-4087)
6618		if ( selection && jQuery.inArray( elem, selection ) > -1 ) {
6619			if ( ignored ) {
6620				ignored.push( elem );
6621			}
6622			continue;
6623		}
6624
6625		contains = jQuery.contains( elem.ownerDocument, elem );
6626
6627		// Append to fragment
6628		tmp = getAll( fragment.appendChild( elem ), "script" );
6629
6630		// Preserve script evaluation history
6631		if ( contains ) {
6632			setGlobalEval( tmp );
6633		}
6634
6635		// Capture executables
6636		if ( scripts ) {
6637			j = 0;
6638			while ( ( elem = tmp[ j++ ] ) ) {
6639				if ( rscriptType.test( elem.type || "" ) ) {
6640					scripts.push( elem );
6641				}
6642			}
6643		}
6644	}
6645
6646	return fragment;
6647}
6648
6649
6650( function() {
6651	var fragment = document.createDocumentFragment(),
6652		div = fragment.appendChild( document.createElement( "div" ) ),
6653		input = document.createElement( "input" );
6654
6655	// Support: Android 4.0-4.3, Safari<=5.1
6656	// Check state lost if the name is set (#11217)
6657	// Support: Windows Web Apps (WWA)
6658	// `name` and `type` must use .setAttribute for WWA (#14901)
6659	input.setAttribute( "type", "radio" );
6660	input.setAttribute( "checked", "checked" );
6661	input.setAttribute( "name", "t" );
6662
6663	div.appendChild( input );
6664
6665	// Support: Safari<=5.1, Android<4.2
6666	// Older WebKit doesn't clone checked state correctly in fragments
6667	support.checkClone = div.cloneNode( true ).cloneNode( true ).lastChild.checked;
6668
6669	// Support: IE<=11+
6670	// Make sure textarea (and checkbox) defaultValue is properly cloned
6671	div.innerHTML = "<textarea>x</textarea>";
6672	support.noCloneChecked = !!div.cloneNode( true ).lastChild.defaultValue;
6673} )();
6674
6675
6676var
6677	rkeyEvent = /^key/,
6678	rmouseEvent = /^(?:mouse|pointer|contextmenu|drag|drop)|click/,
6679	rtypenamespace = /^([^.]*)(?:\.(.+)|)/;
6680
6681function returnTrue() {
6682	return true;
6683}
6684
6685function returnFalse() {
6686	return false;
6687}
6688
6689// Support: IE9
6690// See #13393 for more info
6691function safeActiveElement() {
6692	try {
6693		return document.activeElement;
6694	} catch ( err ) { }
6695}
6696
6697function on( elem, types, selector, data, fn, one ) {
6698	var origFn, type;
6699
6700	// Types can be a map of types/handlers
6701	if ( typeof types === "object" ) {
6702
6703		// ( types-Object, selector, data )
6704		if ( typeof selector !== "string" ) {
6705
6706			// ( types-Object, data )
6707			data = data || selector;
6708			selector = undefined;
6709		}
6710		for ( type in types ) {
6711			on( elem, type, selector, data, types[ type ], one );
6712		}
6713		return elem;
6714	}
6715
6716	if ( data == null && fn == null ) {
6717
6718		// ( types, fn )
6719		fn = selector;
6720		data = selector = undefined;
6721	} else if ( fn == null ) {
6722		if ( typeof selector === "string" ) {
6723
6724			// ( types, selector, fn )
6725			fn = data;
6726			data = undefined;
6727		} else {
6728
6729			// ( types, data, fn )
6730			fn = data;
6731			data = selector;
6732			selector = undefined;
6733		}
6734	}
6735	if ( fn === false ) {
6736		fn = returnFalse;
6737	} else if ( !fn ) {
6738		return elem;
6739	}
6740
6741	if ( one === 1 ) {
6742		origFn = fn;
6743		fn = function( event ) {
6744
6745			// Can use an empty set, since event contains the info
6746			jQuery().off( event );
6747			return origFn.apply( this, arguments );
6748		};
6749
6750		// Use same guid so caller can remove using origFn
6751		fn.guid = origFn.guid || ( origFn.guid = jQuery.guid++ );
6752	}
6753	return elem.each( function() {
6754		jQuery.event.add( this, types, fn, data, selector );
6755	} );
6756}
6757
6758/*
6759 * Helper functions for managing events -- not part of the public interface.
6760 * Props to Dean Edwards' addEvent library for many of the ideas.
6761 */
6762jQuery.event = {
6763
6764	global: {},
6765
6766	add: function( elem, types, handler, data, selector ) {
6767
6768		var handleObjIn, eventHandle, tmp,
6769			events, t, handleObj,
6770			special, handlers, type, namespaces, origType,
6771			elemData = dataPriv.get( elem );
6772
6773		// Don't attach events to noData or text/comment nodes (but allow plain objects)
6774		if ( !elemData ) {
6775			return;
6776		}
6777
6778		// Caller can pass in an object of custom data in lieu of the handler
6779		if ( handler.handler ) {
6780			handleObjIn = handler;
6781			handler = handleObjIn.handler;
6782			selector = handleObjIn.selector;
6783		}
6784
6785		// Make sure that the handler has a unique ID, used to find/remove it later
6786		if ( !handler.guid ) {
6787			handler.guid = jQuery.guid++;
6788		}
6789
6790		// Init the element's event structure and main handler, if this is the first
6791		if ( !( events = elemData.events ) ) {
6792			events = elemData.events = {};
6793		}
6794		if ( !( eventHandle = elemData.handle ) ) {
6795			eventHandle = elemData.handle = function( e ) {
6796
6797				// Discard the second event of a jQuery.event.trigger() and
6798				// when an event is called after a page has unloaded
6799				return typeof jQuery !== "undefined" && jQuery.event.triggered !== e.type ?
6800					jQuery.event.dispatch.apply( elem, arguments ) : undefined;
6801			};
6802		}
6803
6804		// Handle multiple events separated by a space
6805		types = ( types || "" ).match( rnotwhite ) || [ "" ];
6806		t = types.length;
6807		while ( t-- ) {
6808			tmp = rtypenamespace.exec( types[ t ] ) || [];
6809			type = origType = tmp[ 1 ];
6810			namespaces = ( tmp[ 2 ] || "" ).split( "." ).sort();
6811
6812			// There *must* be a type, no attaching namespace-only handlers
6813			if ( !type ) {
6814				continue;
6815			}
6816
6817			// If event changes its type, use the special event handlers for the changed type
6818			special = jQuery.event.special[ type ] || {};
6819
6820			// If selector defined, determine special event api type, otherwise given type
6821			type = ( selector ? special.delegateType : special.bindType ) || type;
6822
6823			// Update special based on newly reset type
6824			special = jQuery.event.special[ type ] || {};
6825
6826			// handleObj is passed to all event handlers
6827			handleObj = jQuery.extend( {
6828				type: type,
6829				origType: origType,
6830				data: data,
6831				handler: handler,
6832				guid: handler.guid,
6833				selector: selector,
6834				needsContext: selector && jQuery.expr.match.needsContext.test( selector ),
6835				namespace: namespaces.join( "." )
6836			}, handleObjIn );
6837
6838			// Init the event handler queue if we're the first
6839			if ( !( handlers = events[ type ] ) ) {
6840				handlers = events[ type ] = [];
6841				handlers.delegateCount = 0;
6842
6843				// Only use addEventListener if the special events handler returns false
6844				if ( !special.setup ||
6845					special.setup.call( elem, data, namespaces, eventHandle ) === false ) {
6846
6847					if ( elem.addEventListener ) {
6848						elem.addEventListener( type, eventHandle );
6849					}
6850				}
6851			}
6852
6853			if ( special.add ) {
6854				special.add.call( elem, handleObj );
6855
6856				if ( !handleObj.handler.guid ) {
6857					handleObj.handler.guid = handler.guid;
6858				}
6859			}
6860
6861			// Add to the element's handler list, delegates in front
6862			if ( selector ) {
6863				handlers.splice( handlers.delegateCount++, 0, handleObj );
6864			} else {
6865				handlers.push( handleObj );
6866			}
6867
6868			// Keep track of which events have ever been used, for event optimization
6869			jQuery.event.global[ type ] = true;
6870		}
6871
6872	},
6873
6874	// Detach an event or set of events from an element
6875	remove: function( elem, types, handler, selector, mappedTypes ) {
6876
6877		var j, origCount, tmp,
6878			events, t, handleObj,
6879			special, handlers, type, namespaces, origType,
6880			elemData = dataPriv.hasData( elem ) && dataPriv.get( elem );
6881
6882		if ( !elemData || !( events = elemData.events ) ) {
6883			return;
6884		}
6885
6886		// Once for each type.namespace in types; type may be omitted
6887		types = ( types || "" ).match( rnotwhite ) || [ "" ];
6888		t = types.length;
6889		while ( t-- ) {
6890			tmp = rtypenamespace.exec( types[ t ] ) || [];
6891			type = origType = tmp[ 1 ];
6892			namespaces = ( tmp[ 2 ] || "" ).split( "." ).sort();
6893
6894			// Unbind all events (on this namespace, if provided) for the element
6895			if ( !type ) {
6896				for ( type in events ) {
6897					jQuery.event.remove( elem, type + types[ t ], handler, selector, true );
6898				}
6899				continue;
6900			}
6901
6902			special = jQuery.event.special[ type ] || {};
6903			type = ( selector ? special.delegateType : special.bindType ) || type;
6904			handlers = events[ type ] || [];
6905			tmp = tmp[ 2 ] &&
6906				new RegExp( "(^|\\.)" + namespaces.join( "\\.(?:.*\\.|)" ) + "(\\.|$)" );
6907
6908			// Remove matching events
6909			origCount = j = handlers.length;
6910			while ( j-- ) {
6911				handleObj = handlers[ j ];
6912
6913				if ( ( mappedTypes || origType === handleObj.origType ) &&
6914					( !handler || handler.guid === handleObj.guid ) &&
6915					( !tmp || tmp.test( handleObj.namespace ) ) &&
6916					( !selector || selector === handleObj.selector ||
6917						selector === "**" && handleObj.selector ) ) {
6918					handlers.splice( j, 1 );
6919
6920					if ( handleObj.selector ) {
6921						handlers.delegateCount--;
6922					}
6923					if ( special.remove ) {
6924						special.remove.call( elem, handleObj );
6925					}
6926				}
6927			}
6928
6929			// Remove generic event handler if we removed something and no more handlers exist
6930			// (avoids potential for endless recursion during removal of special event handlers)
6931			if ( origCount && !handlers.length ) {
6932				if ( !special.teardown ||
6933					special.teardown.call( elem, namespaces, elemData.handle ) === false ) {
6934
6935					jQuery.removeEvent( elem, type, elemData.handle );
6936				}
6937
6938				delete events[ type ];
6939			}
6940		}
6941
6942		// Remove data and the expando if it's no longer used
6943		if ( jQuery.isEmptyObject( events ) ) {
6944			dataPriv.remove( elem, "handle events" );
6945		}
6946	},
6947
6948	dispatch: function( event ) {
6949
6950		// Make a writable jQuery.Event from the native event object
6951		event = jQuery.event.fix( event );
6952
6953		var i, j, ret, matched, handleObj,
6954			handlerQueue = [],
6955			args = slice.call( arguments ),
6956			handlers = ( dataPriv.get( this, "events" ) || {} )[ event.type ] || [],
6957			special = jQuery.event.special[ event.type ] || {};
6958
6959		// Use the fix-ed jQuery.Event rather than the (read-only) native event
6960		args[ 0 ] = event;
6961		event.delegateTarget = this;
6962
6963		// Call the preDispatch hook for the mapped type, and let it bail if desired
6964		if ( special.preDispatch && special.preDispatch.call( this, event ) === false ) {
6965			return;
6966		}
6967
6968		// Determine handlers
6969		handlerQueue = jQuery.event.handlers.call( this, event, handlers );
6970
6971		// Run delegates first; they may want to stop propagation beneath us
6972		i = 0;
6973		while ( ( matched = handlerQueue[ i++ ] ) && !event.isPropagationStopped() ) {
6974			event.currentTarget = matched.elem;
6975
6976			j = 0;
6977			while ( ( handleObj = matched.handlers[ j++ ] ) &&
6978				!event.isImmediatePropagationStopped() ) {
6979
6980				// Triggered event must either 1) have no namespace, or 2) have namespace(s)
6981				// a subset or equal to those in the bound event (both can have no namespace).
6982				if ( !event.rnamespace || event.rnamespace.test( handleObj.namespace ) ) {
6983
6984					event.handleObj = handleObj;
6985					event.data = handleObj.data;
6986
6987					ret = ( ( jQuery.event.special[ handleObj.origType ] || {} ).handle ||
6988						handleObj.handler ).apply( matched.elem, args );
6989
6990					if ( ret !== undefined ) {
6991						if ( ( event.result = ret ) === false ) {
6992							event.preventDefault();
6993							event.stopPropagation();
6994						}
6995					}
6996				}
6997			}
6998		}
6999
7000		// Call the postDispatch hook for the mapped type
7001		if ( special.postDispatch ) {
7002			special.postDispatch.call( this, event );
7003		}
7004
7005		return event.result;
7006	},
7007
7008	handlers: function( event, handlers ) {
7009		var i, matches, sel, handleObj,
7010			handlerQueue = [],
7011			delegateCount = handlers.delegateCount,
7012			cur = event.target;
7013
7014		// Support (at least): Chrome, IE9
7015		// Find delegate handlers
7016		// Black-hole SVG <use> instance trees (#13180)
7017		//
7018		// Support: Firefox<=42+
7019		// Avoid non-left-click in FF but don't block IE radio events (#3861, gh-2343)
7020		if ( delegateCount && cur.nodeType &&
7021			( event.type !== "click" || isNaN( event.button ) || event.button < 1 ) ) {
7022
7023			for ( ; cur !== this; cur = cur.parentNode || this ) {
7024
7025				// Don't check non-elements (#13208)
7026				// Don't process clicks on disabled elements (#6911, #8165, #11382, #11764)
7027				if ( cur.nodeType === 1 && ( cur.disabled !== true || event.type !== "click" ) ) {
7028					matches = [];
7029					for ( i = 0; i < delegateCount; i++ ) {
7030						handleObj = handlers[ i ];
7031
7032						// Don't conflict with Object.prototype properties (#13203)
7033						sel = handleObj.selector + " ";
7034
7035						if ( matches[ sel ] === undefined ) {
7036							matches[ sel ] = handleObj.needsContext ?
7037								jQuery( sel, this ).index( cur ) > -1 :
7038								jQuery.find( sel, this, null, [ cur ] ).length;
7039						}
7040						if ( matches[ sel ] ) {
7041							matches.push( handleObj );
7042						}
7043					}
7044					if ( matches.length ) {
7045						handlerQueue.push( { elem: cur, handlers: matches } );
7046					}
7047				}
7048			}
7049		}
7050
7051		// Add the remaining (directly-bound) handlers
7052		if ( delegateCount < handlers.length ) {
7053			handlerQueue.push( { elem: this, handlers: handlers.slice( delegateCount ) } );
7054		}
7055
7056		return handlerQueue;
7057	},
7058
7059	// Includes some event props shared by KeyEvent and MouseEvent
7060	props: ( "altKey bubbles cancelable ctrlKey currentTarget detail eventPhase " +
7061		"metaKey relatedTarget shiftKey target timeStamp view which" ).split( " " ),
7062
7063	fixHooks: {},
7064
7065	keyHooks: {
7066		props: "char charCode key keyCode".split( " " ),
7067		filter: function( event, original ) {
7068
7069			// Add which for key events
7070			if ( event.which == null ) {
7071				event.which = original.charCode != null ? original.charCode : original.keyCode;
7072			}
7073
7074			return event;
7075		}
7076	},
7077
7078	mouseHooks: {
7079		props: ( "button buttons clientX clientY offsetX offsetY pageX pageY " +
7080			"screenX screenY toElement" ).split( " " ),
7081		filter: function( event, original ) {
7082			var eventDoc, doc, body,
7083				button = original.button;
7084
7085			// Calculate pageX/Y if missing and clientX/Y available
7086			if ( event.pageX == null && original.clientX != null ) {
7087				eventDoc = event.target.ownerDocument || document;
7088				doc = eventDoc.documentElement;
7089				body = eventDoc.body;
7090
7091				event.pageX = original.clientX +
7092					( doc && doc.scrollLeft || body && body.scrollLeft || 0 ) -
7093					( doc && doc.clientLeft || body && body.clientLeft || 0 );
7094				event.pageY = original.clientY +
7095					( doc && doc.scrollTop  || body && body.scrollTop  || 0 ) -
7096					( doc && doc.clientTop  || body && body.clientTop  || 0 );
7097			}
7098
7099			// Add which for click: 1 === left; 2 === middle; 3 === right
7100			// Note: button is not normalized, so don't use it
7101			if ( !event.which && button !== undefined ) {
7102				event.which = ( button & 1 ? 1 : ( button & 2 ? 3 : ( button & 4 ? 2 : 0 ) ) );
7103			}
7104
7105			return event;
7106		}
7107	},
7108
7109	fix: function( event ) {
7110		if ( event[ jQuery.expando ] ) {
7111			return event;
7112		}
7113
7114		// Create a writable copy of the event object and normalize some properties
7115		var i, prop, copy,
7116			type = event.type,
7117			originalEvent = event,
7118			fixHook = this.fixHooks[ type ];
7119
7120		if ( !fixHook ) {
7121			this.fixHooks[ type ] = fixHook =
7122				rmouseEvent.test( type ) ? this.mouseHooks :
7123				rkeyEvent.test( type ) ? this.keyHooks :
7124				{};
7125		}
7126		copy = fixHook.props ? this.props.concat( fixHook.props ) : this.props;
7127
7128		event = new jQuery.Event( originalEvent );
7129
7130		i = copy.length;
7131		while ( i-- ) {
7132			prop = copy[ i ];
7133			event[ prop ] = originalEvent[ prop ];
7134		}
7135
7136		// Support: Cordova 2.5 (WebKit) (#13255)
7137		// All events should have a target; Cordova deviceready doesn't
7138		if ( !event.target ) {
7139			event.target = document;
7140		}
7141
7142		// Support: Safari 6.0+, Chrome<28
7143		// Target should not be a text node (#504, #13143)
7144		if ( event.target.nodeType === 3 ) {
7145			event.target = event.target.parentNode;
7146		}
7147
7148		return fixHook.filter ? fixHook.filter( event, originalEvent ) : event;
7149	},
7150
7151	special: {
7152		load: {
7153
7154			// Prevent triggered image.load events from bubbling to window.load
7155			noBubble: true
7156		},
7157		focus: {
7158
7159			// Fire native event if possible so blur/focus sequence is correct
7160			trigger: function() {
7161				if ( this !== safeActiveElement() && this.focus ) {
7162					this.focus();
7163					return false;
vendor: 12,508 bytes, lines 7164-7640
7164				}
7165			},
7166			delegateType: "focusin"
7167		},
7168		blur: {
7169			trigger: function() {
7170				if ( this === safeActiveElement() && this.blur ) {
7171					this.blur();
7172					return false;
7173				}
7174			},
7175			delegateType: "focusout"
7176		},
7177		click: {
7178
7179			// For checkbox, fire native event so checked state will be right
7180			trigger: function() {
7181				if ( this.type === "checkbox" && this.click && jQuery.nodeName( this, "input" ) ) {
7182					this.click();
7183					return false;
7184				}
7185			},
7186
7187			// For cross-browser consistency, don't fire native .click() on links
7188			_default: function( event ) {
7189				return jQuery.nodeName( event.target, "a" );
7190			}
7191		},
7192
7193		beforeunload: {
7194			postDispatch: function( event ) {
7195
7196				// Support: Firefox 20+
7197				// Firefox doesn't alert if the returnValue field is not set.
7198				if ( event.result !== undefined && event.originalEvent ) {
7199					event.originalEvent.returnValue = event.result;
7200				}
7201			}
7202		}
7203	}
7204};
7205
7206jQuery.removeEvent = function( elem, type, handle ) {
7207
7208	// This "if" is needed for plain objects
7209	if ( elem.removeEventListener ) {
7210		elem.removeEventListener( type, handle );
7211	}
7212};
7213
7214jQuery.Event = function( src, props ) {
7215
7216	// Allow instantiation without the 'new' keyword
7217	if ( !( this instanceof jQuery.Event ) ) {
7218		return new jQuery.Event( src, props );
7219	}
7220
7221	// Event object
7222	if ( src && src.type ) {
7223		this.originalEvent = src;
7224		this.type = src.type;
7225
7226		// Events bubbling up the document may have been marked as prevented
7227		// by a handler lower down the tree; reflect the correct value.
7228		this.isDefaultPrevented = src.defaultPrevented ||
7229				src.defaultPrevented === undefined &&
7230
7231				// Support: Android<4.0
7232				src.returnValue === false ?
7233			returnTrue :
7234			returnFalse;
7235
7236	// Event type
7237	} else {
7238		this.type = src;
7239	}
7240
7241	// Put explicitly provided properties onto the event object
7242	if ( props ) {
7243		jQuery.extend( this, props );
7244	}
7245
7246	// Create a timestamp if incoming event doesn't have one
7247	this.timeStamp = src && src.timeStamp || jQuery.now();
7248
7249	// Mark it as fixed
7250	this[ jQuery.expando ] = true;
7251};
7252
7253// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding
7254// http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html
7255jQuery.Event.prototype = {
7256	constructor: jQuery.Event,
7257	isDefaultPrevented: returnFalse,
7258	isPropagationStopped: returnFalse,
7259	isImmediatePropagationStopped: returnFalse,
7260	isSimulated: false,
7261
7262	preventDefault: function() {
7263		var e = this.originalEvent;
7264
7265		this.isDefaultPrevented = returnTrue;
7266
7267		if ( e && !this.isSimulated ) {
7268			e.preventDefault();
7269		}
7270	},
7271	stopPropagation: function() {
7272		var e = this.originalEvent;
7273
7274		this.isPropagationStopped = returnTrue;
7275
7276		if ( e && !this.isSimulated ) {
7277			e.stopPropagation();
7278		}
7279	},
7280	stopImmediatePropagation: function() {
7281		var e = this.originalEvent;
7282
7283		this.isImmediatePropagationStopped = returnTrue;
7284
7285		if ( e && !this.isSimulated ) {
7286			e.stopImmediatePropagation();
7287		}
7288
7289		this.stopPropagation();
7290	}
7291};
7292
7293// Create mouseenter/leave events using mouseover/out and event-time checks
7294// so that event delegation works in jQuery.
7295// Do the same for pointerenter/pointerleave and pointerover/pointerout
7296//
7297// Support: Safari 7 only
7298// Safari sends mouseenter too often; see:
7299// https://code.google.com/p/chromium/issues/detail?id=470258
7300// for the description of the bug (it existed in older Chrome versions as well).
7301jQuery.each( {
7302	mouseenter: "mouseover",
7303	mouseleave: "mouseout",
7304	pointerenter: "pointerover",
7305	pointerleave: "pointerout"
7306}, function( orig, fix ) {
7307	jQuery.event.special[ orig ] = {
7308		delegateType: fix,
7309		bindType: fix,
7310
7311		handle: function( event ) {
7312			var ret,
7313				target = this,
7314				related = event.relatedTarget,
7315				handleObj = event.handleObj;
7316
7317			// For mouseenter/leave call the handler if related is outside the target.
7318			// NB: No relatedTarget if the mouse left/entered the browser window
7319			if ( !related || ( related !== target && !jQuery.contains( target, related ) ) ) {
7320				event.type = handleObj.origType;
7321				ret = handleObj.handler.apply( this, arguments );
7322				event.type = fix;
7323			}
7324			return ret;
7325		}
7326	};
7327} );
7328
7329jQuery.fn.extend( {
7330	on: function( types, selector, data, fn ) {
7331		return on( this, types, selector, data, fn );
7332	},
7333	one: function( types, selector, data, fn ) {
7334		return on( this, types, selector, data, fn, 1 );
7335	},
7336	off: function( types, selector, fn ) {
7337		var handleObj, type;
7338		if ( types && types.preventDefault && types.handleObj ) {
7339
7340			// ( event )  dispatched jQuery.Event
7341			handleObj = types.handleObj;
7342			jQuery( types.delegateTarget ).off(
7343				handleObj.namespace ?
7344					handleObj.origType + "." + handleObj.namespace :
7345					handleObj.origType,
7346				handleObj.selector,
7347				handleObj.handler
7348			);
7349			return this;
7350		}
7351		if ( typeof types === "object" ) {
7352
7353			// ( types-object [, selector] )
7354			for ( type in types ) {
7355				this.off( type, selector, types[ type ] );
7356			}
7357			return this;
7358		}
7359		if ( selector === false || typeof selector === "function" ) {
7360
7361			// ( types [, fn] )
7362			fn = selector;
7363			selector = undefined;
7364		}
7365		if ( fn === false ) {
7366			fn = returnFalse;
7367		}
7368		return this.each( function() {
7369			jQuery.event.remove( this, types, fn, selector );
7370		} );
7371	}
7372} );
7373
7374
7375var
7376	rxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,
7377
7378	// Support: IE 10-11, Edge 10240+
7379	// In IE/Edge using regex groups here causes severe slowdowns.
7380	// See https://connect.microsoft.com/IE/feedback/details/1736512/
7381	rnoInnerhtml = /<script|<style|<link/i,
7382
7383	// checked="checked" or checked
7384	rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i,
7385	rscriptTypeMasked = /^true\/(.*)/,
7386	rcleanScript = /^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;
7387
7388// Manipulating tables requires a tbody
7389function manipulationTarget( elem, content ) {
7390	return jQuery.nodeName( elem, "table" ) &&
7391		jQuery.nodeName( content.nodeType !== 11 ? content : content.firstChild, "tr" ) ?
7392
7393		elem.getElementsByTagName( "tbody" )[ 0 ] ||
7394			elem.appendChild( elem.ownerDocument.createElement( "tbody" ) ) :
7395		elem;
7396}
7397
7398// Replace/restore the type attribute of script elements for safe DOM manipulation
7399function disableScript( elem ) {
7400	elem.type = ( elem.getAttribute( "type" ) !== null ) + "/" + elem.type;
7401	return elem;
7402}
7403function restoreScript( elem ) {
7404	var match = rscriptTypeMasked.exec( elem.type );
7405
7406	if ( match ) {
7407		elem.type = match[ 1 ];
7408	} else {
7409		elem.removeAttribute( "type" );
7410	}
7411
7412	return elem;
7413}
7414
7415function cloneCopyEvent( src, dest ) {
7416	var i, l, type, pdataOld, pdataCur, udataOld, udataCur, events;
7417
7418	if ( dest.nodeType !== 1 ) {
7419		return;
7420	}
7421
7422	// 1. Copy private data: events, handlers, etc.
7423	if ( dataPriv.hasData( src ) ) {
7424		pdataOld = dataPriv.access( src );
7425		pdataCur = dataPriv.set( dest, pdataOld );
7426		events = pdataOld.events;
7427
7428		if ( events ) {
7429			delete pdataCur.handle;
7430			pdataCur.events = {};
7431
7432			for ( type in events ) {
7433				for ( i = 0, l = events[ type ].length; i < l; i++ ) {
7434					jQuery.event.add( dest, type, events[ type ][ i ] );
7435				}
7436			}
7437		}
7438	}
7439
7440	// 2. Copy user data
7441	if ( dataUser.hasData( src ) ) {
7442		udataOld = dataUser.access( src );
7443		udataCur = jQuery.extend( {}, udataOld );
7444
7445		dataUser.set( dest, udataCur );
7446	}
7447}
7448
7449// Fix IE bugs, see support tests
7450function fixInput( src, dest ) {
7451	var nodeName = dest.nodeName.toLowerCase();
7452
7453	// Fails to persist the checked state of a cloned checkbox or radio button.
7454	if ( nodeName === "input" && rcheckableType.test( src.type ) ) {
7455		dest.checked = src.checked;
7456
7457	// Fails to return the selected option to the default selected state when cloning options
7458	} else if ( nodeName === "input" || nodeName === "textarea" ) {
7459		dest.defaultValue = src.defaultValue;
7460	}
7461}
7462
7463function domManip( collection, args, callback, ignored ) {
7464
7465	// Flatten any nested arrays
7466	args = concat.apply( [], args );
7467
7468	var fragment, first, scripts, hasScripts, node, doc,
7469		i = 0,
7470		l = collection.length,
7471		iNoClone = l - 1,
7472		value = args[ 0 ],
7473		isFunction = jQuery.isFunction( value );
7474
7475	// We can't cloneNode fragments that contain checked, in WebKit
7476	if ( isFunction ||
7477			( l > 1 && typeof value === "string" &&
7478				!support.checkClone && rchecked.test( value ) ) ) {
7479		return collection.each( function( index ) {
7480			var self = collection.eq( index );
7481			if ( isFunction ) {
7482				args[ 0 ] = value.call( this, index, self.html() );
7483			}
7484			domManip( self, args, callback, ignored );
7485		} );
7486	}
7487
7488	if ( l ) {
7489		fragment = buildFragment( args, collection[ 0 ].ownerDocument, false, collection, ignored );
7490		first = fragment.firstChild;
7491
7492		if ( fragment.childNodes.length === 1 ) {
7493			fragment = first;
7494		}
7495
7496		// Require either new content or an interest in ignored elements to invoke the callback
7497		if ( first || ignored ) {
7498			scripts = jQuery.map( getAll( fragment, "script" ), disableScript );
7499			hasScripts = scripts.length;
7500
7501			// Use the original fragment for the last item
7502			// instead of the first because it can end up
7503			// being emptied incorrectly in certain situations (#8070).
7504			for ( ; i < l; i++ ) {
7505				node = fragment;
7506
7507				if ( i !== iNoClone ) {
7508					node = jQuery.clone( node, true, true );
7509
7510					// Keep references to cloned scripts for later restoration
7511					if ( hasScripts ) {
7512
7513						// Support: Android<4.1, PhantomJS<2
7514						// push.apply(_, arraylike) throws on ancient WebKit
7515						jQuery.merge( scripts, getAll( node, "script" ) );
7516					}
7517				}
7518
7519				callback.call( collection[ i ], node, i );
7520			}
7521
7522			if ( hasScripts ) {
7523				doc = scripts[ scripts.length - 1 ].ownerDocument;
7524
7525				// Reenable scripts
7526				jQuery.map( scripts, restoreScript );
7527
7528				// Evaluate executable scripts on first document insertion
7529				for ( i = 0; i < hasScripts; i++ ) {
7530					node = scripts[ i ];
7531					if ( rscriptType.test( node.type || "" ) &&
7532						!dataPriv.access( node, "globalEval" ) &&
7533						jQuery.contains( doc, node ) ) {
7534
7535						if ( node.src ) {
7536
7537							// Optional AJAX dependency, but won't run scripts if not present
7538							if ( jQuery._evalUrl ) {
7539								jQuery._evalUrl( node.src );
7540							}
7541						} else {
7542							jQuery.globalEval( node.textContent.replace( rcleanScript, "" ) );
7543						}
7544					}
7545				}
7546			}
7547		}
7548	}
7549
7550	return collection;
7551}
7552
7553function remove( elem, selector, keepData ) {
7554	var node,
7555		nodes = selector ? jQuery.filter( selector, elem ) : elem,
7556		i = 0;
7557
7558	for ( ; ( node = nodes[ i ] ) != null; i++ ) {
7559		if ( !keepData && node.nodeType === 1 ) {
7560			jQuery.cleanData( getAll( node ) );
7561		}
7562
7563		if ( node.parentNode ) {
7564			if ( keepData && jQuery.contains( node.ownerDocument, node ) ) {
7565				setGlobalEval( getAll( node, "script" ) );
7566			}
7567			node.parentNode.removeChild( node );
7568		}
7569	}
7570
7571	return elem;
7572}
7573
7574jQuery.extend( {
7575	htmlPrefilter: function( html ) {
7576		return html.replace( rxhtmlTag, "<$1></$2>" );
7577	},
7578
7579	clone: function( elem, dataAndEvents, deepDataAndEvents ) {
7580		var i, l, srcElements, destElements,
7581			clone = elem.cloneNode( true ),
7582			inPage = jQuery.contains( elem.ownerDocument, elem );
7583
7584		// Fix IE cloning issues
7585		if ( !support.noCloneChecked && ( elem.nodeType === 1 || elem.nodeType === 11 ) &&
7586				!jQuery.isXMLDoc( elem ) ) {
7587
7588			// We eschew Sizzle here for performance reasons: http://jsperf.com/getall-vs-sizzle/2
7589			destElements = getAll( clone );
7590			srcElements = getAll( elem );
7591
7592			for ( i = 0, l = srcElements.length; i < l; i++ ) {
7593				fixInput( srcElements[ i ], destElements[ i ] );
7594			}
7595		}
7596
7597		// Copy the events from the original to the clone
7598		if ( dataAndEvents ) {
7599			if ( deepDataAndEvents ) {
7600				srcElements = srcElements || getAll( elem );
7601				destElements = destElements || getAll( clone );
7602
7603				for ( i = 0, l = srcElements.length; i < l; i++ ) {
7604					cloneCopyEvent( srcElements[ i ], destElements[ i ] );
7605				}
7606			} else {
7607				cloneCopyEvent( elem, clone );
7608			}
7609		}
7610
7611		// Preserve script evaluation history
7612		destElements = getAll( clone, "script" );
7613		if ( destElements.length > 0 ) {
7614			setGlobalEval( destElements, !inPage && getAll( elem, "script" ) );
7615		}
7616
7617		// Return the cloned set
7618		return clone;
7619	},
7620
7621	cleanData: function( elems ) {
7622		var data, elem, type,
7623			special = jQuery.event.special,
7624			i = 0;
7625
7626		for ( ; ( elem = elems[ i ] ) !== undefined; i++ ) {
7627			if ( acceptData( elem ) ) {
7628				if ( ( data = elem[ dataPriv.expando ] ) ) {
7629					if ( data.events ) {
7630						for ( type in data.events ) {
7631							if ( special[ type ] ) {
7632								jQuery.event.remove( elem, type );
7633
7634							// This is a shortcut to avoid jQuery.event.remove's overhead
7635							} else {
7636								jQuery.removeEvent( elem, type, data.handle );
7637							}
7638						}
7639					}
7640
vendor: 1,186 bytes, lines 7641-7689
7641					// Support: Chrome <= 35-45+
7642					// Assign undefined instead of using delete, see Data#remove
7643					elem[ dataPriv.expando ] = undefined;
7644				}
7645				if ( elem[ dataUser.expando ] ) {
7646
7647					// Support: Chrome <= 35-45+
7648					// Assign undefined instead of using delete, see Data#remove
7649					elem[ dataUser.expando ] = undefined;
7650				}
7651			}
7652		}
7653	}
7654} );
7655
7656jQuery.fn.extend( {
7657
7658	// Keep domManip exposed until 3.0 (gh-2225)
7659	domManip: domManip,
7660
7661	detach: function( selector ) {
7662		return remove( this, selector, true );
7663	},
7664
7665	remove: function( selector ) {
7666		return remove( this, selector );
7667	},
7668
7669	text: function( value ) {
7670		return access( this, function( value ) {
7671			return value === undefined ?
7672				jQuery.text( this ) :
7673				this.empty().each( function() {
7674					if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
7675						this.textContent = value;
7676					}
7677				} );
7678		}, null, value, arguments.length );
7679	},
7680
7681	append: function() {
7682		return domManip( this, arguments, function( elem ) {
7683			if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
7684				var target = manipulationTarget( this, elem );
7685				target.appendChild( elem );
7686			}
7687		} );
7688	},
7689
vendor: 4,383 bytes, lines 7690-7873
7690	prepend: function() {
7691		return domManip( this, arguments, function( elem ) {
7692			if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
7693				var target = manipulationTarget( this, elem );
7694				target.insertBefore( elem, target.firstChild );
7695			}
7696		} );
7697	},
7698
7699	before: function() {
7700		return domManip( this, arguments, function( elem ) {
7701			if ( this.parentNode ) {
7702				this.parentNode.insertBefore( elem, this );
7703			}
7704		} );
7705	},
7706
7707	after: function() {
7708		return domManip( this, arguments, function( elem ) {
7709			if ( this.parentNode ) {
7710				this.parentNode.insertBefore( elem, this.nextSibling );
7711			}
7712		} );
7713	},
7714
7715	empty: function() {
7716		var elem,
7717			i = 0;
7718
7719		for ( ; ( elem = this[ i ] ) != null; i++ ) {
7720			if ( elem.nodeType === 1 ) {
7721
7722				// Prevent memory leaks
7723				jQuery.cleanData( getAll( elem, false ) );
7724
7725				// Remove any remaining nodes
7726				elem.textContent = "";
7727			}
7728		}
7729
7730		return this;
7731	},
7732
7733	clone: function( dataAndEvents, deepDataAndEvents ) {
7734		dataAndEvents = dataAndEvents == null ? false : dataAndEvents;
7735		deepDataAndEvents = deepDataAndEvents == null ? dataAndEvents : deepDataAndEvents;
7736
7737		return this.map( function() {
7738			return jQuery.clone( this, dataAndEvents, deepDataAndEvents );
7739		} );
7740	},
7741
7742	html: function( value ) {
7743		return access( this, function( value ) {
7744			var elem = this[ 0 ] || {},
7745				i = 0,
7746				l = this.length;
7747
7748			if ( value === undefined && elem.nodeType === 1 ) {
7749				return elem.innerHTML;
7750			}
7751
7752			// See if we can take a shortcut and just use innerHTML
7753			if ( typeof value === "string" && !rnoInnerhtml.test( value ) &&
7754				!wrapMap[ ( rtagName.exec( value ) || [ "", "" ] )[ 1 ].toLowerCase() ] ) {
7755
7756				value = jQuery.htmlPrefilter( value );
7757
7758				try {
7759					for ( ; i < l; i++ ) {
7760						elem = this[ i ] || {};
7761
7762						// Remove element nodes and prevent memory leaks
7763						if ( elem.nodeType === 1 ) {
7764							jQuery.cleanData( getAll( elem, false ) );
7765							elem.innerHTML = value;
7766						}
7767					}
7768
7769					elem = 0;
7770
7771				// If using innerHTML throws an exception, use the fallback method
7772				} catch ( e ) {}
7773			}
7774
7775			if ( elem ) {
7776				this.empty().append( value );
7777			}
7778		}, null, value, arguments.length );
7779	},
7780
7781	replaceWith: function() {
7782		var ignored = [];
7783
7784		// Make the changes, replacing each non-ignored context element with the new content
7785		return domManip( this, arguments, function( elem ) {
7786			var parent = this.parentNode;
7787
7788			if ( jQuery.inArray( this, ignored ) < 0 ) {
7789				jQuery.cleanData( getAll( this ) );
7790				if ( parent ) {
7791					parent.replaceChild( elem, this );
7792				}
7793			}
7794
7795		// Force callback invocation
7796		}, ignored );
7797	}
7798} );
7799
7800jQuery.each( {
7801	appendTo: "append",
7802	prependTo: "prepend",
7803	insertBefore: "before",
7804	insertAfter: "after",
7805	replaceAll: "replaceWith"
7806}, function( name, original ) {
7807	jQuery.fn[ name ] = function( selector ) {
7808		var elems,
7809			ret = [],
7810			insert = jQuery( selector ),
7811			last = insert.length - 1,
7812			i = 0;
7813
7814		for ( ; i <= last; i++ ) {
7815			elems = i === last ? this : this.clone( true );
7816			jQuery( insert[ i ] )[ original ]( elems );
7817
7818			// Support: QtWebKit
7819			// .get() because push.apply(_, arraylike) throws
7820			push.apply( ret, elems.get() );
7821		}
7822
7823		return this.pushStack( ret );
7824	};
7825} );
7826
7827
7828var iframe,
7829	elemdisplay = {
7830
7831		// Support: Firefox
7832		// We have to pre-define these values for FF (#10227)
7833		HTML: "block",
7834		BODY: "block"
7835	};
7836
7837/**
7838 * Retrieve the actual display of a element
7839 * @param {String} name nodeName of the element
7840 * @param {Object} doc Document object
7841 */
7842
7843// Called only from within defaultDisplay
7844function actualDisplay( name, doc ) {
7845	var elem = jQuery( doc.createElement( name ) ).appendTo( doc.body ),
7846
7847		display = jQuery.css( elem[ 0 ], "display" );
7848
7849	// We don't have any data stored on the element,
7850	// so use "detach" method as fast way to get rid of the element
7851	elem.detach();
7852
7853	return display;
7854}
7855
7856/**
7857 * Try to determine the default display value of an element
7858 * @param {String} nodeName
7859 */
7860function defaultDisplay( nodeName ) {
7861	var doc = document,
7862		display = elemdisplay[ nodeName ];
7863
7864	if ( !display ) {
7865		display = actualDisplay( nodeName, doc );
7866
7867		// If the simple way fails, read from inside an iframe
7868		if ( display === "none" || !display ) {
7869
7870			// Use the already-created iframe if possible
7871			iframe = ( iframe || jQuery( "<iframe frameborder='0' width='0' height='0'/>" ) )
7872				.appendTo( doc.documentElement );
7873
7874			// Always write a new HTML skeleton so Webkit and Firefox don't choke on reuse
7875			doc = iframe[ 0 ].contentDocument;
7876
7877			// Support: IE
7878			doc.write();
7879			doc.close();
7880
7881			display = actualDisplay( nodeName, doc );
7882			iframe.detach();
7883		}
7884
7885		// Store the correct default display
7886		elemdisplay[ nodeName ] = display;
7887	}
7888
7889	return display;
7890}
7891var rmargin = ( /^margin/ );
7892
7893var rnumnonpx = new RegExp( "^(" + pnum + ")(?!px)[a-z%]+$", "i" );
7894
7895var getStyles = function( elem ) {
7896
7897		// Support: IE<=11+, Firefox<=30+ (#15098, #14150)
7898		// IE throws on elements created in popups
7899		// FF meanwhile throws on frame elements through "defaultView.getComputedStyle"
7900		var view = elem.ownerDocument.defaultView;
7901
7902		if ( !view || !view.opener ) {
7903			view = window;
7904		}
7905
7906		return view.getComputedStyle( elem );
7907	};
7908
7909var swap = function( elem, options, callback, args ) {
7910	var ret, name,
7911		old = {};
7912
7913	// Remember the old values, and insert the new ones
7914	for ( name in options ) {
7915		old[ name ] = elem.style[ name ];
7916		elem.style[ name ] = options[ name ];
7917	}
7918
7919	ret = callback.apply( elem, args || [] );
7920
7921	// Revert the old values
7922	for ( name in options ) {
7923		elem.style[ name ] = old[ name ];
7924	}
7925
7926	return ret;
7927};
7928
7929
7930var documentElement = document.documentElement;
7931
7932
7933
7934( function() {
7935	var pixelPositionVal, boxSizingReliableVal, pixelMarginRightVal, reliableMarginLeftVal,
7936		container = document.createElement( "div" ),
7937		div = document.createElement( "div" );
7938
7939	// Finish early in limited (non-browser) environments
7940	if ( !div.style ) {
7941		return;
7942	}
7943
7944	// Support: IE9-11+
7945	// Style of cloned element affects source element cloned (#8908)
7946	div.style.backgroundClip = "content-box";
7947	div.cloneNode( true ).style.backgroundClip = "";
7948	support.clearCloneStyle = div.style.backgroundClip === "content-box";
7949
7950	container.style.cssText = "border:0;width:8px;height:0;top:0;left:-9999px;" +
7951		"padding:0;margin-top:1px;position:absolute";
7952	container.appendChild( div );
7953
7954	// Executing both pixelPosition & boxSizingReliable tests require only one layout
7955	// so they're executed at the same time to save the second computation.
7956	function computeStyleTests() {
7957		div.style.cssText =
7958
7959			// Support: Firefox<29, Android 2.3
7960			// Vendor-prefix box-sizing
7961			"-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;" +
7962			"position:relative;display:block;" +
7963			"margin:auto;border:1px;padding:1px;" +
7964			"top:1%;width:50%";
7965		div.innerHTML = "";
7966		documentElement.appendChild( container );
7967
7968		var divStyle = window.getComputedStyle( div );
7969		pixelPositionVal = divStyle.top !== "1%";
7970		reliableMarginLeftVal = divStyle.marginLeft === "2px";
7971		boxSizingReliableVal = divStyle.width === "4px";
7972
7973		// Support: Android 4.0 - 4.3 only
7974		// Some styles come back with percentage values, even though they shouldn't
7975		div.style.marginRight = "50%";
7976		pixelMarginRightVal = divStyle.marginRight === "4px";
7977
7978		documentElement.removeChild( container );
7979	}
7980
7981	jQuery.extend( support, {
7982		pixelPosition: function() {
7983
7984			// This test is executed only once but we still do memoizing
7985			// since we can use the boxSizingReliable pre-computing.
7986			// No need to check if the test was already performed, though.
7987			computeStyleTests();
7988			return pixelPositionVal;
7989		},
7990		boxSizingReliable: function() {
7991			if ( boxSizingReliableVal == null ) {
7992				computeStyleTests();
7993			}
7994			return boxSizingReliableVal;
7995		},
7996		pixelMarginRight: function() {
7997
7998			// Support: Android 4.0-4.3
7999			// We're checking for boxSizingReliableVal here instead of pixelMarginRightVal
8000			// since that compresses better and they're computed together anyway.
8001			if ( boxSizingReliableVal == null ) {
8002				computeStyleTests();
8003			}
8004			return pixelMarginRightVal;
8005		},
8006		reliableMarginLeft: function() {
8007
8008			// Support: IE <=8 only, Android 4.0 - 4.3 only, Firefox <=3 - 37
8009			if ( boxSizingReliableVal == null ) {
8010				computeStyleTests();
8011			}
8012			return reliableMarginLeftVal;
8013		},
8014		reliableMarginRight: function() {
8015
8016			// Support: Android 2.3
8017			// Check if div with explicit width and no margin-right incorrectly
8018			// gets computed margin-right based on width of container. (#3333)
8019			// WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right
8020			// This support function is only executed once so no memoizing is needed.
8021			var ret,
8022				marginDiv = div.appendChild( document.createElement( "div" ) );
8023
8024			// Reset CSS: box-sizing; display; margin; border; padding
8025			marginDiv.style.cssText = div.style.cssText =
8026
8027				// Support: Android 2.3
8028				// Vendor-prefix box-sizing
8029				"-webkit-box-sizing:content-box;box-sizing:content-box;" +
8030				"display:block;margin:0;border:0;padding:0";
8031			marginDiv.style.marginRight = marginDiv.style.width = "0";
8032			div.style.width = "1px";
8033			documentElement.appendChild( container );
8034
8035			ret = !parseFloat( window.getComputedStyle( marginDiv ).marginRight );
8036
8037			documentElement.removeChild( container );
8038			div.removeChild( marginDiv );
8039
8040			return ret;
8041		}
8042	} );
8043} )();
8044
8045
8046function curCSS( elem, name, computed ) {
8047	var width, minWidth, maxWidth, ret,
8048		style = elem.style;
8049
8050	computed = computed || getStyles( elem );
8051	ret = computed ? computed.getPropertyValue( name ) || computed[ name ] : undefined;
8052
8053	// Support: Opera 12.1x only
8054	// Fall back to style even without computed
8055	// computed is undefined for elems on document fragments
8056	if ( ( ret === "" || ret === undefined ) && !jQuery.contains( elem.ownerDocument, elem ) ) {
8057		ret = jQuery.style( elem, name );
8058	}
8059
8060	// Support: IE9
8061	// getPropertyValue is only needed for .css('filter') (#12537)
8062	if ( computed ) {
8063
8064		// A tribute to the "awesome hack by Dean Edwards"
8065		// Android Browser returns percentage for some values,
8066		// but width seems to be reliably pixels.
8067		// This is against the CSSOM draft spec:
8068		// http://dev.w3.org/csswg/cssom/#resolved-values
8069		if ( !support.pixelMarginRight() && rnumnonpx.test( ret ) && rmargin.test( name ) ) {
8070
8071			// Remember the original values
8072			width = style.width;
8073			minWidth = style.minWidth;
8074			maxWidth = style.maxWidth;
8075
8076			// Put in the new values to get a computed value out
8077			style.minWidth = style.maxWidth = style.width = ret;
8078			ret = computed.width;
8079
8080			// Revert the changed values
8081			style.width = width;
8082			style.minWidth = minWidth;
8083			style.maxWidth = maxWidth;
8084		}
8085	}
8086
8087	return ret !== undefined ?
8088
8089		// Support: IE9-11+
8090		// IE returns zIndex value as an integer.
8091		ret + "" :
8092		ret;
8093}
8094
8095
8096function addGetHookIf( conditionFn, hookFn ) {
8097
8098	// Define the hook, we'll check on the first run if it's really needed.
8099	return {
8100		get: function() {
8101			if ( conditionFn() ) {
8102
8103				// Hook not needed (or it's not possible to use it due
8104				// to missing dependency), remove it.
8105				delete this.get;
8106				return;
8107			}
8108
8109			// Hook needed; redefine it so that the support test is not executed again.
8110			return ( this.get = hookFn ).apply( this, arguments );
8111		}
8112	};
8113}
8114
8115
8116var
8117
8118	// Swappable if display is none or starts with table
8119	// except "table", "table-cell", or "table-caption"
8120	// See here for display values: https://developer.mozilla.org/en-US/docs/CSS/display
8121	rdisplayswap = /^(none|table(?!-c[ea]).+)/,
8122
8123	cssShow = { position: "absolute", visibility: "hidden", display: "block" },
8124	cssNormalTransform = {
8125		letterSpacing: "0",
8126		fontWeight: "400"
8127	},
8128
8129	cssPrefixes = [ "Webkit", "O", "Moz", "ms" ],
8130	emptyStyle = document.createElement( "div" ).style;
8131
8132// Return a css property mapped to a potentially vendor prefixed property
8133function vendorPropName( name ) {
8134
8135	// Shortcut for names that are not vendor prefixed
8136	if ( name in emptyStyle ) {
8137		return name;
8138	}
8139
8140	// Check for vendor prefixed names
8141	var capName = name[ 0 ].toUpperCase() + name.slice( 1 ),
8142		i = cssPrefixes.length;
8143
8144	while ( i-- ) {
8145		name = cssPrefixes[ i ] + capName;
8146		if ( name in emptyStyle ) {
8147			return name;
8148		}
8149	}
8150}
8151
8152function setPositiveNumber( elem, value, subtract ) {
8153
8154	// Any relative (+/-) values have already been
8155	// normalized at this point
8156	var matches = rcssNum.exec( value );
8157	return matches ?
8158
8159		// Guard against undefined "subtract", e.g., when used as in cssHooks
8160		Math.max( 0, matches[ 2 ] - ( subtract || 0 ) ) + ( matches[ 3 ] || "px" ) :
8161		value;
8162}
8163
8164function augmentWidthOrHeight( elem, name, extra, isBorderBox, styles ) {
8165	var i = extra === ( isBorderBox ? "border" : "content" ) ?
8166
8167		// If we already have the right measurement, avoid augmentation
8168		4 :
8169
8170		// Otherwise initialize for horizontal or vertical properties
8171		name === "width" ? 1 : 0,
8172
8173		val = 0;
8174
8175	for ( ; i < 4; i += 2 ) {
8176
8177		// Both box models exclude margin, so add it if we want it
8178		if ( extra === "margin" ) {
8179			val += jQuery.css( elem, extra + cssExpand[ i ], true, styles );
8180		}
8181
8182		if ( isBorderBox ) {
8183
8184			// border-box includes padding, so remove it if we want content
8185			if ( extra === "content" ) {
8186				val -= jQuery.css( elem, "padding" + cssExpand[ i ], true, styles );
8187			}
8188
8189			// At this point, extra isn't border nor margin, so remove border
8190			if ( extra !== "margin" ) {
8191				val -= jQuery.css( elem, "border" + cssExpand[ i ] + "Width", true, styles );
8192			}
8193		} else {
8194
8195			// At this point, extra isn't content, so add padding
8196			val += jQuery.css( elem, "padding" + cssExpand[ i ], true, styles );
8197
8198			// At this point, extra isn't content nor padding, so add border
8199			if ( extra !== "padding" ) {
8200				val += jQuery.css( elem, "border" + cssExpand[ i ] + "Width", true, styles );
8201			}
8202		}
8203	}
8204
8205	return val;
8206}
8207
8208function getWidthOrHeight( elem, name, extra ) {
8209
8210	// Start with offset property, which is equivalent to the border-box value
8211	var valueIsBorderBox = true,
8212		val = name === "width" ? elem.offsetWidth : elem.offsetHeight,
8213		styles = getStyles( elem ),
8214		isBorderBox = jQuery.css( elem, "boxSizing", false, styles ) === "border-box";
8215
8216	// Some non-html elements return undefined for offsetWidth, so check for null/undefined
8217	// svg - https://bugzilla.mozilla.org/show_bug.cgi?id=649285
8218	// MathML - https://bugzilla.mozilla.org/show_bug.cgi?id=491668
8219	if ( val <= 0 || val == null ) {
8220
8221		// Fall back to computed then uncomputed css if necessary
8222		val = curCSS( elem, name, styles );
8223		if ( val < 0 || val == null ) {
8224			val = elem.style[ name ];
8225		}
8226
8227		// Computed unit is not pixels. Stop here and return.
8228		if ( rnumnonpx.test( val ) ) {
8229			return val;
8230		}
8231
8232		// Check for style in case a browser which returns unreliable values
8233		// for getComputedStyle silently falls back to the reliable elem.style
8234		valueIsBorderBox = isBorderBox &&
8235			( support.boxSizingReliable() || val === elem.style[ name ] );
8236
8237		// Normalize "", auto, and prepare for extra
8238		val = parseFloat( val ) || 0;
8239	}
8240
8241	// Use the active box-sizing model to add/subtract irrelevant styles
8242	return ( val +
8243		augmentWidthOrHeight(
8244			elem,
8245			name,
8246			extra || ( isBorderBox ? "border" : "content" ),
8247			valueIsBorderBox,
8248			styles
8249		)
8250	) + "px";
8251}
8252
8253function showHide( elements, show ) {
8254	var display, elem, hidden,
8255		values = [],
8256		index = 0,
8257		length = elements.length;
8258
8259	for ( ; index < length; index++ ) {
8260		elem = elements[ index ];
8261		if ( !elem.style ) {
8262			continue;
8263		}
8264
8265		values[ index ] = dataPriv.get( elem, "olddisplay" );
8266		display = elem.style.display;
8267		if ( show ) {
8268
8269			// Reset the inline display of this element to learn if it is
8270			// being hidden by cascaded rules or not
8271			if ( !values[ index ] && display === "none" ) {
8272				elem.style.display = "";
8273			}
8274
8275			// Set elements which have been overridden with display: none
8276			// in a stylesheet to whatever the default browser style is
8277			// for such an element
8278			if ( elem.style.display === "" && isHidden( elem ) ) {
8279				values[ index ] = dataPriv.access(
8280					elem,
8281					"olddisplay",
8282					defaultDisplay( elem.nodeName )
8283				);
8284			}
8285		} else {
8286			hidden = isHidden( elem );
8287
8288			if ( display !== "none" || !hidden ) {
8289				dataPriv.set(
8290					elem,
8291					"olddisplay",
vendor: 7,760 bytes, lines 8292-8596
8292					hidden ? display : jQuery.css( elem, "display" )
8293				);
8294			}
8295		}
8296	}
8297
8298	// Set the display of most of the elements in a second loop
8299	// to avoid the constant reflow
8300	for ( index = 0; index < length; index++ ) {
8301		elem = elements[ index ];
8302		if ( !elem.style ) {
8303			continue;
8304		}
8305		if ( !show || elem.style.display === "none" || elem.style.display === "" ) {
8306			elem.style.display = show ? values[ index ] || "" : "none";
8307		}
8308	}
8309
8310	return elements;
8311}
8312
8313jQuery.extend( {
8314
8315	// Add in style property hooks for overriding the default
8316	// behavior of getting and setting a style property
8317	cssHooks: {
8318		opacity: {
8319			get: function( elem, computed ) {
8320				if ( computed ) {
8321
8322					// We should always get a number back from opacity
8323					var ret = curCSS( elem, "opacity" );
8324					return ret === "" ? "1" : ret;
8325				}
8326			}
8327		}
8328	},
8329
8330	// Don't automatically add "px" to these possibly-unitless properties
8331	cssNumber: {
8332		"animationIterationCount": true,
8333		"columnCount": true,
8334		"fillOpacity": true,
8335		"flexGrow": true,
8336		"flexShrink": true,
8337		"fontWeight": true,
8338		"lineHeight": true,
8339		"opacity": true,
8340		"order": true,
8341		"orphans": true,
8342		"widows": true,
8343		"zIndex": true,
8344		"zoom": true
8345	},
8346
8347	// Add in properties whose names you wish to fix before
8348	// setting or getting the value
8349	cssProps: {
8350		"float": "cssFloat"
8351	},
8352
8353	// Get and set the style property on a DOM Node
8354	style: function( elem, name, value, extra ) {
8355
8356		// Don't set styles on text and comment nodes
8357		if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 || !elem.style ) {
8358			return;
8359		}
8360
8361		// Make sure that we're working with the right name
8362		var ret, type, hooks,
8363			origName = jQuery.camelCase( name ),
8364			style = elem.style;
8365
8366		name = jQuery.cssProps[ origName ] ||
8367			( jQuery.cssProps[ origName ] = vendorPropName( origName ) || origName );
8368
8369		// Gets hook for the prefixed version, then unprefixed version
8370		hooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];
8371
8372		// Check if we're setting a value
8373		if ( value !== undefined ) {
8374			type = typeof value;
8375
8376			// Convert "+=" or "-=" to relative numbers (#7345)
8377			if ( type === "string" && ( ret = rcssNum.exec( value ) ) && ret[ 1 ] ) {
8378				value = adjustCSS( elem, name, ret );
8379
8380				// Fixes bug #9237
8381				type = "number";
8382			}
8383
8384			// Make sure that null and NaN values aren't set (#7116)
8385			if ( value == null || value !== value ) {
8386				return;
8387			}
8388
8389			// If a number was passed in, add the unit (except for certain CSS properties)
8390			if ( type === "number" ) {
8391				value += ret && ret[ 3 ] || ( jQuery.cssNumber[ origName ] ? "" : "px" );
8392			}
8393
8394			// Support: IE9-11+
8395			// background-* props affect original clone's values
8396			if ( !support.clearCloneStyle && value === "" && name.indexOf( "background" ) === 0 ) {
8397				style[ name ] = "inherit";
8398			}
8399
8400			// If a hook was provided, use that value, otherwise just set the specified value
8401			if ( !hooks || !( "set" in hooks ) ||
8402				( value = hooks.set( elem, value, extra ) ) !== undefined ) {
8403
8404				style[ name ] = value;
8405			}
8406
8407		} else {
8408
8409			// If a hook was provided get the non-computed value from there
8410			if ( hooks && "get" in hooks &&
8411				( ret = hooks.get( elem, false, extra ) ) !== undefined ) {
8412
8413				return ret;
8414			}
8415
8416			// Otherwise just get the value from the style object
8417			return style[ name ];
8418		}
8419	},
8420
8421	css: function( elem, name, extra, styles ) {
8422		var val, num, hooks,
8423			origName = jQuery.camelCase( name );
8424
8425		// Make sure that we're working with the right name
8426		name = jQuery.cssProps[ origName ] ||
8427			( jQuery.cssProps[ origName ] = vendorPropName( origName ) || origName );
8428
8429		// Try prefixed name followed by the unprefixed name
8430		hooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];
8431
8432		// If a hook was provided get the computed value from there
8433		if ( hooks && "get" in hooks ) {
8434			val = hooks.get( elem, true, extra );
8435		}
8436
8437		// Otherwise, if a way to get the computed value exists, use that
8438		if ( val === undefined ) {
8439			val = curCSS( elem, name, styles );
8440		}
8441
8442		// Convert "normal" to computed value
8443		if ( val === "normal" && name in cssNormalTransform ) {
8444			val = cssNormalTransform[ name ];
8445		}
8446
8447		// Make numeric if forced or a qualifier was provided and val looks numeric
8448		if ( extra === "" || extra ) {
8449			num = parseFloat( val );
8450			return extra === true || isFinite( num ) ? num || 0 : val;
8451		}
8452		return val;
8453	}
8454} );
8455
8456jQuery.each( [ "height", "width" ], function( i, name ) {
8457	jQuery.cssHooks[ name ] = {
8458		get: function( elem, computed, extra ) {
8459			if ( computed ) {
8460
8461				// Certain elements can have dimension info if we invisibly show them
8462				// but it must have a current display style that would benefit
8463				return rdisplayswap.test( jQuery.css( elem, "display" ) ) &&
8464					elem.offsetWidth === 0 ?
8465						swap( elem, cssShow, function() {
8466							return getWidthOrHeight( elem, name, extra );
8467						} ) :
8468						getWidthOrHeight( elem, name, extra );
8469			}
8470		},
8471
8472		set: function( elem, value, extra ) {
8473			var matches,
8474				styles = extra && getStyles( elem ),
8475				subtract = extra && augmentWidthOrHeight(
8476					elem,
8477					name,
8478					extra,
8479					jQuery.css( elem, "boxSizing", false, styles ) === "border-box",
8480					styles
8481				);
8482
8483			// Convert to pixels if value adjustment is needed
8484			if ( subtract && ( matches = rcssNum.exec( value ) ) &&
8485				( matches[ 3 ] || "px" ) !== "px" ) {
8486
8487				elem.style[ name ] = value;
8488				value = jQuery.css( elem, name );
8489			}
8490
8491			return setPositiveNumber( elem, value, subtract );
8492		}
8493	};
8494} );
8495
8496jQuery.cssHooks.marginLeft = addGetHookIf( support.reliableMarginLeft,
8497	function( elem, computed ) {
8498		if ( computed ) {
8499			return ( parseFloat( curCSS( elem, "marginLeft" ) ) ||
8500				elem.getBoundingClientRect().left -
8501					swap( elem, { marginLeft: 0 }, function() {
8502						return elem.getBoundingClientRect().left;
8503					} )
8504				) + "px";
8505		}
8506	}
8507);
8508
8509// Support: Android 2.3
8510jQuery.cssHooks.marginRight = addGetHookIf( support.reliableMarginRight,
8511	function( elem, computed ) {
8512		if ( computed ) {
8513			return swap( elem, { "display": "inline-block" },
8514				curCSS, [ elem, "marginRight" ] );
8515		}
8516	}
8517);
8518
8519// These hooks are used by animate to expand properties
8520jQuery.each( {
8521	margin: "",
8522	padding: "",
8523	border: "Width"
8524}, function( prefix, suffix ) {
8525	jQuery.cssHooks[ prefix + suffix ] = {
8526		expand: function( value ) {
8527			var i = 0,
8528				expanded = {},
8529
8530				// Assumes a single number if not a string
8531				parts = typeof value === "string" ? value.split( " " ) : [ value ];
8532
8533			for ( ; i < 4; i++ ) {
8534				expanded[ prefix + cssExpand[ i ] + suffix ] =
8535					parts[ i ] || parts[ i - 2 ] || parts[ 0 ];
8536			}
8537
8538			return expanded;
8539		}
8540	};
8541
8542	if ( !rmargin.test( prefix ) ) {
8543		jQuery.cssHooks[ prefix + suffix ].set = setPositiveNumber;
8544	}
8545} );
8546
8547jQuery.fn.extend( {
8548	css: function( name, value ) {
8549		return access( this, function( elem, name, value ) {
8550			var styles, len,
8551				map = {},
8552				i = 0;
8553
8554			if ( jQuery.isArray( name ) ) {
8555				styles = getStyles( elem );
8556				len = name.length;
8557
8558				for ( ; i < len; i++ ) {
8559					map[ name[ i ] ] = jQuery.css( elem, name[ i ], false, styles );
8560				}
8561
8562				return map;
8563			}
8564
8565			return value !== undefined ?
8566				jQuery.style( elem, name, value ) :
8567				jQuery.css( elem, name );
8568		}, name, value, arguments.length > 1 );
8569	},
8570	show: function() {
8571		return showHide( this, true );
8572	},
8573	hide: function() {
8574		return showHide( this );
8575	},
8576	toggle: function( state ) {
8577		if ( typeof state === "boolean" ) {
8578			return state ? this.show() : this.hide();
8579		}
8580
8581		return this.each( function() {
8582			if ( isHidden( this ) ) {
8583				jQuery( this ).show();
8584			} else {
8585				jQuery( this ).hide();
8586			}
8587		} );
8588	}
8589} );
8590
8591
8592function Tween( elem, options, prop, end, easing ) {
8593	return new Tween.prototype.init( elem, options, prop, end, easing );
8594}
8595jQuery.Tween = Tween;
8596
vendor: 5,170 bytes, lines 8597-8796
8597Tween.prototype = {
8598	constructor: Tween,
8599	init: function( elem, options, prop, end, easing, unit ) {
8600		this.elem = elem;
8601		this.prop = prop;
8602		this.easing = easing || jQuery.easing._default;
8603		this.options = options;
8604		this.start = this.now = this.cur();
8605		this.end = end;
8606		this.unit = unit || ( jQuery.cssNumber[ prop ] ? "" : "px" );
8607	},
8608	cur: function() {
8609		var hooks = Tween.propHooks[ this.prop ];
8610
8611		return hooks && hooks.get ?
8612			hooks.get( this ) :
8613			Tween.propHooks._default.get( this );
8614	},
8615	run: function( percent ) {
8616		var eased,
8617			hooks = Tween.propHooks[ this.prop ];
8618
8619		if ( this.options.duration ) {
8620			this.pos = eased = jQuery.easing[ this.easing ](
8621				percent, this.options.duration * percent, 0, 1, this.options.duration
8622			);
8623		} else {
8624			this.pos = eased = percent;
8625		}
8626		this.now = ( this.end - this.start ) * eased + this.start;
8627
8628		if ( this.options.step ) {
8629			this.options.step.call( this.elem, this.now, this );
8630		}
8631
8632		if ( hooks && hooks.set ) {
8633			hooks.set( this );
8634		} else {
8635			Tween.propHooks._default.set( this );
8636		}
8637		return this;
8638	}
8639};
8640
8641Tween.prototype.init.prototype = Tween.prototype;
8642
8643Tween.propHooks = {
8644	_default: {
8645		get: function( tween ) {
8646			var result;
8647
8648			// Use a property on the element directly when it is not a DOM element,
8649			// or when there is no matching style property that exists.
8650			if ( tween.elem.nodeType !== 1 ||
8651				tween.elem[ tween.prop ] != null && tween.elem.style[ tween.prop ] == null ) {
8652				return tween.elem[ tween.prop ];
8653			}
8654
8655			// Passing an empty string as a 3rd parameter to .css will automatically
8656			// attempt a parseFloat and fallback to a string if the parse fails.
8657			// Simple values such as "10px" are parsed to Float;
8658			// complex values such as "rotate(1rad)" are returned as-is.
8659			result = jQuery.css( tween.elem, tween.prop, "" );
8660
8661			// Empty strings, null, undefined and "auto" are converted to 0.
8662			return !result || result === "auto" ? 0 : result;
8663		},
8664		set: function( tween ) {
8665
8666			// Use step hook for back compat.
8667			// Use cssHook if its there.
8668			// Use .style if available and use plain properties where available.
8669			if ( jQuery.fx.step[ tween.prop ] ) {
8670				jQuery.fx.step[ tween.prop ]( tween );
8671			} else if ( tween.elem.nodeType === 1 &&
8672				( tween.elem.style[ jQuery.cssProps[ tween.prop ] ] != null ||
8673					jQuery.cssHooks[ tween.prop ] ) ) {
8674				jQuery.style( tween.elem, tween.prop, tween.now + tween.unit );
8675			} else {
8676				tween.elem[ tween.prop ] = tween.now;
8677			}
8678		}
8679	}
8680};
8681
8682// Support: IE9
8683// Panic based approach to setting things on disconnected nodes
8684Tween.propHooks.scrollTop = Tween.propHooks.scrollLeft = {
8685	set: function( tween ) {
8686		if ( tween.elem.nodeType && tween.elem.parentNode ) {
8687			tween.elem[ tween.prop ] = tween.now;
8688		}
8689	}
8690};
8691
8692jQuery.easing = {
8693	linear: function( p ) {
8694		return p;
8695	},
8696	swing: function( p ) {
8697		return 0.5 - Math.cos( p * Math.PI ) / 2;
8698	},
8699	_default: "swing"
8700};
8701
8702jQuery.fx = Tween.prototype.init;
8703
8704// Back Compat <1.8 extension point
8705jQuery.fx.step = {};
8706
8707
8708
8709
8710var
8711	fxNow, timerId,
8712	rfxtypes = /^(?:toggle|show|hide)$/,
8713	rrun = /queueHooks$/;
8714
8715// Animations created synchronously will run synchronously
8716function createFxNow() {
8717	window.setTimeout( function() {
8718		fxNow = undefined;
8719	} );
8720	return ( fxNow = jQuery.now() );
8721}
8722
8723// Generate parameters to create a standard animation
8724function genFx( type, includeWidth ) {
8725	var which,
8726		i = 0,
8727		attrs = { height: type };
8728
8729	// If we include width, step value is 1 to do all cssExpand values,
8730	// otherwise step value is 2 to skip over Left and Right
8731	includeWidth = includeWidth ? 1 : 0;
8732	for ( ; i < 4 ; i += 2 - includeWidth ) {
8733		which = cssExpand[ i ];
8734		attrs[ "margin" + which ] = attrs[ "padding" + which ] = type;
8735	}
8736
8737	if ( includeWidth ) {
8738		attrs.opacity = attrs.width = type;
8739	}
8740
8741	return attrs;
8742}
8743
8744function createTween( value, prop, animation ) {
8745	var tween,
8746		collection = ( Animation.tweeners[ prop ] || [] ).concat( Animation.tweeners[ "*" ] ),
8747		index = 0,
8748		length = collection.length;
8749	for ( ; index < length; index++ ) {
8750		if ( ( tween = collection[ index ].call( animation, prop, value ) ) ) {
8751
8752			// We're done with this property
8753			return tween;
8754		}
8755	}
8756}
8757
8758function defaultPrefilter( elem, props, opts ) {
8759	/* jshint validthis: true */
8760	var prop, value, toggle, tween, hooks, oldfire, display, checkDisplay,
8761		anim = this,
8762		orig = {},
8763		style = elem.style,
8764		hidden = elem.nodeType && isHidden( elem ),
8765		dataShow = dataPriv.get( elem, "fxshow" );
8766
8767	// Handle queue: false promises
8768	if ( !opts.queue ) {
8769		hooks = jQuery._queueHooks( elem, "fx" );
8770		if ( hooks.unqueued == null ) {
8771			hooks.unqueued = 0;
8772			oldfire = hooks.empty.fire;
8773			hooks.empty.fire = function() {
8774				if ( !hooks.unqueued ) {
8775					oldfire();
8776				}
8777			};
8778		}
8779		hooks.unqueued++;
8780
8781		anim.always( function() {
8782
8783			// Ensure the complete handler is called before this completes
8784			anim.always( function() {
8785				hooks.unqueued--;
8786				if ( !jQuery.queue( elem, "fx" ).length ) {
8787					hooks.empty.fire();
8788				}
8789			} );
8790		} );
8791	}
8792
8793	// Height/width overflow pass
8794	if ( elem.nodeType === 1 && ( "height" in props || "width" in props ) ) {
8795
8796		// Make sure that nothing sneaks out
8797		// Record all 3 overflow attributes because IE9-10 do not
8798		// change the overflow attribute when overflowX and
8799		// overflowY are set to the same value
8800		opts.overflow = [ style.overflow, style.overflowX, style.overflowY ];
8801
8802		// Set display property to inline-block for height/width
8803		// animations on inline elements that are having width/height animated
8804		display = jQuery.css( elem, "display" );
8805
8806		// Test default display if display is currently "none"
8807		checkDisplay = display === "none" ?
8808			dataPriv.get( elem, "olddisplay" ) || defaultDisplay( elem.nodeName ) : display;
8809
8810		if ( checkDisplay === "inline" && jQuery.css( elem, "float" ) === "none" ) {
8811			style.display = "inline-block";
8812		}
8813	}
8814
8815	if ( opts.overflow ) {
8816		style.overflow = "hidden";
8817		anim.always( function() {
8818			style.overflow = opts.overflow[ 0 ];
8819			style.overflowX = opts.overflow[ 1 ];
8820			style.overflowY = opts.overflow[ 2 ];
8821		} );
8822	}
8823
8824	// show/hide pass
8825	for ( prop in props ) {
8826		value = props[ prop ];
8827		if ( rfxtypes.exec( value ) ) {
8828			delete props[ prop ];
8829			toggle = toggle || value === "toggle";
8830			if ( value === ( hidden ? "hide" : "show" ) ) {
8831
8832				// If there is dataShow left over from a stopped hide or show
8833				// and we are going to proceed with show, we should pretend to be hidden
8834				if ( value === "show" && dataShow && dataShow[ prop ] !== undefined ) {
8835					hidden = true;
8836				} else {
8837					continue;
8838				}
8839			}
8840			orig[ prop ] = dataShow && dataShow[ prop ] || jQuery.style( elem, prop );
8841
8842		// Any non-fx value stops us from restoring the original display value
8843		} else {
8844			display = undefined;
8845		}
8846	}
8847
8848	if ( !jQuery.isEmptyObject( orig ) ) {
8849		if ( dataShow ) {
8850			if ( "hidden" in dataShow ) {
8851				hidden = dataShow.hidden;
8852			}
8853		} else {
8854			dataShow = dataPriv.access( elem, "fxshow", {} );
8855		}
8856
8857		// Store state if its toggle - enables .stop().toggle() to "reverse"
8858		if ( toggle ) {
8859			dataShow.hidden = !hidden;
8860		}
8861		if ( hidden ) {
8862			jQuery( elem ).show();
8863		} else {
8864			anim.done( function() {
8865				jQuery( elem ).hide();
8866			} );
8867		}
8868		anim.done( function() {
8869			var prop;
8870
8871			dataPriv.remove( elem, "fxshow" );
8872			for ( prop in orig ) {
8873				jQuery.style( elem, prop, orig[ prop ] );
8874			}
8875		} );
8876		for ( prop in orig ) {
8877			tween = createTween( hidden ? dataShow[ prop ] : 0, prop, anim );
8878
8879			if ( !( prop in dataShow ) ) {
8880				dataShow[ prop ] = tween.start;
8881				if ( hidden ) {
8882					tween.end = tween.start;
8883					tween.start = prop === "width" || prop === "height" ? 1 : 0;
8884				}
8885			}
8886		}
8887
8888	// If this is a noop like .hide().hide(), restore an overwritten display value
8889	} else if ( ( display === "none" ? defaultDisplay( elem.nodeName ) : display ) === "inline" ) {
8890		style.display = display;
8891	}
8892}
8893
8894function propFilter( props, specialEasing ) {
8895	var index, name, easing, value, hooks;
8896
8897	// camelCase, specialEasing and expand cssHook pass
8898	for ( index in props ) {
8899		name = jQuery.camelCase( index );
8900		easing = specialEasing[ name ];
8901		value = props[ index ];
8902		if ( jQuery.isArray( value ) ) {
8903			easing = value[ 1 ];
8904			value = props[ index ] = value[ 0 ];
8905		}
8906
8907		if ( index !== name ) {
8908			props[ name ] = value;
8909			delete props[ index ];
8910		}
8911
8912		hooks = jQuery.cssHooks[ name ];
8913		if ( hooks && "expand" in hooks ) {
8914			value = hooks.expand( value );
8915			delete props[ name ];
8916
8917			// Not quite $.extend, this won't overwrite existing keys.
8918			// Reusing 'index' because we have the correct "name"
8919			for ( index in value ) {
8920				if ( !( index in props ) ) {
8921					props[ index ] = value[ index ];
8922					specialEasing[ index ] = easing;
8923				}
8924			}
8925		} else {
8926			specialEasing[ name ] = easing;
8927		}
8928	}
8929}
8930
8931function Animation( elem, properties, options ) {
8932	var result,
8933		stopped,
8934		index = 0,
8935		length = Animation.prefilters.length,
8936		deferred = jQuery.Deferred().always( function() {
8937
8938			// Don't match elem in the :animated selector
8939			delete tick.elem;
8940		} ),
8941		tick = function() {
8942			if ( stopped ) {
8943				return false;
8944			}
8945			var currentTime = fxNow || createFxNow(),
8946				remaining = Math.max( 0, animation.startTime + animation.duration - currentTime ),
8947
vendor: 9,405 bytes, lines 8948-9319
8948				// Support: Android 2.3
8949				// Archaic crash bug won't allow us to use `1 - ( 0.5 || 0 )` (#12497)
8950				temp = remaining / animation.duration || 0,
8951				percent = 1 - temp,
8952				index = 0,
8953				length = animation.tweens.length;
8954
8955			for ( ; index < length ; index++ ) {
8956				animation.tweens[ index ].run( percent );
8957			}
8958
8959			deferred.notifyWith( elem, [ animation, percent, remaining ] );
8960
8961			if ( percent < 1 && length ) {
8962				return remaining;
8963			} else {
8964				deferred.resolveWith( elem, [ animation ] );
8965				return false;
8966			}
8967		},
8968		animation = deferred.promise( {
8969			elem: elem,
8970			props: jQuery.extend( {}, properties ),
8971			opts: jQuery.extend( true, {
8972				specialEasing: {},
8973				easing: jQuery.easing._default
8974			}, options ),
8975			originalProperties: properties,
8976			originalOptions: options,
8977			startTime: fxNow || createFxNow(),
8978			duration: options.duration,
8979			tweens: [],
8980			createTween: function( prop, end ) {
8981				var tween = jQuery.Tween( elem, animation.opts, prop, end,
8982						animation.opts.specialEasing[ prop ] || animation.opts.easing );
8983				animation.tweens.push( tween );
8984				return tween;
8985			},
8986			stop: function( gotoEnd ) {
8987				var index = 0,
8988
8989					// If we are going to the end, we want to run all the tweens
8990					// otherwise we skip this part
8991					length = gotoEnd ? animation.tweens.length : 0;
8992				if ( stopped ) {
8993					return this;
8994				}
8995				stopped = true;
8996				for ( ; index < length ; index++ ) {
8997					animation.tweens[ index ].run( 1 );
8998				}
8999
9000				// Resolve when we played the last frame; otherwise, reject
9001				if ( gotoEnd ) {
9002					deferred.notifyWith( elem, [ animation, 1, 0 ] );
9003					deferred.resolveWith( elem, [ animation, gotoEnd ] );
9004				} else {
9005					deferred.rejectWith( elem, [ animation, gotoEnd ] );
9006				}
9007				return this;
9008			}
9009		} ),
9010		props = animation.props;
9011
9012	propFilter( props, animation.opts.specialEasing );
9013
9014	for ( ; index < length ; index++ ) {
9015		result = Animation.prefilters[ index ].call( animation, elem, props, animation.opts );
9016		if ( result ) {
9017			if ( jQuery.isFunction( result.stop ) ) {
9018				jQuery._queueHooks( animation.elem, animation.opts.queue ).stop =
9019					jQuery.proxy( result.stop, result );
9020			}
9021			return result;
9022		}
9023	}
9024
9025	jQuery.map( props, createTween, animation );
9026
9027	if ( jQuery.isFunction( animation.opts.start ) ) {
9028		animation.opts.start.call( elem, animation );
9029	}
9030
9031	jQuery.fx.timer(
9032		jQuery.extend( tick, {
9033			elem: elem,
9034			anim: animation,
9035			queue: animation.opts.queue
9036		} )
9037	);
9038
9039	// attach callbacks from options
9040	return animation.progress( animation.opts.progress )
9041		.done( animation.opts.done, animation.opts.complete )
9042		.fail( animation.opts.fail )
9043		.always( animation.opts.always );
9044}
9045
9046jQuery.Animation = jQuery.extend( Animation, {
9047	tweeners: {
9048		"*": [ function( prop, value ) {
9049			var tween = this.createTween( prop, value );
9050			adjustCSS( tween.elem, prop, rcssNum.exec( value ), tween );
9051			return tween;
9052		} ]
9053	},
9054
9055	tweener: function( props, callback ) {
9056		if ( jQuery.isFunction( props ) ) {
9057			callback = props;
9058			props = [ "*" ];
9059		} else {
9060			props = props.match( rnotwhite );
9061		}
9062
9063		var prop,
9064			index = 0,
9065			length = props.length;
9066
9067		for ( ; index < length ; index++ ) {
9068			prop = props[ index ];
9069			Animation.tweeners[ prop ] = Animation.tweeners[ prop ] || [];
9070			Animation.tweeners[ prop ].unshift( callback );
9071		}
9072	},
9073
9074	prefilters: [ defaultPrefilter ],
9075
9076	prefilter: function( callback, prepend ) {
9077		if ( prepend ) {
9078			Animation.prefilters.unshift( callback );
9079		} else {
9080			Animation.prefilters.push( callback );
9081		}
9082	}
9083} );
9084
9085jQuery.speed = function( speed, easing, fn ) {
9086	var opt = speed && typeof speed === "object" ? jQuery.extend( {}, speed ) : {
9087		complete: fn || !fn && easing ||
9088			jQuery.isFunction( speed ) && speed,
9089		duration: speed,
9090		easing: fn && easing || easing && !jQuery.isFunction( easing ) && easing
9091	};
9092
9093	opt.duration = jQuery.fx.off ? 0 : typeof opt.duration === "number" ?
9094		opt.duration : opt.duration in jQuery.fx.speeds ?
9095			jQuery.fx.speeds[ opt.duration ] : jQuery.fx.speeds._default;
9096
9097	// Normalize opt.queue - true/undefined/null -> "fx"
9098	if ( opt.queue == null || opt.queue === true ) {
9099		opt.queue = "fx";
9100	}
9101
9102	// Queueing
9103	opt.old = opt.complete;
9104
9105	opt.complete = function() {
9106		if ( jQuery.isFunction( opt.old ) ) {
9107			opt.old.call( this );
9108		}
9109
9110		if ( opt.queue ) {
9111			jQuery.dequeue( this, opt.queue );
9112		}
9113	};
9114
9115	return opt;
9116};
9117
9118jQuery.fn.extend( {
9119	fadeTo: function( speed, to, easing, callback ) {
9120
9121		// Show any hidden elements after setting opacity to 0
9122		return this.filter( isHidden ).css( "opacity", 0 ).show()
9123
9124			// Animate to the value specified
9125			.end().animate( { opacity: to }, speed, easing, callback );
9126	},
9127	animate: function( prop, speed, easing, callback ) {
9128		var empty = jQuery.isEmptyObject( prop ),
9129			optall = jQuery.speed( speed, easing, callback ),
9130			doAnimation = function() {
9131
9132				// Operate on a copy of prop so per-property easing won't be lost
9133				var anim = Animation( this, jQuery.extend( {}, prop ), optall );
9134
9135				// Empty animations, or finishing resolves immediately
9136				if ( empty || dataPriv.get( this, "finish" ) ) {
9137					anim.stop( true );
9138				}
9139			};
9140			doAnimation.finish = doAnimation;
9141
9142		return empty || optall.queue === false ?
9143			this.each( doAnimation ) :
9144			this.queue( optall.queue, doAnimation );
9145	},
9146	stop: function( type, clearQueue, gotoEnd ) {
9147		var stopQueue = function( hooks ) {
9148			var stop = hooks.stop;
9149			delete hooks.stop;
9150			stop( gotoEnd );
9151		};
9152
9153		if ( typeof type !== "string" ) {
9154			gotoEnd = clearQueue;
9155			clearQueue = type;
9156			type = undefined;
9157		}
9158		if ( clearQueue && type !== false ) {
9159			this.queue( type || "fx", [] );
9160		}
9161
9162		return this.each( function() {
9163			var dequeue = true,
9164				index = type != null && type + "queueHooks",
9165				timers = jQuery.timers,
9166				data = dataPriv.get( this );
9167
9168			if ( index ) {
9169				if ( data[ index ] && data[ index ].stop ) {
9170					stopQueue( data[ index ] );
9171				}
9172			} else {
9173				for ( index in data ) {
9174					if ( data[ index ] && data[ index ].stop && rrun.test( index ) ) {
9175						stopQueue( data[ index ] );
9176					}
9177				}
9178			}
9179
9180			for ( index = timers.length; index--; ) {
9181				if ( timers[ index ].elem === this &&
9182					( type == null || timers[ index ].queue === type ) ) {
9183
9184					timers[ index ].anim.stop( gotoEnd );
9185					dequeue = false;
9186					timers.splice( index, 1 );
9187				}
9188			}
9189
9190			// Start the next in the queue if the last step wasn't forced.
9191			// Timers currently will call their complete callbacks, which
9192			// will dequeue but only if they were gotoEnd.
9193			if ( dequeue || !gotoEnd ) {
9194				jQuery.dequeue( this, type );
9195			}
9196		} );
9197	},
9198	finish: function( type ) {
9199		if ( type !== false ) {
9200			type = type || "fx";
9201		}
9202		return this.each( function() {
9203			var index,
9204				data = dataPriv.get( this ),
9205				queue = data[ type + "queue" ],
9206				hooks = data[ type + "queueHooks" ],
9207				timers = jQuery.timers,
9208				length = queue ? queue.length : 0;
9209
9210			// Enable finishing flag on private data
9211			data.finish = true;
9212
9213			// Empty the queue first
9214			jQuery.queue( this, type, [] );
9215
9216			if ( hooks && hooks.stop ) {
9217				hooks.stop.call( this, true );
9218			}
9219
9220			// Look for any active animations, and finish them
9221			for ( index = timers.length; index--; ) {
9222				if ( timers[ index ].elem === this && timers[ index ].queue === type ) {
9223					timers[ index ].anim.stop( true );
9224					timers.splice( index, 1 );
9225				}
9226			}
9227
9228			// Look for any animations in the old queue and finish them
9229			for ( index = 0; index < length; index++ ) {
9230				if ( queue[ index ] && queue[ index ].finish ) {
9231					queue[ index ].finish.call( this );
9232				}
9233			}
9234
9235			// Turn off finishing flag
9236			delete data.finish;
9237		} );
9238	}
9239} );
9240
9241jQuery.each( [ "toggle", "show", "hide" ], function( i, name ) {
9242	var cssFn = jQuery.fn[ name ];
9243	jQuery.fn[ name ] = function( speed, easing, callback ) {
9244		return speed == null || typeof speed === "boolean" ?
9245			cssFn.apply( this, arguments ) :
9246			this.animate( genFx( name, true ), speed, easing, callback );
9247	};
9248} );
9249
9250// Generate shortcuts for custom animations
9251jQuery.each( {
9252	slideDown: genFx( "show" ),
9253	slideUp: genFx( "hide" ),
9254	slideToggle: genFx( "toggle" ),
9255	fadeIn: { opacity: "show" },
9256	fadeOut: { opacity: "hide" },
9257	fadeToggle: { opacity: "toggle" }
9258}, function( name, props ) {
9259	jQuery.fn[ name ] = function( speed, easing, callback ) {
9260		return this.animate( props, speed, easing, callback );
9261	};
9262} );
9263
9264jQuery.timers = [];
9265jQuery.fx.tick = function() {
9266	var timer,
9267		i = 0,
9268		timers = jQuery.timers;
9269
9270	fxNow = jQuery.now();
9271
9272	for ( ; i < timers.length; i++ ) {
9273		timer = timers[ i ];
9274
9275		// Checks the timer has not already been removed
9276		if ( !timer() && timers[ i ] === timer ) {
9277			timers.splice( i--, 1 );
9278		}
9279	}
9280
9281	if ( !timers.length ) {
9282		jQuery.fx.stop();
9283	}
9284	fxNow = undefined;
9285};
9286
9287jQuery.fx.timer = function( timer ) {
9288	jQuery.timers.push( timer );
9289	if ( timer() ) {
9290		jQuery.fx.start();
9291	} else {
9292		jQuery.timers.pop();
9293	}
9294};
9295
9296jQuery.fx.interval = 13;
9297jQuery.fx.start = function() {
9298	if ( !timerId ) {
9299		timerId = window.setInterval( jQuery.fx.tick, jQuery.fx.interval );
9300	}
9301};
9302
9303jQuery.fx.stop = function() {
9304	window.clearInterval( timerId );
9305
9306	timerId = null;
9307};
9308
9309jQuery.fx.speeds = {
9310	slow: 600,
9311	fast: 200,
9312
9313	// Default speed
9314	_default: 400
9315};
9316
9317
9318// Based off of the plugin by Clint Helfers, with permission.
9319// http://web.archive.org/web/20100324014747/http://blindsignals.com/index.php/2009/07/jquery-delay/
vendor: 20,418 bytes, lines 9320-10164
9320jQuery.fn.delay = function( time, type ) {
9321	time = jQuery.fx ? jQuery.fx.speeds[ time ] || time : time;
9322	type = type || "fx";
9323
9324	return this.queue( type, function( next, hooks ) {
9325		var timeout = window.setTimeout( next, time );
9326		hooks.stop = function() {
9327			window.clearTimeout( timeout );
9328		};
9329	} );
9330};
9331
9332
9333( function() {
9334	var input = document.createElement( "input" ),
9335		select = document.createElement( "select" ),
9336		opt = select.appendChild( document.createElement( "option" ) );
9337
9338	input.type = "checkbox";
9339
9340	// Support: iOS<=5.1, Android<=4.2+
9341	// Default value for a checkbox should be "on"
9342	support.checkOn = input.value !== "";
9343
9344	// Support: IE<=11+
9345	// Must access selectedIndex to make default options select
9346	support.optSelected = opt.selected;
9347
9348	// Support: Android<=2.3
9349	// Options inside disabled selects are incorrectly marked as disabled
9350	select.disabled = true;
9351	support.optDisabled = !opt.disabled;
9352
9353	// Support: IE<=11+
9354	// An input loses its value after becoming a radio
9355	input = document.createElement( "input" );
9356	input.value = "t";
9357	input.type = "radio";
9358	support.radioValue = input.value === "t";
9359} )();
9360
9361
9362var boolHook,
9363	attrHandle = jQuery.expr.attrHandle;
9364
9365jQuery.fn.extend( {
9366	attr: function( name, value ) {
9367		return access( this, jQuery.attr, name, value, arguments.length > 1 );
9368	},
9369
9370	removeAttr: function( name ) {
9371		return this.each( function() {
9372			jQuery.removeAttr( this, name );
9373		} );
9374	}
9375} );
9376
9377jQuery.extend( {
9378	attr: function( elem, name, value ) {
9379		var ret, hooks,
9380			nType = elem.nodeType;
9381
9382		// Don't get/set attributes on text, comment and attribute nodes
9383		if ( nType === 3 || nType === 8 || nType === 2 ) {
9384			return;
9385		}
9386
9387		// Fallback to prop when attributes are not supported
9388		if ( typeof elem.getAttribute === "undefined" ) {
9389			return jQuery.prop( elem, name, value );
9390		}
9391
9392		// All attributes are lowercase
9393		// Grab necessary hook if one is defined
9394		if ( nType !== 1 || !jQuery.isXMLDoc( elem ) ) {
9395			name = name.toLowerCase();
9396			hooks = jQuery.attrHooks[ name ] ||
9397				( jQuery.expr.match.bool.test( name ) ? boolHook : undefined );
9398		}
9399
9400		if ( value !== undefined ) {
9401			if ( value === null ) {
9402				jQuery.removeAttr( elem, name );
9403				return;
9404			}
9405
9406			if ( hooks && "set" in hooks &&
9407				( ret = hooks.set( elem, value, name ) ) !== undefined ) {
9408				return ret;
9409			}
9410
9411			elem.setAttribute( name, value + "" );
9412			return value;
9413		}
9414
9415		if ( hooks && "get" in hooks && ( ret = hooks.get( elem, name ) ) !== null ) {
9416			return ret;
9417		}
9418
9419		ret = jQuery.find.attr( elem, name );
9420
9421		// Non-existent attributes return null, we normalize to undefined
9422		return ret == null ? undefined : ret;
9423	},
9424
9425	attrHooks: {
9426		type: {
9427			set: function( elem, value ) {
9428				if ( !support.radioValue && value === "radio" &&
9429					jQuery.nodeName( elem, "input" ) ) {
9430					var val = elem.value;
9431					elem.setAttribute( "type", value );
9432					if ( val ) {
9433						elem.value = val;
9434					}
9435					return value;
9436				}
9437			}
9438		}
9439	},
9440
9441	removeAttr: function( elem, value ) {
9442		var name, propName,
9443			i = 0,
9444			attrNames = value && value.match( rnotwhite );
9445
9446		if ( attrNames && elem.nodeType === 1 ) {
9447			while ( ( name = attrNames[ i++ ] ) ) {
9448				propName = jQuery.propFix[ name ] || name;
9449
9450				// Boolean attributes get special treatment (#10870)
9451				if ( jQuery.expr.match.bool.test( name ) ) {
9452
9453					// Set corresponding property to false
9454					elem[ propName ] = false;
9455				}
9456
9457				elem.removeAttribute( name );
9458			}
9459		}
9460	}
9461} );
9462
9463// Hooks for boolean attributes
9464boolHook = {
9465	set: function( elem, value, name ) {
9466		if ( value === false ) {
9467
9468			// Remove boolean attributes when set to false
9469			jQuery.removeAttr( elem, name );
9470		} else {
9471			elem.setAttribute( name, name );
9472		}
9473		return name;
9474	}
9475};
9476jQuery.each( jQuery.expr.match.bool.source.match( /\w+/g ), function( i, name ) {
9477	var getter = attrHandle[ name ] || jQuery.find.attr;
9478
9479	attrHandle[ name ] = function( elem, name, isXML ) {
9480		var ret, handle;
9481		if ( !isXML ) {
9482
9483			// Avoid an infinite loop by temporarily removing this function from the getter
9484			handle = attrHandle[ name ];
9485			attrHandle[ name ] = ret;
9486			ret = getter( elem, name, isXML ) != null ?
9487				name.toLowerCase() :
9488				null;
9489			attrHandle[ name ] = handle;
9490		}
9491		return ret;
9492	};
9493} );
9494
9495
9496
9497
9498var rfocusable = /^(?:input|select|textarea|button)$/i,
9499	rclickable = /^(?:a|area)$/i;
9500
9501jQuery.fn.extend( {
9502	prop: function( name, value ) {
9503		return access( this, jQuery.prop, name, value, arguments.length > 1 );
9504	},
9505
9506	removeProp: function( name ) {
9507		return this.each( function() {
9508			delete this[ jQuery.propFix[ name ] || name ];
9509		} );
9510	}
9511} );
9512
9513jQuery.extend( {
9514	prop: function( elem, name, value ) {
9515		var ret, hooks,
9516			nType = elem.nodeType;
9517
9518		// Don't get/set properties on text, comment and attribute nodes
9519		if ( nType === 3 || nType === 8 || nType === 2 ) {
9520			return;
9521		}
9522
9523		if ( nType !== 1 || !jQuery.isXMLDoc( elem ) ) {
9524
9525			// Fix name and attach hooks
9526			name = jQuery.propFix[ name ] || name;
9527			hooks = jQuery.propHooks[ name ];
9528		}
9529
9530		if ( value !== undefined ) {
9531			if ( hooks && "set" in hooks &&
9532				( ret = hooks.set( elem, value, name ) ) !== undefined ) {
9533				return ret;
9534			}
9535
9536			return ( elem[ name ] = value );
9537		}
9538
9539		if ( hooks && "get" in hooks && ( ret = hooks.get( elem, name ) ) !== null ) {
9540			return ret;
9541		}
9542
9543		return elem[ name ];
9544	},
9545
9546	propHooks: {
9547		tabIndex: {
9548			get: function( elem ) {
9549
9550				// elem.tabIndex doesn't always return the
9551				// correct value when it hasn't been explicitly set
9552				// http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/
9553				// Use proper attribute retrieval(#12072)
9554				var tabindex = jQuery.find.attr( elem, "tabindex" );
9555
9556				return tabindex ?
9557					parseInt( tabindex, 10 ) :
9558					rfocusable.test( elem.nodeName ) ||
9559						rclickable.test( elem.nodeName ) && elem.href ?
9560							0 :
9561							-1;
9562			}
9563		}
9564	},
9565
9566	propFix: {
9567		"for": "htmlFor",
9568		"class": "className"
9569	}
9570} );
9571
9572// Support: IE <=11 only
9573// Accessing the selectedIndex property
9574// forces the browser to respect setting selected
9575// on the option
9576// The getter ensures a default option is selected
9577// when in an optgroup
9578if ( !support.optSelected ) {
9579	jQuery.propHooks.selected = {
9580		get: function( elem ) {
9581			var parent = elem.parentNode;
9582			if ( parent && parent.parentNode ) {
9583				parent.parentNode.selectedIndex;
9584			}
9585			return null;
9586		},
9587		set: function( elem ) {
9588			var parent = elem.parentNode;
9589			if ( parent ) {
9590				parent.selectedIndex;
9591
9592				if ( parent.parentNode ) {
9593					parent.parentNode.selectedIndex;
9594				}
9595			}
9596		}
9597	};
9598}
9599
9600jQuery.each( [
9601	"tabIndex",
9602	"readOnly",
9603	"maxLength",
9604	"cellSpacing",
9605	"cellPadding",
9606	"rowSpan",
9607	"colSpan",
9608	"useMap",
9609	"frameBorder",
9610	"contentEditable"
9611], function() {
9612	jQuery.propFix[ this.toLowerCase() ] = this;
9613} );
9614
9615
9616
9617
9618var rclass = /[\t\r\n\f]/g;
9619
9620function getClass( elem ) {
9621	return elem.getAttribute && elem.getAttribute( "class" ) || "";
9622}
9623
9624jQuery.fn.extend( {
9625	addClass: function( value ) {
9626		var classes, elem, cur, curValue, clazz, j, finalValue,
9627			i = 0;
9628
9629		if ( jQuery.isFunction( value ) ) {
9630			return this.each( function( j ) {
9631				jQuery( this ).addClass( value.call( this, j, getClass( this ) ) );
9632			} );
9633		}
9634
9635		if ( typeof value === "string" && value ) {
9636			classes = value.match( rnotwhite ) || [];
9637
9638			while ( ( elem = this[ i++ ] ) ) {
9639				curValue = getClass( elem );
9640				cur = elem.nodeType === 1 &&
9641					( " " + curValue + " " ).replace( rclass, " " );
9642
9643				if ( cur ) {
9644					j = 0;
9645					while ( ( clazz = classes[ j++ ] ) ) {
9646						if ( cur.indexOf( " " + clazz + " " ) < 0 ) {
9647							cur += clazz + " ";
9648						}
9649					}
9650
9651					// Only assign if different to avoid unneeded rendering.
9652					finalValue = jQuery.trim( cur );
9653					if ( curValue !== finalValue ) {
9654						elem.setAttribute( "class", finalValue );
9655					}
9656				}
9657			}
9658		}
9659
9660		return this;
9661	},
9662
9663	removeClass: function( value ) {
9664		var classes, elem, cur, curValue, clazz, j, finalValue,
9665			i = 0;
9666
9667		if ( jQuery.isFunction( value ) ) {
9668			return this.each( function( j ) {
9669				jQuery( this ).removeClass( value.call( this, j, getClass( this ) ) );
9670			} );
9671		}
9672
9673		if ( !arguments.length ) {
9674			return this.attr( "class", "" );
9675		}
9676
9677		if ( typeof value === "string" && value ) {
9678			classes = value.match( rnotwhite ) || [];
9679
9680			while ( ( elem = this[ i++ ] ) ) {
9681				curValue = getClass( elem );
9682
9683				// This expression is here for better compressibility (see addClass)
9684				cur = elem.nodeType === 1 &&
9685					( " " + curValue + " " ).replace( rclass, " " );
9686
9687				if ( cur ) {
9688					j = 0;
9689					while ( ( clazz = classes[ j++ ] ) ) {
9690
9691						// Remove *all* instances
9692						while ( cur.indexOf( " " + clazz + " " ) > -1 ) {
9693							cur = cur.replace( " " + clazz + " ", " " );
9694						}
9695					}
9696
9697					// Only assign if different to avoid unneeded rendering.
9698					finalValue = jQuery.trim( cur );
9699					if ( curValue !== finalValue ) {
9700						elem.setAttribute( "class", finalValue );
9701					}
9702				}
9703			}
9704		}
9705
9706		return this;
9707	},
9708
9709	toggleClass: function( value, stateVal ) {
9710		var type = typeof value;
9711
9712		if ( typeof stateVal === "boolean" && type === "string" ) {
9713			return stateVal ? this.addClass( value ) : this.removeClass( value );
9714		}
9715
9716		if ( jQuery.isFunction( value ) ) {
9717			return this.each( function( i ) {
9718				jQuery( this ).toggleClass(
9719					value.call( this, i, getClass( this ), stateVal ),
9720					stateVal
9721				);
9722			} );
9723		}
9724
9725		return this.each( function() {
9726			var className, i, self, classNames;
9727
9728			if ( type === "string" ) {
9729
9730				// Toggle individual class names
9731				i = 0;
9732				self = jQuery( this );
9733				classNames = value.match( rnotwhite ) || [];
9734
9735				while ( ( className = classNames[ i++ ] ) ) {
9736
9737					// Check each className given, space separated list
9738					if ( self.hasClass( className ) ) {
9739						self.removeClass( className );
9740					} else {
9741						self.addClass( className );
9742					}
9743				}
9744
9745			// Toggle whole class name
9746			} else if ( value === undefined || type === "boolean" ) {
9747				className = getClass( this );
9748				if ( className ) {
9749
9750					// Store className if set
9751					dataPriv.set( this, "__className__", className );
9752				}
9753
9754				// If the element has a class name or if we're passed `false`,
9755				// then remove the whole classname (if there was one, the above saved it).
9756				// Otherwise bring back whatever was previously saved (if anything),
9757				// falling back to the empty string if nothing was stored.
9758				if ( this.setAttribute ) {
9759					this.setAttribute( "class",
9760						className || value === false ?
9761						"" :
9762						dataPriv.get( this, "__className__" ) || ""
9763					);
9764				}
9765			}
9766		} );
9767	},
9768
9769	hasClass: function( selector ) {
9770		var className, elem,
9771			i = 0;
9772
9773		className = " " + selector + " ";
9774		while ( ( elem = this[ i++ ] ) ) {
9775			if ( elem.nodeType === 1 &&
9776				( " " + getClass( elem ) + " " ).replace( rclass, " " )
9777					.indexOf( className ) > -1
9778			) {
9779				return true;
9780			}
9781		}
9782
9783		return false;
9784	}
9785} );
9786
9787
9788
9789
9790var rreturn = /\r/g,
9791	rspaces = /[\x20\t\r\n\f]+/g;
9792
9793jQuery.fn.extend( {
9794	val: function( value ) {
9795		var hooks, ret, isFunction,
9796			elem = this[ 0 ];
9797
9798		if ( !arguments.length ) {
9799			if ( elem ) {
9800				hooks = jQuery.valHooks[ elem.type ] ||
9801					jQuery.valHooks[ elem.nodeName.toLowerCase() ];
9802
9803				if ( hooks &&
9804					"get" in hooks &&
9805					( ret = hooks.get( elem, "value" ) ) !== undefined
9806				) {
9807					return ret;
9808				}
9809
9810				ret = elem.value;
9811
9812				return typeof ret === "string" ?
9813
9814					// Handle most common string cases
9815					ret.replace( rreturn, "" ) :
9816
9817					// Handle cases where value is null/undef or number
9818					ret == null ? "" : ret;
9819			}
9820
9821			return;
9822		}
9823
9824		isFunction = jQuery.isFunction( value );
9825
9826		return this.each( function( i ) {
9827			var val;
9828
9829			if ( this.nodeType !== 1 ) {
9830				return;
9831			}
9832
9833			if ( isFunction ) {
9834				val = value.call( this, i, jQuery( this ).val() );
9835			} else {
9836				val = value;
9837			}
9838
9839			// Treat null/undefined as ""; convert numbers to string
9840			if ( val == null ) {
9841				val = "";
9842
9843			} else if ( typeof val === "number" ) {
9844				val += "";
9845
9846			} else if ( jQuery.isArray( val ) ) {
9847				val = jQuery.map( val, function( value ) {
9848					return value == null ? "" : value + "";
9849				} );
9850			}
9851
9852			hooks = jQuery.valHooks[ this.type ] || jQuery.valHooks[ this.nodeName.toLowerCase() ];
9853
9854			// If set returns undefined, fall back to normal setting
9855			if ( !hooks || !( "set" in hooks ) || hooks.set( this, val, "value" ) === undefined ) {
9856				this.value = val;
9857			}
9858		} );
9859	}
9860} );
9861
9862jQuery.extend( {
9863	valHooks: {
9864		option: {
9865			get: function( elem ) {
9866
9867				var val = jQuery.find.attr( elem, "value" );
9868				return val != null ?
9869					val :
9870
9871					// Support: IE10-11+
9872					// option.text throws exceptions (#14686, #14858)
9873					// Strip and collapse whitespace
9874					// https://html.spec.whatwg.org/#strip-and-collapse-whitespace
9875					jQuery.trim( jQuery.text( elem ) ).replace( rspaces, " " );
9876			}
9877		},
9878		select: {
9879			get: function( elem ) {
9880				var value, option,
9881					options = elem.options,
9882					index = elem.selectedIndex,
9883					one = elem.type === "select-one" || index < 0,
9884					values = one ? null : [],
9885					max = one ? index + 1 : options.length,
9886					i = index < 0 ?
9887						max :
9888						one ? index : 0;
9889
9890				// Loop through all the selected options
9891				for ( ; i < max; i++ ) {
9892					option = options[ i ];
9893
9894					// IE8-9 doesn't update selected after form reset (#2551)
9895					if ( ( option.selected || i === index ) &&
9896
9897							// Don't return options that are disabled or in a disabled optgroup
9898							( support.optDisabled ?
9899								!option.disabled : option.getAttribute( "disabled" ) === null ) &&
9900							( !option.parentNode.disabled ||
9901								!jQuery.nodeName( option.parentNode, "optgroup" ) ) ) {
9902
9903						// Get the specific value for the option
9904						value = jQuery( option ).val();
9905
9906						// We don't need an array for one selects
9907						if ( one ) {
9908							return value;
9909						}
9910
9911						// Multi-Selects return an array
9912						values.push( value );
9913					}
9914				}
9915
9916				return values;
9917			},
9918
9919			set: function( elem, value ) {
9920				var optionSet, option,
9921					options = elem.options,
9922					values = jQuery.makeArray( value ),
9923					i = options.length;
9924
9925				while ( i-- ) {
9926					option = options[ i ];
9927					if ( option.selected =
9928						jQuery.inArray( jQuery.valHooks.option.get( option ), values ) > -1
9929					) {
9930						optionSet = true;
9931					}
9932				}
9933
9934				// Force browsers to behave consistently when non-matching value is set
9935				if ( !optionSet ) {
9936					elem.selectedIndex = -1;
9937				}
9938				return values;
9939			}
9940		}
9941	}
9942} );
9943
9944// Radios and checkboxes getter/setter
9945jQuery.each( [ "radio", "checkbox" ], function() {
9946	jQuery.valHooks[ this ] = {
9947		set: function( elem, value ) {
9948			if ( jQuery.isArray( value ) ) {
9949				return ( elem.checked = jQuery.inArray( jQuery( elem ).val(), value ) > -1 );
9950			}
9951		}
9952	};
9953	if ( !support.checkOn ) {
9954		jQuery.valHooks[ this ].get = function( elem ) {
9955			return elem.getAttribute( "value" ) === null ? "on" : elem.value;
9956		};
9957	}
9958} );
9959
9960
9961
9962
9963// Return jQuery for attributes-only inclusion
9964
9965
9966var rfocusMorph = /^(?:focusinfocus|focusoutblur)$/;
9967
9968jQuery.extend( jQuery.event, {
9969
9970	trigger: function( event, data, elem, onlyHandlers ) {
9971
9972		var i, cur, tmp, bubbleType, ontype, handle, special,
9973			eventPath = [ elem || document ],
9974			type = hasOwn.call( event, "type" ) ? event.type : event,
9975			namespaces = hasOwn.call( event, "namespace" ) ? event.namespace.split( "." ) : [];
9976
9977		cur = tmp = elem = elem || document;
9978
9979		// Don't do events on text and comment nodes
9980		if ( elem.nodeType === 3 || elem.nodeType === 8 ) {
9981			return;
9982		}
9983
9984		// focus/blur morphs to focusin/out; ensure we're not firing them right now
9985		if ( rfocusMorph.test( type + jQuery.event.triggered ) ) {
9986			return;
9987		}
9988
9989		if ( type.indexOf( "." ) > -1 ) {
9990
9991			// Namespaced trigger; create a regexp to match event type in handle()
9992			namespaces = type.split( "." );
9993			type = namespaces.shift();
9994			namespaces.sort();
9995		}
9996		ontype = type.indexOf( ":" ) < 0 && "on" + type;
9997
9998		// Caller can pass in a jQuery.Event object, Object, or just an event type string
9999		event = event[ jQuery.expando ] ?
10000			event :
10001			new jQuery.Event( type, typeof event === "object" && event );
10002
10003		// Trigger bitmask: & 1 for native handlers; & 2 for jQuery (always true)
10004		event.isTrigger = onlyHandlers ? 2 : 3;
10005		event.namespace = namespaces.join( "." );
10006		event.rnamespace = event.namespace ?
10007			new RegExp( "(^|\\.)" + namespaces.join( "\\.(?:.*\\.|)" ) + "(\\.|$)" ) :
10008			null;
10009
10010		// Clean up the event in case it is being reused
10011		event.result = undefined;
10012		if ( !event.target ) {
10013			event.target = elem;
10014		}
10015
10016		// Clone any incoming data and prepend the event, creating the handler arg list
10017		data = data == null ?
10018			[ event ] :
10019			jQuery.makeArray( data, [ event ] );
10020
10021		// Allow special events to draw outside the lines
10022		special = jQuery.event.special[ type ] || {};
10023		if ( !onlyHandlers && special.trigger && special.trigger.apply( elem, data ) === false ) {
10024			return;
10025		}
10026
10027		// Determine event propagation path in advance, per W3C events spec (#9951)
10028		// Bubble up to document, then to window; watch for a global ownerDocument var (#9724)
10029		if ( !onlyHandlers && !special.noBubble && !jQuery.isWindow( elem ) ) {
10030
10031			bubbleType = special.delegateType || type;
10032			if ( !rfocusMorph.test( bubbleType + type ) ) {
10033				cur = cur.parentNode;
10034			}
10035			for ( ; cur; cur = cur.parentNode ) {
10036				eventPath.push( cur );
10037				tmp = cur;
10038			}
10039
10040			// Only add window if we got to document (e.g., not plain obj or detached DOM)
10041			if ( tmp === ( elem.ownerDocument || document ) ) {
10042				eventPath.push( tmp.defaultView || tmp.parentWindow || window );
10043			}
10044		}
10045
10046		// Fire handlers on the event path
10047		i = 0;
10048		while ( ( cur = eventPath[ i++ ] ) && !event.isPropagationStopped() ) {
10049
10050			event.type = i > 1 ?
10051				bubbleType :
10052				special.bindType || type;
10053
10054			// jQuery handler
10055			handle = ( dataPriv.get( cur, "events" ) || {} )[ event.type ] &&
10056				dataPriv.get( cur, "handle" );
10057			if ( handle ) {
10058				handle.apply( cur, data );
10059			}
10060
10061			// Native handler
10062			handle = ontype && cur[ ontype ];
10063			if ( handle && handle.apply && acceptData( cur ) ) {
10064				event.result = handle.apply( cur, data );
10065				if ( event.result === false ) {
10066					event.preventDefault();
10067				}
10068			}
10069		}
10070		event.type = type;
10071
10072		// If nobody prevented the default action, do it now
10073		if ( !onlyHandlers && !event.isDefaultPrevented() ) {
10074
10075			if ( ( !special._default ||
10076				special._default.apply( eventPath.pop(), data ) === false ) &&
10077				acceptData( elem ) ) {
10078
10079				// Call a native DOM method on the target with the same name name as the event.
10080				// Don't do default actions on window, that's where global variables be (#6170)
10081				if ( ontype && jQuery.isFunction( elem[ type ] ) && !jQuery.isWindow( elem ) ) {
10082
10083					// Don't re-trigger an onFOO event when we call its FOO() method
10084					tmp = elem[ ontype ];
10085
10086					if ( tmp ) {
10087						elem[ ontype ] = null;
10088					}
10089
10090					// Prevent re-triggering of the same event, since we already bubbled it above
10091					jQuery.event.triggered = type;
10092					elem[ type ]();
10093					jQuery.event.triggered = undefined;
10094
10095					if ( tmp ) {
10096						elem[ ontype ] = tmp;
10097					}
10098				}
10099			}
10100		}
10101
10102		return event.result;
10103	},
10104
10105	// Piggyback on a donor event to simulate a different one
10106	// Used only for `focus(in | out)` events
10107	simulate: function( type, elem, event ) {
10108		var e = jQuery.extend(
10109			new jQuery.Event(),
10110			event,
10111			{
10112				type: type,
10113				isSimulated: true
10114			}
10115		);
10116
10117		jQuery.event.trigger( e, null, elem );
10118	}
10119
10120} );
10121
10122jQuery.fn.extend( {
10123
10124	trigger: function( type, data ) {
10125		return this.each( function() {
10126			jQuery.event.trigger( type, data, this );
10127		} );
10128	},
10129	triggerHandler: function( type, data ) {
10130		var elem = this[ 0 ];
10131		if ( elem ) {
10132			return jQuery.event.trigger( type, data, elem, true );
10133		}
10134	}
10135} );
10136
10137
10138jQuery.each( ( "blur focus focusin focusout load resize scroll unload click dblclick " +
10139	"mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " +
10140	"change select submit keydown keypress keyup error contextmenu" ).split( " " ),
10141	function( i, name ) {
10142
10143	// Handle event binding
10144	jQuery.fn[ name ] = function( data, fn ) {
10145		return arguments.length > 0 ?
10146			this.on( name, null, data, fn ) :
10147			this.trigger( name );
10148	};
10149} );
10150
10151jQuery.fn.extend( {
10152	hover: function( fnOver, fnOut ) {
10153		return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );
10154	}
10155} );
10156
10157
10158
10159
10160support.focusin = "onfocusin" in window;
10161
10162
10163// Support: Firefox
10164// Firefox doesn't have focus(in | out) events
10165// Related ticket - https://bugzilla.mozilla.org/show_bug.cgi?id=687787
10166//
10167// Support: Chrome, Safari
10168// focus(in | out) events fire after focus & blur events,
10169// which is spec violation - http://www.w3.org/TR/DOM-Level-3-Events/#events-focusevent-event-order
10170// Related ticket - https://code.google.com/p/chromium/issues/detail?id=449857
10171if ( !support.focusin ) {
10172	jQuery.each( { focus: "focusin", blur: "focusout" }, function( orig, fix ) {
10173
10174		// Attach a single capturing handler on the document while someone wants focusin/focusout
10175		var handler = function( event ) {
10176			jQuery.event.simulate( fix, event.target, jQuery.event.fix( event ) );
10177		};
10178
10179		jQuery.event.special[ fix ] = {
10180			setup: function() {
10181				var doc = this.ownerDocument || this,
10182					attaches = dataPriv.access( doc, fix );
10183
10184				if ( !attaches ) {
10185					doc.addEventListener( orig, handler, true );
10186				}
10187				dataPriv.access( doc, fix, ( attaches || 0 ) + 1 );
10188			},
10189			teardown: function() {
10190				var doc = this.ownerDocument || this,
10191					attaches = dataPriv.access( doc, fix ) - 1;
10192
10193				if ( !attaches ) {
10194					doc.removeEventListener( orig, handler, true );
10195					dataPriv.remove( doc, fix );
10196
10197				} else {
10198					dataPriv.access( doc, fix, attaches );
10199				}
10200			}
10201		};
10202	} );
10203}
10204var location = window.location;
10205
10206var nonce = jQuery.now();
10207
10208var rquery = ( /\?/ );
10209
10210
10211
10212// Support: Android 2.3
10213// Workaround failure to string-cast null input
10214jQuery.parseJSON = function( data ) {
10215	return JSON.parse( data + "" );
10216};
10217
10218
10219// Cross-browser xml parsing
10220jQuery.parseXML = function( data ) {
10221	var xml;
10222	if ( !data || typeof data !== "string" ) {
10223		return null;
10224	}
10225
10226	// Support: IE9
10227	try {
10228		xml = ( new window.DOMParser() ).parseFromString( data, "text/xml" );
10229	} catch ( e ) {
10230		xml = undefined;
10231	}
10232
10233	if ( !xml || xml.getElementsByTagName( "parsererror" ).length ) {
10234		jQuery.error( "Invalid XML: " + data );
10235	}
10236	return xml;
10237};
10238
10239
10240var
10241	rhash = /#.*$/,
10242	rts = /([?&])_=[^&]*/,
10243	rheaders = /^(.*?):[ \t]*([^\r\n]*)$/mg,
10244
10245	// #7653, #8125, #8152: local protocol detection
10246	rlocalProtocol = /^(?:about|app|app-storage|.+-extension|file|res|widget):$/,
10247	rnoContent = /^(?:GET|HEAD)$/,
10248	rprotocol = /^\/\//,
10249
10250	/* Prefilters
10251	 * 1) They are useful to introduce custom dataTypes (see ajax/jsonp.js for an example)
10252	 * 2) These are called:
10253	 *    - BEFORE asking for a transport
10254	 *    - AFTER param serialization (s.data is a string if s.processData is true)
10255	 * 3) key is the dataType
10256	 * 4) the catchall symbol "*" can be used
10257	 * 5) execution will start with transport dataType and THEN continue down to "*" if needed
10258	 */
10259	prefilters = {},
10260
10261	/* Transports bindings
10262	 * 1) key is the dataType
10263	 * 2) the catchall symbol "*" can be used
10264	 * 3) selection will start with transport dataType and THEN go to "*" if needed
10265	 */
10266	transports = {},
10267
10268	// Avoid comment-prolog char sequence (#10098); must appease lint and evade compression
10269	allTypes = "*/".concat( "*" ),
10270
10271	// Anchor tag for parsing the document origin
10272	originAnchor = document.createElement( "a" );
10273	originAnchor.href = location.href;
10274
10275// Base "constructor" for jQuery.ajaxPrefilter and jQuery.ajaxTransport
10276function addToPrefiltersOrTransports( structure ) {
10277
10278	// dataTypeExpression is optional and defaults to "*"
10279	return function( dataTypeExpression, func ) {
10280
10281		if ( typeof dataTypeExpression !== "string" ) {
10282			func = dataTypeExpression;
10283			dataTypeExpression = "*";
10284		}
10285
10286		var dataType,
10287			i = 0,
10288			dataTypes = dataTypeExpression.toLowerCase().match( rnotwhite ) || [];
10289
10290		if ( jQuery.isFunction( func ) ) {
10291
10292			// For each dataType in the dataTypeExpression
10293			while ( ( dataType = dataTypes[ i++ ] ) ) {
10294
10295				// Prepend if requested
10296				if ( dataType[ 0 ] === "+" ) {
10297					dataType = dataType.slice( 1 ) || "*";
10298					( structure[ dataType ] = structure[ dataType ] || [] ).unshift( func );
10299
10300				// Otherwise append
10301				} else {
10302					( structure[ dataType ] = structure[ dataType ] || [] ).push( func );
10303				}
10304			}
10305		}
10306	};
10307}
10308
10309// Base inspection function for prefilters and transports
10310function inspectPrefiltersOrTransports( structure, options, originalOptions, jqXHR ) {
10311
10312	var inspected = {},
10313		seekingTransport = ( structure === transports );
10314
10315	function inspect( dataType ) {
10316		var selected;
10317		inspected[ dataType ] = true;
10318		jQuery.each( structure[ dataType ] || [], function( _, prefilterOrFactory ) {
10319			var dataTypeOrTransport = prefilterOrFactory( options, originalOptions, jqXHR );
10320			if ( typeof dataTypeOrTransport === "string" &&
10321				!seekingTransport && !inspected[ dataTypeOrTransport ] ) {
10322
10323				options.dataTypes.unshift( dataTypeOrTransport );
10324				inspect( dataTypeOrTransport );
10325				return false;
vendor: 5,117 bytes, lines 10326-10536
10326			} else if ( seekingTransport ) {
10327				return !( selected = dataTypeOrTransport );
10328			}
10329		} );
10330		return selected;
10331	}
10332
10333	return inspect( options.dataTypes[ 0 ] ) || !inspected[ "*" ] && inspect( "*" );
10334}
10335
10336// A special extend for ajax options
10337// that takes "flat" options (not to be deep extended)
10338// Fixes #9887
10339function ajaxExtend( target, src ) {
10340	var key, deep,
10341		flatOptions = jQuery.ajaxSettings.flatOptions || {};
10342
10343	for ( key in src ) {
10344		if ( src[ key ] !== undefined ) {
10345			( flatOptions[ key ] ? target : ( deep || ( deep = {} ) ) )[ key ] = src[ key ];
10346		}
10347	}
10348	if ( deep ) {
10349		jQuery.extend( true, target, deep );
10350	}
10351
10352	return target;
10353}
10354
10355/* Handles responses to an ajax request:
10356 * - finds the right dataType (mediates between content-type and expected dataType)
10357 * - returns the corresponding response
10358 */
10359function ajaxHandleResponses( s, jqXHR, responses ) {
10360
10361	var ct, type, finalDataType, firstDataType,
10362		contents = s.contents,
10363		dataTypes = s.dataTypes;
10364
10365	// Remove auto dataType and get content-type in the process
10366	while ( dataTypes[ 0 ] === "*" ) {
10367		dataTypes.shift();
10368		if ( ct === undefined ) {
10369			ct = s.mimeType || jqXHR.getResponseHeader( "Content-Type" );
10370		}
10371	}
10372
10373	// Check if we're dealing with a known content-type
10374	if ( ct ) {
10375		for ( type in contents ) {
10376			if ( contents[ type ] && contents[ type ].test( ct ) ) {
10377				dataTypes.unshift( type );
10378				break;
10379			}
10380		}
10381	}
10382
10383	// Check to see if we have a response for the expected dataType
10384	if ( dataTypes[ 0 ] in responses ) {
10385		finalDataType = dataTypes[ 0 ];
10386	} else {
10387
10388		// Try convertible dataTypes
10389		for ( type in responses ) {
10390			if ( !dataTypes[ 0 ] || s.converters[ type + " " + dataTypes[ 0 ] ] ) {
10391				finalDataType = type;
10392				break;
10393			}
10394			if ( !firstDataType ) {
10395				firstDataType = type;
10396			}
10397		}
10398
10399		// Or just use first one
10400		finalDataType = finalDataType || firstDataType;
10401	}
10402
10403	// If we found a dataType
10404	// We add the dataType to the list if needed
10405	// and return the corresponding response
10406	if ( finalDataType ) {
10407		if ( finalDataType !== dataTypes[ 0 ] ) {
10408			dataTypes.unshift( finalDataType );
10409		}
10410		return responses[ finalDataType ];
10411	}
10412}
10413
10414/* Chain conversions given the request and the original response
10415 * Also sets the responseXXX fields on the jqXHR instance
10416 */
10417function ajaxConvert( s, response, jqXHR, isSuccess ) {
10418	var conv2, current, conv, tmp, prev,
10419		converters = {},
10420
10421		// Work with a copy of dataTypes in case we need to modify it for conversion
10422		dataTypes = s.dataTypes.slice();
10423
10424	// Create converters map with lowercased keys
10425	if ( dataTypes[ 1 ] ) {
10426		for ( conv in s.converters ) {
10427			converters[ conv.toLowerCase() ] = s.converters[ conv ];
10428		}
10429	}
10430
10431	current = dataTypes.shift();
10432
10433	// Convert to each sequential dataType
10434	while ( current ) {
10435
10436		if ( s.responseFields[ current ] ) {
10437			jqXHR[ s.responseFields[ current ] ] = response;
10438		}
10439
10440		// Apply the dataFilter if provided
10441		if ( !prev && isSuccess && s.dataFilter ) {
10442			response = s.dataFilter( response, s.dataType );
10443		}
10444
10445		prev = current;
10446		current = dataTypes.shift();
10447
10448		if ( current ) {
10449
10450		// There's only work to do if current dataType is non-auto
10451			if ( current === "*" ) {
10452
10453				current = prev;
10454
10455			// Convert response if prev dataType is non-auto and differs from current
10456			} else if ( prev !== "*" && prev !== current ) {
10457
10458				// Seek a direct converter
10459				conv = converters[ prev + " " + current ] || converters[ "* " + current ];
10460
10461				// If none found, seek a pair
10462				if ( !conv ) {
10463					for ( conv2 in converters ) {
10464
10465						// If conv2 outputs current
10466						tmp = conv2.split( " " );
10467						if ( tmp[ 1 ] === current ) {
10468
10469							// If prev can be converted to accepted input
10470							conv = converters[ prev + " " + tmp[ 0 ] ] ||
10471								converters[ "* " + tmp[ 0 ] ];
10472							if ( conv ) {
10473
10474								// Condense equivalence converters
10475								if ( conv === true ) {
10476									conv = converters[ conv2 ];
10477
10478								// Otherwise, insert the intermediate dataType
10479								} else if ( converters[ conv2 ] !== true ) {
10480									current = tmp[ 0 ];
10481									dataTypes.unshift( tmp[ 1 ] );
10482								}
10483								break;
10484							}
10485						}
10486					}
10487				}
10488
10489				// Apply converter (if not an equivalence)
10490				if ( conv !== true ) {
10491
10492					// Unless errors are allowed to bubble, catch and return them
10493					if ( conv && s.throws ) {
10494						response = conv( response );
10495					} else {
10496						try {
10497							response = conv( response );
10498						} catch ( e ) {
10499							return {
10500								state: "parsererror",
10501								error: conv ? e : "No conversion from " + prev + " to " + current
10502							};
10503						}
10504					}
10505				}
10506			}
10507		}
10508	}
10509
10510	return { state: "success", data: response };
10511}
10512
10513jQuery.extend( {
10514
10515	// Counter for holding the number of active queries
10516	active: 0,
10517
10518	// Last-Modified header cache for next request
10519	lastModified: {},
10520	etag: {},
10521
10522	ajaxSettings: {
10523		url: location.href,
10524		type: "GET",
10525		isLocal: rlocalProtocol.test( location.protocol ),
10526		global: true,
10527		processData: true,
10528		async: true,
10529		contentType: "application/x-www-form-urlencoded; charset=UTF-8",
10530		/*
10531		timeout: 0,
10532		data: null,
10533		dataType: null,
10534		username: null,
10535		password: null,
10536		cache: null,
10537		throws: false,
10538		traditional: false,
10539		headers: {},
10540		*/
10541
10542		accepts: {
10543			"*": allTypes,
10544			text: "text/plain",
10545			html: "text/html",
10546			xml: "application/xml, text/xml",
10547			json: "application/json, text/javascript"
10548		},
10549
10550		contents: {
10551			xml: /\bxml\b/,
10552			html: /\bhtml/,
10553			json: /\bjson\b/
10554		},
10555
10556		responseFields: {
10557			xml: "responseXML",
10558			text: "responseText",
10559			json: "responseJSON"
10560		},
10561
10562		// Data converters
10563		// Keys separate source (or catchall "*") and destination types with a single space
10564		converters: {
10565
10566			// Convert anything to text
10567			"* text": String,
10568
10569			// Text to html (true = no transformation)
10570			"text html": true,
10571
10572			// Evaluate text as a json expression
10573			"text json": jQuery.parseJSON,
10574
10575			// Parse text as xml
10576			"text xml": jQuery.parseXML
10577		},
10578
10579		// For options that shouldn't be deep extended:
10580		// you can add your own custom options here if
10581		// and when you create one that shouldn't be
10582		// deep extended (see ajaxExtend)
10583		flatOptions: {
10584			url: true,
10585			context: true
10586		}
10587	},
10588
10589	// Creates a full fledged settings object into target
10590	// with both ajaxSettings and settings fields.
10591	// If target is omitted, writes into ajaxSettings.
10592	ajaxSetup: function( target, settings ) {
10593		return settings ?
10594
10595			// Building a settings object
10596			ajaxExtend( ajaxExtend( target, jQuery.ajaxSettings ), settings ) :
10597
10598			// Extending ajaxSettings
10599			ajaxExtend( jQuery.ajaxSettings, target );
10600	},
10601
10602	ajaxPrefilter: addToPrefiltersOrTransports( prefilters ),
10603	ajaxTransport: addToPrefiltersOrTransports( transports ),
10604
10605	// Main method
10606	ajax: function( url, options ) {
10607
10608		// If url is an object, simulate pre-1.5 signature
10609		if ( typeof url === "object" ) {
10610			options = url;
10611			url = undefined;
10612		}
10613
10614		// Force options to be an object
10615		options = options || {};
10616
10617		var transport,
10618
10619			// URL without anti-cache param
10620			cacheURL,
10621
10622			// Response headers
10623			responseHeadersString,
10624			responseHeaders,
10625
10626			// timeout handle
10627			timeoutTimer,
10628
10629			// Url cleanup var
10630			urlAnchor,
10631
10632			// To know if global events are to be dispatched
10633			fireGlobals,
10634
10635			// Loop variable
10636			i,
10637
10638			// Create the final options object
10639			s = jQuery.ajaxSetup( {}, options ),
10640
10641			// Callbacks context
10642			callbackContext = s.context || s,
10643
10644			// Context for global events is callbackContext if it is a DOM node or jQuery collection
10645			globalEventContext = s.context &&
10646				( callbackContext.nodeType || callbackContext.jquery ) ?
10647					jQuery( callbackContext ) :
10648					jQuery.event,
10649
10650			// Deferreds
10651			deferred = jQuery.Deferred(),
10652			completeDeferred = jQuery.Callbacks( "once memory" ),
10653
10654			// Status-dependent callbacks
10655			statusCode = s.statusCode || {},
10656
10657			// Headers (they are sent all at once)
10658			requestHeaders = {},
10659			requestHeadersNames = {},
10660
10661			// The jqXHR state
10662			state = 0,
10663
10664			// Default abort message
10665			strAbort = "canceled",
10666
10667			// Fake xhr
10668			jqXHR = {
10669				readyState: 0,
10670
10671				// Builds headers hashtable if needed
10672				getResponseHeader: function( key ) {
10673					var match;
10674					if ( state === 2 ) {
10675						if ( !responseHeaders ) {
10676							responseHeaders = {};
10677							while ( ( match = rheaders.exec( responseHeadersString ) ) ) {
10678								responseHeaders[ match[ 1 ].toLowerCase() ] = match[ 2 ];
10679							}
10680						}
10681						match = responseHeaders[ key.toLowerCase() ];
10682					}
10683					return match == null ? null : match;
10684				},
10685
10686				// Raw string
10687				getAllResponseHeaders: function() {
10688					return state === 2 ? responseHeadersString : null;
10689				},
10690
10691				// Caches the header
10692				setRequestHeader: function( name, value ) {
10693					var lname = name.toLowerCase();
10694					if ( !state ) {
10695						name = requestHeadersNames[ lname ] = requestHeadersNames[ lname ] || name;
10696						requestHeaders[ name ] = value;
10697					}
10698					return this;
10699				},
10700
10701				// Overrides response content-type header
10702				overrideMimeType: function( type ) {
10703					if ( !state ) {
10704						s.mimeType = type;
10705					}
10706					return this;
10707				},
10708
10709				// Status-dependent callbacks
10710				statusCode: function( map ) {
10711					var code;
10712					if ( map ) {
10713						if ( state < 2 ) {
10714							for ( code in map ) {
10715
10716								// Lazy-add the new callback in a way that preserves old ones
10717								statusCode[ code ] = [ statusCode[ code ], map[ code ] ];
10718							}
10719						} else {
10720
10721							// Execute the appropriate callbacks
10722							jqXHR.always( map[ jqXHR.status ] );
10723						}
10724					}
10725					return this;
10726				},
10727
10728				// Cancel the request
10729				abort: function( statusText ) {
10730					var finalText = statusText || strAbort;
10731					if ( transport ) {
10732						transport.abort( finalText );
10733					}
10734					done( 0, finalText );
10735					return this;
10736				}
10737			};
10738
10739		// Attach deferreds
10740		deferred.promise( jqXHR ).complete = completeDeferred.add;
10741		jqXHR.success = jqXHR.done;
10742		jqXHR.error = jqXHR.fail;
10743
10744		// Remove hash character (#7531: and string promotion)
10745		// Add protocol if not provided (prefilters might expect it)
10746		// Handle falsy url in the settings object (#10093: consistency with old signature)
10747		// We also use the url parameter if available
10748		s.url = ( ( url || s.url || location.href ) + "" ).replace( rhash, "" )
10749			.replace( rprotocol, location.protocol + "//" );
10750
10751		// Alias method option to type as per ticket #12004
10752		s.type = options.method || options.type || s.method || s.type;
10753
10754		// Extract dataTypes list
10755		s.dataTypes = jQuery.trim( s.dataType || "*" ).toLowerCase().match( rnotwhite ) || [ "" ];
10756
10757		// A cross-domain request is in order when the origin doesn't match the current origin.
10758		if ( s.crossDomain == null ) {
10759			urlAnchor = document.createElement( "a" );
10760
10761			// Support: IE8-11+
10762			// IE throws exception if url is malformed, e.g. http://example.com:80x/
10763			try {
10764				urlAnchor.href = s.url;
10765
10766				// Support: IE8-11+
10767				// Anchor's host property isn't correctly set when s.url is relative
10768				urlAnchor.href = urlAnchor.href;
10769				s.crossDomain = originAnchor.protocol + "//" + originAnchor.host !==
10770					urlAnchor.protocol + "//" + urlAnchor.host;
10771			} catch ( e ) {
10772
10773				// If there is an error parsing the URL, assume it is crossDomain,
10774				// it can be rejected by the transport if it is invalid
10775				s.crossDomain = true;
10776			}
10777		}
10778
10779		// Convert data if not already a string
10780		if ( s.data && s.processData && typeof s.data !== "string" ) {
10781			s.data = jQuery.param( s.data, s.traditional );
10782		}
10783
10784		// Apply prefilters
10785		inspectPrefiltersOrTransports( prefilters, s, options, jqXHR );
10786
10787		// If request was aborted inside a prefilter, stop there
10788		if ( state === 2 ) {
10789			return jqXHR;
10790		}
10791
10792		// We can fire global events as of now if asked to
10793		// Don't fire events if jQuery.event is undefined in an AMD-usage scenario (#15118)
10794		fireGlobals = jQuery.event && s.global;
10795
10796		// Watch for a new set of requests
10797		if ( fireGlobals && jQuery.active++ === 0 ) {
10798			jQuery.event.trigger( "ajaxStart" );
10799		}
10800
10801		// Uppercase the type
10802		s.type = s.type.toUpperCase();
10803
10804		// Determine if request has content
10805		s.hasContent = !rnoContent.test( s.type );
10806
10807		// Save the URL in case we're toying with the If-Modified-Since
10808		// and/or If-None-Match header later on
10809		cacheURL = s.url;
10810
10811		// More options handling for requests with no content
10812		if ( !s.hasContent ) {
10813
10814			// If data is available, append data to url
10815			if ( s.data ) {
10816				cacheURL = ( s.url += ( rquery.test( cacheURL ) ? "&" : "?" ) + s.data );
10817
10818				// #9682: remove data so that it's not used in an eventual retry
10819				delete s.data;
10820			}
10821
10822			// Add anti-cache in url if needed
10823			if ( s.cache === false ) {
10824				s.url = rts.test( cacheURL ) ?
10825
10826					// If there is already a '_' parameter, set its value
10827					cacheURL.replace( rts, "$1_=" + nonce++ ) :
10828
10829					// Otherwise add one to the end
10830					cacheURL + ( rquery.test( cacheURL ) ? "&" : "?" ) + "_=" + nonce++;
10831			}
10832		}
10833
10834		// Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.
10835		if ( s.ifModified ) {
10836			if ( jQuery.lastModified[ cacheURL ] ) {
10837				jqXHR.setRequestHeader( "If-Modified-Since", jQuery.lastModified[ cacheURL ] );
10838			}
10839			if ( jQuery.etag[ cacheURL ] ) {
10840				jqXHR.setRequestHeader( "If-None-Match", jQuery.etag[ cacheURL ] );
10841			}
10842		}
10843
10844		// Set the correct header, if data is being sent
10845		if ( s.data && s.hasContent && s.contentType !== false || options.contentType ) {
10846			jqXHR.setRequestHeader( "Content-Type", s.contentType );
10847		}
10848
10849		// Set the Accepts header for the server, depending on the dataType
10850		jqXHR.setRequestHeader(
10851			"Accept",
10852			s.dataTypes[ 0 ] && s.accepts[ s.dataTypes[ 0 ] ] ?
10853				s.accepts[ s.dataTypes[ 0 ] ] +
10854					( s.dataTypes[ 0 ] !== "*" ? ", " + allTypes + "; q=0.01" : "" ) :
10855				s.accepts[ "*" ]
10856		);
10857
10858		// Check for headers option
10859		for ( i in s.headers ) {
10860			jqXHR.setRequestHeader( i, s.headers[ i ] );
10861		}
10862
10863		// Allow custom headers/mimetypes and early abort
10864		if ( s.beforeSend &&
10865			( s.beforeSend.call( callbackContext, jqXHR, s ) === false || state === 2 ) ) {
10866
10867			// Abort if not done already and return
10868			return jqXHR.abort();
10869		}
10870
10871		// Aborting is no longer a cancellation
10872		strAbort = "abort";
10873
10874		// Install callbacks on deferreds
10875		for ( i in { success: 1, error: 1, complete: 1 } ) {
10876			jqXHR[ i ]( s[ i ] );
10877		}
10878
10879		// Get transport
10880		transport = inspectPrefiltersOrTransports( transports, s, options, jqXHR );
10881
10882		// If no transport, we auto-abort
10883		if ( !transport ) {
10884			done( -1, "No Transport" );
10885		} else {
10886			jqXHR.readyState = 1;
10887
10888			// Send global event
10889			if ( fireGlobals ) {
10890				globalEventContext.trigger( "ajaxSend", [ jqXHR, s ] );
10891			}
10892
10893			// If request was aborted inside ajaxSend, stop there
10894			if ( state === 2 ) {
10895				return jqXHR;
10896			}
10897
10898			// Timeout
10899			if ( s.async && s.timeout > 0 ) {
10900				timeoutTimer = window.setTimeout( function() {
10901					jqXHR.abort( "timeout" );
10902				}, s.timeout );
10903			}
10904
10905			try {
10906				state = 1;
10907				transport.send( requestHeaders, done );
10908			} catch ( e ) {
10909
10910				// Propagate exception as error if not done
10911				if ( state < 2 ) {
10912					done( -1, e );
10913
10914				// Simply rethrow otherwise
10915				} else {
10916					throw e;
10917				}
10918			}
10919		}
10920
10921		// Callback for when everything is done
10922		function done( status, nativeStatusText, responses, headers ) {
10923			var isSuccess, success, error, response, modified,
10924				statusText = nativeStatusText;
10925
10926			// Called once
10927			if ( state === 2 ) {
10928				return;
10929			}
10930
10931			// State is "done" now
10932			state = 2;
10933
10934			// Clear timeout if it exists
10935			if ( timeoutTimer ) {
10936				window.clearTimeout( timeoutTimer );
10937			}
10938
10939			// Dereference transport for early garbage collection
10940			// (no matter how long the jqXHR object will be used)
10941			transport = undefined;
10942
10943			// Cache response headers
10944			responseHeadersString = headers || "";
10945
10946			// Set readyState
10947			jqXHR.readyState = status > 0 ? 4 : 0;
10948
10949			// Determine if successful
10950			isSuccess = status >= 200 && status < 300 || status === 304;
10951
10952			// Get response data
10953			if ( responses ) {
10954				response = ajaxHandleResponses( s, jqXHR, responses );
10955			}
10956
10957			// Convert no matter what (that way responseXXX fields are always set)
10958			response = ajaxConvert( s, response, jqXHR, isSuccess );
10959
10960			// If successful, handle type chaining
10961			if ( isSuccess ) {
10962
10963				// Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.
10964				if ( s.ifModified ) {
10965					modified = jqXHR.getResponseHeader( "Last-Modified" );
10966					if ( modified ) {
10967						jQuery.lastModified[ cacheURL ] = modified;
10968					}
10969					modified = jqXHR.getResponseHeader( "etag" );
10970					if ( modified ) {
10971						jQuery.etag[ cacheURL ] = modified;
10972					}
10973				}
10974
10975				// if no content
10976				if ( status === 204 || s.type === "HEAD" ) {
10977					statusText = "nocontent";
10978
10979				// if not modified
10980				} else if ( status === 304 ) {
10981					statusText = "notmodified";
10982
10983				// If we have data, let's convert it
10984				} else {
10985					statusText = response.state;
10986					success = response.data;
10987					error = response.error;
10988					isSuccess = !error;
10989				}
10990			} else {
10991
10992				// Extract error from statusText and normalize for non-aborts
10993				error = statusText;
10994				if ( status || !statusText ) {
10995					statusText = "error";
10996					if ( status < 0 ) {
10997						status = 0;
10998					}
10999				}
11000			}
11001
11002			// Set data for the fake xhr object
11003			jqXHR.status = status;
11004			jqXHR.statusText = ( nativeStatusText || statusText ) + "";
11005
11006			// Success/Error
11007			if ( isSuccess ) {
11008				deferred.resolveWith( callbackContext, [ success, statusText, jqXHR ] );
11009			} else {
11010				deferred.rejectWith( callbackContext, [ jqXHR, statusText, error ] );
11011			}
11012
11013			// Status-dependent callbacks
11014			jqXHR.statusCode( statusCode );
11015			statusCode = undefined;
11016
11017			if ( fireGlobals ) {
11018				globalEventContext.trigger( isSuccess ? "ajaxSuccess" : "ajaxError",
11019					[ jqXHR, s, isSuccess ? success : error ] );
11020			}
11021
11022			// Complete
11023			completeDeferred.fireWith( callbackContext, [ jqXHR, statusText ] );
11024
11025			if ( fireGlobals ) {
11026				globalEventContext.trigger( "ajaxComplete", [ jqXHR, s ] );
11027
11028				// Handle the global AJAX counter
11029				if ( !( --jQuery.active ) ) {
11030					jQuery.event.trigger( "ajaxStop" );
11031				}
11032			}
11033		}
11034
11035		return jqXHR;
11036	},
11037
11038	getJSON: function( url, data, callback ) {
11039		return jQuery.get( url, data, callback, "json" );
11040	},
11041
11042	getScript: function( url, callback ) {
11043		return jQuery.get( url, undefined, callback, "script" );
11044	}
11045} );
11046
11047jQuery.each( [ "get", "post" ], function( i, method ) {
11048	jQuery[ method ] = function( url, data, callback, type ) {
11049
11050		// Shift arguments if data argument was omitted
11051		if ( jQuery.isFunction( data ) ) {
11052			type = type || callback;
11053			callback = data;
11054			data = undefined;
11055		}
11056
11057		// The url can be an options object (which then must have .url)
11058		return jQuery.ajax( jQuery.extend( {
11059			url: url,
11060			type: method,
11061			dataType: type,
11062			data: data,
11063			success: callback
11064		}, jQuery.isPlainObject( url ) && url ) );
11065	};
11066} );
11067
11068
11069jQuery._evalUrl = function( url ) {
11070	return jQuery.ajax( {
11071		url: url,
11072
11073		// Make this explicit, since user can override this through ajaxSetup (#11264)
11074		type: "GET",
11075		dataType: "script",
11076		async: false,
11077		global: false,
11078		"throws": true
11079	} );
11080};
11081
11082
11083jQuery.fn.extend( {
11084	wrapAll: function( html ) {
11085		var wrap;
11086
11087		if ( jQuery.isFunction( html ) ) {
11088			return this.each( function( i ) {
11089				jQuery( this ).wrapAll( html.call( this, i ) );
11090			} );
11091		}
11092
11093		if ( this[ 0 ] ) {
11094
11095			// The elements to wrap the target around
11096			wrap = jQuery( html, this[ 0 ].ownerDocument ).eq( 0 ).clone( true );
11097
11098			if ( this[ 0 ].parentNode ) {
11099				wrap.insertBefore( this[ 0 ] );
11100			}
11101
11102			wrap.map( function() {
11103				var elem = this;
11104
11105				while ( elem.firstElementChild ) {
11106					elem = elem.firstElementChild;
11107				}
11108
11109				return elem;
11110			} ).append( this );
11111		}
11112
11113		return this;
11114	},
11115
11116	wrapInner: function( html ) {
11117		if ( jQuery.isFunction( html ) ) {
11118			return this.each( function( i ) {
11119				jQuery( this ).wrapInner( html.call( this, i ) );
11120			} );
11121		}
11122
11123		return this.each( function() {
11124			var self = jQuery( this ),
11125				contents = self.contents();
11126
11127			if ( contents.length ) {
11128				contents.wrapAll( html );
11129
11130			} else {
11131				self.append( html );
11132			}
11133		} );
11134	},
11135
11136	wrap: function( html ) {
11137		var isFunction = jQuery.isFunction( html );
11138
11139		return this.each( function( i ) {
11140			jQuery( this ).wrapAll( isFunction ? html.call( this, i ) : html );
11141		} );
11142	},
11143
11144	unwrap: function() {
11145		return this.parent().each( function() {
11146			if ( !jQuery.nodeName( this, "body" ) ) {
11147				jQuery( this ).replaceWith( this.childNodes );
11148			}
11149		} ).end();
11150	}
11151} );
11152
11153
11154jQuery.expr.filters.hidden = function( elem ) {
11155	return !jQuery.expr.filters.visible( elem );
11156};
11157jQuery.expr.filters.visible = function( elem ) {
11158
11159	// Support: Opera <= 12.12
11160	// Opera reports offsetWidths and offsetHeights less than zero on some elements
11161	// Use OR instead of AND as the element is not visible if either is true
11162	// See tickets #10406 and #13132
11163	return elem.offsetWidth > 0 || elem.offsetHeight > 0 || elem.getClientRects().length > 0;
11164};
11165
11166
11167
11168
11169var r20 = /%20/g,
11170	rbracket = /\[\]$/,
11171	rCRLF = /\r?\n/g,
11172	rsubmitterTypes = /^(?:submit|button|image|reset|file)$/i,
11173	rsubmittable = /^(?:input|select|textarea|keygen)/i;
11174
11175function buildParams( prefix, obj, traditional, add ) {
11176	var name;
11177
11178	if ( jQuery.isArray( obj ) ) {
11179
11180		// Serialize array item.
11181		jQuery.each( obj, function( i, v ) {
11182			if ( traditional || rbracket.test( prefix ) ) {
11183
11184				// Treat each array item as a scalar.
11185				add( prefix, v );
11186
11187			} else {
11188
11189				// Item is non-scalar (array or object), encode its numeric index.
11190				buildParams(
11191					prefix + "[" + ( typeof v === "object" && v != null ? i : "" ) + "]",
11192					v,
11193					traditional,
11194					add
11195				);
11196			}
11197		} );
11198
11199	} else if ( !traditional && jQuery.type( obj ) === "object" ) {
11200
11201		// Serialize object item.
11202		for ( name in obj ) {
11203			buildParams( prefix + "[" + name + "]", obj[ name ], traditional, add );
11204		}
11205
11206	} else {
11207
11208		// Serialize scalar item.
11209		add( prefix, obj );
11210	}
11211}
11212
11213// Serialize an array of form elements or a set of
11214// key/values into a query string
11215jQuery.param = function( a, traditional ) {
11216	var prefix,
11217		s = [],
11218		add = function( key, value ) {
11219
11220			// If value is a function, invoke it and return its value
11221			value = jQuery.isFunction( value ) ? value() : ( value == null ? "" : value );
11222			s[ s.length ] = encodeURIComponent( key ) + "=" + encodeURIComponent( value );
11223		};
11224
11225	// Set traditional to true for jQuery <= 1.3.2 behavior.
11226	if ( traditional === undefined ) {
11227		traditional = jQuery.ajaxSettings && jQuery.ajaxSettings.traditional;
11228	}
11229
11230	// If an array was passed in, assume that it is an array of form elements.
11231	if ( jQuery.isArray( a ) || ( a.jquery && !jQuery.isPlainObject( a ) ) ) {
11232
11233		// Serialize the form elements
11234		jQuery.each( a, function() {
11235			add( this.name, this.value );
11236		} );
11237
11238	} else {
11239
11240		// If traditional, encode the "old" way (the way 1.3.2 or older
11241		// did it), otherwise encode params recursively.
11242		for ( prefix in a ) {
11243			buildParams( prefix, a[ prefix ], traditional, add );
11244		}
11245	}
11246
11247	// Return the resulting serialization
11248	return s.join( "&" ).replace( r20, "+" );
11249};
11250
11251jQuery.fn.extend( {
11252	serialize: function() {
11253		return jQuery.param( this.serializeArray() );
11254	},
11255	serializeArray: function() {
11256		return this.map( function() {
11257
11258			// Can add propHook for "elements" to filter or add form elements
11259			var elements = jQuery.prop( this, "elements" );
11260			return elements ? jQuery.makeArray( elements ) : this;
11261		} )
11262		.filter( function() {
11263			var type = this.type;
11264
11265			// Use .is( ":disabled" ) so that fieldset[disabled] works
11266			return this.name && !jQuery( this ).is( ":disabled" ) &&
11267				rsubmittable.test( this.nodeName ) && !rsubmitterTypes.test( type ) &&
11268				( this.checked || !rcheckableType.test( type ) );
11269		} )
11270		.map( function( i, elem ) {
11271			var val = jQuery( this ).val();
11272
11273			return val == null ?
11274				null :
11275				jQuery.isArray( val ) ?
11276					jQuery.map( val, function( val ) {
11277						return { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
11278					} ) :
11279					{ name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
11280		} ).get();
11281	}
11282} );
11283
11284
11285jQuery.ajaxSettings.xhr = function() {
11286	try {
11287		return new window.XMLHttpRequest();
11288	} catch ( e ) {}
11289};
11290
11291var xhrSuccessStatus = {
11292
11293		// File protocol always yields status code 0, assume 200
11294		0: 200,
11295
11296		// Support: IE9
11297		// #1450: sometimes IE returns 1223 when it should be 204
11298		1223: 204
11299	},
11300	xhrSupported = jQuery.ajaxSettings.xhr();
11301
11302support.cors = !!xhrSupported && ( "withCredentials" in xhrSupported );
11303support.ajax = xhrSupported = !!xhrSupported;
11304
11305jQuery.ajaxTransport( function( options ) {
11306	var callback, errorCallback;
11307
11308	// Cross domain only allowed if supported through XMLHttpRequest
11309	if ( support.cors || xhrSupported && !options.crossDomain ) {
11310		return {
11311			send: function( headers, complete ) {
11312				var i,
11313					xhr = options.xhr();
11314
11315				xhr.open(
11316					options.type,
11317					options.url,
11318					options.async,
11319					options.username,
11320					options.password
11321				);
11322
11323				// Apply custom fields if provided
11324				if ( options.xhrFields ) {
11325					for ( i in options.xhrFields ) {
11326						xhr[ i ] = options.xhrFields[ i ];
11327					}
11328				}
11329
11330				// Override mime type if needed
11331				if ( options.mimeType && xhr.overrideMimeType ) {
11332					xhr.overrideMimeType( options.mimeType );
11333				}
11334
11335				// X-Requested-With header
11336				// For cross-domain requests, seeing as conditions for a preflight are
11337				// akin to a jigsaw puzzle, we simply never set it to be sure.
11338				// (it can always be set on a per-request basis or even using ajaxSetup)
vendor: 5,386 bytes, lines 11339-11552
11339				// For same-domain requests, won't change header if already provided.
11340				if ( !options.crossDomain && !headers[ "X-Requested-With" ] ) {
11341					headers[ "X-Requested-With" ] = "XMLHttpRequest";
11342				}
11343
11344				// Set headers
11345				for ( i in headers ) {
11346					xhr.setRequestHeader( i, headers[ i ] );
11347				}
11348
11349				// Callback
11350				callback = function( type ) {
11351					return function() {
11352						if ( callback ) {
11353							callback = errorCallback = xhr.onload =
11354								xhr.onerror = xhr.onabort = xhr.onreadystatechange = null;
11355
11356							if ( type === "abort" ) {
11357								xhr.abort();
11358							} else if ( type === "error" ) {
11359
11360								// Support: IE9
11361								// On a manual native abort, IE9 throws
11362								// errors on any property access that is not readyState
11363								if ( typeof xhr.status !== "number" ) {
11364									complete( 0, "error" );
11365								} else {
11366									complete(
11367
11368										// File: protocol always yields status 0; see #8605, #14207
11369										xhr.status,
11370										xhr.statusText
11371									);
11372								}
11373							} else {
11374								complete(
11375									xhrSuccessStatus[ xhr.status ] || xhr.status,
11376									xhr.statusText,
11377
11378									// Support: IE9 only
11379									// IE9 has no XHR2 but throws on binary (trac-11426)
11380									// For XHR2 non-text, let the caller handle it (gh-2498)
11381									( xhr.responseType || "text" ) !== "text"  ||
11382									typeof xhr.responseText !== "string" ?
11383										{ binary: xhr.response } :
11384										{ text: xhr.responseText },
11385									xhr.getAllResponseHeaders()
11386								);
11387							}
11388						}
11389					};
11390				};
11391
11392				// Listen to events
11393				xhr.onload = callback();
11394				errorCallback = xhr.onerror = callback( "error" );
11395
11396				// Support: IE9
11397				// Use onreadystatechange to replace onabort
11398				// to handle uncaught aborts
11399				if ( xhr.onabort !== undefined ) {
11400					xhr.onabort = errorCallback;
11401				} else {
11402					xhr.onreadystatechange = function() {
11403
11404						// Check readyState before timeout as it changes
11405						if ( xhr.readyState === 4 ) {
11406
11407							// Allow onerror to be called first,
11408							// but that will not handle a native abort
11409							// Also, save errorCallback to a variable
11410							// as xhr.onerror cannot be accessed
11411							window.setTimeout( function() {
11412								if ( callback ) {
11413									errorCallback();
11414								}
11415							} );
11416						}
11417					};
11418				}
11419
11420				// Create the abort callback
11421				callback = callback( "abort" );
11422
11423				try {
11424
11425					// Do send the request (this may raise an exception)
11426					xhr.send( options.hasContent && options.data || null );
11427				} catch ( e ) {
11428
11429					// #14683: Only rethrow if this hasn't been notified as an error yet
11430					if ( callback ) {
11431						throw e;
11432					}
11433				}
11434			},
11435
11436			abort: function() {
11437				if ( callback ) {
11438					callback();
11439				}
11440			}
11441		};
11442	}
11443} );
11444
11445
11446
11447
11448// Install script dataType
11449jQuery.ajaxSetup( {
11450	accepts: {
11451		script: "text/javascript, application/javascript, " +
11452			"application/ecmascript, application/x-ecmascript"
11453	},
11454	contents: {
11455		script: /\b(?:java|ecma)script\b/
11456	},
11457	converters: {
11458		"text script": function( text ) {
11459			jQuery.globalEval( text );
11460			return text;
11461		}
11462	}
11463} );
11464
11465// Handle cache's special case and crossDomain
11466jQuery.ajaxPrefilter( "script", function( s ) {
11467	if ( s.cache === undefined ) {
11468		s.cache = false;
11469	}
11470	if ( s.crossDomain ) {
11471		s.type = "GET";
11472	}
11473} );
11474
11475// Bind script tag hack transport
11476jQuery.ajaxTransport( "script", function( s ) {
11477
11478	// This transport only deals with cross domain requests
11479	if ( s.crossDomain ) {
11480		var script, callback;
11481		return {
11482			send: function( _, complete ) {
11483				script = jQuery( "<script>" ).prop( {
11484					charset: s.scriptCharset,
11485					src: s.url
11486				} ).on(
11487					"load error",
11488					callback = function( evt ) {
11489						script.remove();
11490						callback = null;
11491						if ( evt ) {
11492							complete( evt.type === "error" ? 404 : 200, evt.type );
11493						}
11494					}
11495				);
11496
11497				// Use native DOM manipulation to avoid our domManip AJAX trickery
11498				document.head.appendChild( script[ 0 ] );
11499			},
11500			abort: function() {
11501				if ( callback ) {
11502					callback();
11503				}
11504			}
11505		};
11506	}
11507} );
11508
11509
11510
11511
11512var oldCallbacks = [],
11513	rjsonp = /(=)\?(?=&|$)|\?\?/;
11514
11515// Default jsonp settings
11516jQuery.ajaxSetup( {
11517	jsonp: "callback",
11518	jsonpCallback: function() {
11519		var callback = oldCallbacks.pop() || ( jQuery.expando + "_" + ( nonce++ ) );
11520		this[ callback ] = true;
11521		return callback;
11522	}
11523} );
11524
11525// Detect, normalize options and install callbacks for jsonp requests
11526jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) {
11527
11528	var callbackName, overwritten, responseContainer,
11529		jsonProp = s.jsonp !== false && ( rjsonp.test( s.url ) ?
11530			"url" :
11531			typeof s.data === "string" &&
11532				( s.contentType || "" )
11533					.indexOf( "application/x-www-form-urlencoded" ) === 0 &&
11534				rjsonp.test( s.data ) && "data"
11535		);
11536
11537	// Handle iff the expected data type is "jsonp" or we have a parameter to set
11538	if ( jsonProp || s.dataTypes[ 0 ] === "jsonp" ) {
11539
11540		// Get callback name, remembering preexisting value associated with it
11541		callbackName = s.jsonpCallback = jQuery.isFunction( s.jsonpCallback ) ?
11542			s.jsonpCallback() :
11543			s.jsonpCallback;
11544
11545		// Insert callback into url or form data
11546		if ( jsonProp ) {
11547			s[ jsonProp ] = s[ jsonProp ].replace( rjsonp, "$1" + callbackName );
11548		} else if ( s.jsonp !== false ) {
11549			s.url += ( rquery.test( s.url ) ? "&" : "?" ) + s.jsonp + "=" + callbackName;
11550		}
11551
11552		// Use data converter to retrieve json after script execution
11553		s.converters[ "script json" ] = function() {
11554			if ( !responseContainer ) {
11555				jQuery.error( callbackName + " was not called" );
11556			}
11557			return responseContainer[ 0 ];
11558		};
11559
11560		// Force json dataType
11561		s.dataTypes[ 0 ] = "json";
11562
11563		// Install callback
11564		overwritten = window[ callbackName ];
11565		window[ callbackName ] = function() {
11566			responseContainer = arguments;
11567		};
11568
11569		// Clean-up function (fires after converters)
11570		jqXHR.always( function() {
11571
11572			// If previous value didn't exist - remove it
11573			if ( overwritten === undefined ) {
11574				jQuery( window ).removeProp( callbackName );
11575
11576			// Otherwise restore preexisting value
11577			} else {
11578				window[ callbackName ] = overwritten;
11579			}
11580
11581			// Save back as free
11582			if ( s[ callbackName ] ) {
11583
11584				// Make sure that re-using the options doesn't screw things around
11585				s.jsonpCallback = originalSettings.jsonpCallback;
11586
11587				// Save the callback name for future use
11588				oldCallbacks.push( callbackName );
11589			}
11590
11591			// Call if it was a function and we have a response
11592			if ( responseContainer && jQuery.isFunction( overwritten ) ) {
11593				overwritten( responseContainer[ 0 ] );
11594			}
11595
11596			responseContainer = overwritten = undefined;
11597		} );
11598
11599		// Delegate to script
11600		return "script";
11601	}
11602} );
11603
11604
11605
11606
11607// Argument "data" should be string of html
11608// context (optional): If specified, the fragment will be created in this context,
11609// defaults to document
11610// keepScripts (optional): If true, will include scripts passed in the html string
11611jQuery.parseHTML = function( data, context, keepScripts ) {
11612	if ( !data || typeof data !== "string" ) {
11613		return null;
11614	}
11615	if ( typeof context === "boolean" ) {
11616		keepScripts = context;
11617		context = false;
11618	}
11619	context = context || document;
11620
11621	var parsed = rsingleTag.exec( data ),
11622		scripts = !keepScripts && [];
11623
11624	// Single tag
11625	if ( parsed ) {
11626		return [ context.createElement( parsed[ 1 ] ) ];
11627	}
11628
11629	parsed = buildFragment( [ data ], context, scripts );
11630
11631	if ( scripts && scripts.length ) {
11632		jQuery( scripts ).remove();
11633	}
11634
11635	return jQuery.merge( [], parsed.childNodes );
11636};
11637
11638
11639// Keep a copy of the old load method
11640var _load = jQuery.fn.load;
11641
11642/**
11643 * Load a url into a page
11644 */
11645jQuery.fn.load = function( url, params, callback ) {
11646	if ( typeof url !== "string" && _load ) {
11647		return _load.apply( this, arguments );
11648	}
11649
11650	var selector, type, response,
11651		self = this,
11652		off = url.indexOf( " " );
11653
11654	if ( off > -1 ) {
11655		selector = jQuery.trim( url.slice( off ) );
11656		url = url.slice( 0, off );
11657	}
11658
11659	// If it's a function
11660	if ( jQuery.isFunction( params ) ) {
11661
11662		// We assume that it's the callback
11663		callback = params;
11664		params = undefined;
11665
11666	// Otherwise, build a param string
11667	} else if ( params && typeof params === "object" ) {
11668		type = "POST";
11669	}
11670
11671	// If we have elements to modify, make the request
11672	if ( self.length > 0 ) {
11673		jQuery.ajax( {
11674			url: url,
11675
11676			// If "type" variable is undefined, then "GET" method will be used.
11677			// Make value of this field explicit since
11678			// user can override it through ajaxSetup method
11679			type: type || "GET",
11680			dataType: "html",
11681			data: params
11682		} ).done( function( responseText ) {
11683
11684			// Save response for use in complete callback
11685			response = arguments;
11686
11687			self.html( selector ?
11688
11689				// If a selector was specified, locate the right elements in a dummy div
11690				// Exclude scripts to avoid IE 'Permission Denied' errors
11691				jQuery( "<div>" ).append( jQuery.parseHTML( responseText ) ).find( selector ) :
11692
11693				// Otherwise use the full result
11694				responseText );
11695
11696		// If the request succeeds, this function gets "data", "status", "jqXHR"
11697		// but they are ignored because response was set above.
11698		// If it fails, this function gets "jqXHR", "status", "error"
11699		} ).always( callback && function( jqXHR, status ) {
11700			self.each( function() {
11701				callback.apply( this, response || [ jqXHR.responseText, status, jqXHR ] );
11702			} );
11703		} );
11704	}
11705
11706	return this;
11707};
11708
11709
11710
11711
11712// Attach a bunch of functions for handling common AJAX events
11713jQuery.each( [
11714	"ajaxStart",
11715	"ajaxStop",
11716	"ajaxComplete",
11717	"ajaxError",
11718	"ajaxSuccess",
11719	"ajaxSend"
11720], function( i, type ) {
11721	jQuery.fn[ type ] = function( fn ) {
11722		return this.on( type, fn );
11723	};
11724} );
11725
11726
11727
11728
11729jQuery.expr.filters.animated = function( elem ) {
11730	return jQuery.grep( jQuery.timers, function( fn ) {
11731		return elem === fn.elem;
11732	} ).length;
11733};
11734
11735
11736
11737
11738/**
11739 * Gets a window from an element
11740 */
11741function getWindow( elem ) {
11742	return jQuery.isWindow( elem ) ? elem : elem.nodeType === 9 && elem.defaultView;
11743}
11744
11745jQuery.offset = {
11746	setOffset: function( elem, options, i ) {
11747		var curPosition, curLeft, curCSSTop, curTop, curOffset, curCSSLeft, calculatePosition,
11748			position = jQuery.css( elem, "position" ),
11749			curElem = jQuery( elem ),
11750			props = {};
11751
11752		// Set position first, in-case top/left are set even on static elem
11753		if ( position === "static" ) {
11754			elem.style.position = "relative";
11755		}
11756
11757		curOffset = curElem.offset();
11758		curCSSTop = jQuery.css( elem, "top" );
11759		curCSSLeft = jQuery.css( elem, "left" );
11760		calculatePosition = ( position === "absolute" || position === "fixed" ) &&
11761			( curCSSTop + curCSSLeft ).indexOf( "auto" ) > -1;
11762
11763		// Need to be able to calculate position if either
11764		// top or left is auto and position is either absolute or fixed
11765		if ( calculatePosition ) {
11766			curPosition = curElem.position();
11767			curTop = curPosition.top;
11768			curLeft = curPosition.left;
11769
11770		} else {
11771			curTop = parseFloat( curCSSTop ) || 0;
11772			curLeft = parseFloat( curCSSLeft ) || 0;
11773		}
11774
11775		if ( jQuery.isFunction( options ) ) {
11776
11777			// Use jQuery.extend here to allow modification of coordinates argument (gh-1848)
11778			options = options.call( elem, i, jQuery.extend( {}, curOffset ) );
11779		}
11780
11781		if ( options.top != null ) {
11782			props.top = ( options.top - curOffset.top ) + curTop;
11783		}
11784		if ( options.left != null ) {
11785			props.left = ( options.left - curOffset.left ) + curLeft;
11786		}
11787
11788		if ( "using" in options ) {
11789			options.using.call( elem, props );
11790
11791		} else {
11792			curElem.css( props );
11793		}
11794	}
11795};
11796
11797jQuery.fn.extend( {
11798	offset: function( options ) {
11799		if ( arguments.length ) {
11800			return options === undefined ?
11801				this :
11802				this.each( function( i ) {
11803					jQuery.offset.setOffset( this, options, i );
11804				} );
11805		}
11806
11807		var docElem, win,
11808			elem = this[ 0 ],
11809			box = { top: 0, left: 0 },
11810			doc = elem && elem.ownerDocument;
11811
11812		if ( !doc ) {
11813			return;
11814		}
11815
11816		docElem = doc.documentElement;
11817
11818		// Make sure it's not a disconnected DOM node
11819		if ( !jQuery.contains( docElem, elem ) ) {
11820			return box;
11821		}
11822
11823		box = elem.getBoundingClientRect();
11824		win = getWindow( doc );
11825		return {
11826			top: box.top + win.pageYOffset - docElem.clientTop,
11827			left: box.left + win.pageXOffset - docElem.clientLeft
11828		};
11829	},
11830
11831	position: function() {
11832		if ( !this[ 0 ] ) {
11833			return;
11834		}
11835
11836		var offsetParent, offset,
11837			elem = this[ 0 ],
11838			parentOffset = { top: 0, left: 0 };
11839
11840		// Fixed elements are offset from window (parentOffset = {top:0, left
vendor: 6,137 bytes, lines 11840-12026
11840: 0},
11841		// because it is its only offset parent
11842		if ( jQuery.css( elem, "position" ) === "fixed" ) {
11843
11844			// Assume getBoundingClientRect is there when computed position is fixed
11845			offset = elem.getBoundingClientRect();
11846
11847		} else {
11848
11849			// Get *real* offsetParent
11850			offsetParent = this.offsetParent();
11851
11852			// Get correct offsets
11853			offset = this.offset();
11854			if ( !jQuery.nodeName( offsetParent[ 0 ], "html" ) ) {
11855				parentOffset = offsetParent.offset();
11856			}
11857
11858			// Add offsetParent borders
11859			parentOffset.top += jQuery.css( offsetParent[ 0 ], "borderTopWidth", true );
11860			parentOffset.left += jQuery.css( offsetParent[ 0 ], "borderLeftWidth", true );
11861		}
11862
11863		// Subtract parent offsets and element margins
11864		return {
11865			top: offset.top - parentOffset.top - jQuery.css( elem, "marginTop", true ),
11866			left: offset.left - parentOffset.left - jQuery.css( elem, "marginLeft", true )
11867		};
11868	},
11869
11870	// This method will return documentElement in the following cases:
11871	// 1) For the element inside the iframe without offsetParent, this method will return
11872	//    documentElement of the parent window
11873	// 2) For the hidden or detached element
11874	// 3) For body or html element, i.e. in case of the html node - it will return itself
11875	//
11876	// but those exceptions were never presented as a real life use-cases
11877	// and might be considered as more preferable results.
11878	//
11879	// This logic, however, is not guaranteed and can change at any point in the future
11880	offsetParent: function() {
11881		return this.map( function() {
11882			var offsetParent = this.offsetParent;
11883
11884			while ( offsetParent && jQuery.css( offsetParent, "position" ) === "static" ) {
11885				offsetParent = offsetParent.offsetParent;
11886			}
11887
11888			return offsetParent || documentElement;
11889		} );
11890	}
11891} );
11892
11893// Create scrollLeft and scrollTop methods
11894jQuery.each( { scrollLeft: "pageXOffset", scrollTop: "pageYOffset" }, function( method, prop ) {
11895	var top = "pageYOffset" === prop;
11896
11897	jQuery.fn[ method ] = function( val ) {
11898		return access( this, function( elem, method, val ) {
11899			var win = getWindow( elem );
11900
11901			if ( val === undefined ) {
11902				return win ? win[ prop ] : elem[ method ];
11903			}
11904
11905			if ( win ) {
11906				win.scrollTo(
11907					!top ? val : win.pageXOffset,
11908					top ? val : win.pageYOffset
11909				);
11910
11911			} else {
11912				elem[ method ] = val;
11913			}
11914		}, method, val, arguments.length );
11915	};
11916} );
11917
11918// Support: Safari<7-8+, Chrome<37-44+
11919// Add the top/left cssHooks using jQuery.fn.position
11920// Webkit bug: https://bugs.webkit.org/show_bug.cgi?id=29084
11921// Blink bug: https://code.google.com/p/chromium/issues/detail?id=229280
11922// getComputedStyle returns percent when specified for top/left/bottom/right;
11923// rather than make the css module depend on the offset module, just check for it here
11924jQuery.each( [ "top", "left" ], function( i, prop ) {
11925	jQuery.cssHooks[ prop ] = addGetHookIf( support.pixelPosition,
11926		function( elem, computed ) {
11927			if ( computed ) {
11928				computed = curCSS( elem, prop );
11929
11930				// If curCSS returns percentage, fallback to offset
11931				return rnumnonpx.test( computed ) ?
11932					jQuery( elem ).position()[ prop ] + "px" :
11933					computed;
11934			}
11935		}
11936	);
11937} );
11938
11939
11940// Create innerHeight, innerWidth, height, width, outerHeight and outerWidth methods
11941jQuery.each( { Height: "height", Width: "width" }, function( name, type ) {
11942	jQuery.each( { padding: "inner" + name, content: type, "": "outer" + name },
11943		function( defaultExtra, funcName ) {
11944
11945		// Margin is only for outerHeight, outerWidth
11946		jQuery.fn[ funcName ] = function( margin, value ) {
11947			var chainable = arguments.length && ( defaultExtra || typeof margin !== "boolean" ),
11948				extra = defaultExtra || ( margin === true || value === true ? "margin" : "border" );
11949
11950			return access( this, function( elem, type, value ) {
11951				var doc;
11952
11953				if ( jQuery.isWindow( elem ) ) {
11954
11955					// As of 5/8/2012 this will yield incorrect results for Mobile Safari, but there
11956					// isn't a whole lot we can do. See pull request at this URL for discussion:
11957					// https://github.com/jquery/jquery/pull/764
11958					return elem.document.documentElement[ "client" + name ];
11959				}
11960
11961				// Get document width or height
11962				if ( elem.nodeType === 9 ) {
11963					doc = elem.documentElement;
11964
11965					// Either scroll[Width/Height] or offset[Width/Height] or client[Width/Height],
11966					// whichever is greatest
11967					return Math.max(
11968						elem.body[ "scroll" + name ], doc[ "scroll" + name ],
11969						elem.body[ "offset" + name ], doc[ "offset" + name ],
11970						doc[ "client" + name ]
11971					);
11972				}
11973
11974				return value === undefined ?
11975
11976					// Get width or height on the element, requesting but not forcing parseFloat
11977					jQuery.css( elem, type, extra ) :
11978
11979					// Set width or height on the element
11980					jQuery.style( elem, type, value, extra );
11981			}, type, chainable ? margin : undefined, chainable, null );
11982		};
11983	} );
11984} );
11985
11986
11987jQuery.fn.extend( {
11988
11989	bind: function( types, data, fn ) {
11990		return this.on( types, null, data, fn );
11991	},
11992	unbind: function( types, fn ) {
11993		return this.off( types, null, fn );
11994	},
11995
11996	delegate: function( selector, types, data, fn ) {
11997		return this.on( types, selector, data, fn );
11998	},
11999	undelegate: function( selector, types, fn ) {
12000
12001		// ( namespace ) or ( selector, types [, fn] )
12002		return arguments.length === 1 ?
12003			this.off( selector, "**" ) :
12004			this.off( types, selector || "**", fn );
12005	},
12006	size: function() {
12007		return this.length;
12008	}
12009} );
12010
12011jQuery.fn.andSelf = jQuery.fn.addBack;
12012
12013
12014
12015
12016// Register as a named AMD module, since jQuery can be concatenated with other
12017// files that may use define, but not via a proper concatenation script that
12018// understands anonymous AMD modules. A named AMD is safest and most robust
12019// way to register. Lowercase jquery is used because AMD module names are
12020// derived from file names, and jQuery is normally delivered in a lowercase
12021// file name. Do this after creating the global so that if an AMD module wants
12022// to call noConflict to hide this version of jQuery, it will work.
12023
12024// Note that for maximum portability, libraries that are not jQuery should
12025// declare themselves as anonymous modules, and avoid setting a global if an
12026// AMD loader is present. jQuery is a special case. For more information, see
12027// https://github.com/jrburke/requirejs/wiki/Updating-existing-libraries#wiki-anon
12028
12029if ( typeof define === "function" && define.amd ) {
12030	define( "jquery", [], function() {
12031		return jQuery;
12032	} );
12033}
12034
12035
12036
12037var
12038
12039	// Map over jQuery in case of overwrite
12040	_jQuery = window.jQuery,
12041
12042	// Map over the $ in case of overwrite
12043	_$ = window.$;
12044
12045jQuery.noConflict = function( deep ) {
12046	if ( window.$ === jQuery ) {
12047		window.$ = _$;
12048	}
12049
12050	if ( deep && window.jQuery === jQuery ) {
12051		window.jQuery = _jQuery;
12052	}
12053
12054	return jQuery;
12055};
12056
12057// Expose jQuery and $ identifiers, even in AMD
12058// (#7102#comment:10, https://github.com/jquery/jquery/pull/557)
12059// and CommonJS for browser emulators (#13566)
12060if ( !noGlobal ) {
12061	window.jQuery = window.$ = jQuery;
12062}
12063
12064return jQuery;
12065}));
12066
12067},{}],15:[function(require,module,exports){
12068/*!
12069 * JavaScript Cookie v2.1.4
12070 * https://github.com/js-cookie/js-cookie
12071 *
12072 * Copyright 2006, 2015 Klaus Hartl & Fagner Brack
12073 * Released under the MIT license
12074 */
12075;(function (factory) {
12076	var registeredInModuleLoader = false;
12077	if (typeof define === 'function' && define.amd) {
12078		define(factory);
12079		registeredInModuleLoader = true;
12080	}
12081	if (typeof exports === 'object') {
12082		module.exports = factory();
12083		registeredInModuleLoader = true;
12084	}
12085	if (!registeredInModuleLoader) {
12086		var OldCookies = window.Cookies;
12087		var api = window.Cookies = factory();
12088		api.noConflict = function () {
12089			window.Cookies = OldCookies;
12090			return api;
12091		};
12092	}
12093}(function () {
12094	function extend () {
12095		var i = 0;
12096		var result = {};
12097		for (; i < arguments.length; i++) {
12098			var attributes = arguments[ i ];
12099			for (var key in attributes) {
12100				result[key] = attributes[key];
12101			}
12102		}
12103		return result;
12104	}
12105
12106	function init (converter) {
12107		function api (key, value, attributes) {
12108			var result;
12109			if (typeof document === 'undefined') {
12110				return;
12111			}
12112
12113			// Write
12114
12115			if (arguments.length > 1) {
12116				attributes = extend({
12117					path: '/'
12118				}, api.defaults, attributes);
12119
12120				if (typeof attributes.expires === 'number') {
12121					var expires = new Date();
12122					expires.setMilliseconds(expires.getMilliseconds() + attributes.expires * 864e+5);
12123					attributes.expires = expires;
12124				}
12125
12126				// We're using "expires" because "max-age" is not supported by IE
12127				attributes.expires = attributes.expires ? attributes.expires.toUTCString() : '';
12128
12129				try {
12130					result = JSON.stringify(value);
12131					if (/^[\{\[]/.test(result)) {
12132						value = result;
12133					}
12134				} catch (e) {}
12135
12136				if (!converter.write) {
12137					value = encodeURIComponent(String(value))
12138						.replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g, decodeURIComponent);
12139				} else {
12140					value = converter.write(value, key);
12141				}
12142
12143				key = encodeURIComponent(String(key));
12144				key = key.replace(/%(23|24|26|2B|5E|60|7C)/g, decodeURIComponent);
12145				key = key.replace(/[\(\)]/g, escape);
12146
12147				var stringifiedAttributes = '';
12148
12149				for (var attributeName in attributes) {
12150					if (!attributes[attributeName]) {
12151						continue;
12152					}
12153					stringifiedAttributes += '; ' + attributeName;
12154					if (attributes[attributeName] === true) {
12155						continue;
12156					}
12157					stringifiedAttributes += '=' + attributes[attributeName];
12158				}
12159				return (document.cookie = key + '=' + value + stringifiedAttributes);
12160			}
12161
12162			// Read
12163
12164			if (!key) {
12165				result = {};
12166			}
12167
12168			// To prevent the for loop in the first place assign an empty array
12169			// in case there are no cookies at all. Also prevents odd result when
12170			// calling "get()"
12171			var cookies = document.cookie ? document.cookie.split('; ') : [];
12172			var rdecode = /(%[0-9A-Z]{2})+/g;
12173			var i = 0;
12174
12175			for (; i < cookies.length; i++) {
12176				var parts = cookies[i].split('=');
12177				var cookie = parts.slice(1).join('=');
12178
12179				if (cookie.charAt(0) === '"') {
12180					cookie = cookie.slice(1, -1);
12181				}
12182
12183				try {
12184					var name = parts[0].replace(rdecode, decodeURIComponent);
12185					cookie = converter.read ?
12186						converter.read(cookie, name) : converter(cookie, name) ||
12187						cookie.replace(rdecode, decodeURIComponent);
12188
12189					if (this.json) {
12190						try {
12191							cookie = JSON.parse(cookie);
12192						} catch (e) {}
12193					}
12194
12195					if (key === name) {
12196						result = cookie;
12197						break;
12198					}
12199
12200					if (!key) {
12201						result[name] = cookie;
12202					}
12203				} catch (e) {}
12204			}
12205
12206			return result;
12207		}
12208
12209		api.set = api;
12210		api.get = function (key) {
12211			return api.call(api, key);
12212		};
12213		api.getJSON = function () {
12214			return api.apply({
12215				json: true
12216			}, [].slice.call(arguments));
12217		};
12218		api.defaults = {};
12219
12220		api.remove = function (key, attributes) {
12221			api(key, '', extend(attributes, {
12222				expires: -1
12223			}));
12224		};
12225
12226		api.withConverter = init;
12227
12228		return api;
12229	}
12230
12231	return init(function () {});
12232}));
12233
12234},{}],16:[function(require,module,exports){
12235!function(i){"use strict";"function"==typeof define&&define.amd?define(["jquery"],i):"undefined"!=typeof exports?module.exports=i(require("jquery")):i(jQuery)}(function(i){"use strict";var e=window.Slick||{};(e=function(){var e=0;return function(t,o){var s,n=this;n.defaults={accessibility:!0,adaptiveHeight:!1,appendArrows:i(t),appendDots:i(t),arrows:!0,asNavFor:null,prevArrow:'<button class="slick-prev" aria-label="Previous" type="button">Previous</button>',nextArrow:'<button class="slick-next" aria-label="Next" type="button">Next</button>',autoplay:!1,autoplaySpeed:3e3,centerMode:!1,centerPadding:"50px",cssEase:"ease",customPaging:function(e,t){return i('<button type="button" />').text(t+1)},dots:!1,dotsClass:"slick-dots",draggable:!0,easing:"linear",edgeFriction:.35,fade:!1,focusOnSelect:!1,focusOnChange:!1,infinite:!0,initialSlide:0,lazyLoad:"ondemand",mobileFirst:!1,pauseOnHover:!0,pauseOnFocus:!0,pauseOnDotsHover:!1,respondTo:"window",responsive:null,rows:1,rtl:!1,slide:"",slidesPerRow:1,slidesToShow:1,slidesToScroll:1,speed:500,swipe:!0,swipeToSlide:!1,touchMove:!0,touchThreshold:5,useCSS:!0,useTransform:!0,variableWidth:!1,vertical:!1,verticalSwiping:!1,waitForAnimate:!0,zIndex:1e3},n.initials={animating:!1,dragging:!1,autoPlayTimer:null,currentDirection:0,currentLeft:null,currentSlide:0,direction:1,$dots:null,listWidth:null,listHeight:null,loadIndex:0,$nextArrow:null,$prevArrow:null,scrolling:!1,slideCount:null,slideWidth:null,$slideTrack:null,$slides:null,
vendor: 6,594 bytes, line 12235
12235sliding:!1,slideOffset:0,swipeLeft:null,swiping:!1,$list:null,touchObject:{},transformsEnabled:!1,unslicked:!1},i.extend(n,n.initials),n.activeBreakpoint=null,n.animType=null,n.animProp=null,n.breakpoints=[],n.breakpointSettings=[],n.cssTransitions=!1,n.focussed=!1,n.interrupted=!1,n.hidden="hidden",n.paused=!0,n.positionProp=null,n.respondTo=null,n.rowCount=1,n.shouldClick=!0,n.$slider=i(t),n.$slidesCache=null,n.transformType=null,n.transitionType=null,n.visibilityChange="visibilitychange",n.windowWidth=0,n.windowTimer=null,s=i(t).data("slick")||{},n.options=i.extend({},n.defaults,o,s),n.currentSlide=n.options.initialSlide,n.originalSettings=n.options,void 0!==document.mozHidden?(n.hidden="mozHidden",n.visibilityChange="mozvisibilitychange"):void 0!==document.webkitHidden&&(n.hidden="webkitHidden",n.visibilityChange="webkitvisibilitychange"),n.autoPlay=i.proxy(n.autoPlay,n),n.autoPlayClear=i.proxy(n.autoPlayClear,n),n.autoPlayIterator=i.proxy(n.autoPlayIterator,n),n.changeSlide=i.proxy(n.changeSlide,n),n.clickHandler=i.proxy(n.clickHandler,n),n.selectHandler=i.proxy(n.selectHandler,n),n.setPosition=i.proxy(n.setPosition,n),n.swipeHandler=i.proxy(n.swipeHandler,n),n.dragHandler=i.proxy(n.dragHandler,n),n.keyHandler=i.proxy(n.keyHandler,n),n.instanceUid=e++,n.htmlExpr=/^(?:\s*(<[\w\W]+>)[^>]*)$/,n.registerBreakpoints(),n.init(!0)}}()).prototype.activateADA=function(){this.$slideTrack.find(".slick-active").attr({"aria-hidden":"false"}).find("a, input, button, select").attr({tabindex:"0"})},e.prototype.addSlide=e.prototype.slickAdd=function(e,t,o){var s=this;if("boolean"==typeof t)o=t,t=null;else if(t<0||t>=s.slideCount)return!1;s.unload(),"number"==typeof t?0===t&&0===s.$slides.length?i(e).appendTo(s.$slideTrack):o?i(e).insertBefore(s.$slides.eq(t)):i(e).insertAfter(s.$slides.eq(t)):!0===o?i(e).prependTo(s.$slideTrack):i(e).appendTo(s.$slideTrack),s.$slides=s.$slideTrack.children(this.options.slide),s.$slideTrack.children(this.options.slide).detach(),s.$slideTrack.append(s.$slides),s.$slides.each(function(e,t){i(t).attr("data-slick-index",e)}),s.$slidesCache=s.$slides,s.reinit()},e.prototype.animateHeight=function(){var i=this;if(1===i.options.slidesToShow&&!0===i.options.adaptiveHeight&&!1===i.options.vertical){var e=i.$slides.eq(i.currentSlide).outerHeight(!0);i.$list.animate({height:e},i.options.speed)}},e.prototype.animateSlide=function(e,t){var o={},s=this;s.animateHeight(),!0===s.options.rtl&&!1===s.options.vertical&&(e=-e),!1===s.transformsEnabled?!1===s.options.vertical?s.$slideTrack.animate({left:e},s.options.speed,s.options.easing,t):s.$slideTrack.animate({top:e},s.options.speed,s.options.easing,t):!1===s.cssTransitions?(!0===s.options.rtl&&(s.currentLeft=-s.currentLeft),i({animStart:s.currentLeft}).animate({animStart:e},{duration:s.options.speed,easing:s.options.easing,step:function(i){i=Math.ceil(i),!1===s.options.vertical?(o[s.animType]="translate("+i+"px, 0px)",s.$slideTrack.css(o)):(o[s.animType]="translate(0px,"+i+"px)",s.$slideTrack.css(o))},complete:function(){t&&t.call()}})):(s.applyTransition(),e=Math.ceil(e),!1===s.options.vertical?o[s.animType]="translate3d("+e+"px, 0px, 0px)":o[s.animType]="translate3d(0px,"+e+"px, 0px)",s.$slideTrack.css(o),t&&setTimeout(function(){s.disableTransition(),t.call()},s.options.speed))},e.prototype.getNavTarget=function(){var e=this,t=e.options.asNavFor;return t&&null!==t&&(t=i(t).not(e.$slider)),t},e.prototype.asNavFor=function(e){var t=this.getNavTarget();null!==t&&"object"==typeof t&&t.each(function(){var t=i(this).slick("getSlick");t.unslicked||t.slideHandler(e,!0)})},e.prototype.applyTransition=function(i){var e=this,t={};!1===e.options.fade?t[e.transitionType]=e.transformType+" "+e.options.speed+"ms "+e.options.cssEase:t[e.transitionType]="opacity "+e.options.speed+"ms "+e.options.cssEase,!1===e.options.fade?e.$slideTrack.css(t):e.$slides.eq(i).css(t)},e.prototype.autoPlay=function(){var i=this;i.autoPlayClear(),i.slideCount>i.options.slidesToShow&&(i.autoPlayTimer=setInterval(i.autoPlayIterator,i.options.autoplaySpeed))},e.prototype.autoPlayClear=function(){var i=this;i.autoPlayTimer&&clearInterval(i.autoPlayTimer)},e.prototype.autoPlayIterator=function(){var i=this,e=i.currentSlide+i.options.slidesToScroll;i.paused||i.interrupted||i.focussed||(!1===i.options.infinite&&(1===i.direction&&i.currentSlide+1===i.slideCount-1?i.direction=0:0===i.direction&&(e=i.currentSlide-i.options.slidesToScroll,i.currentSlide-1==0&&(i.direction=1))),i.slideHandler(e))},e.prototype.buildArrows=function(){var e=this;!0===e.options.arrows&&(e.$prevArrow=i(e.options.prevArrow).addClass("slick-arrow"),e.$nextArrow=i(e.options.nextArrow).addClass("slick-arrow"),e.slideCount>e.options.slidesToShow?(e.$prevArrow.removeClass("slick-hidden").removeAttr("aria-hidden tabindex"),e.$nextArrow.removeClass("slick-hidden").removeAttr("aria-hidden tabindex"),e.htmlExpr.test(e.options.prevArrow)&&e.$prevArrow.prependTo(e.options.appendArrows),e.htmlExpr.test(e.options.nextArrow)&&e.$nextArrow.appendTo(e.options.appendArrows),!0!==e.options.infinite&&e.$prevArrow.addClass("slick-disabled").attr("aria-disabled","true")):e.$prevArrow.add(e.$nextArrow).addClass("slick-hidden").attr({"aria-disabled":"true",tabindex:"-1"}))},e.prototype.buildDots=function(){var e,t,o=this;if(!0===o.options.dots){for(o.$slider.addClass("slick-dotted"),t=i("<ul />").addClass(o.options.dotsClass),e=0;e<=o.getDotCount();e+=1)t.append(i("<li />").append(o.options.customPaging.call(this,o,e)));o.$dots=t.appendTo(o.options.appendDots),o.$dots.find("li").first().addClass("slick-active")}},e.prototype.buildOut=function(){var e=this;e.$slides=e.$slider.children(e.options.slide+":not(.slick-cloned)").addClass("slick-slide"),e.slideCount=e.$slides.length,e.$slides.each(function(e,t){i(t).attr("data-slick-index",e).data("originalStyling",i(t).attr("style")||"")}),e.$slider.addClass("slick-slider"),e.$slideTrack=0===e.slideCount?i('<div class="slick-track"/>').appendTo(e.$slider):e.$slides.wrapAll('<div class="slick-track"/>').parent(),e.$list=e.$slideTrack.wrap('<div class="slick-list"/>').parent(),e.$slideTrack.css("opacity",0),!0!==e.options.centerMode&&!0!==e.options.swipeToSlide||(e.options.slidesToScroll=1),i("img[data-lazy]",e.$slider).not("[src]").addClass("slick-loading"),e.setupInfinite(),e.buildArrows(),e.buildDots(),e.updateDots(),e.setSlideClasses("number"==typeof e.currentSlide?e.currentSlide:0),!0===e.options.draggable&&e.$list.addClass("draggable")},e.prototype.buildRows=function(){var i,e,t,o,s,n,r,l=this;if(o=document.createDocumentFragment(),n=l.$slider.children(),l.o
vendor: 3,442 bytes, line 12235
12235ptions.rows>1){for(r=l.options.slidesPerRow*l.options.rows,s=Math.ceil(n.length/r),i=0;i<s;i++){var d=document.createElement("div");for(e=0;e<l.options.rows;e++){var a=document.createElement("div");for(t=0;t<l.options.slidesPerRow;t++){var c=i*r+(e*l.options.slidesPerRow+t);n.get(c)&&a.appendChild(n.get(c))}d.appendChild(a)}o.appendChild(d)}l.$slider.empty().append(o),l.$slider.children().children().children().css({width:100/l.options.slidesPerRow+"%",display:"inline-block"})}},e.prototype.checkResponsive=function(e,t){var o,s,n,r=this,l=!1,d=r.$slider.width(),a=window.innerWidth||i(window).width();if("window"===r.respondTo?n=a:"slider"===r.respondTo?n=d:"min"===r.respondTo&&(n=Math.min(a,d)),r.options.responsive&&r.options.responsive.length&&null!==r.options.responsive){s=null;for(o in r.breakpoints)r.breakpoints.hasOwnProperty(o)&&(!1===r.originalSettings.mobileFirst?n<r.breakpoints[o]&&(s=r.breakpoints[o]):n>r.breakpoints[o]&&(s=r.breakpoints[o]));null!==s?null!==r.activeBreakpoint?(s!==r.activeBreakpoint||t)&&(r.activeBreakpoint=s,"unslick"===r.breakpointSettings[s]?r.unslick(s):(r.options=i.extend({},r.originalSettings,r.breakpointSettings[s]),!0===e&&(r.currentSlide=r.options.initialSlide),r.refresh(e)),l=s):(r.activeBreakpoint=s,"unslick"===r.breakpointSettings[s]?r.unslick(s):(r.options=i.extend({},r.originalSettings,r.breakpointSettings[s]),!0===e&&(r.currentSlide=r.options.initialSlide),r.refresh(e)),l=s):null!==r.activeBreakpoint&&(r.activeBreakpoint=null,r.options=r.originalSettings,!0===e&&(r.currentSlide=r.options.initialSlide),r.refresh(e),l=s),e||!1===l||r.$slider.trigger("breakpoint",[r,l])}},e.prototype.changeSlide=function(e,t){var o,s,n,r=this,l=i(e.currentTarget);switch(l.is("a")&&e.preventDefault(),l.is("li")||(l=l.closest("li")),n=r.slideCount%r.options.slidesToScroll!=0,o=n?0:(r.slideCount-r.currentSlide)%r.options.slidesToScroll,e.data.message){case"previous":s=0===o?r.options.slidesToScroll:r.options.slidesToShow-o,r.slideCount>r.options.slidesToShow&&r.slideHandler(r.currentSlide-s,!1,t);break;case"next":s=0===o?r.options.slidesToScroll:o,r.slideCount>r.options.slidesToShow&&r.slideHandler(r.currentSlide+s,!1,t);break;case"index":var d=0===e.data.index?0:e.data.index||l.index()*r.options.slidesToScroll;r.slideHandler(r.checkNavigable(d),!1,t),l.children().trigger("focus");break;default:return}},e.prototype.checkNavigable=function(i){var e,t;if(e=this.getNavigableIndexes(),t=0,i>e[e.length-1])i=e[e.length-1];else for(var o in e){if(i<e[o]){i=t;break}t=e[o]}return i},e.prototype.cleanUpEvents=function(){var e=this;e.options.dots&&null!==e.$dots&&(i("li",e.$dots).off("click.slick",e.changeSlide).off("mouseenter.slick",i.proxy(e.interrupt,e,!0)).off("mouseleave.slick",i.proxy(e.interrupt,e,!1)),!0===e.options.accessibility&&e.$dots.off("keydown.slick",e.keyHandler)),e.$slider.off("focus.slick blur.slick"),!0===e.options.arrows&&e.slideCount>e.options.slidesToShow&&(e.$prevArrow&&e.$prevArrow.off("click.slick",e.changeSlide),e.$nextArrow&&e.$nextArrow.off("click.slick",e.changeSlide),!0===e.options.accessibility&&(e.$prevArrow&&e.$prevArrow.off("keydown.slick",e.keyHandler),e.$nextArrow&&e.$nextArrow.off("keydown.slick",e.keyHandler))),e.$list.off("touchstart.slick mousedown.slick",e.swipeHandler),e.$list.off("touchmove.slick mousemove.slick",e.swipeHandler),e.$list.off("touchend.slick mouseup.slick",e.swipeHandler),e.$list.off("touchcancel.slick mouseleave.
12235slick",e.swipeHandler),e.$list.off("click.slick",e.clickHandler),i(document).off(e.visibilityChange,e.visibility),e.cleanUpSlideEvents(),!0===e.options.accessibility&&e.$list.off("keydown.slick",e.keyHandler),!0===e.options.focusOnSelect&&i(e.$slideTrack).children().off("click.slick",e.selectHandler),i(window).off("orientationchange.slick.slick-"+e.instanceUid,e.orientationChange),i(window).off("resize.slick.slick-"+e.instanceUid,e.resize),i("[draggable!=true]",e.$slideTrack).off("dragstart",e.preventDefault),i(window).off("load.slick.slick-"+e.instanceUid,e.setPosition)},e.prototype.cleanUpSlideEvents=function(){var e=this;e.$list.off("mouseenter.slick",i.proxy(e.interrupt,e,!0)),e.$list.off("mouseleave.slick",i.proxy(e.interrupt,e,!1))},e.prototype.cleanUpRows=function(){var i,e=this;e.options.rows>1&&((i=e.$slides.children().children()).removeAttr("style"),e.$slider.empty().append(i))},e.prototype.clickHandler=function(i){!1===this.shouldClick&&(i.stopImmediatePropagation(),i.stopPropagation(),i.preventDefault())},e.prototype.destroy=function(e){var t=this;t.autoPlayClear(),t.touchObject={},t.cleanUpEvents(),i(".slick-cloned",t.$slider).detach(),t.$dots&&t.$dots.remove(),t.$prevArrow&&t.$prevArrow.length&&(t.$prevArrow.removeClass("slick-disabled slick-arrow slick-hidden").removeAttr("aria-hidden aria-disabled tabindex").css("display",""),t.htmlExpr.test(t.options.prevArrow)&&t.$prevArrow.remove()),t.$nextArrow&&t.$nextArrow.length&&(t.$nextArrow.removeClass("slick-disabled slick-arrow slick-hidden").removeAttr("aria-hidden aria-disabled tabindex").css("display",""),t.htmlExpr.test(t.options.nextArrow)&&t.$nextArrow.remove()),t.$slides&&(t.$slides.removeClass("slick-slide slick-active slick-center slick-visible slick-current").removeAttr("aria-hidden").removeAttr("data-slick-index").each(function(){i(this).attr("style",i(this).data("originalStyling"))}),t.$slideTrack.children(this.options.slide).detach(),t.$slideTrack.detach(),t.$list.detach(),t.$slider.append(t.$slides)),t.cleanUpRows(),t.$slider.removeClass("slick-slider"),t.$slider.removeClass("slick-initialized"),t.$slider.removeClass("slick-dotted"),t.unslicked=!0,e||t.$slider.trigger("destroy",[t])},e.prototype.disableTransition=function(i){var e=this,t={};t[e.transitionType]="",!1===e.options.fade?e.$slideTrack.css(t):e.$slides.eq(i).css(t)},e.prototype.fadeSlide=function(i,e){var t=this;!1===t.cssTransitions?(t.$slides.eq(i).css({zIndex:t.options.zIndex}),t.$slides.eq(i).animate({opacity:1},t.options.speed,t.options.easing,e)):(t.applyTransition(i),t.$slides.eq(i).css({opacity:1,zIndex:t.options.zIndex}),e&&setTimeout(function(){t.disableTransition(i),e.call()},t.options.speed))},e.prototype.fadeSlideOut=function(i){var e=this;!1===e.cssTransitions?e.$slides.eq(i).animate({opacity:0,zIndex:e.options.zIndex-2},e.options.speed,e.options.easing):(e.applyTransition(i),e.$slides.eq(i).css({opacity:0,zIndex:e.options.zIndex-2}))},e.prototype.filterSlides=e.prototype.slickFilter=function(i){var e=this;null!==i&&(e.$slidesCache=e.$slides,e.unload(),e.$slideTrack.children(this.options.slide).detach(),e.$slidesCache.filter(i).appendTo(e.$slideTrack),e.reinit())},e.prototype.focusHandler=function(){var e=this;e.$slider.off("focus.slick blur.slick").on("focus.slick blur.slick","*",function(t){t.stopImmediatePropagation();var o=i(this);setTimeout(function(){e.options.pauseOnFocus&&(e.focussed=o.is(":focus"),e.autoPlay())},0)})},e.prototype.getCurrent=e.prototype.slickCurrentSlide=function(){return this.currentSlide},e.prototype.getDotCount=function(){var i=this,e=0,t=0,o=0;if(!0===i.options.infinite)if(i.slideCount<=i.options.slidesToShow)++o;else for(;e<i.slideCount;)++o,e=t+i.options.slidesToScroll,t+=i.options.slidesToScroll<=i.options.slidesToShow?i.options.slidesToScroll:i.options.slidesToShow;else if(!0===i.options.centerMode)o=i.slideCount;else if(i.options.asNavFor)for(;e<i.slideCount;)++o,e=t+i.options.slidesToScroll,t+=i.options.slidesToScroll<=i.options.slidesToShow?i.options.slidesToScroll:i.options.slidesToShow;else o=1+Math.ceil((i.slideCount-i.options.slidesToShow)/i.options.slidesToScroll);return o-1},e.prototype.getLeft=function(i){var e,t,o,s,n=this,r=0;return n.slideOffset=0,t=n.$slides.first().outerHeight(!0),!0===n.options.infinite?(n.slideCount>n.options.slidesToShow&&(n.slideOffset=n.slideWidth*n.options.slidesToShow*-1,s=-1,!0===n.options.vertical&&!0===n.options.centerMode&&(2===n.options.slidesToShow?s=-1.5:1===n.options.slidesToShow&&(s=-2)),r=t*n.options.slidesToShow*s),n.slideCount%n.options.slidesToScroll!=0&&i+n.options.slidesToScroll>n.slideCount&&n.slideCount>n.options.slidesToShow&&(i>n.slideCount?(n.slideOffset=(n.options.slidesToShow-(i-n.slideCount))*n.slideWidth*-1,r=(n.options.slidesToShow-(i-n.slideCount))*t*-1):(n.slideOffset=n.slideCount%n.options.slidesToScroll*n.slideWidth*-1,r=n.slideCount%n.options.slidesToScroll*t*-1))):i+n.options.slidesToShow>n.slideCount&&(n.slideOffset=(i+n.options.slidesToShow-n.slideCount)*n.slideWidth,r=(i+n.options.slidesToShow-n.slideCount)*t),n.slideCount<=n.options.slidesToShow&&(n.slideOffset=0,r=0),!0===n.options.centerMode&&n.slideCount<=n.options.slidesToShow?n.slideOffset=n.slideWidth*Math.floor(n.options.slidesToShow)/2-n.slideWidth*n.slideCount/2:!0===n.options.centerMode&&!0===n.options.infinite?n.slideOffset+=n.slideWidth*Math.floor(n.options.slidesToShow/2)-n.slideWidth:!0===n.options.centerMode&&(n.slideOffset=0,n.slideOffset+=n.slideWidth*Math.floor(n.options.slidesToShow/2)),e=!1===n.options.vertical?i*n.slideWidth*-1+n.slideOffset:i*t*-1+r,!0===n.options.variableWidth&&(o=n.slideCount<=n.options.slidesToShow||!1===n.options.infinite?n.$slideTrack.children(".slick-slide").eq(i):n.$slideTrack.children(".slick-slide").eq(i+n.options.slidesToShow),e=!0===n.options.rtl?o[0]?-1*(n.$slideTrack.width()-o[0].offsetLeft-o.width()):0:o[0]?-1*o[0].offsetLeft:0,!0===n.options.centerMode&&(o=n.slideCount<=n.options.slidesToShow||!1===n.options.infinite?n.$slideTrack.children(".slick-slide").eq(i):n.$slideTrack.children(".slick-slide").eq(i+n.options.slidesToShow+1),e=!0===n.options.rtl?o[0]?-1*(n.$slideTrack.width()-o[0].offsetLeft-o.width()):0:o[0]?-1*o[0].offsetLeft:0,e+=(n.$list.width()-o.outerWidth())/2)),e},e.prototype.getOption=e.prototype.slickGetOption=function(i){return this.options[i]},e.prototype.getNavigableIndexes=function(){var i,e=this,t=0,o=0,s=[];for(!1===e.options.infinite?i=e.slideCount:(t=-1*e.options.slidesToScroll,o=-1*e.options.slidesToScroll,i=2*e.slideCount);t<i;)s.push(t),t=o+e.options.slidesToScroll,o+=e.options.slidesToScroll<=e.options.slidesToShow?e.options.slidesToScroll:e.options.slidesToShow;return s},e.prototype.getSlick=function(){return this},e.prototype.getSlideCount=function(){var e,t,o=this;return t=!0===o.options.centerMode?o.slideWidth*Math.floor(o.options.slidesToShow/2):0,!0===o.options.swipeToSlide?(o.$slideTrack.find(".slick-slide").each(function(s,n){if(n.offsetLeft-t+i(n).outerWidth()/2>-1*o.swipeLeft)return e=n,!1}),Math.abs(i(e).attr("data-slick-index")-o.currentSlide)||1):o.options.slidesToScroll},e.prototype.goTo=e.prototype.slickGoTo=function(i,e){this.changeSlide({data:{message:"index",index:
12235parseInt(i)}},e)},e.prototype.init=function(e){var t=this;i(t.$slider).hasClass("slick-initialized")||(i(t.$slider).addClass("slick-initialized"),t.buildRows(),t.buildOut(),t.setProps(),t.startLoad(),t.loadSlider(),t.initializeEvents(),t.updateArrows(),t.updateDots(),t.checkResponsive(!0),t.focusHandler()),e&&t.$slider.trigger("init",[t]),!0===t.options.accessibility&&t.initADA(),t.options.autoplay&&(t.paused=!1,t.autoPlay())},e.prototype.initADA=function(){var e=this,t=Math.ceil(e.slideCount/e.options.slidesToShow),o=e.getNavigableIndexes().filter(function(i){return i>=0&&i<e.slideCount});e.$slides.add(e.$slideTrack.find(".slick-cloned")).attr({"aria-hidden":"true",tabindex:"-1"}).find("a, input, button, select").attr({tabindex:"-1"}),null!==e.$dots&&(e.$slides.not(e.$slideTrack.find(".slick-cloned")).each(function(t){var s=o.indexOf(t);i(this).attr({role:"tabpanel",id:"slick-slide"+e.instanceUid+t,tabindex:-1}),-1!==s&&i(this).attr({"aria-describedby":"slick-slide-control"+e.instanceUid+s})}),e.$dots.attr("role","tablist").find("li").each(function(s){var n=o[s];i(this).attr({role:"presentation"}),i(this).find("button").first().attr({role:"tab",id:"slick-slide-control"+e.instanceUid+s,"aria-controls":"slick-slide"+e.instanceUid+n,"aria-label":s+1+" of "+t,"aria-selected":null,tabindex:"-1"})}).eq(e.currentSlide).find("button").attr({"aria-selected":"true",tabindex:"0"}).end());for(var s=e.currentSlide,n=s+e.options.slidesToShow;s<n;s++)e.$slides.eq(s).attr("tabindex",0);e.activateADA()},e.prototype.initArrowEvents=function(){var i=this;!0===i.options.arrows&&i.slideCount>i.options.slidesToShow&&(i.$prevArrow.off("click.slick").on("click.slick",{message:"previous"},i.changeSlide),i.$nextArrow.off("click.slick").on("click.slick",{message:"next"},i.changeSlide),!0===i.options.accessibility&&(i.$prevArrow.on("keydown.slick",i.keyHandler),i.$nextArrow.on("keydown.slick",i.keyHandler)))},e.prototype.initDotEvents=function(){var e=this;!0===e.options.dots&&(i("li",e.$dots).on("click.slick",{message:"index"},e.changeSlide),!0===e.options.accessibility&&e.$dots.on("keydown.slick",e.keyHandler)),!0===e.options.dots&&!0===e.options.pauseOnDotsHover&&i("li",e.$dots).on("mouseenter.slick",i.proxy(e.interrupt,e,!0)).on("mouseleave.slick",i.proxy(e.interrupt,e,!1))},e.prototype.initSlideEvents=function(){var e=this;e.options.pauseOnHover&&(e.$list.on("mouseenter.slick",i.proxy(e.interrupt,e,!0)),e.$list.on("mouseleave.slick",i.proxy(e.interrupt,e,!1)))},e.prototype.initializeEvents=function(){var e=this;e.initArrowEvents(),e.initDotEvents(),e.initSlideEvents(),e.$list.on("touchstart.slick mousedown.slick",{action:"start"},e.swipeHandler),e.$list.on("touchmove.slick mousemove.slick",{action:"move"},e.swipeHandler),e.$list.on("touchend.slick mouseup.slick",{action:"end"}
12235,e.swipeHandler),e.$list.on("touchcancel.slick mouseleave.slick",{action:"end"},e.swipeHandler),e.$list.on("click.slick",e.clickHandler),i(document).on(e.visibilityChange,i.proxy(e.visibility,e)),!0===e.options.accessibility&&e.$list.on("keydown.slick",e.keyHandler),!0===e.options.focusOnSelect&&i(e.$slideTrack).children().on("click.slick",e.selectHandler),i(window).on("orientationchange.slick.slick-"+e.instanceUid,i.proxy(e.orientationChange,e)),i(window).on("resize.slick.slick-"+e.instanceUid,i.proxy(e.resize,e)),i("[draggable!=true]",e.$slideTrack).on("dragstart",e.preventDefault),i(window).on("load.slick.slick-"+e.instanceUid,e.setPosition),i(e.setPosition)},e.prototype.initUI=function(){var i=this;!0===i.options.arrows&&i.slideCount>i.options.slidesToShow&&(i.$prevArrow.show(),i.$nextArrow.show()),!0===i.options.dots&&i.slideCount>i.options.slidesToShow&&i.$dots.show()},e.prototype.keyHandler=function(i){var e=this;i.target.tagName.match("TEXTAREA|INPUT|SELECT")||(37===i.keyCode&&!0===e.options.accessibility?e.changeSlide({data:{message:!0===e.options.rtl?"next":"previous"}}):39===i.keyCode&&!0===e.options.accessibility&&e.changeSlide({data:{message:!0===e.options.rtl?"previous":"next"}}))},e.prototype.lazyLoad=function(){function e(e){i("img[data-lazy]",e).each(function(){var e=i(this),t=i(this).attr("data-lazy"),o=i(this).attr("data-srcset"),s=i(this).attr("data-sizes")||n.$slider.attr("data-sizes"),r=document.createElement("img");r.onload=function(){e.animate({opacity:0}
vendor: 5,619 bytes, line 12235
12235,100,function(){o&&(e.attr("srcset",o),s&&e.attr("sizes",s)),e.attr("src",t).animate({opacity:1},200,function(){e.removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading")}),n.$slider.trigger("lazyLoaded",[n,e,t])})},r.onerror=function(){e.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"),n.$slider.trigger("lazyLoadError",[n,e,t])},r.src=t})}var t,o,s,n=this;if(!0===n.options.centerMode?!0===n.options.infinite?s=(o=n.currentSlide+(n.options.slidesToShow/2+1))+n.options.slidesToShow+2:(o=Math.max(0,n.currentSlide-(n.options.slidesToShow/2+1)),s=n.options.slidesToShow/2+1+2+n.currentSlide):(o=n.options.infinite?n.options.slidesToShow+n.currentSlide:n.currentSlide,s=Math.ceil(o+n.options.slidesToShow),!0===n.options.fade&&(o>0&&o--,s<=n.slideCount&&s++)),t=n.$slider.find(".slick-slide").slice(o,s),"anticipated"===n.options.lazyLoad)for(var r=o-1,l=s,d=n.$slider.find(".slick-slide"),a=0;a<n.options.slidesToScroll;a++)r<0&&(r=n.slideCount-1),t=(t=t.add(d.eq(r))).add(d.eq(l)),r--,l++;e(t),n.slideCount<=n.options.slidesToShow?e(n.$slider.find(".slick-slide")):n.currentSlide>=n.slideCount-n.options.slidesToShow?e(n.$slider.find(".slick-cloned").slice(0,n.options.slidesToShow)):0===n.currentSlide&&e(n.$slider.find(".slick-cloned").slice(-1*n.options.slidesToShow))},e.prototype.loadSlider=function(){var i=this;i.setPosition(),i.$slideTrack.css({opacity:1}),i.$slider.removeClass("slick-loading"),i.initUI(),"progressive"===i.options.lazyLoad&&i.progressiveLazyLoad()},e.prototype.next=e.prototype.slickNext=function(){this.changeSlide({data:{message:"next"}})},e.prototype.orientationChange=function(){var i=this;i.checkResponsive(),i.setPosition()},e.prototype.pause=e.prototype.slickPause=function(){var i=this;i.autoPlayClear(),i.paused=!0},e.prototype.play=e.prototype.slickPlay=function(){var i=this;i.autoPlay(),i.options.autoplay=!0,i.paused=!1,i.focussed=!1,i.interrupted=!1},e.prototype.postSlide=function(e){var t=this;t.unslicked||(t.$slider.trigger("afterChange",[t,e]),t.animating=!1,t.slideCount>t.options.slidesToShow&&t.setPosition(),t.swipeLeft=null,t.options.autoplay&&t.autoPlay(),!0===t.options.accessibility&&(t.initADA(),t.options.focusOnChange&&i(t.$slides.get(t.currentSlide)).attr("tabindex",0).focus()))},e.prototype.prev=e.prototype.slickPrev=function(){this.changeSlide({data:{message:"previous"}})},e.prototype.preventDefault=function(i){i.preventDefault()},e.prototype.progressiveLazyLoad=function(e){e=e||1;var t,o,s,n,r,l=this,d=i("img[data-lazy]",l.$slider);d.length?(t=d.first(),o=t.attr("data-lazy"),s=t.attr("data-srcset"),n=t.attr("data-sizes")||l.$slider.attr("data-sizes"),(r=document.createElement("img")).onload=function(){s&&(t.attr("srcset",s),n&&t.attr("sizes",n)),t.attr("src",o).removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading"),!0===l.options.adaptiveHeight&&l.setPosition(),l.$slider.trigger("lazyLoaded",[l,t,o]),l.progressiveLazyLoad()},r.onerror=function(){e<3?setTimeout(function(){l.progressiveLazyLoad(e+1)},500):(t.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"),l.$slider.trigger("lazyLoadError",[l,t,o]),l.progressiveLazyLoad())},r.src=o):l.$slider.trigger("allImagesLoaded",[l])},e.prototype.refresh=function(e){var t,o,s=this;o=s.slideCount-s.options.slidesToShow,!s.options.infinite&&s.currentSlide>o&&(s.currentSlide=o),s.slideCount<=s.options.slidesToShow&&(s.currentSlide=0),t=s.currentSlide,s.destroy(!0),i.extend(s,s.initials,{currentSlide:t}),s.init(),e||s.changeSlide({data:{message:"index",index:t}},!1)},e.prototype.registerBreakpoints=function(){var e,t,o,s=this,n=s.options.responsive||null;if("array"===i.type(n)&&n.length){s.respondTo=s.options.respondTo||"window";for(e in n)if(o=s.breakpoints.length-1,n.hasOwnProperty(e)){for(t=n[e].breakpoint;o>=0;)s.breakpoints[o]&&s.breakpoints[o]===t&&s.breakpoints.splice(o,1),o--;s.breakpoints.push(t),s.breakpointSettings[t]=n[e].settings}s.breakpoints.sort(function(i,e){return s.options.mobileFirst?i-e:e-i})}},e.prototype.reinit=function(){var e=this;e.$slides=e.$slideTrack.children(e.options.slide).addClass("slick-slide"),e.slideCount=e.$slides.length,e.currentSlide>=e.slideCount&&0!==e.currentSlide&&(e.currentSlide=e.currentSlide-e.options.slidesToScroll),e.slideCount<=e.options.slidesToShow&&(e.currentSlide=0),e.registerBreakpoints(),e.setProps(),e.setupInfinite(),e.buildArrows(),e.updateArrows(),e.initArrowEvents(),e.buildDots(),e.updateDots(),e.initDotEvents(),e.cleanUpSlideEvents(),e.initSlideEvents(),e.checkResponsive(!1,!0),!0===e.options.focusOnSelect&&i(e.$slideTrack).children().on("click.slick",e.selectHandler),e.setSlideClasses("number"==typeof e.currentSlide?e.currentSlide:0),e.setPosition(),e.focusHandler(),e.paused=!e.options.autoplay,e.autoPlay(),e.$slider.trigger("reInit",[e])},e.prototype.resize=function(){var e=this;i(window).width()!==e.windowWidth&&(clearTimeout(e.windowDelay),e.windowDelay=window.setTimeout(function(){e.windowWidth=i(window).width(),e.checkResponsive(),e.unslicked||e.setPosition()},50))},e.prototype.removeSlide=e.prototype.slickRemove=function(i,e,t){var o=this;if(i="boolean"==typeof i?!0===(e=i)?0:o.slideCount-1:!0===e?--i:i,o.slideCount<1||i<0||i>o.slideCount-1)return!1;o.unload(),!0===t?o.$slideTrack.children().remove():o.$slideTrack.children(this.options.slide).eq(i).remove(),o.$slides=o.$slideTrack.children(this.options.slide),o.$slideTrack.children(this.options.slide).detach(),o.$slideTrack.append(o.$slides),o.$slidesCache=o.$slides,o.reinit()},e.prototype.setCSS=function(i){var e,t,o=this,s={};
12235!0===o.options.rtl&&(i=-i),e="left"==o.positionProp?Math.ceil(i)+"px":"0px",t="top"==o.positionProp?Math.ceil(i)+"px":"0px",s[o.positionProp]=i,!1===o.transformsEnabled?o.$slideTrack.css(s):(s={},!1===o.cssTransitions?(s[o.animType]="translate("+e+", "+t+")",o.$slideTrack.css(s)):(s[o.animType]="translate3d("+e+", "+t+", 0px)",o.$slideTrack.css(s)))},e.prototype.setDimensions=function(){var i=this;!1===i.options.vertical?!0===i.options.centerMode&&i.$list.css({padding:"0px "+i.options.centerPadding}):(i.$list.height(i.$slides.first().outerHeight(!0)*i.options.slidesToShow),!0===i.options.centerMode&&i.$list.css({padding:i.options.centerPadding+" 0px"})),i.listWidth=i.$list.width(),i.listHeight=i.$list.height(),!1===i.options.vertical&&!1===i.options.variableWidth?(i.slideWidth=Math.ceil(i.listWidth/i.options.slidesToShow),i.$slideTrack.width(Math.ceil(i.slideWidth*i.$slideTrack.children(".slick-slide").length))):!0===i.options.variableWidth?i.$slideTrack.width(5e3*i.slideCount):(i.slideWidth=Math.ceil(i.listWidth),i.$slideTrack.height(Math.ceil(i.$slides.first().outerHeight(!0)*i.$slideTrack.children(".slick-slide").length)));var e=i.$slides.first().outerWidth(!0)-i.$slides.first().width();!1===i.options.variableWidth&&i.$slideTrack.children(".slick-slide").width(i.slideWidth-e)},e.prototype.setFade=function(){var e,t=this;t.$slides.each(function(o,s){e=t.slideWidth*o*-1,!0===t.options.rtl?i(s).css({position:"relative",right:e,top:0,zIndex:t.options.zIndex-2,opacity:0}
12235):i(s).css({position:"relative",left:e,top:0,zIndex:t.options.zIndex-2,opacity:0})}),t.$slides.eq(t.currentSlide).css({zIndex:t.options.zIndex-1,opacity:1})},e.prototype.setHeight=function(){var i=this;if(1===i.options.slidesToShow&&!0===i.options.adaptiveHeight&&!1===i.options.vertical){var e=i.$slides.eq(i.currentSlide).outerHeight(!0);i.$list.css("height",e)}},e.prototype.setOption=e.prototype.slickSetOption=function(){var e,t,o,s,n,r=this,l=!1;if("object"===i.type(arguments[0])?(o=arguments[0],l=arguments[1],n="multiple"):"string"===i.type(arguments[0])&&(o=arguments[0],s=arguments[1],l=arguments[2],"responsive"===arguments[0]&&"array"===i.type(arguments[1])?n="responsive":void 0!==arguments[1]&&(n="single")),"single"===n)r.options[o]=s;else if("multiple"===n)i.each(o,function(i,e){r.options[i]=e});else if("responsive"===n)for(t in s)if("array"!==i.type(r.options.responsive))r.options.responsive=[s[t]];else{for(e=r.options.responsive.length-1;e>=0;)r.options.responsive[e].breakpoint===s[t].breakpoint&&r.options.responsive.splice(e,1),e--;r.options.responsive.push(s[t])}l&&(r.unload(),r.reinit())},e.prototype.setPosition=function(){var i=this;i.setDimensions(),i.setHeight(),!1===i.options.fade?i.setCSS(i.getLeft(i.currentSlide)):i.setFade(),i.$slider.trigger("setPosition",[i])},e.prototype.setProps=function(){var i=this,e=document.body.style;i.positionProp=!0===i.options.vertical?"top":"left","top"===i.positionProp?i.$slider.addClass("slick-vertical"):i.$slider.removeClass("slick-vertical"),void 0===e.WebkitTransition&&void 0===e.MozTransition&&void 0===e.msTransition||!0===i.options.useCSS&&(i.cssTransitions=!0),i.options.fade&&("number"==typeof i.options.zIndex?i.options.zIndex<3&&(i.options.zIndex=3):i.options.zIndex=i.defaults.zIndex),void 0!==e.OTransform&&(i.animType="OTransform",i.transformType="-o-transform",i.transitionType="OTransition",void 0===e.perspectiveProperty&&void 0===e.webkitPerspective&&(i.animType=!1)),void 0!==e.MozTransform&&(i.animType="MozTransform",i.transformType="-moz-transform",i.transitionType="MozTransition",void 0===e.perspectiveProperty&&void 0===e.MozPerspective&&(i.animType=!1)),void 0!==e.webkitTransform&&(i.animType="webkitTransform",i.transformType="-webkit-transform",i.transitionType="webkitTransition",void 0===e.perspectiveProperty&&void 0===e.webkitPerspective&&(i.animType=!1)),void 0!==e.msTransform&&(i.animType="msTransform",i.transformType="-ms-transform",i.transitionType="msTransition",void 0===e.msTransform&&(i.animType=!1)),void 0!==e.transform&&!1!==i.animType&&(i.animType="transform",i.transformType="transform",i.transitionType="transition"),i.transformsEnabled=i.options.useTransform&&null!==i.animType&&!1!==i.animType},e.prototype.setSlideClasses=function(i){var e,t,o,s,n=this;if(t=n.$slider.find(".slick-slide").removeClass("slick-active slick-center slick-current").attr("aria-hidden","true"),n.$slides.eq(i).addClass("slick-current"),!0===n.options.centerMode){var r=n.options.slidesToShow%2==0?1:0;e=Math.floor(n.options.slidesToShow/2),!0===n.options.infinite&&(i>=e&&i<=n.slideCount-1-e?n.$slides.slice(i-e+r,i+e+1).addClass("slick-active").attr("aria-hidden","false"):(o=n.options.slidesToShow+i,t.slice(o-e+1+r,o+e+2).addClass("slick-active").attr("aria-hidden","false")),0===i?t.eq(t.length-1-n.options.slidesToShow).addClass("slick-center"):i===n.slideCount-1&&t.eq(n.options.slidesToShow).addClass("slick-center")),n.$slides.eq(i).addClass("slick-center")}else i>=0&&i<=n.slideCount-n.options.slidesToShow?n.$slides.slice(i,i+n.options.slidesToShow).addClass("slick-active").attr("aria-hidden","false"):t.length<=n.options.slidesToShow?t.addClass("slick-active").attr("aria-hidden","false"):(s=n.slideCount%n.options.slidesToShow,o=!0===n.options.infinite?n.options.slidesToShow+i:i,n.options.slidesToShow==n.options.slidesToScroll&&n.slideCount-i<n.options.slidesToShow?t.slice(o-(n.options.slidesToShow-s),o+s).addClass("slick-active").attr("aria-hidden","false"):t.slice(o,o+n.options.slidesToShow).addClass("slick-active").attr("aria-hidden","false"));"ondemand"!==n.options.lazyLoad&&"anticipated"!==n.options.lazyLoad||n.lazyLoad()},e.prototype.setupInfinite=function(){var e,t,o,s=this;if(!0===s.options.fade&&(s.options.centerMode=!1),!0===s.options.infinite&&!1===s.options.fade&&(t=null,s.slideCount>s.options.slidesToShow)){for(o=!0===s.options.centerMode?s.options.slidesToShow+1:s.options.slidesToShow,e=s.slideCount;e>s.slideCount-o;e-=1)t=e-1,i(s.$slides[t]).clone(!0).attr("id","").attr("data-slick-index",t-s.slideCount).prependTo(s.$slideTrack).addClass("slick-cloned");for(e=0;e<o+s.slideCount;e+=1)t=e,i(s.$slides[t]).clone(!0).attr("id","").attr("data-slick-index",t+s.slideCount).appendTo(s.$slideTrack).addClass("slick-cloned");s.$slideTrack.find(".slick-cloned").find("[id]").each(function(){i(this).attr("id","")})}},e.prototype.interrupt=function(i){var e=this;i||e.autoPlay(),e.interrupted=i},e.prototype.selectHandler=function(e){var t=this,o=i(e.target).is(".slick-slide")?i(e.target):i(e.target).parents(".slick-slide"),s=parseInt(o.attr("data-slick-index"));s||(s=0),t.slideCount<=t.options.slidesToShow?t.slideHandler(s,!1,!0):t.slideHandler(s)},e.prototype.slideHandler=function(i,e,t){var o,s,n,r,l,d=null,a=this;if(e=e||!1,!(!0===a.animating&&!0===a.options.waitForAnimate||!0===a.options.fade&&a.currentSlide===i))if(!1===e&&a.asNavFor(i),o=i,d=a.getLeft(o),r=a.getLeft(a.currentSlide),a.currentLeft=null===a.swipeLeft?r:a.swipeLeft,!1===a.options.infinite&&!1===a.options.centerMode&&(i<0||i>a.getDotCount()*a.options.slidesToScroll))!1===a.options.fade&&(o=a.currentSlide,!0!==t?a.animateSlide(r,function(){a.postSlide(o)}):a.postSlide(o));else if(!1===a.options.infinite&&!0===a.options.centerMode&&(i<0||i>a.slideCount-a.options.slidesToScroll))!1===a.options.fade&&(o=a.currentSlide,!0!==t?a.animateSlide(r,function(){a.postSlide(o)}):a.postSlide(o));else{if(a.options.autoplay&&clearInterval(a.autoPlayTimer),s=o<0?a.slideCount%a.options.slidesToScroll!=0?a.slideCount-a.slideCount%a.options.slidesToScroll:a.slideCount+
12235o:o>=a.slideCount?a.slideCount%a.options.slidesToScroll!=0?0:o-a.slideCount:o,a.animating=!0,a.$slider.trigger("beforeChange",[a,a.currentSlide,s]),n=a.currentSlide,a.currentSlide=s,a.setSlideClasses(a.currentSlide),a.options.asNavFor&&(l=(l=a.getNavTarget()).slick("getSlick")).slideCount<=l.options.slidesToShow&&l.setSlideClasses(a.currentSlide),a.updateDots(),a.updateArrows(),!0===a.options.fade)return!0!==t?(a.fadeSlideOut(n),a.fadeSlide(s,function(){a.postSlide(s)})):a.postSlide(s),void a.animateHeight();!0!==t?a.animateSlide(d,function(){a.postSlide(s)}):a.postSlide(s)}},e.prototype.startLoad=function(){var i=this;!0===i.options.arrows&&i.slideCount>i.options.slidesToShow&&(i.$prevArrow.hide(),i.$nextArrow.hide()),!0===i.options.dots&&i.slideCount>i.options.slidesToShow&&i.$dots.hide(),i.$slider.addClass("slick-loading")},e.prototype.swipeDirection=function(){var i,e,t,o,s=this;return i=s.touchObject.startX-s.touchObject.curX,e=s.touchObject.startY-s.touchObject.curY,t=Math.atan2(e,i),(o=Math.round(180*t/Math.PI))<0&&(o=360-Math.abs(o)),o<=45&&o>=0?!1===s.options.rtl?"left":"right":o<=360&&o>=315?!1===s.options.rtl?"left":"right":o>=135&&o<=225?!1===s.options.rtl?"right":"left":!0===s.options.verticalSwiping?o>=35&&o<=135?"down":"up":"vertical"},e.prototype.swipeEnd=function(i){var e,t,o=this;if(o.dragging=!1,o.swiping=!1,o.scrolling)return o.scrolling=!1,!1;if(o.interrupted=!1,o.shouldClick=!(o.touchObject.swipeLength>10),void 0===o.touchObject.curX)return!1;if(!0===o.touchObject.edgeHit&&o.$slider.trigger("edge",[o,o.swipeDirection()]),o.touchObject.swipeLength>=o.touchObject.minSwipe){switch(t=o.swipeDirection()){case"left":case"down":e=o.options.swipeToSlide?o.checkNavigable(o.currentSlide+o.getSlideCount()):o.currentSlide+o.getSlideCount(),o.currentDirection=0;break;case"right":case"up":e=o.options.swipeToSlide?o.checkNavigable(o.currentSlide-o.getSlideCount()):o.currentSlide-o.getSlideCount(),o.currentDirection=1}"vertical"!=t&&(o.slideHandler(e),o.touchObject={},o.$slider.trigger("swipe",[o,t]))}else o.touchObject.startX!==o.touchObject.curX&&(o.slideHandler(o.currentSlide),o.touchObject={})},e.prototype.swipeHandler=function(i){var e=this;if(!(!1===e.options.swipe||"ontouchend"in document&&!1===e.options.swipe||!1===e.options.draggable&&-1!==i.type.indexOf("mouse")))switch(e.touchObject.fingerCount=i.originalEvent&&void 0!==i.originalEvent.touches?i.originalEvent.touches.length:1,e.touchObject.minSwipe=e.listWidth/e.options.touchThreshold,!0===e.options.verticalSwiping&&(e.touchObject.minSwipe=e.listHeight/e.options.touchThreshold),i.data.action){case"start":e.swipeStart(i);break;case"move":e.swipeMove(i);break;case"end":e.swipeEnd(i)}},e.prototype.swipeMove=function(i){var e,t,o,s,n,r,l=this;return n=void 0!==i.originalEvent?i.originalEvent.touches:null,!(!l.dragging||l.scrolling||n&&1!==n.length)&&(e=l.getLeft(l.currentSlide),l.touchObject.curX=void 0!==n?n[0].pageX:i.clientX,l.touchObject.curY=void 0!==n?n[0].pageY:i.clientY,l.touchObject.swipeLength=Math.round(Math.sqrt(Math.pow(l.touchObject.curX-l.touchObject.startX,2))),r=Math.round(Math.sqrt(Math.pow(l.touchObject.curY-l.touchObject.startY,2))),!l.options.verticalSwiping&&!l.swiping&&r>4?(l.scrolling=!0,!1):(!0===l.options.verticalSwiping&&(l.touchObject.swipeLength=r),t=l.swipeDirection(),void 0!==i.originalEvent&&l.touchObject.swipeLength>4&&(l.swiping=!0,i.preventDefault()),s=(!1===l.options.rtl?1:-1)*(l.touchObject.curX>l.touchObject.startX?1:-1),!0===l.options.verticalSwiping&&(s=l.touchObject.curY>l.touchObject.startY?1:-1),o=l.touchObject.swipeLength,l.touchObject.edgeHit=!1,!1===l.options.infinite&&(0===l.currentSlide&&"right"===t||l.currentSlide>=l.getDotCount()&&"left"===t)&&(o=l.touchObject.swipeLength*l.options.edgeFriction,l.touchObject.edgeHit=!0),!1===l.options.vertical?l.swipeLeft=e+o*s:l.swipeLeft=e+o*(l.$list.height()/l.listWidth)*s,!0===l.options.verticalSwiping&&(l.swipeLeft=e+o*s),!0!==l.options.fade&&!1!==l.options.touchMove&&(!0===l.animating?(l.swipeLeft=null,!1):void l.setCSS(l.swipeLeft))))},e.prototype.swipeStart=function(i){var e,t=this;if(t.interrupted=!0,1!==t.touchObject.fingerCount||t.slideCount<=t.options.slidesToShow)return t.touchObject={},!1;void 0!==i.originalEvent&&void 0!==i.originalEvent.touches&&(e=i.originalEvent.touches[0]),t.touchObject.startX=t.touchObject.curX=void 0!==e?e.pageX:i.clientX,t.touchObject.startY=t.touchObject.curY=void 0!==e?e.pageY:i.clientY,t.dragging=!0},e.prototype.unfilterSlides=e.prototype.slickUnfilter=function(){var i=this;null!==i.$slidesCache&&(i.unload(),i.$slideTrack.children(this.options.slide).detach(),i.$slidesCache.appendTo(i.$slideTrack),i.reinit())},e.prototype.unload=function(){var e=this;i(".slick-cloned",e.$slider).remove(),e.$dots&&e.$dots.remove(),e.$prevArrow&&e.htmlExpr.test(e.options.prevArrow)&&e.$prevArrow.remove(),e.$nextArrow&&e.htmlExpr.test(e.options.nextArrow)&&e.$nextArrow.remove(),e.$slides.removeClass("slick-slide slick-active slick-visible slick-current").attr("aria-hidden","true").css("width","")}
12235,e.prototype.unslick=function(i){var e=this;e.$slider.trigger("unslick",[e,i]),e.destroy()},e.prototype.updateArrows=function(){var i=this;Math.floor(i.options.slidesToShow/2),!0===i.options.arrows&&i.slideCount>i.options.slidesToShow&&!i.options.infinite&&(i.$prevArrow.removeClass("slick-disabled").attr("aria-disabled","false"),i.$nextArrow.removeClass("slick-disabled").attr("aria-disabled","false"),0===i.currentSlide?(i.$prevArrow.addClass("slick-disabled").attr("aria-disabled","true"),i.$nextArrow.removeClass("slick-disabled").attr("aria-disabled","false")):i.currentSlide>=i.slideCount-i.options.slidesToShow&&!1===i.options.centerMode?(i.$nextArrow.addClass("slick-disabled").attr("aria-disabled","true"),i.$prevArrow.removeClass("slick-disabled").attr("aria-disabled","false")):i.currentSlide>=i.slideCount-1&&!0===i.options.centerMode&&(i.$nextArrow.addClass("slick-disabled").attr("aria-disabled","true"),i.$prevArrow.removeClass("slick-disabled").attr("aria-disabled","false")))},e.prototype.updateDots=function(){var i=this;null!==i.$dots&&(i.$dots.find("li").removeClass("slick-active").end(),i.$dots.find("li").eq(Math.floor(i.currentSlide/i.options.slidesToScroll)).addClass("slick-active"))},e.prototype.visibility=function(){var i=this;i.options.autoplay&&(document[i.hidden]?i.interrupted=!0:i.interrupted=!1)},i.fn.slick=function(){var i,t,o=this,s=arguments[0],n=Array.prototype.slice.call(arguments,1),r=o.length;for(i=0;i<r;i++)if("object"==typeof s||void 0===s?o[i].slick=new e(o[i],s):t=o[i].slick[s].apply(o[i].slick,n),void 0!==t)return t;return o}});
12236
12237},{"jquery":14}],17:[function(require,module,exports){
12238'use strict';
12239
12240/**
12241 * Module dependencies
12242 */
12243var decouple = require('decouple');
12244var Emitter = require('emitter');
12245
12246/**
12247 * Privates
12248 */
12249var scrollTimeout;
12250var scrolling = false;
12251var doc = window.document;
12252var html = doc.documentElement;
12253var msPointerSupported = window.navigator.msPointerEnabled;
12254var touch = {
12255  'start': msPointerSupported ? 'MSPointerDown' : 'touchstart',
12256  'move': msPointerSupported ? 'MSPointerMove' : 'touchmove',
12257  'end': msPointerSupported ? 'MSPointerUp' : 'touchend'
12258};
12259var prefix = (function prefix() {
12260  var regex = /^(Webkit|Khtml|Moz|ms|O)(?=[A-Z])/;
12261  var styleDeclaration = doc.getElementsByTagName('script')[0].style;
12262  for (var prop in styleDeclaration) {
12263    if (regex.test(prop)) {
12264      return '-' + prop.match(regex)[0].toLowerCase() + '-';
12265    }
12266  }
12267  // Nothing found so far? Webkit does not enumerate over the CSS properties of the style object.
12268  // However (prop in style) returns the correct value, so we'll have to test for
12269  // the precence of a specific property
12270  if ('WebkitOpacity' in styleDeclaration) { return '-webkit-'; }
12271  if ('KhtmlOpacity' in styleDeclaration) { return '-khtml-'; }
12272  return '';
12273}());
12274function extend(destination, from) {
12275  for (var prop in from) {
12276    if (from[prop]) {
12277      destination[prop] = from[prop];
12278    }
12279  }
12280  return destination;
12281}
12282function inherits(child, uber) {
12283  child.prototype = extend(child.prototype || {}, uber.prototype);
12284}
12285function hasIgnoredElements(el) {
12286  while (el.parentNode) {
12287    if (el.getAttribute('data-slideout-ignore') !== null) {
12288      return el;
12289    }
12290    el = el.parentNode;
12291  }
12292  return null;
12293}
12294
12295/**
12296 * Slideout constructor
12297 */
12298function Slideout(options) {
12299  options = options || {};
12300
12301  // Sets default values
12302  this._startOffsetX = 0;
12303  this._currentOffsetX = 0;
12304  this._opening = false;
12305  this._moved = false;
12306  this._opened = false;
12307  this._preventOpen = false;
12308  this._touch = options.touch === undefined ? true : options.touch && true;
12309  this._side = options.side || 'left';
12310
12311  // Sets panel
12312  this.panel = options.panel;
12313  this.menu = options.menu;
12314
12315  // Sets  classnames
12316  if (!this.panel.classList.contains('slideout-panel')) {
12317    this.panel.classList.add('slideout-panel');
12318  }
12319  if (!this.panel.classList.contains('slideout-panel-' + this._side)) {
12320    this.panel.classList.add('slideout-panel-' + this._side);
12321  }
12322  if (!this.menu.classList.contains('slideout-menu')) {
12323    this.menu.classList.add('slideout-menu');
12324  }
12325  if (!this.menu.classList.contains('slideout-menu-' + this._side)) {
12326    this.menu.classList.add('slideout-menu-' + this._side);
12327  }
12328
12329  // Sets options
12330  this._fx = options.fx || 'ease';
12331  this._duration = parseInt(options.duration, 10) || 300;
12332  this._tolerance = parseInt(options.tolerance, 10) || 70;
12333  this._padding = this._translateTo = parseInt(options.padding, 10) || 256;
12334  this._orientation = this._side === 'right' ? -1 : 1;
12335  this._translateTo *= this._orientation;
12336
12337  // Init touch events
12338  if (this._touch) {
12339    this._initTouchEvents();
12340  }
12341}
12342
12343/**
12344 * Inherits from Emitter
12345 */
12346inherits(Slideout, Emitter);
12347
12348/**
12349 * Opens the slideout menu.
12350 */
12351Slideout.prototype.open = function() {
12352  var self = this;
12353  this.emit('beforeopen');
12354  if (!html.classList.contains('slideout-open')) {
12355    html.classList.add('slideout-open');
12356  }
12357  this._setTransition();
12358  this._translateXTo(this._translateTo);
12359  this._opened = true;
12360  setTimeout(function() {
12361    self.panel.style.transition = self.panel.style['-webkit-transition'] = '';
12362    self.emit('open');
12363  }, this._duration + 50);
12364  return this;
12365};
12366
12367/**
12368 * Closes slideout menu.
12369 */
12370Slideout.prototype.close = function() {
12371  var self = this;
12372  if (!this.isOpen() && !this._opening) {
12373    return this;
12374  }
12375  this.emit('beforeclose');
12376  this._setTransition();
12377  this._translateXTo(0);
12378  this._opened = false;
12379  setTimeout(function() {
12380    html.classList.remove('slideout-open');
12381    self.panel.style.transition = self.panel.style['-webkit-transition'] = self.panel.style[prefix + 'transform'] = self.panel.style.transform = '';
12382    self.emit('close');
12383  }, this._duration + 50);
12384  return this;
12385};
12386
12387/**
12388 * Toggles (open/close) slideout menu.
12389 */
12390Slideout.prototype.toggle = function() {
12391  return this.isOpen() ? this.close() : this.open();
12392};
12393
12394/**
12395 * Returns true if the slideout is currently open, and false if it is closed.
12396 */
12397Slideout.prototype.isOpen = function() {
12398  return this._opened;
12399};
12400
12401/**
12402 * Translates panel and updates currentOffset with a given X point
12403 */
12404Slideout.prototype._translateXTo = function(translateX) {
12405  this._currentOffsetX = translateX;
12406  this.panel.style[prefix + 'transform'] = this.panel.style.transform = 'translateX(' + translateX + 'px)';
12407  return this;
12408};
12409
12410/**
12411 * Set transition properties
12412 */
12413Slideout.prototype._setTransition = function() {
12414  this.panel.style[prefix + 'transition'] = this.panel.style.transition = prefix + 'transform ' + this._duration + 'ms ' + this._fx;
12415  return this;
12416};
12417
12418/**
12419 * Initializes touch event
12420 */
12421Slideout.prototype._initTouchEvents = function() {
12422  var self = this;
12423
12424  /**
12425   * Decouple scroll event
12426   */
12427  this._onScrollFn = decouple(doc, 'scroll', function() {
12428    if (!self._moved) {
12429      clearTimeout(scrollTimeout);
12430      scrolling = true;
12431      scrollTimeout = setTimeout(function() {
12432        scrolling = false;
12433      }, 250);
12434    }
12435  });
12436
12437  /**
12438   * Prevents touchmove event if slideout is moving
12439   */
12440  this._preventMove = function(eve) {
12441    if (self._moved) {
12442      eve.preventDefault();
12443    }
12444  };
12445
12446  doc.addEventListener(touch.move, this._preventMove);
12447
12448  /**
12449   * Resets values on touchstart
12450   */
12451  this._resetTouchFn = function(eve) {
12452    if (typeof eve.touches === 'undefined') {
12453      return;
12454    }
12455
12456    self._moved = false;
12457    self._opening = false;
12458    self._startOffsetX = eve.touches[0].pageX;
12459    self._preventOpen = (!self._touch || (!self.isOpen() && self.menu.clientWidth !== 0));
12460  };
12461
12462  this.panel.addEventListener(touch.start, this._resetTouchFn);
12463
12464  /**
12465   * Resets values on touchcancel
12466   */
12467  this._onTouchCancelFn = function() {
12468    self._moved = false;
12469    self._opening = false;
12470  };
12471
12472  this.panel.addEventListener('touchcancel', this._onTouchCancelFn);
12473
12474  /**
12475   * Toggles slideout on touchend
12476   */
12477  this._onTouchEndFn = function() {
12478    if (self._moved) {
12479      self.emit('translateend');
12480      (self._opening && Math.abs(self._currentOffsetX) > self._tolerance) ? self.open() : self.close();
12481    }
12482    self._moved = false;
12483  };
12484
12485  this.panel.addEventListener(touch.end, this._onTouchEndFn);
12486
12487  /**
12488   * Translates panel on touchmove
12489   */
12490  this._onTouchMoveFn = function(eve) {
12491    if (
12492      scrolling ||
12493      self._preventOpen ||
12494      typeof eve.touches === 'undefined' ||
12495      hasIgnoredElements(eve.target)
12496    ) {
12497      return;
12498    }
12499
12500    var dif_x = eve.touches[0].clientX - self._startOffsetX;
12501    var translateX = self._currentOffsetX = dif_x;
12502
12503    if (Math.abs(translateX) > self._padding) {
12504      return;
12505    }
12506
12507    if (Math.abs(dif_x) > 20) {
12508
12509      self._opening = true;
12510
12511      var oriented_dif_x = dif_x * self._orientation;
12512
12513      if (self._opened && oriented_dif_x > 0 || !self._opened && oriented_dif_x < 0) {
12514        return;
12515      }
12516
12517      if (!self._moved) {
12518        self.emit('translatestart');
12519      }
12520
12521      if (oriented_dif_x <= 0) {
12522        translateX = dif_x + self._padding * self._orientation;
12523        self._opening = false;
12524      }
12525
12526      if (!(self._moved && html.classList.contains('slideout-open'))) {
12527        html.classList.add('slideout-open');
12528      }
12529
12530      self.panel.style[prefix + 'transform'] = self.panel.style.transform = 'translateX(' + translateX + 'px)';
12531      self.emit('translate', translateX);
12532      self._moved = true;
12533    }
12534
12535  };
12536
12537  this.panel.addEventListener(touch.move, this._onTouchMoveFn);
12538
12539  return this;
12540};
12541
12542/**
12543 * Enable opening the slideout via touch events.
12544 */
12545Slideout.prototype.enableTouch = function() {
12546  this._touch = true;
12547  return this;
12548};
12549
12550/**
12551 * Disable opening the slideout via touch events.
12552 */
12553Slideout.prototype.disableTouch = function() {
12554  this._touch = false;
12555  return this;
12556};
12557
12558/**
12559 * Destroy an instance of slideout.
12560 */
12561Slideout.prototype.destroy = function() {
12562  // Close before clean
12563  this.close();
12564
12565  // Remove event listeners
12566  doc.removeEventListener(touch.move, this._preventMove);
12567  this.panel.removeEventListener(touch.start, this._resetTouchFn);
12568  this.panel.removeEventListener('touchcancel', this._onTouchCancelFn);
12569  this.panel.removeEventListener(touch.end, this._onTouchEndFn);
12570  this.panel.removeEventListener(touch.move, this._onTouchMoveFn);
12571  doc.removeEventListener('scroll', this._onScrollFn);
12572
12573  // Remove methods
12574  this.open = this.close = function() {};
12575
12576  // Return the instance so it can be easily dereferenced
12577  return this;
12578};
12579
12580/**
12581 * Expose Slideout
12582 */
12583module.exports = Slideout;
12584
12585},{"decouple":1,"emitter":3}],18:[function(require,module,exports){
12586/*! tooltipster v4.2.6 */!function(a,b){"function"==typeof define&&define.amd?define(["jquery"],function(a){return b(a)}):"object"==typeof exports?module.exports=b(require("jquery")):b(jQuery)}(this,function(a){function b(a){this.$container,this.constraints=null,this.__$tooltip,this.__init(a)}function c(b,c){var d=!0;return a.each(b,function(a,e){return void 0===c[a]||b[a]!==c[a]?(d=!1,!1):void 0}),d}function d(b){var c=b.attr("id"),d=c?h.window.document.getElementById(c):null;return d?d===b[0]:a.contains(h.window.document.body,b[0])}function e(){if(!g)return!1;var a=g.document.body||g.document.documentElement,b=a.style,c="transition",d=["Moz","Webkit","Khtml","O","ms"];if("string"==typeof b[c])return!0;c=c.charAt(0).toUpperCase()+c.substr(1);for(var e=0;e<d.length;e++)if("string"==typeof b[d[e]+c])return!0;return!1}var f={animation:"fade",animationDuration:350,content:null,contentAsHTML:!1,contentCloning:!1,debug:!0,delay:300,delayTouch:[300,500],functionInit:null,functionBefore:null,functionReady:null,functionAfter:null,functionFormat:null,IEmin:6,interactive:!1,multiple:!1,parent:null,plugins:["sideTip"],repositionOnScroll:!1,restoration:"none",selfDestruction:!0,theme:[],timer:0,trackerInterval:500,trackOrigin:!1,trackTooltip:!1,trigger:"hover",triggerClose:{click:!1,mouseleave:!1,originClick:!1,scroll:!1,tap:!1,touchleave:!1},triggerOpen:{click:!1,mouseenter:!1,tap:!1,touchstart:!1},updateAnimation:"rotate",zIndex:9999999},g="undefined"!=typeof window?window:null,h={hasTouchCapability:!(!g||!("ontouchstart"in g||g.DocumentTouch&&g.document instanceof g.DocumentTouch||g.navigator.maxTouchPoints)),hasTransitions:e(),IE:!1,semVer:"4.2.6
vendor: 28,893 bytes, line 12586
12586",window:g},i=function(){this.__$emitterPrivate=a({}),this.__$emitterPublic=a({}),this.__instancesLatestArr=[],this.__plugins={},this._env=h};i.prototype={__bridge:function(b,c,d){if(!c[d]){var e=function(){};e.prototype=b;var g=new e;g.__init&&g.__init(c),a.each(b,function(a,b){0!=a.indexOf("__")&&(c[a]?f.debug&&console.log("The "+a+" method of the "+d+" plugin conflicts with another plugin or native methods"):(c[a]=function(){return g[a].apply(g,Array.prototype.slice.apply(arguments))},c[a].bridged=g))}),c[d]=g}return this},__setWindow:function(a){return h.window=a,this},_getRuler:function(a){return new b(a)},_off:function(){return this.__$emitterPrivate.off.apply(this.__$emitterPrivate,Array.prototype.slice.apply(arguments)),this},_on:function(){return this.__$emitterPrivate.on.apply(this.__$emitterPrivate,Array.prototype.slice.apply(arguments)),this},_one:function(){return this.__$emitterPrivate.one.apply(this.__$emitterPrivate,Array.prototype.slice.apply(arguments)),this},_plugin:function(b){var c=this;if("string"==typeof b){var d=b,e=null;return d.indexOf(".")>0?e=c.__plugins[d]:a.each(c.__plugins,function(a,b){return b.name.substring(b.name.length-d.length-1)=="."+d?(e=b,!1):void 0}),e}if(b.name.indexOf(".")<0)throw new Error("Plugins must be namespaced");return c.__plugins[b.name]=b,b.core&&c.__bridge(b.core,c,b.name),this},_trigger:function(){var a=Array.prototype.slice.apply(arguments);return"string"==typeof a[0]&&(a[0]={type:a[0]}),this.__$emitterPrivate.trigger.apply(this.__$emitterPrivate,a),this.__$emitterPublic.trigger.apply(this.__$emitterPublic,a),this},instances:function(b){var c=[],d=b||".tooltipstered";return a(d).each(function(){var b=a(this),d=b.data("tooltipster-ns");d&&a.each(d,function(a,d){c.push(b.data(d))})}),c},instancesLatest:function(){return this.__instancesLatestArr},off:function(){return this.__$emitterPublic.off.apply(this.__$emitterPublic,Array.prototype.slice.apply(arguments)),this},on:function(){return this.__$emitterPublic.on.apply(this.__$emitterPublic,Array.prototype.slice.apply(arguments)),this},one:function(){return this.__$emitterPublic.one.apply(this.__$emitterPublic,Array.prototype.slice.apply(arguments)),this},origins:function(b){var c=b?b+" ":"";return a(c+".tooltipstered").toArray()},setDefaults:function(b){return a.extend(f,b),this},triggerHandler:function(){return this.__$emitterPublic.triggerHandler.apply(this.__$emitterPublic,Array.prototype.slice.apply(arguments)),this}},a.tooltipster=new i,a.Tooltipster=function(b,c){this.__callbacks={close:[],open:[]},this.__closingTime,this.__Content,this.__contentBcr,this.__destroyed=!1,this.__$emitterPrivate=a({}),this.__$emitterPublic=a({}),this.__enabled=!0,this.__garbageCollector,this.__Geometry,this.__lastPosition,this.__namespace="tooltipster-"+Math.round(1e6*Math.random()),this.__options,this.__$originParents,this.__pointerIsOverOrigin=!1,this.__previousThemes=[],this.__state="closed",this.__timeouts={close:[],open:null},this.__touchEvents=[],this.__tracker=null,this._$origin,this._$tooltip,this.__init(b,c)},a.Tooltipster.prototype={__init:function(b,c){var d=this;if(d._$origin=a(b),d.__options=a.extend(!0,{},f,c),d.__optionsFormat(),!h.IE||h.IE>=d.__options.IEmin){var e=null;if(void 0===d._$origin.data("tooltipster-initialTitle")&&(e=d._$origin.attr("title"),void 0===e&&(e=null),d._$origin.data("tooltipster-initialTitle",e)),null!==d.__options.content)d.__contentSet(d.__options.content);else{var g,i=d._$origin.attr("data-tooltip-content");i&&(g=a(i)),g&&g[0]?d.__contentSet(g.first()):d.__contentSet(e)}d._$origin.removeAttr("title").addClass("tooltipstered"),d.__prepareOrigin(),d.__prepareGC(),a.each(d.__options.plugins,function(a,b){d._plug(b)}),h.hasTouchCapability&&a(h.window.document.body).on("touchmove."+d.__namespace+"-triggerOpen",function(a){d._touchRecordEvent(a)}),d._on("created",function(){d.__prepareTooltip()})._on("repositioned",function(a){d.__lastPosition=a.position})}else d.__options.disabled=!0},__contentInsert:function(){var a=this,b=a._$tooltip.find(".tooltipster-content"),c=a.__Content,d=function(a){c=a};return a._trigger({type:"format",content:a.__Content,format:d}),a.__options.functionFormat&&(c=a.__options.functionFormat.call(a,a,{origin:a._$origin[0]},a.__Content)),"string"!=typeof c||a.__options.contentAsHTML?b.empty().append(c):b.text(c),a},__contentSet:function(b){return b instanceof a&&this.__options.contentCloning&&(b=b.clone(!0)),this.__Content=b,this._trigger({type:"updated",content:b}),this},__destroyError:function(){throw new Error("This tooltip has been destroyed and cannot execute your method call.")},__geometry:function(){var b=this,c=b._$origin,d=b._$origin.is("area");if(d){var e=b._$origin.parent().attr("name");c=a('img[usemap="#'+e+'"]')}var f=c[0].getBoundingClientRect(),g=a(h.window.document),i=a(h.window),j=c,k={available:{document:null,window:null},document:{size:{height:g.height(),width:g.width()}},window:{scroll:{left:h.window.scrollX||h.window.document.documentElement.scrollLeft,top:h.window.scrollY||h.window.document.documentElement.scrollTop},size:{height:i.height(),width:i.width()}},origin:{fixedLineage:!1,offset:{},size:{height:f.bottom-f.top,width:f.right-f.left},usemapImage:d?c[0]:null,windowOffset:{bottom:f.bottom,left:f.left,right:f.right,top:f.top}}};if(d){var l=b._$origin.attr("shape"),m=b._$origin.attr("coords");if(m&&(m=m.split(","),a.map(m,function(a,b){m[b]=parseInt(a)})),"default"!=l)switch(l){case"circle":var n=m[0],o=m[1],p=m[2],q=o-p,r=n-p;k.origin.size.height=2*p,k.origin.size.width=k.origin.size.height,k.origin.windowOffset.left+=r,k.origin.windowOffset.top+=q;break;case"rect":var s=m[0],t=m[1],u=m[2],v=m[3];k.origin.size.height=v-t,k.origin.size.width=u-s,k.origin.windowOffset.left+=s,k.origin.windowOffset.top+=t;break;case"poly":for(var w=0,x=0,y=0,z=0,A="even",B=0;B<m.length;B++){var C=m[B];"even"==A?(C>y&&(y=C,0===B&&(w=y)),w>C&&(w=C),A="odd"):(C>z&&(z=C,1==B&&(x=z)),x>C&&(x=C),A="even")}k.origin.size.height=z-x,k.origin.size.width=y-w,k.origin.windowOffset.left+=w,k.origin.windowOffset.top+=x}}var D=function(a){k.origin.size.height=a.height,k.origin.windowOffset.left=a.left,k.origin.windowOffset.top=a.top,k.origin.size.width=a.width};for(b._trigger({type:"geometry",edit:D,geometry:{height:k.origin.size.height,left:k.origin.windowOffset.left,top:k.origin.windowOffset.top,width:k.origin.size.width}}),k.origin.windowOffset.right=k.origin.windowOffset.left+k.origin.size.width,k.origin.windowOffset.bottom=k.origin.windowOffset.top+k.origin.size.height,k.origin.offset.left=k.origin.windowOffset.left+k.window.scroll.left,k.origin.offset.top=k.origin.windowOffset.top+k.window.scroll.top,k.origin.offset.bottom=k.origin.offset.top+k.origin.size.height,k.origin.offset.right=k.origin.offset.left+k.origin.size.width,k.available.document={bottom:{height:k.document.size.height-k.origin.offset.bottom,width:k.document.size.width},left:{height:k.document.size.height,width:k.origin.offset.left},right:{height:k.document.size.height,width:k.document.size.width-k.origin.offset.right},top:{height:k.origin.offset.top,width:k.document.size.width}},k.available.window={bottom:{height:Math.max(k.window.size.height-Math.max(k.origin.windowOffset.bottom,0),0),width:k.window.size.width},left:{height:k.window.size.height,width:Math.max(k.origin.windowOffset.left,0)},right:{height:k.window.size.height,width:Math.max(k.window.size.width-Math.max(k.origin.windowOffset.right,0),0)},top:{height:Math.max(k.origin.windowOffset.top,0),width:k.window.size.width}};"html"!=j[0].tagName.toLowerCase();){if("fixed"==j.css("position")){k.origin.fixedLineage=!0;break}j=j.parent()}return k},__optionsFormat:function(){return"number"==typeof this.__options.animationDuration&&(this.__options.animationDuration=[this.__options.animationDuration,this.__options.animationDuration]),"number"==typeof this.__options.delay&&(this.__options.delay=[this.__options.delay,this.__options.delay]),"number"==typeof this.__options.delayTouch&&(this.__options.delayTouch=[this.__options.delayTouch,this.__options.delayTouch]),"string"==typeof this.__options.theme&&(this.__options.theme=[this.__options.theme]),null===this.__options.parent?this.__options.parent=a(h.window.document.body):"string"==typeof this.__options.parent&&(this.__options.parent=a(this.__options.parent)),"hover"==this.__options.trigger?(this.__options.triggerOpen={mouseenter:!0,touchstart:!0},this.__options.triggerClose={mouseleave:!0,originClick:!0,touchleave:!0}):"click"==this.__options.trigger&&(this.__options.triggerOpen={click:!0,tap:!0},this.__options.triggerClose={click:!0,tap:!0}),this._trigger("options"),this},__prepareGC:function(){var b=this;return b.__options.selfDestruction?b.__garbageCollector=setInterval(function(){var c=(new Date).getTime();b.__touchEvents=a.grep(b.__touchEvents,function(a,b){return c-a.time>6e4}),d(b._$origin)||b.close(function(){b.destroy()})},2e4):clearInterval(b.__garbageCollector),b},__prepareOrigin:function(){var a=this;if(a._$origin.off("."+a.__namespace+"-triggerOpen"),h.hasTouchCapability&&a._$origin.on("touchstart."+a.__namespace+"-triggerOpen touchend."+a.__namespace+"-triggerOpen touchcancel."+a.__namespace+"-triggerOpen",function(b){a._touchRecordEvent(b)}),a.__options.triggerOpen.click||a.__options.triggerOpen.tap&&h.hasTouchCapability){var b="";a.__options.triggerOpen.click&&(b+="click."+a.__namespace+"-triggerOpen "),a.__options.triggerOpen.tap&&h.hasTouchCapability&&(b+="touchend."+a.__namespace+"-triggerOpen"),a._$origin.on(b,function(b){a._touchIsMeaningfulEvent(b)&&a._open(b)})}if(a.__options.triggerOpen.mouseenter||a.__options.triggerOpen.touchstart&&h.hasTouchCapability){var b="";a.__options.triggerOpen.mouseenter&&(b+="mouseenter."+a.__namespace+"-triggerOpen "),a.__options.triggerOpen.touchstart&&h.hasTouchCapability&&(b+="touchstart."+a.__namespace+"-triggerOpen"),a._$origin.on(b,function(b){!a._touchIsTouchEvent(b)&&a._touchIsEmulatedEvent(b)||(a.__pointerIsOverOrigin=!0,a._openShortly(b))})}if(a.__options.triggerClose.mouseleave||a.__options.triggerClose.touchleave&&h.hasTouchCapability){var b="";a.__options.triggerClose.mouseleave&&(b+="mouseleave."+a.__namespace+"-triggerOpen "),a.__options.triggerClose.touchleave&&h.hasTouchCapability&&(b+="touchend."+a.__namespace+"-triggerOpen touchcancel."+a.__namespace+"-triggerOpen"),a._$origin.on(b,function(b){a._touchIsMeaningfulEvent(b)&&(a.__pointerIsOverOrigin=!1)})}return a},__prepareTooltip:function(){var b=this,c=b.__options.interactive?"auto":"";return b._$tooltip.attr("id",b.__namespace).css({"pointer-events":c,zIndex:b.__options.zIndex}),a.each(b.__previousThemes,function(a,c){b._$tooltip.removeClass(c)}),a.each(b.__options.theme,function(a,c){b._$tooltip.addClass(c)}),b.__previousThemes=a.merge([],b.__options.theme),b},__scrollHandler:function(b){var c=this;if(c.__options.triggerClose.scroll)c._close(b);else if(d(c._$origin)&&d(c._$tooltip)){var e=null;if(b.target===h.window.document)c.__Geometry.origin.fixedLineage||c.__options.repositionOnScroll&&c.reposition(b);else{e=c.__geometry();var f=!1;if("fixed"!=c._$origin.css("position")&&c.__$originParents.each(function(b,c){var d=a(c),g=d.css("overflow-x"),h=d.css("overflow-y");if("visible"!=g||"visible"!=h){var i=c.getBoundingClientRect();if("visible"!=g&&(e.origin.windowOffset.left<i.left||e.origin.windowOffset.right>i.right))return f=!0,!1;if("visible"!=h&&(e.origin.windowOffset.top<i.top||e.origin.windowOffset.bottom>i.bottom))return f=!0,!1}return"fixed"==d.css("position")?!1:void 0}),f)c._$tooltip.css("visibility","hidden");else if(c._$tooltip.css("visibility","visible"),c.__options.repositionOnScroll)c.reposition(b);else{var g=e.origin.offset.left-c.__Geometry.origin.offset.left,i=e.origin.offset.top-c.__Geometry.origin.offset.top;c._$tooltip.css({left:c.__lastPosition.coord.left+g,top:c.__lastPosition.coord.top+i})}}c._trigger({type:"scroll",event:b,geo:e})}return c},__stateSet:function(a){return this.__state=a,this._trigger({type:"state",state:a}),this},__timeoutsClear:function(){return clearTimeout(this.__timeouts.open),this.__timeouts.open=null,a.each(this.__timeouts.close,function(a,b){clearTimeout(b)}),this.__timeouts.close=[],this},__trackerStart:function(){var a=this,b=a._$tooltip.find(".tooltipster-content");return a.__options.trackTooltip&&(a.__contentBcr=b[0].getBoundingClientRect()),a.__tracker=setInterval(function(){if(d(a._$origin)&&d(a._$tooltip)){if(a.__options.trackOrigin){var e=a.__geometry(),f=!1;c(e.origin.size,a.__Geometry.origin.size)&&(a.__Geometry.origin.fixedLineage?c(e.origin.windowOffset,a.__Geometry.origin.windowOffset)&&(f=!0):c(e.origin.offset,a.__Geometry.origin.offset)&&(f=!0)),f||(a.__options.triggerClose.mouseleave?a._close():a.reposition())}if(a.__options.trackTooltip){var g=b[0].getBoundingClientRect();g.height===a.__contentBcr.height&&g.width===a.__contentBcr.width||(a.reposition(),a.__contentBcr=g)}}else a._close()},a.__options.trackerInterval),a},_close:function(b,c,d){var e=this,f=!0;if(e._trigger({type:"close",event:b,stop:function(){f=!1}}),f||d){c&&e.__callbacks.close.push(c),e.__callbacks.open=[],e.__timeoutsClear();var g=function(){a.each(e.__callbacks.close,function(a,c){c.call(e,e,{event:b,origin:e._$origin[0]})}),e.__callbacks.close=[]};if("closed"!=e.__state){var i=!0,j=new Date,k=j.getTime(),l=k+e.__options.animationDuration[1];if("disappearing"==e.__state&&l>e.__closingTime&&e.__options.animationDuration[1]>0&&(i=!1),i){e.__closingTime=l,"disappearing"!=e.__state&&e.__stateSet("disappearing");var m=function(){clearInterval(e.__tracker),e._trigger({type:"closing",event:b}),e._$tooltip.off("."+e.__namespace+"-triggerClose").removeClass("tooltipster-dying"),a(h.window).off("."+e.__namespace+"-triggerClose"),e.__$originParents.each(function(b,c){a(c).off("scroll."+e.__namespace+"-triggerClose")}),e.__$originParents=null,a(h.window.document.body).off("."+e.__namespace+"-triggerClose"),e._$origin.off("."+e.__namespace+"-triggerClose"),e._off("dismissable"),e.__stateSet("closed"),e._trigger({type:"after",event:b}),e.__options.functionAfter&&e.__options.functionAfter.call(e,e,{event:b,origin:e._$origin[0]}),g()};h.hasTransitions?(e._$tooltip.css({"-moz-animation-duration":e.__options.animationDuration[1]+"ms","-ms-animation-duration":e.__options.animationDuration[1]+"ms","-o-animation-duration":e.__options.animationDuration[1]+"ms","-webkit-animation-duration":e.__options.animationDuration[1]+"ms","animation-duration":e.__options.animationDuration[1]+"ms","transition-duration":e.__options.animationDuration[1]+"ms"}),e._$tooltip.clearQueue().removeClass("tooltipster-show").addClass("tooltipster-dying"),e.__options.animationDuration[1]>0&&e._$tooltip.delay(e.__options.animationDuration[1]),e._$tooltip.queue(m)):e._$tooltip.stop().fadeOut(e.__options.animationDuration[1],m)}}else g()}return e},_off:function(){return this.__$emitterPrivate.off.apply(this.__$emitterPrivate,Array.prototype.slice.apply(arguments)),this},_on:function(){return this.__$emitterPrivate.on.apply(this.__$emitterPrivate,Array.prototype.slice.apply(arguments)),this},_one:function(){return this.__$emitterPrivate.one.apply(this.__$emitterPrivate,Array.prototype.slice.apply(arguments)),this},_open:function(b,c){var e=this;if(!e.__destroying&&d(e._$origin)&&e.__enabled){var f=!0;if("closed"==e.__state&&(e._trigger({type:"before",event:b,stop:function(){f=!1}}),f&&e.__options.functionBefore&&(f=e.__options.functionBefore.call(e,e,{event:b,origin:e._$origin[0]}))),f!==!1&&null!==e.__Content){c&&e.__callbacks.open.push(c),e.__callbacks.close=[],e.__timeoutsClear();var g,i=function(){"stable"!=e.__state&&e.__stateSet("stable"),a.each(e.__callbacks.open,function(a,b){b.call(e,e,{origin:e._$origin[0],tooltip:e._$tooltip[0]})}),e.__callbacks.open=[]};if("closed"!==e.__state)g=0,"disappearing"===e.__state?(e.__stateSet("appearing"),h.hasTransitions?(e._$tooltip.clearQueue().removeClass("tooltipster-dying").addClass("tooltipster-show"),e.__options.animationDuration[0]>0&&e._$tooltip.delay(e.__options.animationDuration[0]),e._$tooltip.queue(i)):e._$tooltip.stop().fadeIn(i)):"stable"==e.__state&&i();else{if(e.__stateSet("appearing"),g=e.__options.animationDuration[0],e.__contentInsert(),e.reposition(b,!0),h.hasTransitions?(e._$tooltip.addClass("tooltipster-"+e.__options.animation).addClass("tooltipster-initial").css({"-moz-animation-duration":e.__options.animationDuration[0]+"ms","-ms-animation-duration":e.__options.animationDuration[0]+"ms","-o-animation-duration":e.__options.animationDuration[0]+"ms","-webkit-animation-duration":e.__options.animationDuration[0]+"ms","animation-duration":e.__options.animationDuration[0]+"ms","transition-duration":e.__options.animationDuration[0]+"ms"}),setTimeout(function(){"closed"!=e.__state&&(e._$tooltip.addClass("tooltipster-show").removeClass("tooltipster-initial"),e.__options.animationDuration[0]>0&&e._$tooltip.delay(e.__options.animationDuration[0]),e._$tooltip.queue(i))},0)):e._$tooltip.css("display","none").fadeIn(e.__options.animationDuration[0],i),e.__trackerStart(),a(h.window).on("resize."+e.__namespace+"-triggerClose",function(b){var c=a(document.activeElement);(c.is("input")||c.is("textarea"))&&a.contains(e._$tooltip[0],c[0])||e.reposition(b)}).on("scroll."+e.__namespace+"-triggerClose",function(a){e.__scrollHandler(a)}),e.__$originParents=e._$origin.parents(),e.__$originParents.each(function(b,c){a(c).on("scroll."+e.__namespace+"-triggerClose",function(a){e.__scrollHandler(a)})}),e.__options.triggerClose.mouseleave||e.__options.triggerClose.touchleave&&h.hasTouchCapability){e._on("dismissable",function(a){a.dismissable?a.delay?(m=setTimeout(function(){e._close(a.event)},a.delay),e.__timeouts.close.push(m)):e._close(a):clearTimeout(m)});var j=e._$origin,k="",l="",m=null;e.__options.interactive&&(j=j.add(e._$tooltip)),e.__options.triggerClose.mouseleave&&(k+="mouseenter."+e.__namespace+"-triggerClose ",l+="mouseleave."+e.__namespace+"-triggerClose "),e.__options.triggerClose.touchleave&&h.hasTouchCapability&&(k+="touchstart."+e.__namespace+"-triggerClose",l+="touchend."+e.__namespace+"-triggerClose touchcancel."+e.__namespace+"-triggerClose"),j.on(l,function(a){if(e._touchIsTouchEvent(a)||!e._touchIsEmulatedEvent(a)){var b="mouseleave"==a.type?e.__options.delay:e.__options.delayTouch;e._trigger({delay:b[1],dismissable:!0,event:a,type:"dismissable"})}}).on(k,function(a){!e._touchIsTouchEvent(a)&&e._touchIsEmulatedEvent(a)||e._trigger({dismissable:!1,event:a,type:"dismissable"})})}e.__options.triggerClose.originClick&&e._$origin.on("click."+e.__namespace+"-triggerClose",function(a){e._touchIsTouchEvent(a)||e._touchIsEmulatedEvent(a)||e._close(a)}),(e.__options.triggerClose.click||e.__options.triggerClose.tap&&h.hasTouchCapability)&&setTimeout(function(){if("closed"!=e.__state){var b="",c=a(h.window.document.body);e.__options.triggerClose.click&&(b+="click."+e.__namespace+"-triggerClose "),e.__options.triggerClose.tap&&h.hasTouchCapability&&(b+="touchend."+e.__namespace+"-triggerClose"),c.on(b,function(b){e._touchIsMeaningfulEvent(b)&&(e._touchRecordEvent(b),e.__options.interactive&&a.contains(e._$tooltip[0],b.target)||e._close(b))}),e.__options.triggerClose.tap&&h.hasTouchCapability&&c.on("touchstart."+e.__namespace+"-triggerClose",function(a){e._touchRecordEvent(a)})}},0),e._trigger("ready"),e.__options.functionReady&&e.__options.functionReady.call(e,e,{origin:e._$origin[0],tooltip:e._$tooltip[0]})}if(e.__options.timer>0){var m=setTimeout(function(){e._close()},e.__options.timer+g);e.__timeouts.close.push(m)}}}return e},_openShortly:function(a){var b=this,c=!0;if("stable"!=b.__state&&"appearing"!=b.__state&&!b.__timeouts.open&&(b._trigger({type:"start",event:a,stop:function(){c=!1}}),c)){var d=0==a.type.indexOf("touch")?b.__options.delayTouch:b.__options.delay;d[0]?b.__timeouts.open=setTimeout(function(){b.__timeouts.open=null,b.__pointerIsOverOrigin&&b._touchIsMeaningfulEvent(a)?(b._trigger("startend"),b._open(a)):b._trigger("startcancel")},d[0]):(b._trigger("startend"),b._open(a))}return b},_optionsExtract:function(b,c){var d=this,e=a.extend(!0,{},c),f=d.__options[b];return f||(f={},a.each(c,function(a,b){var c=d.__options[a];void 0!==c&&(f[a]=c)})),a.each(e,function(b,c){void 0!==f[b]&&("object"!=typeof c||c instanceof Array||null==c||"object"!=typeof f[b]||f[b]instanceof Array||null==f[b]?e[b]=f[b]:a.extend(e[b],f[b]))}),e},_plug:function(b){var c=a.tooltipster._plugin(b);if(!c)throw new Error('The "'+b+'" plugin is not defined');return c.instance&&a.tooltipster.__bridge(c.instance,this,c.name),this},_touchIsEmulatedEvent:function(a){for(var b=!1,c=(new Date).getTime(),d=this.__touchEvents.length-1;d>=0;d--){var e=this.__touchEvents[d];if(!(c-e.time<500))break;e.target===a.target&&(b=!0)}return b},_touchIsMeaningfulEvent:function(a){return this._touchIsTouchEvent(a)&&!this._touchSwiped(a.target)||!this._touchIsTouchEvent(a)&&!this._touchIsEmulatedEvent(a)},_touchIsTouchEvent:function(a){return 0==a.type.indexOf("touch")},_touchRecordEvent:function(a){return this._touchIsTouchEvent(a)&&(a.time=(new Date).getTime(),this.__touchEvents.push(a)),this},_touchSwiped:function(a){for(var b=!1,c=this.__touchEvents.length-1;c>=0;c--){var d=this.__touchEvents[c];if("touchmove"==d.type){b=!0;break}if("touchstart"==d.type&&a===d.target)break}return b},_trigger:function(){var b=Array.prototype.slice.apply(arguments);return"string"==typeof b[0]&&(b[0]={type:b[0]}),b[0].instance=this,b[0].origin=this._$origin?this._$origin[0]:null,b[0].tooltip=this._$tooltip?this._$tooltip[0]:null,this.__$emitterPrivate.trigger.apply(this.__$emitterPrivate,b),a.tooltipster._trigger.apply(a.tooltipster,b),this.__$emitterPublic.trigger.apply(this.__$emitterPublic,b),this},_unplug:function(b){var c=this;if(c[b]){var d=a.tooltipster._plugin(b);d.instance&&a.each(d.instance,function(a,d){c[a]&&c[a].bridged===c[b]&&delete c[a]}),c[b].__destroy&&c[b].__destroy(),delete c[b]}return c},close:function(a){return this.__destroyed?this.__destroyError():this._close(null,a),this},content:function(a){var b=this;if(void 0===a)return b.__Content;if(b.__destroyed)b.__destroyError();else if(b.__contentSet(a),null!==b.__Content){if("closed"!==b.__state&&(b.__contentInsert(),b.reposition(),b.__options.updateAnimation))if(h.hasTransitions){var c=b.__options.updateAnimation;b._$tooltip.addClass("tooltipster-update-"+c),setTimeout(function(){"closed"!=b.__state&&b._$tooltip.removeClass("tooltipster-update-"+c)},1e3)}else b._$tooltip.fadeTo(200,.5,function(){"closed"!=b.__state&&b._$tooltip.fadeTo(200,1)})}else b._close();return b},destroy:function(){var b=this;if(b.__destroyed)b.__destroyError();else{"closed"!=b.__state?b.option("animationDuration",0)._close(null,null,!0):b.__timeoutsClear(),b._trigger("destroy"),b.__destroyed=!0,b._$origin.removeData(b.__namespace).off("."+b.__namespace+"-triggerOpen"),a(h.window.document.body).off("."+b.__namespace+"-triggerOpen");var c=b._$origin.data("tooltipster-ns");if(c)if(1===c.length){var d=null;"previous"==b.__options.restoration?d=b._$origin.data("tooltipster-initialTitle"):"current"==b.__options.restoration&&(d="string"==typeof b.__Content?b.__Content:a("<div></div>").append(b.__Content).html()),d&&b._$origin.attr("title",d),b._$origin.removeClass("tooltipstered"),b._$origin.removeData("tooltipster-ns").removeData("tooltipster-initialTitle")}else c=a.grep(c,function(a,c){return a!==b.__namespace}),b._$origin.data("tooltipster-ns",c);b._trigger("destroyed"),b._off(),b.off(),b.__Content=null,b.__$emitterPrivate=null,b.__$emitterPublic=null,b.__options.parent=null,b._$origin=null,b._$tooltip=null,a.tooltipster.__instancesLatestArr=a.grep(a.tooltipster.__instancesLatestArr,function(a,c){return b!==a}),clearInterval(b.__garbageCollector)}return b},disable:function(){return this.__destroyed?(this.__destroyError(),this):(this._close(),this.__enabled=!1,this)},elementOrigin:function(){return this.__destroyed?void this.__destroyError():this._$origin[0]},elementTooltip:function(){return this._$tooltip?this._$tooltip[0]:null},enable:function(){return this.__enabled=!0,this},hide:function(a){return this.close(a)},instance:function(){return this},off:function(){return this.__destroyed||this.__$emitterPublic.off.apply(this.__$emitterPublic,Array.prototype.slice.apply(arguments)),this},on:function(){return this.__destroyed?this.__destroyError():this.__$emitterPublic.on.apply(this.__$emitterPublic,Array.prototype.slice.apply(arguments)),this},one:function(){return this.__destroyed?this.__destroyError():this.__$emitterPublic.one.apply(this.__$emitterPublic,Array.prototype.slice.apply(arguments)),this},open:function(a){return this.__destroyed?this.__destroyError():this._open(null,a),this},option:function(b,c){return void 0===c?this.__options[b]:(this.__destroyed?this.__destroyError():(this.__options[b]=c,this.__optionsFormat(),a.inArray(b,["trigger","triggerClose","triggerOpen"])>=0&&this.__prepareOrigin(),"selfDestruction"===b&&this.__prepareGC()),this)},reposition:function(a,b){var c=this;return c.__destroyed?c.__destroyError():"closed"!=c.__state&&d(c._$origin)&&(b||d(c._$tooltip))&&(b||c._$tooltip.detach(),c.__Geometry=c.__geometry(),c._trigger({type:"reposition",event:a,helper:{geo:c.__Geometry}})),c},show:function(a){return this.open(a)},status:function(){return{destroyed:this.__destroyed,enabled:this.__enabled,open:"closed"!==this.__state,state:this.__state}},triggerHandler:function(){return this.__destroyed?this.__destroyError():this.__$emitterPublic.triggerHandler.apply(this.__$emitterPublic,Array.prototype.slice.apply(arguments)),this}},a.fn.tooltipster=function(){var b=Array.prototype.slice.apply(arguments),c="You are using a single HTML element as content for several tooltips. You probably want to set the contentCloning option to TRUE.";if(0===this.length)return this;if("string"==typeof b[0]){var d="#*$~&";return this.each(function(){var e=a(this).data("tooltipster-ns"),f=e?a(this).data(e[0]):null;if(!f)throw new Error("You called Tooltipster's \""+b[0]+'" method on an uninitialized element');if("function"!=typeof f[b[0]])throw new Error('Unknown method "'+b[0]+'"');this.length>1&&"content"==b[0]&&(b[1]instanceof a||"object"==typeof b[1]&&null!=b[1]&&b[1].tagName)&&!f.__options.contentCloning&&f.__options.debug&&console.log(c);var g=f[b[0]](b[1],b[2]);return g!==f||"instance"===b[0]?(d=g,!1):void 0}),"#*$~&"!==d?d:this}a.tooltipster.__instancesLatestArr=[];var e=b[0]&&void 0!==b[0].multiple,g=e&&b[0].multiple||!e&&f.multiple,h=b[0]&&void 0!==b[0].content,i=h&&b[0].content||!h&&f.content,j=b[0]&&void 0!==b[0].contentCloning,k=j&&b[0].contentCloning||!j&&f.contentCloning,l=b[0]&&void 0!==b[0].debug,m=l&&b[0].debug||!l&&f.debug;return this.length>1&&(i instanceof a||"object"==typeof i&&null!=i&&i.tagName)&&!k&&m&&console.log(c),this.each(function(){var c=!1,d=a(this),e=d.data("tooltipster-ns"),f=null;e?g?c=!0:m&&(console.log("Tooltipster: one or more tooltips are already attached to the element below. Ignoring."),console.log(this)):c=!0,c&&(f=new a.Tooltipster(this,b[0]),e||(e=[]),e.push(f.__namespace),d.data("tooltipster-ns",e),d.data(f.__namespace,f),f.__options.functionInit&&f.__options.functionInit.call(f,f,{origin:this}),f._trigger("init")),a.tooltipster.__instancesLatestArr.push(f)}),this},b.prototype={__init:function(b){this.__$tooltip=b,this.__$tooltip.css({left:0,overflow:"hidden",position:"absolute",top:0}).find(".tooltipster-content").css("overflow","auto"),this.$container=a('<div class="tooltipster-ruler"></div>').append(this.__$tooltip).appendTo(h.window.document.body)},__forceRedraw:function(){var a=this.__$tooltip.parent();this.__$tooltip.detach(),this.__$tooltip.appendTo(a)},constrain:function(a,b){return this.constraints={width:a,height:b},this.__$tooltip.css({display:"block",height:"",overflow:"auto",width:a}),this},destroy:function(){this.__$tooltip.detach().find(".tooltipster-content").css({display:"",overflow:""}),this.$container.remove()},free:function(){return this.constraints=null,this.__$tooltip.css({display:"",height:"",overflow:"visible",width:""}),this},measure:function(){this.__forceRedraw();var a=this.__$tooltip[0].getBoundingClientRect(),b={size:{height:a.height||a.bottom-a.top,width:a.width||a.right-a.left}};if(this.constraints){var c=this.__$tooltip.find(".tooltipster-content"),d=this.__$tooltip.outerHeight(),e=c[0].getBoundingClientRect(),f={height:d<=this.constraints.height,width:a.width<=this.constraints.width&&e.width>=c[0].scrollWidth-1};b.fits=f.height&&f.width}return h.IE&&h.IE<=11&&b.size.width!==h.window.document.documentElement.clientWidth&&(b.size.width=Math.ceil(b.size.width)+1),b}};var j=navigator.userAgent.toLowerCase();-1!=j.indexOf("msie")?h.IE=parseInt(j.split("msie")[1]):-1!==j.toLowerCase().indexOf("trident")&&-1!==j.indexOf(" rv:11")?h.IE=11:-1!=j.toLowerCase().indexOf("edge/")&&(h.IE=parseInt(j.toLowerCase().split("edge/")[1]))
vendor: 10,393 bytes, lines 12586-12589
12586;var k="tooltipster.sideTip";return a.tooltipster._plugin({name:k,instance:{__defaults:function(){return{arrow:!0,distance:6,functionPosition:null,maxWidth:null,minIntersection:16,minWidth:0,position:null,side:"top",viewportAware:!0}},__init:function(a){var b=this;b.__instance=a,b.__namespace="tooltipster-sideTip-"+Math.round(1e6*Math.random()),b.__previousState="closed",b.__options,b.__optionsFormat(),b.__instance._on("state."+b.__namespace,function(a){"closed"==a.state?b.__close():"appearing"==a.state&&"closed"==b.__previousState&&b.__create(),b.__previousState=a.state}),b.__instance._on("options."+b.__namespace,function(){b.__optionsFormat()}),b.__instance._on("reposition."+b.__namespace,function(a){b.__reposition(a.event,a.helper)})},__close:function(){this.__instance.content()instanceof a&&this.__instance.content().detach(),this.__instance._$tooltip.remove(),this.__instance._$tooltip=null},__create:function(){var b=a('<div class="tooltipster-base tooltipster-sidetip"><div class="tooltipster-box"><div class="tooltipster-content"></div></div><div class="tooltipster-arrow"><div class="tooltipster-arrow-uncropped"><div class="tooltipster-arrow-border"></div><div class="tooltipster-arrow-background"></div></div></div></div>');this.__options.arrow||b.find(".tooltipster-box").css("margin",0).end().find(".tooltipster-arrow").hide(),this.__options.minWidth&&b.css("min-width",this.__options.minWidth+"px"),this.__options.maxWidth&&b.css("max-width",this.__options.maxWidth+"px"),
12587this.__instance._$tooltip=b,this.__instance._trigger("created")},__destroy:function(){this.__instance._off("."+self.__namespace)},__optionsFormat:function(){var b=this;if(b.__options=b.__instance._optionsExtract(k,b.__defaults()),b.__options.position&&(b.__options.side=b.__options.position),"object"!=typeof b.__options.distance&&(b.__options.distance=[b.__options.distance]),b.__options.distance.length<4&&(void 0===b.__options.distance[1]&&(b.__options.distance[1]=b.__options.distance[0]),void 0===b.__options.distance[2]&&(b.__options.distance[2]=b.__options.distance[0]),void 0===b.__options.distance[3]&&(b.__options.distance[3]=b.__options.distance[1]),b.__options.distance={top:b.__options.distance[0],right:b.__options.distance[1],bottom:b.__options.distance[2],left:b.__options.distance[3]}),"string"==typeof b.__options.side){var c={top:"bottom",right:"left",bottom:"top",left:"right"};b.__options.side=[b.__options.side,c[b.__options.side]],"left"==b.__options.side[0]||"right"==b.__options.side[0]?b.__options.side.push("top","bottom"):b.__options.side.push("right","left")}6===a.tooltipster._env.IE&&b.__options.arrow!==!0&&(b.__options.arrow=!1)},__reposition:function(b,c){var d,e=this,f=e.__targetFind(c),g=[];e.__instance._$tooltip.detach();var h=e.__instance._$tooltip.clone(),i=a.tooltipster._getRuler(h),j=!1,k=e.__instance.option("animation");switch(k&&h.removeClass("tooltipster-"+k),a.each(["window","document"],function(d,k){var l=null;if(e.__instance._trigger({container:k,helper:c,satisfied:j,takeTest:function(a){l=a},results:g,type:"positionTest"}),1==l||0!=l&&0==j&&("window"!=k||e.__options.viewportAware))for(var d=0;d<e.__options.side.length;d++){var m={horizontal:0,vertical:0},n=e.__options.side[d];"top"==n||"bottom"==n?m.vertical=e.__options.distance[n]:m.horizontal=e.__options.distance[n],e.__sideChange(h,n),a.each(["natural","constrained"],function(a,d){if(l=null,e.__instance._trigger({container:k,event:b,helper:c,mode:d,results:g,satisfied:j,side:n,takeTest:function(a){l=a},type:"positionTest"}),1==l||0!=l&&0==j){var h={container:k,distance:m,fits:null,mode:d,outerSize:null,side:n,size:null,target:f[n],whole:null},o="natural"==d?i.free():i.constrain(c.geo.available[k][n].width-m.horizontal,c.geo.available[k][n].height-m.vertical),p=o.measure();if(h.size=p.size,h.outerSize={height:p.size.height+m.vertical,width:p.size.width+m.horizontal},"natural"==d?c.geo.available[k][n].width>=h.outerSize.width&&c.geo.available[k][n].height>=h.outerSize.height?h.fits=!0:h.fits=!1:h.fits=p.fits,"window"==k&&(h.fits?"top"==n||"bottom"==n?h.whole=c.geo.origin.windowOffset.right>=e.__options.minIntersection&&c.geo.window.size.width-c.geo.origin.windowOffset.left>=e.__options.minIntersection:h.whole=c.geo.origin.windowOffset.bottom>=e.__options.minIntersection&&c.geo.window.size.height-c.geo.origin.windowOffset.top>=e.__options.minIntersection:h.whole=!1),g.push(h),h.whole)j=!0;else if("natural"==h.mode&&(h.fits||h.size.width<=c.geo.available[k][n].width))return!1}})}}),e.__instance._trigger({edit:function(a){g=a},event:b,helper:c,results:g,type:"positionTested"}),g.sort(function(a,b){if(a.whole&&!b.whole)return-1;if(!a.whole&&b.whole)return 1;if(a.whole&&b.whole){var c=e.__options.side.indexOf(a.side),d=e.__options.side.indexOf(b.side);return d>c?-1:c>d?1:"natural"==a.mode?-1:1}if(a.fits&&!b.fits)return-1;if(!a.fits&&b.fits)return 1;if(a.fits&&b.fits){var c=e.__options.side.indexOf(a.side),d=e.__options.side.indexOf(b.side);return d>c?-1:c>d?1:"natural"==a.mode?-1:1}return"document"==a.container&&"bottom"==a.side&&"natural"==a.mode?-1:1}),d=g[0],d.coord={},d.side){case"left":case"right":d.coord.top=Math.floor(d.target-d.size.height/2);break;case"bottom":case"top":d.coord.left=Math.floor(d.target-d.size.width/2)}switch(d.side){case"left":d.coord.left=c.geo.origin.windowOffset.left-d.outerSize.width;break;case"right":d.coord.left=c.geo.origin.windowOffset.right+d.distance.horizontal;break;case"top":d.coord.top=c.geo.origin.windowOffset.top-d.outerSize.height;break;case"bottom":d.coord.top=c.geo.origin.windowOffset.bottom+d.distance.vertical}"window"==d.container?"top"==d.side||"bottom"==d.side?d.coord.left<0?c.geo.origin.windowOffset.right-this.__options.minIntersection>=0?d.coord.left=0:d.coord.left=c.geo.origin.windowOffset.right-this.__options.minIntersection-1:d.coord.left>c.geo.window.size.width-d.size.width&&(c.geo.origin.windowOffset.left+this.__options.minIntersection<=c.geo.window.size.width?d.coord.left=c.geo.window.size.width-d.size.width:d.coord.left=c.geo.origin.windowOffset.left+this.__options.minIntersection+1-d.size.width):d.coord.top<0?c.geo.origin.windowOffset.bottom-this.__options.minIntersection>=0?d.coord.top=0:d.coord.top=c.geo.origin.windowOffset.bottom-this.__options.minIntersection-1:d.coord.top>c.geo.window.size.height-d.size.height&&(c.geo.origin.windowOffset.top+this.__options.minIntersection<=c.geo.window.size.height?d.coord.top=c.geo.window.size.height-d.size.height:d.coord.top=c.geo.origin.windowOffset.top+this.__options.minIntersection+1-d.size.height):(d.coord.left>c.geo.window.size.width-d.size.width&&(d.coord.left=c.geo.window.size.width-d.size.width),d.coord.left<0&&(d.coord.left=0)),e.__sideChange(h,d.side),c.tooltipClone=h[0],c.tooltipParent=e.__instance.option("parent").parent[0],c.mode=d.mode,c.whole=d.whole,c.origin=e.__instance._$origin[0],c.tooltip=e.__instance._$tooltip[0],delete d.container,delete d.fits,delete d.mode,delete d.outerSize,delete d.whole,d.distance=d.distance.horizontal||d.distance.vertical;var l=a.extend(!0,{},d);if(e.__instance._trigger({edit:function(a){d=a},event:b,helper:c,position:l,type:"position"}),e.__options.functionPosition){var m=e.__options.functionPosition.call(e,e.__instance,c,l);m&&(d=m)}i.destroy();var n,o;"top"==d.side||"bottom"==d.side?(n={prop:"left",val:d.target-d.coord.left},o=d.size.width-this.__options.minIntersection):(n={prop:"top",val:d.target-d.coord.top},o=d.size.height-this.__options.minIntersection),n.val<this.__options.minIntersection?n.val=this.__options.minIntersection:n.val>o&&(n.val=o);var p;p=c.geo.origin.fixedLineage?c.geo.origin.windowOffset:{left:c.geo.origin.windowOffset.left+c.geo.window.scroll.left,top:c.geo.origin.windowOffset.top+c.geo.window.scroll.top},d.coord={left:p.left+(d.coord.left-c.geo.origin.windowOffset.left),top:p.top+(d.coord.top-c.geo.origin.windowOffset.top)},e.__sideChange(e.__instance._$tooltip,d.side),c.geo.origin.fixedLineage?e.__instance._$tooltip.css("position","fixed"):e.__instance._$tooltip.css("position",""),e.__instance._$tooltip.css({left:d.coord.left,top:d.coord.top,height:d.size.height,width:d.size.width}).find(".tooltipster-arrow").css({left:"",top:""}).css(n.prop,n.val),e.__instance._$tooltip.appendTo(e.__instance.option("parent")),e.__instance._trigger({type:"repositioned",event:b,position:d})},__sideChange:function(a,b){a.removeClass("tooltipster-bottom").removeClass("tooltipster-left").removeClass("tooltipster-right").removeClass("tooltipster-top").addClass("tooltipster-"+b)},__targetFind:function(a){var b={},c=this.__instance._$origin[0].getClientRects();if(c.length>1){var d=this.__instance._$origin.css("opacity");1==d&&(this.__instance._$origin.css("opacity",.99),c=this.__instance._$origin[0].getClientRects(),this.__instance._$origin.css("opacity",1))}if(c.length<2)b.top=Math.floor(a.geo.origin.windowOffset.left+a.geo.origin.size.width/2),b.bottom=b.top,b.left=Math.floor(a.geo.origin.windowOffset.top+a.geo.origin.size.height/2),b.right=b.left;else{var e=c[0];b.top=Math.floor(e.left+(e.right-e.left)/2),e=c.length>2?c[Math.ceil(c.length/2)-1]:c[0],b.right=Math.floor(e.top+(e.bottom-e.top)/2),e=c[c.length-1],b.bottom=Math.floor(e.left+(e.right-e.left)/2),e=c.length>2?c[Math.ceil((c.length+1)/2)-1]:c[c.length-1],b.left=Math.floor(e.top+(e.bottom-e.top)/2)}return b}}}),a});
12588},{"jquery":14}],19:[function(require,module,exports){
12589var _extends=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e},_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(e,t){"object"===("undefined"==typeof exports?"undefined":_typeof(exports))&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):e.LazyLoad=t()}(this,function(){"use strict";var e={elements_selector:"img",container:window,threshold:300,throttle:150,data_src:"src",data_srcset:"srcset",class_loading:"loading",class_loaded:"loaded",class_error:"error",class_initial:"initial",skip_invisible:!0,callback_load:null,callback_error:null,callback_set:null,callback_processed:null},t=!("onscroll"in window)||/glebot/.test(navigator.userAgent),n=function(e,t){e&&e(t)}
12589,o=function(e){return e.getBoundingClientRect().top+window.pageYOffset-e.ownerDocument.documentElement.clientTop},i=function(e,t,n){return(t===window?window.innerHeight+window.pageYOffset:o(t)+t.offsetHeight)<=o(e)-n},s=function(e){return e.getBoundingClientRect().left+window.pageXOffset-e.ownerDocument.documentElement.clientLeft},r=function(e,t,n){var o=window.innerWidth;return(t===window?o+window.pageXOffset:s(t)+o)<=s(e)-n},l=function(e,t,n){return(t===window?window.pageYOffset:o(t))>=o(e)+n+e.offsetHeight},a=function(e,t,n){return(t===window?window.pageXOffset:s(t))>=s(e)+n+e.offsetWidth},c=function(e,t,n){return!(i(e,t,n)||l(e,t,n)||r(e,t,n)||a(e,t,n))},u=function(e,t){var n,o=new e(t);try{n=new CustomEvent("LazyLoad::Initialized",{detail:{instance:o}})}catch(e){(n=document.createEvent("CustomEvent")).initCustomEvent("LazyLoad::Initialized",!1,!1,{instance:o})}window.dispatchEvent(n)},d=function(e,t){return e.getAttribute("data-"+t)},h=function(e,t,n){return e.setAttribute("data-"+t,n)},f=function(e,t){var n=e.parentNode;if("PICTURE"===n.tagName)for(var o=0;o<n.children.length;o++){var i=n.children[o];if("SOURCE"===i.tagName){var s=d(i,t);s&&i.setAttribute("srcset",s)}}},_=function(e,t,n){var o=e.tagName,i=d(e,n);if("IMG"===o){f(e,t);var s=d(e,t);return s&&e.setAttribute("srcset",s),void(i&&e.setAttribute("src",i))}"IFRAME"!==o?i&&(e.style.backgroundImage='url("'+i+'")'):i&&e.setAttribute("src",i)},p="classList"in document.createElement("p"),m=function(e,t){p?e.classList.add(t):e.className+=(e.className?" ":"")+t},g=function(e,t){p?e.classList.remove(t):e.className=e.className.replace(new RegExp("(^|\\s+)"+t+"(\\s+|$)")," ").replace(/^\s+/,"").replace(/\s+$/,"")},v=function(t){this._settings=_extends({},e,t),this._queryOriginNode=this._settings.container===window?document:this._settings.container,this._previousLoopTime=0,this._loopTimeout=null,this._boundHandleScroll=this.handleScroll.bind(this),this._isFirstLoop=!0,window.addEventListener("resize",this._boundHandleScroll),this.update()};v.prototype={_reveal:function(e){var t=this._settings,o=function o(){t&&(e.removeEventListener("load",i),e.removeEventListener("error",o),g(e,t.class_loading),m(e,t.class_error),n(t.callback_error,e))},i=function i(){t&&(g(e,t.class_loading),m(e,t.class_loaded),e.removeEventListener("load",i),e.removeEventListener("error",o),n(t.callback_load,e))};"IMG"!==e.tagName&&"IFRAME"!==e.tagName||(e.addEventListener("load",i),e.addEventListener("error",o),m(e,t.class_loading)),_(e,t.data_srcset,t.data_src),n(t.callback_set,e)},_loopThroughElements:function(){var e=this._settings,o=this._elements,i=o?o.length:0,s=void 0,r=[],l=this._isFirstLoop;for(s=0;s<i;s++){var a=o[s];e.skip_invisible&&null===a.offsetParent||(t||c(a,e.container,e.threshold))&&(l&&m(a,e.class_initial),this._reveal(a),r.push(s),h(a,"was-processed",!0))}for(;r.length;)o.splice(r.pop(),1),n(e.callback_processed,o.length);0===i&&this._stopScrollHandler(),l&&(this._isFirstLoop=!1)},_purgeElements:function(){var e=this._elements,t=e.length,n=void 0,o=[];for(n=0;n<t;n++){var i=e[n];d(i,"was-processed")&&o.push(n)}for(;o.length>0;)e.splice(o.pop(),1)},_startScrollHandler:function(){this._isHandlingScroll||(this._isHandlingScroll=!0,this._settings.container.addEventListener("scroll",this._boundHandleScroll))},_stopScrollHandler:function(){this._isHandlingScroll&&(this._isHandlingScroll=!1,this._settings.container.removeEventListener("scroll",this._boundHandleScroll))},handleScroll:function(){var e=this._settings.throttle;if(0!==e){var t=Date.now(),n=e-(t-this._previousLoopTime);n<=0||n>e?(this._loopTimeout&&(clearTimeout(this._loopTimeout),this._loopTimeout=null),this._previousLoopTime=t,this._loopThroughElements()):this._loopTimeout||(this._loopTimeout=setTimeout(function(){this._previousLoopTime=Date.now(),this._loopTimeout=null,this._loopThroughElements()}.bind(this),n))}else this._loopThroughElements()},update:function(){this._elements=Array.prototype.slice.call(this._queryOriginNode.querySelectorAll(this._settings.elements_selector)),this._purgeElements(),this._loopThroughElements(),this._startScrollHandler()},destroy:function(){window.removeEventListener("resize",this._boundHandleScroll),this._loopTimeout&&(clearTimeout(this._loopTimeout),this._loopTimeout=null),this._stopScrollHandler(),this._elements=null,this._queryOriginNode=null,this._settings=null}};var w=window.lazyLoadOptions;return w&&function(e,t){var n=t.length;if(n)for(var o=0;o<n;o++)u(e,t[o]);else u(e,t)}(v,w),v});
12590},{}],20:[function(require,module,exports){
12591'use strict';
12592
12593(function (window) {
12594
12595        /**
12596         * SoundManager 2: "Bar UI" player
12597         * Copyright (c) 2014, Scott Schiller. All rights reserved.
12598         * http://www.schillmania.com/projects/soundmanager2/
12599         * Code provided under BSD license.
12600         * http://schillmania.com/projects/soundmanager2/license.txt
12601         */
12602
12603        /* global console, document, navigator, soundManager, window */
12604
12605        'use strict';
12606
12607        var Player,
12608            players = [],
12609
12610        // CSS selector that will get us the top-level DOM node for the player UI.
12611        playerSelector = '.sm2-bar-ui',
12612            playerOptions,
12613            utils;
12614
12615        /**
12616         * The following are player object event callback examples.
12617         * Override globally by setting window.sm2BarPlayers.on = {}, or individually by window.sm2BarPlayers[0].on = {} etc.
12618         * soundObject is provided for whileplaying() etc., but playback control should be done via the player object.
12619         */
12620        players.on = {
12621                /*
12622                play: function(player, soundObject) {
12623                  console.log('playing', player);
12624                },
12625                whileplaying: function(player, soundObject) {
12626                  console.log('whileplaying', player, soundObject);
12627                },
12628                finish: function(player, soundObject) {
12629                  // each sound
12630                  console.log('finish', player);
12631                },
12632                pause: function(player, soundObject) {
12633                  console.log('pause', player);
12634                },
12635                error: function(player, soundObject) {
12636                  console.log('error', player);
12637                },
12638                end: function(player, soundObject) {
12639                  // end of playlist
12640                  console.log('end', player);
12641                }
12642                */
12643        };
12644
12645        playerOptions = {
12646                // useful when multiple players are in use, or other SM2 sounds are active etc.
12647                stopOtherSounds: true,
12648                // CSS class to let the browser load the URL directly e.g., <a href="foo.mp3" class="sm2-exclude">download foo.mp3</a>
12649                excludeClass: 'sm2-exclude'
12650        };
12651
12652        soundManager.setup({
12653                // trade-off: higher UI responsiveness (play/progress bar), but may use more CPU.
12654                html5PollingInterval: 50,
12655                flashVersion: 9
12656        });
12657
12658        soundManager.onready(function () {
12659
12660                var nodes, i, j;
12661
12662                nodes = utils.dom.getAll(playerSelector);
12663
12664                if (nodes && nodes.length) {
12665                        for (i = 0, j = nodes.length; i < j; i++) {
12666                                players.push(new Player(nodes[i])
12666);
12667                        }
12668                }
12669        });
12670
12671        /**
12672         * player bits
12673         */
12674
12675        Player = function Player(playerNode) {
12676
12677                var css, dom, extras, playlistController, soundObject, actions, actionData, defaultItem, defaultVolume, firstOpen, exports;
12678
12679                css = {
12680                        disabled: 'disabled',
12681                        selected: 'selected',
12682                        active: 'active',
12683                        legacy: 'legacy',
12684                        noVolume: 'no-volume',
12685                        playlistOpen: 'playlist-open'
12686                };
12687
12688                dom = {
12689                        o: null,
12690                        playlist: null,
12691                        playlistTarget: null,
12692                        playlistContainer: null,
12693                        time: null,
12694                        player: null,
12695                        progress: null,
12696                        progressTrack: null,
12697                        progressBar: null,
12698                        duration: null,
12699                        volume: null
12700                };
12701
12702                // prepended to tracks when a sound fails to load/play
12703                extras = {
12704                        loadFailedCharacter: '<span title="Failed to load/play." class="load-error">✖</span>'
12705                };
12706
12707                function stopOtherSounds() {
12708
12709                        if (playerOptions.stopOtherSounds) {
12710                                soundManager.stopAll();
12711                        }
12712                }
12713
12714                function callback(method, oSound) {
12715                        if (method) {
12716                                // fire callback, passing current player and sound objects
12717                                if (exports.on && exports.on[method]) {
12718                                        exports.on[method](exports, oSound);
12719                                } else if (players.on[method]) {
12720                                        players.on[method](exports, oSound);
12721                                }
12722                        }
12723                }
12724
12725                function getTime(msec, useString) {
12726
12727                        // convert milliseconds to hh:mm:ss, return as object literal or string
12728
12729                        var nSec = Math.floor(msec / 1000),
12730                            hh = Math.floor(nSec / 3600),
12731                            min = Math.floor(nSec / 60) - Math.floor(hh * 60),
12732                            sec = Math.floor(nSec - hh * 3600 - min * 60);
12733
12734                        // if (min === 0 && sec === 0) return null; // return 0:00 as null
12735
12736                        return useString ? (hh ? hh + ':' : '') + (hh && min < 10 ? '0' + min : min) + ':' + (sec < 10 ? '0' + sec : sec) : { min: min, sec: sec };
12737                }
12738
12739                function setTitle(item) {
12740
12741                        // given a link, update the "now playing" UI.
12742
12743                        // if this is an <li> with an inner link, grab and use the text from that.
12744                        var links = item.getElementsByTagName('a');
12745
12746                        if (links.length) {
12747                                item = links[0];
12748                        }
12749
12750                        // remove any failed character sequence, also
12751                        dom.playlistTarget.innerHTML = '<ul class="sm2-playlist-bd"><li>' + item.innerHTML.replace(extras.loadFailedCharacter, '') + '</li></ul>';
12752
12753                        if (dom.playlistTarget.getElementsByTagName('li')[0].scrollWidth > dom.playlistTarget.offsetWidth) {
12754                                // this item can use <marquee>, in fact.
12755                                dom.playlistTarget.innerHTML = '<ul class="sm2-playlist-bd"><li><marquee>' + item.innerHTML + '</marquee></li></ul>';
12756                        }
12757                }
12758
12759                function makeSound(url) {
12760
12761                        var sound = soundManager.createSound({
12762
12763                                url: url,
12764
12765                                volume: defaultVolume,
12766
12767                                whileplaying: function whileplaying() {
12768
12769                                        var progressMaxLeft = 100,
12770                                            left,
12771                                            width;
12772
12773                                        left = Math.min(progressMaxLeft, Math.max(0, progressMaxLeft * (this.position / this.durationEstimate))) + '%';
12774                                        width = Math.min(100, Math.max(0, 100 * (this.position / this.durationEstimate))) + '%';
12775
12776                                        if (this.duration) {
12777
12778                                                dom.progress.style.left = left;
12779                                                dom.progressBar.style.width = width;
12780
12781                                                // TODO: only write changes
12782                                                dom.time.innerHTML = getTime(this.position, true);
12783                                        }
12784
12785                                        callback('whileplaying', this);
12786                                },
12787
12788                                onbufferchange: function onbufferchange(isBuffering) {
12789
12790                                        if (isBuffering) {
12791                                                utils.css.add(dom.o, 'buffering');
12792                                        } else {
12793                                                utils.css.remove(dom.o, 'buffering');
12794                                        }
12795                                },
12796
12797                                onplay: function onplay() {
12798                                        utils.css.swap(dom.o, 'paused', 'playing');
12799                                        callback('play', this);
12800                                },
12801
12802                                onpause: function onpause() {
12803                                        utils.css.swap(dom.o, 'playing', 'paused');
12804                                        callback('pause', this);
12805                                },
12806
12807                                onresume: function onresume() {
12808                                        utils.css.swap(dom.o, 'paused', 'playing');
12809                                },
12810
12811                                whileloading: function whileloading() {
12812
12813                                        if (!this.isHTML5) {
12814                                                dom.duration.innerHTML = getTime(this.durationEstimate, true);
12815                                        }
12816                                },
12817
12818                                onload: function onload(ok) {
12819
12820                                        if (ok) {
12821
12822                                                dom.duration.innerHTML = getTime(this.duration, true);
12823                                        } else if (this._iO && this._iO.onerror) {
12824
12825                                                this._iO.onerror();
12826                                        }
12827                                },
12828
12829                                onerror: function onerror() {
12830
12831                                        // sound failed to load.
12832                                        var item, element, html;
12833
12834                                        item = playlistController.getItem();
12835
12836                                        if (item) {
12837
12838                                                // note error, delay 2 seconds and advance?
12839                                                // playlistTarget.innerHTML = '<ul class="sm2-playlist-bd"><li>' + item.innerHTML + '</li></ul>';
12840
12841                                                if (extras.loadFailedCharacter) {
12842                                                        dom.playlistTarget.innerHTML = dom.playlistTarget.innerHTML.replace('<li>', '<li>' + extras.loadFailedCharacter + ' ');
12843                                                        if (playlistController.data.playlist && playlistController.data.playlist[playlistController.data.selectedIndex]) {
12844                                                                element = playlistController.data.playlist[playlistController.data.selectedIndex].getElementsByTagName('a')[0];
12845                                                                html = element.innerHTML;
12846                                                                if (html.indexOf(extras.loadFailedCharacter) === -1) {
12847                                                                        element.innerHTML = extras.loadFailedCharacter + ' ' + html;
12848                                                                }
12849                                                        }
12850                                                }
12851                                        }
12852
12853                                        callback('error', this);
12854
12855                                        // load next, possibly with delay.
12856
12857                                        if (navigator.userAgent.match(/mobile/i)) {
12858                                                // mobile will likely block the next play() call if there is a setTimeout() - so don't use one here.
12859                                                actions.next();
12860                                        } else {
12861                                                if (playlistController.data.timer) {
12862                                                        window.clearTimeout(playlistController.data.timer);
12863                                                }
12864                                                playlistController.data.timer = window.setTimeout(actions.next, 2000);
12865                                        }
12866                                },
12867
12868                                onstop: function onstop() {
12869
12870                                        utils.css.remove(dom.o, 'playing');
12871                                },
12872
12873                                onfinish: function onfinish() {
12874
12875                                        var lastIndex, item;
12876
12877                                        utils.css.remove(dom.o, 'playing');
12878
12879                                        dom.progress.style.left = '0%';
12880
12881                                        lastIndex = playlistController.data.selectedIndex;
12882
12883                                        callback('finish', this);
12884
12885                                        // next track?
12886                                        item = playlistController.getNext();
12887
12888                                        // don't play the same item over and over again, if at end of playlist (excluding single item case.)
12889                                        if (item && (playlistController.data.selectedIndex !== lastIndex || playlistController.data.playlist.length === 1 && playlistController.data.loopMode)) {
12890
12891                                                playlistController.select(item);
12892
12893                                                setTitle(item);
12894
12895                                                stopOtherSounds();
12896
12897                                                // play next
12898                                                this.play({
12899                                                        url: playlistController.getU
12899RL()
12900                                                });
12901                                        } else {
12902
12903                                                // end of playlist case
12904
12905                                                // explicitly stop?
12906                                                // this.stop();
12907
12908                                                callback('end', this);
12909                                        }
12910                                }
12911
12912                        });
12913
12914                        return sound;
12915                }
12916
12917                function playLink(link) {
12918
12919                        // if a link is OK, play it.
12920
12921                        if (soundManager.canPlayURL(link.href)) {
12922
12923                                // if there's a timer due to failure to play one track, cancel it.
12924                                // catches case when user may use previous/next after an error.
12925                                if (playlistController.data.timer) {
12926                                        window.clearTimeout(playlistController.data.timer);
12927                                        playlistController.data.timer = null;
12928                                }
12929
12930                                if (!soundObject) {
12931                                        soundObject = makeSound(link.href);
12932                                }
12933
12934                                // required to reset pause/play state on iOS so whileplaying() works? odd.
12935                                soundObject.stop();
12936
12937                                playlistController.select(link.parentNode);
12938
12939                                setTitle(link.parentNode);
12940
12941                                // reset the UI
12942                                // TODO: function that also resets/hides timing info.
12943                                dom.progress.style.left = '0px';
12944                                dom.progressBar.style.width = '0px';
12945
12946                                stopOtherSounds();
12947
12948                                soundObject.play({
12949                                        url: link.href,
12950                                        position: 0
12951                                });
12952                        }
12953                }
12954
12955                function PlaylistController() {
12956
12957                        var data;
12958
12959                        data = {
12960
12961                                // list of nodes?
12962                                playlist: [],
12963
12964                                // NOTE: not implemented yet.
12965                                // shuffledIndex: [],
12966                                // shuffleMode: false,
12967
12968                                // selection
12969                                selectedIndex: 0,
12970
12971                                loopMode: false,
12972
12973                                timer: null
12974
12975                        };
12976
12977                        function getPlaylist() {
12978
12979                                return data.playlist;
12980                        }
12981
12982                        function getItem(offset) {
12983
12984                                var list, item;
12985
12986                                // given the current selection (or an offset), return the current item.
12987
12988                                // if currently null, may be end of list case. bail.
12989                                if (data.selectedIndex === null) {
12990                                        return offset;
12991                                }
12992
12993                                list = getPlaylist();
12994
12995                                // use offset if provided, otherwise take default selected.
12996                                offset = offset !== undefined ? offset : data.selectedIndex;
12997
12998                                // safety check - limit to between 0 and list length
12999                                offset = Math.max(0, Math.min(offset, list.length));
13000
13001                                item = list[offset];
13002
13003                                return item;
13004                        }
13005
13006                        function findOffsetFromItem(item) {
13007
13008                                // given an <li> item, find it in the playlist array and return the index.
13009                                var list, i, j, offset;
13010
13011                                offset = -1;
13012
13013                                list = getPlaylist();
13014
13015                                if (list) {
13016
13017                                        for (i = 0, j = list.length; i < j; i++) {
13018                                                if (list[i] === item) {
13019                                                        offset = i;
13020                                                        break;
13021                                                }
13022                                        }
13023                                }
13024
13025                                return offset;
13026                        }
13027
13028                        function getNext() {
13029
13030                                // don't increment if null.
13031                                if (data.selectedIndex !== null) {
13032                                        data.selectedIndex++;
13033                                }
13034
13035                                if (data.playlist.length > 1) {
13036
13037                                        if (data.selectedIndex >= data.playlist.length) {
13038
13039                                                if (data.loopMode) {
13040
13041                                                        // loop to beginning
13042                                                        data.selectedIndex = 0;
13043                                                } else {
13044
13045                                                        // no change
13046                                                        data.selectedIndex--;
13047
13048                                                        // end playback
13049                                                        // data.selectedIndex = null;
13050                                                }
13051                                        }
13052                                } else {
13053
13054                                        data.selectedIndex = null;
13055                                }
13056
13057                                return getItem();
13058                        }
13059
13060                        function getPrevious() {
13061
13062                                data.selectedIndex--;
13063
13064                                if (data.selectedIndex < 0) {
13065                                        // wrapping around beginning of list? loop or exit.
13066                                        if (data.loopMode) {
13067                                                data.selectedIndex = data.playlist.length - 1;
13068                                        } else {
13069                                                // undo
13070                                                data.selectedIndex++;
13071                                        }
13072                                }
13073
13074                                return getItem();
13075                        }
13076
13077                        function resetLastSelected() {
13078
13079                                // remove UI highlight(s) on selected items.
13080                                var items, i, j;
13081
13082                                items = utils.dom.getAll(dom.playlist, '.' + css.selected);
13083
13084                                for (i = 0, j = items.length; i < j; i++) {
13085                                        utils.css.remove(items[i], css.selected);
13086                                }
13087                        }
13088
13089                        function select(item) {
13090
13091                                var offset, itemTop, itemBottom, containerHeight, scrollTop, itemPadding, liElement;
13092
13093                                // remove last selected, if any
13094                                resetLastSelected();
13095
13096                                if (item) {
13097
13098                                        liElement = utils.dom.ancestor('li', item);
13099
13100                                        utils.css.add(liElement, css.selected);
13101
13102                                        itemTop = item.offsetTop;
13103                                        itemBottom = itemTop + item.offsetHeight;
13104                                        containerHeight = dom.playlistContainer.offsetHeight;
13105                                        scrollTop = dom.playlist.scrollTop;
13106                                        itemPadding = 8;
13107
13108                                        if (itemBottom > containerHeight + scrollTop) {
13109                                                // bottom-align
13110                                                dom.playlist.scrollTop = itemBottom - containerHeight + itemPadding;
13111                                        } else if (itemTop < scrollTop) {
13112                                                // top-align
13113                                                dom.playlist.scrollTop = item.offsetTop - itemPadding;
13114                                        }
13115                                }
13116
13117                                // update selected offset, too.
13118                                offset = findOffsetFromItem(liElement);
13119
13120                                data.selectedIndex = offset;
13121                        }
13122
13123                        function playItemByOffset(offset) {
13124
13125                                var item;
13126
13127                                offset = offset || 0;
13128
13129                                item = getItem(offset);
13130
13131                                if (item) {
13132                                        playLink(item.getElementsByTagName('a')[0]);
13133                                }
13134                        }
13135
13136                        function getURL() {
13137
13138                                // return URL of currently-selected item
13139                                var item, url;
13140
13141                                item = getItem();
13142
13143                                if (item) {
13144                                        url = item.getElementsByTagName('a')[0].href;
13145                                }
13146
13147                                return url;
13148                        }
13149
13150                        function refreshDOM() {
13151
13152                                // get / update playlist from DOM
13153
13154                                if (!dom.playlist) {
13155                                        if (window.console && console.warn) {
13156                                                console.warn('refreshDOM(): playlist node not found?');
13157                                        }
13158                                        return;
13159                                }
13160
13161                                data.playlist = dom.playlist.getElementsByTagName('li');
13162                        }
13163
13164                        function initDOM() {
13165
13166                                dom.playlistTarget = utils.dom.get(dom.o, '.sm2-playlist-target');
13167                                dom.playlistContainer = utils.dom.get(dom.o, '.sm2-playlist-drawer');
13168                                dom.playlist = utils.dom.get(dom.o, '.sm2-playlist-bd');
13169                        }
13170
13171                        function initPlaylistController() {
13172
13173                                // inherit the default SM2 volume
13174                                defaultVolume = soundManager.defaultOptions.volume;
13175
13176                                initDOM();
13177                                refreshDOM();
13178
13179                                // animate playlist open, if HTML classname indicates so.
13180                                if (utils.css.has(dom.o, css.playlistOpen)) {
13181                                        // hackish: run this after API has returned
13182                                        window.setTimeout(function () {
13183                                                actions.menu(true);
13184                                        }, 1);
13185                                }
13186                        }
13187
13188                        initPlaylistController();
13189
13190                        return {
13191                                data: data,
13192                                refresh: refreshDOM,
13193                                getNext: getNext,
13194                                getPrevious: getPrevious,
13195                                getItem: getItem,
13196                                getURL: getURL,
13197                                playItemByOffset: playItemByOffset,
13198                                select: select
13199                        };
13200                }
13201
13202                function isRightClick(e) {
13203
13204                        // only pay attention to left clicks. old IE differs where there's no e.which, but e.button is 1 on left click.
13205                        if (e && (e.which && e.which === 2 || e.which === undefined && e.button !== 1)) {
13206                                // http://www.quirksmode.org/js/events_properties.html#button
13207                                return true;
13208                        }
13209
13210                        return false;
13211                }
13212
13213                function getActionData(target) {
13214
13215                        // DOM measurements for volume slider
13216
13217                        if (!target) {
13218                                return;
13219                        }
13220
13221                        actionData.volume.x = utils.position.getOffX(target);
13222                        actionData.volume.y = utils.position.getOffY(target);
13223
13224                        actionData.volume.width = target.offsetWidth;
13225                        actionData.volume.height = target.offsetHeight;
13226
13227                        // potentially dangerous: this should, but may not be a percentage-based value.
13228                        actionData.volume.backgroundSize = parseInt(utils.style.get(target, 'background-size'), 10);
13229
13230                        // IE gives pixels even if background-size specified as % in CSS. Boourns.
13231                        if (window.navigator.userAgent.match(/msie|trident/i)) {
13232                                actionData.volume.backgroundSize = actionData.volume.backgroundSize / actionData.volume.width * 100;
13233                        }
13234                }
13235
13236                function handleMouseDown(e) {
13237
13238                        var links, target;
13239
13240                        target = e.target || e.srcElement;
13241
13242                        if (isRightClick(e)) {
13243                                return;
13244                        }
13245
13246                        // normalize to <a>, if applicable.
13247                        if (target.nodeName.toLowerCase() !== 'a') {
13248
13249                                links = target.getElementsByTagName('a');
13250                                if (links && links.length) {
13251                                        target = target.getElementsByTagName('a')[0];
13252                                }
13253                        }
13254
13255                        if (utils.css.has(target, 'sm2-volume-control')) {
13256
13257                                // drag case for volume
13258
13259                                getActionData(target);
13260
13261                                utils.events.add(document, 'mousemove', actions.adjustVolume);
13262                                utils.events.add(document, 'touchmove', actions.adjustVolume);
13263                                utils.events.add(document, 'mouseup', actions.releaseVolume);
13264                                utils.events.add(document, 'touchend', actions.releaseVolume);
13265
13266                                // and apply right away
13267                                actions.adjustVolume(e);
13268                        }
13269                }
13270
13271                function handleMouse(e) {
13272
13273                        var target, barX, barWidth, x, clientX, newPosition, sound;
13274
13275                        target = dom.progressTrack;
13276
13277                        barX = utils.position.getOffX(target);
13278                        barWidth = target.offsetWidth;
13279                        clientX = utils.events.getClientX(e);
13280
13281                        x = clientX - barX;
13282
13283                        newPosition = x / barWidth;
13284
13285                        sound = soundObject;
13286
13287                        if (sound && sound.duration) {
13288
13289                                sound.setPosition(sound.duration * newPosition);
13290
13291                                // a little hackish: ensure UI updates immediately with current position, even if audio is buffering and hasn't moved there yet.
13292                                if (sound._iO && sound._iO.whileplaying) {
13293                                        sound._iO.whileplaying.apply(sound);
13294                                }
13295                        }
13296
13297                        if (e.preventDefault) {
13298                                e.preventDefault();
13299                        }
13300
13301                        return false;
13302                }
13303
13304                function releaseMouse(e) {
13305
13306                        utils.events.remove(document, 'mousemove', handleMouse);
13307                        utils.events.remove(document, 'touchmove', handleMouse);
13308
13309                        utils.css.remove(dom.o, 'grabbing');
13310
13311                        utils.events.remove(document, 'mouseup', releaseMouse);
13312                        utils.events.remove(document, 'touchend', releaseMouse);
13313
13314                        utils.events.preventDefault(e);
13315
13316                        return false;
13317                }
13318
13319                function handleProgressMouseDown(e) {
13320
13321                        if (isRightClick(e)) {
13322                                return;
13323                        }
13324
13325                        utils.css.add(dom.o, 'grabbing');
13326
13327                        utils.events.add(document, 'mousemove', handleMouse);
13328                        utils.events.add(document, 'touchmove', handleMouse);
13329                        utils.events.add(document, 'mouseup', releaseMouse);
13330                        utils.events.add(document, 'touchend', releaseMouse);
13331
13332                        handleMouse(e);
13333                }
13334
13335                function handleClick(e) {
13336
13337                        var evt, target, offset, targetNodeName, methodName, href, handled;
13338
13339                        evt = e || window.event;
13340
13341                        target = evt.target || evt.srcElement;
13342
13343                        if (target && target.nodeName) {
13344
13345                                targetNodeName = target.nodeName.toLowerCase();
13346
13347                                if (targetNodeName !== 'a') {
13348
13349                                        // old IE (IE 8) might return nested elements inside the <a>, eg., <b> etc. Try to find the parent <a>.
13350
13351                                        if (target.parentNode) {
13352
13353                                                do {
13354                                                        target = target.parentNode;
13355                                                        targetNodeName = target.nodeName.toLowerCase();
13356                                                } while (targetNodeName !== 'a' && target.parentNode);
13357
13358                                                if (!target) {
13359                                                        // something went wrong. bail.
13360                                                        return false;
13361                                                }
13362                                        }
13363                                }
13364
13365                                if (targetNodeName === 'a') {
13366
13367                                        // yep, it's a link.
13368
13369                                        href = target.href;
13370
13371                                        if (soundManager.canPlayURL(href)) {
13372
13373                                                // not excluded
13374                                                if (!utils.css.has(target, playerOptions.excludeClass)) {
13375
13376                                                        // find this in the playlist
13377
13378                                                        playLink(target);
13379
13380                                                        handled = true;
13381                                                }
13382                                        } else {
13383
13384                                                // is this one of the action buttons, eg., play/pause, volume, etc.?
13385                                                offset = target.href.lastIndexOf('#');
13386
13387                                                if (offset !== -1) {
13388
13389                                                        methodName = target.href.substr(offset + 1);
13390
13391                                                        if (methodName && actions[methodName]) {
13392                                                                handled = true;
13393                                                                actions[methodName](e);
13394                                                        }
13395                                                }
13396                                        }
13397
13398                                        // fall-through case
13399
13400                                        if (handled) {
13401                                                // prevent browser fall-through
13402                                                return utils.events.preventDefault(evt);
13403                                        }
13404                                }
13405                        }
13406
13407                        return true;
13408                }
13409
13410                function init() {
13411
13412                        // init DOM?
13413
13414                        if (!playerNode && window.console && console.warn) {
13415                                console.warn('init(): No playerNode element?');
13416                        }
13417
13418                        dom.o = playerNode;
13419
13420                        // are we dealing with a crap browser? apply legacy CSS if so.
13421                        if (window.navigator.userAgent.match(/msie [678]/i)) {
13422                                utils.css.add(dom.o, css.legacy);
13423                        }
13424
13425                        if (window.navigator.userAgent.match(/mobile/i)) {
13426                                // majority of mobile devices don't let HTML5 audio set volume.
13427                                utils.css.add(dom.o, css.noVolume);
13428                        }
13429
13430                        dom.progress = utils.dom.get(dom.o, '.sm2-progress-ball');
13431
13432                        dom.progressTrack = utils.dom.get(dom.o, '.sm2-progress-track');
13433
13434                        dom.progressBar = utils.dom.get(dom.o, '.sm2-progress-bar');
13435
13436                        dom.volume = utils.dom.get(dom.o, 'a.sm2-volume-control');
13437
13438                        // measure volume control dimensions
13439                        if (dom.volume) {
13440                                getActionData(dom.volume);
13441                        }
13442
13443                        dom.duration = utils.dom.get(dom.o, '.sm2-inline-duration');
13444
13445                        dom.time = utils.dom.get(dom.o, '.sm2-inline-time');
13446
13447                        playlistController = new PlaylistController();
13448
13449                        defaultItem = playlistController.getItem(0);
13450
13451                        playlistController.select(defaultItem);
13452
13453                        if (defaultItem) {
13454                                setTitle(defaultItem);
13455                        }
13456
13457                        utils.events.add(dom.o, 'mousedown', handleMouseDown);
13458                        utils.events.add(dom.o, 'touchstart', handleMouseDown);
13459                        utils.events.add(dom.o, 'click', handleClick);
13460                        utils.events.add(dom.progressTrack, 'mousedown', handleProgressMouseDown);
13461                        utils.events.add(dom.progressTrack, 'touchstart', handleProgressMouseDown);
13462                }
13463
13464                // ---
13465
13466                actionData = {
13467
13468                        volume: {
13469                                x: 0,
13470                                y: 0,
13471                                width: 0,
13472                                height: 0,
13473                                backgroundSize: 0
13474                        }
13475
13476                };
13477
13478                actions = {
13479
13480                        play: function play(offsetOrEvent) {
13481
13482                                /**
13483                                 * This is an overloaded function that takes mouse/touch events or offset-based item indices.
13484                                 * Remember, "auto-play" will not work on mobile devices unless this function is called 
13484immediately from a touch or click event.
13485                                 * If you have the link but not the offset, you can also pass a fake event object with a target of an <a> inside the playlist - e.g. { target: someMP3Link }
13486                                 */
13487
13488                                var target, href, e;
13489
13490                                if (offsetOrEvent !== undefined && !isNaN(offsetOrEvent)) {
13491                                        // smells like a number.
13492                                        playlistController.playItemByOffset(offsetOrEvent);
13493                                        return;
13494                                }
13495
13496                                // DRY things a bit
13497                                e = offsetOrEvent;
13498
13499                                if (e && e.target) {
13500
13501                                        target = e.target || e.srcElement;
13502
13503                                        href = target.href;
13504                                }
13505
13506                                // haaaack - if null due to no event, OR '#' due to play/pause link, get first link from playlist
13507                                if (!href || href.indexOf('#') !== -1) {
13508                                        href = dom.playlist.getElementsByTagName('a')[0].href;
13509                                }
13510
13511                                if (!soundObject) {
13512                                        soundObject = makeSound(href);
13513                                }
13514
13515                                // edge case: if the current sound is not playing, stop all others.
13516                                if (!soundObject.playState) {
13517                                        stopOtherSounds();
13518                                }
13519
13520                                // TODO: if user pauses + unpauses a sound that had an error, try to play next?
13521                                soundObject.togglePause();
13522
13523                                // special case: clear "play next" timeout, if one exists.
13524                                // edge case: user pauses after a song failed to load.
13525                                if (soundObject.paused && playlistController.data.timer) {
13526                                        window.clearTimeout(playlistController.data.timer);
13527                                        playlistController.data.timer = null;
13528                                }
13529                        },
13530
13531                        pause: function pause() {
13532
13533                                if (soundObject && soundObject.readyState) {
13534                                        soundObject.pause();
13535                                }
13536                        },
13537
13538                        resume: function resume() {
13539
13540                                if (soundObject && soundObject.readyState) {
13541                                        soundObject.resume();
13542                                }
13543                        },
13544
13545                        stop: function stop() {
13546
13547                                // just an alias for pause, really.
13548                                // don't actually stop because that will mess up some UI state, i.e., dragging the slider.
13549                                return actions.pause();
13550                        },
13551
13552                        next: function next() /* e */{
13553
13554                                var item, lastIndex;
13555
13556                                // special case: clear "play next" timeout, if one exists.
13557                                if (playlistController.data.timer) {
13558                                        window.clearTimeout(playlistController.data.timer);
13559                                        playlistController.data.timer = null;
13560                                }
13561
13562                                lastIndex = playlistController.data.selectedIndex;
13563
13564                                item = playlistController.getNext(true);
13565
13566                                // don't play the same item again
13567                                if (item && playlistController.data.selectedIndex !== lastIndex) {
13568                                        playLink(item.getElementsByTagName('a')[0]);
13569                                }
13570                        },
13571
13572                        prev: function prev() /* e */{
13573
13574                                var item, lastIndex;
13575
13576                                lastIndex = playlistController.data.selectedIndex;
13577
13578                                item = playlistController.getPrevious();
13579
13580                                // don't play the same item again
13581                                if (item && playlistController.data.selectedIndex !== lastIndex) {
13582                                        playLink(item.getElementsByTagName('a')[0]);
13583                                }
13584                        },
13585
13586                        shuffle: function shuffle(e) {
13587
13588                                // NOTE: not implemented yet.
13589
13590                                var target = e ? e.target || e.srcElement : utils.dom.get(dom.o, '.shuffle');
13591
13592                                if (target && !utils.css.has(target, css.disabled)) {
13593                                        utils.css.toggle(target.parentNode, css.active);
13594                                        playlistController.data.shuffleMode = !playlistController.data.shuffleMode;
13595                                }
13596                        },
13597
13598                        repeat: function repeat(e) {
13599
13600                                var target = e ? e.target || e.srcElement : utils.dom.get(dom.o, '.repeat');
13601
13602                                if (target && !utils.css.has(target, css.disabled)) {
13603                                        utils.css.toggle(target.parentNode, css.active);
13604                                        playlistController.data.loopMode = !playlistController.data.loopMode;
13605                                }
13606                        },
13607
13608                        menu: function menu(ignoreToggle) {
13609
13610                                var isOpen;
13611
13612                                isOpen = utils.css.has(dom.o, css.playlistOpen);
13613
13614                                // hackish: reset scrollTop in default first open case. odd, but some browsers have a non-zero scroll offset the first time the playlist opens.
13615                                if (playlistController && !playlistController.data.selectedIndex && !firstOpen) {
13616                                        dom.playlist.scrollTop = 0;
13617                                        firstOpen = true;
13618                                }
13619
13620                                // sniff out booleans from mouse events, as this is referenced directly by event handlers.
13621                                if (typeof ignoreToggle !== 'boolean' || !ignoreToggle) {
13622
13623                                        if (!isOpen) {
13624                                                // explicitly set height:0, so the first closed -> open animation runs properly
13625                                                dom.playlistContainer.style.height = '0px';
13626                                        }
13627
13628                                        isOpen = utils.css.toggle(dom.o, css.playlistOpen);
13629                                }
13630
13631                                // playlist
13632                                dom.playlistContainer.style.height = (isOpen ? dom.playlistContainer.scrollHeight : 0) + 'px';
13633                        },
13634
13635                        adjustVolume: function adjustVolume(e) {
13636
13637                                /**
13638                                 * NOTE: this is the mousemove() event handler version.
13639                                 * Use setVolume(50), etc., to assign volume directly.
13640                                 */
13641
13642                                var backgroundMargin, pixelMargin, target, value, volume;
13643
13644                                value = 0;
13645
13646                                target = dom.volume;
13647
13648                                // safety net
13649                                if (e === undefined) {
13650                                        return false;
13651                                }
13652
13653                                // normalize between mouse and touch events
13654                                var clientX = utils.events.getClientX(e);
13655
13656                                if (!e || clientX === undefined) {
13657                                        // called directly or with a non-mouseEvent object, etc.
13658                                        // proxy to the proper method.
13659                                        if (arguments.length && window.console && window.console.warn) {
13660                                                console.warn('Bar UI: call setVolume(' + e + ') instead of adjustVolume(' + e + ').');
13661                                        }
13662                                        return actions.setVolume.apply(this, arguments);
13663                                }
13664
13665                                // based on getStyle() result
13666                                // figure out spacing around background image based on background size, eg. 60% background size.
13667                                // 60% wide means 20% margin on each side.
13668                                backgroundMargin = (100 - actionData.volume.backgroundSize) / 2;
13669
13670                                // relative position of mouse over element
13671                                value = Math.max(0, Math.min(1, (clientX - actionData.volume.x) / actionData.volume.width));
13672
13673                                target.style.clip = 'rect(0px, ' + actionData.volume.width * value + 'px, ' + actionData.volume.height + 'px, ' + actionData.volume.width * (backgroundMargin / 100) + 'px)';
13674
13675                                // determine logical volume, including background margin
13676                                pixelMargin = backgroundMargin / 100 * actionData.volume.width;
13677
13678                                volume = Math.max(0, Math.min(1, (clientX - actionData.volume.x - pixelMargin) / (actionData.volume.width - pixelMargin * 2))) * 100;
13679
13680                                // set volume
13681                                if (soundObject) {
13682                                        soundObject.setVolume(volume);
13683                                }
13684
13685                                defaultVolume = volume;
13686
13687                                return utils.events.preventDefault(e);
13688                        },
13689
13690                        releaseVolume: function releaseVolume() /* e */{
13691
13692                                utils.events.remove(document, 'mousemove', actions.adjustVolume);
13693                                utils.events.remove(document, 'touchmove', actions.adjustVolume);
13694                                utils.events.remove(document, 'mouseup', actions.releaseVolume);
13695                                utils.events.remove(document, 'touchend', actions.releaseVolume);
13696                        },
13697
13698                        setVolume: function setVolume(volume) {
13699
13700                                // set volume (0-100) and update volume slider UI.
13701
13702                                var backgroundSize, backgroundMargin, backgroundOffset, target, from, to;
13703
13704                                if (volume === undefined || isNaN(volume)) {
13705                                        return;
13706                                }
13707
13708                                if (dom.volume) {
13709
13710                                        target = dom.volume;
13711
13712                                        // based on getStyle() result
13713                                        backgroundSize = actionData.volume.backgroundSize;
13714
13715                                        // figure out spacing around background image based on background size, eg. 60% background size.
13716                                        // 60% wide means 20% margin on each side.
13717                                        backgroundMargin = (100 - backgroundSize) / 2;
13718
13719                                        // margin as pixel value relative to width
13720                                        backgroundOffset = actionData.volume.width * (backgroundMargin / 100);
13721
13722                                        from = backgroundOffset;
13723                                        to = from + (actionData.volume.width - backgroundOffset * 2) * (volume / 100);
13724
13725                                        target.style.clip = 'rect(0px, ' + to + 'px, ' + actionData.volume.height + 'px, ' + from + 'px)';
13726                                }
13727
13728                                // apply volume to sound, as applicable
13729                                if (soundObject) {
13730                                        soundObject.setVolume(volume);
13731                                }
13732
13733                                defaultVolume = volume;
13734                        }
13735
13736                };
13737
13738                init();
13739
13740                // TODO: mixin actions -> exports
13741
13742                exports = {
13743                        // Per-instance events: window.sm2BarPlayers[0].on = { ... } etc. See global players.on example above for reference.
13744                        on: null,
13745                        actions: actions,
13746                        dom: dom,
13747                        playlistController: playlistController
13748                };
13749
13750                return exports;
13751        };
13752
13753        // barebones utilities for logic, CSS, DOM, events etc.
13754
13755        utils = {
13756
13757                array: function () {
13758
13759                        function compare(property) {
13760
13761                                var result;
13762
13763                                return function (a, b) {
13764
13765                                        if (a[property] < b[property]) {
13766                                                result = -1;
13767                                        } else if (a[property] > b[property]) {
13768                                                result = 1;
13769                                        } else {
13770                                                result = 0;
13771                                        }
13772                                        return result;
13773                                };
13774                        }
13775
13776                        function shuffle(array) {
13777
13778                                // Fisher-Yates shuffle algo
13779
13780                                var i, j, temp;
13781
13782                                for (i = array.length - 1; i > 0; i--) {
13783                                        j = Math.floor(Math.random() * (i + 1));
13784                                        temp = array[i];
13785                                        array[i] = array[j];
13786                                        array[j] = temp;
13787                                }
13788
13789                                return array;
13790                        }
13791
13792                        return {
13793                                compare: compare,
13794                                shuffle: shuffle
13795                        };
13796                }(),
13797
13798                css: function () {
13799
13800                        function hasClass(o, cStr) {
13801
13802                                return o.className !== undefined ? new RegExp('(^|\\s)' + cStr + '(\\s|$)').test(o.className) : false;
13803                        }
13804
13805                        function addClass(o, cStr) {
13806
13807                                if (!o || !cStr || hasClass(o, cStr)) {
13808                                        return; // safety net
13809                                }
13810                                o.className = (o.className ? o.className + ' ' : '') + cStr;
13811                        }
13812
13813                        function removeClass(o, cStr) {
13814
13815                                if (!o || !cStr || !hasClass(o, cStr)) {
13816                                        return;
13817                                }
13818                                o.className = o.className.replace(new RegExp('( ' + cStr + ')|(' + cStr + ')', 'g'), '');
13819                        }
13820
13821                        function swapClass(o, cStr1, cStr2) {
13822
13823                                var tmpClass = {
13824                                        className: o.className
13825                                };
13826
13827                                removeClass(tmpClass, cStr1);
13828                                addClass(tmpClass, cStr2);
13829
13830                                o.className = tmpClass.className;
13831                        }
13832
13833                        function toggleClass(o, cStr) {
13834
13835                                var found, method;
13836
13837                                found = hasClass(o, cStr);
13838
13839                                method = found ? removeClass : addClass;
13840
13841                                method(o, cStr);
13842
13843                                // indicate the new state...
13844                                return !found;
13845                        }
13846
13847                        return {
13848                                has: hasClass,
13849                                add: addClass,
13850                                remove: removeClass,
13851                                swap: swapClass,
13852                                toggle: toggleClass
13853                        };
13854                }(),
13855
13856                dom: function () {
13857
13858                        function getAll(param1, param2) {
13859
13860                                var node, selector, results;
13861
13862                                if (arguments.length === 1) {
13863
13864                                        // .selector case
13865                                        node = document.documentElement;
13866                                        // first param is actually the selector
13867                                        selector = param1;
13868                                } else {
13869
13870                                        // node, .selector
13871                                        node = param1;
13872                                        selector = param2;
13873                                }
13874
13875                                // sorry, IE 7 users; IE 8+ required.
13876                                if (node && node.querySelectorAll) {
13877
13878                                        results = node.querySelectorAll(selector);
13879                                }
13880
13881                                return results;
13882                        }
13883
13884                        function get() /* parentNode, selector */{
13885
13886                                var results = getAll.apply(this, arguments);
13887
13888                                // hackish: if an array, return the last item.
13889                                if (results && results.length) {
13890                                        return results[results.length - 1];
13891                                }
13892
13893                                // handle "not found" case
13894                                return results && results.length === 0 ? null : results;
13895                        }
13896
13897                        function ancestor(nodeName, element, checkCurrent) {
13898
13899                                if (!element || !nodeName) {
13900                                        return element;
13901                                }
13902
13903                                nodeName = nodeName.toUpperCase();
13904
13905                                // return if current node matches.
13906                                if (checkCurrent && element && element.nodeName === nodeName) {
13907                                        return element;
13908                                }
13909
13910                                while (element && element.nodeName !== nodeName && element.parentNode) {
13911                                        element = element.parentNode;
13912                                }
13913
13914                                return element && element.nodeName === nodeName ? element : null;
13915                        }
13916
13917                        return {
13918                                ancestor: ancestor,
13919                                get: get,
13920                                getAll: getAll
13921                        };
13922                }(),
13923
13924                position: function () {
13925
13926                        function getOffX(o) {
13927
13928                                // http://www.xs4all.nl/~ppk/js/findpos.html
13929                                var curleft = 0;
13930
13931                                if (o.offsetParent) {
13932
13933                                        while (o.offsetParent) {
13934
13935                                                curleft += o.offsetLeft;
13936
13937                                                o = o.offsetParent;
13938                                        }
13939                                } else if (o.x) {
13940
13941                                        curleft += o.x;
13942                                }
13943
13944                                return curleft;
13945                        }
13946
13947                        function getOffY(o) {
13948
13949                                // http://www.xs4all.nl/~ppk/js/findpos.html
13950                                var curtop = 0;
13951
13952                                if (o.offsetParent) {
13953
13954                                        while (o.offsetParent) {
13955
13956                                                curtop += o.offsetTop;
13957
13958                                                o = o.offsetParent;
13959                                        }
13960                                } else if (o.y) {
13961
13962                                        curtop += o.y;
13963                                }
13964
13965                                return curtop;
13966                        }
13967
13968                        return {
13969                                getOffX: getOffX,
13970                                getOffY: getOffY
13971                        };
13972                }(),
13973
13974                style: function () {
13975
13976                        function get(node, styleProp) {
13977
13978                                // http://www.quirksmode.org/dom/getstyles.html
13979                                var value;
13980
13981                                if (node.currentStyle) {
13982
13983                                        value = node.currentStyle[styleProp];
13984                                } else if (window.getComputedStyle) {
13985
13986                                        value = document.defaultView.getComputedStyle(node, null).getPropertyValue(styleProp);
13987                                }
13988
13989                                return value;
13990                        }
13991
13992                        return {
13993                                get: get
13994                        };
13995                }(),
13996
13997                events: function () {
13998
13999                        var add, remove, preventDefault, getClientX;
14000
14001                        add = function add(o, evtName, evtHandler) {
14002                                // return an object with a convenient detach method.
14003                                var eventObject = {
14004                                        detach: function detach() {
14005                                                return remove(o, evtName, evtHandler);
14006                                        }
14007                                };
14008                                if (window.addEventListener) {
14009                                        o.addEventListener(evtName, evtHandler, false);
14010                                } else {
14011                                        o.attachEvent('on' + evtName, evtHandler);
14012                                }
14013                                return eventObject;
14014                        };
14015
14016                        remove = window.removeEventListener !== undefined ? function (o, evtName, evtHandler) {
14017                                return o.removeEventListener(evtName, evtHandler, false);
14018                        } : function (o, evtName, evtHandler) {
14019                                return o.detachEvent('on' + evtName, evtHandler);
14020                        };
14021
14022                        preventDefault = function preventDefault(e) {
14023                                if (e.preventDefault) {
14024                                        e.preventDefault();
14025                                } else {
14026                                        e.returnValue = false;
14027                                        e.cancelBubble = true;
14028                                }
14029                                return false;
14030                        };
14031
14032                        getClientX = function getClientX(e) {
14033                                // normalize between desktop (mouse) and touch (mobile/tablet/?) events.
14034                                // note pageX for touch, which normalizes zoom/scroll/pan vs. clientX.
14035                                return e && (e.clientX || e.touches && e.touches[0] && e.touches[0].pageX);
14036                        };
14037
14038                        return {
14039                                add: add,
14040                                preventDefault: preventDefault,
14041                                remove: remove,
14042                                getClientX: getClientX
14043                        };
14044                }(),
14045
14046                features: function () {
14047
14048                        var getAnimationFrame, localAnimationFrame, localFeatures, prop, styles, testDiv, transform;
14049
14050                        testDiv = document.createElement('div');
14051
14052                        /**
14053                         * hat tip: paul irish
14054                         * http://paulirish.com/2011/requestanimationframe-for-smart-animating/
14055                         * https://gist.github.com/838785
14056                         */
14057
14058                        localAnimationFrame = window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || window.oRequestAnimationFrame || window.msRequestAnimationFrame || null;
14059
14060                        // apply to window, avoid "illegal invocation" errors in Chrome
14061                        getAnimationFrame = localAnimationFrame ? function () {
14062                                return localAnimationFrame.apply(window, arguments);
14063                        } : null;
14064
14065                        function has(propName) {
14066
14067                                // test for feature support
14068                                return testDiv.style[propName] !== undefined ? propName : null;
14069                        }
14070
14071                        // note local scope.
14072                        localFeatures = {
14073
14074                                transform: {
14075                                        ie: has('-ms-transform'),
14076                                        moz: has('MozTransform'),
14077                                        opera: has('OTransform'),
14078                                        webkit: has('webkitTransform'),
14079                                        w3: has('transform'),
14080                                        prop: null // the normalized property value
14081                                },
14082
14083                                rotate: {
14084                                        has3D: false,
14085                                        prop: null
14086                                },
14087
14088                                getAnimationFrame: getAnimationFrame
14089
14090                        };
14091
14092                        localFeatures.transform.prop = localFeatures.transform.w3 || localFeatures.transform.moz || localFeatures.transform.webkit || localFeatures.transform.ie || localFeatures.transform.opera;
14093
14094                        function attempt(style) {
14095
14096                                try {
14097                                        testDiv.style[transform] = style;
14098                                } catch (e) {
14099                                        // that *definitely* didn't work.
14100                                        return false;
14101                                }
14102                                // if we can read back the style, it should be cool.
14103                                return !!testDiv.style[transform];
14104                        }
14105
14106                        if (localFeatures.transform.prop) {
14107
14108                                // try to derive the rotate/3D support.
14109                                transform = localFeatures.transform.prop;
14110                                styles = {
14111                                        css_2d: 'rotate(0deg)',
14112                                        css_3d: 'rotate3d(0,0,0,0deg)'
14113                                };
14114
14115                                if (attempt(styles.css_3d)) {
14116                                        localFeatures.rotate.has3D = true;
14117                                        prop = 'rotate3d';
14118                                } else if (attempt(styles.css_2d)) {
14119                                        prop = 'rotate';
14120                                }
14121
14122                                localFeatures.rotate.prop = prop;
14123                        }
14124
14125                        testDiv = null;
14126
14127                        return localFeatures;
14128                }()
14129
14130        };
14131
14132        // ---
14133
14134        // expose to global
14135        window.sm2BarPlayers = players;
14136        window.sm2BarPlayerOptions = playerOptions;
14137        window.SM2BarPlayer = Player;
14138})(window);
14139
14140},{}],21:[function(require,module,exports){
14141"use strict";
14142
14143var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
14144
14145/** @license
14146
14147
14148 SoundManager 2: JavaScript Sound for the Web
14149 ----------------------------------------------
14150 http://schillmania.com/projects/soundmanager2/
14151
14152 Copyright (c) 2007, Scott Schiller. All rights reserved.
14153 Code provided under the BSD License:
14154 http://schillmania.com/projects/soundmanager2/license.txt
14155
14156 V2.97a.20170601
14157*/
14158(function (h, g) {
14159  function J(sb, J) {
14160    function ha(b) {
14161      return c.preferFlash && G && !c.ignoreFlash && c.flash[b] !== g && c.flash[b];
14162    }function r(b) {
14163      return function (d) {
14164        var e = this._s;e && e._a ? d = b.call(this, d) : (e && e.id ? c._wD(e.id + ": Ignoring " + d.type) : c._wD("HTML5::Ignoring " + d.type), d = null);return d;
14165      };
14166    }this.setupOptions = { url: sb || null, flashVersion: 8, debugMode: !0, debugFlash: !1, useConsole: !0, consoleOnly: !0, waitForWindowLoad: !1, bgColor: "#ffffff", useHighPerformance: !1, flashPollingInterval: null, html5PollingInterval: null, flashLoadTimeout: 1E3,
14167      wmode: null, allowScriptAccess: "always", useFlashBlock: !1, useHTML5Audio: !0, forceUseGlobalHTML5Audio: !1, ignoreMobileRestrictions: !1, html5Test: /^(probably|maybe)$/i, preferFlash: !1, noSWFCache: !1, idPrefix: "sound" };this.defaultOptions = { autoLoad: !1, autoPlay: !1, from: null, loops: 1, onid3: null, onerror: null, onload: null, whileloading: null, onplay: null, onpause: null, onresume: null, whileplaying: null, onposition: null, onstop: null, onfinish: null, multiShot: !0, multiShotEvents: !1, position: null, pan: 0, playbackRate: 1, stream: !0, to: null,
14168      type: null, usePolicyFile: !1, volume: 100 };this.flash9Options = { onfailure: null, isMovieStar: null, usePeakData: !1, useWaveformData: !1, useEQData: !1, onbufferchange: null, ondataerror: null };this.movieStarOptions = { bufferTime: 3, serverURL: null, onconnect: null, duration: null };this.audioFormats = { mp3: { type: ['audio/mpeg; codecs="mp3"', "audio/mpeg", "audio/mp3", "audio/MPA", "audio/mpa-robust"], required: !0 }, mp4: { related: ["aac", "m4a", "m4b"], type: ['audio/mp4; codecs="mp4a.40.2"', "audio/aac", "audio/x-m4a", "audio/MP4A-LATM", "audio/mpeg4-generic"],
14169        required: !1 }, ogg: { type: ["audio/ogg; codecs=vorbis"], required: !1 }, opus: { type: ["audio/ogg; codecs=opus", "audio/opus"], required: !1 }, wav: { type: ['audio/wav; codecs="1"', "audio/wav", "audio/wave", "audio/x-wav"], required: !1 }, flac: { type: ["audio/flac"], required: !1 } };this.movieID = "sm2-container";this.id = J || "sm2movie";this.debugID = "soundmanager-debug";this.debugURLParam = /([#?&])debug=1/i;this.versionNumber = "V2.97a.20170601";this.altURL = this.movieURL = this.version = null;this.enabled = this.swfLoaded = !1;this.oMC = null;
14170    this.sounds = {};this.soundIDs = [];this.didFlashBlock = this.muted = !1;this.filePattern = null;this.filePatterns = { flash8: /\.mp3(\?.*)?$/i, flash9: /\.mp3(\?.*)?$/i };this.features = { buffering: !1, peakData: !1, waveformData: !1, eqData: !1, movieStar: !1 };this.sandbox = { type: null, types: { remote: "remote (domain-based) rules", localWithFile: "local with file access (no internet access)", localWithNetwork: "local with network (internet access only, no local access)", localTrusted: "local, trusted (local+internet access)" }, description: null,
14171      noRemote: null, noLocal: null };this.html5 = { usingFlash: null };this.flash = {};this.ignoreFlash = this.html5Only = !1;var V,
14172        c = this,
14173        Ya = null,
14174        l = null,
14175        E,
14176        v = navigator.userAgent,
14177        ia = h.location.href.toString(),
14178        m = document,
14179        xa,
14180        Za,
14181        ya,
14182        n,
14183        H = [],
14184        za = !0,
14185        C,
14186        W = !1,
14187        X = !1,
14188        q = !1,
14189        y = !1,
14190        ja = !1,
14191        p,
14192        tb = 0,
14193        Y,
14194        _A,
14195        _Aa,
14196        Q,
14197        Ba,
14198        O,
14199        _R,
14200        S,
14201        $a,
14202        Ca,
14203        Da,
14204        _ka,
14205        z,
14206        la,
14207        _P,
14208        _Ea,
14209        Z,
14210        ma,
14211        na,
14212        T,
14213        ab,
14214        Fa,
14215        bb = ["log", "info", "warn", "error"],
14216        Ga,
14217        Ha,
14218        cb,
14219        aa = null,
14220        Ia = null,
14221        t,
14222        Ja,
14223        U,
14224        db,
14225        oa,
14226        pa,
14227        K,
14228        w,
14229        ba = !1,
14230        Ka = !1,
14231        eb,
14232        fb,
14233        gb,
14234        qa = 0,
14235        ca = null,
14236        ra,
14237        L = [],
14238        da,
14239        u = null,
14240        hb,
14241        sa,
14242        ea,
14243        ib,
14244        M,
14245        ta,
14246        _La,
14247        jb,
14248        x,
14249        kb = Array.prototype.slice,
14250        B = !1,
14251        Ma,
14252        G,
14253        Na,
14254        lb,
14255        I,
14256        mb,
14257        Oa,
14258        fa,
14259        nb = 0,
14260        Pa,
14261        Qa = v.match(/(ipad|iphone|ipod)/i),
14262        Ra = v.match(/android/i),
14263        N = v.match(/msie|trident/i),
14264        ub = v.match(/webkit/i),
14265        ua = v.match(/safari/i) && !v.match(/chrome/i),
14266        Sa = v.match(/opera/i),
14267        va = v.match(/(mobile|pre\/|xoom)/i) || Qa || Ra,
14268        Ta = !ia.match(/usehtml5audio/i) && !ia.match(/sm2-ignorebadua/i) && ua && !v.match(/silk/i) && v.match(/OS\sX\s10_6_([3-7])/i),
14269        Ua = h.console !== g && console.log !== g,
14270        Va = m.hasFocus !== g ? m.hasFocus() : null,
14271        wa = ua && (m.hasFocus === g || !m.hasFocus()),
14272        ob = !wa,
14273        pb = /(mp3|mp4|mpa|m4a|m4b)/i,
14274        ga = m.location ? m.location.protocol.match(/http/i) : null,
14275        vb = ga ? "" : "//",
14276        qb = /^\s*audio\/(?:x-)?(?:mpeg4|aac|flv|mov|mp4|m4v|m4a|m4b|mp4v|3gp|3g2)\s*(?:$|;)/i,
14277        rb = "mpeg4 aac flv mov mp4 m4v f4v m4a m4b mp4v 3gp 3g2".split(" "),
14278        wb = new RegExp("\\.(" + rb.join("|") + ")(\\?.*)?$", "i");this.mimePattern = /^\s*audio\/(?:x-)?(?:mp(?:eg|3))\s*(?:$|;)/i;this.useAltURL = !ga;ib = [null, "MEDIA_ERR_ABORTED", "MEDIA_ERR_NETWORK", "MEDIA_ERR_DECODE", "MEDIA_ERR_SRC_NOT_SUPPORTED"];var Wa;try {
14279      Wa = Audio !== g && (Sa && opera !== g && 10 > opera.version() ? new Audio(null) : new Audio()).canPlayType !== g;
14280    } catch (xb) {
14281      Wa = !1;
14282    }this.hasHTML5 = Wa;this.setup = function (b) {
14283      var d = !c.url;b !== g && q && u && c.ok() && (b.flashVersion !== g || b.url !== g || b.html5Test !== g) && K(t("setupLate"));_Aa(b);if (!B) if (va) {
14284        if (!c.setupOptions.ignoreMobileRestrictions || c.setupOptions.forceUseGlobalHTML5Audio) L.push(z.globalHTML5), B = !0;
14285      } else c.setupOptions.forceUseGlobalHTML5Audio && (L.push(z.globalHTML5), B = !0);if (!Pa && va) if (c.setupOptions.ignoreMobileRestrictions) L.push(z.ignoreMobile);else if (c.setupOptions.useHTML5Audio && !c.setupOptions.preferFlash || c._wD(z.mobileUA), c.setupOptions.useHTML5Audio = !0, c.setupOptions.preferFlash = !1, Qa) c.ignoreFlash = !0;else if (Ra && !v.match(/android\s2\.3/i) || !Ra) c._wD(z.globalHTML5), B = !0;b && (d && Z && b.url !== g && c.beginDelayedInit(), Z || b.url === g || "complete" !== m.readyState || setTimeout(_P, 1));Pa = !0;return c;
14286    };this.supported = this.ok = function () {
14287      return u ? q && !y : c.useHTML5Audio && c.hasHTML5;
14288    };this.getMovie = function (c) {
14289      return E(c) || m[c] || h[c];
14290    };this.createSound = function (b, d) {
14291      function e() {
14292        f = oa(f);c.sounds[f.id] = new V(f);c.soundIDs.push(f.id);return c.sounds[f.id];
14293      }var a, f;a = null;a = "soundManager.createSound(): " + t(q ? "notOK" : "notReady");if (!q || !c.ok()) return K(a), !1;d !== g && (b = { id: b, url: d });f = _A(b);f.url = ra(f.url);f.id === g && (f.id = c.setupOptions.idPrefix + nb++);f.id.toString().charAt(0).match(/^[0-9]$/) && c._wD("soundManager.createSound(): " + t("badID", f.id), 2);c._wD("soundManager.createSound(): " + f.id + (f.url ? " (" + f.url + ")" : ""), 1);if (w(f.id, !0)) return c._wD("soundManager.createSound(): " + f.id + " exists", 1), c.sounds[f.id];
14294      if (sa(f)) a = e(), c.html5Only || c._wD(f.id + ": Using HTML5"), a._setup_html5(f);else {
14295        if (c.html5Only) return c._wD(f.id + ": No HTML5 support for this sound, and no Flash. Exiting."), e();if (c.html5.usingFlash && f.url && f.url.match(/data:/i)) return c._wD(f.id + ": data: URIs not supported via Flash. Exiting."), e();8 < n && (null === f.isMovieStar && (f.isMovieStar = !!(f.serverURL || f.type && f.type.match(qb) || f.url && f.url.match(wb))), f.isMovieStar && (c._wD("soundManager.createSound(): using MovieStar handling"), 1 < f.loops && p("noNSLoop")));
14296        f = pa(f, "soundManager.createSound(): ");
14296a = e();8 === n ? l._createSound(f.id, f.loops || 1, f.usePolicyFile) : (l._createSound(f.id, f.url, f.usePeakData, f.useWaveformData, f.useEQData, f.isMovieStar, f.isMovieStar ? f.bufferTime : !1, f.loops || 1, f.serverURL, f.duration || null, f.autoPlay, !0, f.autoLoad, f.usePolicyFile), f.serverURL || (a.connected = !0, f.onconnect && f.onconnect.apply(a)));f.serverURL || !f.autoLoad && !f.autoPlay || a.load(f);
14297      }!f.serverURL && f.autoPlay && a.play();return a;
14298    };this.destroySound = function (b, d) {
14299      if (!w(b)) return !1;
14300      var e = c.sounds[b],
14301          a;e.stop();e._iO = {};e.unload();for (a = 0; a < c.soundIDs.length; a++) {
14302        if (c.soundIDs[a] === b) {
14303          c.soundIDs.splice(a, 1);break;
14304        }
14305      }d || e.destruct(!0);delete c.sounds[b];return !0;
14306    };this.load = function (b, d) {
14307      return w(b) ? c.sounds[b].load(d) : !1;
14308    };this.unload = function (b) {
14309      return w(b) ? c.sounds[b].unload() : !1;
14310    };this.onposition = this.onPosition = function (b, d, e, a) {
14311      return w(b) ? c.sounds[b].onposition(d, e, a) : !1;
14312    };this.clearOnPosition = function (b, d, e) {
14313      return w(b) ? c.sounds[b].clearOnPosition(d, e) : !1;
14314    };this.start = this.play = function (b, d) {
14315      var e = null,
14316          a = d && !(d instanceof Object);if (!q || !c.ok()) return K("soundManager.play(): " + t(q ? "notOK" : "notReady")), !1;if (w(b, a)) a && (d = { url: d });else {
14317        if (!a) return !1;a && (d = { url: d });d && d.url && (c._wD('soundManager.play(): Attempting to create "' + b + '"', 1), d.id = b, e = c.createSound(d).play());
14318      }null === e && (e = c.sounds[b].play(d));return e;
14319    };this.setPlaybackRate = function (b, d, e) {
14320      return w(b) ? c.sounds[b].setPlaybackRate(d, e) : !1;
14321    };this.setPosition = function (b, d) {
14322      return w(b) ? c.sounds[b].setPosition(d) : !1;
14323    };this.stop = function (b) {
14324      if (!w(b)) return !1;c._wD("soundManager.stop(" + b + ")", 1);return c.sounds[b].stop();
14325    };this.stopAll = function () {
14326      var b;c._wD("soundManager.stopAll()", 1);for (b in c.sounds) {
14327        c.sounds.hasOwnProperty(b) && c.sounds[b].stop();
14328      }
14329    };this.pause = function (b) {
14330      return w(b) ? c.sounds[b].pause() : !1;
14331    };this.pauseAll = function () {
14332      var b;for (b = c.soundIDs.length - 1; 0 <= b; b--) {
14333        c.sounds[c.soundIDs[b]].pause();
14334      }
14335    };this.resume = function (b) {
14336      return w(b) ? c.sounds[b].resume() : !1;
14337    };this.resumeAll = function () {
14338      var b;for (b = c.soundIDs.length - 1; 0 <= b; b--) {
14339        c.sounds[c.soundIDs[b]].resume();
14340      }
14341    };this.togglePause = function (b) {
14342      return w(b) ? c.sounds[b].togglePause() : !1;
14343    };this.setPan = function (b, d) {
14344      return w(b) ? c.sounds[b].setPan(d) : !1;
14345    };this.setVolume = function (b, d) {
14346      var e, a;if (b !== g && !isNaN(b) && d === g) {
14347        e = 0;for (a = c.soundIDs.length; e < a; e++) {
14348          c.sounds[c.soundIDs[e]].setVolume(b);
14349        }return !1;
14350      }return w(b) ? c.sounds[b].setVolume(d) : !1;
14351    };this.mute = function (b) {
14352      var d = 0;b instanceof String && (b = null);if (b) {
14353        if (!w(b)) return !1;c._wD('soundManager.mute(): Muting "' + b + '"');return c.sounds[b].mute();
14354      }c._wD("soundManager.mute(): Muting all sounds");
14355      for (d = c.soundIDs.length - 1; 0 <= d; d--) {
14356        c.sounds[c.soundIDs[d]].mute();
14357      }return c.muted = !0;
14358    };this.muteAll = function () {
14359      c.mute();
14360    };this.unmute = function (b) {
14361      b instanceof String && (b = null);if (b) {
14362        if (!w(b)) return !1;c._wD('soundManager.unmute(): Unmuting "' + b + '"');return c.sounds[b].unmute();
14363      }c._wD("soundManager.unmute(): Unmuting all sounds");for (b = c.soundIDs.length - 1; 0 <= b; b--) {
14364        c.sounds[c.soundIDs[b]].unmute();
14365      }c.muted = !1;return !0;
14366    };this.unmuteAll = function () {
14367      c.unmute();
14368    };this.toggleMute = function (b) {
14369      return w(b) ? c.sounds[b].toggleMute() : !1;
14370    };this.getMemoryUse = function () {
14371      var c = 0;l && 8 !== n && (c = parseInt(l._getMemoryUse(), 10));return c;
14372    };this.disable = function (b) {
14373      var d;b === g && (b = !1);if (y) return !1;y = !0;p("shutdown", 1);for (d = c.soundIDs.length - 1; 0 <= d; d--) {
14374        Ga(c.sounds[c.soundIDs[d]]);
14375      }Ga(c);Y(b);x.remove(h, "load", _R);return !0;
14376    };this.canPlayMIME = function (b) {
14377      var d;c.hasHTML5 && (d = ea({ type: b }));!d && u && (d = b && c.ok() ? !!(8 < n && b.match(qb) || b.match(c.mimePattern)) : null);return d;
14378    };this.canPlayURL = function (b) {
14379      var d;c.hasHTML5 && (d = ea({ url: b }));!d && u && (d = b && c.ok() ? !!b.match(c.filePattern) : null);return d;
14380    };this.canPlayLink = function (b) {
14381      return b.type !== g && b.type && c.canPlayMIME(b.type) ? !0 : c.canPlayURL(b.href);
14382    };
14382this.getSoundById = function (b, d) {
14383      if (!b) return null;var e = c.sounds[b];e || d || c._wD('soundManager.getSoundById(): Sound "' + b + '" not found.', 2);return e;
14384    };this.onready = function (b, d) {
14385      if ("function" === typeof b) q && c._wD(t("queue", "onready")), d || (d = h), Ba("onready", b, d), O();else throw t("needFunction", "onready");return !0;
14386    };this.ontimeout = function (b, d) {
14387      if ("function" === typeof b) q && c._wD(t("queue", "ontimeout")), d || (d = h), Ba("ontimeout", b, d), O({ type: "ontimeout" });else throw t("needFunction", "ontimeout");return !0;
14388    };this._writeDebug = function (b, d) {
14389      var e, a;if (!c.setupOptions.debugMode) return !1;if (Ua && c.useConsole) {
14390        if (d && "object" === (typeof d === "undefined" ? "undefined" : _typeof(d))) console.log(b, d);else if (bb[d] !== g) console[bb[d]](b);else console.log(b);if (c.consoleOnly) return !0;
14391      }e = E("soundmanager-debug");if (!e) return !1;a = m.createElement("div");0 === ++tb % 2 && (a.className = "sm2-alt");d = d === g ? 0 : parseInt(d, 10);a.appendChild(m.createTextNode(b));
14392      d && (2 <= d && (a.style.fontWeight = "bold"), 3 === d && (a.style.color = "#ff3333"));e.insertBefore(a, e.firstChild);return !0;
14393    };-1 !== ia.indexOf("sm2-debug=alert") && (this._writeDebug = function (c) {
14394      h.alert(c);
14395    });this._wD = this._writeDebug;this._debug = function () {
14396      var b, d;p("currentObj", 1);b = 0;for (d = c.soundIDs.length; b < d; b++) {
14397        c.sounds[c.soundIDs[b]]._debug();
14398      }
14399    };this.reboot = function (b, d) {
14400      c.soundIDs.length && c._wD("Destroying " + c.soundIDs.length + " SMSound object" + (1 !== c.soundIDs.length ? "s" : "") + "...");var e, a, f;for (e = c.soundIDs.length - 1; 0 <= e; e--) {
14401        c.sounds[c.soundIDs[e]].destruct();
14402      }if (l) try {
14403        N && (Ia = l.innerHTML), aa = l.parentNode.removeChild(l);
14404      } catch (g) {
14405        p("badRemove", 2);
14406      }Ia = aa = u = l = null;c.enabled = Z = q = ba = Ka = W = X = y = B = c.swfLoaded = !1;c.soundIDs = [];c.sounds = {};nb = 0;Pa = !1;if (b) H = [];else for (e in H) {
14407        if (H.hasOwnProperty(e)) for (a = 0, f = H[e].length; a < f; a++) {
14408          H[e][a].fired = !1;
14409        }
14410      }d || c._wD("soundManager: Rebooting...");c.html5 = { usingFlash: null };c.flash = {};c.html5Only = !1;c.ignoreFlash = !1;h.setTimeout(function () {
14411        d || c.beginDelayedInit();
14412      }, 20);return c;
14413    };this.reset = function () {
14414      p("reset");return c.reboot(!0, !0);
14415    };this.getMoviePercent = function () {
14416      return l && "PercentLoaded" in l ? l.PercentLoaded() : null;
14417    };this.beginDelayedInit = function () {
14418      ja = !0;_P();setTimeout(function () {
14419        if (Ka) return !1;na();la();return Ka = !0;
14420      }, 20);S();
14421    };this.destruct = function () {
14422      c._wD("soundManager.destruct()");c.disable(!0);
14423    };V = function V(b) {
14424      var d,
14425          e,
14426          a = this,
14427          f,
14428          h,
14429          k,
14430          F,
14431          m,
14432          q,
14433          r = !1,
14434          D = [],
14435          v = 0,
14436          Xa,
14437          y,
14438          u = null,
14439          z;e = d = null;this.sID = this.id = b.id;this.url = b.url;this._iO = this.instanceOptions = this.options = _A(b);this.pan = this.options.pan;
14440      this.volume = this.options.volume;this.isHTML5 = !1;this._a = null;z = !this.url;this.id3 = {};this._debug = function () {
14441        c._wD(a.id + ": Merged options:", a.options);
14442      };this.load = function (b) {
14443        var d = null,
14444            e;b !== g ? a._iO = _A(b, a.options) : (b = a.options, a._iO = b, u && u !== a.url && (p("manURL"), a._iO.url = a.url, a.url = null));a._iO.url || (a._iO.url = a.url);a._iO.url = ra(a._iO.url);e = a.instanceOptions = a._iO;c._wD(a.id + ": load (" + e.url + ")");if (!e.url && !a.url) return c._wD(a.id + ": load(): url is unassigned. Exiting.", 2), a;a.isHTML5 || 8 !== n || a.url || e.autoPlay || c._wD(a.id + ": Flash 8 load() limitation: Wait for onload() before calling play().", 1);if (e.url === a.url && 0 !== a.readyState && 2 !== a.readyState) return p("onURL", 1), 3 === a.readyState && e.onload && fa(a, function () {
14445          e.onload.apply(a, [!!a.duration]);
14446        }), a;a.loaded = !1;a.readyState = 1;a.playState = 0;a.id3 = {};if (sa(e)) d = a._setup_html5(e), d._called_load ? c._wD(a.id + ": Ignoring request to load again") : (a._html5_canplay = !1, a.url !== e.url && (c._wD(p("manURL") + ": " + e.url), a._a.src = e.url, a.setPosition(0)), a._a.autobuffer = "auto", a._a.preload = "auto", a._a._called_load = !0);else {
14447          if (c.html5Only) return c._wD(a.id + ": No flash support. Exiting."), a;if (a._iO.url && a._iO.url.match(/data:/i)) return c._wD(a.id + ": data: URIs not supported via Flash. Exiting."), a;try {
14448            a.isHTML5 = !1, a._iO = pa(oa(e)), a._iO.autoPlay && (a._iO.position || a._iO.from) && (c._wD(a.id + ": Disabling autoPlay because of non-zero offset case"), a._iO.autoPlay = !1), e = a._iO, 8 === n ? l._load(a.id, e.url, e.stream, e.autoPlay, e.usePolicyFile) : l._load(a.id, e.url, !!e.stream, !!e.autoPlay, e.loops || 1, !!e.autoLoad, e.usePolicyFile);
14449          } catch (f) {
14450            p("smError", 2), C("onload", !1), T({ type: "SMSOUND_LOAD_JS_EXCEPTION", fatal: !0 });
14451          }
14452        }a.url = e.url;return a;
14453      };this.unload = function () {
14454        0 !== a.readyState && (c._wD(a.id + ": unload()"), a.isHTML5 ? (F(), a._a && (a._a.pause(), u = ta(a._a))) : 8 === n ? l._unload(a.id, "about:blank") : l._unload(a.id), f());return a;
14455      };this.destruct = function (b) {
14456        c._wD(a.id + ": Destruct");a.isHTML5 ? (F(), a._a && (a._a.pause(), ta(a._a), B || k(), a._a._s = null, a._a = null)) : (a._iO.onfailure = null, l._destroySound(a.id));
14457        b || c.destroySound(a.id, !0);
14458      };this.start = this.play = function (b, d) {
14459        var e, f, k, _F, _h;f = !0;e = a.id + ": play(): ";d = d === g ? !0 : d;b || (b = {});a.url && (a._iO.url = a.url);a._iO = _A(a._iO, a.options);a._iO = _A(b, a._iO);a._iO.url = ra(a._iO.url);a.instanceOptions = a._iO;if (!a.isHTML5 && a._iO.serverURL && !a.connected) return a.getAutoPlay() || (c._wD(e + " Netstream not connected yet - setting autoPlay"), a.setAutoPlay(!0)), a;sa(a._iO) && (a._setup_html5(a._iO), m());if (1 === a.playState && !a.paused) {
14460          f = a._iO.multiShot;if (!f) return c._wD(e + "Already playing (one-shot)", 1), a.isHTML5 && a.setPosition(a._iO.position), a;c._wD(e + "Already playing (multi-shot)", 1);
14461        }b.url && b.url !== a.url && (a.readyState || a.isHTML5 || 8 !== n || !z ? a.load(a._iO) : z = !1);if (a.loaded) c._wD(e.substr(0, e.lastIndexOf(":")));else if (0 === a.readyState) {
14462          c._wD(e + "Attempting to load");if (a.isHTML5 || c.html5Only) {
14463            if (a.isHTML5) a.load(a._iO);else return c._wD(e + "Unsupported type. Exiting."), a;
14464          } else a._iO.autoPlay = !0, a.load(a._iO);a.instanceOptions = a._iO;
14465        } else {
14466          if (2 === a.readyState) return c._wD(e + "Could not load - exiting", 2), a;c._wD(e + "Loading - attempting to play...");
14467        }!a.isHTML5 && 9 === n && 0 < a.position && a.position === a.duration && (c._wD(e + "Sound at end, resetting to position: 0"), b.position = 0);a.paused && 0 <= a.position && (!a._iO.serverURL || 0 < a.position) ? (c._wD(e + "Resuming from paused state", 1), a.resume()) : (a._iO = _A(b, a._iO), (!a.isHTML5 && null !== a._iO.position && 0 < a._iO.position || null !== a._iO.from && 0 < a._iO.from || null !== a._iO.to) && 0 === a.instanceCount && 0 === a.playState && !a._iO.serverURL && (f = function f() {
14468          a._iO = _A(b, a._iO);a.play(a._iO);
14469        }, a.isHTML5 && !a._html5_canplay ? (c._wD(e + "Beginning load for non-zero offset case"), a.load({ _oncanplay: f })) : a.isHTML5 || a.loaded || a.readyState && 2 === a.readyState || (c._wD(e + "Preloading for non-zero offset case"), a.load({ onload: f })), a._iO = y()), (!a.instanceCount || a._iO.multiShotEvents || a.isHTML5 && a._iO.multiShot && !B || !a.isHTML5 && 8 < n && !a.getAutoPlay()) && a.instanceCount++, a._iO.onposition && 0 === a.playState && q(a), a.playState = 1, a.paused = !1, a.position = a._iO.position === g || isNaN(a._iO.position) ? 0 : a._iO.position, a.isHTML5 || (a._iO = pa(oa(a._iO))), a._iO.onplay && d && (a._iO.onplay.apply(a), r = !0), a.setVolume(a._iO.volume, !0), a.setPan(a._iO.pan, !0), 1 !== a._iO.playbackRate && a.setPlaybackRate(a._iO.playbackRate), a.isHTML5 ? 2 > a.instanceCount ? (m(), e = a._setup_html5(), a.setPosition(a._iO.position), e.play()) : (c._wD(a.id + ": Cloning Audio() for instance #" + a.instanceCount + "..."), k = new Audio(a._iO.url), _F = function F() {
14470          x.remove(k, "ended", _F);a._onfinish(a);ta(k);k = null;
14471        }, _h = function h() {
14472          x.remove(k, "canplay", _h);try {
14473            k.currentTime = a._iO.position / 1E3;
14474          } catch (c) {
14475            K(a.id + ": multiShot play() failed to apply position of " + a._iO.position / 1E3);
14476          }k.play();
14477        }, x.add(k, "ended", _F), a._iO.volume !== g && (k.volume = Math.max(0, Math.min(1, a._iO.volume / 100))), a.muted && (k.muted = !0), a._iO.position ? x.add(k, "canplay", _h) : k.play()) : (f = l._start(a.id, a._iO.loops || 1, 9 === n ? a.position : a.position / 1E3, a._iO.multiShot || !1), 9 !== n || f || (c._wD(e + "No sound hardware, or 32-sound ceiling hit", 2), a._iO.onplayerror && a._iO.onplayerror.apply(a))));return a;
14478      };this.stop = function (b) {
14479        var d = a._iO;
14480        1 === a.playState && (c._wD(a.id + ": stop()"), a._onbufferchange(0), a._resetOnPosition(0), a.paused = !1, a.isHTML5 || (a.playState = 0), Xa(), d.to && a.clearOnPosition(d.to), a.isHTML5 ? a._a && (b = a.position, a.setPosition(0), a.position = b, a._a.pause(), a.playState = 0, a._onTimer(), F()) : (l._stop(a.id, b), d.serverURL && a.unload()), a.instanceCount = 0, a._iO = {}, d.onstop && d.onstop.apply(a));return a;
14481      };this.setAutoPlay = function (b) {
14482        c._wD(a.id + ": Autoplay turned " + (b ? "on" : "off"));a._iO.autoPlay = b;a.isHTML5 || (l._setAutoPlay(a.id, b), b && !a.instanceCount && 1 === a.readyState && (a.instanceCount++, c._wD(a.id + ": Incremented instance count to " + a.instanceCount)));
14483      };this.getAutoPlay = function () {
14484        return a._iO.autoPlay;
14485      };this.setPlaybackRate = function (b) {
14486        var d = Math.max(.5, Math.min(4, b));d !== b && c._wD(a.id + ": setPlaybackRate(" + b + "): limiting rate to " + d, 2);if (a.isHTML5) try {
14487          a._iO.playbackRate = d, a._a.playbackRate = d;
14488        } catch (e) {
14489          c._wD(a.id + ": setPlaybackRate(" + d + ") failed: " + e.message, 2);
14490        }return a;
14491      };this.setPosition = function (b) {
14492        b === g && (b = 0);var d = a.isHTML5 ? Math.max(b, 0) : Math.min(a.duration || a._iO.duration, Math.max(b, 0));a.position = d;b = a.position / 1E3;a._resetOnPosition(a.position);a._iO.position = d;if (!a.isHTML5) b = 9 === n ? a.position : b, a.readyState && 2 !== a.readyState && l._setPosition(a.id, b, a.paused || !a.playState, a._iO.multiSh
14492ot);else if (a._a) {
14493          if (a._html5_canplay) {
14494            if (a._a.currentTime.toFixed(3) !== b.toFixed(3)) {
14495              c._wD(a.id + ": setPosition(" + b + ")");try {
14496                a._a.currentTime = b, (0 === a.playState || a.paused) && a._a.pause();
14497              } catch (e) {
14498                c._wD(a.id + ": setPosition(" + b + ") failed: " + e.message, 2);
14499              }
14500            }
14501          } else if (b) return c._wD(a.id + ": setPosition(" + b + "): Cannot seek yet, sound not ready", 2), a;a.paused && a._onTimer(!0);
14502        }return a;
14503      };this.pause = function (b) {
14504        if (a.paused || 0 === a.playState && 1 !== a.readyState) return a;c._wD(a.id + ": pause()");a.paused = !0;a.isHTML5 ? (a._setup_html5().pause(), F()) : (b || b === g) && l._pause(a.id, a._iO.multiShot);a._iO.onpause && a._iO.onpause.apply(a);return a;
14505      };this.resume = function () {
14506        var b = a._iO;if (!a.paused) return a;c._wD(a.id + ": resume()");a.paused = !1;a.playState = 1;a.isHTML5 ? (a._setup_html5().play(), m()) : (b.isMovieStar && !b.serverURL && a.setPosition(a.position), l._pause(a.id, b.multiShot));!r && b.onplay ? (b.onplay.apply(a), r = !0) : b.onresume && b.onresume.apply(a);return a;
14507      };this.togglePause = function () {
14508        c._wD(a.id + ": togglePause()");if (0 === a.playState) return a.play({ position: 9 !== n || a.isHTML5 ? a.position / 1E3 : a.position }), a;a.paused ? a.resume() : a.pause();return a;
14509      };this.setPan = function (b, c) {
14510        b === g && (b = 0);c === g && (c = !1);a.isHTML5 || l._setPan(a.id, b);a._iO.pan = b;c || (a.pan = b, a.options.pan = b);return a;
14511      };this.setVolume = function (b, d) {
14512        b === g && (b = 100);d === g && (d = !1);a.isHTML5 ? a._a && (c.muted && !a.muted && (a.muted = !0, a._a.muted = !0), a._a.volume = Math.max(0, Math.min(1, b / 100))) : l._setVolume(a.id, c.muted && !a.muted || a.muted ? 0 : b);a._iO.volume = b;d || (a.volume = b, a.options.volume = b);return a;
14513      };this.mute = function () {
14514        a.muted = !0;a.isHTML5 ? a._a && (a._a.muted = !0) : l._setVolume(a.id, 0);return a;
14515      };this.unmute = function () {
14516        a.muted = !1;var b = a._iO.volume !== g;a.isHTML5 ? a._a && (a._a.muted = !1) : l._setVolume(a.id, b ? a._iO.volume : a.options.volume);return a;
14517      };this.toggleMute = function () {
14518        return a.muted ? a.unmute() : a.mute();
14519      };this.onposition = this.onPosition = function (b, c, d) {
14520        D.push({ position: parseInt(b, 10), method: c, scope: d !== g ? d : a, fired: !1 });return a;
14521      };this.clearOnPosition = function (a, b) {
14522        var c;a = parseInt(a, 10);if (!isNaN(a)) for (c = 0; c < D.length; c++) {
14523          a !== D[c].position || b && b !== D[c].method || (D[c].fired && v--, D.splice(c, 1));
14524        }
14525      };this._processOnPosition = function () {
14526        var b, c;b = D.length;if (!b || !a.playState || v >= b) return !1;for (--b; 0 <= b; b--) {
14527          c = D[b], !c.fired && a.position >= c.position && (c.fired = !0, v++, c.method.apply(c.scope, [c.position]));
14528        }return !0;
14529      };this._resetOnPosition = function (a) {
14530        var b, c;b = D.length;if (!b) return !1;for (--b; 0 <= b; b--) {
14531          c = D[b], c.fired && a <= c.position && (c.fired = !1, v--);
14532        }return !0;
14533      };y = function y() {
14534        var b = a._iO,
14535            d = b.from,
14536            e = b.to,
14537            f,
14538            _g;_g = function g() {
14539          c._wD(a.id + ': "To" time of ' + e + " reached.");a.clearOnPosition(e, _g);a.stop();
14540        };f = function f() {
14541          c._wD(a.id + ': Playing "from" ' + d);if (null !== e && !isNaN(e)) a.onPosition(e, _g);
14542        };null === d || isNaN(d) || (b.position = d, b.multiShot = !1, f());return b;
14543      };q = function q() {
14544        var b,
14545            c = a._iO.onposition;if (c) for (b in c) {
14546          if (c.hasOwnProperty(b)) a.onPosition(parseInt(b, 10), c[b]);
14547        }
14548      };Xa = function Xa() {
14549        var b,
14550            c = a._iO.onposition;if (c) for (b in c) {
14551          c.hasOwnProperty(b) && a.clearOnPosition(parseInt(b, 10));
14552        }
14553      };m = function m() {
14554        a.isHTML5 && eb(a);
14555      };F = function F() {
14556        a.isHTML5 && fb(a);
14557      };f = function f(b) {
14558        b || (D = [], v = 0);r = !1;a._hasTimer = null;a._a = null;a._html5_canplay = !1;a.bytesLoaded = null;a.bytesTotal = null;a.duration = a._iO && a._iO.duration ? a._iO.duration : null;a.durationEstimate = null;a.buffered = [];a.eqData = [];a.eqData.left = [];a.eqData.right = [];a.failures = 0;a.isBuffering = !1;a.instanceOptions = {};a.instanceCount = 0;a.loaded = !1;a.metadata = {};a.readyState = 0;a.muted = !1;a.paused = !1;a.peakData = { left: 0, right: 0 };a.waveformData = { left: [], right: [] };a.playState = 0;a.position = null;a.id3 = {};
14559      };f();this._onTimer = function (b) {
14560        var c,
14561            f = !1,
14562            g = {};(a._hasTimer || b) && a._a && (b || (0 < a.playState || 1 === a.readyState) && !a.paused) && (c = a._get_html5_duration(), c !== d && (d = c, a.duration = c, f = !0), a.durationEstimate = a.duration, c = 1E3 * a._a.currentTime || 0, c !== e && (e = c, f = !0), (f || b) && a._whileplaying(c, g, g, g, g));return f;
14563      };this._get_html5_duration = function () {
14564        var b = a._iO;return (b = a._a && a._a.duration ? 1E3 * a._a.duration : b && b.duration ? b.duration : null) && !isNaN(b) && Infinity !== b ? b : null;
14565      };this._apply_loop = function (a, b) {
14566        !a.loop && 1 < b && c._wD("Note: Native HTML5 looping is infinite.", 1);a.loop = 1 < b ? "loop" : "";
14567      };this._setup_html5 = function (b) {
14568        b = _A(a._iO, b);var c = B ? Ya : a._a,
14569            d = decodeURI(b.url),
14570            e;
14570B ? d === decodeURI(Ma) && (e = !0) : d === decodeURI(u) && (e = !0);if (c) {
14571          if (c._s) if (B) c._s && c._s.playState && !e && c._s.stop();else if (!B && d === decodeURI(u)) return a._apply_loop(c, b.loops), c;e || (u && f(!1), c.src = b.url, Ma = u = a.url = b.url, c._called_load = !1);
14572        } else b.autoLoad || b.autoPlay ? (a._a = new Audio(b.url), a._a.load()) : a._a = Sa && 10 > opera.version() ? new Audio(null) : new Audio(), c = a._a, c._called_load = !1, B && (Ya = c);a.isHTML5 = !0;a._a = c;c._s = a;h();a._apply_loop(c, b.loops);b.autoLoad || b.autoPlay ? a.load() : (c.autobuffer = !1, c.preload = "auto");return c;
14573      };h = function h() {
14574        if (a._a._added_events) return !1;var b;a._a._added_events = !0;for (b in I) {
14575          I.hasOwnProperty(b) && a._a && a._a.addEventListener(b, I[b], !1);
14576        }return !0;
14577      };k = function k() {
14578        var b;c._wD(a.id + ": Removing event listeners");a._a._added_events = !1;for (b in I) {
14579          I.hasOwnProperty(b) && a._a && a._a.removeEventListener(b, I[b], !1);
14580        }
14581      };this._onload = function (b) {
14582        var d = !!b || !a.isHTML5 && 8 === n && a.duration;b = a.id + ": ";c._wD(b + (d ? "onload()" : "Failed to load / invalid sound?" + (a.duration ? " -" : " Zero-length duration reported.") + " (" + a.url + ")"), d ? 1 : 2);d || a.isHTML5 || (!0 === c.sandbox.noRemote && c._wD(b + t("noNet"), 1), !0 === c.sandbox.noLocal && c._wD(b + t("noLocal"), 1));a.loaded = d;a.readyState = d ? 3 : 2;a._onbufferchange(0);d || a.isHTML5 || a._onerror();a._iO.onload && fa(a, function () {
14583          a._iO.onload.apply(a, [d]);
14584        });return !0;
14585      };this._onerror = function (b, c) {
14586        a._iO.onerror && fa(a, function () {
14587          a._iO.onerror.apply(a, [b, c]);
14588        });
14589      };this._onbufferchange = function (b) {
14590        if (0 === a.playState || b && a.isBuffering || !b && !a.isBuffering) return !1;a.isBuffering = 1 === b;a._iO.onbufferchange && (c._wD(a.id + ": Buffer state change: " + b), a._iO.onbufferchange.apply(a, [b]));
14591        return !0;
14592      };this._onsuspend = function () {
14593        a._iO.onsuspend && (c._wD(a.id + ": Playback suspended"), a._iO.onsuspend.apply(a));return !0;
14594      };this._onfailure = function (b, d, e) {
14595        a.failures++;c._wD(a.id + ": Failure (" + a.failures + "): " + b);if (a._iO.onfailure && 1 === a.failures) a._iO.onfailure(b, d, e);else c._wD(a.id + ": Ignoring failure");
14596      };this._onwarning = function (b, c, d) {
14597        if (a._iO.onwarning) a._iO.onwarning(b, c, d);
14598      };this._onfinish = function () {
14599        var b = a._iO.onfinish;a._onbufferchange(0);a._resetOnPosition(0);a.instanceCount && (a.instanceCount--, a.instanceCount || (Xa(), a.playState = 0, a.paused = !1, a.instanceCount = 0, a.instanceOptions = {}, a._iO = {}, F(), a.isHTML5 && (a.position = 0)), a.instanceCount && !a._iO.multiShotEvents || !b || (c._wD(a.id + ": onfinish()"), fa(a, function () {
14600          b.apply(a);
14601        })));
14602      };this._whileloading = function (b, c, d, e) {
14603        var f = a._iO;a.bytesLoaded = b;a.bytesTotal = c;a.duration = Math.floor(d);a.bufferLength = e;a.durationEstimate = a.isHTML5 || f.isMovieStar ? a.duration : f.duration ? a.duration > f.duration ? a.duration : f.duration : parseInt(a.bytesTotal / a.bytesLoaded * a.duration, 10);a.isHTML5 || (a.buffered = [{ start: 0, end: a.duration }]);(3 !== a.readyState || a.isHTML5) && f.whileloading && f.whileloading.apply(a);
14604      };this._whileplaying = function (b, c, d, e, f) {
14605        var k = a._iO;if (isNaN(b) || null === b) return !1;a.position = Math.max(0, b);a._processOnPosition();!a.isHTML5 && 8 < n && (k.usePeakData && c !== g && c && (a.peakData = { left: c.leftPeak, right: c.rightPeak }), k.useWaveformData && d !== g && d && (a.waveformData = { left: d.split(","), right: e.split(",") }), k.useEQData && f !== g && f && f.leftEQ && (b = f.leftEQ.split(","), a.eqData = b, a.eqData.left = b, f.rightEQ !== g && f.rightEQ && (a.eqData.right = f.rightEQ.split(","))));1 === a.playState && (a.isHTML5 || 8 !== n || a.position || !a.isBuffering || a._onbufferchange(0), k.whileplaying && k.whileplaying.apply(a));return !0;
14606      };this._oncaptiondata = function (b) {
14607        c._wD(a.id + ": Caption data received.");a.captiondata = b;a._iO.oncaptiondata && a._iO.oncaptiondata.apply(a, [b]);
14608      };this._onmetadata = function (b, d) {
14609        c._wD(a.id + ": Metadata received.");var e = {},
14610            f,
14611            g;f = 0;for (g = b.length; f < g; f++) {
14612          e[b[f]] = d[f];
14613        }a.metadata = e;a._iO.onmetadata && a._iO.onmetadata.call(a, a.metadata);
14614      };this._onid3 = function (b, d) {
14615        c._wD(a.id + ": ID3 data received.");var e = [],
14616            f,
14617            g;f = 0;for (g = b.length; f < g; f++) {
14618          e[b[f]] = d[f];
14619        }a.id3 = _A(a.id3, e);a._iO.onid3 && a._iO.onid3.apply(a);
14620      };this._onconnect = function (b) {
14621        b = 1 === b;c._wD(a.id + ": " + (b ? "Connected." : "Failed to connect? - " + a.url), b ? 1 : 2);if (a.connected = b) a.failures = 0, w(a.id) && (a.getAutoPlay() ? a.play(g, a.getAutoPlay()) : a._iO.autoLoad && a.load()), a._iO.onconnect && a._iO.onconnect.apply(a, [b]);
14622      };this._ondataerror = function (b) {
14623        0 < a.playState && (c._wD(a.id + ": Data error: " + b), a._iO.ondataerror && a._iO.ondataerror.apply(a));
14624      };this._debug();
14625    };ma = function ma() {
14626      return m.body || m.getElementsByTagName("div")[0];
14627    };E = function E(b) {
14628      return m.getElementById(b);
14629    };_A = function A(b, d) {
14630      var e = b || {},
14631          a,
14632          f;a = d === g ? c.defaultOptions : d;for (f in a) {
14633        a.hasOwnProperty(f) && e[f] === g && (e[f] = "object" !== _typeof(a[f]) || null === a[f] ? a[f] : _A(e[f], a[f]));
14634      }return e;
14635    };fa = function fa(b, c) {
14636      b.isHTML5 || 8 !== n ? c() : h.setTimeout(c, 0);
14637    };Q = { onready: 1, ontimeout: 1, defaultOptions: 1, flash9Options: 1,
14638      movieStarOptions: 1 };_Aa = function Aa(b, d) {
14639      var e,
14640          a = !0,
14641          f = d !== g,
14642          h = c.setupOptions;if (b === g) {
14643        a = [];for (e in h) {
14644          h.hasOwnProperty(e) && a.push(e);
14645        }for (e in Q) {
14646          Q.hasOwnProperty(e) && ("object" === _typeof(c[e]) ? a.push(e + ": {...}") : c[e] instanceof Function ? a.push(e + ": function() {...}") : a.push(e));
14647        }c._wD(t("setup", a.join(", ")));return !1;
14648      }for (e in b) {
14649        if (b.hasOwnProperty(e)) if ("object" !== _typeof(b[e]) || null === b[e] || b[e] instanceof Array || b[e] instanceof RegExp) f && Q[d] !== g ? c[d][e] = b[e] : h[e] !== g ? (c.setupOptions[e] = b[e], c[e] = b[e]) : Q[e] === g ? (K(t(c[e] === g ? "setupUndef" : "setupError", e), 2), a = !1) : c[e] instanceof Function ? c[e].apply(c, b[e] instanceof Array ? b[e] : [b[e]]) : c[e] = b[e];else if (Q[e] === g) K(t(c[e] === g ? "setupUndef" : "setupError", e), 2), a = !1;else return _Aa(b[e], e);
14650      }return a;
14651    };x = function () {
14652      function b(a) {
14653        a = kb.call(a);var b = a.length;e ? (a[1] = "on" + a[1], 3 < b && a.pop()) : 3 === b && a.push(!1);return a;
14654      }function c(b, d) {
14655        var g = b.shift(),
14656            h = [a[d]];if (e) g[h](b[0], b[1]);else g[h].apply(g, b);
14657      }var e = h.attachEvent,
14658          a = { add: e ? "attachEvent" : "addEventListener", remove: e ? "detachEvent" : "removeEventListener" };return { add: function add() {
14659          c(b(arguments), "add");
14660        }, remove: function remove() {
14661          c(b(arguments), "remove");
14662        } };
14663    }();I = { abort: r(function () {
14664        c._wD(this._s.id + ": abort");
14665      }), canplay: r(function () {
14666        var b = this._s,
14667            d;if (!b._html5_canplay) {
14668          b._html5_canplay = !0;c._wD(b.id + ": canplay");b._onbufferchange(0);d = b._iO.position === g || isNaN(b._iO.position) ? null : b._iO.position / 1E3;if (this.currentTime !== d) {
14669            c._wD(b.id + ": canplay: Setting position to " + d);try {
14670              this.currentTime = d;
14671            } catch (e) {
14672              c._wD(b.id + ": canplay: Setting position of " + d + " failed: " + e.message, 2);
14673            }
14674          }b._iO._oncanplay && b._iO._oncanplay();
14675        }
14676      }), canplaythrough: r(function () {
14677        var b = this._s;b.loaded || (b._onbufferchange(0), b._whileloading(b.bytesLoaded, b.bytesTotal, b._get_html5_duration()), b._onload(!0));
14678      }), durationchange: r(function () {
14679        var b = this._s,
14680            d;d = b._get_html5_duration();isNaN(d) || d === b.duration || (c._wD(this._s.id + ": durationchange (" + d + ")" + (b.duration ? ", previously " + b.duration : "")), b.durationEstimate = b.duration = d);
14681      }), ended: r(function () {
14682        var b = this._s;c._wD(b.id + ": ended");
14683        b._onfinish();
14684      }), error: r(function () {
14685        var b = ib[this.error.code] || null;c._wD(this._s.id + ": HTML5 error, code " + this.error.code + (b ? " (" + b + ")" : ""));this._s._onload(!1);
14685this._s._onerror(this.error.code, b);
14686      }), loadeddata: r(function () {
14687        var b = this._s;c._wD(b.id + ": loadeddata");b._loaded || ua || (b.duration = b._get_html5_duration());
14688      }), loadedmetadata: r(function () {
14689        c._wD(this._s.id + ": loadedmetadata");
14690      }), loadstart: r(function () {
14691        c._wD(this._s.id + ": loadstart");this._s._onbufferchange(1);
14692      }), play: r(function () {
14693        this._s._onbufferchange(0);
14694      }),
14695      playing: r(function () {
14696        c._wD(this._s.id + ": playing " + String.fromCharCode(9835));this._s._onbufferchange(0);
14697      }), progress: r(function (b) {
14698        var d = this._s,
14699            e,
14700            a,
14701            f;e = 0;var g = "progress" === b.type,
14702            k = b.target.buffered,
14703            h = b.loaded || 0,
14704            m = b.total || 1;d.buffered = [];if (k && k.length) {
14705          e = 0;for (a = k.length; e < a; e++) {
14706            d.buffered.push({ start: 1E3 * k.start(e), end: 1E3 * k.end(e) });
14707          }e = 1E3 * (k.end(0) - k.start(0));h = Math.min(1, e / (1E3 * b.target.duration));if (g && 1 < k.length) {
14708            f = [];a = k.length;for (e = 0; e < a; e++) {
14709              f.push(1E3 * b.target.buffered.start(e) + "-" + 1E3 * b.target.buffered.end(e));
14710            }c._wD(this._s.id + ": progress, timeRanges: " + f.join(", "));
14711          }g && !isNaN(h) && c._wD(this._s.id + ": progress, " + Math.floor(100 * h) + "% loaded");
14712        }isNaN(h) || (d._whileloading(h, m, d._get_html5_duration()), h && m && h === m && I.canplaythrough.call(this, b));
14713      }), ratechange: r(function () {
14714        c._wD(this._s.id + ": ratechange");
14715      }), suspend: r(function (b) {
14716        var d = this._s;c._wD(this._s.id + ": suspend");I.progress.call(this, b);d._onsuspend();
14717      }), stalled: r(function () {
14718        c._wD(this._s.id + ": stalled");
14719      }), timeupdate: r(function () {
14720        this._s._onTimer();
14721      }),
14722      waiting: r(function () {
14723        var b = this._s;c._wD(this._s.id + ": waiting");b._onbufferchange(1);
14724      }) };sa = function sa(b) {
14725      return b && (b.type || b.url || b.serverURL) ? b.serverURL || b.type && ha(b.type) ? !1 : b.type ? ea({ type: b.type }) : ea({ url: b.url }) || c.html5Only || b.url.match(/data:/i) : !1;
14726    };ta = function ta(b) {
14727      var d;b && (d = ua ? "about:blank" : c.html5.canPlayType("audio/wav") ? "data:audio/wave;base64,/UklGRiYAAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQIAAAD//w==" : "about:blank", b.src = d, b._called_unload !== g && (b._called_load = !1));B && (Ma = null);
14728      return d;
14729    };ea = function ea(b) {
14730      if (!c.useHTML5Audio || !c.hasHTML5) return !1;var d = b.url || null;b = b.type || null;var e = c.audioFormats,
14731          a;if (b && c.html5[b] !== g) return c.html5[b] && !ha(b);if (!M) {
14732        M = [];for (a in e) {
14733          e.hasOwnProperty(a) && (M.push(a), e[a].related && (M = M.concat(e[a].related)));
14734        }M = new RegExp("\\.(" + M.join("|") + ")(\\?.*)?$", "i");
14735      }(a = d ? d.toLowerCase().match(M) : null) && a.length ? a = a[1] : b && (d = b.indexOf(";"), a = (-1 !== d ? b.substr(0, d) : b).substr(6));a && c.html5[a] !== g ? d = c.html5[a] && !ha(a) : (b = "audio/" + a, d = c.html5.canPlayType({ type: b }), d = (c.html5[a] = d) && c.html5[b] && !ha(b));return d;
14736    };jb = function jb() {
14737      function b(a) {
14738        var b,
14739            e = b = !1;if (!d || "function" !== typeof d.canPlayType) return b;if (a instanceof Array) {
14740          k = 0;for (b = a.length; k < b; k++) {
14741            if (c.html5[a[k]] || d.canPlayType(a[k]).match(c.html5Test)) e = !0, c.html5[a[k]] = !0, c.flash[a[k]] = !!a[k].match(pb);
14742          }b = e;
14743        } else a = d && "function" === typeof d.canPlayType ? d.canPlayType(a) : !1, b = !(!a || !a.match(c.html5Test));return b;
14744      }if (!c.useHTML5Audio || !c.hasHTML5) return u = c.html5.usingFlash = !0, !1;var d = Audio !== g ? Sa && 10 > opera.version() ? new Audio(null) : new Audio() : null,
14745          e,
14746          a,
14747          f = {},
14748          h,
14749          k;h = c.audioFormats;for (e in h) {
14750        if (h.hasOwnProperty(e) && (a = "audio/" + e, f[e] = b(h[e].type), f[a] = f[e], e.match(pb) ? (c.flash[e] = !0, c.flash[a] = !0) : (c.flash[e] = !1, c.flash[a] = !1), h[e] && h[e].related)) for (k = h[e].related.length - 1; 0 <= k; k--) {
14751          f["audio/" + h[e].related[k]] = f[e], c.html5[h[e].related[k]] = f[e], c.flash[h[e].related[k]] = f[e];
14752        }
14753      }f.canPlayType = d ? b : null;c.html5 = _A(c.html5, f);c.html5.usingFlash = hb();u = c.html5.usingFlash;return !0;
14754    };z = { notReady: "Unavailable - wait until onready() has fired.",
14755      notOK: "Audio support is not available.", domError: "soundManagerexception caught while appending SWF to DOM.", spcWmode: "Removing wmode, preventing known SWF loading issue(s)", swf404: "soundManager: Verify that %s is a valid path.", tryDebug: "Try soundManager.debugFlash = true for more security details (output goes to SWF.)", checkSWF: "See SWF output for more debug info.", localFail: "soundManager: Non-HTTP page (" + m.location.protocol + " URL?) Review Flash player security settings for this special case:\nhttp://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager04.html\nM
14755ay need to add/allow path, eg. c:/sm2/ or /users/me/sm2/",
14756      waitFocus: "soundManager: Special case: Waiting for SWF to load with window focus...", waitForever: "soundManager: Waiting indefinitely for Flash (will recover if unblocked)...", waitSWF: "soundManager: Waiting for 100% SWF load...", needFunction: "soundManager: Function object expected for %s", badID: 'Sound ID "%s" should be a string, starting with a non-numeric character', currentObj: "soundManager: _debug(): Current sound objects", waitOnload: "soundManager: Waiting for window.onload()", docLoaded: "soundManager: Document already loaded",
14757      onload: "soundManager: initComplete(): calling soundManager.onload()", onloadOK: "soundManager.onload() complete", didInit: "soundManager: init(): Already called?", secNote: "Flash security note: Network/internet URLs will not load due to security restrictions. Access can be configured via Flash Player Global Security Settings Page: http://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager04.html", badRemove: "soundManager: Failed to remove Flash node.", shutdown: "soundManager.disable(): Shutting down",
14758      queue: "soundManager: Queueing %s handler", smError: "SMSound.load(): Exception: JS-Flash communication failed, or JS error.", fbTimeout: "No flash response, applying .swf_timedout CSS...", fbLoaded: "Flash loaded", fbHandler: "soundManager: flashBlockHandler()", manURL: "SMSound.load(): Using manually-assigned URL", onURL: "soundManager.load(): current URL already assigned.", badFV: 'soundManager.flashVersion must be 8 or 9. "%s" is invalid. Reverting to %s.', as2loop: "Note: Setting stream:false so looping can work (flash 8 limitation)",
14759      noNSLoop: "Note: Looping not implemented for MovieStar formats", needfl9: "Note: Switching to flash 9, required for MP4 formats.", mfTimeout: "Setting flashLoadTimeout = 0 (infinite) for off-screen, mobile flash case", needFlash: "soundManager: Fatal error: Flash is needed to play some required formats, but is not available.", gotFocus: "soundManager: Got window focus.", policy: "Enabling usePolicyFile for data access", setup: "soundManager.setup(): allowed parameters: %s", setupError: 'soundManager.setup(): "%s" cannot be assigned with this method.',
14760      setupUndef: 'soundManager.setup(): Could not find option "%s"', setupLate: "soundManager.setup(): url, flashVersion and html5Test property changes will not take effect until reboot().", noURL: "soundManager: Flash URL required. Call soundManager.setup({url:...}) to get started.", sm2Loaded: "SoundManager 2: Ready. " + String.fromCharCode(10003), reset: "soundManager.reset(): Removing event callbacks", mobileUA: "Mobile UA detected, preferring HTML5 by default.", globalHTML5: "Using singleton HTML5 Audio() pattern for this device.",
14761      ignoreMobile: "Ignoring mobile restrictions for this device." };t = function t() {
14762      var b, c, e, a;b = kb.call(arguments);c = b.shift();if ((a = z && z[c] ? z[c] : "") && b && b.length) for (c = 0, e = b.length; c < e; c++) {
14763        a = a.replace("%s", b[c]);
14764      }return a;
14765    };oa = function oa(b) {
14766      8 === n && 1 < b.loops && b.stream && (p("as2loop"), b.stream = !1);return b;
14767    };pa = function pa(b, d) {
14768      b && !b.usePolicyFile && (b.onid3 || b.usePeakData || b.useWaveformData || b.useEQData) && (c._wD((d || "") + t("policy")), b.usePolicyFile = !0);return b;
14769    };K = function K(b) {
14770      Ua && console.warn !== g ? console.warn(b) : c._wD(b);
14771    };xa = function xa() {
14772      return !1;
14773    };Ga = function Ga(b) {
14774      for (var c in b) {
14775        b.hasOwnProperty(c) && "function" === typeof b[c] && (b[c] = xa);
14776      }
14777    };Ha = function Ha(b) {
14778      b === g && (b = !1);(y || b) && c.disable(b);
14779    };cb = function cb(b) {
14780      var d = null;if (b) if (b.match(/\.swf(\?.*)?$/i)) {
14781        if (d = b.substr(b.toLowerCase().lastIndexOf(".swf?") + 4)) return b;
14782      } else b.lastIndexOf("/") !== b.length - 1 && (b += "/");b = (b && -1 !== b.lastIndexOf("/") ? b.substr(0, b.lastIndexOf("/") + 1) : "./") + c.movieURL;c.noSWFCache && (b += "?ts=" + new Date().getTime());return b;
14783    };Da = function Da() {
14784      n = parseInt(c.flashVersion, 10);8 !== n && 9 !== n && (c._wD(t("badFV", n, 8)), c.flashVersion = n = 8);var b = c.debugMode || c.debugFlash ? "_debug.swf" : ".swf";c.useHTML5Audio && !c.html5Only && c.audioFormats.mp4.required && 9 > n && (c._wD(t("needfl9")), c.flashVersion = n = 9);c.version = c.versionNumber + (c.html5Only ? " (HTML5-only mode)" : 9 === n ? " (AS3/Flash 9)" : " (AS2/Flash 8)");8 < n ? (c.defaultOptions = _A(c.defaultOptions, c.flash9Options), c.features.buffering = !0, c.defaultOptions = _A(c.defaultOptions, c.movieStarOptions), c.filePatterns.flash9 = new RegExp("\\.(mp3|" + rb.join("|") + ")(\\?.*)?$", "i"), c.features.movieStar = !0) : c.features.movieStar = !1;c.filePattern = c.filePatterns[8 !== n ? "flash9" : "flash8"];c.movieURL = (8 === n ? "soundmanager2.swf" : "soundmanager2_flash9.swf").replace(".swf", b);c.features.peakData = c.features.waveformData = c.features.eqData = 8 < n;
14785    };ab = function ab(b, c) {
14786      l && l._setPolling(b, c);
14787    };Fa = function Fa() {
14788      c.debugURLParam.test(ia) && (c.setupOptions.debugMode = c.debugMode = !0);if (!E(c.debugID)) {
14789        var b, d, e, a;if (!(!c.debugMode || E(c.debugID) || Ua && c.useConsole && c.consoleOnly)) {
14790          b = m.createElement("div");b.id = c.debugID + "-toggle";d = { position: "fixed", bottom: "0px", right: "0px", width: "1.2em", height: "1.2em", lineHeight: "1.2em", margin: "2px", textAlign: "center", border: "1px solid #999", cursor: "pointer", background: "#fff", color: "#333", zIndex: 10001 };b.appendChild(m.createTextNode("-"));
14790b.onclick = db;b.title = "Toggle SM2 debug console";v.match(/msie 6/i) && (b.style.position = "absolute", b.style.cursor = "hand");for (a in d) {
14791            d.hasOwnProperty(a) && (b.style[a] = d[a]);
14792          }d = m.createElement("div");d.id = c.debugID;
14793          d.style.display = c.debugMode ? "block" : "none";if (c.debugMode && !E(b.id)) {
14794            try {
14795              e = ma(), e.appendChild(b);
14796            } catch (f) {
14797              throw Error(t("domError") + " \n" + f.toString());
14798            }e.appendChild(d);
14799          }
14800        }
14801      }
14802    };w = this.getSoundById;p = function p(b, d) {
14803      return b ? c._wD(t(b), d) : "";
14804    };db = function db() {
14805      var b = E(c.debugID),
14806          d = E(c.debugID + "-toggle");b && (za ? (d.innerHTML = "+", b.style.display = "none") : (d.innerHTML = "-", b.style.display = "block"), za = !za);
14807    };C = function C(b, c, e) {
14808      if (h.sm2Debugger !== g) try {
14809        sm2Debugger.handleEvent(b, c, e);
14810      } catch (a) {
14811        return !1;
14812      }return !0;
14813    };U = function U() {
14814      var b = [];c.debugMode && b.push("sm2_debug");c.debugFlash && b.push("flash_debug");c.useHighPerformance && b.push("high_performance");return b.join(" ");
14815    };Ja = function Ja() {
14816      var b = t("fbHandler"),
14817          d = c.getMoviePercent(),
14818          e = { type: "FLASHBLOCK" };c.html5Only || (c.ok() ? (c.didFlashBlock && c._wD(b + ": Unblocked"), c.oMC && (c.oMC.className = [U(), "movieContainer", "swf_loaded" + (c.didFlashBlock ? " swf_unblocked" : "")].join(" "))) : (u && (c.oMC.className = U() + " movieContainer " + (null === d ? "swf_timedout" : "swf_error"), c._wD(b + ": " + t("fbTimeout") + (d ? " (" + t("fbLoaded") + ")" : ""))), c.didFlashBlock = !0, O({ type: "ontimeout", ignoreInit: !0, error: e }), T(e)));
14819    };Ba = function Ba(b, c, e) {
14820      H[b] === g && (H[b] = []);H[b].push({ method: c, scope: e || null, fired: !1 });
14821    };O = function O(b) {
14822      b || (b = { type: c.ok() ? "onready" : "ontimeout" });if (!q && b && !b.ignoreInit || "ontimeout" === b.type && (c.ok() || y && !b.ignoreInit)) return !1;var d = { success: b && b.ignoreInit ? c.ok() : !y },
14823          e = b && b.type ? H[b.type] || [] : [],
14824          a = [],
14825          f,
14826          d = [d],
14827          g = u && !c.ok();b.error && (d[0].error = b.error);b = 0;for (f = e.length; b < f; b++) {
14828        !0 !== e[b].fired && a.push(e[b]);
14829      }if (a.length) for (b = 0, f = a.length; b < f; b++) {
14830        a[b].scope ? a[b].method.apply(a[b].scope, d) : a[b].method.apply(this, d), g || (a[b].fired = !0);
14831      }return !0;
14832    };_R = function R() {
14833      h.setTimeout(function () {
14834        c.useFlashBlock && Ja();O();"function" === typeof c.onload && (p("onload", 1), c.onload.apply(h), p("onloadOK", 1));c.waitForWindowLoad && x.add(h, "load", _R);
14835      }, 1);
14836    };Na = function Na() {
14837      if (G !== g) return G;var b = !1,
14838          c = navigator,
14839          e,
14840          a = h.ActiveXObject,
14841          f;try {
14842        f = c.plugins;
14843      } catch (m) {
14844        f = void 0;
14845      }if (f && f.length) (c = c.mimeTypes) && c["application/x-shockwave-flash"] && c["application/x-shockwave-flash"].enabledPlugin && c["application/x-shockwave-flash"].enabledPlugin.description && (b = !0);else if (a !== g && !v.match(/MSAppHost/i)) {
14846        try {
14847          e = new a("ShockwaveFlash.ShockwaveFlash");
14848        } catch (k) {
14849          e = null;
14850        }b = !!e;
14851      }return G = b;
14852    };hb = function hb() {
14853      var b,
14854          d,
14855          e = c.audioFormats;Qa && v.match(/os (1|2|3_0|3_1)\s/i) ? (c.hasHTML5 = !1, c.html5Only = !0, c.oMC && (c.oMC.style.display = "none")) : c.useHTML5Audio && (c.html5 && c.html5.canPlayType || (c._wD("SoundManager: No HTML5 Audio() support detected."), c.hasHTML5 = !1), Ta && c._wD("soundManager: Note: Buggy HTML5 Audio in Safari on this OS X release, see https://bugs.webkit.org/show_bug.cgi?id=32159 - " + (G ? "will use flash fallback for MP3/MP4, if available" : " would use flash fallback for MP3/MP4, but none detected."), 1));if (c.useHTML5Audio && c.hasHTML5) for (d in da = !0, e) {
14856        e.hasOwnProperty(d) && e[d].required && (c.html5.canPlayType(e[d].type) ? c.preferFlash && (c.flash[d] || c.flash[e[d].type]) && (b = !0) : (da = !1, b = !0));
14857      }c.ignoreFlash && (b = !1, da = !0);c.html5Only = c.hasHTML5 && c.useHTML5Audio && !b;return !c.html5Only;
14858    };ra = function ra(b) {
14859      var d,
14860          e,
14861          a = 0;if (b instanceof Array) {
14862        d = 0;for (e = b.length; d < e; d++) {
14863          if (b[d] instanceof Object) {
14864            if (c.canPlayMIME(b[d].type)) {
14865              a = d;break;
14866            }
14867          } else if (c.canPlayURL(b[d])) {
14868            a = d;break;
14869          }
14870        }b[a].url && (b[a] = b[a].url);b = b[a];
14871      }return b;
14872    };eb = function eb(b) {
14873      b._hasTimer || (b._hasTimer = !0, !va && c.html5PollingInterval && (null === ca && 0 === qa && (ca = setInterval(gb, c.html5PollingInterval)), qa++));
14874    };fb = function fb(b) {
14875      b._hasTimer && (b._hasTimer = !1, !va && c.html5PollingInterval && qa--);
14876    };gb = function gb() {
14877      var b;if (null === ca || qa) for (b = c.soundIDs.length - 1; 0 <= b; b--) {
14878        c.sounds[c.soundIDs[b]].isHTML5 && c.sounds[c.soundIDs[b]]._hasTimer && c.sounds[c.soundIDs[b]]._onTimer();
14879      } else clearInterval(ca), ca = null;
14880    };T = function T(b) {
14881      b = b !== g ? b : {};"function" === typeof c.onerror && c.onerror.apply(h, [{ type: b.type !== g ? b.type : null }]);b.fatal !== g && b.fatal && c.disable();
14882    };lb = function lb() {
14883      if (Ta && Na()) {
14884        var b = c.audioFormats,
14885            d,
14886            e;for (e in b) {
14887          if (b.hasOwnProperty(e) && ("mp3" === e || "mp4" === e) && (c._wD("soundManager: Using flash fallback for " + e + " format"), c.html5[e] = !1, b[e] && b[e].related)) for (d = b[e].related.length - 1; 0 <= d; d--) {
14888            c.html5[b[e].related[d]] = !1;
14889          }
14890        }
14891      }
14892    };this._setSandboxType = function (b) {
14893      var d = c.sandbox;d.type = b;d.description = d.types[d.types[b] !== g ? b : "unknown"];
14893"localWithFile" === d.type ? (d.noRemote = !0, d.noLocal = !1, p("secNote", 2)) : "localWithNetwork" === d.type ? (d.noRemote = !1, d.noLocal = !0) : "localTrusted" === d.type && (d.noRemote = !1, d.noLocal = !1);
14894    };this._externalInterfaceOK = function (b) {
14895      if (!c.swfLoaded) {
14896        var d;C("swf", !0);C("flashtojs", !0);c.swfLoaded = !0;wa = !1;Ta && lb();b && b.replace(/\+dev/i, "") === c.versionNumber.replace(/\+dev/i, "") ? setTimeout(ya, N ? 100 : 1) : (d = 'soundManager: Fatal: JavaScript file build "' + c.versionNumber + '" does not match Flash SWF build "' + b + '" at ' + c.url + ". Ensure both are up-to-date.", setTimeout(function () {
14897          throw Error(d);
14898        }, 0));
14899      }
14900    };na = function na(b, d) {
14901      function e() {
14902        var a = [],
14903            b,
14904            d = [];b = "SoundManager " + c.version + (!c.html5Only && c.useHTML5Audio ? c.hasHTML5 ? " + HTML5 audio" : ", no HTML5 audio support" : "");c.html5Only ? c.html5PollingInterval && a.push("html5PollingInterval (" + c.html5PollingInterval + "ms)") : (c.preferFlash && a.push("preferFlash"), c.useHighPerformance && a.push("useHighPerformance"), c.flashPollingInterval && a.push("flashPollingInterval (" + c.flashPollingInterval + "ms)"), c.html5PollingInterval && a.push("html5PollingInterval (" + c.html5PollingInterval + "ms)"), c.wmode && a.push("wmode (" + c.wmode + ")"), c.debugFlash && a.push("debugFlash"), c.useFlashBlock && a.push("flashBlock"));a.length && (d = d.concat([a.join(" + ")]));c._wD(b + (d.length ? " + " + d.join(", ") : ""), 1);mb();
14905      }function a(a, b) {
14906        return '<param name="' + a + '" value="' + b + '" />';
14907      }if (W && X) return !1;if (c.html5Only) return Da(), e(), c.oMC = E(c.movieID), ya(), X = W = !0, !1;var f = d || c.url,
14908          h = c.altURL || f,
14909          k = ma(),
14910          l = U(),
14911          n = null,
14912          n = m.getElementsByTagName("html")[0],
14913          p,
14914          r,
14915          q,
14916          n = n && n.dir && n.dir.match(/rtl/i);b = b === g ? c.id : b;Da();c.url = cb(ga ? f : h);d = c.url;c.wmode = !c.wmode && c.useHighPerformance ? "transparent" : c.wmode;null !== c.wmode && (v.match(/msie 8/i) || !N && !c.useHighPerformance) && navigator.platform.match(/win32|win64/i) && (L.push(z.spcWmode), c.wmode = null);k = { name: b, id: b, src: d, quality: "high", allowScriptAccess: c.allowScriptAccess, bgcolor: c.bgColor, pluginspage: vb + "www.macromedia.com/go/getflashplayer", title: "JS/Flash audio component (SoundManager 2)", type: "application/x-shockwave-flash", wmode: c.wmode, hasPriority: "true" };c.debugFlash && (k.FlashVars = "debug=1");c.wmode || delete k.wmode;if (N) f = m.createElement("div"), r = ['<object id="' + b + '" data="' + d + '" type="' + k.type + '" title="' + k.title + '" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0">', a("movie", d), a("AllowScriptAccess", c.allowScriptAccess), a("quality", k.quality), c.wmode ? a("wmode", c.wmode) : "", a("bgcolor", c.bgColor), a("hasPriority", "true"), c.debugFlash ? a("FlashVars", k.FlashVars) : "", "</object>"].join("");else for (p in f = m.createElement("embed"), k) {
14917        k.hasOwnProperty(p) && f.setAttribute(p, k[p]);
14918      }Fa();l = U();if (k = ma()) if (c.oMC = E(c.movieID) || m.createElement("div"), c.oMC.id) q = c.oMC.className, c.oMC.className = (q ? q + " " : "movieContainer") + (l ? " " + l : ""), c.oMC.appendChild(f), N && (p = c.oMC.appendChild(m.createElement("div")), p.className = "sm2-object-box", p.innerHTML = r), X = !0;else {
14919        c.oMC.id = c.movieID;c.oMC.className = "movieContainer " + l;p = l = null;c.useFlashBlock || (c.useHighPerformance ? l = { position: "fixed", width: "8px", height: "8px", bottom: "0px", left: "0px", overflow: "hidden" } : (l = { position: "absolute", width: "6px", height: "6px", top: "-9999px", left: "-9999px" }, n && (l.left = Math.abs(parseInt(l.left, 10)) + "px")));ub && (c.oMC.style.zIndex = 1E4);if (!c.debugFlash) for (q in l) {
14920          l.hasOwnProperty(q) && (c.oMC.style[q] = l[q]);
14921        }try {
14922          N || c.oMC.appendChild(f), k.appendChild(c.oMC), N && (p = c.oMC.appendChild(m.createElement("div")), p.className = "sm2-object-box", p.innerHTML = r), X = !0;
14923        } catch (u) {
14924          throw Error(t("domError") + " \n" + u.toString());
14925        }
14926      }W = !0;e();return !0;
14927    };la = function la() {
14928      if (c.html5Only) return na(), !1;if (l) return !1;if (!c.url) return p("noURL"), !1;l = c.getMovie(c.id);l || (aa ? (N ? c.oMC.innerHTML = Ia : c.oMC.appendChild(aa), aa = null, W = !0) : na(c.id, c.url), l = c.getMovie(c.id));"function" === typeof c.oninitmovie && setTimeout(c.oninitmovie, 1);Oa();return !0;
14929    };S = function S() {
14930      setTimeout($a, 1E3);
14931    };Ca = function Ca() {
14932      h.setTimeout(function () {
14933        K("soundManager: useFlashBlock is false, 100% HTML5 mode is possible. Rebooting with preferFlash: false...");c.setup({ preferFlash: !1 }).reboot();c.didFlashBlock = !0;c.beginDelayedInit();
14934      }, 1);
14935    };$a = function $a() {
14936      var b,
14937          d = !1;c.url && !ba && (ba = !0, x.remove(h, "load", S), G && wa && !Va ? p("waitFocus") : (q || (b = c.getMoviePercent(), 0 < b && 100 > b && (d = !0)), setTimeout(function () {
14938        b = c.getMoviePercent();d ? (ba = !1, c._wD(t("waitSWF")), h.setTimeout(S, 1)) : (q || (c._wD("soundManager: No Flash response within expected time. Likely causes: " + (0 === b ? "SWF load failed, " : "") + "Flash blocked or JS-Flash security error." + (c.debugFlash ? " " + t("checkSWF") : ""), 2), !ga && b && (p("localFail", 2), c.debugFlash || p("tryDebug", 2)), 0 === b && c._wD(t("swf404", c.url), 1), C("flashtojs", !1, ": Timed out" + (ga ? " (Check flash security or flash blockers)" : " (No plugin/missing SWF?)"))), !q && ob && (null === b ? c.useFlashBlock || 0 === c.flashLoadTimeout ? (c.useFlashBlock && Ja(), p("waitForever")) : !c.useFlashBlock && da ? Ca() : (p("waitForever"), O({ type: "ontimeout", ignoreInit: !0, error: { type: "INIT_FLASHBLOCK" } })) : 0 === c.flashLoadTimeout ? p("waitForever") : !c.useFlashBlock && da ? Ca() : Ha(!0)));
14939      }, c.flashLoadTimeout)));
14940    };_ka = function ka() {
14941      if (Va || !wa) return x.remove(h, "focus", _ka), !0;Va = ob = !0;p("gotFocus");ba = !1;S();x.remove(h, "focus", _ka);return !0;
14942    };Oa = function Oa() {
14943      L.length && (c._wD("SoundManager 2: " + L.join(" "), 1), L = []);
14944    };mb = function mb() {
14945      Oa();var b,
14946          d = [];if (c.useHTML5Audio && c.hasHTML5) {
14947        for (b in c.audioFormats) {
14948          c.audioFormats.hasOwnProperty(b) && d.push(b + " = " + c.html5[b] + (!c.html5[b] && u && c.flash[b] ? " (using flash)" : c.preferFlash && c.flash[b] && u ? " (preferring flash)" : c.html5[b] ? "" : " (" + (c.audioFormats[b].required ? "required, " : "") + "and no flash support)"));
14949        }c._wD("SoundManager 2 HTML5 support: " + d.join(", "), 1);
14950      }
14951    };Y = function Y(b) {
14952      if (q) return !1;
14952if (c.html5Only) return p("sm2Loaded", 1), q = !0, _R(), C("onload", !0), !0;var d = !0,
14953          e;c.useFlashBlock && c.flashLoadTimeout && !c.getMoviePercent() || (q = !0);e = { type: !G && u ? "NO_FLASH" : "INIT_TIMEOUT" };c._wD("SoundManager 2 " + (y ? "failed to load" : "loaded") + " (" + (y ? "Flash security/load error" : "OK") + ") " + String.fromCharCode(y ? 10006 : 10003), y ? 2 : 1);y || b ? (c.useFlashBlock && c.oMC && (c.oMC.className = U() + " " + (null === c.getMoviePercent() ? "swf_timedout" : "swf_error")), O({ type: "ontimeout", error: e, ignoreInit: !0 }), C("onload", !1), T(e), d = !1) : C("onload", !0);y || (c.waitForWindowLoad && !ja ? (p("waitOnload"), x.add(h, "load", _R)) : (c.waitForWindowLoad && ja && p("docLoaded"), _R()));return d;
14954    };Za = function Za() {
14955      var b,
14956          d = c.setupOptions;for (b in d) {
14957        d.hasOwnProperty(b) && (c[b] === g ? c[b] = d[b] : c[b] !== d[b] && (c.setupOptions[b] = c[b]));
14958      }
14959    };ya = function ya() {
14960      if (q) return p("didInit"), !1;if (c.html5Only) return q || (x.remove(h, "load", c.beginDelayedInit), c.enabled = !0, Y()), !0;la();try {
14961        l._externalInterfaceTest(!1), ab(!0, c.flashPollingInterval || (c.useHighPerformance ? 10 : 50)), c.debugMode || l._disableDebug(), c.enabled = !0, C("jstoflash", !0), c.html5Only || x.add(h, "unload", xa);
14962      } catch (b) {
14963        return c._wD("js/flash exception: " + b.toString()), C("jstoflash", !1), T({ type: "JS_TO_FLASH_EXCEPTION", fatal: !0 }), Ha(!0), Y(), !1;
14964      }Y();x.remove(h, "load", c.beginDelayedInit);return !0;
14965    };_P = function P() {
14966      if (Z) return !1;Z = !0;Za();
14967      Fa();!G && c.hasHTML5 && (c._wD("SoundManager 2: No Flash detected" + (c.useHTML5Audio ? ". Trying HTML5-only mode." : ", enabling HTML5."), 1), c.setup({ useHTML5Audio: !0, preferFlash: !1 }));jb();!G && u && (L.push(z.needFlash), c.setup({ flashLoadTimeout: 1 }));m.removeEventListener && m.removeEventListener("DOMContentLoaded", _P, !1);la();return !0;
14968    };_La = function La() {
14969      "complete" === m.readyState && (_P(), m.detachEvent("onreadystatechange", _La));return !0;
14970    };_Ea = function Ea() {
14971      ja = !0;_P();x.remove(h, "load", _Ea);
14972    };Na();x.add(h, "focus", _ka);x.add(h, "load", S);x.add(h, "load", _Ea);m.addEventListener ? m.addEventListener("DOMContentLoaded", _P, !1) : m.attachEvent ? m.attachEvent("onreadystatechange", _La) : (C("onload", !1), T({ type: "NO_DOM2_EVENTS", fatal: !0 }));
14973  }if (!h || !h.document) throw Error("SoundManager requires a browser with window and document objects.");var V = null;h.SM2_DEFER !== g && SM2_DEFER || (V = new J());"object" === (typeof module === "undefined" ? "undefined" : _typeof(module)) && module && "object" === _typeof(module.exports) ? (module.exports.SoundManager = J, module.exports.soundManager = V) : "function" === typeof define && define.amd && define(function () {
14974    return { constructor: J, getInstance: function getInstance(g) {
14975        !h.soundManager && g instanceof Function && (g = g(J), g instanceof J && (h.soundManager = g));return h.soundManager;
14976      } };
14977  });h.SoundManager = J;h.soundManager = V;
14978})(window);
14979
14980},{}],22:[function(require,module,exports){
14981(function (global){
14982"use strict";
14983
14984global.jQuery = require("jquery");
14985var $ = global.jQuery,
14986    Cookies = require("js-cookie"),
14987    Slideout = require("slideout"),
14988    matchHeight = require('jquery-match-height'),
14989    soundManager = require('./libs/soundmanager2-jsmin'),
14990    soundManagerBar = require('./libs/bar-ui'),
14991    LazyLoad = require('vanilla-lazyload'),
14992    InfiniteScroll = require('infinite-scroll'),
14993    slick = require('slick-carousel/slick/slick.min'),
14994    tooltipster = require('tooltipster');
14995
14996(function ($) {
14997    $.fn.outside = function (ename, cb) {
14998        return this.each(function () {
14999            var $this = $(this),
15000                self = this;
15001
15002            $(document).bind(ename, function tempo(e) {
15003                if (e.target !== self && !$.contains(self, e.target)) {
15004                    cb.apply(self, [e]);
15005                    if (!self.parentNode) $(document.body).unbind(ename, tempo);
15006                }
15007            });
15008        });
15009    };
15010})(jQuery);
15011
15012$(function () {
15013
15014    var slideout = '',
15015        myLazyLoad = null,
15016        slideshow = null;
15017
15018    function cookieLaw() {
15019        var cookieMessage = $('#cookie-message'),
15020            seenCookie = Cookies.get('seenCookie');
15021        if (seenCookie !== 'yes') {
15022            cookieMessage.show();
15023            Cookies.set('seenCookie', 'yes', { expires: 365 });
15024        }
15025    }
15026
15027    $('.tooltip').tooltipster({
15028        side: 'top',
15029        theme: 'tooltipster-borderless'
15030    });
15031
15032    function responsiveMenu() {
15033        var toggle = $('.toggle-button');
15034
15035        slideout = new Slideout({
15036            'panel': document.getElementById('site'),
15037            'menu': document.getElementById('menu'),
15038            'side': 'left',
15039            'padding': 256,
15040            'tolerance': 70
15041        });
15042
15043        toggle.on('click', function (e) {
15044            slideout.toggle();
15045            return false;
15046        });
15047    }
15048
15049    function cookiePopup() {
15050
15051        var cookiePopup = $('#cookie-popup'),
15052            seenCookiePopup = Cookies.get('seenCookiePopup'),
15053            pageCount = Cookies.get('pageCount');
15054
15055        if (pageCount == null) {
15056            Cookies.set('pageCount', 1, { expires: 1 });
15057        } else {
15058            Cookies.set('pageCount', parseInt(pageCount) + 1, { expires: 1 });
15059        }
15060
15061        if (pageCount > 4) {
15062            Cookies.set('pageCount', 0, { expires: 1 });
15063            if (seenCookiePopup !== 'yes') {
15064                cookiePopup.fadeIn();
15065                Cookies.set('seenCookiePopup', 'yes', { expires: 365 });
15066            }
15067        }
15068
15069        cookiePopup.find('.close').on('click', function (e) {
15070            e.preventDefault();
15071            cookiePopup.fadeOut();
15072        });
15073    }
15074
15075    function resize() {
15076        $(window).resize(function () {
15077            if ($(window).width() < 1024) {
15078                slideout.close();
15079            }
15080        });
15081    }
15082
15083    function navClick() {
15084        var toggle = $('#tog-menu');
15085        toggle.on('click', function (e) {
15086            slideout.toggle();
15087            return false;
15088        });
15089    }
15090
15091    function typeSize() {
15092        var mySize = Cookies.get('typeSize'),
15093            resizer = $('#resizer').find('a');
15094
15095        if (mySize) {
15096            body.addClass(mySize);
15097        }
15098        resizer.on('click', function (e) {
15099            e.preventDefault();
15100            var size = $(this).data('size');
15101            body.removeClass('t-small t-medium t-large').addClass(size);
15102            Cookies.set('typeSize', size, { expires: 365 });
15103        });
15104    }
15105
15106    function setupMatchHeight() {
15107
15108        var equal = $('.equal');
15109        if (equal.length > 0) {
15110            var items = equal.find('.item');
15111            items.matchHeight();
15112        }
15113    }
15114
15115    function subNav() {
15116
15117        jQuery.fn.rotate = function (degrees) {
15118            $(this).css({
15119                '-webkit-transform': 'rotate(' + degrees + 'deg)',
15120                '-moz-transform': 'rotate(' + degrees + 'deg)',
15121                '-ms-transform': 'rotate(' + degrees + 'deg)',
15122                'transform': 'rotate(' + degrees + 'deg)'
15123            });
15124            return $(this);
15125        };
15126
15127        $('.section-link').click(function (e) {
15128            if (!$(this).hasClass('nav-displayed')) {
15129                $(this).addClass('nav-displayed');
15130                $('.sub-nav-menu').slideDown();
15131                $(this).find('i').rotate(180);
15132            } else {
15133                $('.sub-nav-menu').slideUp();
15134                $(this).removeClass('nav-displayed');
15135                $(this).find('i').rotate(0);
15136            }
15137        });
15138
15139        $('.toggle').click(function (e) {
15140            e.preventDefault();
15141            if (!$(this).hasClass('nav-displayed')) {
15142                if ($(this).parent().hasClass('sub-nav')) {
15143                    $('.sub-nav-menu').slideDown();
15144                } else {
15145                    $('.nav-menu').hide();
15146                    $(this).parent().find('.nav-menu').show();
15147                }
15148                $(this).addClass('nav-displayed');
15149                $(this).find('i').rotate(180);
15150            } else {
15151                if ($(this).parent().hasClass('sub-nav')) {
15152                    $('.sub-nav-menu').slideUp();
15153                } else {
15154                    $('.nav-menu').hide();
15155                }
15156                $(this).removeClass('nav-displayed');
15157                $(this).find('i').rotate(0);
15158            }
15159        });
15160
15161        var toggleSub = $('.toggle-sub');
15162        toggleSub.click(function (e) {
15163            e.preventDefault();
15164            var list = $(this).parent().find('ul:first');
15165            if (list.hasClass('open')) {
15166                list.removeClass('open');
15167                $(this).find('i:first').removeClass();
15168                $(this).find('i:first').addClass('fa');
15169                $(this).find('i:first').addClass('fa-chevron-down');
15170                list.slideUp();
15171            } else {
15172                list.addClass('open');
15173                $(this).find('i:first').removeClass();
15174                $(this).find('i:first').addClass('fa');
15175                $(this).find('i:first').addClass('fa-chevron-up');
15176                list.slideDown();
15177            }
15178        });
15179    }
15180
15181    function quantity() {
15182        $('.qtyplus').click(function (e) {
15183            // Stop acting like a button
15184            e.preventDefault();
15185            // Get the field name
15186            var fieldName = $(this).data("field");
15187            // Get its current value
15188            var currentVal = parseInt($('input[name=' + fieldName + ']').val());
15189            // If is not undefined
15190            if (!isNaN(currentVal)) {
15191                // Increment
15192                $('input[name=' + fieldName + ']').val(currentVal + 1);
15193            } else {
15194                // Otherwise put a 0 there
15195                $('input[name=' + fieldName + ']').val(0);
15196            }
15197        });
15198        // This button will decrement the value till 0
15199        $(".qtyminus").click(function (e) {
15200            // Stop acting like a button
15201            e.preventDefault();
15202            // Get the field name
15203            var fieldName = $(this).data("field");
15204            // Get its current value
15205            var currentVal = parseInt($('input[name=' + fieldName + ']').val());
15206            // If it isn't undefined or its greater than 0
15207            if (!isNaN(currentVal) && currentVal > 0) {
15208                // Decrement one
15209                $('input[name=' + fieldName + ']').val(currentVal - 1);
15210            } else {
15211                // Otherwise put a 0 there
15212                $('input[name=' + fieldName + ']').val(0);
15213            }
15214        });
15215    }
15216
15217    function catFilter() {
15218
15219        $('.trigger').on('click', function (e) {
15220            e.preventDefault();
15221
15222            var that = $(this),
15223                target = that.attr('href');
15224            that.toggleClass('open');
15225            $(target).toggleClass('open');
15226        });
15227
15228        $('.filter-bar').outside('click', function (e) {
15229            $('#cat-menu').removeClass('open');
15230            $('#cat-menu-trigger').removeClass('open');
15231        });
15232    }
15233
15234    function triggerMore() {
15235        $('#trigger-more').on('click', function (e) {
15236            e.preventDefault();
15237            $('#more').toggleClass('open');
15238        });
15239    }
15240
15241    function makeSlick() {
15242        slideshow = $('.slideshow');
15243        if (slideshow.length > 0) {
15244            slideshow.slick({
15245                arrows: false,
15246                dots: false,
15247                infinite: true,
15248                slidesToScroll: 1,
15249                slidesToShow: 1,
15250                speed: 900,
15251                autoplay: true,
15252                autoplaySpeed: 3000,
15253                cssEase: "linear",
15254                adaptiveHeight: true,
15255                mobileFirst: true,
15256                responsive: [{
15257                    breakpoint: 768,
15258                    settings: {
15259                        adaptiveHeight: false
15260                    }
15261                }]
15262            });
15263        }
15264    }
15265
15266    try {
15267        soundManager.setup();
15268    } catch (err) {}
15269
15270    function autocompletMe() {
15271        $('#nav-search').keypress(function () {
15272            var that = $(this),
15273                term = that.val();
15274
15275            $.ajax({
15276                url: "/predictivesearch",
15277                method: "GET",
15278                data: {
15279                    searchTerm: term
15280                },
15281                dataType: 'json',
15282                success: function success(data) {
15283                    $('#autocomplete').fadeIn();
15284                    $('#autocomplete ul').empty();
15285                    $.each(data, function (index, element) {
15286
15287                        if (!element.url_slug) {
15288
15289                            $('#autocomplete ul').append('<li><a href="/shop/products/' + element.tag + '" >' + element.title + ' ' + element.sub_title + '</a>');
15290                        } else {
15291                            if (element.tag !== 'terms-conditions' && element.tag !== 'returns' && element.tag !== 'privacy-policy' && element.tag !== 'home' && element.tag !== 'about' && element.tag !== 'brumpic' && element.area_fk !== 2) {
15292                                $('#autocomplete ul').append('<li><a href="' + element.url_slug + '" >' + element.title + '</a>');
15293                            }
15294                        }
15295                    });
15296                },
15297                error: function error() {
15298                    // alert("error");
15299                }
15300            });
15301        });
15302
15303        $(document).mouseup(function (e) {
15304            var container = $('#autocomplete');
15305            // if the target of the click isn't the container nor a descendant of the container
15306            if (!container.is(e.target) && container.has(e.target).length === 0) {
15307                container.fadeOut("fast", function () {
15308                    container.find('ul').empty();
15309                });
15310            }
15311        });
15312    }
15313
15314    function brumpicForm() {
15315        $('#addAnotherPerson').click(function (e) {
15316            e.preventDefault();
15317            var currentPerson = parseInt($('#currentPerson').val()) + 1;
15318            $('#currentPerson').val(currentPerson);
15319            var formGroupHtml = '<div class="recommend-group" id="person-' + currentPerson + '">';
15320            var nameField = renderField(currentPerson, 'name', 'Name');
15321            var emailField = renderField(currentPerson, 'email', 'Email');
15322
15323            formGroupHtml = formGroupHtml + nameField;
15324            formGroupHtml = formGroupHtml + emailField;
15325            formGroupHtml = formGroupHtml + '<button class="btn" id="deletePerson' + currentPerson + '" data-person="' + currentPerson + '">Delete Person</button>';
15326            formGroupHtml = formGroupHtml + '</div>';
15327
15328            $('#brumpicfields').append(formGroupHtml);
15329
15330            $('#deletePerson' + currentPerson).click(function (e) {
15331                e.preventDefault();
15332                var person = $(this).data('person');
15333                console.log($('#person-' + person).html());
15334                $('#person-' + person).remove();
15335                return false;
15336            });
15337            return false;
15338        });
15339    }
15340
15341    function renderField(currentPerson, fieldName, fieldLabel) {
15342        var fieldHtml = '<div class="form-group has-feedback">\n' + '    <label class="col-m-3 control-label" for="' + fieldName + '-' + currentPerson + '">' + fieldLabel + '</label>\n' + '    <input type="text" class="col-m-9 field " id="{{ $fieldName }}-1" name="person[' + currentPerson + '][' + fieldName + ']" value="" aria-describedby="inputnameStatus" placeholder="' + fieldLabel + '">\n' + '    <span class="fa fa-asterisk required  form-control-feedback" aria-hidden="true"></span>\n' + '    <span id="inputnameStatus" class="sr-only">  (success) </span>\n' + '</div>';
15343        return fieldHtml;
15344    }
15345
15346    myLazyLoad = new LazyLoad({
15347        elements_selector: ".lazyBack",
15348        threshold: 0,
15349        callback_processed: function callback_processed(element) {
15350            console.log(element);
15351        }
15352    });
15353
15354    var scrollContainer = document.querySelector('.infiscroll');
15355
15356    if ($('.pagination__next').length > 0) {
15357        new InfiniteScroll(scrollContainer, {
15358            path: '.pagination__next',
15359            append: '.infitem',
15360            hideNav: '.pagination-holder',
15361            status: '.scroll-status',
15362            debug: false,
15363            history: false
15364        }).on('append', function (response, path, items) {
15365            myLazyLoad.update();
15366        });
15367    }
15368
15369    cookieLaw();
15370    brumpicForm();
15371    typeSize();
15372    responsiveMenu();
15373    resize();
15374    navClick();
15375    subNav();
15376    setupMatchHeight();
15377    quantity();
15378    catFilter();
15379    triggerMore();
15380    autocompletMe();
15381    cookiePopup();
15382    makeSlick();
15383});
15384
15385}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
15386},{"./libs/bar-ui":20,"./libs/soundmanager2-jsmin":21,"infinite-scroll":9,"jquery":14,"jquery-match-height":13,"js-cookie":15,"slick-carousel/slick/slick.min":16,"slideout":17,"tooltipster":18,"vanilla-lazyload":19}]},{},[22]);
15387
15388//# sourceMappingURL=script.js.map

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.