@voidable/ui 0.0.0 → 0.2.0
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.
- package/dist/index.d.ts +89 -8
- package/dist/ui.js +475 -220
- package/package.json +6 -4
package/dist/ui.js
CHANGED
|
@@ -108,7 +108,7 @@ s([r({
|
|
|
108
108
|
})], u.prototype, "orientation", void 0), customElements.get("void-divider") || customElements.define("void-divider", u);
|
|
109
109
|
//#endregion
|
|
110
110
|
//#region src/components/spinner.ts
|
|
111
|
-
var
|
|
111
|
+
var ee = class extends o {
|
|
112
112
|
constructor(...e) {
|
|
113
113
|
super(...e), this.size = "md", this.label = "Loading";
|
|
114
114
|
}
|
|
@@ -125,13 +125,13 @@ var d = class extends o {
|
|
|
125
125
|
s([r({
|
|
126
126
|
type: String,
|
|
127
127
|
reflect: !0
|
|
128
|
-
})],
|
|
128
|
+
})], ee.prototype, "size", void 0), s([r({
|
|
129
129
|
type: String,
|
|
130
130
|
reflect: !0
|
|
131
|
-
})],
|
|
131
|
+
})], ee.prototype, "label", void 0), customElements.get("void-spinner") || customElements.define("void-spinner", ee);
|
|
132
132
|
//#endregion
|
|
133
133
|
//#region src/components/skeleton.ts
|
|
134
|
-
var
|
|
134
|
+
var te = class extends o {
|
|
135
135
|
constructor(...e) {
|
|
136
136
|
super(...e), this.variant = "text";
|
|
137
137
|
}
|
|
@@ -142,10 +142,10 @@ var ee = class extends o {
|
|
|
142
142
|
s([r({
|
|
143
143
|
type: String,
|
|
144
144
|
reflect: !0
|
|
145
|
-
})],
|
|
145
|
+
})], te.prototype, "variant", void 0), customElements.get("void-skeleton") || customElements.define("void-skeleton", te);
|
|
146
146
|
//#endregion
|
|
147
147
|
//#region src/components/status-dot.ts
|
|
148
|
-
var
|
|
148
|
+
var ne = class extends o {
|
|
149
149
|
constructor(...e) {
|
|
150
150
|
super(...e), this.status = "offline";
|
|
151
151
|
}
|
|
@@ -166,10 +166,10 @@ var te = class extends o {
|
|
|
166
166
|
s([r({
|
|
167
167
|
type: String,
|
|
168
168
|
reflect: !0
|
|
169
|
-
})],
|
|
169
|
+
})], ne.prototype, "status", void 0), customElements.get("void-status-dot") || customElements.define("void-status-dot", ne);
|
|
170
170
|
//#endregion
|
|
171
171
|
//#region src/components/switch.ts
|
|
172
|
-
var
|
|
172
|
+
var d = class extends o {
|
|
173
173
|
constructor(...e) {
|
|
174
174
|
super(...e), this.checked = !1, this.disabled = !1, this.color = "default", this.size = "md", this._handleClick = () => {
|
|
175
175
|
this.disabled || (this.checked = !this.checked, this.dispatchEvent(new CustomEvent("void-change", {
|
|
@@ -197,19 +197,19 @@ var f = class extends o {
|
|
|
197
197
|
s([r({
|
|
198
198
|
type: Boolean,
|
|
199
199
|
reflect: !0
|
|
200
|
-
})],
|
|
200
|
+
})], d.prototype, "checked", void 0), s([r({
|
|
201
201
|
type: Boolean,
|
|
202
202
|
reflect: !0
|
|
203
|
-
})],
|
|
203
|
+
})], d.prototype, "disabled", void 0), s([r({
|
|
204
204
|
type: String,
|
|
205
205
|
reflect: !0
|
|
206
|
-
})],
|
|
206
|
+
})], d.prototype, "color", void 0), s([r({
|
|
207
207
|
type: String,
|
|
208
208
|
reflect: !0
|
|
209
|
-
})],
|
|
209
|
+
})], d.prototype, "size", void 0), customElements.get("void-switch") || customElements.define("void-switch", d);
|
|
210
210
|
//#endregion
|
|
211
211
|
//#region src/components/avatar.ts
|
|
212
|
-
var
|
|
212
|
+
var f = class extends o {
|
|
213
213
|
constructor(...e) {
|
|
214
214
|
super(...e), this.src = "", this.alt = "", this.initials = "", this.size = "md", this._onImgError = () => {
|
|
215
215
|
this.src = "";
|
|
@@ -228,19 +228,19 @@ var p = class extends o {
|
|
|
228
228
|
s([r({
|
|
229
229
|
type: String,
|
|
230
230
|
reflect: !0
|
|
231
|
-
})],
|
|
231
|
+
})], f.prototype, "src", void 0), s([r({
|
|
232
232
|
type: String,
|
|
233
233
|
reflect: !0
|
|
234
|
-
})],
|
|
234
|
+
})], f.prototype, "alt", void 0), s([r({
|
|
235
235
|
type: String,
|
|
236
236
|
reflect: !0
|
|
237
|
-
})],
|
|
237
|
+
})], f.prototype, "initials", void 0), s([r({
|
|
238
238
|
type: String,
|
|
239
239
|
reflect: !0
|
|
240
|
-
})],
|
|
240
|
+
})], f.prototype, "size", void 0), customElements.get("void-avatar") || customElements.define("void-avatar", f);
|
|
241
241
|
//#endregion
|
|
242
242
|
//#region src/components/alert.ts
|
|
243
|
-
var
|
|
243
|
+
var p = class extends o {
|
|
244
244
|
constructor(...e) {
|
|
245
245
|
super(...e), this.color = "default", this.dismissible = !1, this.variant = "subtle", this._userContent = [], this._didSetup = !1;
|
|
246
246
|
}
|
|
@@ -266,16 +266,16 @@ var m = class extends o {
|
|
|
266
266
|
s([r({
|
|
267
267
|
type: String,
|
|
268
268
|
reflect: !0
|
|
269
|
-
})],
|
|
269
|
+
})], p.prototype, "color", void 0), s([r({
|
|
270
270
|
type: Boolean,
|
|
271
271
|
reflect: !0
|
|
272
|
-
})],
|
|
272
|
+
})], p.prototype, "dismissible", void 0), s([r({
|
|
273
273
|
type: String,
|
|
274
274
|
reflect: !0
|
|
275
|
-
})],
|
|
275
|
+
})], p.prototype, "variant", void 0), customElements.get("void-alert") || customElements.define("void-alert", p);
|
|
276
276
|
//#endregion
|
|
277
277
|
//#region src/components/tag.ts
|
|
278
|
-
var
|
|
278
|
+
var m = class extends o {
|
|
279
279
|
constructor(...e) {
|
|
280
280
|
super(...e), this.color = "default", this.removable = !1, this.size = "md", this._userContent = [], this._didSetup = !1;
|
|
281
281
|
}
|
|
@@ -302,16 +302,16 @@ var h = class extends o {
|
|
|
302
302
|
s([r({
|
|
303
303
|
type: String,
|
|
304
304
|
reflect: !0
|
|
305
|
-
})],
|
|
305
|
+
})], m.prototype, "color", void 0), s([r({
|
|
306
306
|
type: Boolean,
|
|
307
307
|
reflect: !0
|
|
308
|
-
})],
|
|
308
|
+
})], m.prototype, "removable", void 0), s([r({
|
|
309
309
|
type: String,
|
|
310
310
|
reflect: !0
|
|
311
|
-
})],
|
|
311
|
+
})], m.prototype, "size", void 0), customElements.get("void-tag") || customElements.define("void-tag", m);
|
|
312
312
|
//#endregion
|
|
313
313
|
//#region src/components/progress.ts
|
|
314
|
-
var
|
|
314
|
+
var h = class extends o {
|
|
315
315
|
constructor(...e) {
|
|
316
316
|
super(...e), this.value = 0, this.max = 100, this.color = "default", this.size = "md", this.indeterminate = !1;
|
|
317
317
|
}
|
|
@@ -329,22 +329,22 @@ var g = class extends o {
|
|
|
329
329
|
s([r({
|
|
330
330
|
type: Number,
|
|
331
331
|
reflect: !0
|
|
332
|
-
})],
|
|
332
|
+
})], h.prototype, "value", void 0), s([r({
|
|
333
333
|
type: Number,
|
|
334
334
|
reflect: !0
|
|
335
|
-
})],
|
|
335
|
+
})], h.prototype, "max", void 0), s([r({
|
|
336
336
|
type: String,
|
|
337
337
|
reflect: !0
|
|
338
|
-
})],
|
|
338
|
+
})], h.prototype, "color", void 0), s([r({
|
|
339
339
|
type: String,
|
|
340
340
|
reflect: !0
|
|
341
|
-
})],
|
|
341
|
+
})], h.prototype, "size", void 0), s([r({
|
|
342
342
|
type: Boolean,
|
|
343
343
|
reflect: !0
|
|
344
|
-
})],
|
|
344
|
+
})], h.prototype, "indeterminate", void 0), customElements.get("void-progress") || customElements.define("void-progress", h);
|
|
345
345
|
//#endregion
|
|
346
346
|
//#region src/components/panel.ts
|
|
347
|
-
var
|
|
347
|
+
var g = class extends o {
|
|
348
348
|
constructor(...e) {
|
|
349
349
|
super(...e), this.label = "", this.variant = "default", this._userContent = [], this._didSetup = !1;
|
|
350
350
|
}
|
|
@@ -364,13 +364,13 @@ var _ = class extends o {
|
|
|
364
364
|
s([r({
|
|
365
365
|
type: String,
|
|
366
366
|
reflect: !0
|
|
367
|
-
})],
|
|
367
|
+
})], g.prototype, "label", void 0), s([r({
|
|
368
368
|
type: String,
|
|
369
369
|
reflect: !0
|
|
370
|
-
})],
|
|
370
|
+
})], g.prototype, "variant", void 0), customElements.get("void-panel") || customElements.define("void-panel", g);
|
|
371
371
|
//#endregion
|
|
372
372
|
//#region src/components/input.ts
|
|
373
|
-
var
|
|
373
|
+
var _ = class extends o {
|
|
374
374
|
constructor(...e) {
|
|
375
375
|
super(...e), this.type = "text", this.value = "", this.placeholder = "", this.disabled = !1, this.readonly = !1, this.required = !1, this.name = "", this.size = "md", this.error = "";
|
|
376
376
|
}
|
|
@@ -414,31 +414,31 @@ var v = class extends o {
|
|
|
414
414
|
s([r({
|
|
415
415
|
type: String,
|
|
416
416
|
reflect: !0
|
|
417
|
-
})],
|
|
417
|
+
})], _.prototype, "type", void 0), s([r({ type: String })], _.prototype, "value", void 0), s([r({
|
|
418
418
|
type: String,
|
|
419
419
|
reflect: !0
|
|
420
|
-
})],
|
|
420
|
+
})], _.prototype, "placeholder", void 0), s([r({
|
|
421
421
|
type: Boolean,
|
|
422
422
|
reflect: !0
|
|
423
|
-
})],
|
|
423
|
+
})], _.prototype, "disabled", void 0), s([r({
|
|
424
424
|
type: Boolean,
|
|
425
425
|
reflect: !0
|
|
426
|
-
})],
|
|
426
|
+
})], _.prototype, "readonly", void 0), s([r({
|
|
427
427
|
type: Boolean,
|
|
428
428
|
reflect: !0
|
|
429
|
-
})],
|
|
429
|
+
})], _.prototype, "required", void 0), s([r({
|
|
430
430
|
type: String,
|
|
431
431
|
reflect: !0
|
|
432
|
-
})],
|
|
432
|
+
})], _.prototype, "name", void 0), s([r({
|
|
433
433
|
type: String,
|
|
434
434
|
reflect: !0
|
|
435
|
-
})],
|
|
435
|
+
})], _.prototype, "size", void 0), s([r({
|
|
436
436
|
type: String,
|
|
437
437
|
reflect: !0
|
|
438
|
-
})],
|
|
438
|
+
})], _.prototype, "error", void 0), customElements.get("void-input") || customElements.define("void-input", _);
|
|
439
439
|
//#endregion
|
|
440
440
|
//#region src/components/textarea.ts
|
|
441
|
-
var
|
|
441
|
+
var v = class extends o {
|
|
442
442
|
constructor(...e) {
|
|
443
443
|
super(...e), this.value = "", this.placeholder = "", this.disabled = !1, this.readonly = !1, this.required = !1, this.name = "", this.rows = 3, this.resize = "vertical", this.size = "md", this.error = "";
|
|
444
444
|
}
|
|
@@ -480,37 +480,37 @@ var y = class extends o {
|
|
|
480
480
|
}));
|
|
481
481
|
}
|
|
482
482
|
};
|
|
483
|
-
s([r({ type: String })],
|
|
483
|
+
s([r({ type: String })], v.prototype, "value", void 0), s([r({
|
|
484
484
|
type: String,
|
|
485
485
|
reflect: !0
|
|
486
|
-
})],
|
|
486
|
+
})], v.prototype, "placeholder", void 0), s([r({
|
|
487
487
|
type: Boolean,
|
|
488
488
|
reflect: !0
|
|
489
|
-
})],
|
|
489
|
+
})], v.prototype, "disabled", void 0), s([r({
|
|
490
490
|
type: Boolean,
|
|
491
491
|
reflect: !0
|
|
492
|
-
})],
|
|
492
|
+
})], v.prototype, "readonly", void 0), s([r({
|
|
493
493
|
type: Boolean,
|
|
494
494
|
reflect: !0
|
|
495
|
-
})],
|
|
495
|
+
})], v.prototype, "required", void 0), s([r({
|
|
496
496
|
type: String,
|
|
497
497
|
reflect: !0
|
|
498
|
-
})],
|
|
498
|
+
})], v.prototype, "name", void 0), s([r({
|
|
499
499
|
type: Number,
|
|
500
500
|
reflect: !0
|
|
501
|
-
})],
|
|
501
|
+
})], v.prototype, "rows", void 0), s([r({
|
|
502
502
|
type: String,
|
|
503
503
|
reflect: !0
|
|
504
|
-
})],
|
|
504
|
+
})], v.prototype, "resize", void 0), s([r({
|
|
505
505
|
type: String,
|
|
506
506
|
reflect: !0
|
|
507
|
-
})],
|
|
507
|
+
})], v.prototype, "size", void 0), s([r({
|
|
508
508
|
type: String,
|
|
509
509
|
reflect: !0
|
|
510
|
-
})],
|
|
510
|
+
})], v.prototype, "error", void 0), customElements.get("void-textarea") || customElements.define("void-textarea", v);
|
|
511
511
|
//#endregion
|
|
512
512
|
//#region src/components/select.ts
|
|
513
|
-
var
|
|
513
|
+
var y = class extends o {
|
|
514
514
|
constructor(...e) {
|
|
515
515
|
super(...e), this.value = "", this.disabled = !1, this.required = !1, this.name = "", this.size = "md", this.error = "", this.placeholder = "", this._options = [], this._didSetup = !1;
|
|
516
516
|
}
|
|
@@ -548,28 +548,28 @@ var b = class extends o {
|
|
|
548
548
|
}));
|
|
549
549
|
}
|
|
550
550
|
};
|
|
551
|
-
s([r({ type: String })],
|
|
551
|
+
s([r({ type: String })], y.prototype, "value", void 0), s([r({
|
|
552
552
|
type: Boolean,
|
|
553
553
|
reflect: !0
|
|
554
|
-
})],
|
|
554
|
+
})], y.prototype, "disabled", void 0), s([r({
|
|
555
555
|
type: Boolean,
|
|
556
556
|
reflect: !0
|
|
557
|
-
})],
|
|
557
|
+
})], y.prototype, "required", void 0), s([r({
|
|
558
558
|
type: String,
|
|
559
559
|
reflect: !0
|
|
560
|
-
})],
|
|
560
|
+
})], y.prototype, "name", void 0), s([r({
|
|
561
561
|
type: String,
|
|
562
562
|
reflect: !0
|
|
563
|
-
})],
|
|
563
|
+
})], y.prototype, "size", void 0), s([r({
|
|
564
564
|
type: String,
|
|
565
565
|
reflect: !0
|
|
566
|
-
})],
|
|
566
|
+
})], y.prototype, "error", void 0), s([r({
|
|
567
567
|
type: String,
|
|
568
568
|
reflect: !0
|
|
569
|
-
})],
|
|
569
|
+
})], y.prototype, "placeholder", void 0), customElements.get("void-select") || customElements.define("void-select", y);
|
|
570
570
|
//#endregion
|
|
571
571
|
//#region src/components/checkbox.ts
|
|
572
|
-
var
|
|
572
|
+
var b = class extends o {
|
|
573
573
|
constructor(...e) {
|
|
574
574
|
super(...e), this.checked = !1, this.disabled = !1, this.indeterminate = !1, this.name = "", this.value = "", this.color = "default", this.size = "md", this._userContent = [], this._didSetup = !1, this._handleClick = (e) => {
|
|
575
575
|
if (this.disabled) {
|
|
@@ -612,28 +612,28 @@ var x = class extends o {
|
|
|
612
612
|
s([r({
|
|
613
613
|
type: Boolean,
|
|
614
614
|
reflect: !0
|
|
615
|
-
})],
|
|
615
|
+
})], b.prototype, "checked", void 0), s([r({
|
|
616
616
|
type: Boolean,
|
|
617
617
|
reflect: !0
|
|
618
|
-
})],
|
|
618
|
+
})], b.prototype, "disabled", void 0), s([r({
|
|
619
619
|
type: Boolean,
|
|
620
620
|
reflect: !0
|
|
621
|
-
})],
|
|
621
|
+
})], b.prototype, "indeterminate", void 0), s([r({
|
|
622
622
|
type: String,
|
|
623
623
|
reflect: !0
|
|
624
|
-
})],
|
|
624
|
+
})], b.prototype, "name", void 0), s([r({
|
|
625
625
|
type: String,
|
|
626
626
|
reflect: !0
|
|
627
|
-
})],
|
|
627
|
+
})], b.prototype, "value", void 0), s([r({
|
|
628
628
|
type: String,
|
|
629
629
|
reflect: !0
|
|
630
|
-
})],
|
|
630
|
+
})], b.prototype, "color", void 0), s([r({
|
|
631
631
|
type: String,
|
|
632
632
|
reflect: !0
|
|
633
|
-
})],
|
|
633
|
+
})], b.prototype, "size", void 0), customElements.get("void-checkbox") || customElements.define("void-checkbox", b);
|
|
634
634
|
//#endregion
|
|
635
635
|
//#region src/components/radio.ts
|
|
636
|
-
var
|
|
636
|
+
var x = class extends o {
|
|
637
637
|
constructor(...e) {
|
|
638
638
|
super(...e), this.checked = !1, this.disabled = !1, this.name = "", this.value = "", this.color = "default", this.size = "md", this._userContent = [], this._didSetup = !1, this._handleClick = (e) => {
|
|
639
639
|
if (this.disabled || this.checked) {
|
|
@@ -678,25 +678,25 @@ var S = class extends o {
|
|
|
678
678
|
s([r({
|
|
679
679
|
type: Boolean,
|
|
680
680
|
reflect: !0
|
|
681
|
-
})],
|
|
681
|
+
})], x.prototype, "checked", void 0), s([r({
|
|
682
682
|
type: Boolean,
|
|
683
683
|
reflect: !0
|
|
684
|
-
})],
|
|
684
|
+
})], x.prototype, "disabled", void 0), s([r({
|
|
685
685
|
type: String,
|
|
686
686
|
reflect: !0
|
|
687
|
-
})],
|
|
687
|
+
})], x.prototype, "name", void 0), s([r({
|
|
688
688
|
type: String,
|
|
689
689
|
reflect: !0
|
|
690
|
-
})],
|
|
690
|
+
})], x.prototype, "value", void 0), s([r({
|
|
691
691
|
type: String,
|
|
692
692
|
reflect: !0
|
|
693
|
-
})],
|
|
693
|
+
})], x.prototype, "color", void 0), s([r({
|
|
694
694
|
type: String,
|
|
695
695
|
reflect: !0
|
|
696
|
-
})],
|
|
696
|
+
})], x.prototype, "size", void 0), customElements.get("void-radio") || customElements.define("void-radio", x);
|
|
697
697
|
//#endregion
|
|
698
698
|
//#region src/components/radio-group.ts
|
|
699
|
-
var
|
|
699
|
+
var S = class extends o {
|
|
700
700
|
constructor(...e) {
|
|
701
701
|
super(...e), this.label = "", this.value = "", this.name = "", this.orientation = "vertical", this._userContent = [], this._didSetup = !1, this._handleChildChange = (e) => {
|
|
702
702
|
let t = e.target;
|
|
@@ -741,13 +741,13 @@ var C = class extends o {
|
|
|
741
741
|
`;
|
|
742
742
|
}
|
|
743
743
|
};
|
|
744
|
-
s([r({ type: String })],
|
|
744
|
+
s([r({ type: String })], S.prototype, "label", void 0), s([r({ type: String })], S.prototype, "value", void 0), s([r({ type: String })], S.prototype, "name", void 0), s([r({
|
|
745
745
|
type: String,
|
|
746
746
|
reflect: !0
|
|
747
|
-
})],
|
|
747
|
+
})], S.prototype, "orientation", void 0), customElements.get("void-radio-group") || customElements.define("void-radio-group", S);
|
|
748
748
|
//#endregion
|
|
749
749
|
//#region src/components/field.ts
|
|
750
|
-
var
|
|
750
|
+
var C = class extends o {
|
|
751
751
|
constructor(...e) {
|
|
752
752
|
super(...e), this.label = "", this.error = "", this.helper = "", this.required = !1, this._userContent = [], this._didSetup = !1;
|
|
753
753
|
}
|
|
@@ -772,34 +772,31 @@ var w = class extends o {
|
|
|
772
772
|
s([r({
|
|
773
773
|
type: String,
|
|
774
774
|
reflect: !0
|
|
775
|
-
})],
|
|
775
|
+
})], C.prototype, "label", void 0), s([r({
|
|
776
776
|
type: String,
|
|
777
777
|
reflect: !0
|
|
778
|
-
})],
|
|
778
|
+
})], C.prototype, "error", void 0), s([r({
|
|
779
779
|
type: String,
|
|
780
780
|
reflect: !0
|
|
781
|
-
})],
|
|
781
|
+
})], C.prototype, "helper", void 0), s([r({
|
|
782
782
|
type: Boolean,
|
|
783
783
|
reflect: !0
|
|
784
|
-
})],
|
|
784
|
+
})], C.prototype, "required", void 0), customElements.get("void-field") || customElements.define("void-field", C);
|
|
785
785
|
//#endregion
|
|
786
786
|
//#region src/components/multiselect.ts
|
|
787
|
-
var
|
|
787
|
+
var w = class extends o {
|
|
788
788
|
constructor(...e) {
|
|
789
789
|
super(...e), this.value = "", this.selected = !1;
|
|
790
790
|
}
|
|
791
|
-
render() {
|
|
792
|
-
return n;
|
|
793
|
-
}
|
|
794
791
|
};
|
|
795
792
|
s([r({
|
|
796
793
|
type: String,
|
|
797
794
|
reflect: !0
|
|
798
|
-
})],
|
|
795
|
+
})], w.prototype, "value", void 0), s([r({
|
|
799
796
|
type: Boolean,
|
|
800
797
|
reflect: !0
|
|
801
|
-
})],
|
|
802
|
-
var
|
|
798
|
+
})], w.prototype, "selected", void 0), customElements.get("void-option") || customElements.define("void-option", w);
|
|
799
|
+
var T = class extends o {
|
|
803
800
|
constructor(...e) {
|
|
804
801
|
super(...e), this.placeholder = "Select...", this.disabled = !1, this.size = "md", this.error = "", this.name = "", this._open = !1, this._options = [], this._didSetup = !1, this._onTriggerClick = (e) => {
|
|
805
802
|
this.disabled || (e.stopPropagation(), this._open = !this._open, this.requestUpdate());
|
|
@@ -884,22 +881,22 @@ var E = class extends o {
|
|
|
884
881
|
}));
|
|
885
882
|
}
|
|
886
883
|
};
|
|
887
|
-
s([r({ type: String })],
|
|
884
|
+
s([r({ type: String })], T.prototype, "placeholder", void 0), s([r({
|
|
888
885
|
type: Boolean,
|
|
889
886
|
reflect: !0
|
|
890
|
-
})],
|
|
887
|
+
})], T.prototype, "disabled", void 0), s([r({
|
|
891
888
|
type: String,
|
|
892
889
|
reflect: !0
|
|
893
|
-
})],
|
|
890
|
+
})], T.prototype, "size", void 0), s([r({
|
|
894
891
|
type: String,
|
|
895
892
|
reflect: !0
|
|
896
|
-
})],
|
|
893
|
+
})], T.prototype, "error", void 0), s([r({
|
|
897
894
|
type: String,
|
|
898
895
|
reflect: !0
|
|
899
|
-
})],
|
|
896
|
+
})], T.prototype, "name", void 0), customElements.get("void-multiselect") || customElements.define("void-multiselect", T);
|
|
900
897
|
//#endregion
|
|
901
898
|
//#region src/components/dialog.ts
|
|
902
|
-
var
|
|
899
|
+
var E = class extends o {
|
|
903
900
|
constructor(...e) {
|
|
904
901
|
super(...e), this.open = !1, this.heading = "", this.size = "md", this.closable = !0, this._userContent = [], this._didSetup = !1, this._handleKeydown = (e) => {
|
|
905
902
|
e.key === "Escape" && this.closable && this._close();
|
|
@@ -950,13 +947,13 @@ var D = class extends o {
|
|
|
950
947
|
s([r({
|
|
951
948
|
type: Boolean,
|
|
952
949
|
reflect: !0
|
|
953
|
-
})],
|
|
950
|
+
})], E.prototype, "open", void 0), s([r({ type: String })], E.prototype, "heading", void 0), s([r({
|
|
954
951
|
type: String,
|
|
955
952
|
reflect: !0
|
|
956
|
-
})],
|
|
953
|
+
})], E.prototype, "size", void 0), s([r({ type: Boolean })], E.prototype, "closable", void 0), customElements.get("void-dialog") || customElements.define("void-dialog", E);
|
|
957
954
|
//#endregion
|
|
958
955
|
//#region src/components/tabs.ts
|
|
959
|
-
var
|
|
956
|
+
var D = class extends o {
|
|
960
957
|
constructor(...e) {
|
|
961
958
|
super(...e), this.tab = "", this.label = "", this.active = !1;
|
|
962
959
|
}
|
|
@@ -966,21 +963,18 @@ var O = class extends o {
|
|
|
966
963
|
updated(e) {
|
|
967
964
|
super.updated(e), this.setAttribute("role", "tabpanel"), e.has("tab") && this.tab && (this.id = this.tab);
|
|
968
965
|
}
|
|
969
|
-
render() {
|
|
970
|
-
return n;
|
|
971
|
-
}
|
|
972
966
|
};
|
|
973
967
|
s([r({
|
|
974
968
|
type: String,
|
|
975
969
|
reflect: !0
|
|
976
|
-
})],
|
|
970
|
+
})], D.prototype, "tab", void 0), s([r({
|
|
977
971
|
type: String,
|
|
978
972
|
reflect: !0
|
|
979
|
-
})],
|
|
973
|
+
})], D.prototype, "label", void 0), s([r({
|
|
980
974
|
type: Boolean,
|
|
981
975
|
reflect: !0
|
|
982
|
-
})],
|
|
983
|
-
var
|
|
976
|
+
})], D.prototype, "active", void 0), customElements.get("void-tab-panel") || customElements.define("void-tab-panel", D);
|
|
977
|
+
var O = class extends o {
|
|
984
978
|
constructor(...e) {
|
|
985
979
|
super(...e), this.value = "", this.size = "md", this._panels = [];
|
|
986
980
|
}
|
|
@@ -1009,7 +1003,6 @@ var k = class extends o {
|
|
|
1009
1003
|
>${e.label || e.tab}</button>
|
|
1010
1004
|
`)}
|
|
1011
1005
|
</div>
|
|
1012
|
-
<slot></slot>
|
|
1013
1006
|
`;
|
|
1014
1007
|
}
|
|
1015
1008
|
_onTabClick(e) {
|
|
@@ -1024,30 +1017,27 @@ var k = class extends o {
|
|
|
1024
1017
|
e.key === "ArrowRight" ? (e.preventDefault(), n[(t + 1) % n.length].focus()) : e.key === "ArrowLeft" && (e.preventDefault(), n[(t - 1 + n.length) % n.length].focus());
|
|
1025
1018
|
}
|
|
1026
1019
|
};
|
|
1027
|
-
s([r({ type: String })],
|
|
1020
|
+
s([r({ type: String })], O.prototype, "value", void 0), s([r({
|
|
1028
1021
|
type: String,
|
|
1029
1022
|
reflect: !0
|
|
1030
|
-
})],
|
|
1023
|
+
})], O.prototype, "size", void 0), customElements.get("void-tabs") || customElements.define("void-tabs", O);
|
|
1031
1024
|
//#endregion
|
|
1032
1025
|
//#region src/components/accordion.ts
|
|
1033
|
-
var
|
|
1026
|
+
var k = class extends o {
|
|
1034
1027
|
constructor(...e) {
|
|
1035
1028
|
super(...e), this.multiple = !1;
|
|
1036
1029
|
}
|
|
1037
|
-
render() {
|
|
1038
|
-
return t`<slot></slot>`;
|
|
1039
|
-
}
|
|
1040
1030
|
};
|
|
1041
1031
|
s([r({
|
|
1042
1032
|
type: Boolean,
|
|
1043
1033
|
reflect: !0
|
|
1044
|
-
})],
|
|
1045
|
-
var
|
|
1034
|
+
})], k.prototype, "multiple", void 0), customElements.get("void-accordion") || customElements.define("void-accordion", k);
|
|
1035
|
+
var A = class extends o {
|
|
1046
1036
|
constructor(...e) {
|
|
1047
1037
|
super(...e), this.heading = "", this.open = !1, this._id = Math.random().toString(36).slice(2), this._userContent = [], this._didSetup = !1, this._handleClick = (e) => {
|
|
1048
1038
|
e.preventDefault(), this.open = !this.open;
|
|
1049
1039
|
let t = this.parentElement;
|
|
1050
|
-
if (t instanceof
|
|
1040
|
+
if (t instanceof k && !t.multiple) {
|
|
1051
1041
|
let e = Array.from(t.querySelectorAll("void-accordion-item"));
|
|
1052
1042
|
for (let t of e) t !== this && (t.open = !1);
|
|
1053
1043
|
}
|
|
@@ -1094,13 +1084,13 @@ var j = class extends o {
|
|
|
1094
1084
|
`;
|
|
1095
1085
|
}
|
|
1096
1086
|
};
|
|
1097
|
-
s([r({ type: String })],
|
|
1087
|
+
s([r({ type: String })], A.prototype, "heading", void 0), s([r({
|
|
1098
1088
|
type: Boolean,
|
|
1099
1089
|
reflect: !0
|
|
1100
|
-
})],
|
|
1090
|
+
})], A.prototype, "open", void 0), customElements.get("void-accordion-item") || customElements.define("void-accordion-item", A);
|
|
1101
1091
|
//#endregion
|
|
1102
1092
|
//#region src/components/breadcrumbs.ts
|
|
1103
|
-
var
|
|
1093
|
+
var re = class extends o {
|
|
1104
1094
|
constructor(...e) {
|
|
1105
1095
|
super(...e), this.separator = "/", this._items = [], this._didSetup = !1;
|
|
1106
1096
|
}
|
|
@@ -1125,25 +1115,22 @@ var M = class extends o {
|
|
|
1125
1115
|
return t`<ol class="void-breadcrumbs-list"></ol>`;
|
|
1126
1116
|
}
|
|
1127
1117
|
};
|
|
1128
|
-
s([r({ type: String })],
|
|
1118
|
+
s([r({ type: String })], re.prototype, "separator", void 0), customElements.get("void-breadcrumbs") || customElements.define("void-breadcrumbs", re);
|
|
1129
1119
|
//#endregion
|
|
1130
1120
|
//#region src/components/list.ts
|
|
1131
|
-
var
|
|
1121
|
+
var ie = class extends o {
|
|
1132
1122
|
constructor(...e) {
|
|
1133
1123
|
super(...e), this.dividers = !1;
|
|
1134
1124
|
}
|
|
1135
1125
|
connectedCallback() {
|
|
1136
1126
|
super.connectedCallback(), this.setAttribute("role", "list");
|
|
1137
1127
|
}
|
|
1138
|
-
render() {
|
|
1139
|
-
return n;
|
|
1140
|
-
}
|
|
1141
1128
|
};
|
|
1142
1129
|
s([r({
|
|
1143
1130
|
type: Boolean,
|
|
1144
1131
|
reflect: !0
|
|
1145
|
-
})],
|
|
1146
|
-
var
|
|
1132
|
+
})], ie.prototype, "dividers", void 0), customElements.get("void-list") || customElements.define("void-list", ie);
|
|
1133
|
+
var j = class extends o {
|
|
1147
1134
|
constructor(...e) {
|
|
1148
1135
|
super(...e), this.selected = !1, this.disabled = !1, this.interactive = !1, this._handleClick = () => {
|
|
1149
1136
|
this.disabled || this.dispatchEvent(new CustomEvent("void-click", {
|
|
@@ -1159,23 +1146,20 @@ var P = class extends o {
|
|
|
1159
1146
|
updated(e) {
|
|
1160
1147
|
super.updated(e), e.has("interactive") && (this.interactive ? this.addEventListener("click", this._handleClick) : this.removeEventListener("click", this._handleClick));
|
|
1161
1148
|
}
|
|
1162
|
-
render() {
|
|
1163
|
-
return n;
|
|
1164
|
-
}
|
|
1165
1149
|
};
|
|
1166
1150
|
s([r({
|
|
1167
1151
|
type: Boolean,
|
|
1168
1152
|
reflect: !0
|
|
1169
|
-
})],
|
|
1153
|
+
})], j.prototype, "selected", void 0), s([r({
|
|
1170
1154
|
type: Boolean,
|
|
1171
1155
|
reflect: !0
|
|
1172
|
-
})],
|
|
1156
|
+
})], j.prototype, "disabled", void 0), s([r({
|
|
1173
1157
|
type: Boolean,
|
|
1174
1158
|
reflect: !0
|
|
1175
|
-
})],
|
|
1159
|
+
})], j.prototype, "interactive", void 0), customElements.get("void-list-item") || customElements.define("void-list-item", j);
|
|
1176
1160
|
//#endregion
|
|
1177
1161
|
//#region src/components/toast.ts
|
|
1178
|
-
var
|
|
1162
|
+
var M = class extends o {
|
|
1179
1163
|
constructor(...e) {
|
|
1180
1164
|
super(...e), this.color = "default", this.duration = 5e3, this.dismissable = !0, this.heading = "";
|
|
1181
1165
|
}
|
|
@@ -1194,7 +1178,6 @@ var F = class extends o {
|
|
|
1194
1178
|
render() {
|
|
1195
1179
|
return t`
|
|
1196
1180
|
${this.heading ? t`<span class='void-toast-heading'>${this.heading}</span>` : n}
|
|
1197
|
-
<slot></slot>
|
|
1198
1181
|
${this.dismissable ? t`<button class='void-toast-close' aria-label='Close' @click='${this._close}'>×</button>` : n}
|
|
1199
1182
|
`;
|
|
1200
1183
|
}
|
|
@@ -1202,20 +1185,17 @@ var F = class extends o {
|
|
|
1202
1185
|
s([r({
|
|
1203
1186
|
type: String,
|
|
1204
1187
|
reflect: !0
|
|
1205
|
-
})],
|
|
1188
|
+
})], M.prototype, "color", void 0), s([r({ type: Number })], M.prototype, "duration", void 0), s([r({
|
|
1206
1189
|
type: Boolean,
|
|
1207
1190
|
reflect: !0
|
|
1208
|
-
})],
|
|
1209
|
-
var
|
|
1191
|
+
})], M.prototype, "dismissable", void 0), s([r({ type: String })], M.prototype, "heading", void 0), customElements.get("void-toast") || customElements.define("void-toast", M);
|
|
1192
|
+
var ae = class extends o {
|
|
1210
1193
|
constructor(...e) {
|
|
1211
1194
|
super(...e), this.position = "bottom-right";
|
|
1212
1195
|
}
|
|
1213
1196
|
connectedCallback() {
|
|
1214
1197
|
super.connectedCallback(), this.setAttribute("role", "region"), this.setAttribute("aria-label", "Notifications"), this.setAttribute("aria-live", "polite");
|
|
1215
1198
|
}
|
|
1216
|
-
render() {
|
|
1217
|
-
return n;
|
|
1218
|
-
}
|
|
1219
1199
|
static show(e) {
|
|
1220
1200
|
let t = document.querySelector("void-toast-container");
|
|
1221
1201
|
t || (t = document.createElement("void-toast-container"), document.body.appendChild(t));
|
|
@@ -1226,10 +1206,10 @@ var I = class extends o {
|
|
|
1226
1206
|
s([r({
|
|
1227
1207
|
type: String,
|
|
1228
1208
|
reflect: !0
|
|
1229
|
-
})],
|
|
1209
|
+
})], ae.prototype, "position", void 0), customElements.get("void-toast-container") || customElements.define("void-toast-container", ae);
|
|
1230
1210
|
//#endregion
|
|
1231
1211
|
//#region src/components/stepper.ts
|
|
1232
|
-
var
|
|
1212
|
+
var N = class extends o {
|
|
1233
1213
|
constructor(...e) {
|
|
1234
1214
|
super(...e), this.value = 0, this.steps = "";
|
|
1235
1215
|
}
|
|
@@ -1266,10 +1246,10 @@ var L = class extends o {
|
|
|
1266
1246
|
s([r({
|
|
1267
1247
|
type: Number,
|
|
1268
1248
|
reflect: !0
|
|
1269
|
-
})],
|
|
1249
|
+
})], N.prototype, "value", void 0), s([r({ reflect: !0 })], N.prototype, "steps", void 0), customElements.get("void-stepper") || customElements.define("void-stepper", N);
|
|
1270
1250
|
//#endregion
|
|
1271
1251
|
//#region src/components/drawer.ts
|
|
1272
|
-
var
|
|
1252
|
+
var P = class extends o {
|
|
1273
1253
|
constructor(...e) {
|
|
1274
1254
|
super(...e), this.open = !1, this.side = "right", this.size = "md", this.heading = "", this.closable = !0, this._userContent = [], this._didSetup = !1, this._handleKeydown = (e) => {
|
|
1275
1255
|
e.key === "Escape" && this.open && this.closable && this._close();
|
|
@@ -1314,19 +1294,19 @@ var R = class extends o {
|
|
|
1314
1294
|
s([r({
|
|
1315
1295
|
type: Boolean,
|
|
1316
1296
|
reflect: !0
|
|
1317
|
-
})],
|
|
1297
|
+
})], P.prototype, "open", void 0), s([r({
|
|
1318
1298
|
type: String,
|
|
1319
1299
|
reflect: !0
|
|
1320
|
-
})],
|
|
1300
|
+
})], P.prototype, "side", void 0), s([r({
|
|
1321
1301
|
type: String,
|
|
1322
1302
|
reflect: !0
|
|
1323
|
-
})],
|
|
1303
|
+
})], P.prototype, "size", void 0), s([r({ type: String })], P.prototype, "heading", void 0), s([r({
|
|
1324
1304
|
type: Boolean,
|
|
1325
1305
|
reflect: !0
|
|
1326
|
-
})],
|
|
1306
|
+
})], P.prototype, "closable", void 0), customElements.get("void-drawer") || customElements.define("void-drawer", P);
|
|
1327
1307
|
//#endregion
|
|
1328
1308
|
//#region src/components/card.ts
|
|
1329
|
-
var
|
|
1309
|
+
var F = class extends o {
|
|
1330
1310
|
constructor(...e) {
|
|
1331
1311
|
super(...e), this.heading = "", this.variant = "default", this.padding = "md", this._userContent = [], this._didSetup = !1;
|
|
1332
1312
|
}
|
|
@@ -1344,16 +1324,16 @@ var z = class extends o {
|
|
|
1344
1324
|
return t`${this.heading ? t`<div class="void-card-header"><span class="void-card-heading">${this.heading}</span></div>` : n}<div class="void-card-body"></div>`;
|
|
1345
1325
|
}
|
|
1346
1326
|
};
|
|
1347
|
-
s([r({ type: String })],
|
|
1327
|
+
s([r({ type: String })], F.prototype, "heading", void 0), s([r({
|
|
1348
1328
|
type: String,
|
|
1349
1329
|
reflect: !0
|
|
1350
|
-
})],
|
|
1330
|
+
})], F.prototype, "variant", void 0), s([r({
|
|
1351
1331
|
type: String,
|
|
1352
1332
|
reflect: !0
|
|
1353
|
-
})],
|
|
1333
|
+
})], F.prototype, "padding", void 0), customElements.get("void-card") || customElements.define("void-card", F);
|
|
1354
1334
|
//#endregion
|
|
1355
1335
|
//#region src/components/popover.ts
|
|
1356
|
-
var
|
|
1336
|
+
var I = class extends o {
|
|
1357
1337
|
constructor(...e) {
|
|
1358
1338
|
super(...e), this.open = !1, this.position = "bottom", this.trigger = "click", this._triggerEl = null, this._contentNodes = [], this._didSetup = !1, this._handleTriggerClick = () => {
|
|
1359
1339
|
this.open = !this.open, this.open || this._dispatchClose();
|
|
@@ -1364,7 +1344,7 @@ var B = class extends o {
|
|
|
1364
1344
|
};
|
|
1365
1345
|
}
|
|
1366
1346
|
connectedCallback() {
|
|
1367
|
-
super.connectedCallback(), this._didSetup || (this._triggerEl = this.children[0] ?? null, this._contentNodes = Array.from(this.childNodes).
|
|
1347
|
+
super.connectedCallback(), this._didSetup || (this._triggerEl = this.children[0] ?? null, this._contentNodes = Array.from(this.childNodes).filter((e) => e !== this._triggerEl)), document.addEventListener("mousedown", this._handleOutsideClick), document.addEventListener("keydown", this._handleKeydown);
|
|
1368
1348
|
}
|
|
1369
1349
|
disconnectedCallback() {
|
|
1370
1350
|
super.disconnectedCallback(), document.removeEventListener("mousedown", this._handleOutsideClick), document.removeEventListener("keydown", this._handleKeydown);
|
|
@@ -1388,23 +1368,20 @@ var B = class extends o {
|
|
|
1388
1368
|
composed: !0
|
|
1389
1369
|
}));
|
|
1390
1370
|
}
|
|
1391
|
-
render() {
|
|
1392
|
-
return n;
|
|
1393
|
-
}
|
|
1394
1371
|
};
|
|
1395
1372
|
s([r({
|
|
1396
1373
|
type: Boolean,
|
|
1397
1374
|
reflect: !0
|
|
1398
|
-
})],
|
|
1375
|
+
})], I.prototype, "open", void 0), s([r({
|
|
1399
1376
|
type: String,
|
|
1400
1377
|
reflect: !0
|
|
1401
|
-
})],
|
|
1378
|
+
})], I.prototype, "position", void 0), s([r({
|
|
1402
1379
|
type: String,
|
|
1403
1380
|
reflect: !0
|
|
1404
|
-
})],
|
|
1381
|
+
})], I.prototype, "trigger", void 0), customElements.get("void-popover") || customElements.define("void-popover", I);
|
|
1405
1382
|
//#endregion
|
|
1406
1383
|
//#region src/components/tooltip.ts
|
|
1407
|
-
var
|
|
1384
|
+
var L = class extends o {
|
|
1408
1385
|
constructor(...e) {
|
|
1409
1386
|
super(...e), this.text = "", this.position = "top", this.delay = 200, this._visible = !1, this._tooltipId = "void-tooltip-" + Math.random().toString(36).slice(2), this._userContent = [], this._didSetup = !1, this._onMouseEnter = () => {
|
|
1410
1387
|
clearTimeout(this._timerId), this._timerId = setTimeout(() => {
|
|
@@ -1438,13 +1415,13 @@ var V = class extends o {
|
|
|
1438
1415
|
return t`<span id="${this._tooltipId}" class="void-tooltip-bubble" role="tooltip" aria-label=${this.text}>${this.text}</span>`;
|
|
1439
1416
|
}
|
|
1440
1417
|
};
|
|
1441
|
-
s([r({ type: String })],
|
|
1418
|
+
s([r({ type: String })], L.prototype, "text", void 0), s([r({
|
|
1442
1419
|
type: String,
|
|
1443
1420
|
reflect: !0
|
|
1444
|
-
})],
|
|
1421
|
+
})], L.prototype, "position", void 0), s([r({ type: Number })], L.prototype, "delay", void 0), s([a()], L.prototype, "_visible", void 0), customElements.get("void-tooltip") || customElements.define("void-tooltip", L);
|
|
1445
1422
|
//#endregion
|
|
1446
1423
|
//#region src/components/banner.ts
|
|
1447
|
-
var
|
|
1424
|
+
var R = class extends o {
|
|
1448
1425
|
constructor(...e) {
|
|
1449
1426
|
super(...e), this.color = "default", this.dismissable = !1, this.variant = "subtle", this._userContent = [], this._didSetup = !1;
|
|
1450
1427
|
}
|
|
@@ -1470,16 +1447,16 @@ var H = class extends o {
|
|
|
1470
1447
|
s([r({
|
|
1471
1448
|
type: String,
|
|
1472
1449
|
reflect: !0
|
|
1473
|
-
})],
|
|
1450
|
+
})], R.prototype, "color", void 0), s([r({
|
|
1474
1451
|
type: Boolean,
|
|
1475
1452
|
reflect: !0
|
|
1476
|
-
})],
|
|
1453
|
+
})], R.prototype, "dismissable", void 0), s([r({
|
|
1477
1454
|
type: String,
|
|
1478
1455
|
reflect: !0
|
|
1479
|
-
})],
|
|
1456
|
+
})], R.prototype, "variant", void 0), customElements.get("void-banner") || customElements.define("void-banner", R);
|
|
1480
1457
|
//#endregion
|
|
1481
1458
|
//#region src/components/scroll-area.ts
|
|
1482
|
-
var
|
|
1459
|
+
var z = class extends o {
|
|
1483
1460
|
constructor(...e) {
|
|
1484
1461
|
super(...e), this.maxHeight = "", this.direction = "vertical", this._userContent = [], this._didSetup = !1;
|
|
1485
1462
|
}
|
|
@@ -1499,36 +1476,33 @@ var U = class extends o {
|
|
|
1499
1476
|
return t`<div class="void-scroll-area-viewport"></div>`;
|
|
1500
1477
|
}
|
|
1501
1478
|
};
|
|
1502
|
-
s([r({ type: String })],
|
|
1479
|
+
s([r({ type: String })], z.prototype, "maxHeight", void 0), s([r({
|
|
1503
1480
|
type: String,
|
|
1504
1481
|
reflect: !0
|
|
1505
|
-
})],
|
|
1482
|
+
})], z.prototype, "direction", void 0), customElements.get("void-scroll-area") || customElements.define("void-scroll-area", z);
|
|
1506
1483
|
//#endregion
|
|
1507
1484
|
//#region src/components/table.ts
|
|
1508
|
-
var
|
|
1485
|
+
var B = class extends o {
|
|
1509
1486
|
constructor(...e) {
|
|
1510
1487
|
super(...e), this.striped = !1, this.hoverable = !1, this.compact = !1, this.bordered = !1;
|
|
1511
1488
|
}
|
|
1512
|
-
render() {
|
|
1513
|
-
return n;
|
|
1514
|
-
}
|
|
1515
1489
|
};
|
|
1516
1490
|
s([r({
|
|
1517
1491
|
type: Boolean,
|
|
1518
1492
|
reflect: !0
|
|
1519
|
-
})],
|
|
1493
|
+
})], B.prototype, "striped", void 0), s([r({
|
|
1520
1494
|
type: Boolean,
|
|
1521
1495
|
reflect: !0
|
|
1522
|
-
})],
|
|
1496
|
+
})], B.prototype, "hoverable", void 0), s([r({
|
|
1523
1497
|
type: Boolean,
|
|
1524
1498
|
reflect: !0
|
|
1525
|
-
})],
|
|
1499
|
+
})], B.prototype, "compact", void 0), s([r({
|
|
1526
1500
|
type: Boolean,
|
|
1527
1501
|
reflect: !0
|
|
1528
|
-
})],
|
|
1502
|
+
})], B.prototype, "bordered", void 0), customElements.get("void-table") || customElements.define("void-table", B);
|
|
1529
1503
|
//#endregion
|
|
1530
1504
|
//#region src/components/pagination.ts
|
|
1531
|
-
var
|
|
1505
|
+
var V = class extends o {
|
|
1532
1506
|
constructor(...e) {
|
|
1533
1507
|
super(...e), this.total = 1, this.value = 1, this.siblings = 1, this.size = "md";
|
|
1534
1508
|
}
|
|
@@ -1573,16 +1547,16 @@ var G = class extends o {
|
|
|
1573
1547
|
`;
|
|
1574
1548
|
}
|
|
1575
1549
|
};
|
|
1576
|
-
s([r({ type: Number })],
|
|
1550
|
+
s([r({ type: Number })], V.prototype, "total", void 0), s([r({
|
|
1577
1551
|
type: Number,
|
|
1578
1552
|
reflect: !0
|
|
1579
|
-
})],
|
|
1553
|
+
})], V.prototype, "value", void 0), s([r({ type: Number })], V.prototype, "siblings", void 0), s([r({
|
|
1580
1554
|
type: String,
|
|
1581
1555
|
reflect: !0
|
|
1582
|
-
})],
|
|
1556
|
+
})], V.prototype, "size", void 0), customElements.get("void-pagination") || customElements.define("void-pagination", V);
|
|
1583
1557
|
//#endregion
|
|
1584
1558
|
//#region src/components/error-fallback.ts
|
|
1585
|
-
var
|
|
1559
|
+
var H = class extends o {
|
|
1586
1560
|
constructor(...e) {
|
|
1587
1561
|
super(...e), this.heading = "Something went wrong", this.message = "", this.retryable = !1, this.retryLabel = "Try again", this.icon = !0;
|
|
1588
1562
|
}
|
|
@@ -1606,13 +1580,13 @@ var K = class extends o {
|
|
|
1606
1580
|
`;
|
|
1607
1581
|
}
|
|
1608
1582
|
};
|
|
1609
|
-
s([r({ type: String })],
|
|
1583
|
+
s([r({ type: String })], H.prototype, "heading", void 0), s([r({ type: String })], H.prototype, "message", void 0), s([r({
|
|
1610
1584
|
type: Boolean,
|
|
1611
1585
|
reflect: !0
|
|
1612
|
-
})],
|
|
1586
|
+
})], H.prototype, "retryable", void 0), s([r({ type: String })], H.prototype, "retryLabel", void 0), s([r({ type: Boolean })], H.prototype, "icon", void 0), customElements.get("void-error-fallback") || customElements.define("void-error-fallback", H);
|
|
1613
1587
|
//#endregion
|
|
1614
1588
|
//#region src/components/checkbox-group.ts
|
|
1615
|
-
var
|
|
1589
|
+
var U = class extends o {
|
|
1616
1590
|
constructor(...e) {
|
|
1617
1591
|
super(...e), this.label = "", this.orientation = "vertical", this._userContent = [], this._didSetup = !1, this._handleChildChange = (e) => {
|
|
1618
1592
|
let t = e.target;
|
|
@@ -1649,13 +1623,13 @@ var q = class extends o {
|
|
|
1649
1623
|
s([r({
|
|
1650
1624
|
type: String,
|
|
1651
1625
|
reflect: !0
|
|
1652
|
-
})],
|
|
1626
|
+
})], U.prototype, "label", void 0), s([r({
|
|
1653
1627
|
type: String,
|
|
1654
1628
|
reflect: !0
|
|
1655
|
-
})],
|
|
1629
|
+
})], U.prototype, "orientation", void 0), customElements.get("void-checkbox-group") || customElements.define("void-checkbox-group", U);
|
|
1656
1630
|
//#endregion
|
|
1657
1631
|
//#region src/components/combobox.ts
|
|
1658
|
-
var
|
|
1632
|
+
var W = class extends o {
|
|
1659
1633
|
constructor(...e) {
|
|
1660
1634
|
super(...e), this.value = "", this.placeholder = "Search...", this.disabled = !1, this.size = "md", this.error = "", this.name = "", this._open = !1, this._query = "", this._options = [], this._onInputFocus = () => {
|
|
1661
1635
|
this.disabled || (this._open = !0, this._query = "", this.requestUpdate());
|
|
@@ -1724,22 +1698,22 @@ var J = class extends o {
|
|
|
1724
1698
|
}));
|
|
1725
1699
|
}
|
|
1726
1700
|
};
|
|
1727
|
-
s([r({ type: String })],
|
|
1701
|
+
s([r({ type: String })], W.prototype, "value", void 0), s([r({ type: String })], W.prototype, "placeholder", void 0), s([r({
|
|
1728
1702
|
type: Boolean,
|
|
1729
1703
|
reflect: !0
|
|
1730
|
-
})],
|
|
1704
|
+
})], W.prototype, "disabled", void 0), s([r({
|
|
1731
1705
|
type: String,
|
|
1732
1706
|
reflect: !0
|
|
1733
|
-
})],
|
|
1707
|
+
})], W.prototype, "size", void 0), s([r({
|
|
1734
1708
|
type: String,
|
|
1735
1709
|
reflect: !0
|
|
1736
|
-
})],
|
|
1710
|
+
})], W.prototype, "error", void 0), s([r({
|
|
1737
1711
|
type: String,
|
|
1738
1712
|
reflect: !0
|
|
1739
|
-
})],
|
|
1713
|
+
})], W.prototype, "name", void 0), customElements.get("void-combobox") || customElements.define("void-combobox", W);
|
|
1740
1714
|
//#endregion
|
|
1741
1715
|
//#region src/components/slider.ts
|
|
1742
|
-
var
|
|
1716
|
+
var G = class extends o {
|
|
1743
1717
|
constructor(...e) {
|
|
1744
1718
|
super(...e), this.value = 50, this.min = 0, this.max = 100, this.step = 1, this.disabled = !1, this.name = "", this.showValue = !1, this.size = "md";
|
|
1745
1719
|
}
|
|
@@ -1787,22 +1761,22 @@ var Y = class extends o {
|
|
|
1787
1761
|
`;
|
|
1788
1762
|
}
|
|
1789
1763
|
};
|
|
1790
|
-
s([r({ type: Number })],
|
|
1764
|
+
s([r({ type: Number })], G.prototype, "value", void 0), s([r({ type: Number })], G.prototype, "min", void 0), s([r({ type: Number })], G.prototype, "max", void 0), s([r({ type: Number })], G.prototype, "step", void 0), s([r({
|
|
1791
1765
|
type: Boolean,
|
|
1792
1766
|
reflect: !0
|
|
1793
|
-
})],
|
|
1767
|
+
})], G.prototype, "disabled", void 0), s([r({
|
|
1794
1768
|
type: String,
|
|
1795
1769
|
reflect: !0
|
|
1796
|
-
})],
|
|
1770
|
+
})], G.prototype, "name", void 0), s([r({
|
|
1797
1771
|
type: Boolean,
|
|
1798
1772
|
reflect: !0
|
|
1799
|
-
})],
|
|
1773
|
+
})], G.prototype, "showValue", void 0), s([r({
|
|
1800
1774
|
type: String,
|
|
1801
1775
|
reflect: !0
|
|
1802
|
-
})],
|
|
1776
|
+
})], G.prototype, "size", void 0), customElements.get("void-slider") || customElements.define("void-slider", G);
|
|
1803
1777
|
//#endregion
|
|
1804
1778
|
//#region src/components/file-upload.ts
|
|
1805
|
-
var
|
|
1779
|
+
var K = class extends o {
|
|
1806
1780
|
constructor(...e) {
|
|
1807
1781
|
super(...e), this.accept = "", this.multiple = !1, this.disabled = !1, this.maxSize = 0, this.error = "", this._files = [], this._onDropzoneClick = () => {
|
|
1808
1782
|
this.disabled || this._input?.click();
|
|
@@ -1883,19 +1857,19 @@ var X = class extends o {
|
|
|
1883
1857
|
}));
|
|
1884
1858
|
}
|
|
1885
1859
|
};
|
|
1886
|
-
s([r({ type: String })],
|
|
1860
|
+
s([r({ type: String })], K.prototype, "accept", void 0), s([r({
|
|
1887
1861
|
type: Boolean,
|
|
1888
1862
|
reflect: !0
|
|
1889
|
-
})],
|
|
1863
|
+
})], K.prototype, "multiple", void 0), s([r({
|
|
1890
1864
|
type: Boolean,
|
|
1891
1865
|
reflect: !0
|
|
1892
|
-
})],
|
|
1866
|
+
})], K.prototype, "disabled", void 0), s([r({ type: Number })], K.prototype, "maxSize", void 0), s([r({
|
|
1893
1867
|
type: String,
|
|
1894
1868
|
reflect: !0
|
|
1895
|
-
})],
|
|
1869
|
+
})], K.prototype, "error", void 0), customElements.get("void-file-upload") || customElements.define("void-file-upload", K);
|
|
1896
1870
|
//#endregion
|
|
1897
1871
|
//#region src/components/nav-bar.ts
|
|
1898
|
-
var
|
|
1872
|
+
var q = class extends o {
|
|
1899
1873
|
constructor(...e) {
|
|
1900
1874
|
super(...e), this.sticky = !1, this.bordered = !0, this.variant = "default", this._userContent = [], this._didSetup = !1;
|
|
1901
1875
|
}
|
|
@@ -1916,16 +1890,16 @@ var Z = class extends o {
|
|
|
1916
1890
|
s([r({
|
|
1917
1891
|
type: Boolean,
|
|
1918
1892
|
reflect: !0
|
|
1919
|
-
})],
|
|
1893
|
+
})], q.prototype, "sticky", void 0), s([r({
|
|
1920
1894
|
type: Boolean,
|
|
1921
1895
|
reflect: !0
|
|
1922
|
-
})],
|
|
1896
|
+
})], q.prototype, "bordered", void 0), s([r({
|
|
1923
1897
|
type: String,
|
|
1924
1898
|
reflect: !0
|
|
1925
|
-
})],
|
|
1899
|
+
})], q.prototype, "variant", void 0), customElements.get("void-nav-bar") || customElements.define("void-nav-bar", q);
|
|
1926
1900
|
//#endregion
|
|
1927
1901
|
//#region src/components/hamburger.ts
|
|
1928
|
-
var
|
|
1902
|
+
var oe = class extends o {
|
|
1929
1903
|
constructor(...e) {
|
|
1930
1904
|
super(...e), this.active = !1, this.size = "md", this._handleClick = () => {
|
|
1931
1905
|
this.active = !this.active, this.dispatchEvent(new CustomEvent("void-toggle", {
|
|
@@ -1959,13 +1933,13 @@ var Q = class extends o {
|
|
|
1959
1933
|
s([r({
|
|
1960
1934
|
type: Boolean,
|
|
1961
1935
|
reflect: !0
|
|
1962
|
-
})],
|
|
1936
|
+
})], oe.prototype, "active", void 0), s([r({
|
|
1963
1937
|
type: String,
|
|
1964
1938
|
reflect: !0
|
|
1965
|
-
})],
|
|
1939
|
+
})], oe.prototype, "size", void 0), customElements.get("void-hamburger") || customElements.define("void-hamburger", oe);
|
|
1966
1940
|
//#endregion
|
|
1967
1941
|
//#region src/components/compose-input.ts
|
|
1968
|
-
var
|
|
1942
|
+
var J = class extends o {
|
|
1969
1943
|
constructor(...e) {
|
|
1970
1944
|
super(...e), this.value = "", this.placeholder = "Type a message...", this.disabled = !1, this.maxlength = 0;
|
|
1971
1945
|
}
|
|
@@ -2017,15 +1991,296 @@ var $ = class extends o {
|
|
|
2017
1991
|
}));
|
|
2018
1992
|
}
|
|
2019
1993
|
};
|
|
2020
|
-
s([r({ type: String })],
|
|
1994
|
+
s([r({ type: String })], J.prototype, "value", void 0), s([r({
|
|
1995
|
+
type: String,
|
|
1996
|
+
reflect: !0
|
|
1997
|
+
})], J.prototype, "placeholder", void 0), s([r({
|
|
1998
|
+
type: Boolean,
|
|
1999
|
+
reflect: !0
|
|
2000
|
+
})], J.prototype, "disabled", void 0), s([r({
|
|
2001
|
+
type: Number,
|
|
2002
|
+
reflect: !0
|
|
2003
|
+
})], J.prototype, "maxlength", void 0), s([i(".void-compose-input-textarea")], J.prototype, "_textarea", void 0), customElements.get("void-compose-input") || customElements.define("void-compose-input", J);
|
|
2004
|
+
//#endregion
|
|
2005
|
+
//#region src/components/sidebar.ts
|
|
2006
|
+
var Y = class extends o {
|
|
2007
|
+
constructor(...e) {
|
|
2008
|
+
super(...e), this.collapsed = !1, this.width = "240px", this.collapsedWidth = "60px", this.position = "left";
|
|
2009
|
+
}
|
|
2010
|
+
connectedCallback() {
|
|
2011
|
+
super.connectedCallback(), this.setAttribute("role", "navigation"), this.setAttribute("aria-label", "Sidebar navigation"), this._updateWidth();
|
|
2012
|
+
}
|
|
2013
|
+
disconnectedCallback() {
|
|
2014
|
+
super.disconnectedCallback();
|
|
2015
|
+
}
|
|
2016
|
+
updated(e) {
|
|
2017
|
+
e.has("collapsed") && (this._updateWidth(), this.dispatchEvent(new CustomEvent("void-toggle", {
|
|
2018
|
+
bubbles: !0,
|
|
2019
|
+
composed: !0,
|
|
2020
|
+
detail: { collapsed: this.collapsed }
|
|
2021
|
+
}))), (e.has("width") || e.has("collapsedWidth")) && this._updateWidth();
|
|
2022
|
+
}
|
|
2023
|
+
_updateWidth() {
|
|
2024
|
+
this.style.setProperty("--void-sidebar-width", this.collapsed ? this.collapsedWidth : this.width);
|
|
2025
|
+
}
|
|
2026
|
+
};
|
|
2027
|
+
s([r({
|
|
2028
|
+
type: Boolean,
|
|
2029
|
+
reflect: !0
|
|
2030
|
+
})], Y.prototype, "collapsed", void 0), s([r({
|
|
2021
2031
|
type: String,
|
|
2022
2032
|
reflect: !0
|
|
2023
|
-
})],
|
|
2033
|
+
})], Y.prototype, "width", void 0), s([r({
|
|
2034
|
+
type: String,
|
|
2035
|
+
reflect: !0
|
|
2036
|
+
})], Y.prototype, "collapsedWidth", void 0), s([r({
|
|
2037
|
+
type: String,
|
|
2038
|
+
reflect: !0
|
|
2039
|
+
})], Y.prototype, "position", void 0), customElements.get("void-sidebar") || customElements.define("void-sidebar", Y);
|
|
2040
|
+
//#endregion
|
|
2041
|
+
//#region src/components/toggle.ts
|
|
2042
|
+
var X = class extends o {
|
|
2043
|
+
constructor(...e) {
|
|
2044
|
+
super(...e), this.pressed = !1, this.disabled = !1, this.color = "default", this.size = "md", this.variant = "outline", this._handleClick = () => {
|
|
2045
|
+
this.disabled || (this.pressed = !this.pressed, this.dispatchEvent(new CustomEvent("void-change", {
|
|
2046
|
+
bubbles: !0,
|
|
2047
|
+
composed: !0,
|
|
2048
|
+
detail: { pressed: this.pressed }
|
|
2049
|
+
})));
|
|
2050
|
+
}, this._handleKeydown = (e) => {
|
|
2051
|
+
(e.key === " " || e.key === "Enter") && !this.disabled && (e.preventDefault(), this._handleClick());
|
|
2052
|
+
};
|
|
2053
|
+
}
|
|
2054
|
+
connectedCallback() {
|
|
2055
|
+
super.connectedCallback(), this.setAttribute("role", "button"), this.setAttribute("tabindex", this.disabled ? "-1" : "0"), this.setAttribute("aria-pressed", String(this.pressed)), this.addEventListener("click", this._handleClick), this.addEventListener("keydown", this._handleKeydown);
|
|
2056
|
+
}
|
|
2057
|
+
disconnectedCallback() {
|
|
2058
|
+
super.disconnectedCallback(), this.removeEventListener("click", this._handleClick), this.removeEventListener("keydown", this._handleKeydown);
|
|
2059
|
+
}
|
|
2060
|
+
updated(e) {
|
|
2061
|
+
e.has("pressed") && this.setAttribute("aria-pressed", String(this.pressed)), e.has("disabled") && (this.setAttribute("aria-disabled", String(this.disabled)), this.setAttribute("tabindex", this.disabled ? "-1" : "0"));
|
|
2062
|
+
}
|
|
2063
|
+
};
|
|
2064
|
+
s([r({
|
|
2024
2065
|
type: Boolean,
|
|
2025
2066
|
reflect: !0
|
|
2026
|
-
})],
|
|
2067
|
+
})], X.prototype, "pressed", void 0), s([r({
|
|
2068
|
+
type: Boolean,
|
|
2069
|
+
reflect: !0
|
|
2070
|
+
})], X.prototype, "disabled", void 0), s([r({
|
|
2071
|
+
type: String,
|
|
2072
|
+
reflect: !0
|
|
2073
|
+
})], X.prototype, "color", void 0), s([r({
|
|
2074
|
+
type: String,
|
|
2075
|
+
reflect: !0
|
|
2076
|
+
})], X.prototype, "size", void 0), s([r({
|
|
2077
|
+
type: String,
|
|
2078
|
+
reflect: !0
|
|
2079
|
+
})], X.prototype, "variant", void 0), customElements.get("void-toggle") || customElements.define("void-toggle", X);
|
|
2080
|
+
//#endregion
|
|
2081
|
+
//#region src/components/segmented-control.ts
|
|
2082
|
+
var se = class extends o {
|
|
2083
|
+
constructor(...e) {
|
|
2084
|
+
super(...e), this.value = "", this.disabled = !1;
|
|
2085
|
+
}
|
|
2086
|
+
connectedCallback() {
|
|
2087
|
+
super.connectedCallback(), this.setAttribute("role", "radio"), this.setAttribute("tabindex", this.disabled ? "-1" : "0");
|
|
2088
|
+
}
|
|
2089
|
+
updated(e) {
|
|
2090
|
+
e.has("disabled") && this.setAttribute("tabindex", this.disabled ? "-1" : "0");
|
|
2091
|
+
}
|
|
2092
|
+
};
|
|
2093
|
+
s([r({
|
|
2094
|
+
type: String,
|
|
2095
|
+
reflect: !0
|
|
2096
|
+
})], se.prototype, "value", void 0), s([r({
|
|
2097
|
+
type: Boolean,
|
|
2098
|
+
reflect: !0
|
|
2099
|
+
})], se.prototype, "disabled", void 0), customElements.get("void-segmented-control-item") || customElements.define("void-segmented-control-item", se);
|
|
2100
|
+
var Z = class extends o {
|
|
2101
|
+
constructor(...e) {
|
|
2102
|
+
super(...e), this.value = "", this.size = "md", this.color = "default", this._handleClick = (e) => {
|
|
2103
|
+
let t = e.target.closest("void-segmented-control-item");
|
|
2104
|
+
!t || t.disabled || (this.value = t.value, this.dispatchEvent(new CustomEvent("void-change", {
|
|
2105
|
+
bubbles: !0,
|
|
2106
|
+
composed: !0,
|
|
2107
|
+
detail: { value: this.value }
|
|
2108
|
+
})));
|
|
2109
|
+
}, this._handleKeydown = (e) => {
|
|
2110
|
+
let t = Array.from(this.querySelectorAll("void-segmented-control-item:not([disabled])")), n = t.findIndex((e) => e.value === this.value);
|
|
2111
|
+
if (e.key === "ArrowRight" || e.key === "ArrowDown") {
|
|
2112
|
+
e.preventDefault();
|
|
2113
|
+
let r = (n + 1) % t.length;
|
|
2114
|
+
t[r].focus(), t[r].click();
|
|
2115
|
+
} else if (e.key === "ArrowLeft" || e.key === "ArrowUp") {
|
|
2116
|
+
e.preventDefault();
|
|
2117
|
+
let r = (n - 1 + t.length) % t.length;
|
|
2118
|
+
t[r].focus(), t[r].click();
|
|
2119
|
+
}
|
|
2120
|
+
};
|
|
2121
|
+
}
|
|
2122
|
+
connectedCallback() {
|
|
2123
|
+
super.connectedCallback(), this.setAttribute("role", "radiogroup"), this.addEventListener("click", this._handleClick), this.addEventListener("keydown", this._handleKeydown), this._syncItems();
|
|
2124
|
+
}
|
|
2125
|
+
disconnectedCallback() {
|
|
2126
|
+
super.disconnectedCallback(), this.removeEventListener("click", this._handleClick), this.removeEventListener("keydown", this._handleKeydown);
|
|
2127
|
+
}
|
|
2128
|
+
updated(e) {
|
|
2129
|
+
e.has("value") && this._syncItems();
|
|
2130
|
+
}
|
|
2131
|
+
_syncItems() {
|
|
2132
|
+
let e = Array.from(this.querySelectorAll("void-segmented-control-item"));
|
|
2133
|
+
for (let t of e) t.setAttribute("aria-checked", String(t.value === this.value));
|
|
2134
|
+
}
|
|
2135
|
+
};
|
|
2136
|
+
s([r({
|
|
2137
|
+
type: String,
|
|
2138
|
+
reflect: !0
|
|
2139
|
+
})], Z.prototype, "value", void 0), s([r({
|
|
2140
|
+
type: String,
|
|
2141
|
+
reflect: !0
|
|
2142
|
+
})], Z.prototype, "size", void 0), s([r({
|
|
2143
|
+
type: String,
|
|
2144
|
+
reflect: !0
|
|
2145
|
+
})], Z.prototype, "color", void 0), customElements.get("void-segmented-control") || customElements.define("void-segmented-control", Z);
|
|
2146
|
+
//#endregion
|
|
2147
|
+
//#region src/components/stat.ts
|
|
2148
|
+
var Q = class extends o {
|
|
2149
|
+
constructor(...e) {
|
|
2150
|
+
super(...e), this.label = "", this.value = "", this.delta = "", this.trend = null, this.color = "default", this.size = "md";
|
|
2151
|
+
}
|
|
2152
|
+
connectedCallback() {
|
|
2153
|
+
super.connectedCallback(), this.setAttribute("role", "figure");
|
|
2154
|
+
}
|
|
2155
|
+
render() {
|
|
2156
|
+
return t`
|
|
2157
|
+
${this.label ? t`<span class="void-stat-label">${this.label}</span>` : ""}
|
|
2158
|
+
<span class="void-stat-value">${this.value}</span>
|
|
2159
|
+
${this.delta ? t`<span class="void-stat-delta">${this.delta}</span>` : ""}
|
|
2160
|
+
`;
|
|
2161
|
+
}
|
|
2162
|
+
};
|
|
2163
|
+
s([r({
|
|
2164
|
+
type: String,
|
|
2165
|
+
reflect: !0
|
|
2166
|
+
})], Q.prototype, "label", void 0), s([r({
|
|
2167
|
+
type: String,
|
|
2168
|
+
reflect: !0
|
|
2169
|
+
})], Q.prototype, "value", void 0), s([r({
|
|
2170
|
+
type: String,
|
|
2171
|
+
reflect: !0
|
|
2172
|
+
})], Q.prototype, "delta", void 0), s([r({
|
|
2173
|
+
type: String,
|
|
2174
|
+
reflect: !0
|
|
2175
|
+
})], Q.prototype, "trend", void 0), s([r({
|
|
2176
|
+
type: String,
|
|
2177
|
+
reflect: !0
|
|
2178
|
+
})], Q.prototype, "color", void 0), s([r({
|
|
2179
|
+
type: String,
|
|
2180
|
+
reflect: !0
|
|
2181
|
+
})], Q.prototype, "size", void 0), customElements.get("void-stat") || customElements.define("void-stat", Q);
|
|
2182
|
+
//#endregion
|
|
2183
|
+
//#region src/components/dropdown-menu.ts
|
|
2184
|
+
var ce = class extends o {
|
|
2185
|
+
constructor(...e) {
|
|
2186
|
+
super(...e), this.open = !1, this.position = "bottom-start", this._triggerEl = null, this._panel = null, this._handleTriggerClick = () => {
|
|
2187
|
+
this.open = !this.open;
|
|
2188
|
+
}, this._handleOutsideClick = (e) => {
|
|
2189
|
+
this.open && !this.contains(e.target) && (this.open = !1);
|
|
2190
|
+
}, this._handleKeydown = (e) => {
|
|
2191
|
+
if (e.key === "Escape" && this.open && (this.open = !1, this._triggerEl?.focus()), this.open && (e.key === "ArrowDown" || e.key === "ArrowUp")) {
|
|
2192
|
+
e.preventDefault();
|
|
2193
|
+
let t = Array.from(this.querySelectorAll("void-dropdown-menu-item:not([disabled])"));
|
|
2194
|
+
if (!t.length) return;
|
|
2195
|
+
let n = t.indexOf(document.activeElement);
|
|
2196
|
+
e.key === "ArrowDown" ? (t[n + 1] ?? t[0]).focus() : (t[n - 1] ?? t[t.length - 1]).focus();
|
|
2197
|
+
}
|
|
2198
|
+
};
|
|
2199
|
+
}
|
|
2200
|
+
connectedCallback() {
|
|
2201
|
+
super.connectedCallback(), this._triggerEl = this.children[0] ?? null, this._panel = document.createElement("div"), this._panel.className = "void-dropdown-menu-panel", this._panel.setAttribute("role", "menu");
|
|
2202
|
+
let e = Array.from(this.childNodes);
|
|
2203
|
+
for (let t of e) t !== this._triggerEl && this._panel.appendChild(t);
|
|
2204
|
+
this.appendChild(this._panel), this._triggerEl?.addEventListener("click", this._handleTriggerClick), document.addEventListener("mousedown", this._handleOutsideClick), document.addEventListener("keydown", this._handleKeydown);
|
|
2205
|
+
}
|
|
2206
|
+
disconnectedCallback() {
|
|
2207
|
+
super.disconnectedCallback(), this._triggerEl?.removeEventListener("click", this._handleTriggerClick), document.removeEventListener("mousedown", this._handleOutsideClick), document.removeEventListener("keydown", this._handleKeydown);
|
|
2208
|
+
}
|
|
2209
|
+
};
|
|
2210
|
+
s([r({
|
|
2211
|
+
type: Boolean,
|
|
2212
|
+
reflect: !0
|
|
2213
|
+
})], ce.prototype, "open", void 0), s([r({
|
|
2214
|
+
type: String,
|
|
2215
|
+
reflect: !0
|
|
2216
|
+
})], ce.prototype, "position", void 0), customElements.get("void-dropdown-menu") || customElements.define("void-dropdown-menu", ce);
|
|
2217
|
+
var le = class extends o {
|
|
2218
|
+
constructor(...e) {
|
|
2219
|
+
super(...e), this.disabled = !1, this.destructive = !1, this._handleClick = (e) => {
|
|
2220
|
+
if (this.disabled) {
|
|
2221
|
+
e.stopImmediatePropagation();
|
|
2222
|
+
return;
|
|
2223
|
+
}
|
|
2224
|
+
this.dispatchEvent(new CustomEvent("void-select", {
|
|
2225
|
+
bubbles: !0,
|
|
2226
|
+
composed: !0,
|
|
2227
|
+
detail: { item: this }
|
|
2228
|
+
}));
|
|
2229
|
+
}, this._handleKeydown = (e) => {
|
|
2230
|
+
(e.key === "Enter" || e.key === " ") && !this.disabled && (e.preventDefault(), this._handleClick(e));
|
|
2231
|
+
};
|
|
2232
|
+
}
|
|
2233
|
+
connectedCallback() {
|
|
2234
|
+
super.connectedCallback(), this.setAttribute("role", "menuitem"), this.setAttribute("tabindex", this.disabled ? "-1" : "0"), this.addEventListener("click", this._handleClick), this.addEventListener("keydown", this._handleKeydown);
|
|
2235
|
+
}
|
|
2236
|
+
disconnectedCallback() {
|
|
2237
|
+
super.disconnectedCallback(), this.removeEventListener("click", this._handleClick), this.removeEventListener("keydown", this._handleKeydown);
|
|
2238
|
+
}
|
|
2239
|
+
updated(e) {
|
|
2240
|
+
e.has("disabled") && (this.setAttribute("tabindex", this.disabled ? "-1" : "0"), this.setAttribute("aria-disabled", String(this.disabled)));
|
|
2241
|
+
}
|
|
2242
|
+
};
|
|
2243
|
+
s([r({
|
|
2244
|
+
type: Boolean,
|
|
2245
|
+
reflect: !0
|
|
2246
|
+
})], le.prototype, "disabled", void 0), s([r({
|
|
2247
|
+
type: Boolean,
|
|
2248
|
+
reflect: !0
|
|
2249
|
+
})], le.prototype, "destructive", void 0), customElements.get("void-dropdown-menu-item") || customElements.define("void-dropdown-menu-item", le);
|
|
2250
|
+
//#endregion
|
|
2251
|
+
//#region src/components/indicator.ts
|
|
2252
|
+
var $ = class extends o {
|
|
2253
|
+
constructor(...e) {
|
|
2254
|
+
super(...e), this.color = "default", this.position = "top-right", this.count = null, this.ping = !1, this.size = "md";
|
|
2255
|
+
}
|
|
2256
|
+
connectedCallback() {
|
|
2257
|
+
super.connectedCallback(), this.setAttribute("role", "status"), this._dot = document.createElement("span"), this._dot.className = "void-indicator-dot", this._updateDot(), this.appendChild(this._dot);
|
|
2258
|
+
}
|
|
2259
|
+
disconnectedCallback() {
|
|
2260
|
+
super.disconnectedCallback(), this._dot?.remove();
|
|
2261
|
+
}
|
|
2262
|
+
updated() {
|
|
2263
|
+
this._updateDot();
|
|
2264
|
+
}
|
|
2265
|
+
_updateDot() {
|
|
2266
|
+
this._dot && (this._dot.textContent = this.count == null ? "" : String(this.count), this.setAttribute("aria-label", this.count == null ? "notification" : `${this.count} notifications`));
|
|
2267
|
+
}
|
|
2268
|
+
};
|
|
2269
|
+
s([r({
|
|
2270
|
+
type: String,
|
|
2271
|
+
reflect: !0
|
|
2272
|
+
})], $.prototype, "color", void 0), s([r({
|
|
2273
|
+
type: String,
|
|
2274
|
+
reflect: !0
|
|
2275
|
+
})], $.prototype, "position", void 0), s([r({
|
|
2027
2276
|
type: Number,
|
|
2028
2277
|
reflect: !0
|
|
2029
|
-
})], $.prototype, "
|
|
2278
|
+
})], $.prototype, "count", void 0), s([r({
|
|
2279
|
+
type: Boolean,
|
|
2280
|
+
reflect: !0
|
|
2281
|
+
})], $.prototype, "ping", void 0), s([r({
|
|
2282
|
+
type: String,
|
|
2283
|
+
reflect: !0
|
|
2284
|
+
})], $.prototype, "size", void 0), customElements.get("void-indicator") || customElements.define("void-indicator", $);
|
|
2030
2285
|
//#endregion
|
|
2031
|
-
export {
|
|
2286
|
+
export { k as VoidAccordion, A as VoidAccordionItem, p as VoidAlert, f as VoidAvatar, c as VoidBadge, R as VoidBanner, re as VoidBreadcrumbs, l as VoidButton, F as VoidCard, b as VoidCheckbox, U as VoidCheckboxGroup, W as VoidCombobox, J as VoidComposeInput, E as VoidDialog, u as VoidDivider, P as VoidDrawer, ce as VoidDropdownMenu, le as VoidDropdownMenuItem, o as VoidElement, H as VoidErrorFallback, C as VoidField, K as VoidFileUpload, oe as VoidHamburger, $ as VoidIndicator, _ as VoidInput, ie as VoidList, j as VoidListItem, T as VoidMultiselect, q as VoidNavBar, w as VoidOption, V as VoidPagination, g as VoidPanel, I as VoidPopover, h as VoidProgress, x as VoidRadio, S as VoidRadioGroup, z as VoidScrollArea, Z as VoidSegmentedControl, se as VoidSegmentedControlItem, y as VoidSelect, Y as VoidSidebar, te as VoidSkeleton, G as VoidSlider, ee as VoidSpinner, Q as VoidStat, ne as VoidStatusDot, N as VoidStepper, d as VoidSwitch, D as VoidTabPanel, B as VoidTable, O as VoidTabs, m as VoidTag, v as VoidTextarea, M as VoidToast, ae as VoidToastContainer, X as VoidToggle, L as VoidTooltip };
|