diff --git a/client/galaxy/scripts/layout/masthead.js b/client/galaxy/scripts/layout/masthead.js index c9e29be9228..ccc16b53fc6 100644 --- a/client/galaxy/scripts/layout/masthead.js +++ b/client/galaxy/scripts/layout/masthead.js @@ -29,7 +29,6 @@ var View = Backbone.View.extend({ // scratchbook Galaxy.frame = this.frame = new Scratchbook( { collection: this.collection } ); - $( 'body' ).append( this.frame.$el ); // set up the quota meter (And fetch the current user data from trans) // add quota meter to masthead diff --git a/client/galaxy/scripts/layout/page.js b/client/galaxy/scripts/layout/page.js index 407f9285b63..f46fab847d5 100644 --- a/client/galaxy/scripts/layout/page.js +++ b/client/galaxy/scripts/layout/page.js @@ -33,6 +33,7 @@ var PageLayoutView = Backbone.View.extend( BaseMVC.LoggableMixin ).extend({ this.masthead = new Masthead.View( this.options.config ); this.$el.attr( 'scroll', 'no' ); this.$el.html( this._template() ); + this.$el.append( this.masthead.frame.$el ); this.$el.append( this.masthead.$el ); this.$el.append( this.modal.$el ); this.$messagebox = this.$( '#messagebox' ); diff --git a/lib/galaxy/webapps/galaxy/api/remote_files.py b/lib/galaxy/webapps/galaxy/api/remote_files.py index 2e1dc52010c..12118d3d0fa 100644 --- a/lib/galaxy/webapps/galaxy/api/remote_files.py +++ b/lib/galaxy/webapps/galaxy/api/remote_files.py @@ -6,7 +6,7 @@ import time import hashlib from galaxy import exceptions from galaxy.web import _future_expose_api as expose_api -from galaxy.util import jstree +from galaxy.util import jstree, unicodify from galaxy.web.base.controller import BaseAPIController from operator import itemgetter @@ -134,20 +134,18 @@ class RemoteFilesAPIController( BaseAPIController ): jstree_paths = [] if os.path.exists( directory ): for ( dirpath, dirnames, filenames ) in os.walk( directory ): - for dirname in dirnames: dir_path = os.path.relpath( os.path.join( dirpath, dirname ), directory ) - dir_path_hash = hashlib.sha1( dir_path.encode('utf-8') ).hexdigest() + dir_path_hash = hashlib.sha1(unicodify(dir_path).encode('utf-8')).hexdigest() disabled = True if disable == 'folders' else False jstree_paths.append( jstree.Path( dir_path, dir_path_hash, { 'type': 'folder', 'state': { 'disabled': disabled }, 'li_attr': { 'full_path': dir_path } } ) ) for filename in filenames: file_path = os.path.relpath( os.path.join( dirpath, filename ), directory ) - file_path_hash = hashlib.sha1( file_path.encode('utf-8') ).hexdigest() + file_path_hash = hashlib.sha1(unicodify(file_path).encode('utf-8')).hexdigest() disabled = True if disable == 'files' else False jstree_paths.append( jstree.Path( file_path, file_path_hash, { 'type': 'file', 'state': { 'disabled': disabled }, 'li_attr': { 'full_path': file_path } } ) ) else: raise exceptions.ConfigDoesNotAllowException( 'The given directory does not exist.' ) - userdir_jstree = jstree.JSTree( jstree_paths ) return userdir_jstree diff --git a/static/maps/layout/masthead.js.map b/static/maps/layout/masthead.js.map index ae0891de687..8da424b3465 100644 --- a/static/maps/layout/masthead.js.map +++ b/static/maps/layout/masthead.js.map @@ -1 +1 @@ -{"version":3,"file":"masthead.js","sources":["../../src/layout/masthead.js"],"names":["define","Utils","Menu","Scratchbook","QuotaMeter","View","Backbone","extend","initialize","options","self","this","setElement","_template","$navbarBrandLink","$","$navbarBrandImage","$navbarBrandTitle","$navbarTabs","$quoteMeter","collection","Collection","on","model","append","Tab","render","$el","empty","callback","each","m","fetch","Galaxy","frame","quotaMeter","UserQuotaMeter","user","el","window","e","$download_link","target","closest","length","attr","hide","preventDefault","text","q","get","html","brand","logo_url","logo_src"],"mappings":"AAAAA,QACI,cACA,cACA,qBACA,4BACD,SAAUC,EAAOC,EAAMC,EAAaC,GAGvC,GAAIC,GAAOC,SAASD,KAAKE,QACrBC,WAAa,SAAUC,GACnB,GAAIC,GAAOC,IACXA,MAAKF,QAAUA,EACfE,KAAKC,WAAYD,KAAKE,aACtBF,KAAKG,iBAAqBH,KAAKI,EAAG,sBAClCJ,KAAKK,kBAAqBL,KAAKI,EAAG,uBAClCJ,KAAKM,kBAAqBN,KAAKI,EAAG,uBAClCJ,KAAKO,YAAqBP,KAAKI,EAAG,gBAClCJ,KAAKQ,YAAqBR,KAAKI,EAAG,0BAGlCJ,KAAKS,WAAa,GAAIlB,GAAKmB,WAC3BV,KAAKS,WAAWE,GAAI,MAAO,SAAUC,GACjCb,EAAKQ,YAAYM,OAAQ,GAAItB,GAAKuB,KAAOF,MAAQA,IAAUG,SAASC,OACrEL,GAAI,QAAS,WACZZ,EAAKQ,YAAYU,UAClBN,GAAI,WAAY,SAAUO,GACzBnB,EAAKU,WAAWU,KAAM,SAAWC,GAAMF,EAAUE,OAClDC,MAAOrB,KAAKF,SAGfwB,OAAOC,MAAQvB,KAAKuB,MAAQ,GAAI/B,IAAeiB,WAAYT,KAAKS,aAChEL,EAAG,QAASS,OAAQb,KAAKuB,MAAMP,KAI/BM,OAAOE,WAAaxB,KAAKwB,WAAa,GAAI/B,GAAWgC,gBACjDb,MAAUU,OAAOI,KACjBC,GAAU3B,KAAKQ,cAInBJ,EAAGwB,QAASjB,GAAI,QAAS,SAAUkB,GAC/B,GAAIC,GAAiB1B,EAAGyB,EAAEE,QAASC,QAAS,cACd,IAAzBF,EAAeG,SAC0B,IAAtC7B,EAAG,uBAAwB6B,QAC3B7B,EAAG,QAASS,OAAQT,EAAG,aAAc8B,KAAM,KAAM,YAAaC,QAElE/B,EAAG,uBAAwB8B,KAAM,MAAOJ,EAAeI,KAAM,SAC7DL,EAAEO,oBAEPzB,GAAI,eAAgB,WACnB,GAAI0B,GAAO,EAKX,OAJAtC,GAAKU,WAAWU,KAAM,SAAUP,GAC5B,GAAI0B,GAAI1B,EAAM2B,IAAK,mBAAsB3B,EAAM2B,IAAK,mBACpDD,KAAOD,GAAQC,EAAI,OAET,KAATD,EACMA,EADX,UAMRtB,OAAQ,WAKJ,MAJAf,MAAKM,kBAAkBkC,KAAM,WAAcxC,KAAKF,QAAQ2C,OAAS,KAAOzC,KAAKF,QAAQ2C,OAAS,KAC9FzC,KAAKG,iBAAiB+B,KAAM,OAAQlC,KAAKF,QAAQ4C,UACjD1C,KAAKK,kBAAkB6B,KAAM,MAAOlC,KAAKF,QAAQ6C,UACjD3C,KAAKwB,WAAWT,SACTf,MAIXE,UAAW,WACP,MAAQ,2UAgBhB,QACIR,KAAMA"} \ No newline at end of file +{"version":3,"file":"masthead.js","sources":["../../src/layout/masthead.js"],"names":["define","Utils","Menu","Scratchbook","QuotaMeter","View","Backbone","extend","initialize","options","self","this","setElement","_template","$navbarBrandLink","$","$navbarBrandImage","$navbarBrandTitle","$navbarTabs","$quoteMeter","collection","Collection","on","model","append","Tab","render","$el","empty","callback","each","m","fetch","Galaxy","frame","quotaMeter","UserQuotaMeter","user","el","window","e","$download_link","target","closest","length","attr","hide","preventDefault","text","q","get","html","brand","logo_url","logo_src"],"mappings":"AAAAA,QACI,cACA,cACA,qBACA,4BACD,SAAUC,EAAOC,EAAMC,EAAaC,GAGvC,GAAIC,GAAOC,SAASD,KAAKE,QACrBC,WAAa,SAAUC,GACnB,GAAIC,GAAOC,IACXA,MAAKF,QAAUA,EACfE,KAAKC,WAAYD,KAAKE,aACtBF,KAAKG,iBAAqBH,KAAKI,EAAG,sBAClCJ,KAAKK,kBAAqBL,KAAKI,EAAG,uBAClCJ,KAAKM,kBAAqBN,KAAKI,EAAG,uBAClCJ,KAAKO,YAAqBP,KAAKI,EAAG,gBAClCJ,KAAKQ,YAAqBR,KAAKI,EAAG,0BAGlCJ,KAAKS,WAAa,GAAIlB,GAAKmB,WAC3BV,KAAKS,WAAWE,GAAI,MAAO,SAAUC,GACjCb,EAAKQ,YAAYM,OAAQ,GAAItB,GAAKuB,KAAOF,MAAQA,IAAUG,SAASC,OACrEL,GAAI,QAAS,WACZZ,EAAKQ,YAAYU,UAClBN,GAAI,WAAY,SAAUO,GACzBnB,EAAKU,WAAWU,KAAM,SAAWC,GAAMF,EAAUE,OAClDC,MAAOrB,KAAKF,SAGfwB,OAAOC,MAAQvB,KAAKuB,MAAQ,GAAI/B,IAAeiB,WAAYT,KAAKS,aAIhEa,OAAOE,WAAaxB,KAAKwB,WAAa,GAAI/B,GAAWgC,gBACjDb,MAAUU,OAAOI,KACjBC,GAAU3B,KAAKQ,cAInBJ,EAAGwB,QAASjB,GAAI,QAAS,SAAUkB,GAC/B,GAAIC,GAAiB1B,EAAGyB,EAAEE,QAASC,QAAS,cACd,IAAzBF,EAAeG,SAC0B,IAAtC7B,EAAG,uBAAwB6B,QAC3B7B,EAAG,QAASS,OAAQT,EAAG,aAAc8B,KAAM,KAAM,YAAaC,QAElE/B,EAAG,uBAAwB8B,KAAM,MAAOJ,EAAeI,KAAM,SAC7DL,EAAEO,oBAEPzB,GAAI,eAAgB,WACnB,GAAI0B,GAAO,EAKX,OAJAtC,GAAKU,WAAWU,KAAM,SAAUP,GAC5B,GAAI0B,GAAI1B,EAAM2B,IAAK,mBAAsB3B,EAAM2B,IAAK,mBACpDD,KAAOD,GAAQC,EAAI,OAET,KAATD,EACMA,EADX,UAMRtB,OAAQ,WAKJ,MAJAf,MAAKM,kBAAkBkC,KAAM,WAAcxC,KAAKF,QAAQ2C,OAAS,KAAOzC,KAAKF,QAAQ2C,OAAS,KAC9FzC,KAAKG,iBAAiB+B,KAAM,OAAQlC,KAAKF,QAAQ4C,UACjD1C,KAAKK,kBAAkB6B,KAAM,MAAOlC,KAAKF,QAAQ6C,UACjD3C,KAAKwB,WAAWT,SACTf,MAIXE,UAAW,WACP,MAAQ,2UAgBhB,QACIR,KAAMA"} \ No newline at end of file diff --git a/static/maps/layout/page.js.map b/static/maps/layout/page.js.map index cb7807dc9f5..d4536666846 100644 --- a/static/maps/layout/page.js.map +++ b/static/maps/layout/page.js.map @@ -1 +1 @@ -{"version":3,"file":"page.js","sources":["../../src/layout/page.js"],"names":["define","Masthead","Panel","Modal","BaseMVC","PageLayoutView","Backbone","View","extend","LoggableMixin","_logNamespace","el","className","_panelIds","defaultOptions","message_box_visible","message_box_content","message_box_class","show_inactivity_warning","inactivity_box_content","initialize","options","this","log","_","pick","defaults","omit","Galaxy","modal","masthead","config","$el","attr","html","_template","append","$messagebox","$","$inactivebox","render","remove","renderMessageBox","renderInactivityBox","renderPanels","content","level","addClass","toggle","show","removeClass","hide","verificationLink","root","text","page","forEach","panelId","has","setElement","left","center","css","right","join","hideSidePanels","toString"],"mappings":"AAAAA,QACI,kBACA,eACA,kBACA,gBACD,SAAUC,EAAUC,EAAOC,EAAOC,GAGrC,GAAIC,GAAiBC,SAASC,KAAKC,OAAQJ,EAAQK,eAAgBD,QAC/DE,cAAgB,SAEhBC,GAAK,OACLC,UAAY,eAEZC,WACI,OAAQ,SAAU,SAGtBC,gBACIC,qBAA0B,EAC1BC,oBAA0B,GAC1BC,kBAA0B,OAC1BC,yBAA0B,EAC1BC,uBAA0B,IAG9BC,WAAa,SAAUC,GAEnBC,KAAKC,IAAKD,KAAO,eAAgBD,GACjCG,EAAEhB,OAAQc,KAAME,EAAEC,KAAMJ,EAASC,KAAKT,YACtCS,KAAKD,QAAUG,EAAEE,SAAUF,EAAEG,KAAMN,EAASC,KAAKT,WAAaS,KAAKR,gBACnEc,OAAOC,MAAQP,KAAKO,MAAQ,GAAI1B,GAAMI,KACtCe,KAAKQ,SAAW,GAAI7B,GAASM,KAAMe,KAAKD,QAAQU,QAChDT,KAAKU,IAAIC,KAAM,SAAU,MACzBX,KAAKU,IAAIE,KAAMZ,KAAKa,aACpBb,KAAKU,IAAII,OAAQd,KAAKQ,SAASE,KAC/BV,KAAKU,IAAII,OAAQd,KAAKO,MAAMG,KAC5BV,KAAKe,YAAcf,KAAKgB,EAAG,eAC3BhB,KAAKiB,aAAejB,KAAKgB,EAAG,iBAGhCE,OAAS,WAQL,MANAF,GAAG,8BAA+BG,SAClCnB,KAAKC,IAAKD,KAAO,YACjBA,KAAKQ,SAASU,SACdlB,KAAKoB,mBACLpB,KAAKqB,sBACLrB,KAAKsB,eACEtB,MAIXoB,iBAAmB,WACf,GAAKpB,KAAKD,QAAQN,oBAAqB,CACnC,GAAI8B,GAAUvB,KAAKD,QAAQL,qBAAuB,GAC9C8B,EAAQxB,KAAKD,QAAQJ,mBAAqB,MAC9CK,MAAKU,IAAIe,SAAU,mBACnBzB,KAAKe,YACAJ,KAAM,QAAS,SAAWa,EAAQ,YAClCZ,KAAMW,GACNG,SAAUH,GACVI,WAEL3B,MAAKU,IAAIkB,YAAa,mBACtB5B,KAAKe,YAAYc,MAErB,OAAO7B,OAIXqB,oBAAsB,WAClB,GAAIrB,KAAKD,QAAQH,wBAAyB,CACtC,GAAI2B,GAAUvB,KAAKD,QAAQF,wBAA0B,GACjDiC,EAAmBd,EAAG,QAASL,KAAM,OAAQL,OAAOyB,KAAO,4BAA6BC,KAAM,sBAClGhC,MAAKU,IAAIe,SAAU,sBACnBzB,KAAKiB,aACAL,KAAMW,EAAU,KAChBT,OAAQgB,GACRJ,SAAUH,GACVI,WAEL3B,MAAKU,IAAIkB,YAAa,sBACtB5B,KAAKiB,aAAaY,MAEtB,OAAO7B,OAIXsB,aAAe,WACX,GAAIW,GAAOjC,IAaX,OAZAA,MAAKT,UAAU2C,QAAS,SAAUC,GAC1BjC,EAAEkC,IAAKH,EAAME,KACbF,EAAME,GAAUE,WAAY,IAAMF,GAClCF,EAAME,GAAUjB,YAGnBlB,KAAKsC,MACNtC,KAAKuC,OAAO7B,IAAI8B,IAAK,OAAQ,GAE5BxC,KAAKyC,OACNzC,KAAKuC,OAAO7B,IAAI8B,IAAK,QAAS,GAE3BxC,MAIXa,UAAW,WACP,OACI,wBACI,yBACA,yBACA,yDACAb,KAAKsC,KAAQ,oBAAsB,GACnCtC,KAAKuC,OAAQ,sCAAwC,GACrDvC,KAAKyC,MAAQ,qBAAuB,GACxC,SACA,0BACFC,KAAK,KAIXC,eAAiB,WACT3C,KAAKsC,MACLtC,KAAKsC,KAAKT,OAEV7B,KAAKyC,OACLzC,KAAKyC,MAAMZ,QAInBe,SAAW,WAAa,MAAO,mBAI/B,QACI7D,eAAgBA"} \ No newline at end of file +{"version":3,"file":"page.js","sources":["../../src/layout/page.js"],"names":["define","Masthead","Panel","Modal","BaseMVC","PageLayoutView","Backbone","View","extend","LoggableMixin","_logNamespace","el","className","_panelIds","defaultOptions","message_box_visible","message_box_content","message_box_class","show_inactivity_warning","inactivity_box_content","initialize","options","this","log","_","pick","defaults","omit","Galaxy","modal","masthead","config","$el","attr","html","_template","append","frame","$messagebox","$","$inactivebox","render","remove","renderMessageBox","renderInactivityBox","renderPanels","content","level","addClass","toggle","show","removeClass","hide","verificationLink","root","text","page","forEach","panelId","has","setElement","left","center","css","right","join","hideSidePanels","toString"],"mappings":"AAAAA,QACI,kBACA,eACA,kBACA,gBACD,SAAUC,EAAUC,EAAOC,EAAOC,GAGrC,GAAIC,GAAiBC,SAASC,KAAKC,OAAQJ,EAAQK,eAAgBD,QAC/DE,cAAgB,SAEhBC,GAAK,OACLC,UAAY,eAEZC,WACI,OAAQ,SAAU,SAGtBC,gBACIC,qBAA0B,EAC1BC,oBAA0B,GAC1BC,kBAA0B,OAC1BC,yBAA0B,EAC1BC,uBAA0B,IAG9BC,WAAa,SAAUC,GAEnBC,KAAKC,IAAKD,KAAO,eAAgBD,GACjCG,EAAEhB,OAAQc,KAAME,EAAEC,KAAMJ,EAASC,KAAKT,YACtCS,KAAKD,QAAUG,EAAEE,SAAUF,EAAEG,KAAMN,EAASC,KAAKT,WAAaS,KAAKR,gBACnEc,OAAOC,MAAQP,KAAKO,MAAQ,GAAI1B,GAAMI,KACtCe,KAAKQ,SAAW,GAAI7B,GAASM,KAAMe,KAAKD,QAAQU,QAChDT,KAAKU,IAAIC,KAAM,SAAU,MACzBX,KAAKU,IAAIE,KAAMZ,KAAKa,aACpBb,KAAKU,IAAII,OAAQd,KAAKQ,SAASO,MAAML,KACrCV,KAAKU,IAAII,OAAQd,KAAKQ,SAASE,KAC/BV,KAAKU,IAAII,OAAQd,KAAKO,MAAMG,KAC5BV,KAAKgB,YAAchB,KAAKiB,EAAG,eAC3BjB,KAAKkB,aAAelB,KAAKiB,EAAG,iBAGhCE,OAAS,WAQL,MANAF,GAAG,8BAA+BG,SAClCpB,KAAKC,IAAKD,KAAO,YACjBA,KAAKQ,SAASW,SACdnB,KAAKqB,mBACLrB,KAAKsB,sBACLtB,KAAKuB,eACEvB,MAIXqB,iBAAmB,WACf,GAAKrB,KAAKD,QAAQN,oBAAqB,CACnC,GAAI+B,GAAUxB,KAAKD,QAAQL,qBAAuB,GAC9C+B,EAAQzB,KAAKD,QAAQJ,mBAAqB,MAC9CK,MAAKU,IAAIgB,SAAU,mBACnB1B,KAAKgB,YACAL,KAAM,QAAS,SAAWc,EAAQ,YAClCb,KAAMY,GACNG,SAAUH,GACVI,WAEL5B,MAAKU,IAAImB,YAAa,mBACtB7B,KAAKgB,YAAYc,MAErB,OAAO9B,OAIXsB,oBAAsB,WAClB,GAAItB,KAAKD,QAAQH,wBAAyB,CACtC,GAAI4B,GAAUxB,KAAKD,QAAQF,wBAA0B,GACjDkC,EAAmBd,EAAG,QAASN,KAAM,OAAQL,OAAO0B,KAAO,4BAA6BC,KAAM,sBAClGjC,MAAKU,IAAIgB,SAAU,sBACnB1B,KAAKkB,aACAN,KAAMY,EAAU,KAChBV,OAAQiB,GACRJ,SAAUH,GACVI,WAEL5B,MAAKU,IAAImB,YAAa,sBACtB7B,KAAKkB,aAAaY,MAEtB,OAAO9B,OAIXuB,aAAe,WACX,GAAIW,GAAOlC,IAaX,OAZAA,MAAKT,UAAU4C,QAAS,SAAUC,GAC1BlC,EAAEmC,IAAKH,EAAME,KACbF,EAAME,GAAUE,WAAY,IAAMF,GAClCF,EAAME,GAAUjB,YAGnBnB,KAAKuC,MACNvC,KAAKwC,OAAO9B,IAAI+B,IAAK,OAAQ,GAE5BzC,KAAK0C,OACN1C,KAAKwC,OAAO9B,IAAI+B,IAAK,QAAS,GAE3BzC,MAIXa,UAAW,WACP,OACI,wBACI,yBACA,yBACA,yDACAb,KAAKuC,KAAQ,oBAAsB,GACnCvC,KAAKwC,OAAQ,sCAAwC,GACrDxC,KAAK0C,MAAQ,qBAAuB,GACxC,SACA,0BACFC,KAAK,KAIXC,eAAiB,WACT5C,KAAKuC,MACLvC,KAAKuC,KAAKT,OAEV9B,KAAK0C,OACL1C,KAAK0C,MAAMZ,QAInBe,SAAW,WAAa,MAAO,mBAI/B,QACI9D,eAAgBA"} \ No newline at end of file diff --git a/static/scripts/bundled/libs.bundled.js b/static/scripts/bundled/libs.bundled.js index cc3ec7bf1db..cffecb8156b 100644 --- a/static/scripts/bundled/libs.bundled.js +++ b/static/scripts/bundled/libs.bundled.js @@ -25,8 +25,8 @@ function(t){function e(t,e,i,n){var s,r,o,a,l,u,c,p,f,g;if((e?e.ownerDocument||e l=r=d.length;r--;)o=d[r],!s&&g!==o.origType||i&&i.guid!==o.guid||a&&!a.test(o.namespace)||n&&n!==o.selector&&("**"!==n||!o.selector)||(d.splice(r,1),o.selector&&d.delegateCount--,c.remove&&c.remove.call(t,o));l&&!d.length&&(c.teardown&&c.teardown.call(t,f,m.handle)!==!1||lt.removeEvent(t,p,m.handle),delete h[p])}else for(p in h)lt.event.remove(t,p+e[u],i,n,!0);lt.isEmptyObject(h)&&(delete m.handle,lt._removeData(t,"events"))}},trigger:function(t,e,n,s){var r,o,a,l,u,h,c,d=[n||yt],p=rt.call(t,"type")?t.type:t,f=rt.call(t,"namespace")?t.namespace.split("."):[];if(a=h=n=n||yt,3!==n.nodeType&&8!==n.nodeType&&!It.test(p+lt.event.triggered)&&(p.indexOf(".")>=0&&(f=p.split("."),p=f.shift(),f.sort()),o=p.indexOf(":")<0&&"on"+p,t=t[lt.expando]?t:new lt.Event(p,"object"==typeof t&&t),t.isTrigger=s?2:3,t.namespace=f.join("."),t.namespace_re=t.namespace?new RegExp("(^|\\.)"+f.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=n),e=null==e?[t]:lt.makeArray(e,[t]),u=lt.event.special[p]||{},s||!u.trigger||u.trigger.apply(n,e)!==!1)){if(!s&&!u.noBubble&&!lt.isWindow(n)){for(l=u.delegateType||p,It.test(l+p)||(a=a.parentNode);a;a=a.parentNode)d.push(a),h=a;h===(n.ownerDocument||yt)&&d.push(h.defaultView||h.parentWindow||i)}for(c=0;(a=d[c++])&&!t.isPropagationStopped();)t.type=c>1?l:u.bindType||p,r=(lt._data(a,"events")||{})[t.type]&<._data(a,"handle"),r&&r.apply(a,e),r=o&&a[o],r&&r.apply&<.acceptData(a)&&(t.result=r.apply(a,e),t.result===!1&&t.preventDefault());if(t.type=p,!s&&!t.isDefaultPrevented()&&(!u._default||u._default.apply(d.pop(),e)===!1)&<.acceptData(n)&&o&&n[p]&&!lt.isWindow(n)){h=n[o],h&&(n[o]=null),lt.event.triggered=p;try{n[p]()}catch(g){}lt.event.triggered=void 0,h&&(n[o]=h)}return t.result}},dispatch:function(t){t=lt.event.fix(t);var e,i,n,s,r,o=[],a=Z.call(arguments),l=(lt._data(this,"events")||{})[t.type]||[],u=lt.event.special[t.type]||{};if(a[0]=t,t.delegateTarget=this,!u.preDispatch||u.preDispatch.call(this,t)!==!1){for(o=lt.event.handlers.call(this,t,l),e=0;(s=o[e++])&&!t.isPropagationStopped();)for(t.currentTarget=s.elem,r=0;(n=s.handlers[r++])&&!t.isImmediatePropagationStopped();)(!t.namespace_re||t.namespace_re.test(n.namespace))&&(t.handleObj=n,t.data=n.data,i=((lt.event.special[n.origType]||{}).handle||n.handler).apply(s.elem,a),void 0!==i&&(t.result=i)===!1&&(t.preventDefault(),t.stopPropagation()));return u.postDispatch&&u.postDispatch.call(this,t),t.result}},handlers:function(t,e){var i,n,s,r,o=[],a=e.delegateCount,l=t.target;if(a&&l.nodeType&&(!t.button||"click"!==t.type))for(;l!=this;l=l.parentNode||this)if(1===l.nodeType&&(l.disabled!==!0||"click"!==t.type)){for(s=[],r=0;a>r;r++)n=e[r],i=n.selector+" ",void 0===s[i]&&(s[i]=n.needsContext?lt(i,this).index(l)>=0:lt.find(i,this,null,[l]).length),s[i]&&s.push(n);s.length&&o.push({elem:l,handlers:s})}return a]","i"),zt=/^\s+/,Bt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,Ut=/<([\w:]+)/,Vt=/\s*$/g,Zt={option:[1,""],legend:[1,"
","
"],area:[1,"",""],param:[1,"",""],thead:[1,"","
"],tr:[2,"","
"],col:[2,"","
"],td:[3,"","
"],_default:ot.htmlSerialize?[0,"",""]:[1,"X
","
"]},te=b(yt),ee=te.appendChild(yt.createElement("div"));Zt.optgroup=Zt.option,Zt.tbody=Zt.tfoot=Zt.colgroup=Zt.caption=Zt.thead,Zt.th=Zt.td,lt.extend({clone:function(t,e,i){var n,s,r,o,a,l=lt.contains(t.ownerDocument,t);if(ot.html5Clone||lt.isXMLDoc(t)||!Wt.test("<"+t.nodeName+">")?r=t.cloneNode(!0):(ee.innerHTML=t.outerHTML,ee.removeChild(r=ee.firstChild)),!(ot.noCloneEvent&&ot.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||lt.isXMLDoc(t)))for(n=w(r),a=w(t),o=0;null!=(s=a[o]);++o)n[o]&&E(s,n[o]);if(e)if(i)for(a=a||w(t),n=n||w(r),o=0;null!=(s=a[o]);o++)T(s,n[o]);else T(t,r);return n=w(r,"script"),n.length>0&&k(n,!l&&w(t,"script")),n=a=s=null,r},buildFragment:function(t,e,i,n){for(var s,r,o,a,l,u,h,c=t.length,d=b(e),p=[],f=0;c>f;f++)if(r=t[f],r||0===r)if("object"===lt.type(r))lt.merge(p,r.nodeType?[r]:r);else if(Gt.test(r)){for(a=a||d.appendChild(e.createElement("div")),l=(Ut.exec(r)||["",""])[1].toLowerCase(),h=Zt[l]||Zt._default,a.innerHTML=h[1]+r.replace(Bt,"<$1>")+h[2],s=h[0];s--;)a=a.lastChild;if(!ot.leadingWhitespace&&zt.test(r)&&p.push(e.createTextNode(zt.exec(r)[0])),!ot.tbody)for(r="table"!==l||Vt.test(r)?""!==h[1]||Vt.test(r)?0:a:a.firstChild,s=r&&r.childNodes.length;s--;)lt.nodeName(u=r.childNodes[s],"tbody")&&!u.childNodes.length&&r.removeChild(u);for(lt.merge(p,a.childNodes),a.textContent="";a.firstChild;)a.removeChild(a.firstChild);a=d.lastChild}else p.push(e.createTextNode(r));for(a&&d.removeChild(a),ot.appendChecked||lt.grep(w(p,"input"),_),f=0;r=p[f++];)if((!n||-1===lt.inArray(r,n))&&(o=lt.contains(r.ownerDocument,r),a=w(d.appendChild(r),"script"),o&&k(a),i))for(s=0;r=a[s++];)Jt.test(r.type||"")&&i.push(r);return a=null,d},cleanData:function(t,e){for(var i,n,s,r,o=0,a=lt.expando,l=lt.cache,u=ot.deleteExpando,h=lt.event.special;null!=(i=t[o]);o++)if((e||lt.acceptData(i))&&(s=i[a],r=s&&l[s])){if(r.events)for(n in r.events)h[n]?lt.event.remove(i,n):lt.removeEvent(i,n,r.handle);l[s]&&(delete l[s],u?delete i[a]:typeof i.removeAttribute!==Et?i.removeAttribute(a):i[a]=null,Q.push(s))}}}),lt.fn.extend({text:function(t){return Pt(this,function(t){return void 0===t?lt.text(this):this.empty().append((this[0]&&this[0].ownerDocument||yt).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=x(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=x(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 i,n=t?lt.filter(t,this):this,s=0;null!=(i=n[s]);s++)e||1!==i.nodeType||lt.cleanData(w(i)),i.parentNode&&(e&<.contains(i.ownerDocument,i)&&k(w(i,"script")),i.parentNode.removeChild(i));return this},empty:function(){for(var t,e=0;null!=(t=this[e]);e++){for(1===t.nodeType&<.cleanData(w(t,!1));t.firstChild;)t.removeChild(t.firstChild);t.options&<.nodeName(t,"select")&&(t.options.length=0)}return this},clone:function(t,e){return t=null==t?!1:t,e=null==e?t:e,this.map(function(){return lt.clone(this,t,e)})},html:function(t){return Pt(this,function(t){var e=this[0]||{},i=0,n=this.length;if(void 0===t)return 1===e.nodeType?e.innerHTML.replace(qt,""):void 0;if("string"==typeof t&&!Xt.test(t)&&(ot.htmlSerialize||!Wt.test(t))&&(ot.leadingWhitespace||!zt.test(t))&&!Zt[(Ut.exec(t)||["",""])[1].toLowerCase()]){t=t.replace(Bt,"<$1>");try{for(;n>i;i++)e=this[i]||{},1===e.nodeType&&(lt.cleanData(w(e,!1)),e.innerHTML=t);e=0}catch(s){}}e&&this.empty().append(t)},null,t,arguments.length)},replaceWith:function(){var t=arguments[0];return this.domManip(arguments,function(e){t=this.parentNode,lt.cleanData(w(this)),t&&t.replaceChild(e,this)}),t&&(t.length||t.nodeType)?this:this.remove()},detach:function(t){return this.remove(t,!0)},domManip:function(t,e){t=tt.apply([],t);var i,n,s,r,o,a,l=0,u=this.length,h=this,c=u-1,d=t[0],p=lt.isFunction(d);if(p||u>1&&"string"==typeof d&&!ot.checkClone&&Yt.test(d))return this.each(function(i){var n=h.eq(i);p&&(t[0]=d.call(this,i,n.html())),n.domManip(t,e)});if(u&&(a=lt.buildFragment(t,this[0].ownerDocument,!1,this),i=a.firstChild,1===a.childNodes.length&&(a=i),i)){for(r=lt.map(w(a,"script"),C),s=r.length;u>l;l++)n=a,l!==c&&(n=lt.clone(n,!0,!0),s&<.merge(r,w(n,"script"))),e.call(this[l],n,l);if(s)for(o=r[r.length-1].ownerDocument,lt.map(r,S),l=0;s>l;l++)n=r[l],Jt.test(n.type||"")&&!lt._data(n,"globalEval")&<.contains(o,n)&&(n.src?lt._evalUrl&<._evalUrl(n.src):lt.globalEval((n.text||n.textContent||n.innerHTML||"").replace(Qt,"")));a=i=null}return this}}),lt.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(t,e){lt.fn[t]=function(t){for(var i,n=0,s=[],r=lt(t),o=r.length-1;o>=n;n++)i=n===o?this:this.clone(!0),lt(r[n])[e](i),et.apply(s,i.get());return this.pushStack(s)}});var ie,ne={};!function(){var t;ot.shrinkWrapBlocks=function(){if(null!=t)return t;t=!1;var e,i,n;return i=yt.getElementsByTagName("body")[0],i&&i.style?(e=yt.createElement("div"),n=yt.createElement("div"),n.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",i.appendChild(n).appendChild(e),typeof e.style.zoom!==Et&&(e.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:1px;width:1px;zoom:1",e.appendChild(yt.createElement("div")).style.width="5px",t=3!==e.offsetWidth),i.removeChild(n),t):void 0}}();var se,re,oe=/^margin/,ae=new RegExp("^("+Ot+")(?!px)[a-z%]+$","i"),le=/^(top|right|bottom|left)$/;i.getComputedStyle?(se=function(t){return t.ownerDocument.defaultView.opener?t.ownerDocument.defaultView.getComputedStyle(t,null):i.getComputedStyle(t,null)},re=function(t,e,i){var n,s,r,o,a=t.style;return i=i||se(t),o=i?i.getPropertyValue(e)||i[e]:void 0,i&&(""!==o||lt.contains(t.ownerDocument,t)||(o=lt.style(t,e)),ae.test(o)&&oe.test(e)&&(n=a.width,s=a.minWidth,r=a.maxWidth,a.minWidth=a.maxWidth=a.width=o,o=i.width,a.width=n,a.minWidth=s,a.maxWidth=r)),void 0===o?o:o+""}):yt.documentElement.currentStyle&&(se=function(t){return t.currentStyle},re=function(t,e,i){var n,s,r,o,a=t.style;return i=i||se(t),o=i?i[e]:void 0,null==o&&a&&a[e]&&(o=a[e]),ae.test(o)&&!le.test(e)&&(n=a.left,s=t.runtimeStyle,r=s&&s.left,r&&(s.left=t.currentStyle.left),a.left="fontSize"===e?"1em":o,o=a.pixelLeft+"px",a.left=n,r&&(s.left=r)),void 0===o?o:o+""||"auto"}),function(){function t(){var t,e,n,s;e=yt.getElementsByTagName("body")[0],e&&e.style&&(t=yt.createElement("div"),n=yt.createElement("div"),n.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",e.appendChild(n).appendChild(t),t.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",r=o=!1,l=!0,i.getComputedStyle&&(r="1%"!==(i.getComputedStyle(t,null)||{}).top,o="4px"===(i.getComputedStyle(t,null)||{width:"4px"}).width,s=t.appendChild(yt.createElement("div")),s.style.cssText=t.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",s.style.marginRight=s.style.width="0",t.style.width="1px",l=!parseFloat((i.getComputedStyle(s,null)||{}).marginRight),t.removeChild(s)),t.innerHTML="
t
",s=t.getElementsByTagName("td"),s[0].style.cssText="margin:0;border:0;padding:0;display:none",a=0===s[0].offsetHeight,a&&(s[0].style.display="",s[1].style.display="none",a=0===s[0].offsetHeight),e.removeChild(n))}var e,n,s,r,o,a,l;e=yt.createElement("div"),e.innerHTML="
a",s=e.getElementsByTagName("a")[0],n=s&&s.style,n&&(n.cssText="float:left;opacity:.5",ot.opacity="0.5"===n.opacity,ot.cssFloat=!!n.cssFloat,e.style.backgroundClip="content-box",e.cloneNode(!0).style.backgroundClip="",ot.clearCloneStyle="content-box"===e.style.backgroundClip,ot.boxSizing=""===n.boxSizing||""===n.MozBoxSizing||""===n.WebkitBoxSizing,lt.extend(ot,{reliableHiddenOffsets:function(){return null==a&&t(),a},boxSizingReliable:function(){return null==o&&t(),o},pixelPosition:function(){return null==r&&t(),r},reliableMarginRight:function(){return null==l&&t(),l}}))}(),lt.swap=function(t,e,i,n){var s,r,o={};for(r in e)o[r]=t.style[r],t.style[r]=e[r];s=i.apply(t,n||[]);for(r in e)t.style[r]=o[r];return s};var ue=/alpha\([^)]*\)/i,he=/opacity\s*=\s*([^)]*)/,ce=/^(none|table(?!-c[ea]).+)/,de=new RegExp("^("+Ot+")(.*)$","i"),pe=new RegExp("^([+-])=("+Ot+")","i"),fe={position:"absolute",visibility:"hidden",display:"block"},ge={letterSpacing:"0",fontWeight:"400"},me=["Webkit","O","Moz","ms"];lt.extend({cssHooks:{opacity:{get:function(t,e){if(e){var i=re(t,"opacity");return""===i?"1":i}}}},cssNumber:{columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":ot.cssFloat?"cssFloat":"styleFloat"},style:function(t,e,i,n){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var s,r,o,a=lt.camelCase(e),l=t.style;if(e=lt.cssProps[a]||(lt.cssProps[a]=M(l,a)),o=lt.cssHooks[e]||lt.cssHooks[a],void 0===i)return o&&"get"in o&&void 0!==(s=o.get(t,!1,n))?s:l[e];if(r=typeof i,"string"===r&&(s=pe.exec(i))&&(i=(s[1]+1)*s[2]+parseFloat(lt.css(t,e)),r="number"),null!=i&&i===i&&("number"!==r||lt.cssNumber[a]||(i+="px"),ot.clearCloneStyle||""!==i||0!==e.indexOf("background")||(l[e]="inherit"),!(o&&"set"in o&&void 0===(i=o.set(t,i,n)))))try{l[e]=i}catch(u){}}},css:function(t,e,i,n){var s,r,o,a=lt.camelCase(e);return e=lt.cssProps[a]||(lt.cssProps[a]=M(t.style,a)),o=lt.cssHooks[e]||lt.cssHooks[a],o&&"get"in o&&(r=o.get(t,!0,i)),void 0===r&&(r=re(t,e,n)),"normal"===r&&e in ge&&(r=ge[e]),""===i||i?(s=parseFloat(r),i===!0||lt.isNumeric(s)?s||0:r):r}}),lt.each(["height","width"],function(t,e){lt.cssHooks[e]={get:function(t,i,n){return i?ce.test(lt.css(t,"display"))&&0===t.offsetWidth?lt.swap(t,fe,function(){return L(t,e,n)}):L(t,e,n):void 0},set:function(t,i,n){var s=n&&se(t);return P(t,i,n?R(t,e,n,ot.boxSizing&&"border-box"===lt.css(t,"boxSizing",!1,s),s):0)}}}),ot.opacity||(lt.cssHooks.opacity={get:function(t,e){return he.test((e&&t.currentStyle?t.currentStyle.filter:t.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":e?"1":""},set:function(t,e){var i=t.style,n=t.currentStyle,s=lt.isNumeric(e)?"alpha(opacity="+100*e+")":"",r=n&&n.filter||i.filter||"";i.zoom=1,(e>=1||""===e)&&""===lt.trim(r.replace(ue,""))&&i.removeAttribute&&(i.removeAttribute("filter"),""===e||n&&!n.filter)||(i.filter=ue.test(r)?r.replace(ue,s):r+" "+s)}}),lt.cssHooks.marginRight=O(ot.reliableMarginRight,function(t,e){return e?lt.swap(t,{display:"inline-block"},re,[t,"marginRight"]):void 0}),lt.each({margin:"",padding:"",border:"Width"},function(t,e){lt.cssHooks[t+e]={expand:function(i){for(var n=0,s={},r="string"==typeof i?i.split(" "):[i];4>n;n++)s[t+Mt[n]+e]=r[n]||r[n-2]||r[0];return s}},oe.test(t)||(lt.cssHooks[t+e].set=P)}),lt.fn.extend({css:function(t,e){return Pt(this,function(t,e,i){var n,s,r={},o=0;if(lt.isArray(e)){for(n=se(t),s=e.length;s>o;o++)r[e[o]]=lt.css(t,e[o],!1,n);return r}return void 0!==i?lt.style(t,e,i):lt.css(t,e)},t,e,arguments.length>1)},show:function(){return D(this,!0)},hide:function(){return D(this)},toggle:function(t){return"boolean"==typeof t?t?this.show():this.hide():this.each(function(){Dt(this)?lt(this).show():lt(this).hide()})}}),lt.Tween=j,j.prototype={constructor:j,init:function(t,e,i,n,s,r){this.elem=t,this.prop=i,this.easing=s||"swing",this.options=e,this.start=this.now=this.cur(),this.end=n,this.unit=r||(lt.cssNumber[i]?"":"px")},cur:function(){var t=j.propHooks[this.prop];return t&&t.get?t.get(this):j.propHooks._default.get(this)},run:function(t){var e,i=j.propHooks[this.prop];return this.options.duration?this.pos=e=lt.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),i&&i.set?i.set(this):j.propHooks._default.set(this),this}},j.prototype.init.prototype=j.prototype,j.propHooks={_default:{get:function(t){var e;return null==t.elem[t.prop]||t.elem.style&&null!=t.elem.style[t.prop]?(e=lt.css(t.elem,t.prop,""),e&&"auto"!==e?e:0):t.elem[t.prop]},set:function(t){lt.fx.step[t.prop]?lt.fx.step[t.prop](t):t.elem.style&&(null!=t.elem.style[lt.cssProps[t.prop]]||lt.cssHooks[t.prop])?lt.style(t.elem,t.prop,t.now+t.unit):t.elem[t.prop]=t.now}}},j.propHooks.scrollTop=j.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},lt.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2}},lt.fx=j.prototype.init,lt.fx.step={};var ve,ye,be=/^(?:toggle|show|hide)$/,we=new RegExp("^(?:([+-])=|)("+Ot+")([a-z%]*)$","i"),_e=/queueHooks$/,xe=[F],Ce={"*":[function(t,e){var i=this.createTween(t,e),n=i.cur(),s=we.exec(e),r=s&&s[3]||(lt.cssNumber[t]?"":"px"),o=(lt.cssNumber[t]||"px"!==r&&+n)&&we.exec(lt.css(i.elem,t)),a=1,l=20;if(o&&o[3]!==r){r=r||o[3],s=s||[],o=+n||1;do a=a||".5",o/=a,lt.style(i.elem,t,o+r);while(a!==(a=i.cur()/n)&&1!==a&&--l)}return s&&(o=i.start=+o||+n||0,i.unit=r,i.end=s[1]?o+(s[1]+1)*s[2]:+s[2]),i}]};lt.Animation=lt.extend(W,{tweener:function(t,e){lt.isFunction(t)?(e=t,t=["*"]):t=t.split(" ");for(var i,n=0,s=t.length;s>n;n++)i=t[n],Ce[i]=Ce[i]||[],Ce[i].unshift(e)},prefilter:function(t,e){e?xe.unshift(t):xe.push(t)}}),lt.speed=function(t,e,i){var n=t&&"object"==typeof t?lt.extend({},t):{complete:i||!i&&e||lt.isFunction(t)&&t,duration:t,easing:i&&e||e&&!lt.isFunction(e)&&e};return n.duration=lt.fx.off?0:"number"==typeof n.duration?n.duration:n.duration in lt.fx.speeds?lt.fx.speeds[n.duration]:lt.fx.speeds._default,(null==n.queue||n.queue===!0)&&(n.queue="fx"),n.old=n.complete,n.complete=function(){lt.isFunction(n.old)&&n.old.call(this),n.queue&<.dequeue(this,n.queue)},n},lt.fn.extend({fadeTo:function(t,e,i,n){return this.filter(Dt).css("opacity",0).show().end().animate({opacity:e},t,i,n)},animate:function(t,e,i,n){var s=lt.isEmptyObject(t),r=lt.speed(e,i,n),o=function(){var e=W(this,lt.extend({},t),r);(s||lt._data(this,"finish"))&&e.stop(!0)};return o.finish=o,s||r.queue===!1?this.each(o):this.queue(r.queue,o)},stop:function(t,e,i){var n=function(t){var e=t.stop;delete t.stop,e(i)};return"string"!=typeof t&&(i=e,e=t,t=void 0),e&&t!==!1&&this.queue(t||"fx",[]),this.each(function(){var e=!0,s=null!=t&&t+"queueHooks",r=lt.timers,o=lt._data(this);if(s)o[s]&&o[s].stop&&n(o[s]);else for(s in o)o[s]&&o[s].stop&&_e.test(s)&&n(o[s]);for(s=r.length;s--;)r[s].elem!==this||null!=t&&r[s].queue!==t||(r[s].anim.stop(i),e=!1,r.splice(s,1));(e||!i)&<.dequeue(this,t)})},finish:function(t){return t!==!1&&(t=t||"fx"),this.each(function(){var e,i=lt._data(this),n=i[t+"queue"],s=i[t+"queueHooks"],r=lt.timers,o=n?n.length:0;for(i.finish=!0,lt.queue(this,t,[]),s&&s.stop&&s.stop.call(this,!0),e=r.length;e--;)r[e].elem===this&&r[e].queue===t&&(r[e].anim.stop(!0),r.splice(e,1));for(e=0;o>e;e++)n[e]&&n[e].finish&&n[e].finish.call(this);delete i.finish})}}),lt.each(["toggle","show","hide"],function(t,e){var i=lt.fn[e];lt.fn[e]=function(t,n,s){return null==t||"boolean"==typeof t?i.apply(this,arguments):this.animate(I(e,!0),t,n,s)}}),lt.each({slideDown:I("show"),slideUp:I("hide"),slideToggle:I("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(t,e){lt.fn[t]=function(t,i,n){return this.animate(e,t,i,n)}}),lt.timers=[],lt.fx.tick=function(){var t,e=lt.timers,i=0;for(ve=lt.now();i
a",n=e.getElementsByTagName("a")[0],i=yt.createElement("select"),s=i.appendChild(yt.createElement("option")),t=e.getElementsByTagName("input")[0],n.style.cssText="top:1px",ot.getSetAttribute="t"!==e.className,ot.style=/top/.test(n.getAttribute("style")),ot.hrefNormalized="/a"===n.getAttribute("href"),ot.checkOn=!!t.value,ot.optSelected=s.selected,ot.enctype=!!yt.createElement("form").enctype,i.disabled=!0,ot.optDisabled=!s.disabled,t=yt.createElement("input"),t.setAttribute("value",""),ot.input=""===t.getAttribute("value"),t.value="t",t.setAttribute("type","radio"),ot.radioValue="t"===t.value}();var Se=/\r/g;lt.fn.extend({val:function(t){var e,i,n,s=this[0];{if(arguments.length)return n=lt.isFunction(t),this.each(function(i){var s;1===this.nodeType&&(s=n?t.call(this,i,lt(this).val()):t,null==s?s="":"number"==typeof s?s+="":lt.isArray(s)&&(s=lt.map(s,function(t){return null==t?"":t+""})),e=lt.valHooks[this.type]||lt.valHooks[this.nodeName.toLowerCase()],e&&"set"in e&&void 0!==e.set(this,s,"value")||(this.value=s))});if(s)return e=lt.valHooks[s.type]||lt.valHooks[s.nodeName.toLowerCase()],e&&"get"in e&&void 0!==(i=e.get(s,"value"))?i:(i=s.value,"string"==typeof i?i.replace(Se,""):null==i?"":i)}}}),lt.extend({valHooks:{option:{get:function(t){var e=lt.find.attr(t,"value");return null!=e?e:lt.trim(lt.text(t))}},select:{get:function(t){for(var e,i,n=t.options,s=t.selectedIndex,r="select-one"===t.type||0>s,o=r?null:[],a=r?s+1:n.length,l=0>s?a:r?s:0;a>l;l++)if(i=n[l],(i.selected||l===s)&&(ot.optDisabled?!i.disabled:null===i.getAttribute("disabled"))&&(!i.parentNode.disabled||!lt.nodeName(i.parentNode,"optgroup"))){if(e=lt(i).val(),r)return e;o.push(e)}return o},set:function(t,e){for(var i,n,s=t.options,r=lt.makeArray(e),o=s.length;o--;)if(n=s[o],lt.inArray(lt.valHooks.option.get(n),r)>=0)try{n.selected=i=!0}catch(a){n.scrollHeight}else n.selected=!1;return i||(t.selectedIndex=-1),s}}}}),lt.each(["radio","checkbox"],function(){lt.valHooks[this]={set:function(t,e){return lt.isArray(e)?t.checked=lt.inArray(lt(t).val(),e)>=0:void 0}},ot.checkOn||(lt.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})});var ke,Te,Ee=lt.expr.attrHandle,Ae=/^(?:checked|selected)$/i,Ne=ot.getSetAttribute,Oe=ot.input;lt.fn.extend({attr:function(t,e){return Pt(this,lt.attr,t,e,arguments.length>1)},removeAttr:function(t){return this.each(function(){lt.removeAttr(this,t)})}}),lt.extend({attr:function(t,e,i){var n,s,r=t.nodeType;if(t&&3!==r&&8!==r&&2!==r)return typeof t.getAttribute===Et?lt.prop(t,e,i):(1===r&<.isXMLDoc(t)||(e=e.toLowerCase(),n=lt.attrHooks[e]||(lt.expr.match.bool.test(e)?Te:ke)),void 0===i?n&&"get"in n&&null!==(s=n.get(t,e))?s:(s=lt.find.attr(t,e),null==s?void 0:s):null!==i?n&&"set"in n&&void 0!==(s=n.set(t,i,e))?s:(t.setAttribute(e,i+""),i):void lt.removeAttr(t,e))},removeAttr:function(t,e){var i,n,s=0,r=e&&e.match(Ct);if(r&&1===t.nodeType)for(;i=r[s++];)n=lt.propFix[i]||i,lt.expr.match.bool.test(i)?Oe&&Ne||!Ae.test(i)?t[n]=!1:t[lt.camelCase("default-"+i)]=t[n]=!1:lt.attr(t,i,""),t.removeAttribute(Ne?i:n)},attrHooks:{type:{set:function(t,e){if(!ot.radioValue&&"radio"===e&<.nodeName(t,"input")){var i=t.value;return t.setAttribute("type",e),i&&(t.value=i),e}}}}}),Te={set:function(t,e,i){return e===!1?lt.removeAttr(t,i):Oe&&Ne||!Ae.test(i)?t.setAttribute(!Ne&<.propFix[i]||i,i):t[lt.camelCase("default-"+i)]=t[i]=!0,i}},lt.each(lt.expr.match.bool.source.match(/\w+/g),function(t,e){var i=Ee[e]||lt.find.attr;Ee[e]=Oe&&Ne||!Ae.test(e)?function(t,e,n){var s,r;return n||(r=Ee[e],Ee[e]=s,s=null!=i(t,e,n)?e.toLowerCase():null,Ee[e]=r),s}:function(t,e,i){return i?void 0:t[lt.camelCase("default-"+e)]?e.toLowerCase():null}}),Oe&&Ne||(lt.attrHooks.value={set:function(t,e,i){return lt.nodeName(t,"input")?void(t.defaultValue=e):ke&&ke.set(t,e,i)}}),Ne||(ke={set:function(t,e,i){var n=t.getAttributeNode(i);return n||t.setAttributeNode(n=t.ownerDocument.createAttribute(i)),n.value=e+="","value"===i||e===t.getAttribute(i)?e:void 0}},Ee.id=Ee.name=Ee.coords=function(t,e,i){var n;return i?void 0:(n=t.getAttributeNode(e))&&""!==n.value?n.value:null},lt.valHooks.button={get:function(t,e){var i=t.getAttributeNode(e);return i&&i.specified?i.value:void 0},set:ke.set},lt.attrHooks.contenteditable={set:function(t,e,i){ke.set(t,""===e?!1:e,i)}},lt.each(["width","height"],function(t,e){lt.attrHooks[e]={set:function(t,i){return""===i?(t.setAttribute(e,"auto"),i):void 0}}})),ot.style||(lt.attrHooks.style={get:function(t){return t.style.cssText||void 0},set:function(t,e){return t.style.cssText=e+""}});var Me=/^(?:input|select|textarea|button|object)$/i,De=/^(?:a|area)$/i;lt.fn.extend({prop:function(t,e){return Pt(this,lt.prop,t,e,arguments.length>1)},removeProp:function(t){return t=lt.propFix[t]||t,this.each(function(){try{this[t]=void 0,delete this[t]}catch(e){}})}}),lt.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(t,e,i){var n,s,r,o=t.nodeType;if(t&&3!==o&&8!==o&&2!==o)return r=1!==o||!lt.isXMLDoc(t),r&&(e=lt.propFix[e]||e,s=lt.propHooks[e]), void 0!==i?s&&"set"in s&&void 0!==(n=s.set(t,i,e))?n:t[e]=i:s&&"get"in s&&null!==(n=s.get(t,e))?n:t[e]},propHooks:{tabIndex:{get:function(t){var e=lt.find.attr(t,"tabindex");return e?parseInt(e,10):Me.test(t.nodeName)||De.test(t.nodeName)&&t.href?0:-1}}}}),ot.hrefNormalized||lt.each(["href","src"],function(t,e){lt.propHooks[e]={get:function(t){return t.getAttribute(e,4)}}}),ot.optSelected||(lt.propHooks.selected={get:function(t){var e=t.parentNode;return e&&(e.selectedIndex,e.parentNode&&e.parentNode.selectedIndex),null}}),lt.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){lt.propFix[this.toLowerCase()]=this}),ot.enctype||(lt.propFix.enctype="encoding");var Pe=/[\t\r\n\f]/g;lt.fn.extend({addClass:function(t){var e,i,n,s,r,o,a=0,l=this.length,u="string"==typeof t&&t;if(lt.isFunction(t))return this.each(function(e){lt(this).addClass(t.call(this,e,this.className))});if(u)for(e=(t||"").match(Ct)||[];l>a;a++)if(i=this[a],n=1===i.nodeType&&(i.className?(" "+i.className+" ").replace(Pe," "):" ")){for(r=0;s=e[r++];)n.indexOf(" "+s+" ")<0&&(n+=s+" ");o=lt.trim(n),i.className!==o&&(i.className=o)}return this},removeClass:function(t){var e,i,n,s,r,o,a=0,l=this.length,u=0===arguments.length||"string"==typeof t&&t;if(lt.isFunction(t))return this.each(function(e){lt(this).removeClass(t.call(this,e,this.className))});if(u)for(e=(t||"").match(Ct)||[];l>a;a++)if(i=this[a],n=1===i.nodeType&&(i.className?(" "+i.className+" ").replace(Pe," "):"")){for(r=0;s=e[r++];)for(;n.indexOf(" "+s+" ")>=0;)n=n.replace(" "+s+" "," ");o=t?lt.trim(n):"",i.className!==o&&(i.className=o)}return this},toggleClass:function(t,e){var i=typeof t;return"boolean"==typeof e&&"string"===i?e?this.addClass(t):this.removeClass(t):lt.isFunction(t)?this.each(function(i){lt(this).toggleClass(t.call(this,i,this.className,e),e)}):this.each(function(){if("string"===i)for(var e,n=0,s=lt(this),r=t.match(Ct)||[];e=r[n++];)s.hasClass(e)?s.removeClass(e):s.addClass(e);else(i===Et||"boolean"===i)&&(this.className&<._data(this,"__className__",this.className),this.className=this.className||t===!1?"":lt._data(this,"__className__")||"")})},hasClass:function(t){for(var e=" "+t+" ",i=0,n=this.length;n>i;i++)if(1===this[i].nodeType&&(" "+this[i].className+" ").replace(Pe," ").indexOf(e)>=0)return!0;return!1}}),lt.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){lt.fn[e]=function(t,i){return arguments.length>0?this.on(e,null,t,i):this.trigger(e)}}),lt.fn.extend({hover:function(t,e){return this.mouseenter(t).mouseleave(e||t)},bind:function(t,e,i){return this.on(t,null,e,i)},unbind:function(t,e){return this.off(t,null,e)},delegate:function(t,e,i,n){return this.on(e,t,i,n)},undelegate:function(t,e,i){return 1===arguments.length?this.off(t,"**"):this.off(e,t||"**",i)}});var Re=lt.now(),Le=/\?/,je=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;lt.parseJSON=function(t){if(i.JSON&&i.JSON.parse)return i.JSON.parse(t+"");var e,n=null,s=lt.trim(t+"");return s&&!lt.trim(s.replace(je,function(t,i,s,r){return e&&i&&(n=0),0===n?t:(e=s||i,n+=!r-!s,"")}))?Function("return "+s)():lt.error("Invalid JSON: "+t)},lt.parseXML=function(t){var e,n;if(!t||"string"!=typeof t)return null;try{i.DOMParser?(n=new DOMParser,e=n.parseFromString(t,"text/xml")):(e=new ActiveXObject("Microsoft.XMLDOM"),e.async="false",e.loadXML(t))}catch(s){e=void 0}return e&&e.documentElement&&!e.getElementsByTagName("parsererror").length||lt.error("Invalid XML: "+t),e};var He,Ie,$e=/#.*$/,Fe=/([?&])_=[^&]*/,qe=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,We=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,ze=/^(?:GET|HEAD)$/,Be=/^\/\//,Ue=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Ve={},Ge={},Xe="*/".concat("*");try{Ie=location.href}catch(Ye){Ie=yt.createElement("a"),Ie.href="",Ie=Ie.href}He=Ue.exec(Ie.toLowerCase())||[],lt.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ie,type:"GET",isLocal:We.test(He[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Xe,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":lt.parseJSON,"text xml":lt.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?U(U(t,lt.ajaxSettings),e):U(lt.ajaxSettings,t)},ajaxPrefilter:z(Ve),ajaxTransport:z(Ge),ajax:function(t,e){function i(t,e,i,n){var s,h,v,y,w,x=e;2!==b&&(b=2,a&&clearTimeout(a),u=void 0,o=n||"",_.readyState=t>0?4:0,s=t>=200&&300>t||304===t,i&&(y=V(c,_,i)),y=G(c,y,_,s),s?(c.ifModified&&(w=_.getResponseHeader("Last-Modified"),w&&(lt.lastModified[r]=w),w=_.getResponseHeader("etag"),w&&(lt.etag[r]=w)),204===t||"HEAD"===c.type?x="nocontent":304===t?x="notmodified":(x=y.state,h=y.data,v=y.error,s=!v)):(v=x,(t||!x)&&(x="error",0>t&&(t=0))),_.status=t,_.statusText=(e||x)+"",s?f.resolveWith(d,[h,x,_]):f.rejectWith(d,[_,x,v]),_.statusCode(m),m=void 0,l&&p.trigger(s?"ajaxSuccess":"ajaxError",[_,c,s?h:v]),g.fireWith(d,[_,x]),l&&(p.trigger("ajaxComplete",[_,c]),--lt.active||lt.event.trigger("ajaxStop")))}"object"==typeof t&&(e=t,t=void 0),e=e||{};var n,s,r,o,a,l,u,h,c=lt.ajaxSetup({},e),d=c.context||c,p=c.context&&(d.nodeType||d.jquery)?lt(d):lt.event,f=lt.Deferred(),g=lt.Callbacks("once memory"),m=c.statusCode||{},v={},y={},b=0,w="canceled",_={readyState:0,getResponseHeader:function(t){var e;if(2===b){if(!h)for(h={};e=qe.exec(o);)h[e[1].toLowerCase()]=e[2];e=h[t.toLowerCase()]}return null==e?null:e},getAllResponseHeaders:function(){return 2===b?o:null},setRequestHeader:function(t,e){var i=t.toLowerCase();return b||(t=y[i]=y[i]||t,v[t]=e),this},overrideMimeType:function(t){return b||(c.mimeType=t),this},statusCode:function(t){var e;if(t)if(2>b)for(e in t)m[e]=[m[e],t[e]];else _.always(t[_.status]);return this},abort:function(t){var e=t||w;return u&&u.abort(e),i(0,e),this}};if(f.promise(_).complete=g.add,_.success=_.done,_.error=_.fail,c.url=((t||c.url||Ie)+"").replace($e,"").replace(Be,He[1]+"//"),c.type=e.method||e.type||c.method||c.type,c.dataTypes=lt.trim(c.dataType||"*").toLowerCase().match(Ct)||[""],null==c.crossDomain&&(n=Ue.exec(c.url.toLowerCase()),c.crossDomain=!(!n||n[1]===He[1]&&n[2]===He[2]&&(n[3]||("http:"===n[1]?"80":"443"))===(He[3]||("http:"===He[1]?"80":"443")))),c.data&&c.processData&&"string"!=typeof c.data&&(c.data=lt.param(c.data,c.traditional)),B(Ve,c,e,_),2===b)return _;l=lt.event&&c.global,l&&0===lt.active++&<.event.trigger("ajaxStart"),c.type=c.type.toUpperCase(),c.hasContent=!ze.test(c.type),r=c.url,c.hasContent||(c.data&&(r=c.url+=(Le.test(r)?"&":"?")+c.data,delete c.data),c.cache===!1&&(c.url=Fe.test(r)?r.replace(Fe,"$1_="+Re++):r+(Le.test(r)?"&":"?")+"_="+Re++)),c.ifModified&&(lt.lastModified[r]&&_.setRequestHeader("If-Modified-Since",lt.lastModified[r]),lt.etag[r]&&_.setRequestHeader("If-None-Match",lt.etag[r])),(c.data&&c.hasContent&&c.contentType!==!1||e.contentType)&&_.setRequestHeader("Content-Type",c.contentType),_.setRequestHeader("Accept",c.dataTypes[0]&&c.accepts[c.dataTypes[0]]?c.accepts[c.dataTypes[0]]+("*"!==c.dataTypes[0]?", "+Xe+"; q=0.01":""):c.accepts["*"]);for(s in c.headers)_.setRequestHeader(s,c.headers[s]);if(c.beforeSend&&(c.beforeSend.call(d,_,c)===!1||2===b))return _.abort();w="abort";for(s in{success:1,error:1,complete:1})_[s](c[s]);if(u=B(Ge,c,e,_)){_.readyState=1,l&&p.trigger("ajaxSend",[_,c]),c.async&&c.timeout>0&&(a=setTimeout(function(){_.abort("timeout")},c.timeout));try{b=1,u.send(v,i)}catch(x){if(!(2>b))throw x;i(-1,x)}}else i(-1,"No Transport");return _},getJSON:function(t,e,i){return lt.get(t,e,i,"json")},getScript:function(t,e){return lt.get(t,void 0,e,"script")}}),lt.each(["get","post"],function(t,e){lt[e]=function(t,i,n,s){return lt.isFunction(i)&&(s=s||n,n=i,i=void 0),lt.ajax({url:t,type:e,dataType:s,data:i,success:n})}}),lt._evalUrl=function(t){return lt.ajax({url:t,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},lt.fn.extend({wrapAll:function(t){if(lt.isFunction(t))return this.each(function(e){lt(this).wrapAll(t.call(this,e))});if(this[0]){var e=lt(t,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var t=this;t.firstChild&&1===t.firstChild.nodeType;)t=t.firstChild;return t}).append(this)}return this},wrapInner:function(t){return lt.isFunction(t)?this.each(function(e){lt(this).wrapInner(t.call(this,e))}):this.each(function(){var e=lt(this),i=e.contents();i.length?i.wrapAll(t):e.append(t)})},wrap:function(t){var e=lt.isFunction(t);return this.each(function(i){lt(this).wrapAll(e?t.call(this,i):t)})},unwrap:function(){return this.parent().each(function(){lt.nodeName(this,"body")||lt(this).replaceWith(this.childNodes)}).end()}}),lt.expr.filters.hidden=function(t){return t.offsetWidth<=0&&t.offsetHeight<=0||!ot.reliableHiddenOffsets()&&"none"===(t.style&&t.style.display||lt.css(t,"display"))},lt.expr.filters.visible=function(t){return!lt.expr.filters.hidden(t)};var Je=/%20/g,Ke=/\[\]$/,Qe=/\r?\n/g,Ze=/^(?:submit|button|image|reset|file)$/i,ti=/^(?:input|select|textarea|keygen)/i;lt.param=function(t,e){var i,n=[],s=function(t,e){e=lt.isFunction(e)?e():null==e?"":e,n[n.length]=encodeURIComponent(t)+"="+encodeURIComponent(e)};if(void 0===e&&(e=lt.ajaxSettings&<.ajaxSettings.traditional),lt.isArray(t)||t.jquery&&!lt.isPlainObject(t))lt.each(t,function(){s(this.name,this.value)});else for(i in t)X(i,t[i],e,s);return n.join("&").replace(Je,"+")},lt.fn.extend({serialize:function(){return lt.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var t=lt.prop(this,"elements");return t?lt.makeArray(t):this}).filter(function(){var t=this.type;return this.name&&!lt(this).is(":disabled")&&ti.test(this.nodeName)&&!Ze.test(t)&&(this.checked||!Rt.test(t))}).map(function(t,e){var i=lt(this).val();return null==i?null:lt.isArray(i)?lt.map(i,function(t){return{name:e.name,value:t.replace(Qe,"\r\n")}}):{name:e.name,value:i.replace(Qe,"\r\n")}}).get()}}),lt.ajaxSettings.xhr=void 0!==i.ActiveXObject?function(){return!this.isLocal&&/^(get|post|head|put|delete|options)$/i.test(this.type)&&Y()||J()}:Y;var ei=0,ii={},ni=lt.ajaxSettings.xhr();i.attachEvent&&i.attachEvent("onunload",function(){for(var t in ii)ii[t](void 0,!0)}),ot.cors=!!ni&&"withCredentials"in ni,ni=ot.ajax=!!ni,ni&<.ajaxTransport(function(t){if(!t.crossDomain||ot.cors){var e;return{send:function(i,n){var s,r=t.xhr(),o=++ei;if(r.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(s in t.xhrFields)r[s]=t.xhrFields[s];t.mimeType&&r.overrideMimeType&&r.overrideMimeType(t.mimeType),t.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest");for(s in i)void 0!==i[s]&&r.setRequestHeader(s,i[s]+"");r.send(t.hasContent&&t.data||null),e=function(i,s){var a,l,u;if(e&&(s||4===r.readyState))if(delete ii[o],e=void 0,r.onreadystatechange=lt.noop,s)4!==r.readyState&&r.abort();else{u={},a=r.status,"string"==typeof r.responseText&&(u.text=r.responseText);try{l=r.statusText}catch(h){l=""}a||!t.isLocal||t.crossDomain?1223===a&&(a=204):a=u.text?200:404}u&&n(a,l,u,r.getAllResponseHeaders())},t.async?4===r.readyState?setTimeout(e):r.onreadystatechange=ii[o]=e:e()},abort:function(){e&&e(void 0,!0)}}}}),lt.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(t){return lt.globalEval(t),t}}}),lt.ajaxPrefilter("script",function(t){void 0===t.cache&&(t.cache=!1),t.crossDomain&&(t.type="GET",t.global=!1)}),lt.ajaxTransport("script",function(t){if(t.crossDomain){var e,i=yt.head||lt("head")[0]||yt.documentElement;return{send:function(n,s){e=yt.createElement("script"),e.async=!0,t.scriptCharset&&(e.charset=t.scriptCharset),e.src=t.url,e.onload=e.onreadystatechange=function(t,i){(i||!e.readyState||/loaded|complete/.test(e.readyState))&&(e.onload=e.onreadystatechange=null,e.parentNode&&e.parentNode.removeChild(e),e=null,i||s(200,"success"))},i.insertBefore(e,i.firstChild)},abort:function(){e&&e.onload(void 0,!0)}}}});var si=[],ri=/(=)\?(?=&|$)|\?\?/;lt.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var t=si.pop()||lt.expando+"_"+Re++;return this[t]=!0,t}}),lt.ajaxPrefilter("json jsonp",function(t,e,n){var s,r,o,a=t.jsonp!==!1&&(ri.test(t.url)?"url":"string"==typeof t.data&&!(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&ri.test(t.data)&&"data");return a||"jsonp"===t.dataTypes[0]?(s=t.jsonpCallback=lt.isFunction(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,a?t[a]=t[a].replace(ri,"$1"+s):t.jsonp!==!1&&(t.url+=(Le.test(t.url)?"&":"?")+t.jsonp+"="+s),t.converters["script json"]=function(){return o||lt.error(s+" was not called"),o[0]},t.dataTypes[0]="json",r=i[s],i[s]=function(){o=arguments},n.always(function(){i[s]=r,t[s]&&(t.jsonpCallback=e.jsonpCallback,si.push(s)),o&<.isFunction(r)&&r(o[0]),o=r=void 0}),"script"):void 0}),lt.parseHTML=function(t,e,i){if(!t||"string"!=typeof t)return null;"boolean"==typeof e&&(i=e,e=!1),e=e||yt;var n=gt.exec(t),s=!i&&[];return n?[e.createElement(n[1])]:(n=lt.buildFragment([t],e,s),s&&s.length&<(s).remove(),lt.merge([],n.childNodes))};var oi=lt.fn.load;lt.fn.load=function(t,e,i){if("string"!=typeof t&&oi)return oi.apply(this,arguments);var n,s,r,o=this,a=t.indexOf(" ");return a>=0&&(n=lt.trim(t.slice(a,t.length)),t=t.slice(0,a)),lt.isFunction(e)?(i=e,e=void 0):e&&"object"==typeof e&&(r="POST"),o.length>0&<.ajax({url:t,type:r,dataType:"html",data:e}).done(function(t){s=arguments,o.html(n?lt("
").append(lt.parseHTML(t)).find(n):t)}).complete(i&&function(t,e){o.each(i,s||[t.responseText,e,t])}),this},lt.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(t,e){lt.fn[e]=function(t){return this.on(e,t)}}),lt.expr.filters.animated=function(t){return lt.grep(lt.timers,function(e){return t===e.elem}).length};var ai=i.document.documentElement;lt.offset={setOffset:function(t,e,i){var n,s,r,o,a,l,u,h=lt.css(t,"position"),c=lt(t),d={};"static"===h&&(t.style.position="relative"),a=c.offset(),r=lt.css(t,"top"),l=lt.css(t,"left"),u=("absolute"===h||"fixed"===h)&<.inArray("auto",[r,l])>-1,u?(n=c.position(),o=n.top,s=n.left):(o=parseFloat(r)||0,s=parseFloat(l)||0),lt.isFunction(e)&&(e=e.call(t,i,a)),null!=e.top&&(d.top=e.top-a.top+o),null!=e.left&&(d.left=e.left-a.left+s),"using"in e?e.using.call(t,d):c.css(d)}},lt.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){lt.offset.setOffset(this,t,e)});var e,i,n={top:0,left:0},s=this[0],r=s&&s.ownerDocument;if(r)return e=r.documentElement,lt.contains(e,s)?(typeof s.getBoundingClientRect!==Et&&(n=s.getBoundingClientRect()),i=K(r),{top:n.top+(i.pageYOffset||e.scrollTop)-(e.clientTop||0),left:n.left+(i.pageXOffset||e.scrollLeft)-(e.clientLeft||0)}):n},position:function(){if(this[0]){var t,e,i={top:0,left:0},n=this[0];return"fixed"===lt.css(n,"position")?e=n.getBoundingClientRect():(t=this.offsetParent(),e=this.offset(),lt.nodeName(t[0],"html")||(i=t.offset()),i.top+=lt.css(t[0],"borderTopWidth",!0),i.left+=lt.css(t[0],"borderLeftWidth",!0)),{top:e.top-i.top-lt.css(n,"marginTop",!0),left:e.left-i.left-lt.css(n,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var t=this.offsetParent||ai;t&&!lt.nodeName(t,"html")&&"static"===lt.css(t,"position");)t=t.offsetParent;return t||ai})}}),lt.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,e){var i=/Y/.test(e);lt.fn[t]=function(n){return Pt(this,function(t,n,s){var r=K(t);return void 0===s?r?e in r?r[e]:r.document.documentElement[n]:t[n]:void(r?r.scrollTo(i?lt(r).scrollLeft():s,i?s:lt(r).scrollTop()):t[n]=s)},t,n,arguments.length,null)}}),lt.each(["top","left"],function(t,e){lt.cssHooks[e]=O(ot.pixelPosition,function(t,i){return i?(i=re(t,e),ae.test(i)?lt(t).position()[e]+"px":i):void 0})}),lt.each({Height:"height",Width:"width"},function(t,e){lt.each({padding:"inner"+t,content:e,"":"outer"+t},function(i,n){lt.fn[n]=function(n,s){var r=arguments.length&&(i||"boolean"!=typeof n),o=i||(n===!0||s===!0?"margin":"border");return Pt(this,function(e,i,n){var s;return lt.isWindow(e)?e.document.documentElement["client"+t]:9===e.nodeType?(s=e.documentElement,Math.max(e.body["scroll"+t],s["scroll"+t],e.body["offset"+t],s["offset"+t],s["client"+t])):void 0===n?lt.css(e,i,o):lt.style(e,i,n,o)},e,r?n:void 0,r,null)}})}),lt.fn.size=function(){return this.length},lt.fn.andSelf=lt.fn.addBack,n=[],s=function(){return lt}.apply(e,n),!(void 0!==s&&(t.exports=s));var li=i.jQuery,ui=i.$;return lt.noConflict=function(t){return i.$===lt&&(i.$=ui),t&&i.jQuery===lt&&(i.jQuery=li),lt},typeof r===Et&&(i.jQuery=i.$=lt),lt})},function(t,e,i){var n,s;!function(r,o){n=[i(3),i(1),e],s=function(t,e,i){r.Backbone=o(r,i,t,e)}.apply(e,n),!(void 0!==s&&(t.exports=s))}(this,function(t,e,i,n){var s=t.Backbone,r=[],o=(r.push,r.slice);r.splice;e.VERSION="1.1.2",e.$=n,e.noConflict=function(){return t.Backbone=s,this},e.emulateHTTP=!1,e.emulateJSON=!1;var a=e.Events={on:function(t,e,i){if(!u(this,"on",t,[e,i])||!e)return this;this._events||(this._events={});var n=this._events[t]||(this._events[t]=[]);return n.push({callback:e,context:i,ctx:i||this}),this},once:function(t,e,n){if(!u(this,"once",t,[e,n])||!e)return this;var s=this,r=i.once(function(){s.off(t,r),e.apply(this,arguments)});return r._callback=e,this.on(t,r,n)},off:function(t,e,n){var s,r,o,a,l,h,c,d;if(!this._events||!u(this,"off",t,[e,n]))return this;if(!t&&!e&&!n)return this._events=void 0,this;for(a=t?[t]:i.keys(this._events),l=0,h=a.length;h>l;l++)if(t=a[l],o=this._events[t]){if(this._events[t]=s=[],e||n)for(c=0,d=o.length;d>c;c++)r=o[c],(e&&e!==r.callback&&e!==r.callback._callback||n&&n!==r.context)&&s.push(r);s.length||delete this._events[t]}return this},trigger:function(t){if(!this._events)return this;var e=o.call(arguments,1);if(!u(this,"trigger",t,e))return this;var i=this._events[t],n=this._events.all;return i&&h(i,e),n&&h(n,arguments),this},stopListening:function(t,e,n){var s=this._listeningTo;if(!s)return this;var r=!e&&!n;n||"object"!=typeof e||(n=this),t&&((s={})[t._listenId]=t);for(var o in s)t=s[o],t.off(e,n,this),(r||i.isEmpty(t._events))&&delete this._listeningTo[o];return this}},l=/\s+/,u=function(t,e,i,n){if(!i)return!0;if("object"==typeof i){for(var s in i)t[e].apply(t,[s,i[s]].concat(n));return!1}if(l.test(i)){for(var r=i.split(l),o=0,a=r.length;a>o;o++)t[e].apply(t,[r[o]].concat(n));return!1}return!0},h=function(t,e){var i,n=-1,s=t.length,r=e[0],o=e[1],a=e[2];switch(e.length){case 0:for(;++nd;d++)this.trigger("change:"+a[d],this,c[a[d]],n)}if(u)return this;if(!l)for(;this._pending;)n=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,i.extend({},e,{unset:!0}))},clear:function(t){var e={};for(var n in this.attributes)e[n]=void 0;return this.set(e,i.extend({},t,{unset:!0}))},hasChanged:function(t){return null==t?!i.isEmpty(this.changed):i.has(this.changed,t)},changedAttributes:function(t){if(!t)return this.hasChanged()?i.clone(this.changed):!1;var e,n=!1,s=this._changing?this._previousAttributes:this.attributes;for(var r in t)i.isEqual(s[r],e=t[r])||((n||(n={}))[r]=e);return n},previous:function(t){return null!=t&&this._previousAttributes?this._previousAttributes[t]:null},previousAttributes:function(){return i.clone(this._previousAttributes)},fetch:function(t){t=t?i.clone(t):{},void 0===t.parse&&(t.parse=!0);var e=this,n=t.success;return t.success=function(i){return e.set(e.parse(i,t),t)?(n&&n(e,i,t),void e.trigger("sync",e,i,t)):!1},H(this,t),this.sync("read",this,t)},save:function(t,e,n){var s,r,o,a=this.attributes;if(null==t||"object"==typeof t?(s=t,n=e):(s={})[t]=e,n=i.extend({validate:!0},n),s&&!n.wait){if(!this.set(s,n))return!1}else if(!this._validate(s,n))return!1;s&&n.wait&&(this.attributes=i.extend({},a,s)),void 0===n.parse&&(n.parse=!0);var l=this,u=n.success;return n.success=function(t){l.attributes=a;var e=l.parse(t,n);return n.wait&&(e=i.extend(s||{},e)),i.isObject(e)&&!l.set(e,n)?!1:(u&&u(l,t,n),void l.trigger("sync",l,t,n))},H(this,n),r=this.isNew()?"create":n.patch?"patch":"update","patch"===r&&(n.attrs=s),o=this.sync(r,this,n),s&&n.wait&&(this.attributes=a),o},destroy:function(t){t=t?i.clone(t):{};var e=this,n=t.success,s=function(){e.trigger("destroy",e,e.collection,t)};if(t.success=function(i){(t.wait||e.isNew())&&s(),n&&n(e,i,t),e.isNew()||e.trigger("sync",e,i,t)},this.isNew())return t.success(),!1;H(this,t);var r=this.sync("delete",this,t);return t.wait||s(),r},url:function(){var t=i.result(this,"urlRoot")||i.result(this.collection,"url")||j();return this.isNew()?t:t.replace(/([^\/])$/,"$1/")+encodeURIComponent(this.id)},parse:function(t,e){return t},clone:function(){return new this.constructor(this.attributes)},isNew:function(){return!this.has(this.idAttribute)},isValid:function(t){return this._validate({},i.extend(t||{},{validate:!0}))},_validate:function(t,e){if(!e.validate||!this.validate)return!0;t=i.extend({},this.attributes,t);var n=this.validationError=this.validate(t,e)||null;return n?(this.trigger("invalid",this,n,i.extend(e,{validationError:n})),!1):!0}});var p=["keys","values","pairs","invert","pick","omit"];i.each(p,function(t){d.prototype[t]=function(){var e=o.call(arguments);return e.unshift(this.attributes),i[t].apply(i,e)}});var f=e.Collection=function(t,e){e||(e={}),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,i.extend({silent:!0},e))},g={add:!0,remove:!0,merge:!0},m={add:!0,remove:!1};i.extend(f.prototype,a,{model:d,initialize:function(){},toJSON:function(t){return this.map(function(e){return e.toJSON(t)})},sync:function(){return e.sync.apply(this,arguments)},add:function(t,e){return this.set(t,i.extend({merge:!1},e,m))},remove:function(t,e){var n=!i.isArray(t);t=n?[t]:i.clone(t),e||(e={});var s,r,o,a;for(s=0,r=t.length;r>s;s++)a=t[s]=this.get(t[s]),a&&(delete this._byId[a.id],delete this._byId[a.cid],o=this.indexOf(a),this.models.splice(o,1),this.length--,e.silent||(e.index=o,a.trigger("remove",a,this,e)),this._removeReference(a,e));return n?t[0]:t},set:function(t,e){e=i.defaults({},e,g),e.parse&&(t=this.parse(t,e));var n=!i.isArray(t);t=n?t?[t]:[]:i.clone(t);var s,r,o,a,l,u,h,c=e.at,p=this.model,f=this.comparator&&null==c&&e.sort!==!1,m=i.isString(this.comparator)?this.comparator:null,v=[],y=[],b={},w=e.add,_=e.merge,x=e.remove,C=!f&&w&&x?[]:!1;for(s=0,r=t.length;r>s;s++){if(l=t[s]||{},o=l instanceof d?a=l:l[p.prototype.idAttribute||"id"],u=this.get(o))x&&(b[u.cid]=!0),_&&(l=l===a?a.attributes:l,e.parse&&(l=u.parse(l,e)),u.set(l,e),f&&!h&&u.hasChanged(m)&&(h=!0)),t[s]=u;else if(w){if(a=t[s]=this._prepareModel(l,e),!a)continue;v.push(a),this._addReference(a,e)}a=u||a,!C||!a.isNew()&&b[a.id]||C.push(a),b[a.id]=!0}if(x){for(s=0,r=this.length;r>s;++s)b[(a=this.models[s]).cid]||y.push(a);y.length&&this.remove(y,e)}if(v.length||C&&C.length)if(f&&(h=!0),this.length+=v.length,null!=c)for(s=0,r=v.length;r>s;s++)this.models.splice(c+s,0,v[s]);else{C&&(this.models.length=0);var S=C||v;for(s=0,r=S.length;r>s;s++)this.models.push(S[s])}if(h&&this.sort({silent:!0}),!e.silent){for(s=0,r=v.length;r>s;s++)(a=v[s]).trigger("add",a,this,e);(h||C&&C.length)&&this.trigger("sort",this,e)}return n?t[0]:t},reset:function(t,e){e||(e={});for(var n=0,s=this.models.length;s>n;n++)this._removeReference(this.models[n],e);return e.previousModels=this.models,this._reset(),t=this.add(t,i.extend({silent:!0},e)),e.silent||this.trigger("reset",this,e),t},push:function(t,e){return this.add(t,i.extend({at:this.length},e))},pop:function(t){var e=this.at(this.length-1);return this.remove(e,t),e},unshift:function(t,e){return this.add(t,i.extend({at:0},e))},shift:function(t){var e=this.at(0);return this.remove(e,t),e},slice:function(){return o.apply(this.models,arguments)},get:function(t){return null!=t?this._byId[t]||this._byId[t.id]||this._byId[t.cid]:void 0},at:function(t){return this.models[t]},where:function(t,e){return i.isEmpty(t)?e?void 0:[]:this[e?"find":"filter"](function(e){for(var i in t)if(t[i]!==e.get(i))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={}),i.isString(this.comparator)||1===this.comparator.length?this.models=this.sortBy(this.comparator,this):this.models.sort(i.bind(this.comparator,this)),t.silent||this.trigger("sort",this,t),this},pluck:function(t){return i.invoke(this.models,"get",t)},fetch:function(t){t=t?i.clone(t):{},void 0===t.parse&&(t.parse=!0);var e=t.success,n=this;return t.success=function(i){var s=t.reset?"reset":"set";n[s](i,t),e&&e(n,i,t),n.trigger("sync",n,i,t)},H(this,t),this.sync("read",this,t)},create:function(t,e){if(e=e?i.clone(e):{},!(t=this._prepareModel(t,e)))return!1;e.wait||this.add(t,e);var n=this,s=e.success;return e.success=function(t,i){e.wait&&n.add(t,e),s&&s(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 d)return t;e=e?i.clone(e):{},e.collection=this;var n=new this.model(t,e);return n.validationError?(this.trigger("invalid",this,n.validationError,e),!1):n},_addReference:function(t,e){this._byId[t.cid]=t,null!=t.id&&(this._byId[t.id]=t),t.collection||(t.collection=this),t.on("all",this._onModelEvent,this)},_removeReference:function(t,e){this===t.collection&&delete t.collection,t.off("all",this._onModelEvent,this)},_onModelEvent:function(t,e,i,n){("add"!==t&&"remove"!==t||i===this)&&("destroy"===t&&this.remove(e,n),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 v=["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","difference","indexOf","shuffle","lastIndexOf","isEmpty","chain","sample"];i.each(v,function(t){f.prototype[t]=function(){var e=o.call(arguments);return e.unshift(this.models),i[t].apply(i,e)}});var y=["groupBy","countBy","sortBy","indexBy"];i.each(y,function(t){f.prototype[t]=function(e,n){var s=i.isFunction(e)?e:function(t){return t.get(e)};return i[t](this.models,s,n)}});var b=e.View=function(t){this.cid=i.uniqueId("view"),t||(t={}),i.extend(this,i.pick(t,_)),this._ensureElement(),this.initialize.apply(this,arguments),this.delegateEvents()},w=/^(\S+)\s*(.*)$/,_=["model","collection","el","id","attributes","className","tagName","events"];i.extend(b.prototype,a,{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,i){return this.$el&&this.undelegateEvents(),this.$el=t instanceof e.$?t:e.$(t),this.el=this.$el[0],i!==!1&&this.delegateEvents(),this},delegateEvents:function(t){if(!t&&!(t=i.result(this,"events")))return this;this.undelegateEvents();for(var e in t){var n=t[e];if(i.isFunction(n)||(n=this[t[e]]),n){var s=e.match(w),r=s[1],o=s[2];n=i.bind(n,this),r+=".delegateEvents"+this.cid,""===o?this.$el.on(r,n):this.$el.on(r,o,n)}}return this},undelegateEvents:function(){return this.$el.off(".delegateEvents"+this.cid),this},_ensureElement:function(){if(this.el)this.setElement(i.result(this,"el"),!1);else{var t=i.extend({},i.result(this,"attributes"));this.id&&(t.id=i.result(this,"id")),this.className&&(t["class"]=i.result(this,"className"));var n=e.$("<"+i.result(this,"tagName")+">").attr(t);this.setElement(n,!1)}}}),e.sync=function(t,n,s){var r=C[t];i.defaults(s||(s={}),{emulateHTTP:e.emulateHTTP,emulateJSON:e.emulateJSON});var o={type:r,dataType:"json"};if(s.url||(o.url=i.result(n,"url")||j()),null!=s.data||!n||"create"!==t&&"update"!==t&&"patch"!==t||(o.contentType="application/json",o.data=JSON.stringify(s.attrs||n.toJSON(s))),s.emulateJSON&&(o.contentType="application/x-www-form-urlencoded",o.data=o.data?{model:o.data}:{}),s.emulateHTTP&&("PUT"===r||"DELETE"===r||"PATCH"===r)){o.type="POST",s.emulateJSON&&(o.data._method=r);var a=s.beforeSend;s.beforeSend=function(t){return t.setRequestHeader("X-HTTP-Method-Override",r),a?a.apply(this,arguments):void 0}}"GET"===o.type||s.emulateJSON||(o.processData=!1),"PATCH"===o.type&&x&&(o.xhr=function(){return new ActiveXObject("Microsoft.XMLHTTP")});var l=s.xhr=e.ajax(i.extend(o,s));return n.trigger("request",n,l,s),l};var x=!("undefined"==typeof window||!window.ActiveXObject||window.XMLHttpRequest&&(new XMLHttpRequest).dispatchEvent),C={create:"POST",update:"PUT",patch:"PATCH","delete":"DELETE",read:"GET"};e.ajax=function(){return e.$.ajax.apply(e.$,arguments)};var S=e.Router=function(t){t||(t={}),t.routes&&(this.routes=t.routes),this._bindRoutes(),this.initialize.apply(this,arguments)},k=/\((.*?)\)/g,T=/(\(\?)?:\w+/g,E=/\*\w+/g,A=/[\-{}\[\]+?.,\\\^$|#\s]/g;i.extend(S.prototype,a,{initialize:function(){},route:function(t,n,s){i.isRegExp(t)||(t=this._routeToRegExp(t)),i.isFunction(n)&&(s=n,n=""),s||(s=this[n]);var r=this;return e.history.route(t,function(i){var o=r._extractParameters(t,i);r.execute(s,o),r.trigger.apply(r,["route:"+n].concat(o)),r.trigger("route",n,o),e.history.trigger("route",r,n,o)}),this},execute:function(t,e){t&&t.apply(this,e)},navigate:function(t,i){return e.history.navigate(t,i),this},_bindRoutes:function(){if(this.routes){this.routes=i.result(this,"routes");for(var t,e=i.keys(this.routes);null!=(t=e.pop());)this.route(t,this.routes[t]); }},_routeToRegExp:function(t){return t=t.replace(A,"\\$&").replace(k,"(?:$1)?").replace(T,function(t,e){return e?t:"([^/?]+)"}).replace(E,"([^?]*?)"),new RegExp("^"+t+"(?:\\?([\\s\\S]*))?$")},_extractParameters:function(t,e){var n=t.exec(e).slice(1);return i.map(n,function(t,e){return e===n.length-1?t||null:t?decodeURIComponent(t):null})}});var N=e.History=function(){this.handlers=[],i.bindAll(this,"checkUrl"),"undefined"!=typeof window&&(this.location=window.location,this.history=window.history)},O=/^[#\/]|\s+$/g,M=/^\/+|\/+$/g,D=/msie [\w.]+/,P=/\/$/,R=/#.*$/;N.started=!1,i.extend(N.prototype,a,{interval:50,atRoot:function(){return this.location.pathname.replace(/[^\/]$/,"$&/")===this.root},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=decodeURI(this.location.pathname+this.location.search);var i=this.root.replace(P,"");t.indexOf(i)||(t=t.slice(i.length))}else t=this.getHash();return t.replace(O,"")},start:function(t){if(N.started)throw new Error("Backbone.history has already been started");N.started=!0,this.options=i.extend({root:"/"},this.options,t),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(),s=document.documentMode,r=D.exec(navigator.userAgent.toLowerCase())&&(!s||7>=s);if(this.root=("/"+this.root+"/").replace(M,"/"),r&&this._wantsHashChange){var o=e.$('
")}),a.show({backdrop:!0})}var r=t,o=function(t){this.$overlay=t.overlay,this.$dialog=t.dialog,this.$header=this.$dialog.find(".modal-header"),this.$body=this.$dialog.find(".modal-body"),this.$footer=this.$dialog.find(".modal-footer"),this.$backdrop=t.backdrop,this.$header.find(".close").on("click",r.proxy(this.hide,this))};r.extend(o.prototype,{setContent:function(t){this.$header.hide(),t.title&&(this.$header.find(".title").html(t.title),this.$header.show()),t.closeButton?(this.$header.find(".close").show(),this.$header.show()):this.$header.find(".close").hide(),this.$footer.hide();var e=this.$footer.find(".buttons").html("");t.buttons&&(r.each(t.buttons,function(t,i){e.append(r(" ").text(t).click(i)).append(" ")}),this.$footer.show());var i=this.$footer.find(".extra_buttons").html("");t.extra_buttons&&(r.each(t.extra_buttons,function(t,e){i.append(r("").text(t).click(e)).append(" ")}),this.$footer.show());var n=t.body;"progress"==n&&(n=r("
")),this.$body.html(n)},show:function(t,e){this.$dialog.is(":visible")||(t.backdrop?this.$backdrop.addClass("in"):this.$backdrop.removeClass("in"),this.$overlay.show(),this.$dialog.show(),this.$overlay.addClass("in"),this.$body.css("min-width",this.$body.width()),this.$body.css("max-height",r(window).height()-this.$footer.outerHeight()-this.$header.outerHeight()-parseInt(this.$dialog.css("padding-top"),10)-parseInt(this.$dialog.css("padding-bottom"),10))),e&&e()},hide:function(){var t=this;t.$dialog.fadeOut(function(){t.$overlay.hide(),t.$backdrop.removeClass("in"),t.$body.children().remove(),t.$body.css("min-width",void 0)})}});var a;return r(function(){a=new o({overlay:r("#top-modal"),dialog:r("#top-modal-dialog"),backdrop:r("#top-modal-backdrop")})}),{Modal:o,hide_modal:e,show_modal:i,show_message:n,show_in_overlay:s}}.apply(e,n),!(void 0!==s&&(t.exports=s))},function(t,e,i){var n,s;(function(r,o,a){n=[i(90),i(11),i(8),i(6)],s=function(t,e,i,n){var s=r.View.extend(n.LoggableMixin).extend({_logNamespace:"layout",el:"body",className:"full-content",_panelIds:["left","center","right"],defaultOptions:{message_box_visible:!1,message_box_content:"",message_box_class:"info",show_inactivity_warning:!1,inactivity_box_content:""},initialize:function(e){this.log(this+".initialize:",e),o.extend(this,o.pick(e,this._panelIds)),this.options=o.defaults(o.omit(e,this._panelIds),this.defaultOptions),Galaxy.modal=this.modal=new i.View,this.masthead=new t.View(this.options.config),this.$el.attr("scroll","no"),this.$el.html(this._template()),this.$el.append(this.masthead.$el),this.$el.append(this.modal.$el),this.$messagebox=this.$("#messagebox"),this.$inactivebox=this.$("#inactivebox")},render:function(){return a(".select2-hidden-accessible").remove(),this.log(this+".render:"),this.masthead.render(),this.renderMessageBox(),this.renderInactivityBox(),this.renderPanels(),this},renderMessageBox:function(){if(this.options.message_box_visible){var t=this.options.message_box_content||"",e=this.options.message_box_class||"info";this.$el.addClass("has-message-box"),this.$messagebox.attr("class","panel-"+e+"-message").html(t).toggle(!!t).show()}else this.$el.removeClass("has-message-box"),this.$messagebox.hide();return this},renderInactivityBox:function(){if(this.options.show_inactivity_warning){var t=this.options.inactivity_box_content||"",e=a("").attr("href",Galaxy.root+"user/resend_verification").text("Resend verification");this.$el.addClass("has-inactivity-box"),this.$inactivebox.html(t+" ").append(e).toggle(!!t).show()}else this.$el.removeClass("has-inactivity-box"),this.$inactivebox.hide();return this},renderPanels:function(){var t=this;return this._panelIds.forEach(function(e){o.has(t,e)&&(t[e].setElement("#"+e),t[e].render())}),this.left||this.center.$el.css("left",0),this.right||this.center.$el.css("right",0),this},_template:function(){return['
','
','
','
',this.left?'
':"",this.center?'
':"",this.right?'",'
'].join("")},hideSidePanels:function(){this.left&&this.left.hide(),this.right&&this.right.hide()},toString:function(){return"PageLayoutView"}});return{PageLayoutView:s}}.apply(e,n),!(void 0!==s&&(t.exports=s))}).call(e,i(2),i(3),i(1))},function(t,e,i){(function(t){!function(t,e){var i,n;return n=e.document,i=function(){function i(i){var n;try{n=e.localStorage}catch(s){n=!1}this._options=t.extend({name:"tour",steps:[],container:"body",autoscroll:!0,keyboard:!0,storage:n,debug:!1,backdrop:!1,backdropPadding:0,redirect:!0,orphan:!1,duration:!1,delay:!1,basePath:"",template:'',afterSetState:function(t,e){},afterGetState:function(t,e){},afterRemoveState:function(t){},onStart:function(t){},onEnd:function(t){},onShow:function(t){},onShown:function(t){},onHide:function(t){},onHidden:function(t){},onNext:function(t){},onPrev:function(t){},onPause:function(t,e){},onResume:function(t,e){}},i),this._force=!1,this._inited=!1,this.backdrop={overlay:null,$element:null,$background:null,backgroundShown:!1,overlayElementShown:!1}}return i.prototype.addSteps=function(t){var e,i,n;for(i=0,n=t.length;n>i;i++)e=t[i],this.addStep(e);return this},i.prototype.addStep=function(t){return this._options.steps.push(t),this},i.prototype.getStep=function(e){return null!=this._options.steps[e]?t.extend({id:"step-"+e,path:"",placement:"right",title:"",content:"

",next:e===this._options.steps.length-1?-1:e+1,prev:e-1,animation:!0,container:this._options.container,autoscroll:this._options.autoscroll,backdrop:this._options.backdrop,backdropPadding:this._options.backdropPadding,redirect:this._options.redirect,orphan:this._options.orphan,duration:this._options.duration,delay:this._options.delay,template:this._options.template,onShow:this._options.onShow,onShown:this._options.onShown,onHide:this._options.onHide,onHidden:this._options.onHidden,onNext:this._options.onNext,onPrev:this._options.onPrev,onPause:this._options.onPause,onResume:this._options.onResume},this._options.steps[e]):void 0},i.prototype.init=function(t){return this._force=t,this.ended()?(this._debug("Tour ended, init prevented."),this):(this.setCurrentStep(),this._initMouseNavigation(),this._initKeyboardNavigation(),this._onResize(function(t){return function(){return t.showStep(t._current)}}(this)),null!==this._current&&this.showStep(this._current),this._inited=!0,this)},i.prototype.start=function(t){var e;return null==t&&(t=!1),this._inited||this.init(t),null===this._current&&(e=this._makePromise(null!=this._options.onStart?this._options.onStart(this):void 0),this._callOnPromiseDone(e,this.showStep,0)),this},i.prototype.next=function(){var t;return t=this.hideStep(this._current),this._callOnPromiseDone(t,this._showNextStep)},i.prototype.prev=function(){var t;return t=this.hideStep(this._current),this._callOnPromiseDone(t,this._showPrevStep)},i.prototype.goTo=function(t){var e;return e=this.hideStep(this._current),this._callOnPromiseDone(e,this.showStep,t)},i.prototype.end=function(){var i,s;return i=function(i){return function(s){return t(n).off("click.tour-"+i._options.name),t(n).off("keyup.tour-"+i._options.name),t(e).off("resize.tour-"+i._options.name),i._setState("end","yes"),i._inited=!1,i._force=!1,i._clearTimer(),null!=i._options.onEnd?i._options.onEnd(i):void 0}}(this),s=this.hideStep(this._current),this._callOnPromiseDone(s,i)},i.prototype.ended=function(){return!this._force&&!!this._getState("end")},i.prototype.restart=function(){return this._removeState("current_step"),this._removeState("end"),this.start()},i.prototype.pause=function(){var t;return t=this.getStep(this._current),t&&t.duration?(this._paused=!0,this._duration-=(new Date).getTime()-this._start,e.clearTimeout(this._timer),this._debug("Paused/Stopped step "+(this._current+1)+" timer ("+this._duration+" remaining)."),null!=t.onPause?t.onPause(this,this._duration):void 0):this},i.prototype.resume=function(){var t;return t=this.getStep(this._current),t&&t.duration?(this._paused=!1,this._start=(new Date).getTime(),this._duration=this._duration||t.duration,this._timer=e.setTimeout(function(t){return function(){return t._isLast()?t.next():t.end()}}(this),this._duration),this._debug("Started step "+(this._current+1)+" timer with duration "+this._duration),null!=t.onResume&&this._duration!==t.duration?t.onResume(this,this._duration):void 0):this},i.prototype.hideStep=function(e){var i,n,s;return(s=this.getStep(e))?(this._clearTimer(),n=this._makePromise(null!=s.onHide?s.onHide(this,e):void 0),i=function(i){return function(n){var r;return r=t(s.element),r.data("bs.popover")||r.data("popover")||(r=t("body")),r.popover("destroy").removeClass("tour-"+i._options.name+"-element tour-"+i._options.name+"-"+e+"-element"),s.reflex&&r.removeClass("tour-step-element-reflex").off(""+i._reflexEvent(s.reflex)+".tour-"+i._options.name),s.backdrop&&i._hideBackdrop(),null!=s.onHidden?s.onHidden(i):void 0}}(this),this._callOnPromiseDone(n,i),n):void 0},i.prototype.showStep=function(t){var i,s,r,o;return this.ended()?(this._debug("Tour ended, showStep prevented."),this):(o=this.getStep(t))?(r=t").parent().html()},i.prototype._reflexEvent=function(t){return"[object Boolean]"==={}.toString.call(t)?"click":t},i.prototype._reposition=function(e,i){var s,r,o,a,l,u,h;if(a=e[0].offsetWidth,r=e[0].offsetHeight,h=e.offset(),l=h.left,u=h.top,s=t(n).outerHeight()-h.top-e.outerHeight(),0>s&&(h.top=h.top+s),o=t("html").outerWidth()-h.left-e.outerWidth(),0>o&&(h.left=h.left+o),h.top<0&&(h.top=0),h.left<0&&(h.left=0),e.offset(h),"bottom"===i.placement||"top"===i.placement){if(l!==h.left)return this._replaceArrow(e,2*(h.left-l),a,"left")}else if(u!==h.top)return this._replaceArrow(e,2*(h.top-u),r,"top")},i.prototype._center=function(i){return i.css("top",t(e).outerHeight()/2-i.outerHeight()/2)},i.prototype._replaceArrow=function(t,e,i,n){return t.find(".arrow").css(n,e?50*(1-e/i)+"%":"")},i.prototype._scrollIntoView=function(i,n){var s,r,o,a,l,u;return s=t(i),s.length?(r=t(e),a=s.offset().top,u=r.height(),l=Math.max(0,a-u/2),this._debug("Scroll into view. ScrollTop: "+l+". Element offset: "+a+". Window height: "+u+"."),o=0,t("body, html").stop(!0,!0).animate({scrollTop:Math.ceil(l)},function(t){return function(){return 2===++o?(n(),t._debug("Scroll into view.\nAnimation end element offset: "+s.offset().top+".\nWindow height: "+r.height()+".")):void 0}}(this))):n()},i.prototype._onResize=function(i,n){return t(e).on("resize.tour-"+this._options.name,function(){return clearTimeout(n),n=setTimeout(i,100)})},i.prototype._initMouseNavigation=function(){var e;return e=this,t(n).off("click.tour-"+this._options.name,".popover.tour-"+this._options.name+" *[data-role='prev']").off("click.tour-"+this._options.name,".popover.tour-"+this._options.name+" *[data-role='next']").off("click.tour-"+this._options.name,".popover.tour-"+this._options.name+" *[data-role='end']").off("click.tour-"+this._options.name,".popover.tour-"+this._options.name+" *[data-role='pause-resume']").on("click.tour-"+this._options.name,".popover.tour-"+this._options.name+" *[data-role='next']",function(t){return function(e){return e.preventDefault(),t.next()}}(this)).on("click.tour-"+this._options.name,".popover.tour-"+this._options.name+" *[data-role='prev']",function(t){return function(e){return e.preventDefault(),t.prev()}}(this)).on("click.tour-"+this._options.name,".popover.tour-"+this._options.name+" *[data-role='end']",function(t){return function(e){return e.preventDefault(),t.end()}}(this)).on("click.tour-"+this._options.name,".popover.tour-"+this._options.name+" *[data-role='pause-resume']",function(i){var n;return i.preventDefault(),n=t(this),n.text(e._paused?n.data("pause-text"):n.data("resume-text")),e._paused?e.resume():e.pause()})},i.prototype._initKeyboardNavigation=function(){return this._options.keyboard?t(n).on("keyup.tour-"+this._options.name,function(t){return function(e){if(e.which)switch(e.which){case 39:return e.preventDefault(),t._isLast()?t.next():t.end();case 37:if(e.preventDefault(),t._current>0)return t.prev();break;case 27:return e.preventDefault(),t.end()}}}(this)):void 0},i.prototype._makePromise=function(e){return e&&t.isFunction(e.then)?e:null},i.prototype._callOnPromiseDone=function(t,e,i){return t?t.then(function(t){return function(n){return e.call(t,i)}}(this)):e.call(this,i)},i.prototype._showBackdrop=function(e){return this.backdrop.backgroundShown?void 0:(this.backdrop=t("
",{"class":"tour-backdrop"}),this.backdrop.backgroundShown=!0,t("body").append(this.backdrop))},i.prototype._hideBackdrop=function(){return this._hideOverlayElement(),this._hideBackground()},i.prototype._hideBackground=function(){return this.backdrop?(this.backdrop.remove(),this.backdrop.overlay=null,this.backdrop.backgroundShown=!1):void 0},i.prototype._showOverlayElement=function(e){var i,n;return i=t(e.element),i&&0!==i.length&&!this.backdrop.overlayElementShown?(this.backdrop.overlayElementShown=!0,this.backdrop.$element=i.addClass("tour-step-backdrop"),this.backdrop.$background=t("
",{"class":"tour-step-background"}),n={width:i.innerWidth(),height:i.innerHeight(),offset:i.offset()},this.backdrop.$background.appendTo("body"),e.backdropPadding&&(n=this._applyBackdropPadding(e.backdropPadding,n)),this.backdrop.$background.width(n.width).height(n.height).offset(n.offset)):void 0},i.prototype._hideOverlayElement=function(){return this.backdrop.overlayElementShown?(this.backdrop.$element.removeClass("tour-step-backdrop"),this.backdrop.$background.remove(),this.backdrop.$element=null,this.backdrop.$background=null,this.backdrop.overlayElementShown=!1):void 0},i.prototype._applyBackdropPadding=function(t,e){return"object"==typeof t?(null==t.top&&(t.top=0),null==t.right&&(t.right=0),null==t.bottom&&(t.bottom=0),null==t.left&&(t.left=0),e.offset.top=e.offset.top-t.top,e.offset.left=e.offset.left-t.left,e.width=e.width+t.left+t.right,e.height=e.height+t.top+t.bottom):(e.offset.top=e.offset.top-t,e.offset.left=e.offset.left-t,e.width=e.width+2*t,e.height=e.height+2*t),e},i.prototype._clearTimer=function(){return e.clearTimeout(this._timer),this._timer=null,this._duration=null},i}(),e.Tour=i}(t,window)}).call(e,i(1))},function(t,e,i){(function(t){/*! jQuery UI - v1.9.1 - 2012-10-29 +},_templateHeader:function(t){return['
','
','
','
',e.escape(this.title),"
","
","
"].join("")},_templateBody:function(t){return'
'},_templateFooter:function(t){return['