iBet uBet web content aggregator. Adding the entire web to your favor.
iBet uBet web content aggregator. Adding the entire web to your favor.



Link to original content: http://europepmc.org/js/chunk-64244d55.13361d69.js
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-64244d55"],{"49c6":function(t,e,r){"use strict";r.r(e);var n,i=function(){var t=this,e=t._self._c;return e("div",{staticClass:"advanceSearchContainer"},[e("div",{attrs:{id:"epmc_searchBanner"}}),e("div",{staticClass:"grid-row",staticStyle:{flex:"1"}},[e("div",{staticClass:"col-16"},[e("div",{staticClass:"advanceSearchTitle"},[e("div",[e("h1",[t._v("Advanced search - (abbreviated version)")]),e("p",[t._v("\n "+t._s(t.betaAdvanceSearchDescription)+"\n ")])])]),e("div",{staticClass:"has-sections"},t._l(t.sections,(function(r){return e("content-section",{key:r.id,attrs:{section:r},on:{opened:t.onSectionOpened}},["keywordsOrTopics"===r.id?[e("div",{},[e("div",{},[e("form",{attrs:{id:"topicsAndKeywordsForm"},on:{submit:t.onTopicsOrKeywordsSubmit}},[e("h5",[t._v("1. Enter word(s) or phrase")]),e("div",{staticClass:"termsOrPhraseInput"},[t.query.length>0?e("dropdown",{class:["operatorDropdown",t.logicalOperator.freeText.toLowerCase(),t.getLogicalOperatorDropdownClass()],attrs:{options:t.options,"with-separator":!1,"dropdown-icon-type":"chevron",selected:t.getSelectedOptionForLogicalOperator(t.logicalOperator.freeText)},on:{onOptionSelected:function(e){return t.onLogicalOperatorChange(e,"freeText")}}}):t._e(),0===t.query.length?e("input",{attrs:{name:"termOrPhrase",required:""},domProps:{value:t.termOrPhrase},on:{input:t.onTermOrPhraseChange}}):t._e(),t.query.length>0?e("input",{staticClass:"termInput",attrs:{name:"termOrPhrase",required:""},domProps:{value:t.termOrPhrase},on:{input:t.onTermOrPhraseChange}}):t._e()],1),e("p",{staticClass:"termsOrPhraseNote"},[t._v("\n If more than one word is entered, use the guidelines\n below:\n ")]),e("ul",[e("li",[t._v("\n If multiple words are entered as separate ideas, add\n upper case OR, AND, or NOT between them\n "),e("tips-tooltip")],1),e("li",[t._v("\n If multiple words are entered as a phrase, select\n "),e("span",{attrs:{id:"exactPhrase"}},[e("input",{attrs:{type:"checkbox",disabled:!t.termOrPhrase},domProps:{checked:t.isFindExactPhraseEnabled},on:{input:t.onFindExactPhraseClick}}),e("find-exact-phrase-tooltip")],1)])]),e("h5",{staticStyle:{"margin-top":"22px","margin-bottom":"0"}},[t._v("\n 2. Select one or more places to search\n ")]),e("div",{staticClass:"placesToSearch"},[t._l(t.placesToSearch,(function(r){return e("div",{key:r.id,class:["checkbox",r.selected?"selectedCheckbox":""],on:{click:function(e){return t.onPlaceToSearchClick(r.id)}}},[t._v("\n "+t._s(r.label)+"\n "),e("sup",[r.information?e("tooltip",[e("i",{staticClass:"far fa-question-circle",attrs:{slot:"trigger"},slot:"trigger"}),e("b",[t._v(t._s(r.label)+":")]),t._v("\n "+t._s(r.information)+"\n ")]):t._e()],1)])})),e("div",{staticClass:"multiSelectContainer"},[e("multi-select",{staticClass:"articleSectionMultiSelect",attrs:{"input-id":"multi-select",options:t.articleSectionOptions,"enable-tags":!1,placeholder:"Article Sections","multi-select-style":t.multiSelectStyle,variant:"caret-inside"},on:{onOptionChanged:t.onArticleSectionOptionsChanged}})],1)],2),e("div",{staticClass:"submitButton"},[e("button",{attrs:{type:"submit",disabled:!t.isAnyItemSelected}},[e("i",{staticClass:"fa fa-plus"}),t._v(" \n "),t.query.length>0?e("span",[t._v(" Add ")]):e("span",[t._v("Start building my query")])])]),e("div")])])])]:t._e(),"publicationTypeOrJournalOrArticleId"===r.id?[e("form",{attrs:{id:"publicatiobTypeOrJournalOrArticleIdForm"},on:{submit:t.onPublicationTypeOrJournalOrArticleIdSubmit}},[e("div",{staticClass:"publicationType"},[e("div",{staticClass:"allPublicationTypes"},[e("h5",[t._v("\n Publication types from all sources\n "),e("sup",[e("tooltip",[e("i",{staticClass:"far fa-question-circle",attrs:{slot:"trigger"},slot:"trigger"}),t._v("\n This filter includes the most popular publication\n types, and searches the aggregated Europe PMC content\n from PubMed, PMC, Agricola, Chinese Biological\n Abstracts, the NCBI bookshelf. and Preprint servers.\n ")])],1)]),e("div",{staticClass:"dropdownContainer"},[t.query.length>0?e("dropdown",{class:["operatorDropdownSmall",t.logicalOperator.allPublicationTypes.toLowerCase()],attrs:{options:t.options,"with-separator":!1,"dropdown-icon-type":"chevron",selected:t.getSelectedOptionForLogicalOperator(t.logicalOperator.allPublicationTypes)}}):t._e(),e("multi-select",{staticClass:"articleSectionMultiSelect",attrs:{"input-id":"multi-select",options:t.allPublicationTypeOptions,"enable-tags":!1,placeholder:t.allPublicationTypeOptionsPlaceholder,"multi-select-style":"width: 280px",variant:"caret-outside"},on:{onOptionChanged:t.onAllPublicationTypeOptionsChanged}})],1)]),e("div",[e("h5",[t._v("\n Publication types from PubMed/NCBI only\n "),e("sup",[e("tooltip",[e("i",{staticClass:"far fa-question-circle",attrs:{slot:"trigger"},slot:"trigger"}),t._v("\n This filter includes all publication types assigned by\n PubMed, and limits the search to PubMed records.\n ")])],1)]),e("div",{staticClass:"dropdownContainer"},[t.query.length>0?e("dropdown",{class:["operatorDropdownSmall",t.logicalOperator.publicationTypesPubmedNcbi.toLowerCase()],attrs:{options:t.options,"with-separator":!1,"dropdown-icon-type":"chevron",selected:t.getSelectedOptionForLogicalOperator(t.logicalOperator.publicationTypesPubmedNcbi)},on:{onOptionSelected:function(e){return t.onLogicalOperatorChange(e,"publicationTypesPubmedNcbi")}}}):t._e(),e("multi-select",{staticClass:"articleSectionMultiSelect",attrs:{"input-id":"multi-select",options:t.publicationTypePubmedNcbiOptions,"enable-tags":!1,placeholder:t.publicationTypePubmedNcbiOptionsPlaceholder,"multi-select-style":"width: 280px",variant:"caret-outside"},on:{onOptionChanged:t.onPublicationTypePubmedNcbiOptionsChanged}})],1)])]),e("div",{staticClass:"journals"},[e("h5",[t._v("\n Journals\n "),e("sup",[e("tooltip",[e("i",{staticClass:"far fa-question-circle",attrs:{slot:"trigger"},slot:"trigger"}),t._v("\n This filter includes all journals providing the\n aggregated Europe PMC content from PubMed, PMC,\n Agricola, and Chinese Biological Abstracts.\n ")])],1)]),e("div",{staticClass:"dropdownContainer"},[t.query.length>0?e("dropdown",{class:["operatorDropdownSmall",t.logicalOperator.journals.toLowerCase()],attrs:{options:t.options,"with-separator":!1,"dropdown-icon-type":"chevron",selected:t.getSelectedOptionForLogicalOperator(t.logicalOperator.journals)},on:{onOptionSelected:function(e){return t.onLogicalOperatorChange(e,"journals")}}}):t._e(),e("multi-select",{staticClass:"articleSectionMultiSelect",attrs:{"input-id":"multi-select",options:t.articleSectionOptions,"enable-tags":!1,placeholder:"Enter name to view list","multi-select-style":"width: 280px",variant:"caret-outside"},on:{onOptionChanged:t.onArticleSectionOptionsChanged}})],1)]),e("div",{staticClass:"preprints"},[e("h5",[t._v("Preprint Servers")]),e("div",{staticClass:"dropdownContainer"},[t.query.length>0?e("dropdown",{class:["operatorDropdownSmall",t.logicalOperator.preprints.toLowerCase()],attrs:{options:t.options,"with-separator":!1,"dropdown-icon-type":"chevron",selected:t.getSelectedOptionForLogicalOperator(t.logicalOperator.preprints)},on:{onOptionSelected:function(e){return t.onLogicalOperatorChange(e,"preprints")}}}):t._e(),e("multi-select",{staticClass:"articleSectionMultiSelect",attrs:{"input-id":"multi-select",options:t.preprintOptions,"enable-tags":!1,placeholder:t.preprintServerOptionsPlaceholder,"multi-select-style":"width: 280px",variant:"caret-outside"},on:{onOptionChanged:t.onPreprintServerOptionsChanged}})],1)]),e("div",{staticClass:"articleIdSection"},[e("div",{staticClass:"articleIdType"},[e("h5",[t._v("Article ID")]),e("div",{staticClass:"dropdownContainer"},[t.query.length>0?e("dropdown",{class:["operatorDropdownSmall",t.logicalOperator.articleId.toLowerCase()],attrs:{options:t.options,"with-separator":!1,"dropdown-icon-type":"chevron",selected:t.getSelectedOptionForLogicalOperator(t.logicalOperator.articleId)},on:{onOptionSelected:function(e){return t.onLogicalOperatorChange(e,"articleId")}}}):t._e(),e("dropdown",{staticClass:"articleIdOptionsDropdown",attrs:{options:t.articleIdOptions,"with-separator":!1,"dropdown-icon-type":"chevron","default-option-text":"Select ID type","selected-option-style":"color:#bcbcbc; font-weight: 300"}})],1)]),e("div",{staticClass:"articleId"},[e("h5",[t._v("\n ID# "),e("span",[t._v("(Separate multiple IDs with commas.)")])]),e("input",{attrs:{name:"articleId",placeholder:"Enter ID"},domProps:{value:t.articleId},on:{input:t.onArticleIdChange}})])]),e("div",{staticClass:"submitButton"},[e("button",{attrs:{type:"submit",disabled:!t.isAnyItemSelected}},[e("i",{staticClass:"fa fa-plus"}),t._v(" \n "),t.query.length>0?e("span",[t._v(" Add ")]):e("span",[t._v("Start building my query")])])])])]:t._e()],2)})),1)])]),e("div",{staticClass:"searchQuerySection",attrs:{id:"searchQueryBottomSheet"}},[t._m(0),e("div",{staticClass:"searchQueryRowsContainer"},[e("div",{staticClass:"grid-row"},[e("div",{staticClass:"col-16"},[t.query.length>0?e("div",{staticClass:"searchQueryActions"},[e("div",{staticClass:"searchButtonContainer"},[e("button",{staticClass:"regular",on:{click:function(e){return t.onSearchQueryClick()}}},[e("i",{staticClass:"fa fa-search"}),e("span",{attrs:{id:"search-btn-text"}},[t._v(" Search")])])]),e("div",[e("a",{on:{click:t.exportQuery}},[t._v("Export")]),t._v(" |\n "),e("a",{on:{click:t.onClearQueryClick}},[t._v("Clear all")])])]):t._e()])]),e("div",{staticClass:"grid-row"},[e("div",{staticClass:"col-16"},[e("div",{staticClass:"searchQueryRows"},[0===t.query.length?e("p",{staticClass:"noQueryText"},[t._v("\n Enter a search query above.\n ")]):t._e(),t._l(t.query,(function(r,n){return e("div",{key:r.id,staticClass:"searchQueryRowContainer"},[e("div",{staticStyle:{display:"flex",width:"100%","align-items":"center"}},[e("div",{staticClass:"searchQueryRow col-13"},[0===n&&t.query.length>1?e("div",{staticStyle:{display:"flex"}},t._l(t.query,(function(r,n){return e("div",{key:r.id},[n>0?e("div",{staticClass:"queryBracket"},[t._v("(")]):t._e()])})),0):t._e(),r.logicalOperator?e("dropdown",{class:["operatorDropdown","operatorDropdownSmall",r.logicalOperator.toLowerCase()],attrs:{options:t.options,"with-separator":!1,selected:t.getSelectedOptionForLogicalOperator(r.logicalOperator),"dropdown-icon-type":"chevron"},on:{onOptionSelected:function(e){return t.onQueryLogicalOperatorChange(e,r.id)}}}):t._e(),e("span",{ref:"editableContent",refInFor:!0,staticClass:"queryHtmlContainer",domProps:{innerHTML:t._s(t.renderQueryHtml(r))}}),n>0?e("div",{staticClass:"queryBracket endBracket"},[t._v("\n )\n ")]):t._e()],1),r.term?e("tooltip",{attrs:{trigger:"click",placement:"top",close:t.closeEditTermTooltip}},[e("i",{staticClass:"fas fa-pen",staticStyle:{"margin-right":"8px","font-size":"14px"},attrs:{slot:"trigger"},on:{click:function(e){t.closeEditTermTooltip=!1}},slot:"trigger"}),e("b",[e("p",{staticStyle:{"margin-top":"0"}},[t._v("Edit Term")])]),e("form",{on:{submit:function(e){return t.onRowContentChange(e,r)}}},[e("input",{staticStyle:{"margin-right":"8px"},attrs:{required:"",name:"rowTerm"},domProps:{value:r.term}}),e("button",{staticStyle:{background:"white",border:"none",padding:"0",margin:"0","min-width":"10px"}},[e("i",{staticClass:"fas fa-check",attrs:{type:"submit"}})])])]):e("i",{staticClass:"fas fa-pen disabledEditIcon",staticStyle:{"margin-right":"8px","font-size":"14px",color:"#969696",cursor:"not-allowed"}}),e("i",{staticClass:"fas fa-times",on:{click:function(e){return t.onDeleteRowClick(r.id)}}})],1),e("p",{class:["count",t.countLoading?"disabled":""],on:{click:function(e){return t.onSearchQueryClick(r.query)}}},[t._v("\n "+t._s(r.count?r.count.toLocaleString():0)+"\n ")])])}))],2),e("div",{staticClass:"totalCount",attrs:{id:"totalResults"}},[t.query.length>0?e("span",{on:{click:function(e){return t.onSearchQueryClick()}}},[t._v("\n RESULTS:\n "+t._s(t.totalCount.toLocaleString())+"\n ")]):t._e()])])])])]),t.showIntroductionModal?e("modal",{on:{close:t.closeIntroductionModal}},[e("template",{slot:"title"},[t._v("Impact the usability of Advanced search!")]),t._v("\n "+t._s(t.betaAdvanceSearchDescription)+"\n "),e("div",{staticStyle:{"text-align":"right","margin-top":"20px"}},[e("button",{on:{click:t.closeIntroductionModal}},[t._v("Ok")])])],2):t._e()],1)},o=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"grid-row"},[e("div",{staticClass:"col-16"},[e("div",{staticClass:"searchQueryTitle"},[e("h3",[t._v("Search Query:")])])])])}],a=r("bdee"),c=r("bfab"),s=r("f121"),l=r("c28b"),u=r.n(l),p=r("de6e"),d=r("365c"),h=new Uint8Array(16);function f(){if(!n&&(n="undefined"!==typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!==typeof msCrypto&&"function"===typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto),!n))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return n(h)}var v=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function y(t){return"string"===typeof t&&v.test(t)}for(var g=y,m=[],b=0;b<256;++b)m.push((b+256).toString(16).substr(1));function O(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=(m[t[e+0]]+m[t[e+1]]+m[t[e+2]]+m[t[e+3]]+"-"+m[t[e+4]]+m[t[e+5]]+"-"+m[t[e+6]]+m[t[e+7]]+"-"+m[t[e+8]]+m[t[e+9]]+"-"+m[t[e+10]]+m[t[e+11]]+m[t[e+12]]+m[t[e+13]]+m[t[e+14]]+m[t[e+15]]).toLowerCase();if(!g(r))throw TypeError("Stringified UUID is invalid");return r}var C,S,P=O,T=0,w=0;function I(t,e,r){var n=e&&r||0,i=e||new Array(16);t=t||{};var o=t.node||C,a=void 0!==t.clockseq?t.clockseq:S;if(null==o||null==a){var c=t.random||(t.rng||f)();null==o&&(o=C=[1|c[0],c[1],c[2],c[3],c[4],c[5]]),null==a&&(a=S=16383&(c[6]<<8|c[7]))}var s=void 0!==t.msecs?t.msecs:Date.now(),l=void 0!==t.nsecs?t.nsecs:w+1,u=s-T+(l-w)/1e4;if(u<0&&void 0===t.clockseq&&(a=a+1&16383),(u<0||s>T)&&void 0===t.nsecs&&(l=0),l>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");T=s,w=l,S=a,s+=122192928e5;var p=(1e4*(268435455&s)+l)%4294967296;i[n++]=p>>>24&255,i[n++]=p>>>16&255,i[n++]=p>>>8&255,i[n++]=255&p;var d=s/4294967296*1e4&268435455;i[n++]=d>>>8&255,i[n++]=255&d,i[n++]=d>>>24&15|16,i[n++]=d>>>16&255,i[n++]=a>>>8|128,i[n++]=255&a;for(var h=0;h<6;++h)i[n+h]=o[h];return e||P(i)}var _=I;function A(t){if(!g(t))throw TypeError("Invalid UUID");var e,r=new Uint8Array(16);return r[0]=(e=parseInt(t.slice(0,8),16))>>>24,r[1]=e>>>16&255,r[2]=e>>>8&255,r[3]=255&e,r[4]=(e=parseInt(t.slice(9,13),16))>>>8,r[5]=255&e,r[6]=(e=parseInt(t.slice(14,18),16))>>>8,r[7]=255&e,r[8]=(e=parseInt(t.slice(19,23),16))>>>8,r[9]=255&e,r[10]=(e=parseInt(t.slice(24,36),16))/1099511627776&255,r[11]=e/4294967296&255,r[12]=e>>>24&255,r[13]=e>>>16&255,r[14]=e>>>8&255,r[15]=255&e,r}var q=A;function x(t){t=unescape(encodeURIComponent(t));for(var e=[],r=0;r>5]>>>i%32&255,a=parseInt(n.charAt(o>>>4&15)+n.charAt(15&o),16);e.push(a)}return e}function Q(t){return 14+(t+64>>>9<<4)+1}function D(t,e){t[e>>5]|=128<>5]|=(255&t[n/8])<>16)+(e>>16)+(r>>16);return n<<16|65535&r}function B(t,e){return t<>>32-e}function F(t,e,r,n,i,o){return M(B(M(M(e,t),M(n,o)),i),r)}function U(t,e,r,n,i,o,a){return F(e&r|~e&n,t,e,i,o,a)}function J(t,e,r,n,i,o,a){return F(e&n|r&~n,t,e,i,o,a)}function V(t,e,r,n,i,o,a){return F(e^r^n,t,e,i,o,a)}function $(t,e,r,n,i,o,a){return F(r^(e|~n),t,e,i,o,a)}var H=L,K=R("v3",48,H),Y=K;function z(t,e,r){t=t||{};var n=t.random||(t.rng||f)();if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,e){r=r||0;for(var i=0;i<16;++i)e[r+i]=n[i];return e}return P(n)}var G=z;function W(t,e,r,n){switch(t){case 0:return e&r^~e&n;case 1:return e^r^n;case 2:return e&r^e&n^r&n;case 3:return e^r^n}}function X(t,e){return t<>>32-e}function Z(t){var e=[1518500249,1859775393,2400959708,3395469782],r=[1732584193,4023233417,2562383102,271733878,3285377520];if("string"===typeof t){var n=unescape(encodeURIComponent(t));t=[];for(var i=0;i>>0;b=m,m=g,g=X(y,30)>>>0,y=v,v=S}r[0]=r[0]+v>>>0,r[1]=r[1]+y>>>0,r[2]=r[2]+g>>>0,r[3]=r[3]+m>>>0,r[4]=r[4]+b>>>0}return[r[0]>>24&255,r[0]>>16&255,r[0]>>8&255,255&r[0],r[1]>>24&255,r[1]>>16&255,r[1]>>8&255,255&r[1],r[2]>>24&255,r[2]>>16&255,r[2]>>8&255,255&r[2],r[3]>>24&255,r[3]>>16&255,r[3]>>8&255,255&r[3],r[4]>>24&255,r[4]>>16&255,r[4]>>8&255,255&r[4]]}var tt=Z,et=R("v5",80,tt),rt=et,nt={v1:_,v3:Y,v4:G,v5:rt};var it=r("8a40");function ot(t){return ot="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ot(t)}function at(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function ct(t){for(var e=1;e1){var n=this.query[1];delete n.logicalOperator,this.$set(this.query,1,n)}}this.query=this.query.filter((function(e){return e.id!==t})),this.getTotalCount()},onRowContentChange:function(t,e){t.preventDefault();var r=t.target.rowTerm.value,n=e.id,i=e.term,o=this.query.find((function(t){return t.id===n})),a=this.query.findIndex((function(t){return t.id===n}));o.term=r,o.query=o.query.replaceAll("(".concat(i,")"),"(".concat(r,")")),this.$set(this.query,a,o),this.closeEditTermTooltip=!0,this.countLoading=!0,this.getQueryCount(a,o),this.countLoading=!0,this.getTotalCount()},getLogicalOperatorDropdownClass:function(){var t=this.options.find((function(t){return!0===t.selected}));return t.value.toLowerCase()},canSubmit:function(){var t=this.query,e=this.termOrPhrase;return t.length>0&&e.length>0},onTopicsOrKeywordsSubmit:function(t){t.preventDefault();var e=this.termOrPhrase,r=this.query,n=this.logicalOperator,i=this.createPlacesToSearchQuery(e),o=this.createArticleSectionSearchQuery(e);i&&o?r.push({id:nt.v1(),logicalOperator:r.length>0&&n["freeText"],query:i+" OR "+o,term:e}):i?r.push({id:nt.v1(),logicalOperator:r.length>0&&n["freeText"],query:i,term:e}):o&&r.push({id:nt.v1(),logicalOperator:r.length>0&&n["freeText"],query:o,term:e}),this.resetTopicsAndKeywordsForm(),this.countLoading=!0;var a=this.query.length-1,c=this.query[this.query.length-1];this.getQueryCount(a,c),this.getTotalCount(),Object(it["g"])("#searchQueryBottomSheet")},onPublicationTypeOrJournalOrArticleIdSubmit:function(t){t.preventDefault();var e=this.articleId,r=this.query,n=this.logicalOperator,i=this.createAllPublicationQuery(),o=this.createPublicationPubmedNcbiQuery(),a=this.createPreprintServersSearchQuery(),c="";e&&(c=this.createArticleIdSearchQuery(e)),i&&r.push({id:nt.v1(),logicalOperator:r.length>0&&n["allPublicationTypes"],query:i}),o&&r.push({id:nt.v1(),logicalOperator:r.length>0&&n["publicationTypesPubmedNcbi"],query:o}),a&&r.push({id:nt.v1(),logicalOperator:r.length>0&&n["preprints"],query:a}),c&&r.push({id:nt.v1(),logicalOperator:r.length>0&&n["articleId"],query:c,term:e}),this.resetPublicationTypeOrJournalOrArticleIdForm(),this.countLoading=!0;var s=this.query.length-1,l=this.query[this.query.length-1];this.getQueryCount(s,l),this.getTotalCount(),Object(it["g"])("#searchQueryBottomSheet")},getQueryCount:function(t,e){var r=this;if(e&&e.query){var n=Object(d["P"])(e.query);n.then((function(n){e.count=n.hitCount,r.$set(r.query,t,e),r.countLoading=!1})).catch((function(){r.countLoading=!1}))}else this.countLoading=!1},getTotalCount:function(){var t=this,e=this.createSearchQuery(this.query),r=Object(d["P"])(e);r.then((function(e){t.totalCount=e.hitCount,t.countLoading=!1})).catch((function(){t.countLoading=!1}))},onSearchQueryClick:function(t){var e=t||this.createSearchQuery(this.query),r=Object(p["d"])(),n=encodeURIComponent(e||"SRC:*");location.href="?x=http://europepmc.org/".concat(r,"?query=").concat(n)},onClearQueryClick:function(){this.query=[]},createSearchQuery:function(t){var e=this,r="",n="";return t.map((function(t,i){var o=t.query,a=t.logicalOperator;i>1&&(r+=")"),i>0&&(n+="(",r+=" ".concat(a," ")),r+=o,i>0&&i+1===e.query.length&&(r+=")")})),"".concat(n).concat(r)},resetTopicsAndKeywordsForm:function(){var t=document.getElementById("topicsAndKeywordsForm");t&&t.reset(),this.termOrPhrase=null;var e=this.placesToSearch.map((function(t){return ct(ct({},t),{},{selected:!1})})),r=this.articleSectionOptions.map((function(t){return ct(ct({},t),{},{selected:!1})}));this.multiSelectStyle=this.multiSelectStyle.replace("background-color: #dfecf5;",""),this.placesToSearch=e,this.articleSectionOptions=r},resetPublicationTypeOrJournalOrArticleIdForm:function(){var t=document.getElementById("publicatiobTypeOrJournalOrArticleIdForm");t&&t.reset(),this.articleId=null;var e=this.allPublicationTypeOptions.map((function(t){return ct(ct({},t),{},{selected:!1})})),r=this.publicationTypePubmedNcbiOptions.map((function(t){return ct(ct({},t),{},{selected:!1})})),n=this.preprintOptions.map((function(t){return ct(ct({},t),{},{selected:!1})})),i=this.articleIdOptions.map((function(t){return ct(ct({},t),{},{selected:!1})}));this.allPublicationTypeOptions=e,this.allPublicationTypeOptionsPlaceholder=pt,this.preprintOptions=n,this.articleIdOptions=i,this.publicationTypePubmedNcbiOptions=r,this.publicationTypePubmedNcbiOptionsPlaceholder=pt,this.preprintServerOptionsPlaceholder=pt},createPlacesToSearchQuery:function(t){var e=[],r="";if(this.placesToSearch.map((function(t){var r=t.value,n=t.selected;!0===n&&e.push(r)})),e.includes("TITLE")&&e.includes("ABSTRACT")){r="TITLE_ABS:(".concat(t,")"),e.length>2&&(r+=" OR ");var n=e.filter((function(t){return"TITLE"!==t&&"ABSTRACT"!==t}));e=n}return e.map((function(e,n){r+="".concat(n>0?" OR ":"").concat(e?e+":":"","(").concat(t,")")})),r.replace(" ","OR"),r},createArticleSectionSearchQuery:function(t){var e=this.articleSectionOptions,r="";return e.filter((function(t){return!0===t.selected})).map((function(e,n){var i=e.value;r+="".concat(n>0?" OR ":"").concat(i,":(").concat(t,")")})),r.replace(" ","OR"),r},createAllPublicationQuery:function(){var t=this.allPublicationTypeOptions,e="";return t.filter((function(t){return!0===t.selected})).map((function(t,r){var n=t.value;e+="".concat(r>0?" OR ":"").concat(n)})),e.replace(" ","OR"),e},createPublicationPubmedNcbiQuery:function(){var t=this.publicationTypePubmedNcbiOptions,e="";return t.filter((function(t){return!0===t.selected})).map((function(t,r){var n=t.value;e+="".concat(r>0?" OR ":"","PUB_TYPE:(").concat(n,")")})),e.replace(" ","OR"),e},createPreprintServersSearchQuery:function(){var t=this.preprintOptions,e="";return t.filter((function(t){return!0===t.selected})).map((function(t,r){var n=t.value;e+="".concat(r>0?" OR ":"","PUBLISHER:(").concat(n,")")})),e.replace(" ","OR"),e?"SRC:PPR AND "+e:""},createArticleIdSearchQuery:function(t){var e=this.articleIdOptions,r=e.find((function(t){return!0===t.selected})),n=r.value,i=n.replace("*",t);return i},getSelectedOptionForLogicalOperator:function(t){return this.options.find((function(e){return e.value===t}))},exportQuery:function(){var t=this.createSearchQuery(this.query),e=document.createElement("a"),r=new Blob([t],{type:"text/plain"});e.href=URL.createObjectURL(r),e.download="query.txt",document.body.appendChild(e),e.click(),document.body.removeChild(e)},closeIntroductionModal:function(){this.showIntroductionModal=!1,localStorage.setItem("hasVisitedBetaAdvanceSearch","true")}}},ht=dt,ft=(r("9e5d"),r("2877")),vt=Object(ft["a"])(ht,i,o,!1,null,"d45d3720",null);e["default"]=vt.exports},"9e5d":function(t,e,r){"use strict";r("ab53")},ab53:function(t,e,r){}}]); //# sourceMappingURL=chunk-64244d55.13361d69.js.map