import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';

const swBadgeErrorCss = ":host{position:absolute;display:inline-block;bottom:3rem;}.badge-container{width:auto;height:auto;background-color:#F9CECD;color:#981512;font-size:14px;font-family:Karla, serif;min-width:300px;min-height:15px;align-items:center;border-radius:10px;padding:10px}";

const SwBadgeError = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
  constructor() {
    super();
    this.__registerHost();
    this.__attachShadow();
  }
  render() {
    if (this.typeError === undefined) {
      return (h("div", { class: "badge-container" }, "Attenzione! Compila tutti i campi obbligatori."));
    }
    if (this.typeError === 500) {
      return h("div", { class: "badge-container" }, "Attenzione! Errore server.");
    }
  }
  static get style() { return swBadgeErrorCss; }
}, [1, "sw-badge-error"]);
function defineCustomElement() {
  if (typeof customElements === "undefined") {
    return;
  }
  const components = ["sw-badge-error"];
  components.forEach(tagName => { switch (tagName) {
    case "sw-badge-error":
      if (!customElements.get(tagName)) {
        customElements.define(tagName, SwBadgeError);
      }
      break;
  } });
}
defineCustomElement();

export { SwBadgeError as S, defineCustomElement as d };
