class Xa {
  constructor() {
    this.eventBuffer = [], this.handledTypes = [], this.copilotMain = null, this.debug = !1, this.eventProxy = {
      functionCallQueue: [],
      dispatchEvent(...t) {
        return this.functionCallQueue.push({ name: "dispatchEvent", args: t }), !0;
      },
      removeEventListener(...t) {
        this.functionCallQueue.push({ name: "removeEventListener", args: t });
      },
      addEventListener(...t) {
        this.functionCallQueue.push({ name: "addEventListener", args: t });
      },
      processQueue(t) {
        this.functionCallQueue.forEach((r) => {
          t[r.name].call(t, ...r.args);
        }), this.functionCallQueue = [];
      }
    };
  }
  getEventTarget() {
    return this.copilotMain ? this.copilotMain : (this.copilotMain = document.querySelector("copilot-main"), this.copilotMain ? (this.eventProxy.processQueue(this.copilotMain), this.copilotMain) : this.eventProxy);
  }
  on(t, r) {
    const n = r;
    return this.getEventTarget().addEventListener(t, n), this.handledTypes.push(t), this.flush(t), () => this.off(t, n);
  }
  once(t, r) {
    this.getEventTarget().addEventListener(t, r, { once: !0 });
  }
  off(t, r) {
    this.getEventTarget().removeEventListener(t, r);
    const n = this.handledTypes.indexOf(t, 0);
    n > -1 && this.handledTypes.splice(n, 1);
  }
  emit(t, r) {
    const n = new CustomEvent(t, { detail: r, cancelable: !0 });
    return this.handledTypes.includes(t) || this.eventBuffer.push(n), this.debug && console.debug("Emit event", n), this.getEventTarget().dispatchEvent(n), n.defaultPrevented;
  }
  emitUnsafe({ type: t, data: r }) {
    return this.emit(t, r);
  }
  // Communication with server via eventbus
  send(t, r) {
    const n = new CustomEvent("copilot-send", { detail: { command: t, data: r } });
    this.getEventTarget().dispatchEvent(n);
  }
  // Listeners for Copilot itself
  onSend(t) {
    this.on("copilot-send", t);
  }
  offSend(t) {
    this.off("copilot-send", t);
  }
  flush(t) {
    const r = [];
    this.eventBuffer.filter((n) => n.type === t).forEach((n) => {
      this.getEventTarget().dispatchEvent(n), r.push(n);
    }), this.eventBuffer = this.eventBuffer.filter((n) => !r.includes(n));
  }
}
var Ja = {
  0: "Invalid value for configuration 'enforceActions', expected 'never', 'always' or 'observed'",
  1: function(t, r) {
    return "Cannot apply '" + t + "' to '" + r.toString() + "': Field not found.";
  },
  /*
  2(prop) {
      return `invalid decorator for '${prop.toString()}'`
  },
  3(prop) {
      return `Cannot decorate '${prop.toString()}': action can only be used on properties with a function value.`
  },
  4(prop) {
      return `Cannot decorate '${prop.toString()}': computed can only be used on getter properties.`
  },
  */
  5: "'keys()' can only be used on observable objects, arrays, sets and maps",
  6: "'values()' can only be used on observable objects, arrays, sets and maps",
  7: "'entries()' can only be used on observable objects, arrays and maps",
  8: "'set()' can only be used on observable objects, arrays and maps",
  9: "'remove()' can only be used on observable objects, arrays and maps",
  10: "'has()' can only be used on observable objects, arrays and maps",
  11: "'get()' can only be used on observable objects, arrays and maps",
  12: "Invalid annotation",
  13: "Dynamic observable objects cannot be frozen. If you're passing observables to 3rd party component/function that calls Object.freeze, pass copy instead: toJS(observable)",
  14: "Intercept handlers should return nothing or a change object",
  15: "Observable arrays cannot be frozen. If you're passing observables to 3rd party component/function that calls Object.freeze, pass copy instead: toJS(observable)",
  16: "Modification exception: the internal structure of an observable array was changed.",
  17: function(t, r) {
    return "[mobx.array] Index out of bounds, " + t + " is larger than " + r;
  },
  18: "mobx.map requires Map polyfill for the current browser. Check babel-polyfill or core-js/es6/map.js",
  19: function(t) {
    return "Cannot initialize from classes that inherit from Map: " + t.constructor.name;
  },
  20: function(t) {
    return "Cannot initialize map from " + t;
  },
  21: function(t) {
    return "Cannot convert to map from '" + t + "'";
  },
  22: "mobx.set requires Set polyfill for the current browser. Check babel-polyfill or core-js/es6/set.js",
  23: "It is not possible to get index atoms from arrays",
  24: function(t) {
    return "Cannot obtain administration from " + t;
  },
  25: function(t, r) {
    return "the entry '" + t + "' does not exist in the observable map '" + r + "'";
  },
  26: "please specify a property",
  27: function(t, r) {
    return "no observable property '" + t.toString() + "' found on the observable object '" + r + "'";
  },
  28: function(t) {
    return "Cannot obtain atom from " + t;
  },
  29: "Expecting some object",
  30: "invalid action stack. did you forget to finish an action?",
  31: "missing option for computed: get",
  32: function(t, r) {
    return "Cycle detected in computation " + t + ": " + r;
  },
  33: function(t) {
    return "The setter of computed value '" + t + "' is trying to update itself. Did you intend to update an _observable_ value, instead of the computed property?";
  },
  34: function(t) {
    return "[ComputedValue '" + t + "'] It is not possible to assign a new value to a computed value.";
  },
  35: "There are multiple, different versions of MobX active. Make sure MobX is loaded only once or use `configure({ isolateGlobalState: true })`",
  36: "isolateGlobalState should be called before MobX is running any reactions",
  37: function(t) {
    return "[mobx] `observableArray." + t + "()` mutates the array in-place, which is not allowed inside a derivation. Use `array.slice()." + t + "()` instead";
  },
  38: "'ownKeys()' can only be used on observable objects",
  39: "'defineProperty()' can only be used on observable objects"
}, Ga = process.env.NODE_ENV !== "production" ? Ja : {};
function f(e) {
  for (var t = arguments.length, r = new Array(t > 1 ? t - 1 : 0), n = 1; n < t; n++)
    r[n - 1] = arguments[n];
  if (process.env.NODE_ENV !== "production") {
    var i = typeof e == "string" ? e : Ga[e];
    throw typeof i == "function" && (i = i.apply(null, r)), new Error("[MobX] " + i);
  }
  throw new Error(typeof e == "number" ? "[MobX] minified error nr: " + e + (r.length ? " " + r.map(String).join(",") : "") + ". Find the full error at: https://github.com/mobxjs/mobx/blob/main/packages/mobx/src/errors.ts" : "[MobX] " + e);
}
var Ya = {};
function Hr() {
  return typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : Ya;
}
var gi = Object.assign, Ht = Object.getOwnPropertyDescriptor, _ = Object.defineProperty, lr = Object.prototype, Xt = [];
Object.freeze(Xt);
var Xr = {};
Object.freeze(Xr);
var Qa = typeof Proxy < "u", _a = /* @__PURE__ */ Object.toString();
function mi() {
  Qa || f(process.env.NODE_ENV !== "production" ? "`Proxy` objects are not available in the current environment. Please configure MobX to enable a fallback implementation.`" : "Proxy not available");
}
function at(e) {
  process.env.NODE_ENV !== "production" && p.verifyProxies && f("MobX is currently configured to be able to run in ES5 mode, but in ES5 MobX won't be able to " + e);
}
function F() {
  return ++p.mobxGuid;
}
function Jr(e) {
  var t = !1;
  return function() {
    if (!t)
      return t = !0, e.apply(this, arguments);
  };
}
var Fe = function() {
};
function k(e) {
  return typeof e == "function";
}
function Pe(e) {
  var t = typeof e;
  switch (t) {
    case "string":
    case "symbol":
    case "number":
      return !0;
  }
  return !1;
}
function cr(e) {
  return e !== null && typeof e == "object";
}
function D(e) {
  if (!cr(e))
    return !1;
  var t = Object.getPrototypeOf(e);
  if (t == null)
    return !0;
  var r = Object.hasOwnProperty.call(t, "constructor") && t.constructor;
  return typeof r == "function" && r.toString() === _a;
}
function bi(e) {
  var t = e?.constructor;
  return t ? t.name === "GeneratorFunction" || t.displayName === "GeneratorFunction" : !1;
}
function dr(e, t, r) {
  _(e, t, {
    enumerable: !1,
    writable: !0,
    configurable: !0,
    value: r
  });
}
function yi(e, t, r) {
  _(e, t, {
    enumerable: !1,
    writable: !1,
    configurable: !0,
    value: r
  });
}
function Ue(e, t) {
  var r = "isMobX" + e;
  return t.prototype[r] = !0, function(n) {
    return cr(n) && n[r] === !0;
  };
}
function Qe(e) {
  return e != null && Object.prototype.toString.call(e) === "[object Map]";
}
function $a(e) {
  var t = Object.getPrototypeOf(e), r = Object.getPrototypeOf(t), n = Object.getPrototypeOf(r);
  return n === null;
}
function ne(e) {
  return e != null && Object.prototype.toString.call(e) === "[object Set]";
}
var wi = typeof Object.getOwnPropertySymbols < "u";
function eo(e) {
  var t = Object.keys(e);
  if (!wi)
    return t;
  var r = Object.getOwnPropertySymbols(e);
  return r.length ? [].concat(t, r.filter(function(n) {
    return lr.propertyIsEnumerable.call(e, n);
  })) : t;
}
var mt = typeof Reflect < "u" && Reflect.ownKeys ? Reflect.ownKeys : wi ? function(e) {
  return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e));
} : (
  /* istanbul ignore next */
  Object.getOwnPropertyNames
);
function Vr(e) {
  return typeof e == "string" ? e : typeof e == "symbol" ? e.toString() : new String(e).toString();
}
function xi(e) {
  return e === null ? null : typeof e == "object" ? "" + e : e;
}
function W(e, t) {
  return lr.hasOwnProperty.call(e, t);
}
var to = Object.getOwnPropertyDescriptors || function(t) {
  var r = {};
  return mt(t).forEach(function(n) {
    r[n] = Ht(t, n);
  }), r;
};
function T(e, t) {
  return !!(e & t);
}
function V(e, t, r) {
  return r ? e |= t : e &= ~t, e;
}
function pn(e, t) {
  (t == null || t > e.length) && (t = e.length);
  for (var r = 0, n = Array(t); r < t; r++) n[r] = e[r];
  return n;
}
function ro(e, t) {
  for (var r = 0; r < t.length; r++) {
    var n = t[r];
    n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(e, io(n.key), n);
  }
}
function _e(e, t, r) {
  return t && ro(e.prototype, t), Object.defineProperty(e, "prototype", {
    writable: !1
  }), e;
}
function Ze(e, t) {
  var r = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
  if (r) return (r = r.call(e)).next.bind(r);
  if (Array.isArray(e) || (r = ao(e)) || t) {
    r && (e = r);
    var n = 0;
    return function() {
      return n >= e.length ? {
        done: !0
      } : {
        done: !1,
        value: e[n++]
      };
    };
  }
  throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
}
function ve() {
  return ve = Object.assign ? Object.assign.bind() : function(e) {
    for (var t = 1; t < arguments.length; t++) {
      var r = arguments[t];
      for (var n in r) ({}).hasOwnProperty.call(r, n) && (e[n] = r[n]);
    }
    return e;
  }, ve.apply(null, arguments);
}
function Oi(e, t) {
  e.prototype = Object.create(t.prototype), e.prototype.constructor = e, Ir(e, t);
}
function Ir(e, t) {
  return Ir = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(r, n) {
    return r.__proto__ = n, r;
  }, Ir(e, t);
}
function no(e, t) {
  if (typeof e != "object" || !e) return e;
  var r = e[Symbol.toPrimitive];
  if (r !== void 0) {
    var n = r.call(e, t);
    if (typeof n != "object") return n;
    throw new TypeError("@@toPrimitive must return a primitive value.");
  }
  return String(e);
}
function io(e) {
  var t = no(e, "string");
  return typeof t == "symbol" ? t : t + "";
}
function ao(e, t) {
  if (e) {
    if (typeof e == "string") return pn(e, t);
    var r = {}.toString.call(e).slice(8, -1);
    return r === "Object" && e.constructor && (r = e.constructor.name), r === "Map" || r === "Set" ? Array.from(e) : r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r) ? pn(e, t) : void 0;
  }
}
var ie = /* @__PURE__ */ Symbol("mobx-stored-annotations");
function $(e) {
  function t(r, n) {
    if (At(n))
      return e.decorate_20223_(r, n);
    Ct(r, n, e);
  }
  return Object.assign(t, e);
}
function Ct(e, t, r) {
  if (W(e, ie) || dr(e, ie, ve({}, e[ie])), process.env.NODE_ENV !== "production" && Jt(r) && !W(e[ie], t)) {
    var n = e.constructor.name + ".prototype." + t.toString();
    f("'" + n + "' is decorated with 'override', but no such decorated member was found on prototype.");
  }
  oo(e, r, t), Jt(r) || (e[ie][t] = r);
}
function oo(e, t, r) {
  if (process.env.NODE_ENV !== "production" && !Jt(t) && W(e[ie], r)) {
    var n = e.constructor.name + ".prototype." + r.toString(), i = e[ie][r].annotationType_, a = t.annotationType_;
    f("Cannot apply '@" + a + "' to '" + n + "':" + (`
The field is already decorated with '@` + i + "'.") + `
Re-decorating fields is not allowed.
Use '@override' decorator for methods overridden by subclass.`);
  }
}
function At(e) {
  return typeof e == "object" && typeof e.kind == "string";
}
function ur(e, t) {
  process.env.NODE_ENV !== "production" && !t.includes(e.kind) && f("The decorator applied to '" + String(e.name) + "' cannot be used on a " + e.kind + " element");
}
var g = /* @__PURE__ */ Symbol("mobx administration"), me = /* @__PURE__ */ function() {
  function e(r) {
    r === void 0 && (r = process.env.NODE_ENV !== "production" ? "Atom@" + F() : "Atom"), this.name_ = void 0, this.flags_ = 0, this.observers_ = /* @__PURE__ */ new Set(), this.lastAccessedBy_ = 0, this.lowestObserverState_ = w.NOT_TRACKING_, this.onBOL = void 0, this.onBUOL = void 0, this.name_ = r;
  }
  var t = e.prototype;
  return t.onBO = function() {
    this.onBOL && this.onBOL.forEach(function(n) {
      return n();
    });
  }, t.onBUO = function() {
    this.onBUOL && this.onBUOL.forEach(function(n) {
      return n();
    });
  }, t.reportObserved = function() {
    return ji(this);
  }, t.reportChanged = function() {
    R(), Ri(this), q();
  }, t.toString = function() {
    return this.name_;
  }, _e(e, [{
    key: "isBeingObserved",
    get: function() {
      return T(this.flags_, e.isBeingObservedMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isBeingObservedMask_, n);
    }
  }, {
    key: "isPendingUnobservation",
    get: function() {
      return T(this.flags_, e.isPendingUnobservationMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isPendingUnobservationMask_, n);
    }
  }, {
    key: "diffValue",
    get: function() {
      return T(this.flags_, e.diffValueMask_) ? 1 : 0;
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.diffValueMask_, n === 1);
    }
  }]);
}();
me.isBeingObservedMask_ = 1;
me.isPendingUnobservationMask_ = 2;
me.diffValueMask_ = 4;
var Gr = /* @__PURE__ */ Ue("Atom", me);
function Ei(e, t, r) {
  t === void 0 && (t = Fe), r === void 0 && (r = Fe);
  var n = new me(e);
  return t !== Fe && ms(n, t), r !== Fe && Ji(n, r), n;
}
function so(e, t) {
  return oa(e, t);
}
function lo(e, t) {
  return Object.is ? Object.is(e, t) : e === t ? e !== 0 || 1 / e === 1 / t : e !== e && t !== t;
}
var Xe = {
  structural: so,
  default: lo
};
function De(e, t, r) {
  return wt(e) ? e : Array.isArray(e) ? C.array(e, {
    name: r
  }) : D(e) ? C.object(e, void 0, {
    name: r
  }) : Qe(e) ? C.map(e, {
    name: r
  }) : ne(e) ? C.set(e, {
    name: r
  }) : typeof e == "function" && !Ve(e) && !yt(e) ? bi(e) ? Je(e) : bt(r, e) : e;
}
function co(e, t, r) {
  if (e == null || tt(e) || br(e) || be(e) || Y(e))
    return e;
  if (Array.isArray(e))
    return C.array(e, {
      name: r,
      deep: !1
    });
  if (D(e))
    return C.object(e, void 0, {
      name: r,
      deep: !1
    });
  if (Qe(e))
    return C.map(e, {
      name: r,
      deep: !1
    });
  if (ne(e))
    return C.set(e, {
      name: r,
      deep: !1
    });
  process.env.NODE_ENV !== "production" && f("The shallow modifier / decorator can only used in combination with arrays, objects, maps and sets");
}
function pr(e) {
  return e;
}
function uo(e, t) {
  return process.env.NODE_ENV !== "production" && wt(e) && f("observable.struct should not be used with observable values"), oa(e, t) ? t : e;
}
var po = "override";
function Jt(e) {
  return e.annotationType_ === po;
}
function St(e, t) {
  return {
    annotationType_: e,
    options_: t,
    make_: fo,
    extend_: vo,
    decorate_20223_: ho
  };
}
function fo(e, t, r, n) {
  var i;
  if ((i = this.options_) != null && i.bound)
    return this.extend_(e, t, r, !1) === null ? 0 : 1;
  if (n === e.target_)
    return this.extend_(e, t, r, !1) === null ? 0 : 2;
  if (Ve(r.value))
    return 1;
  var a = ki(e, this, t, r, !1);
  return _(n, t, a), 2;
}
function vo(e, t, r, n) {
  var i = ki(e, this, t, r);
  return e.defineProperty_(t, i, n);
}
function ho(e, t) {
  process.env.NODE_ENV !== "production" && ur(t, ["method", "field"]);
  var r = t.kind, n = t.name, i = t.addInitializer, a = this, o = function(c) {
    var d, u, v, h;
    return Ne((d = (u = a.options_) == null ? void 0 : u.name) != null ? d : n.toString(), c, (v = (h = a.options_) == null ? void 0 : h.autoAction) != null ? v : !1);
  };
  if (r == "field")
    return function(l) {
      var c, d = l;
      return Ve(d) || (d = o(d)), (c = a.options_) != null && c.bound && (d = d.bind(this), d.isMobxAction = !0), d;
    };
  if (r == "method") {
    var s;
    return Ve(e) || (e = o(e)), (s = this.options_) != null && s.bound && i(function() {
      var l = this, c = l[n].bind(l);
      c.isMobxAction = !0, l[n] = c;
    }), e;
  }
  f("Cannot apply '" + a.annotationType_ + "' to '" + String(n) + "' (kind: " + r + "):" + (`
'` + a.annotationType_ + "' can only be used on properties with a function value."));
}
function go(e, t, r, n) {
  var i = t.annotationType_, a = n.value;
  process.env.NODE_ENV !== "production" && !k(a) && f("Cannot apply '" + i + "' to '" + e.name_ + "." + r.toString() + "':" + (`
'` + i + "' can only be used on properties with a function value."));
}
function ki(e, t, r, n, i) {
  var a, o, s, l, c, d, u;
  i === void 0 && (i = p.safeDescriptors), go(e, t, r, n);
  var v = n.value;
  if ((a = t.options_) != null && a.bound) {
    var h;
    v = v.bind((h = e.proxy_) != null ? h : e.target_);
  }
  return {
    value: Ne(
      (o = (s = t.options_) == null ? void 0 : s.name) != null ? o : r.toString(),
      v,
      (l = (c = t.options_) == null ? void 0 : c.autoAction) != null ? l : !1,
      // https://github.com/mobxjs/mobx/discussions/3140
      (d = t.options_) != null && d.bound ? (u = e.proxy_) != null ? u : e.target_ : void 0
    ),
    // Non-configurable for classes
    // prevents accidental field redefinition in subclass
    configurable: i ? e.isPlainObject_ : !0,
    // https://github.com/mobxjs/mobx/pull/2641#issuecomment-737292058
    enumerable: !1,
    // Non-obsevable, therefore non-writable
    // Also prevents rewriting in subclass constructor
    writable: !i
  };
}
function Ci(e, t) {
  return {
    annotationType_: e,
    options_: t,
    make_: mo,
    extend_: bo,
    decorate_20223_: yo
  };
}
function mo(e, t, r, n) {
  var i;
  if (n === e.target_)
    return this.extend_(e, t, r, !1) === null ? 0 : 2;
  if ((i = this.options_) != null && i.bound && (!W(e.target_, t) || !yt(e.target_[t])) && this.extend_(e, t, r, !1) === null)
    return 0;
  if (yt(r.value))
    return 1;
  var a = Ai(e, this, t, r, !1, !1);
  return _(n, t, a), 2;
}
function bo(e, t, r, n) {
  var i, a = Ai(e, this, t, r, (i = this.options_) == null ? void 0 : i.bound);
  return e.defineProperty_(t, a, n);
}
function yo(e, t) {
  var r;
  process.env.NODE_ENV !== "production" && ur(t, ["method"]);
  var n = t.name, i = t.addInitializer;
  return yt(e) || (e = Je(e)), (r = this.options_) != null && r.bound && i(function() {
    var a = this, o = a[n].bind(a);
    o.isMobXFlow = !0, a[n] = o;
  }), e;
}
function wo(e, t, r, n) {
  var i = t.annotationType_, a = n.value;
  process.env.NODE_ENV !== "production" && !k(a) && f("Cannot apply '" + i + "' to '" + e.name_ + "." + r.toString() + "':" + (`
'` + i + "' can only be used on properties with a generator function value."));
}
function Ai(e, t, r, n, i, a) {
  a === void 0 && (a = p.safeDescriptors), wo(e, t, r, n);
  var o = n.value;
  if (yt(o) || (o = Je(o)), i) {
    var s;
    o = o.bind((s = e.proxy_) != null ? s : e.target_), o.isMobXFlow = !0;
  }
  return {
    value: o,
    // Non-configurable for classes
    // prevents accidental field redefinition in subclass
    configurable: a ? e.isPlainObject_ : !0,
    // https://github.com/mobxjs/mobx/pull/2641#issuecomment-737292058
    enumerable: !1,
    // Non-obsevable, therefore non-writable
    // Also prevents rewriting in subclass constructor
    writable: !a
  };
}
function Yr(e, t) {
  return {
    annotationType_: e,
    options_: t,
    make_: xo,
    extend_: Oo,
    decorate_20223_: Eo
  };
}
function xo(e, t, r) {
  return this.extend_(e, t, r, !1) === null ? 0 : 1;
}
function Oo(e, t, r, n) {
  return ko(e, this, t, r), e.defineComputedProperty_(t, ve({}, this.options_, {
    get: r.get,
    set: r.set
  }), n);
}
function Eo(e, t) {
  process.env.NODE_ENV !== "production" && ur(t, ["getter"]);
  var r = this, n = t.name, i = t.addInitializer;
  return i(function() {
    var a = et(this)[g], o = ve({}, r.options_, {
      get: e,
      context: this
    });
    o.name || (o.name = process.env.NODE_ENV !== "production" ? a.name_ + "." + n.toString() : "ObservableObject." + n.toString()), a.values_.set(n, new B(o));
  }), function() {
    return this[g].getObservablePropValue_(n);
  };
}
function ko(e, t, r, n) {
  var i = t.annotationType_, a = n.get;
  process.env.NODE_ENV !== "production" && !a && f("Cannot apply '" + i + "' to '" + e.name_ + "." + r.toString() + "':" + (`
'` + i + "' can only be used on getter(+setter) properties."));
}
function fr(e, t) {
  return {
    annotationType_: e,
    options_: t,
    make_: Co,
    extend_: Ao,
    decorate_20223_: So
  };
}
function Co(e, t, r) {
  return this.extend_(e, t, r, !1) === null ? 0 : 1;
}
function Ao(e, t, r, n) {
  var i, a;
  return Po(e, this, t, r), e.defineObservableProperty_(t, r.value, (i = (a = this.options_) == null ? void 0 : a.enhancer) != null ? i : De, n);
}
function So(e, t) {
  if (process.env.NODE_ENV !== "production") {
    if (t.kind === "field")
      throw f("Please use `@observable accessor " + String(t.name) + "` instead of `@observable " + String(t.name) + "`");
    ur(t, ["accessor"]);
  }
  var r = this, n = t.kind, i = t.name, a = /* @__PURE__ */ new WeakSet();
  function o(s, l) {
    var c, d, u = et(s)[g], v = new Se(l, (c = (d = r.options_) == null ? void 0 : d.enhancer) != null ? c : De, process.env.NODE_ENV !== "production" ? u.name_ + "." + i.toString() : "ObservableObject." + i.toString(), !1);
    u.values_.set(i, v), a.add(s);
  }
  if (n == "accessor")
    return {
      get: function() {
        return a.has(this) || o(this, e.get.call(this)), this[g].getObservablePropValue_(i);
      },
      set: function(l) {
        return a.has(this) || o(this, l), this[g].setObservablePropValue_(i, l);
      },
      init: function(l) {
        return a.has(this) || o(this, l), l;
      }
    };
}
function Po(e, t, r, n) {
  var i = t.annotationType_;
  process.env.NODE_ENV !== "production" && !("value" in n) && f("Cannot apply '" + i + "' to '" + e.name_ + "." + r.toString() + "':" + (`
'` + i + "' cannot be used on getter/setter properties"));
}
var Do = "true", No = /* @__PURE__ */ Si();
function Si(e) {
  return {
    annotationType_: Do,
    options_: e,
    make_: To,
    extend_: Vo,
    decorate_20223_: Io
  };
}
function To(e, t, r, n) {
  var i, a;
  if (r.get)
    return vr.make_(e, t, r, n);
  if (r.set) {
    var o = Ve(r.set) ? r.set : Ne(t.toString(), r.set);
    return n === e.target_ ? e.defineProperty_(t, {
      configurable: p.safeDescriptors ? e.isPlainObject_ : !0,
      set: o
    }) === null ? 0 : 2 : (_(n, t, {
      configurable: !0,
      set: o
    }), 2);
  }
  if (n !== e.target_ && typeof r.value == "function") {
    var s;
    if (bi(r.value)) {
      var l, c = (l = this.options_) != null && l.autoBind ? Je.bound : Je;
      return c.make_(e, t, r, n);
    }
    var d = (s = this.options_) != null && s.autoBind ? bt.bound : bt;
    return d.make_(e, t, r, n);
  }
  var u = ((i = this.options_) == null ? void 0 : i.deep) === !1 ? C.ref : C;
  if (typeof r.value == "function" && (a = this.options_) != null && a.autoBind) {
    var v;
    r.value = r.value.bind((v = e.proxy_) != null ? v : e.target_);
  }
  return u.make_(e, t, r, n);
}
function Vo(e, t, r, n) {
  var i, a;
  if (r.get)
    return vr.extend_(e, t, r, n);
  if (r.set)
    return e.defineProperty_(t, {
      configurable: p.safeDescriptors ? e.isPlainObject_ : !0,
      set: Ne(t.toString(), r.set)
    }, n);
  if (typeof r.value == "function" && (i = this.options_) != null && i.autoBind) {
    var o;
    r.value = r.value.bind((o = e.proxy_) != null ? o : e.target_);
  }
  var s = ((a = this.options_) == null ? void 0 : a.deep) === !1 ? C.ref : C;
  return s.extend_(e, t, r, n);
}
function Io(e, t) {
  f("'" + this.annotationType_ + "' cannot be used as a decorator");
}
var zo = "observable", Uo = "observable.ref", Lo = "observable.shallow", Mo = "observable.struct", Pi = {
  deep: !0,
  name: void 0,
  defaultDecorator: void 0,
  proxy: !0
};
Object.freeze(Pi);
function Vt(e) {
  return e || Pi;
}
var zr = /* @__PURE__ */ fr(zo), jo = /* @__PURE__ */ fr(Uo, {
  enhancer: pr
}), Ro = /* @__PURE__ */ fr(Lo, {
  enhancer: co
}), qo = /* @__PURE__ */ fr(Mo, {
  enhancer: uo
}), Di = /* @__PURE__ */ $(zr);
function It(e) {
  return e.deep === !0 ? De : e.deep === !1 ? pr : Bo(e.defaultDecorator);
}
function Ko(e) {
  var t;
  return e ? (t = e.defaultDecorator) != null ? t : Si(e) : void 0;
}
function Bo(e) {
  var t, r;
  return e && (t = (r = e.options_) == null ? void 0 : r.enhancer) != null ? t : De;
}
function Ni(e, t, r) {
  if (At(t))
    return zr.decorate_20223_(e, t);
  if (Pe(t)) {
    Ct(e, t, zr);
    return;
  }
  return wt(e) ? e : D(e) ? C.object(e, t, r) : Array.isArray(e) ? C.array(e, t) : Qe(e) ? C.map(e, t) : ne(e) ? C.set(e, t) : typeof e == "object" && e !== null ? e : C.box(e, t);
}
gi(Ni, Di);
var Fo = {
  box: function(t, r) {
    var n = Vt(r);
    return new Se(t, It(n), n.name, !0, n.equals);
  },
  array: function(t, r) {
    var n = Vt(r);
    return (p.useProxies === !1 || n.proxy === !1 ? Rs : Ds)(t, It(n), n.name);
  },
  map: function(t, r) {
    var n = Vt(r);
    return new ea(t, It(n), n.name);
  },
  set: function(t, r) {
    var n = Vt(r);
    return new ta(t, It(n), n.name);
  },
  object: function(t, r, n) {
    return Me(function() {
      return Yi(p.useProxies === !1 || n?.proxy === !1 ? et({}, n) : As({}, n), t, r);
    });
  },
  ref: /* @__PURE__ */ $(jo),
  shallow: /* @__PURE__ */ $(Ro),
  deep: Di,
  struct: /* @__PURE__ */ $(qo)
}, C = /* @__PURE__ */ gi(Ni, Fo), Ti = "computed", Zo = "computed.struct", Ur = /* @__PURE__ */ Yr(Ti), Wo = /* @__PURE__ */ Yr(Zo, {
  equals: Xe.structural
}), vr = function(t, r) {
  if (At(r))
    return Ur.decorate_20223_(t, r);
  if (Pe(r))
    return Ct(t, r, Ur);
  if (D(t))
    return $(Yr(Ti, t));
  process.env.NODE_ENV !== "production" && (k(t) || f("First argument to `computed` should be an expression."), k(r) && f("A setter as second argument is no longer supported, use `{ set: fn }` option instead"));
  var n = D(r) ? r : {};
  return n.get = t, n.name || (n.name = t.name || ""), new B(n);
};
Object.assign(vr, Ur);
vr.struct = /* @__PURE__ */ $(Wo);
var fn, vn, Gt = 0, Ho = 1, Xo = (fn = (vn = /* @__PURE__ */ Ht(function() {
}, "name")) == null ? void 0 : vn.configurable) != null ? fn : !1, hn = {
  value: "action",
  configurable: !0,
  writable: !1,
  enumerable: !1
};
function Ne(e, t, r, n) {
  r === void 0 && (r = !1), process.env.NODE_ENV !== "production" && (k(t) || f("`action` can only be invoked on functions"), (typeof e != "string" || !e) && f("actions should have valid names, got: '" + e + "'"));
  function i() {
    return Vi(e, r, t, n || this, arguments);
  }
  return i.isMobxAction = !0, i.toString = function() {
    return t.toString();
  }, Xo && (hn.value = e, _(i, "name", hn)), i;
}
function Vi(e, t, r, n, i) {
  var a = Jo(e, t, n, i);
  try {
    return r.apply(n, i);
  } catch (o) {
    throw a.error_ = o, o;
  } finally {
    Go(a);
  }
}
function Jo(e, t, r, n) {
  var i = process.env.NODE_ENV !== "production" && P() && !!e, a = 0;
  if (process.env.NODE_ENV !== "production" && i) {
    a = Date.now();
    var o = n ? Array.from(n) : Xt;
    I({
      type: _r,
      name: e,
      object: r,
      arguments: o
    });
  }
  var s = p.trackingDerivation, l = !t || !s;
  R();
  var c = p.allowStateChanges;
  l && (Le(), c = hr(!0));
  var d = Qr(!0), u = {
    runAsAction_: l,
    prevDerivation_: s,
    prevAllowStateChanges_: c,
    prevAllowStateReads_: d,
    notifySpy_: i,
    startTime_: a,
    actionId_: Ho++,
    parentActionId_: Gt
  };
  return Gt = u.actionId_, u;
}
function Go(e) {
  Gt !== e.actionId_ && f(30), Gt = e.parentActionId_, e.error_ !== void 0 && (p.suppressReactionErrors = !0), gr(e.prevAllowStateChanges_), ft(e.prevAllowStateReads_), q(), e.runAsAction_ && oe(e.prevDerivation_), process.env.NODE_ENV !== "production" && e.notifySpy_ && z({
    time: Date.now() - e.startTime_
  }), p.suppressReactionErrors = !1;
}
function Yo(e, t) {
  var r = hr(e);
  try {
    return t();
  } finally {
    gr(r);
  }
}
function hr(e) {
  var t = p.allowStateChanges;
  return p.allowStateChanges = e, t;
}
function gr(e) {
  p.allowStateChanges = e;
}
var Qo = "create", Se = /* @__PURE__ */ function(e) {
  function t(n, i, a, o, s) {
    var l;
    if (a === void 0 && (a = process.env.NODE_ENV !== "production" ? "ObservableValue@" + F() : "ObservableValue"), o === void 0 && (o = !0), s === void 0 && (s = Xe.default), l = e.call(this, a) || this, l.enhancer = void 0, l.name_ = void 0, l.equals = void 0, l.hasUnreportedChange_ = !1, l.interceptors_ = void 0, l.changeListeners_ = void 0, l.value_ = void 0, l.dehancer = void 0, l.enhancer = i, l.name_ = a, l.equals = s, l.value_ = i(n, void 0, a), process.env.NODE_ENV !== "production" && o && P()) {
      var c;
      Te({
        type: Qo,
        object: l,
        observableKind: "value",
        debugObjectName: l.name_,
        newValue: "" + ((c = l.value_) == null ? void 0 : c.toString())
      });
    }
    return l;
  }
  Oi(t, e);
  var r = t.prototype;
  return r.dehanceValue = function(i) {
    return this.dehancer !== void 0 ? this.dehancer(i) : i;
  }, r.set = function(i) {
    var a = this.value_;
    if (i = this.prepareNewValue_(i), i !== p.UNCHANGED) {
      var o = P();
      process.env.NODE_ENV !== "production" && o && I({
        type: Z,
        object: this,
        observableKind: "value",
        debugObjectName: this.name_,
        newValue: i,
        oldValue: a
      }), this.setNewValue_(i), process.env.NODE_ENV !== "production" && o && z();
    }
  }, r.prepareNewValue_ = function(i) {
    if (Q(this), M(this)) {
      var a = j(this, {
        object: this,
        type: Z,
        newValue: i
      });
      if (!a)
        return p.UNCHANGED;
      i = a.newValue;
    }
    return i = this.enhancer(i, this.value_, this.name_), this.equals(this.value_, i) ? p.UNCHANGED : i;
  }, r.setNewValue_ = function(i) {
    var a = this.value_;
    this.value_ = i, this.reportChanged(), H(this) && X(this, {
      type: Z,
      object: this,
      newValue: i,
      oldValue: a
    });
  }, r.get = function() {
    return this.reportObserved(), this.dehanceValue(this.value_);
  }, r.intercept_ = function(i) {
    return Pt(this, i);
  }, r.observe_ = function(i, a) {
    return a && i({
      observableKind: "value",
      debugObjectName: this.name_,
      object: this,
      type: Z,
      newValue: this.value_,
      oldValue: void 0
    }), Dt(this, i);
  }, r.raw = function() {
    return this.value_;
  }, r.toJSON = function() {
    return this.get();
  }, r.toString = function() {
    return this.name_ + "[" + this.value_ + "]";
  }, r.valueOf = function() {
    return xi(this.get());
  }, r[Symbol.toPrimitive] = function() {
    return this.valueOf();
  }, t;
}(me), B = /* @__PURE__ */ function() {
  function e(r) {
    this.dependenciesState_ = w.NOT_TRACKING_, this.observing_ = [], this.newObserving_ = null, this.observers_ = /* @__PURE__ */ new Set(), this.runId_ = 0, this.lastAccessedBy_ = 0, this.lowestObserverState_ = w.UP_TO_DATE_, this.unboundDepsCount_ = 0, this.value_ = new Yt(null), this.name_ = void 0, this.triggeredBy_ = void 0, this.flags_ = 0, this.derivation = void 0, this.setter_ = void 0, this.isTracing_ = K.NONE, this.scope_ = void 0, this.equals_ = void 0, this.requiresReaction_ = void 0, this.keepAlive_ = void 0, this.onBOL = void 0, this.onBUOL = void 0, r.get || f(31), this.derivation = r.get, this.name_ = r.name || (process.env.NODE_ENV !== "production" ? "ComputedValue@" + F() : "ComputedValue"), r.set && (this.setter_ = Ne(process.env.NODE_ENV !== "production" ? this.name_ + "-setter" : "ComputedValue-setter", r.set)), this.equals_ = r.equals || (r.compareStructural || r.struct ? Xe.structural : Xe.default), this.scope_ = r.context, this.requiresReaction_ = r.requiresReaction, this.keepAlive_ = !!r.keepAlive;
  }
  var t = e.prototype;
  return t.onBecomeStale_ = function() {
    ns(this);
  }, t.onBO = function() {
    this.onBOL && this.onBOL.forEach(function(n) {
      return n();
    });
  }, t.onBUO = function() {
    this.onBUOL && this.onBUOL.forEach(function(n) {
      return n();
    });
  }, t.get = function() {
    if (this.isComputing && f(32, this.name_, this.derivation), p.inBatch === 0 && // !globalState.trackingDerivatpion &&
    this.observers_.size === 0 && !this.keepAlive_)
      Lr(this) && (this.warnAboutUntrackedRead_(), R(), this.value_ = this.computeValue_(!1), q());
    else if (ji(this), Lr(this)) {
      var n = p.trackingContext;
      this.keepAlive_ && !n && (p.trackingContext = this), this.trackAndCompute() && rs(this), p.trackingContext = n;
    }
    var i = this.value_;
    if (Kt(i))
      throw i.cause;
    return i;
  }, t.set = function(n) {
    if (this.setter_) {
      this.isRunningSetter && f(33, this.name_), this.isRunningSetter = !0;
      try {
        this.setter_.call(this.scope_, n);
      } finally {
        this.isRunningSetter = !1;
      }
    } else
      f(34, this.name_);
  }, t.trackAndCompute = function() {
    var n = this.value_, i = (
      /* see #1208 */
      this.dependenciesState_ === w.NOT_TRACKING_
    ), a = this.computeValue_(!0), o = i || Kt(n) || Kt(a) || !this.equals_(n, a);
    return o && (this.value_ = a, process.env.NODE_ENV !== "production" && P() && Te({
      observableKind: "computed",
      debugObjectName: this.name_,
      object: this.scope_,
      type: "update",
      oldValue: n,
      newValue: a
    })), o;
  }, t.computeValue_ = function(n) {
    this.isComputing = !0;
    var i = hr(!1), a;
    if (n)
      a = Ii(this, this.derivation, this.scope_);
    else if (p.disableErrorBoundaries === !0)
      a = this.derivation.call(this.scope_);
    else
      try {
        a = this.derivation.call(this.scope_);
      } catch (o) {
        a = new Yt(o);
      }
    return gr(i), this.isComputing = !1, a;
  }, t.suspend_ = function() {
    this.keepAlive_ || (Mr(this), this.value_ = void 0, process.env.NODE_ENV !== "production" && this.isTracing_ !== K.NONE && console.log("[mobx.trace] Computed value '" + this.name_ + "' was suspended and it will recompute on the next access."));
  }, t.observe_ = function(n, i) {
    var a = this, o = !0, s = void 0;
    return Hi(function() {
      var l = a.get();
      if (!o || i) {
        var c = Le();
        n({
          observableKind: "computed",
          debugObjectName: a.name_,
          type: Z,
          object: a,
          newValue: l,
          oldValue: s
        }), oe(c);
      }
      o = !1, s = l;
    });
  }, t.warnAboutUntrackedRead_ = function() {
    process.env.NODE_ENV !== "production" && (this.isTracing_ !== K.NONE && console.log("[mobx.trace] Computed value '" + this.name_ + "' is being read outside a reactive context. Doing a full recompute."), (typeof this.requiresReaction_ == "boolean" ? this.requiresReaction_ : p.computedRequiresReaction) && console.warn("[mobx] Computed value '" + this.name_ + "' is being read outside a reactive context. Doing a full recompute."));
  }, t.toString = function() {
    return this.name_ + "[" + this.derivation.toString() + "]";
  }, t.valueOf = function() {
    return xi(this.get());
  }, t[Symbol.toPrimitive] = function() {
    return this.valueOf();
  }, _e(e, [{
    key: "isComputing",
    get: function() {
      return T(this.flags_, e.isComputingMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isComputingMask_, n);
    }
  }, {
    key: "isRunningSetter",
    get: function() {
      return T(this.flags_, e.isRunningSetterMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isRunningSetterMask_, n);
    }
  }, {
    key: "isBeingObserved",
    get: function() {
      return T(this.flags_, e.isBeingObservedMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isBeingObservedMask_, n);
    }
  }, {
    key: "isPendingUnobservation",
    get: function() {
      return T(this.flags_, e.isPendingUnobservationMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isPendingUnobservationMask_, n);
    }
  }, {
    key: "diffValue",
    get: function() {
      return T(this.flags_, e.diffValueMask_) ? 1 : 0;
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.diffValueMask_, n === 1);
    }
  }]);
}();
B.isComputingMask_ = 1;
B.isRunningSetterMask_ = 2;
B.isBeingObservedMask_ = 4;
B.isPendingUnobservationMask_ = 8;
B.diffValueMask_ = 16;
var mr = /* @__PURE__ */ Ue("ComputedValue", B), w;
(function(e) {
  e[e.NOT_TRACKING_ = -1] = "NOT_TRACKING_", e[e.UP_TO_DATE_ = 0] = "UP_TO_DATE_", e[e.POSSIBLY_STALE_ = 1] = "POSSIBLY_STALE_", e[e.STALE_ = 2] = "STALE_";
})(w || (w = {}));
var K;
(function(e) {
  e[e.NONE = 0] = "NONE", e[e.LOG = 1] = "LOG", e[e.BREAK = 2] = "BREAK";
})(K || (K = {}));
var Yt = function(t) {
  this.cause = void 0, this.cause = t;
};
function Kt(e) {
  return e instanceof Yt;
}
function Lr(e) {
  switch (e.dependenciesState_) {
    case w.UP_TO_DATE_:
      return !1;
    case w.NOT_TRACKING_:
    case w.STALE_:
      return !0;
    case w.POSSIBLY_STALE_: {
      for (var t = Qr(!0), r = Le(), n = e.observing_, i = n.length, a = 0; a < i; a++) {
        var o = n[a];
        if (mr(o)) {
          if (p.disableErrorBoundaries)
            o.get();
          else
            try {
              o.get();
            } catch {
              return oe(r), ft(t), !0;
            }
          if (e.dependenciesState_ === w.STALE_)
            return oe(r), ft(t), !0;
        }
      }
      return Ui(e), oe(r), ft(t), !1;
    }
  }
}
function Q(e) {
  if (process.env.NODE_ENV !== "production") {
    var t = e.observers_.size > 0;
    !p.allowStateChanges && (t || p.enforceActions === "always") && console.warn("[MobX] " + (p.enforceActions ? "Since strict-mode is enabled, changing (observed) observable values without using an action is not allowed. Tried to modify: " : "Side effects like changing state are not allowed at this point. Are you trying to modify state from, for example, a computed value or the render function of a React component? You can wrap side effects in 'runInAction' (or decorate functions with 'action') if needed. Tried to modify: ") + e.name_);
  }
}
function _o(e) {
  process.env.NODE_ENV !== "production" && !p.allowStateReads && p.observableRequiresReaction && console.warn("[mobx] Observable '" + e.name_ + "' being read outside a reactive context.");
}
function Ii(e, t, r) {
  var n = Qr(!0);
  Ui(e), e.newObserving_ = new Array(
    // Reserve constant space for initial dependencies, dynamic space otherwise.
    // See https://github.com/mobxjs/mobx/pull/3833
    e.runId_ === 0 ? 100 : e.observing_.length
  ), e.unboundDepsCount_ = 0, e.runId_ = ++p.runId;
  var i = p.trackingDerivation;
  p.trackingDerivation = e, p.inBatch++;
  var a;
  if (p.disableErrorBoundaries === !0)
    a = t.call(r);
  else
    try {
      a = t.call(r);
    } catch (o) {
      a = new Yt(o);
    }
  return p.inBatch--, p.trackingDerivation = i, es(e), $o(e), ft(n), a;
}
function $o(e) {
  process.env.NODE_ENV !== "production" && e.observing_.length === 0 && (typeof e.requiresObservable_ == "boolean" ? e.requiresObservable_ : p.reactionRequiresObservable) && console.warn("[mobx] Derivation '" + e.name_ + "' is created/updated without reading any observable value.");
}
function es(e) {
  for (var t = e.observing_, r = e.observing_ = e.newObserving_, n = w.UP_TO_DATE_, i = 0, a = e.unboundDepsCount_, o = 0; o < a; o++) {
    var s = r[o];
    s.diffValue === 0 && (s.diffValue = 1, i !== o && (r[i] = s), i++), s.dependenciesState_ > n && (n = s.dependenciesState_);
  }
  for (r.length = i, e.newObserving_ = null, a = t.length; a--; ) {
    var l = t[a];
    l.diffValue === 0 && Li(l, e), l.diffValue = 0;
  }
  for (; i--; ) {
    var c = r[i];
    c.diffValue === 1 && (c.diffValue = 0, ts(c, e));
  }
  n !== w.UP_TO_DATE_ && (e.dependenciesState_ = n, e.onBecomeStale_());
}
function Mr(e) {
  var t = e.observing_;
  e.observing_ = [];
  for (var r = t.length; r--; )
    Li(t[r], e);
  e.dependenciesState_ = w.NOT_TRACKING_;
}
function zi(e) {
  var t = Le();
  try {
    return e();
  } finally {
    oe(t);
  }
}
function Le() {
  var e = p.trackingDerivation;
  return p.trackingDerivation = null, e;
}
function oe(e) {
  p.trackingDerivation = e;
}
function Qr(e) {
  var t = p.allowStateReads;
  return p.allowStateReads = e, t;
}
function ft(e) {
  p.allowStateReads = e;
}
function Ui(e) {
  if (e.dependenciesState_ !== w.UP_TO_DATE_) {
    e.dependenciesState_ = w.UP_TO_DATE_;
    for (var t = e.observing_, r = t.length; r--; )
      t[r].lowestObserverState_ = w.UP_TO_DATE_;
  }
}
var Or = function() {
  this.version = 6, this.UNCHANGED = {}, this.trackingDerivation = null, this.trackingContext = null, this.runId = 0, this.mobxGuid = 0, this.inBatch = 0, this.pendingUnobservations = [], this.pendingReactions = [], this.isRunningReactions = !1, this.allowStateChanges = !1, this.allowStateReads = !0, this.enforceActions = !0, this.spyListeners = [], this.globalReactionErrorHandlers = [], this.computedRequiresReaction = !1, this.reactionRequiresObservable = !1, this.observableRequiresReaction = !1, this.disableErrorBoundaries = !1, this.suppressReactionErrors = !1, this.useProxies = !0, this.verifyProxies = !1, this.safeDescriptors = !0;
}, Er = !0, p = /* @__PURE__ */ function() {
  var e = /* @__PURE__ */ Hr();
  return e.__mobxInstanceCount > 0 && !e.__mobxGlobals && (Er = !1), e.__mobxGlobals && e.__mobxGlobals.version !== new Or().version && (Er = !1), Er ? e.__mobxGlobals ? (e.__mobxInstanceCount += 1, e.__mobxGlobals.UNCHANGED || (e.__mobxGlobals.UNCHANGED = {}), e.__mobxGlobals) : (e.__mobxInstanceCount = 1, e.__mobxGlobals = /* @__PURE__ */ new Or()) : (setTimeout(function() {
    f(35);
  }, 1), new Or());
}();
function ts(e, t) {
  e.observers_.add(t), e.lowestObserverState_ > t.dependenciesState_ && (e.lowestObserverState_ = t.dependenciesState_);
}
function Li(e, t) {
  e.observers_.delete(t), e.observers_.size === 0 && Mi(e);
}
function Mi(e) {
  e.isPendingUnobservation === !1 && (e.isPendingUnobservation = !0, p.pendingUnobservations.push(e));
}
function R() {
  p.inBatch++;
}
function q() {
  if (--p.inBatch === 0) {
    Bi();
    for (var e = p.pendingUnobservations, t = 0; t < e.length; t++) {
      var r = e[t];
      r.isPendingUnobservation = !1, r.observers_.size === 0 && (r.isBeingObserved && (r.isBeingObserved = !1, r.onBUO()), r instanceof B && r.suspend_());
    }
    p.pendingUnobservations = [];
  }
}
function ji(e) {
  _o(e);
  var t = p.trackingDerivation;
  return t !== null ? (t.runId_ !== e.lastAccessedBy_ && (e.lastAccessedBy_ = t.runId_, t.newObserving_[t.unboundDepsCount_++] = e, !e.isBeingObserved && p.trackingContext && (e.isBeingObserved = !0, e.onBO())), e.isBeingObserved) : (e.observers_.size === 0 && p.inBatch > 0 && Mi(e), !1);
}
function Ri(e) {
  e.lowestObserverState_ !== w.STALE_ && (e.lowestObserverState_ = w.STALE_, e.observers_.forEach(function(t) {
    t.dependenciesState_ === w.UP_TO_DATE_ && (process.env.NODE_ENV !== "production" && t.isTracing_ !== K.NONE && qi(t, e), t.onBecomeStale_()), t.dependenciesState_ = w.STALE_;
  }));
}
function rs(e) {
  e.lowestObserverState_ !== w.STALE_ && (e.lowestObserverState_ = w.STALE_, e.observers_.forEach(function(t) {
    t.dependenciesState_ === w.POSSIBLY_STALE_ ? (t.dependenciesState_ = w.STALE_, process.env.NODE_ENV !== "production" && t.isTracing_ !== K.NONE && qi(t, e)) : t.dependenciesState_ === w.UP_TO_DATE_ && (e.lowestObserverState_ = w.UP_TO_DATE_);
  }));
}
function ns(e) {
  e.lowestObserverState_ === w.UP_TO_DATE_ && (e.lowestObserverState_ = w.POSSIBLY_STALE_, e.observers_.forEach(function(t) {
    t.dependenciesState_ === w.UP_TO_DATE_ && (t.dependenciesState_ = w.POSSIBLY_STALE_, t.onBecomeStale_());
  }));
}
function qi(e, t) {
  if (console.log("[mobx.trace] '" + e.name_ + "' is invalidated due to a change in: '" + t.name_ + "'"), e.isTracing_ === K.BREAK) {
    var r = [];
    Ki(bs(e), r, 1), new Function(`debugger;
/*
Tracing '` + e.name_ + `'

You are entering this break point because derivation '` + e.name_ + "' is being traced and '" + t.name_ + `' is now forcing it to update.
Just follow the stacktrace you should now see in the devtools to see precisely what piece of your code is causing this update
The stackframe you are looking for is at least ~6-8 stack-frames up.

` + (e instanceof B ? e.derivation.toString().replace(/[*]\//g, "/") : "") + `

The dependencies for this derivation are:

` + r.join(`
`) + `
*/
    `)();
  }
}
function Ki(e, t, r) {
  if (t.length >= 1e3) {
    t.push("(and many more)");
    return;
  }
  t.push("" + "	".repeat(r - 1) + e.name), e.dependencies && e.dependencies.forEach(function(n) {
    return Ki(n, t, r + 1);
  });
}
var ee = /* @__PURE__ */ function() {
  function e(r, n, i, a) {
    r === void 0 && (r = process.env.NODE_ENV !== "production" ? "Reaction@" + F() : "Reaction"), this.name_ = void 0, this.onInvalidate_ = void 0, this.errorHandler_ = void 0, this.requiresObservable_ = void 0, this.observing_ = [], this.newObserving_ = [], this.dependenciesState_ = w.NOT_TRACKING_, this.runId_ = 0, this.unboundDepsCount_ = 0, this.flags_ = 0, this.isTracing_ = K.NONE, this.name_ = r, this.onInvalidate_ = n, this.errorHandler_ = i, this.requiresObservable_ = a;
  }
  var t = e.prototype;
  return t.onBecomeStale_ = function() {
    this.schedule_();
  }, t.schedule_ = function() {
    this.isScheduled || (this.isScheduled = !0, p.pendingReactions.push(this), Bi());
  }, t.runReaction_ = function() {
    if (!this.isDisposed) {
      R(), this.isScheduled = !1;
      var n = p.trackingContext;
      if (p.trackingContext = this, Lr(this)) {
        this.isTrackPending = !0;
        try {
          this.onInvalidate_(), process.env.NODE_ENV !== "production" && this.isTrackPending && P() && Te({
            name: this.name_,
            type: "scheduled-reaction"
          });
        } catch (i) {
          this.reportExceptionInDerivation_(i);
        }
      }
      p.trackingContext = n, q();
    }
  }, t.track = function(n) {
    if (!this.isDisposed) {
      R();
      var i = P(), a;
      process.env.NODE_ENV !== "production" && i && (a = Date.now(), I({
        name: this.name_,
        type: "reaction"
      })), this.isRunning = !0;
      var o = p.trackingContext;
      p.trackingContext = this;
      var s = Ii(this, n, void 0);
      p.trackingContext = o, this.isRunning = !1, this.isTrackPending = !1, this.isDisposed && Mr(this), Kt(s) && this.reportExceptionInDerivation_(s.cause), process.env.NODE_ENV !== "production" && i && z({
        time: Date.now() - a
      }), q();
    }
  }, t.reportExceptionInDerivation_ = function(n) {
    var i = this;
    if (this.errorHandler_) {
      this.errorHandler_(n, this);
      return;
    }
    if (p.disableErrorBoundaries)
      throw n;
    var a = process.env.NODE_ENV !== "production" ? "[mobx] Encountered an uncaught exception that was thrown by a reaction or observer component, in: '" + this + "'" : "[mobx] uncaught error in '" + this + "'";
    p.suppressReactionErrors ? process.env.NODE_ENV !== "production" && console.warn("[mobx] (error in reaction '" + this.name_ + "' suppressed, fix error of causing action below)") : console.error(a, n), process.env.NODE_ENV !== "production" && P() && Te({
      type: "error",
      name: this.name_,
      message: a,
      error: "" + n
    }), p.globalReactionErrorHandlers.forEach(function(o) {
      return o(n, i);
    });
  }, t.dispose = function() {
    this.isDisposed || (this.isDisposed = !0, this.isRunning || (R(), Mr(this), q()));
  }, t.getDisposer_ = function(n) {
    var i = this, a = function o() {
      i.dispose(), n == null || n.removeEventListener == null || n.removeEventListener("abort", o);
    };
    return n == null || n.addEventListener == null || n.addEventListener("abort", a), a[g] = this, "dispose" in Symbol && typeof Symbol.dispose == "symbol" && (a[Symbol.dispose] = a), a;
  }, t.toString = function() {
    return "Reaction[" + this.name_ + "]";
  }, t.trace = function(n) {
    n === void 0 && (n = !1), Es(this, n);
  }, _e(e, [{
    key: "isDisposed",
    get: function() {
      return T(this.flags_, e.isDisposedMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isDisposedMask_, n);
    }
  }, {
    key: "isScheduled",
    get: function() {
      return T(this.flags_, e.isScheduledMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isScheduledMask_, n);
    }
  }, {
    key: "isTrackPending",
    get: function() {
      return T(this.flags_, e.isTrackPendingMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isTrackPendingMask_, n);
    }
  }, {
    key: "isRunning",
    get: function() {
      return T(this.flags_, e.isRunningMask_);
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.isRunningMask_, n);
    }
  }, {
    key: "diffValue",
    get: function() {
      return T(this.flags_, e.diffValueMask_) ? 1 : 0;
    },
    set: function(n) {
      this.flags_ = V(this.flags_, e.diffValueMask_, n === 1);
    }
  }]);
}();
ee.isDisposedMask_ = 1;
ee.isScheduledMask_ = 2;
ee.isTrackPendingMask_ = 4;
ee.isRunningMask_ = 8;
ee.diffValueMask_ = 16;
function is(e) {
  return p.globalReactionErrorHandlers.push(e), function() {
    var t = p.globalReactionErrorHandlers.indexOf(e);
    t >= 0 && p.globalReactionErrorHandlers.splice(t, 1);
  };
}
var gn = 100, as = function(t) {
  return t();
};
function Bi() {
  p.inBatch > 0 || p.isRunningReactions || as(os);
}
function os() {
  p.isRunningReactions = !0;
  for (var e = p.pendingReactions, t = 0; e.length > 0; ) {
    ++t === gn && (console.error(process.env.NODE_ENV !== "production" ? "Reaction doesn't converge to a stable state after " + gn + " iterations." + (" Probably there is a cycle in the reactive function: " + e[0]) : "[mobx] cycle in reaction: " + e[0]), e.splice(0));
    for (var r = e.splice(0), n = 0, i = r.length; n < i; n++)
      r[n].runReaction_();
  }
  p.isRunningReactions = !1;
}
var Qt = /* @__PURE__ */ Ue("Reaction", ee);
function P() {
  return process.env.NODE_ENV !== "production" && !!p.spyListeners.length;
}
function Te(e) {
  if (process.env.NODE_ENV !== "production" && p.spyListeners.length)
    for (var t = p.spyListeners, r = 0, n = t.length; r < n; r++)
      t[r](e);
}
function I(e) {
  if (process.env.NODE_ENV !== "production") {
    var t = ve({}, e, {
      spyReportStart: !0
    });
    Te(t);
  }
}
var ss = {
  type: "report-end",
  spyReportEnd: !0
};
function z(e) {
  process.env.NODE_ENV !== "production" && Te(e ? ve({}, e, {
    type: "report-end",
    spyReportEnd: !0
  }) : ss);
}
function ls(e) {
  return process.env.NODE_ENV === "production" ? (console.warn("[mobx.spy] Is a no-op in production builds"), function() {
  }) : (p.spyListeners.push(e), Jr(function() {
    p.spyListeners = p.spyListeners.filter(function(t) {
      return t !== e;
    });
  }));
}
var _r = "action", cs = "action.bound", Fi = "autoAction", ds = "autoAction.bound", Zi = "<unnamed action>", jr = /* @__PURE__ */ St(_r), us = /* @__PURE__ */ St(cs, {
  bound: !0
}), Rr = /* @__PURE__ */ St(Fi, {
  autoAction: !0
}), ps = /* @__PURE__ */ St(ds, {
  autoAction: !0,
  bound: !0
});
function Wi(e) {
  var t = function(n, i) {
    if (k(n))
      return Ne(n.name || Zi, n, e);
    if (k(i))
      return Ne(n, i, e);
    if (At(i))
      return (e ? Rr : jr).decorate_20223_(n, i);
    if (Pe(i))
      return Ct(n, i, e ? Rr : jr);
    if (Pe(n))
      return $(St(e ? Fi : _r, {
        name: n,
        autoAction: e
      }));
    process.env.NODE_ENV !== "production" && f("Invalid arguments for `action`");
  };
  return t;
}
var Ce = /* @__PURE__ */ Wi(!1);
Object.assign(Ce, jr);
var bt = /* @__PURE__ */ Wi(!0);
Object.assign(bt, Rr);
Ce.bound = /* @__PURE__ */ $(us);
bt.bound = /* @__PURE__ */ $(ps);
function Nd(e) {
  return Vi(e.name || Zi, !1, e, this, void 0);
}
function Ve(e) {
  return k(e) && e.isMobxAction === !0;
}
function Hi(e, t) {
  var r, n, i, a;
  t === void 0 && (t = Xr), process.env.NODE_ENV !== "production" && (k(e) || f("Autorun expects a function as first argument"), Ve(e) && f("Autorun does not accept actions since actions are untrackable"));
  var o = (r = (n = t) == null ? void 0 : n.name) != null ? r : process.env.NODE_ENV !== "production" ? e.name || "Autorun@" + F() : "Autorun", s = !t.scheduler && !t.delay, l;
  if (s)
    l = new ee(o, function() {
      this.track(u);
    }, t.onError, t.requiresObservable);
  else {
    var c = Xi(t), d = !1;
    l = new ee(o, function() {
      d || (d = !0, c(function() {
        d = !1, l.isDisposed || l.track(u);
      }));
    }, t.onError, t.requiresObservable);
  }
  function u() {
    e(l);
  }
  return (i = t) != null && (i = i.signal) != null && i.aborted || l.schedule_(), l.getDisposer_((a = t) == null ? void 0 : a.signal);
}
var fs = function(t) {
  return t();
};
function Xi(e) {
  return e.scheduler ? e.scheduler : e.delay ? function(t) {
    return setTimeout(t, e.delay);
  } : fs;
}
function $r(e, t, r) {
  var n, i, a;
  r === void 0 && (r = Xr), process.env.NODE_ENV !== "production" && ((!k(e) || !k(t)) && f("First and second argument to reaction should be functions"), D(r) || f("Third argument of reactions should be an object"));
  var o = (n = r.name) != null ? n : process.env.NODE_ENV !== "production" ? "Reaction@" + F() : "Reaction", s = Ce(o, r.onError ? vs(r.onError, t) : t), l = !r.scheduler && !r.delay, c = Xi(r), d = !0, u = !1, v, h = r.compareStructural ? Xe.structural : r.equals || Xe.default, m = new ee(o, function() {
    d || l ? O() : u || (u = !0, c(O));
  }, r.onError, r.requiresObservable);
  function O() {
    if (u = !1, !m.isDisposed) {
      var A = !1, G = v;
      m.track(function() {
        var je = Yo(!1, function() {
          return e(m);
        });
        A = d || !h(v, je), v = je;
      }), (d && r.fireImmediately || !d && A) && s(v, G, m), d = !1;
    }
  }
  return (i = r) != null && (i = i.signal) != null && i.aborted || m.schedule_(), m.getDisposer_((a = r) == null ? void 0 : a.signal);
}
function vs(e, t) {
  return function() {
    try {
      return t.apply(this, arguments);
    } catch (r) {
      e.call(this, r);
    }
  };
}
var hs = "onBO", gs = "onBUO";
function ms(e, t, r) {
  return Gi(hs, e, t, r);
}
function Ji(e, t, r) {
  return Gi(gs, e, t, r);
}
function Gi(e, t, r, n) {
  var i = Ge(t), a = k(n) ? n : r, o = e + "L";
  return i[o] ? i[o].add(a) : i[o] = /* @__PURE__ */ new Set([a]), function() {
    var s = i[o];
    s && (s.delete(a), s.size === 0 && delete i[o]);
  };
}
function Yi(e, t, r, n) {
  process.env.NODE_ENV !== "production" && (arguments.length > 4 && f("'extendObservable' expected 2-4 arguments"), typeof e != "object" && f("'extendObservable' expects an object as first argument"), be(e) && f("'extendObservable' should not be used on maps, use map.merge instead"), D(t) || f("'extendObservable' only accepts plain objects as second argument"), (wt(t) || wt(r)) && f("Extending an object with another observable (object) is not supported"));
  var i = to(t);
  return Me(function() {
    var a = et(e, n)[g];
    mt(i).forEach(function(o) {
      a.extend_(
        o,
        i[o],
        // must pass "undefined" for { key: undefined }
        r && o in r ? r[o] : !0
      );
    });
  }), e;
}
function bs(e, t) {
  return Qi(Ge(e, t));
}
function Qi(e) {
  var t = {
    name: e.name_
  };
  return e.observing_ && e.observing_.length > 0 && (t.dependencies = ys(e.observing_).map(Qi)), t;
}
function ys(e) {
  return Array.from(new Set(e));
}
var ws = 0;
function _i() {
  this.message = "FLOW_CANCELLED";
}
_i.prototype = /* @__PURE__ */ Object.create(Error.prototype);
var kr = /* @__PURE__ */ Ci("flow"), xs = /* @__PURE__ */ Ci("flow.bound", {
  bound: !0
}), Je = /* @__PURE__ */ Object.assign(function(t, r) {
  if (At(r))
    return kr.decorate_20223_(t, r);
  if (Pe(r))
    return Ct(t, r, kr);
  process.env.NODE_ENV !== "production" && arguments.length !== 1 && f("Flow expects single argument with generator function");
  var n = t, i = n.name || "<unnamed flow>", a = function() {
    var s = this, l = arguments, c = ++ws, d = Ce(i + " - runid: " + c + " - init", n).apply(s, l), u, v = void 0, h = new Promise(function(m, O) {
      var A = 0;
      u = O;
      function G(N) {
        v = void 0;
        var de;
        try {
          de = Ce(i + " - runid: " + c + " - yield " + A++, d.next).call(d, N);
        } catch (we) {
          return O(we);
        }
        it(de);
      }
      function je(N) {
        v = void 0;
        var de;
        try {
          de = Ce(i + " - runid: " + c + " - yield " + A++, d.throw).call(d, N);
        } catch (we) {
          return O(we);
        }
        it(de);
      }
      function it(N) {
        if (k(N?.then)) {
          N.then(it, O);
          return;
        }
        return N.done ? m(N.value) : (v = Promise.resolve(N.value), v.then(G, je));
      }
      G(void 0);
    });
    return h.cancel = Ce(i + " - runid: " + c + " - cancel", function() {
      try {
        v && mn(v);
        var m = d.return(void 0), O = Promise.resolve(m.value);
        O.then(Fe, Fe), mn(O), u(new _i());
      } catch (A) {
        u(A);
      }
    }), h;
  };
  return a.isMobXFlow = !0, a;
}, kr);
Je.bound = /* @__PURE__ */ $(xs);
function mn(e) {
  k(e.cancel) && e.cancel();
}
function yt(e) {
  return e?.isMobXFlow === !0;
}
function Os(e, t) {
  return e ? tt(e) || !!e[g] || Gr(e) || Qt(e) || mr(e) : !1;
}
function wt(e) {
  return process.env.NODE_ENV !== "production" && arguments.length !== 1 && f("isObservable expects only 1 argument. Use isObservableProp to inspect the observability of a property"), Os(e);
}
function Es() {
  if (process.env.NODE_ENV !== "production") {
    for (var e = !1, t = arguments.length, r = new Array(t), n = 0; n < t; n++)
      r[n] = arguments[n];
    typeof r[r.length - 1] == "boolean" && (e = r.pop());
    var i = ks(r);
    if (!i)
      return f("'trace(break?)' can only be used inside a tracked computed value or a Reaction. Consider passing in the computed value or reaction explicitly");
    i.isTracing_ === K.NONE && console.log("[mobx.trace] '" + i.name_ + "' tracing enabled"), i.isTracing_ = e ? K.BREAK : K.LOG;
  }
}
function ks(e) {
  switch (e.length) {
    case 0:
      return p.trackingDerivation;
    case 1:
      return Ge(e[0]);
    case 2:
      return Ge(e[0], e[1]);
  }
}
function ae(e, t) {
  t === void 0 && (t = void 0), R();
  try {
    return e.apply(t);
  } finally {
    q();
  }
}
function xe(e) {
  return e[g];
}
var Cs = {
  has: function(t, r) {
    return process.env.NODE_ENV !== "production" && p.trackingDerivation && at("detect new properties using the 'in' operator. Use 'has' from 'mobx' instead."), xe(t).has_(r);
  },
  get: function(t, r) {
    return xe(t).get_(r);
  },
  set: function(t, r, n) {
    var i;
    return Pe(r) ? (process.env.NODE_ENV !== "production" && !xe(t).values_.has(r) && at("add a new observable property through direct assignment. Use 'set' from 'mobx' instead."), (i = xe(t).set_(r, n, !0)) != null ? i : !0) : !1;
  },
  deleteProperty: function(t, r) {
    var n;
    return process.env.NODE_ENV !== "production" && at("delete properties from an observable object. Use 'remove' from 'mobx' instead."), Pe(r) ? (n = xe(t).delete_(r, !0)) != null ? n : !0 : !1;
  },
  defineProperty: function(t, r, n) {
    var i;
    return process.env.NODE_ENV !== "production" && at("define property on an observable object. Use 'defineProperty' from 'mobx' instead."), (i = xe(t).defineProperty_(r, n)) != null ? i : !0;
  },
  ownKeys: function(t) {
    return process.env.NODE_ENV !== "production" && p.trackingDerivation && at("iterate keys to detect added / removed properties. Use 'keys' from 'mobx' instead."), xe(t).ownKeys_();
  },
  preventExtensions: function(t) {
    f(13);
  }
};
function As(e, t) {
  var r, n;
  return mi(), e = et(e, t), (n = (r = e[g]).proxy_) != null ? n : r.proxy_ = new Proxy(e, Cs);
}
function M(e) {
  return e.interceptors_ !== void 0 && e.interceptors_.length > 0;
}
function Pt(e, t) {
  var r = e.interceptors_ || (e.interceptors_ = []);
  return r.push(t), Jr(function() {
    var n = r.indexOf(t);
    n !== -1 && r.splice(n, 1);
  });
}
function j(e, t) {
  var r = Le();
  try {
    for (var n = [].concat(e.interceptors_ || []), i = 0, a = n.length; i < a && (t = n[i](t), t && !t.type && f(14), !!t); i++)
      ;
    return t;
  } finally {
    oe(r);
  }
}
function H(e) {
  return e.changeListeners_ !== void 0 && e.changeListeners_.length > 0;
}
function Dt(e, t) {
  var r = e.changeListeners_ || (e.changeListeners_ = []);
  return r.push(t), Jr(function() {
    var n = r.indexOf(t);
    n !== -1 && r.splice(n, 1);
  });
}
function X(e, t) {
  var r = Le(), n = e.changeListeners_;
  if (n) {
    n = n.slice();
    for (var i = 0, a = n.length; i < a; i++)
      n[i](t);
    oe(r);
  }
}
var Cr = /* @__PURE__ */ Symbol("mobx-keys");
function $e(e, t, r) {
  return process.env.NODE_ENV !== "production" && (!D(e) && !D(Object.getPrototypeOf(e)) && f("'makeAutoObservable' can only be used for classes that don't have a superclass"), tt(e) && f("makeAutoObservable can only be used on objects not already made observable")), D(e) ? Yi(e, e, t, r) : (Me(function() {
    var n = et(e, r)[g];
    if (!e[Cr]) {
      var i = Object.getPrototypeOf(e), a = new Set([].concat(mt(e), mt(i)));
      a.delete("constructor"), a.delete(g), dr(i, Cr, a);
    }
    e[Cr].forEach(function(o) {
      return n.make_(
        o,
        // must pass "undefined" for { key: undefined }
        t && o in t ? t[o] : !0
      );
    });
  }), e);
}
var bn = "splice", Z = "update", Ss = 1e4, Ps = {
  get: function(t, r) {
    var n = t[g];
    return r === g ? n : r === "length" ? n.getArrayLength_() : typeof r == "string" && !isNaN(r) ? n.get_(parseInt(r)) : W(_t, r) ? _t[r] : t[r];
  },
  set: function(t, r, n) {
    var i = t[g];
    return r === "length" && i.setArrayLength_(n), typeof r == "symbol" || isNaN(r) ? t[r] = n : i.set_(parseInt(r), n), !0;
  },
  preventExtensions: function() {
    f(15);
  }
}, en = /* @__PURE__ */ function() {
  function e(r, n, i, a) {
    r === void 0 && (r = process.env.NODE_ENV !== "production" ? "ObservableArray@" + F() : "ObservableArray"), this.owned_ = void 0, this.legacyMode_ = void 0, this.atom_ = void 0, this.values_ = [], this.interceptors_ = void 0, this.changeListeners_ = void 0, this.enhancer_ = void 0, this.dehancer = void 0, this.proxy_ = void 0, this.lastKnownLength_ = 0, this.owned_ = i, this.legacyMode_ = a, this.atom_ = new me(r), this.enhancer_ = function(o, s) {
      return n(o, s, process.env.NODE_ENV !== "production" ? r + "[..]" : "ObservableArray[..]");
    };
  }
  var t = e.prototype;
  return t.dehanceValue_ = function(n) {
    return this.dehancer !== void 0 ? this.dehancer(n) : n;
  }, t.dehanceValues_ = function(n) {
    return this.dehancer !== void 0 && n.length > 0 ? n.map(this.dehancer) : n;
  }, t.intercept_ = function(n) {
    return Pt(this, n);
  }, t.observe_ = function(n, i) {
    return i === void 0 && (i = !1), i && n({
      observableKind: "array",
      object: this.proxy_,
      debugObjectName: this.atom_.name_,
      type: "splice",
      index: 0,
      added: this.values_.slice(),
      addedCount: this.values_.length,
      removed: [],
      removedCount: 0
    }), Dt(this, n);
  }, t.getArrayLength_ = function() {
    return this.atom_.reportObserved(), this.values_.length;
  }, t.setArrayLength_ = function(n) {
    (typeof n != "number" || isNaN(n) || n < 0) && f("Out of range: " + n);
    var i = this.values_.length;
    if (n !== i)
      if (n > i) {
        for (var a = new Array(n - i), o = 0; o < n - i; o++)
          a[o] = void 0;
        this.spliceWithArray_(i, 0, a);
      } else
        this.spliceWithArray_(n, i - n);
  }, t.updateArrayLength_ = function(n, i) {
    n !== this.lastKnownLength_ && f(16), this.lastKnownLength_ += i, this.legacyMode_ && i > 0 && ia(n + i + 1);
  }, t.spliceWithArray_ = function(n, i, a) {
    var o = this;
    Q(this.atom_);
    var s = this.values_.length;
    if (n === void 0 ? n = 0 : n > s ? n = s : n < 0 && (n = Math.max(0, s + n)), arguments.length === 1 ? i = s - n : i == null ? i = 0 : i = Math.max(0, Math.min(i, s - n)), a === void 0 && (a = Xt), M(this)) {
      var l = j(this, {
        object: this.proxy_,
        type: bn,
        index: n,
        removedCount: i,
        added: a
      });
      if (!l)
        return Xt;
      i = l.removedCount, a = l.added;
    }
    if (a = a.length === 0 ? a : a.map(function(u) {
      return o.enhancer_(u, void 0);
    }), this.legacyMode_ || process.env.NODE_ENV !== "production") {
      var c = a.length - i;
      this.updateArrayLength_(s, c);
    }
    var d = this.spliceItemsIntoValues_(n, i, a);
    return (i !== 0 || a.length !== 0) && this.notifyArraySplice_(n, a, d), this.dehanceValues_(d);
  }, t.spliceItemsIntoValues_ = function(n, i, a) {
    if (a.length < Ss) {
      var o;
      return (o = this.values_).splice.apply(o, [n, i].concat(a));
    } else {
      var s = this.values_.slice(n, n + i), l = this.values_.slice(n + i);
      this.values_.length += a.length - i;
      for (var c = 0; c < a.length; c++)
        this.values_[n + c] = a[c];
      for (var d = 0; d < l.length; d++)
        this.values_[n + a.length + d] = l[d];
      return s;
    }
  }, t.notifyArrayChildUpdate_ = function(n, i, a) {
    var o = !this.owned_ && P(), s = H(this), l = s || o ? {
      observableKind: "array",
      object: this.proxy_,
      type: Z,
      debugObjectName: this.atom_.name_,
      index: n,
      newValue: i,
      oldValue: a
    } : null;
    process.env.NODE_ENV !== "production" && o && I(l), this.atom_.reportChanged(), s && X(this, l), process.env.NODE_ENV !== "production" && o && z();
  }, t.notifyArraySplice_ = function(n, i, a) {
    var o = !this.owned_ && P(), s = H(this), l = s || o ? {
      observableKind: "array",
      object: this.proxy_,
      debugObjectName: this.atom_.name_,
      type: bn,
      index: n,
      removed: a,
      added: i,
      removedCount: a.length,
      addedCount: i.length
    } : null;
    process.env.NODE_ENV !== "production" && o && I(l), this.atom_.reportChanged(), s && X(this, l), process.env.NODE_ENV !== "production" && o && z();
  }, t.get_ = function(n) {
    if (this.legacyMode_ && n >= this.values_.length) {
      console.warn(process.env.NODE_ENV !== "production" ? "[mobx.array] Attempt to read an array index (" + n + ") that is out of bounds (" + this.values_.length + "). Please check length first. Out of bound indices will not be tracked by MobX" : "[mobx] Out of bounds read: " + n);
      return;
    }
    return this.atom_.reportObserved(), this.dehanceValue_(this.values_[n]);
  }, t.set_ = function(n, i) {
    var a = this.values_;
    if (this.legacyMode_ && n > a.length && f(17, n, a.length), n < a.length) {
      Q(this.atom_);
      var o = a[n];
      if (M(this)) {
        var s = j(this, {
          type: Z,
          object: this.proxy_,
          // since "this" is the real array we need to pass its proxy
          index: n,
          newValue: i
        });
        if (!s)
          return;
        i = s.newValue;
      }
      i = this.enhancer_(i, o);
      var l = i !== o;
      l && (a[n] = i, this.notifyArrayChildUpdate_(n, i, o));
    } else {
      for (var c = new Array(n + 1 - a.length), d = 0; d < c.length - 1; d++)
        c[d] = void 0;
      c[c.length - 1] = i, this.spliceWithArray_(a.length, 0, c);
    }
  }, e;
}();
function Ds(e, t, r, n) {
  return r === void 0 && (r = process.env.NODE_ENV !== "production" ? "ObservableArray@" + F() : "ObservableArray"), n === void 0 && (n = !1), mi(), Me(function() {
    var i = new en(r, t, n, !1);
    yi(i.values_, g, i);
    var a = new Proxy(i.values_, Ps);
    return i.proxy_ = a, e && e.length && i.spliceWithArray_(0, 0, e), a;
  });
}
var _t = {
  clear: function() {
    return this.splice(0);
  },
  replace: function(t) {
    var r = this[g];
    return r.spliceWithArray_(0, r.values_.length, t);
  },
  // Used by JSON.stringify
  toJSON: function() {
    return this.slice();
  },
  /*
   * functions that do alter the internal structure of the array, (based on lib.es6.d.ts)
   * since these functions alter the inner structure of the array, the have side effects.
   * Because the have side effects, they should not be used in computed function,
   * and for that reason the do not call dependencyState.notifyObserved
   */
  splice: function(t, r) {
    for (var n = arguments.length, i = new Array(n > 2 ? n - 2 : 0), a = 2; a < n; a++)
      i[a - 2] = arguments[a];
    var o = this[g];
    switch (arguments.length) {
      case 0:
        return [];
      case 1:
        return o.spliceWithArray_(t);
      case 2:
        return o.spliceWithArray_(t, r);
    }
    return o.spliceWithArray_(t, r, i);
  },
  spliceWithArray: function(t, r, n) {
    return this[g].spliceWithArray_(t, r, n);
  },
  push: function() {
    for (var t = this[g], r = arguments.length, n = new Array(r), i = 0; i < r; i++)
      n[i] = arguments[i];
    return t.spliceWithArray_(t.values_.length, 0, n), t.values_.length;
  },
  pop: function() {
    return this.splice(Math.max(this[g].values_.length - 1, 0), 1)[0];
  },
  shift: function() {
    return this.splice(0, 1)[0];
  },
  unshift: function() {
    for (var t = this[g], r = arguments.length, n = new Array(r), i = 0; i < r; i++)
      n[i] = arguments[i];
    return t.spliceWithArray_(0, 0, n), t.values_.length;
  },
  reverse: function() {
    return p.trackingDerivation && f(37, "reverse"), this.replace(this.slice().reverse()), this;
  },
  sort: function() {
    p.trackingDerivation && f(37, "sort");
    var t = this.slice();
    return t.sort.apply(t, arguments), this.replace(t), this;
  },
  remove: function(t) {
    var r = this[g], n = r.dehanceValues_(r.values_).indexOf(t);
    return n > -1 ? (this.splice(n, 1), !0) : !1;
  }
};
x("at", U);
x("concat", U);
x("flat", U);
x("includes", U);
x("indexOf", U);
x("join", U);
x("lastIndexOf", U);
x("slice", U);
x("toString", U);
x("toLocaleString", U);
x("toSorted", U);
x("toSpliced", U);
x("with", U);
x("every", J);
x("filter", J);
x("find", J);
x("findIndex", J);
x("findLast", J);
x("findLastIndex", J);
x("flatMap", J);
x("forEach", J);
x("map", J);
x("some", J);
x("toReversed", J);
x("reduce", $i);
x("reduceRight", $i);
function x(e, t) {
  typeof Array.prototype[e] == "function" && (_t[e] = t(e));
}
function U(e) {
  return function() {
    var t = this[g];
    t.atom_.reportObserved();
    var r = t.dehanceValues_(t.values_);
    return r[e].apply(r, arguments);
  };
}
function J(e) {
  return function(t, r) {
    var n = this, i = this[g];
    i.atom_.reportObserved();
    var a = i.dehanceValues_(i.values_);
    return a[e](function(o, s) {
      return t.call(r, o, s, n);
    });
  };
}
function $i(e) {
  return function() {
    var t = this, r = this[g];
    r.atom_.reportObserved();
    var n = r.dehanceValues_(r.values_), i = arguments[0];
    return arguments[0] = function(a, o, s) {
      return i(a, o, s, t);
    }, n[e].apply(n, arguments);
  };
}
var Ns = /* @__PURE__ */ Ue("ObservableArrayAdministration", en);
function br(e) {
  return cr(e) && Ns(e[g]);
}
var Ts = {}, pe = "add", $t = "delete", ea = /* @__PURE__ */ function() {
  function e(r, n, i) {
    var a = this;
    n === void 0 && (n = De), i === void 0 && (i = process.env.NODE_ENV !== "production" ? "ObservableMap@" + F() : "ObservableMap"), this.enhancer_ = void 0, this.name_ = void 0, this[g] = Ts, this.data_ = void 0, this.hasMap_ = void 0, this.keysAtom_ = void 0, this.interceptors_ = void 0, this.changeListeners_ = void 0, this.dehancer = void 0, this.enhancer_ = n, this.name_ = i, k(Map) || f(18), Me(function() {
      a.keysAtom_ = Ei(process.env.NODE_ENV !== "production" ? a.name_ + ".keys()" : "ObservableMap.keys()"), a.data_ = /* @__PURE__ */ new Map(), a.hasMap_ = /* @__PURE__ */ new Map(), r && a.merge(r);
    });
  }
  var t = e.prototype;
  return t.has_ = function(n) {
    return this.data_.has(n);
  }, t.has = function(n) {
    var i = this;
    if (!p.trackingDerivation)
      return this.has_(n);
    var a = this.hasMap_.get(n);
    if (!a) {
      var o = a = new Se(this.has_(n), pr, process.env.NODE_ENV !== "production" ? this.name_ + "." + Vr(n) + "?" : "ObservableMap.key?", !1);
      this.hasMap_.set(n, o), Ji(o, function() {
        return i.hasMap_.delete(n);
      });
    }
    return a.get();
  }, t.set = function(n, i) {
    var a = this.has_(n);
    if (M(this)) {
      var o = j(this, {
        type: a ? Z : pe,
        object: this,
        newValue: i,
        name: n
      });
      if (!o)
        return this;
      i = o.newValue;
    }
    return a ? this.updateValue_(n, i) : this.addValue_(n, i), this;
  }, t.delete = function(n) {
    var i = this;
    if (Q(this.keysAtom_), M(this)) {
      var a = j(this, {
        type: $t,
        object: this,
        name: n
      });
      if (!a)
        return !1;
    }
    if (this.has_(n)) {
      var o = P(), s = H(this), l = s || o ? {
        observableKind: "map",
        debugObjectName: this.name_,
        type: $t,
        object: this,
        oldValue: this.data_.get(n).value_,
        name: n
      } : null;
      return process.env.NODE_ENV !== "production" && o && I(l), ae(function() {
        var c;
        i.keysAtom_.reportChanged(), (c = i.hasMap_.get(n)) == null || c.setNewValue_(!1);
        var d = i.data_.get(n);
        d.setNewValue_(void 0), i.data_.delete(n);
      }), s && X(this, l), process.env.NODE_ENV !== "production" && o && z(), !0;
    }
    return !1;
  }, t.updateValue_ = function(n, i) {
    var a = this.data_.get(n);
    if (i = a.prepareNewValue_(i), i !== p.UNCHANGED) {
      var o = P(), s = H(this), l = s || o ? {
        observableKind: "map",
        debugObjectName: this.name_,
        type: Z,
        object: this,
        oldValue: a.value_,
        name: n,
        newValue: i
      } : null;
      process.env.NODE_ENV !== "production" && o && I(l), a.setNewValue_(i), s && X(this, l), process.env.NODE_ENV !== "production" && o && z();
    }
  }, t.addValue_ = function(n, i) {
    var a = this;
    Q(this.keysAtom_), ae(function() {
      var c, d = new Se(i, a.enhancer_, process.env.NODE_ENV !== "production" ? a.name_ + "." + Vr(n) : "ObservableMap.key", !1);
      a.data_.set(n, d), i = d.value_, (c = a.hasMap_.get(n)) == null || c.setNewValue_(!0), a.keysAtom_.reportChanged();
    });
    var o = P(), s = H(this), l = s || o ? {
      observableKind: "map",
      debugObjectName: this.name_,
      type: pe,
      object: this,
      name: n,
      newValue: i
    } : null;
    process.env.NODE_ENV !== "production" && o && I(l), s && X(this, l), process.env.NODE_ENV !== "production" && o && z();
  }, t.get = function(n) {
    return this.has(n) ? this.dehanceValue_(this.data_.get(n).get()) : this.dehanceValue_(void 0);
  }, t.dehanceValue_ = function(n) {
    return this.dehancer !== void 0 ? this.dehancer(n) : n;
  }, t.keys = function() {
    return this.keysAtom_.reportObserved(), this.data_.keys();
  }, t.values = function() {
    var n = this, i = this.keys();
    return yn({
      next: function() {
        var o = i.next(), s = o.done, l = o.value;
        return {
          done: s,
          value: s ? void 0 : n.get(l)
        };
      }
    });
  }, t.entries = function() {
    var n = this, i = this.keys();
    return yn({
      next: function() {
        var o = i.next(), s = o.done, l = o.value;
        return {
          done: s,
          value: s ? void 0 : [l, n.get(l)]
        };
      }
    });
  }, t[Symbol.iterator] = function() {
    return this.entries();
  }, t.forEach = function(n, i) {
    for (var a = Ze(this), o; !(o = a()).done; ) {
      var s = o.value, l = s[0], c = s[1];
      n.call(i, c, l, this);
    }
  }, t.merge = function(n) {
    var i = this;
    return be(n) && (n = new Map(n)), ae(function() {
      D(n) ? eo(n).forEach(function(a) {
        return i.set(a, n[a]);
      }) : Array.isArray(n) ? n.forEach(function(a) {
        var o = a[0], s = a[1];
        return i.set(o, s);
      }) : Qe(n) ? ($a(n) || f(19, n), n.forEach(function(a, o) {
        return i.set(o, a);
      })) : n != null && f(20, n);
    }), this;
  }, t.clear = function() {
    var n = this;
    ae(function() {
      zi(function() {
        for (var i = Ze(n.keys()), a; !(a = i()).done; ) {
          var o = a.value;
          n.delete(o);
        }
      });
    });
  }, t.replace = function(n) {
    var i = this;
    return ae(function() {
      for (var a = Vs(n), o = /* @__PURE__ */ new Map(), s = !1, l = Ze(i.data_.keys()), c; !(c = l()).done; ) {
        var d = c.value;
        if (!a.has(d)) {
          var u = i.delete(d);
          if (u)
            s = !0;
          else {
            var v = i.data_.get(d);
            o.set(d, v);
          }
        }
      }
      for (var h = Ze(a.entries()), m; !(m = h()).done; ) {
        var O = m.value, A = O[0], G = O[1], je = i.data_.has(A);
        if (i.set(A, G), i.data_.has(A)) {
          var it = i.data_.get(A);
          o.set(A, it), je || (s = !0);
        }
      }
      if (!s)
        if (i.data_.size !== o.size)
          i.keysAtom_.reportChanged();
        else
          for (var N = i.data_.keys(), de = o.keys(), we = N.next(), un = de.next(); !we.done; ) {
            if (we.value !== un.value) {
              i.keysAtom_.reportChanged();
              break;
            }
            we = N.next(), un = de.next();
          }
      i.data_ = o;
    }), this;
  }, t.toString = function() {
    return "[object ObservableMap]";
  }, t.toJSON = function() {
    return Array.from(this);
  }, t.observe_ = function(n, i) {
    return process.env.NODE_ENV !== "production" && i === !0 && f("`observe` doesn't support fireImmediately=true in combination with maps."), Dt(this, n);
  }, t.intercept_ = function(n) {
    return Pt(this, n);
  }, _e(e, [{
    key: "size",
    get: function() {
      return this.keysAtom_.reportObserved(), this.data_.size;
    }
  }, {
    key: Symbol.toStringTag,
    get: function() {
      return "Map";
    }
  }]);
}(), be = /* @__PURE__ */ Ue("ObservableMap", ea);
function yn(e) {
  return e[Symbol.toStringTag] = "MapIterator", rn(e);
}
function Vs(e) {
  if (Qe(e) || be(e))
    return e;
  if (Array.isArray(e))
    return new Map(e);
  if (D(e)) {
    var t = /* @__PURE__ */ new Map();
    for (var r in e)
      t.set(r, e[r]);
    return t;
  } else
    return f(21, e);
}
var Is = {}, ta = /* @__PURE__ */ function() {
  function e(r, n, i) {
    var a = this;
    n === void 0 && (n = De), i === void 0 && (i = process.env.NODE_ENV !== "production" ? "ObservableSet@" + F() : "ObservableSet"), this.name_ = void 0, this[g] = Is, this.data_ = /* @__PURE__ */ new Set(), this.atom_ = void 0, this.changeListeners_ = void 0, this.interceptors_ = void 0, this.dehancer = void 0, this.enhancer_ = void 0, this.name_ = i, k(Set) || f(22), this.enhancer_ = function(o, s) {
      return n(o, s, i);
    }, Me(function() {
      a.atom_ = Ei(a.name_), r && a.replace(r);
    });
  }
  var t = e.prototype;
  return t.dehanceValue_ = function(n) {
    return this.dehancer !== void 0 ? this.dehancer(n) : n;
  }, t.clear = function() {
    var n = this;
    ae(function() {
      zi(function() {
        for (var i = Ze(n.data_.values()), a; !(a = i()).done; ) {
          var o = a.value;
          n.delete(o);
        }
      });
    });
  }, t.forEach = function(n, i) {
    for (var a = Ze(this), o; !(o = a()).done; ) {
      var s = o.value;
      n.call(i, s, s, this);
    }
  }, t.add = function(n) {
    var i = this;
    if (Q(this.atom_), M(this)) {
      var a = j(this, {
        type: pe,
        object: this,
        newValue: n
      });
      if (!a)
        return this;
      n = a.newValue;
    }
    if (!this.has(n)) {
      ae(function() {
        i.data_.add(i.enhancer_(n, void 0)), i.atom_.reportChanged();
      });
      var o = process.env.NODE_ENV !== "production" && P(), s = H(this), l = s || o ? {
        observableKind: "set",
        debugObjectName: this.name_,
        type: pe,
        object: this,
        newValue: n
      } : null;
      o && process.env.NODE_ENV !== "production" && I(l), s && X(this, l), o && process.env.NODE_ENV !== "production" && z();
    }
    return this;
  }, t.delete = function(n) {
    var i = this;
    if (M(this)) {
      var a = j(this, {
        type: $t,
        object: this,
        oldValue: n
      });
      if (!a)
        return !1;
    }
    if (this.has(n)) {
      var o = process.env.NODE_ENV !== "production" && P(), s = H(this), l = s || o ? {
        observableKind: "set",
        debugObjectName: this.name_,
        type: $t,
        object: this,
        oldValue: n
      } : null;
      return o && process.env.NODE_ENV !== "production" && I(l), ae(function() {
        i.atom_.reportChanged(), i.data_.delete(n);
      }), s && X(this, l), o && process.env.NODE_ENV !== "production" && z(), !0;
    }
    return !1;
  }, t.has = function(n) {
    return this.atom_.reportObserved(), this.data_.has(this.dehanceValue_(n));
  }, t.entries = function() {
    var n = this.values();
    return wn({
      next: function() {
        var a = n.next(), o = a.value, s = a.done;
        return s ? {
          value: void 0,
          done: s
        } : {
          value: [o, o],
          done: s
        };
      }
    });
  }, t.keys = function() {
    return this.values();
  }, t.values = function() {
    this.atom_.reportObserved();
    var n = this, i = this.data_.values();
    return wn({
      next: function() {
        var o = i.next(), s = o.value, l = o.done;
        return l ? {
          value: void 0,
          done: l
        } : {
          value: n.dehanceValue_(s),
          done: l
        };
      }
    });
  }, t.intersection = function(n) {
    if (ne(n) && !Y(n))
      return n.intersection(this);
    var i = new Set(this);
    return i.intersection(n);
  }, t.union = function(n) {
    if (ne(n) && !Y(n))
      return n.union(this);
    var i = new Set(this);
    return i.union(n);
  }, t.difference = function(n) {
    return new Set(this).difference(n);
  }, t.symmetricDifference = function(n) {
    if (ne(n) && !Y(n))
      return n.symmetricDifference(this);
    var i = new Set(this);
    return i.symmetricDifference(n);
  }, t.isSubsetOf = function(n) {
    return new Set(this).isSubsetOf(n);
  }, t.isSupersetOf = function(n) {
    return new Set(this).isSupersetOf(n);
  }, t.isDisjointFrom = function(n) {
    if (ne(n) && !Y(n))
      return n.isDisjointFrom(this);
    var i = new Set(this);
    return i.isDisjointFrom(n);
  }, t.replace = function(n) {
    var i = this;
    return Y(n) && (n = new Set(n)), ae(function() {
      Array.isArray(n) ? (i.clear(), n.forEach(function(a) {
        return i.add(a);
      })) : ne(n) ? (i.clear(), n.forEach(function(a) {
        return i.add(a);
      })) : n != null && f("Cannot initialize set from " + n);
    }), this;
  }, t.observe_ = function(n, i) {
    return process.env.NODE_ENV !== "production" && i === !0 && f("`observe` doesn't support fireImmediately=true in combination with sets."), Dt(this, n);
  }, t.intercept_ = function(n) {
    return Pt(this, n);
  }, t.toJSON = function() {
    return Array.from(this);
  }, t.toString = function() {
    return "[object ObservableSet]";
  }, t[Symbol.iterator] = function() {
    return this.values();
  }, _e(e, [{
    key: "size",
    get: function() {
      return this.atom_.reportObserved(), this.data_.size;
    }
  }, {
    key: Symbol.toStringTag,
    get: function() {
      return "Set";
    }
  }]);
}(), Y = /* @__PURE__ */ Ue("ObservableSet", ta);
function wn(e) {
  return e[Symbol.toStringTag] = "SetIterator", rn(e);
}
var xn = /* @__PURE__ */ Object.create(null), On = "remove", qr = /* @__PURE__ */ function() {
  function e(r, n, i, a) {
    n === void 0 && (n = /* @__PURE__ */ new Map()), a === void 0 && (a = No), this.target_ = void 0, this.values_ = void 0, this.name_ = void 0, this.defaultAnnotation_ = void 0, this.keysAtom_ = void 0, this.changeListeners_ = void 0, this.interceptors_ = void 0, this.proxy_ = void 0, this.isPlainObject_ = void 0, this.appliedAnnotations_ = void 0, this.pendingKeys_ = void 0, this.target_ = r, this.values_ = n, this.name_ = i, this.defaultAnnotation_ = a, this.keysAtom_ = new me(process.env.NODE_ENV !== "production" ? this.name_ + ".keys" : "ObservableObject.keys"), this.isPlainObject_ = D(this.target_), process.env.NODE_ENV !== "production" && !sa(this.defaultAnnotation_) && f("defaultAnnotation must be valid annotation"), process.env.NODE_ENV !== "production" && (this.appliedAnnotations_ = {});
  }
  var t = e.prototype;
  return t.getObservablePropValue_ = function(n) {
    return this.values_.get(n).get();
  }, t.setObservablePropValue_ = function(n, i) {
    var a = this.values_.get(n);
    if (a instanceof B)
      return a.set(i), !0;
    if (M(this)) {
      var o = j(this, {
        type: Z,
        object: this.proxy_ || this.target_,
        name: n,
        newValue: i
      });
      if (!o)
        return null;
      i = o.newValue;
    }
    if (i = a.prepareNewValue_(i), i !== p.UNCHANGED) {
      var s = H(this), l = process.env.NODE_ENV !== "production" && P(), c = s || l ? {
        type: Z,
        observableKind: "object",
        debugObjectName: this.name_,
        object: this.proxy_ || this.target_,
        oldValue: a.value_,
        name: n,
        newValue: i
      } : null;
      process.env.NODE_ENV !== "production" && l && I(c), a.setNewValue_(i), s && X(this, c), process.env.NODE_ENV !== "production" && l && z();
    }
    return !0;
  }, t.get_ = function(n) {
    return p.trackingDerivation && !W(this.target_, n) && this.has_(n), this.target_[n];
  }, t.set_ = function(n, i, a) {
    return a === void 0 && (a = !1), W(this.target_, n) ? this.values_.has(n) ? this.setObservablePropValue_(n, i) : a ? Reflect.set(this.target_, n, i) : (this.target_[n] = i, !0) : this.extend_(n, {
      value: i,
      enumerable: !0,
      writable: !0,
      configurable: !0
    }, this.defaultAnnotation_, a);
  }, t.has_ = function(n) {
    if (!p.trackingDerivation)
      return n in this.target_;
    this.pendingKeys_ || (this.pendingKeys_ = /* @__PURE__ */ new Map());
    var i = this.pendingKeys_.get(n);
    return i || (i = new Se(n in this.target_, pr, process.env.NODE_ENV !== "production" ? this.name_ + "." + Vr(n) + "?" : "ObservableObject.key?", !1), this.pendingKeys_.set(n, i)), i.get();
  }, t.make_ = function(n, i) {
    if (i === !0 && (i = this.defaultAnnotation_), i !== !1) {
      if (Cn(this, i, n), !(n in this.target_)) {
        var a;
        if ((a = this.target_[ie]) != null && a[n])
          return;
        f(1, i.annotationType_, this.name_ + "." + n.toString());
      }
      for (var o = this.target_; o && o !== lr; ) {
        var s = Ht(o, n);
        if (s) {
          var l = i.make_(this, n, s, o);
          if (l === 0)
            return;
          if (l === 1)
            break;
        }
        o = Object.getPrototypeOf(o);
      }
      kn(this, i, n);
    }
  }, t.extend_ = function(n, i, a, o) {
    if (o === void 0 && (o = !1), a === !0 && (a = this.defaultAnnotation_), a === !1)
      return this.defineProperty_(n, i, o);
    Cn(this, a, n);
    var s = a.extend_(this, n, i, o);
    return s && kn(this, a, n), s;
  }, t.defineProperty_ = function(n, i, a) {
    a === void 0 && (a = !1), Q(this.keysAtom_);
    try {
      R();
      var o = this.delete_(n);
      if (!o)
        return o;
      if (M(this)) {
        var s = j(this, {
          object: this.proxy_ || this.target_,
          name: n,
          type: pe,
          newValue: i.value
        });
        if (!s)
          return null;
        var l = s.newValue;
        i.value !== l && (i = ve({}, i, {
          value: l
        }));
      }
      if (a) {
        if (!Reflect.defineProperty(this.target_, n, i))
          return !1;
      } else
        _(this.target_, n, i);
      this.notifyPropertyAddition_(n, i.value);
    } finally {
      q();
    }
    return !0;
  }, t.defineObservableProperty_ = function(n, i, a, o) {
    o === void 0 && (o = !1), Q(this.keysAtom_);
    try {
      R();
      var s = this.delete_(n);
      if (!s)
        return s;
      if (M(this)) {
        var l = j(this, {
          object: this.proxy_ || this.target_,
          name: n,
          type: pe,
          newValue: i
        });
        if (!l)
          return null;
        i = l.newValue;
      }
      var c = En(n), d = {
        configurable: p.safeDescriptors ? this.isPlainObject_ : !0,
        enumerable: !0,
        get: c.get,
        set: c.set
      };
      if (o) {
        if (!Reflect.defineProperty(this.target_, n, d))
          return !1;
      } else
        _(this.target_, n, d);
      var u = new Se(i, a, process.env.NODE_ENV !== "production" ? this.name_ + "." + n.toString() : "ObservableObject.key", !1);
      this.values_.set(n, u), this.notifyPropertyAddition_(n, u.value_);
    } finally {
      q();
    }
    return !0;
  }, t.defineComputedProperty_ = function(n, i, a) {
    a === void 0 && (a = !1), Q(this.keysAtom_);
    try {
      R();
      var o = this.delete_(n);
      if (!o)
        return o;
      if (M(this)) {
        var s = j(this, {
          object: this.proxy_ || this.target_,
          name: n,
          type: pe,
          newValue: void 0
        });
        if (!s)
          return null;
      }
      i.name || (i.name = process.env.NODE_ENV !== "production" ? this.name_ + "." + n.toString() : "ObservableObject.key"), i.context = this.proxy_ || this.target_;
      var l = En(n), c = {
        configurable: p.safeDescriptors ? this.isPlainObject_ : !0,
        enumerable: !1,
        get: l.get,
        set: l.set
      };
      if (a) {
        if (!Reflect.defineProperty(this.target_, n, c))
          return !1;
      } else
        _(this.target_, n, c);
      this.values_.set(n, new B(i)), this.notifyPropertyAddition_(n, void 0);
    } finally {
      q();
    }
    return !0;
  }, t.delete_ = function(n, i) {
    if (i === void 0 && (i = !1), Q(this.keysAtom_), !W(this.target_, n))
      return !0;
    if (M(this)) {
      var a = j(this, {
        object: this.proxy_ || this.target_,
        name: n,
        type: On
      });
      if (!a)
        return null;
    }
    try {
      var o;
      R();
      var s = H(this), l = process.env.NODE_ENV !== "production" && P(), c = this.values_.get(n), d = void 0;
      if (!c && (s || l)) {
        var u;
        d = (u = Ht(this.target_, n)) == null ? void 0 : u.value;
      }
      if (i) {
        if (!Reflect.deleteProperty(this.target_, n))
          return !1;
      } else
        delete this.target_[n];
      if (process.env.NODE_ENV !== "production" && delete this.appliedAnnotations_[n], c && (this.values_.delete(n), c instanceof Se && (d = c.value_), Ri(c)), this.keysAtom_.reportChanged(), (o = this.pendingKeys_) == null || (o = o.get(n)) == null || o.set(n in this.target_), s || l) {
        var v = {
          type: On,
          observableKind: "object",
          object: this.proxy_ || this.target_,
          debugObjectName: this.name_,
          oldValue: d,
          name: n
        };
        process.env.NODE_ENV !== "production" && l && I(v), s && X(this, v), process.env.NODE_ENV !== "production" && l && z();
      }
    } finally {
      q();
    }
    return !0;
  }, t.observe_ = function(n, i) {
    return process.env.NODE_ENV !== "production" && i === !0 && f("`observe` doesn't support the fire immediately property for observable objects."), Dt(this, n);
  }, t.intercept_ = function(n) {
    return Pt(this, n);
  }, t.notifyPropertyAddition_ = function(n, i) {
    var a, o = H(this), s = process.env.NODE_ENV !== "production" && P();
    if (o || s) {
      var l = o || s ? {
        type: pe,
        observableKind: "object",
        debugObjectName: this.name_,
        object: this.proxy_ || this.target_,
        name: n,
        newValue: i
      } : null;
      process.env.NODE_ENV !== "production" && s && I(l), o && X(this, l), process.env.NODE_ENV !== "production" && s && z();
    }
    (a = this.pendingKeys_) == null || (a = a.get(n)) == null || a.set(!0), this.keysAtom_.reportChanged();
  }, t.ownKeys_ = function() {
    return this.keysAtom_.reportObserved(), mt(this.target_);
  }, t.keys_ = function() {
    return this.keysAtom_.reportObserved(), Object.keys(this.target_);
  }, e;
}();
function et(e, t) {
  var r;
  if (process.env.NODE_ENV !== "production" && t && tt(e) && f("Options can't be provided for already observable objects."), W(e, g))
    return process.env.NODE_ENV !== "production" && !(aa(e) instanceof qr) && f("Cannot convert '" + er(e) + `' into observable object:
The target is already observable of different type.
Extending builtins is not supported.`), e;
  process.env.NODE_ENV !== "production" && !Object.isExtensible(e) && f("Cannot make the designated object observable; it is not extensible");
  var n = (r = t?.name) != null ? r : process.env.NODE_ENV !== "production" ? (D(e) ? "ObservableObject" : e.constructor.name) + "@" + F() : "ObservableObject", i = new qr(e, /* @__PURE__ */ new Map(), String(n), Ko(t));
  return dr(e, g, i), e;
}
var zs = /* @__PURE__ */ Ue("ObservableObjectAdministration", qr);
function En(e) {
  return xn[e] || (xn[e] = {
    get: function() {
      return this[g].getObservablePropValue_(e);
    },
    set: function(r) {
      return this[g].setObservablePropValue_(e, r);
    }
  });
}
function tt(e) {
  return cr(e) ? zs(e[g]) : !1;
}
function kn(e, t, r) {
  var n;
  process.env.NODE_ENV !== "production" && (e.appliedAnnotations_[r] = t), (n = e.target_[ie]) == null || delete n[r];
}
function Cn(e, t, r) {
  if (process.env.NODE_ENV !== "production" && !sa(t) && f("Cannot annotate '" + e.name_ + "." + r.toString() + "': Invalid annotation."), process.env.NODE_ENV !== "production" && !Jt(t) && W(e.appliedAnnotations_, r)) {
    var n = e.name_ + "." + r.toString(), i = e.appliedAnnotations_[r].annotationType_, a = t.annotationType_;
    f("Cannot apply '" + a + "' to '" + n + "':" + (`
The field is already annotated with '` + i + "'.") + `
Re-annotating fields is not allowed.
Use 'override' annotation for methods overridden by subclass.`);
  }
}
var Us = /* @__PURE__ */ na(0), Ls = /* @__PURE__ */ function() {
  var e = !1, t = {};
  return Object.defineProperty(t, "0", {
    set: function() {
      e = !0;
    }
  }), Object.create(t)[0] = 1, e === !1;
}(), Ar = 0, ra = function() {
};
function Ms(e, t) {
  Object.setPrototypeOf ? Object.setPrototypeOf(e.prototype, t) : e.prototype.__proto__ !== void 0 ? e.prototype.__proto__ = t : e.prototype = t;
}
Ms(ra, Array.prototype);
var tn = /* @__PURE__ */ function(e) {
  function t(n, i, a, o) {
    var s;
    return a === void 0 && (a = process.env.NODE_ENV !== "production" ? "ObservableArray@" + F() : "ObservableArray"), o === void 0 && (o = !1), s = e.call(this) || this, Me(function() {
      var l = new en(a, i, o, !0);
      l.proxy_ = s, yi(s, g, l), n && n.length && s.spliceWithArray(0, 0, n), Ls && Object.defineProperty(s, "0", Us);
    }), s;
  }
  Oi(t, e);
  var r = t.prototype;
  return r.concat = function() {
    this[g].atom_.reportObserved();
    for (var i = arguments.length, a = new Array(i), o = 0; o < i; o++)
      a[o] = arguments[o];
    return Array.prototype.concat.apply(
      this.slice(),
      //@ts-ignore
      a.map(function(s) {
        return br(s) ? s.slice() : s;
      })
    );
  }, r[Symbol.iterator] = function() {
    var n = this, i = 0;
    return rn({
      next: function() {
        return i < n.length ? {
          value: n[i++],
          done: !1
        } : {
          done: !0,
          value: void 0
        };
      }
    });
  }, _e(t, [{
    key: "length",
    get: function() {
      return this[g].getArrayLength_();
    },
    set: function(i) {
      this[g].setArrayLength_(i);
    }
  }, {
    key: Symbol.toStringTag,
    get: function() {
      return "Array";
    }
  }]);
}(ra);
Object.entries(_t).forEach(function(e) {
  var t = e[0], r = e[1];
  t !== "concat" && dr(tn.prototype, t, r);
});
function na(e) {
  return {
    enumerable: !1,
    configurable: !0,
    get: function() {
      return this[g].get_(e);
    },
    set: function(r) {
      this[g].set_(e, r);
    }
  };
}
function js(e) {
  _(tn.prototype, "" + e, na(e));
}
function ia(e) {
  if (e > Ar) {
    for (var t = Ar; t < e + 100; t++)
      js(t);
    Ar = e;
  }
}
ia(1e3);
function Rs(e, t, r) {
  return new tn(e, t, r);
}
function Ge(e, t) {
  if (typeof e == "object" && e !== null) {
    if (br(e))
      return t !== void 0 && f(23), e[g].atom_;
    if (Y(e))
      return e.atom_;
    if (be(e)) {
      if (t === void 0)
        return e.keysAtom_;
      var r = e.data_.get(t) || e.hasMap_.get(t);
      return r || f(25, t, er(e)), r;
    }
    if (tt(e)) {
      if (!t)
        return f(26);
      var n = e[g].values_.get(t);
      return n || f(27, t, er(e)), n;
    }
    if (Gr(e) || mr(e) || Qt(e))
      return e;
  } else if (k(e) && Qt(e[g]))
    return e[g];
  f(28);
}
function aa(e, t) {
  if (e || f(29), Gr(e) || mr(e) || Qt(e) || be(e) || Y(e))
    return e;
  if (e[g])
    return e[g];
  f(24, e);
}
function er(e, t) {
  var r;
  if (t !== void 0)
    r = Ge(e, t);
  else {
    if (Ve(e))
      return e.name;
    tt(e) || be(e) || Y(e) ? r = aa(e) : r = Ge(e);
  }
  return r.name_;
}
function Me(e) {
  var t = Le(), r = hr(!0);
  R();
  try {
    return e();
  } finally {
    q(), gr(r), oe(t);
  }
}
var An = lr.toString;
function oa(e, t, r) {
  return r === void 0 && (r = -1), Kr(e, t, r);
}
function Kr(e, t, r, n, i) {
  if (e === t)
    return e !== 0 || 1 / e === 1 / t;
  if (e == null || t == null)
    return !1;
  if (e !== e)
    return t !== t;
  var a = typeof e;
  if (a !== "function" && a !== "object" && typeof t != "object")
    return !1;
  var o = An.call(e);
  if (o !== An.call(t))
    return !1;
  switch (o) {
    // Strings, numbers, regular expressions, dates, and booleans are compared by value.
    case "[object RegExp]":
    // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i')
    case "[object String]":
      return "" + e == "" + t;
    case "[object Number]":
      return +e != +e ? +t != +t : +e == 0 ? 1 / +e === 1 / t : +e == +t;
    case "[object Date]":
    case "[object Boolean]":
      return +e == +t;
    case "[object Symbol]":
      return typeof Symbol < "u" && Symbol.valueOf.call(e) === Symbol.valueOf.call(t);
    case "[object Map]":
    case "[object Set]":
      r >= 0 && r++;
      break;
  }
  e = Sn(e), t = Sn(t);
  var s = o === "[object Array]";
  if (!s) {
    if (typeof e != "object" || typeof t != "object")
      return !1;
    var l = e.constructor, c = t.constructor;
    if (l !== c && !(k(l) && l instanceof l && k(c) && c instanceof c) && "constructor" in e && "constructor" in t)
      return !1;
  }
  if (r === 0)
    return !1;
  r < 0 && (r = -1), n = n || [], i = i || [];
  for (var d = n.length; d--; )
    if (n[d] === e)
      return i[d] === t;
  if (n.push(e), i.push(t), s) {
    if (d = e.length, d !== t.length)
      return !1;
    for (; d--; )
      if (!Kr(e[d], t[d], r - 1, n, i))
        return !1;
  } else {
    var u = Object.keys(e), v = u.length;
    if (Object.keys(t).length !== v)
      return !1;
    for (var h = 0; h < v; h++) {
      var m = u[h];
      if (!(W(t, m) && Kr(e[m], t[m], r - 1, n, i)))
        return !1;
    }
  }
  return n.pop(), i.pop(), !0;
}
function Sn(e) {
  return br(e) ? e.slice() : Qe(e) || be(e) || ne(e) || Y(e) ? Array.from(e.entries()) : e;
}
var Pn, qs = ((Pn = Hr().Iterator) == null ? void 0 : Pn.prototype) || {};
function rn(e) {
  return e[Symbol.iterator] = Ks, Object.assign(Object.create(qs), e);
}
function Ks() {
  return this;
}
function sa(e) {
  return (
    // Can be function
    e instanceof Object && typeof e.annotationType_ == "string" && k(e.make_) && k(e.extend_)
  );
}
["Symbol", "Map", "Set"].forEach(function(e) {
  var t = Hr();
  typeof t[e] > "u" && f("MobX requires global '" + e + "' to be available or polyfilled");
});
typeof __MOBX_DEVTOOLS_GLOBAL_HOOK__ == "object" && __MOBX_DEVTOOLS_GLOBAL_HOOK__.injectMobx({
  spy: ls,
  extras: {
    getDebugName: er
  },
  $mobx: g
});
var ye = /* @__PURE__ */ ((e) => (e.INFORMATION = "information", e.WARNING = "warning", e.ERROR = "error", e))(ye || {});
const Bs = Symbol.for("react.portal"), Fs = Symbol.for("react.fragment"), Zs = Symbol.for("react.strict_mode"), Ws = Symbol.for("react.profiler"), Hs = Symbol.for("react.provider"), Xs = Symbol.for("react.context"), la = Symbol.for("react.forward_ref"), Js = Symbol.for("react.suspense"), Gs = Symbol.for("react.suspense_list"), Ys = Symbol.for("react.memo"), Qs = Symbol.for("react.lazy");
function _s(e, t, r) {
  const n = e.displayName;
  if (n)
    return n;
  const i = t.displayName || t.name || "";
  return i !== "" ? `${r}(${i})` : r;
}
function Dn(e) {
  return e.displayName || "Context";
}
function tr(e) {
  if (e === null)
    return null;
  if (typeof e == "function")
    return e.displayName || e.name || null;
  if (typeof e == "string")
    return e;
  switch (e) {
    case Fs:
      return "Fragment";
    case Bs:
      return "Portal";
    case Ws:
      return "Profiler";
    case Zs:
      return "StrictMode";
    case Js:
      return "Suspense";
    case Gs:
      return "SuspenseList";
  }
  if (typeof e == "object")
    switch (e.$$typeof) {
      case Xs:
        return `${Dn(e)}.Consumer`;
      case Hs:
        return `${Dn(e._context)}.Provider`;
      case la:
        return _s(e, e.render, "ForwardRef");
      case Ys:
        const t = e.displayName || null;
        return t !== null ? t : tr(e.type) || "Memo";
      case Qs: {
        const r = e, n = r._payload, i = r._init;
        try {
          return tr(i(n));
        } catch {
          return null;
        }
      }
    }
  return null;
}
let zt;
function Td() {
  const e = /* @__PURE__ */ new Set();
  return Array.from(document.body.querySelectorAll("*")).flatMap(tl).filter($s).filter((r) => !r.fileName.includes("frontend/generated/")).forEach((r) => e.add(r.fileName)), Array.from(e);
}
function $s(e) {
  return !!e && e.fileName;
}
function rr(e) {
  if (!e)
    return;
  if (e._debugSource)
    return e._debugSource;
  const t = e._debugInfo?.source;
  if (t?.fileName && t?.lineNumber)
    return t;
}
function el(e) {
  if (e && e.type?.__debugSourceDefine)
    return e.type.__debugSourceDefine;
}
function tl(e) {
  return rr(nr(e));
}
function rl() {
  return `__reactFiber$${ca()}`;
}
function nl() {
  return `__reactContainer$${ca()}`;
}
function ca() {
  if (!(!zt && (zt = Array.from(document.querySelectorAll("*")).flatMap((e) => Object.keys(e)).filter((e) => e.startsWith("__reactFiber$")).map((e) => e.replace("__reactFiber$", "")).find((e) => e), !zt)))
    return zt;
}
function ut(e) {
  const t = e.type;
  return t?.$$typeof === la && !t.displayName && e.child ? ut(e.child) : tr(e.type) ?? tr(e.elementType) ?? "???";
}
function il() {
  const e = Array.from(document.querySelectorAll("body > *")).flatMap((r) => r[nl()]).find((r) => r), t = Ie(e);
  return Ie(t?.child);
}
function al(e) {
  const t = [];
  let r = Ie(e.child);
  for (; r; )
    t.push(r), r = Ie(r.sibling);
  return t;
}
function ol(e) {
  return e.hasOwnProperty("entanglements") && e.hasOwnProperty("containerInfo");
}
function sl(e) {
  return e.hasOwnProperty("stateNode") && e.hasOwnProperty("pendingProps");
}
function Ie(e) {
  const t = e?.stateNode;
  if (t?.current && (ol(t) || sl(t)))
    return t?.current;
  if (!e)
    return;
  if (!e.alternate)
    return e;
  const r = e.alternate, n = e?.actualStartTime, i = r?.actualStartTime;
  return i !== n && i > n ? r : e;
}
function nr(e) {
  const t = rl(), r = Ie(e[t]);
  if (rr(r))
    return r;
  let n = r?.return || void 0;
  for (; n && !rr(n); )
    n = n.return || void 0;
  return n;
}
function ir(e) {
  if (e.stateNode?.isConnected === !0)
    return e.stateNode;
  if (e.child)
    return ir(e.child);
}
function Nn(e) {
  const t = ir(e);
  return t && Ie(nr(t)) === e;
}
function ll(e) {
  return typeof e.type != "function" || da(e) ? !1 : !!(rr(e) || el(e));
}
function da(e) {
  if (!e)
    return !1;
  const t = e;
  return typeof e.type == "function" && t.tag === 1;
}
const Nt = async (e, t, r) => window.Vaadin.copilot.comm(e, t, r), he = "copilot-", cl = "25.0.7", dl = "undefined", Vd = "attention-required", Id = "https://plugins.jetbrains.com/plugin/23758-vaadin", zd = "https://marketplace.visualstudio.com/items?itemName=vaadin.vaadin-vscode", Ud = "https://marketplace.eclipse.org/content/vaadin-tools";
function Ld(e) {
  return e === void 0 ? !1 : e.nodeId >= 0;
}
function ul(e) {
  if (e.javaClass)
    return e.javaClass.substring(e.javaClass.lastIndexOf(".") + 1);
}
function Ut(e) {
  const t = window.Vaadin;
  if (t && t.Flow) {
    const { clients: r } = t.Flow, n = Object.keys(r);
    for (const i of n) {
      const a = r[i];
      if (a.getNodeId) {
        const o = a.getNodeId(e);
        if (o >= 0) {
          const s = a.getNodeInfo(o);
          return {
            nodeId: o,
            uiId: a.getUIId(),
            element: e,
            javaClass: s.javaClass,
            styles: s.styles,
            hiddenByServer: s.hiddenByServer
          };
        }
      }
    }
  }
}
function Md() {
  const e = window.Vaadin;
  let t;
  if (e && e.Flow) {
    const { clients: r } = e.Flow, n = Object.keys(r);
    for (const i of n) {
      const a = r[i];
      a.getUIId && (t = a.getUIId());
    }
  }
  return t;
}
function jd(e) {
  return {
    uiId: e.uiId,
    nodeId: e.nodeId
  };
}
function pl(e) {
  return e ? e.type?.type === "FlowContainer" : !1;
}
function fl(e) {
  return e.localName.startsWith("flow-container");
}
function Rd(e) {
  const t = e.lastIndexOf(".");
  return t < 0 ? e : e.substring(t + 1);
}
function ua(e, t) {
  const r = e();
  r ? t(r) : setTimeout(() => ua(e, t), 50);
}
async function vl(e) {
  const t = e();
  if (t)
    return t;
  let r;
  const n = new Promise((a) => {
    r = a;
  }), i = setInterval(() => {
    const a = e();
    a && (clearInterval(i), r(a));
  }, 10);
  return n;
}
function ar(e) {
  return C.box(e, { deep: !1 });
}
function hl(e) {
  return e && typeof e.lastAccessedBy_ == "number";
}
function qd(e) {
  if (e) {
    if (typeof e == "string")
      return e;
    if (!hl(e))
      throw new Error(`Expected message to be a string or an observable value but was ${JSON.stringify(e)}`);
    return e.get();
  }
}
function gl(e) {
  return Array.from(new Set(e));
}
function Tt(e) {
  Promise.resolve().then(() => xc).then(({ showNotification: t }) => {
    t(e);
  });
}
function ml() {
  Tt({
    type: ye.INFORMATION,
    message: "The previous operation is still in progress. Please wait for it to finish."
  });
}
function bl(e) {
  return e.children && (e.children = e.children.filter(bl)), e.visible !== !1;
}
function Tn(e) {
  const t = `--${e}`, r = /* @__PURE__ */ new Set();
  function n(c) {
    return "cssRules" in c;
  }
  function i(c) {
    return c.type === CSSRule.STYLE_RULE;
  }
  function a(c) {
    return "cssRules" in c;
  }
  function o(c) {
    if (!c) return !1;
    for (let d = 0; d < c.length; d++)
      if (c[d]?.startsWith(t)) return !0;
    return !1;
  }
  function s(c) {
    if (i(c) && o(c.style)) return !0;
    if (a(c)) {
      const d = c.cssRules;
      for (const u of d)
        if (s(u))
          return !0;
    }
    if (c.type === CSSRule.IMPORT_RULE) {
      const d = c;
      if (d.styleSheet && l(d.styleSheet)) return !0;
    }
    return !1;
  }
  function l(c) {
    if (!c || r.has(c)) return !1;
    r.add(c);
    let d;
    try {
      d = c.cssRules;
    } catch {
      return !1;
    }
    if (!d)
      return !1;
    for (const u of d)
      if (s(u))
        return !0;
    return !1;
  }
  for (const c of Array.from([...document.adoptedStyleSheets, ...document.styleSheets]))
    if (n(c) && l(c)) return !0;
  return !1;
}
function Kd(e) {
  return e?.replace(/^.*[\\/]/, "");
}
async function pa() {
  return vl(() => {
    const e = window.Vaadin.devTools, t = e?.frontendConnection && e?.frontendConnection.status === "active";
    return e !== void 0 && t && e?.frontendConnection;
  });
}
function te(e, t) {
  pa().then((r) => {
    r.canSend ? r.send(e, t) : Tt({
      type: ye.INFORMATION,
      message: "Connection lost",
      details: "Please refresh the page and start the server if it is not running",
      delay: 1e4,
      dismissId: "connection-lost"
    });
  });
}
const yl = () => {
  te("copilot-browser-info", {
    userAgent: navigator.userAgent,
    locale: navigator.language,
    timezone: Intl.DateTimeFormat().resolvedOptions().timeZone
  });
}, xt = (e, t) => {
  te("copilot-track-event", { event: e, properties: t });
}, Bd = (e, t) => {
  xt(e, { ...t, view: "react" });
}, Fd = (e, t) => {
  xt(e, { ...t, view: "flow" });
};
class wl {
  constructor() {
    this.welcomeActive = !1, this.loginCheckActive = !1, this.userInfo = void 0, this.active = !1, this.activatedFrom = null, this.activatedAtLeastOnce = !1, this.operationInProgress = void 0, this.operationWaitsHmrUpdate = void 0, this.operationWaitsHmrUpdateTimeout = void 0, this.idePluginState = void 0, this.notifications = [], this.infoTooltip = null, this.sectionPanelDragging = !1, this.sectionPanelResizing = !1, this.drawerResizing = !1, this.featureFlags = [], this.newVaadinVersionState = void 0, this.pointerEventsDisabledForScrolling = !1, this.editComponent = void 0, this.serverRestartRequiringToggledFeatureFlags = [], this.appTheme = void 0, this.escapeEventHandler = void 0, $e(this, {
      notifications: C.shallow
    });
  }
  setActive(t, r) {
    this.active = t, t && (this.activatedAtLeastOnce || (xt("activate"), this.idePluginState?.active && xt("plugin-active", {
      pluginVersion: this.idePluginState.version,
      ide: this.idePluginState.ide
    })), this.activatedAtLeastOnce = !0), this.activatedFrom = r ?? null;
  }
  setWelcomeActive(t) {
    this.welcomeActive = t;
  }
  setLoginCheckActive(t) {
    this.loginCheckActive = t;
  }
  setUserInfo(t) {
    this.userInfo = t;
  }
  startOperation(t) {
    if (this.operationInProgress)
      throw new Error(`An ${t} operation is already in progress`);
    if (this.operationWaitsHmrUpdate) {
      ml();
      return;
    }
    this.operationInProgress = t;
  }
  stopOperation(t) {
    if (this.operationInProgress) {
      if (this.operationInProgress !== t)
        return;
    } else return;
    this.operationInProgress = void 0;
  }
  setOperationWaitsHmrUpdate(t, r) {
    this.operationWaitsHmrUpdate = t, this.operationWaitsHmrUpdateTimeout = r;
  }
  clearOperationWaitsHmrUpdate() {
    this.operationWaitsHmrUpdate = void 0, this.operationWaitsHmrUpdateTimeout = void 0;
  }
  setIdePluginState(t) {
    this.idePluginState = t;
  }
  toggleActive(t) {
    this.setActive(!this.active, this.active ? null : t ?? null);
  }
  reset() {
    this.active = !1, this.activatedAtLeastOnce = !1;
  }
  setNotifications(t) {
    this.notifications = t;
  }
  removeNotification(t) {
    t.animatingOut = !0, setTimeout(() => {
      this.reallyRemoveNotification(t);
    }, 180);
  }
  reallyRemoveNotification(t) {
    const r = this.notifications.indexOf(t);
    r > -1 && this.notifications.splice(r, 1);
  }
  setTooltip(t, r) {
    this.infoTooltip = {
      text: t,
      loader: r
    };
  }
  clearTooltip() {
    this.infoTooltip = null;
  }
  setSectionPanelDragging(t) {
    this.sectionPanelDragging = t;
  }
  setSectionPanelResizing(t) {
    this.sectionPanelResizing = t;
  }
  setDrawerResizing(t) {
    this.drawerResizing = t;
  }
  setFeatureFlags(t) {
    this.featureFlags = t;
  }
  setVaadinVersionState(t) {
    this.newVaadinVersionState = t;
  }
  setPointerEventsDisabledForScrolling(t) {
    this.pointerEventsDisabledForScrolling = t;
  }
  setEditComponent(t) {
    this.editComponent = t;
  }
  clearEditComponent() {
    this.editComponent = void 0;
  }
  toggleServerRequiringFeatureFlag(t) {
    const r = [...this.serverRestartRequiringToggledFeatureFlags], n = r.findIndex((i) => i.id === t.id);
    n === -1 ? r.push(t) : r.splice(n, 1), this.serverRestartRequiringToggledFeatureFlags = r;
  }
  setAppTheme(t) {
    this.appTheme = t;
  }
  setEscapeEventHandler(t) {
    this.escapeEventHandler = t;
  }
  clearEscapeEventHandler() {
    this.escapeEventHandler = void 0;
  }
}
const xl = (e, t, r) => t >= e.left && t <= e.right && r >= e.top && r <= e.bottom, fa = (e) => {
  const t = [];
  let r = Vn(e);
  for (; r; )
    t.push(r), r = Vn(r);
  return t;
}, Ol = (e) => {
  if (e.length === 0)
    return new DOMRect();
  let t = Number.MAX_VALUE, r = Number.MAX_VALUE, n = Number.MIN_VALUE, i = Number.MIN_VALUE;
  const a = new DOMRect();
  return e.forEach((o) => {
    const s = o.getBoundingClientRect();
    s.x < t && (t = s.x), s.y < r && (r = s.y), s.right > n && (n = s.right), s.bottom > i && (i = s.bottom);
  }), a.x = t, a.y = r, a.width = n - t, a.height = i - r, a;
}, or = (e, t) => {
  let r = e;
  for (; !(r instanceof HTMLElement && r.localName === `${he}main`); ) {
    if (!r.isConnected)
      return null;
    if (r.parentNode)
      r = r.parentNode;
    else if (r.host)
      r = r.host;
    else
      return null;
    if (r instanceof HTMLElement && r.localName === t)
      return r;
  }
  return null;
};
function Vn(e) {
  return e.parentElement ?? e.parentNode?.host;
}
function Br(e) {
  if (e.assignedSlot)
    return Br(e.assignedSlot);
  if (e.parentElement)
    return e.parentElement;
  if (e.parentNode instanceof ShadowRoot)
    return e.parentNode.host;
}
function fe(e) {
  if (e instanceof Node) {
    const t = fa(e);
    return e instanceof HTMLElement && t.push(e), t.map((r) => r.localName).some((r) => r.startsWith(he));
  }
  return !1;
}
function In(e) {
  return e instanceof Element;
}
function zn(e) {
  return e.startsWith("vaadin-") ? e.substring(7).split("-").map((n) => n.charAt(0).toUpperCase() + n.slice(1)).join(" ") : e;
}
function Un(e) {
  if (!e)
    return;
  if (e.id)
    return `#${e.id}`;
  if (!e.children)
    return;
  const t = Array.from(e.children).find((n) => n.localName === "label");
  if (t)
    return t.outerText.trim();
  const r = Array.from(e.childNodes).find(
    (n) => n.nodeType === Node.TEXT_NODE && n.textContent && n.textContent.trim().length > 0
  );
  if (r && r.textContent)
    return r.textContent.trim();
}
function El(e) {
  return e instanceof Element && typeof e.getBoundingClientRect == "function" ? e.getBoundingClientRect() : kl(e);
}
function kl(e) {
  const t = document.createRange();
  t.selectNode(e);
  const r = t.getBoundingClientRect();
  return t.detach(), r;
}
function Cl() {
  let e = document.activeElement;
  for (; e?.shadowRoot && e.shadowRoot.activeElement; )
    e = e.shadowRoot.activeElement;
  return e;
}
function Al(e) {
  let t = Br(e);
  for (; t && t !== document.body; ) {
    const r = window.getComputedStyle(t), n = r.overflowY, i = r.overflowX, a = /(auto|scroll)/.test(n) && t.scrollHeight > t.clientHeight, o = /(auto|scroll)/.test(i) && t.scrollWidth > t.clientWidth;
    if (a || o)
      return t;
    t = Br(t);
  }
  return document.documentElement;
}
function Sl(e, t) {
  return Pl(e, t) && Dl(t);
}
function Pl(e, t) {
  const r = Al(e), n = r.getBoundingClientRect();
  if (r === document.documentElement || r === document.body) {
    const i = window.innerWidth || document.documentElement.clientWidth, a = window.innerHeight || document.documentElement.clientHeight;
    return t.top < a && t.bottom > 0 && t.left < i && t.right > 0;
  }
  return t.bottom > n.top && t.top < n.bottom && t.right > n.left && t.left < n.right;
}
function Dl(e) {
  return e.bottom > 0 && e.right > 0 && e.top < window.innerHeight && e.left < window.innerWidth;
}
function Zd(e) {
  return e instanceof HTMLElement;
}
function Wd(e) {
  const t = va(e), r = Ol(t);
  !t.every((i) => Sl(i, r)) && t.length > 0 && t[0].scrollIntoView();
}
function va(e) {
  const t = e;
  if (!t)
    return [];
  const { element: r } = t;
  if (r) {
    const n = t.element;
    if (r.localName === "vaadin-popover" || r.localName === "vaadin-dialog") {
      const i = n._overlayElement.shadowRoot.querySelector('[part="overlay"]');
      if (i)
        return [i];
    }
    if (r.localName === "vaadin-login-overlay") {
      const i = n.shadowRoot?.querySelector("vaadin-login-overlay-wrapper")?.shadowRoot?.querySelector('[part="card"]');
      if (i)
        return [i];
    }
    return [r];
  }
  return t.children.flatMap((n) => va(n));
}
function Hd(e, t) {
  function r(n) {
    if (n instanceof ShadowRoot)
      for (const i of n.children) {
        const a = r(i);
        if (a)
          return a;
      }
    else if (n instanceof Element) {
      if (n.tagName.toLowerCase() === t.toLowerCase())
        return n;
      for (const i of n.children) {
        const a = r(i);
        if (a)
          return a;
      }
    }
  }
  return r(e);
}
function Nl(e) {
  const { clientX: t, clientY: r } = e;
  return t === 0 && r === 0 || // Safari and Firefox returns the last position where mouse left the screen with adding some offset value, something like 356, -1.
  !xl(document.documentElement.getBoundingClientRect(), t, r);
}
function Ln(e) {
  if (e.localName === "vaadin-login-overlay")
    return !1;
  const t = El(e);
  return t.width === 0 || t.height === 0;
}
function Tl(e) {
  return typeof e.close == "function";
}
function Mn(e) {
  return Tl(e) ? (e.close(), !0) : e.localName === "vaadin-popover" ? (e.opened = !1, !0) : !1;
}
var ha = /* @__PURE__ */ ((e) => (e["vaadin-combo-box"] = "vaadin-combo-box", e["vaadin-date-picker"] = "vaadin-date-picker", e["vaadin-dialog"] = "vaadin-dialog", e["vaadin-multi-select-combo-box"] = "vaadin-multi-select-combo-box", e["vaadin-select"] = "vaadin-select", e["vaadin-time-picker"] = "vaadin-time-picker", e["vaadin-popover"] = "vaadin-popover", e))(ha || {});
const Re = {
  "vaadin-combo-box": {
    hideOnActivation: !0,
    open: (e) => Lt(e),
    close: (e) => Mt(e)
  },
  "vaadin-select": {
    hideOnActivation: !0,
    open: (e) => {
      const t = e;
      ma(t, t._overlayElement), t.opened = !0;
    },
    close: (e) => {
      const t = e;
      ba(t, t._overlayElement), t.opened = !1;
    }
  },
  "vaadin-multi-select-combo-box": {
    hideOnActivation: !0,
    open: (e) => Lt(e),
    close: (e) => {
      Mt(e), e.removeAttribute("focused");
    }
  },
  "vaadin-date-picker": {
    hideOnActivation: !0,
    open: (e) => Lt(e),
    close: (e) => Mt(e)
  },
  "vaadin-time-picker": {
    hideOnActivation: !0,
    open: (e) => Lt(e),
    close: (e) => {
      Mt(e), e.removeAttribute("focused");
    }
  },
  "vaadin-dialog": {
    hideOnActivation: !1
  },
  "vaadin-popover": {
    hideOnActivation: !1
  }
}, ga = (e) => {
  e.preventDefault(), e.stopImmediatePropagation();
}, Lt = (e) => {
  e.addEventListener("focusout", ga, { capture: !0 }), ma(e), e.opened = !0;
}, Mt = (e) => {
  ba(e), e.removeAttribute("focused"), e.removeEventListener("focusout", ga, { capture: !0 }), e.opened = !1;
}, ma = (e, t) => {
  const r = t ?? e.$.overlay;
  r.__oldModeless = r.modeless, r.modeless = !0;
}, ba = (e, t) => {
  const r = t ?? e.$.overlay;
  r.modeless = r.__oldModeless !== void 0 ? r.__oldModeless : r.modeless, delete r.__oldModeless;
};
class Vl {
  constructor() {
    this.openedOverlayOwners = /* @__PURE__ */ new Set(), this.overlayCloseEventListener = (t) => {
      fe(t.detail?.overlay) || (window.Vaadin.copilot._uiState.active || fe(t.detail.sourceEvent?.target)) && (t.preventDefault(), t.stopImmediatePropagation());
    };
  }
  /**
   * Modifies pointer-events property to auto if dialog overlay is present on body element. <br/>
   * Overriding closeOnOutsideClick method in order to keep overlay present while copilot is active
   * @private
   */
  onCopilotActivation() {
    const t = this.findComponentWithOpenOverlay();
    if (!t)
      return;
    const r = Re[t.localName];
    r && (r.hideOnActivation && r.close ? r.close(t) : document.body.style.getPropertyValue("pointer-events") === "none" && document.body.style.removeProperty("pointer-events"));
  }
  findComponentWithOpenOverlay() {
    let t;
    for (t in Re) {
      const r = document.querySelector(`${t}[opened]`);
      if (r)
        return r;
    }
    return null;
  }
  /**
   * Restores pointer-events state on deactivation. <br/>
   * Closes opened overlays while using copilot.
   * @private
   */
  onCopilotDeactivation() {
    this.openedOverlayOwners.forEach((r) => {
      const n = Re[r.localName];
      n && n.close && n.close(r);
    }), document.body.querySelector("vaadin-dialog[opened]") && document.body.style.setProperty("pointer-events", "none");
  }
  getOwner(t) {
    const r = t;
    if (r._comboBox)
      return r._comboBox._comboBox ?? r._comboBox;
    if (r.owner)
      return r.owner;
    if (r?.__focusRestorationController?.focusNode?.parentElement)
      return r?.__focusRestorationController?.focusNode?.parentElement;
  }
  addOverlayOutsideClickEvent() {
    document.documentElement.addEventListener("vaadin-overlay-close", this.overlayCloseEventListener, {
      capture: !0
    });
  }
  removeOverlayOutsideClickEvent() {
    document.documentElement.removeEventListener("vaadin-overlay-close", this.overlayCloseEventListener);
  }
  toggle(t) {
    const r = Re[t.localName];
    this.isOverlayActive(t) ? (r.close(t), this.openedOverlayOwners.delete(t)) : (r.open(t), this.openedOverlayOwners.add(t));
  }
  isOverlayActive(t) {
    const r = Re[t.localName];
    return r.active ? r.active(t) : t.hasAttribute("opened");
  }
  overlayStatus(t) {
    if (!t)
      return { visible: !1 };
    const r = t.localName;
    let n = Object.keys(ha).includes(r);
    if (!n)
      return { visible: !1 };
    const i = Re[t.localName];
    if (!i.open || !i.close)
      return { visible: !1 };
    i.hasOverlay && (n = i.hasOverlay(t));
    const a = this.isOverlayActive(t);
    return { visible: n, active: a };
  }
}
class ya {
  constructor() {
    this.promise = new Promise((t) => {
      this.resolveInit = t;
    });
  }
  done(t) {
    this.resolveInit(t);
  }
}
class Il {
  constructor() {
    this.dismissedNotifications = [], this.termsSummaryDismissed = !1, this.activationButtonPosition = null, this.paletteState = null, this.activationShortcut = !0, this.activationAnimation = !0, this.recentSwitchedUsernames = [], this.newVersionPreReleasesVisible = !1, this.aiUsageAllowed = "ask", this.sendErrorReportsAllowed = !0, this.feedbackDisplayedAtLeastOnce = !1, this.aiProvider = "ANY", $e(this), this.initializer = new ya(), this.initializer.promise.then(() => {
      $r(
        () => JSON.stringify(this),
        () => {
          te("copilot-set-machine-configuration", { conf: JSON.stringify(jn(this)) });
        }
      );
    }), window.Vaadin.copilot.eventbus.on("copilot-machine-configuration", (t) => {
      const r = t.detail.conf;
      r.aiProvider || (r.aiProvider = "ANY"), Object.assign(this, jn(r)), this.initializer.done(!0), t.preventDefault();
    }), this.loadData();
  }
  loadData() {
    te("copilot-get-machine-configuration", {});
  }
  addDismissedNotification(t) {
    this.dismissedNotifications = [...this.dismissedNotifications, t];
  }
  getDismissedNotifications() {
    return this.dismissedNotifications;
  }
  clearDismissedNotifications() {
    this.dismissedNotifications = [];
  }
  setTermsSummaryDismissed(t) {
    this.termsSummaryDismissed = t;
  }
  isTermsSummaryDismissed() {
    return this.termsSummaryDismissed;
  }
  getActivationButtonPosition() {
    return this.activationButtonPosition;
  }
  setActivationButtonPosition(t) {
    this.activationButtonPosition = t;
  }
  getPaletteState() {
    return this.paletteState;
  }
  setPaletteState(t) {
    this.paletteState = t;
  }
  isActivationShortcut() {
    return this.activationShortcut;
  }
  setActivationShortcut(t) {
    this.activationShortcut = t;
  }
  isActivationAnimation() {
    return this.activationAnimation;
  }
  setActivationAnimation(t) {
    this.activationAnimation = t;
  }
  getRecentSwitchedUsernames() {
    return this.recentSwitchedUsernames;
  }
  setRecentSwitchedUsernames(t) {
    this.recentSwitchedUsernames = t;
  }
  addRecentSwitchedUsername(t) {
    this.setRecentSwitchedUsernames(gl([t, ...this.recentSwitchedUsernames]));
  }
  removeRecentSwitchedUsername(t) {
    this.setRecentSwitchedUsernames(this.recentSwitchedUsernames.filter((r) => r !== t));
  }
  getNewVersionPreReleasesVisible() {
    return this.newVersionPreReleasesVisible;
  }
  setNewVersionPreReleasesVisible(t) {
    this.newVersionPreReleasesVisible = t;
  }
  setSendErrorReportsAllowed(t) {
    this.sendErrorReportsAllowed = t;
  }
  isSendErrorReportsAllowed() {
    return this.sendErrorReportsAllowed;
  }
  setAIUsageAllowed(t) {
    this.aiUsageAllowed = t;
  }
  isAIUsageAllowed() {
    return this.aiUsageAllowed;
  }
  getAIProvider() {
    return this.aiProvider;
  }
  setAIProvider(t) {
    this.aiProvider = t;
  }
  setFeedbackDisplayedAtLeastOnce(t) {
    this.feedbackDisplayedAtLeastOnce = t;
  }
  isFeedbackDisplayedAtLeastOnce() {
    return this.feedbackDisplayedAtLeastOnce;
  }
}
function jn(e) {
  const t = { ...e };
  return delete t.initializer, t;
}
class zl {
  constructor() {
    this._previewActivated = !1, this._remainingTimeInMillis = -1, this._active = !1, this._configurationLoaded = !1, $e(this);
  }
  setConfiguration(t) {
    this._previewActivated = t.previewActivated, t.previewActivated ? this._remainingTimeInMillis = t.remainingTimeInMillis : this._remainingTimeInMillis = -1, this._active = t.active, this._configurationLoaded = !0;
  }
  get previewActivated() {
    return this._previewActivated;
  }
  get remainingTimeInMillis() {
    return this._remainingTimeInMillis;
  }
  get active() {
    return this._active;
  }
  get configurationLoaded() {
    return this._configurationLoaded;
  }
  get expired() {
    return this.previewActivated && !this.active;
  }
  reset() {
    this._previewActivated = !1, this._active = !1, this._configurationLoaded = !1, this._remainingTimeInMillis = -1;
  }
  loadPreviewConfiguration() {
    Nt(`${he}get-preview`, {}, (t) => {
      const r = t.data;
      this.setConfiguration(r);
    }).catch((t) => {
      Promise.resolve().then(() => Tc).then((r) => {
        r.handleCopilotError("Load preview configuration failed", t);
      });
    });
  }
}
const Rn = "copilot-conf";
class We {
  static get sessionConfiguration() {
    const t = sessionStorage.getItem(Rn);
    return t ? JSON.parse(t) : {};
  }
  static saveCopilotActivation(t) {
    const r = this.sessionConfiguration;
    r.active = t, this.persist(r);
  }
  static getCopilotActivation() {
    return this.sessionConfiguration.active;
  }
  static saveDrawerSize(t, r) {
    const n = this.sessionConfiguration;
    n.drawerSizes = n.drawerSizes ?? {}, n.drawerSizes[t] = r, this.persist(n);
  }
  static getDrawerSize(t) {
    const r = this.sessionConfiguration;
    if (r.drawerSizes)
      return r.drawerSizes[t];
  }
  static savePanelConfigurations(t) {
    const r = this.sessionConfiguration;
    r.sectionPanelState = t, this.persist(r);
  }
  static getPanelConfigurations() {
    return this.sessionConfiguration.sectionPanelState;
  }
  static persist(t) {
    sessionStorage.setItem(Rn, JSON.stringify(t));
  }
  static savePrompts(t) {
    const r = this.sessionConfiguration;
    r.prompts = t, this.persist(r);
  }
  static getPrompts() {
    return this.sessionConfiguration.prompts || [];
  }
  static saveCurrentSelection(t) {
    const r = this.sessionConfiguration;
    r.selection = r.selection ?? {}, r.selection && (r.selection.current = t, r.selection.location = window.location.pathname, this.persist(r));
  }
  static savePendingSelection(t) {
    const r = this.sessionConfiguration;
    r.selection = r.selection ?? {}, r.selection && (r.selection.pending = t, r.selection.location = window.location.pathname, this.persist(r));
  }
  static getCurrentSelection() {
    const t = this.sessionConfiguration.selection;
    if (t?.location === window.location.pathname)
      return t.current;
  }
  static getPendingSelection() {
    const t = this.sessionConfiguration.selection;
    if (t?.location === window.location.pathname)
      return t.pending;
  }
  static saveDrillDownContextReference(t) {
    const r = this.sessionConfiguration;
    r.drillDownContext = r.drillDownContext ?? {}, r.drillDownContext && (r.drillDownContext.location = window.location.pathname, r.drillDownContext.stack = t, this.persist(r));
  }
  static getDrillDownContextReference() {
    const t = this.sessionConfiguration;
    if (t?.drillDownContext?.location === window.location.pathname)
      return t.drillDownContext?.stack;
  }
}
class Ul {
  constructor() {
    this._panels = [], this._attentionRequiredPanelTag = null, this._floatingPanelsZIndexOrder = [], this.renderedPanels = /* @__PURE__ */ new Set(), this.customTags = /* @__PURE__ */ new Map(), $e(this), this.restorePositions();
  }
  shouldRender(t) {
    return this.renderedPanels.has(t);
  }
  restorePositions() {
    const t = We.getPanelConfigurations();
    t && (this._panels = this._panels.map((r) => {
      const n = t.find((i) => i.tag === r.tag);
      return n && (r = Object.assign(r, { ...n })), r;
    }));
  }
  /**
   * Brings a given floating panel to the front.
   *
   * @param panelTag the tag name of the panel
   */
  bringToFront(t) {
    this._floatingPanelsZIndexOrder = this._floatingPanelsZIndexOrder.filter((r) => r !== t), this.getPanelByTag(t)?.floating && this._floatingPanelsZIndexOrder.push(t);
  }
  /**
   * Returns the focused z-index of floating panel as following order
   * <ul>
   *     <li>Returns 50 for last(focused) element </li>
   *     <li>Returns the index of element in list(starting from 0) </li>
   *     <li>Returns 0 if panel is not in the list</li>
   * </ul>
   * @param panelTag
   */
  getFloatingPanelZIndex(t) {
    const r = this._floatingPanelsZIndexOrder.findIndex((n) => n === t);
    return r === this._floatingPanelsZIndexOrder.length - 1 ? 50 : r === -1 ? 0 : r;
  }
  get floatingPanelsZIndexOrder() {
    return this._floatingPanelsZIndexOrder;
  }
  get attentionRequiredPanelTag() {
    return this._attentionRequiredPanelTag;
  }
  set attentionRequiredPanelTag(t) {
    this._attentionRequiredPanelTag = t;
  }
  getAttentionRequiredPanelConfiguration() {
    return this._panels.find((t) => t.tag === this._attentionRequiredPanelTag);
  }
  clearAttention() {
    this._attentionRequiredPanelTag = null;
  }
  get panels() {
    return this._panels;
  }
  addPanel(t) {
    if (this.getPanelByTag(t.tag))
      return;
    this._panels.push(t), this.restorePositions();
    const r = this.getPanelByTag(t.tag);
    if (r)
      (r.eager || r.expanded) && this.renderedPanels.add(t.tag);
    else throw new Error(`Panel configuration not found for tag ${t.tag}`);
  }
  getPanelByTag(t) {
    return this._panels.find((r) => r.tag === t);
  }
  updatePanel(t, r) {
    const n = [...this._panels], i = n.find((a) => a.tag === t);
    if (i) {
      for (const a in r)
        i[a] = r[a];
      i.expanded && this.renderedPanels.add(i.tag), r.floating === !1 && (this._floatingPanelsZIndexOrder = this._floatingPanelsZIndexOrder.filter((a) => a !== t)), this._panels = n, We.savePanelConfigurations(this._panels);
    }
  }
  updateOrders(t) {
    const r = [...this._panels];
    r.forEach((n) => {
      const i = t.find((a) => a.tag === n.tag);
      i && (n.panelOrder = i.order);
    }), this._panels = r, We.savePanelConfigurations(r);
  }
  removePanel(t) {
    const r = this._panels.findIndex((n) => n.tag === t);
    r < 0 || (this._panels.splice(r, 1), We.savePanelConfigurations(this._panels));
  }
  setCustomPanelHeader(t, r) {
    this.customTags.set(t.tag, r);
  }
  getPanelHeader(t) {
    return this.customTags.get(t.tag) ?? t.header;
  }
  clearCustomPanelHeader(t) {
    this.customTags.delete(t.tag);
  }
}
class Ll {
  constructor() {
    this.supportsHilla = !0, this.springSecurityEnabled = !1, this.springJpaDataEnabled = !1, this.springJpaDatasourceInitialization = !1, this.springApplication = !1, this.urlPrefix = "", this.serverVersions = [], this.clientVersions = [{ name: "Browser", version: navigator.userAgent }], $e(this);
  }
  setSupportsHilla(t) {
    this.supportsHilla = t;
  }
  setSpringSecurityEnabled(t) {
    this.springSecurityEnabled = t;
  }
  setSpringJpaDataEnabled(t) {
    this.springJpaDataEnabled = t;
  }
  setSpringJpaDatasourceInitialization(t) {
    this.springJpaDatasourceInitialization = t;
  }
  setSpringApplication(t) {
    this.springApplication = t;
  }
  setUrlPrefix(t) {
    this.urlPrefix = t;
  }
  setServerVersions(t) {
    this.serverVersions = t;
  }
  setClientVersions(t) {
    this.clientVersions = t;
  }
  setJdkInfo(t) {
    this.jdkInfo = t;
  }
}
class Ml {
  constructor() {
    this.palette = { components: [] }, $e(this), this.initializer = new ya(), this.initializer.promise.then(() => {
      $r(
        () => JSON.stringify(this),
        () => {
          te("copilot-set-project-state-configuration", { conf: JSON.stringify(qn(this)) });
        }
      );
    }), window.Vaadin.copilot.eventbus.on("copilot-project-state-configuration", (t) => {
      const r = t.detail.conf;
      Object.assign(this, qn(r)), this.initializer.done(!0), t.preventDefault();
    }), this.loadData();
  }
  loadData() {
    te("copilot-get-project-state-configuration", {});
  }
  addPaletteCustomComponent(t) {
    return (this.palette?.components ?? []).find((i) => Sr(i, t)) ? !1 : (this.palette || (this.palette = { components: [] }), this.palette = JSON.parse(JSON.stringify(this.palette)), this.palette.components.push(t), !0);
  }
  removePaletteCustomComponent(t) {
    if (this.palette) {
      const r = this.palette.components.findIndex(
        (n) => Sr(n, t)
      );
      r > -1 && this.palette.components.splice(r, 1);
    }
  }
  updatePaletteCustomComponent(t, r) {
    if (!this.palette || !this.palette.components)
      return;
    const n = [...this.palette.components], i = n.findIndex((a) => Sr(a, t));
    i !== -1 && (n[i] = { ...t, ...r }), this.palette.components = n;
  }
  paletteCustomComponentExist(t, r) {
    return !this.palette || !this.palette.components ? !1 : t ? this.palette.components.findIndex(
      (n) => n.java && !n.react && n.javaClassName === t
    ) !== -1 : r ? this.palette.components.findIndex((n) => !n.java && n.react && n.template === r) !== -1 : !1;
  }
  get paletteComponents() {
    return this.palette?.components || [];
  }
}
function qn(e) {
  const t = { ...e };
  return delete t.initializer, t;
}
function Sr(e, t) {
  return e.java ? t.java ? e.javaClassName === t.javaClassName : !1 : e.react && t.react ? e.template === t.template : !1;
}
window.Vaadin ??= {};
window.Vaadin.copilot ??= {};
window.Vaadin.copilot.plugins = [];
window.Vaadin.copilot._uiState = new wl();
window.Vaadin.copilot.eventbus = new Xa();
window.Vaadin.copilot.overlayManager = new Vl();
window.Vaadin.copilot._machineState = new Il();
window.Vaadin.copilot._storedProjectState = new Ml();
window.Vaadin.copilot._previewState = new zl();
window.Vaadin.copilot._sectionPanelUiState = new Ul();
window.Vaadin.copilot._earlyProjectState = new Ll();
/**
 * @license
 * Copyright 2017 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const jl = (e) => (t, r) => {
  r !== void 0 ? r.addInitializer(() => {
    customElements.define(e, t);
  }) : customElements.define(e, t);
};
/**
 * @license
 * Copyright 2019 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const Bt = globalThis, nn = Bt.ShadowRoot && (Bt.ShadyCSS === void 0 || Bt.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, an = Symbol(), Kn = /* @__PURE__ */ new WeakMap();
let wa = class {
  constructor(t, r, n) {
    if (this._$cssResult$ = !0, n !== an) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
    this.cssText = t, this.t = r;
  }
  get styleSheet() {
    let t = this.o;
    const r = this.t;
    if (nn && t === void 0) {
      const n = r !== void 0 && r.length === 1;
      n && (t = Kn.get(r)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), n && Kn.set(r, t));
    }
    return t;
  }
  toString() {
    return this.cssText;
  }
};
const L = (e) => new wa(typeof e == "string" ? e : e + "", void 0, an), Rl = (e, ...t) => {
  const r = e.length === 1 ? e[0] : t.reduce((n, i, a) => n + ((o) => {
    if (o._$cssResult$ === !0) return o.cssText;
    if (typeof o == "number") return o;
    throw Error("Value passed to 'css' function must be a 'css' function result: " + o + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
  })(i) + e[a + 1], e[0]);
  return new wa(r, e, an);
}, ql = (e, t) => {
  if (nn) e.adoptedStyleSheets = t.map((r) => r instanceof CSSStyleSheet ? r : r.styleSheet);
  else for (const r of t) {
    const n = document.createElement("style"), i = Bt.litNonce;
    i !== void 0 && n.setAttribute("nonce", i), n.textContent = r.cssText, e.appendChild(n);
  }
}, Bn = nn ? (e) => e : (e) => e instanceof CSSStyleSheet ? ((t) => {
  let r = "";
  for (const n of t.cssRules) r += n.cssText;
  return L(r);
})(e) : e;
/**
 * @license
 * Copyright 2017 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const { is: Kl, defineProperty: Bl, getOwnPropertyDescriptor: Fl, getOwnPropertyNames: Zl, getOwnPropertySymbols: Wl, getPrototypeOf: Hl } = Object, yr = globalThis, Fn = yr.trustedTypes, Xl = Fn ? Fn.emptyScript : "", Jl = yr.reactiveElementPolyfillSupport, vt = (e, t) => e, Fr = { toAttribute(e, t) {
  switch (t) {
    case Boolean:
      e = e ? Xl : null;
      break;
    case Object:
    case Array:
      e = e == null ? e : JSON.stringify(e);
  }
  return e;
}, fromAttribute(e, t) {
  let r = e;
  switch (t) {
    case Boolean:
      r = e !== null;
      break;
    case Number:
      r = e === null ? null : Number(e);
      break;
    case Object:
    case Array:
      try {
        r = JSON.parse(e);
      } catch {
        r = null;
      }
  }
  return r;
} }, xa = (e, t) => !Kl(e, t), Zn = { attribute: !0, type: String, converter: Fr, reflect: !1, useDefault: !1, hasChanged: xa };
Symbol.metadata ??= Symbol("metadata"), yr.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
let Be = class extends HTMLElement {
  static addInitializer(t) {
    this._$Ei(), (this.l ??= []).push(t);
  }
  static get observedAttributes() {
    return this.finalize(), this._$Eh && [...this._$Eh.keys()];
  }
  static createProperty(t, r = Zn) {
    if (r.state && (r.attribute = !1), this._$Ei(), this.prototype.hasOwnProperty(t) && ((r = Object.create(r)).wrapped = !0), this.elementProperties.set(t, r), !r.noAccessor) {
      const n = Symbol(), i = this.getPropertyDescriptor(t, n, r);
      i !== void 0 && Bl(this.prototype, t, i);
    }
  }
  static getPropertyDescriptor(t, r, n) {
    const { get: i, set: a } = Fl(this.prototype, t) ?? { get() {
      return this[r];
    }, set(o) {
      this[r] = o;
    } };
    return { get: i, set(o) {
      const s = i?.call(this);
      a?.call(this, o), this.requestUpdate(t, s, n);
    }, configurable: !0, enumerable: !0 };
  }
  static getPropertyOptions(t) {
    return this.elementProperties.get(t) ?? Zn;
  }
  static _$Ei() {
    if (this.hasOwnProperty(vt("elementProperties"))) return;
    const t = Hl(this);
    t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
  }
  static finalize() {
    if (this.hasOwnProperty(vt("finalized"))) return;
    if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(vt("properties"))) {
      const r = this.properties, n = [...Zl(r), ...Wl(r)];
      for (const i of n) this.createProperty(i, r[i]);
    }
    const t = this[Symbol.metadata];
    if (t !== null) {
      const r = litPropertyMetadata.get(t);
      if (r !== void 0) for (const [n, i] of r) this.elementProperties.set(n, i);
    }
    this._$Eh = /* @__PURE__ */ new Map();
    for (const [r, n] of this.elementProperties) {
      const i = this._$Eu(r, n);
      i !== void 0 && this._$Eh.set(i, r);
    }
    this.elementStyles = this.finalizeStyles(this.styles);
  }
  static finalizeStyles(t) {
    const r = [];
    if (Array.isArray(t)) {
      const n = new Set(t.flat(1 / 0).reverse());
      for (const i of n) r.unshift(Bn(i));
    } else t !== void 0 && r.push(Bn(t));
    return r;
  }
  static _$Eu(t, r) {
    const n = r.attribute;
    return n === !1 ? void 0 : typeof n == "string" ? n : typeof t == "string" ? t.toLowerCase() : void 0;
  }
  constructor() {
    super(), this._$Ep = void 0, this.isUpdatePending = !1, this.hasUpdated = !1, this._$Em = null, this._$Ev();
  }
  _$Ev() {
    this._$ES = new Promise((t) => this.enableUpdating = t), this._$AL = /* @__PURE__ */ new Map(), this._$E_(), this.requestUpdate(), this.constructor.l?.forEach((t) => t(this));
  }
  addController(t) {
    (this._$EO ??= /* @__PURE__ */ new Set()).add(t), this.renderRoot !== void 0 && this.isConnected && t.hostConnected?.();
  }
  removeController(t) {
    this._$EO?.delete(t);
  }
  _$E_() {
    const t = /* @__PURE__ */ new Map(), r = this.constructor.elementProperties;
    for (const n of r.keys()) this.hasOwnProperty(n) && (t.set(n, this[n]), delete this[n]);
    t.size > 0 && (this._$Ep = t);
  }
  createRenderRoot() {
    const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
    return ql(t, this.constructor.elementStyles), t;
  }
  connectedCallback() {
    this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(!0), this._$EO?.forEach((t) => t.hostConnected?.());
  }
  enableUpdating(t) {
  }
  disconnectedCallback() {
    this._$EO?.forEach((t) => t.hostDisconnected?.());
  }
  attributeChangedCallback(t, r, n) {
    this._$AK(t, n);
  }
  _$ET(t, r) {
    const n = this.constructor.elementProperties.get(t), i = this.constructor._$Eu(t, n);
    if (i !== void 0 && n.reflect === !0) {
      const a = (n.converter?.toAttribute !== void 0 ? n.converter : Fr).toAttribute(r, n.type);
      this._$Em = t, a == null ? this.removeAttribute(i) : this.setAttribute(i, a), this._$Em = null;
    }
  }
  _$AK(t, r) {
    const n = this.constructor, i = n._$Eh.get(t);
    if (i !== void 0 && this._$Em !== i) {
      const a = n.getPropertyOptions(i), o = typeof a.converter == "function" ? { fromAttribute: a.converter } : a.converter?.fromAttribute !== void 0 ? a.converter : Fr;
      this._$Em = i, this[i] = o.fromAttribute(r, a.type) ?? this._$Ej?.get(i) ?? null, this._$Em = null;
    }
  }
  requestUpdate(t, r, n) {
    if (t !== void 0) {
      const i = this.constructor, a = this[t];
      if (n ??= i.getPropertyOptions(t), !((n.hasChanged ?? xa)(a, r) || n.useDefault && n.reflect && a === this._$Ej?.get(t) && !this.hasAttribute(i._$Eu(t, n)))) return;
      this.C(t, r, n);
    }
    this.isUpdatePending === !1 && (this._$ES = this._$EP());
  }
  C(t, r, { useDefault: n, reflect: i, wrapped: a }, o) {
    n && !(this._$Ej ??= /* @__PURE__ */ new Map()).has(t) && (this._$Ej.set(t, o ?? r ?? this[t]), a !== !0 || o !== void 0) || (this._$AL.has(t) || (this.hasUpdated || n || (r = void 0), this._$AL.set(t, r)), i === !0 && this._$Em !== t && (this._$Eq ??= /* @__PURE__ */ new Set()).add(t));
  }
  async _$EP() {
    this.isUpdatePending = !0;
    try {
      await this._$ES;
    } catch (r) {
      Promise.reject(r);
    }
    const t = this.scheduleUpdate();
    return t != null && await t, !this.isUpdatePending;
  }
  scheduleUpdate() {
    return this.performUpdate();
  }
  performUpdate() {
    if (!this.isUpdatePending) return;
    if (!this.hasUpdated) {
      if (this.renderRoot ??= this.createRenderRoot(), this._$Ep) {
        for (const [i, a] of this._$Ep) this[i] = a;
        this._$Ep = void 0;
      }
      const n = this.constructor.elementProperties;
      if (n.size > 0) for (const [i, a] of n) {
        const { wrapped: o } = a, s = this[i];
        o !== !0 || this._$AL.has(i) || s === void 0 || this.C(i, void 0, a, s);
      }
    }
    let t = !1;
    const r = this._$AL;
    try {
      t = this.shouldUpdate(r), t ? (this.willUpdate(r), this._$EO?.forEach((n) => n.hostUpdate?.()), this.update(r)) : this._$EM();
    } catch (n) {
      throw t = !1, this._$EM(), n;
    }
    t && this._$AE(r);
  }
  willUpdate(t) {
  }
  _$AE(t) {
    this._$EO?.forEach((r) => r.hostUpdated?.()), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
  }
  _$EM() {
    this._$AL = /* @__PURE__ */ new Map(), this.isUpdatePending = !1;
  }
  get updateComplete() {
    return this.getUpdateComplete();
  }
  getUpdateComplete() {
    return this._$ES;
  }
  shouldUpdate(t) {
    return !0;
  }
  update(t) {
    this._$Eq &&= this._$Eq.forEach((r) => this._$ET(r, this[r])), this._$EM();
  }
  updated(t) {
  }
  firstUpdated(t) {
  }
};
Be.elementStyles = [], Be.shadowRootOptions = { mode: "open" }, Be[vt("elementProperties")] = /* @__PURE__ */ new Map(), Be[vt("finalized")] = /* @__PURE__ */ new Map(), Jl?.({ ReactiveElement: Be }), (yr.reactiveElementVersions ??= []).push("2.1.0");
const qe = Symbol("LitMobxRenderReaction"), Wn = Symbol("LitMobxRequestUpdate");
function Gl(e, t) {
  var r, n;
  return n = class extends e {
    constructor() {
      super(...arguments), this[r] = () => {
        this.requestUpdate();
      };
    }
    connectedCallback() {
      super.connectedCallback();
      const a = this.constructor.name || this.nodeName;
      this[qe] = new t(`${a}.update()`, this[Wn]), this.hasUpdated && this.requestUpdate();
    }
    disconnectedCallback() {
      super.disconnectedCallback(), this[qe] && (this[qe].dispose(), this[qe] = void 0);
    }
    update(a) {
      this[qe] ? this[qe].track(super.update.bind(this, a)) : super.update(a);
    }
  }, r = Wn, n;
}
function Yl(e) {
  return Gl(e, ee);
}
/**
 * @license
 * Copyright 2017 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const on = globalThis, sr = on.trustedTypes, Hn = sr ? sr.createPolicy("lit-html", { createHTML: (e) => e }) : void 0, Oa = "$lit$", ue = `lit$${Math.random().toFixed(9).slice(2)}$`, Ea = "?" + ue, Ql = `<${Ea}>`, ze = document, Ot = () => ze.createComment(""), Et = (e) => e === null || typeof e != "object" && typeof e != "function", sn = Array.isArray, _l = (e) => sn(e) || typeof e?.[Symbol.iterator] == "function", Pr = `[ 	
\f\r]`, ot = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Xn = /-->/g, Jn = />/g, Oe = RegExp(`>|${Pr}(?:([^\\s"'>=/]+)(${Pr}*=${Pr}*(?:[^ 	
\f\r"'\`<>=]|("|')|))|$)`, "g"), Gn = /'/g, Yn = /"/g, ka = /^(?:script|style|textarea|title)$/i, Ca = (e) => (t, ...r) => ({ _$litType$: e, strings: t, values: r }), le = Ca(1), Yd = Ca(2), ge = Symbol.for("lit-noChange"), E = Symbol.for("lit-nothing"), Qn = /* @__PURE__ */ new WeakMap(), Ae = ze.createTreeWalker(ze, 129);
function Aa(e, t) {
  if (!sn(e) || !e.hasOwnProperty("raw")) throw Error("invalid template strings array");
  return Hn !== void 0 ? Hn.createHTML(t) : t;
}
const $l = (e, t) => {
  const r = e.length - 1, n = [];
  let i, a = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", o = ot;
  for (let s = 0; s < r; s++) {
    const l = e[s];
    let c, d, u = -1, v = 0;
    for (; v < l.length && (o.lastIndex = v, d = o.exec(l), d !== null); ) v = o.lastIndex, o === ot ? d[1] === "!--" ? o = Xn : d[1] !== void 0 ? o = Jn : d[2] !== void 0 ? (ka.test(d[2]) && (i = RegExp("</" + d[2], "g")), o = Oe) : d[3] !== void 0 && (o = Oe) : o === Oe ? d[0] === ">" ? (o = i ?? ot, u = -1) : d[1] === void 0 ? u = -2 : (u = o.lastIndex - d[2].length, c = d[1], o = d[3] === void 0 ? Oe : d[3] === '"' ? Yn : Gn) : o === Yn || o === Gn ? o = Oe : o === Xn || o === Jn ? o = ot : (o = Oe, i = void 0);
    const h = o === Oe && e[s + 1].startsWith("/>") ? " " : "";
    a += o === ot ? l + Ql : u >= 0 ? (n.push(c), l.slice(0, u) + Oa + l.slice(u) + ue + h) : l + ue + (u === -2 ? s : h);
  }
  return [Aa(e, a + (e[r] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), n];
};
class kt {
  constructor({ strings: t, _$litType$: r }, n) {
    let i;
    this.parts = [];
    let a = 0, o = 0;
    const s = t.length - 1, l = this.parts, [c, d] = $l(t, r);
    if (this.el = kt.createElement(c, n), Ae.currentNode = this.el.content, r === 2 || r === 3) {
      const u = this.el.content.firstChild;
      u.replaceWith(...u.childNodes);
    }
    for (; (i = Ae.nextNode()) !== null && l.length < s; ) {
      if (i.nodeType === 1) {
        if (i.hasAttributes()) for (const u of i.getAttributeNames()) if (u.endsWith(Oa)) {
          const v = d[o++], h = i.getAttribute(u).split(ue), m = /([.?@])?(.*)/.exec(v);
          l.push({ type: 1, index: a, name: m[2], strings: h, ctor: m[1] === "." ? tc : m[1] === "?" ? rc : m[1] === "@" ? nc : wr }), i.removeAttribute(u);
        } else u.startsWith(ue) && (l.push({ type: 6, index: a }), i.removeAttribute(u));
        if (ka.test(i.tagName)) {
          const u = i.textContent.split(ue), v = u.length - 1;
          if (v > 0) {
            i.textContent = sr ? sr.emptyScript : "";
            for (let h = 0; h < v; h++) i.append(u[h], Ot()), Ae.nextNode(), l.push({ type: 2, index: ++a });
            i.append(u[v], Ot());
          }
        }
      } else if (i.nodeType === 8) if (i.data === Ea) l.push({ type: 2, index: a });
      else {
        let u = -1;
        for (; (u = i.data.indexOf(ue, u + 1)) !== -1; ) l.push({ type: 7, index: a }), u += ue.length - 1;
      }
      a++;
    }
  }
  static createElement(t, r) {
    const n = ze.createElement("template");
    return n.innerHTML = t, n;
  }
}
function Ye(e, t, r = e, n) {
  if (t === ge) return t;
  let i = n !== void 0 ? r._$Co?.[n] : r._$Cl;
  const a = Et(t) ? void 0 : t._$litDirective$;
  return i?.constructor !== a && (i?._$AO?.(!1), a === void 0 ? i = void 0 : (i = new a(e), i._$AT(e, r, n)), n !== void 0 ? (r._$Co ??= [])[n] = i : r._$Cl = i), i !== void 0 && (t = Ye(e, i._$AS(e, t.values), i, n)), t;
}
let ec = class {
  constructor(t, r) {
    this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = r;
  }
  get parentNode() {
    return this._$AM.parentNode;
  }
  get _$AU() {
    return this._$AM._$AU;
  }
  u(t) {
    const { el: { content: r }, parts: n } = this._$AD, i = (t?.creationScope ?? ze).importNode(r, !0);
    Ae.currentNode = i;
    let a = Ae.nextNode(), o = 0, s = 0, l = n[0];
    for (; l !== void 0; ) {
      if (o === l.index) {
        let c;
        l.type === 2 ? c = new rt(a, a.nextSibling, this, t) : l.type === 1 ? c = new l.ctor(a, l.name, l.strings, this, t) : l.type === 6 && (c = new ic(a, this, t)), this._$AV.push(c), l = n[++s];
      }
      o !== l?.index && (a = Ae.nextNode(), o++);
    }
    return Ae.currentNode = ze, i;
  }
  p(t) {
    let r = 0;
    for (const n of this._$AV) n !== void 0 && (n.strings !== void 0 ? (n._$AI(t, n, r), r += n.strings.length - 2) : n._$AI(t[r])), r++;
  }
};
class rt {
  get _$AU() {
    return this._$AM?._$AU ?? this._$Cv;
  }
  constructor(t, r, n, i) {
    this.type = 2, this._$AH = E, this._$AN = void 0, this._$AA = t, this._$AB = r, this._$AM = n, this.options = i, this._$Cv = i?.isConnected ?? !0;
  }
  get parentNode() {
    let t = this._$AA.parentNode;
    const r = this._$AM;
    return r !== void 0 && t?.nodeType === 11 && (t = r.parentNode), t;
  }
  get startNode() {
    return this._$AA;
  }
  get endNode() {
    return this._$AB;
  }
  _$AI(t, r = this) {
    t = Ye(this, t, r), Et(t) ? t === E || t == null || t === "" ? (this._$AH !== E && this._$AR(), this._$AH = E) : t !== this._$AH && t !== ge && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : _l(t) ? this.k(t) : this._(t);
  }
  O(t) {
    return this._$AA.parentNode.insertBefore(t, this._$AB);
  }
  T(t) {
    this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
  }
  _(t) {
    this._$AH !== E && Et(this._$AH) ? this._$AA.nextSibling.data = t : this.T(ze.createTextNode(t)), this._$AH = t;
  }
  $(t) {
    const { values: r, _$litType$: n } = t, i = typeof n == "number" ? this._$AC(t) : (n.el === void 0 && (n.el = kt.createElement(Aa(n.h, n.h[0]), this.options)), n);
    if (this._$AH?._$AD === i) this._$AH.p(r);
    else {
      const a = new ec(i, this), o = a.u(this.options);
      a.p(r), this.T(o), this._$AH = a;
    }
  }
  _$AC(t) {
    let r = Qn.get(t.strings);
    return r === void 0 && Qn.set(t.strings, r = new kt(t)), r;
  }
  k(t) {
    sn(this._$AH) || (this._$AH = [], this._$AR());
    const r = this._$AH;
    let n, i = 0;
    for (const a of t) i === r.length ? r.push(n = new rt(this.O(Ot()), this.O(Ot()), this, this.options)) : n = r[i], n._$AI(a), i++;
    i < r.length && (this._$AR(n && n._$AB.nextSibling, i), r.length = i);
  }
  _$AR(t = this._$AA.nextSibling, r) {
    for (this._$AP?.(!1, !0, r); t && t !== this._$AB; ) {
      const n = t.nextSibling;
      t.remove(), t = n;
    }
  }
  setConnected(t) {
    this._$AM === void 0 && (this._$Cv = t, this._$AP?.(t));
  }
}
class wr {
  get tagName() {
    return this.element.tagName;
  }
  get _$AU() {
    return this._$AM._$AU;
  }
  constructor(t, r, n, i, a) {
    this.type = 1, this._$AH = E, this._$AN = void 0, this.element = t, this.name = r, this._$AM = i, this.options = a, n.length > 2 || n[0] !== "" || n[1] !== "" ? (this._$AH = Array(n.length - 1).fill(new String()), this.strings = n) : this._$AH = E;
  }
  _$AI(t, r = this, n, i) {
    const a = this.strings;
    let o = !1;
    if (a === void 0) t = Ye(this, t, r, 0), o = !Et(t) || t !== this._$AH && t !== ge, o && (this._$AH = t);
    else {
      const s = t;
      let l, c;
      for (t = a[0], l = 0; l < a.length - 1; l++) c = Ye(this, s[n + l], r, l), c === ge && (c = this._$AH[l]), o ||= !Et(c) || c !== this._$AH[l], c === E ? t = E : t !== E && (t += (c ?? "") + a[l + 1]), this._$AH[l] = c;
    }
    o && !i && this.j(t);
  }
  j(t) {
    t === E ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
  }
}
class tc extends wr {
  constructor() {
    super(...arguments), this.type = 3;
  }
  j(t) {
    this.element[this.name] = t === E ? void 0 : t;
  }
}
class rc extends wr {
  constructor() {
    super(...arguments), this.type = 4;
  }
  j(t) {
    this.element.toggleAttribute(this.name, !!t && t !== E);
  }
}
class nc extends wr {
  constructor(t, r, n, i, a) {
    super(t, r, n, i, a), this.type = 5;
  }
  _$AI(t, r = this) {
    if ((t = Ye(this, t, r, 0) ?? E) === ge) return;
    const n = this._$AH, i = t === E && n !== E || t.capture !== n.capture || t.once !== n.once || t.passive !== n.passive, a = t !== E && (n === E || i);
    i && this.element.removeEventListener(this.name, this, n), a && this.element.addEventListener(this.name, this, t), this._$AH = t;
  }
  handleEvent(t) {
    typeof this._$AH == "function" ? this._$AH.call(this.options?.host ?? this.element, t) : this._$AH.handleEvent(t);
  }
}
class ic {
  constructor(t, r, n) {
    this.element = t, this.type = 6, this._$AN = void 0, this._$AM = r, this.options = n;
  }
  get _$AU() {
    return this._$AM._$AU;
  }
  _$AI(t) {
    Ye(this, t);
  }
}
const ac = { I: rt }, oc = on.litHtmlPolyfillSupport;
oc?.(kt, rt), (on.litHtmlVersions ??= []).push("3.3.0");
const sc = (e, t, r) => {
  const n = r?.renderBefore ?? t;
  let i = n._$litPart$;
  if (i === void 0) {
    const a = r?.renderBefore ?? null;
    n._$litPart$ = i = new rt(t.insertBefore(Ot(), a), a, void 0, r ?? {});
  }
  return i._$AI(e), i;
};
/**
 * @license
 * Copyright 2017 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const ln = globalThis;
let ht = class extends Be {
  constructor() {
    super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
  }
  createRenderRoot() {
    const t = super.createRenderRoot();
    return this.renderOptions.renderBefore ??= t.firstChild, t;
  }
  update(t) {
    const r = this.render();
    this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = sc(r, this.renderRoot, this.renderOptions);
  }
  connectedCallback() {
    super.connectedCallback(), this._$Do?.setConnected(!0);
  }
  disconnectedCallback() {
    super.disconnectedCallback(), this._$Do?.setConnected(!1);
  }
  render() {
    return ge;
  }
};
ht._$litElement$ = !0, ht.finalized = !0, ln.litElementHydrateSupport?.({ LitElement: ht });
const lc = ln.litElementPolyfillSupport;
lc?.({ LitElement: ht });
(ln.litElementVersions ??= []).push("4.2.0");
class cc extends Yl(ht) {
}
class dc extends cc {
  constructor() {
    super(...arguments), this.disposers = [];
  }
  /**
   * Creates a MobX reaction using the given parameters and disposes it when this element is detached.
   *
   * This should be called from `connectedCallback` to ensure that the reaction is active also if the element is attached again later.
   */
  reaction(t, r, n) {
    this.disposers.push($r(t, r, n));
  }
  /**
   * Creates a MobX autorun using the given parameters and disposes it when this element is detached.
   *
   * This should be called from `connectedCallback` to ensure that the reaction is active also if the element is attached again later.
   */
  autorun(t, r) {
    this.disposers.push(Hi(t, r));
  }
  disconnectedCallback() {
    super.disconnectedCallback(), this.disposers.forEach((t) => {
      t();
    }), this.disposers = [];
  }
}
const se = window.Vaadin.copilot._sectionPanelUiState;
if (!se)
  throw new Error("Tried to access copilot section panel ui state before it was initialized.");
let ke = [];
const _n = [];
function $n(e) {
  e.init({
    addPanel: (t) => {
      se.addPanel(t);
    },
    send(t, r) {
      te(t, r);
    }
  });
}
function uc() {
  ke.push(import("./copilot-log-plugin-k9jQ-PoP.js")), ke.push(import("./copilot-info-plugin-C03ukXfd.js")), ke.push(import("./copilot-features-plugin-C7i9ifZr.js")), ke.push(import("./copilot-feedback-plugin-DyqC4FEM.js")), ke.push(import("./copilot-shortcuts-plugin-C9BiTUJ_.js"));
}
function pc() {
  {
    const e = `https://cdn.vaadin.com/copilot/${cl}/copilot-plugins${dl}.js`;
    import(
      /* @vite-ignore */
      e
    ).catch((t) => {
      console.warn(`Unable to load plugins from ${e}. Some Copilot features are unavailable.`, t);
    });
  }
}
function fc() {
  Promise.all(ke).then(() => {
    const e = window.Vaadin;
    if (e.copilot.plugins) {
      const t = e.copilot.plugins;
      e.copilot.plugins.push = (r) => $n(r), Array.from(t).forEach((r) => {
        _n.includes(r) || ($n(r), _n.push(r));
      });
    }
  }), ke = [];
}
function $d(e) {
  return Object.assign({
    expanded: !0,
    expandable: !1,
    panelOrder: 0,
    floating: !1,
    width: 500,
    height: 500,
    floatingPosition: {
      top: 50,
      left: 350
    }
  }, e);
}
function st() {
  return document.body.querySelector("copilot-main");
}
class vc {
  constructor() {
    this.active = !1, this.activate = () => {
      this.active = !0, st()?.focus(), st()?.addEventListener("focusout", this.keepFocusInCopilot);
    }, this.deactivate = () => {
      this.active = !1, st()?.removeEventListener("focusout", this.keepFocusInCopilot);
    }, this.focusInEventListener = (t) => {
      this.active && (t.preventDefault(), t.stopPropagation(), fe(t.target) || requestAnimationFrame(() => {
        t.target.blur && t.target.blur(), st()?.focus();
      }));
    };
  }
  hostConnectedCallback() {
    const t = this.getApplicationRootElement();
    t && t instanceof HTMLElement && t.addEventListener("focusin", this.focusInEventListener);
  }
  hostDisconnectedCallback() {
    const t = this.getApplicationRootElement();
    t && t instanceof HTMLElement && t.removeEventListener("focusin", this.focusInEventListener);
  }
  getApplicationRootElement() {
    return document.body.firstElementChild;
  }
  keepFocusInCopilot(t) {
    t.preventDefault(), t.stopPropagation(), st()?.focus();
  }
}
const jt = new vc(), y = window.Vaadin.copilot.eventbus;
if (!y)
  throw new Error("Tried to access copilot eventbus before it was initialized.");
const Ke = window.Vaadin.copilot.overlayManager, eu = {
  DragAndDrop: "Drag and Drop",
  RedoUndo: "Redo/Undo"
}, b = window.Vaadin.copilot._uiState;
if (!b)
  throw new Error("Tried to access copilot ui state before it was initialized.");
/**
 * @license
 * Copyright 2017 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const Sa = { CHILD: 2, ELEMENT: 6 }, Pa = (e) => (...t) => ({ _$litDirective$: e, values: t });
class Da {
  constructor(t) {
  }
  get _$AU() {
    return this._$AM._$AU;
  }
  _$AT(t, r, n) {
    this._$Ct = t, this._$AM = r, this._$Ci = n;
  }
  _$AS(t, r) {
    return this.update(t, r);
  }
  update(t, r) {
    return this.render(...r);
  }
}
/**
 * @license
 * Copyright 2017 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
class Zr extends Da {
  constructor(t) {
    if (super(t), this.it = E, t.type !== Sa.CHILD) throw Error(this.constructor.directiveName + "() can only be used in child bindings");
  }
  render(t) {
    if (t === E || t == null) return this._t = void 0, this.it = t;
    if (t === ge) return t;
    if (typeof t != "string") throw Error(this.constructor.directiveName + "() called with a non-string value");
    if (t === this.it) return this._t;
    this.it = t;
    const r = [t];
    return r.raw = r, this._t = { _$litType$: this.constructor.resultType, strings: r, values: [] };
  }
}
Zr.directiveName = "unsafeHTML", Zr.resultType = 1;
const hc = Pa(Zr), nt = window.Vaadin.copilot._machineState;
if (!nt)
  throw new Error("Trying to use stored machine state before it was initialized");
const gc = 5e3;
let ei = 1;
function Na(e) {
  b.notifications.includes(e) && (e.dontShowAgain && e.dismissId && mc(e.dismissId), b.removeNotification(e), y.emit("notification-dismissed", e));
}
function Ta(e) {
  return nt.getDismissedNotifications().includes(e);
}
function mc(e) {
  Ta(e) || nt.addDismissedNotification(e);
}
function bc(e) {
  return !(e.dismissId && (Ta(e.dismissId) || b.notifications.find((t) => t.dismissId === e.dismissId)));
}
function yc() {
  const e = "A server restart is required";
  return dn() ? ar(le`${e} <br />${cn()}`) : ar(le`${e}`);
}
function cn() {
  return dn() ? le`<vaadin-button
      theme="primary"
      @click=${(e) => {
    const t = e.target;
    t.disabled = !0, t.innerText = "Restarting...", Oc();
  }}>
      Restart now
    </vaadin-button>` : E;
}
function Va(e) {
  if (bc(e))
    return wc(e);
}
function wc(e) {
  const t = ei;
  ei += 1;
  const r = { ...e, id: t, dontShowAgain: !1, animatingOut: !1 };
  return b.setNotifications([...b.notifications, r]), (e.delay || !e.link && !e.dismissId) && setTimeout(() => {
    Na(r);
  }, e.delay ?? gc), y.emit("notification-shown", e), r;
}
const xc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
  __proto__: null,
  dismissNotification: Na,
  getRestartRequiredMessage: yc,
  renderRestartButton: cn,
  showNotification: Va
}, Symbol.toStringTag, { value: "Module" })), xr = window.Vaadin.copilot._earlyProjectState;
if (!xr)
  throw new Error("Tried to access early project state before it was initialized.");
function dn() {
  return b.idePluginState?.supportedActions?.find((e) => e === "restartApplication");
}
function Oc() {
  Nt(`${he}plugin-restart-application`, {}, () => {
  }).catch((e) => {
    ce("Error restarting server", e);
  });
}
const Ia = window.Vaadin.copilot._previewState;
if (!Ia)
  throw new Error("Tried to access copilot preview state before it was initialized.");
function Ec() {
  const e = b.userInfo;
  return !e || e.copilotProjectCannotLeaveLocalhost ? !1 : nt.isSendErrorReportsAllowed();
}
const kc = (e) => {
  ce("Unspecified error", e), y.emit("vite-after-update", {});
}, Cc = (e, t) => e.error ? (Ac(e.error, t), !0) : !1, ti = (e, t, r) => {
  Tt({
    type: ye.ERROR,
    message: e,
    details: ar(
      le`<vaadin-details summary="Details" style="color: var(--dev-tools-text-color)"
          ><div>
            <code class="codeblock"><copilot-copy></copilot-copy>${hc(t)}</code>
          </div>
        </vaadin-details>
        ${r !== void 0 ? le`
              <vaadin-button
                theme="primary"
                @click="${() => {
        r && y.emit("submit-exception-report-clicked", r);
      }}"
                >Report Issue</vaadin-button
              >
            ` : E} `
    ),
    delay: 3e4
  });
}, za = (e, t, r, n, i) => {
  const a = b.newVaadinVersionState?.versions?.length === 0;
  i && a ? Pc(
    i,
    (o) => {
      ti(e, t, o);
    },
    e,
    t,
    r
  ) : ti(e, t), Ec() && (n?.templateData && typeof n.templateData == "string" && n.templateData.startsWith("data") && (n.templateData = "<IMAGE_DATA>"), y.emit("system-info-with-callback", {
    callback: (o) => y.send("copilot-error", {
      message: e,
      details: String(r).replace("	", `
`) + (n ? `
 
Request: 
${JSON.stringify(n)}
` : ""),
      versions: o
    }),
    notify: !1
  })), b.clearOperationWaitsHmrUpdate();
}, Ac = (e, t) => {
  za(
    e.message,
    e.exceptionMessage ?? "",
    e.exceptionStacktrace?.join(`
`) ?? "",
    t,
    e.exceptionReport
  );
};
function Sc(e, t) {
  const r = {
    title: t.message,
    nodes: [],
    relevantPairs: [],
    items: []
  };
  za(e, t.message, t.stack ?? "", void 0, r);
}
function Dr(e) {
  if (e === void 0)
    return !1;
  const t = Object.keys(e);
  return t.length === 1 && t.includes("message") || t.length >= 3 && t.includes("message") && t.includes("exceptionMessage") && t.includes("exceptionStacktrace");
}
function ce(e, t) {
  const r = Dr(t) ? t.exceptionMessage ?? t.message : t, n = {
    type: ye.ERROR,
    message: "Copilot internal error",
    details: e + (r ? `
${r}` : "")
  };
  Dr(t) && t.suggestRestart && dn() && (n.details = ar(le`${e}<br />${r} ${cn()}`), n.delay = 3e4), Tt(n);
  let i;
  t instanceof Error ? i = t.stack : Dr(t) ? i = t?.exceptionStacktrace?.join(`
`) : i = t?.toString(), y.emit("system-info-with-callback", {
    callback: (a) => y.send("copilot-error", {
      message: `Copilot internal error: ${e}`,
      details: i,
      versions: a
    }),
    notify: !1
  });
}
function ri(e) {
  return e?.stack?.includes("cdn.vaadin.com/copilot") || e?.stack?.includes("/copilot/copilot/") || e?.stack?.includes("/copilot/copilot-private/");
}
function Ua() {
  const e = window.onerror;
  window.onerror = (r, n, i, a, o) => {
    if (ri(o)) {
      ce(r.toString(), o);
      return;
    }
    e && e(r, n, i, a, o);
  }, is((r) => {
    ri(r) && ce("", r);
  });
  const t = window.Vaadin.ConsoleErrors;
  if (Array.isArray(t))
    for (const r of t)
      Array.isArray(r) ? Ft.push(...r) : Ft.push(r);
  La((r) => Ft.push(r));
}
function Pc(e, t, r, n, i, a) {
  const o = { ...e }, s = window.Vaadin.copilot.tree, l = window.Vaadin.copilot.customComponentHandler;
  o.nodes.forEach((u) => {
    u.node = s.allNodesFlat.find((v) => {
      if (!v.isFlowComponent)
        return !1;
      const h = v.node;
      return h.uiId === u.uiId && h.nodeId === u.nodeId;
    });
  });
  const c = [];
  r && c.push(`Error Message -> ${r}`), n && c.push(`Error Details -> ${n}`), c.push(
    `Active Level -> ${l.getActiveDrillDownContext() ? l.getActiveDrillDownContext()?.nameAndIdentifier : "No active level"}`
  ), o.nodes.length > 0 && (c.push(`
Relevant Nodes:`), o.nodes.forEach((u) => {
    c.push(`${u.relevance} -> ${u.node?.nameAndIdentifier ?? "Node not found"}`);
  })), o.relevantPairs.length > 0 && (c.push(`
Additional Info:`), o.relevantPairs.forEach((u) => {
    c.push(`${u.relevance} -> ${u.value}`);
  }));
  const d = {
    name: "Info",
    content: c.join(`
`)
  };
  o.items.unshift(d), i && o.items.push({
    name: "Stacktrace",
    content: i
  }), y.emit("system-info-with-callback", {
    callback: (u) => {
      o.items.push({
        name: "Versions",
        content: u
      }), t(o);
    },
    notify: !1
  });
}
const Ft = [];
function La(e) {
  const t = window.Vaadin.ConsoleErrors;
  window.Vaadin.ConsoleErrors = {
    push: (r) => {
      r[0] === null || r[0] === void 0 || (r[0].type !== void 0 && r[0].message !== void 0 ? e({
        type: r[0].type,
        message: r[0].message,
        internal: !!r[0].internal,
        details: r[0].details,
        link: r[0].link
      }) : e({ type: ye.ERROR, message: r.map((n) => Dc(n)).join(" "), internal: !1 }), t.push(r));
    }
  };
}
function Dc(e) {
  return e.message ? e.message.toString() : e.toString();
}
function Nc(e) {
  Tt({
    type: ye.ERROR,
    message: `Unable to ${e}`,
    details: "Could not find sources for React components, probably because the project is not a React (or Flow) project"
  });
}
const Tc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
  __proto__: null,
  catchErrors: La,
  consoleErrorsQueue: Ft,
  handleBrowserOperationError: Sc,
  handleCopilotError: ce,
  handleErrorDuringOperation: kc,
  handleServerOperationErrorIfNeeded: Cc,
  installErrorHandlers: Ua,
  showNotReactFlowProject: Nc
}, Symbol.toStringTag, { value: "Module" })), Ma = () => {
  Vc().then((e) => b.setUserInfo(e)).catch((e) => ce("Failed to load userInfo", e));
}, Vc = async () => Nt(`${he}get-user-info`, {}, (e) => (delete e.data.reqId, e.data));
y.on("copilot-prokey-received", (e) => {
  Ma(), e.preventDefault();
});
/**
 * @license
 * Copyright 2020 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const ja = Symbol.for(""), Ic = (e) => {
  if (e?.r === ja) return e?._$litStatic$;
}, Ra = (e) => ({ _$litStatic$: e, r: ja }), ni = /* @__PURE__ */ new Map(), zc = (e) => (t, ...r) => {
  const n = r.length;
  let i, a;
  const o = [], s = [];
  let l, c = 0, d = !1;
  for (; c < n; ) {
    for (l = t[c]; c < n && (a = r[c], (i = Ic(a)) !== void 0); ) l += i + t[++c], d = !0;
    c !== n && s.push(a), o.push(l), c++;
  }
  if (c === n && o.push(t[n]), d) {
    const u = o.join("$$lit$$");
    (t = ni.get(u)) === void 0 && (o.raw = o, ni.set(u, t = o)), r = s;
  }
  return e(t, ...r);
}, gt = zc(le);
/**
 * @license
 * Copyright 2020 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const { I: Uc } = ac, tu = (e) => e.strings === void 0, ii = () => document.createComment(""), lt = (e, t, r) => {
  const n = e._$AA.parentNode, i = t === void 0 ? e._$AB : t._$AA;
  if (r === void 0) {
    const a = n.insertBefore(ii(), i), o = n.insertBefore(ii(), i);
    r = new Uc(a, o, e, e.options);
  } else {
    const a = r._$AB.nextSibling, o = r._$AM, s = o !== e;
    if (s) {
      let l;
      r._$AQ?.(e), r._$AM = e, r._$AP !== void 0 && (l = e._$AU) !== o._$AU && r._$AP(l);
    }
    if (a !== i || s) {
      let l = r._$AA;
      for (; l !== a; ) {
        const c = l.nextSibling;
        n.insertBefore(l, i), l = c;
      }
    }
  }
  return r;
}, Ee = (e, t, r = e) => (e._$AI(t, r), e), Lc = {}, Mc = (e, t = Lc) => e._$AH = t, jc = (e) => e._$AH, Nr = (e) => {
  e._$AP?.(!1, !0);
  let t = e._$AA;
  const r = e._$AB.nextSibling;
  for (; t !== r; ) {
    const n = t.nextSibling;
    t.remove(), t = n;
  }
};
/**
 * @license
 * Copyright 2017 Google LLC
 * SPDX-License-Identifier: BSD-3-Clause
 */
const ai = (e, t, r) => {
  const n = /* @__PURE__ */ new Map();
  for (let i = t; i <= r; i++) n.set(e[i], i);
  return n;
}, qa = Pa(class extends Da {
  constructor(e) {
    if (super(e), e.type !== Sa.CHILD) throw Error("repeat() can only be used in text expressions");
  }
  dt(e, t, r) {
    let n;
    r === void 0 ? r = t : t !== void 0 && (n = t);
    const i = [], a = [];
    let o = 0;
    for (const s of e) i[o] = n ? n(s, o) : o, a[o] = r(s, o), o++;
    return { values: a, keys: i };
  }
  render(e, t, r) {
    return this.dt(e, t, r).values;
  }
  update(e, [t, r, n]) {
    const i = jc(e), { values: a, keys: o } = this.dt(t, r, n);
    if (!Array.isArray(i)) return this.ut = o, a;
    const s = this.ut ??= [], l = [];
    let c, d, u = 0, v = i.length - 1, h = 0, m = a.length - 1;
    for (; u <= v && h <= m; ) if (i[u] === null) u++;
    else if (i[v] === null) v--;
    else if (s[u] === o[h]) l[h] = Ee(i[u], a[h]), u++, h++;
    else if (s[v] === o[m]) l[m] = Ee(i[v], a[m]), v--, m--;
    else if (s[u] === o[m]) l[m] = Ee(i[u], a[m]), lt(e, l[m + 1], i[u]), u++, m--;
    else if (s[v] === o[h]) l[h] = Ee(i[v], a[h]), lt(e, i[u], i[v]), v--, h++;
    else if (c === void 0 && (c = ai(o, h, m), d = ai(s, u, v)), c.has(s[u])) if (c.has(s[v])) {
      const O = d.get(o[h]), A = O !== void 0 ? i[O] : null;
      if (A === null) {
        const G = lt(e, i[u]);
        Ee(G, a[h]), l[h] = G;
      } else l[h] = Ee(A, a[h]), lt(e, i[u], A), i[O] = null;
      h++;
    } else Nr(i[v]), v--;
    else Nr(i[u]), u++;
    for (; h <= m; ) {
      const O = lt(e, l[m + 1]);
      Ee(O, a[h]), l[h++] = O;
    }
    for (; u <= v; ) {
      const O = i[u++];
      O !== null && Nr(O);
    }
    return this.ut = o, Mc(e, l), ge;
  }
}), Zt = /* @__PURE__ */ new Map(), Rc = (e) => {
  const r = se.panels.filter((n) => !n.floating && n.panel === e).sort((n, i) => n.panelOrder - i.panelOrder);
  return gt`
    ${qa(
    r,
    (n) => n.tag,
    (n) => {
      const i = Ra(n.tag);
      return gt` <copilot-section-panel-wrapper panelTag="${i}">
          ${se.shouldRender(n.tag) ? gt`<${i} slot="content"></${i}>` : E}
        </copilot-section-panel-wrapper>`;
    }
  )}
  `;
}, qc = () => {
  const e = se.panels;
  return gt`
    ${qa(
    e.filter((t) => t.floating),
    (t) => t.tag,
    (t) => {
      const r = Ra(t.tag);
      return gt`
                        <copilot-section-panel-wrapper panelTag="${r}">
                            <${r} slot="content"></${r}>
                        </copilot-section-panel-wrapper>`;
    }
  )}
  `;
}, ru = (e) => {
  const t = e.panelTag, r = e.querySelector('[slot="content"]');
  r && e.panelInfo?.panel && Zt.set(t, r);
}, nu = (e) => {
  if (Zt.has(e.panelTag)) {
    const t = Zt.get(e.panelTag);
    e.querySelector('[slot="content"]').replaceWith(t);
  }
  Zt.delete(e.panelTag);
}, S = [];
for (let e = 0; e < 256; ++e)
  S.push((e + 256).toString(16).slice(1));
function Kc(e, t = 0) {
  return (S[e[t + 0]] + S[e[t + 1]] + S[e[t + 2]] + S[e[t + 3]] + "-" + S[e[t + 4]] + S[e[t + 5]] + "-" + S[e[t + 6]] + S[e[t + 7]] + "-" + S[e[t + 8]] + S[e[t + 9]] + "-" + S[e[t + 10]] + S[e[t + 11]] + S[e[t + 12]] + S[e[t + 13]] + S[e[t + 14]] + S[e[t + 15]]).toLowerCase();
}
let Tr;
const Bc = new Uint8Array(16);
function Fc() {
  if (!Tr) {
    if (typeof crypto > "u" || !crypto.getRandomValues)
      throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
    Tr = crypto.getRandomValues.bind(crypto);
  }
  return Tr(Bc);
}
const Zc = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), oi = { randomUUID: Zc };
function Wc(e, t, r) {
  e = e || {};
  const n = e.random ?? e.rng?.() ?? Fc();
  if (n.length < 16)
    throw new Error("Random bytes length must be >= 16");
  return n[6] = n[6] & 15 | 64, n[8] = n[8] & 63 | 128, Kc(n);
}
function Ka(e, t, r) {
  return oi.randomUUID && !e ? oi.randomUUID() : Wc(e);
}
const Wt = [], pt = [], iu = async (e, t, r) => {
  let n, i;
  t.reqId = Ka();
  const a = new Promise((o, s) => {
    n = o, i = s;
  });
  return Wt.push({
    handleMessage(o) {
      if (o?.data?.reqId !== t.reqId)
        return !1;
      try {
        n(r(o));
      } catch (s) {
        i(s);
      }
      return !0;
    }
  }), te(e, t), a;
};
function Hc(e) {
  for (const t of Wt)
    if (t.handleMessage(e))
      return Wt.splice(Wt.indexOf(t), 1), !0;
  if (y.emitUnsafe({ type: e.command, data: e.data }))
    return !0;
  for (const t of Fa())
    if (Ba(t, e))
      return !0;
  return pt.push(e), !1;
}
function Ba(e, t) {
  return e.handleMessage?.call(e, t);
}
function Xc() {
  if (pt.length)
    for (const e of Fa())
      for (let t = 0; t < pt.length; t++)
        Ba(e, pt[t]) && (pt.splice(t, 1), t--);
}
function Fa() {
  const e = document.querySelector("copilot-main");
  return e ? e.renderRoot.querySelectorAll("copilot-section-panel-wrapper *") : [];
}
const Jc = ":host{--animate-spin: spin 1s linear infinite;--animate-swirl: swirl 5s linear infinite}@keyframes bounce{0%{transform:scale(.8)}50%{transform:scale(1.5)}to{transform:scale(1)}}@keyframes bounceLeft{0%{transform:translate(0)}30%{transform:translate(-10px)}50%{transform:translate(0)}70%{transform:translate(-5px)}to{transform:translate(0)}}@keyframes bounceRight{0%{transform:translate(0)}30%{transform:translate(10px)}50%{transform:translate(0)}70%{transform:translate(5px)}to{transform:translate(0)}}@keyframes bounceBottom{0%{transform:translateY(0)}30%{transform:translateY(10px)}50%{transform:translateY(0)}70%{transform:translateY(5px)}to{transform:translateY(0)}}@keyframes around-we-go-again{0%{background-position:0 0,0 0,calc(var(--glow-size) * -.5) calc(var(--glow-size) * -.5),calc(100% + calc(var(--glow-size) * .5)) calc(100% + calc(var(--glow-size) * .5))}25%{background-position:0 0,0 0,calc(100% + calc(var(--glow-size) * .5)) calc(var(--glow-size) * -.5),calc(var(--glow-size) * -.5) calc(100% + calc(var(--glow-size) * .5))}50%{background-position:0 0,0 0,calc(100% + calc(var(--glow-size) * .5)) calc(100% + calc(var(--glow-size) * .5)),calc(var(--glow-size) * -.5) calc(var(--glow-size) * -.5)}75%{background-position:0 0,0 0,calc(var(--glow-size) * -.5) calc(100% + calc(var(--glow-size) * .5)),calc(100% + calc(var(--glow-size) * .5)) calc(var(--glow-size) * -.5)}to{background-position:0 0,0 0,calc(var(--glow-size) * -.5) calc(var(--glow-size) * -.5),calc(100% + calc(var(--glow-size) * .5)) calc(100% + calc(var(--glow-size) * .5))}}@keyframes spin{to{transform:rotate(360deg)}}@keyframes swirl{0%{rotate:0deg;filter:hue-rotate(20deg)}50%{filter:hue-rotate(-30deg)}to{rotate:360deg;filter:hue-rotate(20deg)}}@keyframes button-focus-in{0%{box-shadow:0 0 0 0 var(--focus-color)}to{box-shadow:0 0 0 var(--focus-size) var(--focus-color)}}@keyframes button-focus-out{0%{box-shadow:0 0 0 var(--focus-size) var(--focus-color)}}@keyframes button-primary-focus-in{0%{box-shadow:0 0 0 0 var(--focus-color)}to{box-shadow:0 0 0 1px var(--background-color),0 0 0 calc(var(--focus-size) + 2px) var(--focus-color)}}@keyframes button-primary-focus-out{0%{box-shadow:0 0 0 1px var(--background-color),0 0 0 calc(var(--focus-size) + 2px) var(--focus-color)}}@keyframes link-focus-in{0%{box-shadow:0 0 0 0 var(--blue-color)}to{box-shadow:0 0 0 var(--focus-size) var(--blue-color)}}@keyframes link-focus-out{0%{box-shadow:0 0 0 var(--focus-size) var(--blue-color)}}@keyframes ping{75%,to{transform:scale(2);opacity:0}}@keyframes fadeInOut{0%,to{opacity:0}50%{opacity:1}}", Gc = 'button{align-items:center;-webkit-appearance:none;appearance:none;background:transparent;background-origin:border-box;border:1px solid transparent;border-radius:var(--vaadin-radius-s);color:var(--vaadin-text-color);cursor:pointer;display:inline-flex;flex-shrink:0;font:var(--copilot-font-button);height:var(--copilot-size-md);justify-content:center;outline-offset:calc(var(--focus-size) / -1);padding:0 var(--space-100)}button:hover{background:var(--hover-color)}button:focus{outline:var(--vaadin-focus-ring-width) solid var(--vaadin-focus-ring-color);outline-offset:1px}button:active:not([disabled]){background:var(--active-color)}button.primary{background:var(--primary-color);color:var(--primary-contrast-text-color)}button.icon{padding:0;width:var(--copilot-size-md)}button.icon span:has(svg){display:flex;width:fit-content}button svg{height:var(--icon-size-s);width:var(--icon-size-s)}button .prefix,button .suffix{align-items:center;display:flex;height:var(--copilot-size-md);justify-content:center;width:var(--copilot-size-md)}button:has(.prefix){padding-inline-start:0}button:has(.suffix){padding-inline-end:0}button[role=switch]{align-items:center;border:2px solid var(--vaadin-text-color-secondary);border-radius:9999px;box-sizing:border-box;display:flex;flex-shrink:0;height:1rem;justify-content:start;padding:0;transition:.2s;width:1.5rem}button[role=switch] span{background:var(--vaadin-text-color-secondary);border-radius:9999px;content:"";display:flex;flex-shrink:0;height:.5rem;transition:.2s;transform:translate(.125rem);width:.5rem}button[role=switch][aria-checked=true]{background:var(--blue-11);border-color:var(--blue-11)}button[role=switch][aria-checked=true] span{background:var(--blue-5);height:.625rem;transform:translate(.5625rem);width:.625rem}button[disabled]{cursor:not-allowed;opacity:.3}button[hidden]{display:none}button.link-button{all:initial;color:inherit;cursor:pointer;font-family:inherit;font-size:var(--dev-tools-font-size-small);font-weight:600;line-height:1;text-decoration:underline;white-space:nowrap}button.link-button:focus,button.link-button:hover{color:var(--dev-tools-text-color-emphasis)}', Yc = "code.codeblock{background:var(--contrast-color-5);border-radius:var(--vaadin-radius-m);display:block;font-family:var(--monospace-font-family);font-size:var(--copilot-font-size-xs);line-height:var(--copilot-line-height-sm);overflow:hidden;padding:calc((var(--copilot-size-md) - var(--copilot-line-height-sm)) / 2) var(--copilot-size-md) calc((var(--copilot-size-md) - var(--copilot-line-height-sm)) / 2) var(--space-100);position:relative;text-overflow:ellipsis;white-space:pre;min-height:var(--copilot-line-height-sm)}copilot-copy{position:absolute;right:0;top:0}div.message.error code.codeblock copilot-copy svg{color:#ffffffb3}", Qc = ":host{color-scheme:light;--vaadin-background-color: light-dark(var(--gray-1), var(--gray-5));--vaadin-text-color: light-dark(var(--gray-12), white);--vaadin-text-color-secondary: light-dark(var(--gray-11), hsla(0, 0%, 100%, .7));--vaadin-text-color-disabled: var(--vaadin-text-color-secondary);--vaadin-focus-ring-color: var(--vaadin-text-color);--vaadin-divider-color: light-dark(hsla(0, 0%, 0%, .1), hsla(0, 0%, 100%, .15));--vaadin-blue: #1a81fa;--vaadin-violet: #8854fc;--amber-1: light-dark(#fefdfb, #16120c);--amber-2: light-dark(#fefbe9, #1d180f);--amber-3: light-dark(#fff7c2, #302008);--amber-4: light-dark(#ffee9c, #3f2700);--amber-5: light-dark(#fbe577, #4d3000);--amber-6: light-dark(#f3d673, #5c3d05);--amber-7: light-dark(#e9c162, #714f19);--amber-8: light-dark(#e2a336, #8f6424);--amber-9: light-dark(#ffc53d, #ffc53d);--amber-10: light-dark(#ffba18, #ffd60a);--amber-11: light-dark(#ab6400, #ffca16);--amber-12: light-dark(#4f3422, #ffe7b3);--blue-1: light-dark(#fcfdff, #0a111c);--blue-2: light-dark(#f5f9ff, #0f1826);--blue-3: light-dark(#eaf3ff, #0e2649);--blue-4: light-dark(#dbebff, #0d3162);--blue-5: light-dark(#c9e2ff, #133c75);--blue-6: light-dark(#b5d4ff, #1c4885);--blue-7: light-dark(#9bc2fc, #25559a);--blue-8: light-dark(#76aaf7, #2b63b5);--blue-9: light-dark(#0368de, #0368de);--blue-10: light-dark(#0059ce, #265fb0);--blue-11: light-dark(#0368de, #82b8ff);--blue-12: light-dark(#0c3164, #d0e3ff);--gray-1: light-dark(#fcfcfd, #111113);--gray-2: light-dark(#f9f9fb, #19191b);--gray-3: light-dark(#eff0f3, #222325);--gray-4: light-dark(#e7e8ec, #292a2e);--gray-5: light-dark(#e0e1e6, #303136);--gray-6: light-dark(#d8d9e0, #393a40);--gray-7: light-dark(#cdced7, #46484f);--gray-8: light-dark(#b9bbc6, #5f606a);--gray-9: light-dark(#8b8d98, #6c6e79);--gray-10: light-dark(#80828d, #797b86);--gray-11: light-dark(#62636c, #b2b3bd);--gray-12: light-dark(#1e1f24, #eeeef0);--ruby-1: light-dark(#fffcfd, #191113);--ruby-2: light-dark(#fff7f8, #1e1517);--ruby-3: light-dark(#feeaed, #3a141e);--ruby-4: light-dark(#ffdce1, #4e1325);--ruby-5: light-dark(#ffced6, #5e1a2e);--ruby-6: light-dark(#f8bfc8, #6f2539);--ruby-7: light-dark(#efacb8, #883447);--ruby-8: light-dark(#e592a3, #b3445a);--ruby-9: light-dark(#e54666, #e54666);--ruby-10: light-dark(#dc3b5d, #ec5a72);--ruby-11: light-dark(#ca244d, #ff949d);--ruby-12: light-dark(#64172b, #fed2e1);--teal-1: light-dark(#fafefd, #0d1514);--teal-2: light-dark(#f3fbf9, #111c1b);--teal-3: light-dark(#e0f8f3, #0d2d2a);--teal-4: light-dark(#ccf3ea, #023b37);--teal-5: light-dark(#b8eae0, #084843);--teal-6: light-dark(#a1ded2, #145750);--teal-7: light-dark(#83cdc1, #1c6961);--teal-8: light-dark(#53b9ab, #207e73);--teal-9: light-dark(#12a594, #12a594);--teal-10: light-dark(#0d9b8a, #0eb39e);--teal-11: light-dark(#008573, #0bd8b6);--teal-12: light-dark(#0d3d38, #adf0dd);--violet-1: light-dark(#fcfcff, #110d21);--violet-2: light-dark(#f9f8ff, #18132c);--violet-3: light-dark(#f2f0ff, #291853);--violet-4: light-dark(#e8e3ff, #351772);--violet-5: light-dark(#dfd8ff, #3e1f81);--violet-6: light-dark(#d2c8ff, #492b91);--violet-7: light-dark(#c0b0ff, #5838a9);--violet-8: light-dark(#a98fff, #6d45d0);--violet-9: light-dark(#7b2bff, #7b2bff);--violet-10: light-dark(#6c2adf, #6f07ee);--violet-11: light-dark(#6f2fe3, #b8a5ff);--violet-12: light-dark(#361475, #e1dbff);--gray-h: 220;--gray-s: 30%;--gray-l: 30%;--gray-hsl: var(--gray-h) var(--gray-s) var(--gray-l);--gray: hsl(var(--gray-hsl));--gray-50: hsl(var(--gray-hsl) / .05);--gray-100: hsl(var(--gray-hsl) / .1);--gray-150: hsl(var(--gray-hsl) / .16);--gray-200: hsl(var(--gray-hsl) / .24);--gray-250: hsl(var(--gray-hsl) / .34);--gray-300: hsl(var(--gray-hsl) / .46);--gray-350: hsl(var(--gray-hsl) / .6);--gray-400: hsl(var(--gray-hsl) / .7);--gray-450: hsl(var(--gray-hsl) / .8);--gray-500: hsl(var(--gray-hsl) / .9);--gray-550: hsl(var(--gray-hsl));--gray-600: hsl(var(--gray-h) var(--gray-s) calc(var(--gray-l) - 2%));--gray-650: hsl(var(--gray-h) var(--gray-s) calc(var(--gray-l) - 4%));--gray-700: hsl(var(--gray-h) var(--gray-s) calc(var(--gray-l) - 8%));--gray-750: hsl(var(--gray-h) var(--gray-s) calc(var(--gray-l) - 12%));--gray-800: hsl(var(--gray-h) var(--gray-s) calc(var(--gray-l) - 20%));--gray-850: hsl(var(--gray-h) var(--gray-s) calc(var(--gray-l) - 23%));--gray-900: hsl(var(--gray-h) var(--gray-s) calc(var(--gray-l) - 30%));--blue-h: 220;--blue-s: 90%;--blue-l: 53%;--blue-hsl: var(--blue-h) var(--blue-s) var(--blue-l);--blue: hsl(var(--blue-hsl));--blue-50: hsl(var(--blue-hsl) / .05);--blue-100: hsl(var(--blue-hsl) / .1);--blue-150: hsl(var(--blue-hsl) / .2);--blue-200: hsl(var(--blue-hsl) / .3);--blue-250: hsl(var(--blue-hsl) / .4);--blue-300: hsl(var(--blue-hsl) / .5);--blue-350: hsl(var(--blue-hsl) / .6);--blue-400: hsl(var(--blue-hsl) / .7);--blue-450: hsl(var(--blue-hsl) / .8);--blue-500: hsl(var(--blue-hsl) / .9);--blue-550: hsl(var(--blue-hsl));--blue-600: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) - 4%));--blue-650: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) - 8%));--blue-700: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) - 12%));--blue-750: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) - 15%));--blue-800: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) - 18%));--blue-850: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) - 24%));--blue-900: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) - 27%));--purple-h: 246;--purple-s: 90%;--purple-l: 60%;--purple-hsl: var(--purple-h) var(--purple-s) var(--purple-l);--purple: hsl(var(--purple-hsl));--purple-50: hsl(var(--purple-hsl) / .05);--purple-100: hsl(var(--purple-hsl) / .1);--purple-150: hsl(var(--purple-hsl) / .2);--purple-200: hsl(var(--purple-hsl) / .3);--purple-250: hsl(var(--purple-hsl) / .4);--purple-300: hsl(var(--purple-hsl) / .5);--purple-350: hsl(var(--purple-hsl) / .6);--purple-400: hsl(var(--purple-hsl) / .7);--purple-450: hsl(var(--purple-hsl) / .8);--purple-500: hsl(var(--purple-hsl) / .9);--purple-550: hsl(var(--purple-hsl));--purple-600: hsl(var(--purple-h) calc(var(--purple-s) - 4%) calc(var(--purple-l) - 2%));--purple-650: hsl(var(--purple-h) calc(var(--purple-s) - 8%) calc(var(--purple-l) - 4%));--purple-700: hsl(var(--purple-h) calc(var(--purple-s) - 15%) calc(var(--purple-l) - 7%));--purple-750: hsl(var(--purple-h) calc(var(--purple-s) - 23%) calc(var(--purple-l) - 11%));--purple-800: hsl(var(--purple-h) calc(var(--purple-s) - 24%) calc(var(--purple-l) - 15%));--purple-850: hsl(var(--purple-h) calc(var(--purple-s) - 24%) calc(var(--purple-l) - 19%));--purple-900: hsl(var(--purple-h) calc(var(--purple-s) - 27%) calc(var(--purple-l) - 23%));--green-h: 150;--green-s: 80%;--green-l: 42%;--green-hsl: var(--green-h) var(--green-s) var(--green-l);--green: hsl(var(--green-hsl));--green-50: hsl(var(--green-hsl) / .05);--green-100: hsl(var(--green-hsl) / .1);--green-150: hsl(var(--green-hsl) / .2);--green-200: hsl(var(--green-hsl) / .3);--green-250: hsl(var(--green-hsl) / .4);--green-300: hsl(var(--green-hsl) / .5);--green-350: hsl(var(--green-hsl) / .6);--green-400: hsl(var(--green-hsl) / .7);--green-450: hsl(var(--green-hsl) / .8);--green-500: hsl(var(--green-hsl) / .9);--green-550: hsl(var(--green-hsl));--green-600: hsl(var(--green-h) var(--green-s) calc(var(--green-l) - 2%));--green-650: hsl(var(--green-h) var(--green-s) calc(var(--green-l) - 4%));--green-700: hsl(var(--green-h) var(--green-s) calc(var(--green-l) - 8%));--green-750: hsl(var(--green-h) var(--green-s) calc(var(--green-l) - 12%));--green-800: hsl(var(--green-h) var(--green-s) calc(var(--green-l) - 15%));--green-850: hsl(var(--green-h) var(--green-s) calc(var(--green-l) - 19%));--green-900: hsl(var(--green-h) var(--green-s) calc(var(--green-l) - 23%));--yellow-h: 38;--yellow-s: 98%;--yellow-l: 64%;--yellow-hsl: var(--yellow-h) var(--yellow-s) var(--yellow-l);--yellow: hsl(var(--yellow-hsl));--yellow-50: hsl(var(--yellow-hsl) / .07);--yellow-100: hsl(var(--yellow-hsl) / .12);--yellow-150: hsl(var(--yellow-hsl) / .2);--yellow-200: hsl(var(--yellow-hsl) / .3);--yellow-250: hsl(var(--yellow-hsl) / .4);--yellow-300: hsl(var(--yellow-hsl) / .5);--yellow-350: hsl(var(--yellow-hsl) / .6);--yellow-400: hsl(var(--yellow-hsl) / .7);--yellow-450: hsl(var(--yellow-hsl) / .8);--yellow-500: hsl(var(--yellow-hsl) / .9);--yellow-550: hsl(var(--yellow-hsl));--yellow-600: hsl(var(--yellow-h) var(--yellow-s) calc(var(--yellow-l) - 5%));--yellow-650: hsl(var(--yellow-h) var(--yellow-s) calc(var(--yellow-l) - 10%));--yellow-700: hsl(var(--yellow-h) var(--yellow-s) calc(var(--yellow-l) - 15%));--yellow-750: hsl(var(--yellow-h) var(--yellow-s) calc(var(--yellow-l) - 20%));--yellow-800: hsl(var(--yellow-h) var(--yellow-s) calc(var(--yellow-l) - 25%));--yellow-850: hsl(var(--yellow-h) var(--yellow-s) calc(var(--yellow-l) - 30%));--yellow-900: hsl(var(--yellow-h) var(--yellow-s) calc(var(--yellow-l) - 35%));--red-h: 355;--red-s: 75%;--red-l: 55%;--red-hsl: var(--red-h) var(--red-s) var(--red-l);--red: hsl(var(--red-hsl));--red-50: hsl(var(--red-hsl) / .05);--red-100: hsl(var(--red-hsl) / .1);--red-150: hsl(var(--red-hsl) / .2);--red-200: hsl(var(--red-hsl) / .3);--red-250: hsl(var(--red-hsl) / .4);--red-300: hsl(var(--red-hsl) / .5);--red-350: hsl(var(--red-hsl) / .6);--red-400: hsl(var(--red-hsl) / .7);--red-450: hsl(var(--red-hsl) / .8);--red-500: hsl(var(--red-hsl) / .9);--red-550: hsl(var(--red-hsl));--red-600: hsl(var(--red-h) calc(var(--red-s) - 5%) calc(var(--red-l) - 2%));--red-650: hsl(var(--red-h) calc(var(--red-s) - 10%) calc(var(--red-l) - 4%));--red-700: hsl(var(--red-h) calc(var(--red-s) - 15%) calc(var(--red-l) - 8%));--red-750: hsl(var(--red-h) calc(var(--red-s) - 20%) calc(var(--red-l) - 12%));--red-800: hsl(var(--red-h) calc(var(--red-s) - 25%) calc(var(--red-l) - 15%));--red-850: hsl(var(--red-h) calc(var(--red-s) - 30%) calc(var(--red-l) - 19%));--red-900: hsl(var(--red-h) calc(var(--red-s) - 35%) calc(var(--red-l) - 23%));--codeblock-bg: #f4f4f4;--background-color: rgba(255, 255, 255, .87);--primary-color: #0368de;--input-border-color: rgba(0, 0, 0, .42);--divider-primary-color: rgba(0, 0, 0, .1);--divider-secondary-color: rgba(0, 0, 0, .05);--switch-active-color: #0d875b;--switch-inactive-color: #757575;--primary-contrast-text-color: white;--active-color: rgba(3, 104, 222, .1);--focus-color: #0377ff;--hover-color: rgba(0, 0, 0, .05);--info-color: var(--blue-400);--success-color: var(--success-color-80);--error-color: var(--error-color-70);--warning-color: #fec941;--success-color-5: #f0fffa;--success-color-10: #eafaf4;--success-color-20: #d2f0e5;--success-color-30: #8ce4c5;--success-color-40: #39c693;--success-color-50: #1ba875;--success-color-60: #0e9c69;--success-color-70: #0d8b5e;--success-color-80: #066845;--success-color-90: #004d31;--error-color-5: #fff5f6;--error-color-10: #ffedee;--error-color-20: #ffd0d4;--error-color-30: #f8a8ae;--error-color-40: #ff707a;--error-color-50: #ff3a49;--error-color-60: #ff0013;--error-color-70: #ce0010;--error-color-80: #97000b;--error-color-90: #680008;--contrast-color-5: rgba(0, 0, 0, .05);--contrast-color-10: rgba(0, 0, 0, .1);--contrast-color-20: rgba(0, 0, 0, .2);--contrast-color-30: rgba(0, 0, 0, .3);--contrast-color-40: rgba(0, 0, 0, .4);--contrast-color-50: rgba(0, 0, 0, .5);--contrast-color-60: rgba(0, 0, 0, .6);--contrast-color-70: rgba(0, 0, 0, .7);--contrast-color-80: rgba(0, 0, 0, .8);--contrast-color-90: rgba(0, 0, 0, .9);--contrast-color-100: black;--blue-color: #0368de;--violet-color: #7b2bff}:host(.dark){color-scheme:dark;--gray-s: 15%;--gray-l: 70%;--gray-600: hsl(var(--gray-h) calc(var(--gray-s) - 2%) calc(var(--gray-l) + 6%));--gray-650: hsl(var(--gray-h) calc(var(--gray-s) - 5%) calc(var(--gray-l) + 14%));--gray-700: hsl(var(--gray-h) calc(var(--gray-s) - 2%) calc(var(--gray-l) + 26%));--gray-750: hsl(var(--gray-h) calc(var(--gray-s) - 2%) calc(var(--gray-l) + 36%));--gray-800: hsl(var(--gray-h) calc(var(--gray-s) - 2%) calc(var(--gray-l) + 48%));--gray-850: hsl(var(--gray-h) calc(var(--gray-s) - 2%) calc(var(--gray-l) + 62%));--gray-900: hsl(var(--gray-h) calc(var(--gray-s) - 2%) calc(var(--gray-l) + 70%));--blue-s: 90%;--blue-l: 58%;--blue-600: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) + 6%));--blue-650: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) + 12%));--blue-700: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) + 17%));--blue-750: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) + 22%));--blue-800: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) + 28%));--blue-850: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) + 35%));--blue-900: hsl(var(--blue-h) var(--blue-s) calc(var(--blue-l) + 43%));--purple-600: hsl(var(--purple-h) var(--purple-s) calc(var(--purple-l) + 4%));--purple-650: hsl(var(--purple-h) var(--purple-s) calc(var(--purple-l) + 9%));--purple-700: hsl(var(--purple-h) var(--purple-s) calc(var(--purple-l) + 12%));--purple-750: hsl(var(--purple-h) var(--purple-s) calc(var(--purple-l) + 18%));--purple-800: hsl(var(--purple-h) var(--purple-s) calc(var(--purple-l) + 24%));--purple-850: hsl(var(--purple-h) var(--purple-s) calc(var(--purple-l) + 29%));--purple-900: hsl(var(--purple-h) var(--purple-s) calc(var(--purple-l) + 33%));--green-600: hsl(calc(var(--green-h) - 1) calc(var(--green-s) - 5%) calc(var(--green-l) + 5%));--green-650: hsl(calc(var(--green-h) - 2) calc(var(--green-s) - 10%) calc(var(--green-l) + 12%));--green-700: hsl(calc(var(--green-h) - 4) calc(var(--green-s) - 15%) calc(var(--green-l) + 20%));--green-750: hsl(calc(var(--green-h) - 6) calc(var(--green-s) - 20%) calc(var(--green-l) + 29%));--green-800: hsl(calc(var(--green-h) - 8) calc(var(--green-s) - 25%) calc(var(--green-l) + 37%));--green-850: hsl(calc(var(--green-h) - 10) calc(var(--green-s) - 30%) calc(var(--green-l) + 42%));--green-900: hsl(calc(var(--green-h) - 12) calc(var(--green-s) - 35%) calc(var(--green-l) + 48%));--yellow-600: hsl(calc(var(--yellow-h) + 1) var(--yellow-s) calc(var(--yellow-l) + 4%));--yellow-650: hsl(calc(var(--yellow-h) + 2) var(--yellow-s) calc(var(--yellow-l) + 7%));--yellow-700: hsl(calc(var(--yellow-h) + 4) var(--yellow-s) calc(var(--yellow-l) + 11%));--yellow-750: hsl(calc(var(--yellow-h) + 6) var(--yellow-s) calc(var(--yellow-l) + 16%));--yellow-800: hsl(calc(var(--yellow-h) + 8) var(--yellow-s) calc(var(--yellow-l) + 20%));--yellow-850: hsl(calc(var(--yellow-h) + 10) var(--yellow-s) calc(var(--yellow-l) + 24%));--yellow-900: hsl(calc(var(--yellow-h) + 12) var(--yellow-s) calc(var(--yellow-l) + 29%));--red-600: hsl(calc(var(--red-h) - 1) calc(var(--red-s) - 5%) calc(var(--red-l) + 3%));--red-650: hsl(calc(var(--red-h) - 2) calc(var(--red-s) - 10%) calc(var(--red-l) + 7%));--red-700: hsl(calc(var(--red-h) - 4) calc(var(--red-s) - 15%) calc(var(--red-l) + 14%));--red-750: hsl(calc(var(--red-h) - 6) calc(var(--red-s) - 20%) calc(var(--red-l) + 19%));--red-800: hsl(calc(var(--red-h) - 8) calc(var(--red-s) - 25%) calc(var(--red-l) + 24%));--red-850: hsl(calc(var(--red-h) - 10) calc(var(--red-s) - 30%) calc(var(--red-l) + 30%));--red-900: hsl(calc(var(--red-h) - 12) calc(var(--red-s) - 35%) calc(var(--red-l) + 36%));--codeblock-bg: var(--gray-100);--background-color: rgba(0, 0, 0, .87);--primary-color: white;--input-border-color: rgba(255, 255, 255, .42);--divider-primary-color: rgba(255, 255, 255, .2);--divider-secondary-color: rgba(255, 255, 255, .1);--primary-contrast-text-color: rgba(0, 0, 0, .87);--active-color: rgba(255, 255, 255, .15);--focus-color: rgba(255, 255, 255, .5);--hover-color: rgba(255, 255, 255, .1);--success-color: var(--success-color-50);--error-color: var(--error-color-50);--warning-color: #fec941;--success-color-5: #004d31;--success-color-10: #066845;--success-color-20: #0d8b5e;--success-color-30: #0e9c69;--success-color-40: #1ba875;--success-color-50: #39c693;--success-color-60: #8ce4c5;--success-color-70: #d2f0e5;--success-color-80: #eafaf4;--success-color-90: #f0fffa;--error-color-5: #680008;--error-color-10: #97000b;--error-color-20: #ce0010;--error-color-30: #ff0013;--error-color-40: #ff3a49;--error-color-50: #ff707a;--error-color-60: #f8a8ae;--error-color-70: #ffd0d4;--error-color-80: #ffedee;--error-color-90: #fff5f6;--contrast-color-5: rgba(255, 255, 255, .05);--contrast-color-10: rgba(255, 255, 255, .1);--contrast-color-20: rgba(255, 255, 255, .2);--contrast-color-30: rgba(255, 255, 255, .3);--contrast-color-40: rgba(255, 255, 255, .4);--contrast-color-50: rgba(255, 255, 255, .5);--contrast-color-60: rgba(255, 255, 255, .6);--contrast-color-70: rgba(255, 255, 255, .7);--contrast-color-80: rgba(255, 255, 255, .8);--contrast-color-90: rgba(255, 255, 255, .9);--contrast-color-100: white;--blue-color: #95c6ff;--violet-color: #cbb4ff}.bg-blue{background-color:var(--blue-color)}.bg-error{background-color:var(--error-color)}.bg-success{background-color:var(--success-color)}.bg-violet{background-color:var(--violet-color)}.bg-warning{background-color:var(--warning-color)}.blue-text{color:var(--blue-color)}.error-text{color:var(--error-color)}.success-text{color:var(--success-color)}.violet-text{color:var(--violet-color)}.warning-text{color:var(--warning-color)}", _c = `vaadin-button{letter-spacing:.25px;padding:var(--vaadin-button-padding)}vaadin-button[focused]{z-index:1}vaadin-button[theme~=icon]{--vaadin-button-height: 2rem;--vaadin-button-padding: 0;width:var(--vaadin-button-height)}vaadin-button vaadin-icon[slot=prefix]{margin-inline-start:-.375rem}vaadin-button vaadin-icon[slot=suffix]{margin-inline-end:-.375rem}vaadin-button[theme~=primary]{min-width:auto}vaadin-button[disabled][theme~=primary]{--vaadin-button-background: var(--vaadin-text-color);--vaadin-button-text-color: var(--vaadin-background-color)}vaadin-button[theme~=lg]{--vaadin-button-height: 2.5rem;--vaadin-icon-size: 1.5rem;--vaadin-icon-visual-size: 1.5rem}vaadin-button[theme~=lg][theme~=icon]{--vaadin-button-height: 2.5rem}vaadin-button[theme~=xl]{--vaadin-button-border-radius: var(--vaadin-radius-l);--vaadin-icon-size: 1.5rem;--vaadin-icon-visual-size: 1.5rem}vaadin-button[theme~=xl][theme~=icon]{--vaadin-button-height: 3rem}vaadin-checkbox::part(checkbox){margin:0}vaadin-combo-box-item{font:var(--copilot-font-sm);gap:var(--vaadin-item-gap);padding:var(--vaadin-item-padding)}.no-checkmark{--vaadin-item-checkmark-display: none;--_lumo-item-selected-icon-display: none}vaadin-context-menu-list-box hr{border-color:var(--vaadin-divider-color);border-width:0 0 1px;margin:.25rem .5rem .25rem calc(var(--vaadin-icon-size) + var(--vaadin-item-gap) + .5rem)}vaadin-context-menu-item{font:var(--copilot-font-sm);gap:var(--vaadin-item-gap);padding:var(--vaadin-item-padding)}vaadin-context-menu-item:is(:hover,[expanded]){background-color:light-dark(var(--gray-3),var(--gray-6))}vaadin-context-menu-item::part(checkmark){display:var(--vaadin-item-checkmark-display)}vaadin-context-menu-item::part(content){display:flex;gap:inherit}vaadin-context-menu-item[aria-haspopup=false]:after{display:none}vaadin-context-menu-item[aria-haspopup=true]:after{background:var(--vaadin-text-color-secondary);color:inherit;content:"";display:block;font:inherit;height:var(--vaadin-icon-size, 1lh);margin:0;mask:var(--_vaadin-icon-chevron-down) 50% / var(--vaadin-icon-visual-size, 100%) no-repeat;padding:0;rotate:-90deg;width:var(--vaadin-icon-size, 1lh)}vaadin-details{margin:0}vaadin-details[theme~=no-padding]::part(content){padding:0}vaadin-details-summary[theme~=reverse]{--vaadin-details-summary-gap: .25rem;--vaadin-details-summary-padding: .375rem .75rem;color:var(--vaadin-text-color-secondary);letter-spacing:var(--copilot-letter-spacing-xs);font:var(--copilot-font-xs-medium);gap:var(--vaadin-details-summary-gap);justify-content:normal;padding:var(--vaadin-details-summary-padding)}vaadin-details-summary[theme~=reverse]::part(toggle){color:inherit;height:auto;margin:0;order:1;width:auto}vaadin-details-summary[theme~=reverse]::part(toggle):before{background:currentColor;content:"";display:block;height:var(--vaadin-icon-size, 1lh);mask:var(--_vaadin-icon-chevron-down) 50% / var(--vaadin-icon-visual-size, 100%) no-repeat;rotate:-90deg;width:var(--vaadin-icon-size, 1lh)}@media (prefers-reduced-motion: no-preference){vaadin-details-summary[theme~=reverse]::part(toggle){transition:.12s}}vaadin-details-summary[theme~=reverse]::part(content){flex-grow:0}vaadin-dialog::part(header){--vaadin-dialog-padding: .5rem .5rem .5rem 1rem}vaadin-dialog::part(footer){--vaadin-dialog-padding: .5rem}vaadin-grid{background-color:var(--vaadin-grid-background)}vaadin-icon{color:inherit;height:var(--vaadin-icon-size, var(--lumo-icon-size-m));width:var(--vaadin-icon-size, var(--lumo-icon-size-m))}:is(vaadin-combo-box,vaadin-radio-group,vaadin-select,vaadin-text-area,vaadin-text-field){padding:0}:is(vaadin-combo-box,vaadin-select){--vaadin-input-field-padding: calc((6 / 16 * 1rem) - var(--vaadin-input-field-border-width)) calc((6 / 16 * 1rem) - var(--vaadin-input-field-border-width)) calc((6 / 16 * 1rem) - var(--vaadin-input-field-border-width)) calc((8 / 16 * 1rem) - var(--vaadin-input-field-border-width))}:is(vaadin-combo-box,vaadin-select,vaadin-text-field):has([slot=prefix]){--vaadin-input-field-padding: calc(.375rem - var(--vaadin-input-field-border-width))}*:not(vaadin-checkbox,vaadin-button)::part(label){letter-spacing:var(--copilot-letter-spacing-xs);line-height:var(--vaadin-input-field-label-line-height);margin-block:0 var(--vaadin-input-field-container-gap);padding:0}::part(input-field){border:var(--vaadin-input-field-border-color) solid var(--vaadin-input-field-border-width);box-shadow:none;gap:var(--vaadin-input-field-gap);padding:var(--vaadin-input-field-padding)}::part(input-field):after{content:none}[readonly]::part(input-field){--vaadin-input-field-border-color: light-dark(var(--gray-9), var(--gray-10));border-style:dashed}[invalid]::part(input-field){--vaadin-input-field-border-color: var(--vaadin-input-field-error-color)}:is(vaadin-combo-box,vaadin-text-field) input{line-height:var(--copilot-line-height-sm);min-height:1lh}:is(vaadin-combo-box,vaadin-number-field,vaadin-text-field) input{padding:0}::part(error-message){--vaadin-icon-size: 1.125rem ;--vaadin-icon-visual-size: 1rem ;line-height:var(--vaadin-input-field-error-line-height);margin:0}[has-error-message]::part(error-message){margin-top:var(--vaadin-input-field-container-gap)}::part(error-message):before{height:auto}::part(error-message):after{content:none}vaadin-text-area textarea{align-self:auto;height:auto;padding:0}::part(input-field):focus-within{outline:var(--vaadin-focus-ring-width) solid var(--vaadin-focus-ring-color);outline-offset:calc(var(--vaadin-input-field-border-width, 1px) * -1)}:is(vaadin-combo-box,vaadin-select,vaadin-text-field)[disabled]{opacity:.5}[disabled]::part(input-field){--vaadin-input-field-border-color: light-dark(var(--gray-9), var(--gray-10))}[theme~=no-border]{--vaadin-input-field-border-width: 0px}[theme~=no-border]:hover{--vaadin-input-field-background: light-dark(var(--gray-4), var(--gray-7))}[theme~=filled]{--vaadin-input-field-background: light-dark(var(--gray-3), var(--gray-6))}[theme~=filled]:hover{--vaadin-input-field-background: light-dark(var(--gray-4), var(--gray-7))}vaadin-menu-bar-item{font:var(--copilot-font-sm)}vaadin-menu-bar-item:after{content:none}vaadin-menu-bar[theme~=dev-tools]{--vaadin-button-border-radius: var(--vaadin-radius-l);--vaadin-overlay-background: linear-gradient(light-dark(var(--gray-1), var(--gray-5)) 0 0) padding-box, linear-gradient(90deg, var(--vaadin-blue), var(--vaadin-violet)) border-box;--vaadin-overlay-border-color: transparent;--vaadin-overlay-border-width: 2px}vaadin-menu-bar-button[theme~=dev-tools]{--vaadin-button-background: transparent;--vaadin-button-border-width: 0;--vaadin-button-height: var(--copilot-size-xl);--vaadin-button-text-color: white;--vaadin-button-padding: 0;--vaadin-icon-size: 1.5rem;--vaadin-icon-visual-size: 1.5rem;min-width:auto;overflow:hidden;position:relative;width:var(--vaadin-button-height)}vaadin-menu-bar-button[theme~=dev-tools]:before{animation:var(--animate-swirl);background-image:radial-gradient(circle at 50% -10%,var(--blue-9) 0%,transparent 60%),radial-gradient(circle at 25% 40%,var(--violet-9) 0%,transparent 70%),radial-gradient(circle at 80% 10%,var(--gray-9) 0%,transparent 80%),radial-gradient(circle at 110% 50%,var(--teal-9) 20%,transparent 100%);border-radius:inherit;content:"";inset:-.375rem;opacity:1;position:absolute}:host(:not([active])) vaadin-menu-bar-button[theme~=dev-tools]:before{animation-duration:10s;background-color:transparent;background-image:radial-gradient(circle at 50% -10%,var(--gray-9) 0%,transparent 60%),radial-gradient(circle at 25% 40%,var(--gray-9) 0%,transparent 70%),radial-gradient(circle at 80% 10%,var(--gray-9) 0%,transparent 80%),radial-gradient(circle at 110% 50%,var(--gray-9) 20%,transparent 100%)}:host([document-hidden]) vaadin-menu-bar-button[theme~=dev-tools]:before{background-color:var(--gray-9);background-image:none}vaadin-menu-bar-button[theme~=dev-tools]:after{background-color:transparent;border:2px solid rgba(255,255,255,.5);border-radius:inherit;content:"";filter:none;inset:0;opacity:1;position:absolute;transform:none;transition:none}vaadin-menu-bar-button[theme~=dev-tools]::part(prefix){margin:0;z-index:1}vaadin-menu-bar-button[theme~=dev-tools]::part(prefix):after{background:currentColor;content:"";display:flex;height:var(--vaadin-icon-visual-size);-webkit-mask-image:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="24" width="24" viewBox="0 0 24 24"><path d="M3 3C2.55 3 2.25 3.3 2.25 3.75V5.625C2.25 7.05 3.45 8.25 4.875 8.25H10.1997C10.7997 8.25 11.25 8.70029 11.25 9.30029V9.75C11.25 10.2 11.55 10.5 12 10.5C12.45 10.5 12.75 10.2 12.75 9.75V9.30029C12.75 8.70029 13.2003 8.25 13.8003 8.25H19.125C20.55 8.25 21.75 7.05 21.75 5.625V3.75C21.75 3.3 21.45 3 21 3C20.55 3 20.25 3.3 20.25 3.75V4.19971C20.25 4.79971 19.7997 5.25 19.1997 5.25H14.25C12.975 5.25 12 6.225 12 7.5C12 6.225 11.025 5.25 9.75 5.25H4.80029C4.20029 5.25 3.75 4.79971 3.75 4.19971V3.75C3.75 3.3 3.45 3 3 3ZM7.76367 11.2705C7.62187 11.2834 7.48184 11.3244 7.35059 11.3994C6.82559 11.6994 6.59941 12.3744 6.89941 12.8994L11.0244 20.3994C11.1744 20.7744 11.625 21 12 21C12.375 21 12.8256 20.7744 12.9756 20.3994L17.1006 12.8994C17.4006 12.3744 17.1744 11.6994 16.6494 11.3994C16.1244 11.0994 15.4494 11.3256 15.1494 11.8506L12 17.5503L8.85059 11.8506C8.62559 11.4568 8.18906 11.2318 7.76367 11.2705Z" fill="currentColor"/></svg>');mask-image:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="24" width="24" viewBox="0 0 24 24"><path d="M3 3C2.55 3 2.25 3.3 2.25 3.75V5.625C2.25 7.05 3.45 8.25 4.875 8.25H10.1997C10.7997 8.25 11.25 8.70029 11.25 9.30029V9.75C11.25 10.2 11.55 10.5 12 10.5C12.45 10.5 12.75 10.2 12.75 9.75V9.30029C12.75 8.70029 13.2003 8.25 13.8003 8.25H19.125C20.55 8.25 21.75 7.05 21.75 5.625V3.75C21.75 3.3 21.45 3 21 3C20.55 3 20.25 3.3 20.25 3.75V4.19971C20.25 4.79971 19.7997 5.25 19.1997 5.25H14.25C12.975 5.25 12 6.225 12 7.5C12 6.225 11.025 5.25 9.75 5.25H4.80029C4.20029 5.25 3.75 4.79971 3.75 4.19971V3.75C3.75 3.3 3.45 3 3 3ZM7.76367 11.2705C7.62187 11.2834 7.48184 11.3244 7.35059 11.3994C6.82559 11.6994 6.59941 12.3744 6.89941 12.8994L11.0244 20.3994C11.1744 20.7744 11.625 21 12 21C12.375 21 12.8256 20.7744 12.9756 20.3994L17.1006 12.8994C17.4006 12.3744 17.1744 11.6994 16.6494 11.3994C16.1244 11.0994 15.4494 11.3256 15.1494 11.8506L12 17.5503L8.85059 11.8506C8.62559 11.4568 8.18906 11.2318 7.76367 11.2705Z" fill="currentColor"/></svg>');width:var(--vaadin-icon-visual-size)}vaadin-menu-bar-button[theme~=dev-tools]::part(label){clip:rect(0,0,0,0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}vaadin-menu-bar-button[theme~=dev-tools]::part(suffix){display:none}vaadin-menu-bar-submenu[theme~=dev-tools]::part(overlay){border:var(--vaadin-overlay-border-width) solid var(--vaadin-overlay-border-color);border-radius:var(--vaadin-overlay-border-radius);margin-bottom:.375rem;min-width:20rem}vaadin-menu-bar-submenu[theme~=dev-tools]::part(content){--vaadin-item-overlay-padding: 1rem;padding:var(--vaadin-item-overlay-padding)}vaadin-menu-bar-submenu[theme~=dev-tools] vaadin-menu-bar-submenu{--vaadin-overlay-background: light-dark(var(--gray-1), var(--gray-5));--vaadin-overlay-border-color: var(--vaadin-divider-color);--vaadin-overlay-border-width: 1px;margin-bottom:0}vaadin-menu-bar-list-box[theme~=dev-tools]{--vaadin-item-checkmark-display: none;--_lumo-list-box-item-selected-icon-display: none}vaadin-menu-bar-item[theme~=dev-tools]{--vaadin-item-padding: .5rem;background-color:var(--vaadin-button-background);font-weight:var(--copilot-font-weight-medium);letter-spacing:var(--copilot-letter-spacing-md);padding:var(--vaadin-item-padding)}vaadin-menu-bar-item[theme~=dev-tools]+vaadin-menu-bar-item{border-top-left-radius:0;border-top-right-radius:0}vaadin-menu-bar-item[theme~=dev-tools]:has(+vaadin-menu-bar-item){border-bottom-left-radius:0;border-bottom-right-radius:0}vaadin-menu-bar-item[theme~=dev-tools]::part(content){display:flex;gap:.5rem}hr[theme~=dev-tools]{margin:.25rem 0;opacity:0}::part(overlay){background:var(--vaadin-overlay-background);color:var(--vaadin-text-color);font-family:var(--copilot-font-family);font-size:var(--copilot-font-size-sm);font-weight:400;letter-spacing:var(--copilot-letter-spacing-sm);line-height:var(--copilot-line-height-sm)}vaadin-popover#dev-tools-popover{--vaadin-popover-background: linear-gradient(light-dark(var(--gray-1), var(--gray-5)) 0 0) padding-box, linear-gradient(90deg, var(--vaadin-blue), var(--vaadin-violet)) border-box;--vaadin-popover-border-color: transparent;--vaadin-popover-border-width: 2px;--vaadin-popover-offset-bottom: .75rem}vaadin-popover#dev-tools-popover::part(arrow){--vaadin-popover-border-color: var(--vaadin-violet);--vaadin-popover-border-width: 2px;border:var(--vaadin-popover-border-width) solid var(--vaadin-popover-border-color);margin-inline-end:.4375rem}vaadin-radio-group[theme~=filled]::part(group-field){background:light-dark(var(--gray-5),var(--gray-7));border-radius:var(--vaadin-radius-s);flex-direction:row;flex-wrap:wrap;gap:.125rem 0;padding:.125rem;width:fit-content}vaadin-radio-group[theme~=filled] vaadin-radio-button{--vaadin-radio-button-gap: 0;border-radius:.125rem}vaadin-radio-group[theme~=filled] vaadin-radio-button:before{content:none}vaadin-radio-group[theme~=filled] vaadin-radio-button[focused]{outline:var(--vaadin-focus-ring-width) solid var(--vaadin-focus-ring-color)}vaadin-radio-group[theme~=filled] vaadin-radio-button::part(radio){display:none}vaadin-radio-group[theme~=filled] vaadin-radio-button label{align-items:center;display:inline-flex;gap:.375rem;padding:.25rem .75rem}vaadin-radio-group[theme~=filled] vaadin-radio-button label:has(vaadin-icon:first-child){padding-inline-start:.5rem}vaadin-radio-group[theme~=filled] vaadin-radio-button[checked]{--vaadin-radio-button-label-color: var(--vaadin-text-color);background:light-dark(var(--gray-1),var(--gray-5))}vaadin-select-value-button{display:flex;padding:0}vaadin-item,vaadin-select-item{--_lumo-selected-item-height: 0;--_lumo-selected-item-padding: 0}vaadin-item[role=option]{font-size:var(--copilot-font-size-sm);gap:var(--vaadin-item-gap);padding:var(--vaadin-item-padding)}vaadin-item,vaadin-select-item{line-height:var(--vaadin-input-field-value-line-height)}vaadin-tab{background:var(--vaadin-tab-background);border-radius:var(--vaadin-tab-border-radius);font-size:var(--vaadin-tab-font-size);font-weight:var(--vaadin-tab-font-weight);line-height:var(--vaadin-tab-line-height);padding:var(--vaadin-tab-padding)}vaadin-tab:before,vaadin-tab:after{content:none}vaadin-tab[selected]{--vaadin-tab-background: light-dark(var(--gray-4), var(--gray-7))}vaadin-tabs{box-shadow:none;min-height:auto;padding:var(--vaadin-tabs-padding)}vaadin-tabs::part(tabs){margin:0}vaadin-tabsheet::part(tabs-container){box-shadow:none}vaadin-tabsheet[theme~=horizontal]{flex-direction:row}vaadin-tabsheet[theme~=horizontal] vaadin-tabs::part(tabs){flex-direction:column}vaadin-tabsheet[theme~=horizontal] vaadin-tab{justify-content:start}vaadin-tabsheet[theme~=horizontal]::part(tabs-container){border-inline-end:1px solid var(--vaadin-divider-color)}`, $c = "vaadin-dialog::part(overlay){background:var(--background-color);-webkit-backdrop-filter:var(--surface-backdrop-filter);backdrop-filter:var(--surface-backdrop-filter);border:1px solid var(--contrast-color-5);border-radius:var(--vaadin-radius-m);box-shadow:var(--surface-box-shadow-1)}vaadin-dialog::part(header){background:none;border-bottom:1px solid var(--divider-primary-color);box-sizing:border-box;font:var(--copilot-font-xs-semibold);min-height:var(--copilot-size-xl);padding:var(--space-50) var(--space-50) var(--space-50) var(--space-150)}vaadin-dialog h2{font:var(--copilot-font-xs-bold);margin:0;padding:0}vaadin-dialog::part(content){font:var(--copilot-font-xs);padding:var(--space-150)}vaadin-dialog::part(footer){background:none;padding:var(--space-100)}vaadin-dialog.ai-dialog::part(overlay){max-width:20rem}vaadin-dialog.ai-dialog::part(header){border:none}vaadin-dialog.ai-dialog [slot=header-content] svg{color:var(--blue-color)}vaadin-dialog.ai-dialog::part(content){display:flex;flex-direction:column;gap:var(--space-200)}vaadin-dialog.ai-dialog p{margin:0}vaadin-dialog.ai-dialog label:has(input[type=checkbox]){align-items:center;display:flex}vaadin-dialog.ai-dialog input[type=checkbox]{height:.875rem;margin:calc((var(--copilot-size-md) - .875rem) / 2);width:.875rem}vaadin-dialog.ai-dialog button.primary{min-width:calc(var(--copilot-size-md) * 2)}vaadin-dialog.drop-api-dialog::part(overlay){width:35em}vaadin-dialog.drop-api-dialog::part(header-content){width:unset;justify-content:unset;flex:unset}vaadin-dialog.drop-api-dialog::part(title){font-size:var(--copilot-font-size-sm)}vaadin-dialog.drop-api-dialog::part(header){border-bottom:unset;justify-content:space-between}vaadin-dialog.drop-api-dialog::part(content){padding:var(--space-100);max-height:250px;overflow:auto}vaadin-dialog.drop-api-dialog div.item-content{display:flex;justify-content:center;align-items:start;flex-direction:column}vaadin-dialog.drop-api-dialog div.method-row-container{display:flex;justify-content:space-between;width:100%;align-items:center}vaadin-dialog.drop-api-dialog div.method-row-container div.class-method-name{padding-left:var(--space-150)}vaadin-dialog.drop-api-dialog div.method-row-container div.action-btn-container{width:150px}vaadin-dialog.drop-api-dialog div.method-row-container div.action-btn-container button.action-btn.selected{color:var(--selection-color)}vaadin-dialog.edit-component-dialog{width:25em}vaadin-dialog.edit-component-dialog #component-icon{width:75px}vaadin-dialog#report-exception-dialog{z-index:calc(var(--copilot-notifications-container-z-index) + 1)}vaadin-dialog#report-exception-dialog::part(overlay){height:600px}vaadin-dialog#report-exception-dialog vaadin-text-area{width:100%;min-height:120px}vaadin-dialog#report-exception-dialog .list-preview-container{display:flex;flex-direction:row;gap:var(--space-100);margin-top:var(--space-50)}vaadin-dialog#report-exception-dialog .left-menu{display:flex;flex-direction:column;min-width:200px;width:200px}vaadin-dialog#report-exception-dialog .right-menu{display:flex;flex-direction:column;white-space:break-spaces;overflow:auto;border-radius:var(--vaadin-radius-m);align-items:start;height:300px;width:800px}vaadin-dialog#report-exception-dialog .right-menu pre{margin:0}vaadin-dialog#report-exception-dialog vaadin-item div.item-content{display:inline-block}vaadin-dialog#report-exception-dialog vaadin-item div.item-content span{max-width:150px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;display:block}vaadin-dialog#report-exception-dialog vaadin-item div.item-content span.item-description{color:var(--vaadin-text-color-secondary)}vaadin-dialog#report-exception-dialog vaadin-item[selected]{background-color:var(--active-color);border-left:2px solid var(--primary-color)}vaadin-dialog#report-exception-dialog vaadin-item::part(content){display:flex;align-items:center;gap:var(--space-100)}vaadin-dialog#report-exception-dialog vaadin-item::part(checkmark){display:none}vaadin-dialog#report-exception-dialog div.section-title{color:var(--vaadin-text-color-secondary);padding-top:var(--space-50);padding-bottom:var(--space-50)}vaadin-dialog#report-exception-dialog code.codeblock{width:100%;box-sizing:border-box;overflow:auto;text-overflow:unset}", ed = ":is(vaadin-context-menu,vaadin-menu-bar,vaadin-select){z-index:var(--z-index-popover)}", td = "", rd = `:host{--vaadin-radius-s: .25rem ;--vaadin-radius-m: .5rem ;--vaadin-radius-l: .75rem ;--copilot-size-sm: 1.75rem;--copilot-size-md: 2rem;--copilot-size-lg: 2.5rem;--copilot-size-xl: 3rem;--vaadin-focus-ring-width: 2px;--vaadin-button-background: light-dark(var(--gray-3), var(--gray-6));--vaadin-button-gap: .375rem ;--vaadin-button-margin: 0;--vaadin-button-padding: .375rem .75rem ;--vaadin-button-font-size: var(--copilot-font-size-sm);--vaadin-button-primary-background: var(--vaadin-text-color);--vaadin-button-primary-font-weight: 500;--vaadin-button-primary-text-color: var(--vaadin-background-color);--_vaadin-button-disabled-pointer-events: all;--vaadin-checkbox-background: transparent;--vaadin-checkbox-border-radius: .125rem ;--vaadin-checkbox-font-weight: 400;--vaadin-checkbox-size: 1rem ;--vaadin-checkbox-label-color: var(--vaadin-text-color);--vaadin-checkbox-label-font-size: .8125rem ;--vaadin-checkbox-label-line-height: 1.25rem ;--vaadin-checkbox-checkmark-color: var(--vaadin-background-color);--vaadin-checkbox-label-padding: 0 .5rem ;--vaadin-icon-size: 1.25rem ;--vaadin-icon-visual-size: 1.125rem ;--_vaadin-icon-chevron-down: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 -960 960 960" width="24px" fill="currentColor"><path d="M480-344 240-584l56-56 184 184 184-184 56 56-240 240Z"/></svg>');--vaadin-input-field-background: transparent;--vaadin-input-field-border-color: light-dark(var(--gray-9), var(--gray-10));--vaadin-input-field-border-radius: var(--vaadin-radius-s);--vaadin-input-field-border-width: 1px;--vaadin-input-field-container-gap: .25rem ;--vaadin-input-field-disabled-background: transparent;--vaadin-input-field-disabled-text-color: var(--vaadin-text-color-secondary);--vaadin-input-field-gap: .375rem ;--vaadin-input-field-height: auto;--vaadin-input-field-invalid-background: transparent;--vaadin-input-field-autofill-color: var(--vaadin-text-color);--vaadin-padding-block-container: calc((6 / 16 * 1rem) - var(--vaadin-input-field-border-width));--vaadin-padding-inline-container: calc((8 / 16 * 1rem) - var(--vaadin-input-field-border-width));--vaadin-input-field-padding: var(--vaadin-padding-block-container) var(--vaadin-padding-inline-container);--vaadin-input-field-label-color: var(--vaadin-text-color-secondary);--vaadin-input-field-label-font-size: .75rem ;--vaadin-input-field-label-font-weight: normal;--vaadin-input-field-label-line-height: 1.125rem ;--vaadin-input-field-value-font-size: var(--copilot-font-size-sm);--vaadin-input-field-value-font-weight: 400;--vaadin-input-field-value-line-height: var(--copilot-line-height-sm);--vaadin-input-field-helper-font-size: var(--copilot-font-size-xs);--vaadin-input-field-helper-line-height: var(--copilot-line-height-xs);--vaadin-input-field-helper-spacing: .25rem ;--vaadin-input-field-error-color: var(--ruby-11);--vaadin-input-field-error-font-size: var(--copilot-font-size-xs);--vaadin-input-field-error-line-height: var(--copilot-line-height-xs);--vaadin-item-border-radius: var(--vaadin-radius-m);--vaadin-item-gap: .5rem;--vaadin-item-padding: .375rem .5rem;--vaadin-overlay-background: light-dark(var(--gray-1), var(--gray-5));--vaadin-overlay-border-color: var(--vaadin-divider-color);--vaadin-overlay-border-radius: var(--vaadin-radius-l);--vaadin-overlay-border-width: 1px;--vaadin-popover-border-radius: var(--vaadin-radius-l);--vaadin-radio-button-font-weight: 500;--vaadin-radio-button-label-font-size: .8125rem ;--vaadin-radio-button-label-line-height: 1.25rem ;--vaadin-tab-background: transparent;--vaadin-tab-border-radius: var(--vaadin-radius-m);--vaadin-tab-font-size: var(--copilot-font-size-sm);--vaadin-tab-font-weight: var(--copilot-font-weight-medium);--vaadin-tab-line-height: var(--copilot-line-height-sm);--vaadin-tab-padding: .375rem .5rem ;--vaadin-tabs-gap: .25rem ;--vaadin-tabs-padding: 0 .5rem ;--vaadin-tabsheet-padding: 0;--vaadin-tooltip-background: var(--gray-3);--vaadin-tooltip-border-color: var(--vaadin-divider-color);--monospace-font-family: Inconsolata, Monaco, Consolas, Courier New, Courier, monospace;--z-index-component-selector: 100;--z-index-floating-panel: 101;--z-index-drawer: 150;--z-index-opened-drawer: 151;--z-index-spotlight: 200;--z-index-popover: 300;--z-index-activation-button: 1000;--copilot-notifications-container-z-index: 10000;--duration-1: .1s;--duration-2: .2s;--duration-3: .3s;--duration-4: .4s;--button-background: var(--gray-100);--button-background-hover: var(--gray-150);--focus-size: 2px;--icon-size-xs: .75rem;--icon-size-s: 1rem;--icon-size-m: 1.125rem;--shadow-xs: 0 1px 2px 0 rgb(0 0 0 / .05);--shadow-s: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--shadow-m: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--shadow-l: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--shadow-xl: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / .25);--copilot-size-xs: 1.25rem;--space-25: 2px;--space-50: 4px;--space-75: 6px;--space-100: 8px;--space-150: 12px;--space-200: 16px;--space-300: 24px;--space-400: 32px;--space-450: 36px;--space-500: 40px;--space-600: 48px;--space-700: 56px;--space-800: 64px;--space-900: 72px}:host{--lumo-font-family: var(--copilot-font-family);--lumo-font-size-xs: var(--copilot-font-size-xs);--lumo-font-size-s: var(--copilot-font-size-sm);--lumo-border-radius-s: var(--vaadin-radius-s);--lumo-border-radius-m: var(--vaadin-radius-m);--lumo-border-radius-l: var(--vaadin-radius-l);--lumo-base-color: var(--surface-0);--lumo-header-text-color: var(--color-high-contrast);--lumo-tertiary-text-color: var(--color);--lumo-primary-text-color: var(--color-high-contrast);--lumo-primary-color: var(--color-high-contrast);--lumo-primary-color-50pct: var(--color-accent);--lumo-primary-contrast-color: var(--lumo-secondary-text-color);--lumo-space-xs: var(--space-50);--lumo-space-s: var(--space-100);--lumo-space-m: var(--space-200);--lumo-space-l: var(--space-300);--lumo-space-xl: var(--space-500);--lumo-icon-size-xs: var(--copilot-font-size-xs);--lumo-icon-size-s: var(--copilot-font-size-sm);--lumo-icon-size-m: var(--copilot-font-size-md);--lumo-font-size-m: var(--copilot-font-size-xs);--lumo-body-text-color: var(--vaadin-text-color);--lumo-secondary-text-color: var(--vaadin-text-color-secondary);--lumo-error-text-color: var(--error-color);--lumo-size-m: var(--copilot-size-md);--source-file-link-color: var(--blue-600);--source-file-link-decoration-color: currentColor;--source-file-link-text-decoration: none;--source-file-link-font-weight: normal;--source-file-link-button-color: currentColor;--vaadin-button-height: var(--lumo-button-size, var(--lumo-size-m))}:host{color-scheme:light;--surface-0: hsl(var(--gray-h) var(--gray-s) 90% / .8);--surface-1: hsl(var(--gray-h) var(--gray-s) 95% / .8);--surface-2: hsl(var(--gray-h) var(--gray-s) 100% / .8);--surface-background: linear-gradient( hsl(var(--gray-h) var(--gray-s) 95% / .7), hsl(var(--gray-h) var(--gray-s) 95% / .65) );--surface-glow: radial-gradient(circle at 30% 0%, hsl(var(--gray-h) var(--gray-s) 98% / .7), transparent 50%);--surface-border-glow: radial-gradient(at 50% 50%, hsl(var(--purple-h) 90% 90% / .8) 0, transparent 50%);--surface: var(--surface-glow) no-repeat border-box, var(--surface-background) no-repeat padding-box, hsl(var(--gray-h) var(--gray-s) 98% / .2);--surface-with-border-glow: var(--surface-glow) no-repeat border-box, linear-gradient(var(--background-color), var(--background-color)) no-repeat padding-box, var(--surface-border-glow) no-repeat border-box 0 0 / var(--glow-size, 600px) var(--glow-size, 600px);--surface-border-color: hsl(var(--gray-h) var(--gray-s) 100% / .7);--surface-backdrop-filter: blur(10px);--surface-box-shadow-1: 0 0 0 .5px hsl(var(--gray-h) var(--gray-s) 5% / .15), 0 6px 12px -1px hsl(var(--shadow-hsl) / .3);--surface-box-shadow-2: 0 0 0 .5px hsl(var(--gray-h) var(--gray-s) 5% / .15), 0 24px 40px -4px hsl(var(--shadow-hsl) / .4);--background-button: linear-gradient( hsl(var(--gray-h) var(--gray-s) 98% / .4), hsl(var(--gray-h) var(--gray-s) 90% / .2) );--background-button-active: hsl(var(--gray-h) var(--gray-s) 80% / .2);--color: var(--gray-500);--color-high-contrast: var(--gray-900);--color-accent: var(--purple-700);--color-danger: var(--red-700);--border-color: var(--gray-150);--border-color-high-contrast: var(--gray-300);--border-color-button: var(--gray-350);--border-color-popover: hsl(var(--gray-hsl) / .08);--border-color-dialog: hsl(var(--gray-hsl) / .08);--accent-color: var(--purple-600);--selection-color: hsl(var(--blue-hsl));--shadow-hsl: var(--gray-h) var(--gray-s) 20%;--lumo-contrast-5pct: var(--gray-100);--lumo-contrast-10pct: var(--gray-200);--lumo-contrast-60pct: var(--gray-400);--lumo-contrast-80pct: var(--gray-600);--lumo-contrast-90pct: var(--gray-800);--card-bg: rgba(255, 255, 255, .5);--card-hover-bg: rgba(255, 255, 255, .65);--card-open-bg: rgba(255, 255, 255, .8);--card-border: 1px solid rgba(0, 50, 100, .15);--card-open-shadow: 0px 1px 4px -1px rgba(28, 52, 84, .26);--card-section-border: var(--card-border);--card-field-bg: var(--lumo-contrast-5pct);--indicator-border: white}:host(.dark){color-scheme:dark;--surface-0: hsl(var(--gray-h) var(--gray-s) 10% / .85);--surface-1: hsl(var(--gray-h) var(--gray-s) 14% / .85);--surface-2: hsl(var(--gray-h) var(--gray-s) 18% / .85);--surface-background: linear-gradient( hsl(var(--gray-h) var(--gray-s) 8% / .65), hsl(var(--gray-h) var(--gray-s) 8% / .7) );--surface-glow: radial-gradient( circle at 30% 0%, hsl(var(--gray-h) calc(var(--gray-s) * 2) 90% / .12), transparent 50% );--surface: var(--surface-glow) no-repeat border-box, var(--surface-background) no-repeat padding-box, hsl(var(--gray-h) var(--gray-s) 20% / .4);--surface-border-glow: hsl(var(--gray-h) var(--gray-s) 20% / .4) radial-gradient(at 50% 50%, hsl(250 40% 80% / .4) 0, transparent 50%);--surface-border-color: hsl(var(--gray-h) var(--gray-s) 50% / .2);--surface-box-shadow-1: 0 0 0 .5px hsl(var(--purple-h) 40% 5% / .4), 0 6px 12px -1px hsl(var(--shadow-hsl) / .4);--surface-box-shadow-2: 0 0 0 .5px hsl(var(--purple-h) 40% 5% / .4), 0 24px 40px -4px hsl(var(--shadow-hsl) / .5);--color: var(--gray-650);--background-button: linear-gradient( hsl(var(--gray-h) calc(var(--gray-s) * 2) 80% / .1), hsl(var(--gray-h) calc(var(--gray-s) * 2) 80% / 0) );--background-button-active: hsl(var(--gray-h) var(--gray-s) 10% / .1);--border-color-popover: hsl(var(--gray-h) var(--gray-s) 90% / .1);--border-color-dialog: hsl(var(--gray-h) var(--gray-s) 90% / .1);--shadow-hsl: 0 0% 0%;--lumo-disabled-text-color: var(--lumo-contrast-60pct);--card-bg: rgba(255, 255, 255, .05);--card-hover-bg: rgba(255, 255, 255, .065);--card-open-bg: rgba(255, 255, 255, .1);--card-border: 1px solid rgba(255, 255, 255, .11);--card-open-shadow: 0px 1px 4px -1px rgba(0, 0, 0, .26);--card-section-border: var(--card-border);--card-field-bg: var(--lumo-contrast-10pct);--indicator-border: var(--lumo-base-color)}`, nd = '@font-face{font-display:swap;font-family:Roboto;font-style:normal;font-weight:400 700;src:url(data:font/woff2;base64, ) format("woff2")}:host{--copilot-font-family: "Roboto", sans-serif;--copilot-font-size: .8125rem ;--copilot-letter-spacing: .25px;--copilot-line-height: 1.25rem ;--copilot-font-size-xs: .75rem;--copilot-font-size-sm: .8125rem;--copilot-font-size-md: .9375rem;--copilot-font-size-lg: 1.375rem;--copilot-font-size-xl: 1.5rem;--copilot-letter-spacing-xs: .4px;--copilot-letter-spacing-sm: .25px;--copilot-letter-spacing-md: .15px;--copilot-letter-spacing-lg: 0;--copilot-letter-spacing-xl: 0;--copilot-line-height-xs: 1.125rem;--copilot-line-height-sm: 1.25rem;--copilot-line-height-md: 1.5rem;--copilot-line-height-lg: 1.75rem;--copilot-line-height-xl: 2rem;--copilot-font-weight-normal: 400;--copilot-font-weight-medium: 500;--copilot-font-weight-semibold: 600;--copilot-font-weight-bold: 700;--copilot-font-xs: normal var(--copilot-font-weight-normal) var(--copilot-font-size-xs) / var(--copilot-line-height-xs) var(--copilot-font-family);--copilot-font-xs-medium: normal var(--copilot-font-weight-medium) var(--copilot-font-size-xs) / var(--copilot-line-height-xs) var(--copilot-font-family);--copilot-font-xs-semibold: normal var(--copilot-font-weight-semibold) var(--copilot-font-size-xs) / var(--copilot-line-height-xs) var(--copilot-font-family);--copilot-font-xs-bold: normal var(--copilot-font-weight-bold) var(--copilot-font-size-xs) / var(--copilot-line-height-xs) var(--copilot-font-family);--copilot-font-sm: normal var(--copilot-font-weight-normal) var(--copilot-font-size-sm) / var(--copilot-line-height-sm) var(--copilot-font-family);--copilot-font-sm-medium: normal var(--copilot-font-weight-medium) var(--copilot-font-size-sm) / var(--copilot-line-height-sm) var(--copilot-font-family);--copilot-font-sm-semibold: normal var(--copilot-font-weight-semibold) var(--copilot-font-size-sm) / var(--copilot-line-height-sm) var(--copilot-font-family);--copilot-font-sm-bold: normal var(--copilot-font-weight-bold) var(--copilot-font-size-sm) / var(--copilot-line-height-sm) var(--copilot-font-family);--copilot-font-md: normal var(--copilot-font-weight-normal) var(--copilot-font-size-md) / var(--copilot-line-height-md) var(--copilot-font-family);--copilot-font-md-medium: normal var(--copilot-font-weight-medium) var(--copilot-font-size-md) / var(--copilot-line-height-md) var(--copilot-font-family);--copilot-font-md-semibold: normal var(--copilot-font-weight-semibold) var(--copilot-font-size-md) / var(--copilot-line-height-md) var(--copilot-font-family);--copilot-font-md-bold: normal var(--copilot-font-weight-bold) var(--copilot-font-size-md) / var(--copilot-line-height-md) var(--copilot-font-family);--copilot-font-button: normal var(--copilot-font-weight-semibold) var(--copilot-font-size-sm) / var(--copilot-line-height-sm) var(--copilot-font-family);--copilot-font-tooltip: normal var(--copilot-font-weight-medium) var(--copilot-font-size-sm) / var(--copilot-line-height-sm) var(--copilot-font-family)}', id = ".items-baseline{align-items:baseline}.items-center{align-items:center}.items-end{align-items:end}.items-start{align-items:start}.self-start{align-self:start}.animate-spin{animation:var(--animate-spin)}.animate-swirl{animation:var(--animate-swirl)}.bg-amber-3{background-color:var(--amber-3)}.bg-blue-3{background-color:var(--blue-3)}.bg-blue-11{background-color:var(--blue-11)}.bg-cover{background-size:cover}.bg-current{background-color:currentColor}.bg-gray-1{background-color:var(--gray-1)}.bg-gray-1\\/90{background-color:color-mix(in oklab,var(--gray-1) 90%,transparent)}.bg-gray-3{background-color:var(--gray-3)}.focus-within\\:bg-gray-3:focus-within{background-color:var(--gray-3)}.hover\\:bg-gray-3:hover{background-color:var(--gray-3)}.bg-gray-4{background-color:var(--gray-4)}.bg-gray-5{background-color:var(--gray-5)}.bg-ruby-3{background-color:var(--ruby-3)}@media (prefers-color-scheme: dark){.dark\\:bg-amber-5{background-color:var(--amber-5)}.dark\\:bg-amber-6{background-color:var(--amber-6)}.dark\\:bg-blue-5{background-color:var(--blue-5)}.dark\\:bg-blue-6{background-color:var(--blue-6)}.dark\\:bg-gray-2\\/90{background-color:color-mix(in oklab,var(--gray-2) 90%,transparent)}.dark\\:bg-gray-3\\/90{background-color:color-mix(in oklab,var(--gray-3) 90%,transparent)}.dark\\:bg-gray-4\\/90{background-color:color-mix(in oklab,var(--gray-4) 90%,transparent)}.dark\\:bg-gray-5{background-color:var(--gray-5)}.dark\\:bg-gray-5\\/90{background-color:color-mix(in oklab,var(--gray-5) 90%,transparent)}.dark\\:bg-gray-6{background-color:var(--gray-6)}.dark\\:focus-within\\:bg-gray-6:focus-within{background-color:var(--gray-6)}.dark\\:hover\\:bg-gray-6:hover{background-color:var(--gray-6)}.dark\\:bg-gray-7{background-color:var(--gray-7)}.dark\\:bg-ruby-6{background-color:var(--ruby-6)}.dark\\:bg-ruby-7{background-color:var(--ruby-7)}}.border{border:1px var(--border-style, solid) var(--border-color, var(--vaadin-divider-color))}.border-dashed{--border-style: dashed}.border-2{border-width:2px}.border-b{border-bottom:1px var(--border-style, solid) var(--border-color, var(--vaadin-divider-color))}.border-e-0{border-inline-end:none}.border-s-0{border-inline-start:none}.border-t{border-top:1px var(--border-style, solid) var(--border-color, var(--vaadin-divider-color))}.border-t-0{border-top:none}.border-amber-9{border-color:var(--amber-9)}.border-black\\/50{border-color:#00000080}.border-white\\/50{border-color:#ffffff80}.rounded-full{border-radius:9999px}.rounded-s-none{border-end-start-radius:0;border-start-start-radius:0}.rounded-sm{border-radius:var(--vaadin-radius-s)}.rounded-md{border-radius:var(--vaadin-radius-m)}.rounded-lg{border-radius:var(--vaadin-radius-l)}.shadow-2xs{box-shadow:0 1px #0000000d}.shadow-xs{box-shadow:0 1px 2px #0000000d}.shadow-sm{box-shadow:0 1px 3px #0000001a,0 1px 2px -1px #0000001a}.shadow-md{box-shadow:0 4px 6px -1px #0000001a,0 2px 4px -2px #0000001a}.shadow-lg{box-shadow:0 10px 15px -3px #0000001a,0 4px 6px -4px #0000001a}.shadow-xl{box-shadow:0 20px 25px -5px #0000001a,0 8px 10px -6px #0000001a}.shadow-2xl{box-shadow:0 25px 50px -12px #00000040}.shadow-none{box-shadow:0 0 #0000}.box-border{box-sizing:border-box}.box-content{box-sizing:content-box}.text-amber-11{color:var(--amber-11)}.text-amber-12{color:var(--amber-12)}.text-blue-11{color:var(--blue-11)}.text-blue-12{color:var(--blue-12)}.text-body{color:var(--vaadin-text-color)}.text-ruby-11{color:var(--ruby-11)}.text-secondary{color:var(--vaadin-text-color-secondary)}.text-teal-11{color:var(--teal-11)}.text-violet-11{color:var(--violet-11)}.text-white{color:#fff}@media (prefers-color-scheme: dark){.dark\\:text-amber-11{color:var(--amber-11)}.dark\\:text-amber-12{color:var(--amber-12)}.dark\\:text-blue-12{color:var(--blue-12)}}.cursor-inherit{cursor:inherit}.text-blue{color:var(--blue-color)}.text-blue-violet{background-clip:text;background-image:linear-gradient(90deg,var(--blue-color),var(--violet-color));color:transparent}.text-inherit{color:inherit}.text-white,.hover\\:text-white:hover{color:#fff}.contents{display:contents}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline-flex{display:inline-flex}.divide-y>:not(:last-child){border-bottom:1px solid var(--vaadin-divider-color)}.backdrop-blur-xs{-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}.backdrop-blur-sm{-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}.backdrop-blur-md{-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px)}.backdrop-blur-lg{-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px)}.backdrop-blur-xl{-webkit-backdrop-filter:blur(24px);backdrop-filter:blur(24px)}.backdrop-blur-2xl{-webkit-backdrop-filter:blur(40px);backdrop-filter:blur(40px)}.backdrop-blur-3xl{-webkit-backdrop-filter:blur(64px);backdrop-filter:blur(64px)}.flex-1{flex:1}.flex-col{flex-direction:column}.flex-grow{flex-grow:1}.font-sans{font-family:var(--copilot-font-family),sans-serif}.text-xs{font:var(--copilot-font-xs);letter-spacing:var(--copilot-letter-spacing-xs)}.text-sm{font:var(--copilot-font-sm);letter-spacing:var(--copilot-letter-spacing-sm)}.text-md{font:var(--copilot-font-md);letter-spacing:var(--copilot-letter-spacing-md)}.text-1{font-size:var(--copilot-font-size-xs);line-height:var(--copilot-line-height-sm)}.font-normal{font-weight:var(--copilot-font-weight-normal)}.font-medium{font-weight:var(--copilot-font-weight-medium)}.font-semibold{font-weight:var(--copilot-font-weight-semibold)}.font-bold{font-weight:var(--copilot-font-weight-bold)}.gap-1{gap:.25rem}.gap-1\\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-x-1{column-gap:.25rem}.gap-x-2{column-gap:.5rem}.gap-x-3{column-gap:.75rem}.gap-x-4{column-gap:1rem}.gap-y-1{row-gap:.25rem}.gap-y-2{row-gap:.5rem}.gap-y-3{row-gap:.75rem}.gap-y-4{row-gap:1rem}.gap-25{gap:var(--space-25)}.gap-50{gap:var(--space-50)}.gap-75{gap:var(--space-75)}.gap-100{gap:var(--space-100)}.gap-150{gap:var(--space-150)}.gap-200{gap:var(--space-200)}.gap-300{gap:var(--space-300)}.gap-400{gap:var(--space-400)}.icon-s svg{height:var(--icon-size-s);width:var(--icon-size-s)}.col-span-full{grid-column:1 / -1}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.justify-center{justify-content:center}.justify-end{justify-content:end}.justify-start{justify-content:start}.list-none{list-style-type:none}.m-0{margin:0}.m-2{margin:.5rem}.m-3{margin:.75rem}.m-4{margin:1rem}.-m-2{margin:-.5rem}.mb-0{margin-bottom:0}.mb-1{margin-bottom:.25rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.me-auto{margin-inline-end:auto}.-me-2{margin-inline-end:-.5rem}.ms-auto{margin-inline-start:auto}.ms-1{margin-inline-start:.25rem}.ms-2{margin-inline-start:.5rem}.-ms-0\\.5{margin-inline-start:-.125rem}.mt-0{margin-top:0}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mx-1{margin-inline:.25rem}.mx-2{margin-inline:.5rem}.mx-3{margin-inline:.75rem}.mx-4{margin-inline:1rem}.my-0{margin-block:0}.my-px{margin-block:1px}.-my-1\\.5{margin-block:-.375rem}.-my-2{margin-block:-.5rem}.m-25{margin:var(--space-25)}.m-50{margin:var(--space-50)}.m-75{margin:var(--space-75)}.m-100{margin:var(--space-100)}.m-150{margin:var(--space-150)}.m-200{margin:var(--space-200)}.m-300{margin:var(--space-300)}.m-400{margin:var(--space-400)}.mb-25{margin-bottom:var(--space-25)}.mb-50{margin-bottom:var(--space-50)}.mb-75{margin-bottom:var(--space-75)}.mb-100{margin-bottom:var(--space-100)}.mb-150{margin-bottom:var(--space-150)}.mb-200{margin-bottom:var(--space-200)}.mb-300{margin-bottom:var(--space-300)}.mb-400{margin-bottom:var(--space-400)}.me-25{margin-inline-end:var(--space-25)}.me-50{margin-inline-end:var(--space-50)}.me-75{margin-inline-end:var(--space-75)}.me-100{margin-inline-end:var(--space-100)}.me-150{margin-inline-end:var(--space-150)}.me-200{margin-inline-end:var(--space-200)}.me-300{margin-inline-end:var(--space-300)}.me-400{margin-inline-end:var(--space-400)}.-me-25{margin-inline-end:calc(var(--space-25) * -1)}.-me-50{margin-inline-end:calc(var(--space-50) * -1)}.-me-75{margin-inline-end:calc(var(--space-75) * -1)}.-me-100{margin-inline-end:calc(var(--space-100) * -1)}.-me-150{margin-inline-end:calc(var(--space-150) * -1)}.-me-200{margin-inline-end:calc(var(--space-200) * -1)}.-me-300{margin-inline-end:calc(var(--space-300) * -1)}.-me-400{margin-inline-end:calc(var(--space-400) * -1)}.ms-25{margin-inline-start:var(--space-25)}.ms-50{margin-inline-start:var(--space-50)}.ms-75{margin-inline-start:var(--space-75)}.ms-100{margin-inline-start:var(--space-100)}.ms-150{margin-inline-start:var(--space-150)}.ms-200{margin-inline-start:var(--space-200)}.ms-300{margin-inline-start:var(--space-300)}.ms-400{margin-inline-start:var(--space-400)}.-ms-25{margin-inline-start:calc(var(--space-25) / -1)}.-ms-50{margin-inline-start:calc(var(--space-50) / -1)}.-ms-75{margin-inline-start:calc(var(--space-75) / -1)}.-ms-100{margin-inline-start:calc(var(--space-100) / -1)}.-ms-150{margin-inline-start:calc(var(--space-150) / -1)}.-ms-200{margin-inline-start:calc(var(--space-200) / -1)}.-ms-300{margin-inline-start:var(--space-300)}.-ms-400{margin-inline-start:var(--space-400)}.mt-25{margin-top:var(--space-25)}.mt-50{margin-top:var(--space-50)}.mt-75{margin-top:var(--space-75)}.mt-100{margin-top:var(--space-100)}.mt-150{margin-top:var(--space-150)}.mt-200{margin-top:var(--space-200)}.mt-300{margin-top:var(--space-300)}.mt-400{margin-top:var(--space-400)}.-mt-25{margin-top:calc(var(--space-25) * -1)}.-mt-50{margin-top:calc(var(--space-50) * -1)}.-mt-75{margin-top:calc(var(--space-75) * -1)}.-mt-100{margin-top:calc(var(--space-100) * -1)}.-mt-150{margin-top:calc(var(--space-150) * -1)}.-mt-200{margin-top:calc(var(--space-200) * -1)}.-mt-300{margin-top:calc(var(--space-300) * -1)}.-mt-400{margin-top:calc(var(--space-400) * -1)}.mx-25{margin-inline:var(--space-25)}.mx-50{margin-inline:var(--space-50)}.mx-75{margin-inline:var(--space-75)}.mx-100{margin-inline:var(--space-100)}.mx-150{margin-inline:var(--space-150)}.mx-200{margin-inline:var(--space-200)}.mx-300{margin-inline:var(--space-300)}.mx-400{margin-inline:var(--space-400)}.my-25{margin-block:var(--space-25)}.my-50{margin-block:var(--space-50)}.my-75{margin-block:var(--space-75)}.my-100{margin-block:var(--space-100)}.my-150{margin-block:var(--space-150)}.my-200{margin-block:var(--space-200)}.my-300{margin-block:var(--space-300)}.my-400{margin-block:var(--space-400)}.-my-25{margin-block:calc(var(--space-25) * -1)}.-my-50{margin-block:calc(var(--space-50) * -1)}.-my-75{margin-block:calc(var(--space-75) * -1)}.-my-100{margin-block:calc(var(--space-100) * -1)}.-my-150{margin-block:calc(var(--space-150) * -1)}.-my-200{margin-block:calc(var(--space-200) * -1)}.-my-300{margin-block:calc(var(--space-300) * -1)}.-my-400{margin-block:calc(var(--space-400) * -1)}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-100{opacity:1}.group:hover .group-hover\\:opacity-0{opacity:0}.group:hover .group-hover\\:opacity-100{opacity:1}.group:focus-within .group-focus-within\\:opacity-0{opacity:0}.group:focus-within .group-focus-within\\:opacity-100{opacity:1}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.overflow-y-hidden{overflow-y:hidden}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.p-0{padding:0}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.pb-1\\.5{padding-bottom:.375rem}.pb-2{padding-bottom:.5rem}.pb-3{padding-bottom:.75rem}.pb-4{padding-bottom:1rem}.pe-1{padding-inline-end:.25rem}.pe-1\\.75{padding-inline-end:.4375rem}.pe-2{padding-inline-end:.5rem}.pe-3{padding-inline-end:.75rem}.pe-4{padding-inline-end:1rem}.pe-5{padding-inline-end:1.25rem}.pe-6{padding-inline-end:1.5rem}.pe-7{padding-inline-end:1.75rem}.pe-8{padding-inline-end:2rem}.ps-0\\.5{padding-inline-start:.125rem}.ps-1{padding-inline-start:.25rem}.ps-1\\.75{padding-inline-start:.4375rem}.ps-2{padding-inline-start:.5rem}.ps-3{padding-inline-start:.75rem}.ps-3\\.75{padding-inline-start:.9375rem}.ps-4{padding-inline-start:1rem}.pt-1{padding-top:.25rem}.px-0{padding-inline:0}.px-1{padding-inline:.25rem}.px-1\\.5{padding-inline:.375rem}.px-2{padding-inline:.5rem}.px-3{padding-inline:.75rem}.px-4{padding-inline:1rem}.py-1{padding-block:.25rem}.py-1\\.5{padding-block:.375rem}.py-1\\.75{padding-block:.4375rem}.py-2{padding-block:.5rem}.py-2\\.5{padding-block:.625rem}.py-3{padding-block:.75rem}.p-25{padding:var(--space-25)}.p-50{padding:var(--space-50)}.p-75{padding:var(--space-75)}.p-100{padding:var(--space-100)}.p-150{padding:var(--space-150)}.p-200{padding:var(--space-200)}.p-300{padding:var(--space-300)}.p-400{padding:var(--space-400)}.pb-25{padding-bottom:var(--space-25)}.pb-50{padding-bottom:var(--space-50)}.pb-75{padding-bottom:var(--space-75)}.pb-100{padding-bottom:var(--space-100)}.pb-150{padding-bottom:var(--space-150)}.pb-200{padding-bottom:var(--space-200)}.pb-300{padding-bottom:var(--space-300)}.pb-400{padding-bottom:var(--space-400)}.pe-25{padding-inline-end:var(--space-25)}.pe-50{padding-inline-end:var(--space-50)}.pe-75{padding-inline-end:var(--space-75)}.pe-100{padding-inline-end:var(--space-100)}.pe-150{padding-inline-end:var(--space-150)}.pe-200{padding-inline-end:var(--space-200)}.pe-300{padding-inline-end:var(--space-300)}.pe-400{padding-inline-end:var(--space-400)}.ps-25{padding-inline-start:var(--space-25)}.ps-50{padding-inline-start:var(--space-50)}.ps-75{padding-inline-start:var(--space-75)}.ps-100{padding-inline-start:var(--space-100)}.ps-150{padding-inline-start:var(--space-150)}.ps-200{padding-inline-start:var(--space-200)}.ps-300{padding-inline-start:var(--space-300)}.ps-400{padding-inline-start:var(--space-400)}.pt-25{padding-top:var(--space-25)}.pt-50{padding-top:var(--space-50)}.pt-75{padding-top:var(--space-75)}.pt-100{padding-top:var(--space-100)}.pt-150{padding-top:var(--space-150)}.pt-200{padding-top:var(--space-200)}.pt-300{padding-top:var(--space-300)}.pt-400{padding-top:var(--space-400)}.px-25{padding-inline:var(--space-25)}.px-50{padding-inline:var(--space-50)}.px-75{padding-inline:var(--space-75)}.px-100{padding-inline:var(--space-100)}.px-150{padding-inline:var(--space-150)}.px-200{padding-inline:var(--space-200)}.px-300{padding-inline:var(--space-300)}.px-400{padding-inline:var(--space-400)}.py-25{padding-block:var(--space-25)}.py-50{padding-block:var(--space-50)}.py-75{padding-block:var(--space-75)}.py-100{padding-block:var(--space-100)}.py-150{padding-block:var(--space-150)}.py-200{padding-block:var(--space-200)}.py-300{padding-block:var(--space-300)}.py-400{padding-block:var(--space-400)}.pointer-events-none{pointer-events:none}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.-end-4{inset-inline-end:-1rem}.-end-3{inset-inline-end:-.75rem}.-end-2{inset-inline-end:-.5rem}.-end-1{inset-inline-end:-.25rem}.-end-0\\.5{inset-inline-end:-.125rem}.end-0{inset-inline-end:0}.end-1{inset-inline-end:.25rem}.end-2{inset-inline-end:.5rem}.end-3{inset-inline-end:.75rem}.start-0{inset-inline-start:0}.-top-1\\.5{top:-.375rem}.-top-1{top:-.25rem}.-top-0\\.5{top:-.125rem}.top-0{top:0}.top-0\\.5{top:.125rem}.top-1{top:.25rem}.top-1\\.5{top:.375rem}.top-1\\.75{top:.4375rem}.h-5{height:1.25rem}.h-8{height:2rem}.h-9{height:2.25rem}.h-full{height:100%}.max-h-full{max-height:100%}.max-w-full{max-width:100%}.min-w-0{min-width:0}.size-md{height:var(--copilot-size-md);width:var(--copilot-size-md)}.size-1{height:.25rem;width:.25rem}.size-2{height:.5rem;width:.5rem}.size-3{height:.75rem;width:.75rem}.size-4{height:1rem;width:1rem}.size-5{height:1.25rem;width:1.25rem}.size-6{height:1.5rem;width:1.5rem}.size-7{height:1.75rem;width:1.75rem}.size-8{height:2rem;width:2rem}.size-10{height:2.5rem;width:2.5rem}.w-3xs{width:16rem}.w-2xs{width:18rem}.w-xs{width:20rem}.w-sm{width:24rem}.w-md{width:28rem}.w-lg{width:32rem}.w-xl{width:36rem}.w-2xl{width:42rem}.w-3xl{width:48rem}.w-4xl{width:56rem}.w-5xl{width:64rem}.w-6xl{width:72rem}.w-7xl{width:80rem}.w-fit{width:fit-content}.w-full{width:100%}.h-m{height:var(--copilot-size-md)}.h-75{height:var(--space-75)}.h-900{height:var(--space-900)}.w-75{width:var(--space-75)}.text-center{text-align:center}.uppercase{text-transform:uppercase}.text-balance{text-wrap:balance}.text-pretty{text-wrap:pretty}.rotate-90{transform:rotate(90deg)}.transform-none{transform:none}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-shadow{transition-property:box-shadow;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-none{transition-property:none}.translate-y-0{transform:translateY(0)}.group:is(:hover,:focus-within) :is(.group-hover\\:-translate-x-1,.group-focus-within\\:-translate-x-1){transform:translate(-.25rem)}.select-none{-webkit-user-select:none;user-select:none}.invisible{visibility:hidden}.whitespace-nowrap{white-space:nowrap}.z-1{z-index:1}";
var au = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
function ad(e) {
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
}
function ou(e) {
  if (Object.prototype.hasOwnProperty.call(e, "__esModule")) return e;
  var t = e.default;
  if (typeof t == "function") {
    var r = function n() {
      var i = !1;
      try {
        i = this instanceof n;
      } catch {
      }
      return i ? Reflect.construct(t, arguments, this.constructor) : t.apply(this, arguments);
    };
    r.prototype = t.prototype;
  } else r = {};
  return Object.defineProperty(r, "__esModule", { value: !0 }), Object.keys(e).forEach(function(n) {
    var i = Object.getOwnPropertyDescriptor(e, n);
    Object.defineProperty(r, n, i.get ? i : {
      enumerable: !0,
      get: function() {
        return e[n];
      }
    });
  }), r;
}
var Rt = { exports: {} }, si;
function od() {
  if (si) return Rt.exports;
  si = 1;
  function e(t, r = 100, n = {}) {
    if (typeof t != "function")
      throw new TypeError(`Expected the first parameter to be a function, got \`${typeof t}\`.`);
    if (r < 0)
      throw new RangeError("`wait` must not be negative.");
    const { immediate: i } = typeof n == "boolean" ? { immediate: n } : n;
    let a, o, s, l, c;
    function d() {
      const h = a, m = o;
      return a = void 0, o = void 0, c = t.apply(h, m), c;
    }
    function u() {
      const h = Date.now() - l;
      h < r && h >= 0 ? s = setTimeout(u, r - h) : (s = void 0, i || (c = d()));
    }
    const v = function(...h) {
      if (a && this !== a && Object.getPrototypeOf(this) === Object.getPrototypeOf(a))
        throw new Error("Debounced method called with different contexts of the same prototype.");
      a = this, o = h, l = Date.now();
      const m = i && !s;
      return s || (s = setTimeout(u, r)), m && (c = d()), c;
    };
    return Object.defineProperty(v, "isPending", {
      get() {
        return s !== void 0;
      }
    }), v.clear = () => {
      s && (clearTimeout(s), s = void 0);
    }, v.flush = () => {
      s && v.trigger();
    }, v.trigger = () => {
      c = d(), v.clear();
    }, v;
  }
  return Rt.exports.debounce = e, Rt.exports = e, Rt.exports;
}
var sd = /* @__PURE__ */ od();
const ld = /* @__PURE__ */ ad(sd);
class cd {
  constructor() {
    this.documentActive = !0, this.addListeners = () => {
      window.addEventListener("pageshow", this.handleWindowVisibilityChange), window.addEventListener("pagehide", this.handleWindowVisibilityChange), window.addEventListener("focus", this.handleWindowFocusChange), window.addEventListener("blur", this.handleWindowFocusChange), document.addEventListener("visibilitychange", this.handleDocumentVisibilityChange);
    }, this.removeListeners = () => {
      window.removeEventListener("pageshow", this.handleWindowVisibilityChange), window.removeEventListener("pagehide", this.handleWindowVisibilityChange), window.removeEventListener("focus", this.handleWindowFocusChange), window.removeEventListener("blur", this.handleWindowFocusChange), document.removeEventListener("visibilitychange", this.handleDocumentVisibilityChange);
    }, this.handleWindowVisibilityChange = (t) => {
      t.type === "pageshow" ? this.dispatch(!0) : this.dispatch(!1);
    }, this.handleWindowFocusChange = (t) => {
      t.type === "focus" ? this.dispatch(!0) : this.dispatch(!1);
    }, this.handleDocumentVisibilityChange = () => {
      this.dispatch(!document.hidden);
    }, this.dispatch = (t) => {
      if (t !== this.documentActive) {
        const r = window.Vaadin.copilot.eventbus;
        this.documentActive = t, r.emit("document-activation-change", { active: this.documentActive });
      }
    };
  }
  copilotActivated() {
    this.addListeners();
  }
  copilotDeactivated() {
    this.removeListeners();
  }
}
const li = new cd(), dd = "copilot-development-setup-user-guide";
function su() {
  xt("use-dev-workflow-guide"), se.updatePanel(dd, { floating: !0 });
}
function Za() {
  const e = xr.jdkInfo;
  return e ? e.jrebel ? "success" : e.hotswapAgentFound ? !e.hotswapVersionOk || !e.runningWithExtendClassDef || !e.runningWitHotswap || !e.runningInJavaDebugMode ? "error" : "success" : "warning" : null;
}
function lu() {
  const e = xr.jdkInfo;
  return !e || Za() !== "success" ? "none" : e.jrebel ? "jrebel" : e.runningWitHotswap ? "hotswap" : "none";
}
function ud() {
  return b.idePluginState !== void 0 && !b.idePluginState.active ? "warning" : "success";
}
function cu() {
  if (!xr.jdkInfo)
    return { status: "success" };
  const e = Za(), t = ud();
  return e === "warning" ? t === "warning" ? { status: "warning", message: "IDE Plugin, Hotswap" } : { status: "warning", message: "Hotswap is not enabled" } : t === "warning" ? { status: "warning", message: "IDE Plugin is not active" } : e === "error" ? { status: "error", message: "Hotswap is partially enabled" } : { status: "success" };
}
function pd() {
  te(`${he}get-dev-setup-info`, {}), window.Vaadin.copilot.eventbus.on("copilot-get-dev-setup-info-response", (e) => {
    if (e.detail.content) {
      const t = JSON.parse(e.detail.content);
      b.setIdePluginState(t.ideInfo);
    }
  });
}
const ct = /* @__PURE__ */ new WeakMap();
class fd {
  constructor() {
    this.root = null, this.nodeUuidNodeMapFlat = /* @__PURE__ */ new Map(), this.aborted = !1, this._hasFlowComponent = !1, this.flowNodesInSource = {}, this.flowCustomComponentData = {}, this.hillaCustomComponentData = {}, this.componentDragDropApiInfosMap = {}, this.waitForHillaCustomComponentResponseData = () => new Promise((t, r) => {
      const n = setTimeout(() => {
        r(new Error("Timed out waiting for custom component data"));
      }, 1e4);
      y.emit("request-hilla-custom-component-data-with-callback", {
        tree: this,
        callback: (i) => {
          clearTimeout(n), t(i);
        }
      });
    });
  }
  async init() {
    const t = il();
    if (t) {
      const r = await this.addToTree(t);
      r && this.root?.abstractRootNode && this.root.children.length === 1 && (this.root = this.root.children[0]), r && (await this.addOverlayContentToTreeIfExists("vaadin-popover[opened]"), await this.addOverlayContentToTreeIfExists("vaadin-dialog[opened]")), this.hillaCustomComponentData = await this.waitForHillaCustomComponentResponseData();
    }
  }
  getChildren(t) {
    return this.nodeUuidNodeMapFlat.get(t)?.children ?? [];
  }
  get allNodesFlat() {
    return Array.from(this.nodeUuidNodeMapFlat.values());
  }
  getNodeOfElement(t) {
    if (t)
      return this.allNodesFlat.find((r) => r.element === t);
  }
  /**
   * Handles route containers that should not be present in the tree. When this returns <code>true</code>, it means that given node is a route container so adding it to tree should be skipped
   *
   * @param node Node to check whether it is a route container or not
   * @param parentNode Parent of the given {@link node}
   */
  async handleRouteContainers(t, r) {
    const n = In(t);
    if (!n && pl(t)) {
      const i = ir(t);
      if (i && i.nextElementSibling)
        return await this.addToTree(i.nextElementSibling, r), !0;
    }
    if (n && t.localName === "react-router-outlet") {
      for (const i of Array.from(t.children)) {
        const a = nr(i);
        a && await this.addToTree(a, r);
      }
      return !0;
    }
    return !1;
  }
  includeReactNode(t) {
    return ut(t) === "PreconfiguredAuthProvider" || ut(t) === "RouterProvider" ? !1 : Nn(t) || ll(t);
  }
  async includeFlowNode(t) {
    if (fl(t) || Ut(t)?.hiddenByServer)
      return !1;
    const r = Ut(t);
    return r && this.nodeUuidNodeMapFlat.has(ci(r)) ? !1 : this.isInitializedInProjectSources(t);
  }
  async isInitializedInProjectSources(t) {
    const r = Ut(t);
    if (!r)
      return !1;
    const { nodeId: n, uiId: i } = r;
    if (!this.flowNodesInSource[i]) {
      const a = await Nt("copilot-get-component-source-info", { uiId: i }, (o) => o.data);
      a.error && ce("Failed to get component source info", a.error), this.flowCustomComponentData[i] = a.customComponentResponse, this.flowNodesInSource[i] = new Set(a.nodeIdsInProject), this.componentDragDropApiInfosMap[i] = a.dragDropApiInfos;
    }
    return this.flowNodesInSource[i].has(n);
  }
  /**
   * Adds the given element into the tree and returns the result when added.
   * <p>
   *  It recursively travels through the children of given node. This method is called for each child ,but the result of adding a child is swallowed
   * </p>
   * @param node Node to add to tree
   * @param parentNode Parent of the node, might be null if it is the root element
   */
  async addToTree(t, r) {
    if (this.isAborted())
      return !1;
    const n = await this.handleRouteContainers(t, r);
    if (n)
      return n;
    const i = In(t);
    let a;
    if (!i)
      this.includeReactNode(t) && (a = this.generateNodeFromFiber(t, r));
    else if (await this.includeFlowNode(t)) {
      const l = this.generateNodeFromFlow(t, r);
      if (!l)
        return !1;
      this._hasFlowComponent = !0, a = l;
    }
    if (r)
      a && (a.parent = r, r.children || (r.children = []), r.children.push(a));
    else {
      if (!a) {
        if (!(t instanceof Element) && da(t))
          return Va({
            type: ye.WARNING,
            message: "Copilot is partly usable",
            details: `${ut(t)} should be a function component to make Copilot work properly`,
            dismissId: "react_route_component_is_class"
          }), !1;
        if (i ? a = this.generateNodeFromFlow(t) : a = this.generateNodeFromFiber(t), !a)
          return ce("Unable to add node", new Error("Tree root node is undefined")), !1;
        a.abstractRootNode = !0;
      }
      this.root = a;
    }
    a && this.nodeUuidNodeMapFlat.set(a.uuid, a);
    const o = a ?? r, s = i ? Array.from(t.children) : al(t);
    for (const l of s)
      await this.addToTree(l, o);
    return a !== void 0;
  }
  generateNodeFromFiber(t, r) {
    const n = Nn(t) ? ir(t) : void 0, i = r?.children.length ?? 0, a = this;
    return {
      node: t,
      parent: r,
      element: n,
      depth: r && r.depth + 1 || 0,
      children: [],
      siblingIndex: i,
      isFlowComponent: !1,
      isReactComponent: !0,
      isLitTemplate: !1,
      zeroSize: n ? Ln(n) : void 0,
      get uuid() {
        if (ct.has(t))
          return ct.get(t);
        if (t.alternate && ct.has(t.alternate))
          return ct.get(t.alternate);
        const s = Ka();
        return ct.set(t, s), s;
      },
      get name() {
        return zn(ut(t));
      },
      get identifier() {
        return Un(n);
      },
      get nameAndIdentifier() {
        return ui(this.name, this.identifier);
      },
      get previousSibling() {
        if (i !== 0)
          return r?.children[i - 1];
      },
      get nextSibling() {
        if (!(r === void 0 || i === r.children.length - 1))
          return r.children[i + 1];
      },
      get path() {
        return di(this);
      },
      get customComponentData() {
        if (a.hillaCustomComponentData[this.uuid])
          return a.hillaCustomComponentData[this.uuid];
      }
    };
  }
  generateNodeFromFlow(t, r) {
    const n = Ut(t);
    if (!n)
      return;
    const i = r?.children.length ?? 0, a = this.flowCustomComponentData, o = this.componentDragDropApiInfosMap;
    return {
      node: n,
      parent: r,
      element: t,
      depth: r && r.depth + 1 || 0,
      children: [],
      siblingIndex: i,
      get uuid() {
        return ci(n);
      },
      isFlowComponent: !0,
      isReactComponent: !1,
      get isLitTemplate() {
        return !!this.customComponentData?.litTemplate;
      },
      zeroSize: t ? Ln(t) : void 0,
      get name() {
        return ul(n) ?? zn(n.element.localName);
      },
      get identifier() {
        return Un(t);
      },
      get nameAndIdentifier() {
        return ui(this.name, this.identifier);
      },
      get previousSibling() {
        if (i !== 0)
          return r?.children[i - 1];
      },
      get nextSibling() {
        if (!(r === void 0 || i === r.children.length - 1))
          return r.children[i + 1];
      },
      get path() {
        return di(this);
      },
      get customComponentData() {
        if (a[n.uiId])
          return a[n.uiId].allComponentsInfoForCustomComponentSupport[n.nodeId];
      },
      get componentDragDropApiInfo() {
        if (!o[n.uiId])
          return;
        const l = o[n.uiId];
        if (l[n.nodeId])
          return l[n.nodeId];
      }
    };
  }
  async addOverlayContentToTreeIfExists(t) {
    const r = document.body.querySelector(t);
    if (!r)
      return;
    let n = !0;
    if (!this.getNodeOfElement(r)) {
      const i = Ie(nr(r));
      n = await this.addToTree(i ?? r, this.root);
    }
    if (n)
      for (const i of Array.from(r.children))
        await this.addToTree(i, this.getNodeOfElement(r));
  }
  hasFlowComponents() {
    return this._hasFlowComponent;
  }
  findNodeByUuid(t) {
    if (t)
      return this.nodeUuidNodeMapFlat.get(t);
  }
  getElementByNodeUuid(t) {
    return this.findNodeByUuid(t)?.element;
  }
  findByTreePath(t) {
    if (t)
      return this.allNodesFlat.find((r) => r.path === t);
  }
  isAborted() {
    return this.aborted;
  }
  abort() {
    this.aborted = !0;
  }
  get customComponentDataLoaded() {
    return Object.keys(this.hillaCustomComponentData).length !== 0 || Object.keys(this.flowCustomComponentData).length !== 0;
  }
}
function ci(e) {
  return `${e.uiId}#${e.nodeId}`;
}
function di(e) {
  if (!e.parent)
    return e.name;
  let t = 0;
  for (let r = 0; r < e.siblingIndex + 1; r++)
    e.parent.children[r].name === e.name && t++;
  return `${e.parent.path} > ${e.name}[${t}]`;
}
function ui(e, t) {
  return t ? `${e} "${t}"` : e;
}
let He = null;
const vd = async () => {
  He && He.abort();
  const e = new fd();
  He = e, await e.init(), He = null, e.isAborted() || (window.Vaadin.copilot.tree.currentTree = e);
}, du = () => {
  He && He.abort();
};
function hd() {
  const e = window.navigator.userAgent;
  return e.indexOf("Windows") !== -1 ? "Windows" : e.indexOf("Mac") !== -1 ? "Mac" : e.indexOf("Linux") !== -1 ? "Linux" : null;
}
function gd() {
  return hd() === "Mac";
}
function md() {
  return gd() ? "⌘" : "Ctrl";
}
let pi = !1, dt = 0;
const Wr = (e) => {
  if (nt.isActivationShortcut())
    if (e.key === "Shift" && !e.ctrlKey && !e.altKey && !e.metaKey)
      pi = !0;
    else if (pi && e.shiftKey && (e.key === "Control" || e.key === "Meta")) {
      if (dt++, dt === 2)
        return b.toggleActive("shortcut"), dt = 0, !0;
      setTimeout(() => {
        dt = 0;
      }, 500);
    } else
      dt = 0;
  return !1;
};
function fi(e) {
  if ((e.ctrlKey || e.metaKey) && e.key === "c" && !e.shiftKey) {
    const t = document.querySelector("copilot-main")?.shadowRoot;
    let r;
    if (typeof t?.getSelection == "function" ? r = t?.getSelection() : r = document.getSelection() ?? void 0, r && r.rangeCount === 1) {
      const i = r.getRangeAt(0).commonAncestorContainer;
      if (i.nodeType === Node.TEXT_NODE)
        return fe(i);
    }
  }
  return !1;
}
function bd(e) {
  const t = or(e, "vaadin-context-menu-overlay");
  if (!t)
    return !1;
  const r = t.owner;
  return r ? !!or(r, "copilot-component-overlay") : !1;
}
function yd() {
  return b.idePluginState?.supportedActions?.find((e) => e === "undo");
}
const vi = (e) => {
  if (!b.active)
    return;
  if (Wr(e)) {
    e.stopPropagation();
    return;
  }
  const t = Cl();
  if (!t)
    return;
  const r = bd(t), n = t.localName === "copilot-main", i = or(t, "copilot-outline-panel") !== null;
  if (!n && !r && e.key !== "Escape" && !i) {
    e.stopPropagation();
    return;
  }
  let a = !0, o = !1;
  if (fi(e))
    a = !1;
  else if (e.key === "Escape") {
    if (b.loginCheckActive ? b.setLoginCheckActive(!1) : y.emit("close-drawers", {}), xd(t)) {
      e.stopPropagation();
      return;
    }
    y.emit("escape-key-pressed", { event: e });
  } else wd(e) ? (y.emit("delete-selected", {}), o = !0) : (e.ctrlKey || e.metaKey) && e.key === "d" ? (y.emit("duplicate-selected", {}), o = !0) : (e.ctrlKey || e.metaKey) && e.key === "b" ? (y.emit("show-selected-in-ide", { attach: e.shiftKey }), o = !0) : (e.ctrlKey || e.metaKey) && e.key === "z" && yd() ? (y.emit("undoRedo", { undo: !e.shiftKey }), o = !0) : fi(e) || y.emit("keyboard-event", { event: e });
  a && e.stopPropagation(), o && e.preventDefault();
}, wd = (e) => (e.key === "Backspace" || e.key === "Delete") && !e.shiftKey && !e.ctrlKey && !e.altKey && !e.metaKey;
function xd(e) {
  const t = e;
  if (Mn(e))
    return !0;
  const r = fa(t);
  for (const n of r)
    if (Mn(n))
      return !0;
  return !1;
}
const re = md(), qt = "⇧", uu = {
  toggleCopilot: `<kbd>${qt} + ${re} ${re}</kbd>`,
  openAiPopover: `<kbd>${qt} + Space</kbd>`,
  undo: `<kbd>${re} + Z</kbd>`,
  redo: `<kbd>${re} + ${qt} + Z</kbd>`,
  duplicate: `<kbd>${re} + D</kbd>`,
  goToSource: `<kbd>${re} + B</kbd>`,
  goToAttachSource: `<kbd>${re} + ${qt} + B</kbd>`,
  selectParent: "<kbd>←</kbd>",
  selectPreviousSibling: "<kbd>↑</kbd>",
  selectNextSibling: "<kbd>↓</kbd>",
  delete: "<kbd>DEL</kbd>",
  copy: `<kbd>${re} + C</kbd>`,
  paste: `<kbd>${re} + V</kbd>`
};
var Od = Object.getOwnPropertyDescriptor, Ed = (e, t, r, n) => {
  for (var i = n > 1 ? void 0 : n ? Od(t, r) : t, a = e.length - 1, o; a >= 0; a--)
    (o = e[a]) && (i = o(i) || i);
  return i;
};
let hi = class extends dc {
  constructor() {
    super(...arguments), this.removers = [], this.initialized = !1, this.active = !1, this.overlayListener = (e) => {
      if (!b.active)
        return;
      const { overlay: t } = e.detail;
      if (fe(t)) {
        const r = Ke.getOwner(t);
        r && this.addDescendantOverlayOwnersToDrawer(r);
        return;
      }
      this.ensureTopmostPopover();
    }, this.overlayCloseEventListener = (e) => {
      const t = e.detail?.overlay;
      if (!t || !fe(t))
        return;
      const r = Ke.getOwner(t);
      r && this.removeDescendantOverlayOwnersToDrawer(r);
    }, this.addDescendantOverlayOwnersToDrawer = (e) => {
      if (e.getAttribute("slot") === "submenu")
        return;
      const t = this.getAncestorDrawer(e);
      t && e && e.localName !== "vaadin-tooltip" && t.openedDescendantOverlayOwners.add(e);
    }, this.removeDescendantOverlayOwnersToDrawer = (e) => {
      if (e.getAttribute("slot") === "submenu")
        return;
      const t = this.getAncestorDrawer(e);
      t && t.openedDescendantOverlayOwners.has(e) && t.openedDescendantOverlayOwners.delete(e);
    }, this.getAncestorDrawer = (e) => {
      if (!e)
        return;
      const t = or(e, "copilot-drawer-panel") ?? void 0;
      if (t)
        return t;
    }, this.toggleOperationInProgressAttr = () => {
      this.toggleAttribute("operation-in-progress", b.operationWaitsHmrUpdate !== void 0);
    }, this.operationInProgressCursorUpdateDebounceFunc = ld(this.toggleOperationInProgressAttr, 500), this.overlayOutsideClickListener = (e) => {
      fe(e.target?.owner) || (b.active || fe(e.detail.sourceEvent.target)) && e.preventDefault();
    }, this.mouseLeaveListener = () => {
      y.emit("close-drawers", {});
    };
  }
  static get styles() {
    return [
      L(Jc),
      L(Gc),
      L(Yc),
      L(Qc),
      L(_c),
      L($c),
      L(ed),
      L(td),
      L(rd),
      L(nd),
      L(id),
      Rl`
        :host {
          color: var(--vaadin-text-color);
          contain: strict;
          cursor: var(--cursor, default);
          font: var(--copilot-font-xs);
          inset: 0;
          pointer-events: all;
          position: fixed;
          z-index: 9999;

          /* Override native [popover] user agent styles */
          width: auto;
          height: auto;
          border: none;
          padding: 0;
          background-color: transparent;
          overflow: visible;
        }

        :host([operation-in-progress]) {
          --cursor: wait;
          --lumo-clickable-cursor: wait;
        }

        :host(:not([active])) {
          visibility: hidden !important;
          pointer-events: none;
        }

        /* Hide floating panels when not active */

        :host(:not([active])) > copilot-section-panel-wrapper {
          display: none !important;
        }
        :host(:not([active])) > copilot-section-panel-wrapper[individual] {
          display: block !important;
          visibility: visible;
          pointer-events: all;
        }

        /* Keep activation button and menu visible */

        copilot-activation-button,
        .activation-button-menu {
          visibility: visible;
          display: flex !important;
        }

        copilot-activation-button {
          pointer-events: auto;
        }

        a {
          color: var(--blue-11);
        }

        :host([user-select-none]) {
          -webkit-touch-callout: none;
          -webkit-user-select: none;
          -moz-user-select: none;
          -ms-user-select: none;
          user-select: none;
        }

        /* Needed to prevent a JS error because of monkey patched '_attachOverlay'. It is some scope issue, */
        /* where 'this._placeholder.parentNode' is undefined - the scope if 'this' gets messed up at some point. */
        /* We also don't want animations on the overlays to make the feel faster, so this is fine. */
        :is(vaadin-tooltip-overlay) {
          z-index: calc(var(--copilot-notifications-container-z-index) + 10);
        }
        :is(
          vaadin-context-menu,
          vaadin-menu-bar,
          vaadin-select,
          vaadin-combo-box,
          vaadin-tooltip,
          vaadin-multi-select-combo-box
        ):is([opening], [closing]),
        :is(
          vaadin-context-menu,
          vaadin-menu-bar,
          vaadin-select,
          vaadin-combo-box,
          vaadin-tooltip,
          vaadin-multi-select-combo-box
        )::part(overlay) {
          animation: none !important;
        }

        :host(:not([active])) copilot-drawer-panel::before {
          animation: none;
        }

        :host .alwaysVisible {
          visibility: visible !important;
        }
      `
    ];
  }
  connectedCallback() {
    super.connectedCallback(), this.popover = "manual", this.ensureTopmostPopover(), document.body.addEventListener("vaadin-overlay-open", this.overlayListener), document.documentElement.addEventListener("vaadin-overlay-close", this.overlayCloseEventListener), this.init().catch((e) => ce("Unable to initialize copilot", e));
  }
  ensureTopmostPopover() {
    this.isConnected && (this.hidePopover(), this.showPopover());
  }
  async init() {
    if (this.initialized)
      return;
    await window.Vaadin.copilot._machineState.initializer.promise, await import("./copilot-global-vars-later-B4pUkXYD.js"), await import("./copilot-init-step2-TY87urez.js"), yl(), uc(), this.tabIndex = 0, jt.hostConnectedCallback(), window.addEventListener("keydown", Wr), this.addEventListener("keydown", vi), y.onSend(this.handleSendEvent), this.removers.push(y.on("close-drawers", this.closeDrawers.bind(this))), this.removers.push(
      y.on("open-attention-required-drawer", this.openDrawerIfPanelRequiresAttention.bind(this))
    ), this.removers.push(
      y.on("set-pointer-events", (r) => {
        this.style.pointerEvents = r.detail.enable ? "" : "none";
      })
    ), this.addEventListener("mousemove", this.mouseMoveListener), this.addEventListener("dragover", this.dragOverListener), this.addEventListener("dragleave", this.dragLeaveListener), this.addEventListener("drop", this.dropListener), Ke.addOverlayOutsideClickEvent();
    const e = window.matchMedia("(prefers-color-scheme: dark)");
    this.classList.toggle("dark", e.matches), e.addEventListener("change", (r) => {
      this.classList.toggle("dark", e.matches);
    }), this.reaction(
      () => b.active,
      () => {
        this.toggleAttribute("active", b.active), b.active ? this.activate() : this.deactivate(), We.saveCopilotActivation(b.active);
      }
    ), this.reaction(
      () => b.activatedAtLeastOnce,
      () => {
        Ma(), pc();
      }
    ), this.reaction(
      () => b.sectionPanelDragging,
      () => {
        b.sectionPanelDragging && Array.from(this.shadowRoot.children).filter((n) => n.localName.endsWith("-overlay")).forEach((n) => {
          n.close && n.close();
        });
      }
    ), this.reaction(
      () => b.operationWaitsHmrUpdate,
      () => {
        b.operationWaitsHmrUpdate ? this.operationInProgressCursorUpdateDebounceFunc() : (this.operationInProgressCursorUpdateDebounceFunc.clear(), this.toggleOperationInProgressAttr());
      }
    ), this.reaction(
      () => se.panels,
      () => {
        se.panels.find((r) => r.individual) && this.requestUpdate();
      }
    ), We.getCopilotActivation() && pa().then(() => {
      b.setActive(!0, "restore");
    }), this.removers.push(
      y.on("user-select", (r) => {
        const { allowSelection: n } = r.detail;
        this.toggleAttribute("user-select-none", !n);
      })
    ), this.removers.push(
      y.on("featureFlags", (r) => {
        const n = r.detail.features;
        b.setFeatureFlags(n);
      })
    ), this.removers.push(
      y.on("vaadin-drawer-opened-changed", (r) => {
        const { opened: n, owner: i } = r.detail;
        n ? this.addDescendantOverlayOwnersToDrawer(i) : this.removeDescendantOverlayOwnersToDrawer(i);
      })
    );
    const t = new ResizeObserver(() => {
      y.emit("copilot-main-resized", {});
    });
    t.observe(this), this.removers.push(() => {
      t.disconnect();
    }), Ua(), this.detectAppTheme(), this.initialized = !0, pd();
  }
  /**
   * Called when Copilot is activated. Good place to start attach listeners etc.
   */
  async activate() {
    jt.activate(), li.copilotActivated(), fc(), this.openDrawerIfPanelRequiresAttention(), document.documentElement.addEventListener("mouseleave", this.mouseLeaveListener), Ke.onCopilotActivation(), await vd(), Ia.loadPreviewConfiguration(), this.ensureTopmostPopover(), this.active = !0, nt.isActivationAnimation() && b.activatedFrom !== "restore" && this.getAllDrawers().forEach((e) => {
      e.setAttribute("bounce", "");
    });
  }
  /**
   * Called when Copilot is deactivated. Good place to remove listeners etc.
   */
  deactivate() {
    this.getAllDrawers().forEach((e) => {
      e.removeAttribute("bounce");
    }), this.closeDrawers(), jt.deactivate(), li.copilotDeactivated(), document.documentElement.removeEventListener("mouseleave", this.mouseLeaveListener), Ke.onCopilotDeactivation(), this.active = !1;
  }
  getAllDrawers() {
    return Array.from(this.shadowRoot.querySelectorAll("copilot-drawer-panel"));
  }
  disconnectedCallback() {
    super.disconnectedCallback(), jt.hostDisconnectedCallback(), window.removeEventListener("keydown", Wr), this.removeEventListener("keydown", vi), y.offSend(this.handleSendEvent), this.removers.forEach((e) => e()), this.removeEventListener("mousemove", this.mouseMoveListener), this.removeEventListener("dragover", this.dragOverListener), this.removeEventListener("dragleave", this.dragLeaveListener), this.removeEventListener("drop", this.dropListener), Ke.removeOverlayOutsideClickEvent(), document.documentElement.removeEventListener("vaadin-overlay-outside-click", this.overlayOutsideClickListener), document.body.removeEventListener("vaadin-overlay-open", this.overlayListener), document.documentElement.removeEventListener("vaadin-overlay-close", this.overlayCloseEventListener);
  }
  handleSendEvent(e) {
    const t = e.detail.command, r = e.detail.data;
    te(t, r);
  }
  /**
   * Opens the attention required drawer if there is any.
   */
  openDrawerIfPanelRequiresAttention() {
    const e = se.getAttentionRequiredPanelConfiguration();
    if (!e)
      return;
    const t = e.panel;
    if (!t || e.floating)
      return;
    const r = this.shadowRoot.querySelector(`copilot-drawer-panel[position="${t}"]`);
    r.opened = !0;
  }
  render() {
    return le`
      <copilot-activation-button
        @activation-btn-clicked="${() => {
      b.toggleActive("button"), b.setLoginCheckActive(!1);
    }}">
      </copilot-activation-button>
      <copilot-component-selector></copilot-component-selector>
      <copilot-label-editor-container></copilot-label-editor-container>
      <copilot-info-tooltip></copilot-info-tooltip>
      ${this.renderDrawer("left")} ${this.renderDrawer("right")} ${this.renderDrawer("bottom")} ${qc()}
      <copilot-login-check></copilot-login-check>
      <copilot-ai-usage-confirmation-dialog></copilot-ai-usage-confirmation-dialog>
      <copilot-notifications-container></copilot-notifications-container>
      <copilot-report-exception-dialog></copilot-report-exception-dialog>
      <copilot-welcome></copilot-welcome>
    `;
  }
  renderDrawer(e) {
    return le` <copilot-drawer-panel position=${e}> ${Rc(e)} </copilot-drawer-panel>`;
  }
  /**
   * Closes the open drawers if any opened unless an overlay is opened from drawer.
   */
  closeDrawers() {
    const e = this.getAllDrawers();
    if (Array.from(e).some((r) => r.opened))
      for (const r of e)
        r.openedDescendantOverlayOwners.size === 0 && (r.opened = !1);
  }
  updated(e) {
    super.updated(e), this.attachActivationButtonToBody(), Xc();
  }
  attachActivationButtonToBody() {
    const e = document.body.querySelectorAll("copilot-activation-button");
    e.length > 1 && e[0].remove();
  }
  mouseMoveListener(e) {
    e.composedPath().find((t) => t.localName === `${he}drawer-panel`) || this.closeDrawers();
  }
  dragOverListener(e) {
    this.mouseMoveListener(e), e.dataTransfer && (e.dataTransfer.dropEffect = "none"), e.preventDefault(), y.emit("drag-and-drop-in-progress", {});
  }
  dragLeaveListener(e) {
    Nl(e) && y.emit("end-drag-drop", {});
  }
  dropListener(e) {
    e.preventDefault(), y.emit("end-drag-drop", {});
  }
  detectAppTheme() {
    Tn("lumo") ? b.setAppTheme("lumo") : Tn("aura") ? b.setAppTheme("aura") : b.setAppTheme(null), Nt(`${he}set-app-theme`, { theme: b.appTheme }, () => {
    });
  }
};
hi = Ed([
  jl("copilot-main")
], hi);
const kd = window.Vaadin, Cd = {
  init(e) {
    ua(
      () => window.Vaadin.devTools,
      (t) => {
        const r = t.handleFrontendMessage;
        t.handleFrontendMessage = (n) => {
          Hc(n) || r.call(t, n);
        };
      }
    );
  }
};
kd.devToolsPlugins.push(Cd);
function Ad(e, t, r = {}) {
  const n = { ...r };
  e.classNames.length > 0 && (n.className = e.classNames.join(" "));
  const i = Sd(e);
  Object.keys(i).length > 0 && (n.style = i);
  for (const a of Pd()) {
    const o = a(e, t);
    if (o) {
      n.className && o.props?.className && (o.props.className = `${String(o.props.className)} ${String(n.className)}`, delete n.className), o.props = { ...o.props, ...n };
      for (const [s, l] of Object.entries(o.props))
        l === void 0 && delete o.props[s];
      return o;
    }
  }
  console.warn(`No importer found for node: ${e.htmlTag} ${e.reactTag} (${e.type})`);
}
function Sd(e) {
  if (Object.keys(e.styles).length === 0)
    return {};
  const t = {};
  return Object.keys(e.styles).forEach((r) => {
    const n = e.styles[r];
    r.startsWith("--") || (r = r.replace(/-([a-z])/g, (i) => i[1].toUpperCase())), t[r] = n;
  }), t;
}
function pu(e) {
  Wa().unshift(e);
}
function Pd() {
  return [...Wa(), ...Dd()];
}
function Wa() {
  return window.Vaadin.copilot.figmaImporters ??= [], window.Vaadin.copilot.figmaImporters;
}
function Dd() {
  return window.Vaadin.copilot.figmaBuiltInImporters ??= [], window.Vaadin.copilot.figmaBuiltInImporters;
}
function Ha(e, t) {
  const r = [];
  for (const n of e.children)
    t(n) && r.push(n);
  for (const n of e.children)
    r.push(...Ha(n, t));
  return r;
}
function fu(e, t, r) {
  return Ha(e, r).map((n) => Ad(n, t)).filter((n) => n !== void 0);
}
export {
  uu as $,
  Rl as A,
  Vd as B,
  We as C,
  le as D,
  E,
  ht as F,
  Ol as G,
  $d as H,
  dd as I,
  xr as J,
  Za as K,
  Nd as L,
  dc as M,
  Ud as N,
  eu as O,
  he as P,
  lu as Q,
  Id as R,
  nt as S,
  cu as T,
  Ia as U,
  zd as V,
  Zd as W,
  Gc as X,
  _c as Y,
  ed as Z,
  su as _,
  ad as a,
  bl as a0,
  ru as a1,
  nu as a2,
  hc as a3,
  Hd as a4,
  Md as a5,
  xt as a6,
  Va as a7,
  ye as a8,
  Td as a9,
  pu as aA,
  fu as aB,
  Yc as aa,
  qd as ab,
  Na as ac,
  vd as ad,
  vl as ae,
  du as af,
  Da as ag,
  tu as ah,
  Sa as ai,
  sc as aj,
  Pa as ak,
  ar as al,
  Kd as am,
  Rd as an,
  La as ao,
  Ft as ap,
  hl as aq,
  ud as ar,
  yc as as,
  Ma as at,
  dn as au,
  Oc as av,
  xa as aw,
  Fr as ax,
  Mn as ay,
  Yd as az,
  y as b,
  au as c,
  rr as d,
  el as e,
  jd as f,
  ou as g,
  Bd as h,
  Ld as i,
  b as j,
  Nt as k,
  ce as l,
  $e as m,
  Wd as n,
  C as o,
  iu as p,
  fd as q,
  jl as r,
  te as s,
  Fd as t,
  xl as u,
  ld as v,
  se as w,
  L as x,
  Jc as y,
  id as z
};
