@charisol/plexo-sdk 1.4.0 → 1.4.2

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.
@@ -218,37 +218,636 @@ function i(e) {
218
218
  return n[e]?.color || "#475569";
219
219
  }
220
220
  //#endregion
221
+ //#region src/utilities/playground.constants.ts
222
+ var a = (e) => `https://picsum.photos/seed/${encodeURIComponent(e)}/1200/800`, o = [
223
+ {
224
+ id: "all",
225
+ label: "All sources"
226
+ },
227
+ {
228
+ id: "unsplash",
229
+ label: "Unsplash"
230
+ },
231
+ {
232
+ id: "pexels",
233
+ label: "Pexels"
234
+ },
235
+ {
236
+ id: "pixabay",
237
+ label: "Pixabay"
238
+ }
239
+ ], s = [
240
+ {
241
+ id: "surface-book",
242
+ label: "Surface Book",
243
+ width: 1500,
244
+ category: "desktop"
245
+ },
246
+ {
247
+ id: "macbook-pro",
248
+ label: "MacBook Pro",
249
+ width: 1440,
250
+ category: "desktop"
251
+ },
252
+ {
253
+ id: "imac",
254
+ label: "iMac",
255
+ width: 1280,
256
+ category: "desktop"
257
+ },
258
+ {
259
+ id: "macbook",
260
+ label: "MacBook",
261
+ width: 1152,
262
+ category: "desktop"
263
+ },
264
+ {
265
+ id: "surface-pro-4",
266
+ label: "Surface Pro 4",
267
+ width: 1368,
268
+ category: "tablet"
269
+ },
270
+ {
271
+ id: "ipad-pro-129",
272
+ label: "iPad Pro 12.9\"",
273
+ width: 1024,
274
+ category: "tablet"
275
+ },
276
+ {
277
+ id: "ipad-pro-11",
278
+ label: "iPad Pro 11\"",
279
+ width: 834,
280
+ category: "tablet"
281
+ },
282
+ {
283
+ id: "ipad-mini",
284
+ label: "iPad Mini",
285
+ width: 768,
286
+ category: "tablet"
287
+ },
288
+ {
289
+ id: "iphone-15-pro-max",
290
+ label: "iPhone 15 Pro Max",
291
+ width: 430,
292
+ category: "mobile"
293
+ },
294
+ {
295
+ id: "iphone-15-plus",
296
+ label: "iPhone 15 Plus",
297
+ width: 430,
298
+ category: "mobile"
299
+ },
300
+ {
301
+ id: "iphone-se",
302
+ label: "iPhone SE",
303
+ width: 375,
304
+ category: "mobile"
305
+ }
306
+ ], c = 1280, l = Object.entries(n).map(([e, t]) => ({
307
+ id: e,
308
+ label: t.label
309
+ })), u = [
310
+ {
311
+ label: "Text",
312
+ value: "text"
313
+ },
314
+ {
315
+ label: "Email",
316
+ value: "email"
317
+ },
318
+ {
319
+ label: "Number",
320
+ value: "number"
321
+ },
322
+ {
323
+ label: "Date",
324
+ value: "date"
325
+ },
326
+ {
327
+ label: "Textarea",
328
+ value: "textarea"
329
+ },
330
+ {
331
+ label: "Select",
332
+ value: "select"
333
+ },
334
+ {
335
+ label: "Radio",
336
+ value: "radio"
337
+ },
338
+ {
339
+ label: "Checkbox",
340
+ value: "checkbox"
341
+ }
342
+ ], d = [
343
+ {
344
+ label: "1 Column",
345
+ widths: ["100%"],
346
+ percentages: ["100%"]
347
+ },
348
+ {
349
+ label: "2 Columns",
350
+ widths: ["50%", "50%"],
351
+ percentages: ["50%", "50%"]
352
+ },
353
+ {
354
+ label: "60 / 40",
355
+ widths: ["60%", "40%"],
356
+ percentages: ["60%", "40%"]
357
+ },
358
+ {
359
+ label: "40 / 60",
360
+ widths: ["40%", "60%"],
361
+ percentages: ["40%", "60%"]
362
+ },
363
+ {
364
+ label: "3 Columns",
365
+ widths: [
366
+ "33.33%",
367
+ "33.33%",
368
+ "33.33%"
369
+ ],
370
+ percentages: [
371
+ "33%",
372
+ "33%",
373
+ "33%"
374
+ ]
375
+ },
376
+ {
377
+ label: "4 Columns",
378
+ widths: [
379
+ "25%",
380
+ "25%",
381
+ "25%",
382
+ "25%"
383
+ ],
384
+ percentages: [
385
+ "25%",
386
+ "25%",
387
+ "25%",
388
+ "25%"
389
+ ]
390
+ }
391
+ ], f = [
392
+ {
393
+ label: "Roboto",
394
+ value: "'Roboto', sans-serif",
395
+ style: "sans"
396
+ },
397
+ {
398
+ label: "Open Sans",
399
+ value: "'Open Sans', sans-serif",
400
+ style: "sans"
401
+ },
402
+ {
403
+ label: "Lato",
404
+ value: "'Lato', sans-serif",
405
+ style: "sans"
406
+ },
407
+ {
408
+ label: "Montserrat",
409
+ value: "'Montserrat', sans-serif",
410
+ style: "sans"
411
+ },
412
+ {
413
+ label: "Inter",
414
+ value: "'Inter', sans-serif",
415
+ style: "sans"
416
+ },
417
+ {
418
+ label: "Poppins",
419
+ value: "'Poppins', sans-serif",
420
+ style: "sans"
421
+ },
422
+ {
423
+ label: "Raleway",
424
+ value: "'Raleway', sans-serif",
425
+ style: "sans"
426
+ },
427
+ {
428
+ label: "Nunito",
429
+ value: "'Nunito', sans-serif",
430
+ style: "sans"
431
+ },
432
+ {
433
+ label: "Nunito Sans",
434
+ value: "'Nunito Sans', sans-serif",
435
+ style: "sans"
436
+ },
437
+ {
438
+ label: "Ubuntu",
439
+ value: "'Ubuntu', sans-serif",
440
+ style: "sans"
441
+ },
442
+ {
443
+ label: "Rubik",
444
+ value: "'Rubik', sans-serif",
445
+ style: "sans"
446
+ },
447
+ {
448
+ label: "Plus Jakarta Sans",
449
+ value: "'Plus Jakarta Sans', sans-serif",
450
+ style: "sans"
451
+ },
452
+ {
453
+ label: "DM Sans",
454
+ value: "'DM Sans', sans-serif",
455
+ style: "sans"
456
+ },
457
+ {
458
+ label: "Outfit",
459
+ value: "'Outfit', sans-serif",
460
+ style: "sans"
461
+ },
462
+ {
463
+ label: "Figtree",
464
+ value: "'Figtree', sans-serif",
465
+ style: "sans"
466
+ },
467
+ {
468
+ label: "Karla",
469
+ value: "'Karla', sans-serif",
470
+ style: "sans"
471
+ },
472
+ {
473
+ label: "Barlow",
474
+ value: "'Barlow', sans-serif",
475
+ style: "sans"
476
+ },
477
+ {
478
+ label: "Work Sans",
479
+ value: "'Work Sans', sans-serif",
480
+ style: "sans"
481
+ },
482
+ {
483
+ label: "Manrope",
484
+ value: "'Manrope', sans-serif",
485
+ style: "sans"
486
+ },
487
+ {
488
+ label: "Jost",
489
+ value: "'Jost', sans-serif",
490
+ style: "sans"
491
+ },
492
+ {
493
+ label: "Sora",
494
+ value: "'Sora', sans-serif",
495
+ style: "sans"
496
+ },
497
+ {
498
+ label: "Be Vietnam Pro",
499
+ value: "'Be Vietnam Pro', sans-serif",
500
+ style: "sans"
501
+ },
502
+ {
503
+ label: "Mulish",
504
+ value: "'Mulish', sans-serif",
505
+ style: "sans"
506
+ },
507
+ {
508
+ label: "Noto Sans",
509
+ value: "'Noto Sans', sans-serif",
510
+ style: "sans"
511
+ },
512
+ {
513
+ label: "Source Sans 3",
514
+ value: "'Source Sans 3', sans-serif",
515
+ style: "sans"
516
+ },
517
+ {
518
+ label: "IBM Plex Sans",
519
+ value: "'IBM Plex Sans', sans-serif",
520
+ style: "sans"
521
+ },
522
+ {
523
+ label: "Josefin Sans",
524
+ value: "'Josefin Sans', sans-serif",
525
+ style: "sans"
526
+ },
527
+ {
528
+ label: "Quicksand",
529
+ value: "'Quicksand', sans-serif",
530
+ style: "sans"
531
+ },
532
+ {
533
+ label: "Exo 2",
534
+ value: "'Exo 2', sans-serif",
535
+ style: "sans"
536
+ },
537
+ {
538
+ label: "Titillium Web",
539
+ value: "'Titillium Web', sans-serif",
540
+ style: "sans"
541
+ },
542
+ {
543
+ label: "Merriweather",
544
+ value: "'Merriweather', serif",
545
+ style: "serif"
546
+ },
547
+ {
548
+ label: "Playfair Display",
549
+ value: "'Playfair Display', serif",
550
+ style: "serif"
551
+ },
552
+ {
553
+ label: "Lora",
554
+ value: "'Lora', serif",
555
+ style: "serif"
556
+ },
557
+ {
558
+ label: "PT Serif",
559
+ value: "'PT Serif', serif",
560
+ style: "serif"
561
+ },
562
+ {
563
+ label: "Noto Serif",
564
+ value: "'Noto Serif', serif",
565
+ style: "serif"
566
+ },
567
+ {
568
+ label: "EB Garamond",
569
+ value: "'EB Garamond', serif",
570
+ style: "serif"
571
+ },
572
+ {
573
+ label: "Libre Baskerville",
574
+ value: "'Libre Baskerville', serif",
575
+ style: "serif"
576
+ },
577
+ {
578
+ label: "Cormorant Garamond",
579
+ value: "'Cormorant Garamond', serif",
580
+ style: "serif"
581
+ },
582
+ {
583
+ label: "Crimson Text",
584
+ value: "'Crimson Text', serif",
585
+ style: "serif"
586
+ },
587
+ {
588
+ label: "DM Serif Display",
589
+ value: "'DM Serif Display', serif",
590
+ style: "serif"
591
+ },
592
+ {
593
+ label: "Domine",
594
+ value: "'Domine', serif",
595
+ style: "serif"
596
+ },
597
+ {
598
+ label: "Bitter",
599
+ value: "'Bitter', serif",
600
+ style: "serif"
601
+ },
602
+ {
603
+ label: "Spectral",
604
+ value: "'Spectral', serif",
605
+ style: "serif"
606
+ },
607
+ {
608
+ label: "Cardo",
609
+ value: "'Cardo', serif",
610
+ style: "serif"
611
+ },
612
+ {
613
+ label: "Gilda Display",
614
+ value: "'Gilda Display', serif",
615
+ style: "serif"
616
+ },
617
+ {
618
+ label: "Roboto Mono",
619
+ value: "'Roboto Mono', monospace",
620
+ style: "mono"
621
+ },
622
+ {
623
+ label: "Source Code Pro",
624
+ value: "'Source Code Pro', monospace",
625
+ style: "mono"
626
+ },
627
+ {
628
+ label: "Fira Code",
629
+ value: "'Fira Code', monospace",
630
+ style: "mono"
631
+ },
632
+ {
633
+ label: "JetBrains Mono",
634
+ value: "'JetBrains Mono', monospace",
635
+ style: "mono"
636
+ },
637
+ {
638
+ label: "IBM Plex Mono",
639
+ value: "'IBM Plex Mono', monospace",
640
+ style: "mono"
641
+ },
642
+ {
643
+ label: "Space Mono",
644
+ value: "'Space Mono', monospace",
645
+ style: "mono"
646
+ },
647
+ {
648
+ label: "Inconsolata",
649
+ value: "'Inconsolata', monospace",
650
+ style: "mono"
651
+ },
652
+ {
653
+ label: "Courier Prime",
654
+ value: "'Courier Prime', monospace",
655
+ style: "mono"
656
+ },
657
+ {
658
+ label: "Oswald",
659
+ value: "'Oswald', sans-serif",
660
+ style: "display"
661
+ },
662
+ {
663
+ label: "Anton",
664
+ value: "'Anton', sans-serif",
665
+ style: "display"
666
+ },
667
+ {
668
+ label: "Bebas Neue",
669
+ value: "'Bebas Neue', sans-serif",
670
+ style: "display"
671
+ },
672
+ {
673
+ label: "Righteous",
674
+ value: "'Righteous', sans-serif",
675
+ style: "display"
676
+ },
677
+ {
678
+ label: "Russo One",
679
+ value: "'Russo One', sans-serif",
680
+ style: "display"
681
+ },
682
+ {
683
+ label: "Chakra Petch",
684
+ value: "'Chakra Petch', sans-serif",
685
+ style: "display"
686
+ },
687
+ {
688
+ label: "Orbitron",
689
+ value: "'Orbitron', sans-serif",
690
+ style: "display"
691
+ },
692
+ {
693
+ label: "Abril Fatface",
694
+ value: "'Abril Fatface', serif",
695
+ style: "display"
696
+ },
697
+ {
698
+ label: "Lobster",
699
+ value: "'Lobster', cursive",
700
+ style: "display"
701
+ },
702
+ {
703
+ label: "Alfa Slab One",
704
+ value: "'Alfa Slab One', serif",
705
+ style: "display"
706
+ },
707
+ {
708
+ label: "Archivo Black",
709
+ value: "'Archivo Black', sans-serif",
710
+ style: "display"
711
+ },
712
+ {
713
+ label: "Bangers",
714
+ value: "'Bangers', cursive",
715
+ style: "display"
716
+ },
717
+ {
718
+ label: "Boogaloo",
719
+ value: "'Boogaloo', cursive",
720
+ style: "display"
721
+ },
722
+ {
723
+ label: "Fredoka One",
724
+ value: "'Fredoka One', cursive",
725
+ style: "display"
726
+ },
727
+ {
728
+ label: "Permanent Marker",
729
+ value: "'Permanent Marker', cursive",
730
+ style: "display"
731
+ },
732
+ {
733
+ label: "Lilita One",
734
+ value: "'Lilita One', cursive",
735
+ style: "display"
736
+ },
737
+ {
738
+ label: "Dancing Script",
739
+ value: "'Dancing Script', cursive",
740
+ style: "handwriting"
741
+ },
742
+ {
743
+ label: "Pacifico",
744
+ value: "'Pacifico', cursive",
745
+ style: "handwriting"
746
+ },
747
+ {
748
+ label: "Satisfy",
749
+ value: "'Satisfy', cursive",
750
+ style: "handwriting"
751
+ },
752
+ {
753
+ label: "Caveat",
754
+ value: "'Caveat', cursive",
755
+ style: "handwriting"
756
+ },
757
+ {
758
+ label: "Indie Flower",
759
+ value: "'Indie Flower', cursive",
760
+ style: "handwriting"
761
+ },
762
+ {
763
+ label: "Kalam",
764
+ value: "'Kalam', cursive",
765
+ style: "handwriting"
766
+ },
767
+ {
768
+ label: "Shadows Into Light",
769
+ value: "'Shadows Into Light', cursive",
770
+ style: "handwriting"
771
+ },
772
+ {
773
+ label: "Amatic SC",
774
+ value: "'Amatic SC', cursive",
775
+ style: "handwriting"
776
+ },
777
+ {
778
+ label: "Courgette",
779
+ value: "'Courgette', cursive",
780
+ style: "handwriting"
781
+ },
782
+ {
783
+ label: "Cookie",
784
+ value: "'Cookie', cursive",
785
+ style: "handwriting"
786
+ },
787
+ {
788
+ label: "Great Vibes",
789
+ value: "'Great Vibes', cursive",
790
+ style: "handwriting"
791
+ }
792
+ ], p = new Map(f.map((e) => [e.value, e.label]));
793
+ function m(e, t = []) {
794
+ let n = /* @__PURE__ */ new Set(), r = (e) => {
795
+ if (!e) return;
796
+ let t = Array.isArray(e.columns) ? e.columns : [];
797
+ for (let e of t) {
798
+ if (!e) continue;
799
+ let t = Array.isArray(e.elements) ? e.elements : [];
800
+ for (let e of t) {
801
+ let t = e?.style?.fontFamily;
802
+ typeof t == "string" && t.trim() && n.add(t.trim());
803
+ }
804
+ (Array.isArray(e.nestedRows) ? e.nestedRows : []).forEach(r);
805
+ }
806
+ };
807
+ (e || []).forEach(r);
808
+ for (let e of t) typeof e == "string" && e.trim() && n.add(e.trim());
809
+ return n;
810
+ }
811
+ function h(e) {
812
+ let t = /* @__PURE__ */ new Set();
813
+ for (let n of e) {
814
+ let e = p.get(n);
815
+ e && t.add(e);
816
+ }
817
+ return t.size === 0 ? null : `https://fonts.googleapis.com/css?family=${Array.from(t).map((e) => `${encodeURIComponent(e).replace(/%20/g, "+")}:400,700`).join("|")}&display=swap`;
818
+ }
819
+ //#endregion
221
820
  //#region src/utilities/elementResolvers.ts
222
- var a = (e) => e === "twitter" ? "x" : e, o = (e, t = "currentColor") => `<svg viewBox="0 0 24 24" width="16" height="16" aria-hidden="true"><path fill="${t}" d="${n[a(e)]?.path || "M12 8a4 4 0 1 0 0 8 4 4 0 0 0 0-8Z"}"/></svg>`;
223
- function s(e, t) {
224
- let n = e.attributes || {}, r = e.style || {}, o = Array.isArray(n.links) ? n.links : [], s = n.colorMode === "branded", c = s || !!t?.forceBrandedColor;
225
- return o.filter((e) => e && typeof e == "object").map((e) => {
226
- let t = a(String(e.provider || ""));
821
+ var g = (e) => e === "twitter" ? "x" : e, _ = (e, t = "currentColor") => `<svg viewBox="0 0 24 24" width="16" height="16" aria-hidden="true"><path fill="${t}" d="${n[g(e)]?.path || "M12 8a4 4 0 1 0 0 8 4 4 0 0 0 0-8Z"}"/></svg>`;
822
+ function v(e, t) {
823
+ let n = e.attributes || {}, r = e.style || {}, a = Array.isArray(n.links) ? n.links : [], o = n.colorMode === "branded", s = o || !!t?.forceBrandedColor;
824
+ return a.filter((e) => e && typeof e == "object").map((e) => {
825
+ let t = g(String(e.provider || ""));
227
826
  return {
228
827
  provider: t,
229
828
  url: typeof e.url == "string" && e.url.trim() ? e.url : "#",
230
- color: c ? i(t) : e.color || r.iconColor || "#475569",
231
- backgroundColor: s ? "transparent" : e.backgroundColor || r.iconBackgroundColor || "#f8fafc",
829
+ color: s ? i(t) : e.color || r.iconColor || "#475569",
830
+ backgroundColor: o ? "transparent" : e.backgroundColor || r.iconBackgroundColor || "#f8fafc",
232
831
  size: e.size || r.iconSize || "36px",
233
832
  iconType: (e.iconType || n.iconType) === "square" ? "square" : "circle"
234
833
  };
235
834
  });
236
835
  }
237
- function c(e) {
836
+ function y(e) {
238
837
  let t = e.attributes || {};
239
838
  return (Array.isArray(t.links) ? t.links : []).filter((e) => e && typeof e == "object").map((e) => ({
240
839
  label: typeof e.label == "string" && e.label.trim() ? e.label : "Link",
241
840
  href: typeof e.href == "string" && e.href.trim() ? e.href : "#"
242
841
  }));
243
842
  }
244
- function l(e) {
843
+ function b(e) {
245
844
  let t = e.style || {}, n = e.attributes || {};
246
845
  return {
247
846
  width: t.width || "100%",
248
847
  height: n.autoHeight === !1 && t.height || "auto"
249
848
  };
250
849
  }
251
- function u(e, t, n, r) {
850
+ function x(e, t, n, r) {
252
851
  if (e) return e;
253
852
  if (t) {
254
853
  let e = t.trim().split(/\s+/).filter(Boolean);
@@ -264,25 +863,25 @@ function u(e, t, n, r) {
264
863
  }
265
864
  return r;
266
865
  }
267
- function d(e) {
866
+ function S(e) {
268
867
  let t = e.style || {}, n = e.attributes || {};
269
868
  return {
270
869
  width: n.autoWidth === !1 ? t.width || "100%" : "auto",
271
870
  height: n.autoHeight === !1 && t.height || "auto"
272
871
  };
273
872
  }
274
- function f(e) {
873
+ function C(e) {
275
874
  return { autoWidth: (e.attributes || {}).autoWidth === !0 };
276
875
  }
277
- function p(e) {
876
+ function w(e) {
278
877
  let t = e.style || {};
279
878
  return (e.attributes || {}).autoHeight === !1 && t.height || "auto";
280
879
  }
281
- function m(e, t) {
880
+ function T(e, t) {
282
881
  let n = e.style || {};
283
882
  return (e.attributes || {}).autoHeight === !1 && n.height || t;
284
883
  }
285
- var h = [
884
+ var E = [
286
885
  "showLabel",
287
886
  "fontSize",
288
887
  "labelFontWeight",
@@ -293,15 +892,15 @@ var h = [
293
892
  "inputTextColor",
294
893
  "placeholderColor"
295
894
  ];
296
- function g(e) {
895
+ function D(e) {
297
896
  let t = null;
298
897
  return (Array.isArray(e) ? e : []).map((e) => {
299
898
  let n = e?.inheritStylesFromPrevious && t ? { ...e } : e;
300
- if (e?.inheritStylesFromPrevious && t) for (let e of h) n[e] = t[e];
899
+ if (e?.inheritStylesFromPrevious && t) for (let e of E) n[e] = t[e];
301
900
  return t = n, n;
302
901
  });
303
902
  }
304
- function _(e) {
903
+ function O(e) {
305
904
  let t = {};
306
905
  for (let n of e) {
307
906
  let e = n.name || n.id || "field";
@@ -319,8 +918,8 @@ function _(e) {
319
918
  };
320
919
  });
321
920
  }
322
- var v = (e) => String(Math.max(0, e)).padStart(2, "0"), y = /[Zz]$|[+-]\d{2}:?\d{2}$/;
323
- function b(e, t) {
921
+ var k = (e) => String(Math.max(0, e)).padStart(2, "0"), A = /[Zz]$|[+-]\d{2}:?\d{2}$/;
922
+ function j(e, t) {
324
923
  let n = new Intl.DateTimeFormat("en-US", {
325
924
  timeZone: t,
326
925
  hourCycle: "h23",
@@ -333,12 +932,12 @@ function b(e, t) {
333
932
  }).formatToParts(new Date(e)), r = (e) => Number(n.find((t) => t.type === e)?.value);
334
933
  return Date.UTC(r("year"), r("month") - 1, r("day"), r("hour"), r("minute"), r("second")) - e;
335
934
  }
336
- function x(e, t) {
337
- let n = y.test(e), r = Date.parse(n ? e : `${e}Z`);
338
- return Number.isNaN(r) || n || !t ? r : r - b(r, t);
935
+ function M(e, t) {
936
+ let n = A.test(e), r = Date.parse(n ? e : `${e}Z`);
937
+ return Number.isNaN(r) || n || !t ? r : r - j(r, t);
339
938
  }
340
- function S(e, t, n = Date.now()) {
341
- let r = e ? x(e, t) : NaN, i = Number.isNaN(r) ? n : r, a = i - n;
939
+ function N(e, t, n = Date.now()) {
940
+ let r = e ? M(e, t) : NaN, i = Number.isNaN(r) ? n : r, a = i - n;
342
941
  if (a <= 0) return {
343
942
  days: "00",
344
943
  hours: "00",
@@ -349,31 +948,31 @@ function S(e, t, n = Date.now()) {
349
948
  };
350
949
  let o = Math.floor(a / 1e3), s = Math.floor(o / 86400), c = Math.floor(o % 86400 / 3600), l = Math.floor(o % 3600 / 60), u = o % 60;
351
950
  return {
352
- days: v(s),
353
- hours: v(c),
354
- minutes: v(l),
355
- seconds: v(u),
951
+ days: k(s),
952
+ hours: k(c),
953
+ minutes: k(l),
954
+ seconds: k(u),
356
955
  isExpired: !1,
357
956
  targetTimestamp: i
358
957
  };
359
958
  }
360
- var C = [
959
+ var P = [
361
960
  "youtube.com",
362
961
  "www.youtube.com",
363
962
  "youtu.be",
364
963
  "m.youtube.com"
365
964
  ];
366
- function w(e) {
965
+ function F(e) {
367
966
  return e.hostname === "youtu.be" ? e.pathname.slice(1).split("/")[0] || null : e.pathname.startsWith("/embed/") ? e.pathname.slice(7).split("/")[0] || null : e.pathname.startsWith("/shorts/") ? e.pathname.slice(8).split("/")[0] || null : e.searchParams.get("v");
368
967
  }
369
- function T(e) {
968
+ function I(e) {
370
969
  let t = e.pathname.match(/(\d+)/);
371
970
  return t ? t[1] : null;
372
971
  }
373
- var E = "data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22360%22%20viewBox%3D%220%200%20640%20360%22%3E%3Crect%20width%3D%22640%22%20height%3D%22360%22%20fill%3D%22%230f172a%22%2F%3E%3Ccircle%20cx%3D%22320%22%20cy%3D%22180%22%20r%3D%2248%22%20fill%3D%22%23ffffff%22%20opacity%3D%220.9%22%2F%3E%3Cpath%20d%3D%22M304%20156%20L356%20180%20L304%20204%20Z%22%20fill%3D%22%230f172a%22%2F%3E%3C%2Fsvg%3E";
374
- function D(e) {
972
+ var L = "data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22360%22%20viewBox%3D%220%200%20640%20360%22%3E%3Crect%20width%3D%22640%22%20height%3D%22360%22%20fill%3D%22%230f172a%22%2F%3E%3Ccircle%20cx%3D%22320%22%20cy%3D%22180%22%20r%3D%2248%22%20fill%3D%22%23ffffff%22%20opacity%3D%220.9%22%2F%3E%3Cpath%20d%3D%22M304%20156%20L356%20180%20L304%20204%20Z%22%20fill%3D%22%230f172a%22%2F%3E%3C%2Fsvg%3E";
973
+ function R(e) {
375
974
  if (!e || typeof e != "string") return {
376
- thumbnailUrl: E,
975
+ thumbnailUrl: L,
377
976
  provider: "unknown"
378
977
  };
379
978
  let t;
@@ -381,30 +980,30 @@ function D(e) {
381
980
  t = new URL(e);
382
981
  } catch {
383
982
  return {
384
- thumbnailUrl: E,
983
+ thumbnailUrl: L,
385
984
  provider: "unknown"
386
985
  };
387
986
  }
388
- if (C.includes(t.hostname)) {
389
- let e = w(t);
987
+ if (P.includes(t.hostname)) {
988
+ let e = F(t);
390
989
  if (e) return {
391
990
  thumbnailUrl: `https://img.youtube.com/vi/${e}/hqdefault.jpg`,
392
991
  provider: "youtube"
393
992
  };
394
993
  }
395
994
  if (t.hostname === "vimeo.com" || t.hostname === "www.vimeo.com" || t.hostname === "player.vimeo.com") {
396
- let e = T(t);
995
+ let e = I(t);
397
996
  if (e) return {
398
997
  thumbnailUrl: `https://vumbnail.com/${e}.jpg`,
399
998
  provider: "vimeo"
400
999
  };
401
1000
  }
402
1001
  return {
403
- thumbnailUrl: E,
1002
+ thumbnailUrl: L,
404
1003
  provider: "unknown"
405
1004
  };
406
1005
  }
407
- function O(e) {
1006
+ function z(e) {
408
1007
  let t = e.attributes || {}, n = Math.max(1, Number(t.rowCount) || 2), r = Math.max(1, Number(t.colCount) || 2), i = Array.isArray(t.cells) ? t.cells : [], a = [];
409
1008
  for (let e = 0; e < n; e++) {
410
1009
  let t = Array.isArray(i[e]) ? i[e] : [], n = [];
@@ -420,29 +1019,29 @@ function O(e) {
420
1019
  striped: !!t.striped
421
1020
  };
422
1021
  }
423
- var k = 8;
424
- function A(e, t, n) {
425
- let r = n < k && Array.isArray(e?.children) ? e.children : [];
1022
+ var B = 8;
1023
+ function V(e, t, n) {
1024
+ let r = n < B && Array.isArray(e?.children) ? e.children : [];
426
1025
  return {
427
1026
  id: typeof e?.id == "string" && e.id ? e.id : `item-${t}`,
428
1027
  title: typeof e?.title == "string" && e.title.trim() ? e.title : `Item ${t + 1}`,
429
1028
  content: typeof e?.content == "string" ? e.content : "",
430
1029
  defaultOpen: !!e?.defaultOpen,
431
- children: r.map((e, t) => A(e, t, n + 1))
1030
+ children: r.map((e, t) => V(e, t, n + 1))
432
1031
  };
433
1032
  }
434
- function j(e, t) {
1033
+ function H(e, t) {
435
1034
  if (t !== "multi") {
436
1035
  let t = !1;
437
1036
  for (let n of e) n.defaultOpen && (t ? n.defaultOpen = !1 : t = !0);
438
1037
  }
439
- for (let n of e) j(n.children, t);
1038
+ for (let n of e) H(n.children, t);
440
1039
  }
441
- function M(e) {
442
- let t = e.attributes || {}, n = t.mode === "multi" ? "multi" : "single", r = (Array.isArray(t.items) ? t.items : []).map((e, t) => A(e, t, 0));
443
- return j(r, n), r;
1040
+ function U(e) {
1041
+ let t = e.attributes || {}, n = t.mode === "multi" ? "multi" : "single", r = (Array.isArray(t.items) ? t.items : []).map((e, t) => V(e, t, 0));
1042
+ return H(r, n), r;
444
1043
  }
445
- function N(e, t, n) {
1044
+ function W(e, t, n) {
446
1045
  let r = JSON.parse(JSON.stringify(Array.isArray(e) ? e : [])), i = (e, t) => {
447
1046
  let [r, ...a] = t;
448
1047
  if (e[r]) {
@@ -460,7 +1059,7 @@ function N(e, t, n) {
460
1059
  }
461
1060
  //#endregion
462
1061
  //#region src/utilities/iconSvgStatic.ts
463
- var P = {
1062
+ var G = {
464
1063
  "a-arrow-down": [
465
1064
  ["path", { d: "m14 12 4 4 4-4" }],
466
1065
  ["path", { d: "M18 16V7" }],
@@ -15280,18 +15879,18 @@ var P = {
15280
15879
  y2: "11"
15281
15880
  }]
15282
15881
  ]
15283
- }, F = "circle-help";
15284
- function I(e) {
15882
+ }, K = "circle-help";
15883
+ function q(e) {
15285
15884
  return e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").replace(/([A-Z]+)([A-Z][a-z])/g, "$1-$2").toLowerCase();
15286
15885
  }
15287
- function L(e) {
15288
- let t = e || "HelpCircle", n = I(t.replace(/^\w/, (e) => e.toUpperCase()));
15289
- if (P[n]) return n;
15886
+ function J(e) {
15887
+ let t = e || "HelpCircle", n = q(t.replace(/^\w/, (e) => e.toUpperCase()));
15888
+ if (G[n]) return n;
15290
15889
  let r = t.toLowerCase().replace(/[-_\s]/g, "");
15291
- return Object.keys(P).find((e) => e.replace(/-/g, "") === r) || F;
15890
+ return Object.keys(G).find((e) => e.replace(/-/g, "") === r) || K;
15292
15891
  }
15293
- function R(e, t, n) {
15294
- return `<svg xmlns="http://www.w3.org/2000/svg" width="${t}" height="${t}" viewBox="0 0 24 24" fill="none" stroke="${n}" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">${(P[L(e)] || P[F] || []).map(([e, t]) => `<${e} ${Object.entries(t).map(([e, t]) => `${e}="${String(t)}"`).join(" ")}></${e}>`).join("")}</svg>`;
15892
+ function Y(e, t, n) {
15893
+ return `<svg xmlns="http://www.w3.org/2000/svg" width="${t}" height="${t}" viewBox="0 0 24 24" fill="none" stroke="${n}" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">${(G[J(e)] || G[K] || []).map(([e, t]) => `<${e} ${Object.entries(t).map(([e, t]) => `${e}="${String(t)}"`).join(" ")}></${e}>`).join("")}</svg>`;
15295
15894
  }
15296
15895
  //#endregion
15297
- export { t as S, N as _, u as a, i as b, g as c, c as d, s as f, D as g, S as h, M as i, m as l, f as m, _ as n, d as o, O as p, o as r, p as s, R as t, l as u, r as v, e as x, n as y };
15896
+ export { i as A, f as C, a as D, o as E, t as M, r as O, u as S, l as T, W as _, x as a, d as b, D as c, y as d, v as f, R as g, N as h, U as i, e as j, n as k, T as l, C as m, O as n, S as o, z as p, _ as r, w as s, Y as t, b as u, h as v, c as w, s as x, m as y };