PageRenderTime 72ms CodeModel.GetById 22ms RepoModel.GetById 0ms app.codeStats 2ms

/js/app.min.js

https://bitbucket.org/vood/drink
JavaScript | 1440 lines | 985 code | 216 blank | 239 comment | 157 complexity | 3434bed06c8a850f147f04a9c786ab74 MD5 | raw file

Large files files are truncated, but you can click here to view the full file

  1. /**
  2. * @preserve FastClick: polyfill to remove click delays on browsers with touch UIs.
  3. *
  4. * @version 0.5.3
  5. * @codingstandard ftlabs-jsv2
  6. * @copyright The Financial Times Limited [All Rights Reserved]
  7. * @license MIT License (see LICENSE.txt)
  8. */
  9. /*jslint browser:true, node:true*/
  10. /*global define, Event, Node*/
  11. /**
  12. * Instantiate fast-clicking listeners on the specificed layer.
  13. *
  14. * @constructor
  15. * @param {Element} layer The layer to listen on
  16. */
  17. function FastClick(layer) {
  18. 'use strict';
  19. var oldOnClick, self = this;
  20. /**
  21. * Whether a click is currently being tracked.
  22. *
  23. * @type boolean
  24. */
  25. this.trackingClick = false;
  26. /**
  27. * Timestamp for when when click tracking started.
  28. *
  29. * @type number
  30. */
  31. this.trackingClickStart = 0;
  32. /**
  33. * The element being tracked for a click.
  34. *
  35. * @type EventTarget
  36. */
  37. this.targetElement = null;
  38. /**
  39. * X-coordinate of touch start event.
  40. *
  41. * @type number
  42. */
  43. this.touchStartX = 0;
  44. /**
  45. * Y-coordinate of touch start event.
  46. *
  47. * @type number
  48. */
  49. this.touchStartY = 0;
  50. /**
  51. * ID of the last touch, retrieved from Touch.identifier.
  52. *
  53. * @type number
  54. */
  55. this.lastTouchIdentifier = 0;
  56. /**
  57. * The FastClick layer.
  58. *
  59. * @type Element
  60. */
  61. this.layer = layer;
  62. if (!layer || !layer.nodeType) {
  63. throw new TypeError('Layer must be a document node');
  64. }
  65. /** @type function() */
  66. this.onClick = function() { FastClick.prototype.onClick.apply(self, arguments); };
  67. /** @type function() */
  68. this.onTouchStart = function() { FastClick.prototype.onTouchStart.apply(self, arguments); };
  69. /** @type function() */
  70. this.onTouchMove = function() { FastClick.prototype.onTouchMove.apply(self, arguments); };
  71. /** @type function() */
  72. this.onTouchEnd = function() { FastClick.prototype.onTouchEnd.apply(self, arguments); };
  73. /** @type function() */
  74. this.onTouchCancel = function() { FastClick.prototype.onTouchCancel.apply(self, arguments); };
  75. // Devices that don't support touch don't need FastClick
  76. if (typeof window.ontouchstart === 'undefined') {
  77. return;
  78. }
  79. // Set up event handlers as required
  80. layer.addEventListener('click', this.onClick, true);
  81. layer.addEventListener('touchstart', this.onTouchStart, false);
  82. layer.addEventListener('touchmove', this.onTouchMove, false);
  83. layer.addEventListener('touchend', this.onTouchEnd, false);
  84. layer.addEventListener('touchcancel', this.onTouchCancel, false);
  85. // Hack is required for browsers that don't support Event#stopImmediatePropagation (e.g. Android 2)
  86. // which is how FastClick normally stops click events bubbling to callbacks registered on the FastClick
  87. // layer when they are cancelled.
  88. if (!Event.prototype.stopImmediatePropagation) {
  89. layer.removeEventListener = function(type, callback, capture) {
  90. var rmv = Node.prototype.removeEventListener;
  91. if (type === 'click') {
  92. rmv.call(layer, type, callback.hijacked || callback, capture);
  93. } else {
  94. rmv.call(layer, type, callback, capture);
  95. }
  96. };
  97. layer.addEventListener = function(type, callback, capture) {
  98. var adv = Node.prototype.addEventListener;
  99. if (type === 'click') {
  100. adv.call(layer, type, callback.hijacked || (callback.hijacked = function(event) {
  101. if (!event.propagationStopped) {
  102. callback(event);
  103. }
  104. }), capture);
  105. } else {
  106. adv.call(layer, type, callback, capture);
  107. }
  108. };
  109. }
  110. // If a handler is already declared in the element's onclick attribute, it will be fired before
  111. // FastClick's onClick handler. Fix this by pulling out the user-defined handler function and
  112. // adding it as listener.
  113. if (typeof layer.onclick === 'function') {
  114. // Android browser on at least 3.2 requires a new reference to the function in layer.onclick
  115. // - the old one won't work if passed to addEventListener directly.
  116. oldOnClick = layer.onclick;
  117. layer.addEventListener('click', function(event) {
  118. oldOnClick(event);
  119. }, false);
  120. layer.onclick = null;
  121. }
  122. }
  123. /**
  124. * Android requires an exception for labels.
  125. *
  126. * @type boolean
  127. */
  128. FastClick.prototype.deviceIsAndroid = navigator.userAgent.indexOf('Android') > 0;
  129. /**
  130. * iOS requires an exception for alert confirm dialogs.
  131. *
  132. * @type boolean
  133. */
  134. FastClick.prototype.deviceIsIOS = /iP(ad|hone|od)/.test(navigator.userAgent);
  135. /**
  136. * iOS 4 requires an exception for select elements.
  137. *
  138. * @type boolean
  139. */
  140. FastClick.prototype.deviceIsIOS4 = FastClick.prototype.deviceIsIOS && (/OS 4_\d(_\d)?/).test(navigator.userAgent);
  141. /**
  142. * iOS 6.0(+?) requires the target element to be manually derived
  143. *
  144. * @type boolean
  145. */
  146. FastClick.prototype.deviceIsIOSWithBadTarget = FastClick.prototype.deviceIsIOS && (/OS ([6-9]|\d{2})_\d/).test(navigator.userAgent);
  147. /**
  148. * Determine whether a given element requires a native click.
  149. *
  150. * @param {EventTarget|Element} target Target DOM element
  151. * @returns {boolean} Returns true if the element needs a native click
  152. */
  153. FastClick.prototype.needsClick = function(target) {
  154. 'use strict';
  155. switch (target.nodeName.toLowerCase()) {
  156. case 'input':
  157. // Don't send a synthetic click to disabled inputs (issue #62)
  158. return target.disabled;
  159. case 'label':
  160. case 'video':
  161. return true;
  162. default:
  163. return (/\bneedsclick\b/).test(target.className);
  164. }
  165. };
  166. /**
  167. * Determine whether a given element requires a call to focus to simulate click into element.
  168. *
  169. * @param {EventTarget|Element} target Target DOM element
  170. * @returns {boolean} Returns true if the element requires a call to focus to simulate native click.
  171. */
  172. FastClick.prototype.needsFocus = function(target) {
  173. 'use strict';
  174. switch (target.nodeName.toLowerCase()) {
  175. case 'textarea':
  176. case 'select':
  177. return true;
  178. case 'input':
  179. switch (target.type) {
  180. case 'button':
  181. case 'checkbox':
  182. case 'file':
  183. case 'image':
  184. case 'radio':
  185. case 'submit':
  186. return false;
  187. }
  188. // No point in attempting to focus disabled inputs
  189. return target.disabled;
  190. default:
  191. return (/\bneedsfocus\b/).test(target.className);
  192. }
  193. };
  194. /**
  195. * Send a click event to the specified element.
  196. *
  197. * @param {EventTarget|Element} targetElement
  198. * @param {Event} event
  199. */
  200. FastClick.prototype.sendClick = function(targetElement, event) {
  201. 'use strict';
  202. var clickEvent, touch;
  203. // On some Android devices activeElement needs to be blurred otherwise the synthetic click will have no effect (#24)
  204. if (document.activeElement && document.activeElement !== targetElement) {
  205. document.activeElement.blur();
  206. }
  207. touch = event.changedTouches[0];
  208. // Synthesise a click event, with an extra attribute so it can be tracked
  209. clickEvent = document.createEvent('MouseEvents');
  210. clickEvent.initMouseEvent('click', true, true, window, 1, touch.screenX, touch.screenY, touch.clientX, touch.clientY, false, false, false, false, 0, null);
  211. clickEvent.forwardedTouchEvent = true;
  212. targetElement.dispatchEvent(clickEvent);
  213. };
  214. /**
  215. * @param {EventTarget|Element} targetElement
  216. */
  217. FastClick.prototype.focus = function(targetElement) {
  218. 'use strict';
  219. var length;
  220. if (this.deviceIsIOS && targetElement.setSelectionRange) {
  221. length = targetElement.value.length;
  222. targetElement.setSelectionRange(length, length);
  223. } else {
  224. targetElement.focus();
  225. }
  226. };
  227. /**
  228. * Check whether the given target element is a child of a scrollable layer and if so, set a flag on it.
  229. *
  230. * @param {EventTarget|Element} targetElement
  231. */
  232. FastClick.prototype.updateScrollParent = function(targetElement) {
  233. 'use strict';
  234. var scrollParent, parentElement;
  235. scrollParent = targetElement.fastClickScrollParent;
  236. // Attempt to discover whether the target element is contained within a scrollable layer. Re-check if the
  237. // target element was moved to another parent.
  238. if (!scrollParent || !scrollParent.contains(targetElement)) {
  239. parentElement = targetElement;
  240. do {
  241. if (parentElement.scrollHeight > parentElement.offsetHeight) {
  242. scrollParent = parentElement;
  243. targetElement.fastClickScrollParent = parentElement;
  244. break;
  245. }
  246. parentElement = parentElement.parentElement;
  247. } while (parentElement);
  248. }
  249. // Always update the scroll top tracker if possible.
  250. if (scrollParent) {
  251. scrollParent.fastClickLastScrollTop = scrollParent.scrollTop;
  252. }
  253. };
  254. /**
  255. * @param {EventTarget} targetElement
  256. * @returns {Element|EventTarget}
  257. */
  258. FastClick.prototype.getTargetElementFromEventTarget = function(eventTarget) {
  259. 'use strict';
  260. // On some older browsers (notably Safari on iOS 4.1 - see issue #56) the event target may be a text node.
  261. if (eventTarget.nodeType === Node.TEXT_NODE) {
  262. return eventTarget.parentNode;
  263. }
  264. return eventTarget;
  265. };
  266. /**
  267. * On touch start, record the position and scroll offset.
  268. *
  269. * @param {Event} event
  270. * @returns {boolean}
  271. */
  272. FastClick.prototype.onTouchStart = function(event) {
  273. 'use strict';
  274. var targetElement, touch;
  275. targetElement = this.getTargetElementFromEventTarget(event.target);
  276. touch = event.targetTouches[0];
  277. if (this.deviceIsIOS) {
  278. // Only trusted events will deselect text on iOS (issue #49)
  279. if (window.getSelection().rangeCount) {
  280. return true;
  281. }
  282. if (!this.deviceIsIOS4) {
  283. // Weird things happen on iOS when an alert or confirm dialog is opened from a click event callback (issue #23):
  284. // when the user next taps anywhere else on the page, new touchstart and touchend events are dispatched
  285. // with the same identifier as the touch event that previously triggered the click that triggered the alert.
  286. // Sadly, there is an issue on iOS 4 that causes some normal touch events to have the same identifier as an
  287. // immediately preceeding touch event (issue #52), so this fix is unavailable on that platform.
  288. if (touch.identifier === this.lastTouchIdentifier) {
  289. event.preventDefault();
  290. return false;
  291. }
  292. this.lastTouchIdentifier = touch.identifier;
  293. // If the target element is a child of a scrollable layer (using -webkit-overflow-scrolling: touch) and:
  294. // 1) the user does a fling scroll on the scrollable layer
  295. // 2) the user stops the fling scroll with another tap
  296. // then the event.target of the last 'touchend' event will be the element that was under the user's finger
  297. // when the fling scroll was started, causing FastClick to send a click event to that layer - unless a check
  298. // is made to ensure that a parent layer was not scrolled before sending a synthetic click (issue #42).
  299. this.updateScrollParent(targetElement);
  300. }
  301. }
  302. this.trackingClick = true;
  303. this.trackingClickStart = event.timeStamp;
  304. this.targetElement = targetElement;
  305. this.touchStartX = touch.pageX;
  306. this.touchStartY = touch.pageY;
  307. // Prevent phantom clicks on fast double-tap (issue #36)
  308. if ((event.timeStamp - this.lastClickTime) < 200) {
  309. event.preventDefault();
  310. }
  311. return true;
  312. };
  313. /**
  314. * Based on a touchmove event object, check whether the touch has moved past a boundary since it started.
  315. *
  316. * @param {Event} event
  317. * @returns {boolean}
  318. */
  319. FastClick.prototype.touchHasMoved = function(event) {
  320. 'use strict';
  321. var touch = event.targetTouches[0];
  322. if (Math.abs(touch.pageX - this.touchStartX) > 10 || Math.abs(touch.pageY - this.touchStartY) > 10) {
  323. return true;
  324. }
  325. return false;
  326. };
  327. /**
  328. * Update the last position.
  329. *
  330. * @param {Event} event
  331. * @returns {boolean}
  332. */
  333. FastClick.prototype.onTouchMove = function(event) {
  334. 'use strict';
  335. if (!this.trackingClick) {
  336. return true;
  337. }
  338. // If the touch has moved, cancel the click tracking
  339. if (this.targetElement !== this.getTargetElementFromEventTarget(event.target) || this.touchHasMoved(event)) {
  340. this.trackingClick = false;
  341. this.targetElement = null;
  342. }
  343. return true;
  344. };
  345. /**
  346. * Attempt to find the labelled control for the given label element.
  347. *
  348. * @param {EventTarget|HTMLLabelElement} labelElement
  349. * @returns {Element|null}
  350. */
  351. FastClick.prototype.findControl = function(labelElement) {
  352. 'use strict';
  353. // Fast path for newer browsers supporting the HTML5 control attribute
  354. if (labelElement.control !== undefined) {
  355. return labelElement.control;
  356. }
  357. // All browsers under test that support touch events also support the HTML5 htmlFor attribute
  358. if (labelElement.htmlFor) {
  359. return document.getElementById(labelElement.htmlFor);
  360. }
  361. // If no for attribute exists, attempt to retrieve the first labellable descendant element
  362. // the list of which is defined here: http://www.w3.org/TR/html5/forms.html#category-label
  363. return labelElement.querySelector('button, input:not([type=hidden]), keygen, meter, output, progress, select, textarea');
  364. };
  365. /**
  366. * On touch end, determine whether to send a click event at once.
  367. *
  368. * @param {Event} event
  369. * @returns {boolean}
  370. */
  371. FastClick.prototype.onTouchEnd = function(event) {
  372. 'use strict';
  373. var forElement, trackingClickStart, targetTagName, scrollParent, touch, targetElement = this.targetElement;
  374. if (!this.trackingClick) {
  375. return true;
  376. }
  377. // Prevent phantom clicks on fast double-tap (issue #36)
  378. if ((event.timeStamp - this.lastClickTime) < 200) {
  379. this.cancelNextClick = true;
  380. return true;
  381. }
  382. this.lastClickTime = event.timeStamp;
  383. trackingClickStart = this.trackingClickStart;
  384. this.trackingClick = false;
  385. this.trackingClickStart = 0;
  386. // On some iOS devices, the targetElement supplied with the event is invalid if the layer
  387. // is performing a transition or scroll, and has to be re-detected manually. Note that
  388. // for this to function correctly, it must be called *after* the event target is checked!
  389. // See issue #57; also filed as rdar://13048589 .
  390. if (this.deviceIsIOSWithBadTarget) {
  391. touch = event.changedTouches[0];
  392. targetElement = event.target;
  393. targetElement = document.elementFromPoint(touch.pageX - window.pageXOffset, touch.pageY - window.pageYOffset);
  394. }
  395. targetTagName = targetElement.tagName.toLowerCase();
  396. if (targetTagName === 'label') {
  397. forElement = this.findControl(targetElement);
  398. if (forElement) {
  399. this.focus(targetElement);
  400. if (this.deviceIsAndroid) {
  401. return false;
  402. }
  403. targetElement = forElement;
  404. }
  405. } else if (this.needsFocus(targetElement)) {
  406. // Case 1: If the touch started a while ago (best guess is 100ms based on tests for issue #36) then focus will be triggered anyway. Return early and unset the target element reference so that the subsequent click will be allowed through.
  407. // Case 2: Without this exception for input elements tapped when the document is contained in an iframe, then any inputted text won't be visible even though the value attribute is updated as the user types (issue #37).
  408. if ((event.timeStamp - trackingClickStart) > 100 || (this.deviceIsIOS && window.top !== window && targetTagName === 'input')) {
  409. this.targetElement = null;
  410. return false;
  411. }
  412. this.focus(targetElement);
  413. // Select elements need the event to go through on iOS 4, otherwise the selector menu won't open.
  414. if (!this.deviceIsIOS4 || targetTagName !== 'select') {
  415. this.targetElement = null;
  416. event.preventDefault();
  417. }
  418. return false;
  419. }
  420. if (this.deviceIsIOS && !this.deviceIsIOS4) {
  421. // Don't send a synthetic click event if the target element is contained within a parent layer that was scrolled
  422. // and this tap is being used to stop the scrolling (usually initiated by a fling - issue #42).
  423. scrollParent = targetElement.fastClickScrollParent;
  424. if (scrollParent && scrollParent.fastClickLastScrollTop !== scrollParent.scrollTop) {
  425. return true;
  426. }
  427. }
  428. // Prevent the actual click from going though - unless the target node is marked as requiring
  429. // real clicks or if it is in the whitelist in which case only non-programmatic clicks are permitted.
  430. if (!this.needsClick(targetElement)) {
  431. event.preventDefault();
  432. this.sendClick(targetElement, event);
  433. }
  434. return false;
  435. };
  436. /**
  437. * On touch cancel, stop tracking the click.
  438. *
  439. * @returns {void}
  440. */
  441. FastClick.prototype.onTouchCancel = function() {
  442. 'use strict';
  443. this.trackingClick = false;
  444. this.targetElement = null;
  445. };
  446. /**
  447. * On actual clicks, determine whether this is a touch-generated click, a click action occurring
  448. * naturally after a delay after a touch (which needs to be cancelled to avoid duplication), or
  449. * an actual click which should be permitted.
  450. *
  451. * @param {Event} event
  452. * @returns {boolean}
  453. */
  454. FastClick.prototype.onClick = function(event) {
  455. 'use strict';
  456. var oldTargetElement;
  457. // If a target element was never set (because a touch event was never fired) allow the click
  458. if (!this.targetElement) {
  459. return true;
  460. }
  461. if (event.forwardedTouchEvent) {
  462. return true;
  463. }
  464. oldTargetElement = this.targetElement;
  465. this.targetElement = null;
  466. // It's possible for another FastClick-like library delivered with third-party code to fire a click event before FastClick does (issue #44). In that case, set the click-tracking flag back to false and return early. This will cause onTouchEnd to return early.
  467. if (this.trackingClick) {
  468. this.trackingClick = false;
  469. return true;
  470. }
  471. // Programmatically generated events targeting a specific element should be permitted
  472. if (!event.cancelable) {
  473. return true;
  474. }
  475. // Very odd behaviour on iOS (issue #18): if a submit element is present inside a form and the user hits enter in the iOS simulator or clicks the Go button on the pop-up OS keyboard the a kind of 'fake' click event will be triggered with the submit-type input element as the target.
  476. if (event.target.type === 'submit' && event.detail === 0) {
  477. return true;
  478. }
  479. // Derive and check the target element to see whether the click needs to be permitted;
  480. // unless explicitly enabled, prevent non-touch click events from triggering actions,
  481. // to prevent ghost/doubleclicks.
  482. if (!this.needsClick(oldTargetElement) || this.cancelNextClick) {
  483. this.cancelNextClick = false;
  484. // Prevent any user-added listeners declared on FastClick element from being fired.
  485. if (event.stopImmediatePropagation) {
  486. event.stopImmediatePropagation();
  487. } else {
  488. // Part of the hack for browsers that don't support Event#stopImmediatePropagation (e.g. Android 2)
  489. event.propagationStopped = true;
  490. }
  491. // Cancel the event
  492. event.stopPropagation();
  493. event.preventDefault();
  494. return false;
  495. }
  496. // If clicks are permitted, return true for the action to go through.
  497. return true;
  498. };
  499. /**
  500. * Remove all FastClick's event listeners.
  501. *
  502. * @returns {void}
  503. */
  504. FastClick.prototype.destroy = function() {
  505. 'use strict';
  506. var layer = this.layer;
  507. layer.removeEventListener('click', this.onClick, true);
  508. layer.removeEventListener('touchstart', this.onTouchStart, false);
  509. layer.removeEventListener('touchmove', this.onTouchMove, false);
  510. layer.removeEventListener('touchend', this.onTouchEnd, false);
  511. layer.removeEventListener('touchcancel', this.onTouchCancel, false);
  512. };
  513. if (typeof define !== 'undefined' && define.amd) {
  514. // AMD. Register as an anonymous module.
  515. define(function() {
  516. 'use strict';
  517. return FastClick;
  518. });
  519. }
  520. if (typeof module !== 'undefined' && module.exports) {
  521. module.exports = function(layer) {
  522. 'use strict';
  523. return new FastClick(layer);
  524. };
  525. module.exports.FastClick = FastClick;
  526. }(function(){var n=this,t=n._,r={},e=Array.prototype,u=Object.prototype,i=Function.prototype,a=e.push,o=e.slice,c=e.concat,l=u.toString,f=u.hasOwnProperty,s=e.forEach,p=e.map,v=e.reduce,h=e.reduceRight,g=e.filter,d=e.every,m=e.some,y=e.indexOf,b=e.lastIndexOf,x=Array.isArray,_=Object.keys,j=i.bind,w=function(n){return n instanceof w?n:this instanceof w?(this._wrapped=n,void 0):new w(n)};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=w),exports._=w):n._=w,w.VERSION="1.4.3";var A=w.each=w.forEach=function(n,t,e){if(null!=n)if(s&&n.forEach===s)n.forEach(t,e);else if(n.length===+n.length){for(var u=0,i=n.length;i>u;u++)if(t.call(e,n[u],u,n)===r)return}else for(var a in n)if(w.has(n,a)&&t.call(e,n[a],a,n)===r)return};w.map=w.collect=function(n,t,r){var e=[];return null==n?e:p&&n.map===p?n.map(t,r):(A(n,function(n,u,i){e[e.length]=t.call(r,n,u,i)}),e)};var O="Reduce of empty array with no initial value";w.reduce=w.foldl=w.inject=function(n,t,r,e){var u=arguments.length>2;if(null==n&&(n=[]),v&&n.reduce===v)return e&&(t=w.bind(t,e)),u?n.reduce(t,r):n.reduce(t);if(A(n,function(n,i,a){u?r=t.call(e,r,n,i,a):(r=n,u=!0)}),!u)throw new TypeError(O);return r},w.reduceRight=w.foldr=function(n,t,r,e){var u=arguments.length>2;if(null==n&&(n=[]),h&&n.reduceRight===h)return e&&(t=w.bind(t,e)),u?n.reduceRight(t,r):n.reduceRight(t);var i=n.length;if(i!==+i){var a=w.keys(n);i=a.length}if(A(n,function(o,c,l){c=a?a[--i]:--i,u?r=t.call(e,r,n[c],c,l):(r=n[c],u=!0)}),!u)throw new TypeError(O);return r},w.find=w.detect=function(n,t,r){var e;return E(n,function(n,u,i){return t.call(r,n,u,i)?(e=n,!0):void 0}),e},w.filter=w.select=function(n,t,r){var e=[];return null==n?e:g&&n.filter===g?n.filter(t,r):(A(n,function(n,u,i){t.call(r,n,u,i)&&(e[e.length]=n)}),e)},w.reject=function(n,t,r){return w.filter(n,function(n,e,u){return!t.call(r,n,e,u)},r)},w.every=w.all=function(n,t,e){t||(t=w.identity);var u=!0;return null==n?u:d&&n.every===d?n.every(t,e):(A(n,function(n,i,a){return(u=u&&t.call(e,n,i,a))?void 0:r}),!!u)};var E=w.some=w.any=function(n,t,e){t||(t=w.identity);var u=!1;return null==n?u:m&&n.some===m?n.some(t,e):(A(n,function(n,i,a){return u||(u=t.call(e,n,i,a))?r:void 0}),!!u)};w.contains=w.include=function(n,t){return null==n?!1:y&&n.indexOf===y?-1!=n.indexOf(t):E(n,function(n){return n===t})},w.invoke=function(n,t){var r=o.call(arguments,2);return w.map(n,function(n){return(w.isFunction(t)?t:n[t]).apply(n,r)})},w.pluck=function(n,t){return w.map(n,function(n){return n[t]})},w.where=function(n,t){return w.isEmpty(t)?[]:w.filter(n,function(n){for(var r in t)if(t[r]!==n[r])return!1;return!0})},w.max=function(n,t,r){if(!t&&w.isArray(n)&&n[0]===+n[0]&&65535>n.length)return Math.max.apply(Math,n);if(!t&&w.isEmpty(n))return-1/0;var e={computed:-1/0,value:-1/0};return A(n,function(n,u,i){var a=t?t.call(r,n,u,i):n;a>=e.computed&&(e={value:n,computed:a})}),e.value},w.min=function(n,t,r){if(!t&&w.isArray(n)&&n[0]===+n[0]&&65535>n.length)return Math.min.apply(Math,n);if(!t&&w.isEmpty(n))return 1/0;var e={computed:1/0,value:1/0};return A(n,function(n,u,i){var a=t?t.call(r,n,u,i):n;e.computed>a&&(e={value:n,computed:a})}),e.value},w.shuffle=function(n){var t,r=0,e=[];return A(n,function(n){t=w.random(r++),e[r-1]=e[t],e[t]=n}),e};var F=function(n){return w.isFunction(n)?n:function(t){return t[n]}};w.sortBy=function(n,t,r){var e=F(t);return w.pluck(w.map(n,function(n,t,u){return{value:n,index:t,criteria:e.call(r,n,t,u)}}).sort(function(n,t){var r=n.criteria,e=t.criteria;if(r!==e){if(r>e||void 0===r)return 1;if(e>r||void 0===e)return-1}return n.index<t.index?-1:1}),"value")};var k=function(n,t,r,e){var u={},i=F(t||w.identity);return A(n,function(t,a){var o=i.call(r,t,a,n);e(u,o,t)}),u};w.groupBy=function(n,t,r){return k(n,t,r,function(n,t,r){(w.has(n,t)?n[t]:n[t]=[]).push(r)})},w.countBy=function(n,t,r){return k(n,t,r,function(n,t){w.has(n,t)||(n[t]=0),n[t]++})},w.sortedIndex=function(n,t,r,e){r=null==r?w.identity:F(r);for(var u=r.call(e,t),i=0,a=n.length;a>i;){var o=i+a>>>1;u>r.call(e,n[o])?i=o+1:a=o}return i},w.toArray=function(n){return n?w.isArray(n)?o.call(n):n.length===+n.length?w.map(n,w.identity):w.values(n):[]},w.size=function(n){return null==n?0:n.length===+n.length?n.length:w.keys(n).length},w.first=w.head=w.take=function(n,t,r){return null==n?void 0:null==t||r?n[0]:o.call(n,0,t)},w.initial=function(n,t,r){return o.call(n,0,n.length-(null==t||r?1:t))},w.last=function(n,t,r){return null==n?void 0:null==t||r?n[n.length-1]:o.call(n,Math.max(n.length-t,0))},w.rest=w.tail=w.drop=function(n,t,r){return o.call(n,null==t||r?1:t)},w.compact=function(n){return w.filter(n,w.identity)};var R=function(n,t,r){return A(n,function(n){w.isArray(n)?t?a.apply(r,n):R(n,t,r):r.push(n)}),r};w.flatten=function(n,t){return R(n,t,[])},w.without=function(n){return w.difference(n,o.call(arguments,1))},w.uniq=w.unique=function(n,t,r,e){w.isFunction(t)&&(e=r,r=t,t=!1);var u=r?w.map(n,r,e):n,i=[],a=[];return A(u,function(r,e){(t?e&&a[a.length-1]===r:w.contains(a,r))||(a.push(r),i.push(n[e]))}),i},w.union=function(){return w.uniq(c.apply(e,arguments))},w.intersection=function(n){var t=o.call(arguments,1);return w.filter(w.uniq(n),function(n){return w.every(t,function(t){return w.indexOf(t,n)>=0})})},w.difference=function(n){var t=c.apply(e,o.call(arguments,1));return w.filter(n,function(n){return!w.contains(t,n)})},w.zip=function(){for(var n=o.call(arguments),t=w.max(w.pluck(n,"length")),r=Array(t),e=0;t>e;e++)r[e]=w.pluck(n,""+e);return r},w.object=function(n,t){if(null==n)return{};for(var r={},e=0,u=n.length;u>e;e++)t?r[n[e]]=t[e]:r[n[e][0]]=n[e][1];return r},w.indexOf=function(n,t,r){if(null==n)return-1;var e=0,u=n.length;if(r){if("number"!=typeof r)return e=w.sortedIndex(n,t),n[e]===t?e:-1;e=0>r?Math.max(0,u+r):r}if(y&&n.indexOf===y)return n.indexOf(t,r);for(;u>e;e++)if(n[e]===t)return e;return-1},w.lastIndexOf=function(n,t,r){if(null==n)return-1;var e=null!=r;if(b&&n.lastIndexOf===b)return e?n.lastIndexOf(t,r):n.lastIndexOf(t);for(var u=e?r:n.length;u--;)if(n[u]===t)return u;return-1},w.range=function(n,t,r){1>=arguments.length&&(t=n||0,n=0),r=arguments[2]||1;for(var e=Math.max(Math.ceil((t-n)/r),0),u=0,i=Array(e);e>u;)i[u++]=n,n+=r;return i};var I=function(){};w.bind=function(n,t){var r,e;if(n.bind===j&&j)return j.apply(n,o.call(arguments,1));if(!w.isFunction(n))throw new TypeError;return r=o.call(arguments,2),e=function(){if(!(this instanceof e))return n.apply(t,r.concat(o.call(arguments)));I.prototype=n.prototype;var u=new I;I.prototype=null;var i=n.apply(u,r.concat(o.call(arguments)));return Object(i)===i?i:u}},w.bindAll=function(n){var t=o.call(arguments,1);return 0==t.length&&(t=w.functions(n)),A(t,function(t){n[t]=w.bind(n[t],n)}),n},w.memoize=function(n,t){var r={};return t||(t=w.identity),function(){var e=t.apply(this,arguments);return w.has(r,e)?r[e]:r[e]=n.apply(this,arguments)}},w.delay=function(n,t){var r=o.call(arguments,2);return setTimeout(function(){return n.apply(null,r)},t)},w.defer=function(n){return w.delay.apply(w,[n,1].concat(o.call(arguments,1)))},w.throttle=function(n,t){var r,e,u,i,a=0,o=function(){a=new Date,u=null,i=n.apply(r,e)};return function(){var c=new Date,l=t-(c-a);return r=this,e=arguments,0>=l?(clearTimeout(u),u=null,a=c,i=n.apply(r,e)):u||(u=setTimeout(o,l)),i}},w.debounce=function(n,t,r){var e,u;return function(){var i=this,a=arguments,o=function(){e=null,r||(u=n.apply(i,a))},c=r&&!e;return clearTimeout(e),e=setTimeout(o,t),c&&(u=n.apply(i,a)),u}},w.once=function(n){var t,r=!1;return function(){return r?t:(r=!0,t=n.apply(this,arguments),n=null,t)}},w.wrap=function(n,t){return function(){var r=[n];return a.apply(r,arguments),t.apply(this,r)}},w.compose=function(){var n=arguments;return function(){for(var t=arguments,r=n.length-1;r>=0;r--)t=[n[r].apply(this,t)];return t[0]}},w.after=function(n,t){return 0>=n?t():function(){return 1>--n?t.apply(this,arguments):void 0}},w.keys=_||function(n){if(n!==Object(n))throw new TypeError("Invalid object");var t=[];for(var r in n)w.has(n,r)&&(t[t.length]=r);return t},w.values=function(n){var t=[];for(var r in n)w.has(n,r)&&t.push(n[r]);return t},w.pairs=function(n){var t=[];for(var r in n)w.has(n,r)&&t.push([r,n[r]]);return t},w.invert=function(n){var t={};for(var r in n)w.has(n,r)&&(t[n[r]]=r);return t},w.functions=w.methods=function(n){var t=[];for(var r in n)w.isFunction(n[r])&&t.push(r);return t.sort()},w.extend=function(n){return A(o.call(arguments,1),function(t){if(t)for(var r in t)n[r]=t[r]}),n},w.pick=function(n){var t={},r=c.apply(e,o.call(arguments,1));return A(r,function(r){r in n&&(t[r]=n[r])}),t},w.omit=function(n){var t={},r=c.apply(e,o.call(arguments,1));for(var u in n)w.contains(r,u)||(t[u]=n[u]);return t},w.defaults=function(n){return A(o.call(arguments,1),function(t){if(t)for(var r in t)null==n[r]&&(n[r]=t[r])}),n},w.clone=function(n){return w.isObject(n)?w.isArray(n)?n.slice():w.extend({},n):n},w.tap=function(n,t){return t(n),n};var S=function(n,t,r,e){if(n===t)return 0!==n||1/n==1/t;if(null==n||null==t)return n===t;n instanceof w&&(n=n._wrapped),t instanceof w&&(t=t._wrapped);var u=l.call(n);if(u!=l.call(t))return!1;switch(u){case"[object String]":return n==t+"";case"[object Number]":return n!=+n?t!=+t:0==n?1/n==1/t:n==+t;case"[object Date]":case"[object Boolean]":return+n==+t;case"[object RegExp]":return n.source==t.source&&n.global==t.global&&n.multiline==t.multiline&&n.ignoreCase==t.ignoreCase}if("object"!=typeof n||"object"!=typeof t)return!1;for(var i=r.length;i--;)if(r[i]==n)return e[i]==t;r.push(n),e.push(t);var a=0,o=!0;if("[object Array]"==u){if(a=n.length,o=a==t.length)for(;a--&&(o=S(n[a],t[a],r,e)););}else{var c=n.constructor,f=t.constructor;if(c!==f&&!(w.isFunction(c)&&c instanceof c&&w.isFunction(f)&&f instanceof f))return!1;for(var s in n)if(w.has(n,s)&&(a++,!(o=w.has(t,s)&&S(n[s],t[s],r,e))))break;if(o){for(s in t)if(w.has(t,s)&&!a--)break;o=!a}}return r.pop(),e.pop(),o};w.isEqual=function(n,t){return S(n,t,[],[])},w.isEmpty=function(n){if(null==n)return!0;if(w.isArray(n)||w.isString(n))return 0===n.length;for(var t in n)if(w.has(n,t))return!1;return!0},w.isElement=function(n){return!(!n||1!==n.nodeType)},w.isArray=x||function(n){return"[object Array]"==l.call(n)},w.isObject=function(n){return n===Object(n)},A(["Arguments","Function","String","Number","Date","RegExp"],function(n){w["is"+n]=function(t){return l.call(t)=="[object "+n+"]"}}),w.isArguments(arguments)||(w.isArguments=function(n){return!(!n||!w.has(n,"callee"))}),w.isFunction=function(n){return"function"==typeof n},w.isFinite=function(n){return isFinite(n)&&!isNaN(parseFloat(n))},w.isNaN=function(n){return w.isNumber(n)&&n!=+n},w.isBoolean=function(n){return n===!0||n===!1||"[object Boolean]"==l.call(n)},w.isNull=function(n){return null===n},w.isUndefined=function(n){return void 0===n},w.has=function(n,t){return f.call(n,t)},w.noConflict=function(){return n._=t,this},w.identity=function(n){return n},w.times=function(n,t,r){for(var e=Array(n),u=0;n>u;u++)e[u]=t.call(r,u);return e},w.random=function(n,t){return null==t&&(t=n,n=0),n+(0|Math.random()*(t-n+1))};var T={escape:{"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","/":"&#x2F;"}};T.unescape=w.invert(T.escape);var M={escape:RegExp("["+w.keys(T.escape).join("")+"]","g"),unescape:RegExp("("+w.keys(T.unescape).join("|")+")","g")};w.each(["escape","unescape"],function(n){w[n]=function(t){return null==t?"":(""+t).replace(M[n],function(t){return T[n][t]})}}),w.result=function(n,t){if(null==n)return null;var r=n[t];return w.isFunction(r)?r.call(n):r},w.mixin=function(n){A(w.functions(n),function(t){var r=w[t]=n[t];w.prototype[t]=function(){var n=[this._wrapped];return a.apply(n,arguments),z.call(this,r.apply(w,n))}})};var N=0;w.uniqueId=function(n){var t=""+ ++N;return n?n+t:t},w.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var q=/(.)^/,B={"'":"'","\\":"\\","\r":"r","\n":"n"," ":"t","\u2028":"u2028","\u2029":"u2029"},D=/\\|'|\r|\n|\t|\u2028|\u2029/g;w.template=function(n,t,r){r=w.defaults({},r,w.templateSettings);var e=RegExp([(r.escape||q).source,(r.interpolate||q).source,(r.evaluate||q).source].join("|")+"|$","g"),u=0,i="__p+='";n.replace(e,function(t,r,e,a,o){return i+=n.slice(u,o).replace(D,function(n){return"\\"+B[n]}),r&&(i+="'+\n((__t=("+r+"))==null?'':_.escape(__t))+\n'"),e&&(i+="'+\n((__t=("+e+"))==null?'':__t)+\n'"),a&&(i+="';\n"+a+"\n__p+='"),u=o+t.length,t}),i+="';\n",r.variable||(i="with(obj||{}){\n"+i+"}\n"),i="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+i+"return __p;\n";try{var a=Function(r.variable||"obj","_",i)}catch(o){throw o.source=i,o}if(t)return a(t,w);var c=function(n){return a.call(this,n,w)};return c.source="function("+(r.variable||"obj")+"){\n"+i+"}",c},w.chain=function(n){return w(n).chain()};var z=function(n){return this._chain?w(n).chain():n};w.mixin(w),A(["pop","push","reverse","shift","sort","splice","unshift"],function(n){var t=e[n];w.prototype[n]=function(){var r=this._wrapped;return t.apply(r,arguments),"shift"!=n&&"splice"!=n||0!==r.length||delete r[0],z.call(this,r)}}),A(["concat","join","slice"],function(n){var t=e[n];w.prototype[n]=function(){return z.call(this,t.apply(this._wrapped,arguments))}}),w.extend(w.prototype,{chain:function(){return this._chain=!0,this},value:function(){return this._wrapped}})}).call(this);/*! jQuery v1.8.2 jquery.com | jquery.org/license */
  527. (function(a,b){function G(a){var b=F[a]={};return p.each(a.split(s),function(a,c){b[c]=!0}),b}function J(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(I,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:+d+""===d?+d:H.test(d)?p.parseJSON(d):d}catch(f){}p.data(a,c,d)}else d=b}return d}function K(a){var b;for(b in a){if(b==="data"&&p.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function ba(){return!1}function bb(){return!0}function bh(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function bi(a,b){do a=a[b];while(a&&a.nodeType!==1);return a}function bj(a,b,c){b=b||0;if(p.isFunction(b))return p.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return p.grep(a,function(a,d){return a===b===c});if(typeof b=="string"){var d=p.grep(a,function(a){return a.nodeType===1});if(be.test(b))return p.filter(b,d,!c);b=p.filter(b,d)}return p.grep(a,function(a,d){return p.inArray(a,b)>=0===c})}function bk(a){var b=bl.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}function bC(a,b){return a.getElementsByTagName(b)[0]||a.appendChild(a.ownerDocument.createElement(b))}function bD(a,b){if(b.nodeType!==1||!p.hasData(a))return;var c,d,e,f=p._data(a),g=p._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;d<e;d++)p.event.add(b,c,h[c][d])}g.data&&(g.data=p.extend({},g.data))}function bE(a,b){var c;if(b.nodeType!==1)return;b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase(),c==="object"?(b.parentNode&&(b.outerHTML=a.outerHTML),p.support.html5Clone&&a.innerHTML&&!p.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):c==="input"&&bv.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):c==="option"?b.selected=a.defaultSelected:c==="input"||c==="textarea"?b.defaultValue=a.defaultValue:c==="script"&&b.text!==a.text&&(b.text=a.text),b.removeAttribute(p.expando)}function bF(a){return typeof a.getElementsByTagName!="undefined"?a.getElementsByTagName("*"):typeof a.querySelectorAll!="undefined"?a.querySelectorAll("*"):[]}function bG(a){bv.test(a.type)&&(a.defaultChecked=a.checked)}function bY(a,b){if(b in a)return b;var c=b.charAt(0).toUpperCase()+b.slice(1),d=b,e=bW.length;while(e--){b=bW[e]+c;if(b in a)return b}return d}function bZ(a,b){return a=b||a,p.css(a,"display")==="none"||!p.contains(a.ownerDocument,a)}function b$(a,b){var c,d,e=[],f=0,g=a.length;for(;f<g;f++){c=a[f];if(!c.style)continue;e[f]=p._data(c,"olddisplay"),b?(!e[f]&&c.style.display==="none"&&(c.style.display=""),c.style.display===""&&bZ(c)&&(e[f]=p._data(c,"olddisplay",cc(c.nodeName)))):(d=bH(c,"display"),!e[f]&&d!=="none"&&p._data(c,"olddisplay",d))}for(f=0;f<g;f++){c=a[f];if(!c.style)continue;if(!b||c.style.display==="none"||c.style.display==="")c.style.display=b?e[f]||"":"none"}return a}function b_(a,b,c){var d=bP.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function ca(a,b,c,d){var e=c===(d?"border":"content")?4:b==="width"?1:0,f=0;for(;e<4;e+=2)c==="margin"&&(f+=p.css(a,c+bV[e],!0)),d?(c==="content"&&(f-=parseFloat(bH(a,"padding"+bV[e]))||0),c!=="margin"&&(f-=parseFloat(bH(a,"border"+bV[e]+"Width"))||0)):(f+=parseFloat(bH(a,"padding"+bV[e]))||0,c!=="padding"&&(f+=parseFloat(bH(a,"border"+bV[e]+"Width"))||0));return f}function cb(a,b,c){var d=b==="width"?a.offsetWidth:a.offsetHeight,e=!0,f=p.support.boxSizing&&p.css(a,"boxSizing")==="border-box";if(d<=0||d==null){d=bH(a,b);if(d<0||d==null)d=a.style[b];if(bQ.test(d))return d;e=f&&(p.support.boxSizingReliable||d===a.style[b]),d=parseFloat(d)||0}return d+ca(a,b,c||(f?"border":"content"),e)+"px"}function cc(a){if(bS[a])return bS[a];var b=p("<"+a+">").appendTo(e.body),c=b.css("display");b.remove();if(c==="none"||c===""){bI=e.body.appendChild(bI||p.extend(e.createElement("iframe"),{frameBorder:0,width:0,height:0}));if(!bJ||!bI.createElement)bJ=(bI.contentWindow||bI.contentDocument).document,bJ.write("<!doctype html><html><body>"),bJ.close();b=bJ.body.appendChild(bJ.createElement(a)),c=bH(b,"display"),e.body.removeChild(bI)}return bS[a]=c,c}function ci(a,b,c,d){var e;if(p.isArray(b))p.each(b,function(b,e){c||ce.test(a)?d(a,e):ci(a+"["+(typeof e=="object"?b:"")+"]",e,c,d)});else if(!c&&p.type(b)==="object")for(e in b)ci(a+"["+e+"]",b[e],c,d);else d(a,b)}function cz(a){return function(b,c){typeof b!="string"&&(c=b,b="*");var d,e,f,g=b.toLowerCase().split(s),h=0,i=g.length;if(p.isFunction(c))for(;h<i;h++)d=g[h],f=/^\+/.test(d),f&&(d=d.substr(1)||"*"),e=a[d]=a[d]||[],e[f?"unshift":"push"](c)}}function cA(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;var h,i=a[f],j=0,k=i?i.length:0,l=a===cv;for(;j<k&&(l||!h);j++)h=i[j](c,d,e),typeof h=="string"&&(!l||g[h]?h=b:(c.dataTypes.unshift(h),h=cA(a,c,d,e,h,g)));return(l||!h)&&!g["*"]&&(h=cA(a,c,d,e,"*",g)),h}function cB(a,c){var d,e,f=p.ajaxSettings.flatOptions||{};for(d in c)c[d]!==b&&((f[d]?a:e||(e={}))[d]=c[d]);e&&p.extend(!0,a,e)}function cC(a,c,d){var e,f,g,h,i=a.contents,j=a.dataTypes,k=a.responseFields;for(f in k)f in d&&(c[k[f]]=d[f]);while(j[0]==="*")j.shift(),e===b&&(e=a.mimeType||c.getResponseHeader("content-type"));if(e)for(f in i)if(i[f]&&i[f].test(e)){j.unshift(f);break}if(j[0]in d)g=j[0];else{for(f in d){if(!j[0]||a.converters[f+" "+j[0]]){g=f;break}h||(h=f)}g=g||h}if(g)return g!==j[0]&&j.unshift(g),d[g]}function cD(a,b){var c,d,e,f,g=a.dataTypes.slice(),h=g[0],i={},j=0;a.dataFilter&&(b=a.dataFilter(b,a.dataType));if(g[1])for(c in a.converters)i[c.toLowerCase()]=a.converters[c];for(;e=g[++j];)if(e!=="*"){if(h!=="*"&&h!==e){c=i[h+" "+e]||i["* "+e];if(!c)for(d in i){f=d.split(" ");if(f[1]===e){c=i[h+" "+f[0]]||i["* "+f[0]];if(c){c===!0?c=i[d]:i[d]!==!0&&(e=f[0],g.splice(j--,0,e));break}}}if(c!==!0)if(c&&a["throws"])b=c(b);else try{b=c(b)}catch(k){return{state:"parsererror",error:c?k:"No conversion from "+h+" to "+e}}}h=e}return{state:"success",data:b}}function cL(){try{return new a.XMLHttpRequest}catch(b){}}function cM(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function cU(){return setTimeout(function(){cN=b},0),cN=p.now()}function cV(a,b){p.each(b,function(b,c){var d=(cT[b]||[]).concat(cT["*"]),e=0,f=d.length;for(;e<f;e++)if(d[e].call(a,b,c))return})}function cW(a,b,c){var d,e=0,f=0,g=cS.length,h=p.Deferred().always(function(){delete i.elem}),i=function(){var b=cN||cU(),c=Math.max(0,j.startTime+j.duration-b),d=1-(c/j.duration||0),e=0,f=j.tweens.length;for(;e<f;e++)j.tweens[e].run(d);return h.notifyWith(a,[j,d,c]),d<1&&f?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:p.extend({},b),opts:p.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:cN||cU(),duration:c.duration,tweens:[],createTween:function(b,c,d){var e=p.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(e),e},stop:function(b){var c=0,d=b?j.tweens.length:0;for(;c<d;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;cX(k,j.opts.specialEasing);for(;e<g;e++){d=cS[e].call(j,a,k,j.opts);if(d)return d}return cV(j,k),p.isFunction(j.opts.start)&&j.opts.start.call(a,j),p.fx.timer(p.extend(i,{anim:j,queue:j.opts.queue,elem:a})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}function cX(a,b){var c,d,e,f,g;for(c in a){d=p.camelCase(c),e=b[d],f=a[c],p.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=p.cssHooks[d];if(g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}}function cY(a,b,c){var d,e,f,g,h,i,j,k,l=this,m=a.style,n={},o=[],q=a.nodeType&&bZ(a);c.queue||(j=p._queueHooks(a,"fx"),j.unqueued==null&&(j.unqueued=0,k=j.empty.fire,j.empty.fire=function(){j.unqueued||k()}),j.unqueued++,l.always(function(){l.always(function(){j.unqueued--,p.queue(a,"fx").length||j.empty.fire()})})),a.nodeType===1&&("height"in b||"width"in b)&&(c.overflow=[m.overflow,m.overflowX,m.overflowY],p.css(a,"display")==="inline"&&p.css(a,"float")==="none"&&(!p.support.inlineBlockNeedsLayout||cc(a.nodeName)==="inline"?m.display="inline-block":m.zoom=1)),c.overflow&&(m.overflow="hidden",p.support.shrinkWrapBlocks||l.done(function(){m.overflow=c.overflow[0],m.overflowX=c.overflow[1],m.overflowY=c.overflow[2]}));for(d in b){f=b[d];if(cP.exec(f)){delete b[d];if(f===(q?"hide":"show"))continue;o.push(d)}}g=o.length;if(g){h=p._data(a,"fxshow")||p._data(a,"fxshow",{}),q?p(a).show():l.done(function(){p(a).hide()}),l.done(function(){var b;p.removeData(a,"fxshow",!0);for(b in n)p.style(a,b,n[b])});for(d=0;d<g;d++)e=o[d],i=l.createTween(e,q?h[e]:0),n[e]=h[e]||p.style(a,e),e in h||(h[e]=i.start,q&&(i.end=i.start,i.start=e==="width"||e==="height"?1:0))}}function cZ(a,b,c,d,e){return new cZ.prototype.init(a,b,c,d,e)}function c$(a,b){var c,d={height:a},e=0;b=b?1:0;for(;e<4;e+=2-b)c=bV[e],d["margin"+c]=d["padding"+c]=a;return b&&(d.opacity=d.width=a),d}function da(a){return p.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}var c,d,e=a.document,f=a.location,g=a.navigator,h=a.jQuery,i=a.$,j=Array.prototype.push,k=Array.prototype.slice,l=Array.prototype.indexOf,m=Object.prototype.toString,n=Object.prototype.hasOwnProperty,o=String.prototype.trim,p=function(a,b){return new p.fn.init(a,b,c)},q=/[\-+]?(?:\d*\.|)\d+(?:[eE][\-+]?\d+|)/.source,r=/\S/,s=/\s+/,t=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,u=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^[\],:{}\s]*$/,x=/(?:^|:|,)(?:\s*\[)+/g,y=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,z=/"[^"\\\r\n]*"|true|false|null|-?(?:\d\d*\.|)\d+(?:[eE][\-+]?\d+|)/g,A=/^-ms-/,B=/-([\da-z])/gi,C=function(a,b){return(b+"").toUpperCase()},D=function(){e.addEventListener?(e.removeEventListener("DOMContentLoaded",D,!1),p.ready()):e.readyState==="complete"&&(e.detachEvent("onreadystatechange",D),p.ready())},E={};p.fn=p.prototype={constructor:p,init:function(a,c,d){var f,g,h,i;if(!a)return this;if(a.nodeType)return this.context=this[0]=a,this.length=1,this;if(typeof a=="string"){a.charAt(0)==="<"&&a.charAt(a.length-1)===">"&&a.length>=3?f=[null,a,null]:f=u.exec(a);if(f&&(f[1]||!c)){if(f[1])return c=c instanceof p?c[0]:c,i=c&&c.nodeType?c.ownerDocument||c:e,a=p.parseHTML(f[1],i,!0),v.test(f[1])&&p.isPlainObject(c)&&this.attr.call(a,c,!0),p.merge(this,a);g=e.getElementById(f[2]);if(g&&g.parentNode){if(g.id!==f[2])return d.find(a);this.length=1,this[0]=g}return this.context=e,this.selector=a,this}return!c||c.jquery?(c||d).find(a):this.constructor(c).find(a)}return p.isFunction(a)?d.ready(a):(a.selector!==b&&(this.selector=a.selector,this.context=a.context),p.makeArray(a,this))},selector:"",jquery:"1.8.2",length:0,size:function(){return this.length},toArray:function(){return k.call(this)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=p.merge(this.constructor(),a);return d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")"),d},each:function(a,b){return p.each(this,a,b)},ready:function(a){return p.ready.promise().done(a),this},eq:function(a){return a=+a,a===-1?this.slice(a):this.slice(a,a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(k.apply(this,arguments),"slice",k.call(arguments).join(","))},map:function(a){return this.pushStack(p.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:j,sort:[].sort,splice:[].splice},p.fn.init.prototype=p.fn,p.extend=p.fn.extend=function(){var a,c,d,e,f,g,h=arguments[0]||{},i=1,j=arguments.length,k=!1;typeof h=="boolean"&&(k=h,h=arguments[1]||{},i=2),typeof h!="object"&&!p.isFunction(h)&&(h={}),j===i&&(h=this,--i);for(;i<j;i++)if((a=arguments[i])!=null)for(c in a){d=h[c],e=a[c];if(h===e)continue;k&&e&&(p.isPlainObject(e)||(f=p.isArray(e)))?(f?(f=!1,g=d&&p.isArray(d)?d:[]):g=d&&p.isPlainObject(d)?d:{},h[c]=p.extend(k,g,e)):e!==b&&(h[c]=e)}return h},p.extend({noConflict:function(b){return a.$===p&&(a.$=i),b&&a.jQuery===p&&(a.jQuery=h),p},isReady:!1,readyWait:1,holdReady:function(a){a?p.readyWait++:p.ready(!0)},ready:function(a){if(a===!0?--p.readyWait:p.isReady)return;if(!e.body)return setTimeout(p.ready,1);p.isReady=!0;if(a!==!0&&--p.readyWait>0)return;d.resolveWith(e,[p]),p.fn.trigger&&p(e).trigger("ready").off("ready")},isFunction:function(a){return p.type(a)==="function"},isArray:Array.isArray||function(a){return p.type(a)==="array"},isWindow:function(a){return a!=null&&a==a.window},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return a==null?String(a):E[m.call(a)]||"object"},isPlainObject:function(a){if(!a||p.type(a)!=="object"||a.nodeType||p.isWindow(a))return!1;try{if(a.constructor&&!n.call(a,"constructor")&&!n.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||n.call(a,d)},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},error:function(a){throw new Error(a)},parseHTML:function(a,b,c){var d;return!a||typeof a!="string"?null:(typeof b=="boolean"&&(c=b,b=0),b=b||e,(d=v.exec(a))?[b.createElement(d[1])]:(d=p.buildFragment([a],b,c?null:[]),p.merge([],(d.cacheable?p.clone(d.fragment):d.fragment).childNodes)))},parseJSON:function(b){if(!b||typeof b!="string")return null;b=p.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(w.test(b.replace(y,"@").replace(z,"]").replace(x,"")))return(new Function("return "+b))();p.error("Invalid JSON: "+b)},parseXML:function(c){var d,e;if(!c||typeof c!="string")return null;try{a.DOMParser?(e=new DOMParser,d=e.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(f){d=b}return(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&p.error("Invalid XML: "+c),d},noop:function(){},globalEval:function(b){b&&r.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(A,"ms-").replace(B,C)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,c,d){var e,f=0,g=a.length,h=g===b||p.isFunction(a);if(d){if(h){for(e in a)if(c.apply(a[e],d)===!1)break}else for(;f<g;)if(c.apply(a[f++],d)===!1)break}else if(h){for(e in a)if(c.call(a[e],e,a[e])===!1)break}else for(;f<g;)if(c.call(a[f],f,a[f++])===!1)break;return a},trim:o&&!o.call(" ")?function(a){return a==null?"":o.call(a)}:function(a){return a==null?"":(a+"").replace(t,"")},makeArray:function(a,b){var c,d=b||[];return a!=null&&(c=p.type(a),a.length==null||c==="string"||c==="function"||c==="regexp"||p.isWindow(a)?j.call(d,a):p.merge(d,a)),d},inArray:function(a,b,c){var d;if(b){if(l)return l.call(b,a,c);d=b.length,c=c?c<0?Math.max(0,d+c):c:0;for(;c<d;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,c){var d=c.length,e=a.length,f=0;if(typeof d=="number")for(;f<d;f++)a[e++]=c[f];else while(c[f]!==b)a[e++]=c[f++];return a.length=e,a},grep:function(a,b,c){var d,e=[],f=0,g=a.length;c=!!c;for(;f<g;f++)d=!!b(a[f],f),c!==d&&e.push(a[f]);return e},map:function(a,c,d){var e,f,g=[],h=0,i=a.length,j=a instanceof p||i!==b&&typeof i=="number"&&(i>0&&a[0]&&a[i-1]||i===0||p.isArray(a));if(j)for(;h<i;h++)e=c(a[h],h,d),e!=null&&(g[g.length]=e);else for(f in a)e=c(a[f],f,d),e!=null&&(g[g.length]=e);return g.concat.apply([],g)},guid:1,proxy:function(a,c){var d,e,f;return typeof c=="string"&&(d=a[c],c=a,a=d),p.isFunction(a)?(e=k.call(arguments,2),f=function(){return a.apply(c,e.concat(k.call(arguments)))},

Large files files are truncated, but you can click here to view the full file