cas-ds-web-components 1.2.87 → 1.2.88

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -268,7 +268,7 @@
268
268
  * @license
269
269
  * Copyright 2018 Google LLC
270
270
  * SPDX-License-Identifier: BSD-3-Clause
271
- */const Wt=we(class extends Ee{constructor(o){var t;if(super(o),o.type!==xe.ATTRIBUTE||o.name!=="class"||((t=o.strings)===null||t===void 0?void 0:t.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(o){return" "+Object.keys(o).filter(t=>o[t]).join(" ")+" "}update(o,[t]){var e,i;if(this.it===void 0){this.it=new Set,o.strings!==void 0&&(this.nt=new Set(o.strings.join(" ").split(/\s/).filter(r=>r!=="")));for(const r in t)t[r]&&!(!((e=this.nt)===null||e===void 0)&&e.has(r))&&this.it.add(r);return this.render(t)}const s=o.element.classList;this.it.forEach(r=>{r in t||(s.remove(r),this.it.delete(r))});for(const r in t){const n=!!t[r];n===this.it.has(r)||!((i=this.nt)===null||i===void 0)&&i.has(r)||(n?(s.add(r),this.it.add(r)):(s.remove(r),this.it.delete(r)))}return T}}),pt=[{name:"Consulta médica",items:[{name:"Presencial",link:"https://reserva.alemana.cl/reserva/portal/busqueda"},{name:"Teleconsulta",link:"https://agenda.clinicaalemana.cl/paciente"},{name:"TeleUrgencia",link:"https://www.clinicaalemana.cl/telemedicina/teleurgencia"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio"}]},{name:"Exámenes y procedimientos",items:[{name:"Presencial",link:"https://www.clinicaalemana.cl/examenes-y-procedimientos"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio/examenes-laboratorio-domicilio"}]},{name:"Vacunas",items:[{name:"Adulto",link:"https://www.alemana.cl/ReservaDeHoras/resultado-busqueda-area.aspx?idEmp=2&horario=todas&su=-1&idioma=todas&valorArea=Vacunas+Adulto&Am=229,0&Ai=-1&CentrosSalud=-1&centroNombre=&CenAm=-1&CenAi=-1&d=20-12-2023&idAgenda=undefined&fp=20-12-2023&rp=&ipac=0&idreserva=&buscar-nombre=&dispositivo=2&cal=1&linkPortal="},{name:"Covid-19",link:"https://www.clinicaalemana.cl/covid-19"},{name:"Influenza",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/influenza-2023"},{name:"Viajeros",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/reserva-vacuna-fiebre-amarilla"},{name:"TeleAsesoría pediátrica",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/asesoria-en-vacunacion-pediatrica"}]}];class V extends R{constructor(){super(),this.hidden=!1,this.tipoDeAtencion="",this.modalidad="",this.dataTipoDeAtencion=[],this.dataModalidad=[],this.focused=!1,this.refresh=!1,this.link=""}changeHandler(t){const e=t.target.name;if(this[e]=t.composedPath()[0].value,this.handleErrorTipoDeAtencion(!1),this.handleErrorModalidad(!1),e==="tipoDeAtencion"){this.modalidad="",this.refresh=!0,this.handleFocusModalidad(!0),this.handleFocusTipoDeAtencion(!1);const i=pt.find(s=>s.name===this.tipoDeAtencion).items.map(s=>s.name);this.dataModalidad=[...i],this.requestUpdate(),setTimeout(()=>{this.refresh=!1,this.requestUpdate()},100)}e==="modalidad"&&this.handleFocusModalidad(!1),this.handleLink()}handleFocusTipoDeAtencion(t){const e=this.shadowRoot.getElementById("tipoDeAtencion");e==null||e.setAttribute("active",t)}handleFocusModalidad(t){const e=this.shadowRoot.getElementById("modalidad");e==null||e.setAttribute("active",t)}handleErrorTipoDeAtencion(t){const e=this.shadowRoot.getElementById("tipoDeAtencion");t?e==null||e.setAttribute("isSelectError",!0):e==null||e.removeAttribute("isSelectError")}handleErrorModalidad(t){const e=this.shadowRoot.getElementById("modalidad");t?e==null||e.setAttribute("isSelectError",!0):e==null||e.removeAttribute("isSelectError")}handleLink(){let t="";this.tipoDeAtencion!==""&&this.modalidad!==""&&(t=pt.find(i=>i.name===this.tipoDeAtencion).items.find(i=>i.name===this.modalidad).link),this.link=t;const e=this.shadowRoot.querySelector(".btn-action");this.link!==""?e.setAttribute("href",this.link):e.removeAttribute("href")}submit(){this.link!==""?this.handleMark({category:"reservar_hora"}):this.tipoDeAtencion===""?(this.handleErrorTipoDeAtencion(!0),this.handleErrorModalidad(!0)):(this.handleFocusModalidad(!1),this.handleErrorModalidad(!0))}handleMark({category:t,action:e,label:i}){try{window.dataLayer.push({event:"evento-interactivo","evento-interactivo-categoria":t,"evento-interactivo-accion":e??this.tipoDeAtencion,"evento-interactivo-etiqueta":i??this.modalidad})}catch{console.log("event push failed")}}eventHandler(){this.removeAttribute("hidden");let t=this.shadowRoot.getElementById("backdrop");t.style.display="flex",this.hidden=!1,this.focused=!0,this.requestUpdate()}firstUpdated(){if(this.handleParameter(),this.onlyView||document.addEventListener("openBookingBox",()=>{this.eventHandler()}),window.innerWidth>1023){const t=this.shadowRoot.querySelector(".booking-box");let e=this.shadowRoot.getElementById("backdrop");t.addEventListener("focusin",()=>{this.focused=!0,e.style.display="flex",this.requestUpdate()})}}handleParameter(){new URLSearchParams(window.location.search).get("rsv")==="true"&&this.eventHandler()}closeHandler(){let t=this.shadowRoot.getElementById("backdrop");t.style.display="none",this.hidden=!1,this.focused=!1,this.requestUpdate()}handleOverrideTime(){this.handleMark({category:"anular_hora"})}render(){const t=Wt({"booking-box":!0,hidden:this.hidden,home:this.home,focused:this.focused}),e=Wt({backdrop:!0,hidden:this.hidden});return ct`
271
+ */const Wt=we(class extends Ee{constructor(o){var t;if(super(o),o.type!==xe.ATTRIBUTE||o.name!=="class"||((t=o.strings)===null||t===void 0?void 0:t.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(o){return" "+Object.keys(o).filter(t=>o[t]).join(" ")+" "}update(o,[t]){var e,i;if(this.it===void 0){this.it=new Set,o.strings!==void 0&&(this.nt=new Set(o.strings.join(" ").split(/\s/).filter(r=>r!=="")));for(const r in t)t[r]&&!(!((e=this.nt)===null||e===void 0)&&e.has(r))&&this.it.add(r);return this.render(t)}const s=o.element.classList;this.it.forEach(r=>{r in t||(s.remove(r),this.it.delete(r))});for(const r in t){const n=!!t[r];n===this.it.has(r)||!((i=this.nt)===null||i===void 0)&&i.has(r)||(n?(s.add(r),this.it.add(r)):(s.remove(r),this.it.delete(r)))}return T}}),pt=[{name:"Consulta médica",items:[{name:"Presencial",link:"https://reserva.alemana.cl/reserva/portal/busqueda"},{name:"Teleconsulta",link:"https://agenda.clinicaalemana.cl/paciente"},{name:"TeleUrgencia",link:"https://www.clinicaalemana.cl/telemedicina/teleurgencia"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio"},{name:"Teledermatología",link:"https://teledermatologia.clinicaalemana.cl/"}]},{name:"Exámenes y procedimientos",items:[{name:"Presencial",link:"https://www.clinicaalemana.cl/examenes-y-procedimientos"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio/examenes-laboratorio-domicilio"}]},{name:"Vacunas",items:[{name:"Adulto",link:"https://www.alemana.cl/ReservaDeHoras/resultado-busqueda-area.aspx?idEmp=2&horario=todas&su=-1&idioma=todas&valorArea=Vacunas+Adulto&Am=229,0&Ai=-1&CentrosSalud=-1&centroNombre=&CenAm=-1&CenAi=-1&d=20-12-2023&idAgenda=undefined&fp=20-12-2023&rp=&ipac=0&idreserva=&buscar-nombre=&dispositivo=2&cal=1&linkPortal="},{name:"Covid-19",link:"https://www.clinicaalemana.cl/covid-19"},{name:"Influenza",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/influenza-2023"},{name:"Viajeros",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/reserva-vacuna-fiebre-amarilla"},{name:"TeleAsesoría pediátrica",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/asesoria-en-vacunacion-pediatrica"}]}];class V extends R{constructor(){super(),this.hidden=!1,this.tipoDeAtencion="",this.modalidad="",this.dataTipoDeAtencion=[],this.dataModalidad=[],this.focused=!1,this.refresh=!1,this.link=""}changeHandler(t){const e=t.target.name;if(this[e]=t.composedPath()[0].value,this.handleErrorTipoDeAtencion(!1),this.handleErrorModalidad(!1),e==="tipoDeAtencion"){this.modalidad="",this.refresh=!0,this.handleFocusModalidad(!0),this.handleFocusTipoDeAtencion(!1);const i=pt.find(s=>s.name===this.tipoDeAtencion).items.map(s=>s.name);this.dataModalidad=[...i],this.requestUpdate(),setTimeout(()=>{this.refresh=!1,this.requestUpdate()},100)}e==="modalidad"&&this.handleFocusModalidad(!1),this.handleLink()}handleFocusTipoDeAtencion(t){const e=this.shadowRoot.getElementById("tipoDeAtencion");e==null||e.setAttribute("active",t)}handleFocusModalidad(t){const e=this.shadowRoot.getElementById("modalidad");e==null||e.setAttribute("active",t)}handleErrorTipoDeAtencion(t){const e=this.shadowRoot.getElementById("tipoDeAtencion");t?e==null||e.setAttribute("isSelectError",!0):e==null||e.removeAttribute("isSelectError")}handleErrorModalidad(t){const e=this.shadowRoot.getElementById("modalidad");t?e==null||e.setAttribute("isSelectError",!0):e==null||e.removeAttribute("isSelectError")}handleLink(){let t="";this.tipoDeAtencion!==""&&this.modalidad!==""&&(t=pt.find(i=>i.name===this.tipoDeAtencion).items.find(i=>i.name===this.modalidad).link),this.link=t;const e=this.shadowRoot.querySelector(".btn-action");this.link!==""?e.setAttribute("href",this.link):e.removeAttribute("href")}submit(){this.link!==""?this.handleMark({category:"reservar_hora"}):this.tipoDeAtencion===""?(this.handleErrorTipoDeAtencion(!0),this.handleErrorModalidad(!0)):(this.handleFocusModalidad(!1),this.handleErrorModalidad(!0))}handleMark({category:t,action:e,label:i}){try{window.dataLayer.push({event:"evento-interactivo","evento-interactivo-categoria":t,"evento-interactivo-accion":e??this.tipoDeAtencion,"evento-interactivo-etiqueta":i??this.modalidad})}catch{console.log("event push failed")}}eventHandler(){this.removeAttribute("hidden");let t=this.shadowRoot.getElementById("backdrop");t.style.display="flex",this.hidden=!1,this.focused=!0,this.requestUpdate()}firstUpdated(){if(this.handleParameter(),this.onlyView||document.addEventListener("openBookingBox",()=>{this.eventHandler()}),window.innerWidth>1023){const t=this.shadowRoot.querySelector(".booking-box");let e=this.shadowRoot.getElementById("backdrop");t.addEventListener("focusin",()=>{this.focused=!0,e.style.display="flex",this.requestUpdate()})}}handleParameter(){new URLSearchParams(window.location.search).get("rsv")==="true"&&this.eventHandler()}closeHandler(){let t=this.shadowRoot.getElementById("backdrop");t.style.display="none",this.hidden=!1,this.focused=!1,this.requestUpdate()}handleOverrideTime(){this.handleMark({category:"anular_hora"})}render(){const t=Wt({"booking-box":!0,hidden:this.hidden,home:this.home,focused:this.focused}),e=Wt({backdrop:!0,hidden:this.hidden});return ct`
272
272
  <div class="${e}" id="backdrop" @click="${this.closeHandler}"></div>
273
273
  <div class="booking-box-main-cont" id="booking-box-main-cont">
274
274
  <div class="${t}" id="booking-box" tabindex="0">
@@ -1,4 +1,4 @@
1
- (function(b,J){typeof exports=="object"&&typeof module<"u"?J(exports):typeof define=="function"&&define.amd?define(["exports"],J):(b=typeof globalThis<"u"?globalThis:b||self,J(b["all-components"]={}))})(this,function(b){"use strict";var Sv=Object.defineProperty;var Tv=(b,J,J1)=>J in b?Sv(b,J,{enumerable:!0,configurable:!0,writable:!0,value:J1}):b[J]=J1;var g=(b,J,J1)=>(Tv(b,typeof J!="symbol"?J+"":J,J1),J1);var I3,EC;(()=>{const i=document.createElement("link");i.setAttribute("href","https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap"),i.setAttribute("rel","stylesheet"),document.head.appendChild(i)})();const Y5={name:"@eloisa-ds/all-components",version:"1.0.89",dependencies:{},main:"./index.js",module:"./index.mjs",typings:"./index.d.ts",private:!0};/**
1
+ (function(b,J){typeof exports=="object"&&typeof module<"u"?J(exports):typeof define=="function"&&define.amd?define(["exports"],J):(b=typeof globalThis<"u"?globalThis:b||self,J(b["all-components"]={}))})(this,function(b){"use strict";var Sv=Object.defineProperty;var Tv=(b,J,J1)=>J in b?Sv(b,J,{enumerable:!0,configurable:!0,writable:!0,value:J1}):b[J]=J1;var g=(b,J,J1)=>(Tv(b,typeof J!="symbol"?J+"":J,J1),J1);var I3,EC;(()=>{const i=document.createElement("link");i.setAttribute("href","https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap"),i.setAttribute("rel","stylesheet"),document.head.appendChild(i)})();const Y5={name:"@eloisa-ds/all-components",version:"1.0.90",dependencies:{},main:"./index.js",module:"./index.mjs",typings:"./index.d.ts",private:!0};/**
2
2
  * @license
3
3
  * Copyright 2019 Google LLC
4
4
  * SPDX-License-Identifier: BSD-3-Clause
@@ -7074,7 +7074,7 @@
7074
7074
  border-radius: 8px; /* rounded */
7075
7075
  background-color: rgba(229, 231, 235, 0.5); /* bg-gray-100 */
7076
7076
  }
7077
- `,k6=[{name:"Consulta médica",items:[{name:"Presencial",link:"https://reserva.alemana.cl/reserva/portal/busqueda"},{name:"Teleconsulta",link:"https://agenda.clinicaalemana.cl/paciente"},{name:"TeleUrgencia",link:"https://www.clinicaalemana.cl/telemedicina/teleurgencia"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio"}]},{name:"Exámenes y procedimientos",items:[{name:"Presencial",link:"https://www.clinicaalemana.cl/examenes-y-procedimientos"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio/examenes-laboratorio-domicilio"}]},{name:"Vacunas",items:[{name:"Adulto",link:"https://www.alemana.cl/ReservaDeHoras/resultado-busqueda-area.aspx?idEmp=2&horario=todas&su=-1&idioma=todas&valorArea=Vacunas+Adulto&Am=229,0&Ai=-1&CentrosSalud=-1&centroNombre=&CenAm=-1&CenAi=-1&d=20-12-2023&idAgenda=undefined&fp=20-12-2023&rp=&ipac=0&idreserva=&buscar-nombre=&dispositivo=2&cal=1&linkPortal="},{name:"Covid-19",link:"https://www.clinicaalemana.cl/covid-19"},{name:"Influenza",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/influenza-2023"},{name:"Viajeros",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/reserva-vacuna-fiebre-amarilla"},{name:"TeleAsesoría pediátrica",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/asesoria-en-vacunacion-pediatrica"}]}];class t5 extends f{constructor(){super(),this.hidden=!1,this.tipoDeAtencion="",this.modalidad="",this.dataTipoDeAtencion=[],this.dataModalidad=[],this.focused=!1,this.refresh=!1,this.link=""}changeHandler(C){const t=C.target.name;if(this[t]=C.composedPath()[0].value,this.handleErrorTipoDeAtencion(!1),this.handleErrorModalidad(!1),t==="tipoDeAtencion"){this.modalidad="",this.refresh=!0,this.handleFocusModalidad(!0),this.handleFocusTipoDeAtencion(!1);const e=k6.find(o=>o.name===this.tipoDeAtencion).items.map(o=>o.name);this.dataModalidad=[...e],this.requestUpdate(),setTimeout(()=>{this.refresh=!1,this.requestUpdate()},100)}t==="modalidad"&&this.handleFocusModalidad(!1),this.handleLink()}handleFocusTipoDeAtencion(C){const t=this.shadowRoot.getElementById("tipoDeAtencion");t==null||t.setAttribute("active",C)}handleFocusModalidad(C){const t=this.shadowRoot.getElementById("modalidad");t==null||t.setAttribute("active",C)}handleErrorTipoDeAtencion(C){const t=this.shadowRoot.getElementById("tipoDeAtencion");C?t==null||t.setAttribute("isSelectError",!0):t==null||t.removeAttribute("isSelectError")}handleErrorModalidad(C){const t=this.shadowRoot.getElementById("modalidad");C?t==null||t.setAttribute("isSelectError",!0):t==null||t.removeAttribute("isSelectError")}handleLink(){let C="";this.tipoDeAtencion!==""&&this.modalidad!==""&&(C=k6.find(e=>e.name===this.tipoDeAtencion).items.find(e=>e.name===this.modalidad).link),this.link=C;const t=this.shadowRoot.querySelector(".btn-action");this.link!==""?t.setAttribute("href",this.link):t.removeAttribute("href")}submit(){this.link!==""?this.handleMark({category:"reservar_hora"}):this.tipoDeAtencion===""?(this.handleErrorTipoDeAtencion(!0),this.handleErrorModalidad(!0)):(this.handleFocusModalidad(!1),this.handleErrorModalidad(!0))}handleMark({category:C,action:t,label:e}){try{window.dataLayer.push({event:"evento-interactivo","evento-interactivo-categoria":C,"evento-interactivo-accion":t??this.tipoDeAtencion,"evento-interactivo-etiqueta":e??this.modalidad})}catch{console.log("event push failed")}}eventHandler(){this.removeAttribute("hidden");let C=this.shadowRoot.getElementById("backdrop");C.style.display="flex",this.hidden=!1,this.focused=!0,this.requestUpdate()}firstUpdated(){if(this.handleParameter(),this.onlyView||document.addEventListener("openBookingBox",()=>{this.eventHandler()}),window.innerWidth>1023){const C=this.shadowRoot.querySelector(".booking-box");let t=this.shadowRoot.getElementById("backdrop");C.addEventListener("focusin",()=>{this.focused=!0,t.style.display="flex",this.requestUpdate()})}}handleParameter(){new URLSearchParams(window.location.search).get("rsv")==="true"&&this.eventHandler()}closeHandler(){let C=this.shadowRoot.getElementById("backdrop");C.style.display="none",this.hidden=!1,this.focused=!1,this.requestUpdate()}handleOverrideTime(){this.handleMark({category:"anular_hora"})}render(){const C=a2({"booking-box":!0,hidden:this.hidden,home:this.home,focused:this.focused}),t=a2({backdrop:!0,hidden:this.hidden});return M`
7077
+ `,k6=[{name:"Consulta médica",items:[{name:"Presencial",link:"https://reserva.alemana.cl/reserva/portal/busqueda"},{name:"Teleconsulta",link:"https://agenda.clinicaalemana.cl/paciente"},{name:"TeleUrgencia",link:"https://www.clinicaalemana.cl/telemedicina/teleurgencia"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio"},{name:"Teledermatología",link:"https://teledermatologia.clinicaalemana.cl/"}]},{name:"Exámenes y procedimientos",items:[{name:"Presencial",link:"https://www.clinicaalemana.cl/examenes-y-procedimientos"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio/examenes-laboratorio-domicilio"}]},{name:"Vacunas",items:[{name:"Adulto",link:"https://www.alemana.cl/ReservaDeHoras/resultado-busqueda-area.aspx?idEmp=2&horario=todas&su=-1&idioma=todas&valorArea=Vacunas+Adulto&Am=229,0&Ai=-1&CentrosSalud=-1&centroNombre=&CenAm=-1&CenAi=-1&d=20-12-2023&idAgenda=undefined&fp=20-12-2023&rp=&ipac=0&idreserva=&buscar-nombre=&dispositivo=2&cal=1&linkPortal="},{name:"Covid-19",link:"https://www.clinicaalemana.cl/covid-19"},{name:"Influenza",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/influenza-2023"},{name:"Viajeros",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/reserva-vacuna-fiebre-amarilla"},{name:"TeleAsesoría pediátrica",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/asesoria-en-vacunacion-pediatrica"}]}];class t5 extends f{constructor(){super(),this.hidden=!1,this.tipoDeAtencion="",this.modalidad="",this.dataTipoDeAtencion=[],this.dataModalidad=[],this.focused=!1,this.refresh=!1,this.link=""}changeHandler(C){const t=C.target.name;if(this[t]=C.composedPath()[0].value,this.handleErrorTipoDeAtencion(!1),this.handleErrorModalidad(!1),t==="tipoDeAtencion"){this.modalidad="",this.refresh=!0,this.handleFocusModalidad(!0),this.handleFocusTipoDeAtencion(!1);const e=k6.find(o=>o.name===this.tipoDeAtencion).items.map(o=>o.name);this.dataModalidad=[...e],this.requestUpdate(),setTimeout(()=>{this.refresh=!1,this.requestUpdate()},100)}t==="modalidad"&&this.handleFocusModalidad(!1),this.handleLink()}handleFocusTipoDeAtencion(C){const t=this.shadowRoot.getElementById("tipoDeAtencion");t==null||t.setAttribute("active",C)}handleFocusModalidad(C){const t=this.shadowRoot.getElementById("modalidad");t==null||t.setAttribute("active",C)}handleErrorTipoDeAtencion(C){const t=this.shadowRoot.getElementById("tipoDeAtencion");C?t==null||t.setAttribute("isSelectError",!0):t==null||t.removeAttribute("isSelectError")}handleErrorModalidad(C){const t=this.shadowRoot.getElementById("modalidad");C?t==null||t.setAttribute("isSelectError",!0):t==null||t.removeAttribute("isSelectError")}handleLink(){let C="";this.tipoDeAtencion!==""&&this.modalidad!==""&&(C=k6.find(e=>e.name===this.tipoDeAtencion).items.find(e=>e.name===this.modalidad).link),this.link=C;const t=this.shadowRoot.querySelector(".btn-action");this.link!==""?t.setAttribute("href",this.link):t.removeAttribute("href")}submit(){this.link!==""?this.handleMark({category:"reservar_hora"}):this.tipoDeAtencion===""?(this.handleErrorTipoDeAtencion(!0),this.handleErrorModalidad(!0)):(this.handleFocusModalidad(!1),this.handleErrorModalidad(!0))}handleMark({category:C,action:t,label:e}){try{window.dataLayer.push({event:"evento-interactivo","evento-interactivo-categoria":C,"evento-interactivo-accion":t??this.tipoDeAtencion,"evento-interactivo-etiqueta":e??this.modalidad})}catch{console.log("event push failed")}}eventHandler(){this.removeAttribute("hidden");let C=this.shadowRoot.getElementById("backdrop");C.style.display="flex",this.hidden=!1,this.focused=!0,this.requestUpdate()}firstUpdated(){if(this.handleParameter(),this.onlyView||document.addEventListener("openBookingBox",()=>{this.eventHandler()}),window.innerWidth>1023){const C=this.shadowRoot.querySelector(".booking-box");let t=this.shadowRoot.getElementById("backdrop");C.addEventListener("focusin",()=>{this.focused=!0,t.style.display="flex",this.requestUpdate()})}}handleParameter(){new URLSearchParams(window.location.search).get("rsv")==="true"&&this.eventHandler()}closeHandler(){let C=this.shadowRoot.getElementById("backdrop");C.style.display="none",this.hidden=!1,this.focused=!1,this.requestUpdate()}handleOverrideTime(){this.handleMark({category:"anular_hora"})}render(){const C=a2({"booking-box":!0,hidden:this.hidden,home:this.home,focused:this.focused}),t=a2({backdrop:!0,hidden:this.hidden});return M`
7078
7078
  <div class="${t}" id="backdrop" @click="${this.closeHandler}"></div>
7079
7079
  <div class="booking-box-main-cont" id="booking-box-main-cont">
7080
7080
  <div class="${C}" id="booking-box" tabindex="0">
@@ -7074,7 +7074,7 @@
7074
7074
  border-radius: 8px; /* rounded */
7075
7075
  background-color: rgba(229, 231, 235, 0.5); /* bg-gray-100 */
7076
7076
  }
7077
- `,K5=[{name:"Consulta médica",items:[{name:"Presencial",link:"https://reserva.alemana.cl/reserva/portal/busqueda"},{name:"Teleconsulta",link:"https://agenda.clinicaalemana.cl/paciente"},{name:"TeleUrgencia",link:"https://www.clinicaalemana.cl/telemedicina/teleurgencia"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio"}]},{name:"Exámenes y procedimientos",items:[{name:"Presencial",link:"https://www.clinicaalemana.cl/examenes-y-procedimientos"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio/examenes-laboratorio-domicilio"}]},{name:"Vacunas",items:[{name:"Adulto",link:"https://www.alemana.cl/ReservaDeHoras/resultado-busqueda-area.aspx?idEmp=2&horario=todas&su=-1&idioma=todas&valorArea=Vacunas+Adulto&Am=229,0&Ai=-1&CentrosSalud=-1&centroNombre=&CenAm=-1&CenAi=-1&d=20-12-2023&idAgenda=undefined&fp=20-12-2023&rp=&ipac=0&idreserva=&buscar-nombre=&dispositivo=2&cal=1&linkPortal="},{name:"Covid-19",link:"https://www.clinicaalemana.cl/covid-19"},{name:"Influenza",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/influenza-2023"},{name:"Viajeros",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/reserva-vacuna-fiebre-amarilla"},{name:"TeleAsesoría pediátrica",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/asesoria-en-vacunacion-pediatrica"}]}];class x3 extends V{constructor(){super(),this.hidden=!1,this.tipoDeAtencion="",this.modalidad="",this.dataTipoDeAtencion=[],this.dataModalidad=[],this.focused=!1,this.refresh=!1,this.link=""}changeHandler(C){const t=C.target.name;if(this[t]=C.composedPath()[0].value,this.handleErrorTipoDeAtencion(!1),this.handleErrorModalidad(!1),t==="tipoDeAtencion"){this.modalidad="",this.refresh=!0,this.handleFocusModalidad(!0),this.handleFocusTipoDeAtencion(!1);const e=K5.find(i=>i.name===this.tipoDeAtencion).items.map(i=>i.name);this.dataModalidad=[...e],this.requestUpdate(),setTimeout(()=>{this.refresh=!1,this.requestUpdate()},100)}t==="modalidad"&&this.handleFocusModalidad(!1),this.handleLink()}handleFocusTipoDeAtencion(C){const t=this.shadowRoot.getElementById("tipoDeAtencion");t==null||t.setAttribute("active",C)}handleFocusModalidad(C){const t=this.shadowRoot.getElementById("modalidad");t==null||t.setAttribute("active",C)}handleErrorTipoDeAtencion(C){const t=this.shadowRoot.getElementById("tipoDeAtencion");C?t==null||t.setAttribute("isSelectError",!0):t==null||t.removeAttribute("isSelectError")}handleErrorModalidad(C){const t=this.shadowRoot.getElementById("modalidad");C?t==null||t.setAttribute("isSelectError",!0):t==null||t.removeAttribute("isSelectError")}handleLink(){let C="";this.tipoDeAtencion!==""&&this.modalidad!==""&&(C=K5.find(e=>e.name===this.tipoDeAtencion).items.find(e=>e.name===this.modalidad).link),this.link=C;const t=this.shadowRoot.querySelector(".btn-action");this.link!==""?t.setAttribute("href",this.link):t.removeAttribute("href")}submit(){this.link!==""?this.handleMark({category:"reservar_hora"}):this.tipoDeAtencion===""?(this.handleErrorTipoDeAtencion(!0),this.handleErrorModalidad(!0)):(this.handleFocusModalidad(!1),this.handleErrorModalidad(!0))}handleMark({category:C,action:t,label:e}){try{window.dataLayer.push({event:"evento-interactivo","evento-interactivo-categoria":C,"evento-interactivo-accion":t??this.tipoDeAtencion,"evento-interactivo-etiqueta":e??this.modalidad})}catch{console.log("event push failed")}}eventHandler(){this.removeAttribute("hidden");let C=this.shadowRoot.getElementById("backdrop");C.style.display="flex",this.hidden=!1,this.focused=!0,this.requestUpdate()}firstUpdated(){if(this.handleParameter(),this.onlyView||document.addEventListener("openBookingBox",()=>{this.eventHandler()}),window.innerWidth>1023){const C=this.shadowRoot.querySelector(".booking-box");let t=this.shadowRoot.getElementById("backdrop");C.addEventListener("focusin",()=>{this.focused=!0,t.style.display="flex",this.requestUpdate()})}}handleParameter(){new URLSearchParams(window.location.search).get("rsv")==="true"&&this.eventHandler()}closeHandler(){let C=this.shadowRoot.getElementById("backdrop");C.style.display="none",this.hidden=!1,this.focused=!1,this.requestUpdate()}handleOverrideTime(){this.handleMark({category:"anular_hora"})}render(){const C=k2({"booking-box":!0,hidden:this.hidden,home:this.home,focused:this.focused}),t=k2({backdrop:!0,hidden:this.hidden});return u`
7077
+ `,K5=[{name:"Consulta médica",items:[{name:"Presencial",link:"https://reserva.alemana.cl/reserva/portal/busqueda"},{name:"Teleconsulta",link:"https://agenda.clinicaalemana.cl/paciente"},{name:"TeleUrgencia",link:"https://www.clinicaalemana.cl/telemedicina/teleurgencia"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio"},{name:"Teledermatología",link:"https://teledermatologia.clinicaalemana.cl/"}]},{name:"Exámenes y procedimientos",items:[{name:"Presencial",link:"https://www.clinicaalemana.cl/examenes-y-procedimientos"},{name:"A domicilio",link:"https://www.clinicaalemana.cl/servicios-clinicos/servicios-a-domicilio/examenes-laboratorio-domicilio"}]},{name:"Vacunas",items:[{name:"Adulto",link:"https://www.alemana.cl/ReservaDeHoras/resultado-busqueda-area.aspx?idEmp=2&horario=todas&su=-1&idioma=todas&valorArea=Vacunas+Adulto&Am=229,0&Ai=-1&CentrosSalud=-1&centroNombre=&CenAm=-1&CenAi=-1&d=20-12-2023&idAgenda=undefined&fp=20-12-2023&rp=&ipac=0&idreserva=&buscar-nombre=&dispositivo=2&cal=1&linkPortal="},{name:"Covid-19",link:"https://www.clinicaalemana.cl/covid-19"},{name:"Influenza",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/influenza-2023"},{name:"Viajeros",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/reserva-vacuna-fiebre-amarilla"},{name:"TeleAsesoría pediátrica",link:"https://www.clinicaalemana.cl/especialidades/vacunatorio/asesoria-en-vacunacion-pediatrica"}]}];class x3 extends V{constructor(){super(),this.hidden=!1,this.tipoDeAtencion="",this.modalidad="",this.dataTipoDeAtencion=[],this.dataModalidad=[],this.focused=!1,this.refresh=!1,this.link=""}changeHandler(C){const t=C.target.name;if(this[t]=C.composedPath()[0].value,this.handleErrorTipoDeAtencion(!1),this.handleErrorModalidad(!1),t==="tipoDeAtencion"){this.modalidad="",this.refresh=!0,this.handleFocusModalidad(!0),this.handleFocusTipoDeAtencion(!1);const e=K5.find(i=>i.name===this.tipoDeAtencion).items.map(i=>i.name);this.dataModalidad=[...e],this.requestUpdate(),setTimeout(()=>{this.refresh=!1,this.requestUpdate()},100)}t==="modalidad"&&this.handleFocusModalidad(!1),this.handleLink()}handleFocusTipoDeAtencion(C){const t=this.shadowRoot.getElementById("tipoDeAtencion");t==null||t.setAttribute("active",C)}handleFocusModalidad(C){const t=this.shadowRoot.getElementById("modalidad");t==null||t.setAttribute("active",C)}handleErrorTipoDeAtencion(C){const t=this.shadowRoot.getElementById("tipoDeAtencion");C?t==null||t.setAttribute("isSelectError",!0):t==null||t.removeAttribute("isSelectError")}handleErrorModalidad(C){const t=this.shadowRoot.getElementById("modalidad");C?t==null||t.setAttribute("isSelectError",!0):t==null||t.removeAttribute("isSelectError")}handleLink(){let C="";this.tipoDeAtencion!==""&&this.modalidad!==""&&(C=K5.find(e=>e.name===this.tipoDeAtencion).items.find(e=>e.name===this.modalidad).link),this.link=C;const t=this.shadowRoot.querySelector(".btn-action");this.link!==""?t.setAttribute("href",this.link):t.removeAttribute("href")}submit(){this.link!==""?this.handleMark({category:"reservar_hora"}):this.tipoDeAtencion===""?(this.handleErrorTipoDeAtencion(!0),this.handleErrorModalidad(!0)):(this.handleFocusModalidad(!1),this.handleErrorModalidad(!0))}handleMark({category:C,action:t,label:e}){try{window.dataLayer.push({event:"evento-interactivo","evento-interactivo-categoria":C,"evento-interactivo-accion":t??this.tipoDeAtencion,"evento-interactivo-etiqueta":e??this.modalidad})}catch{console.log("event push failed")}}eventHandler(){this.removeAttribute("hidden");let C=this.shadowRoot.getElementById("backdrop");C.style.display="flex",this.hidden=!1,this.focused=!0,this.requestUpdate()}firstUpdated(){if(this.handleParameter(),this.onlyView||document.addEventListener("openBookingBox",()=>{this.eventHandler()}),window.innerWidth>1023){const C=this.shadowRoot.querySelector(".booking-box");let t=this.shadowRoot.getElementById("backdrop");C.addEventListener("focusin",()=>{this.focused=!0,t.style.display="flex",this.requestUpdate()})}}handleParameter(){new URLSearchParams(window.location.search).get("rsv")==="true"&&this.eventHandler()}closeHandler(){let C=this.shadowRoot.getElementById("backdrop");C.style.display="none",this.hidden=!1,this.focused=!1,this.requestUpdate()}handleOverrideTime(){this.handleMark({category:"anular_hora"})}render(){const C=k2({"booking-box":!0,hidden:this.hidden,home:this.home,focused:this.focused}),t=k2({backdrop:!0,hidden:this.hidden});return u`
7078
7078
  <div class="${t}" id="backdrop" @click="${this.closeHandler}"></div>
7079
7079
  <div class="booking-box-main-cont" id="booking-box-main-cont">
7080
7080
  <div class="${C}" id="booking-box" tabindex="0">
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "cas-ds-web-components",
3
3
  "description": "Web Components based on CAS DS",
4
- "version": "1.2.87",
4
+ "version": "1.2.88",
5
5
  "author": "aconejeros",
6
6
  "keywords": [
7
7
  "direflow",