@skf-design-system/ui-components 1.0.0-beta.7 → 1.0.1-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (127) hide show
  1. package/dist/components/alert/alert.component.d.ts +2 -2
  2. package/dist/components/alert/alert.component.js +34 -34
  3. package/dist/components/breadcrumb/breadcrumb.component.d.ts +29 -0
  4. package/dist/components/breadcrumb/breadcrumb.d.ts +8 -0
  5. package/dist/components/breadcrumb/breadcrumb.styles.d.ts +1 -0
  6. package/dist/components/breadcrumb-item/breadcrumb-item.component.d.ts +25 -0
  7. package/dist/components/breadcrumb-item/breadcrumb-item.d.ts +8 -0
  8. package/dist/components/breadcrumb-item/breadcrumb-item.styles.d.ts +1 -0
  9. package/dist/components/button/button.component.d.ts +6 -4
  10. package/dist/components/button/button.component.js +87 -70
  11. package/dist/components/button/button.styles.js +64 -45
  12. package/dist/components/checkbox/checkbox.component.d.ts +3 -1
  13. package/dist/components/checkbox/checkbox.component.js +71 -58
  14. package/dist/components/date-picker/datepicker.calendar.component.d.ts +72 -0
  15. package/dist/components/date-picker/datepicker.calendar.component.js +382 -0
  16. package/dist/components/date-picker/datepicker.calendar.styles.d.ts +1 -0
  17. package/dist/components/date-picker/datepicker.calendar.styles.js +192 -0
  18. package/dist/components/date-picker/datepicker.component.d.ts +74 -0
  19. package/dist/components/date-picker/datepicker.component.js +241 -0
  20. package/dist/components/date-picker/datepicker.d.ts +10 -0
  21. package/dist/components/date-picker/datepicker.helpers.d.ts +40 -0
  22. package/dist/components/date-picker/datepicker.helpers.js +69 -0
  23. package/dist/components/date-picker/datepicker.js +8 -0
  24. package/dist/components/date-picker/datepicker.styles.d.ts +1 -0
  25. package/dist/components/date-picker/datepicker.styles.js +99 -0
  26. package/dist/components/date-picker-input/datepicker-input.component.d.ts +107 -0
  27. package/dist/components/date-picker-input/datepicker-input.component.js +397 -0
  28. package/dist/components/date-picker-input/datepicker-input.d.ts +8 -0
  29. package/dist/components/date-picker-input/datepicker-input.helpers.d.ts +4 -0
  30. package/dist/components/date-picker-input/datepicker-input.helpers.js +29 -0
  31. package/dist/components/date-picker-input/datepicker-input.js +6 -0
  32. package/dist/components/date-picker-input/datepicker-input.styles.d.ts +1 -0
  33. package/dist/components/date-picker-input/datepicker-input.styles.js +22 -0
  34. package/dist/components/dialog/dialog.component.d.ts +0 -1
  35. package/dist/components/dialog/dialog.component.js +2 -4
  36. package/dist/components/icon/icon.component.d.ts +1 -4
  37. package/dist/components/icon/icon.component.js +28 -19
  38. package/dist/components/icon/icon.styles.js +53 -47
  39. package/dist/components/input/input.component.d.ts +1 -0
  40. package/dist/components/input/input.component.js +87 -80
  41. package/dist/components/link/link.component.d.ts +1 -0
  42. package/dist/components/link/link.component.js +21 -21
  43. package/dist/components/menu/menu.component.d.ts +24 -0
  44. package/dist/components/menu/menu.component.js +18 -0
  45. package/dist/components/menu/menu.d.ts +8 -0
  46. package/dist/components/menu/menu.js +6 -0
  47. package/dist/components/menu/menu.styles.d.ts +1 -0
  48. package/dist/components/menu/menu.styles.js +11 -0
  49. package/dist/components/menu-item/menu-item.component.d.ts +25 -0
  50. package/dist/components/menu-item/menu-item.component.js +13 -0
  51. package/dist/components/menu-item/menu-item.d.ts +8 -0
  52. package/dist/components/menu-item/menu-item.js +6 -0
  53. package/dist/components/menu-item/menu-item.styles.d.ts +1 -0
  54. package/dist/components/menu-item/menu-item.styles.js +19 -0
  55. package/dist/components/popover/popover.component.d.ts +29 -0
  56. package/dist/components/popover/popover.component.js +37 -0
  57. package/dist/components/popover/popover.d.ts +8 -0
  58. package/dist/components/popover/popover.js +6 -0
  59. package/dist/components/popover/popover.styles.d.ts +1 -0
  60. package/dist/components/popover/popover.styles.js +12 -0
  61. package/dist/components/select/select.component.d.ts +8 -10
  62. package/dist/components/select/select.component.js +115 -118
  63. package/dist/components/select/select.controllers.d.ts +0 -25
  64. package/dist/components/select/select.controllers.js +35 -95
  65. package/dist/components/stepper/stepper.component.d.ts +38 -0
  66. package/dist/components/stepper/stepper.component.js +91 -0
  67. package/dist/components/stepper/stepper.d.ts +8 -0
  68. package/dist/components/stepper/stepper.helpers.d.ts +16 -0
  69. package/dist/components/stepper/stepper.helpers.js +18 -0
  70. package/dist/components/stepper/stepper.js +6 -0
  71. package/dist/components/stepper/stepper.styles.d.ts +1 -0
  72. package/dist/components/stepper/stepper.styles.js +15 -0
  73. package/dist/components/stepper-item/stepper-item.component.d.ts +47 -0
  74. package/dist/components/stepper-item/stepper-item.component.js +113 -0
  75. package/dist/components/stepper-item/stepper-item.d.ts +8 -0
  76. package/dist/components/stepper-item/stepper-item.js +6 -0
  77. package/dist/components/stepper-item/stepper-item.styles.d.ts +1 -0
  78. package/dist/components/stepper-item/stepper-item.styles.js +98 -0
  79. package/dist/components/toast/toast.component.d.ts +7 -4
  80. package/dist/components/toast/toast.component.js +24 -20
  81. package/dist/components/toast/toast.singleton.d.ts +2 -7
  82. package/dist/components/toast/toast.singleton.js +25 -25
  83. package/dist/components/toast-item/toast-item.component.js +15 -15
  84. package/dist/components/toast-item/toast-item.styles.js +13 -11
  85. package/dist/components/tooltip/tooltip.component.d.ts +24 -0
  86. package/dist/components/tooltip/tooltip.component.js +18 -0
  87. package/dist/components/tooltip/tooltip.d.ts +8 -0
  88. package/dist/components/tooltip/tooltip.js +6 -0
  89. package/dist/components/tooltip/tooltip.styles.d.ts +1 -0
  90. package/dist/components/tooltip/tooltip.styles.js +12 -0
  91. package/dist/custom-elements.json +3278 -1321
  92. package/dist/index.d.ts +8 -0
  93. package/dist/index.js +78 -54
  94. package/dist/internal/base-classes/popover/popover.base.d.ts +29 -0
  95. package/dist/internal/base-classes/popover/popover.base.js +116 -0
  96. package/dist/internal/base-classes/popover/popover.styles.d.ts +1 -0
  97. package/dist/internal/base-classes/popover/popover.styles.js +29 -0
  98. package/dist/internal/controllers/popover.controller.d.ts +17 -0
  99. package/dist/internal/controllers/popover.controller.js +44 -0
  100. package/dist/internal/helpers/dateFormatter.d.ts +2 -0
  101. package/dist/internal/helpers/hintSeverity.d.ts +1 -1
  102. package/dist/internal/helpers/utilityTypes.d.ts +22 -0
  103. package/dist/react/index.d.ts +11 -2
  104. package/dist/react/index.js +11 -2
  105. package/dist/react/skf-breadcrumb/index.d.ts +9 -0
  106. package/dist/react/skf-breadcrumb/index.js +17 -0
  107. package/dist/react/skf-breadcrumb-item/index.d.ts +3 -0
  108. package/dist/react/skf-breadcrumb-item/index.js +13 -0
  109. package/dist/react/skf-datepicker/index.d.ts +12 -0
  110. package/dist/react/skf-datepicker/index.js +18 -0
  111. package/dist/react/skf-menu/index.d.ts +12 -0
  112. package/dist/react/skf-menu/index.js +18 -0
  113. package/dist/react/skf-menu-item/index.d.ts +27 -0
  114. package/dist/react/skf-menu-item/index.js +23 -0
  115. package/dist/react/skf-popover/index.d.ts +12 -0
  116. package/dist/react/skf-popover/index.js +18 -0
  117. package/dist/react/skf-stepper/index.d.ts +9 -0
  118. package/dist/react/skf-stepper/index.js +17 -0
  119. package/dist/react/skf-stepper-item/index.d.ts +9 -0
  120. package/dist/react/skf-stepper-item/index.js +17 -0
  121. package/dist/react/skf-tooltip/index.d.ts +12 -0
  122. package/dist/react/skf-tooltip/index.js +18 -0
  123. package/dist/types/jsx/custom-element-jsx.d.ts +628 -155
  124. package/dist/types/vue/index.d.ts +369 -74
  125. package/dist/vscode.html-custom-data.json +761 -391
  126. package/dist/web-types.json +936 -293
  127. package/package.json +34 -33
package/dist/index.d.ts CHANGED
@@ -4,6 +4,8 @@ export { default as SkfButton } from './components/button/button.js';
4
4
  export { default as SkfCard } from './components/card/card.js';
5
5
  export { default as SkfCheckbox } from './components/checkbox/checkbox.js';
6
6
  export { default as SkfCollapse } from './components/collapse/collapse.js';
7
+ export { default as SkfDatePickerInput } from './components/date-picker-input/datepicker-input.js';
8
+ export { default as SkfDatePicker } from './components/date-picker/datepicker.js';
7
9
  export { default as SkfDialog } from './components/dialog/dialog.js';
8
10
  export { default as SkfDivider } from './components/divider/divider.js';
9
11
  export { default as SkfHeading } from './components/heading/heading.js';
@@ -12,11 +14,16 @@ export { default as SkfInput } from './components/input/input.js';
12
14
  export { default as SkfLink } from './components/link/link.js';
13
15
  export { default as SkfLoader } from './components/loader/loader.js';
14
16
  export { default as SkfLogo } from './components/logo/logo.js';
17
+ export { default as SkfMenuItem } from './components/menu-item/menu-item.js';
18
+ export { default as SkfMenu } from './components/menu/menu.js';
19
+ export { default as SkfPopover } from './components/popover/popover.js';
15
20
  export { default as SkfProgress } from './components/progress/progress.js';
16
21
  export { default as SkfRadio } from './components/radio/radio.js';
17
22
  export { default as SkfOptionGroup } from './components/select-option-group/select-option-group.js';
18
23
  export { default as SkfOption } from './components/select-option/select-option.js';
19
24
  export { default as SkfSelect } from './components/select/select.js';
25
+ export { default as SkfStepperItem } from './components/stepper-item/stepper-item.js';
26
+ export { default as SkfStepper } from './components/stepper/stepper.js';
20
27
  export { default as SkfSwitch } from './components/switch/switch.js';
21
28
  export { default as SkfTabGoup } from './components/tab-group/tab-group.js';
22
29
  export { default as SkfTabPanel } from './components/tab-panel/tab-panel.js';
@@ -24,3 +31,4 @@ export { default as SkfTab } from './components/tab/tab.js';
24
31
  export { default as SkfTag } from './components/tag/tag.js';
25
32
  export { default as SkfTextArea } from './components/textarea/textarea.js';
26
33
  export { default as SkfToast } from './components/toast/toast.js';
34
+ export { default as SkfTooltip } from './components/tooltip/tooltip.js';
package/dist/index.js CHANGED
@@ -4,6 +4,8 @@ import "./components/button/button.js";
4
4
  import "./components/card/card.js";
5
5
  import "./components/checkbox/checkbox.js";
6
6
  import "./components/collapse/collapse.js";
7
+ import "./components/date-picker-input/datepicker-input.js";
8
+ import "./components/date-picker/datepicker.js";
7
9
  import "./components/dialog/dialog.js";
8
10
  import "./components/divider/divider.js";
9
11
  import "./components/heading/heading.js";
@@ -12,11 +14,16 @@ import "./components/input/input.js";
12
14
  import "./components/link/link.js";
13
15
  import "./components/loader/loader.js";
14
16
  import "./components/logo/logo.js";
17
+ import "./components/menu-item/menu-item.js";
18
+ import "./components/menu/menu.js";
19
+ import "./components/popover/popover.js";
15
20
  import "./components/progress/progress.js";
16
21
  import "./components/radio/radio.js";
17
22
  import "./components/select-option-group/select-option-group.js";
18
23
  import "./components/select-option/select-option.js";
19
24
  import "./components/select/select.js";
25
+ import "./components/stepper-item/stepper-item.js";
26
+ import "./components/stepper/stepper.js";
20
27
  import "./components/switch/switch.js";
21
28
  import "./components/tab-group/tab-group.js";
22
29
  import "./components/tab-panel/tab-panel.js";
@@ -24,59 +31,76 @@ import "./components/tab/tab.js";
24
31
  import "./components/tag/tag.js";
25
32
  import "./components/textarea/textarea.js";
26
33
  import "./components/toast/toast.js";
27
- import { SkfAccordion as D } from "./components/accordion/accordion.component.js";
28
- import { SkfAlert as v } from "./components/alert/alert.component.js";
29
- import { SkfButton as B } from "./components/button/button.component.js";
30
- import { SkfCard as R } from "./components/card/card.component.js";
31
- import { SkfCheckbox as q } from "./components/checkbox/checkbox.component.js";
32
- import { SkfCollapse as z } from "./components/collapse/collapse.component.js";
33
- import { SkfDialog as F } from "./components/dialog/dialog.component.js";
34
- import { SkfDivider as K } from "./components/divider/divider.component.js";
35
- import { SkfHeading as N } from "./components/heading/heading.component.js";
36
- import { SkfIcon as U } from "./components/icon/icon.component.js";
37
- import { SkfInput as W } from "./components/input/input.component.js";
38
- import { SkfLink as Y } from "./components/link/link.component.js";
39
- import { SkfLoader as _ } from "./components/loader/loader.component.js";
40
- import { SkfLogo as oo } from "./components/logo/logo.component.js";
41
- import { SkfProgress as to } from "./components/progress/progress.component.js";
42
- import { SkfRadio as fo } from "./components/radio/radio.component.js";
43
- import { SkfSelectOptionGroup as eo } from "./components/select-option-group/select-option-group.component.js";
44
- import { SkfSelectOption as So } from "./components/select-option/select-option.component.js";
45
- import { SkfSelect as xo } from "./components/select/select.component.js";
46
- import { SkfSwitch as no } from "./components/switch/switch.component.js";
47
- import { SkfTabGroup as lo } from "./components/tab-group/tab-group.component.js";
48
- import { SkfTabPanel as To } from "./components/tab-panel/tab-panel.component.js";
49
- import { SkfTab as bo } from "./components/tab/tab.component.js";
50
- import { SkfTag as Ao } from "./components/tag/tag.component.js";
51
- import { SkfTextArea as Oo } from "./components/textarea/textarea.component.js";
52
- import { SkfToast as Io } from "./components/toast/toast.component.js";
53
- import { SkfAccordionItem as ho } from "./components/accordion/accordion-item.js";
34
+ import "./components/tooltip/tooltip.js";
35
+ import { SkfAccordion as j } from "./components/accordion/accordion.component.js";
36
+ import { SkfAlert as y } from "./components/alert/alert.component.js";
37
+ import { SkfButton as E } from "./components/button/button.component.js";
38
+ import { SkfCard as J } from "./components/card/card.component.js";
39
+ import { SkfCheckbox as N } from "./components/checkbox/checkbox.component.js";
40
+ import { SkfCollapse as U } from "./components/collapse/collapse.component.js";
41
+ import { SkfDatePickerInput as W } from "./components/date-picker-input/datepicker-input.component.js";
42
+ import { SkfDatePicker as Y } from "./components/date-picker/datepicker.component.js";
43
+ import { SkfDialog as _ } from "./components/dialog/dialog.component.js";
44
+ import { SkfDivider as oo } from "./components/divider/divider.component.js";
45
+ import { SkfHeading as to } from "./components/heading/heading.component.js";
46
+ import { SkfIcon as fo } from "./components/icon/icon.component.js";
47
+ import { SkfInput as eo } from "./components/input/input.component.js";
48
+ import { SkfLink as So } from "./components/link/link.component.js";
49
+ import { SkfLoader as xo } from "./components/loader/loader.component.js";
50
+ import { SkfLogo as no } from "./components/logo/logo.component.js";
51
+ import { SkfMenuItem as lo } from "./components/menu-item/menu-item.component.js";
52
+ import { SkfMenu as To } from "./components/menu/menu.component.js";
53
+ import { SkfPopover as Io } from "./components/popover/popover.component.js";
54
+ import { SkfProgress as go } from "./components/progress/progress.component.js";
55
+ import { SkfRadio as Ao } from "./components/radio/radio.component.js";
56
+ import { SkfSelectOptionGroup as Go } from "./components/select-option-group/select-option-group.component.js";
57
+ import { SkfSelectOption as Co } from "./components/select-option/select-option.component.js";
58
+ import { SkfSelect as ho } from "./components/select/select.component.js";
59
+ import { SkfStepperItem as Mo } from "./components/stepper-item/stepper-item.component.js";
60
+ import { SkfStepper as Bo } from "./components/stepper/stepper.component.js";
61
+ import { SkfSwitch as Ro } from "./components/switch/switch.component.js";
62
+ import { SkfTabGroup as qo } from "./components/tab-group/tab-group.component.js";
63
+ import { SkfTabPanel as zo } from "./components/tab-panel/tab-panel.component.js";
64
+ import { SkfTab as Fo } from "./components/tab/tab.component.js";
65
+ import { SkfTag as Ko } from "./components/tag/tag.component.js";
66
+ import { SkfTextArea as Qo } from "./components/textarea/textarea.component.js";
67
+ import { SkfToast as Vo } from "./components/toast/toast.component.js";
68
+ import { SkfTooltip as Xo } from "./components/tooltip/tooltip.component.js";
69
+ import { SkfAccordionItem as Zo } from "./components/accordion/accordion-item.js";
54
70
  export {
55
- D as SkfAccordion,
56
- ho as SkfAccordionItem,
57
- v as SkfAlert,
58
- B as SkfButton,
59
- R as SkfCard,
60
- q as SkfCheckbox,
61
- z as SkfCollapse,
62
- F as SkfDialog,
63
- K as SkfDivider,
64
- N as SkfHeading,
65
- U as SkfIcon,
66
- W as SkfInput,
67
- Y as SkfLink,
68
- _ as SkfLoader,
69
- oo as SkfLogo,
70
- So as SkfOption,
71
- eo as SkfOptionGroup,
72
- to as SkfProgress,
73
- fo as SkfRadio,
74
- xo as SkfSelect,
75
- no as SkfSwitch,
76
- bo as SkfTab,
77
- lo as SkfTabGoup,
78
- To as SkfTabPanel,
79
- Ao as SkfTag,
80
- Oo as SkfTextArea,
81
- Io as SkfToast
71
+ j as SkfAccordion,
72
+ Zo as SkfAccordionItem,
73
+ y as SkfAlert,
74
+ E as SkfButton,
75
+ J as SkfCard,
76
+ N as SkfCheckbox,
77
+ U as SkfCollapse,
78
+ Y as SkfDatePicker,
79
+ W as SkfDatePickerInput,
80
+ _ as SkfDialog,
81
+ oo as SkfDivider,
82
+ to as SkfHeading,
83
+ fo as SkfIcon,
84
+ eo as SkfInput,
85
+ So as SkfLink,
86
+ xo as SkfLoader,
87
+ no as SkfLogo,
88
+ To as SkfMenu,
89
+ lo as SkfMenuItem,
90
+ Co as SkfOption,
91
+ Go as SkfOptionGroup,
92
+ Io as SkfPopover,
93
+ go as SkfProgress,
94
+ Ao as SkfRadio,
95
+ ho as SkfSelect,
96
+ Bo as SkfStepper,
97
+ Mo as SkfStepperItem,
98
+ Ro as SkfSwitch,
99
+ Fo as SkfTab,
100
+ qo as SkfTabGoup,
101
+ zo as SkfTabPanel,
102
+ Ko as SkfTag,
103
+ Qo as SkfTextArea,
104
+ Vo as SkfToast,
105
+ Xo as SkfTooltip
82
106
  };
@@ -0,0 +1,29 @@
1
+ import { type Placement } from '@floating-ui/dom';
2
+ import { SkfElement } from '../../components/skf-element.js';
3
+ import { PopoverController } from '../../controllers/popover.controller.js';
4
+ import { type CSSResultGroup } from 'lit';
5
+ export declare class SkfPopoverBase extends SkfElement {
6
+ static styles: CSSResultGroup;
7
+ static classMap: {};
8
+ isOpen: boolean;
9
+ placement: Placement;
10
+ variant: 'dropdown' | 'popup' | 'tooltip';
11
+ anchor?: string;
12
+ offset: number;
13
+ $anchor?: Element | HTMLElement | null;
14
+ arrow: boolean;
15
+ $popover: HTMLElement;
16
+ $arrow: HTMLElement;
17
+ /** @internal */
18
+ protected popoverController: PopoverController;
19
+ private _toggleOpen;
20
+ private _handleToggle;
21
+ handleToggleOpen: () => void;
22
+ handleAnchorChange: () => Promise<void>;
23
+ reposition: () => Promise<void>;
24
+ open: () => boolean;
25
+ close: () => boolean;
26
+ addEventListeners($element: HTMLElement | Element): void;
27
+ removeEventListeners($element: HTMLElement | Element): void;
28
+ render(): import("lit").TemplateResult<1>;
29
+ }
@@ -0,0 +1,116 @@
1
+ import { flip as b, offset as C, arrow as _, computePosition as E } from "@floating-ui/dom";
2
+ import { SkfElement as P } from "../../components/skf-element.js";
3
+ import { PopoverController as L } from "../../controllers/popover.controller.js";
4
+ import { watch as $ } from "../../helpers/watch.js";
5
+ import M from "../../../styles/component.styles.js";
6
+ import { html as y, nothing as T } from "lit";
7
+ import { property as a, state as h, query as u } from "lit/decorators.js";
8
+ import { classMap as j } from "lit/directives/class-map.js";
9
+ import { styles as k } from "./popover.styles.js";
10
+ var B = Object.defineProperty, o = (l, t, i, c) => {
11
+ for (var r = void 0, n = l.length - 1, p; n >= 0; n--)
12
+ (p = l[n]) && (r = p(t, i, r) || r);
13
+ return r && B(t, i, r), r;
14
+ }, s;
15
+ const e = (s = class extends P {
16
+ constructor() {
17
+ super(...arguments), this.isOpen = !1, this.placement = "top", this.variant = "popup", this.offset = 0, this.arrow = !1, this.popoverController = new L(this), this._toggleOpen = (t) => this.isOpen = t ?? !this.isOpen, this._handleToggle = (t) => {
18
+ const i = t.newState === "open";
19
+ this.isOpen = i, this.emit(i ? "open" : "close");
20
+ }, this.handleToggleOpen = () => {
21
+ this.$popover.togglePopover(this.isOpen), this.$popover.animate([{ opacity: 0 }, { opacity: 1 }], {
22
+ duration: 150,
23
+ easing: "ease-out",
24
+ fill: "forwards"
25
+ });
26
+ }, this.handleAnchorChange = async () => {
27
+ if (!this.anchor) return;
28
+ await this.popoverController.stop(), this.$anchor && this.removeEventListeners(this.$anchor);
29
+ const t = this.getRootNode();
30
+ this.$anchor = t.getElementById(this.anchor), this.$anchor && (this.addEventListeners(this.$anchor), this.popoverController.start());
31
+ }, this.reposition = async () => {
32
+ var n, p, f;
33
+ if (!this.$anchor) return;
34
+ const t = [b(), C(this.offset)];
35
+ this.arrow && t.push(_({ element: this.$arrow }));
36
+ const { x: i, y: c, middlewareData: r } = await E(this.$anchor, this.$popover, {
37
+ placement: this.placement,
38
+ middleware: t,
39
+ strategy: "fixed"
40
+ });
41
+ if (Object.assign(this.$popover.style, {
42
+ left: `${String(i)}px`,
43
+ top: `${String(c)}px`
44
+ }), this.arrow) {
45
+ const m = this.placement.split("-")[0], d = { top: "bottom", right: "left", bottom: "top", left: "right" }[m] ?? "", g = (n = r.flip) == null ? void 0 : n.index, v = (p = r.arrow) == null ? void 0 : p.x, w = (f = r.arrow) == null ? void 0 : f.y, O = typeof v == "number" ? `${String(v)}px` : "", S = typeof w == "number" ? `${String(w)}px` : "", x = {
46
+ bottom: 45,
47
+ right: 135,
48
+ top: 225,
49
+ left: 315
50
+ };
51
+ Object.assign(this.$arrow.style, {
52
+ top: S,
53
+ [this.placement.includes("left") ? "right" : "left"]: O,
54
+ [g ? m : d]: "calc(var(--_skf-popover-arrow-size) * -1)",
55
+ rotate: `${(x[d] + (g ? 180 : 0)).toString()}deg`
56
+ });
57
+ }
58
+ }, this.open = () => this._toggleOpen(!0), this.close = () => this._toggleOpen(!1);
59
+ }
60
+ addEventListeners(t) {
61
+ throw new Error(`Cannot add eventListeners for ${t.id}. Method not implemented.`);
62
+ }
63
+ removeEventListeners(t) {
64
+ throw new Error(`Cannot remove eventListeners for ${t.id}. Method not implemented.`);
65
+ }
66
+ render() {
67
+ return y`
68
+ <div
69
+ @toggle=${this._handleToggle}
70
+ class=${j({ popover: !0, ...s.classMap })}
71
+ id="popover"
72
+ popover
73
+ >
74
+ <slot></slot>
75
+ ${this.arrow ? y`<div class="popover__arrow" id="arrow"></div>` : T}
76
+ </div>
77
+ `;
78
+ }
79
+ }, s.styles = [M, k], s.classMap = {}, s);
80
+ o([
81
+ a({ type: Boolean, reflect: !0 })
82
+ ], e.prototype, "isOpen");
83
+ o([
84
+ a()
85
+ ], e.prototype, "placement");
86
+ o([
87
+ a()
88
+ ], e.prototype, "variant");
89
+ o([
90
+ a()
91
+ ], e.prototype, "anchor");
92
+ o([
93
+ h()
94
+ ], e.prototype, "offset");
95
+ o([
96
+ h()
97
+ ], e.prototype, "$anchor");
98
+ o([
99
+ h()
100
+ ], e.prototype, "arrow");
101
+ o([
102
+ u("#popover")
103
+ ], e.prototype, "$popover");
104
+ o([
105
+ u("#arrow")
106
+ ], e.prototype, "$arrow");
107
+ o([
108
+ $("isOpen", { afterUpdate: !0 })
109
+ ], e.prototype, "handleToggleOpen");
110
+ o([
111
+ $("anchor")
112
+ ], e.prototype, "handleAnchorChange");
113
+ let X = e;
114
+ export {
115
+ X as SkfPopoverBase
116
+ };
@@ -0,0 +1 @@
1
+ export declare const styles: import("lit").CSSResult;
@@ -0,0 +1,29 @@
1
+ import { css as o } from "lit";
2
+ const e = o`
3
+ /* stylelint-disable selector-class-pattern */
4
+ @layer components {
5
+ .popover {
6
+ background-color: var(--skf-bg-color-neutral-1);
7
+ border: none;
8
+ border-radius: var(--skf-border-radius-sm);
9
+ box-shadow: var(--skf-shadow-md);
10
+ opacity: 0;
11
+ overflow: visible;
12
+ }
13
+
14
+ .popover__arrow {
15
+ --_skf-popover-arrow-size: calc(6px * 0.7071);
16
+
17
+ background-color: var(--skf-bg-color-neutral-1);
18
+ block-size: calc(var(--_skf-popover-arrow-size) * 2);
19
+ box-shadow: 1px 1px 2px 0 rgb(0 0 0 / 5%);
20
+ inline-size: calc(var(--_skf-popover-arrow-size) * 2);
21
+ position: absolute;
22
+ rotate: 45deg;
23
+ z-index: -1;
24
+ }
25
+ }
26
+ `;
27
+ export {
28
+ e as styles
29
+ };
@@ -0,0 +1,17 @@
1
+ import type { SkfDatePickerInput } from '../../components/date-picker-input/datepicker-input.component.js';
2
+ import { SkfSelect } from '../../components/select/select.component.js';
3
+ import type { SkfPopoverBase } from '../base-classes/popover/popover.base.js';
4
+ import type { ReactiveController } from 'lit';
5
+ type ControllerHost = SkfPopoverBase | SkfSelect | SkfDatePickerInput;
6
+ export declare class PopoverController implements ReactiveController {
7
+ host?: ControllerHost;
8
+ private cleanup;
9
+ private active;
10
+ private autoStart;
11
+ constructor(host: ControllerHost, autoStart?: boolean);
12
+ hostConnected(): void;
13
+ hostDisconnected(): void;
14
+ start(): void;
15
+ stop(): Promise<void>;
16
+ }
17
+ export {};
@@ -0,0 +1,44 @@
1
+ import "../../components/select/select.component.js";
2
+ import { autoUpdate as n } from "@floating-ui/dom";
3
+ class p {
4
+ constructor(t, o = !0) {
5
+ this.active = !1, this.autoStart = !0, this.host = t, t.addController(this), this.autoStart = o;
6
+ }
7
+ hostConnected() {
8
+ var t;
9
+ this.autoStart && ((t = this.host) == null || t.updateComplete.then(() => {
10
+ this.start();
11
+ }).catch((o) => {
12
+ console.error(o);
13
+ }));
14
+ }
15
+ hostDisconnected() {
16
+ this.stop().catch((t) => {
17
+ console.error(t);
18
+ });
19
+ }
20
+ start() {
21
+ var r, e;
22
+ const t = (r = this.host) == null ? void 0 : r.$anchor, o = (e = this.host) == null ? void 0 : e.$popover;
23
+ if (!t || !o) {
24
+ console.warn("PopoverController: anchor or popup not found");
25
+ return;
26
+ }
27
+ this.active || (this.cleanup = n(t, o, () => {
28
+ var s;
29
+ (s = this.host) == null || s.reposition().catch((i) => {
30
+ console.error(i);
31
+ });
32
+ }), this.active = !0);
33
+ }
34
+ async stop() {
35
+ return new Promise((t) => {
36
+ this.cleanup ? (this.cleanup(), this.cleanup = void 0, requestAnimationFrame(() => {
37
+ t();
38
+ })) : t(), this.active = !1;
39
+ });
40
+ }
41
+ }
42
+ export {
43
+ p as PopoverController
44
+ };
@@ -0,0 +1,2 @@
1
+ /** Formats a date to SKF standard format. Can be localized, defaults to GB English */
2
+ export declare function dateFormatter(date?: Date | null, locale?: string): string;
@@ -1,2 +1,2 @@
1
1
  import type { FormFieldBaseProps } from '../types/formField.js';
2
- export declare function hintSeverity(hostSeverity: FormFieldBaseProps['severity'], invalid: boolean): "error" | ("info" | "warning" | "success" | "alert") | undefined;
2
+ export declare function hintSeverity(hostSeverity: FormFieldBaseProps['severity'], invalid: boolean): "error" | ("success" | "info" | "warning" | "alert") | undefined;
@@ -0,0 +1,22 @@
1
+ export type Mutable<T> = {
2
+ -readonly [K in keyof T]: T[K];
3
+ };
4
+ type oneToNine = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9;
5
+ type zeroToNine = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9;
6
+ /**
7
+ * Years
8
+ */
9
+ type YYYY = `19${zeroToNine}${zeroToNine}` | `20${zeroToNine}${zeroToNine}`;
10
+ /**
11
+ * Months
12
+ */
13
+ type MM = `0${oneToNine}` | `1${0 | 1 | 2}`;
14
+ /**
15
+ * Days
16
+ */
17
+ type DD = `${0}${oneToNine}` | `${1 | 2}${zeroToNine}` | `3${0 | 1}`;
18
+ /**
19
+ * YYYY-MM-DD
20
+ */
21
+ export type ISODateString = `${YYYY}-${MM}-${DD}`;
22
+ export {};
@@ -1,22 +1,30 @@
1
1
  export { default as SkfAccordion } from './skf-accordion/index.js';
2
+ export { default as SkfAlert } from './skf-alert/index.js';
3
+ export { default as SkfBreadcrumb } from './skf-breadcrumb/index.js';
4
+ export { default as SkfBreadcrumbItem } from './skf-breadcrumb-item/index.js';
5
+ export { default as SkfButton } from './skf-button/index.js';
2
6
  export { default as SkfCard } from './skf-card/index.js';
3
7
  export { default as SkfCheckbox } from './skf-checkbox/index.js';
4
8
  export { default as SkfCollapse } from './skf-collapse/index.js';
9
+ export { default as SkfDatePicker } from './skf-datepicker/index.js';
5
10
  export { default as SkfDialog } from './skf-dialog/index.js';
6
- export { default as SkfAlert } from './skf-alert/index.js';
7
11
  export { default as SkfDivider } from './skf-divider/index.js';
8
- export { default as SkfButton } from './skf-button/index.js';
9
12
  export { default as SkfHeading } from './skf-heading/index.js';
10
13
  export { default as SkfIcon } from './skf-icon/index.js';
11
14
  export { default as SkfInput } from './skf-input/index.js';
12
15
  export { default as SkfLink } from './skf-link/index.js';
13
16
  export { default as SkfLoader } from './skf-loader/index.js';
14
17
  export { default as SkfLogo } from './skf-logo/index.js';
18
+ export { default as SkfMenu } from './skf-menu/index.js';
19
+ export { default as SkfMenuItem } from './skf-menu-item/index.js';
20
+ export { default as SkfPopover } from './skf-popover/index.js';
15
21
  export { default as SkfProgress } from './skf-progress/index.js';
16
22
  export { default as SkfRadio } from './skf-radio/index.js';
17
23
  export { default as SkfSelect } from './skf-select/index.js';
18
24
  export { default as SkfSelectOption } from './skf-select-option/index.js';
19
25
  export { default as SkfSelectOptionGroup } from './skf-select-option-group/index.js';
26
+ export { default as SkfStepper } from './skf-stepper/index.js';
27
+ export { default as SkfStepperItem } from './skf-stepper-item/index.js';
20
28
  export { default as SkfSwitch } from './skf-switch/index.js';
21
29
  export { default as SkfTab } from './skf-tab/index.js';
22
30
  export { default as SkfTabGroup } from './skf-tab-group/index.js';
@@ -25,3 +33,4 @@ export { default as SkfTag } from './skf-tag/index.js';
25
33
  export { default as SkfTextArea } from './skf-textarea/index.js';
26
34
  export { default as SkfToast } from './skf-toast/index.js';
27
35
  export { default as SkfToastWrapper } from './skf-toast-wrapper/index.js';
36
+ export { default as SkfTooltip } from './skf-tooltip/index.js';
@@ -1,22 +1,30 @@
1
1
  export { default as SkfAccordion } from './skf-accordion/index.js';
2
+ export { default as SkfAlert } from './skf-alert/index.js';
3
+ export { default as SkfBreadcrumb } from './skf-breadcrumb/index.js';
4
+ export { default as SkfBreadcrumbItem } from './skf-breadcrumb-item/index.js';
5
+ export { default as SkfButton } from './skf-button/index.js';
2
6
  export { default as SkfCard } from './skf-card/index.js';
3
7
  export { default as SkfCheckbox } from './skf-checkbox/index.js';
4
8
  export { default as SkfCollapse } from './skf-collapse/index.js';
9
+ export { default as SkfDatePicker } from './skf-datepicker/index.js';
5
10
  export { default as SkfDialog } from './skf-dialog/index.js';
6
- export { default as SkfAlert } from './skf-alert/index.js';
7
11
  export { default as SkfDivider } from './skf-divider/index.js';
8
- export { default as SkfButton } from './skf-button/index.js';
9
12
  export { default as SkfHeading } from './skf-heading/index.js';
10
13
  export { default as SkfIcon } from './skf-icon/index.js';
11
14
  export { default as SkfInput } from './skf-input/index.js';
12
15
  export { default as SkfLink } from './skf-link/index.js';
13
16
  export { default as SkfLoader } from './skf-loader/index.js';
14
17
  export { default as SkfLogo } from './skf-logo/index.js';
18
+ export { default as SkfMenu } from './skf-menu/index.js';
19
+ export { default as SkfMenuItem } from './skf-menu-item/index.js';
20
+ export { default as SkfPopover } from './skf-popover/index.js';
15
21
  export { default as SkfProgress } from './skf-progress/index.js';
16
22
  export { default as SkfRadio } from './skf-radio/index.js';
17
23
  export { default as SkfSelect } from './skf-select/index.js';
18
24
  export { default as SkfSelectOption } from './skf-select-option/index.js';
19
25
  export { default as SkfSelectOptionGroup } from './skf-select-option-group/index.js';
26
+ export { default as SkfStepper } from './skf-stepper/index.js';
27
+ export { default as SkfStepperItem } from './skf-stepper-item/index.js';
20
28
  export { default as SkfSwitch } from './skf-switch/index.js';
21
29
  export { default as SkfTab } from './skf-tab/index.js';
22
30
  export { default as SkfTabGroup } from './skf-tab-group/index.js';
@@ -25,3 +33,4 @@ export { default as SkfTag } from './skf-tag/index.js';
25
33
  export { default as SkfTextArea } from './skf-textarea/index.js';
26
34
  export { default as SkfToast } from './skf-toast/index.js';
27
35
  export { default as SkfToastWrapper } from './skf-toast-wrapper/index.js';
36
+ export { default as SkfTooltip } from './skf-tooltip/index.js';
@@ -0,0 +1,9 @@
1
+ import Component from '../../components/breadcrumb/breadcrumb.js';
2
+ import { type SkfBreadcrumb } from '../../components/breadcrumb/breadcrumb.js';
3
+ import { type EventName } from '@lit/react';
4
+ declare const reactWrapper: import("@lit/react").ReactWebComponent<Component, {
5
+ onClick: EventName<Event & {
6
+ target: SkfBreadcrumb;
7
+ }>;
8
+ }>;
9
+ export default reactWrapper;
@@ -0,0 +1,17 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import Component from '../../components/breadcrumb/breadcrumb.js';
4
+ import {} from '../../components/breadcrumb/breadcrumb.js';
5
+ import {} from '@lit/react';
6
+ const tagName = 'skf-breadcrumb';
7
+ Component.define('skf-breadcrumb');
8
+ const reactWrapper = createComponent({
9
+ tagName,
10
+ elementClass: Component,
11
+ react: React,
12
+ events: {
13
+ onClick: 'click',
14
+ },
15
+ displayName: 'SkfBreadcrumb',
16
+ });
17
+ export default reactWrapper;
@@ -0,0 +1,3 @@
1
+ import Component from '../../components/breadcrumb-item/breadcrumb-item.js';
2
+ declare const reactWrapper: import("@lit/react").ReactWebComponent<Component, {}>;
3
+ export default reactWrapper;
@@ -0,0 +1,13 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import Component from '../../components/breadcrumb-item/breadcrumb-item.js';
4
+ const tagName = 'skf-breadcrumb-item';
5
+ Component.define('skf-breadcrumb-item');
6
+ const reactWrapper = createComponent({
7
+ tagName,
8
+ elementClass: Component,
9
+ react: React,
10
+ events: {},
11
+ displayName: 'SkfBreadcrumbItem',
12
+ });
13
+ export default reactWrapper;
@@ -0,0 +1,12 @@
1
+ import Component from '../../components/date-picker/datepicker.js';
2
+ import { type SkfDatePicker } from '../../components/date-picker/datepicker.js';
3
+ import { type EventName } from '@lit/react';
4
+ declare const reactWrapper: import("@lit/react").ReactWebComponent<Component, {
5
+ onSelectedDateChanged: EventName<Event & {
6
+ target: SkfDatePicker;
7
+ }>;
8
+ onSelectedDateRangeChanged: EventName<Event & {
9
+ target: SkfDatePicker;
10
+ }>;
11
+ }>;
12
+ export default reactWrapper;
@@ -0,0 +1,18 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import Component from '../../components/date-picker/datepicker.js';
4
+ import {} from '../../components/date-picker/datepicker.js';
5
+ import {} from '@lit/react';
6
+ const tagName = 'skf-datepicker';
7
+ Component.define('skf-datepicker');
8
+ const reactWrapper = createComponent({
9
+ tagName,
10
+ elementClass: Component,
11
+ react: React,
12
+ events: {
13
+ onSelectedDateChanged: 'selected-date-changed',
14
+ onSelectedDateRangeChanged: 'selected-date-range-changed',
15
+ },
16
+ displayName: 'SkfDatePicker',
17
+ });
18
+ export default reactWrapper;
@@ -0,0 +1,12 @@
1
+ import Component from '../../components/menu/menu.js';
2
+ import { type SkfMenu } from '../../components/menu/menu.js';
3
+ import { type EventName } from '@lit/react';
4
+ declare const reactWrapper: import("@lit/react").ReactWebComponent<Component, {
5
+ onOpen: EventName<Event & {
6
+ target: SkfMenu;
7
+ }>;
8
+ onClose: EventName<Event & {
9
+ target: SkfMenu;
10
+ }>;
11
+ }>;
12
+ export default reactWrapper;