nutcracker-web 0.0.14 → 0.0.15
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/Gemfile.lock +27 -23
- data/lib/nutcracker/web/version.rb +1 -1
- data/public/assets/application.js +8 -241
- metadata +9 -9
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 910e83e65e835e4cdadd52ea4832d333e72cb40a
|
4
|
+
data.tar.gz: 1352fcebf6c527e6c6ec9501d4abca83bf2e5173
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7bfb242dd4d8f41a15f590b3d6c5473eac69d040f2b0747791bec31a4377340d1dba695b47d28843e03ed4daf73ffb4a1c5c570d73297e19a85940119ff2d76e
|
7
|
+
data.tar.gz: 6d2f347ba71ccb9beb24fa6ad580fe876cd9ba49a6ecff3da4794875d83abe21842b344c037bcc0acb0acebb1571fc5f4be1feb7dd1fbbe5cc57f7da73494927
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -4,38 +4,42 @@ GEM
|
|
4
4
|
coffee-script (2.4.1)
|
5
5
|
coffee-script-source
|
6
6
|
execjs
|
7
|
-
coffee-script-source (1.
|
8
|
-
|
7
|
+
coffee-script-source (1.12.2)
|
8
|
+
concurrent-ruby (1.0.5)
|
9
|
+
daemons (1.2.6)
|
9
10
|
eco (1.0.0)
|
10
11
|
coffee-script
|
11
12
|
eco-source
|
12
13
|
execjs
|
13
14
|
eco-source (1.1.0.rc.1)
|
14
|
-
eventmachine (1.
|
15
|
-
execjs (2.
|
16
|
-
haml (
|
15
|
+
eventmachine (1.2.7)
|
16
|
+
execjs (2.7.0)
|
17
|
+
haml (5.0.4)
|
18
|
+
temple (>= 0.8.0)
|
17
19
|
tilt
|
18
|
-
|
19
|
-
nutcracker (0.4.1.
|
20
|
+
mustermann (1.0.3)
|
21
|
+
nutcracker (0.4.1.22)
|
20
22
|
redis
|
21
|
-
rack (
|
22
|
-
rack-protection (
|
23
|
+
rack (2.0.6)
|
24
|
+
rack-protection (2.0.4)
|
23
25
|
rack
|
24
|
-
redis (
|
25
|
-
sinatra (
|
26
|
-
|
27
|
-
rack
|
28
|
-
|
29
|
-
|
26
|
+
redis (4.0.2)
|
27
|
+
sinatra (2.0.4)
|
28
|
+
mustermann (~> 1.0)
|
29
|
+
rack (~> 2.0)
|
30
|
+
rack-protection (= 2.0.4)
|
31
|
+
tilt (~> 2.0)
|
32
|
+
sprockets (3.7.2)
|
33
|
+
concurrent-ruby (~> 1.0)
|
30
34
|
rack (> 1, < 3)
|
31
|
-
|
35
|
+
temple (0.8.0)
|
36
|
+
thin (1.7.2)
|
32
37
|
daemons (~> 1.0, >= 1.0.9)
|
33
38
|
eventmachine (~> 1.0, >= 1.0.4)
|
34
|
-
rack (
|
35
|
-
tilt (2.0.
|
36
|
-
uglifier (
|
37
|
-
execjs (>= 0.3.0)
|
38
|
-
json (>= 1.8.0)
|
39
|
+
rack (>= 1, < 3)
|
40
|
+
tilt (2.0.8)
|
41
|
+
uglifier (4.1.19)
|
42
|
+
execjs (>= 0.3.0, < 3)
|
39
43
|
|
40
44
|
PLATFORMS
|
41
45
|
ruby
|
@@ -44,12 +48,12 @@ DEPENDENCIES
|
|
44
48
|
coffee-script
|
45
49
|
eco
|
46
50
|
haml
|
47
|
-
json
|
48
51
|
nutcracker (>= 0.4.1.20)
|
52
|
+
rack (>= 2.0.6)
|
49
53
|
sinatra
|
50
54
|
sprockets
|
51
55
|
thin
|
52
56
|
uglifier
|
53
57
|
|
54
58
|
BUNDLED WITH
|
55
|
-
1.
|
59
|
+
1.16.1
|
@@ -11,7 +11,8 @@
|
|
11
11
|
*
|
12
12
|
* Date: 2013-05-30T21:25Z
|
13
13
|
*/
|
14
|
-
!function(t,e){function n(t){var e=t.length,n=ot.type(t);return ot.isWindow(t)?!1:1===t.nodeType&&e?!0:"array"===n||"function"!==n&&(0===e||"number"==typeof e&&e>0&&e-1 in t)}function r(t){var e=dt[t]={};return ot.each(t.match(at)||[],function(t,n){e[n]=!0}),e}function i(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=ot.expando+Math.random()}function o(t,n,r){var i;if(r===e&&1===t.nodeType)if(i="data-"+n.replace(yt,"-$1").toLowerCase(),r=t.getAttribute(i),"string"==typeof r){try{r="true"===r?!0:"false"===r?!1:"null"===r?null:+r+""===r?+r:vt.test(r)?JSON.parse(r):r}catch(o){}mt.set(t,n,r)}else r=e;return r}function s(){return!0}function a(){return!1}function u(){try{return U.activeElement}catch(t){}}function l(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}function c(t,e,n){if(ot.isFunction(e))return ot.grep(t,function(t,r){return!!e.call(t,r,t)!==n});if(e.nodeType)return ot.grep(t,function(t){return t===e!==n});if("string"==typeof e){if($t.test(e))return ot.filter(e,t,n);e=ot.filter(e,t)}return ot.grep(t,function(t){return et.call(e,t)>=0!==n})}function h(t,e){return ot.nodeName(t,"table")&&ot.nodeName(1===e.nodeType?e:e.firstChild,"tr")?t.getElementsByTagName("tbody")[0]||t.appendChild(t.ownerDocument.createElement("tbody")):t}function f(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function p(t){var e=zt.exec(t.type);return e?t.type=e[1]:t.removeAttribute("type"),t}function d(t,e){for(var n=t.length,r=0;n>r;r++)gt.set(t[r],"globalEval",!e||gt.get(e[r],"globalEval"))}function m(t,e){var n,r,i,o,s,a,u,l;if(1===e.nodeType){if(gt.hasData(t)&&(o=gt.access(t),s=gt.set(e,o),l=o.events)){delete s.handle,s.events={};for(i in l)for(n=0,r=l[i].length;r>n;n++)ot.event.add(e,i,l[i][n])}mt.hasData(t)&&(a=mt.access(t),u=ot.extend({},a),mt.set(e,u))}}function g(t,n){var r=t.getElementsByTagName?t.getElementsByTagName(n||"*"):t.querySelectorAll?t.querySelectorAll(n||"*"):[];return n===e||n&&ot.nodeName(t,n)?ot.merge([t],r):r}function v(t,e){var n=e.nodeName.toLowerCase();"input"===n&&Pt.test(t.type)?e.checked=t.checked:("input"===n||"textarea"===n)&&(e.defaultValue=t.defaultValue)}function y(t,e){if(e in t)return e;for(var n=e.charAt(0).toUpperCase()+e.slice(1),r=e,i=Zt.length;i--;)if(e=Zt[i]+n,e in t)return e;return r}function b(t,e){return t=e||t,"none"===ot.css(t,"display")||!ot.contains(t.ownerDocument,t)}function w(e){return t.getComputedStyle(e,null)}function x(t,e){for(var n,r,i,o=[],s=0,a=t.length;a>s;s++)r=t[s],r.style&&(o[s]=gt.get(r,"olddisplay"),n=r.style.display,e?(o[s]||"none"!==n||(r.style.display=""),""===r.style.display&&b(r)&&(o[s]=gt.access(r,"olddisplay",_(r.nodeName)))):o[s]||(i=b(r),(n&&"none"!==n||!i)&>.set(r,"olddisplay",i?n:ot.css(r,"display"))));for(s=0;a>s;s++)r=t[s],r.style&&(e&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=e?o[s]||"":"none"));return t}function C(t,e,n){var r=Jt.exec(e);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):e}function k(t,e,n,r,i){for(var o=n===(r?"border":"content")?4:"width"===e?1:0,s=0;4>o;o+=2)"margin"===n&&(s+=ot.css(t,n+Kt[o],!0,i)),r?("content"===n&&(s-=ot.css(t,"padding"+Kt[o],!0,i)),"margin"!==n&&(s-=ot.css(t,"border"+Kt[o]+"Width",!0,i))):(s+=ot.css(t,"padding"+Kt[o],!0,i),"padding"!==n&&(s+=ot.css(t,"border"+Kt[o]+"Width",!0,i)));return s}function T(t,e,n){var r=!0,i="width"===e?t.offsetWidth:t.offsetHeight,o=w(t),s=ot.support.boxSizing&&"border-box"===ot.css(t,"boxSizing",!1,o);if(0>=i||null==i){if(i=It(t,e,o),(0>i||null==i)&&(i=t.style[e]),Vt.test(i))return i;r=s&&(ot.support.boxSizingReliable||i===t.style[e]),i=parseFloat(i)||0}return i+k(t,e,n||(s?"border":"content"),r,o)+"px"}function _(t){var e=U,n=Gt[t];return n||(n=N(t,e),"none"!==n&&n||(Bt=(Bt||ot("<iframe frameborder='0' width='0' height='0'/>").css("cssText","display:block !important")).appendTo(e.documentElement),e=(Bt[0].contentWindow||Bt[0].contentDocument).document,e.write("<!doctype html><html><body>"),e.close(),n=N(t,e),Bt.detach()),Gt[t]=n),n}function N(t,e){var n=ot(e.createElement(t)).appendTo(e.body),r=ot.css(n[0],"display");return n.remove(),r}function S(t,e,n,r){var i;if(ot.isArray(e))ot.each(e,function(e,i){n||ee.test(t)?r(t,i):S(t+"["+("object"==typeof i?e:"")+"]",i,n,r)});else if(n||"object"!==ot.type(e))r(t,e);else for(i in e)S(t+"["+i+"]",e[i],n,r)}function $(t){return function(e,n){"string"!=typeof e&&(n=e,e="*");var r,i=0,o=e.toLowerCase().match(at)||[];if(ot.isFunction(n))for(;r=o[i++];)"+"===r[0]?(r=r.slice(1)||"*",(t[r]=t[r]||[]).unshift(n)):(t[r]=t[r]||[]).push(n)}}function E(t,e,n,r){function i(a){var u;return o[a]=!0,ot.each(t[a]||[],function(t,a){var l=a(e,n,r);return"string"!=typeof l||s||o[l]?s?!(u=l):void 0:(e.dataTypes.unshift(l),i(l),!1)}),u}var o={},s=t===ye;return i(e.dataTypes[0])||!o["*"]&&i("*")}function j(t,n){var r,i,o=ot.ajaxSettings.flatOptions||{};for(r in n)n[r]!==e&&((o[r]?t:i||(i={}))[r]=n[r]);return i&&ot.extend(!0,t,i),t}function M(t,n,r){for(var i,o,s,a,u=t.contents,l=t.dataTypes;"*"===l[0];)l.shift(),i===e&&(i=t.mimeType||n.getResponseHeader("Content-Type"));if(i)for(o in u)if(u[o]&&u[o].test(i)){l.unshift(o);break}if(l[0]in r)s=l[0];else{for(o in r){if(!l[0]||t.converters[o+" "+l[0]]){s=o;break}a||(a=o)}s=s||a}return s?(s!==l[0]&&l.unshift(s),r[s]):void 0}function D(t,e,n,r){var i,o,s,a,u,l={},c=t.dataTypes.slice();if(c[1])for(s in t.converters)l[s.toLowerCase()]=t.converters[s];for(o=c.shift();o;)if(t.responseFields[o]&&(n[t.responseFields[o]]=e),!u&&r&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(s=l[u+" "+o]||l["* "+o],!s)for(i in l)if(a=i.split(" "),a[1]===o&&(s=l[u+" "+a[0]]||l["* "+a[0]])){s===!0?s=l[i]:l[i]!==!0&&(o=a[0],c.unshift(a[1]));break}if(s!==!0)if(s&&t["throws"])e=s(e);else try{e=s(e)}catch(h){return{state:"parsererror",error:s?h:"No conversion from "+u+" to "+o}}}return{state:"success",data:e}}function A(){return setTimeout(function(){Se=e}),Se=ot.now()}function O(t,e,n){for(var r,i=(Ae[e]||[]).concat(Ae["*"]),o=0,s=i.length;s>o;o++)if(r=i[o].call(n,e,t))return r}function R(t,e,n){var r,i,o=0,s=De.length,a=ot.Deferred().always(function(){delete u.elem}),u=function(){if(i)return!1;for(var e=Se||A(),n=Math.max(0,l.startTime+l.duration-e),r=n/l.duration||0,o=1-r,s=0,u=l.tweens.length;u>s;s++)l.tweens[s].run(o);return a.notifyWith(t,[l,o,n]),1>o&&u?n:(a.resolveWith(t,[l]),!1)},l=a.promise({elem:t,props:ot.extend({},e),opts:ot.extend(!0,{specialEasing:{}},n),originalProperties:e,originalOptions:n,startTime:Se||A(),duration:n.duration,tweens:[],createTween:function(e,n){var r=ot.Tween(t,l.opts,e,n,l.opts.specialEasing[e]||l.opts.easing);return l.tweens.push(r),r},stop:function(e){var n=0,r=e?l.tweens.length:0;if(i)return this;for(i=!0;r>n;n++)l.tweens[n].run(1);return e?a.resolveWith(t,[l,e]):a.rejectWith(t,[l,e]),this}}),c=l.props;for(P(c,l.opts.specialEasing);s>o;o++)if(r=De[o].call(l,t,c,l.opts))return r;return ot.map(c,O,l),ot.isFunction(l.opts.start)&&l.opts.start.call(t,l),ot.fx.timer(ot.extend(u,{elem:t,anim:l,queue:l.opts.queue})),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always)}function P(t,e){var n,r,i,o,s;for(n in t)if(r=ot.camelCase(n),i=e[r],o=t[n],ot.isArray(o)&&(i=o[1],o=t[n]=o[0]),n!==r&&(t[r]=o,delete t[n]),s=ot.cssHooks[r],s&&"expand"in s){o=s.expand(o),delete t[r];for(n in o)n in t||(t[n]=o[n],e[n]=i)}else e[r]=i}function L(t,n,r){var i,o,s,a,u,l,c=this,h={},f=t.style,p=t.nodeType&&b(t),d=gt.get(t,"fxshow");r.queue||(u=ot._queueHooks(t,"fx"),null==u.unqueued&&(u.unqueued=0,l=u.empty.fire,u.empty.fire=function(){u.unqueued||l()}),u.unqueued++,c.always(function(){c.always(function(){u.unqueued--,ot.queue(t,"fx").length||u.empty.fire()})})),1===t.nodeType&&("height"in n||"width"in n)&&(r.overflow=[f.overflow,f.overflowX,f.overflowY],"inline"===ot.css(t,"display")&&"none"===ot.css(t,"float")&&(f.display="inline-block")),r.overflow&&(f.overflow="hidden",c.always(function(){f.overflow=r.overflow[0],f.overflowX=r.overflow[1],f.overflowY=r.overflow[2]}));for(i in n)if(o=n[i],Ee.exec(o)){if(delete n[i],s=s||"toggle"===o,o===(p?"hide":"show")){if("show"!==o||!d||d[i]===e)continue;p=!0}h[i]=d&&d[i]||ot.style(t,i)}if(!ot.isEmptyObject(h)){d?"hidden"in d&&(p=d.hidden):d=gt.access(t,"fxshow",{}),s&&(d.hidden=!p),p?ot(t).show():c.done(function(){ot(t).hide()}),c.done(function(){var e;gt.remove(t,"fxshow");for(e in h)ot.style(t,e,h[e])});for(i in h)a=O(p?d[i]:0,i,c),i in d||(d[i]=a.start,p&&(a.end=a.start,a.start="width"===i||"height"===i?1:0))}}function H(t,e,n,r,i){return new H.prototype.init(t,e,n,r,i)}function z(t,e){var n,r={height:t},i=0;for(e=e?1:0;4>i;i+=2-e)n=Kt[i],r["margin"+n]=r["padding"+n]=t;return e&&(r.opacity=r.width=t),r}function q(t){return ot.isWindow(t)?t:9===t.nodeType&&t.defaultView}var F,I,B=typeof e,W=t.location,U=t.document,J=U.documentElement,V=t.jQuery,X=t.$,G={},Y=[],Q="2.0.2",K=Y.concat,Z=Y.push,tt=Y.slice,et=Y.indexOf,nt=G.toString,rt=G.hasOwnProperty,it=Q.trim,ot=function(t,e){return new ot.fn.init(t,e,F)},st=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,at=/\S+/g,ut=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,lt=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,ct=/^-ms-/,ht=/-([\da-z])/gi,ft=function(t,e){return e.toUpperCase()},pt=function(){U.removeEventListener("DOMContentLoaded",pt,!1),t.removeEventListener("load",pt,!1),ot.ready()};ot.fn=ot.prototype={jquery:Q,constructor:ot,init:function(t,n,r){var i,o;if(!t)return this;if("string"==typeof t){if(i="<"===t.charAt(0)&&">"===t.charAt(t.length-1)&&t.length>=3?[null,t,null]:ut.exec(t),!i||!i[1]&&n)return!n||n.jquery?(n||r).find(t):this.constructor(n).find(t);if(i[1]){if(n=n instanceof ot?n[0]:n,ot.merge(this,ot.parseHTML(i[1],n&&n.nodeType?n.ownerDocument||n:U,!0)),lt.test(i[1])&&ot.isPlainObject(n))for(i in n)ot.isFunction(this[i])?this[i](n[i]):this.attr(i,n[i]);return this}return o=U.getElementById(i[2]),o&&o.parentNode&&(this.length=1,this[0]=o),this.context=U,this.selector=t,this}return t.nodeType?(this.context=this[0]=t,this.length=1,this):ot.isFunction(t)?r.ready(t):(t.selector!==e&&(this.selector=t.selector,this.context=t.context),ot.makeArray(t,this))},selector:"",length:0,toArray:function(){return tt.call(this)},get:function(t){return null==t?this.toArray():0>t?this[this.length+t]:this[t]},pushStack:function(t){var e=ot.merge(this.constructor(),t);return e.prevObject=this,e.context=this.context,e},each:function(t,e){return ot.each(this,t,e)},ready:function(t){return ot.ready.promise().done(t),this},slice:function(){return this.pushStack(tt.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(t){var e=this.length,n=+t+(0>t?e:0);return this.pushStack(n>=0&&e>n?[this[n]]:[])},map:function(t){return this.pushStack(ot.map(this,function(e,n){return t.call(e,n,e)}))},end:function(){return this.prevObject||this.constructor(null)},push:Z,sort:[].sort,splice:[].splice},ot.fn.init.prototype=ot.fn,ot.extend=ot.fn.extend=function(){var t,n,r,i,o,s,a=arguments[0]||{},u=1,l=arguments.length,c=!1;for("boolean"==typeof a&&(c=a,a=arguments[1]||{},u=2),"object"==typeof a||ot.isFunction(a)||(a={}),l===u&&(a=this,--u);l>u;u++)if(null!=(t=arguments[u]))for(n in t)r=a[n],i=t[n],a!==i&&(c&&i&&(ot.isPlainObject(i)||(o=ot.isArray(i)))?(o?(o=!1,s=r&&ot.isArray(r)?r:[]):s=r&&ot.isPlainObject(r)?r:{},a[n]=ot.extend(c,s,i)):i!==e&&(a[n]=i));return a},ot.extend({expando:"jQuery"+(Q+Math.random()).replace(/\D/g,""),noConflict:function(e){return t.$===ot&&(t.$=X),e&&t.jQuery===ot&&(t.jQuery=V),ot},isReady:!1,readyWait:1,holdReady:function(t){t?ot.readyWait++:ot.ready(!0)},ready:function(t){(t===!0?--ot.readyWait:ot.isReady)||(ot.isReady=!0,t!==!0&&--ot.readyWait>0||(I.resolveWith(U,[ot]),ot.fn.trigger&&ot(U).trigger("ready").off("ready")))},isFunction:function(t){return"function"===ot.type(t)},isArray:Array.isArray,isWindow:function(t){return null!=t&&t===t.window},isNumeric:function(t){return!isNaN(parseFloat(t))&&isFinite(t)},type:function(t){return null==t?String(t):"object"==typeof t||"function"==typeof t?G[nt.call(t)]||"object":typeof t},isPlainObject:function(t){if("object"!==ot.type(t)||t.nodeType||ot.isWindow(t))return!1;try{if(t.constructor&&!rt.call(t.constructor.prototype,"isPrototypeOf"))return!1}catch(e){return!1}return!0},isEmptyObject:function(t){var e;for(e in t)return!1;return!0},error:function(t){throw new Error(t)},parseHTML:function(t,e,n){if(!t||"string"!=typeof t)return null;"boolean"==typeof e&&(n=e,e=!1),e=e||U;var r=lt.exec(t),i=!n&&[];return r?[e.createElement(r[1])]:(r=ot.buildFragment([t],e,i),i&&ot(i).remove(),ot.merge([],r.childNodes))},parseJSON:JSON.parse,parseXML:function(t){var n,r;if(!t||"string"!=typeof t)return null;try{r=new DOMParser,n=r.parseFromString(t,"text/xml")}catch(i){n=e}return(!n||n.getElementsByTagName("parsererror").length)&&ot.error("Invalid XML: "+t),n},noop:function(){},globalEval:function(t){var e,n=eval;t=ot.trim(t),t&&(1===t.indexOf("use strict")?(e=U.createElement("script"),e.text=t,U.head.appendChild(e).parentNode.removeChild(e)):n(t))},camelCase:function(t){return t.replace(ct,"ms-").replace(ht,ft)},nodeName:function(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()},each:function(t,e,r){var i,o=0,s=t.length,a=n(t);if(r){if(a)for(;s>o&&(i=e.apply(t[o],r),i!==!1);o++);else for(o in t)if(i=e.apply(t[o],r),i===!1)break}else if(a)for(;s>o&&(i=e.call(t[o],o,t[o]),i!==!1);o++);else for(o in t)if(i=e.call(t[o],o,t[o]),i===!1)break;return t},trim:function(t){return null==t?"":it.call(t)},makeArray:function(t,e){var r=e||[];return null!=t&&(n(Object(t))?ot.merge(r,"string"==typeof t?[t]:t):Z.call(r,t)),r},inArray:function(t,e,n){return null==e?-1:et.call(e,t,n)},merge:function(t,n){var r=n.length,i=t.length,o=0;if("number"==typeof r)for(;r>o;o++)t[i++]=n[o];else for(;n[o]!==e;)t[i++]=n[o++];return t.length=i,t},grep:function(t,e,n){var r,i=[],o=0,s=t.length;for(n=!!n;s>o;o++)r=!!e(t[o],o),n!==r&&i.push(t[o]);return i},map:function(t,e,r){var i,o=0,s=t.length,a=n(t),u=[];if(a)for(;s>o;o++)i=e(t[o],o,r),null!=i&&(u[u.length]=i);else for(o in t)i=e(t[o],o,r),null!=i&&(u[u.length]=i);return K.apply([],u)},guid:1,proxy:function(t,n){var r,i,o;return"string"==typeof n&&(r=t[n],n=t,t=r),ot.isFunction(t)?(i=tt.call(arguments,2),o=function(){return t.apply(n||this,i.concat(tt.call(arguments)))},o.guid=t.guid=t.guid||ot.guid++,o):e},access:function(t,n,r,i,o,s,a){var u=0,l=t.length,c=null==r;if("object"===ot.type(r)){o=!0;for(u in r)ot.access(t,n,u,r[u],!0,s,a)}else if(i!==e&&(o=!0,ot.isFunction(i)||(a=!0),c&&(a?(n.call(t,i),n=null):(c=n,n=function(t,e,n){return c.call(ot(t),n)})),n))for(;l>u;u++)n(t[u],r,a?i:i.call(t[u],u,n(t[u],r)));return o?t:c?n.call(t):l?n(t[0],r):s},now:Date.now,swap:function(t,e,n,r){var i,o,s={};for(o in e)s[o]=t.style[o],t.style[o]=e[o];i=n.apply(t,r||[]);for(o in e)t.style[o]=s[o];return i}}),ot.ready.promise=function(e){return I||(I=ot.Deferred(),"complete"===U.readyState?setTimeout(ot.ready):(U.addEventListener("DOMContentLoaded",pt,!1),t.addEventListener("load",pt,!1))),I.promise(e)},ot.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(t,e){G["[object "+e+"]"]=e.toLowerCase()}),F=ot(U),/*!
|
14
|
+
!function(d,k){function a(t){var e=t.length,n=Et.type(t);return!Et.isWindow(t)&&(!(1!==t.nodeType||!e)||("array"===n||"function"!==n&&(0===e||"number"==typeof e&&0<e&&e-1 in t)))}function t(t){var n=bt[t]={};return Et.each(t.match(st)||[],function(t,e){n[e]=!0}),n}function l(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=Et.expando+Math.random()}function u(t,e,n){var r;if(n===k&&1===t.nodeType)if(r="data-"+e.replace(kt,"-$1").toLowerCase(),"string"==typeof(n=t.getAttribute(r))){try{n="true"===n||"false"!==n&&("null"===n?null:+n+""===n?+n:Ct.test(n)?JSON.parse(n):n)}catch(i){}wt.set(t,e,n)}else n=k;return n}function n(){return!0}function c(){return!1}function e(){try{return U.activeElement}catch(t){}}function r(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}function i(t,n,r){if(Et.isFunction(n))return Et.grep(t,function(t,e){return!!n.call(t,e,t)!==r});if(n.nodeType)return Et.grep(t,function(t){return t===n!==r});if("string"==typeof n){if(Ot.test(n))return Et.filter(n,t,r);n=Et.filter(n,t)}return Et.grep(t,function(t){return 0<=et.call(n,t)!==r})}function o(t,e){return Et.nodeName(t,"table")&&Et.nodeName(1===e.nodeType?e:e.firstChild,"tr")?t.getElementsByTagName("tbody")[0]||t.appendChild(t.ownerDocument.createElement("tbody")):t}function m(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function g(t){var e=Ut.exec(t.type);return e?t.type=e[1]:t.removeAttribute("type"),t}function v(t,e){for(var n=t.length,r=0;r<n;r++)xt.set(t[r],"globalEval",!e||xt.get(e[r],"globalEval"))}function h(t,e){var n,r,i,o,s,a,u,l;if(1===e.nodeType){if(xt.hasData(t)&&(o=xt.access(t),s=xt.set(e,o),l=o.events))for(i in delete s.handle,s.events={},l)for(n=0,r=l[i].length;n<r;n++)Et.event.add(e,i,l[i][n]);wt.hasData(t)&&(a=wt.access(t),u=Et.extend({},a),wt.set(e,u))}}function y(t,e){var n=t.getElementsByTagName?t.getElementsByTagName(e||"*"):t.querySelectorAll?t.querySelectorAll(e||"*"):[];return e===k||e&&Et.nodeName(t,e)?Et.merge([t],n):n}function f(t,e){var n=e.nodeName.toLowerCase();"input"===n&&It.test(t.type)?e.checked=t.checked:"input"!==n&&"textarea"!==n||(e.defaultValue=t.defaultValue)}function p(t,e){if(e in t)return e;for(var n=e.charAt(0).toUpperCase()+e.slice(1),r=e,i=oe.length;i--;)if((e=oe[i]+n)in t)return e;return r}function b(t,e){return t=e||t,"none"===Et.css(t,"display")||!Et.contains(t.ownerDocument,t)}function w(t){return d.getComputedStyle(t,null)}function s(t,e){for(var n,r,i,o=[],s=0,a=t.length;s<a;s++)(r=t[s]).style&&(o[s]=xt.get(r,"olddisplay"),n=r.style.display,e?(o[s]||"none"!==n||(r.style.display=""),""===r.style.display&&b(r)&&(o[s]=xt.access(r,"olddisplay",_(r.nodeName)))):o[s]||(i=b(r),(n&&"none"!==n||!i)&&xt.set(r,"olddisplay",i?n:Et.css(r,"display"))));for(s=0;s<a;s++)(r=t[s]).style&&(e&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=e?o[s]||"":"none"));return t}function x(t,e,n){var r=Kt.exec(e);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):e}function C(t,e,n,r,i){for(var o=n===(r?"border":"content")?4:"width"===e?1:0,s=0;o<4;o+=2)"margin"===n&&(s+=Et.css(t,n+ie[o],!0,i)),r?("content"===n&&(s-=Et.css(t,"padding"+ie[o],!0,i)),"margin"!==n&&(s-=Et.css(t,"border"+ie[o]+"Width",!0,i))):(s+=Et.css(t,"padding"+ie[o],!0,i),"padding"!==n&&(s+=Et.css(t,"border"+ie[o]+"Width",!0,i)));return s}function T(t,e,n){var r=!0,i="width"===e?t.offsetWidth:t.offsetHeight,o=w(t),s=Et.support.boxSizing&&"border-box"===Et.css(t,"boxSizing",!1,o);if(i<=0||null==i){if(((i=Xt(t,e,o))<0||null==i)&&(i=t.style[e]),Zt.test(i))return i;r=s&&(Et.support.boxSizingReliable||i===t.style[e]),i=parseFloat(i)||0}return i+C(t,e,n||(s?"border":"content"),r,o)+"px"}function _(t){var e=U,n=ee[t];return n||("none"!==(n=N(t,e))&&n||((e=((Gt=(Gt||Et("<iframe frameborder='0' width='0' height='0'/>").css("cssText","display:block !important")).appendTo(e.documentElement))[0].contentWindow||Gt[0].contentDocument).document).write("<!doctype html><html><body>"),e.close(),n=N(t,e),Gt.detach()),ee[t]=n),n}function N(t,e){var n=Et(e.createElement(t)).appendTo(e.body),r=Et.css(n[0],"display");return n.remove(),r}function S(n,t,r,i){var e;if(Et.isArray(t))Et.each(t,function(t,e){r||ae.test(n)?i(n,e):S(n+"["+("object"==typeof e?t:"")+"]",e,r,i)});else if(r||"object"!==Et.type(t))i(n,t);else for(e in t)S(n+"["+e+"]",t[e],r,i)}function $(o){return function(t,e){"string"!=typeof t&&(e=t,t="*");var n,r=0,i=t.toLowerCase().match(st)||[];if(Et.isFunction(e))for(;n=i[r++];)"+"===n[0]?(n=n.slice(1)||"*",(o[n]=o[n]||[]).unshift(e)):(o[n]=o[n]||[]).push(e)}}function E(e,i,o,s){function a(t){var r;return u[t]=!0,Et.each(e[t]||[],function(t,e){var n=e(i,o,s);return"string"!=typeof n||l||u[n]?l?!(r=n):void 0:(i.dataTypes.unshift(n),a(n),!1)}),r}var u={},l=e===Te;return a(i.dataTypes[0])||!u["*"]&&a("*")}function j(t,e){var n,r,i=Et.ajaxSettings.flatOptions||{};for(n in e)e[n]!==k&&((i[n]?t:r||(r={}))[n]=e[n]);return r&&Et.extend(!0,t,r),t}function M(t,e,n){for(var r,i,o,s,a=t.contents,u=t.dataTypes;"*"===u[0];)u.shift(),r===k&&(r=t.mimeType||e.getResponseHeader("Content-Type"));if(r)for(i in a)if(a[i]&&a[i].test(r)){u.unshift(i);break}if(u[0]in n)o=u[0];else{for(i in n){if(!u[0]||t.converters[i+" "+u[0]]){o=i;break}s||(s=i)}o=o||s}if(o)return o!==u[0]&&u.unshift(o),n[o]}function D(t,e,n,r){var i,o,s,a,u,l={},c=t.dataTypes.slice();if(c[1])for(s in t.converters)l[s.toLowerCase()]=t.converters[s];for(o=c.shift();o;)if(t.responseFields[o]&&(n[t.responseFields[o]]=e),!u&&r&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(!(s=l[u+" "+o]||l["* "+o]))for(i in l)if((a=i.split(" "))[1]===o&&(s=l[u+" "+a[0]]||l["* "+a[0]])){!0===s?s=l[i]:!0!==l[i]&&(o=a[0],c.unshift(a[1]));break}if(!0!==s)if(s&&t["throws"])e=s(e);else try{e=s(e)}catch(h){return{state:"parsererror",error:s?h:"No conversion from "+u+" to "+o}}}return{state:"success",data:e}}function A(){return setTimeout(function(){De=k}),De=Et.now()}function O(t,e,n){for(var r,i=(He[e]||[]).concat(He["*"]),o=0,s=i.length;o<s;o++)if(r=i[o].call(n,e,t))return r}function R(o,t,e){var n,s,r=0,i=Le.length,a=Et.Deferred().always(function(){delete u.elem}),u=function(){if(s)return!1;for(var t=De||A(),e=Math.max(0,l.startTime+l.duration-t),n=1-(e/l.duration||0),r=0,i=l.tweens.length;r<i;r++)l.tweens[r].run(n);return a.notifyWith(o,[l,n,e]),n<1&&i?e:(a.resolveWith(o,[l]),!1)},l=a.promise({elem:o,props:Et.extend({},t),opts:Et.extend(!0,{specialEasing:{}},e),originalProperties:t,originalOptions:e,startTime:De||A(),duration:e.duration,tweens:[],createTween:function(t,e){var n=Et.Tween(o,l.opts,t,e,l.opts.specialEasing[t]||l.opts.easing);return l.tweens.push(n),n},stop:function(t){var e=0,n=t?l.tweens.length:0;if(s)return this;for(s=!0;e<n;e++)l.tweens[e].run(1);return t?a.resolveWith(o,[l,t]):a.rejectWith(o,[l,t]),this}}),c=l.props;for(P(c,l.opts.specialEasing);r<i;r++)if(n=Le[r].call(l,o,c,l.opts))return n;return Et.map(c,O,l),Et.isFunction(l.opts.start)&&l.opts.start.call(o,l),Et.fx.timer(Et.extend(u,{elem:o,anim:l,queue:l.opts.queue})),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always)}function P(t,e){var n,r,i,o,s;for(n in t)if(i=e[r=Et.camelCase(n)],o=t[n],Et.isArray(o)&&(i=o[1],o=t[n]=o[0]),n!==r&&(t[r]=o,delete t[n]),(s=Et.cssHooks[r])&&"expand"in s)for(n in o=s.expand(o),delete t[r],o)n in t||(t[n]=o[n],e[n]=i);else e[r]=i}function L(e,t,n){var r,i,o,s,a,u,l=this,c={},h=e.style,f=e.nodeType&&b(e),p=xt.get(e,"fxshow");for(r in n.queue||(null==(a=Et._queueHooks(e,"fx")).unqueued&&(a.unqueued=0,u=a.empty.fire,a.empty.fire=function(){a.unqueued||u()}),a.unqueued++,l.always(function(){l.always(function(){a.unqueued--,Et.queue(e,"fx").length||a.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],"inline"===Et.css(e,"display")&&"none"===Et.css(e,"float")&&(h.display="inline-block")),n.overflow&&(h.overflow="hidden",l.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),t)if(i=t[r],Oe.exec(i)){if(delete t[r],o=o||"toggle"===i,i===(f?"hide":"show")){if("show"!==i||!p||p[r]===k)continue;f=!0}c[r]=p&&p[r]||Et.style(e,r)}if(!Et.isEmptyObject(c))for(r in p?"hidden"in p&&(f=p.hidden):p=xt.access(e,"fxshow",{}),o&&(p.hidden=!f),f?Et(e).show():l.done(function(){Et(e).hide()}),l.done(function(){var t;for(t in xt.remove(e,"fxshow"),c)Et.style(e,t,c[t])}),c)s=O(f?p[r]:0,r,l),r in p||(p[r]=s.start,f&&(s.end=s.start,s.start="width"===r||"height"===r?1:0))}function H(t,e,n,r,i){return new H.prototype.init(t,e,n,r,i)}function z(t,e){var n,r={height:t},i=0;for(e=e?1:0;i<4;i+=2-e)r["margin"+(n=ie[i])]=r["padding"+n]=t;return e&&(r.opacity=r.width=t),r}function q(t){return Et.isWindow(t)?t:9===t.nodeType&&t.defaultView}var F,I,B=typeof k,W=d.location,U=d.document,J=U.documentElement,V=d.jQuery,X=d.$,G={},Y=[],Q="2.0.2",K=Y.concat,Z=Y.push,tt=Y.slice,et=Y.indexOf,nt=G.toString,rt=G.hasOwnProperty,it=Q.trim,Et=function(t,e){return new Et.fn.init(t,e,F)},ot=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,st=/\S+/g,at=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,ut=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,lt=/^-ms-/,ct=/-([\da-z])/gi,ht=function(t,e){return e.toUpperCase()},ft=function(){U.removeEventListener("DOMContentLoaded",ft,!1),d.removeEventListener("load",ft,!1),Et.ready()};Et.fn=Et.prototype={jquery:Q,constructor:Et,init:function(t,e,n){var r,i;if(!t)return this;if("string"!=typeof t)return t.nodeType?(this.context=this[0]=t,this.length=1,this):Et.isFunction(t)?n.ready(t):(t.selector!==k&&(this.selector=t.selector,this.context=t.context),Et.makeArray(t,this));if(!(r="<"===t.charAt(0)&&">"===t.charAt(t.length-1)&&3<=t.length?[null,t,null]:at.exec(t))||!r[1]&&e)return!e||e.jquery?(e||n).find(t):this.constructor(e).find(t);if(r[1]){if(e=e instanceof Et?e[0]:e,Et.merge(this,Et.parseHTML(r[1],e&&e.nodeType?e.ownerDocument||e:U,!0)),ut.test(r[1])&&Et.isPlainObject(e))for(r in e)Et.isFunction(this[r])?this[r](e[r]):this.attr(r,e[r]);return this}return(i=U.getElementById(r[2]))&&i.parentNode&&(this.length=1,this[0]=i),this.context=U,this.selector=t,this},selector:"",length:0,toArray:function(){return tt.call(this)},get:function(t){return null==t?this.toArray():t<0?this[this.length+t]:this[t]},pushStack:function(t){var e=Et.merge(this.constructor(),t);return e.prevObject=this,e.context=this.context,e},each:function(t,e){return Et.each(this,t,e)},ready:function(t){return Et.ready.promise().done(t),this},slice:function(){return this.pushStack(tt.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(t){var e=this.length,n=+t+(t<0?e:0);return this.pushStack(0<=n&&n<e?[this[n]]:[])},map:function(n){return this.pushStack(Et.map(this,function(t,e){return n.call(t,e,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:Z,sort:[].sort,splice:[].splice},Et.fn.init.prototype=Et.fn,Et.extend=Et.fn.extend=function(t,e){var n,r,i,o,s,a,u=t||{},l=1,c=arguments.length,h=!1;for("boolean"==typeof u&&(h=u,u=e||{},l=2),"object"==typeof u||Et.isFunction(u)||(u={}),c===l&&(u=this,--l);l<c;l++)if(null!=(n=arguments[l]))for(r in n)i=u[r],u!==(o=n[r])&&(h&&o&&(Et.isPlainObject(o)||(s=Et.isArray(o)))?(a=s?(s=!1,i&&Et.isArray(i)?i:[]):i&&Et.isPlainObject(i)?i:{},u[r]=Et.extend(h,a,o)):o!==k&&(u[r]=o));return u},Et.extend({expando:"jQuery"+(Q+Math.random()).replace(/\D/g,""),noConflict:function(t){return d.$===Et&&(d.$=X),t&&d.jQuery===Et&&(d.jQuery=V),Et},isReady:!1,readyWait:1,holdReady:function(t){t?Et.readyWait++:Et.ready(!0)},ready:function(t){(!0===t?--Et.readyWait:Et.isReady)||(Et.isReady=!0)!==t&&0<--Et.readyWait||(I.resolveWith(U,[Et]),Et.fn.trigger&&Et(U).trigger("ready").off("ready"))},isFunction:function(t){return"function"===Et.type(t)},isArray:Array.isArray,isWindow:function(t){return null!=t&&t===t.window},isNumeric:function(t){return!isNaN(parseFloat(t))&&isFinite(t)},type:function(t){return null==t?String(t):"object"==typeof t||"function"==typeof t?G[nt.call(t)]||"object":typeof t},isPlainObject:function(t){if("object"!==Et.type(t)||t.nodeType||Et.isWindow(t))return!1;try{if(t.constructor&&!rt.call(t.constructor.prototype,"isPrototypeOf"))return!1}catch(e){return!1}return!0},isEmptyObject:function(t){var e;for(e in t)return!1;return!0},error:function(t){throw new Error(t)},parseHTML:function(t,e,n){if(!t||"string"!=typeof t)return null;"boolean"==typeof e&&(n=e,e=!1),e=e||U;var r=ut.exec(t),i=!n&&[];return r?[e.createElement(r[1])]:(r=Et.buildFragment([t],e,i),i&&Et(i).remove(),Et.merge([],r.childNodes))},parseJSON:JSON.parse,parseXML:function(t){var e;if(!t||"string"!=typeof t)return null;try{e=(new DOMParser).parseFromString(t,"text/xml")}catch(n){e=k}return e&&!e.getElementsByTagName("parsererror").length||Et.error("Invalid XML: "+t),e},noop:function(){},globalEval:function(t){var e,n=eval;(t=Et.trim(t))&&(1===t.indexOf("use strict")?((e=U.createElement("script")).text=t,U.head.appendChild(e).parentNode.removeChild(e)):n(t))},camelCase:function(t){return t.replace(lt,"ms-").replace(ct,ht)},nodeName:function(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()},each:function(t,e,n){var r=0,i=t.length,o=a(t);if(n){if(o)for(;r<i&&!1!==e.apply(t[r],n);r++);else for(r in t)if(!1===e.apply(t[r],n))break}else if(o)for(;r<i&&!1!==e.call(t[r],r,t[r]);r++);else for(r in t)if(!1===e.call(t[r],r,t[r]))break;return t},trim:function(t){return null==t?"":it.call(t)},makeArray:function(t,e){var n=e||[];return null!=t&&(a(Object(t))?Et.merge(n,"string"==typeof t?[t]:t):Z.call(n,t)),n},inArray:function(t,e,n){return null==e?-1:et.call(e,t,n)},merge:function(t,e){var n=e.length,r=t.length,i=0;if("number"==typeof n)for(;i<n;i++)t[r++]=e[i];else for(;e[i]!==k;)t[r++]=e[i++];return t.length=r,t},grep:function(t,e,n){var r=[],i=0,o=t.length;for(n=!!n;i<o;i++)n!==!!e(t[i],i)&&r.push(t[i]);return r},map:function(t,e,n){var r,i=0,o=t.length,s=[];if(a(t))for(;i<o;i++)null!=(r=e(t[i],i,n))&&(s[s.length]=r);else for(i in t)null!=(r=e(t[i],i,n))&&(s[s.length]=r);return K.apply([],s)},guid:1,proxy:function(t,e){var n,r,i;return"string"==typeof e&&(n=t[e],e=t,t=n),Et.isFunction(t)?(r=tt.call(arguments,2),(i=function(){return t.apply(e||this,r.concat(tt.call(arguments)))}).guid=t.guid=t.guid||Et.guid++,i):k},access:function(t,e,n,r,i,o,s){var a=0,u=t.length,l=null==n;if("object"===Et.type(n))for(a in i=!0,n)Et.access(t,e,a,n[a],!0,o,s);else if(r!==k&&(i=!0,Et.isFunction(r)||(s=!0),l&&(e=s?(e.call(t,r),null):(l=e,function(t,e,n){return l.call(Et(t),n)})),e))for(;a<u;a++)e(t[a],n,s?r:r.call(t[a],a,e(t[a],n)));return i?t:l?e.call(t):u?e(t[0],n):o},now:Date.now,swap:function(t,e,n,r){var i,o,s={};for(o in e)s[o]=t.style[o],t.style[o]=e[o];for(o in i=n.apply(t,r||[]),e)t.style[o]=s[o];return i}}),Et.ready.promise=function(t){return I||(I=Et.Deferred(),"complete"===U.readyState?setTimeout(Et.ready):(U.addEventListener("DOMContentLoaded",ft,!1),d.addEventListener("load",ft,!1))),I.promise(t)},Et.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(t,e){G["[object "+e+"]"]=e.toLowerCase()}),F=Et(U),
|
15
|
+
/*!
|
15
16
|
* Sizzle CSS Selector Engine v1.9.4-pre
|
16
17
|
* http://sizzlejs.com/
|
17
18
|
*
|
@@ -21,243 +22,9 @@
|
|
21
22
|
*
|
22
23
|
* Date: 2013-05-27
|
23
24
|
*/
|
24
|
-
function(t,e){function n(t,e,n,r){var i,o,s,a,u,l,c,h,f,p;if((e?e.ownerDocument||e:W)!==P&&R(e),e=e||P,n=n||[],!t||"string"!=typeof t)return n;if(1!==(a=e.nodeType)&&9!==a)return[];if(H&&!r){if(i=kt.exec(t))if(s=i[1]){if(9===a){if(o=e.getElementById(s),!o||!o.parentNode)return n;if(o.id===s)return n.push(o),n}else if(e.ownerDocument&&(o=e.ownerDocument.getElementById(s))&&I(e,o)&&o.id===s)return n.push(o),n}else{if(i[2])return it.apply(n,e.getElementsByTagName(t)),n;if((s=i[3])&&S.getElementsByClassName&&e.getElementsByClassName)return it.apply(n,e.getElementsByClassName(s)),n}if(S.qsa&&(!z||!z.test(t))){if(h=c=B,f=e,p=9===a&&t,1===a&&"object"!==e.nodeName.toLowerCase()){for(l=m(t),(c=e.getAttribute("id"))?h=c.replace(Nt,"\\$&"):e.setAttribute("id",h),h="[id='"+h+"'] ",u=l.length;u--;)l[u]=h+g(l[u]);f=vt.test(t)&&e.parentNode||e,p=l.join(",")}if(p)try{return it.apply(n,f.querySelectorAll(p)),n}catch(d){}finally{c||e.removeAttribute("id")}}}return T(t.replace(dt,"$1"),e,n,r)}function r(t){return Ct.test(t+"")}function i(){function t(n,r){return e.push(n+=" ")>E.cacheLength&&delete t[e.shift()],t[n]=r}var e=[];return t}function o(t){return t[B]=!0,t}function s(t){var e=P.createElement("div");try{return!!t(e)}catch(n){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function a(t,e,n){t=t.split("|");for(var r,i=t.length,o=n?null:e;i--;)(r=E.attrHandle[t[i]])&&r!==e||(E.attrHandle[t[i]]=o)}function u(t,e){var n=t.getAttributeNode(e);return n&&n.specified?n.value:t[e]===!0?e.toLowerCase():null}function l(t,e){return t.getAttribute(e,"type"===e.toLowerCase()?1:2)}function c(t){return"input"===t.nodeName.toLowerCase()?t.defaultValue:void 0}function h(t,e){var n=e&&t,r=n&&1===t.nodeType&&1===e.nodeType&&(~e.sourceIndex||Z)-(~t.sourceIndex||Z);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===e)return-1;return t?1:-1}function f(t){return function(e){var n=e.nodeName.toLowerCase();return"input"===n&&e.type===t}}function p(t){return function(e){var n=e.nodeName.toLowerCase();return("input"===n||"button"===n)&&e.type===t}}function d(t){return o(function(e){return e=+e,o(function(n,r){for(var i,o=t([],n.length,e),s=o.length;s--;)n[i=o[s]]&&(n[i]=!(r[i]=n[i]))})})}function m(t,e){var r,i,o,s,a,u,l,c=X[t+" "];if(c)return e?0:c.slice(0);for(a=t,u=[],l=E.preFilter;a;){(!r||(i=mt.exec(a)))&&(i&&(a=a.slice(i[0].length)||a),u.push(o=[])),r=!1,(i=gt.exec(a))&&(r=i.shift(),o.push({value:r,type:i[0].replace(dt," ")}),a=a.slice(r.length));for(s in E.filter)!(i=xt[s].exec(a))||l[s]&&!(i=l[s](i))||(r=i.shift(),o.push({value:r,type:s,matches:i}),a=a.slice(r.length));if(!r)break}return e?a.length:a?n.error(t):X(t,u).slice(0)}function g(t){for(var e=0,n=t.length,r="";n>e;e++)r+=t[e].value;return r}function v(t,e,n){var r=e.dir,i=n&&"parentNode"===r,o=J++;return e.first?function(e,n,o){for(;e=e[r];)if(1===e.nodeType||i)return t(e,n,o)}:function(e,n,s){var a,u,l,c=U+" "+o;if(s){for(;e=e[r];)if((1===e.nodeType||i)&&t(e,n,s))return!0}else for(;e=e[r];)if(1===e.nodeType||i)if(l=e[B]||(e[B]={}),(u=l[r])&&u[0]===c){if((a=u[1])===!0||a===$)return a===!0}else if(u=l[r]=[c],u[1]=t(e,n,s)||$,u[1]===!0)return!0}}function y(t){return t.length>1?function(e,n,r){for(var i=t.length;i--;)if(!t[i](e,n,r))return!1;return!0}:t[0]}function b(t,e,n,r,i){for(var o,s=[],a=0,u=t.length,l=null!=e;u>a;a++)(o=t[a])&&(!n||n(o,r,i))&&(s.push(o),l&&e.push(a));return s}function w(t,e,n,r,i,s){return r&&!r[B]&&(r=w(r)),i&&!i[B]&&(i=w(i,s)),o(function(o,s,a,u){var l,c,h,f=[],p=[],d=s.length,m=o||k(e||"*",a.nodeType?[a]:a,[]),g=!t||!o&&e?m:b(m,f,t,a,u),v=n?i||(o?t:d||r)?[]:s:g;if(n&&n(g,v,a,u),r)for(l=b(v,p),r(l,[],a,u),c=l.length;c--;)(h=l[c])&&(v[p[c]]=!(g[p[c]]=h));if(o){if(i||t){if(i){for(l=[],c=v.length;c--;)(h=v[c])&&l.push(g[c]=h);i(null,v=[],l,u)}for(c=v.length;c--;)(h=v[c])&&(l=i?at.call(o,h):f[c])>-1&&(o[l]=!(s[l]=h))}}else v=b(v===s?v.splice(d,v.length):v),i?i(null,s,v,u):it.apply(s,v)})}function x(t){for(var e,n,r,i=t.length,o=E.relative[t[0].type],s=o||E.relative[" "],a=o?1:0,u=v(function(t){return t===e},s,!0),l=v(function(t){return at.call(e,t)>-1},s,!0),c=[function(t,n,r){return!o&&(r||n!==A)||((e=n).nodeType?u(t,n,r):l(t,n,r))}];i>a;a++)if(n=E.relative[t[a].type])c=[v(y(c),n)];else{if(n=E.filter[t[a].type].apply(null,t[a].matches),n[B]){for(r=++a;i>r&&!E.relative[t[r].type];r++);return w(a>1&&y(c),a>1&&g(t.slice(0,a-1).concat({value:" "===t[a-2].type?"*":""})).replace(dt,"$1"),n,r>a&&x(t.slice(a,r)),i>r&&x(t=t.slice(r)),i>r&&g(t))}c.push(n)}return y(c)}function C(t,e){var r=0,i=e.length>0,s=t.length>0,a=function(o,a,u,l,c){var h,f,p,d=[],m=0,g="0",v=o&&[],y=null!=c,w=A,x=o||s&&E.find.TAG("*",c&&a.parentNode||a),C=U+=null==w?1:Math.random()||.1;for(y&&(A=a!==P&&a,$=r);null!=(h=x[g]);g++){if(s&&h){for(f=0;p=t[f++];)if(p(h,a,u)){l.push(h);break}y&&(U=C,$=++r)}i&&((h=!p&&h)&&m--,o&&v.push(h))}if(m+=g,i&&g!==m){for(f=0;p=e[f++];)p(v,d,a,u);if(o){if(m>0)for(;g--;)v[g]||d[g]||(d[g]=nt.call(l));d=b(d)}it.apply(l,d),y&&!o&&d.length>0&&m+e.length>1&&n.uniqueSort(l)}return y&&(U=C,A=w),v};return i?o(a):a}function k(t,e,r){for(var i=0,o=e.length;o>i;i++)n(t,e[i],r);return r}function T(t,e,n,r){var i,o,s,a,u,l=m(t);if(!r&&1===l.length){if(o=l[0]=l[0].slice(0),o.length>2&&"ID"===(s=o[0]).type&&S.getById&&9===e.nodeType&&H&&E.relative[o[1].type]){if(e=(E.find.ID(s.matches[0].replace(St,$t),e)||[])[0],!e)return n;t=t.slice(o.shift().value.length)}for(i=xt.needsContext.test(t)?0:o.length;i--&&(s=o[i],!E.relative[a=s.type]);)if((u=E.find[a])&&(r=u(s.matches[0].replace(St,$t),vt.test(o[0].type)&&e.parentNode||e))){if(o.splice(i,1),t=r.length&&g(o),!t)return it.apply(n,r),n;break}}return D(t,l)(r,e,!H,n,vt.test(t)),n}function _(){}var N,S,$,E,j,M,D,A,O,R,P,L,H,z,q,F,I,B="sizzle"+-new Date,W=t.document,U=0,J=0,V=i(),X=i(),G=i(),Y=!1,Q=function(){return 0},K=typeof e,Z=1<<31,tt={}.hasOwnProperty,et=[],nt=et.pop,rt=et.push,it=et.push,st=et.slice,at=et.indexOf||function(t){for(var e=0,n=this.length;n>e;e++)if(this[e]===t)return e;return-1},ut="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",lt="[\\x20\\t\\r\\n\\f]",ct="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",ht=ct.replace("w","w#"),ft="\\["+lt+"*("+ct+")"+lt+"*(?:([*^$|!~]?=)"+lt+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+ht+")|)|)"+lt+"*\\]",pt=":("+ct+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+ft.replace(3,8)+")*)|.*)\\)|)",dt=new RegExp("^"+lt+"+|((?:^|[^\\\\])(?:\\\\.)*)"+lt+"+$","g"),mt=new RegExp("^"+lt+"*,"+lt+"*"),gt=new RegExp("^"+lt+"*([>+~]|"+lt+")"+lt+"*"),vt=new RegExp(lt+"*[+~]"),yt=new RegExp("="+lt+"*([^\\]'\"]*)"+lt+"*\\]","g"),bt=new RegExp(pt),wt=new RegExp("^"+ht+"$"),xt={ID:new RegExp("^#("+ct+")"),CLASS:new RegExp("^\\.("+ct+")"),TAG:new RegExp("^("+ct.replace("w","w*")+")"),ATTR:new RegExp("^"+ft),PSEUDO:new RegExp("^"+pt),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+lt+"*(even|odd|(([+-]|)(\\d*)n|)"+lt+"*(?:([+-]|)"+lt+"*(\\d+)|))"+lt+"*\\)|)","i"),bool:new RegExp("^(?:"+ut+")$","i"),needsContext:new RegExp("^"+lt+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+lt+"*((?:-\\d)?\\d*)"+lt+"*\\)|)(?=[^-]|$)","i")},Ct=/^[^{]+\{\s*\[native \w/,kt=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,Tt=/^(?:input|select|textarea|button)$/i,_t=/^h\d$/i,Nt=/'|\\/g,St=new RegExp("\\\\([\\da-f]{1,6}"+lt+"?|("+lt+")|.)","ig"),$t=function(t,e,n){var r="0x"+e-65536;return r!==r||n?e:0>r?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)};try{it.apply(et=st.call(W.childNodes),W.childNodes),et[W.childNodes.length].nodeType}catch(Et){it={apply:et.length?function(t,e){rt.apply(t,st.call(e))}:function(t,e){for(var n=t.length,r=0;t[n++]=e[r++];);t.length=n-1}}}M=n.isXML=function(t){var e=t&&(t.ownerDocument||t).documentElement;return e?"HTML"!==e.nodeName:!1},S=n.support={},R=n.setDocument=function(t){var e=t?t.ownerDocument||t:W,n=e.parentWindow;return e!==P&&9===e.nodeType&&e.documentElement?(P=e,L=e.documentElement,H=!M(e),n&&n.frameElement&&n.attachEvent("onbeforeunload",function(){R()}),S.attributes=s(function(t){return t.innerHTML="<a href='#'></a>",a("type|href|height|width",l,"#"===t.firstChild.getAttribute("href")),a(ut,u,null==t.getAttribute("disabled")),t.className="i",!t.getAttribute("className")}),S.input=s(function(t){return t.innerHTML="<input>",t.firstChild.setAttribute("value",""),""===t.firstChild.getAttribute("value")}),a("value",c,S.attributes&&S.input),S.getElementsByTagName=s(function(t){return t.appendChild(e.createComment("")),!t.getElementsByTagName("*").length}),S.getElementsByClassName=s(function(t){return t.innerHTML="<div class='a'></div><div class='a i'></div>",t.firstChild.className="i",2===t.getElementsByClassName("i").length}),S.getById=s(function(t){return L.appendChild(t).id=B,!e.getElementsByName||!e.getElementsByName(B).length}),S.getById?(E.find.ID=function(t,e){if(typeof e.getElementById!==K&&H){var n=e.getElementById(t);return n&&n.parentNode?[n]:[]}},E.filter.ID=function(t){var e=t.replace(St,$t);return function(t){return t.getAttribute("id")===e}}):(delete E.find.ID,E.filter.ID=function(t){var e=t.replace(St,$t);return function(t){var n=typeof t.getAttributeNode!==K&&t.getAttributeNode("id");return n&&n.value===e}}),E.find.TAG=S.getElementsByTagName?function(t,e){return typeof e.getElementsByTagName!==K?e.getElementsByTagName(t):void 0}:function(t,e){var n,r=[],i=0,o=e.getElementsByTagName(t);if("*"===t){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},E.find.CLASS=S.getElementsByClassName&&function(t,e){return typeof e.getElementsByClassName!==K&&H?e.getElementsByClassName(t):void 0},q=[],z=[],(S.qsa=r(e.querySelectorAll))&&(s(function(t){t.innerHTML="<select><option selected=''></option></select>",t.querySelectorAll("[selected]").length||z.push("\\["+lt+"*(?:value|"+ut+")"),t.querySelectorAll(":checked").length||z.push(":checked")}),s(function(t){var n=e.createElement("input");n.setAttribute("type","hidden"),t.appendChild(n).setAttribute("t",""),t.querySelectorAll("[t^='']").length&&z.push("[*^$]="+lt+"*(?:''|\"\")"),t.querySelectorAll(":enabled").length||z.push(":enabled",":disabled"),t.querySelectorAll("*,:x"),z.push(",.*:")})),(S.matchesSelector=r(F=L.webkitMatchesSelector||L.mozMatchesSelector||L.oMatchesSelector||L.msMatchesSelector))&&s(function(t){S.disconnectedMatch=F.call(t,"div"),F.call(t,"[s!='']:x"),q.push("!=",pt)}),z=z.length&&new RegExp(z.join("|")),q=q.length&&new RegExp(q.join("|")),I=r(L.contains)||L.compareDocumentPosition?function(t,e){var n=9===t.nodeType?t.documentElement:t,r=e&&e.parentNode;return t===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):t.compareDocumentPosition&&16&t.compareDocumentPosition(r)))}:function(t,e){if(e)for(;e=e.parentNode;)if(e===t)return!0;return!1},S.sortDetached=s(function(t){return 1&t.compareDocumentPosition(e.createElement("div"))}),Q=L.compareDocumentPosition?function(t,n){if(t===n)return Y=!0,0;var r=n.compareDocumentPosition&&t.compareDocumentPosition&&t.compareDocumentPosition(n);return r?1&r||!S.sortDetached&&n.compareDocumentPosition(t)===r?t===e||I(W,t)?-1:n===e||I(W,n)?1:O?at.call(O,t)-at.call(O,n):0:4&r?-1:1:t.compareDocumentPosition?-1:1}:function(t,n){var r,i=0,o=t.parentNode,s=n.parentNode,a=[t],u=[n];if(t===n)return Y=!0,0;if(!o||!s)return t===e?-1:n===e?1:o?-1:s?1:O?at.call(O,t)-at.call(O,n):0;if(o===s)return h(t,n);for(r=t;r=r.parentNode;)a.unshift(r);for(r=n;r=r.parentNode;)u.unshift(r);for(;a[i]===u[i];)i++;return i?h(a[i],u[i]):a[i]===W?-1:u[i]===W?1:0},e):P},n.matches=function(t,e){return n(t,null,null,e)},n.matchesSelector=function(t,e){if((t.ownerDocument||t)!==P&&R(t),e=e.replace(yt,"='$1']"),S.matchesSelector&&H&&(!q||!q.test(e))&&(!z||!z.test(e)))try{var r=F.call(t,e);if(r||S.disconnectedMatch||t.document&&11!==t.document.nodeType)return r}catch(i){}return n(e,P,null,[t]).length>0},n.contains=function(t,e){return(t.ownerDocument||t)!==P&&R(t),I(t,e)},n.attr=function(t,n){(t.ownerDocument||t)!==P&&R(t);var r=E.attrHandle[n.toLowerCase()],i=r&&tt.call(E.attrHandle,n.toLowerCase())?r(t,n,!H):e;return i===e?S.attributes||!H?t.getAttribute(n):(i=t.getAttributeNode(n))&&i.specified?i.value:null:i},n.error=function(t){throw new Error("Syntax error, unrecognized expression: "+t)},n.uniqueSort=function(t){var e,n=[],r=0,i=0;if(Y=!S.detectDuplicates,O=!S.sortStable&&t.slice(0),t.sort(Q),Y){for(;e=t[i++];)e===t[i]&&(r=n.push(i));for(;r--;)t.splice(n[r],1)}return t},j=n.getText=function(t){var e,n="",r=0,i=t.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof t.textContent)return t.textContent;for(t=t.firstChild;t;t=t.nextSibling)n+=j(t)}else if(3===i||4===i)return t.nodeValue}else for(;e=t[r];r++)n+=j(e);return n},E=n.selectors={cacheLength:50,createPseudo:o,match:xt,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(t){return t[1]=t[1].replace(St,$t),t[3]=(t[4]||t[5]||"").replace(St,$t),"~="===t[2]&&(t[3]=" "+t[3]+" "),t.slice(0,4)},CHILD:function(t){return t[1]=t[1].toLowerCase(),"nth"===t[1].slice(0,3)?(t[3]||n.error(t[0]),t[4]=+(t[4]?t[5]+(t[6]||1):2*("even"===t[3]||"odd"===t[3])),t[5]=+(t[7]+t[8]||"odd"===t[3])):t[3]&&n.error(t[0]),t},PSEUDO:function(t){var n,r=!t[5]&&t[2];return xt.CHILD.test(t[0])?null:(t[3]&&t[4]!==e?t[2]=t[4]:r&&bt.test(r)&&(n=m(r,!0))&&(n=r.indexOf(")",r.length-n)-r.length)&&(t[0]=t[0].slice(0,n),t[2]=r.slice(0,n)),t.slice(0,3))}},filter:{TAG:function(t){var e=t.replace(St,$t).toLowerCase();return"*"===t?function(){return!0}:function(t){return t.nodeName&&t.nodeName.toLowerCase()===e}},CLASS:function(t){var e=V[t+" "];return e||(e=new RegExp("(^|"+lt+")"+t+"("+lt+"|$)"))&&V(t,function(t){return e.test("string"==typeof t.className&&t.className||typeof t.getAttribute!==K&&t.getAttribute("class")||"")})},ATTR:function(t,e,r){return function(i){var o=n.attr(i,t);return null==o?"!="===e:e?(o+="","="===e?o===r:"!="===e?o!==r:"^="===e?r&&0===o.indexOf(r):"*="===e?r&&o.indexOf(r)>-1:"$="===e?r&&o.slice(-r.length)===r:"~="===e?(" "+o+" ").indexOf(r)>-1:"|="===e?o===r||o.slice(0,r.length+1)===r+"-":!1):!0}},CHILD:function(t,e,n,r,i){var o="nth"!==t.slice(0,3),s="last"!==t.slice(-4),a="of-type"===e;return 1===r&&0===i?function(t){return!!t.parentNode}:function(e,n,u){var l,c,h,f,p,d,m=o!==s?"nextSibling":"previousSibling",g=e.parentNode,v=a&&e.nodeName.toLowerCase(),y=!u&&!a;if(g){if(o){for(;m;){for(h=e;h=h[m];)if(a?h.nodeName.toLowerCase()===v:1===h.nodeType)return!1;d=m="only"===t&&!d&&"nextSibling"}return!0}if(d=[s?g.firstChild:g.lastChild],s&&y){for(c=g[B]||(g[B]={}),l=c[t]||[],p=l[0]===U&&l[1],f=l[0]===U&&l[2],h=p&&g.childNodes[p];h=++p&&h&&h[m]||(f=p=0)||d.pop();)if(1===h.nodeType&&++f&&h===e){c[t]=[U,p,f];break}}else if(y&&(l=(e[B]||(e[B]={}))[t])&&l[0]===U)f=l[1];else for(;(h=++p&&h&&h[m]||(f=p=0)||d.pop())&&((a?h.nodeName.toLowerCase()!==v:1!==h.nodeType)||!++f||(y&&((h[B]||(h[B]={}))[t]=[U,f]),h!==e)););return f-=i,f===r||f%r===0&&f/r>=0}}},PSEUDO:function(t,e){var r,i=E.pseudos[t]||E.setFilters[t.toLowerCase()]||n.error("unsupported pseudo: "+t);return i[B]?i(e):i.length>1?(r=[t,t,"",e],E.setFilters.hasOwnProperty(t.toLowerCase())?o(function(t,n){for(var r,o=i(t,e),s=o.length;s--;)r=at.call(t,o[s]),t[r]=!(n[r]=o[s])}):function(t){return i(t,0,r)}):i}},pseudos:{not:o(function(t){var e=[],n=[],r=D(t.replace(dt,"$1"));return r[B]?o(function(t,e,n,i){for(var o,s=r(t,null,i,[]),a=t.length;a--;)(o=s[a])&&(t[a]=!(e[a]=o))}):function(t,i,o){return e[0]=t,r(e,null,o,n),!n.pop()}}),has:o(function(t){return function(e){return n(t,e).length>0}}),contains:o(function(t){return function(e){return(e.textContent||e.innerText||j(e)).indexOf(t)>-1}}),lang:o(function(t){return wt.test(t||"")||n.error("unsupported lang: "+t),t=t.replace(St,$t).toLowerCase(),function(e){var n;do if(n=H?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return n=n.toLowerCase(),n===t||0===n.indexOf(t+"-");while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var n=t.location&&t.location.hash;return n&&n.slice(1)===e.id},root:function(t){return t===L},focus:function(t){return t===P.activeElement&&(!P.hasFocus||P.hasFocus())&&!!(t.type||t.href||~t.tabIndex)},enabled:function(t){return t.disabled===!1},disabled:function(t){return t.disabled===!0},checked:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&!!t.checked||"option"===e&&!!t.selected},selected:function(t){return t.parentNode&&t.parentNode.selectedIndex,t.selected===!0},empty:function(t){for(t=t.firstChild;t;t=t.nextSibling)if(t.nodeName>"@"||3===t.nodeType||4===t.nodeType)return!1;return!0},parent:function(t){return!E.pseudos.empty(t)},header:function(t){return _t.test(t.nodeName)},input:function(t){return Tt.test(t.nodeName)},button:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&"button"===t.type||"button"===e},text:function(t){var e;return"input"===t.nodeName.toLowerCase()&&"text"===t.type&&(null==(e=t.getAttribute("type"))||e.toLowerCase()===t.type)},first:d(function(){return[0]}),last:d(function(t,e){return[e-1]}),eq:d(function(t,e,n){return[0>n?n+e:n]}),even:d(function(t,e){for(var n=0;e>n;n+=2)t.push(n);return t}),odd:d(function(t,e){for(var n=1;e>n;n+=2)t.push(n);return t}),lt:d(function(t,e,n){for(var r=0>n?n+e:n;--r>=0;)t.push(r);return t}),gt:d(function(t,e,n){for(var r=0>n?n+e:n;++r<e;)t.push(r);return t})}};for(N in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})E.pseudos[N]=f(N);for(N in{submit:!0,reset:!0})E.pseudos[N]=p(N);D=n.compile=function(t,e){var n,r=[],i=[],o=G[t+" "];if(!o){for(e||(e=m(t)),n=e.length;n--;)o=x(e[n]),o[B]?r.push(o):i.push(o);o=G(t,C(i,r))}return o},E.pseudos.nth=E.pseudos.eq,_.prototype=E.filters=E.pseudos,E.setFilters=new _,S.sortStable=B.split("").sort(Q).join("")===B,R(),[0,0].sort(Q),S.detectDuplicates=Y,ot.find=n,ot.expr=n.selectors,ot.expr[":"]=ot.expr.pseudos,ot.unique=n.uniqueSort,ot.text=n.getText,ot.isXMLDoc=n.isXML,ot.contains=n.contains}(t);var dt={};ot.Callbacks=function(t){t="string"==typeof t?dt[t]||r(t):ot.extend({},t);var n,i,o,s,a,u,l=[],c=!t.once&&[],h=function(e){for(n=t.memory&&e,i=!0,u=s||0,s=0,a=l.length,o=!0;l&&a>u;u++)if(l[u].apply(e[0],e[1])===!1&&t.stopOnFalse){n=!1;break}o=!1,l&&(c?c.length&&h(c.shift()):n?l=[]:f.disable())},f={add:function(){if(l){var e=l.length;!function r(e){ot.each(e,function(e,n){var i=ot.type(n);"function"===i?t.unique&&f.has(n)||l.push(n):n&&n.length&&"string"!==i&&r(n)})}(arguments),o?a=l.length:n&&(s=e,h(n))}return this},remove:function(){return l&&ot.each(arguments,function(t,e){for(var n;(n=ot.inArray(e,l,n))>-1;)l.splice(n,1),o&&(a>=n&&a--,u>=n&&u--)}),this},has:function(t){return t?ot.inArray(t,l)>-1:!(!l||!l.length)},empty:function(){return l=[],a=0,this},disable:function(){return l=c=n=e,this},disabled:function(){return!l},lock:function(){return c=e,n||f.disable(),this},locked:function(){return!c},fireWith:function(t,e){return e=e||[],e=[t,e.slice?e.slice():e],!l||i&&!c||(o?c.push(e):h(e)),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!i}};return f},ot.extend({Deferred:function(t){var e=[["resolve","done",ot.Callbacks("once memory"),"resolved"],["reject","fail",ot.Callbacks("once memory"),"rejected"],["notify","progress",ot.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var t=arguments;return ot.Deferred(function(n){ot.each(e,function(e,o){var s=o[0],a=ot.isFunction(t[e])&&t[e];i[o[1]](function(){var t=a&&a.apply(this,arguments);t&&ot.isFunction(t.promise)?t.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[s+"With"](this===r?n.promise():this,a?[t]:arguments)})}),t=null}).promise()},promise:function(t){return null!=t?ot.extend(t,r):r}},i={};return r.pipe=r.then,ot.each(e,function(t,o){var s=o[2],a=o[3];r[o[1]]=s.add,a&&s.add(function(){n=a},e[1^t][2].disable,e[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=s.fireWith}),r.promise(i),t&&t.call(i,i),i},when:function(t){var e,n,r,i=0,o=tt.call(arguments),s=o.length,a=1!==s||t&&ot.isFunction(t.promise)?s:0,u=1===a?t:ot.Deferred(),l=function(t,n,r){return function(i){n[t]=this,r[t]=arguments.length>1?tt.call(arguments):i,r===e?u.notifyWith(n,r):--a||u.resolveWith(n,r)}};if(s>1)for(e=new Array(s),n=new Array(s),r=new Array(s);s>i;i++)o[i]&&ot.isFunction(o[i].promise)?o[i].promise().done(l(i,r,o)).fail(u.reject).progress(l(i,n,e)):--a;return a||u.resolveWith(r,o),u.promise()}}),ot.support=function(e){var n=U.createElement("input"),r=U.createDocumentFragment(),i=U.createElement("div"),o=U.createElement("select"),s=o.appendChild(U.createElement("option"));return n.type?(n.type="checkbox",e.checkOn=""!==n.value,e.optSelected=s.selected,e.reliableMarginRight=!0,e.boxSizingReliable=!0,e.pixelPosition=!1,n.checked=!0,e.noCloneChecked=n.cloneNode(!0).checked,o.disabled=!0,e.optDisabled=!s.disabled,n=U.createElement("input"),n.value="t",n.type="radio",e.radioValue="t"===n.value,n.setAttribute("checked","t"),n.setAttribute("name","t"),r.appendChild(n),e.checkClone=r.cloneNode(!0).cloneNode(!0).lastChild.checked,e.focusinBubbles="onfocusin"in t,i.style.backgroundClip="content-box",i.cloneNode(!0).style.backgroundClip="",e.clearCloneStyle="content-box"===i.style.backgroundClip,ot(function(){var n,r,o="padding:0;margin:0;border:0;display:block;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box",s=U.getElementsByTagName("body")[0];s&&(n=U.createElement("div"),n.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",s.appendChild(n).appendChild(i),i.innerHTML="",i.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%",ot.swap(s,null!=s.style.zoom?{zoom:1}:{},function(){e.boxSizing=4===i.offsetWidth}),t.getComputedStyle&&(e.pixelPosition="1%"!==(t.getComputedStyle(i,null)||{}).top,e.boxSizingReliable="4px"===(t.getComputedStyle(i,null)||{width:"4px"}).width,r=i.appendChild(U.createElement("div")),r.style.cssText=i.style.cssText=o,r.style.marginRight=r.style.width="0",i.style.width="1px",e.reliableMarginRight=!parseFloat((t.getComputedStyle(r,null)||{}).marginRight)),s.removeChild(n))}),e):e}({});var mt,gt,vt=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,yt=/([A-Z])/g;i.uid=1,i.accepts=function(t){return t.nodeType?1===t.nodeType||9===t.nodeType:!0},i.prototype={key:function(t){if(!i.accepts(t))return 0;var e={},n=t[this.expando];if(!n){n=i.uid++;try{e[this.expando]={value:n},Object.defineProperties(t,e)}catch(r){e[this.expando]=n,ot.extend(t,e)}}return this.cache[n]||(this.cache[n]={}),n},set:function(t,e,n){var r,i=this.key(t),o=this.cache[i];if("string"==typeof e)o[e]=n;else if(ot.isEmptyObject(o))ot.extend(this.cache[i],e);else for(r in e)o[r]=e[r];return o},get:function(t,n){var r=this.cache[this.key(t)];return n===e?r:r[n]},access:function(t,n,r){return n===e||n&&"string"==typeof n&&r===e?this.get(t,n):(this.set(t,n,r),r!==e?r:n)},remove:function(t,n){var r,i,o,s=this.key(t),a=this.cache[s];if(n===e)this.cache[s]={};else{ot.isArray(n)?i=n.concat(n.map(ot.camelCase)):(o=ot.camelCase(n),n in a?i=[n,o]:(i=o,i=i in a?[i]:i.match(at)||[])),r=i.length;for(;r--;)delete a[i[r]]}},hasData:function(t){return!ot.isEmptyObject(this.cache[t[this.expando]]||{})},discard:function(t){t[this.expando]&&delete this.cache[t[this.expando]]}},mt=new i,gt=new i,ot.extend({acceptData:i.accepts,hasData:function(t){return mt.hasData(t)||gt.hasData(t)},data:function(t,e,n){return mt.access(t,e,n)},removeData:function(t,e){mt.remove(t,e)},_data:function(t,e,n){return gt.access(t,e,n)},_removeData:function(t,e){gt.remove(t,e)}}),ot.fn.extend({data:function(t,n){var r,i,s=this[0],a=0,u=null;if(t===e){if(this.length&&(u=mt.get(s),1===s.nodeType&&!gt.get(s,"hasDataAttrs"))){for(r=s.attributes;a<r.length;a++)i=r[a].name,0===i.indexOf("data-")&&(i=ot.camelCase(i.slice(5)),o(s,i,u[i]));gt.set(s,"hasDataAttrs",!0)}return u}return"object"==typeof t?this.each(function(){mt.set(this,t)}):ot.access(this,function(n){var r,i=ot.camelCase(t);if(s&&n===e){if(r=mt.get(s,t),r!==e)return r;if(r=mt.get(s,i),r!==e)return r;if(r=o(s,i,e),r!==e)return r}else this.each(function(){var r=mt.get(this,i);mt.set(this,i,n),-1!==t.indexOf("-")&&r!==e&&mt.set(this,t,n)})},null,n,arguments.length>1,null,!0)},removeData:function(t){return this.each(function(){mt.remove(this,t)})}}),ot.extend({queue:function(t,e,n){var r;return t?(e=(e||"fx")+"queue",r=gt.get(t,e),n&&(!r||ot.isArray(n)?r=gt.access(t,e,ot.makeArray(n)):r.push(n)),r||[]):void 0},dequeue:function(t,e){e=e||"fx";var n=ot.queue(t,e),r=n.length,i=n.shift(),o=ot._queueHooks(t,e),s=function(){ot.dequeue(t,e)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===e&&n.unshift("inprogress"),delete o.stop,i.call(t,s,o)),!r&&o&&o.empty.fire()},_queueHooks:function(t,e){var n=e+"queueHooks";return gt.get(t,n)||gt.access(t,n,{empty:ot.Callbacks("once memory").add(function(){gt.remove(t,[e+"queue",n])})})}}),ot.fn.extend({queue:function(t,n){var r=2;return"string"!=typeof t&&(n=t,t="fx",r--),arguments.length<r?ot.queue(this[0],t):n===e?this:this.each(function(){var e=ot.queue(this,t,n);ot._queueHooks(this,t),"fx"===t&&"inprogress"!==e[0]&&ot.dequeue(this,t)})},dequeue:function(t){return this.each(function(){ot.dequeue(this,t)})},delay:function(t,e){return t=ot.fx?ot.fx.speeds[t]||t:t,e=e||"fx",this.queue(e,function(e,n){var r=setTimeout(e,t);n.stop=function(){clearTimeout(r)}})},clearQueue:function(t){return this.queue(t||"fx",[])},promise:function(t,n){var r,i=1,o=ot.Deferred(),s=this,a=this.length,u=function(){--i||o.resolveWith(s,[s])};for("string"!=typeof t&&(n=t,t=e),t=t||"fx";a--;)r=gt.get(s[a],t+"queueHooks"),r&&r.empty&&(i++,r.empty.add(u));return u(),o.promise(n)}});var bt,wt,xt=/[\t\r\n\f]/g,Ct=/\r/g,kt=/^(?:input|select|textarea|button)$/i;ot.fn.extend({attr:function(t,e){return ot.access(this,ot.attr,t,e,arguments.length>1)},removeAttr:function(t){return this.each(function(){ot.removeAttr(this,t)})},prop:function(t,e){return ot.access(this,ot.prop,t,e,arguments.length>1)},removeProp:function(t){return this.each(function(){delete this[ot.propFix[t]||t]})},addClass:function(t){var e,n,r,i,o,s=0,a=this.length,u="string"==typeof t&&t;if(ot.isFunction(t))return this.each(function(e){ot(this).addClass(t.call(this,e,this.className))});if(u)for(e=(t||"").match(at)||[];a>s;s++)if(n=this[s],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(xt," "):" ")){for(o=0;i=e[o++];)r.indexOf(" "+i+" ")<0&&(r+=i+" ");n.className=ot.trim(r)}return this},removeClass:function(t){var e,n,r,i,o,s=0,a=this.length,u=0===arguments.length||"string"==typeof t&&t;if(ot.isFunction(t))return this.each(function(e){ot(this).removeClass(t.call(this,e,this.className))});if(u)for(e=(t||"").match(at)||[];a>s;s++)if(n=this[s],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(xt," "):"")){for(o=0;i=e[o++];)for(;r.indexOf(" "+i+" ")>=0;)r=r.replace(" "+i+" "," ");n.className=t?ot.trim(r):""}return this},toggleClass:function(t,e){var n=typeof t,r="boolean"==typeof e;return ot.isFunction(t)?this.each(function(n){ot(this).toggleClass(t.call(this,n,this.className,e),e)}):this.each(function(){if("string"===n)for(var i,o=0,s=ot(this),a=e,u=t.match(at)||[];i=u[o++];)a=r?a:!s.hasClass(i),s[a?"addClass":"removeClass"](i);else(n===B||"boolean"===n)&&(this.className&>.set(this,"__className__",this.className),this.className=this.className||t===!1?"":gt.get(this,"__className__")||"")})},hasClass:function(t){for(var e=" "+t+" ",n=0,r=this.length;r>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(xt," ").indexOf(e)>=0)return!0;return!1},val:function(t){var n,r,i,o=this[0];{if(arguments.length)return i=ot.isFunction(t),this.each(function(r){var o;1===this.nodeType&&(o=i?t.call(this,r,ot(this).val()):t,null==o?o="":"number"==typeof o?o+="":ot.isArray(o)&&(o=ot.map(o,function(t){return null==t?"":t+""})),n=ot.valHooks[this.type]||ot.valHooks[this.nodeName.toLowerCase()],n&&"set"in n&&n.set(this,o,"value")!==e||(this.value=o))});if(o)return n=ot.valHooks[o.type]||ot.valHooks[o.nodeName.toLowerCase()],n&&"get"in n&&(r=n.get(o,"value"))!==e?r:(r=o.value,"string"==typeof r?r.replace(Ct,""):null==r?"":r)}}}),ot.extend({valHooks:{option:{get:function(t){var e=t.attributes.value;return!e||e.specified?t.value:t.text}},select:{get:function(t){for(var e,n,r=t.options,i=t.selectedIndex,o="select-one"===t.type||0>i,s=o?null:[],a=o?i+1:r.length,u=0>i?a:o?i:0;a>u;u++)if(n=r[u],(n.selected||u===i)&&(ot.support.optDisabled?!n.disabled:null===n.getAttribute("disabled"))&&(!n.parentNode.disabled||!ot.nodeName(n.parentNode,"optgroup"))){if(e=ot(n).val(),o)return e;s.push(e)}return s},set:function(t,e){for(var n,r,i=t.options,o=ot.makeArray(e),s=i.length;s--;)r=i[s],(r.selected=ot.inArray(ot(r).val(),o)>=0)&&(n=!0);return n||(t.selectedIndex=-1),o}}},attr:function(t,n,r){var i,o,s=t.nodeType;if(t&&3!==s&&8!==s&&2!==s)return typeof t.getAttribute===B?ot.prop(t,n,r):(1===s&&ot.isXMLDoc(t)||(n=n.toLowerCase(),i=ot.attrHooks[n]||(ot.expr.match.bool.test(n)?wt:bt)),r===e?i&&"get"in i&&null!==(o=i.get(t,n))?o:(o=ot.find.attr(t,n),null==o?e:o):null!==r?i&&"set"in i&&(o=i.set(t,r,n))!==e?o:(t.setAttribute(n,r+""),r):void ot.removeAttr(t,n))},removeAttr:function(t,e){var n,r,i=0,o=e&&e.match(at);if(o&&1===t.nodeType)for(;n=o[i++];)r=ot.propFix[n]||n,ot.expr.match.bool.test(n)&&(t[r]=!1),t.removeAttribute(n)},attrHooks:{type:{set:function(t,e){if(!ot.support.radioValue&&"radio"===e&&ot.nodeName(t,"input")){var n=t.value;return t.setAttribute("type",e),n&&(t.value=n),e}}}},propFix:{"for":"htmlFor","class":"className"},prop:function(t,n,r){var i,o,s,a=t.nodeType;if(t&&3!==a&&8!==a&&2!==a)return s=1!==a||!ot.isXMLDoc(t),s&&(n=ot.propFix[n]||n,o=ot.propHooks[n]),r!==e?o&&"set"in o&&(i=o.set(t,r,n))!==e?i:t[n]=r:o&&"get"in o&&null!==(i=o.get(t,n))?i:t[n]},propHooks:{tabIndex:{get:function(t){return t.hasAttribute("tabindex")||kt.test(t.nodeName)||t.href?t.tabIndex:-1}}}}),wt={set:function(t,e,n){return e===!1?ot.removeAttr(t,n):t.setAttribute(n,n),n}},ot.each(ot.expr.match.bool.source.match(/\w+/g),function(t,n){var r=ot.expr.attrHandle[n]||ot.find.attr;ot.expr.attrHandle[n]=function(t,n,i){var o=ot.expr.attrHandle[n],s=i?e:(ot.expr.attrHandle[n]=e)!=r(t,n,i)?n.toLowerCase():null;return ot.expr.attrHandle[n]=o,s}}),ot.support.optSelected||(ot.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null}}),ot.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){ot.propFix[this.toLowerCase()]=this}),ot.each(["radio","checkbox"],function(){ot.valHooks[this]={set:function(t,e){return ot.isArray(e)?t.checked=ot.inArray(ot(t).val(),e)>=0:void 0}},ot.support.checkOn||(ot.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})});var Tt=/^key/,_t=/^(?:mouse|contextmenu)|click/,Nt=/^(?:focusinfocus|focusoutblur)$/,St=/^([^.]*)(?:\.(.+)|)$/;ot.event={global:{},add:function(t,n,r,i,o){var s,a,u,l,c,h,f,p,d,m,g,v=gt.get(t);if(v){for(r.handler&&(s=r,r=s.handler,o=s.selector),r.guid||(r.guid=ot.guid++),(l=v.events)||(l=v.events={}),(a=v.handle)||(a=v.handle=function(t){return typeof ot===B||t&&ot.event.triggered===t.type?e:ot.event.dispatch.apply(a.elem,arguments)},a.elem=t),n=(n||"").match(at)||[""],c=n.length;c--;)u=St.exec(n[c])||[],d=g=u[1],m=(u[2]||"").split(".").sort(),d&&(f=ot.event.special[d]||{},d=(o?f.delegateType:f.bindType)||d,f=ot.event.special[d]||{},h=ot.extend({type:d,origType:g,data:i,handler:r,guid:r.guid,selector:o,needsContext:o&&ot.expr.match.needsContext.test(o),namespace:m.join(".")},s),(p=l[d])||(p=l[d]=[],p.delegateCount=0,f.setup&&f.setup.call(t,i,m,a)!==!1||t.addEventListener&&t.addEventListener(d,a,!1)),f.add&&(f.add.call(t,h),h.handler.guid||(h.handler.guid=r.guid)),o?p.splice(p.delegateCount++,0,h):p.push(h),ot.event.global[d]=!0);t=null}},remove:function(t,e,n,r,i){var o,s,a,u,l,c,h,f,p,d,m,g=gt.hasData(t)&>.get(t);if(g&&(u=g.events)){for(e=(e||"").match(at)||[""],l=e.length;l--;)if(a=St.exec(e[l])||[],p=m=a[1],d=(a[2]||"").split(".").sort(),p){for(h=ot.event.special[p]||{},p=(r?h.delegateType:h.bindType)||p,f=u[p]||[],a=a[2]&&new RegExp("(^|\\.)"+d.join("\\.(?:.*\\.|)")+"(\\.|$)"),s=o=f.length;o--;)c=f[o],!i&&m!==c.origType||n&&n.guid!==c.guid||a&&!a.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(f.splice(o,1),c.selector&&f.delegateCount--,h.remove&&h.remove.call(t,c));s&&!f.length&&(h.teardown&&h.teardown.call(t,d,g.handle)!==!1||ot.removeEvent(t,p,g.handle),
|
25
|
-
delete u[p])}else for(p in u)ot.event.remove(t,p+e[l],n,r,!0);ot.isEmptyObject(u)&&(delete g.handle,gt.remove(t,"events"))}},trigger:function(n,r,i,o){var s,a,u,l,c,h,f,p=[i||U],d=rt.call(n,"type")?n.type:n,m=rt.call(n,"namespace")?n.namespace.split("."):[];if(a=u=i=i||U,3!==i.nodeType&&8!==i.nodeType&&!Nt.test(d+ot.event.triggered)&&(d.indexOf(".")>=0&&(m=d.split("."),d=m.shift(),m.sort()),c=d.indexOf(":")<0&&"on"+d,n=n[ot.expando]?n:new ot.Event(d,"object"==typeof n&&n),n.isTrigger=o?2:3,n.namespace=m.join("."),n.namespace_re=n.namespace?new RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,n.result=e,n.target||(n.target=i),r=null==r?[n]:ot.makeArray(r,[n]),f=ot.event.special[d]||{},o||!f.trigger||f.trigger.apply(i,r)!==!1)){if(!o&&!f.noBubble&&!ot.isWindow(i)){for(l=f.delegateType||d,Nt.test(l+d)||(a=a.parentNode);a;a=a.parentNode)p.push(a),u=a;u===(i.ownerDocument||U)&&p.push(u.defaultView||u.parentWindow||t)}for(s=0;(a=p[s++])&&!n.isPropagationStopped();)n.type=s>1?l:f.bindType||d,h=(gt.get(a,"events")||{})[n.type]&>.get(a,"handle"),h&&h.apply(a,r),h=c&&a[c],h&&ot.acceptData(a)&&h.apply&&h.apply(a,r)===!1&&n.preventDefault();return n.type=d,o||n.isDefaultPrevented()||f._default&&f._default.apply(p.pop(),r)!==!1||!ot.acceptData(i)||c&&ot.isFunction(i[d])&&!ot.isWindow(i)&&(u=i[c],u&&(i[c]=null),ot.event.triggered=d,i[d](),ot.event.triggered=e,u&&(i[c]=u)),n.result}},dispatch:function(t){t=ot.event.fix(t);var n,r,i,o,s,a=[],u=tt.call(arguments),l=(gt.get(this,"events")||{})[t.type]||[],c=ot.event.special[t.type]||{};if(u[0]=t,t.delegateTarget=this,!c.preDispatch||c.preDispatch.call(this,t)!==!1){for(a=ot.event.handlers.call(this,t,l),n=0;(o=a[n++])&&!t.isPropagationStopped();)for(t.currentTarget=o.elem,r=0;(s=o.handlers[r++])&&!t.isImmediatePropagationStopped();)(!t.namespace_re||t.namespace_re.test(s.namespace))&&(t.handleObj=s,t.data=s.data,i=((ot.event.special[s.origType]||{}).handle||s.handler).apply(o.elem,u),i!==e&&(t.result=i)===!1&&(t.preventDefault(),t.stopPropagation()));return c.postDispatch&&c.postDispatch.call(this,t),t.result}},handlers:function(t,n){var r,i,o,s,a=[],u=n.delegateCount,l=t.target;if(u&&l.nodeType&&(!t.button||"click"!==t.type))for(;l!==this;l=l.parentNode||this)if(l.disabled!==!0||"click"!==t.type){for(i=[],r=0;u>r;r++)s=n[r],o=s.selector+" ",i[o]===e&&(i[o]=s.needsContext?ot(o,this).index(l)>=0:ot.find(o,this,null,[l]).length),i[o]&&i.push(s);i.length&&a.push({elem:l,handlers:i})}return u<n.length&&a.push({elem:this,handlers:n.slice(u)}),a},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(t,e){return null==t.which&&(t.which=null!=e.charCode?e.charCode:e.keyCode),t}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(t,n){var r,i,o,s=n.button;return null==t.pageX&&null!=n.clientX&&(r=t.target.ownerDocument||U,i=r.documentElement,o=r.body,t.pageX=n.clientX+(i&&i.scrollLeft||o&&o.scrollLeft||0)-(i&&i.clientLeft||o&&o.clientLeft||0),t.pageY=n.clientY+(i&&i.scrollTop||o&&o.scrollTop||0)-(i&&i.clientTop||o&&o.clientTop||0)),t.which||s===e||(t.which=1&s?1:2&s?3:4&s?2:0),t}},fix:function(t){if(t[ot.expando])return t;var e,n,r,i=t.type,o=t,s=this.fixHooks[i];for(s||(this.fixHooks[i]=s=_t.test(i)?this.mouseHooks:Tt.test(i)?this.keyHooks:{}),r=s.props?this.props.concat(s.props):this.props,t=new ot.Event(o),e=r.length;e--;)n=r[e],t[n]=o[n];return t.target||(t.target=U),3===t.target.nodeType&&(t.target=t.target.parentNode),s.filter?s.filter(t,o):t},special:{load:{noBubble:!0},focus:{trigger:function(){return this!==u()&&this.focus?(this.focus(),!1):void 0},delegateType:"focusin"},blur:{trigger:function(){return this===u()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return"checkbox"===this.type&&this.click&&ot.nodeName(this,"input")?(this.click(),!1):void 0},_default:function(t){return ot.nodeName(t.target,"a")}},beforeunload:{postDispatch:function(t){t.result!==e&&(t.originalEvent.returnValue=t.result)}}},simulate:function(t,e,n,r){var i=ot.extend(new ot.Event,n,{type:t,isSimulated:!0,originalEvent:{}});r?ot.event.trigger(i,null,e):ot.event.dispatch.call(e,i),i.isDefaultPrevented()&&n.preventDefault()}},ot.removeEvent=function(t,e,n){t.removeEventListener&&t.removeEventListener(e,n,!1)},ot.Event=function(t,e){return this instanceof ot.Event?(t&&t.type?(this.originalEvent=t,this.type=t.type,this.isDefaultPrevented=t.defaultPrevented||t.getPreventDefault&&t.getPreventDefault()?s:a):this.type=t,e&&ot.extend(this,e),this.timeStamp=t&&t.timeStamp||ot.now(),void(this[ot.expando]=!0)):new ot.Event(t,e)},ot.Event.prototype={isDefaultPrevented:a,isPropagationStopped:a,isImmediatePropagationStopped:a,preventDefault:function(){var t=this.originalEvent;this.isDefaultPrevented=s,t&&t.preventDefault&&t.preventDefault()},stopPropagation:function(){var t=this.originalEvent;this.isPropagationStopped=s,t&&t.stopPropagation&&t.stopPropagation()},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=s,this.stopPropagation()}},ot.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(t,e){ot.event.special[t]={delegateType:e,bindType:e,handle:function(t){var n,r=this,i=t.relatedTarget,o=t.handleObj;return(!i||i!==r&&!ot.contains(r,i))&&(t.type=o.origType,n=o.handler.apply(this,arguments),t.type=e),n}}}),ot.support.focusinBubbles||ot.each({focus:"focusin",blur:"focusout"},function(t,e){var n=0,r=function(t){ot.event.simulate(e,t.target,ot.event.fix(t),!0)};ot.event.special[e]={setup:function(){0===n++&&U.addEventListener(t,r,!0)},teardown:function(){0===--n&&U.removeEventListener(t,r,!0)}}}),ot.fn.extend({on:function(t,n,r,i,o){var s,u;if("object"==typeof t){"string"!=typeof n&&(r=r||n,n=e);for(u in t)this.on(u,n,r,t[u],o);return this}if(null==r&&null==i?(i=n,r=n=e):null==i&&("string"==typeof n?(i=r,r=e):(i=r,r=n,n=e)),i===!1)i=a;else if(!i)return this;return 1===o&&(s=i,i=function(t){return ot().off(t),s.apply(this,arguments)},i.guid=s.guid||(s.guid=ot.guid++)),this.each(function(){ot.event.add(this,t,i,r,n)})},one:function(t,e,n,r){return this.on(t,e,n,r,1)},off:function(t,n,r){var i,o;if(t&&t.preventDefault&&t.handleObj)return i=t.handleObj,ot(t.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if("object"==typeof t){for(o in t)this.off(o,n,t[o]);return this}return(n===!1||"function"==typeof n)&&(r=n,n=e),r===!1&&(r=a),this.each(function(){ot.event.remove(this,t,r,n)})},trigger:function(t,e){return this.each(function(){ot.event.trigger(t,e,this)})},triggerHandler:function(t,e){var n=this[0];return n?ot.event.trigger(t,e,n,!0):void 0}});var $t=/^.[^:#\[\.,]*$/,Et=/^(?:parents|prev(?:Until|All))/,jt=ot.expr.match.needsContext,Mt={children:!0,contents:!0,next:!0,prev:!0};ot.fn.extend({find:function(t){var e,n=[],r=this,i=r.length;if("string"!=typeof t)return this.pushStack(ot(t).filter(function(){for(e=0;i>e;e++)if(ot.contains(r[e],this))return!0}));for(e=0;i>e;e++)ot.find(t,r[e],n);return n=this.pushStack(i>1?ot.unique(n):n),n.selector=this.selector?this.selector+" "+t:t,n},has:function(t){var e=ot(t,this),n=e.length;return this.filter(function(){for(var t=0;n>t;t++)if(ot.contains(this,e[t]))return!0})},not:function(t){return this.pushStack(c(this,t||[],!0))},filter:function(t){return this.pushStack(c(this,t||[],!1))},is:function(t){return!!c(this,"string"==typeof t&&jt.test(t)?ot(t):t||[],!1).length},closest:function(t,e){for(var n,r=0,i=this.length,o=[],s=jt.test(t)||"string"!=typeof t?ot(t,e||this.context):0;i>r;r++)for(n=this[r];n&&n!==e;n=n.parentNode)if(n.nodeType<11&&(s?s.index(n)>-1:1===n.nodeType&&ot.find.matchesSelector(n,t))){n=o.push(n);break}return this.pushStack(o.length>1?ot.unique(o):o)},index:function(t){return t?"string"==typeof t?et.call(ot(t),this[0]):et.call(this,t.jquery?t[0]:t):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(t,e){var n="string"==typeof t?ot(t,e):ot.makeArray(t&&t.nodeType?[t]:t),r=ot.merge(this.get(),n);return this.pushStack(ot.unique(r))},addBack:function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}}),ot.each({parent:function(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(t){return ot.dir(t,"parentNode")},parentsUntil:function(t,e,n){return ot.dir(t,"parentNode",n)},next:function(t){return l(t,"nextSibling")},prev:function(t){return l(t,"previousSibling")},nextAll:function(t){return ot.dir(t,"nextSibling")},prevAll:function(t){return ot.dir(t,"previousSibling")},nextUntil:function(t,e,n){return ot.dir(t,"nextSibling",n)},prevUntil:function(t,e,n){return ot.dir(t,"previousSibling",n)},siblings:function(t){return ot.sibling((t.parentNode||{}).firstChild,t)},children:function(t){return ot.sibling(t.firstChild)},contents:function(t){return t.contentDocument||ot.merge([],t.childNodes)}},function(t,e){ot.fn[t]=function(n,r){var i=ot.map(this,e,n);return"Until"!==t.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=ot.filter(r,i)),this.length>1&&(Mt[t]||ot.unique(i),Et.test(t)&&i.reverse()),this.pushStack(i)}}),ot.extend({filter:function(t,e,n){var r=e[0];return n&&(t=":not("+t+")"),1===e.length&&1===r.nodeType?ot.find.matchesSelector(r,t)?[r]:[]:ot.find.matches(t,ot.grep(e,function(t){return 1===t.nodeType}))},dir:function(t,n,r){for(var i=[],o=r!==e;(t=t[n])&&9!==t.nodeType;)if(1===t.nodeType){if(o&&ot(t).is(r))break;i.push(t)}return i},sibling:function(t,e){for(var n=[];t;t=t.nextSibling)1===t.nodeType&&t!==e&&n.push(t);return n}});var Dt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,At=/<([\w:]+)/,Ot=/<|&#?\w+;/,Rt=/<(?:script|style|link)/i,Pt=/^(?:checkbox|radio)$/i,Lt=/checked\s*(?:[^=]|=\s*.checked.)/i,Ht=/^$|\/(?:java|ecma)script/i,zt=/^true\/(.*)/,qt=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Ft={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};Ft.optgroup=Ft.option,Ft.tbody=Ft.tfoot=Ft.colgroup=Ft.caption=Ft.thead,Ft.th=Ft.td,ot.fn.extend({text:function(t){return ot.access(this,function(t){return t===e?ot.text(this):this.empty().append((this[0]&&this[0].ownerDocument||U).createTextNode(t))},null,t,arguments.length)},append:function(){return this.domManip(arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=h(this,t);e.appendChild(t)}})},prepend:function(){return this.domManip(arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=h(this,t);e.insertBefore(t,e.firstChild)}})},before:function(){return this.domManip(arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this)})},after:function(){return this.domManip(arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)})},remove:function(t,e){for(var n,r=t?ot.filter(t,this):this,i=0;null!=(n=r[i]);i++)e||1!==n.nodeType||ot.cleanData(g(n)),n.parentNode&&(e&&ot.contains(n.ownerDocument,n)&&d(g(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(ot.cleanData(g(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null==t?!1:t,e=null==e?t:e,this.map(function(){return ot.clone(this,t,e)})},html:function(t){return ot.access(this,function(t){var n=this[0]||{},r=0,i=this.length;if(t===e&&1===n.nodeType)return n.innerHTML;if("string"==typeof t&&!Rt.test(t)&&!Ft[(At.exec(t)||["",""])[1].toLowerCase()]){t=t.replace(Dt,"<$1></$2>");try{for(;i>r;r++)n=this[r]||{},1===n.nodeType&&(ot.cleanData(g(n,!1)),n.innerHTML=t);n=0}catch(o){}}n&&this.empty().append(t)},null,t,arguments.length)},replaceWith:function(){var t=ot.map(this,function(t){return[t.nextSibling,t.parentNode]}),e=0;return this.domManip(arguments,function(n){var r=t[e++],i=t[e++];i&&(r&&r.parentNode!==i&&(r=this.nextSibling),ot(this).remove(),i.insertBefore(n,r))},!0),e?this:this.remove()},detach:function(t){return this.remove(t,!0)},domManip:function(t,e,n){t=K.apply([],t);var r,i,o,s,a,u,l=0,c=this.length,h=this,d=c-1,m=t[0],v=ot.isFunction(m);if(v||!(1>=c||"string"!=typeof m||ot.support.checkClone)&&Lt.test(m))return this.each(function(r){var i=h.eq(r);v&&(t[0]=m.call(this,r,i.html())),i.domManip(t,e,n)});if(c&&(r=ot.buildFragment(t,this[0].ownerDocument,!1,!n&&this),i=r.firstChild,1===r.childNodes.length&&(r=i),i)){for(o=ot.map(g(r,"script"),f),s=o.length;c>l;l++)a=r,l!==d&&(a=ot.clone(a,!0,!0),s&&ot.merge(o,g(a,"script"))),e.call(this[l],a,l);if(s)for(u=o[o.length-1].ownerDocument,ot.map(o,p),l=0;s>l;l++)a=o[l],Ht.test(a.type||"")&&!gt.access(a,"globalEval")&&ot.contains(u,a)&&(a.src?ot._evalUrl(a.src):ot.globalEval(a.textContent.replace(qt,"")))}return this}}),ot.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(t,e){ot.fn[t]=function(t){for(var n,r=[],i=ot(t),o=i.length-1,s=0;o>=s;s++)n=s===o?this:this.clone(!0),ot(i[s])[e](n),Z.apply(r,n.get());return this.pushStack(r)}}),ot.extend({clone:function(t,e,n){var r,i,o,s,a=t.cloneNode(!0),u=ot.contains(t.ownerDocument,t);if(!(ot.support.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||ot.isXMLDoc(t)))for(s=g(a),o=g(t),r=0,i=o.length;i>r;r++)v(o[r],s[r]);if(e)if(n)for(o=o||g(t),s=s||g(a),r=0,i=o.length;i>r;r++)m(o[r],s[r]);else m(t,a);return s=g(a,"script"),s.length>0&&d(s,!u&&g(t,"script")),a},buildFragment:function(t,e,n,r){for(var i,o,s,a,u,l,c=0,h=t.length,f=e.createDocumentFragment(),p=[];h>c;c++)if(i=t[c],i||0===i)if("object"===ot.type(i))ot.merge(p,i.nodeType?[i]:i);else if(Ot.test(i)){for(o=o||f.appendChild(e.createElement("div")),s=(At.exec(i)||["",""])[1].toLowerCase(),a=Ft[s]||Ft._default,o.innerHTML=a[1]+i.replace(Dt,"<$1></$2>")+a[2],l=a[0];l--;)o=o.firstChild;ot.merge(p,o.childNodes),o=f.firstChild,o.textContent=""}else p.push(e.createTextNode(i));for(f.textContent="",c=0;i=p[c++];)if((!r||-1===ot.inArray(i,r))&&(u=ot.contains(i.ownerDocument,i),o=g(f.appendChild(i),"script"),u&&d(o),n))for(l=0;i=o[l++];)Ht.test(i.type||"")&&n.push(i);return f},cleanData:function(t){for(var n,r,o,s,a,u,l=ot.event.special,c=0;(r=t[c])!==e;c++){if(i.accepts(r)&&(a=r[gt.expando],a&&(n=gt.cache[a]))){if(o=Object.keys(n.events||{}),o.length)for(u=0;(s=o[u])!==e;u++)l[s]?ot.event.remove(r,s):ot.removeEvent(r,s,n.handle);gt.cache[a]&&delete gt.cache[a]}delete mt.cache[r[mt.expando]]}},_evalUrl:function(t){return ot.ajax({url:t,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})}}),ot.fn.extend({wrapAll:function(t){var e;return ot.isFunction(t)?this.each(function(e){ot(this).wrapAll(t.call(this,e))}):(this[0]&&(e=ot(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t}).append(this)),this)},wrapInner:function(t){return ot.isFunction(t)?this.each(function(e){ot(this).wrapInner(t.call(this,e))}):this.each(function(){var e=ot(this),n=e.contents();n.length?n.wrapAll(t):e.append(t)})},wrap:function(t){var e=ot.isFunction(t);return this.each(function(n){ot(this).wrapAll(e?t.call(this,n):t)})},unwrap:function(){return this.parent().each(function(){ot.nodeName(this,"body")||ot(this).replaceWith(this.childNodes)}).end()}});var It,Bt,Wt=/^(none|table(?!-c[ea]).+)/,Ut=/^margin/,Jt=new RegExp("^("+st+")(.*)$","i"),Vt=new RegExp("^("+st+")(?!px)[a-z%]+$","i"),Xt=new RegExp("^([+-])=("+st+")","i"),Gt={BODY:"block"},Yt={position:"absolute",visibility:"hidden",display:"block"},Qt={letterSpacing:0,fontWeight:400},Kt=["Top","Right","Bottom","Left"],Zt=["Webkit","O","Moz","ms"];ot.fn.extend({css:function(t,n){return ot.access(this,function(t,n,r){var i,o,s={},a=0;if(ot.isArray(n)){for(i=w(t),o=n.length;o>a;a++)s[n[a]]=ot.css(t,n[a],!1,i);return s}return r!==e?ot.style(t,n,r):ot.css(t,n)},t,n,arguments.length>1)},show:function(){return x(this,!0)},hide:function(){return x(this)},toggle:function(t){var e="boolean"==typeof t;return this.each(function(){(e?t:b(this))?ot(this).show():ot(this).hide()})}}),ot.extend({cssHooks:{opacity:{get:function(t,e){if(e){var n=It(t,"opacity");return""===n?"1":n}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(t,n,r,i){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var o,s,a,u=ot.camelCase(n),l=t.style;return n=ot.cssProps[u]||(ot.cssProps[u]=y(l,u)),a=ot.cssHooks[n]||ot.cssHooks[u],r===e?a&&"get"in a&&(o=a.get(t,!1,i))!==e?o:l[n]:(s=typeof r,"string"===s&&(o=Xt.exec(r))&&(r=(o[1]+1)*o[2]+parseFloat(ot.css(t,n)),s="number"),null==r||"number"===s&&isNaN(r)||("number"!==s||ot.cssNumber[u]||(r+="px"),ot.support.clearCloneStyle||""!==r||0!==n.indexOf("background")||(l[n]="inherit"),a&&"set"in a&&(r=a.set(t,r,i))===e||(l[n]=r)),void 0)}},css:function(t,n,r,i){var o,s,a,u=ot.camelCase(n);return n=ot.cssProps[u]||(ot.cssProps[u]=y(t.style,u)),a=ot.cssHooks[n]||ot.cssHooks[u],a&&"get"in a&&(o=a.get(t,!0,r)),o===e&&(o=It(t,n,i)),"normal"===o&&n in Qt&&(o=Qt[n]),""===r||r?(s=parseFloat(o),r===!0||ot.isNumeric(s)?s||0:o):o}}),It=function(t,n,r){var i,o,s,a=r||w(t),u=a?a.getPropertyValue(n)||a[n]:e,l=t.style;return a&&(""!==u||ot.contains(t.ownerDocument,t)||(u=ot.style(t,n)),Vt.test(u)&&Ut.test(n)&&(i=l.width,o=l.minWidth,s=l.maxWidth,l.minWidth=l.maxWidth=l.width=u,u=a.width,l.width=i,l.minWidth=o,l.maxWidth=s)),u},ot.each(["height","width"],function(t,e){ot.cssHooks[e]={get:function(t,n,r){return n?0===t.offsetWidth&&Wt.test(ot.css(t,"display"))?ot.swap(t,Yt,function(){return T(t,e,r)}):T(t,e,r):void 0},set:function(t,n,r){var i=r&&w(t);return C(t,n,r?k(t,e,r,ot.support.boxSizing&&"border-box"===ot.css(t,"boxSizing",!1,i),i):0)}}}),ot(function(){ot.support.reliableMarginRight||(ot.cssHooks.marginRight={get:function(t,e){return e?ot.swap(t,{display:"inline-block"},It,[t,"marginRight"]):void 0}}),!ot.support.pixelPosition&&ot.fn.position&&ot.each(["top","left"],function(t,e){ot.cssHooks[e]={get:function(t,n){return n?(n=It(t,e),Vt.test(n)?ot(t).position()[e]+"px":n):void 0}}})}),ot.expr&&ot.expr.filters&&(ot.expr.filters.hidden=function(t){return t.offsetWidth<=0&&t.offsetHeight<=0},ot.expr.filters.visible=function(t){return!ot.expr.filters.hidden(t)}),ot.each({margin:"",padding:"",border:"Width"},function(t,e){ot.cssHooks[t+e]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];4>r;r++)i[t+Kt[r]+e]=o[r]||o[r-2]||o[0];return i}},Ut.test(t)||(ot.cssHooks[t+e].set=C)});var te=/%20/g,ee=/\[\]$/,ne=/\r?\n/g,re=/^(?:submit|button|image|reset|file)$/i,ie=/^(?:input|select|textarea|keygen)/i;ot.fn.extend({serialize:function(){return ot.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var t=ot.prop(this,"elements");return t?ot.makeArray(t):this}).filter(function(){var t=this.type;return this.name&&!ot(this).is(":disabled")&&ie.test(this.nodeName)&&!re.test(t)&&(this.checked||!Pt.test(t))}).map(function(t,e){var n=ot(this).val();return null==n?null:ot.isArray(n)?ot.map(n,function(t){return{name:e.name,value:t.replace(ne,"\r\n")}}):{name:e.name,value:n.replace(ne,"\r\n")}}).get()}}),ot.param=function(t,n){var r,i=[],o=function(t,e){e=ot.isFunction(e)?e():null==e?"":e,i[i.length]=encodeURIComponent(t)+"="+encodeURIComponent(e)};if(n===e&&(n=ot.ajaxSettings&&ot.ajaxSettings.traditional),ot.isArray(t)||t.jquery&&!ot.isPlainObject(t))ot.each(t,function(){o(this.name,this.value)});else for(r in t)S(r,t[r],n,o);return i.join("&").replace(te,"+")},ot.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(t,e){ot.fn[e]=function(t,n){return arguments.length>0?this.on(e,null,t,n):this.trigger(e)}}),ot.fn.extend({hover:function(t,e){return this.mouseenter(t).mouseleave(e||t)},bind:function(t,e,n){return this.on(t,null,e,n)},unbind:function(t,e){return this.off(t,null,e)},delegate:function(t,e,n,r){return this.on(e,t,n,r)},undelegate:function(t,e,n){return 1===arguments.length?this.off(t,"**"):this.off(e,t||"**",n)}});var oe,se,ae=ot.now(),ue=/\?/,le=/#.*$/,ce=/([?&])_=[^&]*/,he=/^(.*?):[ \t]*([^\r\n]*)$/gm,fe=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,pe=/^(?:GET|HEAD)$/,de=/^\/\//,me=/^([\w.+-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,ge=ot.fn.load,ve={},ye={},be="*/".concat("*");try{se=W.href}catch(we){se=U.createElement("a"),se.href="",se=se.href}oe=me.exec(se.toLowerCase())||[],ot.fn.load=function(t,n,r){if("string"!=typeof t&&ge)return ge.apply(this,arguments);var i,o,s,a=this,u=t.indexOf(" ");return u>=0&&(i=t.slice(u),t=t.slice(0,u)),ot.isFunction(n)?(r=n,n=e):n&&"object"==typeof n&&(o="POST"),a.length>0&&ot.ajax({url:t,type:o,dataType:"html",data:n}).done(function(t){s=arguments,a.html(i?ot("<div>").append(ot.parseHTML(t)).find(i):t)}).complete(r&&function(t,e){a.each(r,s||[t.responseText,e,t])}),this},ot.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(t,e){ot.fn[e]=function(t){return this.on(e,t)}}),ot.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:se,type:"GET",isLocal:fe.test(oe[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":be,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":ot.parseJSON,"text xml":ot.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?j(j(t,ot.ajaxSettings),e):j(ot.ajaxSettings,t)},ajaxPrefilter:$(ve),ajaxTransport:$(ye),ajax:function(t,n){function r(t,n,r,a){var l,h,y,b,x,k=n;2!==w&&(w=2,u&&clearTimeout(u),i=e,s=a||"",C.readyState=t>0?4:0,l=t>=200&&300>t||304===t,r&&(b=M(f,C,r)),b=D(f,b,C,l),l?(f.ifModified&&(x=C.getResponseHeader("Last-Modified"),x&&(ot.lastModified[o]=x),x=C.getResponseHeader("etag"),x&&(ot.etag[o]=x)),204===t||"HEAD"===f.type?k="nocontent":304===t?k="notmodified":(k=b.state,h=b.data,y=b.error,l=!y)):(y=k,(t||!k)&&(k="error",0>t&&(t=0))),C.status=t,C.statusText=(n||k)+"",l?m.resolveWith(p,[h,k,C]):m.rejectWith(p,[C,k,y]),C.statusCode(v),v=e,c&&d.trigger(l?"ajaxSuccess":"ajaxError",[C,f,l?h:y]),g.fireWith(p,[C,k]),c&&(d.trigger("ajaxComplete",[C,f]),--ot.active||ot.event.trigger("ajaxStop")))}"object"==typeof t&&(n=t,t=e),n=n||{};var i,o,s,a,u,l,c,h,f=ot.ajaxSetup({},n),p=f.context||f,d=f.context&&(p.nodeType||p.jquery)?ot(p):ot.event,m=ot.Deferred(),g=ot.Callbacks("once memory"),v=f.statusCode||{},y={},b={},w=0,x="canceled",C={readyState:0,getResponseHeader:function(t){var e;if(2===w){if(!a)for(a={};e=he.exec(s);)a[e[1].toLowerCase()]=e[2];e=a[t.toLowerCase()]}return null==e?null:e},getAllResponseHeaders:function(){return 2===w?s:null},setRequestHeader:function(t,e){var n=t.toLowerCase();return w||(t=b[n]=b[n]||t,y[t]=e),this},overrideMimeType:function(t){return w||(f.mimeType=t),this},statusCode:function(t){var e;if(t)if(2>w)for(e in t)v[e]=[v[e],t[e]];else C.always(t[C.status]);return this},abort:function(t){var e=t||x;return i&&i.abort(e),r(0,e),this}};if(m.promise(C).complete=g.add,C.success=C.done,C.error=C.fail,f.url=((t||f.url||se)+"").replace(le,"").replace(de,oe[1]+"//"),f.type=n.method||n.type||f.method||f.type,f.dataTypes=ot.trim(f.dataType||"*").toLowerCase().match(at)||[""],null==f.crossDomain&&(l=me.exec(f.url.toLowerCase()),f.crossDomain=!(!l||l[1]===oe[1]&&l[2]===oe[2]&&(l[3]||("http:"===l[1]?"80":"443"))===(oe[3]||("http:"===oe[1]?"80":"443")))),f.data&&f.processData&&"string"!=typeof f.data&&(f.data=ot.param(f.data,f.traditional)),E(ve,f,n,C),2===w)return C;c=f.global,c&&0===ot.active++&&ot.event.trigger("ajaxStart"),f.type=f.type.toUpperCase(),f.hasContent=!pe.test(f.type),o=f.url,f.hasContent||(f.data&&(o=f.url+=(ue.test(o)?"&":"?")+f.data,delete f.data),f.cache===!1&&(f.url=ce.test(o)?o.replace(ce,"$1_="+ae++):o+(ue.test(o)?"&":"?")+"_="+ae++)),f.ifModified&&(ot.lastModified[o]&&C.setRequestHeader("If-Modified-Since",ot.lastModified[o]),ot.etag[o]&&C.setRequestHeader("If-None-Match",ot.etag[o])),(f.data&&f.hasContent&&f.contentType!==!1||n.contentType)&&C.setRequestHeader("Content-Type",f.contentType),C.setRequestHeader("Accept",f.dataTypes[0]&&f.accepts[f.dataTypes[0]]?f.accepts[f.dataTypes[0]]+("*"!==f.dataTypes[0]?", "+be+"; q=0.01":""):f.accepts["*"]);for(h in f.headers)C.setRequestHeader(h,f.headers[h]);if(f.beforeSend&&(f.beforeSend.call(p,C,f)===!1||2===w))return C.abort();x="abort";for(h in{success:1,error:1,complete:1})C[h](f[h]);if(i=E(ye,f,n,C)){C.readyState=1,c&&d.trigger("ajaxSend",[C,f]),f.async&&f.timeout>0&&(u=setTimeout(function(){C.abort("timeout")},f.timeout));try{w=1,i.send(y,r)}catch(k){if(!(2>w))throw k;r(-1,k)}}else r(-1,"No Transport");return C},getJSON:function(t,e,n){return ot.get(t,e,n,"json")},getScript:function(t,n){return ot.get(t,e,n,"script")}}),ot.each(["get","post"],function(t,n){ot[n]=function(t,r,i,o){return ot.isFunction(r)&&(o=o||i,i=r,r=e),ot.ajax({url:t,type:n,dataType:o,data:r,success:i})}}),ot.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(t){return ot.globalEval(t),t}}}),ot.ajaxPrefilter("script",function(t){t.cache===e&&(t.cache=!1),t.crossDomain&&(t.type="GET")}),ot.ajaxTransport("script",function(t){if(t.crossDomain){var e,n;return{send:function(r,i){e=ot("<script>").prop({async:!0,charset:t.scriptCharset,src:t.url}).on("load error",n=function(t){e.remove(),n=null,t&&i("error"===t.type?404:200,t.type)}),U.head.appendChild(e[0])},abort:function(){n&&n()}}}});var xe=[],Ce=/(=)\?(?=&|$)|\?\?/;ot.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var t=xe.pop()||ot.expando+"_"+ae++;return this[t]=!0,t}}),ot.ajaxPrefilter("json jsonp",function(n,r,i){var o,s,a,u=n.jsonp!==!1&&(Ce.test(n.url)?"url":"string"==typeof n.data&&!(n.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ce.test(n.data)&&"data");return u||"jsonp"===n.dataTypes[0]?(o=n.jsonpCallback=ot.isFunction(n.jsonpCallback)?n.jsonpCallback():n.jsonpCallback,u?n[u]=n[u].replace(Ce,"$1"+o):n.jsonp!==!1&&(n.url+=(ue.test(n.url)?"&":"?")+n.jsonp+"="+o),n.converters["script json"]=function(){return a||ot.error(o+" was not called"),a[0]},n.dataTypes[0]="json",s=t[o],t[o]=function(){a=arguments},i.always(function(){t[o]=s,n[o]&&(n.jsonpCallback=r.jsonpCallback,xe.push(o)),a&&ot.isFunction(s)&&s(a[0]),a=s=e}),"script"):void 0}),ot.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(t){}};var ke=ot.ajaxSettings.xhr(),Te={0:200,1223:204},_e=0,Ne={};t.ActiveXObject&&ot(t).on("unload",function(){for(var t in Ne)Ne[t]();Ne=e}),ot.support.cors=!!ke&&"withCredentials"in ke,ot.support.ajax=ke=!!ke,ot.ajaxTransport(function(t){var n;return ot.support.cors||ke&&!t.crossDomain?{send:function(r,i){var o,s,a=t.xhr();if(a.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(o in t.xhrFields)a[o]=t.xhrFields[o];t.mimeType&&a.overrideMimeType&&a.overrideMimeType(t.mimeType),t.crossDomain||r["X-Requested-With"]||(r["X-Requested-With"]="XMLHttpRequest");for(o in r)a.setRequestHeader(o,r[o]);n=function(t){return function(){n&&(delete Ne[s],n=a.onload=a.onerror=null,"abort"===t?a.abort():"error"===t?i(a.status||404,a.statusText):i(Te[a.status]||a.status,a.statusText,"string"==typeof a.responseText?{text:a.responseText}:e,a.getAllResponseHeaders()))}},a.onload=n(),a.onerror=n("error"),n=Ne[s=_e++]=n("abort"),a.send(t.hasContent&&t.data||null)},abort:function(){n&&n()}}:void 0});var Se,$e,Ee=/^(?:toggle|show|hide)$/,je=new RegExp("^(?:([+-])=|)("+st+")([a-z%]*)$","i"),Me=/queueHooks$/,De=[L],Ae={"*":[function(t,e){var n=this.createTween(t,e),r=n.cur(),i=je.exec(e),o=i&&i[3]||(ot.cssNumber[t]?"":"px"),s=(ot.cssNumber[t]||"px"!==o&&+r)&&je.exec(ot.css(n.elem,t)),a=1,u=20;if(s&&s[3]!==o){o=o||s[3],i=i||[],s=+r||1;do a=a||".5",s/=a,ot.style(n.elem,t,s+o);while(a!==(a=n.cur()/r)&&1!==a&&--u)}return i&&(s=n.start=+s||+r||0,n.unit=o,n.end=i[1]?s+(i[1]+1)*i[2]:+i[2]),n}]};ot.Animation=ot.extend(R,{tweener:function(t,e){ot.isFunction(t)?(e=t,t=["*"]):t=t.split(" ");for(var n,r=0,i=t.length;i>r;r++)n=t[r],Ae[n]=Ae[n]||[],Ae[n].unshift(e)},prefilter:function(t,e){e?De.unshift(t):De.push(t)}}),ot.Tween=H,H.prototype={constructor:H,init:function(t,e,n,r,i,o){this.elem=t,this.prop=n,this.easing=i||"swing",this.options=e,this.start=this.now=this.cur(),this.end=r,this.unit=o||(ot.cssNumber[n]?"":"px")},cur:function(){var t=H.propHooks[this.prop];return t&&t.get?t.get(this):H.propHooks._default.get(this)},run:function(t){var e,n=H.propHooks[this.prop];return this.options.duration?this.pos=e=ot.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):H.propHooks._default.set(this),this}},H.prototype.init.prototype=H.prototype,H.propHooks={_default:{get:function(t){var e;return null==t.elem[t.prop]||t.elem.style&&null!=t.elem.style[t.prop]?(e=ot.css(t.elem,t.prop,""),e&&"auto"!==e?e:0):t.elem[t.prop]},set:function(t){ot.fx.step[t.prop]?ot.fx.step[t.prop](t):t.elem.style&&(null!=t.elem.style[ot.cssProps[t.prop]]||ot.cssHooks[t.prop])?ot.style(t.elem,t.prop,t.now+t.unit):t.elem[t.prop]=t.now}}},H.propHooks.scrollTop=H.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},ot.each(["toggle","show","hide"],function(t,e){var n=ot.fn[e];ot.fn[e]=function(t,r,i){return null==t||"boolean"==typeof t?n.apply(this,arguments):this.animate(z(e,!0),t,r,i)}}),ot.fn.extend({fadeTo:function(t,e,n,r){return this.filter(b).css("opacity",0).show().end().animate({opacity:e},t,n,r)},animate:function(t,e,n,r){var i=ot.isEmptyObject(t),o=ot.speed(e,n,r),s=function(){var e=R(this,ot.extend({},t),o);(i||gt.get(this,"finish"))&&e.stop(!0)};return s.finish=s,i||o.queue===!1?this.each(s):this.queue(o.queue,s)},stop:function(t,n,r){var i=function(t){var e=t.stop;delete t.stop,e(r)};return"string"!=typeof t&&(r=n,n=t,t=e),n&&t!==!1&&this.queue(t||"fx",[]),this.each(function(){var e=!0,n=null!=t&&t+"queueHooks",o=ot.timers,s=gt.get(this);if(n)s[n]&&s[n].stop&&i(s[n]);else for(n in s)s[n]&&s[n].stop&&Me.test(n)&&i(s[n]);for(n=o.length;n--;)o[n].elem!==this||null!=t&&o[n].queue!==t||(o[n].anim.stop(r),e=!1,o.splice(n,1));(e||!r)&&ot.dequeue(this,t)})},finish:function(t){return t!==!1&&(t=t||"fx"),this.each(function(){var e,n=gt.get(this),r=n[t+"queue"],i=n[t+"queueHooks"],o=ot.timers,s=r?r.length:0;for(n.finish=!0,ot.queue(this,t,[]),i&&i.stop&&i.stop.call(this,!0),e=o.length;e--;)o[e].elem===this&&o[e].queue===t&&(o[e].anim.stop(!0),o.splice(e,1));for(e=0;s>e;e++)r[e]&&r[e].finish&&r[e].finish.call(this);delete n.finish})}}),ot.each({slideDown:z("show"),slideUp:z("hide"),slideToggle:z("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(t,e){ot.fn[t]=function(t,n,r){return this.animate(e,t,n,r)}}),ot.speed=function(t,e,n){var r=t&&"object"==typeof t?ot.extend({},t):{complete:n||!n&&e||ot.isFunction(t)&&t,duration:t,easing:n&&e||e&&!ot.isFunction(e)&&e};return r.duration=ot.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in ot.fx.speeds?ot.fx.speeds[r.duration]:ot.fx.speeds._default,(null==r.queue||r.queue===!0)&&(r.queue="fx"),r.old=r.complete,r.complete=function(){ot.isFunction(r.old)&&r.old.call(this),r.queue&&ot.dequeue(this,r.queue)},r},ot.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2}},ot.timers=[],ot.fx=H.prototype.init,ot.fx.tick=function(){var t,n=ot.timers,r=0;for(Se=ot.now();r<n.length;r++)t=n[r],t()||n[r]!==t||n.splice(r--,1);n.length||ot.fx.stop(),Se=e},ot.fx.timer=function(t){t()&&ot.timers.push(t)&&ot.fx.start()},ot.fx.interval=13,ot.fx.start=function(){$e||($e=setInterval(ot.fx.tick,ot.fx.interval))},ot.fx.stop=function(){clearInterval($e),$e=null},ot.fx.speeds={slow:600,fast:200,_default:400},ot.fx.step={},ot.expr&&ot.expr.filters&&(ot.expr.filters.animated=function(t){return ot.grep(ot.timers,function(e){return t===e.elem}).length}),ot.fn.offset=function(t){if(arguments.length)return t===e?this:this.each(function(e){
|
26
|
-
ot.offset.setOffset(this,t,e)});var n,r,i=this[0],o={top:0,left:0},s=i&&i.ownerDocument;if(s)return n=s.documentElement,ot.contains(n,i)?(typeof i.getBoundingClientRect!==B&&(o=i.getBoundingClientRect()),r=q(s),{top:o.top+r.pageYOffset-n.clientTop,left:o.left+r.pageXOffset-n.clientLeft}):o},ot.offset={setOffset:function(t,e,n){var r,i,o,s,a,u,l,c=ot.css(t,"position"),h=ot(t),f={};"static"===c&&(t.style.position="relative"),a=h.offset(),o=ot.css(t,"top"),u=ot.css(t,"left"),l=("absolute"===c||"fixed"===c)&&(o+u).indexOf("auto")>-1,l?(r=h.position(),s=r.top,i=r.left):(s=parseFloat(o)||0,i=parseFloat(u)||0),ot.isFunction(e)&&(e=e.call(t,n,a)),null!=e.top&&(f.top=e.top-a.top+s),null!=e.left&&(f.left=e.left-a.left+i),"using"in e?e.using.call(t,f):h.css(f)}},ot.fn.extend({position:function(){if(this[0]){var t,e,n=this[0],r={top:0,left:0};return"fixed"===ot.css(n,"position")?e=n.getBoundingClientRect():(t=this.offsetParent(),e=this.offset(),ot.nodeName(t[0],"html")||(r=t.offset()),r.top+=ot.css(t[0],"borderTopWidth",!0),r.left+=ot.css(t[0],"borderLeftWidth",!0)),{top:e.top-r.top-ot.css(n,"marginTop",!0),left:e.left-r.left-ot.css(n,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var t=this.offsetParent||J;t&&!ot.nodeName(t,"html")&&"static"===ot.css(t,"position");)t=t.offsetParent;return t||J})}}),ot.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(n,r){var i="pageYOffset"===r;ot.fn[n]=function(o){return ot.access(this,function(n,o,s){var a=q(n);return s===e?a?a[r]:n[o]:void(a?a.scrollTo(i?t.pageXOffset:s,i?s:t.pageYOffset):n[o]=s)},n,o,arguments.length,null)}}),ot.each({Height:"height",Width:"width"},function(t,n){ot.each({padding:"inner"+t,content:n,"":"outer"+t},function(r,i){ot.fn[i]=function(i,o){var s=arguments.length&&(r||"boolean"!=typeof i),a=r||(i===!0||o===!0?"margin":"border");return ot.access(this,function(n,r,i){var o;return ot.isWindow(n)?n.document.documentElement["client"+t]:9===n.nodeType?(o=n.documentElement,Math.max(n.body["scroll"+t],o["scroll"+t],n.body["offset"+t],o["offset"+t],o["client"+t])):i===e?ot.css(n,r,a):ot.style(n,r,i,a)},n,s?i:e,s,null)}})}),ot.fn.size=function(){return this.length},ot.fn.andSelf=ot.fn.addBack,"object"==typeof module&&module&&"object"==typeof module.exports?module.exports=ot:"function"==typeof define&&define.amd&&define("jquery",[],function(){return ot}),"object"==typeof t&&"object"==typeof t.document&&(t.jQuery=t.$=ot)}(window),function(){var t=this,e=t._,n={},r=Array.prototype,i=Object.prototype,o=Function.prototype,s=r.push,a=r.slice,u=r.concat,l=i.toString,c=i.hasOwnProperty,h=r.forEach,f=r.map,p=r.reduce,d=r.reduceRight,m=r.filter,g=r.every,v=r.some,y=r.indexOf,b=r.lastIndexOf,w=Array.isArray,x=Object.keys,C=o.bind,k=function(t){return t instanceof k?t:this instanceof k?void(this._wrapped=t):new k(t)};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=k),exports._=k):t._=k,k.VERSION="1.4.4";var T=k.each=k.forEach=function(t,e,r){if(null!=t)if(h&&t.forEach===h)t.forEach(e,r);else if(t.length===+t.length){for(var i=0,o=t.length;o>i;i++)if(e.call(r,t[i],i,t)===n)return}else for(var s in t)if(k.has(t,s)&&e.call(r,t[s],s,t)===n)return};k.map=k.collect=function(t,e,n){var r=[];return null==t?r:f&&t.map===f?t.map(e,n):(T(t,function(t,i,o){r[r.length]=e.call(n,t,i,o)}),r)};var _="Reduce of empty array with no initial value";k.reduce=k.foldl=k.inject=function(t,e,n,r){var i=arguments.length>2;if(null==t&&(t=[]),p&&t.reduce===p)return r&&(e=k.bind(e,r)),i?t.reduce(e,n):t.reduce(e);if(T(t,function(t,o,s){i?n=e.call(r,n,t,o,s):(n=t,i=!0)}),!i)throw new TypeError(_);return n},k.reduceRight=k.foldr=function(t,e,n,r){var i=arguments.length>2;if(null==t&&(t=[]),d&&t.reduceRight===d)return r&&(e=k.bind(e,r)),i?t.reduceRight(e,n):t.reduceRight(e);var o=t.length;if(o!==+o){var s=k.keys(t);o=s.length}if(T(t,function(a,u,l){u=s?s[--o]:--o,i?n=e.call(r,n,t[u],u,l):(n=t[u],i=!0)}),!i)throw new TypeError(_);return n},k.find=k.detect=function(t,e,n){var r;return N(t,function(t,i,o){return e.call(n,t,i,o)?(r=t,!0):void 0}),r},k.filter=k.select=function(t,e,n){var r=[];return null==t?r:m&&t.filter===m?t.filter(e,n):(T(t,function(t,i,o){e.call(n,t,i,o)&&(r[r.length]=t)}),r)},k.reject=function(t,e,n){return k.filter(t,function(t,r,i){return!e.call(n,t,r,i)},n)},k.every=k.all=function(t,e,r){e||(e=k.identity);var i=!0;return null==t?i:g&&t.every===g?t.every(e,r):(T(t,function(t,o,s){return(i=i&&e.call(r,t,o,s))?void 0:n}),!!i)};var N=k.some=k.any=function(t,e,r){e||(e=k.identity);var i=!1;return null==t?i:v&&t.some===v?t.some(e,r):(T(t,function(t,o,s){return i||(i=e.call(r,t,o,s))?n:void 0}),!!i)};k.contains=k.include=function(t,e){return null==t?!1:y&&t.indexOf===y?-1!=t.indexOf(e):N(t,function(t){return t===e})},k.invoke=function(t,e){var n=a.call(arguments,2),r=k.isFunction(e);return k.map(t,function(t){return(r?e:t[e]).apply(t,n)})},k.pluck=function(t,e){return k.map(t,function(t){return t[e]})},k.where=function(t,e,n){return k.isEmpty(e)?n?null:[]:k[n?"find":"filter"](t,function(t){for(var n in e)if(e[n]!==t[n])return!1;return!0})},k.findWhere=function(t,e){return k.where(t,e,!0)},k.max=function(t,e,n){if(!e&&k.isArray(t)&&t[0]===+t[0]&&t.length<65535)return Math.max.apply(Math,t);if(!e&&k.isEmpty(t))return-(1/0);var r={computed:-(1/0),value:-(1/0)};return T(t,function(t,i,o){var s=e?e.call(n,t,i,o):t;s>=r.computed&&(r={value:t,computed:s})}),r.value},k.min=function(t,e,n){if(!e&&k.isArray(t)&&t[0]===+t[0]&&t.length<65535)return Math.min.apply(Math,t);if(!e&&k.isEmpty(t))return 1/0;var r={computed:1/0,value:1/0};return T(t,function(t,i,o){var s=e?e.call(n,t,i,o):t;s<r.computed&&(r={value:t,computed:s})}),r.value},k.shuffle=function(t){var e,n=0,r=[];return T(t,function(t){e=k.random(n++),r[n-1]=r[e],r[e]=t}),r};var S=function(t){return k.isFunction(t)?t:function(e){return e[t]}};k.sortBy=function(t,e,n){var r=S(e);return k.pluck(k.map(t,function(t,e,i){return{value:t,index:e,criteria:r.call(n,t,e,i)}}).sort(function(t,e){var n=t.criteria,r=e.criteria;if(n!==r){if(n>r||void 0===n)return 1;if(r>n||void 0===r)return-1}return t.index<e.index?-1:1}),"value")};var $=function(t,e,n,r){var i={},o=S(e||k.identity);return T(t,function(e,s){var a=o.call(n,e,s,t);r(i,a,e)}),i};k.groupBy=function(t,e,n){return $(t,e,n,function(t,e,n){(k.has(t,e)?t[e]:t[e]=[]).push(n)})},k.countBy=function(t,e,n){return $(t,e,n,function(t,e){k.has(t,e)||(t[e]=0),t[e]++})},k.sortedIndex=function(t,e,n,r){n=null==n?k.identity:S(n);for(var i=n.call(r,e),o=0,s=t.length;s>o;){var a=o+s>>>1;n.call(r,t[a])<i?o=a+1:s=a}return o},k.toArray=function(t){return t?k.isArray(t)?a.call(t):t.length===+t.length?k.map(t,k.identity):k.values(t):[]},k.size=function(t){return null==t?0:t.length===+t.length?t.length:k.keys(t).length},k.first=k.head=k.take=function(t,e,n){return null==t?void 0:null==e||n?t[0]:a.call(t,0,e)},k.initial=function(t,e,n){return a.call(t,0,t.length-(null==e||n?1:e))},k.last=function(t,e,n){return null==t?void 0:null==e||n?t[t.length-1]:a.call(t,Math.max(t.length-e,0))},k.rest=k.tail=k.drop=function(t,e,n){return a.call(t,null==e||n?1:e)},k.compact=function(t){return k.filter(t,k.identity)};var E=function(t,e,n){return T(t,function(t){k.isArray(t)?e?s.apply(n,t):E(t,e,n):n.push(t)}),n};k.flatten=function(t,e){return E(t,e,[])},k.without=function(t){return k.difference(t,a.call(arguments,1))},k.uniq=k.unique=function(t,e,n,r){k.isFunction(e)&&(r=n,n=e,e=!1);var i=n?k.map(t,n,r):t,o=[],s=[];return T(i,function(n,r){(e?r&&s[s.length-1]===n:k.contains(s,n))||(s.push(n),o.push(t[r]))}),o},k.union=function(){return k.uniq(u.apply(r,arguments))},k.intersection=function(t){var e=a.call(arguments,1);return k.filter(k.uniq(t),function(t){return k.every(e,function(e){return k.indexOf(e,t)>=0})})},k.difference=function(t){var e=u.apply(r,a.call(arguments,1));return k.filter(t,function(t){return!k.contains(e,t)})},k.zip=function(){for(var t=a.call(arguments),e=k.max(k.pluck(t,"length")),n=new Array(e),r=0;e>r;r++)n[r]=k.pluck(t,""+r);return n},k.object=function(t,e){if(null==t)return{};for(var n={},r=0,i=t.length;i>r;r++)e?n[t[r]]=e[r]:n[t[r][0]]=t[r][1];return n},k.indexOf=function(t,e,n){if(null==t)return-1;var r=0,i=t.length;if(n){if("number"!=typeof n)return r=k.sortedIndex(t,e),t[r]===e?r:-1;r=0>n?Math.max(0,i+n):n}if(y&&t.indexOf===y)return t.indexOf(e,n);for(;i>r;r++)if(t[r]===e)return r;return-1},k.lastIndexOf=function(t,e,n){if(null==t)return-1;var r=null!=n;if(b&&t.lastIndexOf===b)return r?t.lastIndexOf(e,n):t.lastIndexOf(e);for(var i=r?n:t.length;i--;)if(t[i]===e)return i;return-1},k.range=function(t,e,n){arguments.length<=1&&(e=t||0,t=0),n=arguments[2]||1;for(var r=Math.max(Math.ceil((e-t)/n),0),i=0,o=new Array(r);r>i;)o[i++]=t,t+=n;return o},k.bind=function(t,e){if(t.bind===C&&C)return C.apply(t,a.call(arguments,1));var n=a.call(arguments,2);return function(){return t.apply(e,n.concat(a.call(arguments)))}},k.partial=function(t){var e=a.call(arguments,1);return function(){return t.apply(this,e.concat(a.call(arguments)))}},k.bindAll=function(t){var e=a.call(arguments,1);return 0===e.length&&(e=k.functions(t)),T(e,function(e){t[e]=k.bind(t[e],t)}),t},k.memoize=function(t,e){var n={};return e||(e=k.identity),function(){var r=e.apply(this,arguments);return k.has(n,r)?n[r]:n[r]=t.apply(this,arguments)}},k.delay=function(t,e){var n=a.call(arguments,2);return setTimeout(function(){return t.apply(null,n)},e)},k.defer=function(t){return k.delay.apply(k,[t,1].concat(a.call(arguments,1)))},k.throttle=function(t,e){var n,r,i,o,s=0,a=function(){s=new Date,i=null,o=t.apply(n,r)};return function(){var u=new Date,l=e-(u-s);return n=this,r=arguments,0>=l?(clearTimeout(i),i=null,s=u,o=t.apply(n,r)):i||(i=setTimeout(a,l)),o}},k.debounce=function(t,e,n){var r,i;return function(){var o=this,s=arguments,a=function(){r=null,n||(i=t.apply(o,s))},u=n&&!r;return clearTimeout(r),r=setTimeout(a,e),u&&(i=t.apply(o,s)),i}},k.once=function(t){var e,n=!1;return function(){return n?e:(n=!0,e=t.apply(this,arguments),t=null,e)}},k.wrap=function(t,e){return function(){var n=[t];return s.apply(n,arguments),e.apply(this,n)}},k.compose=function(){var t=arguments;return function(){for(var e=arguments,n=t.length-1;n>=0;n--)e=[t[n].apply(this,e)];return e[0]}},k.after=function(t,e){return 0>=t?e():function(){return--t<1?e.apply(this,arguments):void 0}},k.keys=x||function(t){if(t!==Object(t))throw new TypeError("Invalid object");var e=[];for(var n in t)k.has(t,n)&&(e[e.length]=n);return e},k.values=function(t){var e=[];for(var n in t)k.has(t,n)&&e.push(t[n]);return e},k.pairs=function(t){var e=[];for(var n in t)k.has(t,n)&&e.push([n,t[n]]);return e},k.invert=function(t){var e={};for(var n in t)k.has(t,n)&&(e[t[n]]=n);return e},k.functions=k.methods=function(t){var e=[];for(var n in t)k.isFunction(t[n])&&e.push(n);return e.sort()},k.extend=function(t){return T(a.call(arguments,1),function(e){if(e)for(var n in e)t[n]=e[n]}),t},k.pick=function(t){var e={},n=u.apply(r,a.call(arguments,1));return T(n,function(n){n in t&&(e[n]=t[n])}),e},k.omit=function(t){var e={},n=u.apply(r,a.call(arguments,1));for(var i in t)k.contains(n,i)||(e[i]=t[i]);return e},k.defaults=function(t){return T(a.call(arguments,1),function(e){if(e)for(var n in e)null==t[n]&&(t[n]=e[n])}),t},k.clone=function(t){return k.isObject(t)?k.isArray(t)?t.slice():k.extend({},t):t},k.tap=function(t,e){return e(t),t};var j=function(t,e,n,r){if(t===e)return 0!==t||1/t==1/e;if(null==t||null==e)return t===e;t instanceof k&&(t=t._wrapped),e instanceof k&&(e=e._wrapped);var i=l.call(t);if(i!=l.call(e))return!1;switch(i){case"[object String]":return t==String(e);case"[object Number]":return t!=+t?e!=+e:0==t?1/t==1/e:t==+e;case"[object Date]":case"[object Boolean]":return+t==+e;case"[object RegExp]":return t.source==e.source&&t.global==e.global&&t.multiline==e.multiline&&t.ignoreCase==e.ignoreCase}if("object"!=typeof t||"object"!=typeof e)return!1;for(var o=n.length;o--;)if(n[o]==t)return r[o]==e;n.push(t),r.push(e);var s=0,a=!0;if("[object Array]"==i){if(s=t.length,a=s==e.length)for(;s--&&(a=j(t[s],e[s],n,r)););}else{var u=t.constructor,c=e.constructor;if(u!==c&&!(k.isFunction(u)&&u instanceof u&&k.isFunction(c)&&c instanceof c))return!1;for(var h in t)if(k.has(t,h)&&(s++,!(a=k.has(e,h)&&j(t[h],e[h],n,r))))break;if(a){for(h in e)if(k.has(e,h)&&!s--)break;a=!s}}return n.pop(),r.pop(),a};k.isEqual=function(t,e){return j(t,e,[],[])},k.isEmpty=function(t){if(null==t)return!0;if(k.isArray(t)||k.isString(t))return 0===t.length;for(var e in t)if(k.has(t,e))return!1;return!0},k.isElement=function(t){return!(!t||1!==t.nodeType)},k.isArray=w||function(t){return"[object Array]"==l.call(t)},k.isObject=function(t){return t===Object(t)},T(["Arguments","Function","String","Number","Date","RegExp"],function(t){k["is"+t]=function(e){return l.call(e)=="[object "+t+"]"}}),k.isArguments(arguments)||(k.isArguments=function(t){return!(!t||!k.has(t,"callee"))}),"function"!=typeof/./&&(k.isFunction=function(t){return"function"==typeof t}),k.isFinite=function(t){return isFinite(t)&&!isNaN(parseFloat(t))},k.isNaN=function(t){return k.isNumber(t)&&t!=+t},k.isBoolean=function(t){return t===!0||t===!1||"[object Boolean]"==l.call(t)},k.isNull=function(t){return null===t},k.isUndefined=function(t){return void 0===t},k.has=function(t,e){return c.call(t,e)},k.noConflict=function(){return t._=e,this},k.identity=function(t){return t},k.times=function(t,e,n){for(var r=Array(t),i=0;t>i;i++)r[i]=e.call(n,i);return r},k.random=function(t,e){return null==e&&(e=t,t=0),t+Math.floor(Math.random()*(e-t+1))};var M={escape:{"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"}};M.unescape=k.invert(M.escape);var D={escape:new RegExp("["+k.keys(M.escape).join("")+"]","g"),unescape:new RegExp("("+k.keys(M.unescape).join("|")+")","g")};k.each(["escape","unescape"],function(t){k[t]=function(e){return null==e?"":(""+e).replace(D[t],function(e){return M[t][e]})}}),k.result=function(t,e){if(null==t)return null;var n=t[e];return k.isFunction(n)?n.call(t):n},k.mixin=function(t){T(k.functions(t),function(e){var n=k[e]=t[e];k.prototype[e]=function(){var t=[this._wrapped];return s.apply(t,arguments),L.call(this,n.apply(k,t))}})};var A=0;k.uniqueId=function(t){var e=++A+"";return t?t+e:e},k.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var O=/(.)^/,R={"'":"'","\\":"\\","\r":"r","\n":"n"," ":"t","\u2028":"u2028","\u2029":"u2029"},P=/\\|'|\r|\n|\t|\u2028|\u2029/g;k.template=function(t,e,n){var r;n=k.defaults({},n,k.templateSettings);var i=new RegExp([(n.escape||O).source,(n.interpolate||O).source,(n.evaluate||O).source].join("|")+"|$","g"),o=0,s="__p+='";t.replace(i,function(e,n,r,i,a){return s+=t.slice(o,a).replace(P,function(t){return"\\"+R[t]}),n&&(s+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'"),r&&(s+="'+\n((__t=("+r+"))==null?'':__t)+\n'"),i&&(s+="';\n"+i+"\n__p+='"),o=a+e.length,e}),s+="';\n",n.variable||(s="with(obj||{}){\n"+s+"}\n"),s="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+s+"return __p;\n";try{r=new Function(n.variable||"obj","_",s)}catch(a){throw a.source=s,a}if(e)return r(e,k);var u=function(t){return r.call(this,t,k)};return u.source="function("+(n.variable||"obj")+"){\n"+s+"}",u},k.chain=function(t){return k(t).chain()};var L=function(t){return this._chain?k(t).chain():t};k.mixin(k),T(["pop","push","reverse","shift","sort","splice","unshift"],function(t){var e=r[t];k.prototype[t]=function(){var n=this._wrapped;return e.apply(n,arguments),"shift"!=t&&"splice"!=t||0!==n.length||delete n[0],L.call(this,n)}}),T(["concat","join","slice"],function(t){var e=r[t];k.prototype[t]=function(){return L.call(this,e.apply(this._wrapped,arguments))}}),k.extend(k.prototype,{chain:function(){return this._chain=!0,this},value:function(){return this._wrapped}})}.call(this),function(){var t,e=this,n=e.Backbone,r=[],i=r.push,o=r.slice,s=r.splice;t="undefined"!=typeof exports?exports:e.Backbone={},t.VERSION="1.0.0";var a=e._;a||"undefined"==typeof require||(a=require("underscore")),t.$=e.jQuery||e.Zepto||e.ender||e.$,t.noConflict=function(){return e.Backbone=n,this},t.emulateHTTP=!1,t.emulateJSON=!1;var u=t.Events={on:function(t,e,n){if(!c(this,"on",t,[e,n])||!e)return this;this._events||(this._events={});var r=this._events[t]||(this._events[t]=[]);return r.push({callback:e,context:n,ctx:n||this}),this},once:function(t,e,n){if(!c(this,"once",t,[e,n])||!e)return this;var r=this,i=a.once(function(){r.off(t,i),e.apply(this,arguments)});return i._callback=e,this.on(t,i,n)},off:function(t,e,n){var r,i,o,s,u,l,h,f;if(!this._events||!c(this,"off",t,[e,n]))return this;if(!t&&!e&&!n)return this._events={},this;for(s=t?[t]:a.keys(this._events),u=0,l=s.length;l>u;u++)if(t=s[u],o=this._events[t]){if(this._events[t]=r=[],e||n)for(h=0,f=o.length;f>h;h++)i=o[h],(e&&e!==i.callback&&e!==i.callback._callback||n&&n!==i.context)&&r.push(i);r.length||delete this._events[t]}return this},trigger:function(t){if(!this._events)return this;var e=o.call(arguments,1);if(!c(this,"trigger",t,e))return this;var n=this._events[t],r=this._events.all;return n&&h(n,e),r&&h(r,arguments),this},stopListening:function(t,e,n){var r=this._listeners;if(!r)return this;var i=!e&&!n;"object"==typeof e&&(n=this),t&&((r={})[t._listenerId]=t);for(var o in r)r[o].off(e,n,this),i&&delete this._listeners[o];return this}},l=/\s+/,c=function(t,e,n,r){if(!n)return!0;if("object"==typeof n){for(var i in n)t[e].apply(t,[i,n[i]].concat(r));return!1}if(l.test(n)){for(var o=n.split(l),s=0,a=o.length;a>s;s++)t[e].apply(t,[o[s]].concat(r));return!1}return!0},h=function(t,e){var n,r=-1,i=t.length,o=e[0],s=e[1],a=e[2];switch(e.length){case 0:for(;++r<i;)(n=t[r]).callback.call(n.ctx);return;case 1:for(;++r<i;)(n=t[r]).callback.call(n.ctx,o);return;case 2:for(;++r<i;)(n=t[r]).callback.call(n.ctx,o,s);return;case 3:for(;++r<i;)(n=t[r]).callback.call(n.ctx,o,s,a);return;default:for(;++r<i;)(n=t[r]).callback.apply(n.ctx,e)}},f={listenTo:"on",listenToOnce:"once"};a.each(f,function(t,e){u[e]=function(e,n,r){var i=this._listeners||(this._listeners={}),o=e._listenerId||(e._listenerId=a.uniqueId("l"));return i[o]=e,"object"==typeof n&&(r=this),e[t](n,r,this),this}}),u.bind=u.on,u.unbind=u.off,a.extend(t,u);var p=t.Model=function(t,e){var n,r=t||{};e||(e={}),this.cid=a.uniqueId("c"),this.attributes={},a.extend(this,a.pick(e,d)),e.parse&&(r=this.parse(r,e)||{}),(n=a.result(this,"defaults"))&&(r=a.defaults({},r,n)),this.set(r,e),this.changed={},this.initialize.apply(this,arguments)},d=["url","urlRoot","collection"];a.extend(p.prototype,u,{changed:null,validationError:null,idAttribute:"id",initialize:function(){},toJSON:function(t){return a.clone(this.attributes)},sync:function(){return t.sync.apply(this,arguments)},get:function(t){return this.attributes[t]},escape:function(t){return a.escape(this.get(t))},has:function(t){return null!=this.get(t)},set:function(t,e,n){var r,i,o,s,u,l,c,h;if(null==t)return this;if("object"==typeof t?(i=t,n=e):(i={})[t]=e,n||(n={}),!this._validate(i,n))return!1;o=n.unset,u=n.silent,s=[],l=this._changing,this._changing=!0,l||(this._previousAttributes=a.clone(this.attributes),this.changed={}),h=this.attributes,c=this._previousAttributes,this.idAttribute in i&&(this.id=i[this.idAttribute]);for(r in i)e=i[r],a.isEqual(h[r],e)||s.push(r),a.isEqual(c[r],e)?delete this.changed[r]:this.changed[r]=e,o?delete h[r]:h[r]=e;if(!u){s.length&&(this._pending=!0);for(var f=0,p=s.length;p>f;f++)this.trigger("change:"+s[f],this,h[s[f]],n)}if(l)return this;if(!u)for(;this._pending;)this._pending=!1,this.trigger("change",this,n);return this._pending=!1,this._changing=!1,this},unset:function(t,e){return this.set(t,void 0,a.extend({},e,{unset:!0}))},clear:function(t){var e={};for(var n in this.attributes)e[n]=void 0;return this.set(e,a.extend({},t,{unset:!0}))},hasChanged:function(t){return null==t?!a.isEmpty(this.changed):a.has(this.changed,t)},changedAttributes:function(t){if(!t)return this.hasChanged()?a.clone(this.changed):!1;var e,n=!1,r=this._changing?this._previousAttributes:this.attributes;for(var i in t)a.isEqual(r[i],e=t[i])||((n||(n={}))[i]=e);return n},previous:function(t){return null!=t&&this._previousAttributes?this._previousAttributes[t]:null},previousAttributes:function(){return a.clone(this._previousAttributes)},fetch:function(t){t=t?a.clone(t):{},void 0===t.parse&&(t.parse=!0);var e=this,n=t.success;return t.success=function(r){return e.set(e.parse(r,t),t)?(n&&n(e,r,t),void e.trigger("sync",e,r,t)):!1},L(this,t),this.sync("read",this,t)},save:function(t,e,n){var r,i,o,s=this.attributes;if(null==t||"object"==typeof t?(r=t,n=e):(r={})[t]=e,r&&(!n||!n.wait)&&!this.set(r,n))return!1;if(n=a.extend({validate:!0},n),!this._validate(r,n))return!1;r&&n.wait&&(this.attributes=a.extend({},s,r)),void 0===n.parse&&(n.parse=!0);var u=this,l=n.success;return n.success=function(t){u.attributes=s;var e=u.parse(t,n);return n.wait&&(e=a.extend(r||{},e)),a.isObject(e)&&!u.set(e,n)?!1:(l&&l(u,t,n),void u.trigger("sync",u,t,n))},L(this,n),i=this.isNew()?"create":n.patch?"patch":"update","patch"===i&&(n.attrs=r),o=this.sync(i,this,n),r&&n.wait&&(this.attributes=s),o},destroy:function(t){t=t?a.clone(t):{};var e=this,n=t.success,r=function(){e.trigger("destroy",e,e.collection,t)};if(t.success=function(i){(t.wait||e.isNew())&&r(),n&&n(e,i,t),e.isNew()||e.trigger("sync",e,i,t)},this.isNew())return t.success(),!1;L(this,t);var i=this.sync("delete",this,t);return t.wait||r(),i},url:function(){var t=a.result(this,"urlRoot")||a.result(this.collection,"url")||P();return this.isNew()?t:t+("/"===t.charAt(t.length-1)?"":"/")+encodeURIComponent(this.id)},parse:function(t,e){return t},clone:function(){return new this.constructor(this.attributes)},isNew:function(){return null==this.id},isValid:function(t){return this._validate({},a.extend(t||{},{validate:!0}))},_validate:function(t,e){if(!e.validate||!this.validate)return!0;t=a.extend({},this.attributes,t);var n=this.validationError=this.validate(t,e)||null;return n?(this.trigger("invalid",this,n,a.extend(e||{},{validationError:n})),!1):!0}});var m=["keys","values","pairs","invert","pick","omit"];a.each(m,function(t){p.prototype[t]=function(){var e=o.call(arguments);return e.unshift(this.attributes),a[t].apply(a,e)}});var g=t.Collection=function(t,e){e||(e={}),e.url&&(this.url=e.url),e.model&&(this.model=e.model),void 0!==e.comparator&&(this.comparator=e.comparator),this._reset(),this.initialize.apply(this,arguments),t&&this.reset(t,a.extend({silent:!0},e))},v={add:!0,remove:!0,merge:!0},y={add:!0,merge:!1,remove:!1};a.extend(g.prototype,u,{model:p,initialize:function(){},toJSON:function(t){return this.map(function(e){return e.toJSON(t)})},sync:function(){return t.sync.apply(this,arguments)},add:function(t,e){return this.set(t,a.defaults(e||{},y))},remove:function(t,e){t=a.isArray(t)?t.slice():[t],e||(e={});var n,r,i,o;for(n=0,r=t.length;r>n;n++)o=this.get(t[n]),o&&(delete this._byId[o.id],delete this._byId[o.cid],i=this.indexOf(o),this.models.splice(i,1),this.length--,e.silent||(e.index=i,o.trigger("remove",o,this,e)),this._removeReference(o));return this},set:function(t,e){e=a.defaults(e||{},v),e.parse&&(t=this.parse(t,e)),a.isArray(t)||(t=t?[t]:[]);var n,r,o,u,l,c=e.at,h=this.comparator&&null==c&&e.sort!==!1,f=a.isString(this.comparator)?this.comparator:null,p=[],d=[],m={};for(n=0,r=t.length;r>n;n++)(o=this._prepareModel(t[n],e))&&((u=this.get(o))?(e.remove&&(m[u.cid]=!0),e.merge&&(u.set(o.attributes,e),h&&!l&&u.hasChanged(f)&&(l=!0))):e.add&&(p.push(o),o.on("all",this._onModelEvent,this),this._byId[o.cid]=o,null!=o.id&&(this._byId[o.id]=o)));if(e.remove){for(n=0,r=this.length;r>n;++n)m[(o=this.models[n]).cid]||d.push(o);d.length&&this.remove(d,e)}if(p.length&&(h&&(l=!0),this.length+=p.length,null!=c?s.apply(this.models,[c,0].concat(p)):i.apply(this.models,p)),l&&this.sort({silent:!0}),e.silent)return this;for(n=0,r=p.length;r>n;n++)(o=p[n]).trigger("add",o,this,e);return l&&this.trigger("sort",this,e),this},reset:function(t,e){e||(e={});for(var n=0,r=this.models.length;r>n;n++)this._removeReference(this.models[n]);return e.previousModels=this.models,this._reset(),this.add(t,a.extend({silent:!0},e)),e.silent||this.trigger("reset",this,e),this},push:function(t,e){return t=this._prepareModel(t,e),this.add(t,a.extend({at:this.length},e)),t},pop:function(t){var e=this.at(this.length-1);return this.remove(e,t),e},unshift:function(t,e){return t=this._prepareModel(t,e),this.add(t,a.extend({at:0},e)),t},shift:function(t){var e=this.at(0);return this.remove(e,t),e},slice:function(t,e){return this.models.slice(t,e)},get:function(t){return null==t?void 0:this._byId[null!=t.id?t.id:t.cid||t]},at:function(t){return this.models[t]},where:function(t,e){return a.isEmpty(t)?e?void 0:[]:this[e?"find":"filter"](function(e){for(var n in t)if(t[n]!==e.get(n))return!1;return!0})},findWhere:function(t){return this.where(t,!0)},sort:function(t){if(!this.comparator)throw new Error("Cannot sort a set without a comparator");return t||(t={}),a.isString(this.comparator)||1===this.comparator.length?this.models=this.sortBy(this.comparator,this):this.models.sort(a.bind(this.comparator,this)),t.silent||this.trigger("sort",this,t),this},sortedIndex:function(t,e,n){e||(e=this.comparator);var r=a.isFunction(e)?e:function(t){return t.get(e)};return a.sortedIndex(this.models,t,r,n)},pluck:function(t){return a.invoke(this.models,"get",t)},fetch:function(t){t=t?a.clone(t):{},void 0===t.parse&&(t.parse=!0);var e=t.success,n=this;return t.success=function(r){var i=t.reset?"reset":"set";n[i](r,t),e&&e(n,r,t),n.trigger("sync",n,r,t)},L(this,t),this.sync("read",this,t)},create:function(t,e){if(e=e?a.clone(e):{},!(t=this._prepareModel(t,e)))return!1;e.wait||this.add(t,e);var n=this,r=e.success;return e.success=function(i){e.wait&&n.add(t,e),r&&r(t,i,e)},t.save(null,e),t},parse:function(t,e){return t},clone:function(){return new this.constructor(this.models)},_reset:function(){this.length=0,this.models=[],this._byId={}},_prepareModel:function(t,e){if(t instanceof p)return t.collection||(t.collection=this),t;e||(e={}),e.collection=this;var n=new this.model(t,e);return n._validate(t,e)?n:(this.trigger("invalid",this,t,e),!1)},_removeReference:function(t){this===t.collection&&delete t.collection,t.off("all",this._onModelEvent,this)},_onModelEvent:function(t,e,n,r){("add"!==t&&"remove"!==t||n===this)&&("destroy"===t&&this.remove(e,r),e&&t==="change:"+e.idAttribute&&(delete this._byId[e.previous(e.idAttribute)],null!=e.id&&(this._byId[e.id]=e)),this.trigger.apply(this,arguments))}});var b=["forEach","each","map","collect","reduce","foldl","inject","reduceRight","foldr","find","detect","filter","select","reject","every","all","some","any","include","contains","invoke","max","min","toArray","size","first","head","take","initial","rest","tail","drop","last","without","indexOf","shuffle","lastIndexOf","isEmpty","chain"];a.each(b,function(t){g.prototype[t]=function(){var e=o.call(arguments);return e.unshift(this.models),a[t].apply(a,e)}});var w=["groupBy","countBy","sortBy"];a.each(w,function(t){g.prototype[t]=function(e,n){var r=a.isFunction(e)?e:function(t){return t.get(e)};return a[t](this.models,r,n)}});var x=t.View=function(t){this.cid=a.uniqueId("view"),this._configure(t||{}),this._ensureElement(),this.initialize.apply(this,arguments),this.delegateEvents()},C=/^(\S+)\s*(.*)$/,k=["model","collection","el","id","attributes","className","tagName","events"];a.extend(x.prototype,u,{tagName:"div",$:function(t){return this.$el.find(t)},initialize:function(){},render:function(){return this},remove:function(){return this.$el.remove(),this.stopListening(),this},setElement:function(e,n){return this.$el&&this.undelegateEvents(),this.$el=e instanceof t.$?e:t.$(e),this.el=this.$el[0],n!==!1&&this.delegateEvents(),this},delegateEvents:function(t){if(!t&&!(t=a.result(this,"events")))return this;this.undelegateEvents();for(var e in t){var n=t[e];if(a.isFunction(n)||(n=this[t[e]]),n){var r=e.match(C),i=r[1],o=r[2];n=a.bind(n,this),i+=".delegateEvents"+this.cid,""===o?this.$el.on(i,n):this.$el.on(i,o,n)}}return this},undelegateEvents:function(){return this.$el.off(".delegateEvents"+this.cid),this},_configure:function(t){this.options&&(t=a.extend({},a.result(this,"options"),t)),a.extend(this,a.pick(t,k)),this.options=t},_ensureElement:function(){if(this.el)this.setElement(a.result(this,"el"),!1);else{var e=a.extend({},a.result(this,"attributes"));this.id&&(e.id=a.result(this,"id")),this.className&&(e["class"]=a.result(this,"className"));var n=t.$("<"+a.result(this,"tagName")+">").attr(e);this.setElement(n,!1)}}}),t.sync=function(e,n,r){var i=T[e];a.defaults(r||(r={}),{emulateHTTP:t.emulateHTTP,emulateJSON:t.emulateJSON});var o={type:i,dataType:"json"};if(r.url||(o.url=a.result(n,"url")||P()),null!=r.data||!n||"create"!==e&&"update"!==e&&"patch"!==e||(o.contentType="application/json",o.data=JSON.stringify(r.attrs||n.toJSON(r))),r.emulateJSON&&(o.contentType="application/x-www-form-urlencoded",o.data=o.data?{model:o.data}:{}),r.emulateHTTP&&("PUT"===i||"DELETE"===i||"PATCH"===i)){o.type="POST",r.emulateJSON&&(o.data._method=i);var s=r.beforeSend;r.beforeSend=function(t){return t.setRequestHeader("X-HTTP-Method-Override",i),s?s.apply(this,arguments):void 0}}"GET"===o.type||r.emulateJSON||(o.processData=!1),"PATCH"!==o.type||!window.ActiveXObject||window.external&&window.external.msActiveXFilteringEnabled||(o.xhr=function(){return new ActiveXObject("Microsoft.XMLHTTP")});var u=r.xhr=t.ajax(a.extend(o,r));return n.trigger("request",n,u,r),u};var T={create:"POST",update:"PUT",patch:"PATCH","delete":"DELETE",read:"GET"};t.ajax=function(){return t.$.ajax.apply(t.$,arguments)};var _=t.Router=function(t){t||(t={}),t.routes&&(this.routes=t.routes),this._bindRoutes(),this.initialize.apply(this,arguments)},N=/\((.*?)\)/g,S=/(\(\?)?:\w+/g,$=/\*\w+/g,E=/[\-{}\[\]+?.,\\\^$|#\s]/g;a.extend(_.prototype,u,{initialize:function(){},route:function(e,n,r){a.isRegExp(e)||(e=this._routeToRegExp(e)),a.isFunction(n)&&(r=n,n=""),r||(r=this[n]);var i=this;return t.history.route(e,function(o){var s=i._extractParameters(e,o);r&&r.apply(i,s),i.trigger.apply(i,["route:"+n].concat(s)),i.trigger("route",n,s),t.history.trigger("route",i,n,s)}),this},navigate:function(e,n){return t.history.navigate(e,n),this},_bindRoutes:function(){if(this.routes){this.routes=a.result(this,"routes");for(var t,e=a.keys(this.routes);null!=(t=e.pop());)this.route(t,this.routes[t])}},_routeToRegExp:function(t){return t=t.replace(E,"\\$&").replace(N,"(?:$1)?").replace(S,function(t,e){return e?t:"([^/]+)"}).replace($,"(.*?)"),new RegExp("^"+t+"$")},_extractParameters:function(t,e){var n=t.exec(e).slice(1);return a.map(n,function(t){return t?decodeURIComponent(t):null})}});var j=t.History=function(){this.handlers=[],a.bindAll(this,"checkUrl"),"undefined"!=typeof window&&(this.location=window.location,this.history=window.history)},M=/^[#\/]|\s+$/g,D=/^\/+|\/+$/g,A=/msie [\w.]+/,O=/\/$/;j.started=!1,a.extend(j.prototype,u,{interval:50,getHash:function(t){var e=(t||this).location.href.match(/#(.*)$/);return e?e[1]:""},getFragment:function(t,e){if(null==t)if(this._hasPushState||!this._wantsHashChange||e){t=this.location.pathname;var n=this.root.replace(O,"");t.indexOf(n)||(t=t.substr(n.length))}else t=this.getHash();return t.replace(M,"")},start:function(e){if(j.started)throw new Error("Backbone.history has already been started");j.started=!0,this.options=a.extend({},{root:"/"},this.options,e),this.root=this.options.root,this._wantsHashChange=this.options.hashChange!==!1,this._wantsPushState=!!this.options.pushState,this._hasPushState=!!(this.options.pushState&&this.history&&this.history.pushState);var n=this.getFragment(),r=document.documentMode,i=A.exec(navigator.userAgent.toLowerCase())&&(!r||7>=r);this.root=("/"+this.root+"/").replace(D,"/"),i&&this._wantsHashChange&&(this.iframe=t.$('<iframe src="javascript:0" tabindex="-1" />').hide().appendTo("body")[0].contentWindow,this.navigate(n)),this._hasPushState?t.$(window).on("popstate",this.checkUrl):this._wantsHashChange&&"onhashchange"in window&&!i?t.$(window).on("hashchange",this.checkUrl):this._wantsHashChange&&(this._checkUrlInterval=setInterval(this.checkUrl,this.interval)),this.fragment=n;var o=this.location,s=o.pathname.replace(/[^\/]$/,"$&/")===this.root;return this._wantsHashChange&&this._wantsPushState&&!this._hasPushState&&!s?(this.fragment=this.getFragment(null,!0),this.location.replace(this.root+this.location.search+"#"+this.fragment),!0):(this._wantsPushState&&this._hasPushState&&s&&o.hash&&(this.fragment=this.getHash().replace(M,""),this.history.replaceState({},document.title,this.root+this.fragment+o.search)),
|
27
|
-
this.options.silent?void 0:this.loadUrl())},stop:function(){t.$(window).off("popstate",this.checkUrl).off("hashchange",this.checkUrl),clearInterval(this._checkUrlInterval),j.started=!1},route:function(t,e){this.handlers.unshift({route:t,callback:e})},checkUrl:function(t){var e=this.getFragment();return e===this.fragment&&this.iframe&&(e=this.getFragment(this.getHash(this.iframe))),e===this.fragment?!1:(this.iframe&&this.navigate(e),void(this.loadUrl()||this.loadUrl(this.getHash())))},loadUrl:function(t){var e=this.fragment=this.getFragment(t),n=a.any(this.handlers,function(t){return t.route.test(e)?(t.callback(e),!0):void 0});return n},navigate:function(t,e){if(!j.started)return!1;if(e&&e!==!0||(e={trigger:e}),t=this.getFragment(t||""),this.fragment!==t){this.fragment=t;var n=this.root+t;if(this._hasPushState)this.history[e.replace?"replaceState":"pushState"]({},document.title,n);else{if(!this._wantsHashChange)return this.location.assign(n);this._updateHash(this.location,t,e.replace),this.iframe&&t!==this.getFragment(this.getHash(this.iframe))&&(e.replace||this.iframe.document.open().close(),this._updateHash(this.iframe.location,t,e.replace))}e.trigger&&this.loadUrl(t)}},_updateHash:function(t,e,n){if(n){var r=t.href.replace(/(javascript:|#).*$/,"");t.replace(r+"#"+e)}else t.hash="#"+e}}),t.history=new j;var R=function(t,e){var n,r=this;n=t&&a.has(t,"constructor")?t.constructor:function(){return r.apply(this,arguments)},a.extend(n,r,e);var i=function(){this.constructor=n};return i.prototype=r.prototype,n.prototype=new i,t&&a.extend(n.prototype,t),n.__super__=r.prototype,n};p.extend=g.extend=_.extend=x.extend=j.extend=R;var P=function(){throw new Error('A "url" property or function must be specified')},L=function(t,e){var n=e.error;e.error=function(r){n&&n(t,r,e),t.trigger("error",t,r,e)}}}.call(this),/* ===================================================
|
28
|
-
* bootstrap-transition.js v2.3.1
|
29
|
-
*
|
30
|
-
* ===================================================
|
31
|
-
* Copyright 2012 Twitter, Inc.
|
32
|
-
*
|
33
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
34
|
-
* you may not use this file except in compliance with the License.
|
35
|
-
* You may obtain a copy of the License at
|
36
|
-
*
|
37
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
38
|
-
*
|
39
|
-
* Unless required by applicable law or agreed to in writing, software
|
40
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
41
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
42
|
-
* See the License for the specific language governing permissions and
|
43
|
-
* limitations under the License.
|
44
|
-
* ========================================================== */
|
45
|
-
!function(t){"use strict";t(function(){t.support.transition=function(){var t=function(){var t,e=document.createElement("bootstrap"),n={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(t in n)if(void 0!==e.style[t])return n[t]}();return t&&{end:t}}()})}(window.jQuery),/* ==========================================================
|
46
|
-
* bootstrap-alert.js v2.3.1
|
47
|
-
* http://twitter.github.com/bootstrap/javascript.html#alerts
|
48
|
-
* ==========================================================
|
49
|
-
* Copyright 2012 Twitter, Inc.
|
50
|
-
*
|
51
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
52
|
-
* you may not use this file except in compliance with the License.
|
53
|
-
* You may obtain a copy of the License at
|
54
|
-
*
|
55
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
56
|
-
*
|
57
|
-
* Unless required by applicable law or agreed to in writing, software
|
58
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
59
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
60
|
-
* See the License for the specific language governing permissions and
|
61
|
-
* limitations under the License.
|
62
|
-
* ========================================================== */
|
63
|
-
!function(t){"use strict";var e='[data-dismiss="alert"]',n=function(n){t(n).on("click",e,this.close)};n.prototype.close=function(e){function n(){r.trigger("closed").remove()}var r,i=t(this),o=i.attr("data-target");o||(o=i.attr("href"),o=o&&o.replace(/.*(?=#[^\s]*$)/,"")),r=t(o),e&&e.preventDefault(),r.length||(r=i.hasClass("alert")?i:i.parent()),r.trigger(e=t.Event("close")),e.isDefaultPrevented()||(r.removeClass("in"),t.support.transition&&r.hasClass("fade")?r.on(t.support.transition.end,n):n())};var r=t.fn.alert;t.fn.alert=function(e){return this.each(function(){var r=t(this),i=r.data("alert");i||r.data("alert",i=new n(this)),"string"==typeof e&&i[e].call(r)})},t.fn.alert.Constructor=n,t.fn.alert.noConflict=function(){return t.fn.alert=r,this},t(document).on("click.alert.data-api",e,n.prototype.close)}(window.jQuery),/* ============================================================
|
64
|
-
* bootstrap-button.js v2.3.1
|
65
|
-
* http://twitter.github.com/bootstrap/javascript.html#buttons
|
66
|
-
* ============================================================
|
67
|
-
* Copyright 2012 Twitter, Inc.
|
68
|
-
*
|
69
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
70
|
-
* you may not use this file except in compliance with the License.
|
71
|
-
* You may obtain a copy of the License at
|
72
|
-
*
|
73
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
74
|
-
*
|
75
|
-
* Unless required by applicable law or agreed to in writing, software
|
76
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
77
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
78
|
-
* See the License for the specific language governing permissions and
|
79
|
-
* limitations under the License.
|
80
|
-
* ============================================================ */
|
81
|
-
!function(t){"use strict";var e=function(e,n){this.$element=t(e),this.options=t.extend({},t.fn.button.defaults,n)};e.prototype.setState=function(t){var e="disabled",n=this.$element,r=n.data(),i=n.is("input")?"val":"html";t+="Text",r.resetText||n.data("resetText",n[i]()),n[i](r[t]||this.options[t]),setTimeout(function(){"loadingText"==t?n.addClass(e).attr(e,e):n.removeClass(e).removeAttr(e)},0)},e.prototype.toggle=function(){var t=this.$element.closest('[data-toggle="buttons-radio"]');t&&t.find(".active").removeClass("active"),this.$element.toggleClass("active")};var n=t.fn.button;t.fn.button=function(n){return this.each(function(){var r=t(this),i=r.data("button"),o="object"==typeof n&&n;i||r.data("button",i=new e(this,o)),"toggle"==n?i.toggle():n&&i.setState(n)})},t.fn.button.defaults={loadingText:"loading..."},t.fn.button.Constructor=e,t.fn.button.noConflict=function(){return t.fn.button=n,this},t(document).on("click.button.data-api","[data-toggle^=button]",function(e){var n=t(e.target);n.hasClass("btn")||(n=n.closest(".btn")),n.button("toggle")})}(window.jQuery),/* ==========================================================
|
82
|
-
* bootstrap-carousel.js v2.3.1
|
83
|
-
* http://twitter.github.com/bootstrap/javascript.html#carousel
|
84
|
-
* ==========================================================
|
85
|
-
* Copyright 2012 Twitter, Inc.
|
86
|
-
*
|
87
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
88
|
-
* you may not use this file except in compliance with the License.
|
89
|
-
* You may obtain a copy of the License at
|
90
|
-
*
|
91
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
92
|
-
*
|
93
|
-
* Unless required by applicable law or agreed to in writing, software
|
94
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
95
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
96
|
-
* See the License for the specific language governing permissions and
|
97
|
-
* limitations under the License.
|
98
|
-
* ========================================================== */
|
99
|
-
!function(t){"use strict";var e=function(e,n){this.$element=t(e),this.$indicators=this.$element.find(".carousel-indicators"),this.options=n,"hover"==this.options.pause&&this.$element.on("mouseenter",t.proxy(this.pause,this)).on("mouseleave",t.proxy(this.cycle,this))};e.prototype={cycle:function(e){return e||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(t.proxy(this.next,this),this.options.interval)),this},getActiveIndex:function(){return this.$active=this.$element.find(".item.active"),this.$items=this.$active.parent().children(),this.$items.index(this.$active)},to:function(e){var n=this.getActiveIndex(),r=this;if(!(e>this.$items.length-1||0>e))return this.sliding?this.$element.one("slid",function(){r.to(e)}):n==e?this.pause().cycle():this.slide(e>n?"next":"prev",t(this.$items[e]))},pause:function(e){return e||(this.paused=!0),this.$element.find(".next, .prev").length&&t.support.transition.end&&(this.$element.trigger(t.support.transition.end),this.cycle(!0)),clearInterval(this.interval),this.interval=null,this},next:function(){return this.sliding?void 0:this.slide("next")},prev:function(){return this.sliding?void 0:this.slide("prev")},slide:function(e,n){var r,i=this.$element.find(".item.active"),o=n||i[e](),s=this.interval,a="next"==e?"left":"right",u="next"==e?"first":"last",l=this;if(this.sliding=!0,s&&this.pause(),o=o.length?o:this.$element.find(".item")[u](),r=t.Event("slide",{relatedTarget:o[0],direction:a}),!o.hasClass("active")){if(this.$indicators.length&&(this.$indicators.find(".active").removeClass("active"),this.$element.one("slid",function(){var e=t(l.$indicators.children()[l.getActiveIndex()]);e&&e.addClass("active")})),t.support.transition&&this.$element.hasClass("slide")){if(this.$element.trigger(r),r.isDefaultPrevented())return;o.addClass(e),o[0].offsetWidth,i.addClass(a),o.addClass(a),this.$element.one(t.support.transition.end,function(){o.removeClass([e,a].join(" ")).addClass("active"),i.removeClass(["active",a].join(" ")),l.sliding=!1,setTimeout(function(){l.$element.trigger("slid")},0)})}else{if(this.$element.trigger(r),r.isDefaultPrevented())return;i.removeClass("active"),o.addClass("active"),this.sliding=!1,this.$element.trigger("slid")}return s&&this.cycle(),this}}};var n=t.fn.carousel;t.fn.carousel=function(n){return this.each(function(){var r=t(this),i=r.data("carousel"),o=t.extend({},t.fn.carousel.defaults,"object"==typeof n&&n),s="string"==typeof n?n:o.slide;i||r.data("carousel",i=new e(this,o)),"number"==typeof n?i.to(n):s?i[s]():o.interval&&i.pause().cycle()})},t.fn.carousel.defaults={interval:5e3,pause:"hover"},t.fn.carousel.Constructor=e,t.fn.carousel.noConflict=function(){return t.fn.carousel=n,this},t(document).on("click.carousel.data-api","[data-slide], [data-slide-to]",function(e){var n,r,i=t(this),o=t(i.attr("data-target")||(n=i.attr("href"))&&n.replace(/.*(?=#[^\s]+$)/,"")),s=t.extend({},o.data(),i.data());o.carousel(s),(r=i.attr("data-slide-to"))&&o.data("carousel").pause().to(r).cycle(),e.preventDefault()})}(window.jQuery),/* =============================================================
|
100
|
-
* bootstrap-collapse.js v2.3.1
|
101
|
-
* http://twitter.github.com/bootstrap/javascript.html#collapse
|
102
|
-
* =============================================================
|
103
|
-
* Copyright 2012 Twitter, Inc.
|
104
|
-
*
|
105
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
106
|
-
* you may not use this file except in compliance with the License.
|
107
|
-
* You may obtain a copy of the License at
|
108
|
-
*
|
109
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
110
|
-
*
|
111
|
-
* Unless required by applicable law or agreed to in writing, software
|
112
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
113
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
114
|
-
* See the License for the specific language governing permissions and
|
115
|
-
* limitations under the License.
|
116
|
-
* ============================================================ */
|
117
|
-
!function(t){"use strict";var e=function(e,n){this.$element=t(e),this.options=t.extend({},t.fn.collapse.defaults,n),this.options.parent&&(this.$parent=t(this.options.parent)),this.options.toggle&&this.toggle()};e.prototype={constructor:e,dimension:function(){var t=this.$element.hasClass("width");return t?"width":"height"},show:function(){var e,n,r,i;if(!this.transitioning&&!this.$element.hasClass("in")){if(e=this.dimension(),n=t.camelCase(["scroll",e].join("-")),r=this.$parent&&this.$parent.find("> .accordion-group > .in"),r&&r.length){if(i=r.data("collapse"),i&&i.transitioning)return;r.collapse("hide"),i||r.data("collapse",null)}this.$element[e](0),this.transition("addClass",t.Event("show"),"shown"),t.support.transition&&this.$element[e](this.$element[0][n])}},hide:function(){var e;!this.transitioning&&this.$element.hasClass("in")&&(e=this.dimension(),this.reset(this.$element[e]()),this.transition("removeClass",t.Event("hide"),"hidden"),this.$element[e](0))},reset:function(t){var e=this.dimension();return this.$element.removeClass("collapse")[e](t||"auto")[0].offsetWidth,this.$element[null!==t?"addClass":"removeClass"]("collapse"),this},transition:function(e,n,r){var i=this,o=function(){"show"==n.type&&i.reset(),i.transitioning=0,i.$element.trigger(r)};this.$element.trigger(n),n.isDefaultPrevented()||(this.transitioning=1,this.$element[e]("in"),t.support.transition&&this.$element.hasClass("collapse")?this.$element.one(t.support.transition.end,o):o())},toggle:function(){this[this.$element.hasClass("in")?"hide":"show"]()}};var n=t.fn.collapse;t.fn.collapse=function(n){return this.each(function(){var r=t(this),i=r.data("collapse"),o=t.extend({},t.fn.collapse.defaults,r.data(),"object"==typeof n&&n);i||r.data("collapse",i=new e(this,o)),"string"==typeof n&&i[n]()})},t.fn.collapse.defaults={toggle:!0},t.fn.collapse.Constructor=e,t.fn.collapse.noConflict=function(){return t.fn.collapse=n,this},t(document).on("click.collapse.data-api","[data-toggle=collapse]",function(e){var n,r=t(this),i=r.attr("data-target")||e.preventDefault()||(n=r.attr("href"))&&n.replace(/.*(?=#[^\s]+$)/,""),o=t(i).data("collapse")?"toggle":r.data();r[t(i).hasClass("in")?"addClass":"removeClass"]("collapsed"),t(i).collapse(o)})}(window.jQuery),/* ============================================================
|
118
|
-
* bootstrap-dropdown.js v2.3.1
|
119
|
-
* http://twitter.github.com/bootstrap/javascript.html#dropdowns
|
120
|
-
* ============================================================
|
121
|
-
* Copyright 2012 Twitter, Inc.
|
122
|
-
*
|
123
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
124
|
-
* you may not use this file except in compliance with the License.
|
125
|
-
* You may obtain a copy of the License at
|
126
|
-
*
|
127
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
128
|
-
*
|
129
|
-
* Unless required by applicable law or agreed to in writing, software
|
130
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
131
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
132
|
-
* See the License for the specific language governing permissions and
|
133
|
-
* limitations under the License.
|
134
|
-
* ============================================================ */
|
135
|
-
!function(t){"use strict";function e(){t(r).each(function(){n(t(this)).removeClass("open")})}function n(e){var n,r=e.attr("data-target");return r||(r=e.attr("href"),r=r&&/#/.test(r)&&r.replace(/.*(?=#[^\s]*$)/,"")),n=r&&t(r),n&&n.length||(n=e.parent()),n}var r="[data-toggle=dropdown]",i=function(e){var n=t(e).on("click.dropdown.data-api",this.toggle);t("html").on("click.dropdown.data-api",function(){n.parent().removeClass("open")})};i.prototype={constructor:i,toggle:function(r){var i,o,s=t(this);if(!s.is(".disabled, :disabled"))return i=n(s),o=i.hasClass("open"),e(),o||i.toggleClass("open"),s.focus(),!1},keydown:function(e){var i,o,s,a,u;if(/(38|40|27)/.test(e.keyCode)&&(i=t(this),e.preventDefault(),e.stopPropagation(),!i.is(".disabled, :disabled"))){if(s=n(i),a=s.hasClass("open"),!a||a&&27==e.keyCode)return 27==e.which&&s.find(r).focus(),i.click();o=t("[role=menu] li:not(.divider):visible a",s),o.length&&(u=o.index(o.filter(":focus")),38==e.keyCode&&u>0&&u--,40==e.keyCode&&u<o.length-1&&u++,~u||(u=0),o.eq(u).focus())}}};var o=t.fn.dropdown;t.fn.dropdown=function(e){return this.each(function(){var n=t(this),r=n.data("dropdown");r||n.data("dropdown",r=new i(this)),"string"==typeof e&&r[e].call(n)})},t.fn.dropdown.Constructor=i,t.fn.dropdown.noConflict=function(){return t.fn.dropdown=o,this},t(document).on("click.dropdown.data-api",e).on("click.dropdown.data-api",".dropdown form",function(t){t.stopPropagation()}).on("click.dropdown-menu",function(t){t.stopPropagation()}).on("click.dropdown.data-api",r,i.prototype.toggle).on("keydown.dropdown.data-api",r+", [role=menu]",i.prototype.keydown)}(window.jQuery),/* =========================================================
|
136
|
-
* bootstrap-modal.js v2.3.1
|
137
|
-
* http://twitter.github.com/bootstrap/javascript.html#modals
|
138
|
-
* =========================================================
|
139
|
-
* Copyright 2012 Twitter, Inc.
|
140
|
-
*
|
141
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
142
|
-
* you may not use this file except in compliance with the License.
|
143
|
-
* You may obtain a copy of the License at
|
144
|
-
*
|
145
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
146
|
-
*
|
147
|
-
* Unless required by applicable law or agreed to in writing, software
|
148
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
149
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
150
|
-
* See the License for the specific language governing permissions and
|
151
|
-
* limitations under the License.
|
152
|
-
* ========================================================= */
|
153
|
-
!function(t){"use strict";var e=function(e,n){this.options=n,this.$element=t(e).delegate('[data-dismiss="modal"]',"click.dismiss.modal",t.proxy(this.hide,this)),this.options.remote&&this.$element.find(".modal-body").load(this.options.remote)};e.prototype={constructor:e,toggle:function(){return this[this.isShown?"hide":"show"]()},show:function(){var e=this,n=t.Event("show");this.$element.trigger(n),this.isShown||n.isDefaultPrevented()||(this.isShown=!0,this.escape(),this.backdrop(function(){var n=t.support.transition&&e.$element.hasClass("fade");e.$element.parent().length||e.$element.appendTo(document.body),e.$element.show(),n&&e.$element[0].offsetWidth,e.$element.addClass("in").attr("aria-hidden",!1),e.enforceFocus(),n?e.$element.one(t.support.transition.end,function(){e.$element.focus().trigger("shown")}):e.$element.focus().trigger("shown")}))},hide:function(e){e&&e.preventDefault();e=t.Event("hide"),this.$element.trigger(e),this.isShown&&!e.isDefaultPrevented()&&(this.isShown=!1,this.escape(),t(document).off("focusin.modal"),this.$element.removeClass("in").attr("aria-hidden",!0),t.support.transition&&this.$element.hasClass("fade")?this.hideWithTransition():this.hideModal())},enforceFocus:function(){var e=this;t(document).on("focusin.modal",function(t){e.$element[0]===t.target||e.$element.has(t.target).length||e.$element.focus()})},escape:function(){var t=this;this.isShown&&this.options.keyboard?this.$element.on("keyup.dismiss.modal",function(e){27==e.which&&t.hide()}):this.isShown||this.$element.off("keyup.dismiss.modal")},hideWithTransition:function(){var e=this,n=setTimeout(function(){e.$element.off(t.support.transition.end),e.hideModal()},500);this.$element.one(t.support.transition.end,function(){clearTimeout(n),e.hideModal()})},hideModal:function(){var t=this;this.$element.hide(),this.backdrop(function(){t.removeBackdrop(),t.$element.trigger("hidden")})},removeBackdrop:function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},backdrop:function(e){var n=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var r=t.support.transition&&n;if(this.$backdrop=t('<div class="modal-backdrop '+n+'" />').appendTo(document.body),this.$backdrop.click("static"==this.options.backdrop?t.proxy(this.$element[0].focus,this.$element[0]):t.proxy(this.hide,this)),r&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!e)return;r?this.$backdrop.one(t.support.transition.end,e):e()}else!this.isShown&&this.$backdrop?(this.$backdrop.removeClass("in"),t.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one(t.support.transition.end,e):e()):e&&e()}};var n=t.fn.modal;t.fn.modal=function(n){return this.each(function(){var r=t(this),i=r.data("modal"),o=t.extend({},t.fn.modal.defaults,r.data(),"object"==typeof n&&n);i||r.data("modal",i=new e(this,o)),"string"==typeof n?i[n]():o.show&&i.show()})},t.fn.modal.defaults={backdrop:!0,keyboard:!0,show:!0},t.fn.modal.Constructor=e,t.fn.modal.noConflict=function(){return t.fn.modal=n,this},t(document).on("click.modal.data-api",'[data-toggle="modal"]',function(e){var n=t(this),r=n.attr("href"),i=t(n.attr("data-target")||r&&r.replace(/.*(?=#[^\s]+$)/,"")),o=i.data("modal")?"toggle":t.extend({remote:!/#/.test(r)&&r},i.data(),n.data());e.preventDefault(),i.modal(o).one("hide",function(){n.focus()})})}(window.jQuery),/* ===========================================================
|
154
|
-
* bootstrap-tooltip.js v2.3.1
|
155
|
-
* http://twitter.github.com/bootstrap/javascript.html#tooltips
|
156
|
-
* Inspired by the original jQuery.tipsy by Jason Frame
|
157
|
-
* ===========================================================
|
158
|
-
* Copyright 2012 Twitter, Inc.
|
159
|
-
*
|
160
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
161
|
-
* you may not use this file except in compliance with the License.
|
162
|
-
* You may obtain a copy of the License at
|
163
|
-
*
|
164
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
165
|
-
*
|
166
|
-
* Unless required by applicable law or agreed to in writing, software
|
167
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
168
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
169
|
-
* See the License for the specific language governing permissions and
|
170
|
-
* limitations under the License.
|
171
|
-
* ========================================================== */
|
172
|
-
!function(t){"use strict";var e=function(t,e){this.init("tooltip",t,e)};e.prototype={constructor:e,init:function(e,n,r){var i,o,s,a,u;for(this.type=e,this.$element=t(n),this.options=this.getOptions(r),this.enabled=!0,s=this.options.trigger.split(" "),u=s.length;u--;)a=s[u],"click"==a?this.$element.on("click."+this.type,this.options.selector,t.proxy(this.toggle,this)):"manual"!=a&&(i="hover"==a?"mouseenter":"focus",o="hover"==a?"mouseleave":"blur",this.$element.on(i+"."+this.type,this.options.selector,t.proxy(this.enter,this)),this.$element.on(o+"."+this.type,this.options.selector,t.proxy(this.leave,this)));this.options.selector?this._options=t.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(e){return e=t.extend({},t.fn[this.type].defaults,this.$element.data(),e),e.delay&&"number"==typeof e.delay&&(e.delay={show:e.delay,hide:e.delay}),e},enter:function(e){var n,r=t.fn[this.type].defaults,i={};return this._options&&t.each(this._options,function(t,e){r[t]!=e&&(i[t]=e)},this),n=t(e.currentTarget)[this.type](i).data(this.type),n.options.delay&&n.options.delay.show?(clearTimeout(this.timeout),n.hoverState="in",void(this.timeout=setTimeout(function(){"in"==n.hoverState&&n.show()},n.options.delay.show))):n.show()},leave:function(e){var n=t(e.currentTarget)[this.type](this._options).data(this.type);return this.timeout&&clearTimeout(this.timeout),n.options.delay&&n.options.delay.hide?(n.hoverState="out",void(this.timeout=setTimeout(function(){"out"==n.hoverState&&n.hide()},n.options.delay.hide))):n.hide()},show:function(){var e,n,r,i,o,s,a=t.Event("show");if(this.hasContent()&&this.enabled){if(this.$element.trigger(a),a.isDefaultPrevented())return;switch(e=this.tip(),this.setContent(),this.options.animation&&e.addClass("fade"),o="function"==typeof this.options.placement?this.options.placement.call(this,e[0],this.$element[0]):this.options.placement,e.detach().css({top:0,left:0,display:"block"}),this.options.container?e.appendTo(this.options.container):e.insertAfter(this.$element),n=this.getPosition(),r=e[0].offsetWidth,i=e[0].offsetHeight,o){case"bottom":s={top:n.top+n.height,left:n.left+n.width/2-r/2};break;case"top":s={top:n.top-i,left:n.left+n.width/2-r/2};break;case"left":s={top:n.top+n.height/2-i/2,left:n.left-r};break;case"right":s={top:n.top+n.height/2-i/2,left:n.left+n.width}}this.applyPlacement(s,o),this.$element.trigger("shown")}},applyPlacement:function(t,e){var n,r,i,o,s=this.tip(),a=s[0].offsetWidth,u=s[0].offsetHeight;s.offset(t).addClass(e).addClass("in"),n=s[0].offsetWidth,r=s[0].offsetHeight,"top"==e&&r!=u&&(t.top=t.top+u-r,o=!0),"bottom"==e||"top"==e?(i=0,t.left<0&&(i=-2*t.left,t.left=0,s.offset(t),n=s[0].offsetWidth,r=s[0].offsetHeight),this.replaceArrow(i-a+n,n,"left")):this.replaceArrow(r-u,r,"top"),o&&s.offset(t)},replaceArrow:function(t,e,n){this.arrow().css(n,t?50*(1-t/e)+"%":"")},setContent:function(){var t=this.tip(),e=this.getTitle();t.find(".tooltip-inner")[this.options.html?"html":"text"](e),t.removeClass("fade in top bottom left right")},hide:function(){function e(){var e=setTimeout(function(){n.off(t.support.transition.end).detach()},500);n.one(t.support.transition.end,function(){clearTimeout(e),n.detach()})}var n=this.tip(),r=t.Event("hide");return this.$element.trigger(r),r.isDefaultPrevented()?void 0:(n.removeClass("in"),t.support.transition&&this.$tip.hasClass("fade")?e():n.detach(),this.$element.trigger("hidden"),this)},fixTitle:function(){var t=this.$element;(t.attr("title")||"string"!=typeof t.attr("data-original-title"))&&t.attr("data-original-title",t.attr("title")||"").attr("title","")},hasContent:function(){return this.getTitle()},getPosition:function(){var e=this.$element[0];return t.extend({},"function"==typeof e.getBoundingClientRect?e.getBoundingClientRect():{width:e.offsetWidth,height:e.offsetHeight},this.$element.offset())},getTitle:function(){var t,e=this.$element,n=this.options;return t=e.attr("data-original-title")||("function"==typeof n.title?n.title.call(e[0]):n.title)},tip:function(){return this.$tip=this.$tip||t(this.options.template)},arrow:function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(e){var n=e?t(e.currentTarget)[this.type](this._options).data(this.type):this;n.tip().hasClass("in")?n.hide():n.show()},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}};var n=t.fn.tooltip;t.fn.tooltip=function(n){return this.each(function(){var r=t(this),i=r.data("tooltip"),o="object"==typeof n&&n;i||r.data("tooltip",i=new e(this,o)),"string"==typeof n&&i[n]()})},t.fn.tooltip.Constructor=e,t.fn.tooltip.defaults={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1},t.fn.tooltip.noConflict=function(){return t.fn.tooltip=n,this}}(window.jQuery),/* ===========================================================
|
173
|
-
* bootstrap-popover.js v2.3.1
|
174
|
-
* http://twitter.github.com/bootstrap/javascript.html#popovers
|
175
|
-
* ===========================================================
|
176
|
-
* Copyright 2012 Twitter, Inc.
|
177
|
-
*
|
178
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
179
|
-
* you may not use this file except in compliance with the License.
|
180
|
-
* You may obtain a copy of the License at
|
181
|
-
*
|
182
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
183
|
-
*
|
184
|
-
* Unless required by applicable law or agreed to in writing, software
|
185
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
186
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
187
|
-
* See the License for the specific language governing permissions and
|
188
|
-
* limitations under the License.
|
189
|
-
* =========================================================== */
|
190
|
-
!function(t){"use strict";var e=function(t,e){this.init("popover",t,e)};e.prototype=t.extend({},t.fn.tooltip.Constructor.prototype,{constructor:e,setContent:function(){var t=this.tip(),e=this.getTitle(),n=this.getContent();t.find(".popover-title")[this.options.html?"html":"text"](e),t.find(".popover-content")[this.options.html?"html":"text"](n),t.removeClass("fade top bottom left right in")},hasContent:function(){return this.getTitle()||this.getContent()},getContent:function(){var t,e=this.$element,n=this.options;return t=("function"==typeof n.content?n.content.call(e[0]):n.content)||e.attr("data-content")},tip:function(){return this.$tip||(this.$tip=t(this.options.template)),this.$tip},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}});var n=t.fn.popover;t.fn.popover=function(n){return this.each(function(){var r=t(this),i=r.data("popover"),o="object"==typeof n&&n;i||r.data("popover",i=new e(this,o)),"string"==typeof n&&i[n]()})},t.fn.popover.Constructor=e,t.fn.popover.defaults=t.extend({},t.fn.tooltip.defaults,{placement:"right",trigger:"click",content:"",template:'<div class="popover"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),t.fn.popover.noConflict=function(){return t.fn.popover=n,this}}(window.jQuery),/* =============================================================
|
191
|
-
* bootstrap-scrollspy.js v2.3.1
|
192
|
-
* http://twitter.github.com/bootstrap/javascript.html#scrollspy
|
193
|
-
* =============================================================
|
194
|
-
* Copyright 2012 Twitter, Inc.
|
195
|
-
*
|
196
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
197
|
-
* you may not use this file except in compliance with the License.
|
198
|
-
* You may obtain a copy of the License at
|
199
|
-
*
|
200
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
201
|
-
*
|
202
|
-
* Unless required by applicable law or agreed to in writing, software
|
203
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
204
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
205
|
-
* See the License for the specific language governing permissions and
|
206
|
-
* limitations under the License.
|
207
|
-
* ============================================================== */
|
208
|
-
!function(t){"use strict";function e(e,n){var r,i=t.proxy(this.process,this),o=t(t(e).is("body")?window:e);this.options=t.extend({},t.fn.scrollspy.defaults,n),this.$scrollElement=o.on("scroll.scroll-spy.data-api",i),this.selector=(this.options.target||(r=t(e).attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,"")||"")+" .nav li > a",this.$body=t("body"),this.refresh(),this.process()}e.prototype={constructor:e,refresh:function(){var e,n=this;this.offsets=t([]),this.targets=t([]),e=this.$body.find(this.selector).map(function(){var e=t(this),r=e.data("target")||e.attr("href"),i=/^#\w/.test(r)&&t(r);return i&&i.length&&[[i.position().top+(!t.isWindow(n.$scrollElement.get(0))&&n.$scrollElement.scrollTop()),r]]||null}).sort(function(t,e){return t[0]-e[0]}).each(function(){n.offsets.push(this[0]),n.targets.push(this[1])})},process:function(){var t,e=this.$scrollElement.scrollTop()+this.options.offset,n=this.$scrollElement[0].scrollHeight||this.$body[0].scrollHeight,r=n-this.$scrollElement.height(),i=this.offsets,o=this.targets,s=this.activeTarget;if(e>=r)return s!=(t=o.last()[0])&&this.activate(t);for(t=i.length;t--;)s!=o[t]&&e>=i[t]&&(!i[t+1]||e<=i[t+1])&&this.activate(o[t])},activate:function(e){var n,r;this.activeTarget=e,t(this.selector).parent(".active").removeClass("active"),r=this.selector+'[data-target="'+e+'"],'+this.selector+'[href="'+e+'"]',n=t(r).parent("li").addClass("active"),n.parent(".dropdown-menu").length&&(n=n.closest("li.dropdown").addClass("active")),n.trigger("activate")}};var n=t.fn.scrollspy;t.fn.scrollspy=function(n){return this.each(function(){var r=t(this),i=r.data("scrollspy"),o="object"==typeof n&&n;i||r.data("scrollspy",i=new e(this,o)),"string"==typeof n&&i[n]()})},t.fn.scrollspy.Constructor=e,t.fn.scrollspy.defaults={offset:10},t.fn.scrollspy.noConflict=function(){return t.fn.scrollspy=n,this},t(window).on("load",function(){t('[data-spy="scroll"]').each(function(){var e=t(this);e.scrollspy(e.data())})})}(window.jQuery),/* ========================================================
|
209
|
-
* bootstrap-tab.js v2.3.1
|
210
|
-
* http://twitter.github.com/bootstrap/javascript.html#tabs
|
211
|
-
* ========================================================
|
212
|
-
* Copyright 2012 Twitter, Inc.
|
213
|
-
*
|
214
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
215
|
-
* you may not use this file except in compliance with the License.
|
216
|
-
* You may obtain a copy of the License at
|
217
|
-
*
|
218
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
219
|
-
*
|
220
|
-
* Unless required by applicable law or agreed to in writing, software
|
221
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
222
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
223
|
-
* See the License for the specific language governing permissions and
|
224
|
-
* limitations under the License.
|
225
|
-
* ======================================================== */
|
226
|
-
!function(t){"use strict";var e=function(e){this.element=t(e)};e.prototype={constructor:e,show:function(){var e,n,r,i=this.element,o=i.closest("ul:not(.dropdown-menu)"),s=i.attr("data-target");s||(s=i.attr("href"),s=s&&s.replace(/.*(?=#[^\s]*$)/,"")),i.parent("li").hasClass("active")||(e=o.find(".active:last a")[0],r=t.Event("show",{relatedTarget:e}),i.trigger(r),r.isDefaultPrevented()||(n=t(s),this.activate(i.parent("li"),o),this.activate(n,n.parent(),function(){i.trigger({type:"shown",relatedTarget:e})})))},activate:function(e,n,r){function i(){o.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),e.addClass("active"),s?(e[0].offsetWidth,e.addClass("in")):e.removeClass("fade"),e.parent(".dropdown-menu")&&e.closest("li.dropdown").addClass("active"),r&&r()}var o=n.find("> .active"),s=r&&t.support.transition&&o.hasClass("fade");s?o.one(t.support.transition.end,i):i(),o.removeClass("in")}};var n=t.fn.tab;t.fn.tab=function(n){return this.each(function(){var r=t(this),i=r.data("tab");i||r.data("tab",i=new e(this)),"string"==typeof n&&i[n]()})},t.fn.tab.Constructor=e,t.fn.tab.noConflict=function(){return t.fn.tab=n,this},t(document).on("click.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(e){e.preventDefault(),t(this).tab("show")})}(window.jQuery),/* =============================================================
|
227
|
-
* bootstrap-typeahead.js v2.3.1
|
228
|
-
* http://twitter.github.com/bootstrap/javascript.html#typeahead
|
229
|
-
* =============================================================
|
230
|
-
* Copyright 2012 Twitter, Inc.
|
231
|
-
*
|
232
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
233
|
-
* you may not use this file except in compliance with the License.
|
234
|
-
* You may obtain a copy of the License at
|
235
|
-
*
|
236
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
237
|
-
*
|
238
|
-
* Unless required by applicable law or agreed to in writing, software
|
239
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
240
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
241
|
-
* See the License for the specific language governing permissions and
|
242
|
-
* limitations under the License.
|
243
|
-
* ============================================================ */
|
244
|
-
!function(t){"use strict";var e=function(e,n){this.$element=t(e),this.options=t.extend({},t.fn.typeahead.defaults,n),this.matcher=this.options.matcher||this.matcher,this.sorter=this.options.sorter||this.sorter,this.highlighter=this.options.highlighter||this.highlighter,this.updater=this.options.updater||this.updater,this.source=this.options.source,this.$menu=t(this.options.menu),this.shown=!1,this.listen()};e.prototype={constructor:e,select:function(){var t=this.$menu.find(".active").attr("data-value");return this.$element.val(this.updater(t)).change(),this.hide()},updater:function(t){return t},show:function(){var e=t.extend({},this.$element.position(),{height:this.$element[0].offsetHeight});return this.$menu.insertAfter(this.$element).css({top:e.top+e.height,left:e.left}).show(),this.shown=!0,this},hide:function(){return this.$menu.hide(),this.shown=!1,this},lookup:function(e){var n;return this.query=this.$element.val(),!this.query||this.query.length<this.options.minLength?this.shown?this.hide():this:(n=t.isFunction(this.source)?this.source(this.query,t.proxy(this.process,this)):this.source,n?this.process(n):this)},process:function(e){var n=this;return e=t.grep(e,function(t){return n.matcher(t)}),e=this.sorter(e),e.length?this.render(e.slice(0,this.options.items)).show():this.shown?this.hide():this},matcher:function(t){return~t.toLowerCase().indexOf(this.query.toLowerCase())},sorter:function(t){for(var e,n=[],r=[],i=[];e=t.shift();)e.toLowerCase().indexOf(this.query.toLowerCase())?~e.indexOf(this.query)?r.push(e):i.push(e):n.push(e);return n.concat(r,i)},highlighter:function(t){var e=this.query.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&");return t.replace(new RegExp("("+e+")","ig"),function(t,e){return"<strong>"+e+"</strong>"})},render:function(e){var n=this;return e=t(e).map(function(e,r){return e=t(n.options.item).attr("data-value",r),e.find("a").html(n.highlighter(r)),e[0]}),e.first().addClass("active"),this.$menu.html(e),this},next:function(e){var n=this.$menu.find(".active").removeClass("active"),r=n.next();r.length||(r=t(this.$menu.find("li")[0])),r.addClass("active")},prev:function(t){var e=this.$menu.find(".active").removeClass("active"),n=e.prev();n.length||(n=this.$menu.find("li").last()),n.addClass("active")},listen:function(){this.$element.on("focus",t.proxy(this.focus,this)).on("blur",t.proxy(this.blur,this)).on("keypress",t.proxy(this.keypress,this)).on("keyup",t.proxy(this.keyup,this)),this.eventSupported("keydown")&&this.$element.on("keydown",t.proxy(this.keydown,this)),this.$menu.on("click",t.proxy(this.click,this)).on("mouseenter","li",t.proxy(this.mouseenter,this)).on("mouseleave","li",t.proxy(this.mouseleave,this))},eventSupported:function(t){var e=t in this.$element;return e||(this.$element.setAttribute(t,"return;"),e="function"==typeof this.$element[t]),e},move:function(t){if(this.shown){switch(t.keyCode){case 9:case 13:case 27:t.preventDefault();break;case 38:t.preventDefault(),this.prev();break;case 40:t.preventDefault(),this.next()}t.stopPropagation()}},keydown:function(e){this.suppressKeyPressRepeat=~t.inArray(e.keyCode,[40,38,9,13,27]),this.move(e)},keypress:function(t){this.suppressKeyPressRepeat||this.move(t)},keyup:function(t){switch(t.keyCode){case 40:case 38:case 16:case 17:case 18:break;case 9:case 13:if(!this.shown)return;this.select();break;case 27:if(!this.shown)return;this.hide();break;default:this.lookup()}t.stopPropagation(),t.preventDefault()},focus:function(t){this.focused=!0},blur:function(t){this.focused=!1,!this.mousedover&&this.shown&&this.hide()},click:function(t){t.stopPropagation(),t.preventDefault(),this.select(),this.$element.focus()},mouseenter:function(e){this.mousedover=!0,this.$menu.find(".active").removeClass("active"),t(e.currentTarget).addClass("active")},mouseleave:function(t){this.mousedover=!1,!this.focused&&this.shown&&this.hide()}};var n=t.fn.typeahead;t.fn.typeahead=function(n){return this.each(function(){var r=t(this),i=r.data("typeahead"),o="object"==typeof n&&n;i||r.data("typeahead",i=new e(this,o)),"string"==typeof n&&i[n]()})},t.fn.typeahead.defaults={source:[],items:8,menu:'<ul class="typeahead dropdown-menu"></ul>',item:'<li><a href="#"></a></li>',minLength:1},t.fn.typeahead.Constructor=e,t.fn.typeahead.noConflict=function(){return t.fn.typeahead=n,this},t(document).on("focus.typeahead.data-api",'[data-provide="typeahead"]',function(e){var n=t(this);n.data("typeahead")||n.typeahead(n.data())})}(window.jQuery),/* ==========================================================
|
245
|
-
* bootstrap-affix.js v2.3.1
|
246
|
-
* http://twitter.github.com/bootstrap/javascript.html#affix
|
247
|
-
* ==========================================================
|
248
|
-
* Copyright 2012 Twitter, Inc.
|
249
|
-
*
|
250
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
251
|
-
* you may not use this file except in compliance with the License.
|
252
|
-
* You may obtain a copy of the License at
|
253
|
-
*
|
254
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
255
|
-
*
|
256
|
-
* Unless required by applicable law or agreed to in writing, software
|
257
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
258
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
259
|
-
* See the License for the specific language governing permissions and
|
260
|
-
* limitations under the License.
|
261
|
-
* ========================================================== */
|
262
|
-
!function(t){"use strict";var e=function(e,n){this.options=t.extend({},t.fn.affix.defaults,n),this.$window=t(window).on("scroll.affix.data-api",t.proxy(this.checkPosition,this)).on("click.affix.data-api",t.proxy(function(){setTimeout(t.proxy(this.checkPosition,this),1)},this)),this.$element=t(e),this.checkPosition()};e.prototype.checkPosition=function(){if(this.$element.is(":visible")){var e,n=t(document).height(),r=this.$window.scrollTop(),i=this.$element.offset(),o=this.options.offset,s=o.bottom,a=o.top,u="affix affix-top affix-bottom";"object"!=typeof o&&(s=a=o),"function"==typeof a&&(a=o.top()),"function"==typeof s&&(s=o.bottom()),e=null!=this.unpin&&r+this.unpin<=i.top?!1:null!=s&&i.top+this.$element.height()>=n-s?"bottom":null!=a&&a>=r?"top":!1,this.affixed!==e&&(this.affixed=e,this.unpin="bottom"==e?i.top-r:null,this.$element.removeClass(u).addClass("affix"+(e?"-"+e:"")))}};var n=t.fn.affix;t.fn.affix=function(n){return this.each(function(){var r=t(this),i=r.data("affix"),o="object"==typeof n&&n;i||r.data("affix",i=new e(this,o)),"string"==typeof n&&i[n]()})},t.fn.affix.Constructor=e,t.fn.affix.defaults={offset:0},t.fn.affix.noConflict=function(){return t.fn.affix=n,this},t(window).on("load",function(){t('[data-spy="affix"]').each(function(){var e=t(this),n=e.data();n.offset=n.offset||{},n.offsetBottom&&(n.offset.bottom=n.offsetBottom),n.offsetTop&&(n.offset.top=n.offsetTop),e.affix(n)})})}(window.jQuery),function(){var t=this,e=t.humanize,n={};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=n),exports.humanize=n):("function"==typeof define&&define.amd&&define("humanize",function(){return n}),t.humanize=n),n.noConflict=function(){return t.humanize=e,this},n.pad=function(t,e,n,r){if(t+="",n?n.length>1&&(n=n.charAt(0)):n=" ",r=void 0===r?"left":"right","right"===r)for(;t.length<e;)t+=n;else for(;t.length<e;)t=n+t;return t},n.time=function(){return(new Date).getTime()/1e3};var r=[0,0,31,59,90,120,151,181,212,243,273,304,334],i=[0,0,31,60,91,121,152,182,213,244,274,305,335];n.date=function(t,e){var o=void 0===e?new Date:e instanceof Date?new Date(e):new Date(1e3*e),s=/\\?([a-z])/gi,a=function(t,e){return c[t]?c[t]():e},u=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],l=["January","February","March","April","May","June","July","August","September","October","November","December"],c={d:function(){return n.pad(c.j(),2,"0")},D:function(){return c.l().slice(0,3)},j:function(){return o.getDate()},l:function(){return u[c.w()]},N:function(){return c.w()||7},S:function(){var t=c.j();return t>4&&21>t?"th":{1:"st",2:"nd",3:"rd"}[t%10]||"th"},w:function(){return o.getDay()},z:function(){return(c.L()?i[c.n()]:r[c.n()])+c.j()-1},W:function(){var t=c.z()-c.N()+1.5;return n.pad(1+Math.floor(Math.abs(t)/7)+(t%7>3.5?1:0),2,"0")},F:function(){return l[o.getMonth()]},m:function(){return n.pad(c.n(),2,"0")},M:function(){return c.F().slice(0,3)},n:function(){return o.getMonth()+1},t:function(){return new Date(c.Y(),c.n(),0).getDate()},L:function(){return 1===new Date(c.Y(),1,29).getMonth()?1:0},o:function(){var t=c.n(),e=c.W();return c.Y()+(12===t&&9>e?-1:1===t&&e>9)},Y:function(){return o.getFullYear()},y:function(){return String(c.Y()).slice(-2)},a:function(){return o.getHours()>11?"pm":"am"},A:function(){return c.a().toUpperCase()},B:function(){var t=o.getTime()/1e3,e=t%86400+3600;0>e&&(e+=86400);var n=e/86.4%1e3;return 0>t?Math.ceil(n):Math.floor(n)},g:function(){return c.G()%12||12},G:function(){return o.getHours()},h:function(){return n.pad(c.g(),2,"0")},H:function(){return n.pad(c.G(),2,"0")},i:function(){return n.pad(o.getMinutes(),2,"0")},s:function(){return n.pad(o.getSeconds(),2,"0")},u:function(){return n.pad(1e3*o.getMilliseconds(),6,"0")},O:function(){var t=o.getTimezoneOffset(),e=Math.abs(t);return(t>0?"-":"+")+n.pad(100*Math.floor(e/60)+e%60,4,"0")},P:function(){var t=c.O();return t.substr(0,3)+":"+t.substr(3,2)},Z:function(){return 60*-o.getTimezoneOffset()},c:function(){return"Y-m-d\\TH:i:sP".replace(s,a)},r:function(){return"D, d M Y H:i:s O".replace(s,a)},U:function(){return o.getTime()/1e3||0}};return t.replace(s,a)},n.numberFormat=function(t,e,n,r){e=isNaN(e)?2:Math.abs(e),n=void 0===n?".":n,r=void 0===r?",":r;var i=0>t?"-":"";t=Math.abs(+t||0);var o=parseInt(t.toFixed(e),10)+"",s=o.length>3?o.length%3:0;return i+(s?o.substr(0,s)+r:"")+o.substr(s).replace(/(\d{3})(?=\d)/g,"$1"+r)+(e?n+Math.abs(t-o).toFixed(e).slice(2):"")},n.naturalDay=function(t,e){t=void 0===t?n.time():t,e=void 0===e?"Y-m-d":e;var r=86400,i=new Date,o=new Date(i.getFullYear(),i.getMonth(),i.getDate()).getTime()/1e3;return o>t&&t>=o-r?"yesterday":t>=o&&o+r>t?"today":t>=o+r&&o+2*r>t?"tomorrow":n.date(e,t)},n.relativeTime=function(t){t=void 0===t?n.time():t;var e=n.time(),r=e-t;if(2>r&&r>-2)return(r>=0?"just ":"")+"now";if(60>r&&r>-60)return r>=0?Math.floor(r)+" seconds ago":"in "+Math.floor(-r)+" seconds";if(120>r&&r>-120)return r>=0?"about a minute ago":"in about a minute";if(3600>r&&r>-3600)return r>=0?Math.floor(r/60)+" minutes ago":"in "+Math.floor(-r/60)+" minutes";if(7200>r&&r>-7200)return r>=0?"about an hour ago":"in about an hour";if(86400>r&&r>-86400)return r>=0?Math.floor(r/3600)+" hours ago":"in "+Math.floor(-r/3600)+" hours";var i=172800;if(i>r&&r>-i)return r>=0?"1 day ago":"in 1 day";var o=2505600;if(o>r&&r>-o)return r>=0?Math.floor(r/86400)+" days ago":"in "+Math.floor(-r/86400)+" days";var s=5184e3;if(s>r&&r>-s)return r>=0?"about a month ago":"in about a month";var a=parseInt(n.date("Y",e),10),u=parseInt(n.date("Y",t),10),l=12*a+parseInt(n.date("n",e),10),c=12*u+parseInt(n.date("n",t),10),h=l-c;if(12>h&&h>-12)return h>=0?h+" months ago":"in "+-h+" months";var f=a-u;return 2>f&&f>-2?f>=0?"a year ago":"in a year":f>=0?f+" years ago":"in "+-f+" years"},n.ordinal=function(t){t=parseInt(t,10),t=isNaN(t)?0:t;var e=0>t?"-":"";t=Math.abs(t);var n=t%100;return e+t+(n>4&&21>n?"th":{1:"st",2:"nd",3:"rd"}[t%10]||"th")},n.filesize=function(t,e,r,i,o){if(e=void 0===e?1024:e,r=isNaN(r)?2:Math.abs(r),i=void 0===i?".":i,o=void 0===o?",":o,0>=t)return"0 bytes";var s=[1],a=["bytes","Kb","Mb","Gb","Tb","Pb"];if(e>t)return n.numberFormat(t,0)+" "+a[0];for(var u=1;u<a.length;u++)if(s[u]=s[u-1]*e,t<s[u])return n.numberFormat(t/s[u-1],r,i,o)+" "+a[u-1];return n.numberFormat(t/s[a.length-1],r,i,o)+" "+a[a.length-1]},n.linebreaks=function(t){return t=t.replace(/^([\n|\r]*)/,""),t=t.replace(/([\n|\r]*)$/,""),t=t.replace(/(\r\n|\n|\r)/g,"\n"),t=t.replace(/(\n{2,})/g,"</p><p>"),t=t.replace(/\n/g,"<br />"),"<p>"+t+"</p>"},n.nl2br=function(t){return t.replace(/(\r\n|\n|\r)/g,"<br />")},n.truncatechars=function(t,e){return t.length<=e?t:t.substr(0,e)+"\u2026"},n.truncatewords=function(t,e){var n=t.split(" ");return n.length<e?t:n.slice(0,e).join(" ")+"\u2026"}}.call(this),function(){this.JST||(this.JST={}),this.JST.cluster=function(t){t||(t={});var e,n=[],r=function(t){return t&&t.ecoSafe?t:"undefined"!=typeof t&&null!=t?o(t):""},i=t.safe,o=t.escape;return e=t.safe=function(t){if(t&&t.ecoSafe)return t;("undefined"==typeof t||null==t)&&(t="");var e=new String(t);return e.ecoSafe=!0,e},o||(o=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,i,o,s,a;for(n.push("<h3 align=center> "),n.push(r(this.model.get("name"))),n.push(' </h3>\n\n<ul class="pager fixed">\n '),this.prevCluster?(n.push('\n <li class="previous nosel"><a class="nextPrevButton" href="'),n.push(r(null!=(o=this.prevCluster)?o.get("routeURL"):void 0)),n.push('">← Prev</a></li>\n ')):n.push('\n <li class="previous disabled nosel"><a>← Prev</a></li>\n '),n.push("\n\n "),this.nextCluster?(n.push('\n <li class="next nosel"><a class="nextPrevButton" href="'),n.push(r(null!=(s=this.nextCluster)?s.get("routeURL"):void 0)),n.push('">Next →</a></li>\n ')):n.push('\n <li class="next disabled nosel"><a>Next →</a></li>\n '),n.push('\n </li>\n</ul>\n\n\n</br>\n<table class="table table-striped table-bordered">\n <tr>\n <th>Client Connections</th>\n <th>Client EOF</th>\n <th>Client Errors</th>\n <th>Forward Errors</th>\n <th>Fragments</th>\n <th>Server Ejects</th>\n </tr>\n <tr>\n <td>'),n.push(r(this.model.get("client_connections"))),n.push("</td>\n <td>"),n.push(r(this.model.get("client_eof"))),n.push("</td>\n <td>"),n.push(r(this.model.get("client_err"))),n.push("</td>\n <td>"),n.push(r(this.model.get("forward_error"))),n.push("</td>\n <td>"),n.push(r(this.model.get("fragments"))),n.push("</td>\n <td>"),n.push(r(this.model.get("server_ejects"))),n.push('</td>\n </tr>\n\n</table>\n\n</br>\n<div class="chartsBox">\n <div class="row">\n <div class="span5">\n <div id="chart1" style="padding-left: 23%"></div>\n </div>\n <div class="span5">\n <div id="chart2" style="padding-left: 40%"></div>\n </div>\n </div>\n</div>\n\n\n</br>\n<table class="table table-striped table-bordered">\n <thead>\n <tr>\n <th>Host</th>\n <th>Free Memory</th>\n <th>Used Memory</th>\n <th>Used Memory RSS</th>\n <th>Max Memory</th>\n <th>Fragmentation</th>\n </tr>\n </thead>\n <tbody>\n '),a=this.model.get("nodes").models,t=0,e=a.length;e>t;t++)i=a[t],n.push('\n <tr>\n <td><a href="'),n.push(r(i.get("routeURL"))),n.push('">'),n.push(r(i.get("hostname"))),n.push("</a></td>\n <td>"),n.push(r(humanize.filesize(i.get("freeMemory")))),n.push("</td>\n <td>"),n.push(r(humanize.filesize(i.get("usedMemory")))),n.push("</td>\n <td>"),n.push(r(humanize.filesize(i.get("usedMemoryRss")))),n.push("</td>\n <td>"),n.push(r(humanize.filesize(i.get("maxMemory")))),n.push("</td>\n <td>"),n.push(r(i.get("fragmentation"))),n.push("</td>\n </tr>\n ");n.push("\n <tr>\n <td> </td>\n <td>"),n.push(r(humanize.filesize(_(this.model.get("nodes").pluck("freeMemory")).sum()))),n.push("</td>\n <td>"),n.push(r(humanize.filesize(_(this.model.get("nodes").pluck("usedMemory")).sum()))),n.push("</td>\n <td>"),n.push(r(humanize.filesize(_(this.model.get("nodes").pluck("usedMemoryRss")).sum()))),n.push("</td>\n <td>"),n.push(r(humanize.filesize(_(this.model.get("nodes").pluck("maxMemory")).sum()))),n.push("</td>\n <td>~"),n.push(r(humanize.numberFormat(_(this.model.get("nodes").pluck("fragmentation")).average(),2))),n.push("</td>\n </tr>\n </tbody>\n</table>\n")}).call(this)}.call(t),t.safe=i,t.escape=o,n.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.config=function(t){t||(t={});var e,n=[],r=function(t){return t&&t.ecoSafe?t:"undefined"!=typeof t&&null!=t?o(t):""},i=t.safe,o=t.escape;return e=t.safe=function(t){if(t&&t.ecoSafe)return t;("undefined"==typeof t||null==t)&&(t="");var e=new String(t);return e.ecoSafe=!0,e},o||(o=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,i,o,s,a,u,l;for(n.push("\n<h3> Clusters </h3>\n<br/>\n"),u=_(this.model.get("config")).map(function(t,e){return[e,t]}),i=0,s=u.length;s>i;i++){for(e=u[i],n.push('\n <table class="table table-striped table-bordered">\n <tr><th>Name</th><td>'),n.push("<a href="+Nutcracker.Models.Cluster.routeURL(e[0])+">"+e[0]+"</a>"),n.push("</td></tr>\n <tr><th>Servers</th><td>"),n.push(e[1].servers.map(function(t){return"<a href="+Nutcracker.Models.Node.routeURL(t)+">"+t+"</a>"}).join("<br/>")),n.push("</td></tr>\n "),l=_(e[1]).map(function(t,e){return[e,t]}),o=0,a=l.length;a>o;o++)t=l[o],n.push("\n "),/servers/.test(t[0])||(n.push("\n <tr><th>"),n.push(r(t[0])),n.push("</th><td>"),n.push(r(t[1])),n.push("</td></tr>\n ")),n.push("\n ");n.push("\n </table>\n </br>\n")}n.push("\n")}).call(this)}.call(t),t.safe=i,t.escape=o,n.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.footer=function(t){t||(t={});var e,n=[],r=t.safe,i=t.escape;return e=t.safe=function(t){if(t&&t.ecoSafe)return t;("undefined"==typeof t||null==t)&&(t="");var e=new String(t);return e.ecoSafe=!0,e},i||(i=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){n.push('<div id="lastUpdate"></div>\n')}).call(this)}.call(t),t.safe=r,t.escape=i,n.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.navbar=function(t){t||(t={});var e,n=[],r=function(t){return t&&t.ecoSafe?t:"undefined"!=typeof t&&null!=t?o(t):""},i=t.safe,o=t.escape;return e=t.safe=function(t){if(t&&t.ecoSafe)return t;("undefined"==typeof t||null==t)&&(t="");var e=new String(t);return e.ecoSafe=!0,e},o||(o=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,i,o,s,a,u,l;for(n.push('<div class="navbar">\n <div class="navbar-inner">\n <div class="container" style="font-size: 17px">\n <a class="btn btn-navbar" data-toggle="collapse" data-target=".navbar-responsive-collapse">\n <span class="icon-bar"></span>\n <span class="icon-bar"></span>\n <span class="icon-bar"></span>\n </a>\n <a class="brand" href="#" style="color: #ffffff;font-size: 25px">Nutcracker</a>\n <div class="nav-collapse collapse navbar-responsive-collapse">\n <ul class="nav">\n <li class="divider-vertical"></li>\n <li id="overview" ><a href="#/">Overview</a></li>\n <li class="divider-vertical"></li>\n <li id="config" ><a href="#/config">Config </a></li>\n <li class="divider-vertical"></li>\n <li id="clusters" class="dropdown">\n <a class="dropdown-toggle" id="drop4" style="padding-top: 10px;" role="button" data-toggle="dropdown" href="#">Clusters <b class="caret"></b></a>\n <ul id="menu1" class="dropdown-menu" role="menu" aria-labelledby="drop4">\n <li class=\'divider\'></li>\n '),u=this.model.get("clusters").models,e=0,o=u.length;o>e;e++)t=u[e],n.push('\n <li role="presentation" style="font-size: 15px">\n <a role="menuitem" tabindex="-1" href="'),n.push(r(t.get("routeURL"))),n.push('">'),n.push(r(t.get("name"))),n.push("</a>\n </li>\n <li class='divider'></li>\n ");for(n.push('\n </ul>\n </li>\n\n <li class="divider-vertical"></li>\n <li id="nodes" class="dropdown">\n <a class="dropdown-toggle" id="drop5" style="padding-top: 10px;" role="button" data-toggle="dropdown" href="#">Nodes <b class="caret"></b></a>\n <ul id="menu1" class="dropdown-menu" role="menu" aria-labelledby="drop5">\n <li class=\'divider\'></li>\n '),l=this.model.nodes().models,i=0,s=l.length;s>i;i++)a=l[i],n.push('\n <li role="presentation" style="font-size: 15px">\n <a role="menuitem" tabindex="-1" href="'),n.push(r(a.get("routeURL"))),n.push('">'),n.push(r(a.get("hostname"))),n.push("</a>\n </li>\n <li class='divider'></li>\n ");n.push('\n </ul>\n </li>\n\n <li class="divider-vertical"></li>\n </ul>\n\n <ul class="nav pull-right">\n <li class="divider-vertical"></li>\n <li id="auto-refresh-drop-down" class="dropdown">\n <a class="dropdown-toggle" id="auto-refresh-drop" style="padding-top: 10px;" role="button" data-toggle="dropdown" href="#">Auto Refresh </a>\n <ul id="auto-refresh-menu" class="dropdown-menu" role="menu" aria-labelledby="auto-refresh-drop">\n <li id="auto-refresh-value-30" role="presentation" style="font-size: 15px">\n <a class="auto-refresh-button" value="30" role="menuitem" tabindex="-1" href="">30 Seconds</a>\n </li>\n <li class=\'divider\'></li>\n <li id="auto-refresh-value-60" role="presentation" style="font-size: 15px">\n <a class="auto-refresh-button" value="60" role="menuitem" tabindex="-1" href="">60 Seconds</a>\n </li>\n <li class=\'divider\'></li>\n <li id="auto-refresh-value-300" role="presentation" style="font-size: 15px">\n <a class="auto-refresh-button" value="300" role="menuitem" tabindex="-1" href="">5 Minutes</a>\n </li>\n <li class=\'divider\'></li>\n <li id="auto-refresh-value-3600" role="presentation" style="font-size: 15px">\n <a class="auto-refresh-button" value="3600" role="menuitem" tabindex="-1" href="">1 Hour</a>\n </li>\n </ul>\n </li>\n <li class="divider-vertical"></li>\n </ul>\n\n \n </div><!-- /.nav-collapse -->\n </div>\n </div><!-- /navbar-inner -->\n</div><!-- /navbar -->\n')}).call(this)}.call(t),t.safe=i,t.escape=o,n.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.node=function(t){t||(t={});var e,n=[],r=function(t){return t&&t.ecoSafe?t:"undefined"!=typeof t&&null!=t?o(t):""},i=t.safe,o=t.escape;return e=t.safe=function(t){if(t&&t.ecoSafe)return t;("undefined"==typeof t||null==t)&&(t="");var e=new String(t);return e.ecoSafe=!0,e},o||(o=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,i,o,s,a;for(n.push("<h3 align=center>"),n.push(r(this.model.get("hostname"))),n.push('</h3>\n\n<ul class="pager">\n '),this.prevNode?(n.push('\n <li class="previous nosel"><a class="nextPrevButton" href="'),n.push(r(null!=(o=this.prevNode)?o.get("routeURL"):void 0)),n.push('">← Prev</a></li>\n ')):n.push('\n <li class="previous disabled nosel"><a>← Prev</a></li>\n '),n.push("\n \n "),s=this.model.get("clusters"),e=0,i=s.length;i>e;e++)t=s[e],n.push('\n <li class="nosel"><a class="nextPrevButton" href="'),n.push(r(t.get("routeURL"))),n.push('">'),n.push(r(t.get("name"))),n.push("</a></li>\n ");n.push("\n\n "),this.nextNode?(n.push('\n <li class="next nosel"><a class="nextPrevButton" href="'),n.push(r(null!=(a=this.nextNode)?a.get("routeURL"):void 0)),n.push('">Next →</a></li>\n ')):n.push('\n <li class="next disabled nosel"><a>Next →</a></li>\n '),n.push('\n </li>\n</ul>\n</br>\n<div class="chartsBox">\n <div class="row">\n <div class="span5">\n <div id="chart1" style="padding-left: 26%"></div>\n </div>\n <div class="span5">\n <div id="chart2" style="padding-left: 40%"></div>\n </div>\n </div>\n</div>\n\n<br/>\n<div class="row-fluid">\n <div class="span6">\n <h4> Cluster <-> Node Stats </h4>\n <table class="table table-striped table-bordered">\n <tr><th>In-Queue</th><td> '),n.push(r(this.model.get("in_queue"))),n.push("</td></tr>\n <tr><th>In-Queue Memory Size</th><td> "),n.push(r(humanize.filesize(this.model.get("in_queue_bytes")))),n.push("</td></tr>\n <tr><th>Out-Queue</th><td> "),n.push(r(this.model.get("out_queue"))),n.push("</td></tr>\n <tr><th>Out-Queue Memory Size</th><td> "),n.push(r(humanize.filesize(this.model.get("out_queue_bytes")))),n.push("</td></tr>\n <tr><th>Requests</th><td> "),n.push(r(this.model.get("requests"))),n.push("</td></tr>\n <tr><th>Requests Memory Size</th><td> "),n.push(r(humanize.filesize(this.model.get("request_bytes")))),n.push("</td></tr>\n <tr><th>Responses</th><td> "),n.push(r(this.model.get("responses"))),n.push("</td></tr>\n <tr><th>Responses Memory Size</th><td> "),n.push(r(humanize.filesize(this.model.get("response_bytes")))),n.push("</td></tr>\n <tr><th>Server Connections</th><td> "),n.push(r(this.model.get("server_connections"))),n.push("</td></tr>\n <tr><th>Server EOF</th><td> "),n.push(r(this.model.get("server_eof"))),n.push("</td></tr>\n <tr><th>Server Error</th><td> "),n.push(r(this.model.get("server_err"))),n.push("</td></tr>\n <tr><th>Server Timedout</th><td> "),n.push(r(this.model.get("server_timedout"))),n.push('</td></tr>\n </table>\n </div>\n\n <div class="span6">\n <h4>Node Stats</h3>\n <table class="table table-striped table-bordered">\n <tr><th>Hits</th><td> '),n.push(r(humanize.numberFormat(this.model.get("info").hits,0))),n.push("</td></tr>\n <tr><th>Misses</th><td> "),n.push(r(humanize.numberFormat(this.model.get("info").misses,0))),n.push("</td></tr>\n <tr><th>Hit Ratio</th><td> "),n.push(r(humanize.numberFormat(this.model.get("info").hit_ratio,2))),n.push("</td></tr>\n <tr><th>Max Memory</th><td> "),n.push(r(humanize.filesize(this.model.get("info").max_memory))),n.push("</td></tr>\n <tr><th>Used Memory</th><td> "),n.push(r(humanize.filesize(this.model.get("info").used_memory))),n.push("</td></tr>\n <tr><th>Used Memory RSS</th><td> "),n.push(r(humanize.filesize(this.model.get("info").used_memory_rss))),n.push("</td></tr>\n <tr><th>Connections</th><td> "),n.push(r(this.model.get("info").connections)),n.push("</td></tr>\n <tr><th>Keys</th><td> "),n.push(r(humanize.numberFormat(this.model.get("info").keys,0))),n.push("</td></tr>\n <tr><th>Evicted Keys</th><td> "),n.push(r(humanize.numberFormat(this.model.get("info").evicted_keys,0))),n.push("</td></tr>\n <tr><th>Expired Keys</th><td> "),n.push(r(humanize.numberFormat(this.model.get("info").expired_keys,0))),n.push("</td></tr>\n <tr><th>Fragmentation</th><td> "),n.push(r(humanize.numberFormat(this.model.get("info").fragmentation,2))),n.push("</td></tr>\n <tr><th> </th><td> </td></tr>\n </table>\n </div>\n\n</div>\n\n\n")}).call(this)}.call(t),t.safe=i,t.escape=o,n.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.overview=function(t){t||(t={});var e,n=[],r=function(t){return t&&t.ecoSafe?t:"undefined"!=typeof t&&null!=t?o(t):""},i=t.safe,o=t.escape;return e=t.safe=function(t){if(t&&t.ecoSafe)return t;("undefined"==typeof t||null==t)&&(t="");var e=new String(t);return e.ecoSafe=!0,e},o||(o=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,i,o,s,a,u,l;for(n.push('<h3> Overview </h3>\n<br/>\n<table class="table table-striped table-bordered">\n <tbody>\n <tr><th>Hostname</th><td>'),n.push(r(this.model.get("source"))),n.push("</td></tr>\n <tr><th>Service</th><td>Nutcracker Ver. "),n.push(r(this.model.get("version"))),n.push("</td></tr>\n <tr><th>Uptime</th><td>"),n.push(r(humanize.relativeTime((new Date-1e3*this.model.get("uptime"))/1e3))),n.push("</td></tr>\n <tr><th>Server Connections</th><td>"),n.push(r(this.model.get("serverConnections"))),n.push("</td></tr>\n <tr><th>Client Connections</th><td>"),n.push(r(this.model.get("clientConnections"))),n.push("</td></tr>\n\n <tr>\n <th>Total Clusters</th>\n <td>\n "),u=this.model.get("clusters").models,e=0,o=u.length;o>e;e++)t=u[e],n.push('\n <a href="'),n.push(r(t.get("routeURL"))),n.push('">'),n.push(r(t.get("name"))),n.push("</a><br/>\n ");for(n.push("\n </td>\n </tr>\n\n <tr>\n <th>Total Nodes</th>\n <td>\n "),l=this.model.nodes().models,i=0,s=l.length;s>i;i++)a=l[i],n.push('\n <a href="'),n.push(r(a.get("routeURL"))),n.push('">'),n.push(r(a.get("hostname"))),n.push("</a><br/>\n ");n.push("\n </td>\n </tr>\n \n\n </tbody>\n</table>\n\n")}).call(this)}.call(t),t.safe=i,t.escape=o,n.join("")}}.call(this),function(){window.Nutcracker={Models:{},Collections:{},Views:{},Routers:{},Utils:{},reload:function(){return""===window.location.hash?Nutcracker.router.navigate("/",{trigger:!0}):Nutcracker.router.navigate(window.location.hash,{trigger:!0})},initialize:function(){var t;return t=new Nutcracker.Models.Overview($("#container").data("clusters")),Nutcracker.overview=t,Nutcracker.screen=new Nutcracker.Utils.RegionManager,Nutcracker.screen.navbar(new Nutcracker.Views.Navbar({model:t})),Nutcracker.screen.footer(new Nutcracker.Views.Footer({model:t})),Nutcracker.router=new Nutcracker.Routers.Overview,Backbone.history.start()}},$(document).ready(function(){return Nutcracker.initialize()})}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}},e=function(t,e){function r(){this.constructor=t}for(var i in e)n.call(e,i)&&(t[i]=e[i]);return r.prototype=e.prototype,t.prototype=new r,t.__super__=e.prototype,t},n={}.hasOwnProperty;Nutcracker.Collections.Clusters=function(n){function r(){return this.initialize=t(this.initialize,this),r.__super__.constructor.apply(this,arguments)}return e(r,n),r.prototype.initialize=function(t){return this.model=Nutcracker.Models.Cluster},r}(Backbone.Collection)}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}},e=function(t,e){function r(){this.constructor=t}for(var i in e)n.call(e,i)&&(t[i]=e[i]);return r.prototype=e.prototype,t.prototype=new r,t.__super__=e.prototype,t},n={}.hasOwnProperty;Nutcracker.Collections.Nodes=function(n){function r(){return this.usedMemory=t(this.usedMemory,this),this.maxMemory=t(this.maxMemory,this),this.freeMemory=t(this.freeMemory,this),this.serverConnections=t(this.serverConnections,this),this.add=t(this.add,this),r.__super__.constructor.apply(this,arguments)}return e(r,n),r.prototype.initialize=function(){return this.model=Nutcracker.Models.Node},r.prototype.add=function(t){return this.any(function(e){return e.get("server_url")===t[0].server_url})||r.__super__.add.apply(this,arguments)},r.prototype.serverConnections=function(){return _(this.pluck("server_connections")).sum()},r.prototype.freeMemory=function(){return _(this.pluck("freeMemory")).sum()},r.prototype.maxMemory=function(){return _(this.pluck("maxMemory")).sum()},r.prototype.usedMemory=function(){return _(this.pluck("usedMemory")).sum()},r}(Backbone.Collection)}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}},e=function(t,e){function r(){this.constructor=t}for(var i in e)n.call(e,i)&&(t[i]=e[i]);return r.prototype=e.prototype,t.prototype=new r,t.__super__=e.prototype,t},n={}.hasOwnProperty;Nutcracker.Models.Cluster=function(n){function r(){return this.set=t(this.set,this),r.__super__.constructor.apply(this,arguments)}return e(r,n),r.routeURL=function(t){return"#/clusters/"+t},r.prototype.initialize=function(){return this.set("routeURL",this.constructor.routeURL(this.get("name")))},r.prototype.set=function(t,e){var n;return null==t.nodes||t.nodes instanceof Nutcracker.Collections.Nodes||(t.nodes=new Nutcracker.Collections.Nodes(t.nodes)),null!=(n=t.nodes)&&n.map(function(t){return function(e){return e.get("clusters").push(t),e.set("clusters",_(e.get("clusters")).uniq())}}(this)),Backbone.Model.prototype.set.call(this,t,e)},r}(Backbone.Model)}.call(this),function(){var t=function(t,n){function r(){this.constructor=t}for(var i in n)e.call(n,i)&&(t[i]=n[i]);return r.prototype=n.prototype,t.prototype=new r,t.__super__=n.prototype,t},e={}.hasOwnProperty;Nutcracker.Models.Node=function(e){function n(){return n.__super__.constructor.apply(this,arguments)}return t(n,e),n.routeURL=function(t){return"#/nodes/"+t.split(":").slice(0,2).join(":")},n.prototype.initialize=function(){var t;return this.set("clusters",[]),this.set("hostname",null!=(t=this.get("server_url"))?t.replace(/redis:\/\//,""):void 0),this.set("maxMemory",this.get("info").max_memory),this.set("usedMemory",this.get("info").used_memory),this.set("freeMemory",this.get("info").max_memory-this.get("info").used_memory),this.set("usedMemoryRss",this.get("info").used_memory_rss),this.set("fragmentation",this.get("info").fragmentation),this.get("freeMemory")<0&&this.set("freeMemory",0),this.set("hits",this.get("info").hits),this.set("misses",this.get("info").misses),0===this.get("maxMemory")&&this.set("maxMemory",this.get("usedMemory")),0===this.get("hits")&&this.set("hits",1),this.set("routeURL",this.constructor.routeURL(this.get("hostname")))},n}(Backbone.Model)}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}},e=function(t,e){function r(){this.constructor=t}for(var i in e)n.call(e,i)&&(t[i]=e[i]);return r.prototype=e.prototype,t.prototype=new r,t.__super__=e.prototype,t},n={}.hasOwnProperty;Nutcracker.Models.Overview=function(n){function r(){return this.postInit=t(this.postInit,this),this.clusters=t(this.clusters,this),this.fetch=t(this.fetch,this),this.nodes=t(this.nodes,this),this.initialize=t(this.initialize,this),r.__super__.constructor.apply(this,arguments)}return e(r,n),r.prototype.url="/overview.json",r.prototype.initialize=function(){return this.postInit()},r.prototype.nodes=function(){return new Backbone.Collection(_(this.get("clusters").pluck("nodes")).chain().pluck("models").flatten().uniq(!1,function(t){return t.get("hostname")}).value())},r.prototype.fetch=function(){return r.__super__.fetch.apply(this,arguments)&&this.postInit(),Nutcracker.reload()},r.prototype.clusters=function(){return this.get("clusters")},r.prototype.postInit=function(){var t,e,n,r,i,o;for(t=_(this.get("clusters").pluck("client_connections")).sum(),o=0,i=this.get("clusters").pluck("nodes"),e=0,n=i.length;n>e;e++)r=i[e],o+=r.serverConnections();return this.set("serverConnections",o),this.set("clientConnections",t),this.set("initializeTime",new Date)},r.prototype.set=function(t,e){return null==t.clusters||t.clusters instanceof Nutcracker.Collections.Clusters||(t.clusters=new Nutcracker.Collections.Clusters(t.clusters)),Backbone.Model.prototype.set.call(this,t,e)},r}(Backbone.Model)}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}},e=function(t,e){function r(){this.constructor=t}for(var i in e)n.call(e,i)&&(t[i]=e[i]);return r.prototype=e.prototype,t.prototype=new r,t.__super__=e.prototype,t},n={}.hasOwnProperty;Nutcracker.Routers.Overview=function(n){function r(){return this._show=t(this._show,this),this.showConfig=t(this.showConfig,this),this.showNode=t(this.showNode,this),this.showCluster=t(this.showCluster,this),this.showOverview=t(this.showOverview,this),r.__super__.constructor.apply(this,arguments)}return e(r,n),r.prototype.routes={"":"showOverview",config:"showConfig","clusters/:cluster":"showCluster","nodes/:node":"showNode"},r.prototype.initialize=function(){return this.showOverview()},r.prototype.showOverview=function(){return this._show(Nutcracker.Views.Overview)},r.prototype.showCluster=function(t){var e,n;return e=Nutcracker.overview.clusters(),n=e.findWhere({name:t}),this._show(Nutcracker.Views.Cluster,{model:n,collection:e})},r.prototype.showNode=function(t){var e,n;return e=Nutcracker.overview.nodes(),n=e.findWhere({hostname:t}),this._show(Nutcracker.Views.Node,{model:n,collection:e})},r.prototype.showConfig=function(){return this._show(Nutcracker.Views.Config)},r.prototype._show=function(t,e){return null==e&&(e={model:Nutcracker.overview}),Nutcracker.screen.body(new t(e))},r}(Backbone.Router)}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}};Nutcracker.Utils.RegionManager=function(){function e(e,n,r,i){this.navbarID=null!=e?e:"#navbar",this.bodyID=null!=n?n:"#container",this.footerID=null!=r?r:"#footer",this.current=null!=i?i:{},this._render=t(this._render,this),this.footer=t(this.footer,this),this.body=t(this.body,this),this.navbar=t(this.navbar,this)}return e.prototype.navbar=function(t){return this._render(this.navbarID,t)},e.prototype.body=function(t){return this._render(this.bodyID,t)},e.prototype.footer=function(t){return this._render(this.footerID,t)},e.prototype._render=function(t,e){var n;return $(t).html(e.render().el),null!=(n=this.current[t])&&n.remove,this.current[t]=e},e}()}.call(this),function(){_.prototype.sum=function(){return _.reduce(this._wrapped,function(t,e){return t+e},0)},_.prototype.average=function(){return this.sum()/parseFloat(this._wrapped.length)}}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}},e=function(t,e){function r(){this.constructor=t}for(var i in e)n.call(e,i)&&(t[i]=e[i]);return r.prototype=e.prototype,t.prototype=new r,t.__super__=e.prototype,t},n={}.hasOwnProperty;Backbone.GoogleChart=function(n){function r(){return this.listen=t(this.listen,this),this.render=t(this.render,this),this.id=t(this.id,this),this.onGoogleLoad=t(this.onGoogleLoad,this),r.__super__.constructor.apply(this,arguments)}return e(r,n),r.prototype.initialize=function(t){var e;return e=_.extend({},t),["el","id","attributes","className","tagName"].map(function(t){return function(t){return delete e[t];
|
263
|
-
}}(this)),google.load("visualization","1",{packages:["corechart"],callback:function(t){return function(){return t.onGoogleLoad("loaded")}}(this)}),this.onGoogleLoad(function(t){return function(){var n,r;return t.google=google.visualization,e.dataTable instanceof Array&&(e.dataTable=t.google.arrayToDataTable(e.dataTable)),(e.beforeDraw||function(){})(t,e),(n=e.formatter)&&function(){r=[];for(var t=0,n=e.dataTable.getNumberOfRows()-1;n>=0?n>=t:t>=n;n>=0?t++:t--)r.push(t);return r}.apply(this).map(function(t){return n.columns.map(function(r){return e.dataTable.setFormattedValue(t,r,n.callback(e.dataTable.getValue(t,r)))})}),t.wrapper=new t.google.ChartWrapper(e),["ready","select","error"].map(t.listen)}}(this))},r.prototype.onGoogleLoad=function(t){return"loaded"===t?(this.googleLoaded=!0,_(this.onGoogleLoadItems).map(function(t){return t()})):this.googleLoaded?t():(this.onGoogleLoadItems||(this.onGoogleLoadItems=[])).push(t)},r.watch=function(t,e){var n,i;return(r._list||(r._list={}))[t]=e,r._watching?void 0:(r._watching=!0,i=10,(n=function(){return _(r._list).map(function(t,e){return $(e)[0]?t()||delete r._list[e]:void 0}),_(r._list).isEmpty()?r._watching=!1:setTimeout(n,i+=10)})())},r.prototype.id=function(){var t;return(null!=(t=this.el)?t.id:void 0)||this.randomID()},r.prototype.render=function(){return this.onGoogleLoad(function(t){return function(){return t.constructor.watch("#"+t.el.id,function(){return t.wrapper.draw(t.el.id)})}}(this)),this},r.prototype.listen=function(t){return this.google.events.addListener(this.wrapper,t,function(e){return function(){return e.trigger(t,e.wrapper.getChart())}}(this))},r.prototype.randomID=function(){return _.uniqueId("gc_")},r}(Backbone.View)}.call(this),function(){var t=function(t,n){function r(){this.constructor=t}for(var i in n)e.call(n,i)&&(t[i]=n[i]);return r.prototype=n.prototype,t.prototype=new r,t.__super__=n.prototype,t},e={}.hasOwnProperty;Nutcracker.Views.Cluster=function(e){function n(){return n.__super__.constructor.apply(this,arguments)}return t(n,e),n.prototype.template=JST.cluster,n.prototype.render=function(){var t,e,n;return this.curIndex=this.collection.indexOf(this.model),this.nextCluster=this.collection.at(this.curIndex+1),this.prevCluster=this.collection.at(this.curIndex-1),this.$el.html(this.template({model:this.model,nextCluster:this.nextCluster,prevCluster:this.prevCluster})),n={is3D:!0,titleTextStyle:{fontSize:17.5,color:"#333333"},width:300,height:300,sliceVisibilityThreshold:0,chartArea:{width:"100%",height:"80%"},legend:{position:"bottom"}},e=[["Node","Node"]],this.model.get("nodes").map(function(t){return e.push([t.get("hostname"),t.get("maxMemory")])}),t=new Backbone.GoogleChart({formatter:{callback:humanize.filesize,columns:[1]},chartType:"PieChart",options:n,dataTable:e}),t.on("select",function(t){return function(e){return Nutcracker.router.navigate(t.model.get("nodes").at(e.getSelection()[0].row).get("routeURL"),{trigger:!0})}}(this)),this.$el.find("#chart2").html(t.render().el),this.$el.find("#chart1").html(new Backbone.GoogleChart({formatter:{callback:humanize.filesize,columns:[1]},chartType:"PieChart",options:n,dataTable:[["Memory","Memory"],["Free",this.model.get("nodes").freeMemory()],["Used",this.model.get("nodes").usedMemory()]]}).render().el),this},n}(Backbone.View)}.call(this),function(){var t=function(t,n){function r(){this.constructor=t}for(var i in n)e.call(n,i)&&(t[i]=n[i]);return r.prototype=n.prototype,t.prototype=new r,t.__super__=n.prototype,t},e={}.hasOwnProperty;Nutcracker.Views.Config=function(e){function n(){return n.__super__.constructor.apply(this,arguments)}return t(n,e),n.prototype.template=JST.config,n.prototype.render=function(){return this.$el.html(this.template({model:this.model})),this},n}(Backbone.View)}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}},e=function(t,e){function r(){this.constructor=t}for(var i in e)n.call(e,i)&&(t[i]=e[i]);return r.prototype=e.prototype,t.prototype=new r,t.__super__=e.prototype,t},n={}.hasOwnProperty;Nutcracker.Views.Footer=function(n){function r(){return this.render=t(this.render,this),r.__super__.constructor.apply(this,arguments)}return e(r,n),r.prototype.className="container navbar navbar-fixed-bottom navbar-inverse",r.prototype.template=JST.footer,r.prototype.render=function(){return this.$el.html(this.template({model:this.model})),this.$el.find("#lastUpdate").html("Last updated: "+humanize.relativeTime(this.model.get("initializeTime")/1e3)),setTimeout(this.render,1e3),this},r}(Backbone.View)}.call(this),function(){var t=function(t,e){return function(){return t.apply(e,arguments)}},e=function(t,e){function r(){this.constructor=t}for(var i in e)n.call(e,i)&&(t[i]=e[i]);return r.prototype=e.prototype,t.prototype=new r,t.__super__=e.prototype,t},n={}.hasOwnProperty;Nutcracker.Views.Navbar=function(n){function r(){return this.render=t(this.render,this),this.activate=t(this.activate,this),this.autoRefresh=t(this.autoRefresh,this),this.resetButtons=t(this.resetButtons,this),this.initialize=t(this.initialize,this),r.__super__.constructor.apply(this,arguments)}return e(r,n),r.prototype.className="navbar navbar-inverse navbar-fixed-top",r.prototype.template=JST.navbar,r.prototype.events={"click .auto-refresh-button":"autoRefresh"},r.prototype.initialize=function(){return Backbone.history.bind("all",this.resetButtons),this.listenTo(this.model,"change",this.render),this.autoRefreshInterval=null},r.prototype.resetButtons=function(){var t;return this.$el.find("li").removeClass("active"),this.autoRefreshInterval?(this.$("#auto-refresh-drop-down").addClass("active"),this.$("#auto-refresh-value-"+this.autoRefreshInterval).addClass("active")):(this.$("#auto-refresh-drop-down").removeClass("active"),this.$("#auto-refresh-drop-down").find(".active").removeClass("active")),t=window.location.href,/#\/config$/.test(t)?this.activate("#config"):/#\/clusters\//.test(t)?this.activate("#clusters"):/#\/nodes\//.test(t)?this.activate("#nodes"):this.activate("#overview")},r.prototype.autoRefresh=function(t){var e;return e=parseInt($(t.currentTarget).attr("value")),this.autoRefreshTimer&&clearInterval(this.autoRefreshTimer),e===this.autoRefreshInterval?this.autoRefreshInterval=null:(this.autoRefreshInterval=e,this.autoRefreshTimer=setInterval(function(t){return function(){return t.model.fetch()}}(this),1e3*this.autoRefreshInterval)),this.resetButtons(),t.preventDefault()},r.prototype.activate=function(t){return this.$(t).addClass("active")},r.prototype.render=function(){return this.$el.html(this.template({model:this.model})),this.resetButtons(),this},r}(Backbone.View)}.call(this),function(){var t=function(t,n){function r(){this.constructor=t}for(var i in n)e.call(n,i)&&(t[i]=n[i]);return r.prototype=n.prototype,t.prototype=new r,t.__super__=n.prototype,t},e={}.hasOwnProperty;Nutcracker.Views.Node=function(e){function n(){return n.__super__.constructor.apply(this,arguments)}return t(n,e),n.prototype.template=JST.node,n.prototype.render=function(){var t;return this.curIndex=this.collection.indexOf(this.model),this.nextNode=this.collection.at(this.curIndex+1),this.prevNode=this.collection.at(this.curIndex-1),t={is3D:!0,titleTextStyle:{fontSize:17.5,color:"#333333"},titleTextStyle:{fontSize:17.5,color:"#333333"},width:300,height:300,sliceVisibilityThreshold:0,chartArea:{width:"100%",height:"80%"},legend:{position:"bottom"}},this.$el.html(this.template({model:this.model,nextNode:this.nextNode,prevNode:this.prevNode})),this.$el.find("#chart1").append(new Backbone.GoogleChart({chartType:"PieChart",formatter:{callback:humanize.filesize,columns:[1]},options:_({title:"Memory"}).extend(t),dataTable:[["Memory","Memory"],["Free",this.model.get("freeMemory")],["Used",this.model.get("usedMemory")]]}).render().el),this.$el.find("#chart2").append(new Backbone.GoogleChart({formatter:{callback:humanize.numberFormat,columns:[1]},chartType:"PieChart",options:_({title:"Hits"}).extend(t),dataTable:[["Memory","Memory"],["Hits",this.model.get("hits")],["Misses",this.model.get("misses")]]}).render().el),this},n}(Backbone.View)}.call(this),function(){var t=function(t,n){function r(){this.constructor=t}for(var i in n)e.call(n,i)&&(t[i]=n[i]);return r.prototype=n.prototype,t.prototype=new r,t.__super__=n.prototype,t},e={}.hasOwnProperty;Nutcracker.Views.Overview=function(e){function n(){return n.__super__.constructor.apply(this,arguments)}return t(n,e),n.prototype.template=JST.overview,n.prototype.render=function(){return this.$el.html(this.template({model:this.model})),this},n}(Backbone.View)}.call(this);
|
25
|
+
function(n,i){function x(t,e,n,r){var i,o,s,a,u,l,c,h,f,p;if((e?e.ownerDocument||e:W)!==P&&R(e),n=n||[],!t||"string"!=typeof t)return n;if(1!==(a=(e=e||P).nodeType)&&9!==a)return[];if(H&&!r){if(i=Ct.exec(t))if(s=i[1]){if(9===a){if(!(o=e.getElementById(s))||!o.parentNode)return n;if(o.id===s)return n.push(o),n}else if(e.ownerDocument&&(o=e.ownerDocument.getElementById(s))&&I(e,o)&&o.id===s)return n.push(o),n}else{if(i[2])return it.apply(n,e.getElementsByTagName(t)),n;if((s=i[3])&&S.getElementsByClassName&&e.getElementsByClassName)return it.apply(n,e.getElementsByClassName(s)),n}if(S.qsa&&(!z||!z.test(t))){if(h=c=B,f=e,p=9===a&&t,1===a&&"object"!==e.nodeName.toLowerCase()){for(l=m(t),(c=e.getAttribute("id"))?h=c.replace(_t,"\\$&"):e.setAttribute("id",h),h="[id='"+h+"'] ",u=l.length;u--;)l[u]=h+g(l[u]);f=gt.test(t)&&e.parentNode||e,p=l.join(",")}if(p)try{return it.apply(n,f.querySelectorAll(p)),n}catch(d){}finally{c||e.removeAttribute("id")}}}return T(t.replace(pt,"$1"),e,n,r)}function r(t){return xt.test(t+"")}function t(){function n(t,e){return r.push(t+=" ")>E.cacheLength&&delete n[r.shift()],n[t]=e}var r=[];return n}function u(t){return t[B]=!0,t}function o(t){var e=P.createElement("div");try{return!!t(e)}catch(n){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function s(t,e,n){for(var r,i=(t=t.split("|")).length,o=n?null:e;i--;)(r=E.attrHandle[t[i]])&&r!==e||(E.attrHandle[t[i]]=o)}function a(t,e){var n=t.getAttributeNode(e);return n&&n.specified?n.value:!0===t[e]?e.toLowerCase():null}function l(t,e){return t.getAttribute(e,"type"===e.toLowerCase()?1:2)}function c(t){if("input"===t.nodeName.toLowerCase())return t.defaultValue}function h(t,e){var n=e&&t,r=n&&1===t.nodeType&&1===e.nodeType&&(~e.sourceIndex||Z)-(~t.sourceIndex||Z);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===e)return-1;return t?1:-1}function e(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function f(n){return function(t){var e=t.nodeName.toLowerCase();return("input"===e||"button"===e)&&t.type===n}}function p(s){return u(function(o){return o=+o,u(function(t,e){for(var n,r=s([],t.length,o),i=r.length;i--;)t[n=r[i]]&&(t[n]=!(e[n]=t[n]))})})}function m(t,e){var n,r,i,o,s,a,u,l=X[t+" "];if(l)return e?0:l.slice(0);for(s=t,a=[],u=E.preFilter;s;){for(o in n&&!(r=dt.exec(s))||(r&&(s=s.slice(r[0].length)||s),a.push(i=[])),n=!1,(r=mt.exec(s))&&(n=r.shift(),i.push({value:n,type:r[0].replace(pt," ")}),s=s.slice(n.length)),E.filter)!(r=wt[o].exec(s))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),s=s.slice(n.length));if(!n)break}return e?s.length:s?x.error(t):X(t,a).slice(0)}function g(t){for(var e=0,n=t.length,r="";e<n;e++)r+=t[e].value;return r}function d(a,t,e){var u=t.dir,l=e&&"parentNode"===u,c=J++;return t.first?function(t,e,n){for(;t=t[u];)if(1===t.nodeType||l)return a(t,e,n)}:function(t,e,n){var r,i,o,s=U+" "+c;if(n){for(;t=t[u];)if((1===t.nodeType||l)&&a(t,e,n))return!0}else for(;t=t[u];)if(1===t.nodeType||l)if((i=(o=t[B]||(t[B]={}))[u])&&i[0]===s){if(!0===(r=i[1])||r===$)return!0===r}else if((i=o[u]=[s])[1]=a(t,e,n)||$,!0===i[1])return!0}}function v(i){return 1<i.length?function(t,e,n){for(var r=i.length;r--;)if(!i[r](t,e,n))return!1;return!0}:i[0]}function C(t,e,n,r,i){for(var o,s=[],a=0,u=t.length,l=null!=e;a<u;a++)(o=t[a])&&(n&&!n(o,r,i)||(s.push(o),l&&e.push(a)));return s}function y(p,d,m,g,v,t){return g&&!g[B]&&(g=y(g)),v&&!v[B]&&(v=y(v,t)),u(function(t,e,n,r){var i,o,s,a=[],u=[],l=e.length,c=t||k(d||"*",n.nodeType?[n]:n,[]),h=!p||!t&&d?c:C(c,a,p,n,r),f=m?v||(t?p:l||g)?[]:e:h;if(m&&m(h,f,n,r),g)for(i=C(f,u),g(i,[],n,r),o=i.length;o--;)(s=i[o])&&(f[u[o]]=!(h[u[o]]=s));if(t){if(v||p){if(v){for(i=[],o=f.length;o--;)(s=f[o])&&i.push(h[o]=s);v(null,f=[],i,r)}for(o=f.length;o--;)(s=f[o])&&-1<(i=v?st.call(t,s):a[o])&&(t[i]=!(e[i]=s))}}else f=C(f===e?f.splice(l,f.length):f),v?v(null,e,f,r):it.apply(e,f)})}function b(t){for(var r,e,n,i=t.length,o=E.relative[t[0].type],s=o||E.relative[" "],a=o?1:0,u=d(function(t){return t===r},s,!0),l=d(function(t){return-1<st.call(r,t)},s,!0),c=[function(t,e,n){return!o&&(n||e!==A)||((r=e).nodeType?u(t,e,n):l(t,e,n))}];a<i;a++)if(e=E.relative[t[a].type])c=[d(v(c),e)];else{if((e=E.filter[t[a].type].apply(null,t[a].matches))[B]){for(n=++a;n<i&&!E.relative[t[n].type];n++);return y(1<a&&v(c),1<a&&g(t.slice(0,a-1).concat({value:" "===t[a-2].type?"*":""})).replace(pt,"$1"),e,a<n&&b(t.slice(a,n)),n<i&&b(t=t.slice(n)),n<i&&g(t))}c.push(e)}return v(c)}function w(g,v){var y=0,b=0<v.length,w=0<g.length,t=function(t,e,n,r,i){var o,s,a,u=[],l=0,c="0",h=t&&[],f=null!=i,p=A,d=t||w&&E.find.TAG("*",i&&e.parentNode||e),m=U+=null==p?1:Math.random()||.1;for(f&&(A=e!==P&&e,$=y);null!=(o=d[c]);c++){if(w&&o){for(s=0;a=g[s++];)if(a(o,e,n)){r.push(o);break}f&&(U=m,$=++y)}b&&((o=!a&&o)&&l--,t&&h.push(o))}if(l+=c,b&&c!==l){for(s=0;a=v[s++];)a(h,u,e,n);if(t){if(0<l)for(;c--;)h[c]||u[c]||(u[c]=nt.call(r));u=C(u)}it.apply(r,u),f&&!t&&0<u.length&&1<l+v.length&&x.uniqueSort(r)}return f&&(U=m,A=p),h};return b?u(t):t}function k(t,e,n){for(var r=0,i=e.length;r<i;r++)x(t,e[r],n);return n}function T(t,e,n,r){var i,o,s,a,u,l=m(t);if(!r&&1===l.length){if(2<(o=l[0]=l[0].slice(0)).length&&"ID"===(s=o[0]).type&&S.getById&&9===e.nodeType&&H&&E.relative[o[1].type]){if(!(e=(E.find.ID(s.matches[0].replace(Nt,St),e)||[])[0]))return n;t=t.slice(o.shift().value.length)}for(i=wt.needsContext.test(t)?0:o.length;i--&&(s=o[i],!E.relative[a=s.type]);)if((u=E.find[a])&&(r=u(s.matches[0].replace(Nt,St),gt.test(o[0].type)&&e.parentNode||e))){if(o.splice(i,1),!(t=r.length&&g(o)))return it.apply(n,r),n;break}}return D(t,l)(r,e,!H,n,gt.test(t)),n}function _(){}var N,S,$,E,j,M,D,A,O,R,P,L,H,z,q,F,I,B="sizzle"+-new Date,W=n.document,U=0,J=0,V=t(),X=t(),G=t(),Y=!1,Q=function(){return 0},K=typeof i,Z=1<<31,tt={}.hasOwnProperty,et=[],nt=et.pop,rt=et.push,it=et.push,ot=et.slice,st=et.indexOf||function(t){for(var e=0,n=this.length;e<n;e++)if(this[e]===t)return e;return-1},at="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",ut="[\\x20\\t\\r\\n\\f]",lt="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",ct=lt.replace("w","w#"),ht="\\["+ut+"*("+lt+")"+ut+"*(?:([*^$|!~]?=)"+ut+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+ct+")|)|)"+ut+"*\\]",ft=":("+lt+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+ht.replace(3,8)+")*)|.*)\\)|)",pt=new RegExp("^"+ut+"+|((?:^|[^\\\\])(?:\\\\.)*)"+ut+"+$","g"),dt=new RegExp("^"+ut+"*,"+ut+"*"),mt=new RegExp("^"+ut+"*([>+~]|"+ut+")"+ut+"*"),gt=new RegExp(ut+"*[+~]"),vt=new RegExp("="+ut+"*([^\\]'\"]*)"+ut+"*\\]","g"),yt=new RegExp(ft),bt=new RegExp("^"+ct+"$"),wt={ID:new RegExp("^#("+lt+")"),CLASS:new RegExp("^\\.("+lt+")"),TAG:new RegExp("^("+lt.replace("w","w*")+")"),ATTR:new RegExp("^"+ht),PSEUDO:new RegExp("^"+ft),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+ut+"*(even|odd|(([+-]|)(\\d*)n|)"+ut+"*(?:([+-]|)"+ut+"*(\\d+)|))"+ut+"*\\)|)","i"),bool:new RegExp("^(?:"+at+")$","i"),needsContext:new RegExp("^"+ut+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+ut+"*((?:-\\d)?\\d*)"+ut+"*\\)|)(?=[^-]|$)","i")},xt=/^[^{]+\{\s*\[native \w/,Ct=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,kt=/^(?:input|select|textarea|button)$/i,Tt=/^h\d$/i,_t=/'|\\/g,Nt=new RegExp("\\\\([\\da-f]{1,6}"+ut+"?|("+ut+")|.)","ig"),St=function(t,e,n){var r="0x"+e-65536;return r!=r||n?e:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)};try{it.apply(et=ot.call(W.childNodes),W.childNodes),et[W.childNodes.length].nodeType}catch($t){it={apply:et.length?function(t,e){rt.apply(t,ot.call(e))}:function(t,e){for(var n=t.length,r=0;t[n++]=e[r++];);t.length=n-1}}}for(N in M=x.isXML=function(t){var e=t&&(t.ownerDocument||t).documentElement;return!!e&&"HTML"!==e.nodeName},S=x.support={},R=x.setDocument=function(t){var u=t?t.ownerDocument||t:W,e=u.parentWindow;return u!==P&&9===u.nodeType&&u.documentElement?(L=(P=u).documentElement,H=!M(u),e&&e.frameElement&&e.attachEvent("onbeforeunload",function(){R()}),S.attributes=o(function(t){return t.innerHTML="<a href='#'></a>",s("type|href|height|width",l,"#"===t.firstChild.getAttribute("href")),s(at,a,null==t.getAttribute("disabled")),t.className="i",!t.getAttribute("className")}),S.input=o(function(t){return t.innerHTML="<input>",t.firstChild.setAttribute("value",""),""===t.firstChild.getAttribute("value")}),s("value",c,S.attributes&&S.input),S.getElementsByTagName=o(function(t){return t.appendChild(u.createComment("")),!t.getElementsByTagName("*").length}),S.getElementsByClassName=o(function(t){return t.innerHTML="<div class='a'></div><div class='a i'></div>",t.firstChild.className="i",2===t.getElementsByClassName("i").length}),S.getById=o(function(t){return L.appendChild(t).id=B,!u.getElementsByName||!u.getElementsByName(B).length}),S.getById?(E.find.ID=function(t,e){if(typeof e.getElementById!==K&&H){var n=e.getElementById(t);return n&&n.parentNode?[n]:[]}},E.filter.ID=function(t){var e=t.replace(Nt,St);return function(t){return t.getAttribute("id")===e}}):(delete E.find.ID,E.filter.ID=function(t){var n=t.replace(Nt,St);return function(t){var e=typeof t.getAttributeNode!==K&&t.getAttributeNode("id");return e&&e.value===n}}),E.find.TAG=S.getElementsByTagName?function(t,e){if(typeof e.getElementsByTagName!==K)return e.getElementsByTagName(t)}:function(t,e){var n,r=[],i=0,o=e.getElementsByTagName(t);if("*"!==t)return o;for(;n=o[i++];)1===n.nodeType&&r.push(n);return r},E.find.CLASS=S.getElementsByClassName&&function(t,e){if(typeof e.getElementsByClassName!==K&&H)return e.getElementsByClassName(t)},q=[],z=[],(S.qsa=r(u.querySelectorAll))&&(o(function(t){t.innerHTML="<select><option selected=''></option></select>",t.querySelectorAll("[selected]").length||z.push("\\["+ut+"*(?:value|"+at+")"),t.querySelectorAll(":checked").length||z.push(":checked")}),o(function(t){var e=u.createElement("input");e.setAttribute("type","hidden"),t.appendChild(e).setAttribute("t",""),t.querySelectorAll("[t^='']").length&&z.push("[*^$]="+ut+"*(?:''|\"\")"),t.querySelectorAll(":enabled").length||z.push(":enabled",":disabled"),t.querySelectorAll("*,:x"),z.push(",.*:")})),(S.matchesSelector=r(F=L.webkitMatchesSelector||L.mozMatchesSelector||L.oMatchesSelector||L.msMatchesSelector))&&o(function(t){S.disconnectedMatch=F.call(t,"div"),F.call(t,"[s!='']:x"),q.push("!=",ft)}),z=z.length&&new RegExp(z.join("|")),q=q.length&&new RegExp(q.join("|")),I=r(L.contains)||L.compareDocumentPosition?function(t,e){var n=9===t.nodeType?t.documentElement:t,r=e&&e.parentNode;return t===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):t.compareDocumentPosition&&16&t.compareDocumentPosition(r)))}:function(t,e){if(e)for(;e=e.parentNode;)if(e===t)return!0;return!1},S.sortDetached=o(function(t){return 1&t.compareDocumentPosition(u.createElement("div"))}),Q=L.compareDocumentPosition?function(t,e){if(t===e)return Y=!0,0;var n=e.compareDocumentPosition&&t.compareDocumentPosition&&t.compareDocumentPosition(e);return n?1&n||!S.sortDetached&&e.compareDocumentPosition(t)===n?t===u||I(W,t)?-1:e===u||I(W,e)?1:O?st.call(O,t)-st.call(O,e):0:4&n?-1:1:t.compareDocumentPosition?-1:1}:function(t,e){var n,r=0,i=t.parentNode,o=e.parentNode,s=[t],a=[e];if(t===e)return Y=!0,0;if(!i||!o)return t===u?-1:e===u?1:i?-1:o?1:O?st.call(O,t)-st.call(O,e):0;if(i===o)return h(t,e);for(n=t;n=n.parentNode;)s.unshift(n);for(n=e;n=n.parentNode;)a.unshift(n);for(;s[r]===a[r];)r++;return r?h(s[r],a[r]):s[r]===W?-1:a[r]===W?1:0},u):P},x.matches=function(t,e){return x(t,null,null,e)},x.matchesSelector=function(t,e){if((t.ownerDocument||t)!==P&&R(t),e=e.replace(vt,"='$1']"),S.matchesSelector&&H&&(!q||!q.test(e))&&(!z||!z.test(e)))try{var n=F.call(t,e);if(n||S.disconnectedMatch||t.document&&11!==t.document.nodeType)return n}catch($t){}return 0<x(e,P,null,[t]).length},x.contains=function(t,e){return(t.ownerDocument||t)!==P&&R(t),I(t,e)},x.attr=function(t,e){(t.ownerDocument||t)!==P&&R(t);var n=E.attrHandle[e.toLowerCase()],r=n&&tt.call(E.attrHandle,e.toLowerCase())?n(t,e,!H):i;return r===i?S.attributes||!H?t.getAttribute(e):(r=t.getAttributeNode(e))&&r.specified?r.value:null:r},x.error=function(t){throw new Error("Syntax error, unrecognized expression: "+t)},x.uniqueSort=function(t){var e,n=[],r=0,i=0;if(Y=!S.detectDuplicates,O=!S.sortStable&&t.slice(0),t.sort(Q),Y){for(;e=t[i++];)e===t[i]&&(r=n.push(i));for(;r--;)t.splice(n[r],1)}return t},j=x.getText=function(t){var e,n="",r=0,i=t.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof t.textContent)return t.textContent;for(t=t.firstChild;t;t=t.nextSibling)n+=j(t)}else if(3===i||4===i)return t.nodeValue}else for(;e=t[r];r++)n+=j(e);return n},E=x.selectors={cacheLength:50,createPseudo:u,match:wt,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(t){return t[1]=t[1].replace(Nt,St),t[3]=(t[4]||t[5]||"").replace(Nt,St),"~="===t[2]&&(t[3]=" "+t[3]+" "),t.slice(0,4)},CHILD:function(t){return t[1]=t[1].toLowerCase(),"nth"===t[1].slice(0,3)?(t[3]||x.error(t[0]),t[4]=+(t[4]?t[5]+(t[6]||1):2*("even"===t[3]||"odd"===t[3])),t[5]=+(t[7]+t[8]||"odd"===t[3])):t[3]&&x.error(t[0]),t},PSEUDO:function(t){var e,n=!t[5]&&t[2];return wt.CHILD.test(t[0])?null:(t[3]&&t[4]!==i?t[2]=t[4]:n&&yt.test(n)&&(e=m(n,!0))&&(e=n.indexOf(")",n.length-e)-n.length)&&(t[0]=t[0].slice(0,e),t[2]=n.slice(0,e)),t.slice(0,3))}},filter:{TAG:function(t){var e=t.replace(Nt,St).toLowerCase();return"*"===t?function(){return!0}:function(t){return t.nodeName&&t.nodeName.toLowerCase()===e}},CLASS:function(t){var e=V[t+" "];return e||(e=new RegExp("(^|"+ut+")"+t+"("+ut+"|$)"))&&V(t,function(t){return e.test("string"==typeof t.className&&t.className||typeof t.getAttribute!==K&&t.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(t){var e=x.attr(t,n);return null==e?"!="===r:!r||(e+="","="===r?e===i:"!="===r?e!==i:"^="===r?i&&0===e.indexOf(i):"*="===r?i&&-1<e.indexOf(i):"$="===r?i&&e.slice(-i.length)===i:"~="===r?-1<(" "+e+" ").indexOf(i):"|="===r&&(e===i||e.slice(0,i.length+1)===i+"-"))}},CHILD:function(p,t,e,d,m){var g="nth"!==p.slice(0,3),v="last"!==p.slice(-4),y="of-type"===t;return 1===d&&0===m?function(t){return!!t.parentNode}:function(t,e,n){var r,i,o,s,a,u,l=g!==v?"nextSibling":"previousSibling",c=t.parentNode,h=y&&t.nodeName.toLowerCase(),f=!n&&!y;if(c){if(g){for(;l;){for(o=t;o=o[l];)if(y?o.nodeName.toLowerCase()===h:1===o.nodeType)return!1;u=l="only"===p&&!u&&"nextSibling"}return!0}if(u=[v?c.firstChild:c.lastChild],v&&f){for(a=(r=(i=c[B]||(c[B]={}))[p]||[])[0]===U&&r[1],s=r[0]===U&&r[2],o=a&&c.childNodes[a];o=++a&&o&&o[l]||(s=a=0)||u.pop();)if(1===o.nodeType&&++s&&o===t){i[p]=[U,a,s];break}}else if(f&&(r=(t[B]||(t[B]={}))[p])&&r[0]===U)s=r[1];else for(;(o=++a&&o&&o[l]||(s=a=0)||u.pop())&&((y?o.nodeName.toLowerCase()!==h:1!==o.nodeType)||!++s||(f&&((o[B]||(o[B]={}))[p]=[U,s]),o!==t)););return(s-=m)===d||s%d==0&&0<=s/d}}},PSEUDO:function(t,o){var e,s=E.pseudos[t]||E.setFilters[t.toLowerCase()]||x.error("unsupported pseudo: "+t);return s[B]?s(o):1<s.length?(e=[t,t,"",o],E.setFilters.hasOwnProperty(t.toLowerCase())?u(function(t,e){for(var n,r=s(t,o),i=r.length;i--;)t[n=st.call(t,r[i])]=!(e[n]=r[i])}):function(t){return s(t,0,e)}):s}},pseudos:{not:u(function(t){var r=[],i=[],a=D(t.replace(pt,"$1"));return a[B]?u(function(t,e,n,r){for(var i,o=a(t,null,r,[]),s=t.length;s--;)(i=o[s])&&(t[s]=!(e[s]=i))}):function(t,e,n){return r[0]=t,a(r,null,n,i),!i.pop()}}),has:u(function(e){return function(t){return 0<x(e,t).length}}),contains:u(function(e){return function(t){return-1<(t.textContent||t.innerText||j(t)).indexOf(e)}}),lang:u(function(n){return bt.test(n||"")||x.error("unsupported lang: "+n),n=n.replace(Nt,St).toLowerCase(),function(t){var e;do{if(e=H?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(e=e.toLowerCase())===n||0===e.indexOf(n+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var e=n.location&&n.location.hash;return e&&e.slice(1)===t.id},root:function(t){return t===L},focus:function(t){return t===P.activeElement&&(!P.hasFocus||P.hasFocus())&&!!(t.type||t.href||~t.tabIndex)},enabled:function(t){return!1===t.disabled},disabled:function(t){return!0===t.disabled},checked:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&!!t.checked||"option"===e&&!!t.selected},selected:function(t){return t.parentNode&&t.parentNode.selectedIndex,!0===t.selected},empty:function(t){for(t=t.firstChild;t;t=t.nextSibling)if("@"<t.nodeName||3===t.nodeType||4===t.nodeType)return!1;return!0},parent:function(t){return!E.pseudos.empty(t)},header:function(t){return Tt.test(t.nodeName)},input:function(t){return kt.test(t.nodeName)},button:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&"button"===t.type||"button"===e},text:function(t){var e;return"input"===t.nodeName.toLowerCase()&&"text"===t.type&&(null==(e=t.getAttribute("type"))||e.toLowerCase()===t.type)},first:p(function(){return[0]}),last:p(function(t,e){return[e-1]}),eq:p(function(t,e,n){return[n<0?n+e:n]}),even:p(function(t,e){for(var n=0;n<e;n+=2)t.push(n);return t}),odd:p(function(t,e){for(var n=1;n<e;n+=2)t.push(n);return t}),lt:p(function(t,e,n){for(var r=n<0?n+e:n;0<=--r;)t.push(r);return t}),gt:p(function(t,e,n){for(var r=n<0?n+e:n;++r<e;)t.push(r);return t})}},{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})E.pseudos[N]=e(N);for(N in{submit:!0,reset:!0})E.pseudos[N]=f(N);D=x.compile=function(t,e){var n,r=[],i=[],o=G[t+" "];if(!o){for(e||(e=m(t)),n=e.length;n--;)(o=b(e[n]))[B]?r.push(o):i.push(o);o=G(t,w(i,r))}return o},E.pseudos.nth=E.pseudos.eq,_.prototype=E.filters=E.pseudos,E.setFilters=new _,S.sortStable=B.split("").sort(Q).join("")===B,R(),[0,0].sort(Q),S.detectDuplicates=Y,Et.find=x,Et.expr=x.selectors,Et.expr[":"]=Et.expr.pseudos,Et.unique=x.uniqueSort,Et.text=x.getText,Et.isXMLDoc=x.isXML,Et.contains=x.contains}(d);var pt,dt,mt,gt,vt,yt,bt={};Et.Callbacks=function(i){i="string"==typeof i?bt[i]||t(i):Et.extend({},i);var e,n,o,s,a,r,u=[],l=!i.once&&[],c=function(t){for(e=i.memory&&t,n=!0,r=s||0,s=0,a=u.length,o=!0;u&&r<a;r++)if(!1===u[r].apply(t[0],t[1])&&i.stopOnFalse){e=!1;break}o=!1,u&&(l?l.length&&c(l.shift()):e?u=[]:h.disable())},h={add:function(){if(u){var t=u.length;!function r(t){Et.each(t,function(t,e){var n=Et.type(e);"function"===n?i.unique&&h.has(e)||u.push(e):e&&e.length&&"string"!==n&&r(e)})}(arguments),o?a=u.length:e&&(s=t,c(e))}return this},remove:function(){return u&&Et.each(arguments,function(t,e){for(var n;-1<(n=Et.inArray(e,u,n));)u.splice(n,1),o&&(n<=a&&a--,n<=r&&r--)}),this},has:function(t){return t?-1<Et.inArray(t,u):!(!u||!u.length)},empty:function(){return u=[],a=0,this},disable:function(){return u=l=e=k,this},disabled:function(){return!u},lock:function(){return l=k,e||h.disable(),this},locked:function(){return!l},fireWith:function(t,e){return e=[t,(e=e||[]).slice?e.slice():e],!u||n&&!l||(o?l.push(e):c(e)),this},fire:function(){return h.fireWith(this,arguments),this},fired:function(){return!!n}};return h},Et.extend({Deferred:function(t){var s=[["resolve","done",Et.Callbacks("once memory"),"resolved"],["reject","fail",Et.Callbacks("once memory"),"rejected"],["notify","progress",Et.Callbacks("memory")]],i="pending",a={state:function(){return i},always:function(){return u.done(arguments).fail(arguments),this},then:function(){var o=arguments;return Et.Deferred(function(i){Et.each(s,function(t,e){var n=e[0],r=Et.isFunction(o[t])&&o[t];u[e[1]](function(){var t=r&&r.apply(this,arguments);t&&Et.isFunction(t.promise)?t.promise().done(i.resolve).fail(i.reject).progress(i.notify):i[n+"With"](this===a?i.promise():this,r?[t]:arguments)})}),o=null}).promise()},promise:function(t){return null!=t?Et.extend(t,a):a}},u={};return a.pipe=a.then,Et.each(s,function(t,e){var n=e[2],r=e[3];a[e[1]]=n.add,r&&n.add(function(){i=r},s[1^t][2].disable,s[2][2].lock),u[e[0]]=function(){return u[e[0]+"With"](this===u?a:this,arguments),this},u[e[0]+"With"]=n.fireWith}),a.promise(u),t&&t.call(u,u),u},when:function(t){var i,e,n,r=0,o=tt.call(arguments),s=o.length,a=1!==s||t&&Et.isFunction(t.promise)?s:0,u=1===a?t:Et.Deferred(),l=function(e,n,r){return function(t){n[e]=this,r[e]=1<arguments.length?tt.call(arguments):t,r===i?u.notifyWith(n,r):--a||u.resolveWith(n,r)}};if(1<s)for(i=new Array(s),e=new Array(s),n=new Array(s);r<s;r++)o[r]&&Et.isFunction(o[r].promise)?o[r].promise().done(l(r,n,o)).fail(u.reject).progress(l(r,e,i)):--a;return a||u.resolveWith(n,o),u.promise()}}),Et.support=(pt={},dt=U.createElement("input"),mt=U.createDocumentFragment(),gt=U.createElement("div"),vt=U.createElement("select"),yt=vt.appendChild(U.createElement("option")),dt.type&&(dt.type="checkbox",pt.checkOn=""!==dt.value,pt.optSelected=yt.selected,pt.reliableMarginRight=!0,pt.boxSizingReliable=!0,pt.pixelPosition=!1,dt.checked=!0,pt.noCloneChecked=dt.cloneNode(!0).checked,vt.disabled=!0,pt.optDisabled=!yt.disabled,(dt=U.createElement("input")).value="t",dt.type="radio",pt.radioValue="t"===dt.value,dt.setAttribute("checked","t"),dt.setAttribute("name","t"),mt.appendChild(dt),pt.checkClone=mt.cloneNode(!0).cloneNode(!0).lastChild.checked,pt.focusinBubbles="onfocusin"in d,gt.style.backgroundClip="content-box",gt.cloneNode(!0).style.backgroundClip="",pt.clearCloneStyle="content-box"===gt.style.backgroundClip,Et(function(){var t,e,n="padding:0;margin:0;border:0;display:block;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box",r=U.getElementsByTagName("body")[0];r&&((t=U.createElement("div")).style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",r.appendChild(t).appendChild(gt),gt.innerHTML="",gt.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%",Et.swap(r,null!=r.style.zoom?{zoom:1}:{},function(){pt.boxSizing=4===gt.offsetWidth}),d.getComputedStyle&&(pt.pixelPosition="1%"!==(d.getComputedStyle(gt,null)||{}).top,pt.boxSizingReliable="4px"===(d.getComputedStyle(gt,null)||{width:"4px"}).width,(e=gt.appendChild(U.createElement("div"))).style.cssText=gt.style.cssText=n,e.style.marginRight=e.style.width="0",gt.style.width="1px",pt.reliableMarginRight=!parseFloat((d.getComputedStyle(e,null)||{}).marginRight)),r.removeChild(t))})),pt);var wt,xt,Ct=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,kt=/([A-Z])/g;l.uid=1,l.accepts=function(t){return!t.nodeType||(1===t.nodeType||9===t.nodeType)},l.prototype={key:function(t){if(!l.accepts(t))return 0;var e={},n=t[this.expando];if(!n){n=l.uid++;try{e[this.expando]={value:n},Object.defineProperties(t,e)}catch(r){e[this.expando]=n,Et.extend(t,e)}}return this.cache[n]||(this.cache[n]={}),n},set:function(t,e,n){var r,i=this.key(t),o=this.cache[i];if("string"==typeof e)o[e]=n;else if(Et.isEmptyObject(o))Et.extend(this.cache[i],e);else for(r in e)o[r]=e[r];return o},get:function(t,e){var n=this.cache[this.key(t)];return e===k?n:n[e]},access:function(t,e,n){return e===k||e&&"string"==typeof e&&n===k?this.get(t,e):(this.set(t,e,n),n!==k?n:e)},remove:function(t,e){var n,r,i,o=this.key(t),s=this.cache[o];if(e===k)this.cache[o]={};else{n=(r=Et.isArray(e)?e.concat(e.map(Et.camelCase)):(i=Et.camelCase(e),e in s?[e,i]:(r=i)in s?[r]:r.match(st)||[])).length;for(;n--;)delete s[r[n]]}},hasData:function(t){return!Et.isEmptyObject(this.cache[t[this.expando]]||{})},discard:function(t){t[this.expando]&&delete this.cache[t[this.expando]]}},wt=new l,xt=new l,Et.extend({acceptData:l.accepts,hasData:function(t){return wt.hasData(t)||xt.hasData(t)},data:function(t,e,n){return wt.access(t,e,n)},removeData:function(t,e){wt.remove(t,e)},_data:function(t,e,n){return xt.access(t,e,n)},_removeData:function(t,e){xt.remove(t,e)}}),Et.fn.extend({data:function(r,t){var e,n,i=this[0],o=0,s=null;if(r!==k)return"object"==typeof r?this.each(function(){wt.set(this,r)}):Et.access(this,function(e){var t,n=Et.camelCase(r);if(i&&e===k)return(t=wt.get(i,r))!==k?t:(t=wt.get(i,n))!==k?t:(t=u(i,n,k))!==k?t:void 0;this.each(function(){var t=wt.get(this,n);wt.set(this,n,e),-1!==r.indexOf("-")&&t!==k&&wt.set(this,r,e)})},null,t,1<arguments.length,null,!0);if(this.length&&(s=wt.get(i),1===i.nodeType&&!xt.get(i,"hasDataAttrs"))){for(e=i.attributes;o<e.length;o++)0===(n=e[o].name).indexOf("data-")&&(n=Et.camelCase(n.slice(5)),u(i,n,s[n]));xt.set(i,"hasDataAttrs",!0)}return s},removeData:function(t){return this.each(function(){wt.remove(this,t)})}}),Et.extend({queue:function(t,e,n){var r;if(t)return e=(e||"fx")+"queue",r=xt.get(t,e),n&&(!r||Et.isArray(n)?r=xt.access(t,e,Et.makeArray(n)):r.push(n)),r||[]},dequeue:function(t,e){e=e||"fx";var n=Et.queue(t,e),r=n.length,i=n.shift(),o=Et._queueHooks(t,e),s=function(){Et.dequeue(t,e)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===e&&n.unshift("inprogress"),delete o.stop,i.call(t,s,o)),!r&&o&&o.empty.fire()},_queueHooks:function(t,e){var n=e+"queueHooks";return xt.get(t,n)||xt.access(t,n,{empty:Et.Callbacks("once memory").add(function(){xt.remove(t,[e+"queue",n])})})}}),Et.fn.extend({queue:function(e,n){var t=2;return"string"!=typeof e&&(n=e,e="fx",t--),arguments.length<t?Et.queue(this[0],e):n===k?this:this.each(function(){var t=Et.queue(this,e,n);Et._queueHooks(this,e),"fx"===e&&"inprogress"!==t[0]&&Et.dequeue(this,e)})},dequeue:function(t){return this.each(function(){Et.dequeue(this,t)})},delay:function(r,t){return r=Et.fx&&Et.fx.speeds[r]||r,t=t||"fx",this.queue(t,function(t,e){var n=setTimeout(t,r);e.stop=function(){clearTimeout(n)}})},clearQueue:function(t){return this.queue(t||"fx",[])},promise:function(t,e){var n,r=1,i=Et.Deferred(),o=this,s=this.length,a=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof t&&(e=t,t=k),t=t||"fx";s--;)(n=xt.get(o[s],t+"queueHooks"))&&n.empty&&(r++,n.empty.add(a));return a(),i.promise(e)}});var Tt,_t,Nt=/[\t\r\n\f]/g,St=/\r/g,$t=/^(?:input|select|textarea|button)$/i;Et.fn.extend({attr:function(t,e){return Et.access(this,Et.attr,t,e,1<arguments.length)},removeAttr:function(t){return this.each(function(){Et.removeAttr(this,t)})},prop:function(t,e){return Et.access(this,Et.prop,t,e,1<arguments.length)},removeProp:function(t){return this.each(function(){delete this[Et.propFix[t]||t]})},addClass:function(e){var t,n,r,i,o,s=0,a=this.length,u="string"==typeof e&&e;if(Et.isFunction(e))return this.each(function(t){Et(this).addClass(e.call(this,t,this.className))});if(u)for(t=(e||"").match(st)||[];s<a;s++)if(r=1===(n=this[s]).nodeType&&(n.className?(" "+n.className+" ").replace(Nt," "):" ")){for(o=0;i=t[o++];)r.indexOf(" "+i+" ")<0&&(r+=i+" ");n.className=Et.trim(r)}return this},removeClass:function(e){var t,n,r,i,o,s=0,a=this.length,u=0===arguments.length||"string"==typeof e&&e;if(Et.isFunction(e))return this.each(function(t){Et(this).removeClass(e.call(this,t,this.className))});if(u)for(t=(e||"").match(st)||[];s<a;s++)if(r=1===(n=this[s]).nodeType&&(n.className?(" "+n.className+" ").replace(Nt," "):"")){for(o=0;i=t[o++];)for(;0<=r.indexOf(" "+i+" ");)r=r.replace(" "+i+" "," ");n.className=e?Et.trim(r):""}return this},toggleClass:function(o,s){var a=typeof o,u="boolean"==typeof s;return Et.isFunction(o)?this.each(function(t){Et(this).toggleClass(o.call(this,t,this.className,s),s)}):this.each(function(){if("string"===a)for(var t,e=0,n=Et(this),r=s,i=o.match(st)||[];t=i[e++];)r=u?r:!n.hasClass(t),n[r?"addClass":"removeClass"](t);else a!==B&&"boolean"!==a||(this.className&&xt.set(this,"__className__",this.className),this.className=this.className||!1===o?"":xt.get(this,"__className__")||"")})},hasClass:function(t){for(var e=" "+t+" ",n=0,r=this.length;n<r;n++)if(1===this[n].nodeType&&0<=(" "+this[n].className+" ").replace(Nt," ").indexOf(e))return!0;return!1},val:function(n){var r,t,i,e=this[0];return arguments.length?(i=Et.isFunction(n),this.each(function(t){var e;1===this.nodeType&&(null==(e=i?n.call(this,t,Et(this).val()):n)?e="":"number"==typeof e?e+="":Et.isArray(e)&&(e=Et.map(e,function(t){return null==t?"":t+""})),(r=Et.valHooks[this.type]||Et.valHooks[this.nodeName.toLowerCase()])&&"set"in r&&r.set(this,e,"value")!==k||(this.value=e))})):e?(r=Et.valHooks[e.type]||Et.valHooks[e.nodeName.toLowerCase()])&&"get"in r&&(t=r.get(e,"value"))!==k?t:"string"==typeof(t=e.value)?t.replace(St,""):null==t?"":t:void 0}}),Et.extend({valHooks:{option:{get:function(t){var e=t.attributes.value;return!e||e.specified?t.value:t.text}},select:{get:function(t){for(var e,n,r=t.options,i=t.selectedIndex,o="select-one"===t.type||i<0,s=o?null:[],a=o?i+1:r.length,u=i<0?a:o?i:0;u<a;u++)if(((n=r[u]).selected||u===i)&&(Et.support.optDisabled?!n.disabled:null===n.getAttribute("disabled"))&&(!n.parentNode.disabled||!Et.nodeName(n.parentNode,"optgroup"))){if(e=Et(n).val(),o)return e;s.push(e)}return s},set:function(t,e){for(var n,r,i=t.options,o=Et.makeArray(e),s=i.length;s--;)((r=i[s]).selected=0<=Et.inArray(Et(r).val(),o))&&(n=!0);return n||(t.selectedIndex=-1),o}}},attr:function(t,e,n){var r,i,o=t.nodeType;if(t&&3!==o&&8!==o&&2!==o)return typeof t.getAttribute===B?Et.prop(t,e,n):(1===o&&Et.isXMLDoc(t)||(e=e.toLowerCase(),r=Et.attrHooks[e]||(Et.expr.match.bool.test(e)?_t:Tt)),n===k?r&&"get"in r&&null!==(i=r.get(t,e))?i:null==(i=Et.find.attr(t,e))?k:i:null!==n?r&&"set"in r&&(i=r.set(t,n,e))!==k?i:(t.setAttribute(e,n+""),n):void Et.removeAttr(t,e))},removeAttr:function(t,e){var n,r,i=0,o=e&&e.match(st);if(o&&1===t.nodeType)for(;n=o[i++];)r=Et.propFix[n]||n,Et.expr.match.bool.test(n)&&(t[r]=!1),t.removeAttribute(n)},attrHooks:{type:{set:function(t,e){if(!Et.support.radioValue&&"radio"===e&&Et.nodeName(t,"input")){var n=t.value;return t.setAttribute("type",e),n&&(t.value=n),e}}}},propFix:{"for":"htmlFor","class":"className"},prop:function(t,e,n){var r,i,o=t.nodeType;if(t&&3!==o&&8!==o&&2!==o)return(1!==o||!Et.isXMLDoc(t))&&(e=Et.propFix[e]||e,i=Et.propHooks[e]),n!==k?i&&"set"in i&&(r=i.set(t,n,e))!==k?r:t[e]=n:i&&"get"in i&&null!==(r=i.get(t,e))?r:t[e]},propHooks:{tabIndex:{get:function(t){return t.hasAttribute("tabindex")||$t.test(t.nodeName)||t.href?t.tabIndex:-1}}}}),_t={set:function(t,e,n){return!1===e?Et.removeAttr(t,n):t.setAttribute(n,n),n}},Et.each(Et.expr.match.bool.source.match(/\w+/g),function(t,e){var o=Et.expr.attrHandle[e]||Et.find.attr;Et.expr.attrHandle[e]=function(t,e,n){var r=Et.expr.attrHandle[e],i=n?k:(Et.expr.attrHandle[e]=k)!=o(t,e,n)?e.toLowerCase():null;return Et.expr.attrHandle[e]=r,i}}),Et.support.optSelected||(Et.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null}}),Et.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){Et.propFix[this.toLowerCase()]=this}),Et.each(["radio","checkbox"],function(){Et.valHooks[this]={set:function(t,e){if(Et.isArray(e))return t.checked=0<=Et.inArray(Et(t).val(),e)}},Et.support.checkOn||(Et.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})});var jt=/^key/,Mt=/^(?:mouse|contextmenu)|click/,Dt=/^(?:focusinfocus|focusoutblur)$/,At=/^([^.]*)(?:\.(.+)|)$/;Et.event={global:{},add:function(t,e,n,r,i){var o,s,a,u,l,c,h,f,p,d,m,g=xt.get(t);if(g){for(n.handler&&(n=(o=n).handler,i=o.selector),n.guid||(n.guid=Et.guid++),(u=g.events)||(u=g.events={}),(s=g.handle)||((s=g.handle=function(t){return typeof Et===B||t&&Et.event.triggered===t.type?k:Et.event.dispatch.apply(s.elem,arguments)}).elem=t),l=(e=(e||"").match(st)||[""]).length;l--;)p=m=(a=At.exec(e[l])||[])[1],d=(a[2]||"").split(".").sort(),p&&(h=Et.event.special[p]||{},p=(i?h.delegateType:h.bindType)||p,h=Et.event.special[p]||{},c=Et.extend({type:p,origType:m,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&Et.expr.match.needsContext.test(i),namespace:d.join(".")},o),(f=u[p])||((f=u[p]=[]).delegateCount=0,h.setup&&!1!==h.setup.call(t,r,d,s)||t.addEventListener&&t.addEventListener(p,s,!1)),h.add&&(h.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?f.splice(f.delegateCount++,0,c):f.push(c),Et.event.global[p]=!0);t=null}},remove:function(t,e,n,r,i){var o,s,a,u,l,c,h,f,p,d,m,g=xt.hasData(t)&&xt.get(t);if(g&&(u=g.events)){for(l=(e=(e||"").match(st)||[""]).length;l--;)if(p=m=(a=At.exec(e[l])||[])[1],d=(a[2]||"").split(".").sort(),p){for(h=Et.event.special[p]||{},f=u[p=(r?h.delegateType:h.bindType)||p]||[],a=a[2]&&new RegExp("(^|\\.)"+d.join("\\.(?:.*\\.|)")+"(\\.|$)"),s=o=f.length;o--;)c=f[o],!i&&m!==c.origType||n&&n.guid!==c.guid||a&&!a.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(f.splice(o,1),c.selector&&f.delegateCount--,h.remove&&h.remove.call(t,c));s&&!f.length&&(h.teardown&&!1!==h.teardown.call(t,d,g.handle)||Et.removeEvent(t,p,
|
26
|
+
g.handle),delete u[p])}else for(p in u)Et.event.remove(t,p+e[l],n,r,!0);Et.isEmptyObject(u)&&(delete g.handle,xt.remove(t,"events"))}},trigger:function(t,e,n,r){var i,o,s,a,u,l,c,h=[n||U],f=rt.call(t,"type")?t.type:t,p=rt.call(t,"namespace")?t.namespace.split("."):[];if(o=s=n=n||U,3!==n.nodeType&&8!==n.nodeType&&!Dt.test(f+Et.event.triggered)&&(0<=f.indexOf(".")&&(f=(p=f.split(".")).shift(),p.sort()),u=f.indexOf(":")<0&&"on"+f,(t=t[Et.expando]?t:new Et.Event(f,"object"==typeof t&&t)).isTrigger=r?2:3,t.namespace=p.join("."),t.namespace_re=t.namespace?new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=k,t.target||(t.target=n),e=null==e?[t]:Et.makeArray(e,[t]),c=Et.event.special[f]||{},r||!c.trigger||!1!==c.trigger.apply(n,e))){if(!r&&!c.noBubble&&!Et.isWindow(n)){for(a=c.delegateType||f,Dt.test(a+f)||(o=o.parentNode);o;o=o.parentNode)h.push(o),s=o;s===(n.ownerDocument||U)&&h.push(s.defaultView||s.parentWindow||d)}for(i=0;(o=h[i++])&&!t.isPropagationStopped();)t.type=1<i?a:c.bindType||f,(l=(xt.get(o,"events")||{})[t.type]&&xt.get(o,"handle"))&&l.apply(o,e),(l=u&&o[u])&&Et.acceptData(o)&&l.apply&&!1===l.apply(o,e)&&t.preventDefault();return t.type=f,r||t.isDefaultPrevented()||c._default&&!1!==c._default.apply(h.pop(),e)||!Et.acceptData(n)||u&&Et.isFunction(n[f])&&!Et.isWindow(n)&&((s=n[u])&&(n[u]=null),n[Et.event.triggered=f](),Et.event.triggered=k,s&&(n[u]=s)),t.result}},dispatch:function(t){t=Et.event.fix(t);var e,n,r,i,o,s=[],a=tt.call(arguments),u=(xt.get(this,"events")||{})[t.type]||[],l=Et.event.special[t.type]||{};if((a[0]=t).delegateTarget=this,!l.preDispatch||!1!==l.preDispatch.call(this,t)){for(s=Et.event.handlers.call(this,t,u),e=0;(i=s[e++])&&!t.isPropagationStopped();)for(t.currentTarget=i.elem,n=0;(o=i.handlers[n++])&&!t.isImmediatePropagationStopped();)t.namespace_re&&!t.namespace_re.test(o.namespace)||(t.handleObj=o,t.data=o.data,(r=((Et.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,a))!==k&&!1===(t.result=r)&&(t.preventDefault(),t.stopPropagation()));return l.postDispatch&&l.postDispatch.call(this,t),t.result}},handlers:function(t,e){var n,r,i,o,s=[],a=e.delegateCount,u=t.target;if(a&&u.nodeType&&(!t.button||"click"!==t.type))for(;u!==this;u=u.parentNode||this)if(!0!==u.disabled||"click"!==t.type){for(r=[],n=0;n<a;n++)r[i=(o=e[n]).selector+" "]===k&&(r[i]=o.needsContext?0<=Et(i,this).index(u):Et.find(i,this,null,[u]).length),r[i]&&r.push(o);r.length&&s.push({elem:u,handlers:r})}return a<e.length&&s.push({elem:this,handlers:e.slice(a)}),s},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(t,e){return null==t.which&&(t.which=null!=e.charCode?e.charCode:e.keyCode),t}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(t,e){var n,r,i,o=e.button;return null==t.pageX&&null!=e.clientX&&(r=(n=t.target.ownerDocument||U).documentElement,i=n.body,t.pageX=e.clientX+(r&&r.scrollLeft||i&&i.scrollLeft||0)-(r&&r.clientLeft||i&&i.clientLeft||0),t.pageY=e.clientY+(r&&r.scrollTop||i&&i.scrollTop||0)-(r&&r.clientTop||i&&i.clientTop||0)),t.which||o===k||(t.which=1&o?1:2&o?3:4&o?2:0),t}},fix:function(t){if(t[Et.expando])return t;var e,n,r,i=t.type,o=t,s=this.fixHooks[i];for(s||(this.fixHooks[i]=s=Mt.test(i)?this.mouseHooks:jt.test(i)?this.keyHooks:{}),r=s.props?this.props.concat(s.props):this.props,t=new Et.Event(o),e=r.length;e--;)t[n=r[e]]=o[n];return t.target||(t.target=U),3===t.target.nodeType&&(t.target=t.target.parentNode),s.filter?s.filter(t,o):t},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==e()&&this.focus)return this.focus(),!1},delegateType:"focusin"},blur:{trigger:function(){if(this===e()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if("checkbox"===this.type&&this.click&&Et.nodeName(this,"input"))return this.click(),!1},_default:function(t){return Et.nodeName(t.target,"a")}},beforeunload:{postDispatch:function(t){t.result!==k&&(t.originalEvent.returnValue=t.result)}}},simulate:function(t,e,n,r){var i=Et.extend(new Et.Event,n,{type:t,isSimulated:!0,originalEvent:{}});r?Et.event.trigger(i,null,e):Et.event.dispatch.call(e,i),i.isDefaultPrevented()&&n.preventDefault()}},Et.removeEvent=function(t,e,n){t.removeEventListener&&t.removeEventListener(e,n,!1)},Et.Event=function(t,e){if(!(this instanceof Et.Event))return new Et.Event(t,e);t&&t.type?(this.originalEvent=t,this.type=t.type,this.isDefaultPrevented=t.defaultPrevented||t.getPreventDefault&&t.getPreventDefault()?n:c):this.type=t,e&&Et.extend(this,e),this.timeStamp=t&&t.timeStamp||Et.now(),this[Et.expando]=!0},Et.Event.prototype={isDefaultPrevented:c,isPropagationStopped:c,isImmediatePropagationStopped:c,preventDefault:function(){var t=this.originalEvent;this.isDefaultPrevented=n,t&&t.preventDefault&&t.preventDefault()},stopPropagation:function(){var t=this.originalEvent;this.isPropagationStopped=n,t&&t.stopPropagation&&t.stopPropagation()},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=n,this.stopPropagation()}},Et.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(t,o){Et.event.special[t]={delegateType:o,bindType:o,handle:function(t){var e,n=this,r=t.relatedTarget,i=t.handleObj;return r&&(r===n||Et.contains(n,r))||(t.type=i.origType,e=i.handler.apply(this,arguments),t.type=o),e}}}),Et.support.focusinBubbles||Et.each({focus:"focusin",blur:"focusout"},function(t,e){var n=0,r=function(t){Et.event.simulate(e,t.target,Et.event.fix(t),!0)};Et.event.special[e]={setup:function(){0==n++&&U.addEventListener(t,r,!0)},teardown:function(){0==--n&&U.removeEventListener(t,r,!0)}}}),Et.fn.extend({on:function(t,e,n,r,i){var o,s;if("object"==typeof t){for(s in"string"!=typeof e&&(n=n||e,e=k),t)this.on(s,e,n,t[s],i);return this}if(null==n&&null==r?(r=e,n=e=k):null==r&&("string"==typeof e?(r=n,n=k):(r=n,n=e,e=k)),!1===r)r=c;else if(!r)return this;return 1===i&&(o=r,(r=function(t){return Et().off(t),o.apply(this,arguments)}).guid=o.guid||(o.guid=Et.guid++)),this.each(function(){Et.event.add(this,t,r,n,e)})},one:function(t,e,n,r){return this.on(t,e,n,r,1)},off:function(t,e,n){var r,i;if(t&&t.preventDefault&&t.handleObj)return r=t.handleObj,Et(t.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"!=typeof t)return!1!==e&&"function"!=typeof e||(n=e,e=k),!1===n&&(n=c),this.each(function(){Et.event.remove(this,t,n,e)});for(i in t)this.off(i,e,t[i]);return this},trigger:function(t,e){return this.each(function(){Et.event.trigger(t,e,this)})},triggerHandler:function(t,e){var n=this[0];if(n)return Et.event.trigger(t,e,n,!0)}});var Ot=/^.[^:#\[\.,]*$/,Rt=/^(?:parents|prev(?:Until|All))/,Pt=Et.expr.match.needsContext,Lt={children:!0,contents:!0,next:!0,prev:!0};Et.fn.extend({find:function(t){var e,n=[],r=this,i=r.length;if("string"!=typeof t)return this.pushStack(Et(t).filter(function(){for(e=0;e<i;e++)if(Et.contains(r[e],this))return!0}));for(e=0;e<i;e++)Et.find(t,r[e],n);return(n=this.pushStack(1<i?Et.unique(n):n)).selector=this.selector?this.selector+" "+t:t,n},has:function(t){var e=Et(t,this),n=e.length;return this.filter(function(){for(var t=0;t<n;t++)if(Et.contains(this,e[t]))return!0})},not:function(t){return this.pushStack(i(this,t||[],!0))},filter:function(t){return this.pushStack(i(this,t||[],!1))},is:function(t){return!!i(this,"string"==typeof t&&Pt.test(t)?Et(t):t||[],!1).length},closest:function(t,e){for(var n,r=0,i=this.length,o=[],s=Pt.test(t)||"string"!=typeof t?Et(t,e||this.context):0;r<i;r++)for(n=this[r];n&&n!==e;n=n.parentNode)if(n.nodeType<11&&(s?-1<s.index(n):1===n.nodeType&&Et.find.matchesSelector(n,t))){n=o.push(n);break}return this.pushStack(1<o.length?Et.unique(o):o)},index:function(t){return t?"string"==typeof t?et.call(Et(t),this[0]):et.call(this,t.jquery?t[0]:t):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(t,e){var n="string"==typeof t?Et(t,e):Et.makeArray(t&&t.nodeType?[t]:t),r=Et.merge(this.get(),n);return this.pushStack(Et.unique(r))},addBack:function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}}),Et.each({parent:function(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(t){return Et.dir(t,"parentNode")},parentsUntil:function(t,e,n){return Et.dir(t,"parentNode",n)},next:function(t){return r(t,"nextSibling")},prev:function(t){return r(t,"previousSibling")},nextAll:function(t){return Et.dir(t,"nextSibling")},prevAll:function(t){return Et.dir(t,"previousSibling")},nextUntil:function(t,e,n){return Et.dir(t,"nextSibling",n)},prevUntil:function(t,e,n){return Et.dir(t,"previousSibling",n)},siblings:function(t){return Et.sibling((t.parentNode||{}).firstChild,t)},children:function(t){return Et.sibling(t.firstChild)},contents:function(t){return t.contentDocument||Et.merge([],t.childNodes)}},function(r,i){Et.fn[r]=function(t,e){var n=Et.map(this,i,t);return"Until"!==r.slice(-5)&&(e=t),e&&"string"==typeof e&&(n=Et.filter(e,n)),1<this.length&&(Lt[r]||Et.unique(n),Rt.test(r)&&n.reverse()),this.pushStack(n)}}),Et.extend({filter:function(t,e,n){var r=e[0];return n&&(t=":not("+t+")"),1===e.length&&1===r.nodeType?Et.find.matchesSelector(r,t)?[r]:[]:Et.find.matches(t,Et.grep(e,function(t){return 1===t.nodeType}))},dir:function(t,e,n){for(var r=[],i=n!==k;(t=t[e])&&9!==t.nodeType;)if(1===t.nodeType){if(i&&Et(t).is(n))break;r.push(t)}return r},sibling:function(t,e){for(var n=[];t;t=t.nextSibling)1===t.nodeType&&t!==e&&n.push(t);return n}});var Ht=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,zt=/<([\w:]+)/,qt=/<|&#?\w+;/,Ft=/<(?:script|style|link)/i,It=/^(?:checkbox|radio)$/i,Bt=/checked\s*(?:[^=]|=\s*.checked.)/i,Wt=/^$|\/(?:java|ecma)script/i,Ut=/^true\/(.*)/,Jt=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Vt={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};Vt.optgroup=Vt.option,Vt.tbody=Vt.tfoot=Vt.colgroup=Vt.caption=Vt.thead,Vt.th=Vt.td,Et.fn.extend({text:function(t){return Et.access(this,function(t){return t===k?Et.text(this):this.empty().append((this[0]&&this[0].ownerDocument||U).createTextNode(t))},null,t,arguments.length)},append:function(){return this.domManip(arguments,function(t){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||o(this,t).appendChild(t)})},prepend:function(){return this.domManip(arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=o(this,t);e.insertBefore(t,e.firstChild)}})},before:function(){return this.domManip(arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this)})},after:function(){return this.domManip(arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)})},remove:function(t,e){for(var n,r=t?Et.filter(t,this):this,i=0;null!=(n=r[i]);i++)e||1!==n.nodeType||Et.cleanData(y(n)),n.parentNode&&(e&&Et.contains(n.ownerDocument,n)&&v(y(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(Et.cleanData(y(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null!=t&&t,e=null==e?t:e,this.map(function(){return Et.clone(this,t,e)})},html:function(t){return Et.access(this,function(t){var e=this[0]||{},n=0,r=this.length;if(t===k&&1===e.nodeType)return e.innerHTML;if("string"==typeof t&&!Ft.test(t)&&!Vt[(zt.exec(t)||["",""])[1].toLowerCase()]){t=t.replace(Ht,"<$1></$2>");try{for(;n<r;n++)1===(e=this[n]||{}).nodeType&&(Et.cleanData(y(e,!1)),e.innerHTML=t);e=0}catch(i){}}e&&this.empty().append(t)},null,t,arguments.length)},replaceWith:function(){var r=Et.map(this,function(t){return[t.nextSibling,t.parentNode]}),i=0;return this.domManip(arguments,function(t){var e=r[i++],n=r[i++];n&&(e&&e.parentNode!==n&&(e=this.nextSibling),Et(this).remove(),n.insertBefore(t,e))},!0),i?this:this.remove()},detach:function(t){return this.remove(t,!0)},domManip:function(n,r,i){n=K.apply([],n);var t,e,o,s,a,u,l=0,c=this.length,h=this,f=c-1,p=n[0],d=Et.isFunction(p);if(d||!(c<=1||"string"!=typeof p||Et.support.checkClone)&&Bt.test(p))return this.each(function(t){var e=h.eq(t);d&&(n[0]=p.call(this,t,e.html())),e.domManip(n,r,i)});if(c&&(e=(t=Et.buildFragment(n,this[0].ownerDocument,!1,!i&&this)).firstChild,1===t.childNodes.length&&(t=e),e)){for(s=(o=Et.map(y(t,"script"),m)).length;l<c;l++)a=t,l!==f&&(a=Et.clone(a,!0,!0),s&&Et.merge(o,y(a,"script"))),r.call(this[l],a,l);if(s)for(u=o[o.length-1].ownerDocument,Et.map(o,g),l=0;l<s;l++)a=o[l],Wt.test(a.type||"")&&!xt.access(a,"globalEval")&&Et.contains(u,a)&&(a.src?Et._evalUrl(a.src):Et.globalEval(a.textContent.replace(Jt,"")))}return this}}),Et.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(t,s){Et.fn[t]=function(t){for(var e,n=[],r=Et(t),i=r.length-1,o=0;o<=i;o++)e=o===i?this:this.clone(!0),Et(r[o])[s](e),Z.apply(n,e.get());return this.pushStack(n)}}),Et.extend({clone:function(t,e,n){var r,i,o,s,a=t.cloneNode(!0),u=Et.contains(t.ownerDocument,t);if(!(Et.support.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||Et.isXMLDoc(t)))for(s=y(a),r=0,i=(o=y(t)).length;r<i;r++)f(o[r],s[r]);if(e)if(n)for(o=o||y(t),s=s||y(a),r=0,i=o.length;r<i;r++)h(o[r],s[r]);else h(t,a);return 0<(s=y(a,"script")).length&&v(s,!u&&y(t,"script")),a},buildFragment:function(t,e,n,r){for(var i,o,s,a,u,l,c=0,h=t.length,f=e.createDocumentFragment(),p=[];c<h;c++)if((i=t[c])||0===i)if("object"===Et.type(i))Et.merge(p,i.nodeType?[i]:i);else if(qt.test(i)){for(o=o||f.appendChild(e.createElement("div")),s=(zt.exec(i)||["",""])[1].toLowerCase(),a=Vt[s]||Vt._default,o.innerHTML=a[1]+i.replace(Ht,"<$1></$2>")+a[2],l=a[0];l--;)o=o.firstChild;Et.merge(p,o.childNodes),(o=f.firstChild).textContent=""}else p.push(e.createTextNode(i));for(f.textContent="",c=0;i=p[c++];)if((!r||-1===Et.inArray(i,r))&&(u=Et.contains(i.ownerDocument,i),o=y(f.appendChild(i),"script"),u&&v(o),n))for(l=0;i=o[l++];)Wt.test(i.type||"")&&n.push(i);return f},cleanData:function(t){for(var e,n,r,i,o,s,a=Et.event.special,u=0;(n=t[u])!==k;u++){if(l.accepts(n)&&(o=n[xt.expando])&&(e=xt.cache[o])){if((r=Object.keys(e.events||{})).length)for(s=0;(i=r[s])!==k;s++)a[i]?Et.event.remove(n,i):Et.removeEvent(n,i,e.handle);xt.cache[o]&&delete xt.cache[o]}delete wt.cache[n[wt.expando]]}},_evalUrl:function(t){return Et.ajax({url:t,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})}}),Et.fn.extend({wrapAll:function(e){var t;return Et.isFunction(e)?this.each(function(t){Et(this).wrapAll(e.call(this,t))}):(this[0]&&(t=Et(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t}).append(this)),this)},wrapInner:function(n){return Et.isFunction(n)?this.each(function(t){Et(this).wrapInner(n.call(this,t))}):this.each(function(){var t=Et(this),e=t.contents();e.length?e.wrapAll(n):t.append(n)})},wrap:function(e){var n=Et.isFunction(e);return this.each(function(t){Et(this).wrapAll(n?e.call(this,t):e)})},unwrap:function(){return this.parent().each(function(){Et.nodeName(this,"body")||Et(this).replaceWith(this.childNodes)}).end()}});var Xt,Gt,Yt=/^(none|table(?!-c[ea]).+)/,Qt=/^margin/,Kt=new RegExp("^("+ot+")(.*)$","i"),Zt=new RegExp("^("+ot+")(?!px)[a-z%]+$","i"),te=new RegExp("^([+-])=("+ot+")","i"),ee={BODY:"block"},ne={position:"absolute",visibility:"hidden",display:"block"},re={letterSpacing:0,fontWeight:400},ie=["Top","Right","Bottom","Left"],oe=["Webkit","O","Moz","ms"];Et.fn.extend({css:function(t,e){return Et.access(this,function(t,e,n){var r,i,o={},s=0;if(Et.isArray(e)){for(r=w(t),i=e.length;s<i;s++)o[e[s]]=Et.css(t,e[s],!1,r);return o}return n!==k?Et.style(t,e,n):Et.css(t,e)},t,e,1<arguments.length)},show:function(){return s(this,!0)},hide:function(){return s(this)},toggle:function(t){var e="boolean"==typeof t;return this.each(function(){(e?t:b(this))?Et(this).show():Et(this).hide()})}}),Et.extend({cssHooks:{opacity:{get:function(t,e){if(e){var n=Xt(t,"opacity");return""===n?"1":n}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(t,e,n,r){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var i,o,s,a=Et.camelCase(e),u=t.style;if(e=Et.cssProps[a]||(Et.cssProps[a]=p(u,a)),s=Et.cssHooks[e]||Et.cssHooks[a],n===k)return s&&"get"in s&&(i=s.get(t,!1,r))!==k?i:u[e];"string"===(o=typeof n)&&(i=te.exec(n))&&(n=(i[1]+1)*i[2]+parseFloat(Et.css(t,e)),o="number"),null==n||"number"===o&&isNaN(n)||("number"!==o||Et.cssNumber[a]||(n+="px"),Et.support.clearCloneStyle||""!==n||0!==e.indexOf("background")||(u[e]="inherit"),s&&"set"in s&&(n=s.set(t,n,r))===k||(u[e]=n))}},css:function(t,e,n,r){var i,o,s,a=Et.camelCase(e);return e=Et.cssProps[a]||(Et.cssProps[a]=p(t.style,a)),(s=Et.cssHooks[e]||Et.cssHooks[a])&&"get"in s&&(i=s.get(t,!0,n)),i===k&&(i=Xt(t,e,r)),"normal"===i&&e in re&&(i=re[e]),""===n||n?(o=parseFloat(i),!0===n||Et.isNumeric(o)?o||0:i):i}}),Xt=function(t,e,n){var r,i,o,s=n||w(t),a=s?s.getPropertyValue(e)||s[e]:k,u=t.style;return s&&(""!==a||Et.contains(t.ownerDocument,t)||(a=Et.style(t,e)),Zt.test(a)&&Qt.test(e)&&(r=u.width,i=u.minWidth,o=u.maxWidth,u.minWidth=u.maxWidth=u.width=a,a=s.width,u.width=r,u.minWidth=i,u.maxWidth=o)),a},Et.each(["height","width"],function(t,i){Et.cssHooks[i]={get:function(t,e,n){if(e)return 0===t.offsetWidth&&Yt.test(Et.css(t,"display"))?Et.swap(t,ne,function(){return T(t,i,n)}):T(t,i,n)},set:function(t,e,n){var r=n&&w(t);return x(t,e,n?C(t,i,n,Et.support.boxSizing&&"border-box"===Et.css(t,"boxSizing",!1,r),r):0)}}}),Et(function(){Et.support.reliableMarginRight||(Et.cssHooks.marginRight={get:function(t,e){if(e)return Et.swap(t,{display:"inline-block"},Xt,[t,"marginRight"])}}),!Et.support.pixelPosition&&Et.fn.position&&Et.each(["top","left"],function(t,n){Et.cssHooks[n]={get:function(t,e){if(e)return e=Xt(t,n),Zt.test(e)?Et(t).position()[n]+"px":e}}})}),Et.expr&&Et.expr.filters&&(Et.expr.filters.hidden=function(t){return t.offsetWidth<=0&&t.offsetHeight<=0},Et.expr.filters.visible=function(t){return!Et.expr.filters.hidden(t)}),Et.each({margin:"",padding:"",border:"Width"},function(i,o){Et.cssHooks[i+o]={expand:function(t){for(var e=0,n={},r="string"==typeof t?t.split(" "):[t];e<4;e++)n[i+ie[e]+o]=r[e]||r[e-2]||r[0];return n}},Qt.test(i)||(Et.cssHooks[i+o].set=x)});var se=/%20/g,ae=/\[\]$/,ue=/\r?\n/g,le=/^(?:submit|button|image|reset|file)$/i,ce=/^(?:input|select|textarea|keygen)/i;Et.fn.extend({serialize:function(){return Et.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var t=Et.prop(this,"elements");return t?Et.makeArray(t):this}).filter(function(){var t=this.type;return this.name&&!Et(this).is(":disabled")&&ce.test(this.nodeName)&&!le.test(t)&&(this.checked||!It.test(t))}).map(function(t,e){var n=Et(this).val();return null==n?null:Et.isArray(n)?Et.map(n,function(t){return{name:e.name,value:t.replace(ue,"\r\n")}}):{name:e.name,value:n.replace(ue,"\r\n")}}).get()}}),Et.param=function(t,e){var n,r=[],i=function(t,e){e=Et.isFunction(e)?e():null==e?"":e,r[r.length]=encodeURIComponent(t)+"="+encodeURIComponent(e)};if(e===k&&(e=Et.ajaxSettings&&Et.ajaxSettings.traditional),Et.isArray(t)||t.jquery&&!Et.isPlainObject(t))Et.each(t,function(){i(this.name,this.value)});else for(n in t)S(n,t[n],e,i);return r.join("&").replace(se,"+")},Et.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(t,n){Et.fn[n]=function(t,e){return 0<arguments.length?this.on(n,null,t,e):this.trigger(n)}}),Et.fn.extend({hover:function(t,e){return this.mouseenter(t).mouseleave(e||t)},bind:function(t,e,n){return this.on(t,null,e,n)},unbind:function(t,e){return this.off(t,null,e)},delegate:function(t,e,n,r){return this.on(e,t,n,r)},undelegate:function(t,e,n){return 1===arguments.length?this.off(t,"**"):this.off(e,t||"**",n)}});var he,fe,pe=Et.now(),de=/\?/,me=/#.*$/,ge=/([?&])_=[^&]*/,ve=/^(.*?):[ \t]*([^\r\n]*)$/gm,ye=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,be=/^(?:GET|HEAD)$/,we=/^\/\//,xe=/^([\w.+-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,Ce=Et.fn.load,ke={},Te={},_e="*/".concat("*");try{fe=W.href}catch(ze){(fe=U.createElement("a")).href="",fe=fe.href}he=xe.exec(fe.toLowerCase())||[],Et.fn.load=function(t,e,n){if("string"!=typeof t&&Ce)return Ce.apply(this,arguments);var r,i,o,s=this,a=t.indexOf(" ");return 0<=a&&(r=t.slice(a),t=t.slice(0,a)),Et.isFunction(e)?(n=e,e=k):e&&"object"==typeof e&&(i="POST"),0<s.length&&Et.ajax({url:t,type:i,dataType:"html",data:e}).done(function(t){o=arguments,s.html(r?Et("<div>").append(Et.parseHTML(t)).find(r):t)}).complete(n&&function(t,e){s.each(n,o||[t.responseText,e,t])}),this},Et.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(t,e){Et.fn[e]=function(t){return this.on(e,t)}}),Et.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:fe,type:"GET",isLocal:ye.test(he[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":_e,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":Et.parseJSON,"text xml":Et.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?j(j(t,Et.ajaxSettings),e):j(Et.ajaxSettings,t)},ajaxPrefilter:$(ke),ajaxTransport:$(Te),ajax:function(t,e){function n(t,e,n,r){var i,o,s,a,u,l=e;2!==x&&(x=2,p&&clearTimeout(p),c=k,f=r||"",C.readyState=0<t?4:0,i=200<=t&&t<300||304===t,n&&(a=M(m,C,n)),a=D(m,a,C,i),i?(m.ifModified&&((u=C.getResponseHeader("Last-Modified"))&&(Et.lastModified[h]=u),(u=C.getResponseHeader("etag"))&&(Et.etag[h]=u)),204===t||"HEAD"===m.type?l="nocontent":304===t?l="notmodified":(l=a.state,o=a.data,i=!(s=a.error))):(s=l,!t&&l||(l="error",t<0&&(t=0))),C.status=t,C.statusText=(e||l)+"",i?y.resolveWith(g,[o,l,C]):y.rejectWith(g,[C,l,s]),C.statusCode(w),w=k,d&&v.trigger(i?"ajaxSuccess":"ajaxError",[C,m,i?o:s]),b.fireWith(g,[C,l]),d&&(v.trigger("ajaxComplete",[C,m]),--Et.active||Et.event.trigger("ajaxStop")))}"object"==typeof t&&(e=t,t=k),e=e||{};var c,h,f,r,p,i,d,o,m=Et.ajaxSetup({},e),g=m.context||m,v=m.context&&(g.nodeType||g.jquery)?Et(g):Et.event,y=Et.Deferred(),b=Et.Callbacks("once memory"),w=m.statusCode||{},s={},a={},x=0,u="canceled",C={readyState:0,getResponseHeader:function(t){var e;if(2===x){if(!r)for(r={};e=ve.exec(f);)r[e[1].toLowerCase()]=e[2];e=r[t.toLowerCase()]}return null==e?null:e},getAllResponseHeaders:function(){return 2===x?f:null},setRequestHeader:function(t,e){var n=t.toLowerCase();return x||(t=a[n]=a[n]||t,s[t]=e),this},overrideMimeType:function(t){return x||(m.mimeType=t),this},statusCode:function(t){var e;if(t)if(x<2)for(e in t)w[e]=[w[e],t[e]];else C.always(t[C.status]);return this},abort:function(t){var e=t||u;return c&&c.abort(e),n(0,e),this}};if(y.promise(C).complete=b.add,C.success=C.done,C.error=C.fail,m.url=((t||m.url||fe)+"").replace(me,"").replace(we,he[1]+"//"),m.type=e.method||e.type||m.method||m.type,m.dataTypes=Et.trim(m.dataType||"*").toLowerCase().match(st)||[""],null==m.crossDomain&&(i=xe.exec(m.url.toLowerCase()),m.crossDomain=!(!i||i[1]===he[1]&&i[2]===he[2]&&(i[3]||("http:"===i[1]?"80":"443"))===(he[3]||("http:"===he[1]?"80":"443")))),m.data&&m.processData&&"string"!=typeof m.data&&(m.data=Et.param(m.data,m.traditional)),E(ke,m,e,C),2===x)return C;for(o in(d=m.global)&&0==Et.active++&&Et.event.trigger("ajaxStart"),m.type=m.type.toUpperCase(),m.hasContent=!be.test(m.type),h=m.url,m.hasContent||(m.data&&(h=m.url+=(de.test(h)?"&":"?")+m.data,delete m.data),!1===m.cache&&(m.url=ge.test(h)?h.replace(ge,"$1_="+pe++):h+(de.test(h)?"&":"?")+"_="+pe++)),m.ifModified&&(Et.lastModified[h]&&C.setRequestHeader("If-Modified-Since",Et.lastModified[h]),Et.etag[h]&&C.setRequestHeader("If-None-Match",Et.etag[h])),(m.data&&m.hasContent&&!1!==m.contentType||e.contentType)&&C.setRequestHeader("Content-Type",m.contentType),C.setRequestHeader("Accept",m.dataTypes[0]&&m.accepts[m.dataTypes[0]]?m.accepts[m.dataTypes[0]]+("*"!==m.dataTypes[0]?", "+_e+"; q=0.01":""):m.accepts["*"]),m.headers)C.setRequestHeader(o,m.headers[o]);if(m.beforeSend&&(!1===m.beforeSend.call(g,C,m)||2===x))return C.abort();for(o in u="abort",{success:1,error:1,complete:1})C[o](m[o]);if(c=E(Te,m,e,C)){C.readyState=1,d&&v.trigger("ajaxSend",[C,m]),m.async&&0<m.timeout&&(p=setTimeout(function(){C.abort("timeout")},m.timeout));try{x=1,c.send(s,n)}catch(ze){if(!(x<2))throw ze;n(-1,ze)}}else n(-1,"No Transport");return C},getJSON:function(t,e,n){return Et.get(t,e,n,"json")},getScript:function(t,e){return Et.get(t,k,e,"script")}}),Et.each(["get","post"],function(t,i){Et[i]=function(t,e,n,r){return Et.isFunction(e)&&(r=r||n,n=e,e=k),Et.ajax({url:t,type:i,dataType:r,data:e,success:n})}}),Et.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(t){return Et.globalEval(t),t}}}),Et.ajaxPrefilter("script",function(t){t.cache===k&&(t.cache=!1),t.crossDomain&&(t.type="GET")}),Et.ajaxTransport("script",function(n){var r,i;if(n.crossDomain)return{send:function(t,e){r=Et("<script>").prop({async:!0,charset:n.scriptCharset,src:n.url}).on("load error",i=function(t){r.remove(),i=null,t&&e("error"===t.type?404:200,t.type)}),U.head.appendChild(r[0])},abort:function(){i&&i()}}});var Ne=[],Se=/(=)\?(?=&|$)|\?\?/;Et.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var t=Ne.pop()||Et.expando+"_"+pe++;return this[t]=!0,t}}),Et.ajaxPrefilter("json jsonp",function(t,e,n){var r,i,o,s=!1!==t.jsonp&&(Se.test(t.url)?"url":"string"==typeof t.data&&!(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&Se.test(t.data)&&"data");if(s||"jsonp"===t.dataTypes[0])return r=t.jsonpCallback=Et.isFunction(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(Se,"$1"+r):!1!==t.jsonp&&(t.url+=(de.test(t.url)?"&":"?")+t.jsonp+"="+r),t.converters["script json"]=function(){return o||Et.error(r+" was not called"),o[0]},t.dataTypes[0]="json",i=d[r],d[r]=function(){o=arguments},n.always(function(){d[r]=i,t[r]&&(t.jsonpCallback=e.jsonpCallback,Ne.push(r)),o&&Et.isFunction(i)&&i(o[0]),o=i=k}),"script"}),Et.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(ze){}};var $e=Et.ajaxSettings.xhr(),Ee={0:200,1223:204},je=0,Me={};d.ActiveXObject&&Et(d).on("unload",function(){for(var t in Me)Me[t]();Me=k}),Et.support.cors=!!$e&&"withCredentials"in $e,Et.support.ajax=$e=!!$e,Et.ajaxTransport(function(o){var s;if(Et.support.cors||$e&&!o.crossDomain)return{send:function(t,e){var n,r,i=o.xhr();if(i.open(o.type,o.url,o.async,o.username,o.password),o.xhrFields)for(n in o.xhrFields)i[n]=o.xhrFields[n];for(n in o.mimeType&&i.overrideMimeType&&i.overrideMimeType(o.mimeType),o.crossDomain||t["X-Requested-With"]||(t["X-Requested-With"]="XMLHttpRequest"),t)i.setRequestHeader(n,t[n]);s=function(t){return function(){s&&(delete Me[r],s=i.onload=i.onerror=null,"abort"===t?i.abort():"error"===t?e(i.status||404,i.statusText):e(Ee[i.status]||i.status,i.statusText,"string"==typeof i.responseText?{text:i.responseText}:k,i.getAllResponseHeaders()))}},i.onload=s(),i.onerror=s("error"),s=Me[r=je++]=s("abort"),i.send(o.hasContent&&o.data||null)},abort:function(){s&&s()}}});var De,Ae,Oe=/^(?:toggle|show|hide)$/,Re=new RegExp("^(?:([+-])=|)("+ot+")([a-z%]*)$","i"),Pe=/queueHooks$/,Le=[L],He={"*":[function(t,e){var n=this.createTween(t,e),r=n.cur(),i=Re.exec(e),o=i&&i[3]||(Et.cssNumber[t]?"":"px"),s=(Et.cssNumber[t]||"px"!==o&&+r)&&Re.exec(Et.css(n.elem,t)),a=1,u=20;if(s&&s[3]!==o)for(o=o||s[3],i=i||[],s=+r||1;s/=a=a||".5",Et.style(n.elem,t,s+o),a!==(a=n.cur()/r)&&1!==a&&--u;);return i&&(s=n.start=+s||+r||0,n.unit=o,n.end=i[1]?s+(i[1]+1)*i[2]:+i[2]),n}]};Et.Animation=Et.extend(R,{tweener:function(t,e){for(var n,r=0,i=(t=Et.isFunction(t)?(e=t,["*"]):t.split(" ")).length;r<i;r++)n=t[r],He[n]=He[n]||[],He[n].unshift(e)},prefilter:function(t,e){e?Le.unshift(t):Le.push(t)}}),(Et.Tween=H).prototype={constructor:H,init:function(t,e,n,r,i,o){this.elem=t,this.prop=n,this.easing=i||"swing",this.options=e,this.start=this.now=this.cur(),this.end=r,this.unit=o||(Et.cssNumber[n]?"":"px")},cur:function(){var t=H.propHooks[this.prop];return t&&t.get?t.get(this):H.propHooks._default.get(this)},run:function(t){var e,n=H.propHooks[this.prop];return this.options.duration?this.pos=e=Et.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):H.propHooks._default.set(this),this}},H.prototype.init.prototype=H.prototype,H.propHooks={_default:{get:function(t){var e;return null==t.elem[t.prop]||t.elem.style&&null!=t.elem.style[t.prop]?(e=Et.css(t.elem,t.prop,""))&&"auto"!==e?e:0:t.elem[t.prop]},set:function(t){Et.fx.step[t.prop]?Et.fx.step[t.prop](t):t.elem.style&&(null!=t.elem.style[Et.cssProps[t.prop]]||Et.cssHooks[t.prop])?Et.style(t.elem,t.prop,t.now+t.unit):t.elem[t.prop]=t.now}}},H.propHooks.scrollTop=H.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},Et.each(["toggle","show","hide"],function(t,r){var i=Et.fn[r];Et.fn[r]=function(t,e,n){return null==t||"boolean"==typeof t?i.apply(this,arguments):this.animate(z(r,!0),t,e,n)}}),Et.fn.extend({fadeTo:function(t,e,n,r){return this.filter(b).css("opacity",0).show().end().animate({opacity:e},t,n,r)},animate:function(e,t,n,r){var i=Et.isEmptyObject(e),o=Et.speed(t,n,r),s=function(){var t=R(this,Et.extend({},e),o);(i||xt.get(this,"finish"))&&t.stop(!0)};return s.finish=s,i||!1===o.queue?this.each(s):this.queue(o.queue,s)},stop:function(i,t,o){var s=function(t){var e=t.stop;delete t.stop,e(o)};return"string"!=typeof i&&(o=t,t=i,i=k),t&&!1!==i&&this.queue(i||"fx",[]),this.each(function(){var t=!0,e=null!=i&&i+"queueHooks",n=Et.timers,r=xt.get(this);if(e)r[e]&&r[e].stop&&s(r[e]);else for(e in r)r[e]&&r[e].stop&&Pe.test(e)&&s(r[e]);for(e=n.length;e--;)n[e].elem!==this||null!=i&&n[e].queue!==i||(n[e].anim.stop(o),t=!1,n.splice(e,1));!t&&o||Et.dequeue(this,i)})},finish:function(s){return!1!==s&&(s=s||"fx"),this.each(function(){var t,e=xt.get(this),n=e[s+"queue"],r=e[s+"queueHooks"],i=Et.timers,o=n?n.length:0;for(e.finish=!0,Et.queue(this,s,[]),r&&r.stop&&r.stop.call(this,!0),t=i.length;t--;)i[t].elem===this&&i[t].queue===s&&(i[t].anim.stop(!0),i.splice(t,1));for(t=0;t<o;t++)n[t]&&n[t].finish&&n[t].finish.call(this);delete e.finish})}}),Et.each({slideDown:z("show"),slideUp:z("hide"),slideToggle:z("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(t,r){Et.fn[t]=function(t,e,n){return this.animate(r,t,e,n)}}),Et.speed=function(t,e,n){var r=t&&"object"==typeof t?Et.extend({},t):{complete:n||!n&&e||Et.isFunction(t)&&t,duration:t,easing:n&&e||e&&!Et.isFunction(e)&&e};return r.duration=Et.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in Et.fx.speeds?Et.fx.speeds[r.duration]:Et.fx.speeds._default,null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){Et.isFunction(r.old)&&r.old.call(this),r.queue&&Et.dequeue(this,r.queue)},r},Et.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2}},Et.timers=[],Et.fx=H.prototype.init,Et.fx.tick=function(){var t,e=Et.timers,n=0;for(De=Et.now();n<e.length;n++)(t=e[n])()||e[n]!==t||e.splice(n--,1);e.length||Et.fx.stop(),De=k},Et.fx.timer=function(t){t()&&Et.timers.push(t)&&Et.fx.start()},Et.fx.interval=13,Et.fx.start=function(){Ae||(Ae=setInterval(Et.fx.tick,Et.fx.interval))},Et.fx.stop=function(){clearInterval(Ae),Ae=null},Et.fx.speeds={slow:600,fast:200,_default:400},Et.fx.step={},Et.expr&&Et.expr.filters&&(Et.expr.filters.animated=function(e){return Et.grep(Et.timers,function(t){return e===t.elem}).length}),Et.fn.offset=function(e){if(arguments.length)return e===k?this:this.each(function(t){Et.offset.setOffset(this,e,t)});var t,n,r=this[0],i={top:0,left:0},
|
27
|
+
o=r&&r.ownerDocument;return o?(t=o.documentElement,Et.contains(t,r)?(typeof r.getBoundingClientRect!==B&&(i=r.getBoundingClientRect()),n=q(o),{top:i.top+n.pageYOffset-t.clientTop,left:i.left+n.pageXOffset-t.clientLeft}):i):void 0},Et.offset={setOffset:function(t,e,n){var r,i,o,s,a,u,l=Et.css(t,"position"),c=Et(t),h={};"static"===l&&(t.style.position="relative"),a=c.offset(),o=Et.css(t,"top"),u=Et.css(t,"left"),i=("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(s=(r=c.position()).top,r.left):(s=parseFloat(o)||0,parseFloat(u)||0),Et.isFunction(e)&&(e=e.call(t,n,a)),null!=e.top&&(h.top=e.top-a.top+s),null!=e.left&&(h.left=e.left-a.left+i),"using"in e?e.using.call(t,h):c.css(h)}},Et.fn.extend({position:function(){if(this[0]){var t,e,n=this[0],r={top:0,left:0};return"fixed"===Et.css(n,"position")?e=n.getBoundingClientRect():(t=this.offsetParent(),e=this.offset(),Et.nodeName(t[0],"html")||(r=t.offset()),r.top+=Et.css(t[0],"borderTopWidth",!0),r.left+=Et.css(t[0],"borderLeftWidth",!0)),{top:e.top-r.top-Et.css(n,"marginTop",!0),left:e.left-r.left-Et.css(n,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var t=this.offsetParent||J;t&&!Et.nodeName(t,"html")&&"static"===Et.css(t,"position");)t=t.offsetParent;return t||J})}}),Et.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,i){var o="pageYOffset"===i;Et.fn[e]=function(t){return Et.access(this,function(t,e,n){var r=q(t);if(n===k)return r?r[i]:t[e];r?r.scrollTo(o?d.pageXOffset:n,o?n:d.pageYOffset):t[e]=n},e,t,arguments.length,null)}}),Et.each({Height:"height",Width:"width"},function(o,s){Et.each({padding:"inner"+o,content:s,"":"outer"+o},function(r,t){Et.fn[t]=function(t,e){var n=arguments.length&&(r||"boolean"!=typeof t),i=r||(!0===t||!0===e?"margin":"border");return Et.access(this,function(t,e,n){var r;return Et.isWindow(t)?t.document.documentElement["client"+o]:9===t.nodeType?(r=t.documentElement,Math.max(t.body["scroll"+o],r["scroll"+o],t.body["offset"+o],r["offset"+o],r["client"+o])):n===k?Et.css(t,e,i):Et.style(t,e,n,i)},s,n?t:k,n,null)}})}),Et.fn.size=function(){return this.length},Et.fn.andSelf=Et.fn.addBack,"object"==typeof module&&module&&"object"==typeof module.exports?module.exports=Et:"function"==typeof define&&define.amd&&define("jquery",[],function(){return Et}),"object"==typeof d&&"object"==typeof d.document&&(d.jQuery=d.$=Et)}(window),function(){var t=this,e=t._,s={},i=Array.prototype,n=Object.prototype,r=Function.prototype,o=i.push,a=i.slice,u=i.concat,h=n.toString,l=n.hasOwnProperty,c=i.forEach,f=i.map,p=i.reduce,d=i.reduceRight,m=i.filter,g=i.every,v=i.some,y=i.indexOf,b=i.lastIndexOf,w=Array.isArray,x=Object.keys,C=r.bind,k=function(t){return t instanceof k?t:this instanceof k?void(this._wrapped=t):new k(t)};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=k),exports._=k):t._=k,k.VERSION="1.4.4";var T=k.each=k.forEach=function(t,e,n){if(null!=t)if(c&&t.forEach===c)t.forEach(e,n);else if(t.length===+t.length){for(var r=0,i=t.length;r<i;r++)if(e.call(n,t[r],r,t)===s)return}else for(var o in t)if(k.has(t,o)&&e.call(n,t[o],o,t)===s)return};k.map=k.collect=function(t,r,i){var o=[];return null==t?o:f&&t.map===f?t.map(r,i):(T(t,function(t,e,n){o[o.length]=r.call(i,t,e,n)}),o)};var _="Reduce of empty array with no initial value";k.reduce=k.foldl=k.inject=function(t,r,i,o){var s=2<arguments.length;if(null==t&&(t=[]),p&&t.reduce===p)return o&&(r=k.bind(r,o)),s?t.reduce(r,i):t.reduce(r);if(T(t,function(t,e,n){s?i=r.call(o,i,t,e,n):(i=t,s=!0)}),!s)throw new TypeError(_);return i},k.reduceRight=k.foldr=function(r,i,o,s){var a=2<arguments.length;if(null==r&&(r=[]),d&&r.reduceRight===d)return s&&(i=k.bind(i,s)),a?r.reduceRight(i,o):r.reduceRight(i);var u=r.length;if(u!==+u){var l=k.keys(r);u=l.length}if(T(r,function(t,e,n){e=l?l[--u]:--u,a?o=i.call(s,o,r[e],e,n):(o=r[e],a=!0)}),!a)throw new TypeError(_);return o},k.find=k.detect=function(t,r,i){var o;return N(t,function(t,e,n){if(r.call(i,t,e,n))return o=t,!0}),o},k.filter=k.select=function(t,r,i){var o=[];return null==t?o:m&&t.filter===m?t.filter(r,i):(T(t,function(t,e,n){r.call(i,t,e,n)&&(o[o.length]=t)}),o)},k.reject=function(t,r,i){return k.filter(t,function(t,e,n){return!r.call(i,t,e,n)},i)},k.every=k.all=function(t,r,i){r||(r=k.identity);var o=!0;return null==t?o:g&&t.every===g?t.every(r,i):(T(t,function(t,e,n){if(!(o=o&&r.call(i,t,e,n)))return s}),!!o)};var N=k.some=k.any=function(t,r,i){r||(r=k.identity);var o=!1;return null==t?o:v&&t.some===v?t.some(r,i):(T(t,function(t,e,n){if(o||(o=r.call(i,t,e,n)))return s}),!!o)};k.contains=k.include=function(t,e){return null!=t&&(y&&t.indexOf===y?-1!=t.indexOf(e):N(t,function(t){return t===e}))},k.invoke=function(t,e){var n=a.call(arguments,2),r=k.isFunction(e);return k.map(t,function(t){return(r?e:t[e]).apply(t,n)})},k.pluck=function(t,e){return k.map(t,function(t){return t[e]})},k.where=function(t,n,e){return k.isEmpty(n)?e?null:[]:k[e?"find":"filter"](t,function(t){for(var e in n)if(n[e]!==t[e])return!1;return!0})},k.findWhere=function(t,e){return k.where(t,e,!0)},k.max=function(t,i,o){if(!i&&k.isArray(t)&&t[0]===+t[0]&&t.length<65535)return Math.max.apply(Math,t);if(!i&&k.isEmpty(t))return-Infinity;var s={computed:-Infinity,value:-Infinity};return T(t,function(t,e,n){var r=i?i.call(o,t,e,n):t;r>=s.computed&&(s={value:t,computed:r})}),s.value},k.min=function(t,i,o){if(!i&&k.isArray(t)&&t[0]===+t[0]&&t.length<65535)return Math.min.apply(Math,t);if(!i&&k.isEmpty(t))return Infinity;var s={computed:Infinity,value:Infinity};return T(t,function(t,e,n){var r=i?i.call(o,t,e,n):t;r<s.computed&&(s={value:t,computed:r})}),s.value},k.shuffle=function(t){var e,n=0,r=[];return T(t,function(t){e=k.random(n++),r[n-1]=r[e],r[e]=t}),r};var S=function(e){return k.isFunction(e)?e:function(t){return t[e]}};k.sortBy=function(t,e,r){var i=S(e);return k.pluck(k.map(t,function(t,e,n){return{value:t,index:e,criteria:i.call(r,t,e,n)}}).sort(function(t,e){var n=t.criteria,r=e.criteria;if(n!==r){if(r<n||void 0===n)return 1;if(n<r||void 0===r)return-1}return t.index<e.index?-1:1}),"value")};var $=function(r,t,i,o){var s={},a=S(t||k.identity);return T(r,function(t,e){var n=a.call(i,t,e,r);o(s,n,t)}),s};k.groupBy=function(t,e,n){return $(t,e,n,function(t,e,n){(k.has(t,e)?t[e]:t[e]=[]).push(n)})},k.countBy=function(t,e,n){return $(t,e,n,function(t,e){k.has(t,e)||(t[e]=0),t[e]++})},k.sortedIndex=function(t,e,n,r){for(var i=(n=null==n?k.identity:S(n)).call(r,e),o=0,s=t.length;o<s;){var a=o+s>>>1;n.call(r,t[a])<i?o=a+1:s=a}return o},k.toArray=function(t){return t?k.isArray(t)?a.call(t):t.length===+t.length?k.map(t,k.identity):k.values(t):[]},k.size=function(t){return null==t?0:t.length===+t.length?t.length:k.keys(t).length},k.first=k.head=k.take=function(t,e,n){if(null!=t)return null==e||n?t[0]:a.call(t,0,e)},k.initial=function(t,e,n){return a.call(t,0,t.length-(null==e||n?1:e))},k.last=function(t,e,n){if(null!=t)return null==e||n?t[t.length-1]:a.call(t,Math.max(t.length-e,0))},k.rest=k.tail=k.drop=function(t,e,n){return a.call(t,null==e||n?1:e)},k.compact=function(t){return k.filter(t,k.identity)};var E=function(t,e,n){return T(t,function(t){k.isArray(t)?e?o.apply(n,t):E(t,e,n):n.push(t)}),n};k.flatten=function(t,e){return E(t,e,[])},k.without=function(t){return k.difference(t,a.call(arguments,1))},k.uniq=k.unique=function(n,r,t,e){k.isFunction(r)&&(e=t,t=r,r=!1);var i=t?k.map(n,t,e):n,o=[],s=[];return T(i,function(t,e){(r?e&&s[s.length-1]===t:k.contains(s,t))||(s.push(t),o.push(n[e]))}),o},k.union=function(){return k.uniq(u.apply(i,arguments))},k.intersection=function(t){var n=a.call(arguments,1);return k.filter(k.uniq(t),function(e){return k.every(n,function(t){return 0<=k.indexOf(t,e)})})},k.difference=function(t){var e=u.apply(i,a.call(arguments,1));return k.filter(t,function(t){return!k.contains(e,t)})},k.zip=function(){for(var t=a.call(arguments),e=k.max(k.pluck(t,"length")),n=new Array(e),r=0;r<e;r++)n[r]=k.pluck(t,""+r);return n},k.object=function(t,e){if(null==t)return{};for(var n={},r=0,i=t.length;r<i;r++)e?n[t[r]]=e[r]:n[t[r][0]]=t[r][1];return n},k.indexOf=function(t,e,n){if(null==t)return-1;var r=0,i=t.length;if(n){if("number"!=typeof n)return t[r=k.sortedIndex(t,e)]===e?r:-1;r=n<0?Math.max(0,i+n):n}if(y&&t.indexOf===y)return t.indexOf(e,n);for(;r<i;r++)if(t[r]===e)return r;return-1},k.lastIndexOf=function(t,e,n){if(null==t)return-1;var r=null!=n;if(b&&t.lastIndexOf===b)return r?t.lastIndexOf(e,n):t.lastIndexOf(e);for(var i=r?n:t.length;i--;)if(t[i]===e)return i;return-1},k.range=function(t,e,n){arguments.length<=1&&(e=t||0,t=0),n=n||1;for(var r=Math.max(Math.ceil((e-t)/n),0),i=0,o=new Array(r);i<r;)o[i++]=t,t+=n;return o},k.bind=function(t,e){if(t.bind===C&&C)return C.apply(t,a.call(arguments,1));var n=a.call(arguments,2);return function(){return t.apply(e,n.concat(a.call(arguments)))}},k.partial=function(t){var e=a.call(arguments,1);return function(){return t.apply(this,e.concat(a.call(arguments)))}},k.bindAll=function(e){var t=a.call(arguments,1);return 0===t.length&&(t=k.functions(e)),T(t,function(t){e[t]=k.bind(e[t],e)}),e},k.memoize=function(e,n){var r={};return n||(n=k.identity),function(){var t=n.apply(this,arguments);return k.has(r,t)?r[t]:r[t]=e.apply(this,arguments)}},k.delay=function(t,e){var n=a.call(arguments,2);return setTimeout(function(){return t.apply(null,n)},e)},k.defer=function(t){return k.delay.apply(k,[t,1].concat(a.call(arguments,1)))},k.throttle=function(n,r){var i,o,s,a,u=0,l=function(){u=new Date,s=null,a=n.apply(i,o)};return function(){var t=new Date,e=r-(t-u);return i=this,o=arguments,e<=0?(clearTimeout(s),s=null,u=t,a=n.apply(i,o)):s||(s=setTimeout(l,e)),a}},k.debounce=function(i,o,s){var a,u;return function(){var t=this,e=arguments,n=function(){a=null,s||(u=i.apply(t,e))},r=s&&!a;return clearTimeout(a),a=setTimeout(n,o),r&&(u=i.apply(t,e)),u}},k.once=function(t){var e,n=!1;return function(){return n||(n=!0,e=t.apply(this,arguments),t=null),e}},k.wrap=function(e,n){return function(){var t=[e];return o.apply(t,arguments),n.apply(this,t)}},k.compose=function(){var n=arguments;return function(){for(var t=arguments,e=n.length-1;0<=e;e--)t=[n[e].apply(this,t)];return t[0]}},k.after=function(t,e){return t<=0?e():function(){if(--t<1)return e.apply(this,arguments)}},k.keys=x||function(t){if(t!==Object(t))throw new TypeError("Invalid object");var e=[];for(var n in t)k.has(t,n)&&(e[e.length]=n);return e},k.values=function(t){var e=[];for(var n in t)k.has(t,n)&&e.push(t[n]);return e},k.pairs=function(t){var e=[];for(var n in t)k.has(t,n)&&e.push([n,t[n]]);return e},k.invert=function(t){var e={};for(var n in t)k.has(t,n)&&(e[t[n]]=n);return e},k.functions=k.methods=function(t){var e=[];for(var n in t)k.isFunction(t[n])&&e.push(n);return e.sort()},k.extend=function(n){return T(a.call(arguments,1),function(t){if(t)for(var e in t)n[e]=t[e]}),n},k.pick=function(e){var n={},t=u.apply(i,a.call(arguments,1));return T(t,function(t){t in e&&(n[t]=e[t])}),n},k.omit=function(t){var e={},n=u.apply(i,a.call(arguments,1));for(var r in t)k.contains(n,r)||(e[r]=t[r]);return e},k.defaults=function(n){return T(a.call(arguments,1),function(t){if(t)for(var e in t)null==n[e]&&(n[e]=t[e])}),n},k.clone=function(t){return k.isObject(t)?k.isArray(t)?t.slice():k.extend({},t):t},k.tap=function(t,e){return e(t),t};var j=function(t,e,n,r){if(t===e)return 0!==t||1/t==1/e;if(null==t||null==e)return t===e;t instanceof k&&(t=t._wrapped),e instanceof k&&(e=e._wrapped);var i=h.call(t);if(i!=h.call(e))return!1;switch(i){case"[object String]":return t==String(e);case"[object Number]":return t!=+t?e!=+e:0==t?1/t==1/e:t==+e;case"[object Date]":case"[object Boolean]":return+t==+e;case"[object RegExp]":return t.source==e.source&&t.global==e.global&&t.multiline==e.multiline&&t.ignoreCase==e.ignoreCase}if("object"!=typeof t||"object"!=typeof e)return!1;for(var o=n.length;o--;)if(n[o]==t)return r[o]==e;n.push(t),r.push(e);var s=0,a=!0;if("[object Array]"==i){if(a=(s=t.length)==e.length)for(;s--&&(a=j(t[s],e[s],n,r)););}else{var u=t.constructor,l=e.constructor;if(u!==l&&!(k.isFunction(u)&&u instanceof u&&k.isFunction(l)&&l instanceof l))return!1;for(var c in t)if(k.has(t,c)&&(s++,!(a=k.has(e,c)&&j(t[c],e[c],n,r))))break;if(a){for(c in e)if(k.has(e,c)&&!s--)break;a=!s}}return n.pop(),r.pop(),a};k.isEqual=function(t,e){return j(t,e,[],[])},k.isEmpty=function(t){if(null==t)return!0;if(k.isArray(t)||k.isString(t))return 0===t.length;for(var e in t)if(k.has(t,e))return!1;return!0},k.isElement=function(t){return!(!t||1!==t.nodeType)},k.isArray=w||function(t){return"[object Array]"==h.call(t)},k.isObject=function(t){return t===Object(t)},T(["Arguments","Function","String","Number","Date","RegExp"],function(e){k["is"+e]=function(t){return h.call(t)=="[object "+e+"]"}}),k.isArguments(arguments)||(k.isArguments=function(t){return!(!t||!k.has(t,"callee"))}),"function"!=typeof/./&&(k.isFunction=function(t){return"function"==typeof t}),k.isFinite=function(t){return isFinite(t)&&!isNaN(parseFloat(t))},k.isNaN=function(t){return k.isNumber(t)&&t!=+t},k.isBoolean=function(t){return!0===t||!1===t||"[object Boolean]"==h.call(t)},k.isNull=function(t){return null===t},k.isUndefined=function(t){return void 0===t},k.has=function(t,e){return l.call(t,e)},k.noConflict=function(){return t._=e,this},k.identity=function(t){return t},k.times=function(t,e,n){for(var r=Array(t),i=0;i<t;i++)r[i]=e.call(n,i);return r},k.random=function(t,e){return null==e&&(e=t,t=0),t+Math.floor(Math.random()*(e-t+1))};var M={escape:{"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"}};M.unescape=k.invert(M.escape);var D={escape:new RegExp("["+k.keys(M.escape).join("")+"]","g"),unescape:new RegExp("("+k.keys(M.unescape).join("|")+")","g")};k.each(["escape","unescape"],function(e){k[e]=function(t){return null==t?"":(""+t).replace(D[e],function(t){return M[e][t]})}}),k.result=function(t,e){if(null==t)return null;var n=t[e];return k.isFunction(n)?n.call(t):n},k.mixin=function(n){T(k.functions(n),function(t){var e=k[t]=n[t];k.prototype[t]=function(){var t=[this._wrapped];return o.apply(t,arguments),L.call(this,e.apply(k,t))}})};var A=0;k.uniqueId=function(t){var e=++A+"";return t?t+e:e},k.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var O=/(.)^/,R={"'":"'","\\":"\\","\r":"r","\n":"n","\t":"t","\u2028":"u2028","\u2029":"u2029"},P=/\\|'|\r|\n|\t|\u2028|\u2029/g;k.template=function(o,t,e){var n;e=k.defaults({},e,k.templateSettings);var r=new RegExp([(e.escape||O).source,(e.interpolate||O).source,(e.evaluate||O).source].join("|")+"|$","g"),s=0,a="__p+='";o.replace(r,function(t,e,n,r,i){return a+=o.slice(s,i).replace(P,function(t){return"\\"+R[t]}),e&&(a+="'+\n((__t=("+e+"))==null?'':_.escape(__t))+\n'"),n&&(a+="'+\n((__t=("+n+"))==null?'':__t)+\n'"),r&&(a+="';\n"+r+"\n__p+='"),s=i+t.length,t}),a+="';\n",e.variable||(a="with(obj||{}){\n"+a+"}\n"),a="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+a+"return __p;\n";try{n=new Function(e.variable||"obj","_",a)}catch(u){throw u.source=a,u}if(t)return n(t,k);var i=function(t){return n.call(this,t,k)};return i.source="function("+(e.variable||"obj")+"){\n"+a+"}",i},k.chain=function(t){return k(t).chain()};var L=function(t){return this._chain?k(t).chain():t};k.mixin(k),T(["pop","push","reverse","shift","sort","splice","unshift"],function(e){var n=i[e];k.prototype[e]=function(){var t=this._wrapped;return n.apply(t,arguments),"shift"!=e&&"splice"!=e||0!==t.length||delete t[0],L.call(this,t)}}),T(["concat","join","slice"],function(t){var e=i[t];k.prototype[t]=function(){return L.call(this,e.apply(this._wrapped,arguments))}}),k.extend(k.prototype,{chain:function(){return this._chain=!0,this},value:function(){return this._wrapped}})}.call(this),function(){var a,t=this,e=t.Backbone,n=[],p=n.push,i=n.slice,d=n.splice;(a="undefined"!=typeof exports?exports:t.Backbone={}).VERSION="1.0.0";var m=t._;m||"undefined"==typeof require||(m=require("underscore")),a.$=t.jQuery||t.Zepto||t.ender||t.$,a.noConflict=function(){return t.Backbone=e,this},a.emulateHTTP=!1,a.emulateJSON=!1;var r=a.Events={on:function(t,e,n){return h(this,"on",t,[e,n])&&e&&(this._events||(this._events={}),(this._events[t]||(this._events[t]=[])).push({callback:e,context:n,ctx:n||this})),this},once:function(t,e,n){if(!h(this,"once",t,[e,n])||!e)return this;var r=this,i=m.once(function(){r.off(t,i),e.apply(this,arguments)});return i._callback=e,this.on(t,i,n)},off:function(t,e,n){var r,i,o,s,a,u,l,c;if(!this._events||!h(this,"off",t,[e,n]))return this;if(!t&&!e&&!n)return this._events={},this;for(a=0,u=(s=t?[t]:m.keys(this._events)).length;a<u;a++)if(t=s[a],o=this._events[t]){if(this._events[t]=r=[],e||n)for(l=0,c=o.length;l<c;l++)i=o[l],(e&&e!==i.callback&&e!==i.callback._callback||n&&n!==i.context)&&r.push(i);r.length||delete this._events[t]}return this},trigger:function(t){if(!this._events)return this;var e=i.call(arguments,1);if(!h(this,"trigger",t,e))return this;var n=this._events[t],r=this._events.all;return n&&o(n,e),r&&o(r,arguments),this},stopListening:function(t,e,n){var r=this._listeners;if(!r)return this;var i=!e&&!n;for(var o in"object"==typeof e&&(n=this),t&&((r={})[t._listenerId]=t),r)r[o].off(e,n,this),i&&delete this._listeners[o];return this}},u=/\s+/,h=function(t,e,n,r){if(!n)return!0;if("object"==typeof n){for(var i in n)t[e].apply(t,[i,n[i]].concat(r));return!1}if(u.test(n)){for(var o=n.split(u),s=0,a=o.length;s<a;s++)t[e].apply(t,[o[s]].concat(r));return!1}return!0},o=function(t,e){var n,r=-1,i=t.length,o=e[0],s=e[1],a=e[2];switch(e.length){case 0:for(;++r<i;)(n=t[r]).callback.call(n.ctx);return;case 1:for(;++r<i;)(n=t[r]).callback.call(n.ctx,o);return;case 2:for(;++r<i;)(n=t[r]).callback.call(n.ctx,o,s);return;case 3:for(;++r<i;)(n=t[r]).callback.call(n.ctx,o,s,a);return;default:for(;++r<i;)(n=t[r]).callback.apply(n.ctx,e)}},s={listenTo:"on",listenToOnce:"once"};m.each(s,function(i,t){r[t]=function(t,e,n){var r=this._listeners||(this._listeners={});return"object"==typeof e&&(n=this),(r[t._listenerId||(t._listenerId=m.uniqueId("l"))]=t)[i](e,n,this),this}}),r.bind=r.on,r.unbind=r.off,m.extend(a,r);var l=a.Model=function(t,e){var n,r=t||{};e||(e={}),this.cid=m.uniqueId("c"),this.attributes={},m.extend(this,m.pick(e,c)),e.parse&&(r=this.parse(r,e)||{}),(n=m.result(this,"defaults"))&&(r=m.defaults({},r,n)),this.set(r,e),this.changed={},this.initialize.apply(this,arguments)},c=["url","urlRoot","collection"];m.extend(l.prototype,r,{changed:null,validationError:null,idAttribute:"id",initialize:function(){},toJSON:function(){return m.clone(this.attributes)},sync:function(){return a.sync.apply(this,arguments)},get:function(t){return this.attributes[t]},escape:function(t){return m.escape(this.get(t))},has:function(t){return null!=this.get(t)},set:function(t,e,n){var r,i,o,s,a,u,l,c;if(null==t)return this;if("object"==typeof t?(i=t,n=e):(i={})[t]=e,n||(n={}),!this._validate(i,n))return!1;for(r in o=n.unset,a=n.silent,s=[],u=this._changing,this._changing=!0,u||(this._previousAttributes=m.clone(this.attributes),this.changed={}),c=this.attributes,l=this._previousAttributes,this.idAttribute in i&&(this.id=i[this.idAttribute]),i)e=i[r],m.isEqual(c[r],e)||s.push(r),m.isEqual(l[r],e)?delete this.changed[r]:this.changed[r]=e,o?delete c[r]:c[r]=e;if(!a){s.length&&(this._pending=!0);for(var h=0,f=s.length;h<f;h++)this.trigger("change:"+s[h],this,c[s[h]],n)}if(u)return this;if(!a)for(;this._pending;)this._pending=!1,this.trigger("change",this,n);return this._pending=!1,this._changing=!1,this},unset:function(t,e){return this.set(t,void 0,m.extend({},e,{unset:!0}))},clear:function(t){var e={};for(var n in this.attributes)e[n]=void 0;return this.set(e,m.extend({},t,{unset:!0}))},hasChanged:function(t){return null==t?!m.isEmpty(this.changed):m.has(this.changed,t)},changedAttributes:function(t){if(!t)return!!this.hasChanged()&&m.clone(this.changed);var e,n=!1,r=this._changing?this._previousAttributes:this.attributes;for(var i in t)m.isEqual(r[i],e=t[i])||((n||(n={}))[i]=e);return n},previous:function(t){return null!=t&&this._previousAttributes?this._previousAttributes[t]:null},previousAttributes:function(){return m.clone(this._previousAttributes)},fetch:function(e){void 0===(e=e?m.clone(e):{}).parse&&(e.parse=!0);var n=this,r=e.success;return e.success=function(t){if(!n.set(n.parse(t,e),e))return!1;r&&r(n,t,e),n.trigger("sync",n,t,e)},L(this,e),this.sync("read",this,e)},save:function(t,e,n){var r,i,o,s=this.attributes;if(null==t||"object"==typeof t?(r=t,n=e):(r={})[t]=e,r&&(!n||!n.wait)&&!this.set(r,n))return!1;if(n=m.extend({validate:!0},n),!this._validate(r,n))return!1;r&&n.wait&&(this.attributes=m.extend({},s,r)),void 0===n.parse&&(n.parse=!0);var a=this,u=n.success;return n.success=function(t){a.attributes=s;var e=a.parse(t,n);if(n.wait&&(e=m.extend(r||{},e)),m.isObject(e)&&!a.set(e,n))return!1;u&&u(a,t,n),a.trigger("sync",a,t,n)},L(this,n),"patch"===(i=this.isNew()?"create":n.patch?"patch":"update")&&(n.attrs=r),o=this.sync(i,this,n),r&&n.wait&&(this.attributes=s),o},destroy:function(e){e=e?m.clone(e):{};var n=this,r=e.success,i=function(){n.trigger("destroy",n,n.collection,e)};if(e.success=function(t){(e.wait||n.isNew())&&i(),r&&r(n,t,e),n.isNew()||n.trigger("sync",n,t,e)},this.isNew())return e.success(),!1;L(this,e);var t=this.sync("delete",this,e);return e.wait||i(),t},url:function(){var t=m.result(this,"urlRoot")||m.result(this.collection,"url")||P();return this.isNew()?t:t+("/"===t.charAt(t.length-1)?"":"/")+encodeURIComponent(this.id)},parse:function(t){return t},clone:function(){return new this.constructor(this.attributes)},isNew:function(){return null==this.id},isValid:function(t){return this._validate({},m.extend(t||{},{validate:!0}))},_validate:function(t,e){if(!e.validate||!this.validate)return!0;t=m.extend({},this.attributes,t);var n=this.validationError=this.validate(t,e)||null;return!n||(this.trigger("invalid",this,n,m.extend(e||{},{validationError:n})),!1)}});var f=["keys","values","pairs","invert","pick","omit"];m.each(f,function(e){l.prototype[e]=function(){var t=i.call(arguments);return t.unshift(this.attributes),m[e].apply(m,t)}});var g=a.Collection=function(t,e){e||(e={}),e.url&&(this.url=e.url),e.model&&(this.model=e.model),void 0!==e.comparator&&(this.comparator=e.comparator),this._reset(),this.initialize.apply(this,arguments),t&&this.reset(t,m.extend({silent:!0},e))},v={add:!0,remove:!0,merge:!0},y={add:!0,merge:!1,remove:!1};m.extend(g.prototype,r,{model:l,initialize:function(){},toJSON:function(e){return this.map(function(t){return t.toJSON(e)})},sync:function(){return a.sync.apply(this,arguments)},add:function(t,e){return this.set(t,m.defaults(e||{},y))},remove:function(t,e){var n,r,i,o;for(e||(e={}),n=0,r=(t=m.isArray(t)?t.slice():[t]).length;n<r;n++)(o=this.get(t[n]))&&(delete this._byId[o.id],delete this._byId[o.cid],i=this.indexOf(o),this.models.splice(i,1),this.length--,e.silent||(e.index=i,o.trigger("remove",o,this,e)),this._removeReference(o));return this},set:function(t,e){var n,r,i,o,s;(e=m.defaults(e||{},v)).parse&&(t=this.parse(t,e)),m.isArray(t)||(t=t?[t]:[]);var a=e.at,u=this.comparator&&null==a&&!1!==e.sort,l=m.isString(this.comparator)?this.comparator:null,c=[],h=[],f={};for(n=0,r=t.length;n<r;n++)(i=this._prepareModel(t[n],e))&&((o=this.get(i))?(e.remove&&(f[o.cid]=!0),e.merge&&(o.set(i.attributes,e),u&&!s&&o.hasChanged(l)&&(s=!0))):e.add&&(c.push(i),i.on("all",this._onModelEvent,this),null!=(this._byId[i.cid]=i).id&&(this._byId[i.id]=i)));if(e.remove){for(n=0,r=this.length;n<r;++n)f[(i=this.models[n]).cid]||h.push(i);h.length&&this.remove(h,e)}if(c.length&&(u&&(s=!0),this.length+=c.length,null!=a?d.apply(this.models,[a,0].concat(c)):p.apply(this.models,c)),s&&this.sort({silent:!0}),e.silent)return this;for(n=0,r=c.length;n<r;n++)(i=c[n]).trigger("add",i,this,e);return s&&this.trigger("sort",this,e),this},reset:function(t,e){e||(e={});for(var n=0,r=this.models.length;n<r;n++)this._removeReference(this.models[n]);return e.previousModels=this.models,this._reset(),this.add(t,m.extend({silent:!0},e)),e.silent||this.trigger("reset",this,e),this},push:function(t,e){return t=this._prepareModel(t,e),this.add(t,m.extend({at:this.length},e)),t},pop:function(t){var e=this.at(this.length-1);return this.remove(e,t),e},unshift:function(t,e){return t=this._prepareModel(t,e),this.add(t,m.extend({at:0},e)),t},shift:function(t){var e=this.at(0);return this.remove(e,t),e},slice:function(t,e){return this.models.slice(t,e)},get:function(t){if(null!=t)return this._byId[null!=t.id?t.id:t.cid||t]},at:function(t){return this.models[t]},where:function(n,t){return m.isEmpty(n)?t?void 0:[]:this[t?"find":"filter"](function(t){for(var e in n)if(n[e]!==t.get(e))return!1;return!0})},findWhere:function(t){return this.where(t,!0)},sort:function(t){if(!this.comparator)throw new Error("Cannot sort a set without a comparator");return t||(t={}),m.isString(this.comparator)||1===this.comparator.length?this.models=this.sortBy(this.comparator,this):this.models.sort(m.bind(this.comparator,this)),t.silent||this.trigger("sort",this,t),this},sortedIndex:function(t,e,n){e||(e=this.comparator);var r=m.isFunction(e)?e:function(t){return t.get(e)};return m.sortedIndex(this.models,t,r,n)},pluck:function(t){return m.invoke(this.models,"get",t)},fetch:function(n){void 0===(n=n?m.clone(n):{}).parse&&(n.parse=!0);var r=n.success,i=this;return n.success=function(t){var e=n.reset?"reset":"set";i[e](t,n),r&&r(i,t,n),i.trigger("sync",i,t,n)},L(this,n),this.sync("read",this,n)},create:function(e,n){if(n=n?m.clone(n):{},!(e=this._prepareModel(e,n)))return!1;n.wait||this.add(e,n);var r=this,i=n.success;return n.success=function(t){n.wait&&r.add(e,n),i&&i(e,t,n)},e.save(null,n),e},parse:function(t){return t},clone:function(){return new this.constructor(this.models)},_reset:function(){this.length=0,this.models=[],this._byId={}},_prepareModel:function(t,e){if(t instanceof l)return t.collection||(t.collection=this),t;e||(e={});var n=new(e.collection=this).model(t,e);return n._validate(t,e)?n:(this.trigger("invalid",this,t,e),!1)},_removeReference:function(t){this===t.collection&&delete t.collection,t.off("all",this._onModelEvent,this)},_onModelEvent:function(t,e,n,r){("add"!==t&&"remove"!==t||n===this)&&("destroy"===t&&this.remove(e,r),e&&t==="change:"+e.idAttribute&&(delete this._byId[e.previous(e.idAttribute)],null!=e.id&&(this._byId[e.id]=e)),this.trigger.apply(this,arguments))}});var b=["forEach","each","map","collect","reduce","foldl","inject","reduceRight","foldr","find","detect","filter","select","reject","every","all","some","any","include","contains","invoke","max","min","toArray","size","first","head","take","initial","rest","tail","drop","last","without","indexOf","shuffle","lastIndexOf","isEmpty","chain"];m.each(b,function(e){g.prototype[e]=function(){var t=i.call(arguments);return t.unshift(this.models),m[e].apply(m,t)}});var w=["groupBy","countBy","sortBy"];m.each(w,function(r){g.prototype[r]=function(e,t){var n=m.isFunction(e)?e:function(t){return t.get(e)};return m[r](this.models,n,t)}});var x=a.View=function(t){this.cid=m.uniqueId("view"),this._configure(t||{}),this._ensureElement(),this.initialize.apply(this,arguments),this.delegateEvents()},C=/^(\S+)\s*(.*)$/,k=["model","collection","el","id","attributes","className","tagName","events"];m.extend(x.prototype,r,{tagName:"div",$:function(t){return this.$el.find(t)},initialize:function(){},render:function(){return this},remove:function(){return this.$el.remove(),this.stopListening(),this},setElement:function(t,e){return this.$el&&this.undelegateEvents(),this.$el=t instanceof a.$?t:a.$(t),this.el=this.$el[0],!1!==e&&this.delegateEvents(),this},delegateEvents:function(t){if(!t&&!(t=m.result(this,"events")))return this;for(var e in this.undelegateEvents(),t){var n=t[e];if(m.isFunction(n)||(n=this[t[e]]),n){var r=e.match(C),i=r[1],o=r[2];n=m.bind(n,this),i+=".delegateEvents"+this.cid,""===o?this.$el.on(i,n):this.$el.on(i,o,n)}}return this},undelegateEvents:function(){return this.$el.off(".delegateEvents"+this.cid),this},_configure:function(t){this.options&&(t=m.extend({},m.result(this,"options"),t)),m.extend(this,m.pick(t,k)),this.options=t},_ensureElement:function(){if(this.el)this.setElement(m.result(this,"el"),!1);else{var t=m.extend({},m.result(this,"attributes"));this.id&&(t.id=m.result(this,"id")),this.className&&(t["class"]=m.result(this,"className"));var e=a.$("<"+m.result(this,"tagName")+">").attr(t);this.setElement(e,!1)}}}),a.sync=function(t,e,n){var r=T[t];m.defaults(n||(n={}),{emulateHTTP:a.emulateHTTP,emulateJSON:a.emulateJSON});var i={type:r,dataType:"json"};if(n.url||(i.url=m.result(e,"url")||P()),null!=n.data||!e||"create"!==t&&"update"!==t&&"patch"!==t||(i.contentType="application/json",i.data=JSON.stringify(n.attrs||e.toJSON(n))),n.emulateJSON&&(i.contentType="application/x-www-form-urlencoded",i.data=i.data?{model:i.data}:{}),n.emulateHTTP&&("PUT"===r||"DELETE"===r||"PATCH"===r)){i.type="POST",n.emulateJSON&&(i.data._method=r);var o=n.beforeSend;n.beforeSend=function(t){if(t.setRequestHeader("X-HTTP-Method-Override",r),o)return o.apply(this,arguments)}}"GET"===i.type||n.emulateJSON||(i.processData=!1),"PATCH"!==i.type||!window.ActiveXObject||window.external&&window.external.msActiveXFilteringEnabled||(i.xhr=function(){return new ActiveXObject("Microsoft.XMLHTTP")});var s=n.xhr=a.ajax(m.extend(i,n));return e.trigger("request",e,s,n),s};var T={create:"POST",update:"PUT",patch:"PATCH","delete":"DELETE",read:"GET"};a.ajax=function(){return a.$.ajax.apply(a.$,arguments)};var _=a.Router=function(t){t||(t={}),t.routes&&(this.routes=t.routes),this._bindRoutes(),this.initialize.apply(this,arguments)},N=/\((.*?)\)/g,S=/(\(\?)?:\w+/g,$=/\*\w+/g,E=/[\-{}\[\]+?.,\\\^$|#\s]/g;m.extend(_.prototype,r,{initialize:function(){},route:function(n,r,i){m.isRegExp(n)||(n=this._routeToRegExp(n)),m.isFunction(r)&&(i=r,r=""),i||(i=this[r]);var o=this;return a.history.route(n,function(t){var e=o._extractParameters(n,t);i&&i.apply(o,e),o.trigger.apply(o,["route:"+r].concat(e)),o.trigger("route",r,e),a.history.trigger("route",o,r,e)}),this},navigate:function(t,e){return a.history.navigate(t,e),this},_bindRoutes:function(){if(this.routes){this.routes=m.result(this,"routes");for(var t,e=m.keys(this.routes);null!=(t=e.pop());)this.route(t,this.routes[t])}},_routeToRegExp:function(t){return t=t.replace(E,"\\$&").replace(N,"(?:$1)?").replace(S,function(t,e){return e?t:"([^/]+)"}).replace($,"(.*?)"),new RegExp("^"+t+"$")},_extractParameters:function(t,e){var n=t.exec(e).slice(1);return m.map(n,function(t){return t?decodeURIComponent(t):null})}});var j=a.History=function(){this.handlers=[],m.bindAll(this,"checkUrl"),"undefined"!=typeof window&&(this.location=window.location,this.history=window.history)},M=/^[#\/]|\s+$/g,D=/^\/+|\/+$/g,A=/msie [\w.]+/,O=/\/$/;j.started=!1,m.extend(j.prototype,r,{interval:50,getHash:function(t){var e=(t||this).location.href.match(/#(.*)$/);return e?e[1]:""},getFragment:function(t,e){if(null==t)if(this._hasPushState||!this._wantsHashChange||e){t=this.location.pathname;var n=this.root.replace(O,"");t.indexOf(n)||(t=t.substr(n.length))}else t=this.getHash();return t.replace(M,"")},start:function(t){if(j.started)throw new Error("Backbone.history has already been started");j.started=!0,this.options=m.extend({},{root:"/"},this.options,t),this.root=this.options.root,this._wantsHashChange=!1!==this.options.hashChange,this._wantsPushState=!!this.options.pushState,this._hasPushState=!!(this.options.pushState&&this.history&&this.history.pushState);var e=this.getFragment(),n=document.documentMode,r=A.exec(navigator.userAgent.toLowerCase())&&(!n||n<=7);this.root=("/"+this.root+"/").replace(D,"/"),r&&this._wantsHashChange&&(this.iframe=a.$('<iframe src="javascript:0" tabindex="-1" />').hide().appendTo("body")[0].contentWindow,this.navigate(e)),this._hasPushState?a.$(window).on("popstate",this.checkUrl):this._wantsHashChange&&"onhashchange"in window&&!r?a.$(window).on("hashchange",this.checkUrl):this._wantsHashChange&&(this._checkUrlInterval=setInterval(this.checkUrl,this.interval)),this.fragment=e;var i=this.location,o=i.pathname.replace(/[^\/]$/,"$&/")===this.root;return this._wantsHashChange&&this._wantsPushState&&!this._hasPushState&&!o?(this.fragment=this.getFragment(null,!0),this.location.replace(this.root+this.location.search+"#"+this.fragment),!0):(this._wantsPushState&&this._hasPushState&&o&&i.hash&&(this.fragment=this.getHash().replace(M,""),this.history.replaceState({},document.title,this.root+this.fragment+i.search)),this.options.silent?void 0:this.loadUrl())},stop:function(){a.$(window).off("popstate",this.checkUrl).off(
|
28
|
+
"hashchange",this.checkUrl),clearInterval(this._checkUrlInterval),j.started=!1},route:function(t,e){this.handlers.unshift({route:t,callback:e})},checkUrl:function(){var t=this.getFragment();if(t===this.fragment&&this.iframe&&(t=this.getFragment(this.getHash(this.iframe))),t===this.fragment)return!1;this.iframe&&this.navigate(t),this.loadUrl()||this.loadUrl(this.getHash())},loadUrl:function(t){var e=this.fragment=this.getFragment(t);return m.any(this.handlers,function(t){if(t.route.test(e))return t.callback(e),!0})},navigate:function(t,e){if(!j.started)return!1;if(e&&!0!==e||(e={trigger:e}),t=this.getFragment(t||""),this.fragment!==t){this.fragment=t;var n=this.root+t;if(this._hasPushState)this.history[e.replace?"replaceState":"pushState"]({},document.title,n);else{if(!this._wantsHashChange)return this.location.assign(n);this._updateHash(this.location,t,e.replace),this.iframe&&t!==this.getFragment(this.getHash(this.iframe))&&(e.replace||this.iframe.document.open().close(),this._updateHash(this.iframe.location,t,e.replace))}e.trigger&&this.loadUrl(t)}},_updateHash:function(t,e,n){if(n){var r=t.href.replace(/(javascript:|#).*$/,"");t.replace(r+"#"+e)}else t.hash="#"+e}}),a.history=new j;var R=function(t,e){var n,r=this;n=t&&m.has(t,"constructor")?t.constructor:function(){return r.apply(this,arguments)},m.extend(n,r,e);var i=function(){this.constructor=n};return i.prototype=r.prototype,n.prototype=new i,t&&m.extend(n.prototype,t),n.__super__=r.prototype,n};l.extend=g.extend=_.extend=x.extend=j.extend=R;var P=function(){throw new Error('A "url" property or function must be specified')},L=function(e,n){var r=n.error;n.error=function(t){r&&r(e,t,n),e.trigger("error",e,t,n)}}}.call(this),function(e){"use strict";e(function(){var t;e.support.transition=(t=function(){var t,e=document.createElement("bootstrap"),n={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(t in n)if(e.style[t]!==undefined)return n[t]}())&&{end:t}})}(window.jQuery),function(o){"use strict";var e='[data-dismiss="alert"]',r=function(t){o(t).on("click",e,this.close)};r.prototype.close=function(t){function e(){n.trigger("closed").remove()}var n,r=o(this),i=r.attr("data-target");i||(i=(i=r.attr("href"))&&i.replace(/.*(?=#[^\s]*$)/,"")),n=o(i),t&&t.preventDefault(),n.length||(n=r.hasClass("alert")?r:r.parent()),n.trigger(t=o.Event("close")),t.isDefaultPrevented()||(n.removeClass("in"),o.support.transition&&n.hasClass("fade")?n.on(o.support.transition.end,e):e())};var t=o.fn.alert;o.fn.alert=function(n){return this.each(function(){var t=o(this),e=t.data("alert");e||t.data("alert",e=new r(this)),"string"==typeof n&&e[n].call(t)})},o.fn.alert.Constructor=r,o.fn.alert.noConflict=function(){return o.fn.alert=t,this},o(document).on("click.alert.data-api",e,r.prototype.close)}(window.jQuery),function(i){"use strict";var o=function(t,e){this.$element=i(t),this.options=i.extend({},i.fn.button.defaults,e)};o.prototype.setState=function(t){var e="disabled",n=this.$element,r=n.data(),i=n.is("input")?"val":"html";t+="Text",r.resetText||n.data("resetText",n[i]()),n[i](r[t]||this.options[t]),setTimeout(function(){"loadingText"==t?n.addClass(e).attr(e,e):n.removeClass(e).removeAttr(e)},0)},o.prototype.toggle=function(){var t=this.$element.closest('[data-toggle="buttons-radio"]');t&&t.find(".active").removeClass("active"),this.$element.toggleClass("active")};var t=i.fn.button;i.fn.button=function(r){return this.each(function(){var t=i(this),e=t.data("button"),n="object"==typeof r&&r;e||t.data("button",e=new o(this,n)),"toggle"==r?e.toggle():r&&e.setState(r)})},i.fn.button.defaults={loadingText:"loading..."},i.fn.button.Constructor=o,i.fn.button.noConflict=function(){return i.fn.button=t,this},i(document).on("click.button.data-api","[data-toggle^=button]",function(t){var e=i(t.target);e.hasClass("btn")||(e=e.closest(".btn")),e.button("toggle")})}(window.jQuery),function(l){"use strict";var o=function(t,e){this.$element=l(t),this.$indicators=this.$element.find(".carousel-indicators"),this.options=e,"hover"==this.options.pause&&this.$element.on("mouseenter",l.proxy(this.pause,this)).on("mouseleave",l.proxy(this.cycle,this))};o.prototype={cycle:function(t){return t||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(l.proxy(this.next,this),this.options.interval)),this},getActiveIndex:function(){return this.$active=this.$element.find(".item.active"),this.$items=this.$active.parent().children(),this.$items.index(this.$active)},to:function(t){var e=this.getActiveIndex(),n=this;if(!(t>this.$items.length-1||t<0))return this.sliding?this.$element.one("slid",function(){n.to(t)}):e==t?this.pause().cycle():this.slide(e<t?"next":"prev",l(this.$items[t]))},pause:function(t){return t||(this.paused=!0),this.$element.find(".next, .prev").length&&l.support.transition.end&&(this.$element.trigger(l.support.transition.end),this.cycle(!0)),clearInterval(this.interval),this.interval=null,this},next:function(){if(!this.sliding)return this.slide("next")},prev:function(){if(!this.sliding)return this.slide("prev")},slide:function(t,e){var n,r=this.$element.find(".item.active"),i=e||r[t](),o=this.interval,s="next"==t?"left":"right",a="next"==t?"first":"last",u=this;if(this.sliding=!0,o&&this.pause(),i=i.length?i:this.$element.find(".item")[a](),n=l.Event("slide",{relatedTarget:i[0],direction:s}),!i.hasClass("active")){if(this.$indicators.length&&(this.$indicators.find(".active").removeClass("active"),this.$element.one("slid",function(){var t=l(u.$indicators.children()[u.getActiveIndex()]);t&&t.addClass("active")})),l.support.transition&&this.$element.hasClass("slide")){if(this.$element.trigger(n),n.isDefaultPrevented())return;i.addClass(t),i[0].offsetWidth,r.addClass(s),i.addClass(s),this.$element.one(l.support.transition.end,function(){i.removeClass([t,s].join(" ")).addClass("active"),r.removeClass(["active",s].join(" ")),u.sliding=!1,setTimeout(function(){u.$element.trigger("slid")},0)})}else{if(this.$element.trigger(n),n.isDefaultPrevented())return;r.removeClass("active"),i.addClass("active"),this.sliding=!1,this.$element.trigger("slid")}return o&&this.cycle(),this}}};var t=l.fn.carousel;l.fn.carousel=function(i){return this.each(function(){var t=l(this),e=t.data("carousel"),n=l.extend({},l.fn.carousel.defaults,"object"==typeof i&&i),r="string"==typeof i?i:n.slide;e||t.data("carousel",e=new o(this,n)),"number"==typeof i?e.to(i):r?e[r]():n.interval&&e.pause().cycle()})},l.fn.carousel.defaults={interval:5e3,pause:"hover"},l.fn.carousel.Constructor=o,l.fn.carousel.noConflict=function(){return l.fn.carousel=t,this},l(document).on("click.carousel.data-api","[data-slide], [data-slide-to]",function(t){var e,n,r=l(this),i=l(r.attr("data-target")||(e=r.attr("href"))&&e.replace(/.*(?=#[^\s]+$)/,"")),o=l.extend({},i.data(),r.data());i.carousel(o),(n=r.attr("data-slide-to"))&&i.data("carousel").pause().to(n).cycle(),t.preventDefault()})}(window.jQuery),function(o){"use strict";var i=function(t,e){this.$element=o(t),this.options=o.extend({},o.fn.collapse.defaults,e),this.options.parent&&(this.$parent=o(this.options.parent)),this.options.toggle&&this.toggle()};i.prototype={constructor:i,dimension:function(){return this.$element.hasClass("width")?"width":"height"},show:function(){var t,e,n,r;if(!this.transitioning&&!this.$element.hasClass("in")){if(t=this.dimension(),e=o.camelCase(["scroll",t].join("-")),(n=this.$parent&&this.$parent.find("> .accordion-group > .in"))&&n.length){if((r=n.data("collapse"))&&r.transitioning)return;n.collapse("hide"),r||n.data("collapse",null)}this.$element[t](0),this.transition("addClass",o.Event("show"),"shown"),o.support.transition&&this.$element[t](this.$element[0][e])}},hide:function(){var t;!this.transitioning&&this.$element.hasClass("in")&&(t=this.dimension(),this.reset(this.$element[t]()),this.transition("removeClass",o.Event("hide"),"hidden"),this.$element[t](0))},reset:function(t){var e=this.dimension();return this.$element.removeClass("collapse")[e](t||"auto")[0].offsetWidth,this.$element[null!==t?"addClass":"removeClass"]("collapse"),this},transition:function(t,e,n){var r=this,i=function(){"show"==e.type&&r.reset(),r.transitioning=0,r.$element.trigger(n)};this.$element.trigger(e),e.isDefaultPrevented()||(this.transitioning=1,this.$element[t]("in"),o.support.transition&&this.$element.hasClass("collapse")?this.$element.one(o.support.transition.end,i):i())},toggle:function(){this[this.$element.hasClass("in")?"hide":"show"]()}};var t=o.fn.collapse;o.fn.collapse=function(r){return this.each(function(){var t=o(this),e=t.data("collapse"),n=o.extend({},o.fn.collapse.defaults,t.data(),"object"==typeof r&&r);e||t.data("collapse",e=new i(this,n)),"string"==typeof r&&e[r]()})},o.fn.collapse.defaults={toggle:!0},o.fn.collapse.Constructor=i,o.fn.collapse.noConflict=function(){return o.fn.collapse=t,this},o(document).on("click.collapse.data-api","[data-toggle=collapse]",function(t){var e,n=o(this),r=n.attr("data-target")||t.preventDefault()||(e=n.attr("href"))&&e.replace(/.*(?=#[^\s]+$)/,""),i=o(r).data("collapse")?"toggle":n.data();n[o(r).hasClass("in")?"addClass":"removeClass"]("collapsed"),o(r).collapse(i)})}(window.jQuery),function(s){"use strict";function r(){s(u).each(function(){a(s(this)).removeClass("open")})}function a(t){var e,n=t.attr("data-target");return n||(n=(n=t.attr("href"))&&/#/.test(n)&&n.replace(/.*(?=#[^\s]*$)/,"")),(e=n&&s(n))&&e.length||(e=t.parent()),e}var u="[data-toggle=dropdown]",i=function(t){var e=s(t).on("click.dropdown.data-api",this.toggle);s("html").on("click.dropdown.data-api",function(){e.parent().removeClass("open")})};i.prototype={constructor:i,toggle:function(){var t,e,n=s(this);if(!n.is(".disabled, :disabled"))return e=(t=a(n)).hasClass("open"),r(),e||t.toggleClass("open"),n.focus(),!1},keydown:function(t){var e,n,r,i,o;if(/(38|40|27)/.test(t.keyCode)&&(e=s(this),t.preventDefault(),t.stopPropagation(),!e.is(".disabled, :disabled"))){if(!(i=(r=a(e)).hasClass("open"))||i&&27==t.keyCode)return 27==t.which&&r.find(u).focus(),e.click();(n=s("[role=menu] li:not(.divider):visible a",r)).length&&(o=n.index(n.filter(":focus")),38==t.keyCode&&0<o&&o--,40==t.keyCode&&o<n.length-1&&o++,~o||(o=0),n.eq(o).focus())}}};var t=s.fn.dropdown;s.fn.dropdown=function(n){return this.each(function(){var t=s(this),e=t.data("dropdown");e||t.data("dropdown",e=new i(this)),"string"==typeof n&&e[n].call(t)})},s.fn.dropdown.Constructor=i,s.fn.dropdown.noConflict=function(){return s.fn.dropdown=t,this},s(document).on("click.dropdown.data-api",r).on("click.dropdown.data-api",".dropdown form",function(t){t.stopPropagation()}).on("click.dropdown-menu",function(t){t.stopPropagation()}).on("click.dropdown.data-api",u,i.prototype.toggle).on("keydown.dropdown.data-api",u+", [role=menu]",i.prototype.keydown)}(window.jQuery),function(o){"use strict";var i=function(t,e){this.options=e,this.$element=o(t).delegate('[data-dismiss="modal"]',"click.dismiss.modal",o.proxy(this.hide,this)),this.options.remote&&this.$element.find(".modal-body").load(this.options.remote)};i.prototype={constructor:i,toggle:function(){return this[this.isShown?"hide":"show"]()},show:function(){var e=this,t=o.Event("show");this.$element.trigger(t),this.isShown||t.isDefaultPrevented()||(this.isShown=!0,this.escape(),this.backdrop(function(){var t=o.support.transition&&e.$element.hasClass("fade");e.$element.parent().length||e.$element.appendTo(document.body),e.$element.show(),t&&e.$element[0].offsetWidth,e.$element.addClass("in").attr("aria-hidden",!1),e.enforceFocus(),t?e.$element.one(o.support.transition.end,function(){e.$element.focus().trigger("shown")}):e.$element.focus().trigger("shown")}))},hide:function(t){t&&t.preventDefault();t=o.Event("hide"),this.$element.trigger(t),this.isShown&&!t.isDefaultPrevented()&&(this.isShown=!1,this.escape(),o(document).off("focusin.modal"),this.$element.removeClass("in").attr("aria-hidden",!0),o.support.transition&&this.$element.hasClass("fade")?this.hideWithTransition():this.hideModal())},enforceFocus:function(){var e=this;o(document).on("focusin.modal",function(t){e.$element[0]===t.target||e.$element.has(t.target).length||e.$element.focus()})},escape:function(){var e=this;this.isShown&&this.options.keyboard?this.$element.on("keyup.dismiss.modal",function(t){27==t.which&&e.hide()}):this.isShown||this.$element.off("keyup.dismiss.modal")},hideWithTransition:function(){var t=this,e=setTimeout(function(){t.$element.off(o.support.transition.end),t.hideModal()},500);this.$element.one(o.support.transition.end,function(){clearTimeout(e),t.hideModal()})},hideModal:function(){var t=this;this.$element.hide(),this.backdrop(function(){t.removeBackdrop(),t.$element.trigger("hidden")})},removeBackdrop:function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},backdrop:function(t){var e=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var n=o.support.transition&&e;if(this.$backdrop=o('<div class="modal-backdrop '+e+'" />').appendTo(document.body),this.$backdrop.click("static"==this.options.backdrop?o.proxy(this.$element[0].focus,this.$element[0]):o.proxy(this.hide,this)),n&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!t)return;n?this.$backdrop.one(o.support.transition.end,t):t()}else!this.isShown&&this.$backdrop?(this.$backdrop.removeClass("in"),o.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one(o.support.transition.end,t):t()):t&&t()}};var t=o.fn.modal;o.fn.modal=function(r){return this.each(function(){var t=o(this),e=t.data("modal"),n=o.extend({},o.fn.modal.defaults,t.data(),"object"==typeof r&&r);e||t.data("modal",e=new i(this,n)),"string"==typeof r?e[r]():n.show&&e.show()})},o.fn.modal.defaults={backdrop:!0,keyboard:!0,show:!0},o.fn.modal.Constructor=i,o.fn.modal.noConflict=function(){return o.fn.modal=t,this},o(document).on("click.modal.data-api",'[data-toggle="modal"]',function(t){var e=o(this),n=e.attr("href"),r=o(e.attr("data-target")||n&&n.replace(/.*(?=#[^\s]+$)/,"")),i=r.data("modal")?"toggle":o.extend({remote:!/#/.test(n)&&n},r.data(),e.data());t.preventDefault(),r.modal(i).one("hide",function(){e.focus()})})}(window.jQuery),function(u){"use strict";var i=function(t,e){this.init("tooltip",t,e)};i.prototype={constructor:i,init:function(t,e,n){var r,i,o,s,a;for(this.type=t,this.$element=u(e),this.options=this.getOptions(n),this.enabled=!0,a=(o=this.options.trigger.split(" ")).length;a--;)"click"==(s=o[a])?this.$element.on("click."+this.type,this.options.selector,u.proxy(this.toggle,this)):"manual"!=s&&(r="hover"==s?"mouseenter":"focus",i="hover"==s?"mouseleave":"blur",this.$element.on(r+"."+this.type,this.options.selector,u.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,u.proxy(this.leave,this)));this.options.selector?this._options=u.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(t){return(t=u.extend({},u.fn[this.type].defaults,this.$element.data(),t)).delay&&"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),t},enter:function(t){var e,n=u.fn[this.type].defaults,r={};if(this._options&&u.each(this._options,function(t,e){n[t]!=e&&(r[t]=e)},this),!(e=u(t.currentTarget)[this.type](r).data(this.type)).options.delay||!e.options.delay.show)return e.show();clearTimeout(this.timeout),e.hoverState="in",this.timeout=setTimeout(function(){"in"==e.hoverState&&e.show()},e.options.delay.show)},leave:function(t){var e=u(t.currentTarget)[this.type](this._options).data(this.type);if(this.timeout&&clearTimeout(this.timeout),!e.options.delay||!e.options.delay.hide)return e.hide();e.hoverState="out",this.timeout=setTimeout(function(){"out"==e.hoverState&&e.hide()},e.options.delay.hide)},show:function(){var t,e,n,r,i,o,s=u.Event("show");if(this.hasContent()&&this.enabled){if(this.$element.trigger(s),s.isDefaultPrevented())return;switch(t=this.tip(),this.setContent(),this.options.animation&&t.addClass("fade"),i="function"==typeof this.options.placement?this.options.placement.call(this,t[0],this.$element[0]):this.options.placement,t.detach().css({top:0,left:0,display:"block"}),this.options.container?t.appendTo(this.options.container):t.insertAfter(this.$element),e=this.getPosition(),n=t[0].offsetWidth,r=t[0].offsetHeight,i){case"bottom":o={top:e.top+e.height,left:e.left+e.width/2-n/2};break;case"top":o={top:e.top-r,left:e.left+e.width/2-n/2};break;case"left":o={top:e.top+e.height/2-r/2,left:e.left-n};break;case"right":o={top:e.top+e.height/2-r/2,left:e.left+e.width}}this.applyPlacement(o,i),this.$element.trigger("shown")}},applyPlacement:function(t,e){var n,r,i,o,s=this.tip(),a=s[0].offsetWidth,u=s[0].offsetHeight;s.offset(t).addClass(e).addClass("in"),n=s[0].offsetWidth,r=s[0].offsetHeight,"top"==e&&r!=u&&(t.top=t.top+u-r,o=!0),"bottom"==e||"top"==e?(i=0,t.left<0&&(i=-2*t.left,t.left=0,s.offset(t),n=s[0].offsetWidth,r=s[0].offsetHeight),this.replaceArrow(i-a+n,n,"left")):this.replaceArrow(r-u,r,"top"),o&&s.offset(t)},replaceArrow:function(t,e,n){this.arrow().css(n,t?50*(1-t/e)+"%":"")},setContent:function(){var t=this.tip(),e=this.getTitle();t.find(".tooltip-inner")[this.options.html?"html":"text"](e),t.removeClass("fade in top bottom left right")},hide:function(){function t(){var t=setTimeout(function(){e.off(u.support.transition.end).detach()},500);e.one(u.support.transition.end,function(){clearTimeout(t),e.detach()})}var e=this.tip(),n=u.Event("hide");if(this.$element.trigger(n),!n.isDefaultPrevented())return e.removeClass("in"),u.support.transition&&this.$tip.hasClass("fade")?t():e.detach(),this.$element.trigger("hidden"),this},fixTitle:function(){var t=this.$element;(t.attr("title")||"string"!=typeof t.attr("data-original-title"))&&t.attr("data-original-title",t.attr("title")||"").attr("title","")},hasContent:function(){return this.getTitle()},getPosition:function(){var t=this.$element[0];return u.extend({},"function"==typeof t.getBoundingClientRect?t.getBoundingClientRect():{width:t.offsetWidth,height:t.offsetHeight},this.$element.offset())},getTitle:function(){var t=this.$element,e=this.options;return t.attr("data-original-title")||("function"==typeof e.title?e.title.call(t[0]):e.title)},tip:function(){return this.$tip=this.$tip||u(this.options.template)},arrow:function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(t){var e=t?u(t.currentTarget)[this.type](this._options).data(this.type):this;e.tip().hasClass("in")?e.hide():e.show()},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}};var t=u.fn.tooltip;u.fn.tooltip=function(r){return this.each(function(){var t=u(this),e=t.data("tooltip"),n="object"==typeof r&&r;e||t.data("tooltip",e=new i(this,n)),"string"==typeof r&&e[r]()})},u.fn.tooltip.Constructor=i,u.fn.tooltip.defaults={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1},u.fn.tooltip.noConflict=function(){return u.fn.tooltip=t,this}}(window.jQuery),function(i){"use strict";var o=function(t,e){this.init("popover",t,e)};o.prototype=i.extend({},i.fn.tooltip.Constructor.prototype,{constructor:o,setContent:function(){var t=this.tip(),e=this.getTitle(),n=this.getContent();t.find(".popover-title")[this.options.html?"html":"text"](e),t.find(".popover-content")[this.options.html?"html":"text"](n),t.removeClass("fade top bottom left right in")},hasContent:function(){return this.getTitle()||this.getContent()},getContent:function(){var t=this.$element,e=this.options;return("function"==typeof e.content?e.content.call(t[0]):e.content)||t.attr("data-content")},tip:function(){return this.$tip||(this.$tip=i(this.options.template)),this.$tip},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}});var t=i.fn.popover;i.fn.popover=function(r){return this.each(function(){var t=i(this),e=t.data("popover"),n="object"==typeof r&&r;e||t.data("popover",e=new o(this,n)),"string"==typeof r&&e[r]()})},i.fn.popover.Constructor=o,i.fn.popover.defaults=i.extend({},i.fn.tooltip.defaults,{placement:"right",trigger:"click",content:"",template:'<div class="popover"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),i.fn.popover.noConflict=function(){return i.fn.popover=t,this}}(window.jQuery),function(o){"use strict";function i(t,e){var n,r=o.proxy(this.process,this),i=o(t).is("body")?o(window):o(t);this.options=o.extend({},o.fn.scrollspy.defaults,e),this.$scrollElement=i.on("scroll.scroll-spy.data-api",r),this.selector=(this.options.target||(n=o(t).attr("href"))&&n.replace(/.*(?=#[^\s]+$)/,"")||"")+" .nav li > a",this.$body=o("body"),this.refresh(),this.process()}i.prototype={constructor:i,refresh:function(){var r=this;this.offsets=o([]),this.targets=o([]),this.$body.find(this.selector).map(function(){var t=o(this),e=t.data("target")||t.attr("href"),n=/^#\w/.test(e)&&o(e);return n&&n.length&&[[n.position().top+(!o.isWindow(r.$scrollElement.get(0))&&r.$scrollElement.scrollTop()),e]]||null}).sort(function(t,e){return t[0]-e[0]}).each(function(){r.offsets.push(this[0]),r.targets.push(this[1])})},process:function(){var t,e=this.$scrollElement.scrollTop()+this.options.offset,n=(this.$scrollElement[0].scrollHeight||this.$body[0].scrollHeight)-this.$scrollElement.height(),r=this.offsets,i=this.targets,o=this.activeTarget;if(n<=e)return o!=(t=i.last()[0])&&this.activate(t);for(t=r.length;t--;)o!=i[t]&&e>=r[t]&&(!r[t+1]||e<=r[t+1])&&this.activate(i[t])},activate:function(t){var e,n;this.activeTarget=t,o(this.selector).parent(".active").removeClass("active"),n=this.selector+'[data-target="'+t+'"],'+this.selector+'[href="'+t+'"]',(e=o(n).parent("li").addClass("active")).parent(".dropdown-menu").length&&(e=e.closest("li.dropdown").addClass("active")),e.trigger("activate")}};var t=o.fn.scrollspy;o.fn.scrollspy=function(r){return this.each(function(){var t=o(this),e=t.data("scrollspy"),n="object"==typeof r&&r;e||t.data("scrollspy",e=new i(this,n)),"string"==typeof r&&e[r]()})},o.fn.scrollspy.Constructor=i,o.fn.scrollspy.defaults={offset:10},o.fn.scrollspy.noConflict=function(){return o.fn.scrollspy=t,this},o(window).on("load",function(){o('[data-spy="scroll"]').each(function(){var t=o(this);t.scrollspy(t.data())})})}(window.jQuery),function(s){"use strict";var r=function(t){this.element=s(t)};r.prototype={constructor:r,show:function(){var t,e,n,r=this.element,i=r.closest("ul:not(.dropdown-menu)"),o=r.attr("data-target");o||(o=(o=r.attr("href"))&&o.replace(/.*(?=#[^\s]*$)/,"")),r.parent("li").hasClass("active")||(t=i.find(".active:last a")[0],n=s.Event("show",{relatedTarget:t}),r.trigger(n),n.isDefaultPrevented()||(e=s(o),this.activate(r.parent("li"),i),this.activate(e,e.parent(),function(){r.trigger({type:"shown",relatedTarget:t})})))},activate:function(t,e,n){function r(){i.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),t.addClass("active"),o?(t[0].offsetWidth,t.addClass("in")):t.removeClass("fade"),t.parent(".dropdown-menu")&&t.closest("li.dropdown").addClass("active"),n&&n()}var i=e.find("> .active"),o=n&&s.support.transition&&i.hasClass("fade");o?i.one(s.support.transition.end,r):r(),i.removeClass("in")}};var t=s.fn.tab;s.fn.tab=function(n){return this.each(function(){var t=s(this),e=t.data("tab");e||t.data("tab",e=new r(this)),"string"==typeof n&&e[n]()})},s.fn.tab.Constructor=r,s.fn.tab.noConflict=function(){return s.fn.tab=t,this},s(document).on("click.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(t){t.preventDefault(),s(this).tab("show")})}(window.jQuery),function(i){"use strict";var o=function(t,e){this.$element=i(t),this.options=i.extend({},i.fn.typeahead.defaults,e),this.matcher=this.options.matcher||this.matcher,this.sorter=this.options.sorter||this.sorter,this.highlighter=this.options.highlighter||this.highlighter,this.updater=this.options.updater||this.updater,this.source=this.options.source,this.$menu=i(this.options.menu),this.shown=!1,this.listen()};o.prototype={constructor:o,select:function(){var t=this.$menu.find(".active").attr("data-value");return this.$element.val(this.updater(t)).change(),this.hide()},updater:function(t){return t},show:function(){var t=i.extend({},this.$element.position(),{height:this.$element[0].offsetHeight});return this.$menu.insertAfter(this.$element).css({top:t.top+t.height,left:t.left}).show(),this.shown=!0,this},hide:function(){return this.$menu.hide(),this.shown=!1,this},lookup:function(){var t;return this.query=this.$element.val(),!this.query||this.query.length<this.options.minLength?this.shown?this.hide():this:(t=i.isFunction(this.source)?this.source(this.query,i.proxy(this.process,this)):this.source)?this.process(t):this},process:function(t){var e=this;return t=i.grep(t,function(t){return e.matcher(t)}),(t=this.sorter(t)).length?this.render(t.slice(0,this.options.items)).show():this.shown?this.hide():this},matcher:function(t){return~t.toLowerCase().indexOf(this.query.toLowerCase())},sorter:function(t){for(var e,n=[],r=[],i=[];e=t.shift();)e.toLowerCase().indexOf(this.query.toLowerCase())?~e.indexOf(this.query)?r.push(e):i.push(e):n.push(e);return n.concat(r,i)},highlighter:function(t){var e=this.query.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&");return t.replace(new RegExp("("+e+")","ig"),function(t,e){return"<strong>"+e+"</strong>"})},render:function(t){var n=this;return(t=i(t).map(function(t,e){return(t=i(n.options.item).attr("data-value",e)).find("a").html(n.highlighter(e)),t[0]})).first().addClass("active"),this.$menu.html(t),this},next:function(){var t=this.$menu.find(".active").removeClass("active").next();t.length||(t=i(this.$menu.find("li")[0])),t.addClass("active")},prev:function(){var t=this.$menu.find(".active").removeClass("active").prev();t.length||(t=this.$menu.find("li").last()),t.addClass("active")},listen:function(){this.$element.on("focus",i.proxy(this.focus,this)).on("blur",i.proxy(this.blur,this)).on("keypress",i.proxy(this.keypress,this)).on("keyup",i.proxy(this.keyup,this)),this.eventSupported("keydown")&&this.$element.on("keydown",i.proxy(this.keydown,this)),this.$menu.on("click",i.proxy(this.click,this)).on("mouseenter","li",i.proxy(this.mouseenter,this)).on("mouseleave","li",i.proxy(this.mouseleave,this))},eventSupported:function(t){var e=t in this.$element;return e||(this.$element.setAttribute(t,"return;"),e="function"==typeof this.$element[t]),e},move:function(t){if(this.shown){switch(t.keyCode){case 9:case 13:case 27:t.preventDefault();break;case 38:t.preventDefault(),this.prev();break;case 40:t.preventDefault(),this.next()}t.stopPropagation()}},keydown:function(t){this.suppressKeyPressRepeat=~i.inArray(t.keyCode,[40,38,9,13,27]),this.move(t)},keypress:function(t){this.suppressKeyPressRepeat||this.move(t)},keyup:function(t){switch(t.keyCode){case 40:case 38:case 16:case 17:case 18:break;case 9:case 13:if(!this.shown)return;this.select();break;case 27:if(!this.shown)return;this.hide();break;default:this.lookup()}t.stopPropagation(),t.preventDefault()},focus:function(){this.focused=!0},blur:function(){this.focused=!1,!this.mousedover&&this.shown&&this.hide()},click:function(t){t.stopPropagation(),t.preventDefault(),this.select(),this.$element.focus()},mouseenter:function(t){this.mousedover=!0,this.$menu.find(".active").removeClass("active"),i(t.currentTarget).addClass("active")},mouseleave:function(){this.mousedover=!1,!this.focused&&this.shown&&this.hide()}};var t=i.fn.typeahead;i.fn.typeahead=function(r){return this.each(function(){var t=i(this),e=t.data("typeahead"),n="object"==typeof r&&r;e||t.data("typeahead",e=new o(this,n)),"string"==typeof r&&e[r]()})},i.fn.typeahead.defaults={source:[],items:8,menu:'<ul class="typeahead dropdown-menu"></ul>',item:'<li><a href="#"></a></li>',minLength:1},i.fn.typeahead.Constructor=o,i.fn.typeahead.noConflict=function(){return i.fn.typeahead=t,this},i(document).on("focus.typeahead.data-api",'[data-provide="typeahead"]',function(){var t=i(this);t.data("typeahead")||t.typeahead(t.data())})}(window.jQuery),function(u){"use strict";var i=function(t,e){this.options=u.extend({},u.fn.affix.defaults,e),this.$window=u(window).on("scroll.affix.data-api",u.proxy(this.checkPosition,this)).on("click.affix.data-api",u.proxy(function(){setTimeout(u.proxy(this.checkPosition,this),1)},this)),this.$element=u(t),this.checkPosition()};i.prototype.checkPosition=function(){if(this.$element.is(":visible")){var t,e=u(document).height(),n=this.$window.scrollTop(),r=this.$element.offset(),i=this.options.offset,o=i.bottom,s=i.top,a="affix affix-top affix-bottom";"object"!=typeof i&&(o=s=i),"function"==typeof s&&(s=i.top()),"function"==typeof o&&(o=i.bottom()),t=!(null!=this.unpin&&n+this.unpin<=r.top)&&(null!=o&&r.top+this.$element.height()>=e-o?"bottom":null!=s&&n<=s&&"top"),this.affixed!==t&&(this.affixed=t,this.unpin="bottom"==t?r.top-n:null,this.$element.removeClass(a).addClass("affix"+(t?"-"+t:"")))}};var t=u.fn.affix;u.fn.affix=function(r){return this.each(function(){var t=u(this),e=t.data("affix"),n="object"==typeof r&&r;e||t.data("affix",e=new i(this,n)),"string"==typeof r&&e[r]()})},u.fn.affix.Constructor=i,u.fn.affix.defaults={offset:0},u.fn.affix.noConflict=function(){return u.fn.affix=t,this},u(window).on("load",function(){u('[data-spy="affix"]').each(function(){var t=u(this),e=t.data();e.offset=e.offset||{},e.offsetBottom&&(e.offset.bottom=e.offsetBottom),e.offsetTop&&(e.offset.top=e.offsetTop),t.affix(e)})})}(window.jQuery),function(){var t=this,e=t.humanize,c={};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=c),exports.humanize=c):("function"==typeof define&&define.amd&&define("humanize",function(){return c}),t.humanize=c),c.noConflict=function(){return t.humanize=e,this},c.pad=function(t,e,n,r){if(t+="",n?1<n.length&&(n=n.charAt(0)):n=" ","right"===(r=r===undefined?"left":"right"))for(;t.length<e;)t+=n;else for(;t.length<e;)t=n+t;return t},c.time=function(){return(new Date).getTime()/1e3};var u=[0,0,31,59,90,120,151,181,212,243,273,304,334],l=[0,0,31,60,91,121,152,182,213,244,274,305,335];c.date=function(t,e){var r=e===undefined?new Date:e instanceof Date?new Date(e):new Date(1e3*e),n=/\\?([a-z])/gi,i=function(t,e){return a[t]?a[t]():e},o=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],s=["January","February","March","April","May","June","July","August","September","October","November","December"],a={d:function(){return c.pad(a.j(),2,"0")},D:function(){return a.l().slice(0,3)},j:function(){return r.getDate()},l:function(){return o[a.w()]},N:function(){return a.w()||7},S:function(){var t=a.j();return 4<t&&t<21?"th":{1:"st",2:"nd",3:"rd"}[t%10]||"th"},w:function(){return r.getDay()},z:function(){return(a.L()?l[a.n()]:u[a.n()])+a.j()-1},W:function(){var t=a.z()-a.N()+1.5;return c.pad(1+Math.floor(Math.abs(t)/7)+(3.5<t%7?1:0),2,"0")},F:function(){return s[r.getMonth()]},m:function(){return c.pad(a.n(),2,"0")},M:function(){return a.F().slice(0,3)},n:function(){return r.getMonth()+1},t:function(){return new Date(a.Y(),a.n(),0).getDate()},L:function(){return 1===new Date(a.Y(),1,29).getMonth()?1:0},o:function(){var t=a.n(),e=a.W();return a.Y()+(12===t&&e<9?-1:1===t&&9<e)},Y:function(){return r.getFullYear()},y:function(){return String(a.Y()).slice(-2)},a:function(){return 11<r.getHours()?"pm":"am"},A:function(){return a.a().toUpperCase()},B:function(){var t=r.getTime()/1e3,e=t%86400+3600;e<0&&(e+=86400);var n=e/86.4%1e3;return t<0?Math.ceil(n):Math.floor(n)},g:function(){return a.G()%12||12},G:function(){return r.getHours()},h:function(){return c.pad(a.g(),2,"0")},H:function(){return c.pad(a.G(),2,"0")},i:function(){return c.pad(r.getMinutes(),2,"0")},s:function(){return c.pad(r.getSeconds(),2,"0")},u:function(){return c.pad(1e3*r.getMilliseconds(),6,"0")},O:function(){var t=r.getTimezoneOffset(),e=Math.abs(t);return(0<t?"-":"+")+c.pad(100*Math.floor(e/60)+e%60,4,"0")},P:function(){var t=a.O();return t.substr(0,3)+":"+t.substr(3,2)},Z:function(){return 60*-r.getTimezoneOffset()},c:function(){return"Y-m-d\\TH:i:sP".replace(n,i)},r:function(){return"D, d M Y H:i:s O".replace(n,i)},U:function(){return r.getTime()/1e3||0}};return t.replace(n,i)},c.numberFormat=function(t,e,n,r){e=isNaN(e)?2:Math.abs(e),n=n===undefined?".":n,r=r===undefined?",":r;var i=t<0?"-":"";t=Math.abs(+t||0)
|
29
|
+
;var o=parseInt(t.toFixed(e),10)+"",s=3<o.length?o.length%3:0;return i+(s?o.substr(0,s)+r:"")+o.substr(s).replace(/(\d{3})(?=\d)/g,"$1"+r)+(e?n+Math.abs(t-o).toFixed(e).slice(2):"")},c.naturalDay=function(t,e){t=t===undefined?c.time():t,e=e===undefined?"Y-m-d":e;var n=86400,r=new Date,i=new Date(r.getFullYear(),r.getMonth(),r.getDate()).getTime()/1e3;return t<i&&i-n<=t?"yesterday":i<=t&&t<i+n?"today":i+n<=t&&t<i+2*n?"tomorrow":c.date(e,t)},c.relativeTime=function(t){t=t===undefined?c.time():t;var e=c.time(),n=e-t;if(n<2&&-2<n)return(0<=n?"just ":"")+"now";if(n<60&&-60<n)return 0<=n?Math.floor(n)+" seconds ago":"in "+Math.floor(-n)+" seconds";if(n<120&&-120<n)return 0<=n?"about a minute ago":"in about a minute";if(n<3600&&-3600<n)return 0<=n?Math.floor(n/60)+" minutes ago":"in "+Math.floor(-n/60)+" minutes";if(n<7200&&-7200<n)return 0<=n?"about an hour ago":"in about an hour";if(n<86400&&-86400<n)return 0<=n?Math.floor(n/3600)+" hours ago":"in "+Math.floor(-n/3600)+" hours";var r=172800;if(n<r&&-r<n)return 0<=n?"1 day ago":"in 1 day";var i=2505600;if(n<i&&-i<n)return 0<=n?Math.floor(n/86400)+" days ago":"in "+Math.floor(-n/86400)+" days";var o=5184e3;if(n<o&&-o<n)return 0<=n?"about a month ago":"in about a month";var s=parseInt(c.date("Y",e),10),a=parseInt(c.date("Y",t),10),u=12*s+parseInt(c.date("n",e),10)-(12*a+parseInt(c.date("n",t),10));if(u<12&&-12<u)return 0<=u?u+" months ago":"in "+-u+" months";var l=s-a;return l<2&&-2<l?0<=l?"a year ago":"in a year":0<=l?l+" years ago":"in "+-l+" years"},c.ordinal=function(t){t=parseInt(t,10);var e=(t=isNaN(t)?0:t)<0?"-":"",n=(t=Math.abs(t))%100;return e+t+(4<n&&n<21?"th":{1:"st",2:"nd",3:"rd"}[t%10]||"th")},c.filesize=function(t,e,n,r,i){if(e=e===undefined?1024:e,n=isNaN(n)?2:Math.abs(n),r=r===undefined?".":r,i=i===undefined?",":i,t<=0)return"0 bytes";var o=[1],s=["bytes","Kb","Mb","Gb","Tb","Pb"];if(t<e)return c.numberFormat(t,0)+" "+s[0];for(var a=1;a<s.length;a++)if(o[a]=o[a-1]*e,t<o[a])return c.numberFormat(t/o[a-1],n,r,i)+" "+s[a-1];return c.numberFormat(t/o[s.length-1],n,r,i)+" "+s[s.length-1]},c.linebreaks=function(t){return"<p>"+(t=(t=(t=(t=(t=t.replace(/^([\n|\r]*)/,"")).replace(/([\n|\r]*)$/,"")).replace(/(\r\n|\n|\r)/g,"\n")).replace(/(\n{2,})/g,"</p><p>")).replace(/\n/g,"<br />"))+"</p>"},c.nl2br=function(t){return t.replace(/(\r\n|\n|\r)/g,"<br />")},c.truncatechars=function(t,e){return t.length<=e?t:t.substr(0,e)+"\u2026"},c.truncatewords=function(t,e){var n=t.split(" ");return n.length<e?t:n.slice(0,e).join(" ")+"\u2026"}}.call(this),function(){this.JST||(this.JST={}),this.JST.cluster=function(t){t||(t={});var s=[],a=function(t){return t&&t.ecoSafe?t:void 0!==t&&null!=t?n(t):""},e=t.safe,n=t.escape;return t.safe=function(t){if(t&&t.ecoSafe)return t;void 0!==t&&null!=t||(t="");var e=new String(t);return e.ecoSafe=!0,e},n||(n=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,n,r,i,o;for(s.push("<h3 align=center> "),s.push(a(this.model.get("name"))),s.push(' </h3>\n\n<ul class="pager fixed">\n '),this.prevCluster?(s.push('\n <li class="previous nosel"><a class="nextPrevButton" href="'),s.push(a(null!=(r=this.prevCluster)?r.get("routeURL"):void 0)),s.push('">← Prev</a></li>\n ')):s.push('\n <li class="previous disabled nosel"><a>← Prev</a></li>\n '),s.push("\n\n "),this.nextCluster?(s.push('\n <li class="next nosel"><a class="nextPrevButton" href="'),s.push(a(null!=(i=this.nextCluster)?i.get("routeURL"):void 0)),s.push('">Next →</a></li>\n ')):s.push('\n <li class="next disabled nosel"><a>Next →</a></li>\n '),s.push('\n </li>\n</ul>\n\n\n</br>\n<table class="table table-striped table-bordered">\n <tr>\n <th>Client Connections</th>\n <th>Client EOF</th>\n <th>Client Errors</th>\n <th>Forward Errors</th>\n <th>Fragments</th>\n <th>Server Ejects</th>\n </tr>\n <tr>\n <td>'),s.push(a(this.model.get("client_connections"))),s.push("</td>\n <td>"),s.push(a(this.model.get("client_eof"))),s.push("</td>\n <td>"),s.push(a(this.model.get("client_err"))),s.push("</td>\n <td>"),s.push(a(this.model.get("forward_error"))),s.push("</td>\n <td>"),s.push(a(this.model.get("fragments"))),s.push("</td>\n <td>"),s.push(a(this.model.get("server_ejects"))),s.push('</td>\n </tr>\n\n</table>\n\n</br>\n<div class="chartsBox">\n <div class="row">\n <div class="span5">\n <div id="chart1" style="padding-left: 23%"></div>\n </div>\n <div class="span5">\n <div id="chart2" style="padding-left: 40%"></div>\n </div>\n </div>\n</div>\n\n\n</br>\n<table class="table table-striped table-bordered">\n <thead>\n <tr>\n <th>Host</th>\n <th>Free Memory</th>\n <th>Used Memory</th>\n <th>Used Memory RSS</th>\n <th>Max Memory</th>\n <th>Fragmentation</th>\n </tr>\n </thead>\n <tbody>\n '),t=0,e=(o=this.model.get("nodes").models).length;t<e;t++)n=o[t],s.push('\n <tr>\n <td><a href="'),s.push(a(n.get("routeURL"))),s.push('">'),s.push(a(n.get("hostname"))),s.push("</a></td>\n <td>"),s.push(a(humanize.filesize(n.get("freeMemory")))),s.push("</td>\n <td>"),s.push(a(humanize.filesize(n.get("usedMemory")))),s.push("</td>\n <td>"),s.push(a(humanize.filesize(n.get("usedMemoryRss")))),s.push("</td>\n <td>"),s.push(a(humanize.filesize(n.get("maxMemory")))),s.push("</td>\n <td>"),s.push(a(n.get("fragmentation"))),s.push("</td>\n </tr>\n ");s.push("\n <tr>\n <td> </td>\n <td>"),s.push(a(humanize.filesize(_(this.model.get("nodes").pluck("freeMemory")).sum()))),s.push("</td>\n <td>"),s.push(a(humanize.filesize(_(this.model.get("nodes").pluck("usedMemory")).sum()))),s.push("</td>\n <td>"),s.push(a(humanize.filesize(_(this.model.get("nodes").pluck("usedMemoryRss")).sum()))),s.push("</td>\n <td>"),s.push(a(humanize.filesize(_(this.model.get("nodes").pluck("maxMemory")).sum()))),s.push("</td>\n <td>~"),s.push(a(humanize.numberFormat(_(this.model.get("nodes").pluck("fragmentation")).average(),2))),s.push("</td>\n </tr>\n </tbody>\n</table>\n")}).call(this)}.call(t),t.safe=e,t.escape=n,s.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.config=function(t){t||(t={});var u=[],l=function(t){return t&&t.ecoSafe?t:void 0!==t&&null!=t?n(t):""},e=t.safe,n=t.escape;return t.safe=function(t){if(t&&t.ecoSafe)return t;void 0!==t&&null!=t||(t="");var e=new String(t);return e.ecoSafe=!0,e},n||(n=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,n,r,i,o,s,a;for(u.push("\n<h3> Clusters </h3>\n<br/>\n"),n=0,i=(s=_(this.model.get("config")).map(function(t,e){return[e,t]})).length;n<i;n++){for(e=s[n],u.push('\n <table class="table table-striped table-bordered">\n <tr><th>Name</th><td>'),u.push("<a href="+Nutcracker.Models.Cluster.routeURL(e[0])+">"+e[0]+"</a>"),u.push("</td></tr>\n <tr><th>Servers</th><td>"),u.push(e[1].servers.map(function(t){return"<a href="+Nutcracker.Models.Node.routeURL(t)+">"+t+"</a>"}).join("<br/>")),u.push("</td></tr>\n "),r=0,o=(a=_(e[1]).map(function(t,e){return[e,t]})).length;r<o;r++)t=a[r],u.push("\n "),/servers/.test(t[0])||(u.push("\n <tr><th>"),u.push(l(t[0])),u.push("</th><td>"),u.push(l(t[1])),u.push("</td></tr>\n ")),u.push("\n ");u.push("\n </table>\n </br>\n")}u.push("\n")}).call(this)}.call(t),t.safe=e,t.escape=n,u.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.footer=function(t){t||(t={});var e=[],n=t.safe,r=t.escape;return t.safe=function(t){if(t&&t.ecoSafe)return t;void 0!==t&&null!=t||(t="");var e=new String(t);return e.ecoSafe=!0,e},r||(r=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){e.push('<div id="lastUpdate"></div>\n')}).call(this)}.call(t),t.safe=n,t.escape=r,e.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.navbar=function(t){t||(t={});var u=[],l=function(t){return t&&t.ecoSafe?t:void 0!==t&&null!=t?n(t):""},e=t.safe,n=t.escape;return t.safe=function(t){if(t&&t.ecoSafe)return t;void 0!==t&&null!=t||(t="");var e=new String(t);return e.ecoSafe=!0,e},n||(n=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,n,r,i,o,s,a;for(u.push('<div class="navbar">\n <div class="navbar-inner">\n <div class="container" style="font-size: 17px">\n <a class="btn btn-navbar" data-toggle="collapse" data-target=".navbar-responsive-collapse">\n <span class="icon-bar"></span>\n <span class="icon-bar"></span>\n <span class="icon-bar"></span>\n </a>\n <a class="brand" href="#" style="color: #ffffff;font-size: 25px">Nutcracker</a>\n <div class="nav-collapse collapse navbar-responsive-collapse">\n <ul class="nav">\n <li class="divider-vertical"></li>\n <li id="overview" ><a href="#/">Overview</a></li>\n <li class="divider-vertical"></li>\n <li id="config" ><a href="#/config">Config </a></li>\n <li class="divider-vertical"></li>\n <li id="clusters" class="dropdown">\n <a class="dropdown-toggle" id="drop4" style="padding-top: 10px;" role="button" data-toggle="dropdown" href="#">Clusters <b class="caret"></b></a>\n <ul id="menu1" class="dropdown-menu" role="menu" aria-labelledby="drop4">\n <li class=\'divider\'></li>\n '),e=0,r=(s=this.model.get("clusters").models).length;e<r;e++)t=s[e],u.push('\n <li role="presentation" style="font-size: 15px">\n <a role="menuitem" tabindex="-1" href="'),u.push(l(t.get("routeURL"))),u.push('">'),u.push(l(t.get("name"))),u.push("</a>\n </li>\n <li class='divider'></li>\n ");for(u.push('\n </ul>\n </li>\n\n <li class="divider-vertical"></li>\n <li id="nodes" class="dropdown">\n <a class="dropdown-toggle" id="drop5" style="padding-top: 10px;" role="button" data-toggle="dropdown" href="#">Nodes <b class="caret"></b></a>\n <ul id="menu1" class="dropdown-menu" role="menu" aria-labelledby="drop5">\n <li class=\'divider\'></li>\n '),n=0,i=(a=this.model.nodes().models).length;n<i;n++)o=a[n],u.push('\n <li role="presentation" style="font-size: 15px">\n <a role="menuitem" tabindex="-1" href="'),u.push(l(o.get("routeURL"))),u.push('">'),u.push(l(o.get("hostname"))),u.push("</a>\n </li>\n <li class='divider'></li>\n ");u.push('\n </ul>\n </li>\n\n <li class="divider-vertical"></li>\n </ul>\n\n <ul class="nav pull-right">\n <li class="divider-vertical"></li>\n <li id="auto-refresh-drop-down" class="dropdown">\n <a class="dropdown-toggle" id="auto-refresh-drop" style="padding-top: 10px;" role="button" data-toggle="dropdown" href="#">Auto Refresh </a>\n <ul id="auto-refresh-menu" class="dropdown-menu" role="menu" aria-labelledby="auto-refresh-drop">\n <li id="auto-refresh-value-30" role="presentation" style="font-size: 15px">\n <a class="auto-refresh-button" value="30" role="menuitem" tabindex="-1" href="">30 Seconds</a>\n </li>\n <li class=\'divider\'></li>\n <li id="auto-refresh-value-60" role="presentation" style="font-size: 15px">\n <a class="auto-refresh-button" value="60" role="menuitem" tabindex="-1" href="">60 Seconds</a>\n </li>\n <li class=\'divider\'></li>\n <li id="auto-refresh-value-300" role="presentation" style="font-size: 15px">\n <a class="auto-refresh-button" value="300" role="menuitem" tabindex="-1" href="">5 Minutes</a>\n </li>\n <li class=\'divider\'></li>\n <li id="auto-refresh-value-3600" role="presentation" style="font-size: 15px">\n <a class="auto-refresh-button" value="3600" role="menuitem" tabindex="-1" href="">1 Hour</a>\n </li>\n </ul>\n </li>\n <li class="divider-vertical"></li>\n </ul>\n\n \n </div><!-- /.nav-collapse -->\n </div>\n </div><!-- /navbar-inner -->\n</div><!-- /navbar -->\n')}).call(this)}.call(t),t.safe=e,t.escape=n,u.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.node=function(t){t||(t={});var s=[],a=function(t){return t&&t.ecoSafe?t:void 0!==t&&null!=t?n(t):""},e=t.safe,n=t.escape;return t.safe=function(t){if(t&&t.ecoSafe)return t;void 0!==t&&null!=t||(t="");var e=new String(t);return e.ecoSafe=!0,e},n||(n=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,n,r,i,o;for(s.push("<h3 align=center>"),s.push(a(this.model.get("hostname"))),s.push('</h3>\n\n<ul class="pager">\n '),this.prevNode?(s.push('\n <li class="previous nosel"><a class="nextPrevButton" href="'),s.push(a(null!=(r=this.prevNode)?r.get("routeURL"):void 0)),s.push('">← Prev</a></li>\n ')):s.push('\n <li class="previous disabled nosel"><a>← Prev</a></li>\n '),s.push("\n \n "),e=0,n=(i=this.model.get("clusters")).length;e<n;e++)t=i[e],s.push('\n <li class="nosel"><a class="nextPrevButton" href="'),s.push(a(t.get("routeURL"))),s.push('">'),s.push(a(t.get("name"))),s.push("</a></li>\n ");s.push("\n\n "),this.nextNode?(s.push('\n <li class="next nosel"><a class="nextPrevButton" href="'),s.push(a(null!=(o=this.nextNode)?o.get("routeURL"):void 0)),s.push('">Next →</a></li>\n ')):s.push('\n <li class="next disabled nosel"><a>Next →</a></li>\n '),s.push('\n </li>\n</ul>\n</br>\n<div class="chartsBox">\n <div class="row">\n <div class="span5">\n <div id="chart1" style="padding-left: 26%"></div>\n </div>\n <div class="span5">\n <div id="chart2" style="padding-left: 40%"></div>\n </div>\n </div>\n</div>\n\n<br/>\n<div class="row-fluid">\n <div class="span6">\n <h4> Cluster <-> Node Stats </h4>\n <table class="table table-striped table-bordered">\n <tr><th>In-Queue</th><td> '),s.push(a(this.model.get("in_queue"))),s.push("</td></tr>\n <tr><th>In-Queue Memory Size</th><td> "),s.push(a(humanize.filesize(this.model.get("in_queue_bytes")))),s.push("</td></tr>\n <tr><th>Out-Queue</th><td> "),s.push(a(this.model.get("out_queue"))),s.push("</td></tr>\n <tr><th>Out-Queue Memory Size</th><td> "),s.push(a(humanize.filesize(this.model.get("out_queue_bytes")))),s.push("</td></tr>\n <tr><th>Requests</th><td> "),s.push(a(this.model.get("requests"))),s.push("</td></tr>\n <tr><th>Requests Memory Size</th><td> "),s.push(a(humanize.filesize(this.model.get("request_bytes")))),s.push("</td></tr>\n <tr><th>Responses</th><td> "),s.push(a(this.model.get("responses"))),s.push("</td></tr>\n <tr><th>Responses Memory Size</th><td> "),s.push(a(humanize.filesize(this.model.get("response_bytes")))),s.push("</td></tr>\n <tr><th>Server Connections</th><td> "),s.push(a(this.model.get("server_connections"))),s.push("</td></tr>\n <tr><th>Server EOF</th><td> "),s.push(a(this.model.get("server_eof"))),s.push("</td></tr>\n <tr><th>Server Error</th><td> "),s.push(a(this.model.get("server_err"))),s.push("</td></tr>\n <tr><th>Server Timedout</th><td> "),s.push(a(this.model.get("server_timedout"))),s.push('</td></tr>\n </table>\n </div>\n\n <div class="span6">\n <h4>Node Stats</h3>\n <table class="table table-striped table-bordered">\n <tr><th>Hits</th><td> '),s.push(a(humanize.numberFormat(this.model.get("info").hits,0))),s.push("</td></tr>\n <tr><th>Misses</th><td> "),s.push(a(humanize.numberFormat(this.model.get("info").misses,0))),s.push("</td></tr>\n <tr><th>Hit Ratio</th><td> "),s.push(a(humanize.numberFormat(this.model.get("info").hit_ratio,2))),s.push("</td></tr>\n <tr><th>Max Memory</th><td> "),s.push(a(humanize.filesize(this.model.get("info").max_memory))),s.push("</td></tr>\n <tr><th>Used Memory</th><td> "),s.push(a(humanize.filesize(this.model.get("info").used_memory))),s.push("</td></tr>\n <tr><th>Used Memory RSS</th><td> "),s.push(a(humanize.filesize(this.model.get("info").used_memory_rss))),s.push("</td></tr>\n <tr><th>Connections</th><td> "),s.push(a(this.model.get("info").connections)),s.push("</td></tr>\n <tr><th>Keys</th><td> "),s.push(a(humanize.numberFormat(this.model.get("info").keys,0))),s.push("</td></tr>\n <tr><th>Evicted Keys</th><td> "),s.push(a(humanize.numberFormat(this.model.get("info").evicted_keys,0))),s.push("</td></tr>\n <tr><th>Expired Keys</th><td> "),s.push(a(humanize.numberFormat(this.model.get("info").expired_keys,0))),s.push("</td></tr>\n <tr><th>Fragmentation</th><td> "),s.push(a(humanize.numberFormat(this.model.get("info").fragmentation,2))),s.push("</td></tr>\n <tr><th> </th><td> </td></tr>\n </table>\n </div>\n\n</div>\n\n\n")}).call(this)}.call(t),t.safe=e,t.escape=n,s.join("")}}.call(this),function(){this.JST||(this.JST={}),this.JST.overview=function(t){t||(t={});var u=[],l=function(t){return t&&t.ecoSafe?t:void 0!==t&&null!=t?n(t):""},e=t.safe,n=t.escape;return t.safe=function(t){if(t&&t.ecoSafe)return t;void 0!==t&&null!=t||(t="");var e=new String(t);return e.ecoSafe=!0,e},n||(n=t.escape=function(t){return(""+t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}),function(){(function(){var t,e,n,r,i,o,s,a;for(u.push('<h3> Overview </h3>\n<br/>\n<table class="table table-striped table-bordered">\n <tbody>\n <tr><th>Hostname</th><td>'),u.push(l(this.model.get("source"))),u.push("</td></tr>\n <tr><th>Service</th><td>Nutcracker Ver. "),u.push(l(this.model.get("version"))),u.push("</td></tr>\n <tr><th>Uptime</th><td>"),u.push(l(humanize.relativeTime((new Date-1e3*this.model.get("uptime"))/1e3))),u.push("</td></tr>\n <tr><th>Server Connections</th><td>"),u.push(l(this.model.get("serverConnections"))),u.push("</td></tr>\n <tr><th>Client Connections</th><td>"),u.push(l(this.model.get("clientConnections"))),u.push("</td></tr>\n\n <tr>\n <th>Total Clusters</th>\n <td>\n "),e=0,r=(s=this.model.get("clusters").models).length;e<r;e++)t=s[e],u.push('\n <a href="'),u.push(l(t.get("routeURL"))),u.push('">'),u.push(l(t.get("name"))),u.push("</a><br/>\n ");for(u.push("\n </td>\n </tr>\n\n <tr>\n <th>Total Nodes</th>\n <td>\n "),n=0,i=(a=this.model.nodes().models).length;n<i;n++)o=a[n],u.push('\n <a href="'),u.push(l(o.get("routeURL"))),u.push('">'),u.push(l(o.get("hostname"))),u.push("</a><br/>\n ");u.push("\n </td>\n </tr>\n \n\n </tbody>\n</table>\n\n")}).call(this)}.call(t),t.safe=e,t.escape=n,u.join("")}}.call(this),function(){window.Nutcracker={Models:{},Collections:{},Views:{},Routers:{},Utils:{},reload:function(){return""===window.location.hash?Nutcracker.router.navigate("/",{trigger:!0}):Nutcracker.router.navigate(window.location.hash,{trigger:!0})},initialize:function(){var t;return t=new Nutcracker.Models.Overview($("#container").data("clusters")),Nutcracker.overview=t,Nutcracker.screen=new Nutcracker.Utils.RegionManager,Nutcracker.screen.navbar(new Nutcracker.Views.Navbar({model:t})),Nutcracker.screen.footer(new Nutcracker.Views.Footer({model:t})),Nutcracker.router=new Nutcracker.Routers.Overview,Backbone.history.start()}},$(document).ready(function(){return Nutcracker.initialize()})}.call(this),function(){var n=function(t,e){return function(){return t.apply(e,arguments)}},r=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Collections.Clusters=function(t){function e(){return this.initialize=n(this.initialize,this),e.__super__.constructor.apply(this,arguments)}return r(e,t),e.prototype.initialize=function(){return this.model=Nutcracker.Models.Cluster},e}(Backbone.Collection)}.call(this),function(){var e=function(t,e){return function(){return t.apply(e,arguments)}},r=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Collections.Nodes=function(t){function n(){return this.usedMemory=e(this.usedMemory,this),this.maxMemory=e(this.maxMemory,this),this.freeMemory=e(this.freeMemory,this),this.serverConnections=e(this.serverConnections,this),this.add=e(this.add,this),n.__super__.constructor.apply(this,arguments)}return r(n,t),n.prototype.initialize=function(){return this.model=Nutcracker.Models.Node},n.prototype.add=function(e){return this.any(function(t){return t.get("server_url")===e[0].server_url})||n.__super__.add.apply(this,arguments)},n.prototype.serverConnections=function(){return _(this.pluck("server_connections")).sum()},n.prototype.freeMemory=function(){return _(this.pluck("freeMemory")).sum()},n.prototype.maxMemory=function(){return _(this.pluck("maxMemory")).sum()},n.prototype.usedMemory=function(){return _(this.pluck("usedMemory")).sum()},n}(Backbone.Collection)}.call(this),function(){var n=function(t,e){return function(){return t.apply(e,arguments)}},r=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Models.Cluster=function(t){function e(){return this.set=n(this.set,this),e.__super__.constructor.apply(this,arguments)}return r(e,t),e.routeURL=function(t){return"#/clusters/"+t},e.prototype.initialize=function(){return this.set("routeURL",this.constructor.routeURL(this.get("name")))},e.prototype.set=function(t,e){var n,r;return null==t.nodes||t.nodes instanceof Nutcracker.Collections.Nodes||(t.nodes=new Nutcracker.Collections.Nodes(t.nodes)),null!=(n=t.nodes)&&n.map((r=this,function(t){return t.get("clusters").push(r),t.set("clusters",_(t.get("clusters")).uniq())})),Backbone.Model.prototype.set.call(this,t,e)},e}(Backbone.Model)}.call(this),function(){var n=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Models.Node=function(t){function e(){return e.__super__.constructor.apply(this,arguments)}return n(e,t),e.routeURL=function(t){return"#/nodes/"+t.split(":").slice(0,2).join(":")},e.prototype.initialize=function(){var t;return this.set("clusters",[]),this.set("hostname",null!=(t=this.get("server_url"))?t.replace(/redis:\/\//,""):void 0),this.set("maxMemory",this.get("info").max_memory),this.set("usedMemory",this.get("info").used_memory),this.set("freeMemory",this.get("info").max_memory-this.get("info").used_memory),this.set("usedMemoryRss",this.get("info").used_memory_rss),this.set("fragmentation",this.get("info").fragmentation),this.get("freeMemory")<0&&this.set("freeMemory",0),this.set("hits",this.get("info").hits),this.set("misses",this.get("info").misses),0===this.get("maxMemory")&&this.set("maxMemory",this.get("usedMemory")),0===this.get("hits")&&this.set("hits",1),this.set("routeURL",this.constructor.routeURL(this.get("hostname")))},e}(Backbone.Model)}.call(this),function(){var n=function(t,e){return function(){return t.apply(e,arguments)}},r=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Models.Overview=function(t){function e(){return this.postInit=n(this.postInit,this),this.clusters=n(this.clusters,this),this.fetch=n(this.fetch,this),this.nodes=n(this.nodes,this),this.initialize=n(this.initialize,this),e.__super__.constructor.apply(this,arguments)}return r(e,t),e.prototype.url="/overview.json",e.prototype.initialize=function(){return this.postInit()},e.prototype.nodes=function(){return new Backbone.Collection(_(this.get("clusters").pluck("nodes")).chain().pluck("models").flatten().uniq(!1,function(t){return t.get("hostname")}).value())},e.prototype.fetch=function(){return e.__super__.fetch.apply(this,arguments)&&this.postInit(),Nutcracker.reload()},e.prototype.clusters=function(){return this.get("clusters")},e.prototype.postInit=function(){var t,e,n,r,i;for(t=_(this.get("clusters").pluck("client_connections")).sum(),e=i=0,n=(r=this.get("clusters").pluck("nodes")).length;e<n;e++)i+=r[e].serverConnections();return this.set("serverConnections",i),this.set("clientConnections",t),this.set("initializeTime",new Date)},e.prototype.set=function(t,e){return null==t.clusters||t.clusters instanceof Nutcracker.Collections.Clusters||(t.clusters=new Nutcracker.Collections.Clusters(t.clusters)),Backbone.Model.prototype.set.call(this,t,e)},e}(Backbone.Model)}.call(this),function(){var n=function(t,e){return function(){return t.apply(e,arguments)}},r=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Routers.Overview=function(t){function e(){return this._show=n(this._show,this),this.showConfig=n(this.showConfig,this),this.showNode=n(this.showNode,this),this.showCluster=n(this.showCluster,this),this.showOverview=n(this.showOverview,this),e.__super__.constructor.apply(this,arguments)}return r(e,t),e.prototype.routes={"":"showOverview",config:"showConfig","clusters/:cluster":"showCluster","nodes/:node":"showNode"},e.prototype.initialize=function(){return this.showOverview()},e.prototype.showOverview=function(){return this._show(Nutcracker.Views.Overview)},e.prototype.showCluster=function(t){var e,n;return n=(e=Nutcracker.overview.clusters()).findWhere({name:t}),this._show(Nutcracker.Views.Cluster,{model:n,collection:e})},e.prototype.showNode=function(t){var e,n;return n=(e=Nutcracker.overview.nodes()).findWhere({hostname:t}),this._show(Nutcracker.Views.Node,{model:n,collection:e})},e.prototype.showConfig=function(){return this._show(Nutcracker.Views.Config)},e.prototype._show=function(t,e){return null==e&&(e={model:Nutcracker.overview}),Nutcracker.screen.body(new t(e))},e}(Backbone.Router)}.call(this),function(){var i=function(t,e){return function(){return t.apply(e,arguments)}};Nutcracker.Utils.RegionManager=function(){function t(t,e,n,r){this.navbarID=null!=t?t:"#navbar",this.bodyID=null!=e?e:"#container",this.footerID=null!=n?n:"#footer",this.current=null!=r?r:{},this._render=i(this._render,this),this.footer=i(this.footer,this),this.body=i(this.body,this),this.navbar=i(this.navbar,this)}return t.prototype.navbar=function(t){return this._render(this.navbarID,t)},t.prototype.body=function(t){return this._render(this.bodyID,t)},t.prototype.footer=function(t){return this._render(this.footerID,t)},t.prototype._render=function(t,e){var n;return $(t).html(e.render().el),null!=(n=this.current[t])&&n.remove,this.current[t]=e},t}()}.call(this),function(){_.prototype.sum=function(){return _.reduce(this._wrapped,function(t,e){return t+e},0)},_.prototype.average=function(){return this.sum()/parseFloat(this._wrapped.length)}}.call(this),function(){var e=function(t,e){return function(){return t.apply(e,arguments)}},n=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Backbone.GoogleChart=function(t){function i(){return this.listen=e(this.listen,this),this.render=e(this.render,this),this.id=e(this.id,this),this.onGoogleLoad=e(this.onGoogleLoad,this),i.__super__.constructor.apply(this,arguments)}return n(i,t),i.prototype.initialize=function(t){var i,e,o;return i=_.extend({},t),["el","id","attributes","className","tagName"].map(function(t){return delete i[t]}),google.load("visualization","1",{packages:["corechart"],callback:(e=this,function(){return e.onGoogleLoad("loaded")})}),this.onGoogleLoad((o=this,function(){var n,r;return o.google=google.visualization,i.dataTable instanceof Array&&(i.dataTable=o.google.arrayToDataTable(i.dataTable)),(i.beforeDraw||function(){})(o,i),(n=i.formatter)&&function(){r=[];for(var t=0,e=i.dataTable.getNumberOfRows()-1;0<=e?t<=e:e<=t;0<=e?t++:t--)r.push(t);return r}.apply(this).map(function(e){return n.columns.map(function(t){return i.dataTable.setFormattedValue(e,t,n.callback(i.dataTable.getValue(e,t)))})}),o.wrapper=new o.google.ChartWrapper(i),["ready","select","error"].map(o.listen)}))},i.prototype.onGoogleLoad=function(t){return"loaded"===t?(this.googleLoaded=!0,_(this.onGoogleLoadItems).map(function(t){return t()})):this.googleLoaded?t():(this.onGoogleLoadItems||(this.onGoogleLoadItems=[])).push(t)},i.watch=function(t,e){var n,r;if((i._list||(i._list={}))[t]=e,!i._watching)return i._watching=!0,r=10,(n=function(){return _(i._list).map(function(t,e){if($(e)[0])return t()||delete i._list[e]}),_(i._list).isEmpty()?i._watching=!1:setTimeout(n,r+=10)})()},i.prototype.id=function(){var t;return(null!=(t=this.el)?t.id:void 0)||this.randomID()},i.prototype.render=function(){var t;return this.onGoogleLoad((t=this,function(){return t.constructor.watch("#"+t.el.id,function(){return t.wrapper.draw(t.el.id)})})),this},i.prototype.listen=function(t){return this.google.events.addListener(this.wrapper,t,(e=this,function(){return e.trigger(t,e.wrapper.getChart())}));var e},i.prototype.randomID=function(){return _.uniqueId("gc_")},i}(Backbone.View)}.call(this),function(){var n=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Views.Cluster=function(t){function e(){return e.__super__.constructor.apply(this,arguments)}return n(e,t),e.prototype.template=JST.cluster,e.prototype.render=function(){var t,e,n,r;return this.curIndex=this.collection.indexOf(this.model),this.nextCluster=this.collection.at(this.curIndex+1),this.prevCluster=this.collection.at(this.curIndex-1),this.$el.html(this.template({model:this.model,nextCluster:this.nextCluster,prevCluster:this.prevCluster})),n={is3D:!0,titleTextStyle:{fontSize:17.5,color:"#333333"},width:300,height:300,sliceVisibilityThreshold:0,chartArea:{width:"100%",height:"80%"},legend:{position:"bottom"}},e=[["Node","Node"]],this.model.get("nodes").map(function(t){return e.push([t.get("hostname"),t.get("maxMemory")])}),(t=new Backbone.GoogleChart({formatter:{callback:humanize.filesize,columns:[1]},chartType:"PieChart",options:n,dataTable:e})).on("select",(r=this,function(t){return Nutcracker.router.navigate(r.model.get("nodes").at(t.getSelection()[0].row).get("routeURL"),{trigger:!0})})),this.$el.find("#chart2").html(t.render().el),this.$el.find("#chart1").html(new Backbone.GoogleChart({formatter:{callback:humanize.filesize,columns:[1]},chartType:"PieChart",options:n,dataTable:[["Memory","Memory"],["Free",this.model.get("nodes").freeMemory()],["Used",this.model.get("nodes").usedMemory()]]}).render().el),this},e}(Backbone.View)}.call(this),function(){var n=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Views.Config=function(t){function e(){return e.__super__.constructor.apply(this,arguments)}return n(e,t),e.prototype.template=JST.config,e.prototype.render=function(){return this.$el.html(this.template({model:this.model})),this},e}(Backbone.View)}.call(this),function(){var n=function(t,e){return function(){return t.apply(e,arguments)}},r=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Views.Footer=function(t){function e(){return this.render=n(this.render,this),e.__super__.constructor.apply(this,arguments)}return r(e,t),e.prototype.className="container navbar navbar-fixed-bottom navbar-inverse",e.prototype.template=JST.footer,e.prototype.render=function(){return this.$el.html(this.template({model:this.model})),this.$el.find("#lastUpdate").html("Last updated: "+humanize.relativeTime(this.model.get("initializeTime")/1e3)),setTimeout(this.render,1e3),this},e}(Backbone.View)}.call(
|
30
|
+
this),function(){var n=function(t,e){return function(){return t.apply(e,arguments)}},r=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Views.Navbar=function(t){function e(){return this.render=n(this.render,this),this.activate=n(this.activate,this),this.autoRefresh=n(this.autoRefresh,this),this.resetButtons=n(this.resetButtons,this),this.initialize=n(this.initialize,this),e.__super__.constructor.apply(this,arguments)}return r(e,t),e.prototype.className="navbar navbar-inverse navbar-fixed-top",e.prototype.template=JST.navbar,e.prototype.events={"click .auto-refresh-button":"autoRefresh"},e.prototype.initialize=function(){return Backbone.history.bind("all",this.resetButtons),this.listenTo(this.model,"change",this.render),this.autoRefreshInterval=null},e.prototype.resetButtons=function(){var t;return this.$el.find("li").removeClass("active"),this.autoRefreshInterval?(this.$("#auto-refresh-drop-down").addClass("active"),this.$("#auto-refresh-value-"+this.autoRefreshInterval).addClass("active")):(this.$("#auto-refresh-drop-down").removeClass("active"),this.$("#auto-refresh-drop-down").find(".active").removeClass("active")),t=window.location.href,/#\/config$/.test(t)?this.activate("#config"):/#\/clusters\//.test(t)?this.activate("#clusters"):/#\/nodes\//.test(t)?this.activate("#nodes"):this.activate("#overview")},e.prototype.autoRefresh=function(t){var e,n;return e=parseInt($(t.currentTarget).attr("value")),this.autoRefreshTimer&&clearInterval(this.autoRefreshTimer),e===this.autoRefreshInterval?this.autoRefreshInterval=null:(this.autoRefreshInterval=e,this.autoRefreshTimer=setInterval((n=this,function(){return n.model.fetch()}),1e3*this.autoRefreshInterval)),this.resetButtons(),t.preventDefault()},e.prototype.activate=function(t){return this.$(t).addClass("active")},e.prototype.render=function(){return this.$el.html(this.template({model:this.model})),this.resetButtons(),this},e}(Backbone.View)}.call(this),function(){var n=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Views.Node=function(t){function e(){return e.__super__.constructor.apply(this,arguments)}return n(e,t),e.prototype.template=JST.node,e.prototype.render=function(){var t;return this.curIndex=this.collection.indexOf(this.model),this.nextNode=this.collection.at(this.curIndex+1),this.prevNode=this.collection.at(this.curIndex-1),t={is3D:!0,titleTextStyle:{fontSize:17.5,color:"#333333"},titleTextStyle:{fontSize:17.5,color:"#333333"},width:300,height:300,sliceVisibilityThreshold:0,chartArea:{width:"100%",height:"80%"},legend:{position:"bottom"}},this.$el.html(this.template({model:this.model,nextNode:this.nextNode,prevNode:this.prevNode})),this.$el.find("#chart1").append(new Backbone.GoogleChart({chartType:"PieChart",formatter:{callback:humanize.filesize,columns:[1]},options:_({title:"Memory"}).extend(t),dataTable:[["Memory","Memory"],["Free",this.model.get("freeMemory")],["Used",this.model.get("usedMemory")]]}).render().el),this.$el.find("#chart2").append(new Backbone.GoogleChart({formatter:{callback:humanize.numberFormat,columns:[1]},chartType:"PieChart",options:_({title:"Hits"}).extend(t),dataTable:[["Memory","Memory"],["Hits",this.model.get("hits")],["Misses",this.model.get("misses")]]}).render().el),this},e}(Backbone.View)}.call(this),function(){var n=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;Nutcracker.Views.Overview=function(t){function e(){return e.__super__.constructor.apply(this,arguments)}return n(e,t),e.prototype.template=JST.overview,e.prototype.render=function(){return this.$el.html(this.template({model:this.model})),this},e}(Backbone.View)}.call(this);
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nutcracker-web
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.15
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eran Barak Levi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-12-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: minitest
|
@@ -42,30 +42,30 @@ dependencies:
|
|
42
42
|
name: nutcracker
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 0.4.1.
|
47
|
+
version: 0.4.1.23
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - "
|
52
|
+
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 0.4.1.
|
54
|
+
version: 0.4.1.23
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: rack
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - ">="
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
61
|
+
version: 2.0.6
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
68
|
+
version: 2.0.6
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: haml
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -144,7 +144,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
144
144
|
version: '0'
|
145
145
|
requirements: []
|
146
146
|
rubyforge_project: ruby-nutcracker-web
|
147
|
-
rubygems_version: 2.6.
|
147
|
+
rubygems_version: 2.6.12
|
148
148
|
signing_key:
|
149
149
|
specification_version: 4
|
150
150
|
summary: Nutcracker Web Interface
|