diff --git a/target/1.bundle.js b/target/1.bundle.js index 3ec85b9..33e7a98 100644 --- a/target/1.bundle.js +++ b/target/1.bundle.js @@ -1,4 +1,4 @@ -webpackJsonp([1],[,,,,,,,,function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}var o=n(9),i=r(o),a=n(10),u=r(a),s=n(20),l=r(s),c=n(21),f=r(c),d=n(1),p=r(d),h=n(11),g=r(h),v=n(16),m=r(v);n(36).polyfill(),n(40),(0,m["default"])(document).on("touchmove",function(e){return e.preventDefault()}),(0,m["default"])(window).on("unload beforeunload",function(){u["default"].trigger("exitApp",null,!0)});var y=["images/jewel.svg"],b=[];b.push(g["default"].setup()),b.push(l["default"].loadImages(y).then(function(){return console.log("images loaded")})),Promise.all(b).then(function(){var e=(0,m["default"])("#splash-screen");e.click(function(){e.hide(),null==i["default"].getSelectedDeck()?f["default"].navigateTo("settings"):f["default"].navigateTo("main-menu")}),e.find(".continue").removeClass("hidden"),p["default"].stop()})},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function o(){var e=_.filter(function(e){var t=D.find(function(t){return t.uid===e.uid});return t&&t.version>(e.version||0)});if(0===_.length)console.log("No decks stored locally");else{if(0!==e.length)return console.log("Updating decks..."),Promise.all(e.map(function(e){return m(e.uid).then(function(t){d(e,t),console.log('Deck "'+e.displayName+'" up-to-date')})["catch"](function(){return console.error('Failed to update deck "'+e.displayName+'"')})})).then(function(){console.log("Finished updating decks")});console.log("All "+_.length+" decks are up-to-date.")}return Promise.resolve()}function i(e){if(console.log("selectDeck("+e+")"),!L)throw Error("A deck cannot be selected before all decks are up-to-date.");if(e!==M){var t=u(e);if(null===t)throw"Unknown deck ("+e+") cannot be selected";M=e,w["default"].store(A.SELECTED_DECK,e),b["default"].trigger("deckSelected",{deck:_[t]})}}function a(){var e=u(M);return null===e?null:S["default"].copyData(_[e])}function u(e){for(var t=0;t<_.length;t++)if(_[t].id===e)return t;return null}function s(e){return _.filter(e)[0]}function l(e){return new Promise(function(t,n){if("string"==typeof e){var r=D.find(function(t){return t.uid===e});r?t(m(r.uid)):n(Error('Deck "'+e+'" not found.'))}else t(e)}).then(function(e){return w["default"].transaction(function(){var t=p(g(),e),n=e.cards.map(function(e,t){return new C["default"](t,e[0],e[1])});return _.push(t),w["default"].store(A.DECKS,_),c(n,t.id),S["default"].copyData(t)})})}function c(e,t){var n=e.map(function(e){return e.serialize()});t=void 0===t?M:t,w["default"].store(A.DECK_PREFIX+t,n)}function f(e){return w["default"].load(A.DECK_PREFIX+e).map(function(e,t){return C["default"].unserialize(t,e)})}function d(e,t){w["default"].transaction(function(){var n=h(e);_=_.map(function(n){return n.id===e.id?p(e.id,t):n}),w["default"].store(A.DECKS,_);var r=t.cards.map(function(e,t){var r=e[0],o=e[1];return r in n&&o in n[r]?C["default"].unserialize(t,n[r][o]):new C["default"](t,r,o)});c(r,e.id)})}function p(e,t){return{id:e,uid:t.uid,version:t.version,displayName:t.displayName,languageFront:t.languageFront,languageBack:t.languageBack,size:t.cards.length}}function h(e){var t={};return f(e.id).forEach(function(e){e.front in t||(t[e.front]={}),t[e.front][e.back]=e.serialize()}),t}function g(){for(var e=-1,t=0;t<_.length;t++)_[t].id>e&&(e=_[t].id);return e+1}function v(){return D.map(function(e){return{uid:e.uid,displayName:e.displayName}})}function m(e){return new Promise(function(t,n){E["default"].ajax({url:"./decks/"+e+".json",type:"GET",dataType:"json",cache:!1,success:t,error:n})})}Object.defineProperty(t,"__esModule",{value:!0});var y=n(10),b=r(y),x=n(11),w=r(x),T=n(15),S=r(T),k=n(12),C=r(k),N=n(16),E=r(N),A={DECK_PREFIX:"deck.",SELECTED_DECK:"selectedDeck",DECKS:"decks"},_=[],D=[n(17),n(18),n(19)],M=null,L=!1;!function(){D.sort(function(e,t){return e.displayName=0&&(r.splice(n,1),0==r.length&&t())}}(e[o]))}function i(e,t){if(e in l){var n=function(){var n=u(t);return{v:Promise.all(l[e].map(function(e){return a(e,n)}))}}();if("object"===("undefined"==typeof n?"undefined":s(n)))return n.v}return Promise.resolve()}function a(e,t){return Promise.resolve(e.call(null,JSON.parse(t)))}function u(e){return void 0===e?"null":JSON.stringify(e)}Object.defineProperty(t,"__esModule",{value:!0});var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e},l={},c={};t["default"]={bind:n,trigger:r,waitFor:o}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function o(){c();var e=a("modelVersion")||0;for(console.log("storage model v"+e);ec["default"].now()},o.prototype.suspend=function(e){this.suspendedUntil=e},t["default"]=o},function(e,t){"use strict";function n(){return Date.now()}function r(e){return new Date(e).toISOString().replace(/\.[\dZ]+/,"").replace("T"," ")}function o(e,t){t=t||0;var n=2*t+(t-1),r=e,o="";for(var a in i)if(i.hasOwnProperty(a)){var u=Math.floor(r/i[a]);""!==o?o+=":"+(10>u?"0":"")+u:u>0&&(o+=u),r-=u*i[a]}return o.lengthr))return t}function a(e){return e.splice(o(e.length),1)[0]}function u(e,t){function n(){e(),r()}function r(){o in d&&(d[o]=setTimeout(n,t()))}var o=f["default"].now();return d[o]=0,r(),o}function s(e){e in d&&(clearTimeout(d[e]),delete d[e])}function l(e){return void 0===e?void 0:JSON.parse(JSON.stringify(e))}Object.defineProperty(t,"__esModule",{value:!0});var c=n(13),f=r(c),d={};t["default"]={randomInt:o,weighedRandom:i,randomPop:a,setDynamicInterval:u,clearInterval:s,copyData:l}},function(e,t,n){var r,o;(function(e){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};/*! +webpackJsonp([1],[,,,,,,,,function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}n(9);var o=n(42),i=r(o),a=n(43),u=r(a),s=n(53),l=r(s),c=n(54),f=r(c),d=n(1),p=r(d),h=n(44),g=r(h),v=n(49),m=r(v);n(69).polyfill(),n(73),(0,m["default"])(document).on("touchmove",function(e){return e.preventDefault()}),(0,m["default"])(window).on("unload beforeunload",function(){u["default"].trigger("exitApp",null,!0)});var y=["images/jewel.svg"],b=[];b.push(g["default"].setup()),b.push(l["default"].loadImages(y).then(function(){return console.log("images loaded")})),Promise.all(b).then(function(){var e=(0,m["default"])("#splash-screen");e.click(function(){e.hide(),null==i["default"].getSelectedDeck()?f["default"].navigateTo("settings"):f["default"].navigateTo("main-menu")}),e.find(".continue").removeClass("hidden"),p["default"].stop()})},function(e,t,n){"use strict";n(10),e.exports=n(13).Array.find},function(e,t,n){"use strict";var r=n(11),o=n(29)(5),i="find",a=!0;i in[]&&Array(1)[i](function(){a=!1}),r(r.P+r.F*a,"Array",{find:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(41)(i)},function(e,t,n){"use strict";var r=n(12),o=n(13),i=n(14),a=n(24),u=n(27),s="prototype",l=function c(e,t,n){var l,f,d,p,h=e&c.F,g=e&c.G,v=e&c.S,m=e&c.P,y=e&c.B,b=g?r:v?r[t]||(r[t]={}):(r[t]||{})[s],x=g?o:o[t]||(o[t]={}),w=x[s]||(x[s]={});g&&(n=t);for(l in n)f=!h&&b&&void 0!==b[l],d=(f?b:n)[l],p=y&&f?u(d,r):m&&"function"==typeof d?u(Function.call,d):d,b&&a(b,l,d,e&c.U),x[l]!=d&&i(x,l,p),m&&w[l]!=d&&(w[l]=d)};r.core=o,l.F=1,l.G=2,l.S=4,l.P=8,l.B=16,l.W=32,l.U=64,l.R=128,e.exports=l},function(e,t){"use strict";var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t){"use strict";var n=e.exports={version:"2.3.0"};"number"==typeof __e&&(__e=n)},function(e,t,n){"use strict";var r=n(15),o=n(23);e.exports=n(19)?function(e,t,n){return r.f(e,t,o(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){"use strict";var r=n(16),o=n(18),i=n(22),a=Object.defineProperty;t.f=n(19)?Object.defineProperty:function(e,t,n){if(r(e),t=i(t,!0),r(n),o)try{return a(e,t,n)}catch(u){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){"use strict";var r=n(17);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};e.exports=function(e){return"object"===("undefined"==typeof e?"undefined":n(e))?null!==e:"function"==typeof e}},function(e,t,n){"use strict";e.exports=!n(19)&&!n(20)(function(){return 7!=Object.defineProperty(n(21)("div"),"a",{get:function(){return 7}}).a})},function(e,t,n){"use strict";e.exports=!n(20)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t){"use strict";e.exports=function(e){try{return!!e()}catch(t){return!0}}},function(e,t,n){"use strict";var r=n(17),o=n(12).document,i=r(o)&&r(o.createElement);e.exports=function(e){return i?o.createElement(e):{}}},function(e,t,n){"use strict";var r=n(17);e.exports=function(e,t){if(!r(e))return e;var n,o;if(t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;if("function"==typeof(n=e.valueOf)&&!r(o=n.call(e)))return o;if(!t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;throw TypeError("Can't convert object to primitive value")}},function(e,t){"use strict";e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,n){"use strict";var r=n(12),o=n(14),i=n(25),a=n(26)("src"),u="toString",s=Function[u],l=(""+s).split(u);n(13).inspectSource=function(e){return s.call(e)},(e.exports=function(e,t,n,u){var s="function"==typeof n;s&&(i(n,"name")||o(n,"name",t)),e[t]!==n&&(s&&(i(n,a)||o(n,a,e[t]?""+e[t]:l.join(String(t)))),e===r?e[t]=n:u?e[t]?e[t]=n:o(e,t,n):(delete e[t],o(e,t,n)))})(Function.prototype,u,function(){return"function"==typeof this&&this[a]||s.call(this)})},function(e,t){"use strict";var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t){"use strict";var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},function(e,t,n){"use strict";var r=n(28);e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}}},function(e,t){"use strict";e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){"use strict";var r=n(27),o=n(30),i=n(32),a=n(34),u=n(36);e.exports=function(e,t){var n=1==e,s=2==e,l=3==e,c=4==e,f=6==e,d=5==e||f,p=t||u;return function(t,u,h){for(var g,v,m=i(t),y=o(m),b=r(u,h,3),x=a(y.length),w=0,S=n?p(t,x):s?p(t,0):void 0;x>w;w++)if((d||w in y)&&(g=y[w],v=b(g,w,m),e))if(n)S[w]=v;else if(v)switch(e){case 3:return!0;case 5:return g;case 6:return w;case 2:S.push(g)}else if(c)return!1;return f?-1:l||c?c:S}}},function(e,t,n){"use strict";var r=n(31);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},function(e,t){"use strict";var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t,n){"use strict";var r=n(33);e.exports=function(e){return Object(r(e))}},function(e,t){"use strict";e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,n){"use strict";var r=n(35),o=Math.min;e.exports=function(e){return e>0?o(r(e),9007199254740991):0}},function(e,t){"use strict";var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?r:n)(e)}},function(e,t,n){"use strict";var r=n(37);e.exports=function(e,t){return new(r(e))(t)}},function(e,t,n){"use strict";var r=n(17),o=n(38),i=n(39)("species");e.exports=function(e){var t;return o(e)&&(t=e.constructor,"function"!=typeof t||t!==Array&&!o(t.prototype)||(t=void 0),r(t)&&(t=t[i],null===t&&(t=void 0))),void 0===t?Array:t}},function(e,t,n){"use strict";var r=n(31);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){"use strict";var r=n(40)("wks"),o=n(26),i=n(12).Symbol,a="function"==typeof i,u=e.exports=function(e){return r[e]||(r[e]=a&&i[e]||(a?i:o)("Symbol."+e))};u.store=r},function(e,t,n){"use strict";var r=n(12),o="__core-js_shared__",i=r[o]||(r[o]={});e.exports=function(e){return i[e]||(i[e]={})}},function(e,t,n){"use strict";var r=n(39)("unscopables"),o=Array.prototype;void 0==o[r]&&n(14)(o,r,{}),e.exports=function(e){o[r][e]=!0}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function o(){var e=A.filter(function(e){var t=M.find(function(t){return t.uid===e.uid});return t&&t.version>(e.version||0)});if(0===A.length)console.log("No decks stored locally");else{if(0!==e.length)return console.log("Updating decks..."),Promise.all(e.map(function(e){return m(e.uid).then(function(t){d(e,t),console.log('Deck "'+e.displayName+'" up-to-date')})["catch"](function(){return console.error('Failed to update deck "'+e.displayName+'"')})})).then(function(){console.log("Finished updating decks")});console.log("All "+A.length+" decks are up-to-date.")}return Promise.resolve()}function i(e){if(console.log("selectDeck("+e+")"),!O)throw Error("A deck cannot be selected before all decks are up-to-date.");if(e!==D){var t=u(e);if(null===t)throw"Unknown deck ("+e+") cannot be selected";D=e,w["default"].store(_.SELECTED_DECK,e),b["default"].trigger("deckSelected",{deck:A[t]})}}function a(){var e=u(D);return null===e?null:T["default"].copyData(A[e])}function u(e){for(var t=0;te&&(e=A[t].id);return e+1}function v(){return M.map(function(e){return{uid:e.uid,displayName:e.displayName}})}function m(e){return new Promise(function(t,n){C["default"].ajax({url:"./decks/"+e+".json",type:"GET",dataType:"json",cache:!1,success:t,error:n})})}Object.defineProperty(t,"__esModule",{value:!0});var y=n(43),b=r(y),x=n(44),w=r(x),S=n(48),T=r(S),k=n(45),E=r(k),N=n(49),C=r(N),_={DECK_PREFIX:"deck.",SELECTED_DECK:"selectedDeck",DECKS:"decks"},A=[],M=[n(50),n(51),n(52)],D=null,O=!1;!function(){M.sort(function(e,t){return e.displayName=0&&(r.splice(n,1),0==r.length&&t())}}(e[o]))}function i(e,t){if(e in l){var n=function(){var n=u(t);return{v:Promise.all(l[e].map(function(e){return a(e,n)}))}}();if("object"===("undefined"==typeof n?"undefined":s(n)))return n.v}return Promise.resolve()}function a(e,t){return Promise.resolve(e.call(null,JSON.parse(t)))}function u(e){return void 0===e?"null":JSON.stringify(e)}Object.defineProperty(t,"__esModule",{value:!0});var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e},l={},c={};t["default"]={bind:n,trigger:r,waitFor:o}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function o(){c();var e=a("modelVersion")||0;for(console.log("storage model v"+e);ef["default"].now()}},{key:"suspend",value:function(e){this.suspendedUntil=e}},{key:"toString",value:function(){return a(this.id,4)+" "+i(this.lastRep)+" "+i(this.nextRep)+" "+this.state+" "+(this.isMismatched?"T":"F")+" "+a(this.front,15)+" "+a(this.back,15)}}],[{key:"unserialize",value:function(t,n){return new e(t,n.ft,n.bk,n.lr,n.nr,n.ea,n.st,n.ms)}}]),e}();t["default"]=h},function(e,t){"use strict";function n(){return Date.now()}function r(e){return new Date(e).toISOString().replace(/\.[\dZ]+/,"").replace("T"," ")}function o(e,t){t=t||0;var n=2*t+(t-1),r=e,o="";for(var a in i)if(i.hasOwnProperty(a)){var u=Math.floor(r/i[a]);""!==o?o+=":"+(10>u?"0":"")+u:u>0&&(o+=u),r-=u*i[a]}return o.lengthr))return t}function a(e){return e.splice(o(e.length),1)[0]}function u(e,t){function n(){e(),r()}function r(){o in d&&(d[o]=setTimeout(n,t()))}var o=f["default"].now();return d[o]=0,r(),o}function s(e){e in d&&(clearTimeout(d[e]),delete d[e])}function l(e){return void 0===e?void 0:JSON.parse(JSON.stringify(e))}Object.defineProperty(t,"__esModule",{value:!0});var c=n(46),f=r(c),d={};t["default"]={randomInt:o,weighedRandom:i,randomPop:a,setDynamicInterval:u,clearInterval:s,copyData:l}},function(e,t,n){var r,o;(function(e){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};/*! * jQuery JavaScript Library v2.2.1 * http://jquery.com/ * @@ -11,7 +11,7 @@ webpackJsonp([1],[,,,,,,,,function(e,t,n){"use strict";function r(e){return e&&e * * Date: 2016-02-22T19:11Z */ -!function(t,r){"object"===n(e)&&"object"===n(e.exports)?e.exports=t.document?r(t,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return r(e)}:r(t)}("undefined"!=typeof window?window:void 0,function(i,a){function u(e){var t=!!e&&"length"in e&&e.length,n=ce.type(e);return"function"===n||ce.isWindow(e)?!1:"array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e}function s(e,t,n){if(ce.isFunction(t))return ce.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return ce.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(xe.test(t))return ce.filter(t,e,n);t=ce.filter(t,e)}return ce.grep(e,function(e){return oe.call(t,e)>-1!==n})}function l(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}function c(e){var t={};return ce.each(e.match(Ne)||[],function(e,n){t[n]=!0}),t}function f(){ee.removeEventListener("DOMContentLoaded",f),i.removeEventListener("load",f),ce.ready()}function d(){this.expando=ce.expando+d.uid++}function p(e,t,n){var r;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(Oe,"-$&").toLowerCase(),n=e.getAttribute(r),"string"==typeof n){try{n="true"===n?!0:"false"===n?!1:"null"===n?null:+n+""===n?+n:Le.test(n)?ce.parseJSON(n):n}catch(o){}Me.set(e,t,n)}else n=void 0;return n}function h(e,t,n,r){var o,i=1,a=20,u=r?function(){return r.cur()}:function(){return ce.css(e,t,"")},s=u(),l=n&&n[3]||(ce.cssNumber[t]?"":"px"),c=(ce.cssNumber[t]||"px"!==l&&+s)&&Ie.exec(ce.css(e,t));if(c&&c[3]!==l){l=l||c[3],n=n||[],c=+s||1;do i=i||".5",c/=i,ce.style(e,t,c+l);while(i!==(i=u()/s)&&1!==i&&--a)}return n&&(c=+c||+s||0,o=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=o)),o}function g(e,t){var n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[];return void 0===t||t&&ce.nodeName(e,t)?ce.merge([e],n):n}function v(e,t){for(var n=0,r=e.length;r>n;n++)De.set(e[n],"globalEval",!t||De.get(t[n],"globalEval"))}function m(e,t,n,r,o){for(var i,a,u,s,l,c,f=t.createDocumentFragment(),d=[],p=0,h=e.length;h>p;p++)if(i=e[p],i||0===i)if("object"===ce.type(i))ce.merge(d,i.nodeType?[i]:i);else if(Be.test(i)){for(a=a||f.appendChild(t.createElement("div")),u=(He.exec(i)||["",""])[1].toLowerCase(),s=We[u]||We._default,a.innerHTML=s[1]+ce.htmlPrefilter(i)+s[2],c=s[0];c--;)a=a.lastChild;ce.merge(d,a.childNodes),a=f.firstChild,a.textContent=""}else d.push(t.createTextNode(i));for(f.textContent="",p=0;i=d[p++];)if(r&&ce.inArray(i,r)>-1)o&&o.push(i);else if(l=ce.contains(i.ownerDocument,i),a=g(f.appendChild(i),"script"),l&&v(a),n)for(c=0;i=a[c++];)Fe.test(i.type||"")&&n.push(i);return f}function y(){return!0}function b(){return!1}function x(){try{return ee.activeElement}catch(e){}}function w(e,t,r,o,i,a){var u,s;if("object"===("undefined"==typeof t?"undefined":n(t))){"string"!=typeof r&&(o=o||r,r=void 0);for(s in t)w(e,s,r,o,t[s],a);return e}if(null==o&&null==i?(i=r,o=r=void 0):null==i&&("string"==typeof r?(i=o,o=void 0):(i=o,o=r,r=void 0)),i===!1)i=b;else if(!i)return e;return 1===a&&(u=i,i=function(e){return ce().off(e),u.apply(this,arguments)},i.guid=u.guid||(u.guid=ce.guid++)),e.each(function(){ce.event.add(this,t,i,o,r)})}function T(e,t){return ce.nodeName(e,"table")&&ce.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function S(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function k(e){var t=Ke.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function C(e,t){var n,r,o,i,a,u,s,l;if(1===t.nodeType){if(De.hasData(e)&&(i=De.access(e),a=De.set(t,i),l=i.events)){delete a.handle,a.events={};for(o in l)for(n=0,r=l[o].length;r>n;n++)ce.event.add(t,o,l[o][n])}Me.hasData(e)&&(u=Me.access(e),s=ce.extend({},u),Me.set(t,s))}}function N(e,t){var n=t.nodeName.toLowerCase();"input"===n&&qe.test(e.type)?t.checked=e.checked:"input"!==n&&"textarea"!==n||(t.defaultValue=e.defaultValue)}function E(e,t,n,r){t=ne.apply([],t);var o,i,a,u,s,l,c=0,f=e.length,d=f-1,p=t[0],h=ce.isFunction(p);if(h||f>1&&"string"==typeof p&&!se.checkClone&&Je.test(p))return e.each(function(o){var i=e.eq(o);h&&(t[0]=p.call(this,o,i.html())),E(i,t,n,r)});if(f&&(o=m(t,e[0].ownerDocument,!1,e,r),i=o.firstChild,1===o.childNodes.length&&(o=i),i||r)){for(a=ce.map(g(o,"script"),S),u=a.length;f>c;c++)s=o,c!==d&&(s=ce.clone(s,!0,!0),u&&ce.merge(a,g(s,"script"))),n.call(e[c],s,c);if(u)for(l=a[a.length-1].ownerDocument,ce.map(a,k),c=0;u>c;c++)s=a[c],Fe.test(s.type||"")&&!De.access(s,"globalEval")&&ce.contains(l,s)&&(s.src?ce._evalUrl&&ce._evalUrl(s.src):ce.globalEval(s.textContent.replace(Ve,"")))}return e}function A(e,t,n){for(var r,o=t?ce.filter(t,e):e,i=0;null!=(r=o[i]);i++)n||1!==r.nodeType||ce.cleanData(g(r)),r.parentNode&&(n&&ce.contains(r.ownerDocument,r)&&v(g(r,"script")),r.parentNode.removeChild(r));return e}function _(e,t){var n=ce(t.createElement(e)).appendTo(t.body),r=ce.css(n[0],"display");return n.detach(),r}function D(e){var t=ee,n=Qe[e];return n||(n=_(e,t),"none"!==n&&n||(Ye=(Ye||ce("