var P = (e, t, n) => new Promise((s, r) => {
  var i = (a) => {
    try {
      $(n.next(a));
    } catch (o) {
      r(o);
    }
  }, l = (a) => {
    try {
      $(n.throw(a));
    } catch (o) {
      r(o);
    }
  }, $ = (a) => a.done ? s(a.value) : Promise.resolve(a.value).then(i, l);
  $((n = n.apply(e, t)).next());
});
const ue = "ui-image", de = (
  /* ui-image */
  { hydratedSelectorName: "hydrated" }
);
var ve = Object.defineProperty, ge = (e, t) => {
  for (var n in t)
    ve(e, n, { get: t[n], enumerable: !0 });
}, z = /* @__PURE__ */ new WeakMap(), E = (e) => z.get(e), tt = (e, t) => z.set(t.$lazyInstance$ = e, t), pe = (e, t) => {
  const n = {
    $flags$: 0,
    $hostElement$: e,
    $cmpMeta$: t,
    $instanceValues$: /* @__PURE__ */ new Map()
  };
  return n.$onReadyPromise$ = new Promise((s) => n.$onReadyResolve$ = s), e["s-p"] = [], e["s-rc"] = [], z.set(e, n);
}, D = (e, t) => t in e, k = (e, t) => (0, console.error)(e, t), w = /* @__PURE__ */ new Map(), he = (e, t, n) => {
  const s = e.$tagName$.replace(/-/g, "_"), r = e.$lazyBundleId$;
  if (!r)
    return;
  const i = w.get(r);
  if (i)
    return i[s];
  {
    const l = ($) => (w.set(r, $), $[s]);
    switch (r) {
      case "ui-image_2":
        return import(
          /* webpackMode: "lazy" */
          "./ui-image_2-qO3reSlr.js"
        ).then(l, k);
    }
  }
  return import(
    /* @vite-ignore */
    /* webpackInclude: /\.entry\.js$/ */
    /* webpackExclude: /\.system\.entry\.js$/ */
    /* webpackMode: "lazy" */
    `./${r}.entry.js`
  ).then((l) => (w.set(r, l), l[s]), k);
}, A = /* @__PURE__ */ new Map(), ye = "{visibility:hidden}.hydrated{visibility:inherit}", Q = "slot-fb{display:contents}slot-fb[hidden]{display:none}", j = typeof window != "undefined" ? window : {}, m = j.document || { head: {} }, p = {
  $flags$: 0,
  $resourcesUrl$: "",
  jmp: (e) => e(),
  raf: (e) => requestAnimationFrame(e),
  ael: (e, t, n, s) => e.addEventListener(t, n, s),
  rel: (e, t, n, s) => e.removeEventListener(t, n, s),
  ce: (e, t) => new CustomEvent(e, t)
}, me = (e) => Promise.resolve(e), Se = /* @__PURE__ */ (() => {
  try {
    return new CSSStyleSheet(), typeof new CSSStyleSheet().replaceSync == "function";
  } catch (e) {
  }
  return !1;
})(), I = !1, W = [], Z = [], Ee = (e, t) => (n) => {
  e.push(n), I || (I = !0, p.$flags$ & 4 ? C(U) : p.raf(U));
}, M = (e) => {
  for (let t = 0; t < e.length; t++)
    try {
      e[t](performance.now());
    } catch (n) {
      k(n);
    }
  e.length = 0;
}, U = () => {
  M(W), M(Z), (I = W.length > 0) && p.raf(U);
}, C = (e) => me().then(e), ke = /* @__PURE__ */ Ee(Z), G = {}, q = (e) => (e = typeof e, e === "object" || e === "function");
function R(e) {
  var t, n, s;
  return (s = (n = (t = e.head) == null ? void 0 : t.querySelector('meta[name="csp-nonce"]')) == null ? void 0 : n.getAttribute("content")) != null ? s : void 0;
}
var be = {};
ge(be, {
  err: () => N,
  map: () => xe,
  ok: () => H,
  unwrap: () => Pe,
  unwrapErr: () => Te
});
var H = (e) => ({
  isOk: !0,
  isErr: !1,
  value: e
}), N = (e) => ({
  isOk: !1,
  isErr: !0,
  value: e
});
function xe(e, t) {
  if (e.isOk) {
    const n = t(e.value);
    return n instanceof Promise ? n.then((s) => H(s)) : H(n);
  }
  if (e.isErr) {
    const n = e.value;
    return N(n);
  }
  throw "should never get here";
}
var Pe = (e) => {
  if (e.isOk)
    return e.value;
  throw e.value;
}, Te = (e) => {
  if (e.isErr)
    return e.value;
  throw e.value;
}, S = (e, t = "") => () => {
}, _e = (e, t) => () => {
}, Ae = (e, t, ...n) => {
  let s = null, r = null, i = !1, l = !1;
  const $ = [], a = (c) => {
    for (let f = 0; f < c.length; f++)
      s = c[f], Array.isArray(s) ? a(s) : s != null && typeof s != "boolean" && ((i = typeof e != "function" && !q(s)) && (s = String(s)), i && l ? $[$.length - 1].$text$ += s : $.push(i ? B(null, s) : s), l = i);
  };
  if (a(n), t) {
    t.key && (r = t.key);
    {
      const c = t.className || t.class;
      c && (t.class = typeof c != "object" ? c : Object.keys(c).filter((f) => c[f]).join(" "));
    }
  }
  const o = B(e, null);
  return o.$attrs$ = t, $.length > 0 && (o.$children$ = $), o.$key$ = r, o;
}, B = (e, t) => {
  const n = {
    $flags$: 0,
    $tag$: e,
    $text$: t,
    $elm$: null,
    $children$: null
  };
  return n.$attrs$ = null, n.$key$ = null, n;
}, Le = {}, je = (e) => e && e.$tag$ === Le, Oe = (e, t) => e != null && !q(e) ? t & 4 ? e === "false" ? !1 : e === "" || !!e : t & 2 ? parseFloat(e) : t & 1 ? String(e) : e : e, st = (e) => E(e).$hostElement$, we = (e, t, n) => {
  const s = p.ce(t, n);
  return e.dispatchEvent(s), s;
}, X = /* @__PURE__ */ new WeakMap(), Ie = (e, t, n) => {
  let s = A.get(e);
  Se && n ? (s = s || new CSSStyleSheet(), typeof s == "string" ? s = t : s.replaceSync(t)) : s = t, A.set(e, s);
}, Ue = (e, t, n) => {
  var s;
  const r = V(t), i = A.get(r);
  if (e = e.nodeType === 11 ? e : m, i)
    if (typeof i == "string") {
      e = e.head || e;
      let l = X.get(e), $;
      if (l || X.set(e, l = /* @__PURE__ */ new Set()), !l.has(r)) {
        {
          $ = m.createElement("style"), $.innerHTML = i;
          const a = (s = p.$nonce$) != null ? s : R(m);
          a != null && $.setAttribute("nonce", a), e.insertBefore($, e.querySelector("link"));
        }
        t.$flags$ & 4 && ($.innerHTML += Q), l && l.add(r);
      }
    } else
      e.adoptedStyleSheets.includes(i) || (e.adoptedStyleSheets = [...e.adoptedStyleSheets, i]);
  return r;
}, He = (e) => {
  const t = e.$cmpMeta$, n = e.$hostElement$, s = S("attachStyles", t.$tagName$);
  Ue(
    n.getRootNode(),
    t
  ), s();
}, V = (e, t) => "sc-" + e.$tagName$, Y = (e, t, n, s, r, i) => {
  if (n !== s) {
    let l = D(e, t), $ = t.toLowerCase();
    if (t === "class") {
      const a = e.classList, o = J(n), c = J(s);
      a.remove(...o.filter((f) => f && !c.includes(f))), a.add(...c.filter((f) => f && !o.includes(f)));
    } else if (t === "style") {
      for (const a in n)
        (!s || s[a] == null) && (a.includes("-") ? e.style.removeProperty(a) : e.style[a] = "");
      for (const a in s)
        (!n || s[a] !== n[a]) && (a.includes("-") ? e.style.setProperty(a, s[a]) : e.style[a] = s[a]);
    } else if (t !== "key")
      if (t === "ref")
        s && s(e);
      else if (!l && t[0] === "o" && t[1] === "n") {
        if (t[2] === "-" ? t = t.slice(3) : D(j, $) ? t = $.slice(2) : t = $[2] + t.slice(3), n || s) {
          const a = t.endsWith(ee);
          t = t.replace(ze, ""), n && p.rel(e, t, n, a), s && p.ael(e, t, s, a);
        }
      } else {
        const a = q(s);
        if ((l || a && s !== null) && !r)
          try {
            if (e.tagName.includes("-"))
              e[t] = s;
            else {
              const o = s == null ? "" : s;
              t === "list" ? l = !1 : (n == null || e[t] != o) && (e[t] = o);
            }
          } catch (o) {
          }
        s == null || s === !1 ? (s !== !1 || e.getAttribute(t) === "") && e.removeAttribute(t) : (!l || i & 4 || r) && !a && (s = s === !0 ? "" : s, e.setAttribute(t, s));
      }
  }
}, Be = /\s/, J = (e) => e ? e.split(Be) : [], ee = "Capture", ze = new RegExp(ee + "$"), te = (e, t, n) => {
  const s = t.$elm$.nodeType === 11 && t.$elm$.host ? t.$elm$.host : t.$elm$, r = e && e.$attrs$ || G, i = t.$attrs$ || G;
  for (const l of K(Object.keys(r)))
    l in i || Y(s, l, r[l], void 0, n, t.$flags$);
  for (const l of K(Object.keys(i)))
    Y(s, l, r[l], i[l], n, t.$flags$);
};
function K(e) {
  return e.includes("ref") ? (
    // we need to sort these to ensure that `'ref'` is the last attr
    [...e.filter((t) => t !== "ref"), "ref"]
  ) : (
    // no need to sort, return the original array
    e
  );
}
var se, ne = !1, L = (e, t, n, s) => {
  const r = t.$children$[n];
  let i = 0, l, $;
  if (r.$text$ !== null)
    l = r.$elm$ = m.createTextNode(r.$text$);
  else if (l = r.$elm$ = m.createElement(
    r.$tag$
  ), te(null, r, ne), r.$children$)
    for (i = 0; i < r.$children$.length; ++i)
      $ = L(e, r, i), $ && l.appendChild($);
  return l["s-hn"] = se, l;
}, re = (e, t, n, s, r, i) => {
  let l = e, $;
  for (; r <= i; ++r)
    s[r] && ($ = L(null, n, r), $ && (s[r].$elm$ = $, _(l, $, t)));
}, le = (e, t, n) => {
  for (let s = t; s <= n; ++s) {
    const r = e[s];
    if (r) {
      const i = r.$elm$;
      ae(r), i && i.remove();
    }
  }
}, Ce = (e, t, n, s, r = !1) => {
  let i = 0, l = 0, $ = 0, a = 0, o = t.length - 1, c = t[0], f = t[o], u = s.length - 1, d = s[0], v = s[u], g, h;
  for (; i <= o && l <= u; )
    if (c == null)
      c = t[++i];
    else if (f == null)
      f = t[--o];
    else if (d == null)
      d = s[++l];
    else if (v == null)
      v = s[--u];
    else if (T(c, d, r))
      b(c, d, r), c = t[++i], d = s[++l];
    else if (T(f, v, r))
      b(f, v, r), f = t[--o], v = s[--u];
    else if (T(c, v, r))
      b(c, v, r), _(e, c.$elm$, f.$elm$.nextSibling), c = t[++i], v = s[--u];
    else if (T(f, d, r))
      b(f, d, r), _(e, f.$elm$, c.$elm$), f = t[--o], d = s[++l];
    else {
      for ($ = -1, a = i; a <= o; ++a)
        if (t[a] && t[a].$key$ !== null && t[a].$key$ === d.$key$) {
          $ = a;
          break;
        }
      $ >= 0 ? (h = t[$], h.$tag$ !== d.$tag$ ? g = L(t && t[l], n, $) : (b(h, d, r), t[$] = void 0, g = h.$elm$), d = s[++l]) : (g = L(t && t[l], n, l), d = s[++l]), g && _(c.$elm$.parentNode, g, c.$elm$);
    }
  i > o ? re(
    e,
    s[u + 1] == null ? null : s[u + 1].$elm$,
    n,
    s,
    l,
    u
  ) : l > u && le(t, i, o);
}, T = (e, t, n = !1) => e.$tag$ === t.$tag$ ? n ? !0 : e.$key$ === t.$key$ : !1, b = (e, t, n = !1) => {
  const s = t.$elm$ = e.$elm$, r = e.$children$, i = t.$children$, l = t.$text$;
  l === null ? (te(e, t, ne), r !== null && i !== null ? Ce(s, r, t, i, n) : i !== null ? (e.$text$ !== null && (s.textContent = ""), re(s, null, t, i, 0, i.length - 1)) : r !== null && le(r, 0, r.length - 1)) : e.$text$ !== l && (s.data = l);
}, ae = (e) => {
  e.$attrs$ && e.$attrs$.ref && e.$attrs$.ref(null), e.$children$ && e.$children$.map(ae);
}, _ = (e, t, n) => e == null ? void 0 : e.insertBefore(t, n), qe = (e, t, n = !1) => {
  const s = e.$hostElement$, r = e.$vnode$ || B(null, null), i = je(t) ? t : Ae(null, null, t);
  if (se = s.tagName, n && i.$attrs$)
    for (const l of Object.keys(i.$attrs$))
      s.hasAttribute(l) && !["key", "ref", "style", "class"].includes(l) && (i.$attrs$[l] = s[l]);
  i.$tag$ = null, i.$flags$ |= 4, e.$vnode$ = i, i.$elm$ = r.$elm$ = s, b(r, i, n);
}, ie = (e, t) => {
  t && !e.$onRenderResolve$ && t["s-p"] && t["s-p"].push(new Promise((n) => e.$onRenderResolve$ = n));
}, F = (e, t) => {
  if (e.$flags$ |= 16, e.$flags$ & 4) {
    e.$flags$ |= 512;
    return;
  }
  return ie(e, e.$ancestorComponent$), ke(() => Fe(e, t));
}, Fe = (e, t) => {
  const n = e.$hostElement$, s = S("scheduleUpdate", e.$cmpMeta$.$tagName$), r = e.$lazyInstance$;
  if (!r)
    throw new Error(
      `Can't render component <${n.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`
    );
  let i;
  return s(), De(i, () => Me(e, r, t));
}, De = (e, t) => We(e) ? e.then(t).catch((n) => {
  console.error(n), t();
}) : t(), We = (e) => e instanceof Promise || e && e.then && typeof e.then == "function", Me = (e, t, n) => P(void 0, null, function* () {
  var s;
  const r = e.$hostElement$, i = S("update", e.$cmpMeta$.$tagName$), l = r["s-rc"];
  n && He(e);
  const $ = S("render", e.$cmpMeta$.$tagName$);
  Ge(e, t, r, n), l && (l.map((a) => a()), r["s-rc"] = void 0), $(), i();
  {
    const a = (s = r["s-p"]) != null ? s : [], o = () => Xe(e);
    a.length === 0 ? o() : (Promise.all(a).then(o), e.$flags$ |= 4, a.length = 0);
  }
}), Ge = (e, t, n, s) => {
  try {
    t = t.render(), e.$flags$ &= -17, e.$flags$ |= 2, qe(e, t, s);
  } catch (r) {
    k(r, e.$hostElement$);
  }
  return null;
}, Xe = (e) => {
  const t = e.$cmpMeta$.$tagName$, n = e.$hostElement$, s = S("postUpdate", t), r = e.$lazyInstance$, i = e.$ancestorComponent$;
  e.$flags$ & 64 ? s() : (e.$flags$ |= 64, oe(n), Ye(r, "componentDidLoad"), s(), e.$onReadyResolve$(n), i || $e()), e.$onRenderResolve$ && (e.$onRenderResolve$(), e.$onRenderResolve$ = void 0), e.$flags$ & 512 && C(() => F(e, !1)), e.$flags$ &= -517;
}, $e = (e) => {
  oe(m.documentElement), C(() => we(j, "appload", { detail: { namespace: ue } }));
}, Ye = (e, t, n) => {
  if (e && e[t])
    try {
      return e[t](n);
    } catch (s) {
      k(s);
    }
}, oe = (e) => {
  var t;
  return e.classList.add((t = de.hydratedSelectorName) != null ? t : "hydrated");
}, Je = (e, t) => E(e).$instanceValues$.get(t), Ke = (e, t, n, s) => {
  const r = E(e);
  if (!r)
    throw new Error(
      `Couldn't find host element for "${s.$tagName$}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/ionic-team/stencil/issues/5457).`
    );
  const i = r.$hostElement$, l = r.$instanceValues$.get(t), $ = r.$flags$, a = r.$lazyInstance$;
  n = Oe(n, s.$members$[t][0]);
  const o = Number.isNaN(l) && Number.isNaN(n), c = n !== l && !o;
  if ((!($ & 8) || l === void 0) && c && (r.$instanceValues$.set(t, n), a)) {
    if (s.$watchers$ && $ & 128) {
      const f = s.$watchers$[t];
      f && f.map((u) => {
        try {
          a[u](n, l, t);
        } catch (d) {
          k(d, i);
        }
      });
    }
    ($ & 18) === 2 && F(r, !1);
  }
}, ce = (e, t, n) => {
  var s, r;
  const i = e.prototype;
  if (t.$members$ || t.$watchers$ || e.watchers) {
    e.watchers && !t.$watchers$ && (t.$watchers$ = e.watchers);
    const l = Object.entries((s = t.$members$) != null ? s : {});
    if (l.map(([$, [a]]) => {
      (a & 31 || n & 2 && a & 32) && Object.defineProperty(i, $, {
        get() {
          return Je(this, $);
        },
        set(o) {
          Ke(this, $, o, t);
        },
        configurable: !0,
        enumerable: !0
      });
    }), n & 1) {
      const $ = /* @__PURE__ */ new Map();
      i.attributeChangedCallback = function(a, o, c) {
        p.jmp(() => {
          var f;
          const u = $.get(a);
          if (this.hasOwnProperty(u))
            c = this[u], delete this[u];
          else {
            if (i.hasOwnProperty(u) && typeof this[u] == "number" && this[u] == c)
              return;
            if (u == null) {
              const d = E(this), v = d == null ? void 0 : d.$flags$;
              if (v && !(v & 8) && v & 128 && c !== o) {
                const g = d.$lazyInstance$, h = (f = t.$watchers$) == null ? void 0 : f[a];
                h == null || h.forEach((y) => {
                  g[y] != null && g[y].call(g, c, o, a);
                });
              }
              return;
            }
          }
          this[u] = c === null && typeof this[u] == "boolean" ? !1 : c;
        });
      }, e.observedAttributes = Array.from(
        /* @__PURE__ */ new Set([
          ...Object.keys((r = t.$watchers$) != null ? r : {}),
          ...l.filter(
            ([a, o]) => o[0] & 15
            /* HasAttribute */
          ).map(([a, o]) => {
            const c = o[1] || a;
            return $.set(c, a), c;
          })
        ])
      );
    }
  }
  return e;
}, Qe = (e, t, n, s) => P(void 0, null, function* () {
  let r;
  if (!(t.$flags$ & 32)) {
    if (t.$flags$ |= 32, n.$lazyBundleId$) {
      const a = he(n);
      if (a && "then" in a) {
        const c = _e();
        r = yield a, c();
      } else
        r = a;
      if (!r)
        throw new Error(`Constructor for "${n.$tagName$}#${t.$modeName$}" was not found`);
      r.isProxied || (n.$watchers$ = r.watchers, ce(
        r,
        n,
        2
        /* proxyState */
      ), r.isProxied = !0);
      const o = S("createInstance", n.$tagName$);
      t.$flags$ |= 8;
      try {
        new r(t);
      } catch (c) {
        k(c);
      }
      t.$flags$ &= -9, t.$flags$ |= 128, o();
    } else {
      r = e.constructor;
      const a = e.localName;
      customElements.whenDefined(a).then(
        () => t.$flags$ |= 128
        /* isWatchReady */
      );
    }
    if (r && r.style) {
      let a;
      typeof r.style == "string" && (a = r.style);
      const o = V(n);
      if (!A.has(o)) {
        const c = S("registerStyles", n.$tagName$);
        Ie(o, a, !!(n.$flags$ & 1)), c();
      }
    }
  }
  const i = t.$ancestorComponent$, l = () => F(t, !0);
  i && i["s-rc"] ? i["s-rc"].push(l) : l();
}), Ze = (e) => {
}, Re = (e) => {
  if (!(p.$flags$ & 1)) {
    const t = E(e), n = t.$cmpMeta$, s = S("connectedCallback", n.$tagName$);
    if (t.$flags$ & 1)
      t != null && t.$lazyInstance$ || t != null && t.$onReadyPromise$ && t.$onReadyPromise$.then(() => Ze());
    else {
      t.$flags$ |= 1;
      {
        let r = e;
        for (; r = r.parentNode || r.host; )
          if (r["s-p"]) {
            ie(t, t.$ancestorComponent$ = r);
            break;
          }
      }
      n.$members$ && Object.entries(n.$members$).map(([r, [i]]) => {
        if (i & 31 && e.hasOwnProperty(r)) {
          const l = e[r];
          delete e[r], e[r] = l;
        }
      }), Qe(e, t, n);
    }
    s();
  }
}, Ne = (e) => {
}, Ve = (e) => P(void 0, null, function* () {
  if (!(p.$flags$ & 1)) {
    const t = E(e);
    t != null && t.$lazyInstance$ || t != null && t.$onReadyPromise$ && t.$onReadyPromise$.then(() => Ne());
  }
}), nt = (e, t = {}) => {
  var n;
  const s = S(), r = [], i = t.exclude || [], l = j.customElements, $ = m.head, a = /* @__PURE__ */ $.querySelector("meta[charset]"), o = /* @__PURE__ */ m.createElement("style"), c = [];
  let f, u = !0;
  Object.assign(p, t), p.$resourcesUrl$ = new URL(t.resourcesUrl || "./", m.baseURI).href;
  let d = !1;
  if (e.map((v) => {
    v[1].map((g) => {
      var h;
      const y = {
        $flags$: g[0],
        $tagName$: g[1],
        $members$: g[2],
        $listeners$: g[3]
      };
      y.$flags$ & 4 && (d = !0), y.$members$ = g[2], y.$watchers$ = (h = g[4]) != null ? h : {};
      const x = y.$tagName$, fe = class extends HTMLElement {
        // StencilLazyHost
        constructor(O) {
          super(O), this.hasRegisteredEventListeners = !1, O = this, pe(O, y);
        }
        connectedCallback() {
          E(this), this.hasRegisteredEventListeners || (this.hasRegisteredEventListeners = !0), f && (clearTimeout(f), f = null), u ? c.push(this) : p.jmp(() => Re(this));
        }
        disconnectedCallback() {
          p.jmp(() => Ve(this));
        }
        componentOnReady() {
          return E(this).$onReadyPromise$;
        }
      };
      y.$lazyBundleId$ = v[0], !i.includes(x) && !l.get(x) && (r.push(x), l.define(
        x,
        ce(
          fe,
          y,
          1
          /* isElementConstructor */
        )
      ));
    });
  }), r.length > 0 && (d && (o.textContent += Q), o.textContent += r.sort() + ye, o.innerHTML.length)) {
    o.setAttribute("data-styles", "");
    const v = (n = p.$nonce$) != null ? n : R(m);
    v != null && o.setAttribute("nonce", v), $.insertBefore(o, a ? a.nextSibling : $.firstChild);
  }
  u = !1, c.length ? c.map((v) => v.connectedCallback()) : p.jmp(() => f = setTimeout($e, 30)), s();
};
export {
  Le as H,
  nt as b,
  st as g,
  Ae as h,
  me as p,
  tt as r
};
