@golemui/gui-react 0.12.2 → 0.13.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.
Files changed (96) hide show
  1. package/Accordion-BU3skkjb.js +58 -0
  2. package/Alert-DpUiDxQT.js +17 -0
  3. package/Button-BYVR5EKG.js +86 -0
  4. package/CHANGELOG.md +16 -0
  5. package/{Calendar-Dxavv2c7.js → Calendar-BmMkpTcV.js} +13 -11
  6. package/Checkbox-B1Tsf-vi.js +164 -0
  7. package/Currency-D0pOQwU4.js +233 -0
  8. package/{DateInput-CdkyyAhc.js → DateInput-CqFHtc9F.js} +12 -10
  9. package/{DatePicker-TkMCndrw.js → DatePicker-BmW3TO0X.js} +18 -15
  10. package/{Dropdown-jKk4TyOa.js → Dropdown-C-_zDFCe.js} +5 -3
  11. package/Flex-Rs-RvIcq.js +20 -0
  12. package/{Grid-DREMTVQI.js → Grid-BcPUrfRL.js} +3 -2
  13. package/{List-BjMIo577.js → List-YkH8gdMh.js} +5 -3
  14. package/Markdown-DeAW4y3P.js +571 -0
  15. package/MarkdownText-BdISjAsE.js +11 -0
  16. package/Number-GsGZMR5a.js +247 -0
  17. package/Password-B8QjtpUe.js +204 -0
  18. package/RadioGroup-Cd1_Zkkz.js +197 -0
  19. package/{RangeCalendar-u2vxIhna.js → RangeCalendar-9IJoFEXw.js} +10 -8
  20. package/{RangeDateInput-CopLdb6J.js → RangeDateInput-DrVR4T_z.js} +21 -19
  21. package/{RangeDatePicker-DXpV-B_G.js → RangeDatePicker-Cq_Tt6NE.js} +38 -35
  22. package/{Renderer-B6WmwKDv.js → Renderer-CWqudTUu.js} +4 -2
  23. package/Repeater-DE-DAylQ.js +124 -0
  24. package/Select-CCCPYQW6.js +238 -0
  25. package/{Tabs-C2qqi8xO.js → Tabs-BVgVVvnu.js} +4 -3
  26. package/TextArea-BlRaVCon.js +202 -0
  27. package/TextInput-KuHLSN2X.js +169 -0
  28. package/Toggle-D-bglMPv.js +166 -0
  29. package/abstract-calendar-JfbbRwFb.js +528 -0
  30. package/calendar-BgptByan.js +95 -0
  31. package/class-map-DrTVAYz_.js +26 -0
  32. package/date-BS1lA1xg.js +786 -0
  33. package/date-input-Dux0mFJw.js +266 -0
  34. package/directive-1yd1wdny.js +555 -0
  35. package/errors-6UKoJh8Y.js +108 -0
  36. package/index.js +2705 -1171
  37. package/index.umd.cjs +878 -2
  38. package/lib/components/Accordion.d.ts +2 -2
  39. package/lib/components/Alert.d.ts +2 -2
  40. package/lib/components/Button.d.ts +2 -2
  41. package/lib/components/Calendar.d.ts +2 -2
  42. package/lib/components/Checkbox.d.ts +2 -2
  43. package/lib/components/Currency.d.ts +2 -2
  44. package/lib/components/DateInput.d.ts +2 -2
  45. package/lib/components/DatePicker.d.ts +2 -2
  46. package/lib/components/Dropdown.d.ts +2 -2
  47. package/lib/components/Flex.d.ts +2 -2
  48. package/lib/components/Form.d.ts +5 -5
  49. package/lib/components/Grid.d.ts +2 -2
  50. package/lib/components/List.d.ts +2 -2
  51. package/lib/components/Markdown.d.ts +2 -2
  52. package/lib/components/MarkdownText.d.ts +2 -2
  53. package/lib/components/Number.d.ts +2 -2
  54. package/lib/components/Password.d.ts +2 -2
  55. package/lib/components/RadioGroup.d.ts +2 -2
  56. package/lib/components/RangeCalendar.d.ts +2 -2
  57. package/lib/components/RangeDateInput.d.ts +2 -2
  58. package/lib/components/RangeDatePicker.d.ts +2 -2
  59. package/lib/components/Renderer.d.ts +2 -2
  60. package/lib/components/Repeater.d.ts +2 -2
  61. package/lib/components/Select.d.ts +2 -2
  62. package/lib/components/Tabs.d.ts +2 -2
  63. package/lib/components/TextArea.d.ts +2 -2
  64. package/lib/components/TextInput.d.ts +2 -2
  65. package/lib/components/Toggle.d.ts +2 -2
  66. package/lib/widget.loaders.d.ts +2 -2
  67. package/list-DHX7bG4r.js +282 -0
  68. package/live-BfTBpQrp.js +24 -0
  69. package/markdown-text-BUv0K0WF.js +44 -0
  70. package/one-of-DifUsEYY.js +48 -0
  71. package/package.json +6 -6
  72. package/query-h1h36oxg.js +12 -0
  73. package/range-calendar-SAyiW3EF.js +326 -0
  74. package/range-date-input-8WtB1urD.js +507 -0
  75. package/repeat-BucBfSPF.js +79 -0
  76. package/state-DI9ZsB5W.js +7 -0
  77. package/style-map-C_0XzJlx.js +29 -0
  78. package/tabs-DzSCq_98.js +13 -0
  79. package/templates-DBGyvZtc.js +75 -0
  80. package/Accordion-Btp_b0xA.js +0 -59
  81. package/Alert-CBgIsMKO.js +0 -16
  82. package/Button-DN0G-MUb.js +0 -21
  83. package/Checkbox-ViM9MktI.js +0 -30
  84. package/Currency-C4QFWO7Y.js +0 -37
  85. package/DefaultListItemRenderer-lNc9Kk7x.js +0 -18
  86. package/Flex-gD893rrB.js +0 -19
  87. package/Markdown-Ck_88HOR.js +0 -47
  88. package/MarkdownText-kJVkmihW.js +0 -9
  89. package/Number-CnQ95aLO.js +0 -35
  90. package/Password-Bg97DYW3.js +0 -36
  91. package/RadioGroup-Dldom5ja.js +0 -33
  92. package/Repeater-BYgXVfbl.js +0 -111
  93. package/Select-BLUX_W91.js +0 -55
  94. package/TextArea-cw3Q2v97.js +0 -35
  95. package/TextInput-geLoAA0c.js +0 -32
  96. package/Toggle-a7L71GwR.js +0 -30
@@ -0,0 +1,555 @@
1
+ const O = globalThis, D = O.ShadowRoot && (O.ShadyCSS === void 0 || O.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, Q = Symbol(), z = /* @__PURE__ */ new WeakMap();
2
+ let it = class {
3
+ constructor(t, e, s) {
4
+ if (this._$cssResult$ = !0, s !== Q) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
5
+ this.cssText = t, this.t = e;
6
+ }
7
+ get styleSheet() {
8
+ let t = this.o;
9
+ const e = this.t;
10
+ if (D && t === void 0) {
11
+ const s = e !== void 0 && e.length === 1;
12
+ s && (t = z.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), s && z.set(e, t));
13
+ }
14
+ return t;
15
+ }
16
+ toString() {
17
+ return this.cssText;
18
+ }
19
+ };
20
+ const rt = (r) => new it(typeof r == "string" ? r : r + "", void 0, Q), nt = (r, t) => {
21
+ if (D) r.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet);
22
+ else for (const e of t) {
23
+ const s = document.createElement("style"), i = O.litNonce;
24
+ i !== void 0 && s.setAttribute("nonce", i), s.textContent = e.cssText, r.appendChild(s);
25
+ }
26
+ }, B = D ? (r) => r : (r) => r instanceof CSSStyleSheet ? ((t) => {
27
+ let e = "";
28
+ for (const s of t.cssRules) e += s.cssText;
29
+ return rt(e);
30
+ })(r) : r;
31
+ const { is: ot, defineProperty: ht, getOwnPropertyDescriptor: at, getOwnPropertyNames: lt, getOwnPropertySymbols: ct, getPrototypeOf: dt } = Object, H = globalThis, q = H.trustedTypes, pt = q ? q.emptyScript : "", $t = H.reactiveElementPolyfillSupport, b = (r, t) => r, T = { toAttribute(r, t) {
32
+ switch (t) {
33
+ case Boolean:
34
+ r = r ? pt : null;
35
+ break;
36
+ case Object:
37
+ case Array:
38
+ r = r == null ? r : JSON.stringify(r);
39
+ }
40
+ return r;
41
+ }, fromAttribute(r, t) {
42
+ let e = r;
43
+ switch (t) {
44
+ case Boolean:
45
+ e = r !== null;
46
+ break;
47
+ case Number:
48
+ e = r === null ? null : Number(r);
49
+ break;
50
+ case Object:
51
+ case Array:
52
+ try {
53
+ e = JSON.parse(r);
54
+ } catch {
55
+ e = null;
56
+ }
57
+ }
58
+ return e;
59
+ } }, k = (r, t) => !ot(r, t), W = { attribute: !0, type: String, converter: T, reflect: !1, useDefault: !1, hasChanged: k };
60
+ Symbol.metadata ??= Symbol("metadata"), H.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
61
+ let g = class extends HTMLElement {
62
+ static addInitializer(t) {
63
+ this._$Ei(), (this.l ??= []).push(t);
64
+ }
65
+ static get observedAttributes() {
66
+ return this.finalize(), this._$Eh && [...this._$Eh.keys()];
67
+ }
68
+ static createProperty(t, e = W) {
69
+ if (e.state && (e.attribute = !1), this._$Ei(), this.prototype.hasOwnProperty(t) && ((e = Object.create(e)).wrapped = !0), this.elementProperties.set(t, e), !e.noAccessor) {
70
+ const s = Symbol(), i = this.getPropertyDescriptor(t, s, e);
71
+ i !== void 0 && ht(this.prototype, t, i);
72
+ }
73
+ }
74
+ static getPropertyDescriptor(t, e, s) {
75
+ const { get: i, set: n } = at(this.prototype, t) ?? { get() {
76
+ return this[e];
77
+ }, set(o) {
78
+ this[e] = o;
79
+ } };
80
+ return { get: i, set(o) {
81
+ const a = i?.call(this);
82
+ n?.call(this, o), this.requestUpdate(t, a, s);
83
+ }, configurable: !0, enumerable: !0 };
84
+ }
85
+ static getPropertyOptions(t) {
86
+ return this.elementProperties.get(t) ?? W;
87
+ }
88
+ static _$Ei() {
89
+ if (this.hasOwnProperty(b("elementProperties"))) return;
90
+ const t = dt(this);
91
+ t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
92
+ }
93
+ static finalize() {
94
+ if (this.hasOwnProperty(b("finalized"))) return;
95
+ if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(b("properties"))) {
96
+ const e = this.properties, s = [...lt(e), ...ct(e)];
97
+ for (const i of s) this.createProperty(i, e[i]);
98
+ }
99
+ const t = this[Symbol.metadata];
100
+ if (t !== null) {
101
+ const e = litPropertyMetadata.get(t);
102
+ if (e !== void 0) for (const [s, i] of e) this.elementProperties.set(s, i);
103
+ }
104
+ this._$Eh = /* @__PURE__ */ new Map();
105
+ for (const [e, s] of this.elementProperties) {
106
+ const i = this._$Eu(e, s);
107
+ i !== void 0 && this._$Eh.set(i, e);
108
+ }
109
+ this.elementStyles = this.finalizeStyles(this.styles);
110
+ }
111
+ static finalizeStyles(t) {
112
+ const e = [];
113
+ if (Array.isArray(t)) {
114
+ const s = new Set(t.flat(1 / 0).reverse());
115
+ for (const i of s) e.unshift(B(i));
116
+ } else t !== void 0 && e.push(B(t));
117
+ return e;
118
+ }
119
+ static _$Eu(t, e) {
120
+ const s = e.attribute;
121
+ return s === !1 ? void 0 : typeof s == "string" ? s : typeof t == "string" ? t.toLowerCase() : void 0;
122
+ }
123
+ constructor() {
124
+ super(), this._$Ep = void 0, this.isUpdatePending = !1, this.hasUpdated = !1, this._$Em = null, this._$Ev();
125
+ }
126
+ _$Ev() {
127
+ this._$ES = new Promise((t) => this.enableUpdating = t), this._$AL = /* @__PURE__ */ new Map(), this._$E_(), this.requestUpdate(), this.constructor.l?.forEach((t) => t(this));
128
+ }
129
+ addController(t) {
130
+ (this._$EO ??= /* @__PURE__ */ new Set()).add(t), this.renderRoot !== void 0 && this.isConnected && t.hostConnected?.();
131
+ }
132
+ removeController(t) {
133
+ this._$EO?.delete(t);
134
+ }
135
+ _$E_() {
136
+ const t = /* @__PURE__ */ new Map(), e = this.constructor.elementProperties;
137
+ for (const s of e.keys()) this.hasOwnProperty(s) && (t.set(s, this[s]), delete this[s]);
138
+ t.size > 0 && (this._$Ep = t);
139
+ }
140
+ createRenderRoot() {
141
+ const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
142
+ return nt(t, this.constructor.elementStyles), t;
143
+ }
144
+ connectedCallback() {
145
+ this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(!0), this._$EO?.forEach((t) => t.hostConnected?.());
146
+ }
147
+ enableUpdating(t) {
148
+ }
149
+ disconnectedCallback() {
150
+ this._$EO?.forEach((t) => t.hostDisconnected?.());
151
+ }
152
+ attributeChangedCallback(t, e, s) {
153
+ this._$AK(t, s);
154
+ }
155
+ _$ET(t, e) {
156
+ const s = this.constructor.elementProperties.get(t), i = this.constructor._$Eu(t, s);
157
+ if (i !== void 0 && s.reflect === !0) {
158
+ const n = (s.converter?.toAttribute !== void 0 ? s.converter : T).toAttribute(e, s.type);
159
+ this._$Em = t, n == null ? this.removeAttribute(i) : this.setAttribute(i, n), this._$Em = null;
160
+ }
161
+ }
162
+ _$AK(t, e) {
163
+ const s = this.constructor, i = s._$Eh.get(t);
164
+ if (i !== void 0 && this._$Em !== i) {
165
+ const n = s.getPropertyOptions(i), o = typeof n.converter == "function" ? { fromAttribute: n.converter } : n.converter?.fromAttribute !== void 0 ? n.converter : T;
166
+ this._$Em = i;
167
+ const a = o.fromAttribute(e, n.type);
168
+ this[i] = a ?? this._$Ej?.get(i) ?? a, this._$Em = null;
169
+ }
170
+ }
171
+ requestUpdate(t, e, s, i = !1, n) {
172
+ if (t !== void 0) {
173
+ const o = this.constructor;
174
+ if (i === !1 && (n = this[t]), s ??= o.getPropertyOptions(t), !((s.hasChanged ?? k)(n, e) || s.useDefault && s.reflect && n === this._$Ej?.get(t) && !this.hasAttribute(o._$Eu(t, s)))) return;
175
+ this.C(t, e, s);
176
+ }
177
+ this.isUpdatePending === !1 && (this._$ES = this._$EP());
178
+ }
179
+ C(t, e, { useDefault: s, reflect: i, wrapped: n }, o) {
180
+ s && !(this._$Ej ??= /* @__PURE__ */ new Map()).has(t) && (this._$Ej.set(t, o ?? e ?? this[t]), n !== !0 || o !== void 0) || (this._$AL.has(t) || (this.hasUpdated || s || (e = void 0), this._$AL.set(t, e)), i === !0 && this._$Em !== t && (this._$Eq ??= /* @__PURE__ */ new Set()).add(t));
181
+ }
182
+ async _$EP() {
183
+ this.isUpdatePending = !0;
184
+ try {
185
+ await this._$ES;
186
+ } catch (e) {
187
+ Promise.reject(e);
188
+ }
189
+ const t = this.scheduleUpdate();
190
+ return t != null && await t, !this.isUpdatePending;
191
+ }
192
+ scheduleUpdate() {
193
+ return this.performUpdate();
194
+ }
195
+ performUpdate() {
196
+ if (!this.isUpdatePending) return;
197
+ if (!this.hasUpdated) {
198
+ if (this.renderRoot ??= this.createRenderRoot(), this._$Ep) {
199
+ for (const [i, n] of this._$Ep) this[i] = n;
200
+ this._$Ep = void 0;
201
+ }
202
+ const s = this.constructor.elementProperties;
203
+ if (s.size > 0) for (const [i, n] of s) {
204
+ const { wrapped: o } = n, a = this[i];
205
+ o !== !0 || this._$AL.has(i) || a === void 0 || this.C(i, void 0, n, a);
206
+ }
207
+ }
208
+ let t = !1;
209
+ const e = this._$AL;
210
+ try {
211
+ t = this.shouldUpdate(e), t ? (this.willUpdate(e), this._$EO?.forEach((s) => s.hostUpdate?.()), this.update(e)) : this._$EM();
212
+ } catch (s) {
213
+ throw t = !1, this._$EM(), s;
214
+ }
215
+ t && this._$AE(e);
216
+ }
217
+ willUpdate(t) {
218
+ }
219
+ _$AE(t) {
220
+ this._$EO?.forEach((e) => e.hostUpdated?.()), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
221
+ }
222
+ _$EM() {
223
+ this._$AL = /* @__PURE__ */ new Map(), this.isUpdatePending = !1;
224
+ }
225
+ get updateComplete() {
226
+ return this.getUpdateComplete();
227
+ }
228
+ getUpdateComplete() {
229
+ return this._$ES;
230
+ }
231
+ shouldUpdate(t) {
232
+ return !0;
233
+ }
234
+ update(t) {
235
+ this._$Eq &&= this._$Eq.forEach((e) => this._$ET(e, this[e])), this._$EM();
236
+ }
237
+ updated(t) {
238
+ }
239
+ firstUpdated(t) {
240
+ }
241
+ };
242
+ g.elementStyles = [], g.shadowRootOptions = { mode: "open" }, g[b("elementProperties")] = /* @__PURE__ */ new Map(), g[b("finalized")] = /* @__PURE__ */ new Map(), $t?.({ ReactiveElement: g }), (H.reactiveElementVersions ??= []).push("2.1.2");
243
+ const j = globalThis, V = (r) => r, M = j.trustedTypes, Z = M ? M.createPolicy("lit-html", { createHTML: (r) => r }) : void 0, X = "$lit$", _ = `lit$${Math.random().toFixed(9).slice(2)}$`, tt = "?" + _, ut = `<${tt}>`, m = document, w = () => m.createComment(""), C = (r) => r === null || typeof r != "object" && typeof r != "function", I = Array.isArray, _t = (r) => I(r) || typeof r?.[Symbol.iterator] == "function", R = `[
244
+ \f\r]`, S = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, J = /-->/g, K = />/g, f = RegExp(`>|${R}(?:([^\\s"'>=/]+)(${R}*=${R}*(?:[^
245
+ \f\r"'\`<>=]|("|')|))|$)`, "g"), F = /'/g, Y = /"/g, et = /^(?:script|style|textarea|title)$/i, ft = (r) => (t, ...e) => ({ _$litType$: r, strings: t, values: e }), xt = ft(1), y = Symbol.for("lit-noChange"), d = Symbol.for("lit-nothing"), G = /* @__PURE__ */ new WeakMap(), A = m.createTreeWalker(m, 129);
246
+ function st(r, t) {
247
+ if (!I(r) || !r.hasOwnProperty("raw")) throw Error("invalid template strings array");
248
+ return Z !== void 0 ? Z.createHTML(t) : t;
249
+ }
250
+ const At = (r, t) => {
251
+ const e = r.length - 1, s = [];
252
+ let i, n = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", o = S;
253
+ for (let a = 0; a < e; a++) {
254
+ const h = r[a];
255
+ let c, p, l = -1, $ = 0;
256
+ for (; $ < h.length && (o.lastIndex = $, p = o.exec(h), p !== null); ) $ = o.lastIndex, o === S ? p[1] === "!--" ? o = J : p[1] !== void 0 ? o = K : p[2] !== void 0 ? (et.test(p[2]) && (i = RegExp("</" + p[2], "g")), o = f) : p[3] !== void 0 && (o = f) : o === f ? p[0] === ">" ? (o = i ?? S, l = -1) : p[1] === void 0 ? l = -2 : (l = o.lastIndex - p[2].length, c = p[1], o = p[3] === void 0 ? f : p[3] === '"' ? Y : F) : o === Y || o === F ? o = f : o === J || o === K ? o = S : (o = f, i = void 0);
257
+ const u = o === f && r[a + 1].startsWith("/>") ? " " : "";
258
+ n += o === S ? h + ut : l >= 0 ? (s.push(c), h.slice(0, l) + X + h.slice(l) + _ + u) : h + _ + (l === -2 ? a : u);
259
+ }
260
+ return [st(r, n + (r[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), s];
261
+ };
262
+ class P {
263
+ constructor({ strings: t, _$litType$: e }, s) {
264
+ let i;
265
+ this.parts = [];
266
+ let n = 0, o = 0;
267
+ const a = t.length - 1, h = this.parts, [c, p] = At(t, e);
268
+ if (this.el = P.createElement(c, s), A.currentNode = this.el.content, e === 2 || e === 3) {
269
+ const l = this.el.content.firstChild;
270
+ l.replaceWith(...l.childNodes);
271
+ }
272
+ for (; (i = A.nextNode()) !== null && h.length < a; ) {
273
+ if (i.nodeType === 1) {
274
+ if (i.hasAttributes()) for (const l of i.getAttributeNames()) if (l.endsWith(X)) {
275
+ const $ = p[o++], u = i.getAttribute(l).split(_), U = /([.?@])?(.*)/.exec($);
276
+ h.push({ type: 1, index: n, name: U[2], strings: u, ctor: U[1] === "." ? gt : U[1] === "?" ? yt : U[1] === "@" ? vt : N }), i.removeAttribute(l);
277
+ } else l.startsWith(_) && (h.push({ type: 6, index: n }), i.removeAttribute(l));
278
+ if (et.test(i.tagName)) {
279
+ const l = i.textContent.split(_), $ = l.length - 1;
280
+ if ($ > 0) {
281
+ i.textContent = M ? M.emptyScript : "";
282
+ for (let u = 0; u < $; u++) i.append(l[u], w()), A.nextNode(), h.push({ type: 2, index: ++n });
283
+ i.append(l[$], w());
284
+ }
285
+ }
286
+ } else if (i.nodeType === 8) if (i.data === tt) h.push({ type: 2, index: n });
287
+ else {
288
+ let l = -1;
289
+ for (; (l = i.data.indexOf(_, l + 1)) !== -1; ) h.push({ type: 7, index: n }), l += _.length - 1;
290
+ }
291
+ n++;
292
+ }
293
+ }
294
+ static createElement(t, e) {
295
+ const s = m.createElement("template");
296
+ return s.innerHTML = t, s;
297
+ }
298
+ }
299
+ function v(r, t, e = r, s) {
300
+ if (t === y) return t;
301
+ let i = s !== void 0 ? e._$Co?.[s] : e._$Cl;
302
+ const n = C(t) ? void 0 : t._$litDirective$;
303
+ return i?.constructor !== n && (i?._$AO?.(!1), n === void 0 ? i = void 0 : (i = new n(r), i._$AT(r, e, s)), s !== void 0 ? (e._$Co ??= [])[s] = i : e._$Cl = i), i !== void 0 && (t = v(r, i._$AS(r, t.values), i, s)), t;
304
+ }
305
+ class mt {
306
+ constructor(t, e) {
307
+ this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = e;
308
+ }
309
+ get parentNode() {
310
+ return this._$AM.parentNode;
311
+ }
312
+ get _$AU() {
313
+ return this._$AM._$AU;
314
+ }
315
+ u(t) {
316
+ const { el: { content: e }, parts: s } = this._$AD, i = (t?.creationScope ?? m).importNode(e, !0);
317
+ A.currentNode = i;
318
+ let n = A.nextNode(), o = 0, a = 0, h = s[0];
319
+ for (; h !== void 0; ) {
320
+ if (o === h.index) {
321
+ let c;
322
+ h.type === 2 ? c = new E(n, n.nextSibling, this, t) : h.type === 1 ? c = new h.ctor(n, h.name, h.strings, this, t) : h.type === 6 && (c = new Et(n, this, t)), this._$AV.push(c), h = s[++a];
323
+ }
324
+ o !== h?.index && (n = A.nextNode(), o++);
325
+ }
326
+ return A.currentNode = m, i;
327
+ }
328
+ p(t) {
329
+ let e = 0;
330
+ for (const s of this._$AV) s !== void 0 && (s.strings !== void 0 ? (s._$AI(t, s, e), e += s.strings.length - 2) : s._$AI(t[e])), e++;
331
+ }
332
+ }
333
+ class E {
334
+ get _$AU() {
335
+ return this._$AM?._$AU ?? this._$Cv;
336
+ }
337
+ constructor(t, e, s, i) {
338
+ this.type = 2, this._$AH = d, this._$AN = void 0, this._$AA = t, this._$AB = e, this._$AM = s, this.options = i, this._$Cv = i?.isConnected ?? !0;
339
+ }
340
+ get parentNode() {
341
+ let t = this._$AA.parentNode;
342
+ const e = this._$AM;
343
+ return e !== void 0 && t?.nodeType === 11 && (t = e.parentNode), t;
344
+ }
345
+ get startNode() {
346
+ return this._$AA;
347
+ }
348
+ get endNode() {
349
+ return this._$AB;
350
+ }
351
+ _$AI(t, e = this) {
352
+ t = v(this, t, e), C(t) ? t === d || t == null || t === "" ? (this._$AH !== d && this._$AR(), this._$AH = d) : t !== this._$AH && t !== y && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : _t(t) ? this.k(t) : this._(t);
353
+ }
354
+ O(t) {
355
+ return this._$AA.parentNode.insertBefore(t, this._$AB);
356
+ }
357
+ T(t) {
358
+ this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
359
+ }
360
+ _(t) {
361
+ this._$AH !== d && C(this._$AH) ? this._$AA.nextSibling.data = t : this.T(m.createTextNode(t)), this._$AH = t;
362
+ }
363
+ $(t) {
364
+ const { values: e, _$litType$: s } = t, i = typeof s == "number" ? this._$AC(t) : (s.el === void 0 && (s.el = P.createElement(st(s.h, s.h[0]), this.options)), s);
365
+ if (this._$AH?._$AD === i) this._$AH.p(e);
366
+ else {
367
+ const n = new mt(i, this), o = n.u(this.options);
368
+ n.p(e), this.T(o), this._$AH = n;
369
+ }
370
+ }
371
+ _$AC(t) {
372
+ let e = G.get(t.strings);
373
+ return e === void 0 && G.set(t.strings, e = new P(t)), e;
374
+ }
375
+ k(t) {
376
+ I(this._$AH) || (this._$AH = [], this._$AR());
377
+ const e = this._$AH;
378
+ let s, i = 0;
379
+ for (const n of t) i === e.length ? e.push(s = new E(this.O(w()), this.O(w()), this, this.options)) : s = e[i], s._$AI(n), i++;
380
+ i < e.length && (this._$AR(s && s._$AB.nextSibling, i), e.length = i);
381
+ }
382
+ _$AR(t = this._$AA.nextSibling, e) {
383
+ for (this._$AP?.(!1, !0, e); t !== this._$AB; ) {
384
+ const s = V(t).nextSibling;
385
+ V(t).remove(), t = s;
386
+ }
387
+ }
388
+ setConnected(t) {
389
+ this._$AM === void 0 && (this._$Cv = t, this._$AP?.(t));
390
+ }
391
+ }
392
+ class N {
393
+ get tagName() {
394
+ return this.element.tagName;
395
+ }
396
+ get _$AU() {
397
+ return this._$AM._$AU;
398
+ }
399
+ constructor(t, e, s, i, n) {
400
+ this.type = 1, this._$AH = d, this._$AN = void 0, this.element = t, this.name = e, this._$AM = i, this.options = n, s.length > 2 || s[0] !== "" || s[1] !== "" ? (this._$AH = Array(s.length - 1).fill(new String()), this.strings = s) : this._$AH = d;
401
+ }
402
+ _$AI(t, e = this, s, i) {
403
+ const n = this.strings;
404
+ let o = !1;
405
+ if (n === void 0) t = v(this, t, e, 0), o = !C(t) || t !== this._$AH && t !== y, o && (this._$AH = t);
406
+ else {
407
+ const a = t;
408
+ let h, c;
409
+ for (t = n[0], h = 0; h < n.length - 1; h++) c = v(this, a[s + h], e, h), c === y && (c = this._$AH[h]), o ||= !C(c) || c !== this._$AH[h], c === d ? t = d : t !== d && (t += (c ?? "") + n[h + 1]), this._$AH[h] = c;
410
+ }
411
+ o && !i && this.j(t);
412
+ }
413
+ j(t) {
414
+ t === d ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
415
+ }
416
+ }
417
+ class gt extends N {
418
+ constructor() {
419
+ super(...arguments), this.type = 3;
420
+ }
421
+ j(t) {
422
+ this.element[this.name] = t === d ? void 0 : t;
423
+ }
424
+ }
425
+ class yt extends N {
426
+ constructor() {
427
+ super(...arguments), this.type = 4;
428
+ }
429
+ j(t) {
430
+ this.element.toggleAttribute(this.name, !!t && t !== d);
431
+ }
432
+ }
433
+ class vt extends N {
434
+ constructor(t, e, s, i, n) {
435
+ super(t, e, s, i, n), this.type = 5;
436
+ }
437
+ _$AI(t, e = this) {
438
+ if ((t = v(this, t, e, 0) ?? d) === y) return;
439
+ const s = this._$AH, i = t === d && s !== d || t.capture !== s.capture || t.once !== s.once || t.passive !== s.passive, n = t !== d && (s === d || i);
440
+ i && this.element.removeEventListener(this.name, this, s), n && this.element.addEventListener(this.name, this, t), this._$AH = t;
441
+ }
442
+ handleEvent(t) {
443
+ typeof this._$AH == "function" ? this._$AH.call(this.options?.host ?? this.element, t) : this._$AH.handleEvent(t);
444
+ }
445
+ }
446
+ class Et {
447
+ constructor(t, e, s) {
448
+ this.element = t, this.type = 6, this._$AN = void 0, this._$AM = e, this.options = s;
449
+ }
450
+ get _$AU() {
451
+ return this._$AM._$AU;
452
+ }
453
+ _$AI(t) {
454
+ v(this, t);
455
+ }
456
+ }
457
+ const Tt = { I: E }, St = j.litHtmlPolyfillSupport;
458
+ St?.(P, E), (j.litHtmlVersions ??= []).push("3.3.2");
459
+ const bt = (r, t, e) => {
460
+ const s = e?.renderBefore ?? t;
461
+ let i = s._$litPart$;
462
+ if (i === void 0) {
463
+ const n = e?.renderBefore ?? null;
464
+ s._$litPart$ = i = new E(t.insertBefore(w(), n), n, void 0, e ?? {});
465
+ }
466
+ return i._$AI(r), i;
467
+ };
468
+ const L = globalThis;
469
+ let x = class extends g {
470
+ constructor() {
471
+ super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
472
+ }
473
+ createRenderRoot() {
474
+ const t = super.createRenderRoot();
475
+ return this.renderOptions.renderBefore ??= t.firstChild, t;
476
+ }
477
+ update(t) {
478
+ const e = this.render();
479
+ this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = bt(e, this.renderRoot, this.renderOptions);
480
+ }
481
+ connectedCallback() {
482
+ super.connectedCallback(), this._$Do?.setConnected(!0);
483
+ }
484
+ disconnectedCallback() {
485
+ super.disconnectedCallback(), this._$Do?.setConnected(!1);
486
+ }
487
+ render() {
488
+ return y;
489
+ }
490
+ };
491
+ x._$litElement$ = !0, x.finalized = !0, L.litElementHydrateSupport?.({ LitElement: x });
492
+ const wt = L.litElementPolyfillSupport;
493
+ wt?.({ LitElement: x });
494
+ (L.litElementVersions ??= []).push("4.2.2");
495
+ const Ht = (r) => (t, e) => {
496
+ e !== void 0 ? e.addInitializer(() => {
497
+ customElements.define(r, t);
498
+ }) : customElements.define(r, t);
499
+ };
500
+ const Ct = { attribute: !0, type: String, converter: T, reflect: !1, hasChanged: k }, Pt = (r = Ct, t, e) => {
501
+ const { kind: s, metadata: i } = e;
502
+ let n = globalThis.litPropertyMetadata.get(i);
503
+ if (n === void 0 && globalThis.litPropertyMetadata.set(i, n = /* @__PURE__ */ new Map()), s === "setter" && ((r = Object.create(r)).wrapped = !0), n.set(e.name, r), s === "accessor") {
504
+ const { name: o } = e;
505
+ return { set(a) {
506
+ const h = t.get.call(this);
507
+ t.set.call(this, a), this.requestUpdate(o, h, r, !0, a);
508
+ }, init(a) {
509
+ return a !== void 0 && this.C(o, void 0, r, a), a;
510
+ } };
511
+ }
512
+ if (s === "setter") {
513
+ const { name: o } = e;
514
+ return function(a) {
515
+ const h = this[o];
516
+ t.call(this, a), this.requestUpdate(o, h, r, !0, a);
517
+ };
518
+ }
519
+ throw Error("Unsupported decorator location: " + s);
520
+ };
521
+ function Nt(r) {
522
+ return (t, e) => typeof e == "object" ? Pt(r, t, e) : ((s, i, n) => {
523
+ const o = i.hasOwnProperty(n);
524
+ return i.constructor.createProperty(n, s), o ? Object.getOwnPropertyDescriptor(i, n) : void 0;
525
+ })(r, t, e);
526
+ }
527
+ const Rt = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4 }, Dt = (r) => (...t) => ({ _$litDirective$: r, values: t });
528
+ class kt {
529
+ constructor(t) {
530
+ }
531
+ get _$AU() {
532
+ return this._$AM._$AU;
533
+ }
534
+ _$AT(t, e, s) {
535
+ this._$Ct = t, this._$AM = e, this._$Ci = s;
536
+ }
537
+ _$AS(t, e) {
538
+ return this.update(t, e);
539
+ }
540
+ update(t, e) {
541
+ return this.render(...e);
542
+ }
543
+ }
544
+ export {
545
+ d as A,
546
+ y as E,
547
+ kt as a,
548
+ xt as b,
549
+ Rt as c,
550
+ Dt as e,
551
+ x as i,
552
+ Tt as j,
553
+ Nt as n,
554
+ Ht as t
555
+ };
@@ -0,0 +1,108 @@
1
+ import { i as h, b as y, n as r, t as c } from "./directive-1yd1wdny.js";
2
+ import { G as f, b as m, c as g } from "./templates-DBGyvZtc.js";
3
+ var v = Object.defineProperty, b = Object.getOwnPropertyDescriptor, o = (d, s, n, i) => {
4
+ for (var e = i > 1 ? void 0 : i ? b(s, n) : s, a = d.length - 1, l; a >= 0; a--)
5
+ (l = d[a]) && (e = (i ? l(s, n, e) : l(e)) || e);
6
+ return i && e && v(s, n, e), e;
7
+ };
8
+ let t = class extends h {
9
+ constructor() {
10
+ super(...arguments), this.targetElement = void 0, this.uid = void 0, this.label = void 0, this.hint = void 0, this.required = void 0, this.errors = [], this.disabled = !1, this.readOnly = !1, this.touched = !1, this.native = !0, this.ariaController = new f(this, {
11
+ getTargets: () => Array.isArray(this.targetElement) ? [...this.targetElement] : [this.targetElement],
12
+ getState: () => ({
13
+ uid: this.uid,
14
+ templateData: {
15
+ hint: this.hint,
16
+ errors: this.errors,
17
+ readonly: this.readOnly,
18
+ disabled: this.disabled,
19
+ touched: this.touched
20
+ }
21
+ })
22
+ });
23
+ }
24
+ createRenderRoot() {
25
+ return this;
26
+ }
27
+ render() {
28
+ return super.render(), y`${m(
29
+ this.uid,
30
+ {
31
+ label: this.label,
32
+ hint: this.hint,
33
+ required: this.required,
34
+ errors: this.errors,
35
+ touched: this.touched
36
+ },
37
+ !1,
38
+ void 0,
39
+ this.native
40
+ )}`;
41
+ }
42
+ };
43
+ o([
44
+ r({ type: Object })
45
+ ], t.prototype, "targetElement", 2);
46
+ o([
47
+ r({ type: String })
48
+ ], t.prototype, "uid", 2);
49
+ o([
50
+ r({ type: String })
51
+ ], t.prototype, "label", 2);
52
+ o([
53
+ r({ type: String })
54
+ ], t.prototype, "hint", 2);
55
+ o([
56
+ r({ type: Boolean })
57
+ ], t.prototype, "required", 2);
58
+ o([
59
+ r({ type: Array })
60
+ ], t.prototype, "errors", 2);
61
+ o([
62
+ r({ type: Boolean })
63
+ ], t.prototype, "disabled", 2);
64
+ o([
65
+ r({ type: Boolean, attribute: "readonly" })
66
+ ], t.prototype, "readOnly", 2);
67
+ o([
68
+ r({ type: Boolean })
69
+ ], t.prototype, "touched", 2);
70
+ o([
71
+ r({ type: Boolean })
72
+ ], t.prototype, "native", 2);
73
+ t = o([
74
+ c("gui-label")
75
+ ], t);
76
+ typeof customElements < "u" && !customElements.get("gui-label") && customElements.define("gui-label", t);
77
+ var E = Object.defineProperty, O = Object.getOwnPropertyDescriptor, u = (d, s, n, i) => {
78
+ for (var e = i > 1 ? void 0 : i ? O(s, n) : s, a = d.length - 1, l; a >= 0; a--)
79
+ (l = d[a]) && (e = (i ? l(s, n, e) : l(e)) || e);
80
+ return i && e && E(s, n, e), e;
81
+ };
82
+ let p = class extends h {
83
+ constructor() {
84
+ super(...arguments), this.uid = void 0, this.errors = [], this.touched = !1;
85
+ }
86
+ createRenderRoot() {
87
+ return this;
88
+ }
89
+ render() {
90
+ return super.render(), y`${g(this.uid, {
91
+ touched: this.touched,
92
+ errors: this.errors
93
+ })}`;
94
+ }
95
+ };
96
+ u([
97
+ r({ type: String })
98
+ ], p.prototype, "uid", 2);
99
+ u([
100
+ r({ type: Array })
101
+ ], p.prototype, "errors", 2);
102
+ u([
103
+ r({ type: Boolean })
104
+ ], p.prototype, "touched", 2);
105
+ p = u([
106
+ c("gui-errors")
107
+ ], p);
108
+ typeof customElements < "u" && !customElements.get("gui-errors") && customElements.define("gui-errors", p);