@eox/itemfilter 0.4.0 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,235 +1,235 @@
1
- var _e = Object.defineProperty;
2
- var ye = (i, t, e) => t in i ? _e(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e;
3
- var m = (i, t, e) => (ye(i, typeof t != "symbol" ? t + "" : t, e), e);
1
+ var Cr = Object.defineProperty;
2
+ var Or = (i, e, t) => e in i ? Cr(i, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[e] = t;
3
+ var ee = (i, e, t) => (Or(i, typeof e != "symbol" ? e + "" : e, t), t);
4
4
  /**
5
5
  * @license
6
6
  * Copyright 2019 Google LLC
7
7
  * SPDX-License-Identifier: BSD-3-Clause
8
8
  */
9
- const rt = window, kt = rt.ShadowRoot && (rt.ShadyCSS === void 0 || rt.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, ie = Symbol(), Pt = /* @__PURE__ */ new WeakMap();
10
- let $e = class {
11
- constructor(t, e, s) {
12
- if (this._$cssResult$ = !0, s !== ie)
9
+ const kt = window, Ms = kt.ShadowRoot && (kt.ShadyCSS === void 0 || kt.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, yi = Symbol(), Js = /* @__PURE__ */ new WeakMap();
10
+ let Dr = class {
11
+ constructor(e, t, s) {
12
+ if (this._$cssResult$ = !0, s !== yi)
13
13
  throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
14
- this.cssText = t, this.t = e;
14
+ this.cssText = e, this.t = t;
15
15
  }
16
16
  get styleSheet() {
17
- let t = this.o;
18
- const e = this.t;
19
- if (kt && t === void 0) {
20
- const s = e !== void 0 && e.length === 1;
21
- s && (t = Pt.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), s && Pt.set(e, t));
17
+ let e = this.o;
18
+ const t = this.t;
19
+ if (Ms && e === void 0) {
20
+ const s = t !== void 0 && t.length === 1;
21
+ s && (e = Js.get(t)), e === void 0 && ((this.o = e = new CSSStyleSheet()).replaceSync(this.cssText), s && Js.set(t, e));
22
22
  }
23
- return t;
23
+ return e;
24
24
  }
25
25
  toString() {
26
26
  return this.cssText;
27
27
  }
28
28
  };
29
- const ve = (i) => new $e(typeof i == "string" ? i : i + "", void 0, ie), Ae = (i, t) => {
30
- kt ? i.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet) : t.forEach((e) => {
31
- const s = document.createElement("style"), n = rt.litNonce;
32
- n !== void 0 && s.setAttribute("nonce", n), s.textContent = e.cssText, i.appendChild(s);
29
+ const Tr = (i) => new Dr(typeof i == "string" ? i : i + "", void 0, yi), Rr = (i, e) => {
30
+ Ms ? i.adoptedStyleSheets = e.map((t) => t instanceof CSSStyleSheet ? t : t.styleSheet) : e.forEach((t) => {
31
+ const s = document.createElement("style"), n = kt.litNonce;
32
+ n !== void 0 && s.setAttribute("nonce", n), s.textContent = t.cssText, i.appendChild(s);
33
33
  });
34
- }, jt = kt ? (i) => i : (i) => i instanceof CSSStyleSheet ? ((t) => {
35
- let e = "";
36
- for (const s of t.cssRules)
37
- e += s.cssText;
38
- return ve(e);
34
+ }, Zs = Ms ? (i) => i : (i) => i instanceof CSSStyleSheet ? ((e) => {
35
+ let t = "";
36
+ for (const s of e.cssRules)
37
+ t += s.cssText;
38
+ return Tr(t);
39
39
  })(i) : i;
40
40
  /**
41
41
  * @license
42
42
  * Copyright 2017 Google LLC
43
43
  * SPDX-License-Identifier: BSD-3-Clause
44
44
  */
45
- var dt;
46
- const ot = window, Ht = ot.trustedTypes, Ee = Ht ? Ht.emptyScript : "", Ut = ot.reactiveElementPolyfillSupport, At = { toAttribute(i, t) {
47
- switch (t) {
45
+ var ns;
46
+ const Lt = window, Qs = Lt.trustedTypes, Pr = Qs ? Qs.emptyScript : "", ei = Lt.reactiveElementPolyfillSupport, fs = { toAttribute(i, e) {
47
+ switch (e) {
48
48
  case Boolean:
49
- i = i ? Ee : null;
49
+ i = i ? Pr : null;
50
50
  break;
51
51
  case Object:
52
52
  case Array:
53
53
  i = i == null ? i : JSON.stringify(i);
54
54
  }
55
55
  return i;
56
- }, fromAttribute(i, t) {
57
- let e = i;
58
- switch (t) {
56
+ }, fromAttribute(i, e) {
57
+ let t = i;
58
+ switch (e) {
59
59
  case Boolean:
60
- e = i !== null;
60
+ t = i !== null;
61
61
  break;
62
62
  case Number:
63
- e = i === null ? null : Number(i);
63
+ t = i === null ? null : Number(i);
64
64
  break;
65
65
  case Object:
66
66
  case Array:
67
67
  try {
68
- e = JSON.parse(i);
68
+ t = JSON.parse(i);
69
69
  } catch {
70
- e = null;
70
+ t = null;
71
71
  }
72
72
  }
73
- return e;
74
- } }, ne = (i, t) => t !== i && (t == t || i == i), ft = { attribute: !0, type: String, converter: At, reflect: !1, hasChanged: ne };
75
- let B = class extends HTMLElement {
73
+ return t;
74
+ } }, bi = (i, e) => e !== i && (e == e || i == i), os = { attribute: !0, type: String, converter: fs, reflect: !1, hasChanged: bi }, gs = "finalized";
75
+ let Ze = class extends HTMLElement {
76
76
  constructor() {
77
77
  super(), this._$Ei = /* @__PURE__ */ new Map(), this.isUpdatePending = !1, this.hasUpdated = !1, this._$El = null, this.u();
78
78
  }
79
- static addInitializer(t) {
80
- var e;
81
- this.finalize(), ((e = this.h) !== null && e !== void 0 ? e : this.h = []).push(t);
79
+ static addInitializer(e) {
80
+ var t;
81
+ this.finalize(), ((t = this.h) !== null && t !== void 0 ? t : this.h = []).push(e);
82
82
  }
83
83
  static get observedAttributes() {
84
84
  this.finalize();
85
- const t = [];
86
- return this.elementProperties.forEach((e, s) => {
87
- const n = this._$Ep(s, e);
88
- n !== void 0 && (this._$Ev.set(n, s), t.push(n));
89
- }), t;
90
- }
91
- static createProperty(t, e = ft) {
92
- if (e.state && (e.attribute = !1), this.finalize(), this.elementProperties.set(t, e), !e.noAccessor && !this.prototype.hasOwnProperty(t)) {
93
- const s = typeof t == "symbol" ? Symbol() : "__" + t, n = this.getPropertyDescriptor(t, s, e);
94
- n !== void 0 && Object.defineProperty(this.prototype, t, n);
85
+ const e = [];
86
+ return this.elementProperties.forEach((t, s) => {
87
+ const n = this._$Ep(s, t);
88
+ n !== void 0 && (this._$Ev.set(n, s), e.push(n));
89
+ }), e;
90
+ }
91
+ static createProperty(e, t = os) {
92
+ if (t.state && (t.attribute = !1), this.finalize(), this.elementProperties.set(e, t), !t.noAccessor && !this.prototype.hasOwnProperty(e)) {
93
+ const s = typeof e == "symbol" ? Symbol() : "__" + e, n = this.getPropertyDescriptor(e, s, t);
94
+ n !== void 0 && Object.defineProperty(this.prototype, e, n);
95
95
  }
96
96
  }
97
- static getPropertyDescriptor(t, e, s) {
97
+ static getPropertyDescriptor(e, t, s) {
98
98
  return { get() {
99
- return this[e];
99
+ return this[t];
100
100
  }, set(n) {
101
- const r = this[t];
102
- this[e] = n, this.requestUpdate(t, r, s);
101
+ const l = this[e];
102
+ this[t] = n, this.requestUpdate(e, l, s);
103
103
  }, configurable: !0, enumerable: !0 };
104
104
  }
105
- static getPropertyOptions(t) {
106
- return this.elementProperties.get(t) || ft;
105
+ static getPropertyOptions(e) {
106
+ return this.elementProperties.get(e) || os;
107
107
  }
108
108
  static finalize() {
109
- if (this.hasOwnProperty("finalized"))
109
+ if (this.hasOwnProperty(gs))
110
110
  return !1;
111
- this.finalized = !0;
112
- const t = Object.getPrototypeOf(this);
113
- if (t.finalize(), t.h !== void 0 && (this.h = [...t.h]), this.elementProperties = new Map(t.elementProperties), this._$Ev = /* @__PURE__ */ new Map(), this.hasOwnProperty("properties")) {
114
- const e = this.properties, s = [...Object.getOwnPropertyNames(e), ...Object.getOwnPropertySymbols(e)];
111
+ this[gs] = !0;
112
+ const e = Object.getPrototypeOf(this);
113
+ if (e.finalize(), e.h !== void 0 && (this.h = [...e.h]), this.elementProperties = new Map(e.elementProperties), this._$Ev = /* @__PURE__ */ new Map(), this.hasOwnProperty("properties")) {
114
+ const t = this.properties, s = [...Object.getOwnPropertyNames(t), ...Object.getOwnPropertySymbols(t)];
115
115
  for (const n of s)
116
- this.createProperty(n, e[n]);
116
+ this.createProperty(n, t[n]);
117
117
  }
118
118
  return this.elementStyles = this.finalizeStyles(this.styles), !0;
119
119
  }
120
- static finalizeStyles(t) {
121
- const e = [];
122
- if (Array.isArray(t)) {
123
- const s = new Set(t.flat(1 / 0).reverse());
120
+ static finalizeStyles(e) {
121
+ const t = [];
122
+ if (Array.isArray(e)) {
123
+ const s = new Set(e.flat(1 / 0).reverse());
124
124
  for (const n of s)
125
- e.unshift(jt(n));
125
+ t.unshift(Zs(n));
126
126
  } else
127
- t !== void 0 && e.push(jt(t));
128
- return e;
127
+ e !== void 0 && t.push(Zs(e));
128
+ return t;
129
129
  }
130
- static _$Ep(t, e) {
131
- const s = e.attribute;
132
- return s === !1 ? void 0 : typeof s == "string" ? s : typeof t == "string" ? t.toLowerCase() : void 0;
130
+ static _$Ep(e, t) {
131
+ const s = t.attribute;
132
+ return s === !1 ? void 0 : typeof s == "string" ? s : typeof e == "string" ? e.toLowerCase() : void 0;
133
133
  }
134
134
  u() {
135
- var t;
136
- this._$E_ = new Promise((e) => this.enableUpdating = e), this._$AL = /* @__PURE__ */ new Map(), this._$Eg(), this.requestUpdate(), (t = this.constructor.h) === null || t === void 0 || t.forEach((e) => e(this));
135
+ var e;
136
+ this._$E_ = new Promise((t) => this.enableUpdating = t), this._$AL = /* @__PURE__ */ new Map(), this._$Eg(), this.requestUpdate(), (e = this.constructor.h) === null || e === void 0 || e.forEach((t) => t(this));
137
137
  }
138
- addController(t) {
139
- var e, s;
140
- ((e = this._$ES) !== null && e !== void 0 ? e : this._$ES = []).push(t), this.renderRoot !== void 0 && this.isConnected && ((s = t.hostConnected) === null || s === void 0 || s.call(t));
138
+ addController(e) {
139
+ var t, s;
140
+ ((t = this._$ES) !== null && t !== void 0 ? t : this._$ES = []).push(e), this.renderRoot !== void 0 && this.isConnected && ((s = e.hostConnected) === null || s === void 0 || s.call(e));
141
141
  }
142
- removeController(t) {
143
- var e;
144
- (e = this._$ES) === null || e === void 0 || e.splice(this._$ES.indexOf(t) >>> 0, 1);
142
+ removeController(e) {
143
+ var t;
144
+ (t = this._$ES) === null || t === void 0 || t.splice(this._$ES.indexOf(e) >>> 0, 1);
145
145
  }
146
146
  _$Eg() {
147
- this.constructor.elementProperties.forEach((t, e) => {
148
- this.hasOwnProperty(e) && (this._$Ei.set(e, this[e]), delete this[e]);
147
+ this.constructor.elementProperties.forEach((e, t) => {
148
+ this.hasOwnProperty(t) && (this._$Ei.set(t, this[t]), delete this[t]);
149
149
  });
150
150
  }
151
151
  createRenderRoot() {
152
- var t;
153
- const e = (t = this.shadowRoot) !== null && t !== void 0 ? t : this.attachShadow(this.constructor.shadowRootOptions);
154
- return Ae(e, this.constructor.elementStyles), e;
152
+ var e;
153
+ const t = (e = this.shadowRoot) !== null && e !== void 0 ? e : this.attachShadow(this.constructor.shadowRootOptions);
154
+ return Rr(t, this.constructor.elementStyles), t;
155
155
  }
156
156
  connectedCallback() {
157
- var t;
158
- this.renderRoot === void 0 && (this.renderRoot = this.createRenderRoot()), this.enableUpdating(!0), (t = this._$ES) === null || t === void 0 || t.forEach((e) => {
157
+ var e;
158
+ this.renderRoot === void 0 && (this.renderRoot = this.createRenderRoot()), this.enableUpdating(!0), (e = this._$ES) === null || e === void 0 || e.forEach((t) => {
159
159
  var s;
160
- return (s = e.hostConnected) === null || s === void 0 ? void 0 : s.call(e);
160
+ return (s = t.hostConnected) === null || s === void 0 ? void 0 : s.call(t);
161
161
  });
162
162
  }
163
- enableUpdating(t) {
163
+ enableUpdating(e) {
164
164
  }
165
165
  disconnectedCallback() {
166
- var t;
167
- (t = this._$ES) === null || t === void 0 || t.forEach((e) => {
166
+ var e;
167
+ (e = this._$ES) === null || e === void 0 || e.forEach((t) => {
168
168
  var s;
169
- return (s = e.hostDisconnected) === null || s === void 0 ? void 0 : s.call(e);
169
+ return (s = t.hostDisconnected) === null || s === void 0 ? void 0 : s.call(t);
170
170
  });
171
171
  }
172
- attributeChangedCallback(t, e, s) {
173
- this._$AK(t, s);
172
+ attributeChangedCallback(e, t, s) {
173
+ this._$AK(e, s);
174
174
  }
175
- _$EO(t, e, s = ft) {
175
+ _$EO(e, t, s = os) {
176
176
  var n;
177
- const r = this.constructor._$Ep(t, s);
178
- if (r !== void 0 && s.reflect === !0) {
179
- const o = (((n = s.converter) === null || n === void 0 ? void 0 : n.toAttribute) !== void 0 ? s.converter : At).toAttribute(e, s.type);
180
- this._$El = t, o == null ? this.removeAttribute(r) : this.setAttribute(r, o), this._$El = null;
177
+ const l = this.constructor._$Ep(e, s);
178
+ if (l !== void 0 && s.reflect === !0) {
179
+ const o = (((n = s.converter) === null || n === void 0 ? void 0 : n.toAttribute) !== void 0 ? s.converter : fs).toAttribute(t, s.type);
180
+ this._$El = e, o == null ? this.removeAttribute(l) : this.setAttribute(l, o), this._$El = null;
181
181
  }
182
182
  }
183
- _$AK(t, e) {
183
+ _$AK(e, t) {
184
184
  var s;
185
- const n = this.constructor, r = n._$Ev.get(t);
186
- if (r !== void 0 && this._$El !== r) {
187
- const o = n.getPropertyOptions(r), c = typeof o.converter == "function" ? { fromAttribute: o.converter } : ((s = o.converter) === null || s === void 0 ? void 0 : s.fromAttribute) !== void 0 ? o.converter : At;
188
- this._$El = r, this[r] = c.fromAttribute(e, o.type), this._$El = null;
185
+ const n = this.constructor, l = n._$Ev.get(e);
186
+ if (l !== void 0 && this._$El !== l) {
187
+ const o = n.getPropertyOptions(l), h = typeof o.converter == "function" ? { fromAttribute: o.converter } : ((s = o.converter) === null || s === void 0 ? void 0 : s.fromAttribute) !== void 0 ? o.converter : fs;
188
+ this._$El = l, this[l] = h.fromAttribute(t, o.type), this._$El = null;
189
189
  }
190
190
  }
191
- requestUpdate(t, e, s) {
191
+ requestUpdate(e, t, s) {
192
192
  let n = !0;
193
- t !== void 0 && (((s = s || this.constructor.getPropertyOptions(t)).hasChanged || ne)(this[t], e) ? (this._$AL.has(t) || this._$AL.set(t, e), s.reflect === !0 && this._$El !== t && (this._$EC === void 0 && (this._$EC = /* @__PURE__ */ new Map()), this._$EC.set(t, s))) : n = !1), !this.isUpdatePending && n && (this._$E_ = this._$Ej());
193
+ e !== void 0 && (((s = s || this.constructor.getPropertyOptions(e)).hasChanged || bi)(this[e], t) ? (this._$AL.has(e) || this._$AL.set(e, t), s.reflect === !0 && this._$El !== e && (this._$EC === void 0 && (this._$EC = /* @__PURE__ */ new Map()), this._$EC.set(e, s))) : n = !1), !this.isUpdatePending && n && (this._$E_ = this._$Ej());
194
194
  }
195
195
  async _$Ej() {
196
196
  this.isUpdatePending = !0;
197
197
  try {
198
198
  await this._$E_;
199
- } catch (e) {
200
- Promise.reject(e);
199
+ } catch (t) {
200
+ Promise.reject(t);
201
201
  }
202
- const t = this.scheduleUpdate();
203
- return t != null && await t, !this.isUpdatePending;
202
+ const e = this.scheduleUpdate();
203
+ return e != null && await e, !this.isUpdatePending;
204
204
  }
205
205
  scheduleUpdate() {
206
206
  return this.performUpdate();
207
207
  }
208
208
  performUpdate() {
209
- var t;
209
+ var e;
210
210
  if (!this.isUpdatePending)
211
211
  return;
212
- this.hasUpdated, this._$Ei && (this._$Ei.forEach((n, r) => this[r] = n), this._$Ei = void 0);
213
- let e = !1;
212
+ this.hasUpdated, this._$Ei && (this._$Ei.forEach((n, l) => this[l] = n), this._$Ei = void 0);
213
+ let t = !1;
214
214
  const s = this._$AL;
215
215
  try {
216
- e = this.shouldUpdate(s), e ? (this.willUpdate(s), (t = this._$ES) === null || t === void 0 || t.forEach((n) => {
217
- var r;
218
- return (r = n.hostUpdate) === null || r === void 0 ? void 0 : r.call(n);
216
+ t = this.shouldUpdate(s), t ? (this.willUpdate(s), (e = this._$ES) === null || e === void 0 || e.forEach((n) => {
217
+ var l;
218
+ return (l = n.hostUpdate) === null || l === void 0 ? void 0 : l.call(n);
219
219
  }), this.update(s)) : this._$Ek();
220
220
  } catch (n) {
221
- throw e = !1, this._$Ek(), n;
221
+ throw t = !1, this._$Ek(), n;
222
222
  }
223
- e && this._$AE(s);
223
+ t && this._$AE(s);
224
224
  }
225
- willUpdate(t) {
225
+ willUpdate(e) {
226
226
  }
227
- _$AE(t) {
228
- var e;
229
- (e = this._$ES) === null || e === void 0 || e.forEach((s) => {
227
+ _$AE(e) {
228
+ var t;
229
+ (t = this._$ES) === null || t === void 0 || t.forEach((s) => {
230
230
  var n;
231
231
  return (n = s.hostUpdated) === null || n === void 0 ? void 0 : n.call(s);
232
- }), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
232
+ }), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(e)), this.updated(e);
233
233
  }
234
234
  _$Ek() {
235
235
  this._$AL = /* @__PURE__ */ new Map(), this.isUpdatePending = !1;
@@ -240,104 +240,104 @@ let B = class extends HTMLElement {
240
240
  getUpdateComplete() {
241
241
  return this._$E_;
242
242
  }
243
- shouldUpdate(t) {
243
+ shouldUpdate(e) {
244
244
  return !0;
245
245
  }
246
- update(t) {
247
- this._$EC !== void 0 && (this._$EC.forEach((e, s) => this._$EO(s, this[s], e)), this._$EC = void 0), this._$Ek();
246
+ update(e) {
247
+ this._$EC !== void 0 && (this._$EC.forEach((t, s) => this._$EO(s, this[s], t)), this._$EC = void 0), this._$Ek();
248
248
  }
249
- updated(t) {
249
+ updated(e) {
250
250
  }
251
- firstUpdated(t) {
251
+ firstUpdated(e) {
252
252
  }
253
253
  };
254
- B.finalized = !0, B.elementProperties = /* @__PURE__ */ new Map(), B.elementStyles = [], B.shadowRootOptions = { mode: "open" }, Ut == null || Ut({ ReactiveElement: B }), ((dt = ot.reactiveElementVersions) !== null && dt !== void 0 ? dt : ot.reactiveElementVersions = []).push("1.6.1");
254
+ Ze[gs] = !0, Ze.elementProperties = /* @__PURE__ */ new Map(), Ze.elementStyles = [], Ze.shadowRootOptions = { mode: "open" }, ei == null || ei({ ReactiveElement: Ze }), ((ns = Lt.reactiveElementVersions) !== null && ns !== void 0 ? ns : Lt.reactiveElementVersions = []).push("1.6.2");
255
255
  /**
256
256
  * @license
257
257
  * Copyright 2017 Google LLC
258
258
  * SPDX-License-Identifier: BSD-3-Clause
259
259
  */
260
- var pt;
261
- const lt = window, W = lt.trustedTypes, Ft = W ? W.createPolicy("lit-html", { createHTML: (i) => i }) : void 0, Et = "$lit$", O = `lit$${(Math.random() + "").slice(9)}$`, re = "?" + O, be = `<${re}>`, H = document, Z = () => H.createComment(""), q = (i) => i === null || typeof i != "object" && typeof i != "function", oe = Array.isArray, xe = (i) => oe(i) || typeof (i == null ? void 0 : i[Symbol.iterator]) == "function", gt = `[
262
- \f\r]`, Y = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Dt = /-->/g, zt = />/g, N = RegExp(`>|${gt}(?:([^\\s"'>=/]+)(${gt}*=${gt}*(?:[^
263
- \f\r"'\`<>=]|("|')|))|$)`, "g"), Bt = /'/g, Wt = /"/g, le = /^(?:script|style|textarea|title)$/i, Se = (i) => (t, ...e) => ({ _$litType$: i, strings: t, values: e }), x = Se(1), U = Symbol.for("lit-noChange"), _ = Symbol.for("lit-nothing"), Vt = /* @__PURE__ */ new WeakMap(), j = H.createTreeWalker(H, 129, null, !1), we = (i, t) => {
264
- const e = i.length - 1, s = [];
265
- let n, r = t === 2 ? "<svg>" : "", o = Y;
266
- for (let l = 0; l < e; l++) {
267
- const a = i[l];
268
- let u, h, d = -1, p = 0;
269
- for (; p < a.length && (o.lastIndex = p, h = o.exec(a), h !== null); )
270
- p = o.lastIndex, o === Y ? h[1] === "!--" ? o = Dt : h[1] !== void 0 ? o = zt : h[2] !== void 0 ? (le.test(h[2]) && (n = RegExp("</" + h[2], "g")), o = N) : h[3] !== void 0 && (o = N) : o === N ? h[0] === ">" ? (o = n ?? Y, d = -1) : h[1] === void 0 ? d = -2 : (d = o.lastIndex - h[2].length, u = h[1], o = h[3] === void 0 ? N : h[3] === '"' ? Wt : Bt) : o === Wt || o === Bt ? o = N : o === Dt || o === zt ? o = Y : (o = N, n = void 0);
271
- const g = o === N && i[l + 1].startsWith("/>") ? " " : "";
272
- r += o === Y ? a + be : d >= 0 ? (s.push(u), a.slice(0, d) + Et + a.slice(d) + O + g) : a + O + (d === -2 ? (s.push(void 0), l) : g);
273
- }
274
- const c = r + (i[e] || "<?>") + (t === 2 ? "</svg>" : "");
260
+ var ls;
261
+ const Ct = window, Qe = Ct.trustedTypes, ti = Qe ? Qe.createPolicy("lit-html", { createHTML: (i) => i }) : void 0, vs = "$lit$", Ie = `lit$${(Math.random() + "").slice(9)}$`, $i = "?" + Ie, Ir = `<${$i}>`, We = document, ht = () => We.createComment(""), ut = (i) => i === null || typeof i != "object" && typeof i != "function", _i = Array.isArray, Nr = (i) => _i(i) || typeof (i == null ? void 0 : i[Symbol.iterator]) == "function", as = `[
262
+ \f\r]`, nt = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, si = /-->/g, ii = />/g, Fe = RegExp(`>|${as}(?:([^\\s"'>=/]+)(${as}*=${as}*(?:[^
263
+ \f\r"'\`<>=]|("|')|))|$)`, "g"), ri = /'/g, ni = /"/g, xi = /^(?:script|style|textarea|title)$/i, jr = (i) => (e, ...t) => ({ _$litType$: i, strings: e, values: t }), _e = jr(1), Ve = Symbol.for("lit-noChange"), te = Symbol.for("lit-nothing"), oi = /* @__PURE__ */ new WeakMap(), ze = We.createTreeWalker(We, 129, null, !1), Hr = (i, e) => {
264
+ const t = i.length - 1, s = [];
265
+ let n, l = e === 2 ? "<svg>" : "", o = nt;
266
+ for (let u = 0; u < t; u++) {
267
+ const d = i[u];
268
+ let m, v, $ = -1, M = 0;
269
+ for (; M < d.length && (o.lastIndex = M, v = o.exec(d), v !== null); )
270
+ M = o.lastIndex, o === nt ? v[1] === "!--" ? o = si : v[1] !== void 0 ? o = ii : v[2] !== void 0 ? (xi.test(v[2]) && (n = RegExp("</" + v[2], "g")), o = Fe) : v[3] !== void 0 && (o = Fe) : o === Fe ? v[0] === ">" ? (o = n ?? nt, $ = -1) : v[1] === void 0 ? $ = -2 : ($ = o.lastIndex - v[2].length, m = v[1], o = v[3] === void 0 ? Fe : v[3] === '"' ? ni : ri) : o === ni || o === ri ? o = Fe : o === si || o === ii ? o = nt : (o = Fe, n = void 0);
271
+ const j = o === Fe && i[u + 1].startsWith("/>") ? " " : "";
272
+ l += o === nt ? d + Ir : $ >= 0 ? (s.push(m), d.slice(0, $) + vs + d.slice($) + Ie + j) : d + Ie + ($ === -2 ? (s.push(void 0), u) : j);
273
+ }
274
+ const h = l + (i[t] || "<?>") + (e === 2 ? "</svg>" : "");
275
275
  if (!Array.isArray(i) || !i.hasOwnProperty("raw"))
276
276
  throw Error("invalid template strings array");
277
- return [Ft !== void 0 ? Ft.createHTML(c) : c, s];
277
+ return [ti !== void 0 ? ti.createHTML(h) : h, s];
278
278
  };
279
- class tt {
280
- constructor({ strings: t, _$litType$: e }, s) {
279
+ class dt {
280
+ constructor({ strings: e, _$litType$: t }, s) {
281
281
  let n;
282
282
  this.parts = [];
283
- let r = 0, o = 0;
284
- const c = t.length - 1, l = this.parts, [a, u] = we(t, e);
285
- if (this.el = tt.createElement(a, s), j.currentNode = this.el.content, e === 2) {
286
- const h = this.el.content, d = h.firstChild;
287
- d.remove(), h.append(...d.childNodes);
283
+ let l = 0, o = 0;
284
+ const h = e.length - 1, u = this.parts, [d, m] = Hr(e, t);
285
+ if (this.el = dt.createElement(d, s), ze.currentNode = this.el.content, t === 2) {
286
+ const v = this.el.content, $ = v.firstChild;
287
+ $.remove(), v.append(...$.childNodes);
288
288
  }
289
- for (; (n = j.nextNode()) !== null && l.length < c; ) {
289
+ for (; (n = ze.nextNode()) !== null && u.length < h; ) {
290
290
  if (n.nodeType === 1) {
291
291
  if (n.hasAttributes()) {
292
- const h = [];
293
- for (const d of n.getAttributeNames())
294
- if (d.endsWith(Et) || d.startsWith(O)) {
295
- const p = u[o++];
296
- if (h.push(d), p !== void 0) {
297
- const g = n.getAttribute(p.toLowerCase() + Et).split(O), v = /([.?@])?(.*)/.exec(p);
298
- l.push({ type: 1, index: r, name: v[2], strings: g, ctor: v[1] === "." ? Ce : v[1] === "?" ? Ie : v[1] === "@" ? ke : at });
292
+ const v = [];
293
+ for (const $ of n.getAttributeNames())
294
+ if ($.endsWith(vs) || $.startsWith(Ie)) {
295
+ const M = m[o++];
296
+ if (v.push($), M !== void 0) {
297
+ const j = n.getAttribute(M.toLowerCase() + vs).split(Ie), J = /([.?@])?(.*)/.exec(M);
298
+ u.push({ type: 1, index: l, name: J[2], strings: j, ctor: J[1] === "." ? Fr : J[1] === "?" ? zr : J[1] === "@" ? Wr : Dt });
299
299
  } else
300
- l.push({ type: 6, index: r });
300
+ u.push({ type: 6, index: l });
301
301
  }
302
- for (const d of h)
303
- n.removeAttribute(d);
302
+ for (const $ of v)
303
+ n.removeAttribute($);
304
304
  }
305
- if (le.test(n.tagName)) {
306
- const h = n.textContent.split(O), d = h.length - 1;
307
- if (d > 0) {
308
- n.textContent = W ? W.emptyScript : "";
309
- for (let p = 0; p < d; p++)
310
- n.append(h[p], Z()), j.nextNode(), l.push({ type: 2, index: ++r });
311
- n.append(h[d], Z());
305
+ if (xi.test(n.tagName)) {
306
+ const v = n.textContent.split(Ie), $ = v.length - 1;
307
+ if ($ > 0) {
308
+ n.textContent = Qe ? Qe.emptyScript : "";
309
+ for (let M = 0; M < $; M++)
310
+ n.append(v[M], ht()), ze.nextNode(), u.push({ type: 2, index: ++l });
311
+ n.append(v[$], ht());
312
312
  }
313
313
  }
314
314
  } else if (n.nodeType === 8)
315
- if (n.data === re)
316
- l.push({ type: 2, index: r });
315
+ if (n.data === $i)
316
+ u.push({ type: 2, index: l });
317
317
  else {
318
- let h = -1;
319
- for (; (h = n.data.indexOf(O, h + 1)) !== -1; )
320
- l.push({ type: 7, index: r }), h += O.length - 1;
318
+ let v = -1;
319
+ for (; (v = n.data.indexOf(Ie, v + 1)) !== -1; )
320
+ u.push({ type: 7, index: l }), v += Ie.length - 1;
321
321
  }
322
- r++;
322
+ l++;
323
323
  }
324
324
  }
325
- static createElement(t, e) {
326
- const s = H.createElement("template");
327
- return s.innerHTML = t, s;
325
+ static createElement(e, t) {
326
+ const s = We.createElement("template");
327
+ return s.innerHTML = e, s;
328
328
  }
329
329
  }
330
- function V(i, t, e = i, s) {
331
- var n, r, o, c;
332
- if (t === U)
333
- return t;
334
- let l = s !== void 0 ? (n = e._$Co) === null || n === void 0 ? void 0 : n[s] : e._$Cl;
335
- const a = q(t) ? void 0 : t._$litDirective$;
336
- return (l == null ? void 0 : l.constructor) !== a && ((r = l == null ? void 0 : l._$AO) === null || r === void 0 || r.call(l, !1), a === void 0 ? l = void 0 : (l = new a(i), l._$AT(i, e, s)), s !== void 0 ? ((o = (c = e)._$Co) !== null && o !== void 0 ? o : c._$Co = [])[s] = l : e._$Cl = l), l !== void 0 && (t = V(i, l._$AS(i, t.values), l, s)), t;
330
+ function et(i, e, t = i, s) {
331
+ var n, l, o, h;
332
+ if (e === Ve)
333
+ return e;
334
+ let u = s !== void 0 ? (n = t._$Co) === null || n === void 0 ? void 0 : n[s] : t._$Cl;
335
+ const d = ut(e) ? void 0 : e._$litDirective$;
336
+ return (u == null ? void 0 : u.constructor) !== d && ((l = u == null ? void 0 : u._$AO) === null || l === void 0 || l.call(u, !1), d === void 0 ? u = void 0 : (u = new d(i), u._$AT(i, t, s)), s !== void 0 ? ((o = (h = t)._$Co) !== null && o !== void 0 ? o : h._$Co = [])[s] = u : t._$Cl = u), u !== void 0 && (e = et(i, u._$AS(i, e.values), u, s)), e;
337
337
  }
338
- class Me {
339
- constructor(t, e) {
340
- this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = e;
338
+ class Ur {
339
+ constructor(e, t) {
340
+ this._$AV = [], this._$AN = void 0, this._$AD = e, this._$AM = t;
341
341
  }
342
342
  get parentNode() {
343
343
  return this._$AM.parentNode;
@@ -345,39 +345,39 @@ class Me {
345
345
  get _$AU() {
346
346
  return this._$AM._$AU;
347
347
  }
348
- u(t) {
349
- var e;
350
- const { el: { content: s }, parts: n } = this._$AD, r = ((e = t == null ? void 0 : t.creationScope) !== null && e !== void 0 ? e : H).importNode(s, !0);
351
- j.currentNode = r;
352
- let o = j.nextNode(), c = 0, l = 0, a = n[0];
353
- for (; a !== void 0; ) {
354
- if (c === a.index) {
355
- let u;
356
- a.type === 2 ? u = new et(o, o.nextSibling, this, t) : a.type === 1 ? u = new a.ctor(o, a.name, a.strings, this, t) : a.type === 6 && (u = new Oe(o, this, t)), this._$AV.push(u), a = n[++l];
348
+ u(e) {
349
+ var t;
350
+ const { el: { content: s }, parts: n } = this._$AD, l = ((t = e == null ? void 0 : e.creationScope) !== null && t !== void 0 ? t : We).importNode(s, !0);
351
+ ze.currentNode = l;
352
+ let o = ze.nextNode(), h = 0, u = 0, d = n[0];
353
+ for (; d !== void 0; ) {
354
+ if (h === d.index) {
355
+ let m;
356
+ d.type === 2 ? m = new pt(o, o.nextSibling, this, e) : d.type === 1 ? m = new d.ctor(o, d.name, d.strings, this, e) : d.type === 6 && (m = new Vr(o, this, e)), this._$AV.push(m), d = n[++u];
357
357
  }
358
- c !== (a == null ? void 0 : a.index) && (o = j.nextNode(), c++);
358
+ h !== (d == null ? void 0 : d.index) && (o = ze.nextNode(), h++);
359
359
  }
360
- return j.currentNode = H, r;
360
+ return ze.currentNode = We, l;
361
361
  }
362
- v(t) {
363
- let e = 0;
362
+ v(e) {
363
+ let t = 0;
364
364
  for (const s of this._$AV)
365
- s !== void 0 && (s.strings !== void 0 ? (s._$AI(t, s, e), e += s.strings.length - 2) : s._$AI(t[e])), e++;
365
+ s !== void 0 && (s.strings !== void 0 ? (s._$AI(e, s, t), t += s.strings.length - 2) : s._$AI(e[t])), t++;
366
366
  }
367
367
  }
368
- class et {
369
- constructor(t, e, s, n) {
370
- var r;
371
- this.type = 2, this._$AH = _, this._$AN = void 0, this._$AA = t, this._$AB = e, this._$AM = s, this.options = n, this._$Cp = (r = n == null ? void 0 : n.isConnected) === null || r === void 0 || r;
368
+ class pt {
369
+ constructor(e, t, s, n) {
370
+ var l;
371
+ this.type = 2, this._$AH = te, this._$AN = void 0, this._$AA = e, this._$AB = t, this._$AM = s, this.options = n, this._$Cp = (l = n == null ? void 0 : n.isConnected) === null || l === void 0 || l;
372
372
  }
373
373
  get _$AU() {
374
- var t, e;
375
- return (e = (t = this._$AM) === null || t === void 0 ? void 0 : t._$AU) !== null && e !== void 0 ? e : this._$Cp;
374
+ var e, t;
375
+ return (t = (e = this._$AM) === null || e === void 0 ? void 0 : e._$AU) !== null && t !== void 0 ? t : this._$Cp;
376
376
  }
377
377
  get parentNode() {
378
- let t = this._$AA.parentNode;
379
- const e = this._$AM;
380
- return e !== void 0 && (t == null ? void 0 : t.nodeType) === 11 && (t = e.parentNode), t;
378
+ let e = this._$AA.parentNode;
379
+ const t = this._$AM;
380
+ return t !== void 0 && (e == null ? void 0 : e.nodeType) === 11 && (e = t.parentNode), e;
381
381
  }
382
382
  get startNode() {
383
383
  return this._$AA;
@@ -385,55 +385,55 @@ class et {
385
385
  get endNode() {
386
386
  return this._$AB;
387
387
  }
388
- _$AI(t, e = this) {
389
- t = V(this, t, e), q(t) ? t === _ || t == null || t === "" ? (this._$AH !== _ && this._$AR(), this._$AH = _) : t !== this._$AH && t !== U && this._(t) : t._$litType$ !== void 0 ? this.g(t) : t.nodeType !== void 0 ? this.$(t) : xe(t) ? this.T(t) : this._(t);
388
+ _$AI(e, t = this) {
389
+ e = et(this, e, t), ut(e) ? e === te || e == null || e === "" ? (this._$AH !== te && this._$AR(), this._$AH = te) : e !== this._$AH && e !== Ve && this._(e) : e._$litType$ !== void 0 ? this.g(e) : e.nodeType !== void 0 ? this.$(e) : Nr(e) ? this.T(e) : this._(e);
390
390
  }
391
- k(t) {
392
- return this._$AA.parentNode.insertBefore(t, this._$AB);
391
+ k(e) {
392
+ return this._$AA.parentNode.insertBefore(e, this._$AB);
393
393
  }
394
- $(t) {
395
- this._$AH !== t && (this._$AR(), this._$AH = this.k(t));
394
+ $(e) {
395
+ this._$AH !== e && (this._$AR(), this._$AH = this.k(e));
396
396
  }
397
- _(t) {
398
- this._$AH !== _ && q(this._$AH) ? this._$AA.nextSibling.data = t : this.$(H.createTextNode(t)), this._$AH = t;
397
+ _(e) {
398
+ this._$AH !== te && ut(this._$AH) ? this._$AA.nextSibling.data = e : this.$(We.createTextNode(e)), this._$AH = e;
399
399
  }
400
- g(t) {
401
- var e;
402
- const { values: s, _$litType$: n } = t, r = typeof n == "number" ? this._$AC(t) : (n.el === void 0 && (n.el = tt.createElement(n.h, this.options)), n);
403
- if (((e = this._$AH) === null || e === void 0 ? void 0 : e._$AD) === r)
400
+ g(e) {
401
+ var t;
402
+ const { values: s, _$litType$: n } = e, l = typeof n == "number" ? this._$AC(e) : (n.el === void 0 && (n.el = dt.createElement(n.h, this.options)), n);
403
+ if (((t = this._$AH) === null || t === void 0 ? void 0 : t._$AD) === l)
404
404
  this._$AH.v(s);
405
405
  else {
406
- const o = new Me(r, this), c = o.u(this.options);
407
- o.v(s), this.$(c), this._$AH = o;
406
+ const o = new Ur(l, this), h = o.u(this.options);
407
+ o.v(s), this.$(h), this._$AH = o;
408
408
  }
409
409
  }
410
- _$AC(t) {
411
- let e = Vt.get(t.strings);
412
- return e === void 0 && Vt.set(t.strings, e = new tt(t)), e;
410
+ _$AC(e) {
411
+ let t = oi.get(e.strings);
412
+ return t === void 0 && oi.set(e.strings, t = new dt(e)), t;
413
413
  }
414
- T(t) {
415
- oe(this._$AH) || (this._$AH = [], this._$AR());
416
- const e = this._$AH;
414
+ T(e) {
415
+ _i(this._$AH) || (this._$AH = [], this._$AR());
416
+ const t = this._$AH;
417
417
  let s, n = 0;
418
- for (const r of t)
419
- n === e.length ? e.push(s = new et(this.k(Z()), this.k(Z()), this, this.options)) : s = e[n], s._$AI(r), n++;
420
- n < e.length && (this._$AR(s && s._$AB.nextSibling, n), e.length = n);
418
+ for (const l of e)
419
+ n === t.length ? t.push(s = new pt(this.k(ht()), this.k(ht()), this, this.options)) : s = t[n], s._$AI(l), n++;
420
+ n < t.length && (this._$AR(s && s._$AB.nextSibling, n), t.length = n);
421
421
  }
422
- _$AR(t = this._$AA.nextSibling, e) {
422
+ _$AR(e = this._$AA.nextSibling, t) {
423
423
  var s;
424
- for ((s = this._$AP) === null || s === void 0 || s.call(this, !1, !0, e); t && t !== this._$AB; ) {
425
- const n = t.nextSibling;
426
- t.remove(), t = n;
424
+ for ((s = this._$AP) === null || s === void 0 || s.call(this, !1, !0, t); e && e !== this._$AB; ) {
425
+ const n = e.nextSibling;
426
+ e.remove(), e = n;
427
427
  }
428
428
  }
429
- setConnected(t) {
430
- var e;
431
- this._$AM === void 0 && (this._$Cp = t, (e = this._$AP) === null || e === void 0 || e.call(this, t));
429
+ setConnected(e) {
430
+ var t;
431
+ this._$AM === void 0 && (this._$Cp = e, (t = this._$AP) === null || t === void 0 || t.call(this, e));
432
432
  }
433
433
  }
434
- class at {
435
- constructor(t, e, s, n, r) {
436
- this.type = 1, this._$AH = _, this._$AN = void 0, this.element = t, this.name = e, this._$AM = n, this.options = r, s.length > 2 || s[0] !== "" || s[1] !== "" ? (this._$AH = Array(s.length - 1).fill(new String()), this.strings = s) : this._$AH = _;
434
+ class Dt {
435
+ constructor(e, t, s, n, l) {
436
+ this.type = 1, this._$AH = te, this._$AN = void 0, this.element = e, this.name = t, this._$AM = n, this.options = l, s.length > 2 || s[0] !== "" || s[1] !== "" ? (this._$AH = Array(s.length - 1).fill(new String()), this.strings = s) : this._$AH = te;
437
437
  }
438
438
  get tagName() {
439
439
  return this.element.tagName;
@@ -441,76 +441,76 @@ class at {
441
441
  get _$AU() {
442
442
  return this._$AM._$AU;
443
443
  }
444
- _$AI(t, e = this, s, n) {
445
- const r = this.strings;
444
+ _$AI(e, t = this, s, n) {
445
+ const l = this.strings;
446
446
  let o = !1;
447
- if (r === void 0)
448
- t = V(this, t, e, 0), o = !q(t) || t !== this._$AH && t !== U, o && (this._$AH = t);
447
+ if (l === void 0)
448
+ e = et(this, e, t, 0), o = !ut(e) || e !== this._$AH && e !== Ve, o && (this._$AH = e);
449
449
  else {
450
- const c = t;
451
- let l, a;
452
- for (t = r[0], l = 0; l < r.length - 1; l++)
453
- a = V(this, c[s + l], e, l), a === U && (a = this._$AH[l]), o || (o = !q(a) || a !== this._$AH[l]), a === _ ? t = _ : t !== _ && (t += (a ?? "") + r[l + 1]), this._$AH[l] = a;
450
+ const h = e;
451
+ let u, d;
452
+ for (e = l[0], u = 0; u < l.length - 1; u++)
453
+ d = et(this, h[s + u], t, u), d === Ve && (d = this._$AH[u]), o || (o = !ut(d) || d !== this._$AH[u]), d === te ? e = te : e !== te && (e += (d ?? "") + l[u + 1]), this._$AH[u] = d;
454
454
  }
455
- o && !n && this.j(t);
455
+ o && !n && this.j(e);
456
456
  }
457
- j(t) {
458
- t === _ ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
457
+ j(e) {
458
+ e === te ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, e ?? "");
459
459
  }
460
460
  }
461
- class Ce extends at {
461
+ class Fr extends Dt {
462
462
  constructor() {
463
463
  super(...arguments), this.type = 3;
464
464
  }
465
- j(t) {
466
- this.element[this.name] = t === _ ? void 0 : t;
465
+ j(e) {
466
+ this.element[this.name] = e === te ? void 0 : e;
467
467
  }
468
468
  }
469
- const Re = W ? W.emptyScript : "";
470
- class Ie extends at {
469
+ const Br = Qe ? Qe.emptyScript : "";
470
+ class zr extends Dt {
471
471
  constructor() {
472
472
  super(...arguments), this.type = 4;
473
473
  }
474
- j(t) {
475
- t && t !== _ ? this.element.setAttribute(this.name, Re) : this.element.removeAttribute(this.name);
474
+ j(e) {
475
+ e && e !== te ? this.element.setAttribute(this.name, Br) : this.element.removeAttribute(this.name);
476
476
  }
477
477
  }
478
- class ke extends at {
479
- constructor(t, e, s, n, r) {
480
- super(t, e, s, n, r), this.type = 5;
478
+ class Wr extends Dt {
479
+ constructor(e, t, s, n, l) {
480
+ super(e, t, s, n, l), this.type = 5;
481
481
  }
482
- _$AI(t, e = this) {
482
+ _$AI(e, t = this) {
483
483
  var s;
484
- if ((t = (s = V(this, t, e, 0)) !== null && s !== void 0 ? s : _) === U)
484
+ if ((e = (s = et(this, e, t, 0)) !== null && s !== void 0 ? s : te) === Ve)
485
485
  return;
486
- const n = this._$AH, r = t === _ && n !== _ || t.capture !== n.capture || t.once !== n.once || t.passive !== n.passive, o = t !== _ && (n === _ || r);
487
- r && this.element.removeEventListener(this.name, this, n), o && this.element.addEventListener(this.name, this, t), this._$AH = t;
486
+ const n = this._$AH, l = e === te && n !== te || e.capture !== n.capture || e.once !== n.once || e.passive !== n.passive, o = e !== te && (n === te || l);
487
+ l && this.element.removeEventListener(this.name, this, n), o && this.element.addEventListener(this.name, this, e), this._$AH = e;
488
488
  }
489
- handleEvent(t) {
490
- var e, s;
491
- typeof this._$AH == "function" ? this._$AH.call((s = (e = this.options) === null || e === void 0 ? void 0 : e.host) !== null && s !== void 0 ? s : this.element, t) : this._$AH.handleEvent(t);
489
+ handleEvent(e) {
490
+ var t, s;
491
+ typeof this._$AH == "function" ? this._$AH.call((s = (t = this.options) === null || t === void 0 ? void 0 : t.host) !== null && s !== void 0 ? s : this.element, e) : this._$AH.handleEvent(e);
492
492
  }
493
493
  }
494
- class Oe {
495
- constructor(t, e, s) {
496
- this.element = t, this.type = 6, this._$AN = void 0, this._$AM = e, this.options = s;
494
+ class Vr {
495
+ constructor(e, t, s) {
496
+ this.element = e, this.type = 6, this._$AN = void 0, this._$AM = t, this.options = s;
497
497
  }
498
498
  get _$AU() {
499
499
  return this._$AM._$AU;
500
500
  }
501
- _$AI(t) {
502
- V(this, t);
501
+ _$AI(e) {
502
+ et(this, e);
503
503
  }
504
504
  }
505
- const Kt = lt.litHtmlPolyfillSupport;
506
- Kt == null || Kt(tt, et), ((pt = lt.litHtmlVersions) !== null && pt !== void 0 ? pt : lt.litHtmlVersions = []).push("2.7.4");
507
- const Te = (i, t, e) => {
505
+ const li = Ct.litHtmlPolyfillSupport;
506
+ li == null || li(dt, pt), ((ls = Ct.litHtmlVersions) !== null && ls !== void 0 ? ls : Ct.litHtmlVersions = []).push("2.7.4");
507
+ const Yr = (i, e, t) => {
508
508
  var s, n;
509
- const r = (s = e == null ? void 0 : e.renderBefore) !== null && s !== void 0 ? s : t;
510
- let o = r._$litPart$;
509
+ const l = (s = t == null ? void 0 : t.renderBefore) !== null && s !== void 0 ? s : e;
510
+ let o = l._$litPart$;
511
511
  if (o === void 0) {
512
- const c = (n = e == null ? void 0 : e.renderBefore) !== null && n !== void 0 ? n : null;
513
- r._$litPart$ = o = new et(t.insertBefore(Z(), c), c, void 0, e ?? {});
512
+ const h = (n = t == null ? void 0 : t.renderBefore) !== null && n !== void 0 ? n : null;
513
+ l._$litPart$ = o = new pt(e.insertBefore(ht(), h), h, void 0, t ?? {});
514
514
  }
515
515
  return o._$AI(i), o;
516
516
  };
@@ -519,97 +519,97 @@ const Te = (i, t, e) => {
519
519
  * Copyright 2017 Google LLC
520
520
  * SPDX-License-Identifier: BSD-3-Clause
521
521
  */
522
- var mt, _t;
523
- class Q extends B {
522
+ var cs, hs;
523
+ class ct extends Ze {
524
524
  constructor() {
525
525
  super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
526
526
  }
527
527
  createRenderRoot() {
528
- var t, e;
528
+ var e, t;
529
529
  const s = super.createRenderRoot();
530
- return (t = (e = this.renderOptions).renderBefore) !== null && t !== void 0 || (e.renderBefore = s.firstChild), s;
530
+ return (e = (t = this.renderOptions).renderBefore) !== null && e !== void 0 || (t.renderBefore = s.firstChild), s;
531
531
  }
532
- update(t) {
533
- const e = this.render();
534
- this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = Te(e, this.renderRoot, this.renderOptions);
532
+ update(e) {
533
+ const t = this.render();
534
+ this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(e), this._$Do = Yr(t, this.renderRoot, this.renderOptions);
535
535
  }
536
536
  connectedCallback() {
537
- var t;
538
- super.connectedCallback(), (t = this._$Do) === null || t === void 0 || t.setConnected(!0);
537
+ var e;
538
+ super.connectedCallback(), (e = this._$Do) === null || e === void 0 || e.setConnected(!0);
539
539
  }
540
540
  disconnectedCallback() {
541
- var t;
542
- super.disconnectedCallback(), (t = this._$Do) === null || t === void 0 || t.setConnected(!1);
541
+ var e;
542
+ super.disconnectedCallback(), (e = this._$Do) === null || e === void 0 || e.setConnected(!1);
543
543
  }
544
544
  render() {
545
- return U;
545
+ return Ve;
546
546
  }
547
547
  }
548
- Q.finalized = !0, Q._$litElement$ = !0, (mt = globalThis.litElementHydrateSupport) === null || mt === void 0 || mt.call(globalThis, { LitElement: Q });
549
- const Gt = globalThis.litElementPolyfillSupport;
550
- Gt == null || Gt({ LitElement: Q });
551
- ((_t = globalThis.litElementVersions) !== null && _t !== void 0 ? _t : globalThis.litElementVersions = []).push("3.3.2");
548
+ ct.finalized = !0, ct._$litElement$ = !0, (cs = globalThis.litElementHydrateSupport) === null || cs === void 0 || cs.call(globalThis, { LitElement: ct });
549
+ const ai = globalThis.litElementPolyfillSupport;
550
+ ai == null || ai({ LitElement: ct });
551
+ ((hs = globalThis.litElementVersions) !== null && hs !== void 0 ? hs : globalThis.litElementVersions = []).push("3.3.2");
552
552
  /**
553
553
  * @license
554
554
  * Copyright 2017 Google LLC
555
555
  * SPDX-License-Identifier: BSD-3-Clause
556
556
  */
557
- const Le = (i) => (t) => typeof t == "function" ? ((e, s) => (customElements.define(e, s), s))(i, t) : ((e, s) => {
558
- const { kind: n, elements: r } = s;
559
- return { kind: n, elements: r, finisher(o) {
560
- customElements.define(e, o);
557
+ const Kr = (i) => (e) => typeof e == "function" ? ((t, s) => (customElements.define(t, s), s))(i, e) : ((t, s) => {
558
+ const { kind: n, elements: l } = s;
559
+ return { kind: n, elements: l, finisher(o) {
560
+ customElements.define(t, o);
561
561
  } };
562
- })(i, t);
562
+ })(i, e);
563
563
  /**
564
564
  * @license
565
565
  * Copyright 2017 Google LLC
566
566
  * SPDX-License-Identifier: BSD-3-Clause
567
567
  */
568
- const Ne = (i, t) => t.kind === "method" && t.descriptor && !("value" in t.descriptor) ? { ...t, finisher(e) {
569
- e.createProperty(t.key, i);
570
- } } : { kind: "field", key: Symbol(), placement: "own", descriptor: {}, originalKey: t.key, initializer() {
571
- typeof t.initializer == "function" && (this[t.key] = t.initializer.call(this));
572
- }, finisher(e) {
573
- e.createProperty(t.key, i);
574
- } };
575
- function Ot(i) {
576
- return (t, e) => e !== void 0 ? ((s, n, r) => {
577
- n.constructor.createProperty(r, s);
578
- })(i, t, e) : Ne(i, t);
568
+ const qr = (i, e) => e.kind === "method" && e.descriptor && !("value" in e.descriptor) ? { ...e, finisher(t) {
569
+ t.createProperty(e.key, i);
570
+ } } : { kind: "field", key: Symbol(), placement: "own", descriptor: {}, originalKey: e.key, initializer() {
571
+ typeof e.initializer == "function" && (this[e.key] = e.initializer.call(this));
572
+ }, finisher(t) {
573
+ t.createProperty(e.key, i);
574
+ } }, Xr = (i, e, t) => {
575
+ e.constructor.createProperty(t, i);
576
+ };
577
+ function Ss(i) {
578
+ return (e, t) => t !== void 0 ? Xr(i, e, t) : qr(i, e);
579
579
  }
580
580
  /**
581
581
  * @license
582
582
  * Copyright 2017 Google LLC
583
583
  * SPDX-License-Identifier: BSD-3-Clause
584
584
  */
585
- function ht(i) {
586
- return Ot({ ...i, state: !0 });
585
+ function Tt(i) {
586
+ return Ss({ ...i, state: !0 });
587
587
  }
588
588
  /**
589
589
  * @license
590
590
  * Copyright 2021 Google LLC
591
591
  * SPDX-License-Identifier: BSD-3-Clause
592
592
  */
593
- var yt;
594
- ((yt = window.HTMLSlotElement) === null || yt === void 0 ? void 0 : yt.prototype.assignedElements) != null;
593
+ var us;
594
+ ((us = window.HTMLSlotElement) === null || us === void 0 ? void 0 : us.prototype.assignedElements) != null;
595
595
  /**
596
596
  * @license
597
597
  * Copyright 2021 Google LLC
598
598
  * SPDX-License-Identifier: BSD-3-Clause
599
599
  */
600
- function J(i, t, e) {
601
- return i ? t() : e == null ? void 0 : e();
600
+ function ot(i, e, t) {
601
+ return i ? e() : t == null ? void 0 : t();
602
602
  }
603
603
  /**
604
604
  * @license
605
605
  * Copyright 2021 Google LLC
606
606
  * SPDX-License-Identifier: BSD-3-Clause
607
607
  */
608
- function* X(i, t) {
608
+ function* lt(i, e) {
609
609
  if (i !== void 0) {
610
- let e = 0;
610
+ let t = 0;
611
611
  for (const s of i)
612
- yield t(s, e++);
612
+ yield e(s, t++);
613
613
  }
614
614
  }
615
615
  /**
@@ -617,21 +617,21 @@ function* X(i, t) {
617
617
  * Copyright 2017 Google LLC
618
618
  * SPDX-License-Identifier: BSD-3-Clause
619
619
  */
620
- const Pe = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4, EVENT: 5, ELEMENT: 6 }, je = (i) => (...t) => ({ _$litDirective$: i, values: t });
621
- class He {
622
- constructor(t) {
620
+ const Gr = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4, EVENT: 5, ELEMENT: 6 }, Jr = (i) => (...e) => ({ _$litDirective$: i, values: e });
621
+ class Zr {
622
+ constructor(e) {
623
623
  }
624
624
  get _$AU() {
625
625
  return this._$AM._$AU;
626
626
  }
627
- _$AT(t, e, s) {
628
- this._$Ct = t, this._$AM = e, this._$Ci = s;
627
+ _$AT(e, t, s) {
628
+ this._$Ct = e, this._$AM = t, this._$Ci = s;
629
629
  }
630
- _$AS(t, e) {
631
- return this.update(t, e);
630
+ _$AS(e, t) {
631
+ return this.update(e, t);
632
632
  }
633
- update(t, e) {
634
- return this.render(...e);
633
+ update(e, t) {
634
+ return this.render(...t);
635
635
  }
636
636
  }
637
637
  /**
@@ -639,78 +639,78 @@ class He {
639
639
  * Copyright 2017 Google LLC
640
640
  * SPDX-License-Identifier: BSD-3-Clause
641
641
  */
642
- class bt extends He {
643
- constructor(t) {
644
- if (super(t), this.et = _, t.type !== Pe.CHILD)
642
+ class ms extends Zr {
643
+ constructor(e) {
644
+ if (super(e), this.et = te, e.type !== Gr.CHILD)
645
645
  throw Error(this.constructor.directiveName + "() can only be used in child bindings");
646
646
  }
647
- render(t) {
648
- if (t === _ || t == null)
649
- return this.ft = void 0, this.et = t;
650
- if (t === U)
651
- return t;
652
- if (typeof t != "string")
647
+ render(e) {
648
+ if (e === te || e == null)
649
+ return this.ft = void 0, this.et = e;
650
+ if (e === Ve)
651
+ return e;
652
+ if (typeof e != "string")
653
653
  throw Error(this.constructor.directiveName + "() called with a non-string value");
654
- if (t === this.et)
654
+ if (e === this.et)
655
655
  return this.ft;
656
- this.et = t;
657
- const e = [t];
658
- return e.raw = e, this.ft = { _$litType$: this.constructor.resultType, strings: e, values: [] };
656
+ this.et = e;
657
+ const t = [e];
658
+ return t.raw = t, this.ft = { _$litType$: this.constructor.resultType, strings: t, values: [] };
659
659
  }
660
660
  }
661
- bt.directiveName = "unsafeHTML", bt.resultType = 1;
662
- const Yt = je(bt);
663
- function k(i) {
664
- return Array.isArray ? Array.isArray(i) : he(i) === "[object Array]";
661
+ ms.directiveName = "unsafeHTML", ms.resultType = 1;
662
+ const ci = Jr(ms);
663
+ function Re(i) {
664
+ return Array.isArray ? Array.isArray(i) : Mi(i) === "[object Array]";
665
665
  }
666
- const Ue = 1 / 0;
667
- function Fe(i) {
666
+ const Qr = 1 / 0;
667
+ function en(i) {
668
668
  if (typeof i == "string")
669
669
  return i;
670
- let t = i + "";
671
- return t == "0" && 1 / i == -Ue ? "-0" : t;
670
+ let e = i + "";
671
+ return e == "0" && 1 / i == -Qr ? "-0" : e;
672
672
  }
673
- function De(i) {
674
- return i == null ? "" : Fe(i);
673
+ function tn(i) {
674
+ return i == null ? "" : en(i);
675
675
  }
676
- function C(i) {
676
+ function Te(i) {
677
677
  return typeof i == "string";
678
678
  }
679
- function ce(i) {
679
+ function wi(i) {
680
680
  return typeof i == "number";
681
681
  }
682
- function ze(i) {
683
- return i === !0 || i === !1 || Be(i) && he(i) == "[object Boolean]";
682
+ function sn(i) {
683
+ return i === !0 || i === !1 || rn(i) && Mi(i) == "[object Boolean]";
684
684
  }
685
- function ae(i) {
685
+ function Ai(i) {
686
686
  return typeof i == "object";
687
687
  }
688
- function Be(i) {
689
- return ae(i) && i !== null;
688
+ function rn(i) {
689
+ return Ai(i) && i !== null;
690
690
  }
691
- function b(i) {
691
+ function xe(i) {
692
692
  return i != null;
693
693
  }
694
- function $t(i) {
694
+ function ds(i) {
695
695
  return !i.trim().length;
696
696
  }
697
- function he(i) {
697
+ function Mi(i) {
698
698
  return i == null ? i === void 0 ? "[object Undefined]" : "[object Null]" : Object.prototype.toString.call(i);
699
699
  }
700
- const We = "Incorrect 'index' type", Ve = (i) => `Invalid value for key ${i}`, Ke = (i) => `Pattern length exceeds max of ${i}.`, Ge = (i) => `Missing ${i} property in key`, Ye = (i) => `Property 'weight' in key '${i}' must be a positive integer`, Jt = Object.prototype.hasOwnProperty;
701
- class Je {
702
- constructor(t) {
700
+ const nn = "Incorrect 'index' type", on = (i) => `Invalid value for key ${i}`, ln = (i) => `Pattern length exceeds max of ${i}.`, an = (i) => `Missing ${i} property in key`, cn = (i) => `Property 'weight' in key '${i}' must be a positive integer`, hi = Object.prototype.hasOwnProperty;
701
+ class hn {
702
+ constructor(e) {
703
703
  this._keys = [], this._keyMap = {};
704
- let e = 0;
705
- t.forEach((s) => {
706
- let n = ue(s);
707
- e += n.weight, this._keys.push(n), this._keyMap[n.id] = n, e += n.weight;
704
+ let t = 0;
705
+ e.forEach((s) => {
706
+ let n = Si(s);
707
+ t += n.weight, this._keys.push(n), this._keyMap[n.id] = n, t += n.weight;
708
708
  }), this._keys.forEach((s) => {
709
- s.weight /= e;
709
+ s.weight /= t;
710
710
  });
711
711
  }
712
- get(t) {
713
- return this._keyMap[t];
712
+ get(e) {
713
+ return this._keyMap[e];
714
714
  }
715
715
  keys() {
716
716
  return this._keys;
@@ -719,50 +719,50 @@ class Je {
719
719
  return JSON.stringify(this._keys);
720
720
  }
721
721
  }
722
- function ue(i) {
723
- let t = null, e = null, s = null, n = 1, r = null;
724
- if (C(i) || k(i))
725
- s = i, t = Xt(i), e = xt(i);
722
+ function Si(i) {
723
+ let e = null, t = null, s = null, n = 1, l = null;
724
+ if (Te(i) || Re(i))
725
+ s = i, e = ui(i), t = ys(i);
726
726
  else {
727
- if (!Jt.call(i, "name"))
728
- throw new Error(Ge("name"));
727
+ if (!hi.call(i, "name"))
728
+ throw new Error(an("name"));
729
729
  const o = i.name;
730
- if (s = o, Jt.call(i, "weight") && (n = i.weight, n <= 0))
731
- throw new Error(Ye(o));
732
- t = Xt(o), e = xt(o), r = i.getFn;
730
+ if (s = o, hi.call(i, "weight") && (n = i.weight, n <= 0))
731
+ throw new Error(cn(o));
732
+ e = ui(o), t = ys(o), l = i.getFn;
733
733
  }
734
- return { path: t, id: e, weight: n, src: s, getFn: r };
734
+ return { path: e, id: t, weight: n, src: s, getFn: l };
735
735
  }
736
- function Xt(i) {
737
- return k(i) ? i : i.split(".");
736
+ function ui(i) {
737
+ return Re(i) ? i : i.split(".");
738
738
  }
739
- function xt(i) {
740
- return k(i) ? i.join(".") : i;
739
+ function ys(i) {
740
+ return Re(i) ? i.join(".") : i;
741
741
  }
742
- function Xe(i, t) {
743
- let e = [], s = !1;
744
- const n = (r, o, c) => {
745
- if (b(r))
746
- if (!o[c])
747
- e.push(r);
742
+ function un(i, e) {
743
+ let t = [], s = !1;
744
+ const n = (l, o, h) => {
745
+ if (xe(l))
746
+ if (!o[h])
747
+ t.push(l);
748
748
  else {
749
- let l = o[c];
750
- const a = r[l];
751
- if (!b(a))
749
+ let u = o[h];
750
+ const d = l[u];
751
+ if (!xe(d))
752
752
  return;
753
- if (c === o.length - 1 && (C(a) || ce(a) || ze(a)))
754
- e.push(De(a));
755
- else if (k(a)) {
753
+ if (h === o.length - 1 && (Te(d) || wi(d) || sn(d)))
754
+ t.push(tn(d));
755
+ else if (Re(d)) {
756
756
  s = !0;
757
- for (let u = 0, h = a.length; u < h; u += 1)
758
- n(a[u], o, c + 1);
757
+ for (let m = 0, v = d.length; m < v; m += 1)
758
+ n(d[m], o, h + 1);
759
759
  } else
760
- o.length && n(a, o, c + 1);
760
+ o.length && n(d, o, h + 1);
761
761
  }
762
762
  };
763
- return n(i, C(t) ? t.split(".") : t, 0), s ? e : e[0];
763
+ return n(i, Te(e) ? e.split(".") : e, 0), s ? t : t[0];
764
764
  }
765
- const Qe = {
765
+ const dn = {
766
766
  // Whether the matches should be included in the result set. When `true`, each record in the result
767
767
  // set will include the indices of the matched characters.
768
768
  // These can consequently be used for highlighting purposes.
@@ -772,7 +772,7 @@ const Qe = {
772
772
  findAllMatches: !1,
773
773
  // Minimum number of characters that must be matched before a result is considered a match
774
774
  minMatchCharLength: 1
775
- }, Ze = {
775
+ }, pn = {
776
776
  // When `true`, the algorithm continues searching to the end of the input even if a perfect
777
777
  // match is found before the end of the same input.
778
778
  isCaseSensitive: !1,
@@ -783,8 +783,8 @@ const Qe = {
783
783
  // Whether to sort the result list, by score
784
784
  shouldSort: !0,
785
785
  // Default sort function: sort by ascending score, ascending index
786
- sortFn: (i, t) => i.score === t.score ? i.idx < t.idx ? -1 : 1 : i.score < t.score ? -1 : 1
787
- }, qe = {
786
+ sortFn: (i, e) => i.score === e.score ? i.idx < e.idx ? -1 : 1 : i.score < e.score ? -1 : 1
787
+ }, fn = {
788
788
  // Approximately where in the text is the pattern expected to be found?
789
789
  location: 0,
790
790
  // At what point does the match algorithm give up. A threshold of '0.0' requires a perfect match
@@ -796,12 +796,12 @@ const Qe = {
796
796
  // the exact location specified, a threshold of '1000' would require a perfect match
797
797
  // to be within 800 characters of the fuzzy location to be found using a 0.8 threshold.
798
798
  distance: 100
799
- }, ts = {
799
+ }, gn = {
800
800
  // When `true`, it enables the use of unix-like search commands
801
801
  useExtendedSearch: !1,
802
802
  // The get function to use when fetching an object's properties.
803
803
  // The default will search nested paths *ie foo.bar.baz*
804
- getFn: Xe,
804
+ getFn: un,
805
805
  // When `true`, search will ignore `location` and `distance`, so it won't matter
806
806
  // where in the string the pattern appears.
807
807
  // More info: https://fusejs.io/concepts/scoring-theory.html#fuzziness-score
@@ -813,113 +813,113 @@ const Qe = {
813
813
  // The weight to determine how much field length norm effects scoring.
814
814
  fieldNormWeight: 1
815
815
  };
816
- var f = {
817
- ...Ze,
818
- ...Qe,
819
- ...qe,
820
- ...ts
816
+ var T = {
817
+ ...pn,
818
+ ...dn,
819
+ ...fn,
820
+ ...gn
821
821
  };
822
- const es = /[^ ]+/g;
823
- function ss(i = 1, t = 3) {
824
- const e = /* @__PURE__ */ new Map(), s = Math.pow(10, t);
822
+ const vn = /[^ ]+/g;
823
+ function mn(i = 1, e = 3) {
824
+ const t = /* @__PURE__ */ new Map(), s = Math.pow(10, e);
825
825
  return {
826
826
  get(n) {
827
- const r = n.match(es).length;
828
- if (e.has(r))
829
- return e.get(r);
830
- const o = 1 / Math.pow(r, 0.5 * i), c = parseFloat(Math.round(o * s) / s);
831
- return e.set(r, c), c;
827
+ const l = n.match(vn).length;
828
+ if (t.has(l))
829
+ return t.get(l);
830
+ const o = 1 / Math.pow(l, 0.5 * i), h = parseFloat(Math.round(o * s) / s);
831
+ return t.set(l, h), h;
832
832
  },
833
833
  clear() {
834
- e.clear();
834
+ t.clear();
835
835
  }
836
836
  };
837
837
  }
838
- class Tt {
838
+ class Es {
839
839
  constructor({
840
- getFn: t = f.getFn,
841
- fieldNormWeight: e = f.fieldNormWeight
840
+ getFn: e = T.getFn,
841
+ fieldNormWeight: t = T.fieldNormWeight
842
842
  } = {}) {
843
- this.norm = ss(e, 3), this.getFn = t, this.isCreated = !1, this.setIndexRecords();
843
+ this.norm = mn(t, 3), this.getFn = e, this.isCreated = !1, this.setIndexRecords();
844
844
  }
845
- setSources(t = []) {
846
- this.docs = t;
845
+ setSources(e = []) {
846
+ this.docs = e;
847
847
  }
848
- setIndexRecords(t = []) {
849
- this.records = t;
848
+ setIndexRecords(e = []) {
849
+ this.records = e;
850
850
  }
851
- setKeys(t = []) {
852
- this.keys = t, this._keysMap = {}, t.forEach((e, s) => {
853
- this._keysMap[e.id] = s;
851
+ setKeys(e = []) {
852
+ this.keys = e, this._keysMap = {}, e.forEach((t, s) => {
853
+ this._keysMap[t.id] = s;
854
854
  });
855
855
  }
856
856
  create() {
857
- this.isCreated || !this.docs.length || (this.isCreated = !0, C(this.docs[0]) ? this.docs.forEach((t, e) => {
858
- this._addString(t, e);
859
- }) : this.docs.forEach((t, e) => {
860
- this._addObject(t, e);
857
+ this.isCreated || !this.docs.length || (this.isCreated = !0, Te(this.docs[0]) ? this.docs.forEach((e, t) => {
858
+ this._addString(e, t);
859
+ }) : this.docs.forEach((e, t) => {
860
+ this._addObject(e, t);
861
861
  }), this.norm.clear());
862
862
  }
863
863
  // Adds a doc to the end of the index
864
- add(t) {
865
- const e = this.size();
866
- C(t) ? this._addString(t, e) : this._addObject(t, e);
864
+ add(e) {
865
+ const t = this.size();
866
+ Te(e) ? this._addString(e, t) : this._addObject(e, t);
867
867
  }
868
868
  // Removes the doc at the specified index of the index
869
- removeAt(t) {
870
- this.records.splice(t, 1);
871
- for (let e = t, s = this.size(); e < s; e += 1)
872
- this.records[e].i -= 1;
869
+ removeAt(e) {
870
+ this.records.splice(e, 1);
871
+ for (let t = e, s = this.size(); t < s; t += 1)
872
+ this.records[t].i -= 1;
873
873
  }
874
- getValueForItemAtKeyId(t, e) {
875
- return t[this._keysMap[e]];
874
+ getValueForItemAtKeyId(e, t) {
875
+ return e[this._keysMap[t]];
876
876
  }
877
877
  size() {
878
878
  return this.records.length;
879
879
  }
880
- _addString(t, e) {
881
- if (!b(t) || $t(t))
880
+ _addString(e, t) {
881
+ if (!xe(e) || ds(e))
882
882
  return;
883
883
  let s = {
884
- v: t,
885
- i: e,
886
- n: this.norm.get(t)
884
+ v: e,
885
+ i: t,
886
+ n: this.norm.get(e)
887
887
  };
888
888
  this.records.push(s);
889
889
  }
890
- _addObject(t, e) {
891
- let s = { i: e, $: {} };
892
- this.keys.forEach((n, r) => {
893
- let o = n.getFn ? n.getFn(t) : this.getFn(t, n.path);
894
- if (b(o)) {
895
- if (k(o)) {
896
- let c = [];
897
- const l = [{ nestedArrIndex: -1, value: o }];
898
- for (; l.length; ) {
899
- const { nestedArrIndex: a, value: u } = l.pop();
900
- if (b(u))
901
- if (C(u) && !$t(u)) {
902
- let h = {
903
- v: u,
904
- i: a,
905
- n: this.norm.get(u)
890
+ _addObject(e, t) {
891
+ let s = { i: t, $: {} };
892
+ this.keys.forEach((n, l) => {
893
+ let o = n.getFn ? n.getFn(e) : this.getFn(e, n.path);
894
+ if (xe(o)) {
895
+ if (Re(o)) {
896
+ let h = [];
897
+ const u = [{ nestedArrIndex: -1, value: o }];
898
+ for (; u.length; ) {
899
+ const { nestedArrIndex: d, value: m } = u.pop();
900
+ if (xe(m))
901
+ if (Te(m) && !ds(m)) {
902
+ let v = {
903
+ v: m,
904
+ i: d,
905
+ n: this.norm.get(m)
906
906
  };
907
- c.push(h);
907
+ h.push(v);
908
908
  } else
909
- k(u) && u.forEach((h, d) => {
910
- l.push({
911
- nestedArrIndex: d,
912
- value: h
909
+ Re(m) && m.forEach((v, $) => {
910
+ u.push({
911
+ nestedArrIndex: $,
912
+ value: v
913
913
  });
914
914
  });
915
915
  }
916
- s.$[r] = c;
917
- } else if (C(o) && !$t(o)) {
918
- let c = {
916
+ s.$[l] = h;
917
+ } else if (Te(o) && !ds(o)) {
918
+ let h = {
919
919
  v: o,
920
920
  n: this.norm.get(o)
921
921
  };
922
- s.$[r] = c;
922
+ s.$[l] = h;
923
923
  }
924
924
  }
925
925
  }), this.records.push(s);
@@ -931,221 +931,221 @@ class Tt {
931
931
  };
932
932
  }
933
933
  }
934
- function de(i, t, { getFn: e = f.getFn, fieldNormWeight: s = f.fieldNormWeight } = {}) {
935
- const n = new Tt({ getFn: e, fieldNormWeight: s });
936
- return n.setKeys(i.map(ue)), n.setSources(t), n.create(), n;
934
+ function Ei(i, e, { getFn: t = T.getFn, fieldNormWeight: s = T.fieldNormWeight } = {}) {
935
+ const n = new Es({ getFn: t, fieldNormWeight: s });
936
+ return n.setKeys(i.map(Si)), n.setSources(e), n.create(), n;
937
937
  }
938
- function is(i, { getFn: t = f.getFn, fieldNormWeight: e = f.fieldNormWeight } = {}) {
939
- const { keys: s, records: n } = i, r = new Tt({ getFn: t, fieldNormWeight: e });
940
- return r.setKeys(s), r.setIndexRecords(n), r;
938
+ function yn(i, { getFn: e = T.getFn, fieldNormWeight: t = T.fieldNormWeight } = {}) {
939
+ const { keys: s, records: n } = i, l = new Es({ getFn: e, fieldNormWeight: t });
940
+ return l.setKeys(s), l.setIndexRecords(n), l;
941
941
  }
942
- function it(i, {
943
- errors: t = 0,
944
- currentLocation: e = 0,
942
+ function St(i, {
943
+ errors: e = 0,
944
+ currentLocation: t = 0,
945
945
  expectedLocation: s = 0,
946
- distance: n = f.distance,
947
- ignoreLocation: r = f.ignoreLocation
946
+ distance: n = T.distance,
947
+ ignoreLocation: l = T.ignoreLocation
948
948
  } = {}) {
949
- const o = t / i.length;
950
- if (r)
949
+ const o = e / i.length;
950
+ if (l)
951
951
  return o;
952
- const c = Math.abs(s - e);
953
- return n ? o + c / n : c ? 1 : o;
954
- }
955
- function ns(i = [], t = f.minMatchCharLength) {
956
- let e = [], s = -1, n = -1, r = 0;
957
- for (let o = i.length; r < o; r += 1) {
958
- let c = i[r];
959
- c && s === -1 ? s = r : !c && s !== -1 && (n = r - 1, n - s + 1 >= t && e.push([s, n]), s = -1);
960
- }
961
- return i[r - 1] && r - s >= t && e.push([s, r - 1]), e;
962
- }
963
- const P = 32;
964
- function rs(i, t, e, {
965
- location: s = f.location,
966
- distance: n = f.distance,
967
- threshold: r = f.threshold,
968
- findAllMatches: o = f.findAllMatches,
969
- minMatchCharLength: c = f.minMatchCharLength,
970
- includeMatches: l = f.includeMatches,
971
- ignoreLocation: a = f.ignoreLocation
952
+ const h = Math.abs(s - t);
953
+ return n ? o + h / n : h ? 1 : o;
954
+ }
955
+ function bn(i = [], e = T.minMatchCharLength) {
956
+ let t = [], s = -1, n = -1, l = 0;
957
+ for (let o = i.length; l < o; l += 1) {
958
+ let h = i[l];
959
+ h && s === -1 ? s = l : !h && s !== -1 && (n = l - 1, n - s + 1 >= e && t.push([s, n]), s = -1);
960
+ }
961
+ return i[l - 1] && l - s >= e && t.push([s, l - 1]), t;
962
+ }
963
+ const Be = 32;
964
+ function $n(i, e, t, {
965
+ location: s = T.location,
966
+ distance: n = T.distance,
967
+ threshold: l = T.threshold,
968
+ findAllMatches: o = T.findAllMatches,
969
+ minMatchCharLength: h = T.minMatchCharLength,
970
+ includeMatches: u = T.includeMatches,
971
+ ignoreLocation: d = T.ignoreLocation
972
972
  } = {}) {
973
- if (t.length > P)
974
- throw new Error(Ke(P));
975
- const u = t.length, h = i.length, d = Math.max(0, Math.min(s, h));
976
- let p = r, g = d;
977
- const v = c > 1 || l, M = v ? Array(h) : [];
978
- let A;
979
- for (; (A = i.indexOf(t, g)) > -1; ) {
980
- let $ = it(t, {
981
- currentLocation: A,
982
- expectedLocation: d,
973
+ if (e.length > Be)
974
+ throw new Error(ln(Be));
975
+ const m = e.length, v = i.length, $ = Math.max(0, Math.min(s, v));
976
+ let M = l, j = $;
977
+ const J = h > 1 || u, ge = J ? Array(v) : [];
978
+ let le;
979
+ for (; (le = i.indexOf(e, j)) > -1; ) {
980
+ let X = St(e, {
981
+ currentLocation: le,
982
+ expectedLocation: $,
983
983
  distance: n,
984
- ignoreLocation: a
984
+ ignoreLocation: d
985
985
  });
986
- if (p = Math.min($, p), g = A + u, v) {
987
- let E = 0;
988
- for (; E < u; )
989
- M[A + E] = 1, E += 1;
990
- }
991
- }
992
- g = -1;
993
- let R = [], I = 1, D = u + h;
994
- const G = 1 << u - 1;
995
- for (let $ = 0; $ < u; $ += 1) {
996
- let E = 0, S = D;
997
- for (; E < S; )
998
- it(t, {
999
- errors: $,
1000
- currentLocation: d + S,
1001
- expectedLocation: d,
986
+ if (M = Math.min(X, M), j = le + m, J) {
987
+ let ie = 0;
988
+ for (; ie < m; )
989
+ ge[le + ie] = 1, ie += 1;
990
+ }
991
+ }
992
+ j = -1;
993
+ let ve = [], pe = 1, Me = m + v;
994
+ const me = 1 << m - 1;
995
+ for (let X = 0; X < m; X += 1) {
996
+ let ie = 0, z = Me;
997
+ for (; ie < z; )
998
+ St(e, {
999
+ errors: X,
1000
+ currentLocation: $ + z,
1001
+ expectedLocation: $,
1002
1002
  distance: n,
1003
- ignoreLocation: a
1004
- }) <= p ? E = S : D = S, S = Math.floor((D - E) / 2 + E);
1005
- D = S;
1006
- let Lt = Math.max(1, d - S + 1), ut = o ? h : Math.min(d + S, h) + u, z = Array(ut + 2);
1007
- z[ut + 1] = (1 << $) - 1;
1008
- for (let w = ut; w >= Lt; w -= 1) {
1009
- let st = w - 1, Nt = e[i.charAt(st)];
1010
- if (v && (M[st] = +!!Nt), z[w] = (z[w + 1] << 1 | 1) & Nt, $ && (z[w] |= (R[w + 1] | R[w]) << 1 | 1 | R[w + 1]), z[w] & G && (I = it(t, {
1011
- errors: $,
1012
- currentLocation: st,
1013
- expectedLocation: d,
1003
+ ignoreLocation: d
1004
+ }) <= M ? ie = z : Me = z, z = Math.floor((Me - ie) / 2 + ie);
1005
+ Me = z;
1006
+ let B = Math.max(1, $ - z + 1), Ce = o ? v : Math.min($ + z, v) + m, Se = Array(Ce + 2);
1007
+ Se[Ce + 1] = (1 << X) - 1;
1008
+ for (let y = Ce; y >= B; y -= 1) {
1009
+ let b = y - 1, k = t[i.charAt(b)];
1010
+ if (J && (ge[b] = +!!k), Se[y] = (Se[y + 1] << 1 | 1) & k, X && (Se[y] |= (ve[y + 1] | ve[y]) << 1 | 1 | ve[y + 1]), Se[y] & me && (pe = St(e, {
1011
+ errors: X,
1012
+ currentLocation: b,
1013
+ expectedLocation: $,
1014
1014
  distance: n,
1015
- ignoreLocation: a
1016
- }), I <= p)) {
1017
- if (p = I, g = st, g <= d)
1015
+ ignoreLocation: d
1016
+ }), pe <= M)) {
1017
+ if (M = pe, j = b, j <= $)
1018
1018
  break;
1019
- Lt = Math.max(1, 2 * d - g);
1019
+ B = Math.max(1, 2 * $ - j);
1020
1020
  }
1021
1021
  }
1022
- if (it(t, {
1023
- errors: $ + 1,
1024
- currentLocation: d,
1025
- expectedLocation: d,
1022
+ if (St(e, {
1023
+ errors: X + 1,
1024
+ currentLocation: $,
1025
+ expectedLocation: $,
1026
1026
  distance: n,
1027
- ignoreLocation: a
1028
- }) > p)
1027
+ ignoreLocation: d
1028
+ }) > M)
1029
1029
  break;
1030
- R = z;
1030
+ ve = Se;
1031
1031
  }
1032
- const y = {
1033
- isMatch: g >= 0,
1032
+ const F = {
1033
+ isMatch: j >= 0,
1034
1034
  // Count exact matches (those with a score of 0) to be "almost" exact
1035
- score: Math.max(1e-3, I)
1035
+ score: Math.max(1e-3, pe)
1036
1036
  };
1037
- if (v) {
1038
- const $ = ns(M, c);
1039
- $.length ? l && (y.indices = $) : y.isMatch = !1;
1037
+ if (J) {
1038
+ const X = bn(ge, h);
1039
+ X.length ? u && (F.indices = X) : F.isMatch = !1;
1040
1040
  }
1041
- return y;
1041
+ return F;
1042
1042
  }
1043
- function os(i) {
1044
- let t = {};
1045
- for (let e = 0, s = i.length; e < s; e += 1) {
1046
- const n = i.charAt(e);
1047
- t[n] = (t[n] || 0) | 1 << s - e - 1;
1043
+ function _n(i) {
1044
+ let e = {};
1045
+ for (let t = 0, s = i.length; t < s; t += 1) {
1046
+ const n = i.charAt(t);
1047
+ e[n] = (e[n] || 0) | 1 << s - t - 1;
1048
1048
  }
1049
- return t;
1049
+ return e;
1050
1050
  }
1051
- class fe {
1052
- constructor(t, {
1053
- location: e = f.location,
1054
- threshold: s = f.threshold,
1055
- distance: n = f.distance,
1056
- includeMatches: r = f.includeMatches,
1057
- findAllMatches: o = f.findAllMatches,
1058
- minMatchCharLength: c = f.minMatchCharLength,
1059
- isCaseSensitive: l = f.isCaseSensitive,
1060
- ignoreLocation: a = f.ignoreLocation
1051
+ class ki {
1052
+ constructor(e, {
1053
+ location: t = T.location,
1054
+ threshold: s = T.threshold,
1055
+ distance: n = T.distance,
1056
+ includeMatches: l = T.includeMatches,
1057
+ findAllMatches: o = T.findAllMatches,
1058
+ minMatchCharLength: h = T.minMatchCharLength,
1059
+ isCaseSensitive: u = T.isCaseSensitive,
1060
+ ignoreLocation: d = T.ignoreLocation
1061
1061
  } = {}) {
1062
1062
  if (this.options = {
1063
- location: e,
1063
+ location: t,
1064
1064
  threshold: s,
1065
1065
  distance: n,
1066
- includeMatches: r,
1066
+ includeMatches: l,
1067
1067
  findAllMatches: o,
1068
- minMatchCharLength: c,
1069
- isCaseSensitive: l,
1070
- ignoreLocation: a
1071
- }, this.pattern = l ? t : t.toLowerCase(), this.chunks = [], !this.pattern.length)
1068
+ minMatchCharLength: h,
1069
+ isCaseSensitive: u,
1070
+ ignoreLocation: d
1071
+ }, this.pattern = u ? e : e.toLowerCase(), this.chunks = [], !this.pattern.length)
1072
1072
  return;
1073
- const u = (d, p) => {
1073
+ const m = ($, M) => {
1074
1074
  this.chunks.push({
1075
- pattern: d,
1076
- alphabet: os(d),
1077
- startIndex: p
1075
+ pattern: $,
1076
+ alphabet: _n($),
1077
+ startIndex: M
1078
1078
  });
1079
- }, h = this.pattern.length;
1080
- if (h > P) {
1081
- let d = 0;
1082
- const p = h % P, g = h - p;
1083
- for (; d < g; )
1084
- u(this.pattern.substr(d, P), d), d += P;
1085
- if (p) {
1086
- const v = h - P;
1087
- u(this.pattern.substr(v), v);
1079
+ }, v = this.pattern.length;
1080
+ if (v > Be) {
1081
+ let $ = 0;
1082
+ const M = v % Be, j = v - M;
1083
+ for (; $ < j; )
1084
+ m(this.pattern.substr($, Be), $), $ += Be;
1085
+ if (M) {
1086
+ const J = v - Be;
1087
+ m(this.pattern.substr(J), J);
1088
1088
  }
1089
1089
  } else
1090
- u(this.pattern, 0);
1090
+ m(this.pattern, 0);
1091
1091
  }
1092
- searchIn(t) {
1093
- const { isCaseSensitive: e, includeMatches: s } = this.options;
1094
- if (e || (t = t.toLowerCase()), this.pattern === t) {
1095
- let g = {
1092
+ searchIn(e) {
1093
+ const { isCaseSensitive: t, includeMatches: s } = this.options;
1094
+ if (t || (e = e.toLowerCase()), this.pattern === e) {
1095
+ let j = {
1096
1096
  isMatch: !0,
1097
1097
  score: 0
1098
1098
  };
1099
- return s && (g.indices = [[0, t.length - 1]]), g;
1099
+ return s && (j.indices = [[0, e.length - 1]]), j;
1100
1100
  }
1101
1101
  const {
1102
1102
  location: n,
1103
- distance: r,
1103
+ distance: l,
1104
1104
  threshold: o,
1105
- findAllMatches: c,
1106
- minMatchCharLength: l,
1107
- ignoreLocation: a
1105
+ findAllMatches: h,
1106
+ minMatchCharLength: u,
1107
+ ignoreLocation: d
1108
1108
  } = this.options;
1109
- let u = [], h = 0, d = !1;
1110
- this.chunks.forEach(({ pattern: g, alphabet: v, startIndex: M }) => {
1111
- const { isMatch: A, score: R, indices: I } = rs(t, g, v, {
1112
- location: n + M,
1113
- distance: r,
1109
+ let m = [], v = 0, $ = !1;
1110
+ this.chunks.forEach(({ pattern: j, alphabet: J, startIndex: ge }) => {
1111
+ const { isMatch: le, score: ve, indices: pe } = $n(e, j, J, {
1112
+ location: n + ge,
1113
+ distance: l,
1114
1114
  threshold: o,
1115
- findAllMatches: c,
1116
- minMatchCharLength: l,
1115
+ findAllMatches: h,
1116
+ minMatchCharLength: u,
1117
1117
  includeMatches: s,
1118
- ignoreLocation: a
1118
+ ignoreLocation: d
1119
1119
  });
1120
- A && (d = !0), h += R, A && I && (u = [...u, ...I]);
1120
+ le && ($ = !0), v += ve, le && pe && (m = [...m, ...pe]);
1121
1121
  });
1122
- let p = {
1123
- isMatch: d,
1124
- score: d ? h / this.chunks.length : 1
1122
+ let M = {
1123
+ isMatch: $,
1124
+ score: $ ? v / this.chunks.length : 1
1125
1125
  };
1126
- return d && s && (p.indices = u), p;
1126
+ return $ && s && (M.indices = m), M;
1127
1127
  }
1128
1128
  }
1129
- class L {
1130
- constructor(t) {
1131
- this.pattern = t;
1129
+ class je {
1130
+ constructor(e) {
1131
+ this.pattern = e;
1132
1132
  }
1133
- static isMultiMatch(t) {
1134
- return Qt(t, this.multiRegex);
1133
+ static isMultiMatch(e) {
1134
+ return di(e, this.multiRegex);
1135
1135
  }
1136
- static isSingleMatch(t) {
1137
- return Qt(t, this.singleRegex);
1136
+ static isSingleMatch(e) {
1137
+ return di(e, this.singleRegex);
1138
1138
  }
1139
1139
  search() {
1140
1140
  }
1141
1141
  }
1142
- function Qt(i, t) {
1143
- const e = i.match(t);
1144
- return e ? e[1] : null;
1142
+ function di(i, e) {
1143
+ const t = i.match(e);
1144
+ return t ? t[1] : null;
1145
1145
  }
1146
- class ls extends L {
1147
- constructor(t) {
1148
- super(t);
1146
+ class xn extends je {
1147
+ constructor(e) {
1148
+ super(e);
1149
1149
  }
1150
1150
  static get type() {
1151
1151
  return "exact";
@@ -1156,18 +1156,18 @@ class ls extends L {
1156
1156
  static get singleRegex() {
1157
1157
  return /^=(.*)$/;
1158
1158
  }
1159
- search(t) {
1160
- const e = t === this.pattern;
1159
+ search(e) {
1160
+ const t = e === this.pattern;
1161
1161
  return {
1162
- isMatch: e,
1163
- score: e ? 0 : 1,
1162
+ isMatch: t,
1163
+ score: t ? 0 : 1,
1164
1164
  indices: [0, this.pattern.length - 1]
1165
1165
  };
1166
1166
  }
1167
1167
  }
1168
- class cs extends L {
1169
- constructor(t) {
1170
- super(t);
1168
+ class wn extends je {
1169
+ constructor(e) {
1170
+ super(e);
1171
1171
  }
1172
1172
  static get type() {
1173
1173
  return "inverse-exact";
@@ -1178,18 +1178,18 @@ class cs extends L {
1178
1178
  static get singleRegex() {
1179
1179
  return /^!(.*)$/;
1180
1180
  }
1181
- search(t) {
1182
- const s = t.indexOf(this.pattern) === -1;
1181
+ search(e) {
1182
+ const s = e.indexOf(this.pattern) === -1;
1183
1183
  return {
1184
1184
  isMatch: s,
1185
1185
  score: s ? 0 : 1,
1186
- indices: [0, t.length - 1]
1186
+ indices: [0, e.length - 1]
1187
1187
  };
1188
1188
  }
1189
1189
  }
1190
- class as extends L {
1191
- constructor(t) {
1192
- super(t);
1190
+ class An extends je {
1191
+ constructor(e) {
1192
+ super(e);
1193
1193
  }
1194
1194
  static get type() {
1195
1195
  return "prefix-exact";
@@ -1200,18 +1200,18 @@ class as extends L {
1200
1200
  static get singleRegex() {
1201
1201
  return /^\^(.*)$/;
1202
1202
  }
1203
- search(t) {
1204
- const e = t.startsWith(this.pattern);
1203
+ search(e) {
1204
+ const t = e.startsWith(this.pattern);
1205
1205
  return {
1206
- isMatch: e,
1207
- score: e ? 0 : 1,
1206
+ isMatch: t,
1207
+ score: t ? 0 : 1,
1208
1208
  indices: [0, this.pattern.length - 1]
1209
1209
  };
1210
1210
  }
1211
1211
  }
1212
- class hs extends L {
1213
- constructor(t) {
1214
- super(t);
1212
+ class Mn extends je {
1213
+ constructor(e) {
1214
+ super(e);
1215
1215
  }
1216
1216
  static get type() {
1217
1217
  return "inverse-prefix-exact";
@@ -1222,18 +1222,18 @@ class hs extends L {
1222
1222
  static get singleRegex() {
1223
1223
  return /^!\^(.*)$/;
1224
1224
  }
1225
- search(t) {
1226
- const e = !t.startsWith(this.pattern);
1225
+ search(e) {
1226
+ const t = !e.startsWith(this.pattern);
1227
1227
  return {
1228
- isMatch: e,
1229
- score: e ? 0 : 1,
1230
- indices: [0, t.length - 1]
1228
+ isMatch: t,
1229
+ score: t ? 0 : 1,
1230
+ indices: [0, e.length - 1]
1231
1231
  };
1232
1232
  }
1233
1233
  }
1234
- class us extends L {
1235
- constructor(t) {
1236
- super(t);
1234
+ class Sn extends je {
1235
+ constructor(e) {
1236
+ super(e);
1237
1237
  }
1238
1238
  static get type() {
1239
1239
  return "suffix-exact";
@@ -1244,18 +1244,18 @@ class us extends L {
1244
1244
  static get singleRegex() {
1245
1245
  return /^(.*)\$$/;
1246
1246
  }
1247
- search(t) {
1248
- const e = t.endsWith(this.pattern);
1247
+ search(e) {
1248
+ const t = e.endsWith(this.pattern);
1249
1249
  return {
1250
- isMatch: e,
1251
- score: e ? 0 : 1,
1252
- indices: [t.length - this.pattern.length, t.length - 1]
1250
+ isMatch: t,
1251
+ score: t ? 0 : 1,
1252
+ indices: [e.length - this.pattern.length, e.length - 1]
1253
1253
  };
1254
1254
  }
1255
1255
  }
1256
- class ds extends L {
1257
- constructor(t) {
1258
- super(t);
1256
+ class En extends je {
1257
+ constructor(e) {
1258
+ super(e);
1259
1259
  }
1260
1260
  static get type() {
1261
1261
  return "inverse-suffix-exact";
@@ -1266,35 +1266,35 @@ class ds extends L {
1266
1266
  static get singleRegex() {
1267
1267
  return /^!(.*)\$$/;
1268
1268
  }
1269
- search(t) {
1270
- const e = !t.endsWith(this.pattern);
1269
+ search(e) {
1270
+ const t = !e.endsWith(this.pattern);
1271
1271
  return {
1272
- isMatch: e,
1273
- score: e ? 0 : 1,
1274
- indices: [0, t.length - 1]
1272
+ isMatch: t,
1273
+ score: t ? 0 : 1,
1274
+ indices: [0, e.length - 1]
1275
1275
  };
1276
1276
  }
1277
1277
  }
1278
- class pe extends L {
1279
- constructor(t, {
1280
- location: e = f.location,
1281
- threshold: s = f.threshold,
1282
- distance: n = f.distance,
1283
- includeMatches: r = f.includeMatches,
1284
- findAllMatches: o = f.findAllMatches,
1285
- minMatchCharLength: c = f.minMatchCharLength,
1286
- isCaseSensitive: l = f.isCaseSensitive,
1287
- ignoreLocation: a = f.ignoreLocation
1278
+ class Li extends je {
1279
+ constructor(e, {
1280
+ location: t = T.location,
1281
+ threshold: s = T.threshold,
1282
+ distance: n = T.distance,
1283
+ includeMatches: l = T.includeMatches,
1284
+ findAllMatches: o = T.findAllMatches,
1285
+ minMatchCharLength: h = T.minMatchCharLength,
1286
+ isCaseSensitive: u = T.isCaseSensitive,
1287
+ ignoreLocation: d = T.ignoreLocation
1288
1288
  } = {}) {
1289
- super(t), this._bitapSearch = new fe(t, {
1290
- location: e,
1289
+ super(e), this._bitapSearch = new ki(e, {
1290
+ location: t,
1291
1291
  threshold: s,
1292
1292
  distance: n,
1293
- includeMatches: r,
1293
+ includeMatches: l,
1294
1294
  findAllMatches: o,
1295
- minMatchCharLength: c,
1296
- isCaseSensitive: l,
1297
- ignoreLocation: a
1295
+ minMatchCharLength: h,
1296
+ isCaseSensitive: u,
1297
+ ignoreLocation: d
1298
1298
  });
1299
1299
  }
1300
1300
  static get type() {
@@ -1306,13 +1306,13 @@ class pe extends L {
1306
1306
  static get singleRegex() {
1307
1307
  return /^(.*)$/;
1308
1308
  }
1309
- search(t) {
1310
- return this._bitapSearch.searchIn(t);
1309
+ search(e) {
1310
+ return this._bitapSearch.searchIn(e);
1311
1311
  }
1312
1312
  }
1313
- class ge extends L {
1314
- constructor(t) {
1315
- super(t);
1313
+ class Ci extends je {
1314
+ constructor(e) {
1315
+ super(e);
1316
1316
  }
1317
1317
  static get type() {
1318
1318
  return "include";
@@ -1323,11 +1323,11 @@ class ge extends L {
1323
1323
  static get singleRegex() {
1324
1324
  return /^'(.*)$/;
1325
1325
  }
1326
- search(t) {
1327
- let e = 0, s;
1328
- const n = [], r = this.pattern.length;
1329
- for (; (s = t.indexOf(this.pattern, e)) > -1; )
1330
- e = s + r, n.push([s, e - 1]);
1326
+ search(e) {
1327
+ let t = 0, s;
1328
+ const n = [], l = this.pattern.length;
1329
+ for (; (s = e.indexOf(this.pattern, t)) > -1; )
1330
+ t = s + l, n.push([s, t - 1]);
1331
1331
  const o = !!n.length;
1332
1332
  return {
1333
1333
  isMatch: o,
@@ -1336,33 +1336,33 @@ class ge extends L {
1336
1336
  };
1337
1337
  }
1338
1338
  }
1339
- const St = [
1340
- ls,
1341
- ge,
1342
- as,
1343
- hs,
1344
- ds,
1345
- us,
1346
- cs,
1347
- pe
1348
- ], Zt = St.length, fs = / +(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)/, ps = "|";
1349
- function gs(i, t = {}) {
1350
- return i.split(ps).map((e) => {
1351
- let s = e.trim().split(fs).filter((r) => r && !!r.trim()), n = [];
1352
- for (let r = 0, o = s.length; r < o; r += 1) {
1353
- const c = s[r];
1354
- let l = !1, a = -1;
1355
- for (; !l && ++a < Zt; ) {
1356
- const u = St[a];
1357
- let h = u.isMultiMatch(c);
1358
- h && (n.push(new u(h, t)), l = !0);
1339
+ const bs = [
1340
+ xn,
1341
+ Ci,
1342
+ An,
1343
+ Mn,
1344
+ En,
1345
+ Sn,
1346
+ wn,
1347
+ Li
1348
+ ], pi = bs.length, kn = / +(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)/, Ln = "|";
1349
+ function Cn(i, e = {}) {
1350
+ return i.split(Ln).map((t) => {
1351
+ let s = t.trim().split(kn).filter((l) => l && !!l.trim()), n = [];
1352
+ for (let l = 0, o = s.length; l < o; l += 1) {
1353
+ const h = s[l];
1354
+ let u = !1, d = -1;
1355
+ for (; !u && ++d < pi; ) {
1356
+ const m = bs[d];
1357
+ let v = m.isMultiMatch(h);
1358
+ v && (n.push(new m(v, e)), u = !0);
1359
1359
  }
1360
- if (!l)
1361
- for (a = -1; ++a < Zt; ) {
1362
- const u = St[a];
1363
- let h = u.isSingleMatch(c);
1364
- if (h) {
1365
- n.push(new u(h, t));
1360
+ if (!u)
1361
+ for (d = -1; ++d < pi; ) {
1362
+ const m = bs[d];
1363
+ let v = m.isSingleMatch(h);
1364
+ if (v) {
1365
+ n.push(new m(v, e));
1366
1366
  break;
1367
1367
  }
1368
1368
  }
@@ -1370,63 +1370,63 @@ function gs(i, t = {}) {
1370
1370
  return n;
1371
1371
  });
1372
1372
  }
1373
- const ms = /* @__PURE__ */ new Set([pe.type, ge.type]);
1374
- class _s {
1375
- constructor(t, {
1376
- isCaseSensitive: e = f.isCaseSensitive,
1377
- includeMatches: s = f.includeMatches,
1378
- minMatchCharLength: n = f.minMatchCharLength,
1379
- ignoreLocation: r = f.ignoreLocation,
1380
- findAllMatches: o = f.findAllMatches,
1381
- location: c = f.location,
1382
- threshold: l = f.threshold,
1383
- distance: a = f.distance
1373
+ const On = /* @__PURE__ */ new Set([Li.type, Ci.type]);
1374
+ class Dn {
1375
+ constructor(e, {
1376
+ isCaseSensitive: t = T.isCaseSensitive,
1377
+ includeMatches: s = T.includeMatches,
1378
+ minMatchCharLength: n = T.minMatchCharLength,
1379
+ ignoreLocation: l = T.ignoreLocation,
1380
+ findAllMatches: o = T.findAllMatches,
1381
+ location: h = T.location,
1382
+ threshold: u = T.threshold,
1383
+ distance: d = T.distance
1384
1384
  } = {}) {
1385
1385
  this.query = null, this.options = {
1386
- isCaseSensitive: e,
1386
+ isCaseSensitive: t,
1387
1387
  includeMatches: s,
1388
1388
  minMatchCharLength: n,
1389
1389
  findAllMatches: o,
1390
- ignoreLocation: r,
1391
- location: c,
1392
- threshold: l,
1393
- distance: a
1394
- }, this.pattern = e ? t : t.toLowerCase(), this.query = gs(this.pattern, this.options);
1395
- }
1396
- static condition(t, e) {
1397
- return e.useExtendedSearch;
1398
- }
1399
- searchIn(t) {
1400
- const e = this.query;
1401
- if (!e)
1390
+ ignoreLocation: l,
1391
+ location: h,
1392
+ threshold: u,
1393
+ distance: d
1394
+ }, this.pattern = t ? e : e.toLowerCase(), this.query = Cn(this.pattern, this.options);
1395
+ }
1396
+ static condition(e, t) {
1397
+ return t.useExtendedSearch;
1398
+ }
1399
+ searchIn(e) {
1400
+ const t = this.query;
1401
+ if (!t)
1402
1402
  return {
1403
1403
  isMatch: !1,
1404
1404
  score: 1
1405
1405
  };
1406
1406
  const { includeMatches: s, isCaseSensitive: n } = this.options;
1407
- t = n ? t : t.toLowerCase();
1408
- let r = 0, o = [], c = 0;
1409
- for (let l = 0, a = e.length; l < a; l += 1) {
1410
- const u = e[l];
1411
- o.length = 0, r = 0;
1412
- for (let h = 0, d = u.length; h < d; h += 1) {
1413
- const p = u[h], { isMatch: g, indices: v, score: M } = p.search(t);
1414
- if (g) {
1415
- if (r += 1, c += M, s) {
1416
- const A = p.constructor.type;
1417
- ms.has(A) ? o = [...o, ...v] : o.push(v);
1407
+ e = n ? e : e.toLowerCase();
1408
+ let l = 0, o = [], h = 0;
1409
+ for (let u = 0, d = t.length; u < d; u += 1) {
1410
+ const m = t[u];
1411
+ o.length = 0, l = 0;
1412
+ for (let v = 0, $ = m.length; v < $; v += 1) {
1413
+ const M = m[v], { isMatch: j, indices: J, score: ge } = M.search(e);
1414
+ if (j) {
1415
+ if (l += 1, h += ge, s) {
1416
+ const le = M.constructor.type;
1417
+ On.has(le) ? o = [...o, ...J] : o.push(J);
1418
1418
  }
1419
1419
  } else {
1420
- c = 0, r = 0, o.length = 0;
1420
+ h = 0, l = 0, o.length = 0;
1421
1421
  break;
1422
1422
  }
1423
1423
  }
1424
- if (r) {
1425
- let h = {
1424
+ if (l) {
1425
+ let v = {
1426
1426
  isMatch: !0,
1427
- score: c / r
1427
+ score: h / l
1428
1428
  };
1429
- return s && (h.indices = o), h;
1429
+ return s && (v.indices = o), v;
1430
1430
  }
1431
1431
  }
1432
1432
  return {
@@ -1435,354 +1435,1455 @@ class _s {
1435
1435
  };
1436
1436
  }
1437
1437
  }
1438
- const wt = [];
1439
- function ys(...i) {
1440
- wt.push(...i);
1438
+ const $s = [];
1439
+ function Tn(...i) {
1440
+ $s.push(...i);
1441
1441
  }
1442
- function Mt(i, t) {
1443
- for (let e = 0, s = wt.length; e < s; e += 1) {
1444
- let n = wt[e];
1445
- if (n.condition(i, t))
1446
- return new n(i, t);
1442
+ function _s(i, e) {
1443
+ for (let t = 0, s = $s.length; t < s; t += 1) {
1444
+ let n = $s[t];
1445
+ if (n.condition(i, e))
1446
+ return new n(i, e);
1447
1447
  }
1448
- return new fe(i, t);
1448
+ return new ki(i, e);
1449
1449
  }
1450
- const ct = {
1450
+ const Ot = {
1451
1451
  AND: "$and",
1452
1452
  OR: "$or"
1453
- }, Ct = {
1453
+ }, xs = {
1454
1454
  PATH: "$path",
1455
1455
  PATTERN: "$val"
1456
- }, Rt = (i) => !!(i[ct.AND] || i[ct.OR]), $s = (i) => !!i[Ct.PATH], vs = (i) => !k(i) && ae(i) && !Rt(i), qt = (i) => ({
1457
- [ct.AND]: Object.keys(i).map((t) => ({
1458
- [t]: i[t]
1456
+ }, ws = (i) => !!(i[Ot.AND] || i[Ot.OR]), Rn = (i) => !!i[xs.PATH], Pn = (i) => !Re(i) && Ai(i) && !ws(i), fi = (i) => ({
1457
+ [Ot.AND]: Object.keys(i).map((e) => ({
1458
+ [e]: i[e]
1459
1459
  }))
1460
1460
  });
1461
- function me(i, t, { auto: e = !0 } = {}) {
1461
+ function Oi(i, e, { auto: t = !0 } = {}) {
1462
1462
  const s = (n) => {
1463
- let r = Object.keys(n);
1464
- const o = $s(n);
1465
- if (!o && r.length > 1 && !Rt(n))
1466
- return s(qt(n));
1467
- if (vs(n)) {
1468
- const l = o ? n[Ct.PATH] : r[0], a = o ? n[Ct.PATTERN] : n[l];
1469
- if (!C(a))
1470
- throw new Error(Ve(l));
1471
- const u = {
1472
- keyId: xt(l),
1473
- pattern: a
1463
+ let l = Object.keys(n);
1464
+ const o = Rn(n);
1465
+ if (!o && l.length > 1 && !ws(n))
1466
+ return s(fi(n));
1467
+ if (Pn(n)) {
1468
+ const u = o ? n[xs.PATH] : l[0], d = o ? n[xs.PATTERN] : n[u];
1469
+ if (!Te(d))
1470
+ throw new Error(on(u));
1471
+ const m = {
1472
+ keyId: ys(u),
1473
+ pattern: d
1474
1474
  };
1475
- return e && (u.searcher = Mt(a, t)), u;
1475
+ return t && (m.searcher = _s(d, e)), m;
1476
1476
  }
1477
- let c = {
1477
+ let h = {
1478
1478
  children: [],
1479
- operator: r[0]
1479
+ operator: l[0]
1480
1480
  };
1481
- return r.forEach((l) => {
1482
- const a = n[l];
1483
- k(a) && a.forEach((u) => {
1484
- c.children.push(s(u));
1481
+ return l.forEach((u) => {
1482
+ const d = n[u];
1483
+ Re(d) && d.forEach((m) => {
1484
+ h.children.push(s(m));
1485
1485
  });
1486
- }), c;
1486
+ }), h;
1487
1487
  };
1488
- return Rt(i) || (i = qt(i)), s(i);
1488
+ return ws(i) || (i = fi(i)), s(i);
1489
1489
  }
1490
- function As(i, { ignoreFieldNorm: t = f.ignoreFieldNorm }) {
1491
- i.forEach((e) => {
1490
+ function In(i, { ignoreFieldNorm: e = T.ignoreFieldNorm }) {
1491
+ i.forEach((t) => {
1492
1492
  let s = 1;
1493
- e.matches.forEach(({ key: n, norm: r, score: o }) => {
1494
- const c = n ? n.weight : null;
1493
+ t.matches.forEach(({ key: n, norm: l, score: o }) => {
1494
+ const h = n ? n.weight : null;
1495
1495
  s *= Math.pow(
1496
- o === 0 && c ? Number.EPSILON : o,
1497
- (c || 1) * (t ? 1 : r)
1496
+ o === 0 && h ? Number.EPSILON : o,
1497
+ (h || 1) * (e ? 1 : l)
1498
1498
  );
1499
- }), e.score = s;
1499
+ }), t.score = s;
1500
1500
  });
1501
1501
  }
1502
- function Es(i, t) {
1503
- const e = i.matches;
1504
- t.matches = [], b(e) && e.forEach((s) => {
1505
- if (!b(s.indices) || !s.indices.length)
1502
+ function Nn(i, e) {
1503
+ const t = i.matches;
1504
+ e.matches = [], xe(t) && t.forEach((s) => {
1505
+ if (!xe(s.indices) || !s.indices.length)
1506
1506
  return;
1507
- const { indices: n, value: r } = s;
1507
+ const { indices: n, value: l } = s;
1508
1508
  let o = {
1509
1509
  indices: n,
1510
- value: r
1510
+ value: l
1511
1511
  };
1512
- s.key && (o.key = s.key.src), s.idx > -1 && (o.refIndex = s.idx), t.matches.push(o);
1512
+ s.key && (o.key = s.key.src), s.idx > -1 && (o.refIndex = s.idx), e.matches.push(o);
1513
1513
  });
1514
1514
  }
1515
- function bs(i, t) {
1516
- t.score = i.score;
1515
+ function jn(i, e) {
1516
+ e.score = i.score;
1517
1517
  }
1518
- function xs(i, t, {
1519
- includeMatches: e = f.includeMatches,
1520
- includeScore: s = f.includeScore
1518
+ function Hn(i, e, {
1519
+ includeMatches: t = T.includeMatches,
1520
+ includeScore: s = T.includeScore
1521
1521
  } = {}) {
1522
1522
  const n = [];
1523
- return e && n.push(Es), s && n.push(bs), i.map((r) => {
1524
- const { idx: o } = r, c = {
1525
- item: t[o],
1523
+ return t && n.push(Nn), s && n.push(jn), i.map((l) => {
1524
+ const { idx: o } = l, h = {
1525
+ item: e[o],
1526
1526
  refIndex: o
1527
1527
  };
1528
- return n.length && n.forEach((l) => {
1529
- l(r, c);
1530
- }), c;
1528
+ return n.length && n.forEach((u) => {
1529
+ u(l, h);
1530
+ }), h;
1531
1531
  });
1532
1532
  }
1533
- class K {
1534
- constructor(t, e = {}, s) {
1535
- this.options = { ...f, ...e }, this.options.useExtendedSearch, this._keyStore = new Je(this.options.keys), this.setCollection(t, s);
1533
+ class tt {
1534
+ constructor(e, t = {}, s) {
1535
+ this.options = { ...T, ...t }, this.options.useExtendedSearch, this._keyStore = new hn(this.options.keys), this.setCollection(e, s);
1536
1536
  }
1537
- setCollection(t, e) {
1538
- if (this._docs = t, e && !(e instanceof Tt))
1539
- throw new Error(We);
1540
- this._myIndex = e || de(this.options.keys, this._docs, {
1537
+ setCollection(e, t) {
1538
+ if (this._docs = e, t && !(t instanceof Es))
1539
+ throw new Error(nn);
1540
+ this._myIndex = t || Ei(this.options.keys, this._docs, {
1541
1541
  getFn: this.options.getFn,
1542
1542
  fieldNormWeight: this.options.fieldNormWeight
1543
1543
  });
1544
1544
  }
1545
- add(t) {
1546
- b(t) && (this._docs.push(t), this._myIndex.add(t));
1545
+ add(e) {
1546
+ xe(e) && (this._docs.push(e), this._myIndex.add(e));
1547
1547
  }
1548
- remove(t = () => !1) {
1549
- const e = [];
1548
+ remove(e = () => !1) {
1549
+ const t = [];
1550
1550
  for (let s = 0, n = this._docs.length; s < n; s += 1) {
1551
- const r = this._docs[s];
1552
- t(r, s) && (this.removeAt(s), s -= 1, n -= 1, e.push(r));
1551
+ const l = this._docs[s];
1552
+ e(l, s) && (this.removeAt(s), s -= 1, n -= 1, t.push(l));
1553
1553
  }
1554
- return e;
1554
+ return t;
1555
1555
  }
1556
- removeAt(t) {
1557
- this._docs.splice(t, 1), this._myIndex.removeAt(t);
1556
+ removeAt(e) {
1557
+ this._docs.splice(e, 1), this._myIndex.removeAt(e);
1558
1558
  }
1559
1559
  getIndex() {
1560
1560
  return this._myIndex;
1561
1561
  }
1562
- search(t, { limit: e = -1 } = {}) {
1562
+ search(e, { limit: t = -1 } = {}) {
1563
1563
  const {
1564
1564
  includeMatches: s,
1565
1565
  includeScore: n,
1566
- shouldSort: r,
1566
+ shouldSort: l,
1567
1567
  sortFn: o,
1568
- ignoreFieldNorm: c
1568
+ ignoreFieldNorm: h
1569
1569
  } = this.options;
1570
- let l = C(t) ? C(this._docs[0]) ? this._searchStringList(t) : this._searchObjectList(t) : this._searchLogical(t);
1571
- return As(l, { ignoreFieldNorm: c }), r && l.sort(o), ce(e) && e > -1 && (l = l.slice(0, e)), xs(l, this._docs, {
1570
+ let u = Te(e) ? Te(this._docs[0]) ? this._searchStringList(e) : this._searchObjectList(e) : this._searchLogical(e);
1571
+ return In(u, { ignoreFieldNorm: h }), l && u.sort(o), wi(t) && t > -1 && (u = u.slice(0, t)), Hn(u, this._docs, {
1572
1572
  includeMatches: s,
1573
1573
  includeScore: n
1574
1574
  });
1575
1575
  }
1576
- _searchStringList(t) {
1577
- const e = Mt(t, this.options), { records: s } = this._myIndex, n = [];
1578
- return s.forEach(({ v: r, i: o, n: c }) => {
1579
- if (!b(r))
1576
+ _searchStringList(e) {
1577
+ const t = _s(e, this.options), { records: s } = this._myIndex, n = [];
1578
+ return s.forEach(({ v: l, i: o, n: h }) => {
1579
+ if (!xe(l))
1580
1580
  return;
1581
- const { isMatch: l, score: a, indices: u } = e.searchIn(r);
1582
- l && n.push({
1583
- item: r,
1581
+ const { isMatch: u, score: d, indices: m } = t.searchIn(l);
1582
+ u && n.push({
1583
+ item: l,
1584
1584
  idx: o,
1585
- matches: [{ score: a, value: r, norm: c, indices: u }]
1585
+ matches: [{ score: d, value: l, norm: h, indices: m }]
1586
1586
  });
1587
1587
  }), n;
1588
1588
  }
1589
- _searchLogical(t) {
1590
- const e = me(t, this.options), s = (c, l, a) => {
1591
- if (!c.children) {
1592
- const { keyId: h, searcher: d } = c, p = this._findMatches({
1593
- key: this._keyStore.get(h),
1594
- value: this._myIndex.getValueForItemAtKeyId(l, h),
1595
- searcher: d
1589
+ _searchLogical(e) {
1590
+ const t = Oi(e, this.options), s = (h, u, d) => {
1591
+ if (!h.children) {
1592
+ const { keyId: v, searcher: $ } = h, M = this._findMatches({
1593
+ key: this._keyStore.get(v),
1594
+ value: this._myIndex.getValueForItemAtKeyId(u, v),
1595
+ searcher: $
1596
1596
  });
1597
- return p && p.length ? [
1597
+ return M && M.length ? [
1598
1598
  {
1599
- idx: a,
1600
- item: l,
1601
- matches: p
1599
+ idx: d,
1600
+ item: u,
1601
+ matches: M
1602
1602
  }
1603
1603
  ] : [];
1604
1604
  }
1605
- const u = [];
1606
- for (let h = 0, d = c.children.length; h < d; h += 1) {
1607
- const p = c.children[h], g = s(p, l, a);
1608
- if (g.length)
1609
- u.push(...g);
1610
- else if (c.operator === ct.AND)
1605
+ const m = [];
1606
+ for (let v = 0, $ = h.children.length; v < $; v += 1) {
1607
+ const M = h.children[v], j = s(M, u, d);
1608
+ if (j.length)
1609
+ m.push(...j);
1610
+ else if (h.operator === Ot.AND)
1611
1611
  return [];
1612
1612
  }
1613
- return u;
1614
- }, n = this._myIndex.records, r = {}, o = [];
1615
- return n.forEach(({ $: c, i: l }) => {
1616
- if (b(c)) {
1617
- let a = s(e, c, l);
1618
- a.length && (r[l] || (r[l] = { idx: l, item: c, matches: [] }, o.push(r[l])), a.forEach(({ matches: u }) => {
1619
- r[l].matches.push(...u);
1613
+ return m;
1614
+ }, n = this._myIndex.records, l = {}, o = [];
1615
+ return n.forEach(({ $: h, i: u }) => {
1616
+ if (xe(h)) {
1617
+ let d = s(t, h, u);
1618
+ d.length && (l[u] || (l[u] = { idx: u, item: h, matches: [] }, o.push(l[u])), d.forEach(({ matches: m }) => {
1619
+ l[u].matches.push(...m);
1620
1620
  }));
1621
1621
  }
1622
1622
  }), o;
1623
1623
  }
1624
- _searchObjectList(t) {
1625
- const e = Mt(t, this.options), { keys: s, records: n } = this._myIndex, r = [];
1626
- return n.forEach(({ $: o, i: c }) => {
1627
- if (!b(o))
1624
+ _searchObjectList(e) {
1625
+ const t = _s(e, this.options), { keys: s, records: n } = this._myIndex, l = [];
1626
+ return n.forEach(({ $: o, i: h }) => {
1627
+ if (!xe(o))
1628
1628
  return;
1629
- let l = [];
1630
- s.forEach((a, u) => {
1631
- l.push(
1629
+ let u = [];
1630
+ s.forEach((d, m) => {
1631
+ u.push(
1632
1632
  ...this._findMatches({
1633
- key: a,
1634
- value: o[u],
1635
- searcher: e
1633
+ key: d,
1634
+ value: o[m],
1635
+ searcher: t
1636
1636
  })
1637
1637
  );
1638
- }), l.length && r.push({
1639
- idx: c,
1638
+ }), u.length && l.push({
1639
+ idx: h,
1640
1640
  item: o,
1641
- matches: l
1641
+ matches: u
1642
1642
  });
1643
- }), r;
1643
+ }), l;
1644
1644
  }
1645
- _findMatches({ key: t, value: e, searcher: s }) {
1646
- if (!b(e))
1645
+ _findMatches({ key: e, value: t, searcher: s }) {
1646
+ if (!xe(t))
1647
1647
  return [];
1648
1648
  let n = [];
1649
- if (k(e))
1650
- e.forEach(({ v: r, i: o, n: c }) => {
1651
- if (!b(r))
1649
+ if (Re(t))
1650
+ t.forEach(({ v: l, i: o, n: h }) => {
1651
+ if (!xe(l))
1652
1652
  return;
1653
- const { isMatch: l, score: a, indices: u } = s.searchIn(r);
1654
- l && n.push({
1655
- score: a,
1656
- key: t,
1657
- value: r,
1653
+ const { isMatch: u, score: d, indices: m } = s.searchIn(l);
1654
+ u && n.push({
1655
+ score: d,
1656
+ key: e,
1657
+ value: l,
1658
1658
  idx: o,
1659
- norm: c,
1660
- indices: u
1659
+ norm: h,
1660
+ indices: m
1661
1661
  });
1662
1662
  });
1663
1663
  else {
1664
- const { v: r, n: o } = e, { isMatch: c, score: l, indices: a } = s.searchIn(r);
1665
- c && n.push({ score: l, key: t, value: r, norm: o, indices: a });
1664
+ const { v: l, n: o } = t, { isMatch: h, score: u, indices: d } = s.searchIn(l);
1665
+ h && n.push({ score: u, key: e, value: l, norm: o, indices: d });
1666
1666
  }
1667
1667
  return n;
1668
1668
  }
1669
1669
  }
1670
- K.version = "6.6.2";
1671
- K.createIndex = de;
1672
- K.parseIndex = is;
1673
- K.config = f;
1674
- K.parseQuery = me;
1675
- ys(_s);
1676
- var nt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
1677
- function Ss(i) {
1670
+ tt.version = "6.6.2";
1671
+ tt.createIndex = Ei;
1672
+ tt.parseIndex = yn;
1673
+ tt.config = T;
1674
+ tt.parseQuery = Oi;
1675
+ Tn(Dn);
1676
+ var at = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
1677
+ function Di(i) {
1678
1678
  return i && i.__esModule && Object.prototype.hasOwnProperty.call(i, "default") ? i.default : i;
1679
1679
  }
1680
- var ws = "Expected a function", te = 0 / 0, Ms = "[object Symbol]", Cs = /^\s+|\s+$/g, Rs = /^[-+]0x[0-9a-f]+$/i, Is = /^0b[01]+$/i, ks = /^0o[0-7]+$/i, Os = parseInt, Ts = typeof nt == "object" && nt && nt.Object === Object && nt, Ls = typeof self == "object" && self && self.Object === Object && self, Ns = Ts || Ls || Function("return this")(), Ps = Object.prototype, js = Ps.toString, Hs = Math.max, Us = Math.min, vt = function() {
1681
- return Ns.Date.now();
1680
+ var Un = "Expected a function", gi = 0 / 0, Fn = "[object Symbol]", Bn = /^\s+|\s+$/g, zn = /^[-+]0x[0-9a-f]+$/i, Wn = /^0b[01]+$/i, Vn = /^0o[0-7]+$/i, Yn = parseInt, Kn = typeof at == "object" && at && at.Object === Object && at, qn = typeof self == "object" && self && self.Object === Object && self, Xn = Kn || qn || Function("return this")(), Gn = Object.prototype, Jn = Gn.toString, Zn = Math.max, Qn = Math.min, ps = function() {
1681
+ return Xn.Date.now();
1682
1682
  };
1683
- function Fs(i, t, e) {
1684
- var s, n, r, o, c, l, a = 0, u = !1, h = !1, d = !0;
1683
+ function eo(i, e, t) {
1684
+ var s, n, l, o, h, u, d = 0, m = !1, v = !1, $ = !0;
1685
1685
  if (typeof i != "function")
1686
- throw new TypeError(ws);
1687
- t = ee(t) || 0, It(e) && (u = !!e.leading, h = "maxWait" in e, r = h ? Hs(ee(e.maxWait) || 0, t) : r, d = "trailing" in e ? !!e.trailing : d);
1688
- function p(y) {
1689
- var $ = s, E = n;
1690
- return s = n = void 0, a = y, o = i.apply(E, $), o;
1691
- }
1692
- function g(y) {
1693
- return a = y, c = setTimeout(A, t), u ? p(y) : o;
1694
- }
1695
- function v(y) {
1696
- var $ = y - l, E = y - a, S = t - $;
1697
- return h ? Us(S, r - E) : S;
1698
- }
1699
- function M(y) {
1700
- var $ = y - l, E = y - a;
1701
- return l === void 0 || $ >= t || $ < 0 || h && E >= r;
1702
- }
1703
- function A() {
1704
- var y = vt();
1705
- if (M(y))
1706
- return R(y);
1707
- c = setTimeout(A, v(y));
1708
- }
1709
- function R(y) {
1710
- return c = void 0, d && s ? p(y) : (s = n = void 0, o);
1711
- }
1712
- function I() {
1713
- c !== void 0 && clearTimeout(c), a = 0, s = l = n = c = void 0;
1714
- }
1715
- function D() {
1716
- return c === void 0 ? o : R(vt());
1717
- }
1718
- function G() {
1719
- var y = vt(), $ = M(y);
1720
- if (s = arguments, n = this, l = y, $) {
1721
- if (c === void 0)
1722
- return g(l);
1723
- if (h)
1724
- return c = setTimeout(A, t), p(l);
1686
+ throw new TypeError(Un);
1687
+ e = vi(e) || 0, As(t) && (m = !!t.leading, v = "maxWait" in t, l = v ? Zn(vi(t.maxWait) || 0, e) : l, $ = "trailing" in t ? !!t.trailing : $);
1688
+ function M(F) {
1689
+ var X = s, ie = n;
1690
+ return s = n = void 0, d = F, o = i.apply(ie, X), o;
1691
+ }
1692
+ function j(F) {
1693
+ return d = F, h = setTimeout(le, e), m ? M(F) : o;
1694
+ }
1695
+ function J(F) {
1696
+ var X = F - u, ie = F - d, z = e - X;
1697
+ return v ? Qn(z, l - ie) : z;
1698
+ }
1699
+ function ge(F) {
1700
+ var X = F - u, ie = F - d;
1701
+ return u === void 0 || X >= e || X < 0 || v && ie >= l;
1702
+ }
1703
+ function le() {
1704
+ var F = ps();
1705
+ if (ge(F))
1706
+ return ve(F);
1707
+ h = setTimeout(le, J(F));
1708
+ }
1709
+ function ve(F) {
1710
+ return h = void 0, $ && s ? M(F) : (s = n = void 0, o);
1711
+ }
1712
+ function pe() {
1713
+ h !== void 0 && clearTimeout(h), d = 0, s = u = n = h = void 0;
1714
+ }
1715
+ function Me() {
1716
+ return h === void 0 ? o : ve(ps());
1717
+ }
1718
+ function me() {
1719
+ var F = ps(), X = ge(F);
1720
+ if (s = arguments, n = this, u = F, X) {
1721
+ if (h === void 0)
1722
+ return j(u);
1723
+ if (v)
1724
+ return h = setTimeout(le, e), M(u);
1725
1725
  }
1726
- return c === void 0 && (c = setTimeout(A, t)), o;
1726
+ return h === void 0 && (h = setTimeout(le, e)), o;
1727
1727
  }
1728
- return G.cancel = I, G.flush = D, G;
1728
+ return me.cancel = pe, me.flush = Me, me;
1729
1729
  }
1730
- function It(i) {
1731
- var t = typeof i;
1732
- return !!i && (t == "object" || t == "function");
1730
+ function As(i) {
1731
+ var e = typeof i;
1732
+ return !!i && (e == "object" || e == "function");
1733
1733
  }
1734
- function Ds(i) {
1734
+ function to(i) {
1735
1735
  return !!i && typeof i == "object";
1736
1736
  }
1737
- function zs(i) {
1738
- return typeof i == "symbol" || Ds(i) && js.call(i) == Ms;
1737
+ function so(i) {
1738
+ return typeof i == "symbol" || to(i) && Jn.call(i) == Fn;
1739
1739
  }
1740
- function ee(i) {
1740
+ function vi(i) {
1741
1741
  if (typeof i == "number")
1742
1742
  return i;
1743
- if (zs(i))
1744
- return te;
1745
- if (It(i)) {
1746
- var t = typeof i.valueOf == "function" ? i.valueOf() : i;
1747
- i = It(t) ? t + "" : t;
1743
+ if (so(i))
1744
+ return gi;
1745
+ if (As(i)) {
1746
+ var e = typeof i.valueOf == "function" ? i.valueOf() : i;
1747
+ i = As(e) ? e + "" : e;
1748
1748
  }
1749
1749
  if (typeof i != "string")
1750
1750
  return i === 0 ? i : +i;
1751
- i = i.replace(Cs, "");
1752
- var e = Is.test(i);
1753
- return e || ks.test(i) ? Os(i.slice(2), e ? 2 : 8) : Rs.test(i) ? te : +i;
1754
- }
1755
- var Bs = Fs;
1756
- const Ws = /* @__PURE__ */ Ss(Bs), Vs = (i, t = "highlight", e = "title") => {
1757
- const s = (r, o, c) => {
1758
- const l = o.split(".");
1759
- let a;
1760
- for (a = 0; a < l.length - 1; a++)
1761
- r = r[l[a]];
1762
- r[l[a]] = c;
1763
- }, n = (r, o = []) => {
1764
- let c = "", l = 0;
1765
- return o.forEach((a) => {
1766
- const u = a[1] + 1;
1767
- c += [
1768
- r.substring(l, a[0]),
1769
- `<mark class="${t}">`,
1770
- r.substring(a[0], u),
1751
+ i = i.replace(Bn, "");
1752
+ var t = Wn.test(i);
1753
+ return t || Vn.test(i) ? Yn(i.slice(2), t ? 2 : 8) : zn.test(i) ? gi : +i;
1754
+ }
1755
+ var io = eo;
1756
+ const ro = /* @__PURE__ */ Di(io);
1757
+ (() => {
1758
+ var i = Object.defineProperty, e = Math.pow, t = (r, c, f) => c in r ? i(r, c, { enumerable: !0, configurable: !0, writable: !0, value: f }) : r[c] = f, s = (r, c, f) => (t(r, typeof c != "symbol" ? c + "" : c, f), f), n = (r, c) => ` ${c && c.length > 0 ? c.map((f) => `<link rel="stylesheet" href="${f}" />`).join("") : ""} <style> ${r} </style> <div class="range-slider-box"> <div class="row"> <div id="range-slider" class="range-slider"> <div class="container"> <div class="panel"></div> <div class="panel-fill"></div> <div class="container"> <div class="pointer" tabindex="0" role="slider"> <div class="pointer-shape"></div> </div> </div> </div> </div> </div> </div>`, l = ":host{--width:300px;--height:.25rem;--opacity:.4;--panel-bg:#cbd5e1;--panel-bg-hover:#94a3b8;--panel-bg-fill:#475569;--panel-bg-border-radius:1rem;--pointer-width:1rem;--pointer-height:1rem;--pointer-bg:#fff;--pointer-bg-hover:#dcdcdc;--pointer-bg-focus:#dcdcdc;--pointer-shadow:0 0 2px rgba(0,0,0,0.8);--pointer-shadow-hover:0 0 2px #000;--pointer-shadow-focus:var(--pointer-shadow-hover);--pointer-border:1px solid hsla(0,0%,88%,0.5);--pointer-border-hover:1px solid #94a3b8;--pointer-border-focus:var(--pointer-border-hover);--pointer-border-radius:100%;--animate-onclick:.3s}:host{max-width:100%}.range-slider-box{display:flex;position:relative;flex-direction:column}.range-slider{position:relative;width:var(--width,100%);height:var(--height,0.25rem);touch-action:none;max-width:100%;box-sizing:border-box;cursor:pointer}.row{width:100%;display:flex;align-items:center}.range-slider.disabled{opacity:var(--opacity,0.4);cursor:default}.pointer.disabled{-webkit-filter:brightness(0.8);filter:brightness(0.8);cursor:default}.range-slider *{box-sizing:border-box}.container{position:absolute;width:100%;height:100%}.panel{position:absolute;z-index:10;width:100%;height:100%;background:var(--panel-bg,#2d4373);border-radius:var(--panel-bg-border-radius,1rem);overflow:hidden;transition:.3s all ease}.panel-fill{background:var(--panel-bg-fill,#000);border-radius:var(--panel-bg-border-radius,1rem);overflow:hidden;height:100%;position:absolute;z-index:10}.panel:hover{background:var(--panel-bg-hover,#5f79b7)}.disabled .panel:hover{background:var(--panel-bg,#5f79b7)}.pointer{position:absolute;z-index:20;outline:0;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.pointer-shape{background:var(--pointer-bg,#fff);background-size:contain;box-shadow:var(--pointer-shadow);border:var(--pointer-border);border-radius:var(--pointer-border-radius,100%);-webkit-transform:translateX(-50%);transform:translateX(-50%);width:var(--pointer-width,15px);height:var(--pointer-height,15px);transition:.3s all ease}.pointer-shape:hover{background:var(--pointer-bg-hover,#fff);background-size:contain;border:var(--pointer-border-hover);box-shadow:var(--pointer-shadow-hover)}.disabled .pointer-shape:hover{background:var(--pointer-bg,#fff);background-size:contain;border:var(--pointer-border);box-shadow:var(--pointer-shadow)}.pointer:focus .pointer-shape{background:var(--pointer-bg-focus,#fff);background-size:contain;border:var(--pointer-border-focus);box-shadow:var(--pointer-shadow-focus)}.disabled .pointer:focus .pointer-shape{background:var(--pointer-bg,#fff);background-size:contain;border:var(--pointer-border);box-shadow:var(--pointer-shadow)}.type-vertical .range-slider{--width:.25rem;--height:300px;max-height:100%}.type-vertical .range-slider .pointer{left:50%}.type-vertical .range-slider .panel-fill{width:100%}.type-vertical.range-slider-box{flex-direction:row}.type-vertical .row{flex-direction:column}.animate-on-click .pointer,.animate-on-click .panel-fill{transition:all var(--animate-onclick)}.range-dragging .panel-fill{cursor:move}", o = "pointers-overlap", h = "pointers-min-distance", u = "pointers-max-distance", d = "range-dragging", m = "data", v = "min", $ = "max", M = "step", j = "round", J = "type", ge = "theme", le = "rtl", ve = "btt", pe = "disabled", Me = "keyboard-disabled", me = "mousewheel-disabled", F = "slider-width", X = "slider-height", ie = "slider-radius", z = "slider-bg", B = "slider-bg-hover", Ce = "slider-bg-fill", Se = "pointer-width", D = "pointer-height", y = "pointer-radius", b = "pointer-bg", k = "pointer-bg-hover", _ = "pointer-bg-focus", P = "pointer-shadow", R = "pointer-shadow-hover", V = "pointer-shadow-focus", se = "pointer-border", Z = "pointer-border-hover", ce = "pointer-border-focus", Ee = "animate-onclick", ke = "css-links", ue = "vertical", we = "horizontal", Oe = (r, c, f, p, x) => {
1759
+ let L = c - r;
1760
+ return L === 0 ? f : (p - f) * (x - r) / L + f;
1761
+ }, Q = (r) => !isNaN(parseFloat(r)) && isFinite(r), K = (r, c) => Q(r) ? Number(r) : c, Ke = (r, c) => c === 0 ? 0 : Math.round(r / c) * c, qe = (r, c = 1 / 0) => {
1762
+ if (c === 1 / 0)
1763
+ return r;
1764
+ let f = e(10, c);
1765
+ return Math.round(r * f) / f;
1766
+ }, de = (r) => r == null ? !1 : typeof r == "boolean" ? r : r.trim().toLowerCase() === "true", Ri = (r, c) => {
1767
+ r.dispatchEvent(new CustomEvent("onPointerClicked", { detail: { $pointer: c } }));
1768
+ }, Pi = (r, c) => {
1769
+ r.dispatchEvent(new CustomEvent("onMouseDown", { detail: { nativeEvent: c } }));
1770
+ }, Ii = (r, c) => {
1771
+ r.dispatchEvent(new CustomEvent("onMouseUp", { detail: { nativeEvent: c } }));
1772
+ }, Ni = (r, c) => {
1773
+ r.dispatchEvent(new CustomEvent("onKeyDown", { detail: { nativeEvent: c } }));
1774
+ }, ji = (r, c) => {
1775
+ if (!c || c.length <= 0)
1776
+ return;
1777
+ let f = c.map((x) => Q(x) ? K(x, x) : x), p = { values: f || [] };
1778
+ p.value = f[0], p.value0 = f[0], p.value1 = f[0];
1779
+ for (let x = 1; x < f.length; x++)
1780
+ p[`value${x + 1}`] = f[x];
1781
+ r.dispatchEvent(new CustomEvent("change", { detail: p }));
1782
+ }, Rt = (r, c, f) => {
1783
+ let p = 0, x, L, I, w, A = !1, N = (O, G, he, ae, re, ne) => {
1784
+ let ye = p;
1785
+ he !== void 0 && O > he && (O = he), G !== void 0 && O < G && (O = G), p = O;
1786
+ let be = p;
1787
+ return (ae === ue && ne || ae === we && re) && (be = 100 - be), ae === ue ? c.style.top = `${be}%` : c.style.left = `${be}%`, ye !== p;
1788
+ }, U = (O) => O === c || c.contains(O), E = (O, G, he, ae) => {
1789
+ x = O, L = G, I = he, w = ae;
1790
+ }, Y = (O) => {
1791
+ A = O, c.classList.toggle("disabled", A), A ? c.setAttribute("aria-disabled", "true") : c.hasAttribute("aria-disabled") && c.removeAttribute("aria-disabled");
1792
+ }, Ae = (O, G) => {
1793
+ G == null ? c.removeAttribute(O) : c.setAttribute(O, G);
1794
+ }, fe = (O) => c.getAttribute(O), C = (O) => {
1795
+ if (!A) {
1796
+ switch (O.key) {
1797
+ case "ArrowLeft": {
1798
+ O.preventDefault(), typeof x == "function" && x(f);
1799
+ break;
1800
+ }
1801
+ case "ArrowRight": {
1802
+ O.preventDefault(), typeof L == "function" && L(f);
1803
+ break;
1804
+ }
1805
+ case "ArrowUp": {
1806
+ O.preventDefault(), typeof I == "function" && I(f);
1807
+ break;
1808
+ }
1809
+ case "ArrowDown": {
1810
+ O.preventDefault(), typeof w == "function" && w(f);
1811
+ break;
1812
+ }
1813
+ }
1814
+ Ni(r, O);
1815
+ }
1816
+ }, H = () => {
1817
+ A || Ri(r, c);
1818
+ };
1819
+ return c.className = `pointer pointer-${f}`, c.addEventListener("keydown", C), c.addEventListener("click", H), { $pointer: c, get percent() {
1820
+ return p;
1821
+ }, get disabled() {
1822
+ return A;
1823
+ }, set disabled(O) {
1824
+ Y(O);
1825
+ }, updatePosition: N, isClicked: U, setCallbacks: E, setAttr: Ae, getAttr: fe, destroy: () => {
1826
+ c.removeEventListener("keydown", C), c.removeEventListener("click", H), c.remove();
1827
+ } };
1828
+ }, Hi = (r) => {
1829
+ if (r == null)
1830
+ return;
1831
+ if (Array.isArray(r))
1832
+ return r;
1833
+ if (r.trim() === "")
1834
+ return;
1835
+ let c = r.split(","), f = [], p = !0;
1836
+ for (let x = 0; x < c.length; x++) {
1837
+ let L = c[x].trim();
1838
+ L !== "" && (f.push(L), Q(L) || (p = !1));
1839
+ }
1840
+ return p ? f.map((x) => Number(x)) : f;
1841
+ }, Ui = (r, c) => c ? c.findIndex((f) => f === r || f.toString().trim() === r.toString().trim()) : -1, Fi = (r) => ({ updatePosition: (c, f, p, x) => {
1842
+ if (f.length <= 0)
1843
+ return;
1844
+ let L = f.length === 1, I = f[0], w = f[f.length - 1];
1845
+ c === ue ? (r.style.removeProperty("width"), r.style.removeProperty("right"), r.style.removeProperty("left"), L ? r.style.height = `${I}%` : r.style.height = `${Math.abs(I - w)}%`, x ? (r.style.bottom = "0%", L ? r.style.top = "auto" : r.style.top = `${Math.min(100 - w, 100 - I)}%`) : (r.style.bottom = "auto", L ? r.style.top = "0%" : r.style.top = `${Math.min(I, w)}%`)) : (r.style.removeProperty("height"), r.style.removeProperty("top"), r.style.removeProperty("bottom"), L ? r.style.width = `${I}%` : r.style.width = `${Math.abs(I - w)}%`, p ? (r.style.right = "0%", L ? r.style.left = "auto" : r.style.left = `${Math.min(100 - w, 100 - I)}%`) : (r.style.right = "auto", L ? r.style.left = "0%" : r.style.left = `${Math.min(I, w)}%`));
1846
+ } }), ks = "--animate-onclick", Bi = "--width", zi = "--height", Wi = "--panel-bg-border-radius", Vi = "--panel-bg", Yi = "--panel-bg-hover", Ki = "--panel-bg-fill", qi = "--pointer-width", Xi = "--pointer-height", Gi = "--pointer-border-radius", Ji = "--pointer-bg", Zi = "--pointer-bg-hover", Qi = "--pointer-bg-focus", er = "--pointer-shadow", tr = "--pointer-shadow-hover", sr = "--pointer-shadow-focus", ir = "--pointer-border", rr = "--pointer-border-hover", nr = "--pointer-border-focus", ft = (r, c, f) => {
1847
+ let p = /* @__PURE__ */ new Map();
1848
+ for (let x of r.attributes) {
1849
+ let L = x.nodeName.trim().toLowerCase();
1850
+ if (!c.test(L))
1851
+ continue;
1852
+ let I = L.replace(/\D/g, "").trim(), w = I === "" || I === "0" || I === "1" ? 0 : K(I, 0) - 1, A = f && typeof f == "function" ? f(x.value) : x.value;
1853
+ p.set(w, A);
1854
+ }
1855
+ return p;
1856
+ }, or = (r) => {
1857
+ if (!r)
1858
+ return null;
1859
+ let c = r.getAttribute(ke);
1860
+ if (!c)
1861
+ return null;
1862
+ let f = c.split(";"), p = [];
1863
+ for (let x of f)
1864
+ x.trim() !== "" && p.push(x.trim());
1865
+ return p;
1866
+ }, Ls = [[Bi, F, "sliderWidth", null], [zi, X, "sliderHeight", null], [Wi, ie, "sliderRadius", null], [Vi, z, "sliderBg", null], [Yi, B, "sliderBgHover", null], [Ki, Ce, "sliderBgFill", null], [qi, Se, "pointer#Width", /^pointer([0-9]*)-width$/], [Xi, D, "pointer#Height", /^pointer([0-9]*)-height$/], [Gi, y, "pointer#Radius", /^pointer([0-9]*)-radius$/], [Ji, b, "pointer#Bg", /^pointer([0-9]*)-bg$/], [Zi, k, "pointer#BgHover", /^pointer([0-9]*)-bg-hover$/], [Qi, _, "pointer#BgFocus", /^pointer([0-9]*)-bg-focus$/], [er, P, "pointer#Shadow", /^pointer([0-9]*)-shadow$/], [tr, R, "pointer#ShadowHover", /^pointer([0-9]*)-shadow-hover$/], [sr, V, "pointer#ShadowFocus", /^pointer([0-9]*)-shadow-focus$/], [ir, se, "pointer#Border", /^pointer([0-9]*)-border$/], [rr, Z, "pointer#BorderHover", /^pointer([0-9]*)-border-hover$/], [nr, ce, "pointer#BorderFocus", /^pointer([0-9]*)-border-focus$/]], lr = (r, c, f) => {
1867
+ let p = null, x = [], L = /* @__PURE__ */ new Map(), I = (C, H = c) => {
1868
+ let O = [...H.classList];
1869
+ for (let G of O)
1870
+ G.startsWith(C) && c.classList.remove(G);
1871
+ }, w = () => {
1872
+ I("shape");
1873
+ let C = c.querySelectorAll(".pointer");
1874
+ for (let H of C)
1875
+ I("shape", H);
1876
+ }, A = (C) => {
1877
+ p = C, I("theme-"), typeof C == "string" && c.classList.add(`theme-${C}`);
1878
+ }, N = () => {
1879
+ if (w(), !(x.length <= 0)) {
1880
+ c.classList.add("shape", `shape-${x[0]}`);
1881
+ for (let C = 1; C < x.length; C++) {
1882
+ let H = x[C];
1883
+ if (!H)
1884
+ continue;
1885
+ let O = c.querySelector(`.pointer-${C}`);
1886
+ !O || O.classList.add("shape", `shape-${H}`);
1887
+ }
1888
+ }
1889
+ }, U = (C, H) => {
1890
+ x[C] = H, N();
1891
+ }, E = () => {
1892
+ w();
1893
+ let C = ft(r, /^pointer([0-9]*)-shape$/);
1894
+ if (!(C.size <= 0)) {
1895
+ for (let H of C) {
1896
+ let O = H[0];
1897
+ x[O] = H[1];
1898
+ }
1899
+ N();
1900
+ }
1901
+ }, Y = (C, H) => `${C}-${H}`, Ae = (C, H, O) => {
1902
+ let G = f[O];
1903
+ if (!G)
1904
+ return;
1905
+ let he = O === 0 ? c : G.$pointer;
1906
+ if (H == null) {
1907
+ L.has(Y(C, O)) && L.delete(Y(C, O)), he.style.removeProperty(C);
1908
+ return;
1909
+ }
1910
+ L.set(Y(C, O), H), he.style.setProperty(C, H);
1911
+ }, fe = (C, H) => L.get(Y(C, H));
1912
+ return (() => {
1913
+ for (let C of Ls) {
1914
+ let [H, O, G, he] = C;
1915
+ if (he) {
1916
+ let re = ft(r, he);
1917
+ for (let ne of re) {
1918
+ let ye = ne[0], be = ne[1];
1919
+ Ae(H, be, ye);
1920
+ }
1921
+ } else {
1922
+ let re = r.getAttribute(O);
1923
+ Ae(H, re, 0);
1924
+ }
1925
+ let ae = [];
1926
+ if (G.indexOf("#") === -1)
1927
+ ae.push([G, 0]);
1928
+ else {
1929
+ ae.push([G.replace("#", ""), 0]), ae.push([G.replace("#", "0"), 0]), ae.push([G.replace("#", "1"), 0]);
1930
+ for (let re = 1; re < f.length; re++)
1931
+ ae.push([G.replace("#", (re + 1).toString()), re]);
1932
+ }
1933
+ for (let re of ae)
1934
+ try {
1935
+ let ne = re[0], ye = re[1];
1936
+ Object.prototype.hasOwnProperty.call(r, ne) || Object.defineProperty(r, ne, { get() {
1937
+ return fe(H, ye);
1938
+ }, set: (be) => {
1939
+ Ae(H, be, ye);
1940
+ } });
1941
+ } catch (ne) {
1942
+ console.error(ne);
1943
+ }
1944
+ }
1945
+ A(r.getAttribute(ge)), E();
1946
+ })(), { setStyle: Ae, getStyle: fe, get theme() {
1947
+ return p;
1948
+ }, set theme(C) {
1949
+ A(C);
1950
+ }, get pointerShapes() {
1951
+ return x;
1952
+ }, setPointerShape: U };
1953
+ }, Xe = "animate-on-click", Cs = "range-dragging", ar = (r, c, f, p) => {
1954
+ let x = [], L = (U) => {
1955
+ for (let E of x)
1956
+ E.update && typeof E.update == "function" && E.update(U);
1957
+ }, I = () => {
1958
+ for (let U of x)
1959
+ U.destroy && typeof U.destroy == "function" && U.destroy();
1960
+ }, w = (U, E) => {
1961
+ for (let Y of x)
1962
+ Y.onAttrChange && typeof Y.onAttrChange == "function" && Y.onAttrChange(U, E);
1963
+ }, A = (U) => {
1964
+ if (U.gettersAndSetters) {
1965
+ for (let E of U.gettersAndSetters)
1966
+ if (!(!E.name || !E.attributes))
1967
+ try {
1968
+ Object.prototype.hasOwnProperty.call(r, E.name) || Object.defineProperty(r, E.name, E.attributes);
1969
+ } catch (Y) {
1970
+ console.error("defineSettersGetters error:", Y);
1971
+ }
1972
+ }
1973
+ }, N = (U) => {
1974
+ var E;
1975
+ if (!U.css)
1976
+ return;
1977
+ let Y = (E = r.shadowRoot) == null ? void 0 : E.querySelector("style");
1978
+ !Y || (Y.innerHTML += U.css);
1979
+ };
1980
+ return { init: () => {
1981
+ if (window.tcRangeSliderPlugins)
1982
+ for (let U of window.tcRangeSliderPlugins) {
1983
+ let E = U();
1984
+ x.push(E), E.init && typeof E.init == "function" && (E.init(r, c, f, p), A(E), N(E));
1985
+ }
1986
+ }, update: L, onAttrChange: w, destroy: I };
1987
+ }, cr = 10, hr = (r, c) => {
1988
+ let f = /* @__PURE__ */ new Map(), p = /^value([0-9]*)$/;
1989
+ for (let w of r.attributes) {
1990
+ let A = w.nodeName.trim().toLowerCase();
1991
+ if (!p.test(A))
1992
+ continue;
1993
+ let N = A.replace("value", "").trim(), U = N === "" || N === "0" || N === "1" ? 0 : K(N, 0) - 1, E = Q(w.value) ? K(w.value, 0) : w.value;
1994
+ f.set(U, E);
1995
+ }
1996
+ let x = Math.max(...Array.from(f.keys())), L = [];
1997
+ L.push([Rt(r, c, 0), f.get(0)]);
1998
+ let I = c;
1999
+ for (let w = 1; w <= x; w++) {
2000
+ let A = c.cloneNode(!0);
2001
+ I.after(A), I = A, L.push([Rt(r, A, w), f.get(w)]);
2002
+ }
2003
+ return L;
2004
+ }, Os = (r, c, f, p, x, L, I) => {
2005
+ try {
2006
+ Object.defineProperty(r, p, { configurable: !0, get() {
2007
+ if (!c)
2008
+ return;
2009
+ let w = c.pointers[f];
2010
+ if (!w)
2011
+ return;
2012
+ let A = c.getTextValue(w.percent);
2013
+ return Q(A) ? K(A, A) : A;
2014
+ }, set: (w) => {
2015
+ c.pointers[f] ? c == null || c.setValue(w, f) : c == null || c.addPointer(w);
2016
+ } }), Object.defineProperty(r, x, { configurable: !0, get() {
2017
+ var w, A;
2018
+ return (A = (w = c == null ? void 0 : c.pointers[f]) == null ? void 0 : w.getAttr("aria-label")) != null ? A : void 0;
2019
+ }, set: (w) => {
2020
+ !c || c.setAriaLabel(f, w);
2021
+ } }), Object.defineProperty(r, L, { configurable: !0, get() {
2022
+ var w, A;
2023
+ return (A = (w = c == null ? void 0 : c.styles) == null ? void 0 : w.pointerShapes[f]) != null ? A : null;
2024
+ }, set: (w) => {
2025
+ !c || !c.styles || c.styles.setPointerShape(f, w);
2026
+ } }), Object.defineProperty(r, I, { configurable: !0, get() {
2027
+ var w;
2028
+ return (w = c == null ? void 0 : c.pointers[f].disabled) != null ? w : !1;
2029
+ }, set: (w) => {
2030
+ if (!c)
2031
+ return;
2032
+ let A = c == null ? void 0 : c.pointers[f];
2033
+ !A || (A.disabled = w);
2034
+ } });
2035
+ } catch (w) {
2036
+ console.error(w);
2037
+ }
2038
+ }, ur = (r, c) => {
2039
+ let f = [["value", "ariaLabel", "pointerShape", "pointerDisabled", 0], ["value0", "ariaLabel0", "pointerShape0", "pointer0Disabled", 0], ["value1", "ariaLabel1", "pointerShape1", "pointer1Disabled", 0]];
2040
+ for (let p = 2; p < cr; p++)
2041
+ f.push([`value${p}`, `ariaLabel${p}`, `pointer${p}Shape`, `pointer${p}Disabled`, p - 1]);
2042
+ for (let p of f)
2043
+ Os(r, c, p[4], p[0], p[1], p[2], p[3]);
2044
+ }, Ds = (r, c, f) => {
2045
+ var p;
2046
+ let x = (p = f.shadowRoot) == null ? void 0 : p.querySelector(".container");
2047
+ if (x)
2048
+ for (let L of r)
2049
+ c ? x.prepend(L.$pointer) : x.append(L.$pointer);
2050
+ }, Pt = 0, st = 100, Ge = 2, Ts = "0.3s", dr = (r, c, f) => {
2051
+ let p = f.map((a) => a[0]), x = null, L = null, I = null, w = null, A = Pt, N = st, U, E, Y = we, Ae = Ge, fe = !1, C = !1, H = !1, O = 0, G = 1 / 0, he = !1, ae, re, ne = !1, ye = !1, be = !1, Pe = Ts, Rs = [], Ps = (a) => {
2052
+ ne || (a.preventDefault && a.preventDefault(), He(a), window.addEventListener("mousemove", He), window.addEventListener("mouseup", gt), Pi(r, a));
2053
+ }, gt = (a) => {
2054
+ ne || (ae = void 0, re = void 0, window.removeEventListener("mousemove", He), window.removeEventListener("mouseup", gt), Pe && c.classList.add(Xe), Ii(r, a));
2055
+ }, gr = (a, g) => {
2056
+ if (p.length <= 0)
2057
+ return;
2058
+ if (p.length === 1)
2059
+ return p[0].isClicked(a) && Pe && c.classList.remove(Xe), p[0];
2060
+ let S = mr(a);
2061
+ if (he) {
2062
+ let W = g, Le = mt(W);
2063
+ Le !== void 0 && (W = Ke(W, Le)), S ? (ae = W, re = 0, Pe && c.classList.remove(Xe)) : ae !== void 0 && (re = W - ae, ae = W);
2064
+ }
2065
+ if (!vr(a) && !S) {
2066
+ for (let W of p)
2067
+ if (!(!W.isClicked(a) || W.disabled))
2068
+ return Pe && c.classList.remove(Xe), W;
2069
+ for (let W of p)
2070
+ if (x === W)
2071
+ return W;
2072
+ }
2073
+ let q = 1 / 0, oe = null;
2074
+ for (let W of p) {
2075
+ if (W.disabled)
2076
+ continue;
2077
+ let Le = Math.abs(g - W.percent);
2078
+ Le < q && (q = Le, oe = W);
2079
+ }
2080
+ return oe;
2081
+ }, Is = () => p.findIndex((a) => x === a && !a.disabled), He = (a) => {
2082
+ let g;
2083
+ if (Y === ue) {
2084
+ let { height: q, top: oe } = c.getBoundingClientRect(), W = a.type.indexOf("mouse") !== -1 ? a.clientY : a.touches[0].clientY;
2085
+ g = Math.min(Math.max(0, W - oe), q) * 100 / q;
2086
+ } else {
2087
+ let { width: q, left: oe } = c.getBoundingClientRect(), W = a.type.indexOf("mouse") !== -1 ? a.clientX : a.touches[0].clientX;
2088
+ g = Math.min(Math.max(0, W - oe), q) * 100 / q;
2089
+ }
2090
+ if ((fe || C) && (g = 100 - g), x = gr(a.target, g), he && p.length > 1 && re !== void 0) {
2091
+ let q = p[0], oe = p[p.length - 1], W = q.percent + re < 0, Le = oe.percent + re > 100;
2092
+ if (W || Le)
2093
+ return;
2094
+ for (let Mt = 0; Mt < p.length; Mt++)
2095
+ $e(Mt, p[Mt].percent + re);
2096
+ return;
2097
+ }
2098
+ let S = Is();
2099
+ S !== -1 && ($e(S, g), x == null || x.$pointer.focus());
2100
+ }, vt = (a) => {
2101
+ if (ne || document.activeElement !== r || x != null && x.disabled)
2102
+ return;
2103
+ a.stopPropagation(), a.preventDefault();
2104
+ let g = a.deltaY < 0, S = fe || C, q = g ? !S : S, oe = Is();
2105
+ oe !== -1 && (q ? it(oe, p[oe].percent) : rt(oe, p[oe].percent));
2106
+ }, Ns = (a) => {
2107
+ ne || ye || (Y === ue ? C ? $e(a, 100) : $e(a, 0) : fe ? rt(a, p[a].percent) : it(a, p[a].percent));
2108
+ }, js = (a) => {
2109
+ ne || ye || (Y === ue ? C ? $e(a, 0) : $e(a, 100) : fe ? it(a, p[a].percent) : rt(a, p[a].percent));
2110
+ }, Hs = (a) => {
2111
+ ne || ye || (Y === ue ? C ? rt(a, p[a].percent) : it(a, p[a].percent) : fe ? $e(a, 100) : $e(a, 0));
2112
+ }, Us = (a) => {
2113
+ ne || ye || (Y === ue ? C ? it(a, p[a].percent) : rt(a, p[a].percent) : fe ? $e(a, 0) : $e(a, 100));
2114
+ }, vr = (a) => a.classList.contains("panel"), mr = (a) => a.classList.contains("panel-fill"), it = (a, g) => {
2115
+ if (g === void 0)
2116
+ return;
2117
+ let S = mt(g);
2118
+ S == null && (S = 1), g -= S, g < 0 && (g = 0), $e(a, g);
2119
+ }, rt = (a, g) => {
2120
+ if (g === void 0)
2121
+ return;
2122
+ let S = mt(g);
2123
+ S == null && (S = 1), g += S, g > 100 && (g = 100), $e(a, g);
2124
+ }, Ue = () => {
2125
+ !w || w.update({ percents: Fs(), values: Bs(), $pointers: zs(), min: Ws(), max: Vs(), data: jt(), step: Nt(), round: Ut(), type: Ht(), textMin: yt(), textMax: bt(), rightToLeft: zt(), bottomToTop: Wt(), pointersOverlap: qt(), pointersMinDistance: Ft(), pointersMaxDistance: Bt(), rangeDragging: Xt(), disabled: Vt(), keyboardDisabled: Yt(), mousewheelDisabled: Kt() });
2126
+ }, yr = () => {
2127
+ Ue();
2128
+ }, br = (a) => {
2129
+ if (!(H || p.length <= 1 || N === A))
2130
+ if (a === 0) {
2131
+ let g = G * 100 / (N - A);
2132
+ return Math.max(0, p[a + 1].percent - g);
2133
+ } else {
2134
+ let g = O * 100 / (N - A);
2135
+ return Math.min(p[a - 1].percent + g, 100);
2136
+ }
2137
+ }, $r = (a) => {
2138
+ if (!(H || p.length <= 1 || N === A))
2139
+ if (a === p.length - 1) {
2140
+ let g = G * 100 / (N - A);
2141
+ return Math.min(p[a - 1].percent + g, 100);
2142
+ } else {
2143
+ let g = O * 100 / (N - A);
2144
+ return Math.max(0, p[a + 1].percent - g);
2145
+ }
2146
+ }, mt = (a) => {
2147
+ let g;
2148
+ if (typeof U == "function") {
2149
+ let S = Oe(0, 100, A, N, a);
2150
+ g = U(S, a);
2151
+ } else
2152
+ g = U;
2153
+ if (Q(g)) {
2154
+ let S = N - A;
2155
+ return g = S === 0 ? 0 : g * 100 / S, g;
2156
+ }
2157
+ }, Je = (a) => {
2158
+ if (a === void 0)
2159
+ return;
2160
+ let g = Oe(0, 100, A, N, a);
2161
+ return E !== void 0 ? E[Math.round(g)] : qe(g, Ae);
2162
+ }, yt = () => E !== void 0 ? E[A] : A, bt = () => E !== void 0 ? E[N] : N, Nt = () => U, _r = (a) => {
2163
+ var g;
2164
+ return a <= 0 || H ? yt() : (g = Je(p[a - 1].percent)) != null ? g : "";
2165
+ }, xr = (a) => {
2166
+ var g;
2167
+ return p.length <= 1 || a >= p.length - 1 || H ? bt() : (g = Je(p[a + 1].percent)) != null ? g : "";
2168
+ }, Fs = () => p.map((a) => a.percent), Bs = () => p.map((a) => Je(a.percent)), zs = () => p.map((a) => a.$pointer), Ws = () => A, Vs = () => N, jt = () => E, Ht = () => Y, Ut = () => Ae, Ft = () => O, Bt = () => G, wr = (a) => Rs[a], zt = () => fe, Wt = () => C, Vt = () => ne, Yt = () => ye, Kt = () => be, qt = () => H, Xt = () => he, $e = (a, g) => {
2169
+ if (g === void 0)
2170
+ return;
2171
+ let S = mt(g);
2172
+ S !== void 0 && (g = Ke(g, S));
2173
+ let q = p[a];
2174
+ if (!q)
2175
+ return;
2176
+ let oe = q.updatePosition(g, br(a), $r(a), Y, fe, C);
2177
+ L == null || L.updatePosition(Y, p.map((W) => W.percent), fe, C), Ue();
2178
+ for (let W of p) {
2179
+ let Le = Je(W.percent);
2180
+ Le !== void 0 && (W.setAttr("aria-valuenow", Le.toString()), W.setAttr("aria-valuetext", Le.toString()));
2181
+ }
2182
+ Mr(), oe && ji(r, p.map((W) => Je(W.percent)));
2183
+ }, De = () => {
2184
+ for (let a = 0; a < p.length; a++)
2185
+ $e(a, p[a].percent);
2186
+ }, Ar = (a, g) => {
2187
+ A = E !== void 0 ? 0 : K(a, Pt), N = E !== void 0 ? E.length - 1 : K(g, st), $t(A), _t(N);
2188
+ }, Mr = () => {
2189
+ var a, g;
2190
+ for (let S = 0; S < p.length; S++) {
2191
+ let q = p[S];
2192
+ q.setAttr("aria-valuemin", ((a = _r(S)) != null ? a : "").toString()), q.setAttr("aria-valuemax", ((g = xr(S)) != null ? g : "").toString());
2193
+ }
2194
+ }, $t = (a) => {
2195
+ A = K(a, Pt), A > N && (N = A + st), De();
2196
+ }, _t = (a) => {
2197
+ N = K(a, st), N < A && (N = A + st), De();
2198
+ }, Ys = (a) => {
2199
+ H = !0;
2200
+ for (let g = 0; g < a.length; g++)
2201
+ xt(a[g], g);
2202
+ H = !1;
2203
+ for (let g = 0; g < a.length; g++)
2204
+ xt(a[g], g);
2205
+ }, xt = (a, g) => {
2206
+ let S;
2207
+ E !== void 0 ? (S = a == null ? 0 : Ui(a, E), S === -1 && (S = 0)) : (S = K(a, A), S < A && (S = A), S > N && (S = N));
2208
+ let q = Oe(A, N, 0, 100, S);
2209
+ $e(g, q);
2210
+ }, wt = (a) => {
2211
+ if (a == null) {
2212
+ U = void 0;
2213
+ return;
2214
+ }
2215
+ if (typeof a == "function") {
2216
+ U = a, De();
2217
+ return;
2218
+ }
2219
+ if (Q(a)) {
2220
+ U = K(a, 1);
2221
+ let g = Math.abs(N - A);
2222
+ U > g && (U = void 0), De();
2223
+ return;
2224
+ }
2225
+ U = void 0;
2226
+ }, Gt = (a) => {
2227
+ H = a, De();
2228
+ }, Jt = (a) => {
2229
+ (!Q(a) || a < 0) && (a = 0), O = a;
2230
+ }, Zt = (a) => {
2231
+ (!Q(a) || a < 0) && (a = 1 / 0), G = a;
2232
+ }, Qt = (a) => {
2233
+ ne = a, c.classList.toggle("disabled", ne), ne ? c.setAttribute("aria-disabled", "true") : c.hasAttribute("aria-disabled") && c.removeAttribute("aria-disabled");
2234
+ }, Ks = (a) => {
2235
+ ye = a;
2236
+ }, qs = (a) => {
2237
+ be = a, be ? document.removeEventListener("wheel", vt) : document.addEventListener("wheel", vt, { passive: !1 });
2238
+ }, es = (a) => {
2239
+ if (a == null) {
2240
+ E = void 0;
2241
+ return;
2242
+ }
2243
+ if (E = Hi(a), E === void 0 || E.length <= 0) {
2244
+ E = void 0;
2245
+ return;
2246
+ }
2247
+ $t(0), _t(E.length - 1), U === void 0 && wt(1);
2248
+ }, ts = (a) => {
2249
+ var g;
2250
+ typeof a == "string" ? Y = a.trim().toLowerCase() === ue ? ue : we : Y = we;
2251
+ let S = (g = r.shadowRoot) == null ? void 0 : g.querySelector(".range-slider-box");
2252
+ if (!S)
2253
+ return;
2254
+ S.className = `range-slider-box type-${Y}`, De();
2255
+ let q = Y === ue ? "vertical" : "horizontal";
2256
+ for (let oe of p)
2257
+ oe.setAttr("aria-orientation", q);
2258
+ }, ss = (a) => {
2259
+ fe = a, p.length > 1 && Ds(p, fe, r), De(), Ue();
2260
+ }, is = (a) => {
2261
+ C = a, p.length > 1 && Ds(p, C, r), De(), Ue();
2262
+ }, rs = (a) => {
2263
+ Ae = K(a, Ge), Ae < 0 && (Ae = Ge), Ue();
2264
+ }, Xs = (a) => {
2265
+ a == null || a.toString().trim().toLowerCase() === "false" ? (Pe = void 0, c.style.removeProperty(ks), c.classList.remove(Xe)) : (Pe = a.toString(), c.style.setProperty(ks, Pe), c.classList.add(Xe));
2266
+ }, Gs = (a, g) => {
2267
+ let S = p[a];
2268
+ !S || (S.setAttr("aria-label", g), Rs[a] = g);
2269
+ }, At = (a) => {
2270
+ if (ae = void 0, p.length <= 1) {
2271
+ he = !1, c.classList.remove(Cs);
2272
+ return;
2273
+ }
2274
+ he = a, c.classList.toggle(Cs, he);
2275
+ }, Sr = () => {
2276
+ Qt(de(r.getAttribute(pe))), ye = de(r.getAttribute(Me)), be = de(r.getAttribute(me));
2277
+ let a = ft(r, /^pointer([0-9]*)-disabled$/, (g) => de(g));
2278
+ for (let g of a) {
2279
+ let S = g[0];
2280
+ !p[S] || (p[S].disabled = g[1]);
2281
+ }
2282
+ }, Er = () => {
2283
+ let a = ft(r, /^aria-label([0-9]*)$/);
2284
+ for (let g of a) {
2285
+ let S = g[0];
2286
+ Gs(S, g[1]);
2287
+ }
2288
+ }, kr = (a) => {
2289
+ let g = p.length, S = p[g - 1].$pointer, q = S.cloneNode(!0);
2290
+ S.after(q);
2291
+ let oe = Rt(r, q, g);
2292
+ return oe.setCallbacks(Ns, js, Hs, Us), p.push(oe), xt(a, g), De(), Ue(), g;
2293
+ }, Lr = () => {
2294
+ let a = p.length, g = p[a - 1];
2295
+ return g ? (g.destroy(), p.pop(), p.length <= 1 && At(!1), De(), Ue(), a - 1) : -1;
2296
+ };
2297
+ return (() => {
2298
+ var a, g;
2299
+ for (let q of p)
2300
+ q.setCallbacks(Ns, js, Hs, Us);
2301
+ let S = (a = r.shadowRoot) == null ? void 0 : a.querySelector(".panel-fill");
2302
+ S && (L = Fi(S)), ts(r.getAttribute(J)), ss(de(r.getAttribute(le))), is(de(r.getAttribute(ve))), Ar(r.getAttribute(v), r.getAttribute($)), wt(r.getAttribute(M)), es(r.getAttribute(m)), Ys(f.map((q) => q[1])), Gt(de(r.getAttribute(o))), Jt(K(r.getAttribute(h), 0)), Zt(K(r.getAttribute(u), 1 / 0)), At(de(r.getAttribute(d))), rs(K(r.getAttribute(j), Ge)), Sr(), Er(), I = lr(r, c, p), Xs((g = r.getAttribute(Ee)) != null ? g : Ts), c.addEventListener("mousedown", Ps), c.addEventListener("mouseup", gt), c.addEventListener("touchmove", He), c.addEventListener("touchstart", He), be || document.addEventListener("wheel", vt, { passive: !1 }), w = ar(r, yr, { setValues: Ys, setMin: $t, setMax: _t, setStep: wt, setPointersOverlap: Gt, setPointersMinDistance: Jt, setPointersMaxDistance: Zt, setDisabled: Qt, setType: ts, setRightToLeft: ss, setBottomToTop: is, setRound: rs, setKeyboardDisabled: Ks, setMousewheelDisabled: qs, setRangeDragging: At, setData: es }, { getPercents: Fs, getValues: Bs, getPointerElements: zs, getMin: Ws, getMax: Vs, getStep: Nt, getData: jt, getType: Ht, getRound: Ut, getTextMin: yt, getTextMax: bt, isRightToLeft: zt, isBottomToTop: Wt, isDisabled: Vt, isKeyboardDisabled: Yt, isMousewheelDisabled: Kt, isPointersOverlap: qt, isRangeDraggingEnabled: Xt, getPointersMinDistance: Ft, getPointersMaxDistance: Bt }), w.init();
2303
+ })(), { get pointers() {
2304
+ return p;
2305
+ }, get styles() {
2306
+ return I;
2307
+ }, get pluginsManager() {
2308
+ return w;
2309
+ }, get min() {
2310
+ return yt();
2311
+ }, get max() {
2312
+ return bt();
2313
+ }, get step() {
2314
+ return Nt();
2315
+ }, get pointersOverlap() {
2316
+ return qt();
2317
+ }, set pointersOverlap(a) {
2318
+ Gt(a);
2319
+ }, get pointersMinDistance() {
2320
+ return Ft();
2321
+ }, set pointersMinDistance(a) {
2322
+ Jt(a);
2323
+ }, get pointersMaxDistance() {
2324
+ return Bt();
2325
+ }, set pointersMaxDistance(a) {
2326
+ Zt(a);
2327
+ }, get disabled() {
2328
+ return Vt();
2329
+ }, set disabled(a) {
2330
+ Qt(a);
2331
+ }, get data() {
2332
+ return jt();
2333
+ }, get type() {
2334
+ return Ht();
2335
+ }, set type(a) {
2336
+ ts(a);
2337
+ }, get rightToLeft() {
2338
+ return zt();
2339
+ }, set rightToLeft(a) {
2340
+ ss(a);
2341
+ }, get bottomToTop() {
2342
+ return Wt();
2343
+ }, set bottomToTop(a) {
2344
+ is(a);
2345
+ }, get round() {
2346
+ return Ut();
2347
+ }, set round(a) {
2348
+ rs(a);
2349
+ }, get animateOnClick() {
2350
+ return Pe;
2351
+ }, set animateOnClick(a) {
2352
+ Xs(a);
2353
+ }, get keyboardDisabled() {
2354
+ return Yt();
2355
+ }, set keyboardDisabled(a) {
2356
+ Ks(a);
2357
+ }, get mousewheelDisabled() {
2358
+ return Kt();
2359
+ }, set mousewheelDisabled(a) {
2360
+ qs(a);
2361
+ }, get rangeDragging() {
2362
+ return Xt();
2363
+ }, set rangeDragging(a) {
2364
+ At(a);
2365
+ }, setMin: $t, setMax: _t, setValue: xt, setStep: wt, setData: es, getTextValue: Je, setAriaLabel: Gs, getAriaLabel: wr, addPointer: kr, removePointer: Lr, destroy: () => {
2366
+ c.removeEventListener("mousedown", Ps), c.removeEventListener("mouseup", gt), c.removeEventListener("touchmove", He), c.removeEventListener("touchstart", He), document.removeEventListener("wheel", vt);
2367
+ for (let a of p)
2368
+ a.destroy();
2369
+ w == null || w.destroy();
2370
+ } };
2371
+ }, pr = (r, c, f) => {
2372
+ let p = Ls.find(([w, A, N, U]) => A.replace("#", "") === c.replace(/\d+/g, ""));
2373
+ if (p && r.styles) {
2374
+ let [w, A, N, U] = p, E = c.replace(/\D/g, "").trim(), Y = E === "" || E === "0" || E === "1" ? 0 : K(E, 0) - 1;
2375
+ r.styles.setStyle(w, f, Y);
2376
+ return;
2377
+ }
2378
+ switch (r && r.pluginsManager && r.pluginsManager.onAttrChange(c, f), c) {
2379
+ case v: {
2380
+ r.setMin(f);
2381
+ break;
2382
+ }
2383
+ case $: {
2384
+ r.setMax(f);
2385
+ break;
2386
+ }
2387
+ case M: {
2388
+ r.setStep(f);
2389
+ break;
2390
+ }
2391
+ case o: {
2392
+ r.pointersOverlap = de(f);
2393
+ break;
2394
+ }
2395
+ case h: {
2396
+ r.pointersMinDistance = K(f, 0);
2397
+ break;
2398
+ }
2399
+ case d: {
2400
+ r.rangeDragging = de(f);
2401
+ break;
2402
+ }
2403
+ case u: {
2404
+ r.pointersMaxDistance = K(f, 1 / 0);
2405
+ break;
2406
+ }
2407
+ case pe: {
2408
+ r.disabled = de(f);
2409
+ break;
2410
+ }
2411
+ case Me: {
2412
+ r.keyboardDisabled = de(f);
2413
+ break;
2414
+ }
2415
+ case me: {
2416
+ r.mousewheelDisabled = de(f);
2417
+ break;
2418
+ }
2419
+ case m: {
2420
+ r.setData(f);
2421
+ break;
2422
+ }
2423
+ case J: {
2424
+ r.type = f;
2425
+ break;
2426
+ }
2427
+ case le: {
2428
+ r.rightToLeft = de(f);
2429
+ break;
2430
+ }
2431
+ case ve: {
2432
+ r.bottomToTop = de(f);
2433
+ break;
2434
+ }
2435
+ case j: {
2436
+ r.round = K(f, Ge);
2437
+ break;
2438
+ }
2439
+ case ge: {
2440
+ r.styles && (r.styles.theme = f);
2441
+ break;
2442
+ }
2443
+ case Ee: {
2444
+ r.animateOnClick = f;
2445
+ break;
2446
+ }
2447
+ }
2448
+ let x = null;
2449
+ if (/^value([0-9]*)$/.test(c) && (x = "value"), /^pointer([0-9]*)-disabled$/.test(c) && (x = "pointer-disabled"), /^aria-label([0-9]*)$/.test(c) && (x = "aria-label"), /^pointer([0-9]*)-shape$/.test(c) && (x = "pointer-shape"), !x)
2450
+ return;
2451
+ let L = c.replace(/\D/g, "").trim(), I = L === "" || L === "0" || L === "1" ? 0 : K(L, 0) - 1;
2452
+ switch (x) {
2453
+ case "value": {
2454
+ r.setValue(f, I);
2455
+ break;
2456
+ }
2457
+ case "pointer-disabled": {
2458
+ let w = r == null ? void 0 : r.pointers[I];
2459
+ if (!w)
2460
+ return;
2461
+ w.disabled = de(f);
2462
+ break;
2463
+ }
2464
+ case "aria-label": {
2465
+ r.setAriaLabel(I, f);
2466
+ break;
2467
+ }
2468
+ case "pointer-shape": {
2469
+ r.styles && r.styles.setPointerShape(I, f);
2470
+ break;
2471
+ }
2472
+ }
2473
+ }, fr = class extends HTMLElement {
2474
+ constructor() {
2475
+ super(), s(this, "slider"), s(this, "_externalCSSList", []), s(this, "_observer", null), this.attachShadow({ mode: "open" });
2476
+ }
2477
+ set step(r) {
2478
+ this.slider && this.slider.setStep(r);
2479
+ }
2480
+ get step() {
2481
+ var r;
2482
+ return (r = this.slider) == null ? void 0 : r.step;
2483
+ }
2484
+ set disabled(r) {
2485
+ this.slider && (this.slider.disabled = r);
2486
+ }
2487
+ get disabled() {
2488
+ var r, c;
2489
+ return (c = (r = this.slider) == null ? void 0 : r.disabled) != null ? c : !1;
2490
+ }
2491
+ set data(r) {
2492
+ var c;
2493
+ (c = this.slider) == null || c.setData(r);
2494
+ }
2495
+ get data() {
2496
+ var r;
2497
+ return (r = this.slider) == null ? void 0 : r.data;
2498
+ }
2499
+ set min(r) {
2500
+ var c;
2501
+ (c = this.slider) == null || c.setMin(r);
2502
+ }
2503
+ get min() {
2504
+ var r;
2505
+ return (r = this.slider) == null ? void 0 : r.min;
2506
+ }
2507
+ set max(r) {
2508
+ var c;
2509
+ (c = this.slider) == null || c.setMax(r);
2510
+ }
2511
+ get max() {
2512
+ var r;
2513
+ return (r = this.slider) == null ? void 0 : r.max;
2514
+ }
2515
+ set round(r) {
2516
+ !this.slider || (this.slider.round = r);
2517
+ }
2518
+ get round() {
2519
+ var r, c;
2520
+ return (c = (r = this.slider) == null ? void 0 : r.round) != null ? c : Ge;
2521
+ }
2522
+ set type(r) {
2523
+ !this.slider || (this.slider.type = r ?? we);
2524
+ }
2525
+ get type() {
2526
+ var r;
2527
+ return ((r = this.slider) == null ? void 0 : r.type) || we;
2528
+ }
2529
+ set pointersOverlap(r) {
2530
+ !this.slider || (this.slider.pointersOverlap = r);
2531
+ }
2532
+ get pointersOverlap() {
2533
+ var r, c;
2534
+ return (c = (r = this.slider) == null ? void 0 : r.pointersOverlap) != null ? c : !1;
2535
+ }
2536
+ set pointersMinDistance(r) {
2537
+ !this.slider || (this.slider.pointersMinDistance = r);
2538
+ }
2539
+ get pointersMinDistance() {
2540
+ var r, c;
2541
+ return (c = (r = this.slider) == null ? void 0 : r.pointersMinDistance) != null ? c : 0;
2542
+ }
2543
+ set pointersMaxDistance(r) {
2544
+ !this.slider || (this.slider.pointersMaxDistance = r);
2545
+ }
2546
+ get pointersMaxDistance() {
2547
+ var r, c;
2548
+ return (c = (r = this.slider) == null ? void 0 : r.pointersMaxDistance) != null ? c : 1 / 0;
2549
+ }
2550
+ set theme(r) {
2551
+ !this.slider || !this.slider.styles || (this.slider.styles.theme = r);
2552
+ }
2553
+ get theme() {
2554
+ var r, c, f;
2555
+ return (f = (c = (r = this.slider) == null ? void 0 : r.styles) == null ? void 0 : c.theme) != null ? f : null;
2556
+ }
2557
+ set rtl(r) {
2558
+ !this.slider || (this.slider.rightToLeft = r);
2559
+ }
2560
+ get rtl() {
2561
+ var r, c;
2562
+ return (c = (r = this.slider) == null ? void 0 : r.rightToLeft) != null ? c : !1;
2563
+ }
2564
+ set btt(r) {
2565
+ !this.slider || (this.slider.bottomToTop = r);
2566
+ }
2567
+ get btt() {
2568
+ var r, c;
2569
+ return (c = (r = this.slider) == null ? void 0 : r.bottomToTop) != null ? c : !1;
2570
+ }
2571
+ set keyboardDisabled(r) {
2572
+ !this.slider || (this.slider.keyboardDisabled = r);
2573
+ }
2574
+ get keyboardDisabled() {
2575
+ var r, c;
2576
+ return (c = (r = this.slider) == null ? void 0 : r.keyboardDisabled) != null ? c : !1;
2577
+ }
2578
+ set mousewheelDisabled(r) {
2579
+ !this.slider || (this.slider.mousewheelDisabled = r);
2580
+ }
2581
+ get mousewheelDisabled() {
2582
+ var r, c;
2583
+ return (c = (r = this.slider) == null ? void 0 : r.mousewheelDisabled) != null ? c : !1;
2584
+ }
2585
+ set animateOnClick(r) {
2586
+ !this.slider || (this.slider.animateOnClick = r);
2587
+ }
2588
+ get animateOnClick() {
2589
+ var r;
2590
+ return (r = this.slider) == null ? void 0 : r.animateOnClick;
2591
+ }
2592
+ get rangeDragging() {
2593
+ var r, c;
2594
+ return (c = (r = this.slider) == null ? void 0 : r.rangeDragging) != null ? c : !1;
2595
+ }
2596
+ set rangeDragging(r) {
2597
+ this.slider && (this.slider.rangeDragging = de(r));
2598
+ }
2599
+ get externalCSSList() {
2600
+ return this._externalCSSList;
2601
+ }
2602
+ addPointer(r) {
2603
+ var c;
2604
+ if (!this.slider)
2605
+ return;
2606
+ let f = (c = this.slider) == null ? void 0 : c.addPointer(r);
2607
+ Os(this, this.slider, f, `value${f + 1}`, `ariaLabel${f + 1}`, `pointerShape${f + 1}`, `pointer${f + 1}Disabled`);
2608
+ }
2609
+ removePointer() {
2610
+ var r;
2611
+ !this.slider || (r = this.slider) == null || r.removePointer();
2612
+ }
2613
+ addCSS(r) {
2614
+ if (!this.shadowRoot)
2615
+ return;
2616
+ let c = document.createElement("style");
2617
+ c.textContent = r, this.shadowRoot.appendChild(c);
2618
+ }
2619
+ connectedCallback() {
2620
+ var r, c;
2621
+ if (!this.shadowRoot)
2622
+ return;
2623
+ this._externalCSSList = or(this), this.shadowRoot.innerHTML = n(l, this._externalCSSList);
2624
+ let f = (r = this.shadowRoot) == null ? void 0 : r.querySelector(".pointer");
2625
+ if (!f)
2626
+ return;
2627
+ let p = (c = this.shadowRoot) == null ? void 0 : c.getElementById("range-slider");
2628
+ if (!p)
2629
+ return;
2630
+ let x = hr(this, f);
2631
+ this.slider = dr(this, p, x), ur(this, this.slider), this._observer = new MutationObserver((L) => {
2632
+ L.forEach((I) => {
2633
+ var w;
2634
+ if (!this.slider || I.type !== "attributes")
2635
+ return;
2636
+ let A = I.attributeName;
2637
+ !A || pr(this.slider, A, (w = this.getAttribute(A)) != null ? w : "");
2638
+ });
2639
+ }), this._observer.observe(this, { attributes: !0 });
2640
+ }
2641
+ disconnectedCallback() {
2642
+ this._observer && this._observer.disconnect(), this.slider && this.slider.destroy();
2643
+ }
2644
+ }, It = fr;
2645
+ window.tcRangeSlider = It, customElements.get("toolcool-range-slider") || customElements.define("toolcool-range-slider", It), customElements.get("tc-range-slider") || customElements.define("tc-range-slider", class extends It {
2646
+ });
2647
+ })();
2648
+ var Ti = { exports: {} };
2649
+ (function(i, e) {
2650
+ (function(t, s) {
2651
+ i.exports = s();
2652
+ })(at, function() {
2653
+ var t = 1e3, s = 6e4, n = 36e5, l = "millisecond", o = "second", h = "minute", u = "hour", d = "day", m = "week", v = "month", $ = "quarter", M = "year", j = "date", J = "Invalid Date", ge = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, le = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, ve = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(D) {
2654
+ var y = ["th", "st", "nd", "rd"], b = D % 100;
2655
+ return "[" + D + (y[(b - 20) % 10] || y[b] || y[0]) + "]";
2656
+ } }, pe = function(D, y, b) {
2657
+ var k = String(D);
2658
+ return !k || k.length >= y ? D : "" + Array(y + 1 - k.length).join(b) + D;
2659
+ }, Me = { s: pe, z: function(D) {
2660
+ var y = -D.utcOffset(), b = Math.abs(y), k = Math.floor(b / 60), _ = b % 60;
2661
+ return (y <= 0 ? "+" : "-") + pe(k, 2, "0") + ":" + pe(_, 2, "0");
2662
+ }, m: function D(y, b) {
2663
+ if (y.date() < b.date())
2664
+ return -D(b, y);
2665
+ var k = 12 * (b.year() - y.year()) + (b.month() - y.month()), _ = y.clone().add(k, v), P = b - _ < 0, R = y.clone().add(k + (P ? -1 : 1), v);
2666
+ return +(-(k + (b - _) / (P ? _ - R : R - _)) || 0);
2667
+ }, a: function(D) {
2668
+ return D < 0 ? Math.ceil(D) || 0 : Math.floor(D);
2669
+ }, p: function(D) {
2670
+ return { M: v, y: M, w: m, d, D: j, h: u, m: h, s: o, ms: l, Q: $ }[D] || String(D || "").toLowerCase().replace(/s$/, "");
2671
+ }, u: function(D) {
2672
+ return D === void 0;
2673
+ } }, me = "en", F = {};
2674
+ F[me] = ve;
2675
+ var X = function(D) {
2676
+ return D instanceof Ce;
2677
+ }, ie = function D(y, b, k) {
2678
+ var _;
2679
+ if (!y)
2680
+ return me;
2681
+ if (typeof y == "string") {
2682
+ var P = y.toLowerCase();
2683
+ F[P] && (_ = P), b && (F[P] = b, _ = P);
2684
+ var R = y.split("-");
2685
+ if (!_ && R.length > 1)
2686
+ return D(R[0]);
2687
+ } else {
2688
+ var V = y.name;
2689
+ F[V] = y, _ = V;
2690
+ }
2691
+ return !k && _ && (me = _), _ || !k && me;
2692
+ }, z = function(D, y) {
2693
+ if (X(D))
2694
+ return D.clone();
2695
+ var b = typeof y == "object" ? y : {};
2696
+ return b.date = D, b.args = arguments, new Ce(b);
2697
+ }, B = Me;
2698
+ B.l = ie, B.i = X, B.w = function(D, y) {
2699
+ return z(D, { locale: y.$L, utc: y.$u, x: y.$x, $offset: y.$offset });
2700
+ };
2701
+ var Ce = function() {
2702
+ function D(b) {
2703
+ this.$L = ie(b.locale, null, !0), this.parse(b);
2704
+ }
2705
+ var y = D.prototype;
2706
+ return y.parse = function(b) {
2707
+ this.$d = function(k) {
2708
+ var _ = k.date, P = k.utc;
2709
+ if (_ === null)
2710
+ return /* @__PURE__ */ new Date(NaN);
2711
+ if (B.u(_))
2712
+ return /* @__PURE__ */ new Date();
2713
+ if (_ instanceof Date)
2714
+ return new Date(_);
2715
+ if (typeof _ == "string" && !/Z$/i.test(_)) {
2716
+ var R = _.match(ge);
2717
+ if (R) {
2718
+ var V = R[2] - 1 || 0, se = (R[7] || "0").substring(0, 3);
2719
+ return P ? new Date(Date.UTC(R[1], V, R[3] || 1, R[4] || 0, R[5] || 0, R[6] || 0, se)) : new Date(R[1], V, R[3] || 1, R[4] || 0, R[5] || 0, R[6] || 0, se);
2720
+ }
2721
+ }
2722
+ return new Date(_);
2723
+ }(b), this.$x = b.x || {}, this.init();
2724
+ }, y.init = function() {
2725
+ var b = this.$d;
2726
+ this.$y = b.getFullYear(), this.$M = b.getMonth(), this.$D = b.getDate(), this.$W = b.getDay(), this.$H = b.getHours(), this.$m = b.getMinutes(), this.$s = b.getSeconds(), this.$ms = b.getMilliseconds();
2727
+ }, y.$utils = function() {
2728
+ return B;
2729
+ }, y.isValid = function() {
2730
+ return this.$d.toString() !== J;
2731
+ }, y.isSame = function(b, k) {
2732
+ var _ = z(b);
2733
+ return this.startOf(k) <= _ && _ <= this.endOf(k);
2734
+ }, y.isAfter = function(b, k) {
2735
+ return z(b) < this.startOf(k);
2736
+ }, y.isBefore = function(b, k) {
2737
+ return this.endOf(k) < z(b);
2738
+ }, y.$g = function(b, k, _) {
2739
+ return B.u(b) ? this[k] : this.set(_, b);
2740
+ }, y.unix = function() {
2741
+ return Math.floor(this.valueOf() / 1e3);
2742
+ }, y.valueOf = function() {
2743
+ return this.$d.getTime();
2744
+ }, y.startOf = function(b, k) {
2745
+ var _ = this, P = !!B.u(k) || k, R = B.p(b), V = function(Oe, Q) {
2746
+ var K = B.w(_.$u ? Date.UTC(_.$y, Q, Oe) : new Date(_.$y, Q, Oe), _);
2747
+ return P ? K : K.endOf(d);
2748
+ }, se = function(Oe, Q) {
2749
+ return B.w(_.toDate()[Oe].apply(_.toDate("s"), (P ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(Q)), _);
2750
+ }, Z = this.$W, ce = this.$M, Ee = this.$D, ke = "set" + (this.$u ? "UTC" : "");
2751
+ switch (R) {
2752
+ case M:
2753
+ return P ? V(1, 0) : V(31, 11);
2754
+ case v:
2755
+ return P ? V(1, ce) : V(0, ce + 1);
2756
+ case m:
2757
+ var ue = this.$locale().weekStart || 0, we = (Z < ue ? Z + 7 : Z) - ue;
2758
+ return V(P ? Ee - we : Ee + (6 - we), ce);
2759
+ case d:
2760
+ case j:
2761
+ return se(ke + "Hours", 0);
2762
+ case u:
2763
+ return se(ke + "Minutes", 1);
2764
+ case h:
2765
+ return se(ke + "Seconds", 2);
2766
+ case o:
2767
+ return se(ke + "Milliseconds", 3);
2768
+ default:
2769
+ return this.clone();
2770
+ }
2771
+ }, y.endOf = function(b) {
2772
+ return this.startOf(b, !1);
2773
+ }, y.$set = function(b, k) {
2774
+ var _, P = B.p(b), R = "set" + (this.$u ? "UTC" : ""), V = (_ = {}, _[d] = R + "Date", _[j] = R + "Date", _[v] = R + "Month", _[M] = R + "FullYear", _[u] = R + "Hours", _[h] = R + "Minutes", _[o] = R + "Seconds", _[l] = R + "Milliseconds", _)[P], se = P === d ? this.$D + (k - this.$W) : k;
2775
+ if (P === v || P === M) {
2776
+ var Z = this.clone().set(j, 1);
2777
+ Z.$d[V](se), Z.init(), this.$d = Z.set(j, Math.min(this.$D, Z.daysInMonth())).$d;
2778
+ } else
2779
+ V && this.$d[V](se);
2780
+ return this.init(), this;
2781
+ }, y.set = function(b, k) {
2782
+ return this.clone().$set(b, k);
2783
+ }, y.get = function(b) {
2784
+ return this[B.p(b)]();
2785
+ }, y.add = function(b, k) {
2786
+ var _, P = this;
2787
+ b = Number(b);
2788
+ var R = B.p(k), V = function(ce) {
2789
+ var Ee = z(P);
2790
+ return B.w(Ee.date(Ee.date() + Math.round(ce * b)), P);
2791
+ };
2792
+ if (R === v)
2793
+ return this.set(v, this.$M + b);
2794
+ if (R === M)
2795
+ return this.set(M, this.$y + b);
2796
+ if (R === d)
2797
+ return V(1);
2798
+ if (R === m)
2799
+ return V(7);
2800
+ var se = (_ = {}, _[h] = s, _[u] = n, _[o] = t, _)[R] || 1, Z = this.$d.getTime() + b * se;
2801
+ return B.w(Z, this);
2802
+ }, y.subtract = function(b, k) {
2803
+ return this.add(-1 * b, k);
2804
+ }, y.format = function(b) {
2805
+ var k = this, _ = this.$locale();
2806
+ if (!this.isValid())
2807
+ return _.invalidDate || J;
2808
+ var P = b || "YYYY-MM-DDTHH:mm:ssZ", R = B.z(this), V = this.$H, se = this.$m, Z = this.$M, ce = _.weekdays, Ee = _.months, ke = function(Q, K, Ke, qe) {
2809
+ return Q && (Q[K] || Q(k, P)) || Ke[K].slice(0, qe);
2810
+ }, ue = function(Q) {
2811
+ return B.s(V % 12 || 12, Q, "0");
2812
+ }, we = _.meridiem || function(Q, K, Ke) {
2813
+ var qe = Q < 12 ? "AM" : "PM";
2814
+ return Ke ? qe.toLowerCase() : qe;
2815
+ }, Oe = { YY: String(this.$y).slice(-2), YYYY: B.s(this.$y, 4, "0"), M: Z + 1, MM: B.s(Z + 1, 2, "0"), MMM: ke(_.monthsShort, Z, Ee, 3), MMMM: ke(Ee, Z), D: this.$D, DD: B.s(this.$D, 2, "0"), d: String(this.$W), dd: ke(_.weekdaysMin, this.$W, ce, 2), ddd: ke(_.weekdaysShort, this.$W, ce, 3), dddd: ce[this.$W], H: String(V), HH: B.s(V, 2, "0"), h: ue(1), hh: ue(2), a: we(V, se, !0), A: we(V, se, !1), m: String(se), mm: B.s(se, 2, "0"), s: String(this.$s), ss: B.s(this.$s, 2, "0"), SSS: B.s(this.$ms, 3, "0"), Z: R };
2816
+ return P.replace(le, function(Q, K) {
2817
+ return K || Oe[Q] || R.replace(":", "");
2818
+ });
2819
+ }, y.utcOffset = function() {
2820
+ return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
2821
+ }, y.diff = function(b, k, _) {
2822
+ var P, R = B.p(k), V = z(b), se = (V.utcOffset() - this.utcOffset()) * s, Z = this - V, ce = B.m(this, V);
2823
+ return ce = (P = {}, P[M] = ce / 12, P[v] = ce, P[$] = ce / 3, P[m] = (Z - se) / 6048e5, P[d] = (Z - se) / 864e5, P[u] = Z / n, P[h] = Z / s, P[o] = Z / t, P)[R] || Z, _ ? ce : B.a(ce);
2824
+ }, y.daysInMonth = function() {
2825
+ return this.endOf(v).$D;
2826
+ }, y.$locale = function() {
2827
+ return F[this.$L];
2828
+ }, y.locale = function(b, k) {
2829
+ if (!b)
2830
+ return this.$L;
2831
+ var _ = this.clone(), P = ie(b, k, !0);
2832
+ return P && (_.$L = P), _;
2833
+ }, y.clone = function() {
2834
+ return B.w(this.$d, this);
2835
+ }, y.toDate = function() {
2836
+ return new Date(this.valueOf());
2837
+ }, y.toJSON = function() {
2838
+ return this.isValid() ? this.toISOString() : null;
2839
+ }, y.toISOString = function() {
2840
+ return this.$d.toISOString();
2841
+ }, y.toString = function() {
2842
+ return this.$d.toUTCString();
2843
+ }, D;
2844
+ }(), Se = Ce.prototype;
2845
+ return z.prototype = Se, [["$ms", l], ["$s", o], ["$m", h], ["$H", u], ["$W", d], ["$M", v], ["$y", M], ["$D", j]].forEach(function(D) {
2846
+ Se[D[1]] = function(y) {
2847
+ return this.$g(y, D[0], D[1]);
2848
+ };
2849
+ }), z.extend = function(D, y) {
2850
+ return D.$i || (D(y, Ce, z), D.$i = !0), z;
2851
+ }, z.locale = ie, z.isDayjs = X, z.unix = function(D) {
2852
+ return z(1e3 * D);
2853
+ }, z.en = F[me], z.Ls = F, z.p = {}, z;
2854
+ });
2855
+ })(Ti);
2856
+ var no = Ti.exports;
2857
+ const Et = /* @__PURE__ */ Di(no), oo = (i, e = "highlight", t = "title") => {
2858
+ const s = (l, o, h) => {
2859
+ const u = o.split(".");
2860
+ let d;
2861
+ for (d = 0; d < u.length - 1; d++)
2862
+ l = l[u[d]];
2863
+ l[u[d]] = h;
2864
+ }, n = (l, o = []) => {
2865
+ let h = "", u = 0;
2866
+ return o.forEach((d) => {
2867
+ const m = d[1] + 1;
2868
+ h += [
2869
+ l.substring(u, d[0]),
2870
+ `<mark class="${e}">`,
2871
+ l.substring(d[0], m),
1771
2872
  "</mark>"
1772
- ].join(""), l = u;
1773
- }), c += r.substring(l), c;
2873
+ ].join(""), u = m;
2874
+ }), h += l.substring(u), h;
1774
2875
  };
1775
- return i.filter(({ matches: r }) => r && r.length).map(({ item: r, matches: o }) => {
1776
- const c = { ...r };
1777
- return o.forEach((l) => {
1778
- l.key === e && s(
1779
- c,
1780
- l.key,
1781
- n(l.value, l.indices)
2876
+ return i.filter(({ matches: l }) => l && l.length).map(({ item: l, matches: o }) => {
2877
+ const h = { ...l };
2878
+ return o.forEach((u) => {
2879
+ u.key === t && s(
2880
+ h,
2881
+ u.key,
2882
+ n(u.value, u.indices)
1782
2883
  );
1783
- }), c;
2884
+ }), h;
1784
2885
  });
1785
- }, Ks = `
2886
+ }, lo = `
1786
2887
  :host {
1787
2888
  display: flex;
1788
2889
  box-sizing: border-box;
@@ -1927,92 +3028,92 @@ section.inline details.details-filter summary {
1927
3028
  overflow-y: auto;
1928
3029
  }
1929
3030
  `;
1930
- var Gs = Object.defineProperty, Ys = Object.getOwnPropertyDescriptor, F = (i, t, e, s) => {
1931
- for (var n = s > 1 ? void 0 : s ? Ys(t, e) : t, r = i.length - 1, o; r >= 0; r--)
1932
- (o = i[r]) && (n = (s ? o(t, e, n) : o(n)) || n);
1933
- return s && n && Gs(t, e, n), n;
3031
+ var ao = Object.defineProperty, co = Object.getOwnPropertyDescriptor, Ye = (i, e, t, s) => {
3032
+ for (var n = s > 1 ? void 0 : s ? co(e, t) : e, l = i.length - 1, o; l >= 0; l--)
3033
+ (o = i[l]) && (n = (s ? o(e, t, n) : o(n)) || n);
3034
+ return s && n && ao(e, t, n), n;
1934
3035
  };
1935
- class se {
3036
+ class mi {
1936
3037
  constructor() {
1937
3038
  /**
1938
3039
  * Aggregate results by a property key
1939
3040
  */
1940
- m(this, "aggregateResults");
3041
+ ee(this, "aggregateResults");
1941
3042
  /**
1942
3043
  * Highlighting of search result character matches
1943
3044
  */
1944
- m(this, "enableHighlighting", !1);
3045
+ ee(this, "enableHighlighting", !1);
1945
3046
  /**
1946
3047
  * Search functionality
1947
3048
  */
1948
- m(this, "enableSearch", !1);
3049
+ ee(this, "enableSearch", !1);
1949
3050
  /**
1950
3051
  * Make the filters mutually exclusive
1951
3052
  */
1952
- m(this, "exclusiveFilters", !1);
3053
+ ee(this, "exclusiveFilters", !1);
1953
3054
  /**
1954
3055
  * Use an external search endpoint instead of fuse search.
1955
3056
  * Passed properties: input string, filters object
1956
3057
  */
1957
- m(this, "externalSearch");
3058
+ ee(this, "externalSearch");
1958
3059
  /**
1959
3060
  * The filter properties.
1960
3061
  * @param filterProperties
1961
3062
  */
1962
- m(this, "filterProperties", []);
3063
+ ee(this, "filterProperties", []);
1963
3064
  /**
1964
3065
  * Native fuse.js config override
1965
3066
  */
1966
- m(this, "fuseConfig", {
3067
+ ee(this, "fuseConfig", {
1967
3068
  keys: ["title"]
1968
3069
  });
1969
3070
  /**
1970
3071
  * Inline mode, for rendering the itemfilter in avery condensed space.
1971
3072
  * Expexts showResults to be false and enableSearch to be true
1972
3073
  */
1973
- m(this, "inlineMode", !1);
3074
+ ee(this, "inlineMode", !1);
1974
3075
  /**
1975
3076
  * Show all result items if nothing is input by the user
1976
3077
  * @default true
1977
3078
  */
1978
- m(this, "matchAllWhenEmpty", !0);
3079
+ ee(this, "matchAllWhenEmpty", !0);
1979
3080
  /**
1980
3081
  * Callback that is triggered on item search
1981
3082
  * @returns result items
1982
3083
  */
1983
- m(this, "onSearch", () => {
3084
+ ee(this, "onSearch", () => {
1984
3085
  });
1985
3086
  /**
1986
3087
  * Callback that is triggered on item selection
1987
3088
  * @returns selected item
1988
3089
  */
1989
- m(this, "onSelect", () => {
3090
+ ee(this, "onSelect", () => {
1990
3091
  });
1991
3092
  /**
1992
3093
  * Display results list
1993
3094
  */
1994
- m(this, "showResults", !0);
3095
+ ee(this, "showResults", !0);
1995
3096
  /**
1996
3097
  * The property of the result items used for display
1997
3098
  */
1998
- m(this, "titleProperty", "title");
3099
+ ee(this, "titleProperty", "title");
1999
3100
  }
2000
3101
  }
2001
- let T = class extends Q {
3102
+ let Ne = class extends ct {
2002
3103
  constructor() {
2003
3104
  super(...arguments);
2004
- m(this, "_fuse");
2005
- m(this, "_resultAggregation", []);
2006
- m(this, "_items", []);
2007
- m(this, "_results");
2008
- m(this, "_filters", {});
2009
- m(this, "_selectedResult");
2010
- m(this, "_config", new se());
2011
- m(this, "apply", (t) => {
2012
- this._items = t.map((e, s) => ({
2013
- ...e,
2014
- id: `item-${s}`
2015
- })), this._fuse = new K(this._items, {
3105
+ ee(this, "_fuse");
3106
+ ee(this, "_resultAggregation", []);
3107
+ ee(this, "_items", []);
3108
+ ee(this, "_results");
3109
+ ee(this, "_filters", {});
3110
+ ee(this, "_selectedResult");
3111
+ ee(this, "_config", new mi());
3112
+ ee(this, "apply", (e) => {
3113
+ this._items = e.map((t, s) => ({
3114
+ id: `item-${s}`,
3115
+ ...t
3116
+ })), this._fuse = new tt(this._items, {
2016
3117
  // minMatchCharLength: 3,
2017
3118
  // location: 0,
2018
3119
  threshold: 0.4,
@@ -2020,110 +3121,168 @@ let T = class extends Q {
2020
3121
  includeMatches: !0,
2021
3122
  useExtendedSearch: !0,
2022
3123
  ...this._config.fuseConfig
2023
- }), this._config.filterProperties.length && this._config.filterProperties.forEach((e) => {
2024
- const s = {};
2025
- this._items.forEach((n) => {
2026
- Array.isArray(n[e.key]) ? n[e.key].forEach((r) => {
2027
- s[r] = void 0;
2028
- }) : s[n[e.key]] = void 0;
2029
- }), this._filters[e.key] = s;
3124
+ }), this._config.filterProperties.length && this._config.filterProperties.forEach((t) => {
3125
+ const s = {}, n = (l) => t.format === "date" ? Et(l).unix() : parseInt(l);
3126
+ this._items.forEach((l) => {
3127
+ if (t.type === "range") {
3128
+ if (Array.isArray(l[t.key])) {
3129
+ const o = [
3130
+ // @ts-ignore
3131
+ n(l[t.key][0]),
3132
+ // @ts-ignore
3133
+ n(l[t.key][1])
3134
+ ];
3135
+ s.min = // @ts-ignore
3136
+ s.min !== void 0 ? (
3137
+ // @ts-ignore
3138
+ Math.min(s.min, o[0])
3139
+ ) : o[0], s.max = // @ts-ignore
3140
+ s.max !== void 0 ? (
3141
+ // @ts-ignore
3142
+ Math.max(s.max, o[1])
3143
+ ) : o[1];
3144
+ } else {
3145
+ const o = n(l[t.key]);
3146
+ s.min = // @ts-ignore
3147
+ s.min !== void 0 ? (
3148
+ // @ts-ignore
3149
+ Math.min(s.min, o)
3150
+ ) : o, s.max = // @ts-ignore
3151
+ s.max !== void 0 ? (
3152
+ // @ts-ignore
3153
+ Math.max(s.max, o)
3154
+ ) : o;
3155
+ }
3156
+ return;
3157
+ }
3158
+ Array.isArray(l[t.key]) ? l[t.key].forEach((o) => {
3159
+ s[o] = void 0;
3160
+ }) : s[l[t.key]] = void 0;
3161
+ }), this._filters[t.key] = {
3162
+ type: t.type || "string",
3163
+ keys: s,
3164
+ ...t.type === "range" && {
3165
+ // @ts-ignore
3166
+ min: s.min,
3167
+ // @ts-ignore
3168
+ max: s.max,
3169
+ format: t.format
3170
+ }
3171
+ };
2030
3172
  }), this._config.matchAllWhenEmpty !== !1 && (this._results = this.sortResults(this._items), this.requestUpdate()), this._config.aggregateResults && (this._resultAggregation = [
2031
3173
  ...new Set(
2032
- this._items.reduce((e, s) => e.concat(s[this._config.aggregateResults]), [])
3174
+ this._items.reduce((t, s) => t.concat(s[this._config.aggregateResults]), [])
2033
3175
  )
2034
- ].sort((e, s) => e.localeCompare(s)));
3176
+ ].sort((t, s) => t.localeCompare(s)));
2035
3177
  });
2036
- m(this, "inputHandler", () => {
3178
+ ee(this, "inputHandler", () => {
2037
3179
  this.search(this.renderRoot.querySelector("input[type='text']").value);
2038
3180
  });
2039
- m(this, "debouncedInputHandler", Ws(this.inputHandler, 500, {
3181
+ ee(this, "debouncedInputHandler", ro(this.inputHandler, 500, {
2040
3182
  leading: !0
2041
3183
  }));
2042
3184
  }
2043
- set config(t) {
2044
- const e = this._config;
3185
+ set config(e) {
3186
+ const t = this._config;
2045
3187
  this._config = {
2046
- ...new se(),
2047
- ...t
2048
- }, this.requestUpdate("config", e);
3188
+ ...new mi(),
3189
+ ...e
3190
+ }, this.requestUpdate("config", t);
2049
3191
  }
2050
3192
  get config() {
2051
3193
  return this._config;
2052
3194
  }
2053
- async search(t = "", e = this._filters) {
2054
- const s = Object.entries(e).reduce(
2055
- (r, [o, c]) => {
2056
- const l = "$or", a = [], u = (h) => {
2057
- const d = {};
2058
- d[o] = `="${h}"`, a.push(d);
2059
- };
2060
- return Object.entries(c).filter(([h, d]) => d).forEach(([h, d]) => u(h)), a.length > 0 && r.push({
2061
- [l]: a
2062
- }), r;
2063
- },
2064
- []
2065
- );
3195
+ async search(e = "", t = this._filters) {
3196
+ const s = Object.entries(t).filter(([o, h]) => h.type === "string").reduce((o, [h, u]) => {
3197
+ const d = "$or", m = [], v = ($) => {
3198
+ const M = {};
3199
+ M[h] = `="${$}"`, m.push(M);
3200
+ };
3201
+ return Object.entries(u.keys).filter(([$, M]) => M).forEach(([$, M]) => v($)), m.length > 0 && o.push({
3202
+ [d]: m
3203
+ }), o;
3204
+ }, []);
2066
3205
  let n;
2067
- if (!(t.length > 0) && !s.length && this._config.matchAllWhenEmpty !== !1)
3206
+ if (!(e.length > 0) && !s.length && this._config.matchAllWhenEmpty !== !1)
2068
3207
  n = this._items;
2069
3208
  else if (this.config.externalSearch)
2070
3209
  n = (await (await fetch(
2071
- `${this.config.externalSearch(t, e)}`
3210
+ `${this.config.externalSearch(e, t)}`
2072
3211
  )).json()).features;
2073
3212
  else {
2074
- const r = {
3213
+ const o = {
2075
3214
  $and: [
2076
- ...t.length > 0 ? [
3215
+ ...e.length > 0 ? [
2077
3216
  {
2078
3217
  $or: [
2079
3218
  // @ts-ignore
2080
- ...this._config.fuseConfig.keys.map((c) => ({
2081
- [c]: t
3219
+ ...this._config.fuseConfig.keys.map((u) => ({
3220
+ [u]: e
2082
3221
  }))
2083
3222
  ]
2084
3223
  }
2085
3224
  ] : [],
2086
3225
  ...s
2087
3226
  ]
2088
- }, o = this._fuse.search(r);
2089
- n = this._config.enableHighlighting ? Vs(o, "highlight", this._config.titleProperty) : o.map((c) => c.item);
3227
+ }, h = this._fuse.search(o);
3228
+ n = this._config.enableHighlighting ? oo(h, "highlight", this._config.titleProperty) : h.map((u) => u.item);
3229
+ }
3230
+ const l = Object.entries(this._filters).filter(([o, h]) => h.type === "range").reduce((o, [h, u]) => (o[h] = {
3231
+ min: u.keys.min,
3232
+ max: u.keys.max,
3233
+ format: u.format
3234
+ }, o), {});
3235
+ if (Object.keys(l).length > 0) {
3236
+ const o = [];
3237
+ for (let h = 0; h < n.length; h++) {
3238
+ const u = {};
3239
+ for (let [d, m] of Object.entries(l)) {
3240
+ const v = ($) => m.format === "date" ? Et($).unix() : $;
3241
+ n[h].hasOwnProperty(d) ? Array.isArray(n[h][d]) ? u[d] = // @ts-ignore
3242
+ l[d].min <= v(n[h][d][1]) && // @ts-ignore
3243
+ v(n[h][d][0]) <= l[d].max : /* @ts-ignore */ v(n[h][d]) >= l[d].min && // @ts-ignore
3244
+ v(n[h][d]) <= l[d].max ? u[d] = !0 : u[d] = !1 : u[d] = !0;
3245
+ }
3246
+ Object.values(u).every((d) => !!d) && o.push(n[h]);
3247
+ }
3248
+ n = [...o];
2090
3249
  }
2091
3250
  this._results = this.sortResults(n), this._config.onSearch(n), this.requestUpdate();
2092
3251
  }
2093
- aggregateResults(t, e) {
2094
- return t.filter((s) => {
2095
- const n = s[this._config.aggregateResults], r = Object.keys(
3252
+ aggregateResults(e, t) {
3253
+ return e.filter((s) => {
3254
+ const n = s[this._config.aggregateResults], l = Object.keys(
2096
3255
  // @ts-ignore
2097
3256
  this._filters[this._config.aggregateResults]
2098
3257
  // @ts-ignore
2099
- ).filter((c) => this._filters[this._config.aggregateResults][c]);
2100
- return (r.length ? (
3258
+ ).filter((h) => this._filters[this._config.aggregateResults].keys[h]);
3259
+ return (l.length ? (
2101
3260
  // @ts-ignore
2102
- r.includes(e)
2103
- ) : !0) && Array.isArray(n) ? n.includes(e) : n === e;
3261
+ l.includes(t)
3262
+ ) : !0) && Array.isArray(n) ? n.includes(t) : n === t;
2104
3263
  });
2105
3264
  }
2106
- sortResults(t) {
2107
- return [...t].sort(
2108
- (e, s) => (
3265
+ sortResults(e) {
3266
+ return [...e].sort(
3267
+ (t, s) => (
2109
3268
  // @ts-ignore
2110
- e[this._config.titleProperty].localeCompare(s[this._config.titleProperty])
3269
+ t[this._config.titleProperty].localeCompare(s[this._config.titleProperty])
2111
3270
  )
2112
3271
  );
2113
3272
  }
2114
- toggleFilter(t, e, s) {
2115
- s && Object.keys(this._filters).forEach((o) => {
2116
- this._config.filterProperties.find((c) => c.key === o).exclusive && Object.keys(this._filters[o]).forEach((c) => {
2117
- this._filters[o][c] = !1;
3273
+ toggleFilter(e, t, s) {
3274
+ s && Object.keys(this._filters).filter((o) => this._filters[o].type === "string").forEach((o) => {
3275
+ this._config.filterProperties.find((h) => h.key === o).exclusive && Object.keys(this._filters[o].keys).forEach((h) => {
3276
+ this._filters[o].keys[h] = !1;
2118
3277
  });
2119
- }), this._filters[t][e] = !this._filters[t][e];
3278
+ }), this._filters[e].keys[t] = !this._filters[e].keys[t];
2120
3279
  const n = this.renderRoot.querySelector('input[type="text"]');
2121
3280
  n ? this.search(n.value) : this.search();
2122
- const r = this.renderRoot.querySelectorAll(
3281
+ const l = this.renderRoot.querySelectorAll(
2123
3282
  "ul#results input[type='radio']"
2124
3283
  );
2125
- for (let o = 0; o < r.length; o++)
2126
- r[o].checked = !1;
3284
+ for (let o = 0; o < l.length; o++)
3285
+ l[o].checked = !1;
2127
3286
  this._selectedResult && setTimeout(() => {
2128
3287
  const o = this.renderRoot.querySelector(
2129
3288
  // @ts-ignore
@@ -2133,25 +3292,29 @@ let T = class extends Q {
2133
3292
  });
2134
3293
  }
2135
3294
  resetFilters() {
2136
- this.renderRoot.querySelectorAll(".details-filter input").forEach((e) => {
2137
- e.checked = !1;
3295
+ this.renderRoot.querySelectorAll(".details-filter input").forEach((t) => {
3296
+ t.checked = !1;
2138
3297
  });
2139
- const t = this.renderRoot.querySelector('input[type="text"]');
2140
- t && (t.value = ""), Object.keys(this._filters).forEach((e) => {
2141
- Object.keys(this._filters[e]).forEach((s) => {
2142
- this._filters[e][s] = !1;
3298
+ const e = this.renderRoot.querySelector('input[type="text"]');
3299
+ e && (e.value = ""), Object.keys(this._filters).forEach((t) => {
3300
+ if (this._filters[t].type === "range") {
3301
+ this._filters[t].keys.min = this._filters[t].min, this._filters[t].keys.max = this._filters[t].max;
3302
+ return;
3303
+ }
3304
+ Object.keys(this._filters[t].keys).forEach((s) => {
3305
+ this._filters[t].keys[s] = !1;
2143
3306
  });
2144
3307
  }), this.search(), this.requestUpdate();
2145
3308
  }
2146
3309
  render() {
2147
- return x`
3310
+ return _e`
2148
3311
  <style>
2149
- ${Ks}
3312
+ ${lo}
2150
3313
  </style>
2151
- <form @submit="${(t) => t.preventDefault()}">
2152
- ${J(
3314
+ <form @submit="${(e) => e.preventDefault()}">
3315
+ ${ot(
2153
3316
  this._config.enableSearch,
2154
- () => x`
3317
+ () => _e`
2155
3318
  <section>
2156
3319
  <input
2157
3320
  type="text"
@@ -2163,37 +3326,37 @@ let T = class extends Q {
2163
3326
  </section>
2164
3327
  `
2165
3328
  )}
2166
- ${J(
3329
+ ${ot(
2167
3330
  this._config.filterProperties.length,
2168
- () => x`
2169
- <section class="${this.config.inlineMode ? "inline" : _}">
2170
- ${J(
3331
+ () => _e`
3332
+ <section class="${this.config.inlineMode ? "inline" : te}">
3333
+ ${ot(
2171
3334
  !this.config.inlineMode,
2172
- () => x` <slot name="filterstitle"></slot> `
3335
+ () => _e` <slot name="filterstitle"></slot> `
2173
3336
  )}
2174
3337
  <ul id="filters">
2175
- ${X(
3338
+ ${lt(
2176
3339
  this._config.filterProperties,
2177
- (t) => x`
3340
+ (e) => _e`
2178
3341
  <details
2179
3342
  class="details-filter"
2180
3343
  part="details-filter"
2181
- data-filter="${t.key}"
3344
+ data-filter="${e.key}"
2182
3345
  >
2183
3346
  <summary>
2184
3347
  <small>
2185
3348
  <strong
2186
3349
  class="title"
2187
- style="${!t.title && "text-transform: capitalize"}"
3350
+ style="${!e.title && "text-transform: capitalize"}"
2188
3351
  >
2189
- ${t.title || t.key}
2190
- ${// @ts-ignore
2191
- Object.values(this._filters[t.key]).filter(
2192
- (e) => e
2193
- ).length ? `(${Object.values(
3352
+ ${e.title || e.key}
3353
+ ${e.type === "string" && Object.values(
3354
+ // @ts-ignore
3355
+ this._filters[e.key].keys
3356
+ ).filter((t) => t).length ? `(${Object.values(
2194
3357
  // @ts-ignore
2195
- this._filters[t.key]
2196
- ).filter((e) => e).length})` : _}
3358
+ this._filters[e.key].keys
3359
+ ).filter((t) => t).length})` : te}
2197
3360
  </strong>
2198
3361
  </small>
2199
3362
  <div
@@ -2212,41 +3375,88 @@ let T = class extends Q {
2212
3375
  </div>
2213
3376
  </summary>
2214
3377
  <div class="scroll" style="max-height: 150px">
2215
- <ul>
2216
- ${// @ts-ignore
2217
- this._filters[t.key] ? X(
3378
+ ${e.type === "range" ? _e`
3379
+ <div>
3380
+ ${e.format === "date" ? Et.unix(
2218
3381
  // @ts-ignore
2219
- Object.keys(this._filters[t.key]).sort(
2220
- (e, s) => e.localeCompare(s)
2221
- ),
2222
- (e) => x`
2223
- <li>
2224
- <label>
2225
- <input
2226
- name="selection"
2227
- type="${t.exclusive ? "radio" : "checkbox"}"
2228
- checked="${// @ts-ignore
2229
- this._filters[t.key][e] || _}"
2230
- @click=${() => this.toggleFilter(
2231
- t.key,
2232
- e,
2233
- t.exclusive
3382
+ this._filters[e.key].keys.min
3383
+ ) : (
3384
+ // @ts-ignore
3385
+ this._filters[e.key].keys.min
3386
+ )}
3387
+ </div>
3388
+ <tc-range-slider
3389
+ min="${// @ts-ignore
3390
+ this._filters[e.key].min}"
3391
+ max="${// @ts-ignore
3392
+ this._filters[e.key].max}"
3393
+ value1="${// @ts-ignore
3394
+ this._filters[e.key].keys.min}"
3395
+ value2="${// @ts-ignore
3396
+ this._filters[e.key].keys.max}"
3397
+ step="1"
3398
+ style="margin: 5px"
3399
+ @change="${(t) => {
3400
+ [
3401
+ // @ts-ignore
3402
+ this._filters[e.key].keys.min,
3403
+ // @ts-ignore
3404
+ this._filters[e.key].keys.max
3405
+ // @ts-ignore
3406
+ ] = t.detail.values, this.search(
3407
+ this.renderRoot.querySelector(
3408
+ "input[type='text']"
3409
+ // @ts-ignore
3410
+ ).value
3411
+ );
3412
+ }}"
3413
+ ></tc-range-slider>
3414
+ <div>
3415
+ ${e.format === "date" ? Et.unix(
3416
+ // @ts-ignore
3417
+ this._filters[e.key].keys.max
3418
+ ) : (
3419
+ // @ts-ignore
3420
+ this._filters[e.key].keys.max
3421
+ )}
3422
+ </div>
3423
+ ` : _e`
3424
+ <ul>
3425
+ ${// @ts-ignore
3426
+ this._filters[e.key] ? lt(
3427
+ Object.keys(
3428
+ // @ts-ignore
3429
+ this._filters[e.key].keys
3430
+ ).sort((t, s) => t.localeCompare(s)),
3431
+ (t) => _e`
3432
+ <li>
3433
+ <label>
3434
+ <input
3435
+ name="selection"
3436
+ type="${e.exclusive ? "radio" : "checkbox"}"
3437
+ checked="${// @ts-ignore
3438
+ this._filters[e.key].keys[t] || te}"
3439
+ @click=${() => this.toggleFilter(
3440
+ e.key,
3441
+ t,
3442
+ e.exclusive
2234
3443
  )}
2235
- />
2236
- <span class="title">${e}</span>
2237
- </label>
2238
- </li>
2239
- `
3444
+ />
3445
+ <span class="title">${t}</span>
3446
+ </label>
3447
+ </li>
3448
+ `
2240
3449
  ) : null}
2241
- </ul>
3450
+ </ul>
3451
+ `}
2242
3452
  </div>
2243
3453
  </details>
2244
3454
  `
2245
3455
  )}
2246
3456
  </ul>
2247
- ${J(
3457
+ ${ot(
2248
3458
  this._config.filterProperties,
2249
- () => x`
3459
+ () => _e`
2250
3460
  <a
2251
3461
  id="filter-reset"
2252
3462
  data-cy="filter-reset"
@@ -2258,24 +3468,24 @@ let T = class extends Q {
2258
3468
  </section>
2259
3469
  `
2260
3470
  )}
2261
- ${J(
3471
+ ${ot(
2262
3472
  this.config.showResults && this._results,
2263
- () => x`
3473
+ () => _e`
2264
3474
  <section id="section-results">
2265
3475
  <div>
2266
3476
  <slot name="resultstitle"></slot>
2267
3477
  </div>
2268
3478
  <div id="container-results" class="scroll">
2269
- ${this._results.length < 1 ? x` <small class="no-results">No matching items</small> ` : _}
3479
+ ${this._results.length < 1 ? _e` <small class="no-results">No matching items</small> ` : te}
2270
3480
  <ul id="results" part="results">
2271
- ${this._config.aggregateResults ? X(
3481
+ ${this._config.aggregateResults ? lt(
2272
3482
  this._resultAggregation.filter(
2273
- (t) => this.aggregateResults(
3483
+ (e) => this.aggregateResults(
2274
3484
  this._results,
2275
- t
3485
+ e
2276
3486
  ).length
2277
3487
  ),
2278
- (t) => x`<details
3488
+ (e) => _e`<details
2279
3489
  id="details-results"
2280
3490
  open
2281
3491
  >
@@ -2290,38 +3500,38 @@ let T = class extends Q {
2290
3500
  />
2291
3501
  </svg>
2292
3502
  <strong class="title">
2293
- ${t}
3503
+ ${e}
2294
3504
  </strong>
2295
3505
  <span style="margin-left: 0.25rem"
2296
3506
  >(${this.aggregateResults(
2297
3507
  this._results,
2298
- t
3508
+ e
2299
3509
  ).length})</span
2300
3510
  >
2301
3511
  </summary>
2302
3512
  <ul>
2303
- ${X(
3513
+ ${lt(
2304
3514
  this.aggregateResults(
2305
3515
  this._results,
2306
- t
3516
+ e
2307
3517
  ),
2308
3518
  // @ts-ignore
2309
- (e) => x`
3519
+ (t) => _e`
2310
3520
  <li>
2311
3521
  <label>
2312
3522
  <input
2313
3523
  type="radio"
2314
3524
  name="result"
2315
3525
  id="${// @ts-ignore
2316
- e.id}"
3526
+ t.id}"
2317
3527
  @click=${() => {
2318
- this._selectedResult = e, this._config.onSelect(e);
3528
+ this._selectedResult = t, this._config.onSelect(t);
2319
3529
  }}
2320
3530
  />
2321
3531
  <span class="title"
2322
- >${Yt(
3532
+ >${ci(
2323
3533
  // @ts-ignore
2324
- e[this._config.titleProperty]
3534
+ t[this._config.titleProperty]
2325
3535
  )}</span
2326
3536
  >
2327
3537
  </label>
@@ -2330,12 +3540,12 @@ let T = class extends Q {
2330
3540
  )}
2331
3541
  </ul>
2332
3542
  </details>`
2333
- ) : X(
3543
+ ) : lt(
2334
3544
  this._results,
2335
3545
  // @ts-ignore
2336
- (t) => x`<li part="result">
3546
+ (e) => _e`<li part="result">
2337
3547
  ${// @ts-ignore
2338
- Yt(t[this._config.titleProperty])}
3548
+ ci(e[this._config.titleProperty])}
2339
3549
  </li>`
2340
3550
  )}
2341
3551
  </ul>
@@ -2363,27 +3573,27 @@ let T = class extends Q {
2363
3573
  // slot.replaceWith(clon);
2364
3574
  // }
2365
3575
  };
2366
- F([
2367
- ht()
2368
- ], T.prototype, "_items", 2);
2369
- F([
2370
- ht()
2371
- ], T.prototype, "_results", 2);
2372
- F([
2373
- ht()
2374
- ], T.prototype, "_filters", 2);
2375
- F([
2376
- ht()
2377
- ], T.prototype, "_selectedResult", 2);
2378
- F([
2379
- Ot({ attribute: !1 })
2380
- ], T.prototype, "config", 1);
2381
- F([
2382
- Ot()
2383
- ], T.prototype, "apply", 2);
2384
- T = F([
2385
- Le("eox-itemfilter")
2386
- ], T);
3576
+ Ye([
3577
+ Tt()
3578
+ ], Ne.prototype, "_items", 2);
3579
+ Ye([
3580
+ Tt()
3581
+ ], Ne.prototype, "_results", 2);
3582
+ Ye([
3583
+ Tt()
3584
+ ], Ne.prototype, "_filters", 2);
3585
+ Ye([
3586
+ Tt()
3587
+ ], Ne.prototype, "_selectedResult", 2);
3588
+ Ye([
3589
+ Ss({ attribute: !1 })
3590
+ ], Ne.prototype, "config", 1);
3591
+ Ye([
3592
+ Ss()
3593
+ ], Ne.prototype, "apply", 2);
3594
+ Ne = Ye([
3595
+ Kr("eox-itemfilter")
3596
+ ], Ne);
2387
3597
  export {
2388
- T as EOxItemFilter
3598
+ Ne as EOxItemFilter
2389
3599
  };