@kapiuara/ui 0.23.0 → 0.23.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 (366) hide show
  1. package/dist/components/chat/KapiChatDivider.js +1 -2
  2. package/dist/components/chat/KapiChatList.js +15 -16
  3. package/dist/components/chat/KapiChatThread.js +21 -22
  4. package/dist/components/chat/KapiComposer.js +23 -24
  5. package/dist/components/chat/KapiMessageBubble.js +5 -6
  6. package/dist/components/chat/KapiTypingIndicator.js +5 -6
  7. package/dist/components/chat/chatLogic.js +1 -2
  8. package/dist/components/data/KapiBarChart.js +22 -23
  9. package/dist/components/data/KapiDataTable.js +92 -93
  10. package/dist/components/data/KapiEventCalendar.js +96 -97
  11. package/dist/components/data/KapiHeatmap.js +21 -22
  12. package/dist/components/data/KapiLineChart.js +23 -24
  13. package/dist/components/data/KapiPagination.js +1 -2
  14. package/dist/components/data/KapiPaginationFooter.js +5 -6
  15. package/dist/components/data/KapiScatterChart.js +18 -19
  16. package/dist/components/data/KapiSheet.js +2 -3
  17. package/dist/components/data/KapiSparkline.js +1 -2
  18. package/dist/components/data/KapiTable.js +107 -108
  19. package/dist/components/data/KapiTableFilter.js +13 -14
  20. package/dist/components/data/KapiTableFooter.js +21 -22
  21. package/dist/components/data/KapiTableRow.js +10 -11
  22. package/dist/components/data/KapiTableToolbar.js +95 -96
  23. package/dist/components/data/barChartLogic.js +1 -2
  24. package/dist/components/data/chartFrame.js +13 -14
  25. package/dist/components/data/datasetSelectionLogic.js +1 -2
  26. package/dist/components/data/eventCalendarLogic.js +2 -3
  27. package/dist/components/data/heatmapLogic.js +1 -2
  28. package/dist/components/data/lineChartLogic.js +1 -2
  29. package/dist/components/data/rowClickLogic.js +2 -17
  30. package/dist/components/data/scatterLogic.js +1 -2
  31. package/dist/components/data/sparklineLogic.js +1 -2
  32. package/dist/components/data/tableCells.js +14 -15
  33. package/dist/components/data/tableHeaderMenu.js +1 -2
  34. package/dist/components/data/tableLabels.js +1 -2
  35. package/dist/components/data/tableLogic.js +0 -1
  36. package/dist/components/data/tablePaginationLogic.js +1 -2
  37. package/dist/components/data/tableResizeLogic.js +1 -2
  38. package/dist/components/data/tableSlots.js +1 -2
  39. package/dist/components/data/tableSpanLogic.js +1 -2
  40. package/dist/components/data/useColumnResize.js +23 -24
  41. package/dist/components/data/useRowKeyWarning.js +1 -2
  42. package/dist/components/data/useTableEdges.js +1 -2
  43. package/dist/components/data/useTableSelection.js +25 -26
  44. package/dist/components/display/KapiAnchor.js +7 -8
  45. package/dist/components/display/KapiAnnotation.js +15 -16
  46. package/dist/components/display/KapiAvatar.js +6 -7
  47. package/dist/components/display/KapiAvatarGroup.js +15 -16
  48. package/dist/components/display/KapiBadge.js +1 -2
  49. package/dist/components/display/KapiCodeBlock.js +14 -15
  50. package/dist/components/display/KapiComment.js +10 -11
  51. package/dist/components/display/KapiCommentComposer.js +13 -14
  52. package/dist/components/display/KapiDescriptionList.js +1 -2
  53. package/dist/components/display/KapiDiff.js +23 -24
  54. package/dist/components/display/KapiFileItem.js +13 -14
  55. package/dist/components/display/KapiFileViewer.js +17 -18
  56. package/dist/components/display/KapiHighlight.js +2 -3
  57. package/dist/components/display/KapiIconTile.js +2 -3
  58. package/dist/components/display/KapiStat.js +8 -9
  59. package/dist/components/display/KapiTag.js +6 -7
  60. package/dist/components/display/KapiText.js +5 -6
  61. package/dist/components/display/KapiTimeline.js +2 -3
  62. package/dist/components/display/KapiTitle.js +1 -2
  63. package/dist/components/display/KapiTruncate.js +5 -6
  64. package/dist/components/display/annotationLogic.js +1 -2
  65. package/dist/components/display/avatarGroupLogic.js +1 -2
  66. package/dist/components/display/avatarGroupSlots.js +1 -2
  67. package/dist/components/display/avatarLogic.js +1 -2
  68. package/dist/components/display/codeBlockSlots.js +1 -2
  69. package/dist/components/display/commentLogic.js +1 -2
  70. package/dist/components/display/diffLogic.js +1 -2
  71. package/dist/components/display/diffSlots.js +1 -2
  72. package/dist/components/display/fileItemLogic.js +1 -2
  73. package/dist/components/display/highlightLogic.js +1 -2
  74. package/dist/components/display/highlightSlots.js +1 -2
  75. package/dist/components/display/iconTileLogic.js +1 -2
  76. package/dist/components/display/statLogic.js +1 -2
  77. package/dist/components/display/tagLogic.js +1 -2
  78. package/dist/components/display/textLogic.js +1 -2
  79. package/dist/components/display/timelineLogic.js +1 -2
  80. package/dist/components/display/truncateLogic.js +1 -2
  81. package/dist/components/feedback/KapiAlert.js +6 -7
  82. package/dist/components/feedback/KapiBulkBar.js +5 -6
  83. package/dist/components/feedback/KapiCountdown.js +16 -17
  84. package/dist/components/feedback/KapiEmpty.js +2 -3
  85. package/dist/components/feedback/KapiFab.js +96 -97
  86. package/dist/components/feedback/KapiOfflineBanner.js +4 -5
  87. package/dist/components/feedback/KapiProgress.js +1 -2
  88. package/dist/components/feedback/KapiSkeleton.js +1 -2
  89. package/dist/components/feedback/KapiSpinner.js +5 -6
  90. package/dist/components/feedback/KapiToastContainer.js +28 -29
  91. package/dist/components/feedback/KapiTour.js +24 -25
  92. package/dist/components/feedback/KapiUnsavedBar.js +5 -6
  93. package/dist/components/feedback/alertSlots.js +1 -2
  94. package/dist/components/feedback/bulkBarLogic.js +1 -2
  95. package/dist/components/feedback/countdownLogic.js +1 -2
  96. package/dist/components/feedback/countdownSlots.js +1 -2
  97. package/dist/components/feedback/emptySlots.js +1 -2
  98. package/dist/components/feedback/fabLogic.js +1 -2
  99. package/dist/components/feedback/offlineBannerLogic.js +1 -2
  100. package/dist/components/feedback/progressLogic.js +1 -2
  101. package/dist/components/feedback/toastLayer.js +1 -2
  102. package/dist/components/feedback/toastStore.js +2 -3
  103. package/dist/components/feedback/tourLogic.js +1 -2
  104. package/dist/components/feedback/unsavedBarLogic.js +1 -2
  105. package/dist/components/inputs/KapiAutocomplete.js +23 -24
  106. package/dist/components/inputs/KapiButton.js +1 -2
  107. package/dist/components/inputs/KapiCalendar.js +12 -13
  108. package/dist/components/inputs/KapiCalendarGrid.js +15 -16
  109. package/dist/components/inputs/KapiCheckCard.js +4 -5
  110. package/dist/components/inputs/KapiCheckbox.js +1 -2
  111. package/dist/components/inputs/KapiChecklist.js +62 -63
  112. package/dist/components/inputs/KapiCopyButton.js +6 -7
  113. package/dist/components/inputs/KapiDatePicker.js +33 -34
  114. package/dist/components/inputs/KapiDateRangePicker.js +145 -146
  115. package/dist/components/inputs/KapiFacetedSearch.js +55 -56
  116. package/dist/components/inputs/KapiField.js +5 -6
  117. package/dist/components/inputs/KapiFileUpload.js +26 -27
  118. package/dist/components/inputs/KapiIconButton.js +1 -2
  119. package/dist/components/inputs/KapiInput.js +46 -47
  120. package/dist/components/inputs/KapiInputGroup.js +1 -2
  121. package/dist/components/inputs/KapiMaskedInput.js +50 -51
  122. package/dist/components/inputs/KapiNumberStepper.js +49 -50
  123. package/dist/components/inputs/KapiPinInput.js +9 -10
  124. package/dist/components/inputs/KapiPropsForm.js +43 -44
  125. package/dist/components/inputs/KapiRadio.js +1 -2
  126. package/dist/components/inputs/KapiRating.js +38 -39
  127. package/dist/components/inputs/KapiSearchChip.js +10 -11
  128. package/dist/components/inputs/KapiSegmented.js +65 -66
  129. package/dist/components/inputs/KapiSelect.js +198 -199
  130. package/dist/components/inputs/KapiSelectMenu.js +1 -2
  131. package/dist/components/inputs/KapiSlider.js +11 -12
  132. package/dist/components/inputs/KapiSwitch.js +6 -7
  133. package/dist/components/inputs/KapiTagInput.js +32 -33
  134. package/dist/components/inputs/KapiTextarea.js +22 -23
  135. package/dist/components/inputs/asyncSelectLogic.js +22 -23
  136. package/dist/components/inputs/autocompleteLogic.js +1 -2
  137. package/dist/components/inputs/checkControl.js +4 -5
  138. package/dist/components/inputs/checklistLogic.js +1 -2
  139. package/dist/components/inputs/copyLogic.js +1 -2
  140. package/dist/components/inputs/datePickerLogic.js +1 -2
  141. package/dist/components/inputs/dateRangeLogic.js +1 -2
  142. package/dist/components/inputs/facetedSearchLogic.js +1 -2
  143. package/dist/components/inputs/fieldLogic.js +1 -2
  144. package/dist/components/inputs/fileUploadLogic.js +1 -2
  145. package/dist/components/inputs/formBridgeLogic.js +1 -2
  146. package/dist/components/inputs/inputGroupLogic.js +1 -2
  147. package/dist/components/inputs/inputLogic.js +1 -2
  148. package/dist/components/inputs/maskLogic.js +0 -1
  149. package/dist/components/inputs/misuseWarnings.js +1 -2
  150. package/dist/components/inputs/numberStepLogic.js +1 -2
  151. package/dist/components/inputs/ownField.js +9 -10
  152. package/dist/components/inputs/pinInputLogic.js +1 -2
  153. package/dist/components/inputs/propsFormLogic.js +1 -2
  154. package/dist/components/inputs/ratingLogic.js +1 -2
  155. package/dist/components/inputs/searchChipLogic.js +1 -2
  156. package/dist/components/inputs/segmentedLogic.js +1 -2
  157. package/dist/components/inputs/selectKeyLogic.js +1 -2
  158. package/dist/components/inputs/selectLogic.js +1 -2
  159. package/dist/components/inputs/selectSlots.js +1 -2
  160. package/dist/components/inputs/sliderLogic.js +1 -2
  161. package/dist/components/inputs/tagInputLogic.js +1 -2
  162. package/dist/components/inputs/textareaLogic.js +1 -2
  163. package/dist/components/inputs/useCalendarFocus.js +1 -2
  164. package/dist/components/inputs/useDatePopSide.js +1 -2
  165. package/dist/components/inputs/useSelectCreate.js +1 -2
  166. package/dist/components/inputs/useSelectSource.js +11 -12
  167. package/dist/components/labelsLogic.js +1 -2
  168. package/dist/components/layout/KapiAccessCard.js +10 -11
  169. package/dist/components/layout/KapiAccountMenu.js +24 -25
  170. package/dist/components/layout/KapiBox.js +5 -6
  171. package/dist/components/layout/KapiCard.js +18 -19
  172. package/dist/components/layout/KapiCenter.js +1 -2
  173. package/dist/components/layout/KapiCluster.js +1 -2
  174. package/dist/components/layout/KapiCol.js +1 -2
  175. package/dist/components/layout/KapiCollapse.js +1 -2
  176. package/dist/components/layout/KapiContextSlot.js +98 -99
  177. package/dist/components/layout/KapiDivider.js +1 -2
  178. package/dist/components/layout/KapiGrid.js +9 -10
  179. package/dist/components/layout/KapiMasonry.js +1 -2
  180. package/dist/components/layout/KapiNotificationBell.js +53 -54
  181. package/dist/components/layout/KapiPageHeader.js +42 -43
  182. package/dist/components/layout/KapiPanelParts.js +43 -44
  183. package/dist/components/layout/KapiRail.js +103 -104
  184. package/dist/components/layout/KapiRailAccount.js +11 -12
  185. package/dist/components/layout/KapiRoot.js +33 -34
  186. package/dist/components/layout/KapiScrollArea.js +7 -8
  187. package/dist/components/layout/KapiShell.js +8 -9
  188. package/dist/components/layout/KapiStack.js +1 -2
  189. package/dist/components/layout/KapiThemeScript.js +1 -2
  190. package/dist/components/layout/accessCardLogic.js +1 -2
  191. package/dist/components/layout/cardLogic.js +1 -2
  192. package/dist/components/layout/cardSlots.js +1 -2
  193. package/dist/components/layout/gridSpanLogic.js +1 -2
  194. package/dist/components/layout/layoutPrimitives.js +1 -2
  195. package/dist/components/layout/masonryLogic.js +1 -2
  196. package/dist/components/layout/notificationBellLogic.js +1 -2
  197. package/dist/components/layout/pageHeaderLogic.js +1 -2
  198. package/dist/components/layout/pageHeaderSlots.js +1 -2
  199. package/dist/components/layout/railContext.js +1 -2
  200. package/dist/components/layout/railLogic.js +1 -2
  201. package/dist/components/layout/railSlots.js +1 -2
  202. package/dist/components/layout/reopenBus.js +1 -2
  203. package/dist/components/layout/shellSlots.js +1 -2
  204. package/dist/components/layout/useGridBreakpoint.js +1 -2
  205. package/dist/components/layout/useMasonrySpans.js +6 -7
  206. package/dist/components/layout/useRailOverflow.js +7 -8
  207. package/dist/components/locale/KapiLocaleProvider.js +1 -2
  208. package/dist/components/locale/linkLabels.js +1 -2
  209. package/dist/components/locale/localeLogic.js +1 -2
  210. package/dist/components/navigation/CtxSlidingList.js +7 -8
  211. package/dist/components/navigation/KapiAccordion.js +11 -12
  212. package/dist/components/navigation/KapiBreadcrumb.js +11 -12
  213. package/dist/components/navigation/KapiCollapsiblePanel.js +13 -14
  214. package/dist/components/navigation/KapiContextPanel.js +138 -139
  215. package/dist/components/navigation/KapiFilterChips.js +25 -22
  216. package/dist/components/navigation/KapiNavBadge.js +6 -7
  217. package/dist/components/navigation/KapiPanelGroup.js +34 -35
  218. package/dist/components/navigation/KapiSteps.js +41 -36
  219. package/dist/components/navigation/KapiTabs.js +40 -41
  220. package/dist/components/navigation/KapiToc.js +15 -16
  221. package/dist/components/navigation/KapiTree.js +126 -124
  222. package/dist/components/navigation/KapiWizard.js +12 -13
  223. package/dist/components/navigation/MiniNavItem.js +11 -12
  224. package/dist/components/navigation/accordionLogic.js +1 -2
  225. package/dist/components/navigation/activeItemLogic.js +1 -2
  226. package/dist/components/navigation/breadcrumbLogic.js +1 -2
  227. package/dist/components/navigation/contextPanelLogic.js +1 -2
  228. package/dist/components/navigation/filterChipsLogic.d.ts +9 -1
  229. package/dist/components/navigation/filterChipsLogic.js +2 -3
  230. package/dist/components/navigation/navBadgeLogic.js +1 -2
  231. package/dist/components/navigation/navLink.js +1 -2
  232. package/dist/components/navigation/navLinkLogic.js +1 -2
  233. package/dist/components/navigation/panelGroupLogic.js +1 -2
  234. package/dist/components/navigation/panelMini.js +0 -1
  235. package/dist/components/navigation/panelMiniLogic.js +1 -2
  236. package/dist/components/navigation/stepsLogic.js +1 -2
  237. package/dist/components/navigation/tabsLogic.js +1 -2
  238. package/dist/components/navigation/tocLogic.js +1 -2
  239. package/dist/components/navigation/tocSlots.js +1 -2
  240. package/dist/components/navigation/treeLogic.js +1 -2
  241. package/dist/components/navigation/wizardLogic.js +1 -2
  242. package/dist/components/overlays/KapiCanvasForm.js +5 -6
  243. package/dist/components/overlays/KapiCommandPalette.js +45 -45
  244. package/dist/components/overlays/KapiConfirm.js +9 -10
  245. package/dist/components/overlays/KapiContextMenu.js +16 -17
  246. package/dist/components/overlays/KapiDialogHost.js +50 -51
  247. package/dist/components/overlays/KapiDropdown.js +2 -3
  248. package/dist/components/overlays/KapiImageViewer.js +8 -9
  249. package/dist/components/overlays/KapiLoading.js +7 -8
  250. package/dist/components/overlays/KapiMenuButton.js +19 -20
  251. package/dist/components/overlays/KapiModal.js +58 -59
  252. package/dist/components/overlays/KapiOffcanvas.js +146 -147
  253. package/dist/components/overlays/KapiOffcanvasStack.js +18 -19
  254. package/dist/components/overlays/KapiPhotoView.js +21 -22
  255. package/dist/components/overlays/KapiPopover.js +12 -13
  256. package/dist/components/overlays/KapiShapeSheet.js +11 -12
  257. package/dist/components/overlays/KapiShortcutsHelp.js +18 -19
  258. package/dist/components/overlays/KapiSplitModal.js +20 -21
  259. package/dist/components/overlays/KapiTooltip.js +46 -47
  260. package/dist/components/overlays/KapiViewport.js +17 -18
  261. package/dist/components/overlays/canvasFormLogic.js +1 -2
  262. package/dist/components/overlays/commandPaletteLogic.js +1 -2
  263. package/dist/components/overlays/dialogStore.js +3 -4
  264. package/dist/components/overlays/dialogUtils.js +1 -2
  265. package/dist/components/overlays/exitPresenceLogic.js +1 -2
  266. package/dist/components/overlays/menuButtonLogic.js +1 -2
  267. package/dist/components/overlays/menuKeyboardLogic.js +1 -2
  268. package/dist/components/overlays/menuList.js +94 -95
  269. package/dist/components/overlays/modalSlots.js +1 -2
  270. package/dist/components/overlays/modalStack.js +1 -2
  271. package/dist/components/overlays/offcanvasCompanion.js +1 -2
  272. package/dist/components/overlays/offcanvasResize.js +0 -1
  273. package/dist/components/overlays/offcanvasSide.js +1 -2
  274. package/dist/components/overlays/offcanvasStack.js +1 -2
  275. package/dist/components/overlays/overlayPortal.js +1 -2
  276. package/dist/components/overlays/popoverLogic.js +1 -2
  277. package/dist/components/overlays/shortcutsHelpSlots.js +1 -2
  278. package/dist/components/overlays/splitModalLayout.js +1 -2
  279. package/dist/components/overlays/useExitPresence.js +11 -12
  280. package/dist/components/overlays/useNativeDialog.js +21 -22
  281. package/dist/components/overlays/viewportLogic.js +1 -2
  282. package/dist/components/renderSlot.js +1 -2
  283. package/dist/components/rootProps.js +1 -2
  284. package/dist/components/slotCatalog.js +33 -34
  285. package/dist/components/slotsLogic.js +1 -2
  286. package/dist/components/tone.js +1 -2
  287. package/dist/css/components/overlays/KapiViewport.css +1 -1
  288. package/dist/hooks/asyncResourceLogic.js +1 -2
  289. package/dist/hooks/breakpointOpenLogic.js +1 -2
  290. package/dist/hooks/colorLogic.js +1 -2
  291. package/dist/hooks/dateFormat.js +1 -2
  292. package/dist/hooks/densityLogic.js +1 -2
  293. package/dist/hooks/directionLogic.js +1 -2
  294. package/dist/hooks/downloadLogic.js +1 -2
  295. package/dist/hooks/elementSizeLogic.js +1 -2
  296. package/dist/hooks/fieldErrorsLogic.js +1 -2
  297. package/dist/hooks/focusLogic.js +2 -11
  298. package/dist/hooks/growOriginLogic.js +1 -2
  299. package/dist/hooks/hotkeyLogic.js +1 -2
  300. package/dist/hooks/hotkeyRegistry.js +1 -2
  301. package/dist/hooks/kapiRoot.js +2 -3
  302. package/dist/hooks/mergeRefs.js +1 -2
  303. package/dist/hooks/numberFormatLogic.js +1 -2
  304. package/dist/hooks/onlineStatusLogic.js +1 -2
  305. package/dist/hooks/ownerDocument.js +1 -2
  306. package/dist/hooks/persistentStateLogic.js +1 -2
  307. package/dist/hooks/portalRoot.js +1 -2
  308. package/dist/hooks/rafThrottle.js +1 -2
  309. package/dist/hooks/rangeSelectLogic.js +1 -2
  310. package/dist/hooks/recentLogic.js +1 -2
  311. package/dist/hooks/reducedMotion.js +8 -9
  312. package/dist/hooks/rightClick.js +10 -11
  313. package/dist/hooks/scrollCollapseLogic.js +1 -2
  314. package/dist/hooks/scrollEdgesLogic.js +1 -2
  315. package/dist/hooks/shallowStable.js +1 -2
  316. package/dist/hooks/slidingIndicatorLogic.js +1 -2
  317. package/dist/hooks/storageLogic.js +1 -2
  318. package/dist/hooks/themeColorsLogic.js +1 -2
  319. package/dist/hooks/themeContrastLogic.js +1 -2
  320. package/dist/hooks/themeDeriveLogic.js +0 -1
  321. package/dist/hooks/themeRadiiLogic.js +1 -2
  322. package/dist/hooks/themeScript.js +1 -2
  323. package/dist/hooks/toneFamilyLogic.js +1 -2
  324. package/dist/hooks/unsavedGuardLogic.js +1 -2
  325. package/dist/hooks/useAsyncLoader.js +1 -2
  326. package/dist/hooks/useAsyncResource.js +5 -6
  327. package/dist/hooks/useAsyncTasks.js +1 -2
  328. package/dist/hooks/useBottomBarInset.js +9 -10
  329. package/dist/hooks/useControllableState.js +1 -2
  330. package/dist/hooks/useDebouncedValue.js +1 -2
  331. package/dist/hooks/useDisclosure.js +1 -2
  332. package/dist/hooks/useDismiss.js +10 -11
  333. package/dist/hooks/useDragScroll.js +12 -13
  334. package/dist/hooks/useElementSize.js +1 -2
  335. package/dist/hooks/useFieldErrors.js +1 -2
  336. package/dist/hooks/useFocusReturn.js +1 -2
  337. package/dist/hooks/useFormReset.js +1 -2
  338. package/dist/hooks/useGlobalRightClick.js +1 -2
  339. package/dist/hooks/useGrowOrigin.js +1 -2
  340. package/dist/hooks/useHotkey.js +1 -2
  341. package/dist/hooks/useHydrated.js +1 -2
  342. package/dist/hooks/useKapiTheme.js +55 -56
  343. package/dist/hooks/useMediaQuery.js +1 -2
  344. package/dist/hooks/useObjectUrl.js +1 -2
  345. package/dist/hooks/useOnlineStatus.js +1 -2
  346. package/dist/hooks/useOutsidePress.js +1 -2
  347. package/dist/hooks/usePersistentState.js +9 -10
  348. package/dist/hooks/usePlacement.js +15 -16
  349. package/dist/hooks/useRangeSelect.js +2 -3
  350. package/dist/hooks/useRecent.js +6 -7
  351. package/dist/hooks/useScrollCollapse.js +1 -2
  352. package/dist/hooks/useScrollEdges.js +25 -26
  353. package/dist/hooks/useSlidingIndicator.js +19 -20
  354. package/dist/hooks/useSubmitDraft.js +1 -2
  355. package/dist/hooks/useToneFamilies.js +0 -1
  356. package/dist/hooks/useTypeahead.js +1 -2
  357. package/dist/hooks/useUnsavedGuard.js +5 -6
  358. package/dist/hooks/useVirtualList.js +1 -2
  359. package/dist/hooks/useWheelZoom.js +1 -2
  360. package/dist/hooks/viewportInsetLogic.js +1 -2
  361. package/dist/hooks/virtualListLogic.js +0 -1
  362. package/dist/hooks/wheelZoomLogic.js +1 -2
  363. package/dist/kapi.css +1 -1
  364. package/dist/kapi.layered.css +1 -1
  365. package/dist/logic.js +45 -45
  366. package/package.json +16 -16
@@ -2,14 +2,14 @@
2
2
  import "#kapi-css/components/inputs/inputsExtra.css";
3
3
  import { useToneLook as e } from "../../hooks/useToneFamilies.js";
4
4
  import { isFamilyTone as t } from "../tone.js";
5
- import { nativeFieldProps as n, resolveFieldClassName as r, resolveReadOnly as i } from "./fieldLogic.js";
6
- import { useOwnField as a } from "./ownField.js";
7
5
  /* empty css */
8
- import { useControllableState as o } from "../../hooks/useControllableState.js";
9
- import { clampToStep as s, percentOf as c } from "./sliderLogic.js";
6
+ import { clampToStep as n, percentOf as r } from "./sliderLogic.js";
7
+ import { useOwnField as i } from "./ownField.js";
8
+ import { useControllableState as a } from "../../hooks/useControllableState.js";
9
+ import { nativeFieldProps as o, resolveFieldClassName as s, resolveReadOnly as c } from "./fieldLogic.js";
10
10
  import "react";
11
11
  import { jsx as l, jsxs as u } from "react/jsx-runtime";
12
- //#region src/components/inputs/KapiSlider.tsx
12
+ // src/components/inputs/KapiSlider.tsx
13
13
  var d = ({ tone: e = "primary", disabled: n = !1, readOnly: r = !1, className: i = "" } = {}) => [
14
14
  "kapi-slider",
15
15
  t(e) ? "kapi-slider--family" : e !== "primary" && `kapi-slider--${e}`,
@@ -17,31 +17,31 @@ var d = ({ tone: e = "primary", disabled: n = !1, readOnly: r = !1, className: i
17
17
  r && "kapi-slider--readonly",
18
18
  i
19
19
  ].filter(Boolean).join(" "), f = ({ value: t, defaultValue: f, onChange: p, min: m = 0, max: h = 100, step: g = 1, tone: _, label: v, help: y, error: b, readOnly: x, showValue: S, formatValue: C, fieldClassName: w, wrapperClassName: T, className: E, style: D, disabled: O, id: k, ref: A, invalid: j, required: M, "aria-describedby": N, "aria-invalid": P, "aria-required": F, ...I }) => {
20
- let L = a({
20
+ let L = i({
21
21
  id: k,
22
22
  help: y,
23
23
  error: b,
24
24
  required: M,
25
25
  invalid: j,
26
26
  readOnly: x
27
- }), R = L.autoId, z = i(x, L.field), [B, V] = o(t, f ?? m, p), H = n(L.wraps || v == null ? L.field : null, {
27
+ }), R = L.autoId, z = c(x, L.field), [B, V] = a(t, f ?? m, p), H = o(L.wraps || v == null ? L.field : null, {
28
28
  id: k,
29
29
  describedBy: N,
30
30
  invalid: j,
31
31
  required: M,
32
32
  ariaInvalid: P,
33
33
  ariaRequired: F
34
- }), U = H.id ?? R, W = s(B, {
34
+ }), U = H.id ?? R, W = n(B, {
35
35
  min: m,
36
36
  max: h,
37
37
  step: g
38
- }), G = e("KapiSlider", _), K = { "--kapi-slider-pct": `${c(W, m, h)}%` }, q = v != null || S, J = C ? C(W) : void 0;
38
+ }), G = e("KapiSlider", _), K = { "--kapi-slider-pct": `${r(W, m, h)}%` }, q = v != null || S, J = C ? C(W) : void 0;
39
39
  return L.wrap(/* @__PURE__ */ u("div", {
40
40
  className: d({
41
41
  tone: G.tone,
42
42
  disabled: O,
43
43
  readOnly: z,
44
- className: r(w, T)
44
+ className: s(w, T)
45
45
  }),
46
46
  children: [q && /* @__PURE__ */ u("div", {
47
47
  className: "kapi-slider__head",
@@ -74,7 +74,7 @@ var d = ({ tone: e = "primary", disabled: n = !1, readOnly: r = !1, className: i
74
74
  ...K
75
75
  },
76
76
  onChange: (e) => {
77
- z || V(s(Number(e.target.value), {
77
+ z || V(n(Number(e.target.value), {
78
78
  min: m,
79
79
  max: h,
80
80
  step: g
@@ -83,5 +83,4 @@ var d = ({ tone: e = "primary", disabled: n = !1, readOnly: r = !1, className: i
83
83
  })]
84
84
  }));
85
85
  };
86
- //#endregion
87
86
  export { f as KapiSlider, d as sliderClasses };
@@ -1,13 +1,13 @@
1
1
  "use client";
2
2
  import "#kapi-css/components/inputs/checkControl.css";
3
- import { joinClasses as e } from "../rootProps.js";
3
+ import { useKapiField as e } from "./KapiField.js";
4
4
  import { nativeFieldProps as t } from "./fieldLogic.js";
5
- import { useKapiField as n } from "./KapiField.js";
5
+ import { joinClasses as n } from "../rootProps.js";
6
6
  /* empty css */
7
7
  import { Fragment as r, jsx as i, jsxs as a } from "react/jsx-runtime";
8
- //#region src/components/inputs/KapiSwitch.tsx
8
+ // src/components/inputs/KapiSwitch.tsx
9
9
  var o = ({ label: o, className: s, ref: c, invalid: l, id: u, required: d, "aria-describedby": f, "aria-invalid": p, "aria-required": m, ...h }) => {
10
- let g = t(n(), {
10
+ let g = t(e(), {
11
11
  id: u,
12
12
  describedBy: f,
13
13
  invalid: l,
@@ -23,15 +23,14 @@ var o = ({ label: o, className: s, ref: c, invalid: l, id: u, required: d, "aria
23
23
  required: d
24
24
  }), /* @__PURE__ */ i("span", { className: "kapi-switch__track" })] });
25
25
  return o == null ? /* @__PURE__ */ i("label", {
26
- className: e("kapi-switch", s),
26
+ className: n("kapi-switch", s),
27
27
  children: _
28
28
  }) : /* @__PURE__ */ a("label", {
29
- className: e("kapi-switchfield", s),
29
+ className: n("kapi-switchfield", s),
30
30
  children: [/* @__PURE__ */ i("span", {
31
31
  className: "kapi-switch",
32
32
  children: _
33
33
  }), o]
34
34
  });
35
35
  };
36
- //#endregion
37
36
  export { o as KapiSwitch };
@@ -1,25 +1,25 @@
1
1
  "use client";
2
2
  import "#kapi-css/components/inputs/KapiTagInput.css";
3
- import { joinClasses as e } from "../rootProps.js";
3
+ import { useControllableState as e } from "../../hooks/useControllableState.js";
4
4
  import { useMergedRefs as t } from "../../hooks/mergeRefs.js";
5
- import { useLabels as n } from "../locale/KapiLocaleProvider.js";
6
- import { assignRef as r, fieldControlProps as i, focusLeaves as a, joinIds as o, resolveReadOnly as ee } from "./fieldLogic.js";
7
- import { useOwnField as s } from "./ownField.js";
8
- import { useControllableState as te } from "../../hooks/useControllableState.js";
9
- import { useFormReset as ne } from "../../hooks/useFormReset.js";
5
+ import { useFormReset as n } from "../../hooks/useFormReset.js";
10
6
  /* empty css */
11
- import { addTags as re, hasSeparator as c, removeTagAt as l, spliceText as ie, splitDraft as ae, splitTags as u } from "./tagInputLogic.js";
12
- import { KapiTag as oe } from "../display/KapiTag.js";
7
+ import { useOwnField as r } from "./ownField.js";
8
+ import { assignRef as i, fieldControlProps as ee, focusLeaves as a, joinIds as te, resolveReadOnly as o } from "./fieldLogic.js";
9
+ import { addTags as ne, hasSeparator as s, removeTagAt as c, spliceText as re, splitDraft as ie, splitTags as l } from "./tagInputLogic.js";
10
+ import { KapiTag as ae } from "../display/KapiTag.js";
11
+ import { joinClasses as u } from "../rootProps.js";
12
+ import { useLabels as oe } from "../locale/KapiLocaleProvider.js";
13
13
  import { useCallback as d, useId as se, useRef as f, useState as p } from "react";
14
14
  import { jsx as m, jsxs as h } from "react/jsx-runtime";
15
- //#region src/components/inputs/KapiTagInput.tsx
15
+ // src/components/inputs/KapiTagInput.tsx
16
16
  var g = {
17
17
  remove: "Quitar",
18
18
  duplicate: "Ya está en la lista:",
19
19
  max: "Llegaste al máximo de"
20
- }, _ = ({ size: t = "md", invalid: n, disabled: r, readOnly: i, className: a }) => e("kapi-taginput", t !== "md" && `kapi-taginput--${t}`, n && "kapi-taginput--err", r && "kapi-taginput--disabled", i && "kapi-taginput--readonly", a);
21
- function v({ value: e, defaultValue: v = [], onChange: ce, validate: y, maxTags: b, allowDuplicates: le, caseSensitive: ue, placeholder: x, disabled: S = !1, size: C = "md", name: w, id: T, invalid: E, required: D, label: de, help: fe, error: pe, fieldClassName: O, readOnly: k, "aria-label": A, "aria-labelledby": j, "aria-describedby": M, onBlur: N, ref: P, labels: F, className: I, onClick: L, ...R }) {
22
- let z = n("tagInput", g, F), B = s({
20
+ }, _ = ({ size: e = "md", invalid: t, disabled: n, readOnly: r, className: i }) => u("kapi-taginput", e !== "md" && `kapi-taginput--${e}`, t && "kapi-taginput--err", n && "kapi-taginput--disabled", r && "kapi-taginput--readonly", i);
21
+ function v({ value: u, defaultValue: v = [], onChange: ce, validate: le, maxTags: y, allowDuplicates: ue, caseSensitive: b, placeholder: x, disabled: S = !1, size: C = "md", name: w, id: T, invalid: E, required: D, label: de, help: fe, error: pe, fieldClassName: O, readOnly: k, "aria-label": A, "aria-labelledby": j, "aria-describedby": M, onBlur: N, ref: P, labels: F, className: I, onClick: L, ...R }) {
22
+ let z = oe("tagInput", g, F), B = r({
23
23
  id: T,
24
24
  label: de,
25
25
  help: fe,
@@ -28,39 +28,39 @@ function v({ value: e, defaultValue: v = [], onChange: ce, validate: y, maxTags:
28
28
  invalid: E,
29
29
  readOnly: k,
30
30
  fieldClassName: O
31
- }), V = B.field, H = ee(k, V), U = se(), [W, G, , me] = te(e, v, ce), [K, q] = p(""), [J, Y] = p(null), X = f(null), he = t(X, ne(me)), Z = f(null), ge = d((e) => {
32
- Z.current = e, r(P, e);
33
- }, [P]), _e = (e) => e.reason === "invalid" ? e.message : e.reason === "duplicate" ? `${z.duplicate} ${e.tag}` : `${z.max} ${b}`, Q = (e, t = "") => {
34
- let { values: n, rejected: r } = re(W, e, {
35
- validate: y,
36
- maxTags: b,
37
- allowDuplicates: le,
38
- caseSensitive: ue
31
+ }), V = B.field, H = o(k, V), U = se(), [W, G, , me] = e(u, v, ce), [K, q] = p(""), [J, Y] = p(null), X = f(null), he = t(X, n(me)), Z = f(null), ge = d((e) => {
32
+ Z.current = e, i(P, e);
33
+ }, [P]), _e = (e) => e.reason === "invalid" ? e.message : e.reason === "duplicate" ? `${z.duplicate} ${e.tag}` : `${z.max} ${y}`, Q = (e, t = "") => {
34
+ let { values: n, rejected: r } = ne(W, e, {
35
+ validate: le,
36
+ maxTags: y,
37
+ allowDuplicates: ue,
38
+ caseSensitive: b
39
39
  });
40
40
  n.length !== W.length && G(n), Y(r[0] ? _e(r[0]) : null), q([...r.map((e) => e.tag), t].filter(Boolean).join(", "));
41
41
  }, ve = (e) => {
42
42
  let t = e.target.value;
43
- if (Y(null), !c(t)) {
43
+ if (Y(null), !s(t)) {
44
44
  q(t);
45
45
  return;
46
46
  }
47
- let { complete: n, tail: r } = ae(t);
47
+ let { complete: n, tail: r } = ie(t);
48
48
  Q(n, r);
49
49
  }, ye = (e) => {
50
- S || H || (e.key === "Enter" && K.trim() ? (e.preventDefault(), Q(u(K))) : e.key === "Backspace" && K === "" && W.length > 0 && (e.preventDefault(), Y(null), G(l(W, W.length - 1))));
50
+ S || H || (e.key === "Enter" && K.trim() ? (e.preventDefault(), Q(l(K))) : e.key === "Backspace" && K === "" && W.length > 0 && (e.preventDefault(), Y(null), G(c(W, W.length - 1))));
51
51
  }, be = (e) => {
52
52
  if (H) return;
53
53
  let t = e.clipboardData.getData("text");
54
- if (!c(t)) return;
54
+ if (!s(t)) return;
55
55
  e.preventDefault();
56
- let n = e.currentTarget, r = ie(K, n.selectionStart ?? K.length, n.selectionEnd ?? K.length, t);
57
- Q(u(r));
56
+ let n = e.currentTarget, r = re(K, n.selectionStart ?? K.length, n.selectionEnd ?? K.length, t);
57
+ Q(l(r));
58
58
  }, xe = (e) => {
59
- a(e.relatedTarget, X.current) && (K.trim() && !H && Q(u(K)), N?.(e));
59
+ a(e.relatedTarget, X.current) && (K.trim() && !H && Q(l(K)), N?.(e));
60
60
  }, Se = (e) => {
61
- L?.(e), !(e.defaultPrevented || S) && (e.target.closest("button, input") || Z.current?.focus());
61
+ L?.(e), e.defaultPrevented || S || e.target.closest("button, input") || Z.current?.focus();
62
62
  }, Ce = (e) => {
63
- Y(null), G(l(W, e)), Z.current?.focus();
63
+ Y(null), G(c(W, e)), Z.current?.focus();
64
64
  }, $ = J !== null || (E ?? V?.invalid ?? !1);
65
65
  return B.wrap(/* @__PURE__ */ h("div", {
66
66
  ...R,
@@ -81,7 +81,7 @@ function v({ value: e, defaultValue: v = [], onChange: ce, validate: y, maxTags:
81
81
  className: "kapi-taginput__tags",
82
82
  children: W.map((e, t) => /* @__PURE__ */ m("li", {
83
83
  className: "kapi-taginput__item",
84
- children: /* @__PURE__ */ m(oe, {
84
+ children: /* @__PURE__ */ m(ae, {
85
85
  tone: "primary",
86
86
  size: C === "sm" ? "sm" : "md",
87
87
  onRemove: S || H ? void 0 : () => Ce(t),
@@ -93,9 +93,9 @@ function v({ value: e, defaultValue: v = [], onChange: ce, validate: y, maxTags:
93
93
  ref: ge,
94
94
  type: "text",
95
95
  className: "kapi-taginput__input",
96
- ...i(V, {
96
+ ...ee(V, {
97
97
  id: T,
98
- describedBy: o(J !== null && U, M),
98
+ describedBy: te(J !== null && U, M),
99
99
  invalid: $,
100
100
  required: D
101
101
  }),
@@ -125,5 +125,4 @@ function v({ value: e, defaultValue: v = [], onChange: ce, validate: y, maxTags:
125
125
  ]
126
126
  }));
127
127
  }
128
- //#endregion
129
128
  export { g as DEFAULT_TAG_INPUT_LABELS, v as KapiTagInput, _ as tagInputClasses };
@@ -1,46 +1,46 @@
1
1
  "use client";
2
2
  import "#kapi-css/components/inputs/inputsExtra.css";
3
- import { computedStyleOf as e } from "../../hooks/ownerDocument.js";
4
- import { fieldControlProps as t, joinIds as n, resolveFieldMessage as r } from "./fieldLogic.js";
5
- import { useOwnField as i } from "./ownField.js";
6
3
  /* empty css */
7
- import { inputClasses as a } from "./KapiInput.js";
8
- import { rafThrottle as o } from "../../hooks/rafThrottle.js";
9
- import { autosizeHeight as s, rowsToHeight as c } from "./textareaLogic.js";
4
+ import { useOwnField as e } from "./ownField.js";
5
+ import { fieldControlProps as t, joinIds as n, resolveFieldMessage as r } from "./fieldLogic.js";
6
+ import { inputClasses as i } from "./KapiInput.js";
7
+ import { autosizeHeight as a, rowsToHeight as o } from "./textareaLogic.js";
8
+ import { computedStyleOf as s } from "../../hooks/ownerDocument.js";
9
+ import { rafThrottle as c } from "../../hooks/rafThrottle.js";
10
10
  import { useCallback as l, useEffect as u, useLayoutEffect as d, useRef as f } from "react";
11
11
  import { jsx as p } from "react/jsx-runtime";
12
- //#region src/components/inputs/KapiTextarea.tsx
13
- var m = ({ status: e, autosize: t = !1, className: n = "" } = {}) => a({
12
+ // src/components/inputs/KapiTextarea.tsx
13
+ var m = ({ status: e, autosize: t = !1, className: n = "" } = {}) => i({
14
14
  status: e,
15
15
  className: [
16
16
  "kapi-textarea",
17
17
  t && "kapi-textarea--auto",
18
18
  n
19
19
  ].filter(Boolean).join(" ")
20
- }), h = ({ invalid: a, status: h, label: g, required: _, help: v, error: y, fieldClassName: b, autosize: x, maxRows: S, className: C, id: w, rows: T = 3, onInput: E, ref: D, ...O }) => {
21
- let { invalid: k, status: A } = r(y, v, a, h), j = i({
20
+ }), h = ({ invalid: i, status: h, label: g, required: _, help: v, error: y, fieldClassName: b, autosize: x, maxRows: S, className: C, id: w, rows: T = 3, onInput: E, ref: D, ...O }) => {
21
+ let { invalid: k, status: A } = r(y, v, i, h), j = e({
22
22
  id: w,
23
23
  label: g,
24
24
  help: v,
25
25
  error: y,
26
26
  required: _,
27
- invalid: a,
27
+ invalid: i,
28
28
  status: h,
29
29
  fieldClassName: b
30
30
  }), { controlId: M, helpId: N } = j, P = f(null), F = l((e) => {
31
31
  P.current = e, typeof D == "function" ? D(e) : D && (D.current = e);
32
32
  }, [D]), I = f(null), L = l(() => {
33
- let t = P.current;
34
- if (!t || !x) return;
35
- let n = e(t), r = (e) => parseFloat(e) || 0;
36
- I.current = Math.max(0, t.clientWidth - r(n.paddingLeft) - r(n.paddingRight));
37
- let i = r(n.lineHeight) || r(n.fontSize) * 1.5, a = r(n.borderTopWidth) + r(n.borderBottomWidth), o = r(n.paddingTop) + r(n.paddingBottom) + a;
38
- t.style.height = "auto";
39
- let { height: l, overflowing: u } = s(t.scrollHeight + a, {
40
- minHeight: c(T, i, o),
41
- maxHeight: S ? c(S, i, o) : void 0
33
+ let e = P.current;
34
+ if (!e || !x) return;
35
+ let t = s(e), n = (e) => parseFloat(e) || 0;
36
+ I.current = Math.max(0, e.clientWidth - n(t.paddingLeft) - n(t.paddingRight));
37
+ let r = n(t.lineHeight) || n(t.fontSize) * 1.5, i = n(t.borderTopWidth) + n(t.borderBottomWidth), c = n(t.paddingTop) + n(t.paddingBottom) + i;
38
+ e.style.height = "auto";
39
+ let { height: l, overflowing: u } = a(e.scrollHeight + i, {
40
+ minHeight: o(T, r, c),
41
+ maxHeight: S ? o(S, r, c) : void 0
42
42
  });
43
- t.style.height = `${l}px`, t.style.overflowY = u ? "auto" : "hidden";
43
+ e.style.height = `${l}px`, e.style.overflowY = u ? "auto" : "hidden";
44
44
  }, [
45
45
  x,
46
46
  S,
@@ -53,7 +53,7 @@ var m = ({ status: e, autosize: t = !1, className: n = "" } = {}) => a({
53
53
  z.current = L, u(() => {
54
54
  let e = P.current;
55
55
  if (!e || !x || typeof ResizeObserver > "u") return;
56
- let t = null, n = o(() => z.current()), r = new ResizeObserver((e) => {
56
+ let t = null, n = c(() => z.current()), r = new ResizeObserver((e) => {
57
57
  let r = e[e.length - 1]?.contentRect.width;
58
58
  if (r === void 0 || r === t) return;
59
59
  let i = t === null;
@@ -86,5 +86,4 @@ var m = ({ status: e, autosize: t = !1, className: n = "" } = {}) => a({
86
86
  });
87
87
  return j.wrap(V);
88
88
  };
89
- //#endregion
90
89
  export { h as KapiTextarea, m as textareaClasses };
@@ -1,47 +1,46 @@
1
1
  import { normalizeText as e } from "../overlays/menuKeyboardLogic.js";
2
- import { flattenOptions as t, normalizeValue as n, toggleValue as r } from "./selectLogic.js";
3
- import { createRequestTracker as i } from "./autocompleteLogic.js";
4
- //#region src/components/inputs/asyncSelectLogic.ts
5
- var a = (e, t) => e === t || e.label === t.label && e.disabled === t.disabled && e.data === t.data, o = (e, n) => {
2
+ import { createRequestTracker as t } from "./autocompleteLogic.js";
3
+ import { flattenOptions as n, normalizeValue as r, toggleValue as i } from "./selectLogic.js";
4
+ // src/components/inputs/asyncSelectLogic.ts
5
+ var a = (e, t) => e === t || e.label === t.label && e.disabled === t.disabled && e.data === t.data, o = (e, t) => {
6
6
  let r = null;
7
- for (let i of t(n)) {
7
+ for (let i of n(t)) {
8
8
  let t = (r ?? e).get(i.value);
9
9
  t && a(t, i) || (r ??= new Map(e), r.set(i.value, i));
10
10
  }
11
11
  return r ?? e;
12
12
  }, s = (e, t) => {
13
- let r = [];
14
- for (let i of n(t, !0)) {
13
+ let n = [];
14
+ for (let i of r(t, !0)) {
15
15
  let t = e.get(i);
16
- t && r.push(t);
16
+ t && n.push(t);
17
17
  }
18
- return r;
19
- }, c = (n, r) => {
18
+ return n;
19
+ }, c = (t, r) => {
20
20
  let i = e(r.trim());
21
- return i ? !t(n).some((t) => e(t.label.trim()) === i) : !1;
22
- }, l = (e, t, i) => i && n(e, !0).includes(t) ? [...n(e, !0)] : r(e, t, i), u = () => {
23
- let e = i(), t = null;
21
+ return i ? !n(t).some((t) => e(t.label.trim()) === i) : !1;
22
+ }, l = (e, t, n) => n && r(e, !0).includes(t) ? [...r(e, !0)] : i(e, t, n), u = () => {
23
+ let e = t(), n = null;
24
24
  return {
25
25
  start: () => {
26
- t?.abort();
27
- let n = new AbortController();
28
- t = n;
26
+ n?.abort();
27
+ let t = new AbortController();
28
+ n = t;
29
29
  let r = e.next();
30
30
  return {
31
- signal: n.signal,
32
- isCurrent: () => e.isCurrent(r) && !n.signal.aborted
31
+ signal: t.signal,
32
+ isCurrent: () => e.isCurrent(r) && !t.signal.aborted
33
33
  };
34
34
  },
35
35
  cancel: () => {
36
- t?.abort(), t = null, e.cancel();
36
+ n?.abort(), n = null, e.cancel();
37
37
  }
38
38
  };
39
- }, d = "\0kapisel-create", f = (e) => e.value === d, p = (e, n, r, i) => {
40
- let a = t(e);
41
- return r && c(e, n) ? [...a, {
39
+ }, d = "\0kapisel-create", f = (e) => e.value === d, p = (e, t, r, i) => {
40
+ let a = n(e);
41
+ return r && c(e, t) ? [...a, {
42
42
  value: d,
43
43
  label: i
44
44
  }] : a;
45
45
  };
46
- //#endregion
47
46
  export { d as CREATE_VALUE, u as createLoadSequencer, f as isCreateRow, p as menuItems, o as mergeKnownOptions, s as selectedFromKnown, c as showCreateOption, l as withCreated };
@@ -1,4 +1,4 @@
1
- //#region src/components/inputs/autocompleteLogic.ts
1
+ // src/components/inputs/autocompleteLogic.ts
2
2
  var e = (e) => e.normalize("NFD").replace(/[̀-ͯ]/g, "").toLowerCase(), t = (t, n, r, i = Infinity) => {
3
3
  let a = e(n.trim()), o = i > 0 ? i : Infinity;
4
4
  if (!a) return t.slice(0, o);
@@ -63,5 +63,4 @@ var e = (e) => e.normalize("NFD").replace(/[̀-ͯ]/g, "").toLowerCase(), t = (t,
63
63
  }
64
64
  return String(e);
65
65
  };
66
- //#endregion
67
66
  export { s as AUTOCOMPLETE_MENU_PLACEMENT, n as clampActiveIndex, o as createRequestTracker, c as defaultGetLabel, t as filterOptions, i as highlightParts, a as isLatestRequest, e as normalizeText, r as shouldOpen };
@@ -1,13 +1,13 @@
1
1
  "use client";
2
2
  import "#kapi-css/components/inputs/checkControl.css";
3
- import { nativeFieldProps as e } from "./fieldLogic.js";
4
- import { useKapiField as t } from "./KapiField.js";
3
+ import { useKapiField as e } from "./KapiField.js";
4
+ import { nativeFieldProps as t } from "./fieldLogic.js";
5
5
  /* empty css */
6
6
  import { jsx as n, jsxs as r } from "react/jsx-runtime";
7
- //#region src/components/inputs/checkControl.tsx
7
+ // src/components/inputs/checkControl.tsx
8
8
  var i = (e = "") => ["kapi-check", e].filter(Boolean).join(" "), a = (a, o) => {
9
9
  let s = ({ label: o, className: s, ref: c, invalid: l, id: u, required: d, "aria-describedby": f, "aria-invalid": p, "aria-required": m, ...h }) => {
10
- let g = e(t(), {
10
+ let g = t(e(), {
11
11
  id: u,
12
12
  describedBy: f,
13
13
  invalid: l,
@@ -29,5 +29,4 @@ var i = (e = "") => ["kapi-check", e].filter(Boolean).join(" "), a = (a, o) => {
29
29
  };
30
30
  return s.displayName = o, s;
31
31
  };
32
- //#endregion
33
32
  export { i as checkClasses, a as createCheckControl };
@@ -1,5 +1,5 @@
1
1
  import { normalizeText as e } from "../overlays/menuKeyboardLogic.js";
2
- //#region src/components/inputs/checklistLogic.ts
2
+ // src/components/inputs/checklistLogic.ts
3
3
  var t = (e) => e.text === void 0 ? typeof e.label == "string" || typeof e.label == "number" ? String(e.label) : "" : e.text, n = (n, r) => {
4
4
  let i = e(r.trim());
5
5
  return i ? n.filter((n) => e(t(n)).includes(i)) : [...n];
@@ -12,5 +12,4 @@ var t = (e) => e.text === void 0 ? typeof e.label == "string" || typeof e.label
12
12
  let n = e.filter((e) => !e.disabled), r = n.filter((e) => t.has(e.id)).length;
13
13
  return r === 0 ? "none" : r === n.length ? "all" : "some";
14
14
  };
15
- //#endregion
16
15
  export { a as checklistBulkState, t as checklistItemText, n as filterChecklistItems, r as orderedChecklistValue, i as setChecklistItems };
@@ -1,5 +1,5 @@
1
1
  import { winOf as e } from "../../hooks/ownerDocument.js";
2
- //#region src/components/inputs/copyLogic.ts
2
+ // src/components/inputs/copyLogic.ts
3
3
  var t = async (t, n) => {
4
4
  try {
5
5
  let r = (n ? e(n) : globalThis.window)?.navigator?.clipboard;
@@ -8,5 +8,4 @@ var t = async (t, n) => {
8
8
  return !1;
9
9
  }
10
10
  };
11
- //#endregion
12
11
  export { t as copyText };
@@ -1,5 +1,5 @@
1
1
  import "../locale/localeLogic.js";
2
- //#region src/components/inputs/datePickerLogic.ts
2
+ // src/components/inputs/datePickerLogic.ts
3
3
  var e = [
4
4
  "enero",
5
5
  "febrero",
@@ -239,5 +239,4 @@ var e = [
239
239
  }
240
240
  return u;
241
241
  }, V = ({ variant: e, icon: t, chipLabel: n, label: r }) => e === void 0 ? !!t || !!n || !!r : e === "chip";
242
- //#endregion
243
242
  export { r as DEFAULT_CALENDAR_LABELS, A as DEFAULT_DATE_PATTERN, e as MESES, t as WEEKDAYS, n as WEEKDAY_NAMES, k as buildDays, w as calendarDayLabel, l as calendarNames, T as calendarRows, m as chipFieldSize, P as datePatternFor, I as formDateValue, F as formatValue, h as hasCalendar, g as hasTime, u as localizedCalendarLabels, L as maskInput, p as minuteOptions, d as monthTitle, O as moveCalendarFocus, f as pad, B as parseText, V as pickerIsChip, _ as sameDay, v as sameMonth, R as validDateOrNull, x as weekdayOrder };
@@ -1,5 +1,5 @@
1
1
  import { DEFAULT_DATE_PATTERN as e, formatValue as t, maskInput as n, parseText as r, sameDay as i, validDateOrNull as a } from "./datePickerLogic.js";
2
- //#region src/components/inputs/dateRangeLogic.ts
2
+ // src/components/inputs/dateRangeLogic.ts
3
3
  var o = {
4
4
  from: null,
5
5
  to: null
@@ -72,5 +72,4 @@ var o = {
72
72
  };
73
73
  }
74
74
  };
75
- //#endregion
76
75
  export { o as EMPTY_RANGE, s as RANGE_SEPARATOR, x as formatRange, g as isCompleteRange, S as maskRangeInput, y as openEndedDay, w as parseRangeText, v as pickRangeDay, b as rangeDayState, p as rangePlaceholder, _ as sameRange, C as validRange };
@@ -1,5 +1,5 @@
1
1
  import { normalizeFilterText as e } from "../data/tableLogic.js";
2
- //#region src/components/inputs/facetedSearchLogic.ts
2
+ // src/components/inputs/facetedSearchLogic.ts
3
3
  var t = (e) => e.operators && e.operators.length > 0 ? e.operators : ["eq"], n = (e, t) => {
4
4
  let n = e.operator && e.operator !== "eq" && t ? `${e.label} ${t}` : e.label;
5
5
  return e.value !== void 0 && e.value.trim() !== "" ? `${n}: ${e.value}` : n;
@@ -55,5 +55,4 @@ var o = (e) => `${e.getFullYear()}-${String(e.getMonth() + 1).padStart(2, "0")}-
55
55
  to: t[2]
56
56
  } : null;
57
57
  }, l = (e) => e.count === void 0 ? e.label : `${e.label}, ${e.count}`, u = (e) => e?.kind === "date" || e?.kind === "dateRange";
58
- //#endregion
59
58
  export { n as facetChipText, a as facetKeyAction, i as facetMenuItems, t as facetOperators, l as facetOptionName, u as isDateFacet, c as parseDateRangeValue, s as toDateRangeValue, o as toDateValue };
@@ -1,5 +1,5 @@
1
1
  import { present as e } from "./inputLogic.js";
2
- //#region src/components/inputs/fieldLogic.ts
2
+ // src/components/inputs/fieldLogic.ts
3
3
  var t = ({ controlId: e, labelId: t, helpId: n, required: r, status: i, readOnly: a }) => ({
4
4
  controlId: e,
5
5
  labelId: t,
@@ -58,5 +58,4 @@ var t = ({ controlId: e, labelId: t, helpId: n, required: r, status: i, readOnly
58
58
  message: n,
59
59
  ...l(r, i)
60
60
  }, d = (e, t) => e ?? t;
61
- //#endregion
62
61
  export { c as assignRef, t as fieldContextValue, a as fieldControlProps, i as fieldIds, s as focusLeaves, r as joinIds, o as nativeFieldProps, d as resolveFieldClassName, u as resolveFieldMessage, n as resolveReadOnly, l as resolveValidation };
@@ -1,9 +1,8 @@
1
- //#region src/components/inputs/fileUploadLogic.ts
1
+ // src/components/inputs/fileUploadLogic.ts
2
2
  var e = (e) => `${e > 0 ? Math.max(1, Math.round(e / 1024)) : 0} KB`, t = (e, t) => {
3
3
  let n = (t ?? "").split(",").map((e) => e.trim().toLowerCase()).filter(Boolean);
4
4
  if (n.length === 0) return !0;
5
5
  let r = e.name.toLowerCase(), i = e.type.toLowerCase();
6
6
  return n.some((e) => e.startsWith(".") ? r.endsWith(e) : e.endsWith("/*") ? i.startsWith(e.slice(0, -1)) : i === e);
7
7
  }, n = (e, t, n) => n ? [...e, ...t] : t.slice(0, 1), r = (e, t) => e.filter((e, n) => n !== t), i = (e) => e === "Enter" || e === " " || e === "Spacebar";
8
- //#endregion
9
8
  export { e as formatFileSize, i as isActivationKey, t as matchesAccept, n as mergeFiles, r as removeFileAt };
@@ -1,5 +1,5 @@
1
1
  import { present as e } from "./inputLogic.js";
2
- //#region src/components/inputs/formBridgeLogic.ts
2
+ // src/components/inputs/formBridgeLogic.ts
3
3
  var t = (e, t) => t === void 0 ? {} : { [e]: t };
4
4
  function n(n, r = "event") {
5
5
  let i = n.onChange, a = {
@@ -21,5 +21,4 @@ function n(n, r = "event") {
21
21
  ...t("error", n.error)
22
22
  };
23
23
  }
24
- //#endregion
25
24
  export { n as bindField };
@@ -1,9 +1,8 @@
1
- //#region src/components/inputs/inputGroupLogic.ts
1
+ // src/components/inputs/inputGroupLogic.ts
2
2
  var e = ({ size: e = "md", status: t, className: n = "" } = {}) => [
3
3
  "kapi-inputgroup",
4
4
  e !== "md" && `kapi-inputgroup--${e}`,
5
5
  t && `kapi-inputgroup--${t}`,
6
6
  n
7
7
  ].filter(Boolean).join(" "), t = (e = "") => ["kapi-inputgroup__addon", e].filter(Boolean).join(" "), n = (e, t) => e ?? t, r = ({ id: e, fieldControlId: t, autoId: n, inGroup: r }) => e ?? (r ? void 0 : t) ?? n;
8
- //#endregion
9
8
  export { t as inputGroupAddonClasses, e as inputGroupClasses, n as resolveGroupSize, r as selectControlId };
@@ -1,4 +1,4 @@
1
- //#region src/components/inputs/inputLogic.ts
1
+ // src/components/inputs/inputLogic.ts
2
2
  var e = (e) => e != null && typeof e != "boolean" && e !== "", t = ({ startIcon: t, endIcon: n, prefix: r, suffix: i, clearable: a, reveal: o, shortcut: s }) => e(t) || e(n) || e(r) || e(i) || !!a || !!o || !!s, n = (e) => e == null ? !1 : Array.isArray(e) ? e.length > 0 : String(e) !== "", r = ({ size: e = "md", status: t, disabled: n = !1, className: r = "" } = {}) => [
3
3
  "kapi-inputbox",
4
4
  e !== "md" && `kapi-inputbox--${e}`,
@@ -6,5 +6,4 @@ var e = (e) => e != null && typeof e != "boolean" && e !== "", t = ({ startIcon:
6
6
  n && "is-disabled",
7
7
  r
8
8
  ].filter(Boolean).join(" "), i = ({ reveal: e, revealed: t, disabled: n }) => e && t && !n ? "text" : void 0;
9
- //#endregion
10
9
  export { t as hasAdornments, n as hasValue, r as inputBoxClasses, e as present, i as tipoDeCampo };
@@ -55,5 +55,4 @@ var e = [
55
55
  for (let r = 0; r < e.length; r += 1) if (f(e[r]) && (n += 1, n === t)) return r + 1;
56
56
  return e.length;
57
57
  };
58
- //#endregion
59
58
  export { m as caretForSignificant, p as countSignificant, a as cuitCheckDigit, i as formatCuit, d as formatCurrency, r as formatDni, o as isValidCuit, l as maskCurrencyInput, t as onlyDigits, u as parseCurrency };
@@ -1,6 +1,6 @@
1
1
  "use client";
2
2
  import { useEffect as e, useRef as t } from "react";
3
- //#region src/components/inputs/misuseWarnings.ts
3
+ // src/components/inputs/misuseWarnings.ts
4
4
  var n = (e) => {
5
5
  let t = /* @__PURE__ */ new Set();
6
6
  for (let n of e) {
@@ -32,5 +32,4 @@ var n = (e) => {
32
32
  l
33
33
  ]);
34
34
  };
35
- //#endregion
36
35
  export { n as firstDuplicate, i as isMuted, r as useDuplicateValueWarning, a as useMutedControlWarning };
@@ -1,4 +1,4 @@
1
- //#region src/components/inputs/numberStepLogic.ts
1
+ // src/components/inputs/numberStepLogic.ts
2
2
  var e = (e) => {
3
3
  let t = String(e), n = /e-(\d+)$/i.exec(t);
4
4
  if (n) {
@@ -26,5 +26,4 @@ var e = (e) => {
26
26
  max: a
27
27
  });
28
28
  }, o = (e, { min: t } = {}) => t === void 0 || e > t, s = (e, { max: t } = {}) => t === void 0 || e < t;
29
- //#endregion
30
29
  export { o as canDecrement, s as canIncrement, i as clampNumber, n as parseTypedNumber, r as snapToStep, a as stepValue };
@@ -1,15 +1,15 @@
1
1
  "use client";
2
- import { present as e } from "./inputLogic.js";
3
- import { fieldContextValue as t, resolveFieldMessage as n } from "./fieldLogic.js";
4
- import { KapiField as r, useKapiField as i } from "./KapiField.js";
2
+ import { KapiField as e, useKapiField as t } from "./KapiField.js";
3
+ import { fieldContextValue as n, resolveFieldMessage as r } from "./fieldLogic.js";
4
+ import { present as i } from "./inputLogic.js";
5
5
  import { useId as a } from "react";
6
6
  import { jsx as o } from "react/jsx-runtime";
7
- //#region src/components/inputs/ownField.tsx
7
+ // src/components/inputs/ownField.tsx
8
8
  var s = ({ id: s, label: c, help: l, error: u, required: d, invalid: f, status: p, readOnly: m, fieldClassName: h }) => {
9
- let g = i(), _ = a(), { message: v, status: y } = n(u, l, f, p), b = c != null || e(v), x = s ?? (b ? _ : g?.controlId), S = e(v) ? `${x}-help` : void 0;
9
+ let g = t(), _ = a(), { message: v, status: y } = r(u, l, f, p), b = c != null || i(v), x = s ?? (b ? _ : g?.controlId), S = i(v) ? `${x}-help` : void 0;
10
10
  return {
11
11
  wraps: b,
12
- field: b ? t({
12
+ field: b ? n({
13
13
  controlId: x ?? _,
14
14
  labelId: c == null ? void 0 : `${x}-label`,
15
15
  helpId: S,
@@ -21,7 +21,7 @@ var s = ({ id: s, label: c, help: l, error: u, required: d, invalid: f, status:
21
21
  controlId: x,
22
22
  autoId: _,
23
23
  helpId: S,
24
- wrap: (e) => b ? /* @__PURE__ */ o(r, {
24
+ wrap: (t) => b ? /* @__PURE__ */ o(e, {
25
25
  label: c,
26
26
  htmlFor: x,
27
27
  required: d,
@@ -30,9 +30,8 @@ var s = ({ id: s, label: c, help: l, error: u, required: d, invalid: f, status:
30
30
  status: y,
31
31
  readOnly: m,
32
32
  className: h,
33
- children: e
34
- }) : e
33
+ children: t
34
+ }) : t
35
35
  };
36
36
  };
37
- //#endregion
38
37
  export { s as useOwnField };