@skf-design-system/ui-components 1.0.0-alpha.35 → 1.0.0-alpha.36

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 (52) hide show
  1. package/custom-elements.json +25490 -0
  2. package/dist/components/accordion/accordion.component.d.ts +1 -1
  3. package/dist/components/accordion/accordion.component.js +2 -2
  4. package/dist/components/card/card.component.d.ts +2 -0
  5. package/dist/components/card/card.styles.js +2 -1
  6. package/dist/components/datepicker/datepicker.component.js +1 -0
  7. package/dist/components/icon/icon.component.d.ts +1 -4
  8. package/dist/components/icon/icon.component.js +41 -53
  9. package/dist/components/icon/icon.styles.js +0 -1
  10. package/dist/components/input/input.component.js +1 -0
  11. package/dist/components/link/link.component.d.ts +15 -18
  12. package/dist/components/link/link.component.js +99 -108
  13. package/dist/components/link/link.styles.js +45 -45
  14. package/dist/components/menu/menu-item.component.d.ts +1 -1
  15. package/dist/components/menu/menu-item.component.js +8 -8
  16. package/dist/components/menu/menu-item.styles.js +8 -5
  17. package/dist/components/nav/nav-item.component.d.ts +4 -0
  18. package/dist/components/nav/nav-item.component.js +44 -25
  19. package/dist/components/nav/nav-item.styles.js +29 -25
  20. package/dist/components/nav/nav.component.d.ts +6 -0
  21. package/dist/components/nav/nav.component.js +42 -21
  22. package/dist/components/nav/nav.styles.js +15 -9
  23. package/dist/components/popover/popover.component.d.ts +4 -0
  24. package/dist/components/popover/popover.component.js +31 -23
  25. package/dist/components/progress/progress.component.d.ts +2 -0
  26. package/dist/components/progress/progress.component.js +38 -29
  27. package/dist/components/progress/progress.styles.js +3 -3
  28. package/dist/components/select/select-option-group.component.d.ts +4 -0
  29. package/dist/components/select/select-option-group.component.js +37 -18
  30. package/dist/components/select/select-option-group.style.js +12 -6
  31. package/dist/components/select/select-option.component.d.ts +5 -1
  32. package/dist/components/select/select-option.component.js +69 -52
  33. package/dist/components/select/select-option.styles.js +43 -31
  34. package/dist/components/select/select.component.d.ts +5 -1
  35. package/dist/components/select/select.component.js +47 -29
  36. package/dist/components/select/select.controllers.js +2 -1
  37. package/dist/components/textarea/textarea.component.js +5 -4
  38. package/dist/components/toast/toast.component.js +9 -9
  39. package/dist/components/toast/toast.singleton.d.ts +1 -1
  40. package/dist/components/toast/toast.singleton.js +18 -18
  41. package/dist/custom-elements.json +758 -678
  42. package/dist/internal/base-classes/popover/popover.base.d.ts +2 -2
  43. package/dist/internal/base-classes/popover/popover.base.js +17 -17
  44. package/dist/internal/base-classes/popover/popover.styles.js +4 -5
  45. package/dist/internal/components/hint/hint.component.d.ts +4 -0
  46. package/dist/internal/components/hint/hint.component.js +47 -20
  47. package/dist/internal/components/hint/hint.styles.js +29 -25
  48. package/dist/types/jsx/custom-element-jsx.d.ts +188 -70
  49. package/dist/types/vue/index.d.ts +81 -69
  50. package/dist/vscode.html-custom-data.json +91 -95
  51. package/dist/web-types.json +204 -203
  52. package/package.json +13 -13
@@ -17,13 +17,13 @@ import type { SkfDialog, CustomEvent } from "../../components/dialog/dialog.comp
17
17
  import type { SkfDivider } from "../../components/divider/divider.component.js";
18
18
  import type { SkfDrawer, CustomEvent } from "../../components/drawer/drawer.component.js";
19
19
  import type { SkfLogo } from "../../components/logo/logo.component.js";
20
+ import type { SkfLink, CustomEvent } from "../../components/link/link.component.js";
21
+ import type { SkfNavItem } from "../../components/nav-item/nav-item.component.js";
20
22
  import type { SkfNav } from "../../components/nav/nav.component.js";
21
23
  import type { SkfHeader } from "../../components/header/header.component.js";
22
24
  import type { SkfInput, CustomEvent } from "../../components/input/input.component.js";
23
- import type { SkfLink } from "../../components/link/link.component.js";
24
- import type { SkfMenuItem } from "../../components/menu-item/menu-item.component.js";
25
+ import type { SkfMenuItem, CustomEvent } from "../../components/menu-item/menu-item.component.js";
25
26
  import type { SkfMenu, CustomEvent } from "../../components/menu/menu.component.js";
26
- import type { SkfNavItem } from "../../components/nav-item/nav-item.component.js";
27
27
  import type { SkfPopover, CustomEvent } from "../../components/popover/popover.component.js";
28
28
  import type { SkfProgress } from "../../components/progress/progress.component.js";
29
29
  import type { SkfRadio, Event } from "../../components/radio/radio.component.js";
@@ -329,8 +329,45 @@ type SkfLogoProps = {
329
329
  color?: SkfLogo["color"];
330
330
  };
331
331
 
332
- type SkfNavProps = {
332
+ type SkfLinkProps = {
333
+ /** Defines the semantic element to render */
334
+ as?: SkfLink["as"];
335
+ /** Defines the text-color */
336
+ color?: SkfLink["color"];
337
+ /** If true, disables the link */
338
+ disabled?: SkfLink["disabled"];
339
+ /** If defined, downloads the url */
340
+ download?: SkfLink["download"];
341
+ /** If defined, loads url on click */
342
+ href?: SkfLink["href"];
343
+ /** If defined, renders an icon before or after the text */
344
+ icon?: SkfLink["icon"];
345
+ /** If true, the icon is placed to the right in relation to the text */
346
+ "icon-right"?: SkfLink["iconRight"];
347
+ /** If defined, describes the relationship between a linked resource and the current document */
348
+ rel?: SkfLink["rel"];
349
+ /** If defined, used on conjunction with onClick property. **Notice!** Only applicable to as=button. */
350
+ route?: SkfLink["route"];
351
+ /** If true, fills the parents horizontal axis */
352
+ stretch?: SkfLink["stretch"];
353
+ /** If defined, specifies where to open the linked document */
354
+ target?: SkfLink["target"];
355
+
356
+ /** Fired when the link is clicked */
357
+ "onskf-link-click"?: (e: CustomEvent<CustomEvent>) => void;
358
+ };
359
+
360
+ type SkfNavItemProps = {
361
+ /** */
362
+ href?: SkfNavItem["href"];
363
+ /** */
364
+ icon?: SkfNavItem["icon"];
333
365
  /** */
366
+ vertical?: SkfNavItem["vertical"];
367
+ };
368
+
369
+ type SkfNavProps = {
370
+ /** If true, the navigation will be displayed vertically */
334
371
  vertical?: SkfNav["vertical"];
335
372
  };
336
373
 
@@ -413,35 +450,6 @@ type SkfInputProps = {
413
450
  oninvalid?: (e: CustomEvent<CustomEvent>) => void;
414
451
  };
415
452
 
416
- type SkfLinkProps = {
417
- /** Defines the semantic element to render */
418
- as?: SkfLink["as"];
419
- /** Defines the text-color */
420
- color?: SkfLink["color"];
421
- /** If true, disables the link */
422
- disabled?: SkfLink["disabled"];
423
- /** If defined, downloads the url */
424
- download?: SkfLink["download"];
425
- /** If defined, loads url on click */
426
- href?: SkfLink["href"];
427
- /** If defined, renders an icon before or after the text */
428
- icon?: SkfLink["icon"];
429
- /** Defines the position of the icon in relation to the text */
430
- "icon-placement"?: SkfLink["iconPlacement"];
431
- /** If defined, describes the relationship between a linked resource and the current document */
432
- rel?: SkfLink["rel"];
433
- /** If defined, used on conjunction with onClick property, second argument */
434
- route?: SkfLink["route"];
435
- /** If true, fills the parents horizontal axis */
436
- stretch?: SkfLink["stretch"];
437
- /** If defined, specifies where to open the linked document */
438
- target?: SkfLink["target"];
439
- /** Defines the type of button */
440
- type?: SkfLink["type"];
441
- /** If defined, accepts a function that runs on click. Forwards optional route as second argument. */
442
- onClick?: SkfLink["onClick"];
443
- };
444
-
445
453
  type SkfMenuItemProps = {
446
454
  /** Defines the semantic element to render */
447
455
  as?: SkfMenuItem["as"];
@@ -455,22 +463,19 @@ type SkfMenuItemProps = {
455
463
  href?: SkfMenuItem["href"];
456
464
  /** If defined, renders an icon before or after the text */
457
465
  icon?: SkfMenuItem["icon"];
458
- /** Defines the position of the icon in relation to the text */
459
- "icon-placement"?: SkfMenuItem["iconPlacement"];
466
+ /** If true, the icon is placed to the right in relation to the text */
467
+ "icon-right"?: SkfMenuItem["iconRight"];
460
468
  /** If defined, describes the relationship between a linked resource and the current document */
461
469
  rel?: SkfMenuItem["rel"];
462
- /** If defined, used on conjunction with onClick property, second argument */
470
+ /** If defined, used on conjunction with onClick property. **Notice!** Only applicable to as=button. */
463
471
  route?: SkfMenuItem["route"];
464
472
  /** If true, fills the parents horizontal axis */
465
473
  stretch?: SkfMenuItem["stretch"];
466
474
  /** If defined, specifies where to open the linked document */
467
475
  target?: SkfMenuItem["target"];
468
- /** Defines the type of button */
469
- type?: SkfMenuItem["type"];
470
- /** */
471
- role?: SkfMenuItem["role"];
472
- /** If defined, accepts a function that runs on click. Forwards optional route as second argument. */
473
- onClick?: SkfMenuItem["onClick"];
476
+
477
+ /** Fired when the link is clicked */
478
+ "onskf-link-click"?: (e: CustomEvent<CustomEvent>) => void;
474
479
  };
475
480
 
476
481
  type SkfMenuProps = {
@@ -485,13 +490,6 @@ type SkfMenuProps = {
485
490
  "onskf-closed"?: (e: CustomEvent<CustomEvent>) => void;
486
491
  };
487
492
 
488
- type SkfNavItemProps = {
489
- /** */
490
- href?: SkfNavItem["href"];
491
- /** */
492
- icon?: SkfNavItem["icon"];
493
- };
494
-
495
493
  type SkfPopoverProps = {
496
494
  /** The placement of the popover */
497
495
  placement?: SkfPopover["undefined"];
@@ -567,6 +565,8 @@ type SkfSegmentedButtonProps = {
567
565
  type SkfSelectOptionGroupProps = {
568
566
  /** */
569
567
  label?: SkfSelectOptionGroup["label"];
568
+ /** */
569
+ small?: SkfSelectOptionGroup["small"];
570
570
  };
571
571
 
572
572
  type SkfTagProps = {
@@ -653,6 +653,8 @@ type SkfSelectOptionProps = {
653
653
  /** The option's label text (equivalent to the tags textContent) */
654
654
  text?: SkfSelectOption["text"];
655
655
  /** */
656
+ small?: SkfSelectOption["small"];
657
+ /** */
656
658
  role?: SkfSelectOption["role"];
657
659
  /** */
658
660
  _parent?: SkfSelectOption["_parent"];
@@ -944,6 +946,9 @@ export type CustomElements = {
944
946
  *
945
947
  * ### **Slots:**
946
948
  * - _default_ - The card's main content
949
+ *
950
+ * ### **CSS Properties:**
951
+ * - **--mod-card-bg-color** - Ability to set a custom background color _(default: undefined)_
947
952
  */
948
953
  "skf-card": DefineComponent<SkfCardProps>;
949
954
 
@@ -1048,6 +1053,30 @@ export type CustomElements = {
1048
1053
  */
1049
1054
  "skf-logo": DefineComponent<SkfLogoProps>;
1050
1055
 
1056
+ /**
1057
+ * The `<skf-link>` can be used as either a regular link or a semantic button. The button variant is
1058
+ * intended to be used for triggering javascript functions, not handling forms.
1059
+ * ---
1060
+ *
1061
+ *
1062
+ * ### **Events:**
1063
+ * - **skf-link-click** - Fired when the link is clicked
1064
+ *
1065
+ * ### **Slots:**
1066
+ * - _default_ - The links' main content
1067
+ */
1068
+ "skf-link": DefineComponent<SkfLinkProps>;
1069
+
1070
+ /**
1071
+ * The `<skf-nav>` is a component that displays a list of <nav-items>.
1072
+ * ---
1073
+ *
1074
+ *
1075
+ * ### **Slots:**
1076
+ * - _default_ - The component's main content
1077
+ */
1078
+ "skf-nav-item": DefineComponent<SkfNavItemProps>;
1079
+
1051
1080
  /**
1052
1081
  * The `<skf-nav>` is a component that displays a list of <nav-items>.
1053
1082
  * ---
@@ -1084,21 +1113,14 @@ export type CustomElements = {
1084
1113
  */
1085
1114
  "skf-input": DefineComponent<SkfInputProps>;
1086
1115
 
1087
- /**
1088
- * The `<skf-link>` can be used as either a regular link or a link styled semantic button
1089
- * ---
1090
- *
1091
- *
1092
- * ### **Slots:**
1093
- * - _default_ - The links' main content
1094
- */
1095
- "skf-link": DefineComponent<SkfLinkProps>;
1096
-
1097
1116
  /**
1098
1117
  * The `<skf-menu-item>` is used in conjunction with the `<skf-menu>` component
1099
1118
  * ---
1100
1119
  *
1101
1120
  *
1121
+ * ### **Events:**
1122
+ * - **skf-link-click** - Fired when the link is clicked
1123
+ *
1102
1124
  * ### **Slots:**
1103
1125
  * - _default_ - The component's main content
1104
1126
  */
@@ -1120,16 +1142,6 @@ export type CustomElements = {
1120
1142
  */
1121
1143
  "skf-menu": DefineComponent<SkfMenuProps>;
1122
1144
 
1123
- /**
1124
- * The `<skf-nav>` is a component that displays a list of <nav-items>.
1125
- * ---
1126
- *
1127
- *
1128
- * ### **Slots:**
1129
- * - _default_ - The component's main content
1130
- */
1131
- "skf-nav-item": DefineComponent<SkfNavItemProps>;
1132
-
1133
1145
  /**
1134
1146
  * The `<skf-popover>` is a general purpose component that displays the slot content in a popover.
1135
1147
  *
@@ -240,7 +240,7 @@
240
240
  },
241
241
  {
242
242
  "name": "skf-card",
243
- "description": "The `<skf-card>` can be used to group related subjects in a container\n\nSee [zeroheight](https://zeroheight.com/853e936c9/p/021eed-card) for design principles\n---\n\n\n### **Slots:**\n - _default_ - The card's main content",
243
+ "description": "The `<skf-card>` can be used to group related subjects in a container\n\nSee [zeroheight](https://zeroheight.com/853e936c9/p/021eed-card) for design principles\n---\n\n\n### **Slots:**\n - _default_ - The card's main content\n\n### **CSS Properties:**\n - **--mod-card-bg-color** - Ability to set a custom background color _(default: undefined)_",
244
244
  "attributes": [
245
245
  {
246
246
  "name": "no-border",
@@ -581,10 +581,92 @@
581
581
  ],
582
582
  "references": []
583
583
  },
584
+ {
585
+ "name": "skf-link",
586
+ "description": "The `<skf-link>` can be used as either a regular link or a semantic button. The button variant is\nintended to be used for triggering javascript functions, not handling forms.\n---\n\n\n### **Events:**\n - **skf-link-click** - Fired when the link is clicked\n\n### **Slots:**\n - _default_ - The links' main content",
587
+ "attributes": [
588
+ {
589
+ "name": "as",
590
+ "description": "Defines the semantic element to render",
591
+ "values": [{ "name": "button" }, { "name": "link" }]
592
+ },
593
+ {
594
+ "name": "color",
595
+ "description": "Defines the text-color",
596
+ "values": [{ "name": "Color" }]
597
+ },
598
+ {
599
+ "name": "disabled",
600
+ "description": "If true, disables the link",
601
+ "values": []
602
+ },
603
+ {
604
+ "name": "download",
605
+ "description": "If defined, downloads the url",
606
+ "values": []
607
+ },
608
+ {
609
+ "name": "href",
610
+ "description": "If defined, loads url on click",
611
+ "values": []
612
+ },
613
+ {
614
+ "name": "icon",
615
+ "description": "If defined, renders an icon before or after the text",
616
+ "values": [{ "name": "Icon" }]
617
+ },
618
+ {
619
+ "name": "icon-right",
620
+ "description": "If true, the icon is placed to the right in relation to the text",
621
+ "values": []
622
+ },
623
+ {
624
+ "name": "rel",
625
+ "description": "If defined, describes the relationship between a linked resource and the current document",
626
+ "values": []
627
+ },
628
+ {
629
+ "name": "route",
630
+ "description": "If defined, used on conjunction with onClick property. **Notice!** Only applicable to as=button.",
631
+ "values": []
632
+ },
633
+ {
634
+ "name": "stretch",
635
+ "description": "If true, fills the parents horizontal axis",
636
+ "values": []
637
+ },
638
+ {
639
+ "name": "target",
640
+ "description": "If defined, specifies where to open the linked document",
641
+ "values": [
642
+ { "name": "_blank" },
643
+ { "name": "_parent" },
644
+ { "name": "_self" },
645
+ { "name": "_top" }
646
+ ]
647
+ }
648
+ ],
649
+ "references": []
650
+ },
651
+ {
652
+ "name": "skf-nav-item",
653
+ "description": "The `<skf-nav>` is a component that displays a list of <nav-items>.\n---\n\n\n### **Slots:**\n - _default_ - The component's main content",
654
+ "attributes": [
655
+ { "name": "href", "values": [] },
656
+ { "name": "icon", "values": [{ "name": "Icon" }] }
657
+ ],
658
+ "references": []
659
+ },
584
660
  {
585
661
  "name": "skf-nav",
586
662
  "description": "The `<skf-nav>` is a component that displays a list of <nav-items>.\n---\n\n\n### **Slots:**\n - _default_ - The component's main content",
587
- "attributes": [{ "name": "vertical", "values": [] }],
663
+ "attributes": [
664
+ {
665
+ "name": "vertical",
666
+ "description": "If true, the navigation will be displayed vertically",
667
+ "values": []
668
+ }
669
+ ],
588
670
  "references": []
589
671
  },
590
672
  {
@@ -778,91 +860,19 @@
778
860
  ],
779
861
  "references": []
780
862
  },
781
- {
782
- "name": "skf-link",
783
- "description": "The `<skf-link>` can be used as either a regular link or a link styled semantic button\n---\n\n\n### **Slots:**\n - _default_ - The links' main content",
784
- "attributes": [
785
- {
786
- "name": "as",
787
- "description": "Defines the semantic element to render",
788
- "values": [{ "name": "button" }, { "name": "a" }]
789
- },
790
- {
791
- "name": "color",
792
- "description": "Defines the text-color",
793
- "values": [{ "name": "primary" }, { "name": "inverse" }]
794
- },
795
- {
796
- "name": "disabled",
797
- "description": "If true, disables the link",
798
- "values": []
799
- },
800
- {
801
- "name": "download",
802
- "description": "If defined, downloads the url",
803
- "values": []
804
- },
805
- {
806
- "name": "href",
807
- "description": "If defined, loads url on click",
808
- "values": []
809
- },
810
- {
811
- "name": "icon",
812
- "description": "If defined, renders an icon before or after the text",
813
- "values": [{ "name": "Icon" }]
814
- },
815
- {
816
- "name": "icon-placement",
817
- "description": "Defines the position of the icon in relation to the text",
818
- "values": [{ "name": "left" }, { "name": "right" }]
819
- },
820
- {
821
- "name": "rel",
822
- "description": "If defined, describes the relationship between a linked resource and the current document",
823
- "values": []
824
- },
825
- {
826
- "name": "route",
827
- "description": "If defined, used on conjunction with onClick property, second argument",
828
- "values": []
829
- },
830
- {
831
- "name": "stretch",
832
- "description": "If true, fills the parents horizontal axis",
833
- "values": []
834
- },
835
- {
836
- "name": "target",
837
- "description": "If defined, specifies where to open the linked document",
838
- "values": [
839
- { "name": "_blank" },
840
- { "name": "_parent" },
841
- { "name": "_self" },
842
- { "name": "_top" }
843
- ]
844
- },
845
- {
846
- "name": "type",
847
- "description": "Defines the type of button",
848
- "values": [{ "name": "SkfLinkType" }]
849
- }
850
- ],
851
- "references": []
852
- },
853
863
  {
854
864
  "name": "skf-menu-item",
855
- "description": "The `<skf-menu-item>` is used in conjunction with the `<skf-menu>` component\n---\n\n\n### **Slots:**\n - _default_ - The component's main content",
865
+ "description": "The `<skf-menu-item>` is used in conjunction with the `<skf-menu>` component\n---\n\n\n### **Events:**\n - **skf-link-click** - Fired when the link is clicked\n\n### **Slots:**\n - _default_ - The component's main content",
856
866
  "attributes": [
857
867
  {
858
868
  "name": "as",
859
869
  "description": "Defines the semantic element to render",
860
- "values": [{ "name": "button" }, { "name": "a" }]
870
+ "values": [{ "name": "button" }, { "name": "link" }]
861
871
  },
862
872
  {
863
873
  "name": "color",
864
874
  "description": "Defines the text-color",
865
- "values": [{ "name": "primary" }, { "name": "inverse" }]
875
+ "values": [{ "name": "Color" }]
866
876
  },
867
877
  {
868
878
  "name": "disabled",
@@ -885,9 +895,9 @@
885
895
  "values": [{ "name": "Icon" }]
886
896
  },
887
897
  {
888
- "name": "icon-placement",
889
- "description": "Defines the position of the icon in relation to the text",
890
- "values": [{ "name": "left" }, { "name": "right" }]
898
+ "name": "icon-right",
899
+ "description": "If true, the icon is placed to the right in relation to the text",
900
+ "values": []
891
901
  },
892
902
  {
893
903
  "name": "rel",
@@ -896,7 +906,7 @@
896
906
  },
897
907
  {
898
908
  "name": "route",
899
- "description": "If defined, used on conjunction with onClick property, second argument",
909
+ "description": "If defined, used on conjunction with onClick property. **Notice!** Only applicable to as=button.",
900
910
  "values": []
901
911
  },
902
912
  {
@@ -913,11 +923,6 @@
913
923
  { "name": "_self" },
914
924
  { "name": "_top" }
915
925
  ]
916
- },
917
- {
918
- "name": "type",
919
- "description": "Defines the type of button",
920
- "values": [{ "name": "SkfLinkType" }]
921
926
  }
922
927
  ],
923
928
  "references": []
@@ -952,15 +957,6 @@
952
957
  ],
953
958
  "references": []
954
959
  },
955
- {
956
- "name": "skf-nav-item",
957
- "description": "The `<skf-nav>` is a component that displays a list of <nav-items>.\n---\n\n\n### **Slots:**\n - _default_ - The component's main content",
958
- "attributes": [
959
- { "name": "href", "values": [] },
960
- { "name": "icon", "values": [{ "name": "Icon" }] }
961
- ],
962
- "references": []
963
- },
964
960
  {
965
961
  "name": "skf-popover",
966
962
  "description": "The `<skf-popover>` is a general purpose component that displays the slot content in a popover.\n\nSee [zeroheight](https://zeroheight.com/853e936c9/p/983e5d-popover) for design principles\n---\n\n\n### **Events:**\n - **skf-opened** - Fired when the menu is opened\n- **skf-closed** - Fired when the menu is closed\n\n### **Slots:**\n - _default_ - The popover content",