"use strict";(self.webpackChunkporta_frontend_starter_kit=self.webpackChunkporta_frontend_starter_kit||[]).push([[717],{717:function(t,e,n){n.r(e),n.d(e,{initTogglers:function(){return i}});const i=()=>{const t=document.querySelectorAll(".sh-trig");for(const e of t)s(e,{slide:!0});const e=document.querySelectorAll(".show-more");for(const t of e)s(t,{hideTrigger:!0})},s=(t,e)=>{const n=Object.assign({hideTrigger:!1,slide:!1,scrollToContent:!1},e),i=document.querySelector("#"+t.getAttribute("data-content")),s=t.getAttribute("data-less"),o=t.getAttribute("data-more"),r=t.type&&"checkbox"===t.type,c=r?"change":"click";t.addEventListener(c,(e=>{e.preventDefault();let c=!1;return c=r?!0===t.checked:!i.classList.contains("sh-content--active"),t.classList.contains("sh-trig--active")?t.setAttribute("aria-expanded","true"):t.setAttribute("aria-expanded","false"),c?(i.animIn(),n.scrollToContent&&function(t){t.scrollIntoView()}(i),t.classList.add("sh-trig--active"),t.setAttribute("aria-expanded","true"),s&&(t.innerHtml=s),n.hideTrigger&&t.hide()):(i.animOut(),n.scrollToContent&&function(t){t.scrollIntoView()}(t),t.classList.remove("sh-trig--active"),t.setAttribute("aria-expanded","false"),o&&(t.innerHtml=o),n.hideTrigger&&t.show(n.hideSpeed)),!1})),r&&t.dispatchEvent(new Event("change"))};HTMLElement.prototype.hide=function(){this.style.display="none"},HTMLElement.prototype.show=function(){this.style.display=""},HTMLElement.prototype.animIn=function(){this.classList.add("sh-content--active")},HTMLElement.prototype.animOut=function(){this.classList.remove("sh-content--active")}}}]);