@festo-ui/react 9.0.1 → 10.0.0-dev.827

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 (150) hide show
  1. package/dist/components/accordion/Accordion.d.ts +3 -3
  2. package/dist/components/accordion/Accordion.js +2 -1
  3. package/dist/components/accordion/accordion-header/AccordionHeader.js +1 -0
  4. package/dist/components/accordion/accordion-item/AccordionItem.d.ts +1 -1
  5. package/dist/components/accordion/accordion-item/AccordionItem.js +2 -1
  6. package/dist/components/accordion/accordion-item/accordion-item-body/AccordionItemBody.js +1 -0
  7. package/dist/components/accordion/accordion-item/accordion-item-header/AccordionItemHeader.js +1 -0
  8. package/dist/components/bottom-sheet/BottomSheet.d.ts +2 -3
  9. package/dist/components/bottom-sheet/BottomSheet.js +7 -4
  10. package/dist/components/breadcrumb/Breadcrumb.d.ts +9 -9
  11. package/dist/components/breadcrumb/Breadcrumb.js +86 -26
  12. package/dist/components/button/Button.js +1 -0
  13. package/dist/components/card/Card.d.ts +3 -4
  14. package/dist/components/card/Card.js +6 -4
  15. package/dist/components/card/CardBody.d.ts +3 -3
  16. package/dist/components/card/CardBody.js +6 -4
  17. package/dist/components/card/CardHeader.d.ts +3 -3
  18. package/dist/components/card/CardHeader.js +6 -4
  19. package/dist/components/card/CardNotification.d.ts +2 -3
  20. package/dist/components/card/CardNotification.js +6 -2
  21. package/dist/components/chips/chip/Chip.d.ts +4 -5
  22. package/dist/components/chips/chip/Chip.js +11 -4
  23. package/dist/components/chips/chip-container/ChipContainer.d.ts +3 -3
  24. package/dist/components/chips/chip-container/ChipContainer.js +6 -2
  25. package/dist/components/icon-wrapper/IconWrapper.d.ts +2 -1
  26. package/dist/components/loading-indicator/LoadingIndicator.d.ts +2 -2
  27. package/dist/components/loading-indicator/LoadingIndicator.js +1 -0
  28. package/dist/components/mobile-flyout/MobileFlyout.js +1 -0
  29. package/dist/components/mobile-flyout/mobile-flyout-item/MobileFlyoutItem.d.ts +1 -0
  30. package/dist/components/mobile-flyout/mobile-flyout-item/MobileFlyoutItem.js +3 -2
  31. package/dist/components/mobile-flyout/mobile-flyout-page/MobileFlyoutPage.js +4 -3
  32. package/dist/components/modals/AlertModal.d.ts +1 -1
  33. package/dist/components/modals/AlertModal.js +5 -4
  34. package/dist/components/modals/ConfirmModal.d.ts +1 -1
  35. package/dist/components/modals/ConfirmModal.js +5 -4
  36. package/dist/components/modals/CustomModal.js +1 -0
  37. package/dist/components/modals/Modal.js +1 -0
  38. package/dist/components/modals/ModalBase.js +1 -0
  39. package/dist/components/modals/ModalFooter.d.ts +2 -2
  40. package/dist/components/modals/ModalFooter.js +3 -1
  41. package/dist/components/modals/Prompt.d.ts +3 -3
  42. package/dist/components/modals/Prompt.js +9 -6
  43. package/dist/components/modals/image-gallery/ImageGallery.css +24 -6
  44. package/dist/components/modals/image-gallery/ImageGallery.d.ts +1 -1
  45. package/dist/components/modals/image-gallery/ImageGallery.js +1 -0
  46. package/dist/components/modals/image-gallery/ImageGallerySwiper.js +1 -1
  47. package/dist/components/modals/image-gallery/internal/ImageGalleryContainer.d.ts +1 -1
  48. package/dist/components/pagination/Pagination.d.ts +3 -4
  49. package/dist/components/pagination/Pagination.js +17 -13
  50. package/dist/components/popovers/legend/Legend.d.ts +6 -4
  51. package/dist/components/popovers/legend/Legend.js +8 -4
  52. package/dist/components/popovers/popover/Popover.css +5 -52
  53. package/dist/components/popovers/popover/Popover.d.ts +12 -14
  54. package/dist/components/popovers/popover/Popover.js +81 -91
  55. package/dist/components/popovers/popover-menu/PopoverMenu.d.ts +6 -4
  56. package/dist/components/popovers/popover-menu/PopoverMenu.js +23 -27
  57. package/dist/components/popovers/popover-menu/PopoverMenuContext.d.ts +2 -1
  58. package/dist/components/popovers/popover-menu/PopoverMenuContext.js +1 -1
  59. package/dist/components/popovers/popover-menu/popover-menu-item/PopoverMenuItem.d.ts +9 -0
  60. package/dist/components/popovers/popover-menu/popover-menu-item/PopoverMenuItem.js +31 -0
  61. package/dist/components/popovers/tooltip/Tooltip.d.ts +4 -3
  62. package/dist/components/popovers/tooltip/Tooltip.js +7 -6
  63. package/dist/components/progress/Progress.d.ts +2 -3
  64. package/dist/components/progress/Progress.js +6 -2
  65. package/dist/components/search-input/ClearButton.d.ts +1 -2
  66. package/dist/components/search-input/ClearButton.js +5 -4
  67. package/dist/components/search-input/SearchInput.d.ts +3 -4
  68. package/dist/components/search-input/SearchInput.js +9 -5
  69. package/dist/components/snackbar/Snackbar.d.ts +4 -4
  70. package/dist/components/snackbar/Snackbar.js +11 -7
  71. package/dist/components/snackbar/SnackbarProvider.d.ts +3 -3
  72. package/dist/components/snackbar/SnackbarProvider.js +7 -4
  73. package/dist/components/stepper-horizontal/StepperHorizontal.d.ts +2 -2
  74. package/dist/components/stepper-horizontal/StepperHorizontal.js +4 -3
  75. package/dist/components/stepper-horizontal/step-horizontal/StepHorizontal.js +2 -1
  76. package/dist/components/stepper-vertical/StepperVertical.js +1 -1
  77. package/dist/components/stepper-vertical/step-vertical/StepVertical.js +1 -0
  78. package/dist/components/tab/Tabs.js +3 -3
  79. package/dist/components/tab/tab-pane/TabPane.d.ts +3 -4
  80. package/dist/components/tab/tab-pane/TabPane.js +6 -2
  81. package/dist/components/table-header-cell/TableHeaderCell.d.ts +2 -1
  82. package/dist/components/table-header-cell/TableHeaderCell.js +1 -0
  83. package/dist/forms/checkbox/Checkbox.d.ts +3 -6
  84. package/dist/forms/checkbox/Checkbox.js +5 -2
  85. package/dist/forms/combobox/ComboBox.css +124 -0
  86. package/dist/forms/combobox/ComboBox.d.ts +27 -0
  87. package/dist/forms/combobox/ComboBox.js +174 -0
  88. package/dist/forms/multi-select/MultiSelect.css +13 -0
  89. package/dist/forms/multi-select/MultiSelect.d.ts +20 -0
  90. package/dist/forms/multi-select/MultiSelect.js +192 -0
  91. package/dist/forms/radio/RadioButton.d.ts +4 -4
  92. package/dist/forms/radio/RadioButton.js +11 -10
  93. package/dist/forms/radio/RadioGroup.d.ts +4 -4
  94. package/dist/forms/radio/RadioGroup.js +1 -0
  95. package/dist/forms/segment/Segment.d.ts +4 -5
  96. package/dist/forms/segment/Segment.js +10 -9
  97. package/dist/forms/segment/segment-control/SegmentControl.d.ts +4 -8
  98. package/dist/forms/segment/segment-control/SegmentControl.js +8 -6
  99. package/dist/forms/select/Select.d.ts +16 -17
  100. package/dist/forms/select/Select.js +80 -82
  101. package/dist/forms/select/internal/SelectButton.d.ts +0 -12
  102. package/dist/forms/select/internal/SelectButton.js +0 -49
  103. package/dist/forms/select/internal/SelectButtonContent.d.ts +0 -7
  104. package/dist/forms/select/internal/SelectButtonContent.js +0 -31
  105. package/dist/forms/select/internal/SelectOptionsContainer.d.ts +0 -17
  106. package/dist/forms/select/internal/SelectOptionsContainer.js +0 -103
  107. package/dist/forms/slider/Slider.d.ts +4 -7
  108. package/dist/forms/slider/Slider.js +11 -6
  109. package/dist/forms/switch/Switch.d.ts +4 -6
  110. package/dist/forms/switch/Switch.js +12 -6
  111. package/dist/forms/text-area/TextArea.d.ts +6 -15
  112. package/dist/forms/text-area/TextArea.js +42 -25
  113. package/dist/forms/text-input/TextInput.css +31 -0
  114. package/dist/forms/text-input/TextInput.d.ts +6 -17
  115. package/dist/forms/text-input/TextInput.js +16 -25
  116. package/dist/forms/time-picker/TimePicker.d.ts +7 -6
  117. package/dist/forms/time-picker/TimePicker.js +16 -31
  118. package/dist/forms/time-picker/time-picker-dropdown/TimePickerDropdown.js +1 -0
  119. package/dist/forms/time-picker/time-picker-dropdown/TimePickerInput.js +1 -0
  120. package/dist/index.d.ts +7 -5
  121. package/dist/index.js +4 -3
  122. package/dist/utils/types.d.ts +0 -6
  123. package/dist/utils/useControlled.js +4 -4
  124. package/dist/utils/useForkRef.d.ts +2 -2
  125. package/dist/utils/useForkRef.js +2 -2
  126. package/dist/utils/useOnClickOutside.d.ts +1 -1
  127. package/package.json +17 -28
  128. package/dist/components/popovers/popover-menu-item/PopoverMenuItem.d.ts +0 -9
  129. package/dist/components/popovers/popover-menu-item/PopoverMenuItem.js +0 -29
  130. package/dist/forms/select/Select.css +0 -160
  131. package/dist/forms/select/internal/HiddenInput.d.ts +0 -8
  132. package/dist/forms/select/internal/HiddenInput.js +0 -15
  133. package/dist/forms/select/internal/ListItem.d.ts +0 -18
  134. package/dist/forms/select/internal/ListItem.js +0 -69
  135. package/dist/forms/select/internal/SelectCheckbox.d.ts +0 -4
  136. package/dist/forms/select/internal/SelectCheckbox.js +0 -13
  137. package/dist/forms/select/internal/SelectLabel.d.ts +0 -7
  138. package/dist/forms/select/internal/SelectLabel.js +0 -12
  139. package/dist/forms/select/internal/SelectScrollContainer.d.ts +0 -8
  140. package/dist/forms/select/internal/SelectScrollContainer.js +0 -15
  141. package/dist/forms/select/internal/SelectWrapper.d.ts +0 -6
  142. package/dist/forms/select/internal/SelectWrapper.js +0 -12
  143. package/dist/forms/select/internal/index.d.ts +0 -6
  144. package/dist/forms/select/internal/index.js +0 -7
  145. package/dist/forms/select/internal/utils.d.ts +0 -7
  146. package/dist/forms/select/internal/utils.js +0 -30
  147. package/dist/forms/select/select-option/SelectOption.d.ts +0 -14
  148. package/dist/forms/select/select-option/SelectOption.js +0 -12
  149. package/dist/forms/select/utils.d.ts +0 -2
  150. package/dist/forms/select/utils.js +0 -12
@@ -1,9 +1,9 @@
1
1
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
2
2
  import classnames from "classnames";
3
+ import { forwardRef } from "react";
3
4
  import { Modal } from "./Modal.js";
4
5
  import { ModalFooter } from "./ModalFooter.js";
5
- function AlertModal({ title, subtitle, alertType, strong, cancel, ok, onCancel, onOk, className, body, ...props }) {
6
- return /*#__PURE__*/ jsx(Modal, {
6
+ const AlertModal = /*#__PURE__*/ forwardRef(({ title, subtitle, alertType, strong, cancel, ok, onCancel, onOk, className, body, ...props }, ref)=>/*#__PURE__*/ jsx(Modal, {
7
7
  className: classnames({
8
8
  'fwe-modal--with-indicator-bar': strong,
9
9
  'fwe-modal--warning': 'warning' === alertType,
@@ -25,6 +25,7 @@ function AlertModal({ title, subtitle, alertType, strong, cancel, ok, onCancel,
25
25
  body: 'string' == typeof body ? /*#__PURE__*/ jsx("p", {
26
26
  children: body
27
27
  }) : body,
28
+ ref: ref,
28
29
  ...props,
29
30
  children: (cancel || ok) && /*#__PURE__*/ jsxs(ModalFooter, {
30
31
  children: [
@@ -48,6 +49,6 @@ function AlertModal({ title, subtitle, alertType, strong, cancel, ok, onCancel,
48
49
  })
49
50
  ]
50
51
  })
51
- });
52
- }
52
+ }));
53
+ AlertModal.displayName = 'AlertModal';
53
54
  export { AlertModal };
@@ -8,4 +8,4 @@ export interface ConfirmModalProps extends Omit<ModalProps, 'head' | 'children'>
8
8
  readonly onOk?: () => void;
9
9
  readonly large?: boolean;
10
10
  }
11
- export declare function ConfirmModal({ title, subtitle, cancel, ok, onCancel, onOk, large, body, className, ...props }: ConfirmModalProps): import("react/jsx-runtime").JSX.Element;
11
+ export declare const ConfirmModal: (props: ConfirmModalProps & import("react").RefAttributes<HTMLDivElement>) => React.ReactElement | null;
@@ -1,9 +1,9 @@
1
1
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
2
2
  import classnames from "classnames";
3
+ import { forwardRef } from "react";
3
4
  import { Modal } from "./Modal.js";
4
5
  import { ModalFooter } from "./ModalFooter.js";
5
- function ConfirmModal({ title, subtitle, cancel, ok, onCancel, onOk, large, body, className, ...props }) {
6
- return /*#__PURE__*/ jsx(Modal, {
6
+ const ConfirmModal = /*#__PURE__*/ forwardRef(({ title, subtitle, cancel, ok, onCancel, onOk, large, body, className, ...props }, ref)=>/*#__PURE__*/ jsx(Modal, {
7
7
  className: classnames({
8
8
  'fwe-modal--large': large
9
9
  }, className),
@@ -22,6 +22,7 @@ function ConfirmModal({ title, subtitle, cancel, ok, onCancel, onOk, large, body
22
22
  body: 'string' == typeof body ? /*#__PURE__*/ jsx("p", {
23
23
  children: body
24
24
  }) : body,
25
+ ref: ref,
25
26
  ...props,
26
27
  children: (cancel || ok) && /*#__PURE__*/ jsxs(ModalFooter, {
27
28
  children: [
@@ -41,6 +42,6 @@ function ConfirmModal({ title, subtitle, cancel, ok, onCancel, onOk, large, body
41
42
  })
42
43
  ]
43
44
  })
44
- });
45
- }
45
+ }));
46
+ ConfirmModal.displayName = 'ConfirmModal';
46
47
  export { ConfirmModal };
@@ -35,4 +35,5 @@ const CustomModal = /*#__PURE__*/ forwardRef(({ large, title, subtitle, classNam
35
35
  children
36
36
  ]
37
37
  }));
38
+ CustomModal.displayName = 'CustomModal';
38
39
  export { CustomModal };
@@ -28,4 +28,5 @@ const Modal = /*#__PURE__*/ forwardRef(({ head, body, className, children, ...pr
28
28
  children
29
29
  ]
30
30
  }));
31
+ Modal.displayName = 'Modal';
31
32
  export { Modal };
@@ -121,4 +121,5 @@ const ModalBase = /*#__PURE__*/ forwardRef(({ isOpen, isLoading, onClose, onClos
121
121
  }), container.body)
122
122
  });
123
123
  });
124
+ ModalBase.displayName = 'ModalBase';
124
125
  export { ModalBase };
@@ -1,2 +1,2 @@
1
- import type { ClassNamePropsWithChildren } from '../../utils/types';
2
- export declare const ModalFooter: (props: ClassNamePropsWithChildren & import("react").RefAttributes<HTMLDivElement>) => React.ReactElement | null;
1
+ import type React from 'react';
2
+ export declare const ModalFooter: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>) => React.ReactElement | null;
@@ -1,12 +1,14 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import classnames from "classnames";
3
3
  import { forwardRef } from "react";
4
- const ModalFooter = /*#__PURE__*/ forwardRef(({ children, className }, ref)=>/*#__PURE__*/ jsx("div", {
4
+ const ModalFooter = /*#__PURE__*/ forwardRef(({ children, className, ...props }, ref)=>/*#__PURE__*/ jsx("div", {
5
5
  ref: ref,
6
6
  className: classnames('fwe-modal-footer', className),
7
+ ...props,
7
8
  children: /*#__PURE__*/ jsx("div", {
8
9
  className: classnames('fwe-modal-buttons'),
9
10
  children: children
10
11
  })
11
12
  }));
13
+ ModalFooter.displayName = 'ModalFooter';
12
14
  export { ModalFooter };
@@ -1,15 +1,15 @@
1
1
  import type React from 'react';
2
2
  import { type ModalProps } from './Modal';
3
- export interface PromptProps extends Omit<ModalProps, 'head' | 'body' | 'children'> {
3
+ export interface PromptProps extends Omit<ModalProps, 'head' | 'body' | 'children' | 'onChange'> {
4
4
  readonly title: string;
5
5
  readonly subtitle?: string;
6
6
  readonly hint?: string;
7
7
  readonly label?: string;
8
8
  readonly value?: string;
9
- readonly onChange: (event: React.FormEvent<HTMLInputElement>) => void;
9
+ readonly onChange?: (value: string, event: React.ChangeEvent<HTMLInputElement>) => void;
10
10
  readonly cancel?: string;
11
11
  readonly ok?: string;
12
12
  readonly onCancel?: () => void;
13
13
  readonly onOk: (value: string | undefined) => void;
14
14
  }
15
- export declare function Prompt({ title, subtitle, hint, label, value, onChange, onOk, onCancel, cancel, ok, ...props }: PromptProps): JSX.Element;
15
+ export declare const Prompt: (props: PromptProps & React.RefAttributes<HTMLDivElement>) => React.ReactElement | null;
@@ -1,20 +1,21 @@
1
1
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
2
- import { useEffect, useState } from "react";
2
+ import { forwardRef, useEffect, useState } from "react";
3
3
  import { TextInput } from "../../forms/text-input/TextInput.js";
4
4
  import { Modal } from "./Modal.js";
5
5
  import { ModalFooter } from "./ModalFooter.js";
6
- function Prompt({ title, subtitle, hint, label, value, onChange, onOk, onCancel, cancel, ok, ...props }) {
6
+ const Prompt = /*#__PURE__*/ forwardRef(({ title, subtitle, hint, label, value, onChange, onOk, onCancel, cancel, ok, className, ...props }, ref)=>{
7
7
  const [innerValue, setInnerValue] = useState(value);
8
8
  useEffect(()=>{
9
9
  setInnerValue(value);
10
10
  }, [
11
11
  value
12
12
  ]);
13
- function handleChange(e) {
14
- setInnerValue(e.target.value);
15
- if (onChange) onChange(e);
13
+ function handleChange(newValue, e) {
14
+ setInnerValue(newValue);
15
+ if (onChange) onChange(newValue, e);
16
16
  }
17
17
  return /*#__PURE__*/ jsx(Modal, {
18
+ className: className,
18
19
  head: /*#__PURE__*/ jsxs(Fragment, {
19
20
  children: [
20
21
  subtitle && /*#__PURE__*/ jsx("h2", {
@@ -34,6 +35,7 @@ function Prompt({ title, subtitle, hint, label, value, onChange, onOk, onCancel,
34
35
  value: innerValue,
35
36
  autoFocus: true
36
37
  }),
38
+ ref: ref,
37
39
  ...props,
38
40
  children: (cancel || ok) && /*#__PURE__*/ jsxs(ModalFooter, {
39
41
  children: [
@@ -54,5 +56,6 @@ function Prompt({ title, subtitle, hint, label, value, onChange, onOk, onCancel,
54
56
  ]
55
57
  })
56
58
  });
57
- }
59
+ });
60
+ Prompt.displayName = 'Prompt';
58
61
  export { Prompt };
@@ -110,12 +110,30 @@
110
110
  & > .swiper-wrapper {
111
111
  scroll-snap-type: x mandatory;
112
112
  }
113
+
114
+ & > .swiper-wrapper > .swiper-slide:first-child {
115
+ margin-inline-start: var(--swiper-slides-offset-before);
116
+ scroll-margin-inline-start: var(--swiper-slides-offset-before);
117
+ }
118
+
119
+ & > .swiper-wrapper > .swiper-slide:last-child {
120
+ margin-inline-end: var(--swiper-slides-offset-after);
121
+ }
113
122
  }
114
123
 
115
124
  &.swiper-vertical {
116
125
  & > .swiper-wrapper {
117
126
  scroll-snap-type: y mandatory;
118
127
  }
128
+
129
+ & > .swiper-wrapper > .swiper-slide:first-child {
130
+ margin-block-start: var(--swiper-slides-offset-before);
131
+ scroll-margin-block-start: var(--swiper-slides-offset-before);
132
+ }
133
+
134
+ & > .swiper-wrapper > .swiper-slide:last-child {
135
+ margin-block-end: var(--swiper-slides-offset-after);
136
+ }
119
137
  }
120
138
 
121
139
  &.swiper-free-mode {
@@ -298,7 +316,7 @@
298
316
  display: none !important;
299
317
  }
300
318
 
301
- & svg {
319
+ & ::slotted(svg), & svg {
302
320
  object-fit: contain;
303
321
  transform-origin: center;
304
322
  fill: currentColor;
@@ -321,7 +339,7 @@
321
339
  left: var(--swiper-navigation-sides-offset, 4px);
322
340
  right: auto;
323
341
 
324
- & .swiper-navigation-icon {
342
+ & ::slotted(.swiper-navigation-icon), & .swiper-navigation-icon {
325
343
  transform: rotate(180deg);
326
344
  }
327
345
  }
@@ -349,13 +367,13 @@
349
367
  }
350
368
 
351
369
  & .swiper-button-prev, & ~ .swiper-button-prev, &.swiper-rtl .swiper-button-next, &.swiper-rtl ~ .swiper-button-next {
352
- & .swiper-navigation-icon {
370
+ & ::slotted(.swiper-navigation-icon), & .swiper-navigation-icon {
353
371
  transform: rotate(180deg);
354
372
  }
355
373
  }
356
374
 
357
375
  &.swiper-rtl .swiper-button-prev, &.swiper-rtl ~ .swiper-button-prev {
358
- & .swiper-navigation-icon {
376
+ & ::slotted(.swiper-navigation-icon), & .swiper-navigation-icon {
359
377
  transform: rotate(0);
360
378
  }
361
379
  }
@@ -373,7 +391,7 @@
373
391
  top: var(--swiper-navigation-sides-offset, 4px);
374
392
  bottom: auto;
375
393
 
376
- & .swiper-navigation-icon {
394
+ & ::slotted(.swiper-navigation-icon), & .swiper-navigation-icon {
377
395
  transform: rotate(-90deg);
378
396
  }
379
397
  }
@@ -382,7 +400,7 @@
382
400
  bottom: var(--swiper-navigation-sides-offset, 4px);
383
401
  top: auto;
384
402
 
385
- & .swiper-navigation-icon {
403
+ & ::slotted(.swiper-navigation-icon), & .swiper-navigation-icon {
386
404
  transform: rotate(90deg);
387
405
  }
388
406
  }
@@ -18,4 +18,4 @@ export interface ImageGalleryProps extends ComponentPropsWithoutRef<'div'>, Moda
18
18
  descriptiveContent?: boolean | ((index: number) => React.ReactNode);
19
19
  onSlideChanged?: (index: number) => void;
20
20
  }
21
- export declare const ImageGallery: (props: ImageGalleryProps & import("react").RefAttributes<HTMLImageElement>) => React.ReactElement | null;
21
+ export declare const ImageGallery: (props: ImageGalleryProps & import("react").RefAttributes<HTMLDivElement>) => React.ReactElement | null;
@@ -100,4 +100,5 @@ const ImageGallery = /*#__PURE__*/ forwardRef(({ isOpen, startIndex, images, thu
100
100
  ]
101
101
  });
102
102
  });
103
+ ImageGallery.displayName = 'ImageGallery';
103
104
  export { ImageGallery };
@@ -36,5 +36,5 @@ function ImageGallerySwiper({ images, onSlideChanged, thumbsSwiper, startIndex }
36
36
  }, image.src))
37
37
  });
38
38
  }
39
- ImageGallerySwiper.displayName = 'Swiper';
39
+ ImageGallerySwiper.displayName = 'ImageGallerySwiper';
40
40
  export { ImageGallerySwiper };
@@ -2,4 +2,4 @@ export interface ImageGalleryContainerProps {
2
2
  children: React.ReactNode;
3
3
  descriptiveContent?: boolean;
4
4
  }
5
- export declare function ImageGalleryContainer({ children, descriptiveContent, }: ImageGalleryContainerProps): string | number | boolean | Iterable<import("react").ReactNode> | import("react/jsx-runtime").JSX.Element | null | undefined;
5
+ export declare function ImageGalleryContainer({ children, descriptiveContent, }: ImageGalleryContainerProps): string | number | bigint | boolean | Iterable<import("react").ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
@@ -1,15 +1,14 @@
1
1
  import './Pagination.scss';
2
- import type { ClassNameProps } from '../../utils/types';
3
2
  export declare enum PaginationType {
4
3
  Simple = "SIMPLE",
5
4
  Numeric = "NUMERIC",
6
5
  Dots = "DOTS"
7
6
  }
8
- export interface PaginationProps extends ClassNameProps {
7
+ export interface PaginationProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'onChange'> {
9
8
  readonly type?: PaginationType;
10
- readonly onChange?: (page: number) => void;
9
+ readonly onChange?: (page: number, event: React.MouseEvent<HTMLButtonElement>) => void;
11
10
  readonly pageCurrent?: number;
12
11
  readonly defaultPageCurrent?: number;
13
12
  readonly pageMax: number;
14
13
  }
15
- export declare function Pagination(props: PaginationProps): import("react/jsx-runtime").JSX.Element;
14
+ export declare const Pagination: (props: PaginationProps & import("react").RefAttributes<HTMLDivElement>) => React.ReactElement | null;
@@ -1,15 +1,14 @@
1
1
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
2
2
  import "./Pagination.css";
3
3
  import classnames from "classnames";
4
- import { useEffect, useState } from "react";
4
+ import { forwardRef, useEffect, useState } from "react";
5
5
  var Pagination_PaginationType = /*#__PURE__*/ function(PaginationType) {
6
6
  PaginationType["Simple"] = "SIMPLE";
7
7
  PaginationType["Numeric"] = "NUMERIC";
8
8
  PaginationType["Dots"] = "DOTS";
9
9
  return PaginationType;
10
10
  }({});
11
- function Pagination(props) {
12
- const { pageMax, onChange, pageCurrent, defaultPageCurrent = 1, type = "NUMERIC", className } = props;
11
+ const Pagination = /*#__PURE__*/ forwardRef(({ pageMax, onChange, pageCurrent, defaultPageCurrent = 1, type = "NUMERIC", className, ...props }, ref)=>{
13
12
  const controlled = void 0 !== pageCurrent;
14
13
  const dotArray = Array.from(new Array(pageMax).keys());
15
14
  const [innerPageCurrent, setInnerPageCurrent] = useState(controlled ? pageCurrent : defaultPageCurrent);
@@ -19,32 +18,34 @@ function Pagination(props) {
19
18
  pageCurrent,
20
19
  controlled
21
20
  ]);
22
- function handleChange(newPage) {
21
+ function handleChange(newPage, event) {
23
22
  if (!controlled) setInnerPageCurrent(newPage);
24
- if (onChange) onChange(newPage);
23
+ if (onChange) onChange(newPage, event);
25
24
  }
26
- function onBtnDown() {
25
+ function onBtnDown(event) {
27
26
  if (innerPageCurrent > 1) {
28
27
  const newPageCurrent = innerPageCurrent - 1;
29
- handleChange(newPageCurrent);
28
+ handleChange(newPageCurrent, event);
30
29
  }
31
30
  }
32
- function onBtnUp() {
31
+ function onBtnUp(event) {
33
32
  if (innerPageCurrent < pageMax) {
34
33
  const newPageCurrent = innerPageCurrent + 1;
35
- handleChange(newPageCurrent);
34
+ handleChange(newPageCurrent, event);
36
35
  }
37
36
  }
38
- function onDotClick(index) {
37
+ function onDotClick(index, event) {
39
38
  const newPageCurrent = index + 1;
40
- handleChange(newPageCurrent);
39
+ handleChange(newPageCurrent, event);
41
40
  }
42
41
  return /*#__PURE__*/ jsxs(Fragment, {
43
42
  children: [
44
43
  "DOTS" !== type && /*#__PURE__*/ jsxs("div", {
44
+ ...props,
45
45
  className: classnames('fwe-pagination', {
46
46
  'fwe-d-none': pageMax < 2
47
47
  }, className),
48
+ ref: ref,
48
49
  children: [
49
50
  /*#__PURE__*/ jsx("button", {
50
51
  className: classnames('fwe-navigate-btn-down', {
@@ -78,9 +79,11 @@ function Pagination(props) {
78
79
  ]
79
80
  }),
80
81
  "DOTS" === type && /*#__PURE__*/ jsx("div", {
82
+ ...props,
81
83
  className: classnames({
82
84
  'fwe-d-none': pageMax < 2
83
85
  }, className),
86
+ ref: ref,
84
87
  children: /*#__PURE__*/ jsx("div", {
85
88
  className: "fwe-pagination",
86
89
  children: dotArray.map((index)=>/*#__PURE__*/ jsx("button", {
@@ -88,7 +91,7 @@ function Pagination(props) {
88
91
  className: classnames('fwe-page-dot', {
89
92
  'fwe-selected': index + 1 === innerPageCurrent
90
93
  }),
91
- onClick: ()=>onDotClick(index),
94
+ onClick: (e)=>onDotClick(index, e),
92
95
  "aria-label": `Go to page ${index + 1}`,
93
96
  "aria-current": index + 1 === innerPageCurrent ? 'page' : void 0
94
97
  }, index))
@@ -96,5 +99,6 @@ function Pagination(props) {
96
99
  })
97
100
  ]
98
101
  });
99
- }
102
+ });
103
+ Pagination.displayName = 'Pagination';
100
104
  export { Pagination, Pagination_PaginationType as PaginationType };
@@ -1,9 +1,11 @@
1
1
  import { type PopoverProps } from '../popover/Popover';
2
- export interface PopoverLegendItem {
2
+ export interface LegendItem {
3
3
  readonly name: string;
4
4
  readonly text: string;
5
5
  }
6
- export interface LegendProps extends Omit<PopoverProps, 'popoverContent'> {
7
- readonly items: PopoverLegendItem[];
6
+ export interface LegendProps extends Omit<PopoverProps, 'content'> {
7
+ readonly items: LegendItem[];
8
8
  }
9
- export declare function Legend({ items, ...props }: LegendProps): import("react/jsx-runtime").JSX.Element;
9
+ export declare const Legend: (props: LegendProps & {
10
+ children?: import("react").ReactNode | undefined;
11
+ } & import("react").RefAttributes<HTMLDivElement>) => React.ReactElement | null;
@@ -1,6 +1,8 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
+ import classnames from "classnames";
3
+ import { forwardRef } from "react";
2
4
  import { Popover } from "../popover/Popover.js";
3
- function Legend({ items, ...props }) {
5
+ const Legend = /*#__PURE__*/ forwardRef(({ items, containerClassName, ...props }, ref)=>{
4
6
  const content = items.map((item)=>/*#__PURE__*/ jsxs("dl", {
5
7
  className: "fwe-popover-legend-content",
6
8
  children: [
@@ -13,9 +15,11 @@ function Legend({ items, ...props }) {
13
15
  ]
14
16
  }, item.name));
15
17
  return /*#__PURE__*/ jsx(Popover, {
16
- popoverContent: content,
17
- popoverClassName: "fwe-popover--legend",
18
+ content: content,
19
+ containerClassName: classnames('fwe-popover--legend', containerClassName),
20
+ ref: ref,
18
21
  ...props
19
22
  });
20
- }
23
+ });
24
+ Legend.displayName = 'Legend';
21
25
  export { Legend };
@@ -1,56 +1,9 @@
1
- #arrow, #arrow:after {
2
- width: 12px;
3
- height: 12px;
4
- position: absolute;
5
- transform: rotate(45deg);
1
+ .fwe-popover-container {
2
+ z-index: var(--fwe-z-index-popover);
3
+ filter: drop-shadow(0 1px 3px #3336);
6
4
  }
7
5
 
8
- #arrow {
9
- width: 17px;
10
- height: 17px;
11
- overflow: hidden;
12
- }
13
-
14
- #arrow:after {
15
- content: "";
16
- z-index: -1;
17
- background: #fff;
18
- box-shadow: 0 1px 4px #3333;
19
- }
20
-
21
- .fwe-popover-container[data-popper-placement^="top"] > #arrow {
22
- top: 100%;
23
- }
24
-
25
- .fwe-popover-container[data-popper-placement^="top"] > #arrow:after {
26
- top: -6px;
27
- left: 3px;
28
- }
29
-
30
- .fwe-popover-container[data-popper-placement^="bottom"] > #arrow {
31
- top: -17px;
32
- }
33
-
34
- .fwe-popover-container[data-popper-placement^="bottom"] > #arrow:after {
35
- top: 11px;
36
- left: 3px;
37
- }
38
-
39
- .fwe-popover-container[data-popper-placement^="left"] > #arrow {
40
- left: 100%;
41
- }
42
-
43
- .fwe-popover-container[data-popper-placement^="left"] > #arrow:after {
44
- top: 2px;
45
- left: -6px;
46
- }
47
-
48
- .fwe-popover-container[data-popper-placement^="right"] > #arrow {
49
- left: -17px;
50
- }
51
-
52
- .fwe-popover-container[data-popper-placement^="right"] > #arrow:after {
53
- top: 2px;
54
- left: 11px;
6
+ .fwe-popover-container .fwe-popover {
7
+ box-shadow: none;
55
8
  }
56
9
 
@@ -1,21 +1,19 @@
1
1
  import './Popover.scss';
2
- import type { Placement } from '@popperjs/core';
3
- import type React from 'react';
4
- import type { ClassNamePropsWithChildren } from '../../../utils/types';
5
- export interface PopoverProps extends ClassNamePropsWithChildren {
6
- readonly popoverContent: React.ReactNode;
2
+ import { type Placement } from '@floating-ui/react';
3
+ import { type MouseEvent, type ReactNode } from 'react';
4
+ export interface PopoverProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'content' | 'onChange'> {
5
+ readonly 'data-testid'?: string;
6
+ readonly containerClassName?: string;
7
+ readonly content: ReactNode;
7
8
  readonly position?: Placement;
8
9
  readonly fallbackPositions?: Placement[];
10
+ readonly isOpen?: boolean;
9
11
  readonly openOnHover?: boolean;
10
- readonly defaultOpen?: boolean;
11
- readonly open?: boolean;
12
- readonly onStatusChange?: (status: boolean) => void;
13
- readonly wrapper?: (children: React.ReactNode) => React.ReactNode;
12
+ readonly openByDefault?: boolean;
13
+ readonly onChange?: (isOpen: boolean) => void;
14
14
  readonly flip?: boolean;
15
- readonly containerClassName?: string;
16
- readonly popoverClassName?: string;
15
+ readonly showArrow?: boolean;
16
+ readonly onTriggerClick?: (event: MouseEvent) => void;
17
17
  readonly stopPropagation?: boolean;
18
- readonly arrow?: boolean;
19
- readonly onClick?: (event: React.MouseEvent<HTMLDivElement, MouseEvent>) => void;
20
18
  }
21
- export declare function Popover({ popoverContent, children, position, fallbackPositions, openOnHover, defaultOpen, open, onStatusChange, wrapper, className, flip, containerClassName, popoverClassName, stopPropagation, arrow, onClick, }: PopoverProps): import("react/jsx-runtime").JSX.Element;
19
+ export declare const Popover: (props: PopoverProps & import("react").RefAttributes<HTMLDivElement>) => React.ReactElement | null;