epmc
Version:
For retrieving article metadata from Europe PMC (http://www.europepmc.org). Covers all of PubMed (updated daily) and 3 million full text articles and other sources. A single article or list view can be returned.
2 lines • 118 kB
JavaScript
!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.biojsVisPmccitation=t()}}(function(){var t;return function e(t,n,i){function r(s,a){if(!n[s]){if(!t[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(o)return o(s,!0);var u=new Error("Cannot find module '"+s+"'");throw u.code="MODULE_NOT_FOUND",u}var c=n[s]={exports:{}};t[s][0].call(c.exports,function(e){var n=t[s][1][e];return r(n?n:e)},c,c.exports,e,t,n,i)}return n[s].exports}for(var o="function"==typeof require&&require,s=0;s<i.length;s++)r(i[s]);return r}({1:[function(t,e,n){var r,o=t("jquery"),s=t("js-extend").extend,a=t("js-class");e.exports=r=a({constructor:function(t){s(this.opt,t),"string"==typeof this.opt.target?this._container=o("#"+this.opt.target):(this.opt.target="biojs_Citation_"+this.getId(),this._container=o('<div id="'+this.opt.target+'"></div>')),this._container.addClass("Citation");var e=this.opt.width,n=this.opt.height;void 0!=e&&this._container.width(e),void 0!=n&&this._container.height(n),void 0==n?this.opt.collapsable=!1:this.opt.collapsable=!0,this.resetContainer()},opt:{target:"YourOwnDivId",citation_id:void 0,source:void 0,restEpmcUrl:"https://www.ebi.ac.uk/europepmc/webservices/rest/search?",height:void 0,width:void 0,loadingStatusImage:"../css/images/ajax-loader-1.gif",collapsable:!0,showAbstract:!0,elementOrder:"TITLE_FIRST",displayStyle:"FULL_STYLE",numRowCompact:4,logoImage:"http://www.europepmc.org/docs/images/europe_pmc_standard.jpg"},_innerWidth:0,_tempLabel:"",eventTypes:["onRequestError","onCitationLoaded"],resetContainer:function(){this._container.html(""),this._datacontainer=o('<div class="epmc_Citation_data_container"></div>').appendTo(this._container),this._datacontainer.width(this.opt.width),void 0!=this.opt.height&&this._datacontainer.height(this.opt.height),this._logoContainer=o('<div class="epmc_display_container"></div>').appendTo(this._datacontainer),this._logoContainer.width(this.opt.width-10),this.opt.displayStyle==r.TITLE_ONLY_STYLE?this._titleContainer=o('<div class="epmc_Citation_title"></div>').appendTo(this._datacontainer):(this.opt.elementOrder==r.AUTHORS_FIRST?(this._authorsContainer=o('<div class="epmc_Citation_authors"></div>').appendTo(this._datacontainer),this._subContainer=o('<div class="epmc_Citation_subdata"></div>').appendTo(this._datacontainer),this._titleContainer=o('<div class="epmc_Citation_title"></div>').appendTo(this._subContainer),this._journalContainer=o('<div class="epmc_Citation_journal"></div>').appendTo(this._subContainer),this._sourceContainer=o('<div class="epmc_Citation_source"></div>').appendTo(this._subContainer)):(this._titleContainer=o('<div class="epmc_Citation_title"></div>').appendTo(this._datacontainer),this._subContainer=o('<div class="epmc_Citation_subdata"></div>').appendTo(this._datacontainer),this._authorsContainer=o('<div class="epmc_Citation_authors"></div>').appendTo(this._subContainer),this._journalContainer=o('<div class="epmc_Citation_journal"></div>').appendTo(this._subContainer),this._sourceContainer=o('<div class="epmc_Citation_source"></div>').appendTo(this._subContainer)),this.opt.showAbstract&&(this._abstractContainer=o('<div class="epmc_Citation_abstract"></div>').appendTo(this._subContainer))),null!=this.opt.loadingStatusImage&&""!=this.opt.loadingStatusImage&&(this._loadingContainer=o('<div class="epmc_Citation_loading_image"></div>').appendTo(this._datacontainer),void 0!=this.opt.height&&this._loadingContainer.height(this.opt.height),this._loadingContainer.width(this.opt.width))},load:function(){this.loadCitation()},loadCitation:function(){if(void 0==this.opt.width||0==this.opt.width)this.trigger(r.EVT_ON_REQUEST_ERROR,{error:"width parameter mandatory"});else if(void 0==this.opt.source||""==this.opt.source)this.trigger(r.EVT_ON_REQUEST_ERROR,{error:"source parameter mandatory"});else if(void 0==this.opt.citation_id||""==this.opt.citation_id)this.trigger(r.EVT_ON_REQUEST_ERROR,{error:"citation_id parameter mandatory"});else{this.resetContainer();var t="";if(this.opt.source==r.PMC_SOURCE?t="PMCID:"+this.opt.citation_id:this.opt.source==r.DOI_SOURCE?t="DOI:"+this.opt.citation_id:this.opt.source!=r.MED_SOURCE&&this.opt.source!=r.PAT_SOURCE&&this.opt.source!=r.AGR_SOURCE&&this.opt.source!=r.ETH_SOURCE&&this.opt.source!=r.HIR_SOURCE&&this.opt.source!=r.CBA_SOURCE&&this.opt.source!=r.CTX_SOURCE||(t="EXT_ID:"+this.opt.citation_id+"%20AND%20SRC:"+this.opt.source),""!=t){null!=this.opt.loadingStatusImage&&""!=this.opt.loadingStatusImage&&(this._loadingContainer.html('<img class="epmc_image_citation_loading" alt="Loading Citation SRC:'+this.opt.source+" ID:"+this.opt.citation_id+'" src="'+this.opt.loadingStatusImage+'"/>'),this._loadingContainer.css("padding-left",(this.opt.width-o("#"+this.opt.target+" img.epmc_image_citation_loading").width())/2),void 0!=this.opt.height&&this._loadingContainer.css("padding-top",(this.opt.height-o("#"+this.opt.target+" img.epmc_image_citation_loading").height())/2));var e=this.opt.restEpmcUrl+"query="+t+"&resultType=core&format=json",n=this;o.ajax({type:"GET",url:e,dataType:"json",encoding:"UTF-8",contentType:"text/plain; charset=UTF-8",success:function(t){null!=n.opt.loadingStatusImage&&""!=n.opt.loadingStatusImage&&n._loadingContainer.hide(),t.hitCount>0?(n.buildPanel(t),n.trigger(r.EVT_ON_CITATION_LOADED,{})):n.trigger(r.EVT_ON_REQUEST_ERROR,{error:"Impossible to find a citation identified by id "+n.opt.citation_id+" and source "+n.opt.source})},error:function(t){null!=n.opt.loadingStatusImage&&""!=n.opt.loadingStatusImage&&n._loadingContainer.hide(),n.trigger(r.EVT_ON_REQUEST_ERROR,{error:"Generic error"})}})}else this.trigger(r.EVT_ON_REQUEST_ERROR,{error:"Source "+this.opt.source+" not recognized"})}},buildPanel:function(t){null!=this.opt.logoImage&&""!=this.opt.logoImage&&this._logoContainer.html('<img id="epmc_logo_single" src="'+this.opt.logoImage+'">'),this._innerWidth=this.opt.width+17;var e=t.resultList.result[0],n=!0;if(this.opt.displayStyle==r.TITLE_ONLY_STYLE){var i=this.getAbstractUrl(e);this._titleContainer.html('<a class="epmc_citation_link" href="'+i+'">'+e.title+"</a>")}else if(this.opt.elementOrder==r.AUTHORS_FIRST){var s=0,a=0;if(n){var l=this._authorsContainer.css("font-size"),u=this._authorsContainer.css("font-family"),c=this.getAuthorsElement(e,l,s,u);a=this.textWidth(o('<span style="font-family:'+u+";font-size:"+l+'px;">'+this._tempLabel+"</span>")),s+=Math.ceil(a/this._innerWidth),this._authorsContainer.html(c)}if(this.opt.displayStyle==r.COMPACT_STYLE&&(n=s+1<=this.opt.numRowCompact),n){var i=this.getAbstractUrl(e),p=this._titleContainer.css("font-size"),f=this._titleContainer.css("font-family"),h=this.getLabelTitle(e,p,s,f);a=this.textWidth(o('<span style="font-family:'+f+";font-size:"+p+'px;">'+h+"</span>")),s+=Math.ceil(a/this._innerWidth),this._titleContainer.html('<a class="epmc_citation_link" href="'+i+'">'+h+"</a>")}if(this.opt.displayStyle==r.COMPACT_STYLE&&(n=s+1<=this.opt.numRowCompact),n){var d=this.getSourceElement(e);this._sourceContainer.html(d),s+=1}if(this.opt.displayStyle==r.COMPACT_STYLE&&(n=s+1<=this.opt.numRowCompact),n){var m=this.getJournalElement(e);this._journalContainer.html(m),s+=1}}else if(this.opt.elementOrder==r.TITLE_FIRST){if(s=0,a=0,n){var i=this.getAbstractUrl(e),p=this._titleContainer.css("font-size"),f=this._titleContainer.css("font-family"),h=this.getLabelTitle(e,p,s,f);a=this.textWidth(o('<span style="font-family:'+f+";font-size:"+p+'px;">'+h+"</span>")),s+=Math.ceil(a/this._innerWidth),this._titleContainer.html('<a class="epmc_citation_link" href="'+i+'">'+h+"</a>")}if(this.opt.displayStyle==r.COMPACT_STYLE&&(n=s+1<=this.opt.numRowCompact),n){var l=this._authorsContainer.css("font-size"),u=this._authorsContainer.css("font-family"),c=this.getAuthorsElement(e,l,s,u);a=this.textWidth(o('<span style="font-family:'+u+";font-size:"+l+'px;">'+this._tempLabel+"</span>")),s+=Math.ceil(a/this._innerWidth),this._authorsContainer.html(c)}if(this.opt.displayStyle==r.COMPACT_STYLE&&(n=s+1<=this.opt.numRowCompact),n){var m=this.getJournalElement(e);this._journalContainer.html(m),s+=1}if(this.opt.displayStyle==r.COMPACT_STYLE&&(n=s+1<=this.opt.numRowCompact),n){var d=this.getSourceElement(e);this._sourceContainer.html(d),s+=1}}null!=t.resultList.result[0].abstractText&&this.opt.showAbstract&&this.opt.displayStyle!=r.TITLE_ONLY_STYLE&&this._abstractContainer.html('<div class="epmc_Citation_abstract_text">'+e.abstractText+"</div>");var g;g=this.opt.collapsable?this._container.height():this._datacontainer[0].scrollHeight,this._datacontainer.css("height",""),this._container.css("height","");var v=this._container[0].scrollHeight,y=this._container,_=this._datacontainer,b=this.opt.target,x=this.opt.width,C=this.opt.collapsable;this._datacontainer.animate({maxHeight:g},500,function(){if(C&&v>g){_.css("overflow-y","scroll");var t="jQuery('#"+b+" .epmc_Citation_data_container').animate({maxHeight:"+v+"}, 500, function() {jQuery('#"+b+" .epmc_extend_data_citation').hide();jQuery('#"+b+" .epmc_collapse_data_citation').show(); });return false;",e=o('<div class="epmc_extend_data_citation"><a class="epmc_citation_link" href="#" onClick="'+t+'">Show more Data</a></div>').appendTo(y);e.width(x),t="jQuery('#"+b+" .epmc_Citation_data_container').animate({\n\rmaxHeight:"+g+"\n\r}, 500, function() {\n\r\tjQuery('#"+b+" .epmc_extend_data_citation').show();\n\r\tjQuery('#"+b+" .epmc_collapse_data_citation').hide();\n\r });return false;";var n=o('<div style="display:none" class="epmc_collapse_data_citation"><a class="epmc_citation_link" href="#" onClick="'+t+'">Show fewer Data</a></div>').appendTo(y);n.width(x)}0==C&&v>g&&(y.height(v),_.height(v))})},textWidth:function(t){var e=o("<span>"+t.html()+"</span>");e.css("font-size",t.css("font-size")).hide(),e.css("font-family",t.css("font-family")).hide(),e.css("white-space","nowrap").hide(),e.prependTo("body");var n=e.width();return e.remove(),n},getAbstractUrl:function(t){var e="";return e=t.source==r.PMC_SOURCE?"http://europepmc.org/abstract/PMC/"+t.id:t.source==r.DOI_SOURCE||t.source==r.MED_SOURCE?"http://europepmc.org/abstract/med/"+t.id:t.source==r.ETH_SOURCE?"http://europepmc.org/theses/ETH/"+t.id:t.source==r.PAT_SOURCE?"http://europepmc.org/patents/pat/"+t.id:t.source==r.HIR_SOURCE?"http://europepmc.org/guidelines/HIR/"+t.id:t.source==r.AGR_SOURCE?"http://europepmc.org/abstract/AGR/"+t.id:t.source==r.CBA_SOURCE?"http://europepmc.org/abstract/CBA/"+t.id:t.source==r.CTX_SOURCE?"http://europepmc.org/abstract/CTX/"+t.id:"http://europepmc.org/abstract/med/"+t.id},getLabelTitle:function(t,e,n,i){var s=t.title;if(this.opt.displayStyle==r.COMPACT_STYLE){var a=this.textWidth(o('<span style="font-family:'+i+";font-size:"+e+'px;">'+s+"</span>")),l=Math.ceil(a/this._innerWidth);if(l>this.opt.numRowCompact-n){var u=s.length*(this.opt.numRowCompact-n)/l;u-=3,s=s.substring(0,u),s+="..."}}return s},getSourceElement:function(t){var e="";return t.source==r.PMC_SOURCE?e="PMCID:"+t.id:t.source==r.DOI_SOURCE?e="DOI:"+t.id:t.source==r.MED_SOURCE?(e="PMID:"+t.id,null!=t.pmcid&&""!=t.pmcid&&(e+=" PMCID:"+t.pmcid)):e=t.source==r.PAT_SOURCE?"PATENT:"+t.id:t.source==r.ETH_SOURCE?"THESIS:"+t.id:t.source+":"+t.id,e},getJournalElement:function(t){var e="",n=null;void 0!=t.journalInfo&&(n=t.journalInfo.journal);var i="";if(null!=n&&(i=n.medlineAbbreviation),""!=i){var r="JOURNAL:""+i+""";e='<a class="epmc_citation_link" href="http://europepmc.org/search?query='+r+'&page=1">'+i+"</a>";var o=t.journalInfo.yearOfPublication,s=t.journalInfo.issue,a=t.journalInfo.volume,l=t.pageInfo;null==o&&null==s&&null==a||(e+=" <span>[",null!=o&&(e+=o),null!=a&&(null!=o&&(e+=", "),e+=a),null!=s&&(e+="("+s+")"),null!=l&&(e+=":"+l),e+="]</span>")}else if(void 0!=t.bookOrReportDetails&&null!=t.bookOrReportDetails.publisher){i=t.bookOrReportDetails.publisher;var r="PUBLISHER:""+i+""";e='<a class="epmc_citation_link" href="http://europepmc.org/search?query='+r+'&page=1">'+i+"</a>";var o=t.bookOrReportDetails.yearOfPublication;null!=o&&(e+="[",e+=o,e+="]")}return e},getAuthorsElement:function(t,e,n,s){var a=t.authorList.author,l="",u="",c="",p="",f="",h=0,d=0;for(i=0;i<a.length;i++)if(author=a[i],i>0&&(l+=", ",u+=", "),c=""!=author.fullName?author.fullName:""!=author.lastName?author.lastName:""!=author.collectiveName?author.collectiveName:"",void 0!=c&&""!=c)if(p=u+c,f="AUTH:""+c+""",authorsHtmlNew=l+'<a class="epmc_citation_link" href="http://europepmc.org/search?query='+f+'&page=1">'+c+"</a>",this.opt.displayStyle==r.COMPACT_STYLE){if(h=this.textWidth(o('<span style="font-family:'+s+";font-size:"+e+'px;">'+p+"</span>")),d=Math.ceil(h/this._innerWidth),d>this.opt.numRowCompact-n){d=this.opt.numRowCompact-n,l+="...",u+="...";break}u=p,l=authorsHtmlNew}else u=p,l=authorsHtmlNew;return this._tempLabel=u,l}});var l={MED_SOURCE:"MED",PMC_SOURCE:"PMC",PAT_SOURCE:"PAT",ETH_SOURCE:"ETH",HIR_SOURCE:"HIR",CTX_SOURCE:"CTX",CBA_SOURCE:"CBA",AGR_SOURCE:"AGR",DOI_SOURCE:"DOI",TITLE_FIRST:"TITLE_FIRST",AUTHORS_FIRST:"AUTHORS_FIRST",FULL_STYLE:"FULL_STYLE",COMPACT_STYLE:"COMPACT_STYLE",TITLE_ONLY_STYLE:"TITLE_ONLY_STYLE",EVT_ON_CITATION_LOADED:"onCitationLoaded",EVT_ON_REQUEST_ERROR:"onRequestError"};for(var u in l)r[u]=l[u];var c=t("biojs-events");c.mixin(r.prototype)},{"biojs-events":5,jquery:6,"js-class":7,"js-extend":8}],2:[function(t,e,n){var r,o=t("jquery"),s=t("js-extend").extend,a=t("js-class");e.exports=r=a({constructor:function(t){s(this.opt,t),"string"==typeof this.opt.target?this._container=o("#"+this.opt.target):(this.opt.target="biojs_Citation_"+this.getId(),this._container=o('<div id="'+this.opt.target+'"></div>')),this._container.addClass("Citation_list");var e=this.opt.width,n=this.opt.height;void 0!=e&&this._container.width(e),void 0!=n&&this._container.height(n),void 0==n?this.opt.collapsable=!1:this.opt.collapsable=!0,this.opt.numberResults>25&&(this.opt.numberResults=25),void 0!=this.opt.elementOrder&&""!=this.opt.elementOrder||(this.opt.elementOrder=r.TITLE_FIRST),void 0!=this.opt.displayStyle&&""!=this.opt.displayStyle||(this.opt.displayStyle=r.FULL_STYLE),this.resetListContainer()},opt:{target:"YourOwnDivId",query:void 0,restEpmcUrl:"https://www.ebi.ac.uk/europepmc/webservices/rest/search",height:void 0,width:void 0,loadingStatusImage:"../css/images/ajax-loader-1.gif",numberResults:25,collapsable:!0,elementOrder:"TITLE_FIRST",displayStyle:"FULL_STYLE",numRowCompact:4,logoImage:"http://www.europepmc.org/docs/images/europe_pmc_standard.jpg"},_innerWidth:0,_tempLabel:"",eventTypes:["onRequestError","onResultsLoaded"],resetListContainer:function(){this._container.html(""),this._citationsContainer=o('<div class="epmc_Citations_data_container"></div>').appendTo(this._container),this._citationsContainer.width(this.opt.width),void 0!=this.opt.height&&this._citationsContainer.height(this.opt.height),null!=this.opt.loadingStatusImage&&""!=this.opt.loadingStatusImage&&(this._loadingContainer=o('<div class="epmc_Results_loading_image"></div>').appendTo(this._citationsContainer),void 0!=this.opt.height&&this._loadingContainer.height(this.opt.height),this._loadingContainer.width(this.opt.width))},load:function(){this.loadResults()},loadResults:function(){if(void 0==this.opt.width||0==this.opt.width)this.trigger(r.EVT_ON_REQUEST_ERROR,{error:"width parameter mandatory"});else if(void 0==this.opt.query||""==this.opt.query)this.trigger(r.EVT_ON_REQUEST_ERROR,{error:"query parameter mandatory"});else{this.resetListContainer();var t=encodeURIComponent(this.opt.query);if(""!=t){null!=this.opt.loadingStatusImage&&""!=this.opt.loadingStatusImage&&(this._loadingContainer.html('<img class="epmc_image_citation_loading" alt="Loading Citations for query '+this.opt.query+'" src="'+this.opt.loadingStatusImage+'"/>'),this._loadingContainer.css("padding-left",(this.opt.width-o("#"+this.opt.target+" img.epmc_image_citation_loading").width())/2),void 0!=this.opt.height&&this._loadingContainer.css("padding-top",(this.opt.height-o("#"+this.opt.target+" img.epmc_image_citation_loading").height())/2));var e=this.opt.restEpmcUrl+"query="+t+"&resultType=core&format=json&page=1",n=this;o.ajax({type:"GET",url:e,dataType:"json",encoding:"UTF-8",contentType:"text/plain; charset=UTF-8",success:function(t){null!=n.opt.loadingStatusImage&&""!=n.opt.loadingStatusImage&&n._loadingContainer.hide(),t.hitCount>0?(n.buildPanel(t),n.trigger(r.EVT_ON_RESULTS_LOADED,{})):n.trigger(r.EVT_ON_REQUEST_ERROR,{error:"Impossible to find any citation matching the query "+n.opt.query})},error:function(t){null!=n.opt.loadingStatusImage&&""!=n.opt.loadingStatusImage&&n._loadingContainer.hide(),n.trigger(r.EVT_ON_REQUEST_ERROR,{error:"Generic error"})}})}else this.trigger(r.EVT_ON_REQUEST_ERROR,{error:"query parameter mandatory"})}},getAbstractUrl:function(t){var e="";return e=t.source==r.PMC_SOURCE?"http://europepmc.org/abstract/PMC/"+t.id:t.source==r.DOI_SOURCE||t.source==r.MED_SOURCE?"http://europepmc.org/abstract/med/"+t.id:t.source==r.ETH_SOURCE?"http://europepmc.org/theses/ETH/"+t.id:t.source==r.PAT_SOURCE?"http://europepmc.org/patents/pat/"+t.id:t.source==r.HIR_SOURCE?"http://europepmc.org/guidelines/HIR/"+t.id:t.source==r.AGR_SOURCE?"http://europepmc.org/abstract/AGR/"+t.id:t.source==r.CBA_SOURCE?"http://europepmc.org/abstract/CBA/"+t.id:t.source==r.CTX_SOURCE?"http://europepmc.org/abstract/CTX/"+t.id:"http://europepmc.org/abstract/med/"+t.id},getLabelTitle:function(t,e,n,i){var s=t.title;if(this.opt.displayStyle==r.COMPACT_STYLE){var a=this.textWidth(o('<span style="font-family:'+i+";font-size:"+e+'px;">'+s+"</span>")),l=Math.ceil(a/this._innerWidth);if(l>this.opt.numRowCompact-n){var u=s.length*(this.opt.numRowCompact-n)/l;u-=3,s=s.substring(0,u),s+="..."}}return s},getSourceElement:function(t){var e="";return t.source==r.PMC_SOURCE?e="PMCID:"+t.id:t.source==r.DOI_SOURCE?e="DOI:"+t.id:t.source==r.MED_SOURCE?(e="PMID:"+t.id,null!=t.pmcid&&""!=t.pmcid&&(e+=" PMCID:"+t.pmcid)):e=t.source==r.PAT_SOURCE?"PATENT:"+t.id:t.source==r.ETH_SOURCE?"THESIS:"+t.id:t.source+":"+t.id,e},getJournalElement:function(t){var e="",n=null;void 0!=t.journalInfo&&(n=t.journalInfo.journal);var i="";if(null!=n&&(i=n.medlineAbbreviation),""!=i){var r="JOURNAL:""+i+""";e='<a class="epmc_citation_link" href="http://europepmc.org/search?query='+r+'&page=1">'+i+"</a>";var o=t.journalInfo.yearOfPublication,s=t.journalInfo.issue,a=t.journalInfo.volume,l=t.pageInfo;null==o&&null==s&&null==a||(e+=" <span>[",null!=o&&(e+=o),null!=a&&(null!=o&&(e+=", "),e+=a),null!=s&&(e+="("+s+")"),null!=l&&(e+=":"+l),e+="]</span>")}else if(void 0!=t.bookOrReportDetails&&null!=t.bookOrReportDetails.publisher){i=t.bookOrReportDetails.publisher;var r="PUBLISHER:""+i+""";e='<a class="epmc_citation_link" href="http://europepmc.org/search?query='+r+'&page=1">'+i+"</a>";var o=t.bookOrReportDetails.yearOfPublication;null!=o&&(e+="<span>[",e+=o,e+="]</span>")}return e},getAuthorsElement:function(t,e,n,s){var a=t.authorList.author,l="",u="",c="",p="",f="",h=0,d=0;for(i=0;i<a.length;i++)if(author=a[i],i>0&&(l+=", ",u+=", "),c=""!=author.fullName?author.fullName:""!=author.lastName?author.lastName:""!=author.collectiveName?author.collectiveName:"",void 0!=c&&""!=c)if(p=u+c,f="AUTH:""+c+""",authorsHtmlNew=l+'<a class="epmc_citation_link" href="http://europepmc.org/search?query='+f+'&page=1">'+c+"</a>",this.opt.displayStyle==r.COMPACT_STYLE){if(h=this.textWidth(o('<span style="font-family:'+s+";font-size:"+e+'px;">'+p+"</span>")),d=Math.ceil(h/this._innerWidth),d>this.opt.numRowCompact-n){d=this.opt.numRowCompact-n,l+="...",u+="...";break}u=p,l=authorsHtmlNew}else u=p,l=authorsHtmlNew;return this._tempLabel=u,l},buildPanel:function(t){this._citationsContainer.css("border","0px");var e;e=t.hitCount>this.opt.numberResults?this.opt.numberResults:t.hitCount,null!=this.opt.logoImage&&""!=this.opt.logoImage&&this.opt.width>=150?o('<div class="epmc_display_container"><span>Displaying '+e+" results of "+t.hitCount+'</span> <img id="epmc_logo" src="'+this.opt.logoImage+'"></div>').appendTo(this._citationsContainer):o('<div class="epmc_display_container"><span>Displaying '+e+" results of "+t.hitCount+"</span></div>").appendTo(this._citationsContainer),o(".epmc_display_container").width(this.opt.width-10);var n=t.resultList.result.length;n>this.opt.numberResults&&(n=this.opt.numberResults);var i=0,s=0,a=!0;for(this._innerWidth=this.opt.width+17,k=0;k<n;k++){a=!0,resultElement=t.resultList.result[k],citationContainer=o('<div class="epmc_Citation_container"></div>').appendTo(this._citationsContainer);var l,u,c,p,f;if(this.opt.displayStyle==r.TITLE_ONLY_STYLE?l=o('<div class="epmc_Citation_title"></div>').appendTo(citationContainer):this.opt.elementOrder==r.AUTHORS_FIRST?(u=o('<div class="epmc_Citation_authors"></div>').appendTo(citationContainer),c=o('<div class="epmc_Citation_subdata"></div>').appendTo(citationContainer),l=o('<div class="epmc_Citation_title"></div>').appendTo(c),p=o('<div class="epmc_Citation_journal"></div>').appendTo(c),f=o('<div class="epmc_Citation_source"></div>').appendTo(c)):(l=o('<div class="epmc_Citation_title"></div>').appendTo(citationContainer),c=o('<div class="epmc_Citation_subdata"></div>').appendTo(citationContainer),u=o('<div class="epmc_Citation_authors"></div>').appendTo(c),p=o('<div class="epmc_Citation_journal"></div>').appendTo(c),f=o('<div class="epmc_Citation_source"></div>').appendTo(c)),this.opt.displayStyle==r.TITLE_ONLY_STYLE){var h=this.getAbstractUrl(resultElement);l.html('<a class="epmc_citation_link" href="'+h+'">'+resultElement.title+"</a>")}else if(this.opt.elementOrder==r.AUTHORS_FIRST){if(i=0,s=0,a){var d=u.css("font-size"),m=u.css("font-family"),g=this.getAuthorsElement(resultElement,d,i,m);s=this.textWidth(o('<span style="font-family:'+m+";font-size:"+d+'px;">'+this._tempLabel+"</span>")),i+=Math.ceil(s/this._innerWidth),u.html(g)}if(this.opt.displayStyle==r.COMPACT_STYLE&&(a=i+1<=this.opt.numRowCompact),a){var h=this.getAbstractUrl(resultElement),v=l.css("font-size"),y=l.css("font-family"),_=this.getLabelTitle(resultElement,v,i,y);s=this.textWidth(o('<span style="font-family:'+y+";font-size:"+v+'px;">'+_+"</span>")),i+=Math.ceil(s/this._innerWidth),l.html('<a class="epmc_citation_link" href="'+h+'">'+_+"</a>")}if(this.opt.displayStyle==r.COMPACT_STYLE&&(a=i+1<=this.opt.numRowCompact),a){var b=this.getSourceElement(resultElement);f.html(b),i+=1}if(this.opt.displayStyle==r.COMPACT_STYLE&&(a=i+1<=this.opt.numRowCompact),a){var x=this.getJournalElement(resultElement);p.html(x),i+=1}}else if(this.opt.elementOrder==r.TITLE_FIRST){if(i=0,s=0,a){var h=this.getAbstractUrl(resultElement),v=l.css("font-size"),y=l.css("font-family"),_=this.getLabelTitle(resultElement,v,i,y);s=this.textWidth(o('<span style="font-family:'+y+";font-size:"+v+'px;">'+_+"</span>")),i+=Math.ceil(s/this._innerWidth),l.html('<a class="epmc_citation_link" href="'+h+'">'+_+"</a>")}if(this.opt.displayStyle==r.COMPACT_STYLE&&(a=i+1<=this.opt.numRowCompact),a){var d=u.css("font-size"),m=u.css("font-family"),g=this.getAuthorsElement(resultElement,d,i,m);s=this.textWidth(o('<span style="font-family:'+m+";font-size:"+d+'px;">'+this._tempLabel+"</span>")),i+=Math.ceil(s/this._innerWidth),u.html(g)}if(this.opt.displayStyle==r.COMPACT_STYLE&&(a=i+1<=this.opt.numRowCompact),a){var x=this.getJournalElement(resultElement);p.html(x),i+=1}if(this.opt.displayStyle==r.COMPACT_STYLE&&(a=i+1<=this.opt.numRowCompact),a){var b=this.getSourceElement(resultElement);f.html(b),i+=1}}}t.hitCount>this.opt.numberResults&&(o('<div class="epmc_more_resuts"><a class="epmc_citation_link" href="http://europepmc.org/search?query='+this.opt.query+'&page=1">See All Results...</a></div>').appendTo(this._citationsContainer),o(".epmc_more_resuts").width(this.opt.width-10));var C;C=this.opt.collapsable?this._container.height():this._container[0].scrollHeight,this._citationsContainer.css("height",""),this._container.css("height","");var T=this._container[0].scrollHeight,w=this._container,E=this._citationsContainer,S=this.opt.target,R=this.opt.width,O=this.opt.collapsable;this._citationsContainer.animate({maxHeight:C},500,function(){if(O&&T>C){E.css("overflow-y","scroll");var t="jQuery('#"+S+" .epmc_Citations_data_container').animate({maxHeight:"+T+"}, 500, function() {jQuery('#"+S+" .epmc_extend_data_citation').hide();jQuery('#"+S+" .epmc_collapse_data_citation').show(); });return false;",e=o('<div class="epmc_extend_data_citation"><a class="epmc_citation_link" href="#" onClick="'+t+'">Show more Results</a></div>').appendTo(w);e.width(R),t="jQuery('#"+S+" .epmc_Citations_data_container').animate({\n\rmaxHeight:"+C+"\n\r}, 500, function() {\n\r\tjQuery('#"+S+" .epmc_extend_data_citation').show();\n\r\tjQuery('#"+S+" .epmc_collapse_data_citation').hide();\n\r });return false;";var n=o('<div style="display:none" class="epmc_collapse_data_citation"><a class="epmc_citation_link" href="#" onClick="'+t+'">Show fewer Results</a></div>').appendTo(w);n.width(R)}(0==O||T<C)&&(w.height(T),E.height(T))})},textWidth:function(t){var e=o("<span>"+t.html()+"</span>");e.css("font-size",t.css("font-size")).hide(),e.css("font-family",t.css("font-family")).hide(),e.css("white-space","nowrap").hide(),e.prependTo("body");var n=e.width();return e.remove(),n}});var l={MED_SOURCE:"MED",PMC_SOURCE:"PMC",PAT_SOURCE:"PAT",ETH_SOURCE:"ETH",HIR_SOURCE:"HIR",CTX_SOURCE:"CTX",CBA_SOURCE:"CBA",AGR_SOURCE:"AGR",DOI_SOURCE:"DOI",TITLE_FIRST:"TITLE_FIRST",AUTHORS_FIRST:"AUTHORS_FIRST",FULL_STYLE:"FULL_STYLE",COMPACT_STYLE:"COMPACT_STYLE",TITLE_ONLY_STYLE:"TITLE_ONLY_STYLE",EVT_ON_RESULTS_LOADED:"onResultsLoaded",EVT_ON_REQUEST_ERROR:"onRequestError"};for(var u in l)r[u]=l[u];var c=t("biojs-events");c.mixin(r.prototype)},{"biojs-events":5,jquery:6,"js-class":7,"js-extend":8}],3:[function(e,n,i){!function(){function e(){return{keys:Object.keys||function(t){if("object"!=typeof t&&"function"!=typeof t||null===t)throw new TypeError("keys() called on a non-object");var e,n=[];for(e in t)t.hasOwnProperty(e)&&(n[n.length]=e);return n},uniqueId:function(t){var e=++u+"";return t?t+e:e},has:function(t,e){return a.call(t,e)},each:function(t,e,n){if(null!=t)if(s&&t.forEach===s)t.forEach(e,n);else if(t.length===+t.length)for(var i=0,r=t.length;i<r;i++)e.call(n,t[i],i,t);else for(var o in t)this.has(t,o)&&e.call(n,t[o],o,t)},once:function(t){var e,n=!1;return function(){return n?e:(n=!0,e=t.apply(this,arguments),t=null,e)}}}}var r,o=this,s=Array.prototype.forEach,a=Object.prototype.hasOwnProperty,l=Array.prototype.slice,u=0,c=e();r={on:function(t,e,n){if(!f(this,"on",t,[e,n])||!e)return this;this._events||(this._events={});var i=this._events[t]||(this._events[t]=[]);return i.push({callback:e,context:n,ctx:n||this}),this},once:function(t,e,n){if(!f(this,"once",t,[e,n])||!e)return this;var i=this,r=c.once(function(){i.off(t,r),e.apply(this,arguments)});return r._callback=e,this.on(t,r,n)},off:function(t,e,n){var i,r,o,s,a,l,u,p;if(!this._events||!f(this,"off",t,[e,n]))return this;if(!t&&!e&&!n)return this._events={},this;for(s=t?[t]:c.keys(this._events),a=0,l=s.length;a<l;a++)if(t=s[a],o=this._events[t]){if(this._events[t]=i=[],e||n)for(u=0,p=o.length;u<p;u++)r=o[u],(e&&e!==r.callback&&e!==r.callback._callback||n&&n!==r.context)&&i.push(r);i.length||delete this._events[t]}return this},trigger:function(t){if(!this._events)return this;var e=l.call(arguments,1);if(!f(this,"trigger",t,e))return this;var n=this._events[t],i=this._events.all;return n&&h(n,e),i&&h(i,arguments),this},stopListening:function(t,e,n){var i=this._listeners;if(!i)return this;var r=!e&&!n;"object"==typeof e&&(n=this),t&&((i={})[t._listenerId]=t);for(var o in i)i[o].off(e,n,this),r&&delete this._listeners[o];return this}};var p=/\s+/,f=function(t,e,n,i){if(!n)return!0;if("object"==typeof n){for(var r in n)t[e].apply(t,[r,n[r]].concat(i));return!1}if(p.test(n)){for(var o=n.split(p),s=0,a=o.length;s<a;s++)t[e].apply(t,[o[s]].concat(i));return!1}return!0},h=function(t,e){var n,i=-1,r=t.length,o=e[0],s=e[1],a=e[2];switch(e.length){case 0:for(;++i<r;)(n=t[i]).callback.call(n.ctx);return;case 1:for(;++i<r;)(n=t[i]).callback.call(n.ctx,o);return;case 2:for(;++i<r;)(n=t[i]).callback.call(n.ctx,o,s);return;case 3:for(;++i<r;)(n=t[i]).callback.call(n.ctx,o,s,a);return;default:for(;++i<r;)(n=t[i]).callback.apply(n.ctx,e)}},d={listenTo:"on",listenToOnce:"once"};c.each(d,function(t,e){r[e]=function(e,n,i){var r=this._listeners||(this._listeners={}),o=e._listenerId||(e._listenerId=c.uniqueId("l"));return r[o]=e,"object"==typeof n&&(i=this),e[t](n,i,this),this}}),r.bind=r.on,r.unbind=r.off,r.mixin=function(t){var e=["on","once","off","trigger","stopListening","listenTo","listenToOnce","bind","unbind"];return c.each(e,function(e){t[e]=this[e]},this),t},"undefined"!=typeof i?("undefined"!=typeof n&&n.exports&&(i=n.exports=r),i.BackboneEvents=r):"function"==typeof t&&"object"==typeof t.amd?t(function(){return r}):o.BackboneEvents=r}(this)},{}],4:[function(t,e,n){e.exports=t("./backbone-events-standalone")},{"./backbone-events-standalone":3}],5:[function(t,e,n){var i=t("backbone-events-standalone");i.onAll=function(t,e){return this.on("all",t,e),this},i.oldMixin=i.mixin,i.mixin=function(t){i.oldMixin(t);for(var e=["onAll"],n=0;n<e.length;n++){var r=e[n];t[r]=this[r]}return t},e.exports=i},{"backbone-events-standalone":4}],6:[function(e,n,i){!function(t,e){"object"==typeof n&&"object"==typeof n.exports?n.exports=t.document?e(t,!0):function(t){if(!t.document)throw new Error("jQuery requires a window with a document");return e(t)}:e(t)}("undefined"!=typeof window?window:this,function(e,n){function i(t){var e=!!t&&"length"in t&&t.length,n=st.type(t);return"function"!==n&&!st.isWindow(t)&&("array"===n||0===e||"number"==typeof e&&e>0&&e-1 in t)}function r(t,e,n){if(st.isFunction(e))return st.grep(t,function(t,i){return!!e.call(t,i,t)!==n});if(e.nodeType)return st.grep(t,function(t){return t===e!==n});if("string"==typeof e){if(gt.test(e))return st.filter(e,t,n);e=st.filter(e,t)}return st.grep(t,function(t){return tt.call(e,t)>-1!==n})}function o(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}function s(t){var e={};return st.each(t.match(Ct)||[],function(t,n){e[n]=!0}),e}function a(){G.removeEventListener("DOMContentLoaded",a),e.removeEventListener("load",a),st.ready()}function l(){this.expando=st.expando+l.uid++}function u(t,e,n){var i;if(void 0===n&&1===t.nodeType)if(i="data-"+e.replace(Lt,"-$&").toLowerCase(),n=t.getAttribute(i),"string"==typeof n){try{n="true"===n||"false"!==n&&("null"===n?null:+n+""===n?+n:Ot.test(n)?st.parseJSON(n):n)}catch(r){}Rt.set(t,e,n)}else n=void 0;return n}function c(t,e,n,i){var r,o=1,s=20,a=i?function(){return i.cur()}:function(){return st.css(t,e,"")},l=a(),u=n&&n[3]||(st.cssNumber[e]?"":"px"),c=(st.cssNumber[e]||"px"!==u&&+l)&&jt.exec(st.css(t,e));if(c&&c[3]!==u){u=u||c[3],n=n||[],c=+l||1;do o=o||".5",c/=o,st.style(t,e,c+u);while(o!==(o=a()/l)&&1!==o&&--s)}return n&&(c=+c||+l||0,r=n[1]?c+(n[1]+1)*n[2]:+n[2],i&&(i.unit=u,i.start=c,i.end=r)),r}function p(t,e){var n="undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e||"*"):"undefined"!=typeof t.querySelectorAll?t.querySelectorAll(e||"*"):[];return void 0===e||e&&st.nodeName(t,e)?st.merge([t],n):n}function f(t,e){for(var n=0,i=t.length;n<i;n++)St.set(t[n],"globalEval",!e||St.get(e[n],"globalEval"))}function h(t,e,n,i,r){for(var o,s,a,l,u,c,h=e.createDocumentFragment(),d=[],m=0,g=t.length;m<g;m++)if(o=t[m],o||0===o)if("object"===st.type(o))st.merge(d,o.nodeType?[o]:o);else if(Pt.test(o)){for(s=s||h.appendChild(e.createElement("div")),a=(It.exec(o)||["",""])[1].toLowerCase(),l=Ht[a]||Ht._default,s.innerHTML=l[1]+st.htmlPrefilter(o)+l[2],c=l[0];c--;)s=s.lastChild;st.merge(d,s.childNodes),s=h.firstChild,s.textContent=""}else d.push(e.createTextNode(o));
for(h.textContent="",m=0;o=d[m++];)if(i&&st.inArray(o,i)>-1)r&&r.push(o);else if(u=st.contains(o.ownerDocument,o),s=p(h.appendChild(o),"script"),u&&f(s),n)for(c=0;o=s[c++];)qt.test(o.type||"")&&n.push(o);return h}function d(){return!0}function m(){return!1}function g(){try{return G.activeElement}catch(t){}}function v(t,e,n,i,r,o){var s,a;if("object"==typeof e){"string"!=typeof n&&(i=i||n,n=void 0);for(a in e)v(t,a,n,i,e[a],o);return t}if(null==i&&null==r?(r=n,i=n=void 0):null==r&&("string"==typeof n?(r=i,i=void 0):(r=i,i=n,n=void 0)),r===!1)r=m;else if(!r)return t;return 1===o&&(s=r,r=function(t){return st().off(t),s.apply(this,arguments)},r.guid=s.guid||(s.guid=st.guid++)),t.each(function(){st.event.add(this,e,r,i,n)})}function y(t,e){return st.nodeName(t,"table")&&st.nodeName(11!==e.nodeType?e:e.firstChild,"tr")?t.getElementsByTagName("tbody")[0]||t.appendChild(t.ownerDocument.createElement("tbody")):t}function _(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function b(t){var e=zt.exec(t.type);return e?t.type=e[1]:t.removeAttribute("type"),t}function x(t,e){var n,i,r,o,s,a,l,u;if(1===e.nodeType){if(St.hasData(t)&&(o=St.access(t),s=St.set(e,o),u=o.events)){delete s.handle,s.events={};for(r in u)for(n=0,i=u[r].length;n<i;n++)st.event.add(e,r,u[r][n])}Rt.hasData(t)&&(a=Rt.access(t),l=st.extend({},a),Rt.set(e,l))}}function C(t,e){var n=e.nodeName.toLowerCase();"input"===n&&Dt.test(t.type)?e.checked=t.checked:"input"!==n&&"textarea"!==n||(e.defaultValue=t.defaultValue)}function T(t,e,n,i){e=K.apply([],e);var r,o,s,a,l,u,c=0,f=t.length,d=f-1,m=e[0],g=st.isFunction(m);if(g||f>1&&"string"==typeof m&&!rt.checkClone&&Yt.test(m))return t.each(function(r){var o=t.eq(r);g&&(e[0]=m.call(this,r,o.html())),T(o,e,n,i)});if(f&&(r=h(e,t[0].ownerDocument,!1,t,i),o=r.firstChild,1===r.childNodes.length&&(r=o),o||i)){for(s=st.map(p(r,"script"),_),a=s.length;c<f;c++)l=r,c!==d&&(l=st.clone(l,!0,!0),a&&st.merge(s,p(l,"script"))),n.call(t[c],l,c);if(a)for(u=s[s.length-1].ownerDocument,st.map(s,b),c=0;c<a;c++)l=s[c],qt.test(l.type||"")&&!St.access(l,"globalEval")&&st.contains(u,l)&&(l.src?st._evalUrl&&st._evalUrl(l.src):st.globalEval(l.textContent.replace($t,"")))}return t}function w(t,e,n){for(var i,r=e?st.filter(e,t):t,o=0;null!=(i=r[o]);o++)n||1!==i.nodeType||st.cleanData(p(i)),i.parentNode&&(n&&st.contains(i.ownerDocument,i)&&f(p(i,"script")),i.parentNode.removeChild(i));return t}function E(t,e){var n=st(e.createElement(t)).appendTo(e.body),i=st.css(n[0],"display");return n.detach(),i}function S(t){var e=G,n=Vt[t];return n||(n=E(t,e),"none"!==n&&n||(Xt=(Xt||st("<iframe frameborder='0' width='0' height='0'/>")).appendTo(e.documentElement),e=Xt[0].contentDocument,e.write(),e.close(),n=E(t,e),Xt.detach()),Vt[t]=n),n}function R(t,e,n){var i,r,o,s,a=t.style;return n=n||Jt(t),s=n?n.getPropertyValue(e)||n[e]:void 0,""!==s&&void 0!==s||st.contains(t.ownerDocument,t)||(s=st.style(t,e)),n&&!rt.pixelMarginRight()&&Gt.test(s)&&Qt.test(e)&&(i=a.width,r=a.minWidth,o=a.maxWidth,a.minWidth=a.maxWidth=a.width=s,s=n.width,a.width=i,a.minWidth=r,a.maxWidth=o),void 0!==s?s+"":s}function O(t,e){return{get:function(){return t()?void delete this.get:(this.get=e).apply(this,arguments)}}}function L(t){if(t in re)return t;for(var e=t[0].toUpperCase()+t.slice(1),n=ie.length;n--;)if(t=ie[n]+e,t in re)return t}function A(t,e,n){var i=jt.exec(e);return i?Math.max(0,i[2]-(n||0))+(i[3]||"px"):e}function j(t,e,n,i,r){for(var o=n===(i?"border":"content")?4:"width"===e?1:0,s=0;o<4;o+=2)"margin"===n&&(s+=st.css(t,n+kt[o],!0,r)),i?("content"===n&&(s-=st.css(t,"padding"+kt[o],!0,r)),"margin"!==n&&(s-=st.css(t,"border"+kt[o]+"Width",!0,r))):(s+=st.css(t,"padding"+kt[o],!0,r),"padding"!==n&&(s+=st.css(t,"border"+kt[o]+"Width",!0,r)));return s}function k(t,e,n){var i=!0,r="width"===e?t.offsetWidth:t.offsetHeight,o=Jt(t),s="border-box"===st.css(t,"boxSizing",!1,o);if(r<=0||null==r){if(r=R(t,e,o),(r<0||null==r)&&(r=t.style[e]),Gt.test(r))return r;i=s&&(rt.boxSizingReliable()||r===t.style[e]),r=parseFloat(r)||0}return r+j(t,e,n||(s?"border":"content"),i,o)+"px"}function N(t,e){for(var n,i,r,o=[],s=0,a=t.length;s<a;s++)i=t[s],i.style&&(o[s]=St.get(i,"olddisplay"),n=i.style.display,e?(o[s]||"none"!==n||(i.style.display=""),""===i.style.display&&Nt(i)&&(o[s]=St.access(i,"olddisplay",S(i.nodeName)))):(r=Nt(i),"none"===n&&r||St.set(i,"olddisplay",r?n:st.css(i,"display"))));for(s=0;s<a;s++)i=t[s],i.style&&(e&&"none"!==i.style.display&&""!==i.style.display||(i.style.display=e?o[s]||"":"none"));return t}function D(t,e,n,i,r){return new D.prototype.init(t,e,n,i,r)}function I(){return e.setTimeout(function(){oe=void 0}),oe=st.now()}function q(t,e){var n,i=0,r={height:t};for(e=e?1:0;i<4;i+=2-e)n=kt[i],r["margin"+n]=r["padding"+n]=t;return e&&(r.opacity=r.width=t),r}function H(t,e,n){for(var i,r=(M.tweeners[e]||[]).concat(M.tweeners["*"]),o=0,s=r.length;o<s;o++)if(i=r[o].call(n,e,t))return i}function P(t,e,n){var i,r,o,s,a,l,u,c,p=this,f={},h=t.style,d=t.nodeType&&Nt(t),m=St.get(t,"fxshow");n.queue||(a=st._queueHooks(t,"fx"),null==a.unqueued&&(a.unqueued=0,l=a.empty.fire,a.empty.fire=function(){a.unqueued||l()}),a.unqueued++,p.always(function(){p.always(function(){a.unqueued--,st.queue(t,"fx").length||a.empty.fire()})})),1===t.nodeType&&("height"in e||"width"in e)&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],u=st.css(t,"display"),c="none"===u?St.get(t,"olddisplay")||S(t.nodeName):u,"inline"===c&&"none"===st.css(t,"float")&&(h.display="inline-block")),n.overflow&&(h.overflow="hidden",p.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]}));for(i in e)if(r=e[i],ae.exec(r)){if(delete e[i],o=o||"toggle"===r,r===(d?"hide":"show")){if("show"!==r||!m||void 0===m[i])continue;d=!0}f[i]=m&&m[i]||st.style(t,i)}else u=void 0;if(st.isEmptyObject(f))"inline"===("none"===u?S(t.nodeName):u)&&(h.display=u);else{m?"hidden"in m&&(d=m.hidden):m=St.access(t,"fxshow",{}),o&&(m.hidden=!d),d?st(t).show():p.done(function(){st(t).hide()}),p.done(function(){var e;St.remove(t,"fxshow");for(e in f)st.style(t,e,f[e])});for(i in f)s=H(d?m[i]:0,i,p),i in m||(m[i]=s.start,d&&(s.end=s.start,s.start="width"===i||"height"===i?1:0))}}function U(t,e){var n,i,r,o,s;for(n in t)if(i=st.camelCase(n),r=e[i],o=t[n],st.isArray(o)&&(r=o[1],o=t[n]=o[0]),n!==i&&(t[i]=o,delete t[n]),s=st.cssHooks[i],s&&"expand"in s){o=s.expand(o),delete t[i];for(n in o)n in t||(t[n]=o[n],e[n]=r)}else e[i]=r}function M(t,e,n){var i,r,o=0,s=M.prefilters.length,a=st.Deferred().always(function(){delete l.elem}),l=function(){if(r)return!1;for(var e=oe||I(),n=Math.max(0,u.startTime+u.duration-e),i=n/u.duration||0,o=1-i,s=0,l=u.tweens.length;s<l;s++)u.tweens[s].run(o);return a.notifyWith(t,[u,o,n]),o<1&&l?n:(a.resolveWith(t,[u]),!1)},u=a.promise({elem:t,props:st.extend({},e),opts:st.extend(!0,{specialEasing:{},easing:st.easing._default},n),originalProperties:e,originalOptions:n,startTime:oe||I(),duration:n.duration,tweens:[],createTween:function(e,n){var i=st.Tween(t,u.opts,e,n,u.opts.specialEasing[e]||u.opts.easing);return u.tweens.push(i),i},stop:function(e){var n=0,i=e?u.tweens.length:0;if(r)return this;for(r=!0;n<i;n++)u.tweens[n].run(1);return e?(a.notifyWith(t,[u,1,0]),a.resolveWith(t,[u,e])):a.rejectWith(t,[u,e]),this}}),c=u.props;for(U(c,u.opts.specialEasing);o<s;o++)if(i=M.prefilters[o].call(u,t,c,u.opts))return st.isFunction(i.stop)&&(st._queueHooks(u.elem,u.opts.queue).stop=st.proxy(i.stop,i)),i;return st.map(c,H,u),st.isFunction(u.opts.start)&&u.opts.start.call(t,u),st.fx.timer(st.extend(l,{elem:t,anim:u,queue:u.opts.queue})),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always)}function F(t){return t.getAttribute&&t.getAttribute("class")||""}function W(t){return function(e,n){"string"!=typeof e&&(n=e,e="*");var i,r=0,o=e.toLowerCase().match(Ct)||[];if(st.isFunction(n))for(;i=o[r++];)"+"===i[0]?(i=i.slice(1)||"*",(t[i]=t[i]||[]).unshift(n)):(t[i]=t[i]||[]).push(n)}}function B(t,e,n,i){function r(a){var l;return o[a]=!0,st.each(t[a]||[],function(t,a){var u=a(e,n,i);return"string"!=typeof u||s||o[u]?s?!(l=u):void 0:(e.dataTypes.unshift(u),r(u),!1)}),l}var o={},s=t===Re;return r(e.dataTypes[0])||!o["*"]&&r("*")}function Y(t,e){var n,i,r=st.ajaxSettings.flatOptions||{};for(n in e)void 0!==e[n]&&((r[n]?t:i||(i={}))[n]=e[n]);return i&&st.extend(!0,t,i),t}function z(t,e,n){for(var i,r,o,s,a=t.contents,l=t.dataTypes;"*"===l[0];)l.shift(),void 0===i&&(i=t.mimeType||e.getResponseHeader("Content-Type"));if(i)for(r in a)if(a[r]&&a[r].test(i)){l.unshift(r);break}if(l[0]in n)o=l[0];else{for(r in n){if(!l[0]||t.converters[r+" "+l[0]]){o=r;break}s||(s=r)}o=o||s}if(o)return o!==l[0]&&l.unshift(o),n[o]}function $(t,e,n,i){var r,o,s,a,l,u={},c=t.dataTypes.slice();if(c[1])for(s in t.converters)u[s.toLowerCase()]=t.converters[s];for(o=c.shift();o;)if(t.responseFields[o]&&(n[t.responseFields[o]]=e),!l&&i&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),l=o,o=c.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(s=u[l+" "+o]||u["* "+o],!s)for(r in u)if(a=r.split(" "),a[1]===o&&(s=u[l+" "+a[0]]||u["* "+a[0]])){s===!0?s=u[r]:u[r]!==!0&&(o=a[0],c.unshift(a[1]));break}if(s!==!0)if(s&&t["throws"])e=s(e);else try{e=s(e)}catch(p){return{state:"parsererror",error:s?p:"No conversion from "+l+" to "+o}}}return{state:"success",data:e}}function X(t,e,n,i){var r;if(st.isArray(e))st.each(e,function(e,r){n||je.test(t)?i(t,r):X(t+"["+("object"==typeof r&&null!=r?e:"")+"]",r,n,i)});else if(n||"object"!==st.type(e))i(t,e);else for(r in e)X(t+"["+r+"]",e[r],n,i)}function V(t){return st.isWindow(t)?t:9===t.nodeType&&t.defaultView}var Q=[],G=e.document,J=Q.slice,K=Q.concat,Z=Q.push,tt=Q.indexOf,et={},nt=et.toString,it=et.hasOwnProperty,rt={},ot="2.2.4",st=function(t,e){return new st.fn.init(t,e)},at=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,lt=/^-ms-/,ut=/-([\da-z])/gi,ct=function(t,e){return e.toUpperCase()};st.fn=st.prototype={jquery:ot,constructor:st,selector:"",length:0,toArray:function(){return J.call(this)},get:function(t){return null!=t?t<0?this[t+this.length]:this[t]:J.call(this)},pushStack:function(t){var e=st.merge(this.constructor(),t);return e.prevObject=this,e.context=this.context,e},each:function(t){return st.each(this,t)},map:function(t){return this.pushStack(st.map(this,function(e,n){return t.call(e,n,e)}))},slice:function(){return this.pushStack(J.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(t){var e=this.length,n=+t+(t<0?e:0);return this.pushStack(n>=0&&n<e?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:Z,sort:Q.sort,splice:Q.splice},st.extend=st.fn.extend=function(){var t,e,n,i,r,o,s=arguments[0]||{},a=1,l=arguments.length,u=!1;for("boolean"==typeof s&&(u=s,s=arguments[a]||{},a++),"object"==typeof s||st.isFunction(s)||(s={}),a===l&&(s=this,a--);a<l;a++)if(null!=(t=arguments[a]))for(e in t)n=s[e],i=t[e],s!==i&&(u&&i&&(st.isPlainObject(i)||(r=st.isArray(i)))?(r?(r=!1,o=n&&st.isArray(n)?n:[]):o=n&&st.isPlainObject(n)?n:{},s[e]=st.extend(u,o,i)):void 0!==i&&(s[e]=i));return s},st.extend({expando:"jQuery"+(ot+Math.random()).replace(/\D/g,""),isReady:!0,error:function(t){throw new Error(t)},noop:function(){},isFunction:function(t){return"function"===st.type(t)},isArray:Array.isArray,isWindow:function(t){return null!=t&&t===t.window},isNumeric:function(t){var e=t&&t.toString();return!st.isArray(t)&&e-parseFloat(e)+1>=0},isPlainObject:function(t){var e;if("object"!==st.type(t)||t.nodeType||st.isWindow(t))return!1;if(t.constructor&&!it.call(t,"constructor")&&!it.call(t.constructor.prototype||{},"isPrototypeOf"))return!1;for(e in t);return void 0===e||it.call(t,e)},isEmptyObject:function(t){var e;for(e in t)return!1;return!0},type:function(t){return null==t?t+"":"object"==typeof t||"function"==typeof t?et[nt.call(t)]||"object":typeof t},globalEval:function(t){var e,n=eval;t=st.trim(t),t&&(1===t.indexOf("use strict")?(e=G.createElement("script"),e.text=t,G.head.appendChild(e).parentNode.removeChild(e)):n(t))},camelCase:function(t){return t.replace(lt,"ms-").replace(ut,ct)},nodeName:function(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()},each:function(t,e){var n,r=0;if(i(t))for(n=t.length;r<n&&e.call(t[r],r,t[r])!==!1;r++);else for(r in t)if(e.call(t[r],r,t[r])===!1)break;return t},trim:function(t){return null==t?"":(t+"").replace(at,"")},makeArray:function(t,e){var n=e||[];return null!=t&&(i(Object(t))?st.merge(n,"string"==typeof t?[t]:t):Z.call(n,t)),n},inArray:function(t,e,n){return null==e?-1:tt.call(e,t,n)},merge:function(t,e){for(var n=+e.length,i=0,r=t.length;i<n;i++)t[r++]=e[i];return t.length=r,t},grep:function(t,e,n){for(var i,r=[],o=0,s=t.length,a=!n;o<s;o++)i=!e(t[o],o),i!==a&&r.push(t[o]);return r},map:function(t,e,n){var r,o,s=0,a=[];if(i(t))for(r=t.length;s<r;s++)o=e(t[s],s,n),null!=o&&a.push(o);else for(s in t)o=e(t[s],s,n),null!=o&&a.push(o);return K.apply([],a)},guid:1,proxy:function(t,e){var n,i,r;if("string"==typeof e&&(n=t[e],e=t,t=n),st.isFunction(t))return i=J.call(arguments,2),r=function(){return t.apply(e||this,i.concat(J.call(arguments)))},r.guid=t.guid=t.guid||st.guid++,r},now:Date.now,support:rt}),"function"==typeof Symbol&&(st.fn[Symbol.iterator]=Q[Symbol.iterator]),st.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(t,e){et["[object "+e+"]"]=e.toLowerCase()});var pt=function(t){function e(t,e,n,i){var r,o,s,a,l,u,p,h,d=e&&e.ownerDocument,m=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==m&&9!==m&&11!==m)return n;if(!i&&((e?e.ownerDocument||e:M)!==k&&j(e),e=e||k,D)){if(11!==m&&(u=vt.exec(t)))if(r=u[1]){if(9===m){if(!(s=e.getElementById(r)))return n;if(s.id===r)return n.push(s),n}else if(d&&(s=d.getElementById(r))&&P(e,s)&&s.id===r)return n.push(s),n}else{if(u[2])return K.apply(n,e.getElementsByTagName(t)),n;if((r=u[3])&&x.getElementsByClassName&&e.getElementsByClassName)return K.apply(n,e.getElementsByClassName(r)),n}if(x.qsa&&!z[t+" "]&&(!I||!I.test(t))){if(1!==m)d=e,h=t;else if("object"!==e.nodeName.toLowerCase()){for((a=e.getAttribute("id"))?a=a.replace(_t,"\\$&"):e.setAttribute("id",a=U),p=E(t),o=p.length,l=ft.test(a)?"#"+a:"[id='"+a+"']";o--;)p[o]=l+" "+f(p[o]);h=p.join(","),d=yt.test(t)&&c(e.parentNode)||e}if(h)try{return K.apply(n,d.querySelectorAll(h)),n}catch(g){}finally{a===U&&e.removeAttribute("id")}}}return R(t.replace(at,"$1"),e,n,i)}function n(){function t(n,i){return e.push(n+" ")>C.cacheLength&&delete t[e.shift()],t[n+" "]=i}var e=[];return t}function i(t){return t[U]=!0,t}function r(t){var e=k.createElement("div");try{return!!t(e)}catch(n){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function o(t,e){for(var n=t.split("|"),i=n.length;i--;)C.attrHandle[n[i]]=e}function s(t,e){var n=e&&t,i=n&&1===t.nodeType&&1===e.nodeType&&(~e.sourceIndex||X)-(~t.sourceIndex||X);if(i)return i;if(n)for(;n=n.nextSibling;)if(n===e)return-1;return t?1:-1}function a(t){return function(e){var n=e.nodeName.toLowerCase();return"input"===n&&e.type===t}}function l(t){return function(e){var n=e.nodeName.toLowerCase();return("input"===n||"button"===n)&&e.type===t}}function u(t){return i(function(e){return e=+e,i(function(n,i){for(var r,o=t([],n.length,e),s=o.length;s--;)n[r=o[s]]&&(n[r]=!(i[r]=n[r]))})})}function c(t){return t&&"undefined"!=typeof t.getElementsByTagName&&t}function p(){}function f(t){for(var e=0,n=t.length,i="";e<n;e++)i+=t[e].value;return i}function h(t,e,n){var i=e.dir,r=n&&"parentNode"===i,o=W++;return e.first?function(e,n,o){for(;e=e[i];)if(1===e.nodeType||r)return t(e,n,o)}:function(e,n,s){var a,l,u,c=[F,o];if(s){for(;e=e[i];)if((1===e.nodeType||r)&&t(e,n,s))return!0}else for(;e=e[i];)if(1===e.nodeType||r){if(u=e[U]||(e[U]={}),l=u[e.uniqueID]||(u[e.uniqueID]={}),(a=l[i])&&a[0]===F&&a[1]===o)return c[2]=a[2];if(l[i]=c,c[2]=t(e,n,s))return!0}}}function d(t){return t.length>1?function(e,n,i){for(var r=t.length;r--;)if(!t[r](e,n,i))return!1;return!0}:t[0]}function m(t,n,i){for(var r=0,o=n.length;r<o;r++)e(t,n[r],i);return i}function g(t,e,n,i,r){for(var o,s=[],a=0,l=t.length,u=null!=e;a<l;a++)(o=t[a])&&(n&&!n(o,i,r)||(s.push(o),u&&e.push(a)));return s}function v(t,e,n,r,o,s){return r&&!r[U]&&(r=v(r)),o&&!o[U]&&(o=v(o,s)),i(function(i,s,a,l){var u,c,p,f=[],h=[],d=s.length,v=i||m(e||"*",a.nodeType?[a]:a,[]),y=!t||!i&&e?v:g(v,f,t,a,l),_=n?o||(i?t:d||r)?[]:s:y;if(n&&n(y,_,a,l),r)for(u=g(_,h),r(u,[],a,l),c=u.length;c--;)(p=u[c])&&(_[h[c]]=!(y[h[c]]=p));if(i){if(o||t){if(o){for(u=[],c=_.length;c--;)(p=_[c])&&u.push(y[c]=p);o(null,_=[],u,l)}for(c=_.length;c--;)(p=_[c])&&(u=o?tt(i,p):f[c])>-1&&(i[u]=!(s[u]=p))}}else _=g(_===s?_.splice(d,_.length):_),o?o(null,s,_,l):K.apply(s,_)})}function y(t){for(var e,n,i,r=t.length,o=C.relative[t[0].type],s=o||C.relative[" "],a=o?1:0,l=h(function(t){return t===e},s,!0),u=h(function(t){return tt(e,t)>-1},s,!0),c=[function(t,n,i){var r=!o&&(i||n!==O)||((e=n).nodeType?l(t,n,i):u(t,n,i));return e=null,r}];a<r;a++)if(n=C.relative[t[a].type])c=[h(d(c),n)];else{if(n=C.filter[t[a].type].apply(null,t[a].matches),n[U]){for(i=++a;i<r&&!C.relative[t[i].type];i++);return v(a>1&&d(c),a>1&&f(t.slice(0,a-1).concat({value:" "===t[a-2].type?"*":""})).replace(at,"$1"),n,a<i&&y(t.slice(a,i)),i<r&&y(t=t.slice(i)),i<r&&f(t))}c.push(n)}return d(c)}function _(t,n){var r=n.length>0,o=t.length>0,s=function(i,s,a,l,u){var c,p,f,h=0,d="0",m=i&&[],v=[],y=O,_=i||o&&C.find.TAG("*",u),b=F+=null==y?1:Math.random()||.1,x=_.length;for(u&&(O=s===k||s||u);d!==x&&null!=(c=_[d]);d++){if(o&&c){for(p=0,s||c.ownerDocument===k||(j(c),a=!D);f=t[p++];)if(f(c,s||k,a)){l.push(c);break}u&&(F=b)}r&&((c=!f&&c)&&h--,i&&m.push(c))}if(h+=d,r&&d!==h){for(p=0;f=n[p++];)f(m,v,s,a);if(i){if(h>0)for(;d--;)m[d]||v[d]||(v[d]=G.call(l));v=g(v)}K.apply(l,v),u&&!i&&v.length>0&&h+n.length>1&&e.uniqueSort(l)}return u&&(F=b,O=y),m};return r?i(s):s}var b,x,C,T,w,E,S,R,O,L,A,j,k,N,D,I,q,H,P,U="sizzle"+1*new Date,M=t.document,F=0,W=0,B=n