!function(){"use strict";const t={attributes:!0,attributeFilter:["class"],childList:!1,characterData:!1};function e(t,e,n){this.classList.contains("hydrated")&&(n.disconnect(),t(this))}function n(t){var e;let n=null===(e=null==t?void 0:t.detail)||void 0===e?void 0:e.target;n||(n=t.target.querySelector("input,select")),function(t,e){const n=function(t){let e;for(e in t.validity)if(t.validity[e])return"valid"===e?void 0:e}(e);if(n){const i=function(t,e,n){let i;(function(t){const e=t._originalInvalidMessage;void 0===e&&(t._originalInvalidMessage=t.getAttribute("invalid-message"))})(e),"customError"===t&&(i=t+n.validationMessage.charAt(0).toUpperCase()+n.validationMessage.substring(1));const r=i&&e.dataset[i]||e.dataset[t]||e._originalInvalidMessage;"string"!=typeof r&&console.warn(`No error message found for "${t}" constraint for "${e.getAttribute("name")}" field.`);return r||""}(n,t,e);t.setAttribute("invalid-message",i)}}(t.target,n)}const i=150;function r(){!function(n){const i=document.querySelector("prism-layout");i?(r=i,o=n,new MutationObserver(e.bind(r,o)).observe(r,t)):n();var r,o}((()=>{document.querySelectorAll("main form").forEach((t=>{t.addEventListener("submit",o),t.addEventListener("prismPress",c),t.addEventListener("prismClick",c)}))}))}function o(t){var e;const n=(null!==(e=t.target.submitListeners)&&void 0!==e?e:[]).sort(a),r=n.findIndex((t=>{var e;return(null!==(e=t.order)&&void 0!==e?e:0)>=0})),o=-1===r?0:r,c=n.slice(0,o),l=n.slice(o);c.forEach(s(t)),function(t){const e=t.target;!t.defaultPrevented&&(e.isSubmitting||function(t){var e;return!(null===(e=t.submitter)||void 0===e?void 0:e.hasAttribute("formnovalidate"))}(t)&&!e.checkValidity())&&t.preventDefault()}(t),l.forEach(s(t)),function(t){if(!t.defaultPrevented){t.target.isSubmitting=!0,function(t){var e;const n=null===(e=t.submitter)||void 0===e?void 0:e.closest("prism-button");if(n&&"link"!==n.getAttribute("display"))return n.setAttribute("loading","true"),!0;return!1}(t)&&function(t){const e=t.target;t.preventDefault(),setTimeout((()=>{u(e,t.submitter),e.submit()}),i)}(t)}}(t)}function a(t,e){return void 0===t.order?void 0===e.order?0:1:void 0===e.order?-1:t.order-e.order}function s(t){return e=>e.listener(t)}function u(t,e){const n=document.createElement("input");n.type="hidden",n.name=e.name,n.value=e.value,t.appendChild(n)}function c(t){const e=t.target.closest("form"),n=t.detail.target;var i;e&&!e.isSubmitting&&n instanceof HTMLButtonElement&&("_eventId"===(i=n).name&&"button"===i.type)&&(e.isSubmitting=!0,u(e,n),e.submit())}const l=["prism-input-text","prism-select","prism-checkbox"];function d(t){const e=t.target;e&&l.includes(e.nodeName.toLowerCase())&&n(t)}function m(t){const e=t.getAttribute("custom-validity");e&&(t.customValidity=JSON.parse(e))}function f(t){(function(t){var e;const{name:n,value:i}=function(t){const e={name:"",value:""},n=t.value.indexOf("=");-1===n?e.name=t.value:(e.name=t.value.substring(0,n),e.value=t.value.substring(n+1));return e}(t),r=document.createElement("button");return r.type="submit",r.hidden=!0,r.formNoValidate=t.formNoValidate,r.name=n,r.value=i,null===(e=t.parentElement)||void 0===e||e.insertBefore(r,t),r})(t.detail.target).click()}function v(t){t.target.setAttribute("loading","true")}function g(t){const e=t.getAttribute("attr");e&&(t.attr=JSON.parse(e))}function p(t){const e=t.target.dataset.idRef,n=document.getElementById(e);null==n||n.setAttribute("open","true")}r(),document.addEventListener("prismInvalid",d),document.addEventListener("prismChange",d),document.querySelectorAll("prism-input-otp").forEach(m),document.querySelectorAll("prism-button[name=_submit]:not([type=submit],[type=reset])").forEach((t=>{t.addEventListener("prismPress",f)})),document.querySelectorAll("prism-input-text[data-trim-on-blur]").forEach((t=>{t.addEventListener("prismChange",(t=>{const e=t.target;e.value=e.value.trim()}))})),document.querySelectorAll("prism-button[data-loader]").forEach((t=>{t.addEventListener("prismPress",v)})),document.querySelectorAll("prism-lineitem").forEach(g),document.querySelectorAll("button[data-id-ref],prism-button[data-id-ref]").forEach((t=>{"prism-button"==t.localName?t.addEventListener("prismPress",p):t.addEventListener("click",p)})),async function(){const t=document.querySelector("form[name=signin]");if(t){const e=function(t){const e=document.createElement("input");return e.type="hidden",e.name="userVerifyingPlatformAuthenticatorAvailable",e.value=t.toString(),e}(await async function(){return!!window.PublicKeyCredential&&await window.PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable()}());t.appendChild(e)}}()}();
//# sourceMappingURL=bundle.js.map
