@povio/ui 2.2.5 → 2.2.7

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 (262) hide show
  1. package/dist/assets/icons/AlignCenter.js +3 -1
  2. package/dist/assets/icons/AlignLeft.js +3 -1
  3. package/dist/assets/icons/AlignLeftRight.js +3 -1
  4. package/dist/assets/icons/AlignRight.js +3 -1
  5. package/dist/assets/icons/ArrowDropDown.js +3 -1
  6. package/dist/assets/icons/ArrowDropUp.js +3 -1
  7. package/dist/assets/icons/ArrowLeft.js +3 -1
  8. package/dist/assets/icons/ArrowRight.js +3 -1
  9. package/dist/assets/icons/Bold.js +3 -1
  10. package/dist/assets/icons/BulletedList.js +3 -1
  11. package/dist/assets/icons/Calendar.js +3 -1
  12. package/dist/assets/icons/Check.js +3 -1
  13. package/dist/assets/icons/CheckCircle.js +3 -1
  14. package/dist/assets/icons/CheckboxCheckmark.js +3 -1
  15. package/dist/assets/icons/CheckboxIndeterminate.js +3 -1
  16. package/dist/assets/icons/ChevronDown.js +3 -1
  17. package/dist/assets/icons/ChevronLeft.js +3 -1
  18. package/dist/assets/icons/ChevronRight.js +3 -1
  19. package/dist/assets/icons/ChevronUp.js +3 -1
  20. package/dist/assets/icons/ChevronsLeft.js +3 -1
  21. package/dist/assets/icons/ChevronsRight.js +3 -1
  22. package/dist/assets/icons/Clock.js +3 -1
  23. package/dist/assets/icons/Close.js +3 -1
  24. package/dist/assets/icons/DateTime.js +3 -1
  25. package/dist/assets/icons/DragIndicator.js +3 -1
  26. package/dist/assets/icons/File.js +3 -1
  27. package/dist/assets/icons/Highlight.js +3 -1
  28. package/dist/assets/icons/HighlightOn.js +3 -1
  29. package/dist/assets/icons/Home.js +3 -1
  30. package/dist/assets/icons/Info.js +3 -1
  31. package/dist/assets/icons/Italic.js +3 -1
  32. package/dist/assets/icons/Link.js +3 -1
  33. package/dist/assets/icons/Menu.js +3 -1
  34. package/dist/assets/icons/NumberedList.js +3 -1
  35. package/dist/assets/icons/PointerHorizontal.js +3 -1
  36. package/dist/assets/icons/PointerVertical.js +3 -1
  37. package/dist/assets/icons/Search.js +15 -0
  38. package/dist/assets/icons/Send.js +3 -1
  39. package/dist/assets/icons/Strikethrough.js +3 -1
  40. package/dist/assets/icons/TextColor.js +3 -1
  41. package/dist/assets/icons/Today.js +3 -1
  42. package/dist/assets/icons/Underlined.js +3 -1
  43. package/dist/assets/icons/Upload.js +3 -1
  44. package/dist/assets/icons/Visibility.js +3 -1
  45. package/dist/assets/icons/VisibilityOff.js +3 -1
  46. package/dist/assets/icons/WarningFilled.js +3 -1
  47. package/dist/assets/locales/en/translation.json.js +1 -0
  48. package/dist/assets/locales/sl/translation.json.js +1 -0
  49. package/dist/components/Breadcrumbs/Breadcrumbs.js +5 -3
  50. package/dist/components/Breadcrumbs/breadcrumbs.cva.js +7 -5
  51. package/dist/components/Menu/Menu.js +3 -1
  52. package/dist/components/Menu/MenuDesktop.js +3 -1
  53. package/dist/components/Menu/MenuItem.js +3 -1
  54. package/dist/components/Menu/MenuMobile.js +4 -1
  55. package/dist/components/Menu/MenuPopover.js +3 -1
  56. package/dist/components/Menu/menu.cva.js +6 -4
  57. package/dist/components/buttons/Button/Button.js +3 -1
  58. package/dist/components/buttons/Button/button.cva.js +7 -5
  59. package/dist/components/buttons/IconButton/IconButton.js +3 -1
  60. package/dist/components/buttons/InlineIconButton/InlineIconButton.js +3 -1
  61. package/dist/components/buttons/PillButton/PillButton.js +3 -1
  62. package/dist/components/buttons/PillButton/pillButton.cva.js +6 -4
  63. package/dist/components/buttons/SplitButton/SplitButton.js +3 -1
  64. package/dist/components/buttons/TextButton/TextButton.js +3 -1
  65. package/dist/components/buttons/ToggleButton/ToggleButton.js +3 -1
  66. package/dist/components/buttons/shared/ButtonContent.js +3 -1
  67. package/dist/components/buttons/shared/buttonContent.cva.js +2 -1
  68. package/dist/components/inputs/Checkbox/Checkbox.js +4 -2
  69. package/dist/components/inputs/Checkbox/CheckboxCheckmark.js +3 -1
  70. package/dist/components/inputs/Checkbox/checkbox.cva.js +7 -4
  71. package/dist/components/inputs/DateTime/DatePicker/DatePicker.js +3 -1
  72. package/dist/components/inputs/DateTime/DateRangePicker/DateRangePicker.js +10 -8
  73. package/dist/components/inputs/DateTime/DateTimePicker/DateTimePicker.js +3 -1
  74. package/dist/components/inputs/DateTime/TimePicker/TimePicker.js +3 -1
  75. package/dist/components/inputs/DateTime/shared/Calendar.js +3 -1
  76. package/dist/components/inputs/DateTime/shared/CalendarCell.js +3 -1
  77. package/dist/components/inputs/DateTime/shared/CalendarGrid.js +3 -1
  78. package/dist/components/inputs/DateTime/shared/CalendarHeader.js +3 -1
  79. package/dist/components/inputs/DateTime/shared/CalendarSelectHeader.js +5 -3
  80. package/dist/components/inputs/DateTime/shared/DateField.js +3 -1
  81. package/dist/components/inputs/DateTime/shared/DatePickerInput.js +3 -1
  82. package/dist/components/inputs/DateTime/shared/DateSegmentItem.js +4 -2
  83. package/dist/components/inputs/DateTime/shared/DateTimeDialog.js +6 -14
  84. package/dist/components/inputs/DateTime/shared/DateTimeDialogFooter.js +4 -2
  85. package/dist/components/inputs/DateTime/shared/MonthPicker.js +3 -1
  86. package/dist/components/inputs/DateTime/shared/RangeCalendar.js +3 -1
  87. package/dist/components/inputs/DateTime/shared/TimeField.js +3 -1
  88. package/dist/components/inputs/DateTime/shared/TimePickerForm.js +3 -1
  89. package/dist/components/inputs/DateTime/shared/TimePickerInput.js +3 -1
  90. package/dist/components/inputs/DateTime/shared/YearPicker.js +3 -1
  91. package/dist/components/inputs/File/FileUpload.d.ts +1 -1
  92. package/dist/components/inputs/File/FileUpload.js +21 -7
  93. package/dist/components/inputs/File/FileUploadContainer.js +3 -1
  94. package/dist/components/inputs/File/InputUpload.js +3 -1
  95. package/dist/components/inputs/File/fileUpload.types.d.ts +11 -1
  96. package/dist/components/inputs/File/shared/FileCard.js +3 -1
  97. package/dist/components/inputs/File/shared/FileCardList.js +4 -2
  98. package/dist/components/inputs/File/shared/FileUploadContent.js +3 -1
  99. package/dist/components/inputs/File/shared/FileUploadContentEmpty.js +3 -1
  100. package/dist/components/inputs/File/shared/FileUploadContentError.js +5 -3
  101. package/dist/components/inputs/File/shared/FileUploadContentFilled.js +6 -4
  102. package/dist/components/inputs/File/shared/FileUploadContentLoading.js +6 -4
  103. package/dist/components/inputs/File/shared/InputUploadContent.js +4 -2
  104. package/dist/components/inputs/File/shared/InputUploadFilled.js +3 -1
  105. package/dist/components/inputs/File/shared/ProgressBar.js +3 -1
  106. package/dist/components/inputs/File/shared/fileUpload.cva.js +4 -2
  107. package/dist/components/inputs/File/shared/inputUploadButton.cva.js +6 -3
  108. package/dist/components/inputs/FormField/FormField.js +11 -1
  109. package/dist/components/inputs/FormField/FormFieldError.js +5 -3
  110. package/dist/components/inputs/FormField/FormFieldHeader.js +3 -1
  111. package/dist/components/inputs/FormField/FormFieldHeaderClose.js +4 -2
  112. package/dist/components/inputs/FormField/FormFieldHelper.d.ts +8 -0
  113. package/dist/components/inputs/FormField/FormFieldHelper.js +14 -0
  114. package/dist/components/inputs/FormField/FormFieldLabel.js +4 -1
  115. package/dist/components/inputs/FormField/formFieldError.cva.d.ts +6 -0
  116. package/dist/components/inputs/FormField/formFieldError.cva.js +11 -0
  117. package/dist/components/inputs/FormField/formFieldHelper.cva.d.ts +6 -0
  118. package/dist/components/inputs/FormField/formFieldHelper.cva.js +11 -0
  119. package/dist/components/inputs/Input/NumberInput/NumberInput.js +3 -1
  120. package/dist/components/inputs/Input/PasswordInput/PasswordInput.js +4 -2
  121. package/dist/components/inputs/Input/TextArea/TextArea.js +3 -1
  122. package/dist/components/inputs/Input/TextInput/TextInput.js +3 -1
  123. package/dist/components/inputs/Input/shared/InputContent.js +4 -1
  124. package/dist/components/inputs/Inputs/Form.js +2 -0
  125. package/dist/components/inputs/Inputs/InputItem.js +2 -0
  126. package/dist/components/inputs/Inputs/Inputs.js +2 -0
  127. package/dist/components/inputs/RadioGroup/RadioGroup.js +6 -4
  128. package/dist/components/inputs/RadioGroup/radio.cva.js +6 -3
  129. package/dist/components/inputs/Selection/Autocomplete/Autocomplete.js +3 -1
  130. package/dist/components/inputs/Selection/Autocomplete/QueryAutocomplete.js +3 -1
  131. package/dist/components/inputs/Selection/Select/Select.js +3 -1
  132. package/dist/components/inputs/Selection/shared/SelectBase.d.ts +1 -0
  133. package/dist/components/inputs/Selection/shared/SelectBase.js +5 -2
  134. package/dist/components/inputs/Selection/shared/SelectDesktop.js +4 -2
  135. package/dist/components/inputs/Selection/shared/SelectInput.js +4 -2
  136. package/dist/components/inputs/Selection/shared/SelectInputTags.js +3 -1
  137. package/dist/components/inputs/Selection/shared/SelectListBox.js +4 -2
  138. package/dist/components/inputs/Selection/shared/SelectListBoxItem.js +5 -3
  139. package/dist/components/inputs/Selection/shared/SelectListBoxItemSelectAll.js +4 -2
  140. package/dist/components/inputs/Selection/shared/SelectListBoxLoadingItem.js +4 -2
  141. package/dist/components/inputs/Selection/shared/SelectListBoxSelectionBar.js +4 -2
  142. package/dist/components/inputs/Selection/shared/SelectMobile.js +19 -13
  143. package/dist/components/inputs/Selection/shared/select.context.js +20 -18
  144. package/dist/components/inputs/Selection/shared/useSelectItems.js +6 -4
  145. package/dist/components/inputs/Slider/Slider.js +3 -1
  146. package/dist/components/inputs/TextEditor/TextEditor.js +3 -1
  147. package/dist/components/inputs/TextEditor/Toolbar/ColorPicker.js +3 -1
  148. package/dist/components/inputs/TextEditor/Toolbar/ColorPickerDropdown.js +3 -1
  149. package/dist/components/inputs/TextEditor/Toolbar/HyperlinkAction.js +4 -2
  150. package/dist/components/inputs/TextEditor/Toolbar/TextAlignSelect.js +4 -2
  151. package/dist/components/inputs/TextEditor/Toolbar/TextColorSelect.js +3 -1
  152. package/dist/components/inputs/TextEditor/Toolbar/TextEditorToolbar.js +3 -1
  153. package/dist/components/inputs/TextEditor/Toolbar/TextHighlightSelect.js +3 -1
  154. package/dist/components/inputs/TextEditor/Toolbar/TextListActions.js +4 -2
  155. package/dist/components/inputs/TextEditor/Toolbar/TextMarksActions.js +4 -2
  156. package/dist/components/inputs/TextEditor/Toolbar/TextStyleSelect.js +4 -2
  157. package/dist/components/inputs/TextEditor/textEditor.types.js +3 -1
  158. package/dist/components/inputs/Toggle/Toggle.js +3 -1
  159. package/dist/components/inputs/Toggle/toggle.cva.js +5 -2
  160. package/dist/components/inputs/shared/CheckContent.js +4 -1
  161. package/dist/components/inputs/shared/InputClear.js +5 -3
  162. package/dist/components/inputs/shared/TooltipWrapper.js +3 -1
  163. package/dist/components/inputs/shared/input.cva.js +6 -4
  164. package/dist/components/inputs/shared/label.cva.js +9 -2
  165. package/dist/components/navigation/Accordion/Accordion.js +3 -1
  166. package/dist/components/navigation/Accordion/AccordionItem.js +3 -1
  167. package/dist/components/navigation/Accordion/accordion.cva.js +12 -10
  168. package/dist/components/navigation/Stepper/Stepper.js +3 -1
  169. package/dist/components/navigation/Stepper/StepperItem.js +3 -1
  170. package/dist/components/navigation/Stepper/StepperSeparator.js +3 -1
  171. package/dist/components/navigation/Stepper/stepper.cva.js +9 -7
  172. package/dist/components/outline.clsx.js +4 -2
  173. package/dist/components/overlays/ActionModal/ActionModal.js +3 -1
  174. package/dist/components/overlays/BottomSheet/BottomSheet.d.ts +5 -0
  175. package/dist/components/overlays/BottomSheet/BottomSheet.js +23 -7
  176. package/dist/components/overlays/BottomSheet/BottomSheetHeader.d.ts +13 -0
  177. package/dist/components/overlays/BottomSheet/BottomSheetHeader.js +38 -0
  178. package/dist/components/overlays/Drawer/Drawer.js +3 -1
  179. package/dist/components/overlays/Modal/Modal.js +4 -2
  180. package/dist/components/overlays/Modal/modal.cva.js +5 -3
  181. package/dist/components/overlays/ResponsivePopover/ResponsivePopover.js +7 -10
  182. package/dist/components/overlays/Tooltip/Tooltip.js +7 -2
  183. package/dist/components/overlays/Tooltip/TooltipEllipsis.js +3 -1
  184. package/dist/components/overlays/Tooltip/tooltip.cva.js +6 -4
  185. package/dist/components/segment/Segment.js +3 -1
  186. package/dist/components/segment/SegmentItem.js +3 -1
  187. package/dist/components/segment/segment.cva.js +4 -2
  188. package/dist/components/shared/pagination/Pagination.js +4 -2
  189. package/dist/components/shared/pagination/PaginationList.js +4 -2
  190. package/dist/components/shared/pagination/minWidth.cva.js +3 -1
  191. package/dist/components/shared/popover.cva.js +3 -1
  192. package/dist/components/status/Alert/Alert.js +3 -1
  193. package/dist/components/status/Alert/alert.cva.js +3 -1
  194. package/dist/components/status/Loader/Loader.js +3 -1
  195. package/dist/components/status/Loader/loader.cva.js +4 -2
  196. package/dist/components/status/Toast/Toast.js +15 -6
  197. package/dist/components/status/Toast/toast.cva.js +6 -20
  198. package/dist/components/status/Toast/useToast.js +3 -1
  199. package/dist/components/status/shared/status.cva.js +4 -2
  200. package/dist/components/table/CellText.d.ts +2 -1
  201. package/dist/components/table/CellText.js +18 -10
  202. package/dist/components/table/ColumnConfig.js +3 -1
  203. package/dist/components/table/HeaderText.d.ts +5 -2
  204. package/dist/components/table/HeaderText.js +17 -7
  205. package/dist/components/table/InfiniteTable.js +3 -1
  206. package/dist/components/table/PaginatedTable.js +3 -1
  207. package/dist/components/table/Table.js +5 -3
  208. package/dist/components/table/table.cva.d.ts +6 -0
  209. package/dist/components/table/table.cva.js +9 -5
  210. package/dist/components/text/Link/Link.js +3 -1
  211. package/dist/components/text/Link/link.cva.js +3 -1
  212. package/dist/components/text/Tag/Tag.d.ts +3 -0
  213. package/dist/components/text/Tag/Tag.js +9 -4
  214. package/dist/components/text/Tag/tag.cva.js +3 -1
  215. package/dist/components/text/Typography/Typography.js +3 -1
  216. package/dist/components/text/Typography/typography.cva.js +3 -1
  217. package/dist/config/confirmation.context.js +4 -2
  218. package/dist/config/i18n.js +4 -2
  219. package/dist/config/link.context.js +3 -1
  220. package/dist/config/router.context.js +3 -1
  221. package/dist/config/theme.context.js +8 -6
  222. package/dist/config/uiConfig.context.d.ts +10 -2
  223. package/dist/config/uiConfig.context.js +25 -4
  224. package/dist/config/uiStyle.context.d.ts +9 -1
  225. package/dist/config/uiStyle.context.js +3 -1
  226. package/dist/helpers/dynamicColumns.js +4 -2
  227. package/dist/helpers/dynamicInputs.js +5 -3
  228. package/dist/hooks/useAutosave.js +2 -0
  229. package/dist/hooks/useBreakpoint.js +5 -3
  230. package/dist/hooks/useDebounceCallback.js +2 -0
  231. package/dist/hooks/useDeepCompare.js +5 -3
  232. package/dist/hooks/useFilters.js +3 -1
  233. package/dist/hooks/useForm.js +2 -0
  234. package/dist/hooks/useFormAutosave.js +2 -0
  235. package/dist/hooks/useIntersectionObserver.js +3 -1
  236. package/dist/hooks/useLocalStorage.js +3 -1
  237. package/dist/hooks/useLongPressRepeat.js +3 -1
  238. package/dist/hooks/usePagination.js +2 -0
  239. package/dist/hooks/useScrollableListBox.js +2 -0
  240. package/dist/hooks/useSorting.js +2 -0
  241. package/dist/hooks/useStateAndRef.js +3 -1
  242. package/dist/hooks/useTableColumnConfig.js +2 -0
  243. package/dist/hooks/useTableNav.js +124 -20
  244. package/dist/hooks/useTranslationMemo.js +2 -0
  245. package/dist/index.js +1 -1
  246. package/dist/tw-ui-plugin.js +4 -2
  247. package/dist/utils/array.utils.js +3 -1
  248. package/dist/utils/compoundMapper.js +3 -1
  249. package/dist/utils/date-time.utils.js +3 -1
  250. package/dist/utils/date.utils.js +3 -1
  251. package/dist/utils/dom.utils.js +3 -1
  252. package/dist/utils/file.utils.d.ts +4 -0
  253. package/dist/utils/file.utils.js +10 -3
  254. package/dist/utils/isEqual.js +3 -1
  255. package/dist/utils/logger.js +3 -1
  256. package/dist/utils/object.utils.js +3 -1
  257. package/dist/utils/queries.utils.js +3 -1
  258. package/dist/utils/rest.utils.js +3 -1
  259. package/dist/utils/routing.utils.js +3 -1
  260. package/dist/utils/string.utils.js +3 -1
  261. package/dist/utils/zod.utils.js +3 -1
  262. package/package.json +2 -2
@@ -1,4 +1,5 @@
1
1
  import { UIConfig } from "../../../config/uiConfig.context.js";
2
+ import { BottomSheetHeader } from "./BottomSheetHeader.js";
2
3
  import { useStateAndRef } from "../../../hooks/useStateAndRef.js";
3
4
  import { DomUtils } from "../../../utils/dom.utils.js";
4
5
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
@@ -6,7 +7,8 @@ import { clsx } from "clsx";
6
7
  import { useEffect, useMemo, useRef, useState } from "react";
7
8
  import { Dialog, DialogTrigger, Modal, ModalOverlay } from "react-aria-components";
8
9
  import { useResizeObserver, useViewportSize } from "@react-aria/utils";
9
- import { AnimatePresence, animate, motion, useMotionValue } from "motion/react";
10
+ import { AnimatePresence, animate, motion, useDragControls, useMotionValue } from "motion/react";
11
+ //#region src/components/overlays/BottomSheet/BottomSheet.tsx
10
12
  var MotionModal = motion.create(Modal);
11
13
  var MotionModalOverlay = motion.create(ModalOverlay);
12
14
  var inertiaTransition = {
@@ -24,10 +26,12 @@ var staticTransition = {
24
26
  1
25
27
  ]
26
28
  };
27
- var BottomSheetBase = ({ isOpen, onOpenChange, onStateChange, isDismissable = false, isScrollable = true, height = "full", label, portalContainerRef, children, footer, sheetMarginTop = 96, sheetMarginBottom = 128, closeDragThreshold: closeDragThresholdProp, closeVelocityThreshold: closeVelocityThresholdProp, shouldCloseOnInteractOutside, containerClassName }) => {
29
+ var BottomSheetBase = ({ isOpen, onOpenChange, onStateChange, isDismissable = true, isScrollable = true, height = "full", label, portalContainerRef, children, footer, hideHeader, hideThumb: hideThumbProp, sheetMarginTop = 96, sheetMarginBottom = 128, closeDragThreshold: closeDragThresholdProp, closeVelocityThreshold: closeVelocityThresholdProp, shouldCloseOnInteractOutside, containerClassName, overlayClassName, headerTypography: headerTypographyProp }) => {
28
30
  const uiConfig = UIConfig.useConfig();
29
31
  const closeDragThreshold = closeDragThresholdProp ?? uiConfig.bottomSheet.closeDragThreshold;
30
32
  const closeVelocityThreshold = closeVelocityThresholdProp ?? uiConfig.bottomSheet.closeVelocityThreshold;
33
+ const hideThumb = hideThumbProp ?? uiConfig.bottomSheet.hideThumb;
34
+ const headerTypography = headerTypographyProp ?? uiConfig.bottomSheet.headerTypography;
31
35
  const viewport = useViewportSize();
32
36
  const { sheetHeight, windowHeight } = useMemo(() => {
33
37
  return {
@@ -36,6 +40,7 @@ var BottomSheetBase = ({ isOpen, onOpenChange, onStateChange, isDismissable = fa
36
40
  };
37
41
  }, [viewport.height, sheetMarginTop]);
38
42
  const y = useMotionValue(sheetHeight);
43
+ const dragControls = useDragControls();
39
44
  const closeVelocityRef = useRef(true);
40
45
  const overlayRef = useRef(null);
41
46
  const containerRef = useRef(null);
@@ -78,12 +83,12 @@ var BottomSheetBase = ({ isOpen, onOpenChange, onStateChange, isDismissable = fa
78
83
  ref: overlayRef,
79
84
  shouldCloseOnInteractOutside,
80
85
  children: [/* @__PURE__ */ jsx(motion.div, {
81
- className: "pointer-events-none absolute inset-0 bg-support-overlay",
86
+ className: clsx("pointer-events-none absolute inset-0 bg-support-overlay", overlayClassName),
82
87
  animate: { opacity: 1 },
83
88
  initial: { opacity: 0 },
84
89
  exit: { opacity: 0 }
85
90
  }), /* @__PURE__ */ jsx(MotionModal, {
86
- isDismissable: true,
91
+ isDismissable,
87
92
  className: clsx("pointer-events-none flex h-full w-full flex-col items-stretch justify-end outline-none will-change-transform"),
88
93
  animate: {
89
94
  y: 0,
@@ -109,6 +114,8 @@ var BottomSheetBase = ({ isOpen, onOpenChange, onStateChange, isDismissable = fa
109
114
  minHeight: "100%"
110
115
  },
111
116
  drag: "y",
117
+ dragListener: false,
118
+ dragControls,
112
119
  dragElastic: {
113
120
  top: 0,
114
121
  bottom: .5
@@ -157,10 +164,18 @@ var BottomSheetBase = ({ isOpen, onOpenChange, onStateChange, isDismissable = fa
157
164
  ref: focusTrapRef,
158
165
  tabIndex: -1
159
166
  }),
160
- /* @__PURE__ */ jsx("div", {
167
+ /* @__PURE__ */ jsxs("div", {
161
168
  className: "flex max-h-full min-h-0 flex-col items-stretch",
162
169
  ref: containerRef,
163
- children: typeof children === "function" ? children(close) : children
170
+ children: [/* @__PURE__ */ jsx(BottomSheetHeader, {
171
+ label,
172
+ dragControls,
173
+ onClose: close,
174
+ isDismissable,
175
+ hideHeader,
176
+ hideThumb,
177
+ headerTypography
178
+ }), typeof children === "function" ? children(close) : children]
164
179
  }),
165
180
  /* @__PURE__ */ jsx("div", {
166
181
  className: "shrink-0",
@@ -182,7 +197,7 @@ var BottomSheetBase = ({ isOpen, onOpenChange, onStateChange, isDismissable = fa
182
197
  })]
183
198
  }) });
184
199
  };
185
- const BottomSheet = ({ isOpen, portalContainerRef, onOpenChange, trigger, children, ...rest }) => {
200
+ var BottomSheet = ({ isOpen, portalContainerRef, onOpenChange, trigger, children, ...rest }) => {
186
201
  const [isSheetOpen, setIsSheetOpen] = useState(!!isOpen);
187
202
  const hasTrigger = !!trigger;
188
203
  useEffect(() => {
@@ -213,4 +228,5 @@ const BottomSheet = ({ isOpen, portalContainerRef, onOpenChange, trigger, childr
213
228
  children
214
229
  });
215
230
  };
231
+ //#endregion
216
232
  export { BottomSheet };
@@ -0,0 +1,13 @@
1
+ import { DragControls } from 'motion/react';
2
+ import { ReactNode } from 'react';
3
+ import { TypographyVariantProps } from '../../text/Typography/typography.cva';
4
+ export interface BottomSheetHeaderProps {
5
+ label?: ReactNode;
6
+ isDismissable?: boolean;
7
+ dragControls?: DragControls;
8
+ hideHeader?: boolean;
9
+ hideThumb?: boolean;
10
+ headerTypography?: TypographyVariantProps;
11
+ onClose?: () => void;
12
+ }
13
+ export declare const BottomSheetHeader: ({ label, dragControls, isDismissable, hideThumb, hideHeader, headerTypography, onClose, }: BottomSheetHeaderProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,38 @@
1
+ import { CloseIcon } from "../../../assets/icons/Close.js";
2
+ import { Typography } from "../../text/Typography/Typography.js";
3
+ import "../../../config/i18n.js";
4
+ import { jsx, jsxs } from "react/jsx-runtime";
5
+ import { clsx } from "clsx";
6
+ import { Button } from "react-aria-components";
7
+ import { useTranslation } from "react-i18next";
8
+ //#region src/components/overlays/BottomSheet/BottomSheetHeader.tsx
9
+ var BottomSheetHeader = ({ label, dragControls, isDismissable, hideThumb, hideHeader, headerTypography, onClose }) => {
10
+ const { t } = useTranslation("ui");
11
+ return /* @__PURE__ */ jsxs("div", {
12
+ className: clsx("pb-list-height-title-bottom", !isDismissable && "pt-list-height-title-top"),
13
+ children: [isDismissable && !hideThumb && /* @__PURE__ */ jsx("div", {
14
+ className: "flex shrink-0 cursor-grab touch-none justify-center px-list-side-title pt-list-height-title-top pb-2-5",
15
+ onPointerDown: (e) => {
16
+ e.preventDefault();
17
+ dragControls?.start(e);
18
+ },
19
+ "aria-hidden": true,
20
+ children: /* @__PURE__ */ jsx("div", { className: "h-1 w-16 shrink-0 rounded-full bg-elevation-fill-default-3" })
21
+ }), !hideHeader && /* @__PURE__ */ jsxs("div", {
22
+ className: "flex justify-between px-list-side-title",
23
+ children: [/* @__PURE__ */ jsx(Typography, {
24
+ size: "label-2",
25
+ variant: "prominent-1",
26
+ ...headerTypography,
27
+ children: label
28
+ }), onClose && isDismissable && /* @__PURE__ */ jsx(Button, {
29
+ onPress: onClose,
30
+ "aria-label": t(($) => $.ui.closeAlt),
31
+ className: "-m-2 shrink-0 p-2 text-interactive-text-secondary-idle focus-visible:outline-interactive-text-secondary-focus",
32
+ children: /* @__PURE__ */ jsx(CloseIcon, { className: "size-6" })
33
+ })]
34
+ })]
35
+ });
36
+ };
37
+ //#endregion
38
+ export { BottomSheetHeader };
@@ -2,7 +2,8 @@ import { modalOverlay } from "../Modal/modal.cva.js";
2
2
  import { jsx, jsxs } from "react/jsx-runtime";
3
3
  import { clsx } from "clsx";
4
4
  import { Dialog, DialogTrigger, Modal, ModalOverlay } from "react-aria-components";
5
- const Drawer = ({ label, isOpen, portalContainerRef, onOpenChange, trigger, children, isDismissable, overlayClassName, dialogClassName, className, shouldCloseOnInteractOutside }) => {
5
+ //#region src/components/overlays/Drawer/Drawer.tsx
6
+ var Drawer = ({ label, isOpen, portalContainerRef, onOpenChange, trigger, children, isDismissable, overlayClassName, dialogClassName, className, shouldCloseOnInteractOutside }) => {
6
7
  if (trigger) return /* @__PURE__ */ jsxs(DialogTrigger, {
7
8
  isOpen,
8
9
  onOpenChange,
@@ -48,4 +49,5 @@ var DrawerOverlay = ({ label, isOpen, onOpenChange, portalContainerRef, children
48
49
  })
49
50
  });
50
51
  };
52
+ //#endregion
51
53
  export { Drawer };
@@ -1,13 +1,14 @@
1
1
  import { CloseIcon } from "../../../assets/icons/Close.js";
2
2
  import { UIStyle } from "../../../config/uiStyle.context.js";
3
3
  import { InlineIconButton } from "../../buttons/InlineIconButton/InlineIconButton.js";
4
- import { ns } from "../../../config/i18n.js";
4
+ import "../../../config/i18n.js";
5
5
  import { modalContent, modalMain, modalOverlay } from "./modal.cva.js";
6
6
  import { jsx, jsxs } from "react/jsx-runtime";
7
7
  import { clsx } from "clsx";
8
8
  import { Dialog, Modal, ModalOverlay } from "react-aria-components";
9
9
  import { useTranslation } from "react-i18next";
10
- const Modal$1 = ({ isOpen, portalContainerRef, onClose, aside, children, modalClassName, closeIconClassName, overlayClassName, showCloseIcon, isDismissable = true, isKeyboardDismissable, shouldCloseOnInteractOutside }) => {
10
+ //#region src/components/overlays/Modal/Modal.tsx
11
+ var Modal$1 = ({ isOpen, portalContainerRef, onClose, aside, children, modalClassName, closeIconClassName, overlayClassName, showCloseIcon, isDismissable = true, isKeyboardDismissable, shouldCloseOnInteractOutside }) => {
11
12
  const { t } = useTranslation("ui");
12
13
  const modalMainCva = UIStyle.useCva("modal.mainCva", modalMain);
13
14
  const modalContentCva = UIStyle.useCva("modal.contentCva", modalContent);
@@ -50,4 +51,5 @@ const Modal$1 = ({ isOpen, portalContainerRef, onClose, aside, children, modalCl
50
51
  })
51
52
  });
52
53
  };
54
+ //#endregion
53
55
  export { Modal$1 as Modal };
@@ -1,5 +1,6 @@
1
1
  import { cva } from "class-variance-authority";
2
- const modalContent = cva([
2
+ //#region src/components/overlays/Modal/modal.cva.ts
3
+ var modalContent = cva([
3
4
  "relative flex flex-col items-center gap-modal-gap-content px-modal-side-mobile py-modal-height-mobile md:px-modal-side-desktop md:py-modal-height-desktop",
4
5
  "w-fit max-w-full [&>*]:max-w-full",
5
6
  "border-elevation-outline-default-1 bg-elevation-fill-default-1 outline-none",
@@ -12,7 +13,7 @@ const modalContent = cva([
12
13
  } },
13
14
  defaultVariants: { aside: "center" }
14
15
  });
15
- const modalOverlay = cva(["fixed inset-0 z-10 flex h-(--visual-viewport-height) w-screen overflow-y-auto bg-support-overlay"], {
16
+ var modalOverlay = cva(["fixed inset-0 z-10 flex h-(--visual-viewport-height) w-screen overflow-y-auto bg-support-overlay"], {
16
17
  variants: { aside: {
17
18
  left: "p-0",
18
19
  right: "p-0",
@@ -20,7 +21,7 @@ const modalOverlay = cva(["fixed inset-0 z-10 flex h-(--visual-viewport-height)
20
21
  } },
21
22
  defaultVariants: { aside: "center" }
22
23
  });
23
- const modalMain = cva(["pointer-events-none my-auto flex w-full"], {
24
+ var modalMain = cva(["pointer-events-none my-auto flex w-full"], {
24
25
  variants: { aside: {
25
26
  left: "entering:animate-drawer-enter-left exiting:animate-drawer-exit-left justify-start",
26
27
  right: "entering:animate-drawer-enter-right exiting:animate-drawer-exit-right justify-end",
@@ -28,4 +29,5 @@ const modalMain = cva(["pointer-events-none my-auto flex w-full"], {
28
29
  } },
29
30
  defaultVariants: { aside: "center" }
30
31
  });
32
+ //#endregion
31
33
  export { modalContent, modalMain, modalOverlay };
@@ -1,13 +1,12 @@
1
1
  import { UIStyle } from "../../../config/uiStyle.context.js";
2
2
  import { BottomSheet } from "../BottomSheet/BottomSheet.js";
3
3
  import { useBreakpoint } from "../../../hooks/useBreakpoint.js";
4
- import { FormFieldHeader } from "../../inputs/FormField/FormFieldHeader.js";
5
- import { FormFieldHeaderClose } from "../../inputs/FormField/FormFieldHeaderClose.js";
6
4
  import { popover } from "../../shared/popover.cva.js";
7
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
5
+ import { jsx, jsxs } from "react/jsx-runtime";
8
6
  import { clsx } from "clsx";
9
7
  import { Dialog, DialogTrigger, Popover } from "react-aria-components";
10
- const ResponsivePopover = ({ trigger, isOpen, onOpenChange, children, popoverClassName, sheetLabel }) => {
8
+ //#region src/components/overlays/ResponsivePopover/ResponsivePopover.tsx
9
+ var ResponsivePopover = ({ trigger, isOpen, onOpenChange, children, popoverClassName, sheetLabel }) => {
11
10
  const popoverCva = UIStyle.useCva("popover.cva", popover);
12
11
  if (!useBreakpoint("md")) return /* @__PURE__ */ jsx(BottomSheet, {
13
12
  isOpen,
@@ -15,14 +14,11 @@ const ResponsivePopover = ({ trigger, isOpen, onOpenChange, children, popoverCla
15
14
  trigger,
16
15
  height: "auto",
17
16
  isDismissable: true,
18
- children: (close) => /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(FormFieldHeader, {
19
- label: sheetLabel,
20
- rightContent: /* @__PURE__ */ jsx(FormFieldHeaderClose, { onClose: close }),
21
- className: "px-4 pt-3"
22
- }), /* @__PURE__ */ jsx("div", {
17
+ label: sheetLabel,
18
+ children: /* @__PURE__ */ jsx("div", {
23
19
  className: "p-4",
24
20
  children
25
- })] })
21
+ })
26
22
  });
27
23
  return /* @__PURE__ */ jsxs(DialogTrigger, {
28
24
  isOpen,
@@ -41,4 +37,5 @@ const ResponsivePopover = ({ trigger, isOpen, onOpenChange, children, popoverCla
41
37
  })]
42
38
  });
43
39
  };
40
+ //#endregion
44
41
  export { ResponsivePopover };
@@ -8,6 +8,7 @@ import { clsx } from "clsx";
8
8
  import { Fragment as Fragment$1, useRef } from "react";
9
9
  import { OverlayArrow, Tooltip, TooltipTrigger } from "react-aria-components";
10
10
  import { useFocusable } from "react-aria";
11
+ //#region src/components/overlays/Tooltip/Tooltip.tsx
11
12
  var CustomTrigger = ({ children, className, tabIndex }) => {
12
13
  const ref = useRef(null);
13
14
  const { focusableProps } = useFocusable({}, ref);
@@ -19,7 +20,7 @@ var CustomTrigger = ({ children, className, tabIndex }) => {
19
20
  children
20
21
  });
21
22
  };
22
- const Tooltip$1 = ({ children, text, isDisabled, delay, closeDelay, color, isNonInteractiveTrigger, triggerClassName, triggerTabIndex, ...tooltipProps }) => {
23
+ var Tooltip$1 = ({ children, text, isDisabled, delay, closeDelay, color, isNonInteractiveTrigger, triggerClassName, triggerTabIndex, ...tooltipProps }) => {
23
24
  const tooltipCva$1 = UIStyle.useCva("tooltip.cva", tooltipCva);
24
25
  const tooltipPointerHorizontalCva$1 = UIStyle.useCva("tooltip.pointerHorizontalCva", tooltipPointerHorizontalCva);
25
26
  const tooltipPointerVerticalCva$1 = UIStyle.useCva("tooltip.pointerVerticalCva", tooltipPointerVerticalCva);
@@ -34,8 +35,11 @@ const Tooltip$1 = ({ children, text, isDisabled, delay, closeDelay, color, isNon
34
35
  tabIndex: triggerTabIndex,
35
36
  children
36
37
  }) : /* @__PURE__ */ jsx(Trigger, { children }), /* @__PURE__ */ jsxs(Tooltip, {
37
- className: tooltipCva$1({ color }),
38
38
  ...tooltipProps,
39
+ className: tooltipCva$1({
40
+ color,
41
+ className: tooltipProps.className
42
+ }),
39
43
  offset: 13,
40
44
  children: [/* @__PURE__ */ jsxs(OverlayArrow, { children: [/* @__PURE__ */ jsx(PointerHorizontalIcon, { className: tooltipPointerHorizontalCva$1({ color }) }), /* @__PURE__ */ jsx(PointerVerticalIcon, { className: tooltipPointerVerticalCva$1({ color }) })] }), /* @__PURE__ */ jsx(Typography, {
41
45
  size: "body-4",
@@ -46,4 +50,5 @@ const Tooltip$1 = ({ children, text, isDisabled, delay, closeDelay, color, isNon
46
50
  })]
47
51
  });
48
52
  };
53
+ //#endregion
49
54
  export { Tooltip$1 as Tooltip };
@@ -1,7 +1,8 @@
1
1
  import { Tooltip } from "./Tooltip.js";
2
2
  import { jsx } from "react/jsx-runtime";
3
3
  import { useState } from "react";
4
- const TooltipEllipsis = ({ text, children, isDisabled, isNonInteractiveTrigger }) => {
4
+ //#region src/components/overlays/Tooltip/TooltipEllipsis.tsx
5
+ var TooltipEllipsis = ({ text, children, isDisabled, isNonInteractiveTrigger }) => {
5
6
  const [isEllipsisActive, setIsEllipsisActive] = useState(false);
6
7
  const onContentRef = (ref) => {
7
8
  if (ref) setIsEllipsisActive(ref.offsetWidth < ref.scrollWidth);
@@ -16,4 +17,5 @@ const TooltipEllipsis = ({ text, children, isDisabled, isNonInteractiveTrigger }
16
17
  });
17
18
  return content;
18
19
  };
20
+ //#endregion
19
21
  export { TooltipEllipsis };
@@ -1,30 +1,32 @@
1
1
  import { cva } from "class-variance-authority";
2
- const tooltipCva = cva(["group max-w-64 rounded-tooltip-rounding-default px-tooltip-side-default py-tooltip-height-default shadow-2"], {
2
+ //#region src/components/overlays/Tooltip/tooltip.cva.ts
3
+ var tooltipCva = cva(["group max-w-64 rounded-tooltip-rounding-default px-tooltip-side-default py-tooltip-height-default shadow-2"], {
3
4
  variants: { color: {
4
5
  default: ["bg-interactive-contained-secondary-idle"],
5
6
  error: ["w-max bg-elevation-fill-error-1"]
6
7
  } },
7
8
  defaultVariants: { color: "default" }
8
9
  });
9
- const tooltipPointerHorizontalCva = cva(["h-2-5 w-5 group-placement-left:hidden group-placement-right:hidden group-placement-top:rotate-180"], {
10
+ var tooltipPointerHorizontalCva = cva(["h-2-5 w-5 group-placement-left:hidden group-placement-right:hidden group-placement-top:rotate-180"], {
10
11
  variants: { color: {
11
12
  default: ["text-interactive-contained-secondary-idle"],
12
13
  error: ["text-elevation-fill-error-1"]
13
14
  } },
14
15
  defaultVariants: { color: "default" }
15
16
  });
16
- const tooltipPointerVerticalCva = cva(["h-5 w-2-5 group-placement-bottom:hidden group-placement-top:hidden group-placement-left:rotate-180"], {
17
+ var tooltipPointerVerticalCva = cva(["h-5 w-2-5 group-placement-bottom:hidden group-placement-top:hidden group-placement-left:rotate-180"], {
17
18
  variants: { color: {
18
19
  default: ["text-interactive-contained-secondary-idle"],
19
20
  error: ["text-elevation-fill-error-1"]
20
21
  } },
21
22
  defaultVariants: { color: "default" }
22
23
  });
23
- const tooltipTextCva = cva([], {
24
+ var tooltipTextCva = cva([], {
24
25
  variants: { color: {
25
26
  default: ["text-interactive-contained-secondary-on-idle"],
26
27
  error: ["text-text-error-inverted-1"]
27
28
  } },
28
29
  defaultVariants: { color: "default" }
29
30
  });
31
+ //#endregion
30
32
  export { tooltipCva, tooltipPointerHorizontalCva, tooltipPointerVerticalCva, tooltipTextCva };
@@ -10,6 +10,7 @@ import { useToggleButtonGroup } from "react-aria";
10
10
  import { mergeRefs } from "@react-aria/utils";
11
11
  import { Controller } from "react-hook-form";
12
12
  import { useToggleGroupState } from "react-stately";
13
+ //#region src/components/segment/Segment.tsx
13
14
  var SegmentBase = ({ className, items, error, onChange, value, defaultValue, ...rest }) => {
14
15
  const props = {
15
16
  ...rest,
@@ -60,7 +61,7 @@ var SegmentBase = ({ className, items, error, onChange, value, defaultValue, ...
60
61
  })
61
62
  });
62
63
  };
63
- const Segment = (props) => {
64
+ var Segment = (props) => {
64
65
  if ("formControl" in props && props.formControl) {
65
66
  const { formControl, ref, ...innerProps } = props;
66
67
  return /* @__PURE__ */ jsx(Controller, {
@@ -78,4 +79,5 @@ const Segment = (props) => {
78
79
  }
79
80
  return /* @__PURE__ */ jsx(SegmentBase, { ...props });
80
81
  };
82
+ //#endregion
81
83
  export { Segment };
@@ -3,7 +3,8 @@ import { Typography } from "../text/Typography/Typography.js";
3
3
  import { segmentItemCva } from "./segment.cva.js";
4
4
  import { jsx, jsxs } from "react/jsx-runtime";
5
5
  import { ToggleButton } from "react-aria-components";
6
- const SegmentItem = ({ label, icon, id, isDisabled, ...props }) => {
6
+ //#region src/components/segment/SegmentItem.tsx
7
+ var SegmentItem = ({ label, icon, id, isDisabled, ...props }) => {
7
8
  const IconComponent = icon;
8
9
  const iconOnly = !!(icon && !label);
9
10
  const segmentItemCva$1 = UIStyle.useCva("segment.itemCva", segmentItemCva);
@@ -20,4 +21,5 @@ const SegmentItem = ({ label, icon, id, isDisabled, ...props }) => {
20
21
  })]
21
22
  });
22
23
  };
24
+ //#endregion
23
25
  export { SegmentItem };
@@ -1,10 +1,11 @@
1
1
  import { cva } from "class-variance-authority";
2
- const segmentCva = cva([
2
+ //#region src/components/segment/segment.cva.ts
3
+ var segmentCva = cva([
3
4
  "group/segment grid w-fit items-center gap-segmented-control-side-segmented-control p-segmented-control-side-segmented-control",
4
5
  "bg-elevation-fill-default-3",
5
6
  "rounded-segmented-control-rounding-segmented-control"
6
7
  ]);
7
- const segmentItemCva = cva([
8
+ var segmentItemCva = cva([
8
9
  "flex items-center justify-center gap-segmented-control-gap-content-icon-to-text transition-all duration-200",
9
10
  "border border-support-transparent-outline",
10
11
  "py-segmented-control-height-segment",
@@ -22,4 +23,5 @@ const segmentItemCva = cva([
22
23
  } },
23
24
  defaultVariants: { iconOnly: false }
24
25
  });
26
+ //#endregion
25
27
  export { segmentCva, segmentItemCva };
@@ -1,11 +1,12 @@
1
1
  import { Typography } from "../../text/Typography/Typography.js";
2
- import { ns } from "../../../config/i18n.js";
2
+ import "../../../config/i18n.js";
3
3
  import { NumberInput } from "../../inputs/Input/NumberInput/NumberInput.js";
4
4
  import { PaginationList } from "./PaginationList.js";
5
5
  import { jsx, jsxs } from "react/jsx-runtime";
6
6
  import { clsx } from "clsx";
7
7
  import { useTranslation } from "react-i18next";
8
- const Pagination = ({ size = "s", variant = "subtle", color = "secondary", page, totalItems, totalPages, pageSize, hideText = true, hideFirstLast = true, hidePrevNext = false, hideNumbers = false, className, onPageChange, onPageSizeChange }) => {
8
+ //#region src/components/shared/pagination/Pagination.tsx
9
+ var Pagination = ({ size = "s", variant = "subtle", color = "secondary", page, totalItems, totalPages, pageSize, hideText = true, hideFirstLast = true, hidePrevNext = false, hideNumbers = false, className, onPageChange, onPageSizeChange }) => {
9
10
  const { t } = useTranslation("ui");
10
11
  return /* @__PURE__ */ jsxs("nav", {
11
12
  id: "pagination",
@@ -40,4 +41,5 @@ const Pagination = ({ size = "s", variant = "subtle", color = "secondary", page,
40
41
  })]
41
42
  });
42
43
  };
44
+ //#endregion
43
45
  export { Pagination };
@@ -3,13 +3,14 @@ import { ChevronRightIcon } from "../../../assets/icons/ChevronRight.js";
3
3
  import { ChevronsLeftIcon } from "../../../assets/icons/ChevronsLeft.js";
4
4
  import { ChevronsRightIcon } from "../../../assets/icons/ChevronsRight.js";
5
5
  import { Button } from "../../buttons/Button/Button.js";
6
- import { ns } from "../../../config/i18n.js";
6
+ import "../../../config/i18n.js";
7
7
  import { minWidth } from "./minWidth.cva.js";
8
8
  import { jsx, jsxs } from "react/jsx-runtime";
9
9
  import { clsx } from "clsx";
10
10
  import { useMemo } from "react";
11
11
  import { useTranslation } from "react-i18next";
12
- const PaginationList = ({ page, totalPages, size, color, variant, hideText, hideFirstLast, hidePrevNext, hideNumbers, className, onPageChange }) => {
12
+ //#region src/components/shared/pagination/PaginationList.tsx
13
+ var PaginationList = ({ page, totalPages, size, color, variant, hideText, hideFirstLast, hidePrevNext, hideNumbers, className, onPageChange }) => {
13
14
  const { t } = useTranslation("ui");
14
15
  const isPrevDisabled = page <= 1;
15
16
  const isNextDisabled = page >= totalPages;
@@ -102,4 +103,5 @@ const PaginationList = ({ page, totalPages, size, color, variant, hideText, hide
102
103
  ]
103
104
  });
104
105
  };
106
+ //#endregion
105
107
  export { PaginationList };
@@ -1,9 +1,11 @@
1
1
  import { cva } from "class-variance-authority";
2
- const minWidth = cva("", { variants: { size: {
2
+ //#region src/components/shared/pagination/minWidth.cva.ts
3
+ var minWidth = cva("", { variants: { size: {
3
4
  xxs: ["min-w-button-width-min-width-xxs"],
4
5
  xs: ["min-w-button-width-min-width-xs"],
5
6
  s: ["min-w-button-width-min-width-s"],
6
7
  m: ["min-w-button-width-min-width-m"],
7
8
  l: ["min-w-button-width-min-width-l"]
8
9
  } } });
10
+ //#endregion
9
11
  export { minWidth };
@@ -1,3 +1,5 @@
1
1
  import { cva } from "class-variance-authority";
2
- const popover = cva("rounded-list-rounding-dropdown border border-elevation-outline-default-1 border-solid bg-elevation-fill-default-1 shadow-5 outline-none");
2
+ //#region src/components/shared/popover.cva.ts
3
+ var popover = cva("rounded-list-rounding-dropdown border border-elevation-outline-default-1 border-solid bg-elevation-fill-default-1 shadow-5 outline-none");
4
+ //#endregion
3
5
  export { popover };
@@ -4,7 +4,8 @@ import { Loader } from "../Loader/Loader.js";
4
4
  import { alert } from "./alert.cva.js";
5
5
  import { statusIcon, statusSeparator } from "../shared/status.cva.js";
6
6
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
7
- const Alert = ({ variant, color, text, isLoading = false, rightContent, hasSeparator, icon: Icon, className }) => {
7
+ //#region src/components/status/Alert/Alert.tsx
8
+ var Alert = ({ variant, color, text, isLoading = false, rightContent, hasSeparator, icon: Icon, className }) => {
8
9
  const alertCva = UIStyle.useCva("alert.cva", alert);
9
10
  const iconCva = UIStyle.useCva("status.iconCva", statusIcon);
10
11
  const separatorCva = UIStyle.useCva("status.separatorCva", statusSeparator);
@@ -42,4 +43,5 @@ const Alert = ({ variant, color, text, isLoading = false, rightContent, hasSepar
42
43
  })
43
44
  });
44
45
  };
46
+ //#endregion
45
47
  export { Alert };
@@ -1,5 +1,6 @@
1
1
  import { cva } from "class-variance-authority";
2
- const alert = cva("min-h-0 overflow-hidden rounded-alert-rounding-default p-0", {
2
+ //#region src/components/status/Alert/alert.cva.ts
3
+ var alert = cva("min-h-0 overflow-hidden rounded-alert-rounding-default p-0", {
3
4
  variants: {
4
5
  variant: {
5
6
  outlined: "border bg-elevation-fill-default-1 text-text-default-1",
@@ -59,4 +60,5 @@ const alert = cva("min-h-0 overflow-hidden rounded-alert-rounding-default p-0",
59
60
  color: "neutral"
60
61
  }
61
62
  });
63
+ //#endregion
62
64
  export { alert };
@@ -1,6 +1,7 @@
1
1
  import { loader, loaderWrapper } from "./loader.cva.js";
2
2
  import { jsx, jsxs } from "react/jsx-runtime";
3
- const Loader = ({ size, className, ...props }) => {
3
+ //#region src/components/status/Loader/Loader.tsx
4
+ var Loader = ({ size, className, ...props }) => {
4
5
  return /* @__PURE__ */ jsx("div", {
5
6
  className: loaderWrapper({
6
7
  size,
@@ -29,4 +30,5 @@ const Loader = ({ size, className, ...props }) => {
29
30
  })
30
31
  });
31
32
  };
33
+ //#endregion
32
34
  export { Loader };
@@ -1,16 +1,18 @@
1
1
  import { cva } from "class-variance-authority";
2
- const loaderWrapper = cva("flex items-center justify-center", {
2
+ //#region src/components/status/Loader/loader.cva.ts
3
+ var loaderWrapper = cva("flex items-center justify-center", {
3
4
  variants: { size: {
4
5
  default: "size-6",
5
6
  l: "size-16"
6
7
  } },
7
8
  defaultVariants: { size: "default" }
8
9
  });
9
- const loader = cva("animate-loader-spin", {
10
+ var loader = cva("animate-loader-spin", {
10
11
  variants: { size: {
11
12
  default: "size-3-5",
12
13
  l: "size-8"
13
14
  } },
14
15
  defaultVariants: { size: "default" }
15
16
  });
17
+ //#endregion
16
18
  export { loader, loaderWrapper };
@@ -1,18 +1,26 @@
1
1
  import { UIStyle } from "../../../config/uiStyle.context.js";
2
2
  import { Typography } from "../../text/Typography/Typography.js";
3
3
  import { Loader } from "../Loader/Loader.js";
4
+ import { UIConfig } from "../../../config/uiConfig.context.js";
4
5
  import { Button } from "../../buttons/Button/Button.js";
5
6
  import { statusIcon, statusSeparator } from "../shared/status.cva.js";
6
7
  import { buttonColorVariant, toast as toast$1, toastContainer, toastWrapper } from "./toast.cva.js";
7
8
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
8
9
  import { ToastContainer } from "react-toastify";
9
- const Toast = ({ text, isLoading = false, actions = [], icon: Icon, ...props }) => {
10
+ //#region src/components/status/Toast/Toast.tsx
11
+ var Toast = ({ text, isLoading = false, actions = [], icon: Icon, ...props }) => {
12
+ const uiConfig = UIConfig.useConfig();
13
+ const { variant = uiConfig.toast.variant, ...restProps } = props;
10
14
  const toastCva = UIStyle.useCva("toast.cva", toast$1);
11
15
  const buttonColor = UIStyle.useMapper("toast.buttonColor", buttonColorVariant);
12
16
  const iconCva = UIStyle.useCva("status.iconCva", statusIcon);
13
17
  const separatorCva = UIStyle.useCva("status.separatorCva", statusSeparator);
18
+ const variantProps = {
19
+ variant,
20
+ ...restProps
21
+ };
14
22
  return /* @__PURE__ */ jsxs("div", {
15
- className: toastCva({ ...props }),
23
+ className: toastCva(variantProps),
16
24
  children: [/* @__PURE__ */ jsxs("div", {
17
25
  className: "flex items-start gap-toast-gap-icon-to-text px-toast-side-default py-toast-height-content",
18
26
  children: [
@@ -20,17 +28,17 @@ const Toast = ({ text, isLoading = false, actions = [], icon: Icon, ...props })
20
28
  size: "default",
21
29
  className: "shrink-0"
22
30
  }),
23
- !isLoading && Icon && /* @__PURE__ */ jsx(Icon, { className: iconCva({ ...props }) }),
31
+ !isLoading && Icon && /* @__PURE__ */ jsx(Icon, { className: iconCva(variantProps) }),
24
32
  /* @__PURE__ */ jsx(Typography, {
25
33
  size: "label-2",
26
34
  children: text
27
35
  })
28
36
  ]
29
- }), actions.length > 0 && /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("div", { className: separatorCva({ ...props }) }), /* @__PURE__ */ jsx("div", {
37
+ }), actions.length > 0 && /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("div", { className: separatorCva(variantProps) }), /* @__PURE__ */ jsx("div", {
30
38
  className: "flex w-full shrink-0 flex-wrap items-center justify-end gap-toast-gap-action px-toast-side-default py-toast-height-actions-mobile md:w-auto md:justify-center md:py-toast-height-actions-desktop",
31
39
  children: actions.map(({ text: buttonText, onPress }) => /* @__PURE__ */ jsx(Button, {
32
40
  onPress,
33
- ...buttonColor({ ...props }),
41
+ ...buttonColor(variantProps),
34
42
  variant: "text",
35
43
  size: "none",
36
44
  width: "hug",
@@ -39,7 +47,7 @@ const Toast = ({ text, isLoading = false, actions = [], icon: Icon, ...props })
39
47
  })] })]
40
48
  });
41
49
  };
42
- const ToastContainer$1 = () => {
50
+ var ToastContainer$1 = () => {
43
51
  return /* @__PURE__ */ jsx(ToastContainer, {
44
52
  className: (params) => {
45
53
  return toastContainer({
@@ -54,4 +62,5 @@ const ToastContainer$1 = () => {
54
62
  hideProgressBar: true
55
63
  });
56
64
  };
65
+ //#endregion
57
66
  export { Toast, ToastContainer$1 as ToastContainer };