@rio-cloud/uikit-mcp 1.1.9 → 1.1.11

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 (211) hide show
  1. package/README.md +2 -1
  2. package/dist/doc-metadata.json +334 -94
  3. package/dist/docs/components/accentBar.md +110 -116
  4. package/dist/docs/components/activity.md +1 -1
  5. package/dist/docs/components/analyticsAnalysisOverlay.md +630 -0
  6. package/dist/docs/components/animatedNumber.md +2 -2
  7. package/dist/docs/components/animatedTextReveal.md +53 -55
  8. package/dist/docs/components/animations.md +21 -21
  9. package/dist/docs/components/appHeader.md +27 -38
  10. package/dist/docs/components/appLayout.md +23 -77
  11. package/dist/docs/components/appNavigationBar.md +1 -1
  12. package/dist/docs/components/areaCharts.md +57 -61
  13. package/dist/docs/components/aspectRatioPlaceholder.md +1 -1
  14. package/dist/docs/components/assetTree.md +429 -342
  15. package/dist/docs/components/autosuggests.md +1 -1
  16. package/dist/docs/components/avatar.md +1 -1
  17. package/dist/docs/components/banner.md +2 -2
  18. package/dist/docs/components/barCharts.md +530 -414
  19. package/dist/docs/components/barList.md +10 -10
  20. package/dist/docs/components/basicMap.md +104 -39
  21. package/dist/docs/components/bottomSheet.md +2 -2
  22. package/dist/docs/components/button.md +8 -2
  23. package/dist/docs/components/buttonToolbar.md +1 -1
  24. package/dist/docs/components/calendarStripe.md +59 -63
  25. package/dist/docs/components/card.md +1 -1
  26. package/dist/docs/components/carousel.md +1 -1
  27. package/dist/docs/components/chartColors.md +1 -1
  28. package/dist/docs/components/chartsGettingStarted.md +1 -1
  29. package/dist/docs/components/chat.md +2 -2
  30. package/dist/docs/components/checkbox.md +15 -10
  31. package/dist/docs/components/circularProgress.md +6 -6
  32. package/dist/docs/components/clearableInput.md +1 -1
  33. package/dist/docs/components/collapse.md +2 -2
  34. package/dist/docs/components/composedCharts.md +63 -51
  35. package/dist/docs/components/contentLoader.md +1 -1
  36. package/dist/docs/components/dataTabs.md +33 -33
  37. package/dist/docs/components/datepickers.md +693 -685
  38. package/dist/docs/components/dayPicker.md +5624 -0
  39. package/dist/docs/components/dayPickerCalendar.md +5289 -0
  40. package/dist/docs/components/dialogs.md +17 -19
  41. package/dist/docs/components/divider.md +1 -1
  42. package/dist/docs/components/dropdowns.md +3264 -3276
  43. package/dist/docs/components/editableContent.md +91 -91
  44. package/dist/docs/components/expander.md +4 -1
  45. package/dist/docs/components/fade.md +1 -1
  46. package/dist/docs/components/fadeExpander.md +1 -1
  47. package/dist/docs/components/fadeUp.md +32 -36
  48. package/dist/docs/components/feedback.md +1 -1
  49. package/dist/docs/components/filePickers.md +1 -1
  50. package/dist/docs/components/formLabel.md +29 -31
  51. package/dist/docs/components/groupedItemList.md +3 -7
  52. package/dist/docs/components/htmlTable.md +5074 -0
  53. package/dist/docs/components/iconList.md +4 -4
  54. package/dist/docs/components/imagePreloader.md +1 -1
  55. package/dist/docs/components/labeledElement.md +1 -1
  56. package/dist/docs/components/licensePlate.md +1 -1
  57. package/dist/docs/components/lineCharts.md +172 -170
  58. package/dist/docs/components/listMenu.md +15 -12
  59. package/dist/docs/components/loadMore.md +4 -2
  60. package/dist/docs/components/mainNavigation.md +1 -1
  61. package/dist/docs/components/mapCircle.md +10 -1
  62. package/dist/docs/components/mapCluster.md +25 -1
  63. package/dist/docs/components/mapContext.md +12 -4
  64. package/dist/docs/components/mapDraggableMarker.md +12 -1
  65. package/dist/docs/components/mapGettingStarted.md +39 -1
  66. package/dist/docs/components/mapInfoBubble.md +129 -2
  67. package/dist/docs/components/mapLayerGroup.md +10 -1
  68. package/dist/docs/components/mapMarker.md +10 -1
  69. package/dist/docs/components/mapPolygon.md +288 -85
  70. package/dist/docs/components/mapRoute.md +262 -172
  71. package/dist/docs/components/mapSettings.md +28 -1
  72. package/dist/docs/components/mapUtils.md +1 -1
  73. package/dist/docs/components/mapViewportHistory.md +287 -0
  74. package/dist/docs/components/multiselects.md +217 -18
  75. package/dist/docs/components/noData.md +1 -1
  76. package/dist/docs/components/notifications.md +2 -2
  77. package/dist/docs/components/numbercontrol.md +15 -15
  78. package/dist/docs/components/onboarding.md +1 -1
  79. package/dist/docs/components/page.md +1 -1
  80. package/dist/docs/components/pager.md +1 -1
  81. package/dist/docs/components/pieCharts.md +237 -211
  82. package/dist/docs/components/popover.md +1 -1
  83. package/dist/docs/components/position.md +1 -1
  84. package/dist/docs/components/radialBarCharts.md +446 -398
  85. package/dist/docs/components/radioCardGroup.md +1 -1
  86. package/dist/docs/components/radiobutton.md +98 -98
  87. package/dist/docs/components/releaseNotes.md +1 -1
  88. package/dist/docs/components/resizer.md +1 -1
  89. package/dist/docs/components/responsiveColumnStripe.md +1 -1
  90. package/dist/docs/components/responsiveVideo.md +1 -1
  91. package/dist/docs/components/rioglyph.md +1 -1
  92. package/dist/docs/components/rules.md +41 -47
  93. package/dist/docs/components/saveableInput.md +252 -252
  94. package/dist/docs/components/selects.md +332 -161
  95. package/dist/docs/components/sidebar.md +1 -1
  96. package/dist/docs/components/sliders.md +1 -1
  97. package/dist/docs/components/smoothScrollbars.md +19 -13
  98. package/dist/docs/components/spinners.md +1 -1
  99. package/dist/docs/components/states.md +15 -1
  100. package/dist/docs/components/statsWidgets.md +1 -1
  101. package/dist/docs/components/statusBar.md +3 -1
  102. package/dist/docs/components/stepButton.md +1 -1
  103. package/dist/docs/components/steppedProgressBars.md +9 -11
  104. package/dist/docs/components/subNavigation.md +1 -1
  105. package/dist/docs/components/supportMarker.md +1 -1
  106. package/dist/docs/components/svgImage.md +1 -1
  107. package/dist/docs/components/switch.md +5 -1
  108. package/dist/docs/components/table.md +21361 -0
  109. package/dist/docs/components/tableControls.md +982 -0
  110. package/dist/docs/components/tagManager.md +1 -1
  111. package/dist/docs/components/tags.md +1 -1
  112. package/dist/docs/components/teaser.md +1 -1
  113. package/dist/docs/components/textTruncateMiddle.md +1 -1
  114. package/dist/docs/components/timeline.md +1 -1
  115. package/dist/docs/components/timepicker.md +3 -1
  116. package/dist/docs/components/toggleButton.md +3 -1
  117. package/dist/docs/components/tooltip.md +8 -2
  118. package/dist/docs/components/tracker.md +1 -1
  119. package/dist/docs/components/virtualList.md +60 -60
  120. package/dist/docs/foundations.md +761 -3077
  121. package/dist/docs/start/changelog.md +73 -3
  122. package/dist/docs/start/goodtoknow.md +5 -1
  123. package/dist/docs/start/guidelines/color-combinations.md +5 -1
  124. package/dist/docs/start/guidelines/custom-css.md +26 -2
  125. package/dist/docs/start/guidelines/custom-rioglyph.md +20 -2
  126. package/dist/docs/start/guidelines/formatting.md +2254 -249
  127. package/dist/docs/start/guidelines/iframe.md +53 -19
  128. package/dist/docs/start/guidelines/obfuscate-data.md +24 -2
  129. package/dist/docs/start/guidelines/print-css.md +16 -2
  130. package/dist/docs/start/guidelines/spinner.md +1 -1
  131. package/dist/docs/start/guidelines/state-in-url.md +1138 -11
  132. package/dist/docs/start/guidelines/supported-browsers.md +9 -2
  133. package/dist/docs/start/guidelines/writing.md +228 -2
  134. package/dist/docs/start/howto.md +155 -13
  135. package/dist/docs/start/intro.md +40 -2
  136. package/dist/docs/start/responsiveness.md +27 -1
  137. package/dist/docs/templates/ai-assistant.md +311 -0
  138. package/dist/docs/templates/common-table.md +814 -0
  139. package/dist/docs/templates/detail-views.md +846 -0
  140. package/dist/docs/templates/expandable-details.md +214 -0
  141. package/dist/docs/templates/feature-cards.md +479 -0
  142. package/dist/docs/templates/form-summary.md +179 -0
  143. package/dist/docs/templates/form-toggle.md +329 -0
  144. package/dist/docs/templates/list-blocks.md +872 -0
  145. package/dist/docs/templates/loading-progress.md +100 -0
  146. package/dist/docs/templates/options-panel.md +132 -0
  147. package/dist/docs/templates/panel-variants.md +137 -0
  148. package/dist/docs/templates/progress-cards.md +541 -0
  149. package/dist/docs/templates/progress-success.md +125 -0
  150. package/dist/docs/templates/settings-form.md +401 -0
  151. package/dist/docs/templates/stats-blocks.md +1245 -0
  152. package/dist/docs/templates/table-panel.md +310 -0
  153. package/dist/docs/templates/usage-cards.md +199 -0
  154. package/dist/docs/utilities/classNames.md +89 -1
  155. package/dist/docs/utilities/deviceUtils.md +2 -2
  156. package/dist/docs/utilities/featureToggles.md +182 -2
  157. package/dist/docs/utilities/fuelTypeUtils.md +27 -29
  158. package/dist/docs/utilities/getTrackingAttributes.md +322 -0
  159. package/dist/docs/utilities/routeUtils.md +211 -3
  160. package/dist/docs/utilities/useAfterMount.md +1 -1
  161. package/dist/docs/utilities/useAutoAnimate.md +1 -1
  162. package/dist/docs/utilities/useAverage.md +1 -1
  163. package/dist/docs/utilities/useClickOutside.md +1 -1
  164. package/dist/docs/utilities/useClipboard.md +2 -2
  165. package/dist/docs/utilities/useCookies.md +1 -1
  166. package/dist/docs/utilities/useCount.md +1 -1
  167. package/dist/docs/utilities/useDarkMode.md +5 -4
  168. package/dist/docs/utilities/useDebugInfo.md +3 -3
  169. package/dist/docs/utilities/useDraggableElement.md +281 -0
  170. package/dist/docs/utilities/useEffectOnce.md +1 -1
  171. package/dist/docs/utilities/useElapsedTime.md +1 -1
  172. package/dist/docs/utilities/useElementSize.md +1 -1
  173. package/dist/docs/utilities/useEsc.md +1 -1
  174. package/dist/docs/utilities/useEvent.md +1 -1
  175. package/dist/docs/utilities/useFocusTrap.md +1 -1
  176. package/dist/docs/utilities/useFullscreen.md +1 -1
  177. package/dist/docs/utilities/useHover.md +1 -1
  178. package/dist/docs/utilities/useIncomingPostMessages.md +1 -1
  179. package/dist/docs/utilities/useInterval.md +1 -1
  180. package/dist/docs/utilities/useIsFocusWithin.md +1 -1
  181. package/dist/docs/utilities/useKey.md +8 -10
  182. package/dist/docs/utilities/useLocalStorage.md +1 -1
  183. package/dist/docs/utilities/useLocationSuggestions.md +1 -1
  184. package/dist/docs/utilities/useMax.md +1 -1
  185. package/dist/docs/utilities/useMin.md +1 -1
  186. package/dist/docs/utilities/useMutationObserver.md +1 -1
  187. package/dist/docs/utilities/useOnScreen.md +1 -1
  188. package/dist/docs/utilities/useOnlineStatus.md +1 -1
  189. package/dist/docs/utilities/usePostMessage.md +2 -2
  190. package/dist/docs/utilities/usePostMessageSender.md +1 -1
  191. package/dist/docs/utilities/usePrevious.md +110 -2
  192. package/dist/docs/utilities/useResizeObserver.md +35 -15
  193. package/dist/docs/utilities/useRioCookieConsent.md +1 -1
  194. package/dist/docs/utilities/useScrollPosition.md +3 -6
  195. package/dist/docs/utilities/useSearch.md +1 -3
  196. package/dist/docs/utilities/useSearchHighlight.md +1 -1
  197. package/dist/docs/utilities/useSorting.md +370 -239
  198. package/dist/docs/utilities/useStateWithValidation.md +1 -1
  199. package/dist/docs/utilities/useSum.md +1 -1
  200. package/dist/docs/utilities/useTableExport.md +364 -288
  201. package/dist/docs/utilities/useTableSelection.md +88 -92
  202. package/dist/docs/utilities/useTimeout.md +1 -1
  203. package/dist/docs/utilities/useToggle.md +1 -1
  204. package/dist/docs/utilities/useUrlState.md +1 -1
  205. package/dist/docs/utilities/useWindowResize.md +1 -1
  206. package/dist/index.mjs +173 -69
  207. package/dist/search-synonyms.json +214 -76
  208. package/dist/version.json +2 -2
  209. package/package.json +4 -5
  210. package/dist/docs/components/mapRouteGenerator.md +0 -6
  211. package/dist/docs/components/tables.md +0 -8
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useElementSize
6
- *Captured:* 2026-03-06T10:41:38.089Z
6
+ *Captured:* 2026-04-27T14:59:33.593Z
7
7
 
8
8
  The useElementSize hook allows to easily detect an elements dimension.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useEsc
6
- *Captured:* 2026-03-06T10:41:39.113Z
6
+ *Captured:* 2026-04-27T14:59:34.674Z
7
7
 
8
8
  The useEsc hook allows to easily detect keydown events for escape key to to react on. This comes in handy when closing something or aborting some operation on esc.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* UI state & input hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useEvent
6
- *Captured:* 2026-03-06T10:41:51.160Z
6
+ *Captured:* 2026-04-27T14:59:43.176Z
7
7
 
8
8
  The useEvent hook allows to easily detect given events registered on the document.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useFocusTrap
6
- *Captured:* 2026-03-06T10:41:39.661Z
6
+ *Captured:* 2026-04-27T14:59:34.932Z
7
7
 
8
8
  This custom hook allows to keep the focus inside a defined wrapper element. This might be a dialog or a custom overlay.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useFullscreen
6
- *Captured:* 2026-03-06T10:41:43.215Z
6
+ *Captured:* 2026-04-27T14:59:35.793Z
7
7
 
8
8
  The cross-browser useFullscreen hook allows to easily switch to fullscreen mode for the document or a dedicated element like a map or a certain part of a service.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useHover
6
- *Captured:* 2026-03-06T10:41:40.955Z
6
+ *Captured:* 2026-04-27T14:59:35.844Z
7
7
 
8
8
  ## useHover
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Browser & device hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useIncomingPostMessages
6
- *Captured:* 2026-03-06T10:41:47.230Z
6
+ *Captured:* 2026-04-27T14:59:39.988Z
7
7
 
8
8
  For handling postMessage events in React components.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Lifecycle & execution hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useInterval
6
- *Captured:* 2026-03-06T10:41:35.430Z
6
+ *Captured:* 2026-04-27T14:59:31.082Z
7
7
 
8
8
  The useInterval hook allows for executing some code after a specified amount of time.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useIsFocusWithin
6
- *Captured:* 2026-03-06T10:41:40.739Z
6
+ *Captured:* 2026-04-27T14:59:36.144Z
7
7
 
8
8
  The useIsFocusWithin hook allows you to detect whether the focus is currently within a specific element or any of its children. This is useful for managing focus-based behavior like showing or hiding UI elements, styling active areas, or triggering accessibility behavior.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useKey
6
- *Captured:* 2026-03-06T10:41:41.456Z
6
+ *Captured:* 2026-04-27T14:59:36.468Z
7
7
 
8
8
  The useKey hook allows to easily detect key events. It can be used in two ways, either to specify a specific key to listen for or with a callback to listen for all keys.
9
9
 
@@ -94,15 +94,13 @@ const Usage3 = () => {
94
94
  );
95
95
  };
96
96
 
97
- const UseKeyExample = () => {
98
- return (
99
- <div className='display-flex flex-column justify-content-center align-items-center'>
100
- <Usage1 />
101
- <Usage2 />
102
- <Usage3 />
103
- </div>
104
- );
105
- };
97
+ const UseKeyExample = () => (
98
+ <div className='display-flex flex-column justify-content-center align-items-center'>
99
+ <Usage1 />
100
+ <Usage2 />
101
+ <Usage3 />
102
+ </div>
103
+ );
106
104
 
107
105
  export default UseKeyExample;
108
106
  ```
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Browser & device hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useLocalStorage
6
- *Captured:* 2026-03-06T10:41:50.097Z
6
+ *Captured:* 2026-04-27T14:59:41.668Z
7
7
 
8
8
  The useLocalStorage and the useSessionStorage hook allows to save custom data in the respective storage locations.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* UI state & input hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useLocationSuggestions
6
- *Captured:* 2026-03-06T10:41:51.833Z
6
+ *Captured:* 2026-04-27T14:59:43.359Z
7
7
 
8
8
  The useLocationSuggestions hook allows to use a side effect after the component has been mounted and rendered. The effect will not be triggered on mount and only when the dependencies change.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Data aggregation hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useMax
6
- *Captured:* 2026-03-06T10:41:56.465Z
6
+ *Captured:* 2026-04-27T14:59:46.367Z
7
7
 
8
8
  Returns the largest valid numeric value found at the specified path within a list of objects. Supports localized formats and gracefully skips unparsable values.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Data aggregation hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useMin
6
- *Captured:* 2026-03-06T10:41:56.398Z
6
+ *Captured:* 2026-04-27T14:59:46.997Z
7
7
 
8
8
  Returns the smallest valid numeric value found at the specified path within a list of objects. Handles localized number strings and safely ignores invalid values.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useMutationObserver
6
- *Captured:* 2026-03-06T10:41:42.777Z
6
+ *Captured:* 2026-04-27T14:59:37.240Z
7
7
 
8
8
  The useMutationObserver hook enables you to listen for changes on the given element or on its children. For more details, check out https://developer.mozilla.org/en-US/docs/Web/API/MutationObserver
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useOnScreen
6
- *Captured:* 2026-03-06T10:41:43.357Z
6
+ *Captured:* 2026-04-27T14:59:37.297Z
7
7
 
8
8
  The useOnScreen hook tells you when an element is visible on screen.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Browser & device hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useOnlineStatus
6
- *Captured:* 2026-03-06T10:41:49.569Z
6
+ *Captured:* 2026-04-27T14:59:41.667Z
7
7
 
8
8
  The useOnlineStatus hook tells you when there is a network connection or not.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Browser & device hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/usePostMessage
6
- *Captured:* 2026-03-06T10:41:49.551Z
6
+ *Captured:* 2026-04-27T14:59:41.796Z
7
7
 
8
8
  The usePostMessage hook allows to easily exchange events and data between the parent window and embedded iframes.
9
9
 
@@ -88,7 +88,7 @@ export default () => {
88
88
  </div>
89
89
  </div>
90
90
  <div class="iframe-wrapper">
91
- <iframe title="iframe" id="postMessageExample" src="/#postMessageExample" class="unstyled width-100pct" style="width: 1px; min-width: 100%; overflow: hidden; height: 150px;" scrolling="no">
91
+ <iframe title="iframe" id="postMessageExample" src="/#postMessageExample" class="unstyled width-100pct" style="width: 1px; min-width: 100%; overflow: hidden; height: 200px;" scrolling="no">
92
92
  </iframe>
93
93
  </div>
94
94
  </div>
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Browser & device hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/usePostMessageSender
6
- *Captured:* 2026-03-06T10:41:50.191Z
6
+ *Captured:* 2026-04-27T14:59:41.816Z
7
7
 
8
8
  Helper hook to fire postMessage events to other windows: a specific target (including yourself), the parent or top window, or every iframe on the page. It uses the wildcard target origin (*) and no-ops when a target window is missing, so it is safe to call even when an iframe or parent is not present.
9
9
 
@@ -3,12 +3,14 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Lifecycle & execution hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/usePrevious
6
- *Captured:* 2026-03-06T10:41:36.456Z
6
+ *Captured:* 2026-04-27T14:59:31.535Z
7
7
 
8
8
  The usePrevious hook allows to easily access state from previous component render. Instead of using a React.ref and a useEffect, this hook uses a useState internally to keep track of the previous state value.
9
9
 
10
10
  ## usePrevious
11
11
 
12
+ Quoting from the React documentation:
13
+
12
14
  - If the value you need can be computed entirely from the current props or other state, remove that redundant state altogether. If you’re worried about recomputing too often, the useMemo Hook can help.
13
15
  - If you want to reset the entire component tree’s state, pass a different key to your component.
14
16
  - If you can, update all the relevant state in the event handlers.
@@ -28,6 +30,112 @@ setSelection(null);
28
30
  }
29
31
  ```
30
32
 
33
+ function
34
+
35
+ List
36
+
37
+ (
38
+
39
+ { items }
40
+
41
+ )
42
+
43
+ {
44
+
45
+ const
46
+
47
+ [
48
+
49
+ ,
50
+
51
+ ]
52
+
53
+ =
54
+
55
+ useState
56
+
57
+ (
58
+
59
+ false
60
+
61
+ )
62
+
63
+ ;
64
+
65
+ const
66
+
67
+ [
68
+
69
+ ,
70
+
71
+ ]
72
+
73
+ =
74
+
75
+ useState
76
+
77
+ (
78
+
79
+ null
80
+
81
+ )
82
+
83
+ ;
84
+
85
+ // Better: Adjust the state while rendering
86
+
87
+ const
88
+
89
+ [
90
+
91
+ ,
92
+
93
+ ]
94
+
95
+ =
96
+
97
+ useState
98
+
99
+ (
100
+
101
+ )
102
+
103
+ ;
104
+
105
+ if
106
+
107
+ (
108
+
109
+ !==
110
+
111
+ )
112
+
113
+ {
114
+
115
+ setPrevItems
116
+
117
+ (
118
+
119
+ )
120
+
121
+ ;
122
+
123
+ setSelection
124
+
125
+ (
126
+
127
+ null
128
+
129
+ )
130
+
131
+ ;
132
+
133
+ }
134
+
135
+ // ...
136
+
137
+ }
138
+
31
139
  > Note: If you want to use this to update the internal state due to a prop change, you might run into a loop. Therefore, use the following snippet suggested by the React team here: https://react.dev/learn/you-might-not-need-an-effect#adjusting-some-state-when-a-prop-changes
32
140
 
33
141
  ### Example: Example 1
@@ -69,7 +177,7 @@ export default () => {
69
177
  <div class="NumberControl margin-0 width-100">
70
178
  <div class="input-group">
71
179
  <div class="form-control-feedback-wrapper">
72
- <input type="number" step="1" min="0" max="1.7976931348623157e+308" class="form-control no-controls" aria-label="number-input" value="1">
180
+ <input type="number" step="1" min="0" max="1.7976931348623157e+308" class="form-control no-controls padding-right-5" aria-label="number-input" value="1">
73
181
  </div>
74
182
  <div class="input-group-addon ">
75
183
  <div class="display-flex padding-left-10">
@@ -3,15 +3,17 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useResizeObserver
6
- *Captured:* 2026-03-06T10:41:44.548Z
6
+ *Captured:* 2026-04-27T14:59:38.448Z
7
7
 
8
8
  The useResizeObserver hook allows to react on resize changes of a given element.
9
9
 
10
10
  ## useResizeObserver
11
11
 
12
+ You can either attach the returned ref to the observed element or pass an existing DOM element directly as the optional first argument.
13
+
12
14
  > Note: that is important to consider the padding of the element to observe and to take it into consideration when working with its width and height. When using the contentRect from the observerEntry, keep in mind that this will not include the paddings.
13
15
 
14
- To include the target elements padding, please use the borderBoxSize instead.
16
+ To include the target element padding, use the third return value with inlineSize and blockSize, or read borderBoxSize from the observer entry directly.
15
17
 
16
18
  ### Example: Example 1
17
19
 
@@ -28,9 +30,7 @@ import useResizeObserver from '@rio-cloud/rio-uikit/useResizeObserver';
28
30
  export default () => {
29
31
  const [boxWidth, setBoxWidth] = useState(200);
30
32
 
31
- // To include target elements padding, use "borderBoxSize" or for convenience
32
- // purpose, use the dedicated return object already containing "inlineSize" and "blockSize".
33
- // const [ref, { borderBox }] = useResizeObserver();
33
+ // The third tuple item already exposes border-box based inline/block size values.
34
34
  const [ref, _, { inlineSize, blockSize }] = useResizeObserver();
35
35
 
36
36
  const handleResizeHorizontal = (diff: number) => setBoxWidth(previousValue => previousValue - diff);
@@ -47,7 +47,7 @@ export default () => {
47
47
  ref={ref}
48
48
  >
49
49
  <div className='text-color-white text-medium'>
50
- {inlineSize}x{blockSize}
50
+ {inlineSize ?? 0}x{blockSize ?? 0}
51
51
  </div>
52
52
  <Resizer onResize={handleResizeHorizontal}>
53
53
  <div className='width-5 height-100pct bg-light' />
@@ -71,11 +71,19 @@ export default () => {
71
71
  </div>
72
72
  ```
73
73
 
74
- #### Props (json)
74
+ #### Props
75
75
 
76
- ```json
77
- ref
78
- ```
76
+ | Name | Type | Default | Description |
77
+ | --- | --- | --- | --- |
78
+ | observedElement | HTMLElement \| null | — | Optional existing DOM element to observe directly instead of attaching the returned ref. |
79
+
80
+ #### Props
81
+
82
+ | Name | Type | Default | Description |
83
+ | --- | --- | --- | --- |
84
+ | ref | MutableRefObject<T \| null> | — | Ref object for the observed element. When you pass observedElement directly, this ref can be ignored. |
85
+ | observerEntry | ResizeObserverEntry \| null | — | The latest ResizeObserverEntry or null until the first observation. See https://developer.mozilla.org/en-US/docs/Web/API/ResizeObserverEntry |
86
+ | size | { inlineSize: number \| undefined; blockSize: number \| undefined } | — | Convenience object that prefers borderBoxSize and falls back to contentRect. |
79
87
 
80
88
  ### Example: Example 2
81
89
 
@@ -97,7 +105,11 @@ export default () => {
97
105
  const contentRect = observerEntry?.contentRect;
98
106
 
99
107
  const getContentRect = useCallback(
100
- (key: keyof DOMRectReadOnly) => Math.round(contentRect?.[key] as number),
108
+ (key: keyof DOMRectReadOnly) => {
109
+ const value = contentRect?.[key];
110
+
111
+ return typeof value === 'number' ? Math.round(value) : 0;
112
+ },
101
113
  [contentRect]
102
114
  );
103
115
 
@@ -136,8 +148,16 @@ export default () => {
136
148
  </div>
137
149
  ```
138
150
 
139
- #### Props (json)
151
+ #### Props
152
+
153
+ | Name | Type | Default | Description |
154
+ | --- | --- | --- | --- |
155
+ | observedElement | HTMLElement \| null | — | Optional existing DOM element to observe directly instead of attaching the returned ref. |
156
+
157
+ #### Props
140
158
 
141
- ```json
142
- ref
143
- ```
159
+ | Name | Type | Default | Description |
160
+ | --- | --- | --- | --- |
161
+ | ref | MutableRefObject<T \| null> | — | Ref object for the observed element. When you pass observedElement directly, this ref can be ignored. |
162
+ | observerEntry | ResizeObserverEntry \| null | — | The latest ResizeObserverEntry or null until the first observation. See https://developer.mozilla.org/en-US/docs/Web/API/ResizeObserverEntry |
163
+ | size | { inlineSize: number \| undefined; blockSize: number \| undefined } | — | Convenience object that prefers borderBoxSize and falls back to contentRect. |
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* Browser & device hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useRioCookieConsent
6
- *Captured:* 2026-03-06T10:41:47.562Z
6
+ *Captured:* 2026-04-27T14:59:40.030Z
7
7
 
8
8
  The useRioCookieConsent hook reads and parses RIO's cookie_settings cookie and returns a typed consent state.
9
9
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* DOM behavior hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useScrollPosition
6
- *Captured:* 2026-03-06T10:41:45.570Z
6
+ *Captured:* 2026-04-27T14:59:38.575Z
7
7
 
8
8
  The useScrollPosition hook allows to react on a desired scroll position of a given target. Use it when showing or hiding content based on the scroll position.
9
9
 
@@ -143,10 +143,7 @@ export default () => {
143
143
  return (
144
144
  <>
145
145
  <label>Example for scroll position of a certain element</label>
146
- <div
147
- ref={contentRef}
148
- className='height-200 position-relative overflow-auto height-200 position-relative overflow-auto'
149
- >
146
+ <div ref={contentRef} className='height-200 position-relative overflow-auto'>
150
147
  <div className='position-sticky top-0 well well-sm border shadow-default'>{`${scrollPosition} px`}</div>
151
148
  <div className='text-size-14'>{dummyTextExtraLong}</div>
152
149
  </div>
@@ -159,7 +156,7 @@ export default () => {
159
156
 
160
157
  ```html
161
158
  <label>Example for scroll position of a certain element</label>
162
- <div class="height-200 position-relative overflow-auto height-200 position-relative overflow-auto">
159
+ <div class="height-200 position-relative overflow-auto">
163
160
  <div class="position-sticky top-0 well well-sm border shadow-default">0 px</div>
164
161
  <div class="text-size-14">
165
162
  Lorem ipsum dolor sit amet, consectetur adipiscing elit. In pharetra dui eget massa efficitur aliquam condimentum in felis. Integer eget metus vel nunc efficitur iaculis. Vivamus elementum ante et est sagittis semper. Ut consectetur enim nec tortor scelerisque tincidunt. Fusce ac ligula bibendum, rutrum libero quis, viverra sem. Interdum et malesuada fames ac ante ipsum primis in faucibus. Duis ut hendrerit massa, in molestie elit. Sed vitae orci ac purus volutpat posuere ac ut neque. Mauris ante orci, semper finibus lorem in, fringilla pretium velit.
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* UI state & input hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useSearch
6
- *Captured:* 2026-03-06T10:41:52.947Z
6
+ *Captured:* 2026-04-27T14:59:44.024Z
7
7
 
8
8
  The useSearch hook is a custom hook to filter a list of objects by a search value. Supports field-based filtering, custom filtering logic, debounce, and case sensitivity.
9
9
 
@@ -23,8 +23,6 @@ import useSearch from '@rio-cloud/rio-uikit/useSearch';
23
23
  import ClearableInput from '@rio-cloud/rio-uikit/ClearableInput';
24
24
  import FormLabel from '@rio-cloud/rio-uikit/FormLabel';
25
25
 
26
- type ListType = { name: string };
27
-
28
26
  export default () => {
29
27
  const items = [{ name: 'Apple' }, { name: 'Banana' }, { name: 'Fig' }, { name: 'Pear' }, { name: 'Mango' }];
30
28
 
@@ -3,7 +3,7 @@
3
3
  *Category:* Utilities
4
4
  *Section:* UI state & input hooks
5
5
  *Source:* https://uikit.developers.rio.cloud/#/utilities/useSearchHighlight
6
- *Captured:* 2026-03-06T10:41:54.695Z
6
+ *Captured:* 2026-04-27T14:59:46.152Z
7
7
 
8
8
  The useSearchHighlight hook applies native CSS Highlight API ranges to matching text in a referenced container. It progressively enhances supported browsers without mutating markup and can be scoped or made case-sensitive as needed.
9
9