(window.webpackJsonp=window.webpackJsonp||[]).push([[1,34],{1706:function(e,t,n){var content=n(1731);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[e.i,content,""]]),content.locals&&(e.exports=content.locals);(0,n(16).default)("43a94d8d",content,!0,{sourceMap:!1})},1716:function(e,t,n){"use strict";var r=n(0),o=(n(20),n(120),n(1717),n(14),n(36),n(78),n(1738)),l=n(32),c=n(83),d=n(1529),h=(n(86),{name:"MainSearcherDropdown",components:{MainSearcherInputItem:n(1761).a},props:{miniVariant:{type:Boolean,default:!1},showingSuggestions:{type:Boolean,default:!1},coincidence:{type:String,default:""},icon:{type:String,required:!0},items:{type:Array,required:!0},inputName:{type:String,default:""},noResults:{type:Boolean,default:!1},name:{type:String,default:""}},computed:{getParentPlace(){return this.$td360config.getPlaceType(1,this.$td360config.region)}},methods:{resultsOrDummy(e){"articles"===e.name&&e.items.map((e=>Object.assign(e,{name:"articles"})));for(var output=(e.items||[]).slice();output.length<5;)output.push({dummy:!0});return output}}}),f=(n(2726),n(3)),m=Object(f.a)(h,(function(){var e=this,t=e._self._c;return t("table",{staticClass:"table search-table pa-0 ma-0 is-fullwidth"},[t("tbody",{staticClass:"search-table-body table is-stripped is-fullwidth",class:{"is-flex flex-wrap":e.$viewport.isLessThan("desktop")}},[""===e.coincidence&&e.showingSuggestions?t("tr",{staticClass:"pa-1"},[t("td",[e._m(0),e._v(" "),t("span",{staticClass:"has-text-primary is-size-8"},[e._v("\n          "+e._s(e.$t("search.main_dropdown.".concat(e.name,".suggestion")))+"\n        ")])])]):e.noResults?t("tr",{staticClass:"pa-1"},[t("td",[e._m(1),e._v(" "),t("span",{staticClass:"has-text-primary is-size-8"},[e._v("\n          "+e._s(e.$t("search.main_dropdown.".concat(e.name,".suggestion")))+"\n        ")])])]):e._e(),e._v(" "),t("tr",{staticClass:"pa-0 ma-0 flex-1",class:{columns:!e.miniVariant},attrs:{"data-cy":"list"}},[e._l(e.items,(function(n){return[n.name!==e.getParentPlace||n.name===e.getParentPlace&&!e.$store.state.modules.DisablePlaceParent?[t("td",{key:n.key||n.name,staticClass:"column pa-0 ma-0 has-scroll scroll-large"},[!n.dummy&&(n.items||[]).length>0?[t("div",{staticClass:"droppdown"},[t("p",{staticClass:"has-text-primary pa-1 has-text-weight-semibold has-background-white-ter"},["doctors"!==n.name||e.$store.state.modules.ClinicOrdinary?[e._v("\n                    "+e._s(e.$t("search.main_dropdown.".concat(n.name,".").concat(e.showingSuggestions?"suggestions":"title")))+"\n                  ")]:[e._v("\n                    "+e._s(e.$t("search.main_dropdown.".concat(n.name,"_no_clinic_ordinary.").concat(e.showingSuggestions?"suggestions":"title")))+"\n                  ")]],2)]),e._v(" "),t("ul",e._l(e.resultsOrDummy(n),(function(r,o){return t("li",{directives:[{name:"show",rawName:"v-show",value:!r.dummy,expression:"!item.dummy"}],key:String(o),attrs:{"data-cy":"dropdown-item"}},[e._t("default",(function(){return[t("MainSearcherInputItem",{key:String(o),staticClass:"py-1 pl-1 has-no-background is-clickable",attrs:{icon:e.icon,coincidence:e.coincidence,text:r.name,sons:r.sons,item:r},on:{click:function(t){return e.$emit("click",{section:n.name,item:t})}}})]}),{section:n.name,item:r,inputValue:e.coincidence,index:String(o)})],2)})),0)]:e.$viewport.isLessThan("tablet")?e._e():[t("div",{staticClass:"droppdown"},[t("p",{staticClass:"has-text-primary pa-1 has-text-weight-semibold"},[e._v("\n                  "+e._s(e.$t("search.main_dropdown.".concat(n.name,".").concat(e.showingSuggestions?"suggestions":"title")))+"\n                ")])]),e._v(" "),t("div",[t("ul",[t("li",{staticClass:"pl-1 py-1 is-flex align-center"},[e._m(2,!0),e._v(" "),t("span",{staticClass:"has-text-primary has-text-weight-semibold is-size-9 ma-0 pl-1"},[e._v("\n                      "+e._s(e.$t("search.no_results"))+"\n                    ")])])])])]],2)]:e._e()]}))],2)])])}),[function(){var e=this._self._c;return e("span",{staticClass:"icon"},[e("i",{staticClass:"td-icon-filled-alert has-text-info"})])},function(){var e=this._self._c;return e("span",{staticClass:"icon"},[e("i",{staticClass:"td-icon-filled-alert has-text-info"})])},function(){var e=this._self._c;return e("span",{staticClass:"icon is-small ma-0 pa-0"},[e("i",{staticClass:"td-icon-outline-alert has-text-primary ma-0 pa-0"})])}],!1,null,"73a516df",null).exports,v=n(1728),y=n(98),w=e=>new Error("data for results must be Array but got ".concat(e,"\nYou can use the method mapResponseData to modify it")),x=null,_={name:"MainSearcherInput",components:{MainSearcherDropdown:m,TDSpinningLogo:v.default},props:{miniVariant:{type:Boolean,default:!1},value:{type:String,default:""},name:{type:String,default:""},icon:{type:String,required:!0},placeholder:{type:String,default:""},service:{type:Function,required:!0},suggest:{type:Boolean,default:!1},cacheKey:{type:String,default:"cachekey"},preValue:{type:String,default:""},isFocused:{type:Boolean,default:!1}},data:()=>({storedValue:"",droppdownIsOpen:!1,results:[],suggestions:[],cache:{suggestions:{},results:{}},isLoading:!0,selected:!1}),computed:{inputClass(){return Object(o.a)(this.name)},reducedResultItems(){return Array.isArray(this.results)?this.results.reduce(((output,section)=>output.concat((section.items||[]).map((e=>(e.section=section.name,e))))),[]).filter((e=>!Object(c.a)(e))):[]},resultsOrSuggestions(){return this.showingSuggestions?this.suggestions:this.results},hiddenSuggestionMobile(){if(this.$viewport.isLessThan("tablet")){var e,t,n,r=!(null!==(e=this.results[0])&&void 0!==e&&e.items||null!==(t=this.results[1])&&void 0!==t&&t.items||0===(null===(n=this.results[2])||void 0===n||null===(n=n.items)||void 0===n?void 0:n.lenght));if(0!==this.value.length&&r&&"insurances"!==this.name)return!0}return!1},showingSuggestions(){return this.suggest&&(Object(l.a)(this.value)||Object(l.a)(this.results)||Object(l.a)(this.reducedResultItems))},computedCacheKey(){return this.$helpers.getCacheKey(this.cacheKey)},guessedSuggestionFromValue(){var e,t=this.resultsOrSuggestions.slice();for(var i in t.reverse())if(t[i].items&&t[i].items.length>0&&(e=t[i].items.find((e=>e.name.toLowerCase().includes(this.value.toLowerCase())))),e)break;return e},isMedicalPageDetail(){return"medical_dictionary_detail"===this.$route.name},idToScroll(){return this.isMedicalPageDetail?"":"#search-scroll"}},watch:{value:{immediate:!0,handler:Object(d.a)(function(){var e=Object(r.a)((function*(e,t){this.$store.commit("search/setGuessedSuggestion",void 0),this.selected||this.preValue===e||(this.results=yield this.search(e),!this.selected&&t&&(this.droppdownIsOpen=!0),this.name.includes("main.")&&this.$store.commit("search/setGuessedSuggestion",this.guessedSuggestionFromValue))}));return function(t,n){return e.apply(this,arguments)}}(),300)},computedCacheKey(){var e=this;return Object(r.a)((function*(){e.results=[],e.suggestions=[],e.results=yield e.search(e.value),e.suggest&&(e.suggestions=yield e.getSuggestions())}))()}},created(){x=new y.d([y.a,y.b],{expirity:this.$dateFns.addDays(new Date,1)})},mounted(){this.suggest&&this.getSuggestions().then((e=>{this.suggestions=e})),this.value&&this.search(this.value).then((e=>{this.results=e})),setTimeout((()=>{this.isFocused&&this.focusOut()}),500)},methods:{focusOut(){this.droppdownIsOpen=!1,"search_specialists"===this.$route.name&&this.$viewport.isLessThan("tablet")&&(this.droppdownIsOpen=!0)},search(text){var e=this;return Object(r.a)((function*(){"search_specialists"!==e.$route.name||e.$viewport.isLessThan("tablet")||(e.suggestions=[]);var t=e.computedCacheKey+"-"+e.name+"-"+(text||"empty_value");if(void 0!==e.cache.results[t]&&!Object(l.a)(e.cache.results[t]))return e.cache.results[t];var data=yield e.service(text);if(!Array.isArray(data)){if(!Array.isArray(data.data))throw w(typeof data);data=data.data}return e.cache.results[t]=data,e.isLoading=!1,data}))()},getSuggestions(){var e=this;return Object(r.a)((function*(){var t=e.computedCacheKey+"-"+e.name;if(void 0!==e.cache.suggestions[t]&&!Object(l.a)(e.cache.suggestions[t]))return e.cache.suggestions[t];var n=!1;if(!n){var data=yield e.service();if(!Array.isArray(data)){if(!Array.isArray(data.data))throw w(typeof data);data=data.data}n=data,x.set(t,n)}return e.cache.suggestions[t]=n,e.isLoading=!1,n}))()},scrollToSearch(){try{this.$scrollTo(this.idToScroll)}catch(e){console.log(e)}}}},S=_,k=(n(2728),Object(f.a)(S,(function(){var e=this,t=e._self._c;return t("div",{directives:[{name:"click-outside",rawName:"v-click-outside",value:()=>{e.focusOut()},expression:"() => { focusOut() }"}],staticClass:"input-container",class:{"focus-class":e.droppdownIsOpen},attrs:{"data-cy":"main-searcher-input"}},[t("p",{staticClass:"control has-icons-left lp-1"},[t("input",{ref:"input",staticClass:"input is-expanded is-large tooltip is-tooltip-top",class:e.inputClass,attrs:{title:e.placeholder,placeholder:e.placeholder||e.$t("MainSearch.placeholders.".concat(e.cacheKey)),tabindex:"-1",autocomplete:"off",type:"text","data-cy":"input"},domProps:{value:e.value},on:{input:function(t){return e.$emit("input",t.target.value)},focus:()=>{e.scrollToSearch(),e.droppdownIsOpen=!0,e.$emit("input","")}}}),e._v(" "),t("span",{staticClass:"icon is-left tooltip is-tooltip-top reset-height"},[t("i",{class:e.icon})])]),e._v(" "),e.droppdownIsOpen?t("div",{staticClass:"search-container box pa-0 ma-0",class:[e.droppdownIsOpen?"is-open":"hidden",e.miniVariant?"is-mini":""]},[e.isLoading?t("div",{staticClass:"loader-wrapper"},[t("TDSpinningLogo")],1):e.hiddenSuggestionMobile&&0==e.resultsOrSuggestions.length?t("div",[e._v("\n      No se encontraron coincidencias\n    ")]):t("MainSearcherDropdown",{attrs:{items:e.resultsOrSuggestions,icon:e.icon,name:e.name,coincidence:e.value,"showing-suggestions":e.showingSuggestions,"no-results":0===e.reducedResultItems.length,"mini-variant":e.miniVariant,"data-cy":"dropdown"},on:{click:t=>{e.$emit("click",t),e.selected=!0,e.$viewport.isLessThan("tablet")||(e.droppdownIsOpen=!1)}},scopedSlots:e._u([{key:"default",fn:function(t){return e.$scopedSlots.default?[e._t("default",null,{close:t=>{t(),e.focusOut(),e.selected=!0}},t)]:void 0}}],null,!0)})],1):e._e()])}),[],!1,null,"7be538ae",null));t.a=k.exports},1728:function(e,t,n){"use strict";n.r(t);var r={name:"TDSpinningLogo"},o=(n(1730),n(3)),component=Object(o.a)(r,(function(){var e=this._self._c;return e("span",{staticClass:"logo td-loader"},[e("svg",{staticClass:"heart-loader",attrs:{"xmlns:rdf":"http://www.w3.org/1999/02/22-rdf-syntax-ns#","xmlns:svg":"http://www.w3.org/2000/svg",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 90 90",version:"1.1"}},[e("g",{staticClass:"heart-loader__group"},[e("path",{staticClass:"heart-loader__heartPath",attrs:{"stroke-width":"4","stroke-linecap":"round",d:"M60,30 a30,30 0 0,1 0,60 L0,90 0,30 a30,30 0 0,1 60,0"}})])])])}),[],!1,null,"04605062",null);t.default=component.exports},1730:function(e,t,n){"use strict";n(1706)},1731:function(e,t,n){var r=n(15)((function(i){return i[1]}));r.push([e.i,".spin[data-v-04605062]{animation:spin-04605062 1.4s infinite ease-in-out}@keyframes spin-04605062{0%{transform:perspective(120px) rotateX(0deg) rotateY(0deg)}50%{transform:perspective(120px) rotateX(0deg) rotateY(-180deg)}100%{transform:perspective(120px) rotateX(0deg) rotateY(-360deg)}}*[data-v-04605062],*[data-v-04605062]:before,*[data-v-04605062]:after{box-sizing:border-box;margin:0;padding:0}.heart-loader[data-v-04605062]{position:absolute;display:block;left:50%;top:50%;margin-top:-40px;width:80px;height:80px;overflow:visible}.heart-loader__group[data-v-04605062]{transform-origin:0 90px;animation:group-anim 2s 1s infinite;transform:rotate(-45deg)}.heart-loader__heartPath[data-v-04605062]{stroke:#007fb5;fill:rgba(0,0,0,0);stroke-dasharray:308.522,308.522;stroke-dashoffset:308.522;animation:heart-anim-04605062 2s 1s infinite}@keyframes heart-anim-04605062{0%{stroke-dashoffset:308.522;fill:rgba(0,0,0,0)}25%{stroke-dashoffset:0;fill:rgba(0,0,0,0)}75%{stroke-dashoffset:0;fill:#007fb5}100%{stroke-dashoffset:0;fill:rgba(0,0,0,0);stroke-opacity:0}}",""]),r.locals={},e.exports=r},1743:function(e,t,n){"use strict";var r=n(162),o={name:"EmSpan",introduction:"Component that show all the coincidence of string in boldface type",description:"This component is used into the searchers",props:{coincidence:{type:String,default:""},text:{type:String,default:""}},data:()=>({}),computed:{result(){for(var e=Object(r.normalize)(this.text||""),t=Object(r.normalize)(this.coincidence||""),n=this._getIndicesOf(t,e,!1),o=this.text,i=0;i<n.length;i++){var l=this.text.substr(n[i],this.coincidence.length);o=o.substring(0,n[i]+7*i)+"<b>"+l+"</b>"+o.substr(n[i]+l.length+7*i,o.length)}return o}},methods:{_getIndicesOf(e,t,n){var r=e.length;if(0===r)return[];var o=0,l=0,c=[];for(n||(t=t.toLowerCase(),e=e.toLowerCase());(l=t.indexOf(e,o))>-1;)c.push(l),o=l+r;return c}}},l=n(3),component=Object(l.a)(o,(function(){var e=this;return(0,e._self._c)("span",{domProps:{innerHTML:e._s(e.result)}})}),[],!1,null,null,null);t.a=component.exports},1761:function(e,t,n){"use strict";var r={name:"MainSearcherInputItem",components:{EmphasibleSpan:n(1743).a},props:{icon:{type:String,default:""},coincidence:{type:String,default:""},text:{type:String,default:""},sons:{type:Array,default:void 0},item:{type:Object,required:!0}},data(){return{storageURL:this.$td360config.getValue("urls.storage")}},computed:{image(){var e,t;return[this.storageURL,null===(e=this.item.image)||void 0===e?void 0:e.path,null===(t=this.item.image)||void 0===t?void 0:t.uuid].filter((i=>""!==i)).join("/")}}},o=(n(2724),n(3)),component=Object(o.a)(r,(function(){var e=this,t=e._self._c;return t("span",{staticClass:"is-clickable"},[t("a",{staticClass:"ma-0 pa-0 is-fullwidth",on:{click:function(t){return e.$emit("click",e.item)}}},["articles"!==e.item.name&&"articles"!==e.item.section?t("span",{staticClass:"panel-icon"},[t("i",{class:e.icon})]):t("img",{staticClass:"img-circle",attrs:{src:e.image,onerror:"this.src='".concat(n(2035),"'")},on:{error:function(t){e.errorLoading=!0}}}),e._v(" "),t("span",[t("EmphasibleSpan",{staticStyle:{display:"inline"},attrs:{coincidence:e.coincidence,text:"articles"===e.item.name?e.item.title:e.text,"data-cy":"item"}})],1)]),e._v(" "),e.$u.arrays.filled(e.sons)?t("ul",{staticClass:"pl-1"},e._l(e.sons,(function(n,r){return t("li",{key:r},[t("MainSearcherInputItem",{attrs:{coincidence:e.coincidence,text:"articles"===n.name?n.title:n.name,sons:n.sons,item:n,icon:"td-icon-filled-chevron-right-bold"},on:{click:function(t){return e.$emit("click",t)}}})],1)})),0):e._e()])}),[],!1,null,"ef51c45a",null);t.a=component.exports},2035:function(e,t,n){e.exports=n.p+"img/logo-topdoctors-vertical.583ee8a.jpg"},2350:function(e,t,n){var content=n(2725);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[e.i,content,""]]),content.locals&&(e.exports=content.locals);(0,n(16).default)("0d88a87b",content,!0,{sourceMap:!1})},2351:function(e,t,n){var content=n(2727);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[e.i,content,""]]),content.locals&&(e.exports=content.locals);(0,n(16).default)("08eb15f8",content,!0,{sourceMap:!1})},2352:function(e,t,n){var content=n(2729);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[e.i,content,""]]),content.locals&&(e.exports=content.locals);(0,n(16).default)("559e178b",content,!0,{sourceMap:!1})},2724:function(e,t,n){"use strict";n(2350)},2725:function(e,t,n){var r=n(15)((function(i){return i[1]}));r.push([e.i,"span[data-v-ef51c45a]{display:flex;flex-flow:column;justify-content:flex-start;align-items:flex-start}span a[data-v-ef51c45a]:hover{background-color:initial !important}",""]),r.locals={},e.exports=r},2726:function(e,t,n){"use strict";n(2351)},2727:function(e,t,n){var r=n(15)((function(i){return i[1]}));r.push([e.i,".search-table[data-v-73a516df]{border:none}.search-table[data-v-73a516df] .search-table-body{border:none}.search-table[data-v-73a516df] .search-table-body td,.search-table[data-v-73a516df] .search-table-body th{border:none}.search-table[data-v-73a516df] .search-table-body tr a span{font-size:.9rem;color:#6f6f6f}.search-table[data-v-73a516df] .search-table-body tr a .icon i,.search-table[data-v-73a516df] .search-table-body tr a .panel-icon i{color:#009ee2;font-weight:600;font-size:1rem}.search-table[data-v-73a516df] .search-table-body tr a .img-circle{width:50px;height:50px;margin:10px;border:1px solid #bfcace;object-fit:cover;border-radius:100%}.search-table[data-v-73a516df] .search-table-body tr ul li{border-bottom:1px solid #e4edee}.search-table[data-v-73a516df] .search-table-body tr ul li a,.search-table[data-v-73a516df] .search-table-body tr ul li span a{display:flex;align-items:center}.search-table[data-v-73a516df] .search-table-body tr ul li:first-of-type{border-top:1px solid #e4edee}.search-table[data-v-73a516df] .search-table-body tr ul li:hover{background:#f8fafb}.search-table[data-v-73a516df] .search-table-body tr td:nth-of-type(2){border-left:1px solid #e4edee}.search-table[data-v-73a516df] .search-table-body tr td:nth-of-type(3){border-left:1px solid #e4edee}.search-table[data-v-73a516df] .search-table-body tr td:nth-of-type(3) ul li{border-bottom:1px solid #e4edee}.search-table[data-v-73a516df] .search-table-body tr td:nth-of-type(3) ul li a{display:flex;align-items:center}.search-table[data-v-73a516df] .search-table-body tr td:nth-of-type(3) ul li a span.name-doctor-center-list{line-height:1.5rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.search-table[data-v-73a516df] .search-table-body tr td:nth-of-type(3) ul li a span.name-doctor-center-list .has-text-primary{font-size:.8rem}.search-table[data-v-73a516df] .search-table-body tr td:nth-of-type(3) ul li:first-of-type{border-top:1px solid #e4edee}@media screen and (min-width: 768px){.column[data-v-73a516df]{min-width:180px}}@media screen and (min-width: 1170px){.column[data-v-73a516df]{min-width:200px}}.column.is-large[data-v-73a516df]{width:340px}@media screen and (max-width: 600px){.column.is-large[data-v-73a516df]{min-width:300px;max-width:300px}}p[data-v-73a516df]{font-size:1rem}.has-no-background[data-v-73a516df]{background-color:none}.has-no-background[data-v-73a516df]:hover{background-color:none}.has-no-background:hover>*[data-v-73a516df]{background-color:none}.has-scroll[data-v-73a516df]{max-height:300px;overflow:auto;width:100%}.has-scroll.scroll-large[data-v-73a516df]{max-height:400px}",""]),r.locals={},e.exports=r},2728:function(e,t,n){"use strict";n(2352)},2729:function(e,t,n){var r=n(15)((function(i){return i[1]}));r.push([e.i,"@supports(-webkit-touch-callout: none){input.input[data-v-7be538ae]{font-size:16px !important}}[data-v-7be538ae]::placeholder{color:#97979a !important;font-size:.9rem}.medical-dictionary[data-v-7be538ae]::placeholder{font-size:1.5rem}@keyframes animdropp-7be538ae{0%{-webkit-clip-path:polygon(0 0, 0 0, 0 0, 0 0);clip-path:polygon(0 0, 0 0, 0 0, 0 0);opacity:0}25%{-webkit-clip-path:polygon(0 0, 62% 0, 30% 27%, 0 54%);clip-path:polygon(0 0, 62% 0, 30% 27%, 0 54%)}50%{-webkit-clip-path:polygonseguro médico(0 0, 100% 0%, 50% 50%, 0% 100%);clip-path:polygon(0 0, 100% 0%, 50% 50%, 0% 100%);opacity:.3}100%{-webkit-clip-path:polygon(0 0, 100% 0, 100% 100%, 0% 100%);clip-path:polygon(0 0, 100% 0, 100% 100%, 0% 100%);opacity:1}}.reset-height[data-v-7be538ae]{height:100% !important}.search-container[data-v-7be538ae]{box-sizing:border-box;position:absolute;height:auto;-webkit-clip-path:polygon(0 0, 100% 0, 100% 100%, 0% 100%);clip-path:polygon(0 0, 100% 0, 100% 100%, 0% 100%);transition:all .1s linear;animation:animdropp-7be538ae .15s alternate;border-radius:6px;border:rgba(128,128,128,.4) 1px solid;z-index:9999 !important;top:calc(100% + 3px);will-change:-webkit-clip-path,clip-path,opacity}@media screen and (max-width: 600px){.search-container[data-v-7be538ae]{font-size:.7rem !important}}.focus-class[data-v-7be538ae]{box-shadow:0 0 0 1px #009ee2}@media screen and (max-width: 992px){.search-container[data-v-7be538ae]{width:100%;left:0}}@media screen and (min-width: 992px){[data-v-7be538ae] .icon{justify-content:left !important;padding-left:10px !important}[data-v-7be538ae] input.input{padding-left:50px !important}}.loader-wrapper[data-v-7be538ae]{height:90vh;overflow:hidden;display:flex;justify-content:center;align-items:center;text-align:center}",""]),r.locals={},e.exports=r}}]);