"use strict";(globalThis.webpackChunk_icanbwell_composite=globalThis.webpackChunk_icanbwell_composite||[]).push([[279],{3279:(F,d,n)=>{n.r(d),n.d(d,{DefaultErrorBoundaryFallback:()=>v});function l(r,t,o,e){if(o==="a"&&!e)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?r!==t||!e:!t.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return o==="m"?e:o==="a"?e.call(r):e?e.value:t.get(r)}var u=n(934);const f="Looks like something went wrong when loading this page. Please try refreshing it.",h=r=>f;var c=n(9226);function C(r){var t;let o=h(c.ErrorCode.UNKNOWN),e=c.ErrorCode.UNKNOWN;return r instanceof u.b&&(e=(t=r.errorCode)!==null&&t!==void 0?t:e,o=h()),{message:o,errorCode:e}}var b=n(1677),a,i,g;const m="bwell-error-component";class w extends HTMLElement{static get observedAttributes(){return["message"]}constructor(){super(),a.add(this),this.attachShadow({mode:"open"})}connectedCallback(){var t,o;const{message:e}=C(),s=l(this,a,"m",g).call(this);this.shadowRoot.appendChild(s),l(this,a,"m",i).call(this,"message",this.getAttribute("message")||e),(o=(t=this.shadowRoot)===null||t===void 0?void 0:t.getElementById("refresh"))===null||o===void 0||o.addEventListener("click",()=>{this.resetError()})}attributeChangedCallback(t,o,e){l(this,a,"m",i).call(this,t,e)}resetError(){b.b.reloadView()}}a=new WeakSet,i=function(t,o){var e;const s=(e=this.shadowRoot)===null||e===void 0?void 0:e.getElementById(t);s&&(s.innerHTML=o)},g=function(){var t,o;let e=(o=(t=document.getElementById("bwell-custom-error-template"))===null||t===void 0?void 0:t.content)===null||o===void 0?void 0:o.cloneNode(!0);return e||(e=document.createElement("article"),e.innerHTML=`
    <style>
      :host {
        --background: #FFFFFF;
        --messageTextColor: #6F6F6F;
      }
      article {
        background: var(--background);
        font-family: regular,sans-serif;
        font-size: 16px;
        font-style: normal;
        font-weight: 400;
        letter-spacing: 0px;
        line-height: 20px;
        margin: auto;
        max-width: 340px;
        text-align: center;
      }
      h3 {
        color: #2E3586;
        font-size: 28px;
        font-style: normal;
        font-weight: 400;
        line-height: 34px;
      }
      p {
        color: var(--messageTextColor);
      }
      button {
        background: #2E3586;
        border-radius: 5px;
        height: 55px;
        width: 200px;
        border: none;
        cursor: pointer;
      }
      button>span {
        color: #FFFFFF;
        font-size: 18px;
        font-style: normal;
        font-weight: 700;
        line-height: 22px;
      }
    </style>
    <header>
    <svg width="100" height="100" viewBox="0 0 100 100" fill="none" xmlns="http://www.w3.org/2000/svg">
      <g clip-path="url(#clip0_645_19)">
      <path d="M98.1598 74.7658L62.8319 11.0741C60.1952 6.38657 55.3902 3.51562 50 3.51562C44.6099 3.51562 39.8049 6.38657 37.1681 11.0741L1.84023 74.7658C-0.679762 79.3358 -0.621016 84.7855 2.07445 89.2967C4.71117 93.8087 9.45742 96.5042 14.6721 96.5042H85.3279C90.5426 96.5042 95.2889 93.8087 97.9256 89.2967C100.621 84.7855 100.68 79.3358 98.1598 74.7658Z" fill="#FDBF00"/>
      <path d="M97.9255 89.2967C95.2888 93.8087 90.5433 96.5042 85.3279 96.5042H50V3.51562C55.3902 3.51562 60.1952 6.38657 62.8319 11.0741L98.1598 74.7658C100.68 79.3358 100.621 84.7855 97.9255 89.2967Z" fill="#FF9F00"/>
      <path d="M41.2109 20.3325V64.2778H58.7891V20.3325H41.2109Z" fill="#5A5A5A"/>
      <path d="M50 70.137C45.1363 70.137 41.2109 74.0623 41.2109 78.926C41.2109 83.789 45.1363 87.7151 50 87.7151C54.8637 87.7151 58.7891 83.789 58.7891 78.926C58.7891 74.0623 54.8637 70.137 50 70.137Z" fill="#5A5A5A"/>
      <path d="M58.7891 78.926C58.7891 83.789 54.8637 87.7151 50 87.7151V70.137C54.8637 70.137 58.7891 74.0623 58.7891 78.926Z" fill="#444444"/>
      <path d="M50 20.3323H58.7891V64.2776H50V20.3323Z" fill="#444444"/>
      </g>
      <defs>
      <clipPath id="clip0_645_19">
      <rect width="100" height="100" fill="white"/>
      </clipPath>
      </defs>
      </svg>
    </header>
    <h3>Oops!</h3>
    <p id="message">Looks like something went wrong when loading this page. Please try refreshing it.</p>
    <button id="refresh">
      <span>Refresh</span>
    </button>
    `),e},customElements.get(m)||customElements.define(m,w);var E=n(1085),p=n(4041);const v=({errorDetails:r,resetError:t})=>{const o=(0,p.useRef)();return(0,p.useEffect)(()=>{const e=o.current;e&&(e.resetError=t)},[]),(0,E.jsx)("bwell-error-component",{message:r.message,ref:o})}}}]);

//# sourceMappingURL=279.index.js.map