@oracle/oraclejet-preact 18.1.6 → 18.1.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 (657) hide show
  1. package/amd/ActionCard-5ae60cb4.js +1 -1
  2. package/amd/{BarChart-0ad4ca6d.js → BarChart-254aecbb.js} +2 -2
  3. package/amd/{BarChart-0ad4ca6d.js.map → BarChart-254aecbb.js.map} +1 -1
  4. package/amd/BarGroup-d6909cb1.js +1 -1
  5. package/amd/BaseButton-c86afd54.js +1 -1
  6. package/amd/{BaseCardView-a1c5a21d.js → BaseCardView-4f88499c.js} +2 -2
  7. package/amd/{BaseCardView-a1c5a21d.js.map → BaseCardView-4f88499c.js.map} +1 -1
  8. package/amd/{BaseCardViewSelectionTest-36a03079.js → BaseCardViewSelectionTest-00655472.js} +2 -2
  9. package/amd/{BaseCardViewSelectionTest-36a03079.js.map → BaseCardViewSelectionTest-00655472.js.map} +1 -1
  10. package/amd/BaseNavigationListItem-84858a0f.js +2 -0
  11. package/{es/BaseNavigationListItem-1c75c13f.js.map → amd/BaseNavigationListItem-84858a0f.js.map} +1 -1
  12. package/amd/BaseRichSelection-33a97275.js +1 -1
  13. package/amd/ButtonSet-7a7a63e8.js +1 -1
  14. package/amd/ButtonSetIconButton-9f171b1e.js +1 -1
  15. package/amd/Card-4d47fe95.js +2 -0
  16. package/amd/{Card-70e5f9f2.js.map → Card-4d47fe95.js.map} +1 -1
  17. package/amd/CardFlexView-86cb369a.js +2 -0
  18. package/amd/{CardFlexView-f7fdfac8.js.map → CardFlexView-86cb369a.js.map} +1 -1
  19. package/amd/CardGridView-b3f11290.js +2 -0
  20. package/amd/{CardGridView-b8a60fae.js.map → CardGridView-b3f11290.js.map} +1 -1
  21. package/amd/{Center-e552eb11.js → Center-05b00f39.js} +2 -2
  22. package/amd/{Center-e552eb11.js.map → Center-05b00f39.js.map} +1 -1
  23. package/amd/{Chart-79cfc878.js → Chart-87ae799b.js} +2 -2
  24. package/amd/{Chart-79cfc878.js.map → Chart-87ae799b.js.map} +1 -1
  25. package/amd/Checkbox-49753599.js +1 -1
  26. package/amd/CheckboxControl-c6a380b3.js +1 -1
  27. package/amd/CheckboxRadioField-1987c75d.js +1 -1
  28. package/amd/Chip-1bcbf57e.js +1 -1
  29. package/amd/ClearIcon-d73689cc.js +1 -1
  30. package/amd/CollapseIcon-a7f8693d.js +1 -1
  31. package/amd/Collapsible-ea0dca8a.js +1 -1
  32. package/amd/{ComboChart-72eda15f.js → ComboChart-79e7d438.js} +2 -2
  33. package/amd/{ComboChart-72eda15f.js.map → ComboChart-79e7d438.js.map} +1 -1
  34. package/amd/CompactHelpSource-de995a7f.js +1 -1
  35. package/amd/CompactLabelAssistance-f3d093c7.js +2 -0
  36. package/amd/{CompactLabelAssistance-9f9f658d.js.map → CompactLabelAssistance-f3d093c7.js.map} +1 -1
  37. package/amd/CompactUserAssistance-3799998f.js +1 -1
  38. package/amd/ComponentMessageContainer-cf186eeb.js +1 -1
  39. package/amd/ConveyorBeltItem-e3002f4a.js +1 -1
  40. package/amd/{DatePicker-9115226e.js → DatePicker-abe79055.js} +2 -2
  41. package/amd/{DatePicker-9115226e.js.map → DatePicker-abe79055.js.map} +1 -1
  42. package/amd/DatePickerHeader-a0da70a0.js +1 -1
  43. package/amd/{Diagram-14fa4924.js → Diagram-3d169c49.js} +2 -2
  44. package/amd/{Diagram-14fa4924.js.map → Diagram-3d169c49.js.map} +1 -1
  45. package/amd/{Dialog-896c0bfd.js → Dialog-11e863b2.js} +2 -2
  46. package/amd/{Dialog-896c0bfd.js.map → Dialog-11e863b2.js.map} +1 -1
  47. package/amd/DirectionalCollapseArrowIcon-31539047.js +1 -1
  48. package/amd/DirectionalExpandArrowIcon-533fd2a0.js +1 -1
  49. package/amd/{DragHandle-14ea6e74.js → DragHandle-7335845b.js} +2 -2
  50. package/amd/{DragHandle-14ea6e74.js.map → DragHandle-7335845b.js.map} +1 -1
  51. package/amd/{DrawerPopup-90b8ecf5.js → DrawerPopup-8d5736fb.js} +2 -2
  52. package/amd/{DrawerPopup-90b8ecf5.js.map → DrawerPopup-8d5736fb.js.map} +1 -1
  53. package/amd/{Dropdown-73238fd5.js → Dropdown-3d2abe1f.js} +2 -2
  54. package/amd/{Dropdown-73238fd5.js.map → Dropdown-3d2abe1f.js.map} +1 -1
  55. package/amd/{EnvironmentProvider-806b8f3a.js → EnvironmentProvider-bbf80843.js} +2 -2
  56. package/amd/{EnvironmentProvider-806b8f3a.js.map → EnvironmentProvider-bbf80843.js.map} +1 -1
  57. package/amd/ExpandableList-daabc548.js +1 -1
  58. package/amd/FilePicker-7e31189e.js +1 -1
  59. package/amd/{Flex-590160eb.js → Flex-b8764305.js} +2 -2
  60. package/amd/{Flex-590160eb.js.map → Flex-b8764305.js.map} +1 -1
  61. package/amd/{Floating-ae9845d4.js → Floating-f12b8739.js} +2 -2
  62. package/amd/{Floating-ae9845d4.js.map → Floating-f12b8739.js.map} +1 -1
  63. package/amd/FormLayout-3d643cdf.js +1 -1
  64. package/amd/Gantt-7265d4ce.js +1 -1
  65. package/amd/Grid-e6f0d4a6.js +2 -0
  66. package/amd/{Grid-a8a51c37.js.map → Grid-e6f0d4a6.js.map} +1 -1
  67. package/amd/{Gridlines-8894882d.js → Gridlines-efa5606a.js} +2 -2
  68. package/amd/{Gridlines-8894882d.js.map → Gridlines-efa5606a.js.map} +1 -1
  69. package/amd/GroupLoadingIndicator-9fd33355.js +1 -1
  70. package/amd/HighlightText-d1b13537.js +2 -0
  71. package/amd/{HighlightText-ded0d51b.js.map → HighlightText-d1b13537.js.map} +1 -1
  72. package/amd/Icon-383a68bb.js +1 -1
  73. package/amd/IconButton-368fba34.js +1 -1
  74. package/amd/IconMenuButton-3f3c2386.js +1 -1
  75. package/amd/IconProgressButton-11c44c28.js +1 -1
  76. package/amd/IconSwitchButton-1a400cdf.js +1 -1
  77. package/amd/IconToggleButton-ea46b246.js +1 -1
  78. package/amd/{IconUserAssistance-e496ab70.js → IconUserAssistance-f5228b1d.js} +2 -2
  79. package/amd/{IconUserAssistance-e496ab70.js.map → IconUserAssistance-f5228b1d.js.map} +1 -1
  80. package/amd/{Indexer-5df524f2.js → Indexer-510aaf3a.js} +2 -2
  81. package/amd/{Indexer-5df524f2.js.map → Indexer-510aaf3a.js.map} +1 -1
  82. package/amd/InlineHelpSource-8277317c.js +1 -1
  83. package/amd/InlineUserAssistance-a97e0011.js +1 -1
  84. package/amd/InputDateMask-09989b51.js +1 -1
  85. package/amd/InputDatePicker-4c3c6bb4.js +2 -0
  86. package/amd/{InputDatePicker-03bdeb95.js.map → InputDatePicker-4c3c6bb4.js.map} +1 -1
  87. package/amd/InputPassword-57a5e072.js +1 -1
  88. package/amd/InputText-a72eb1c3.js +1 -1
  89. package/amd/Label-41b672b4.js +1 -1
  90. package/amd/LabelValueLayout-b6701ecf.js +1 -1
  91. package/amd/{Layer-139c23c4.js → Layer-69221878.js} +2 -2
  92. package/amd/{Layer-139c23c4.js.map → Layer-69221878.js.map} +1 -1
  93. package/amd/{LayerHost-733ade2f.js → LayerHost-27dfba9e.js} +2 -2
  94. package/amd/{LayerHost-733ade2f.js.map → LayerHost-27dfba9e.js.map} +1 -1
  95. package/amd/{LayerManager-9a628ce3.js → LayerManager-7f82d3ce.js} +2 -2
  96. package/amd/{LayerManager-9a628ce3.js.map → LayerManager-7f82d3ce.js.map} +1 -1
  97. package/amd/Legend-6fa54628.js +1 -1
  98. package/amd/{LineAreaChart-3aff0c1a.js → LineAreaChart-1f66d439.js} +2 -2
  99. package/amd/{LineAreaChart-3aff0c1a.js.map → LineAreaChart-1f66d439.js.map} +1 -1
  100. package/amd/{LineSeries-ce197af6.js → LineSeries-fe392d85.js} +2 -2
  101. package/amd/{LineSeries-ce197af6.js.map → LineSeries-fe392d85.js.map} +1 -1
  102. package/amd/Link-1f126248.js +1 -1
  103. package/amd/List-37e37948.js +2 -0
  104. package/amd/{List-0da6ee9c.js.map → List-37e37948.js.map} +1 -1
  105. package/amd/{ListItemLayout-59986c55.js → ListItemLayout-60fc51b7.js} +2 -2
  106. package/amd/{ListItemLayout-59986c55.js.map → ListItemLayout-60fc51b7.js.map} +1 -1
  107. package/amd/{ListView-cdfac903.js → ListView-325e1814.js} +2 -2
  108. package/amd/{ListView-cdfac903.js.map → ListView-325e1814.js.map} +1 -1
  109. package/amd/LiveRegion-17fea064.js +2 -0
  110. package/amd/{LiveRegion-1917f798.js.map → LiveRegion-17fea064.js.map} +1 -1
  111. package/amd/LoadMoreCollection-83413a59.js +2 -0
  112. package/amd/{LoadMoreCollection-a6adbc3f.js.map → LoadMoreCollection-83413a59.js.map} +1 -1
  113. package/amd/{MaxLengthLiveRegion-46bb45da.js → MaxLengthLiveRegion-ecc0c894.js} +2 -2
  114. package/amd/{MaxLengthLiveRegion-46bb45da.js.map → MaxLengthLiveRegion-ecc0c894.js.map} +1 -1
  115. package/amd/Menu-bb715ef5.js +1 -1
  116. package/amd/MenuButton-66e5430a.js +1 -1
  117. package/amd/MenuItem-1a324975.js +1 -1
  118. package/amd/Message-d66cc7e9.js +1 -1
  119. package/amd/{MessageLayer-a439ce52.js → MessageLayer-d39be82d.js} +2 -2
  120. package/amd/{MessageLayer-a439ce52.js.map → MessageLayer-d39be82d.js.map} +1 -1
  121. package/amd/MessageToast-19703f73.js +1 -1
  122. package/amd/MessagesManager-2c4c218f.js +1 -1
  123. package/amd/MeterBar-9f58cfad.js +1 -1
  124. package/amd/MeterCircle-c3138125.js +1 -1
  125. package/amd/{Modal-9eaf8cd9.js → Modal-e4a033c8.js} +2 -2
  126. package/amd/{Modal-9eaf8cd9.js.map → Modal-e4a033c8.js.map} +1 -1
  127. package/amd/{MonthView-67179db3.js → MonthView-ca0355b8.js} +2 -2
  128. package/amd/{MonthView-67179db3.js.map → MonthView-ca0355b8.js.map} +1 -1
  129. package/amd/NavigationList-ae9fcc27.js +2 -0
  130. package/{es/NavigationList-fb05e081.js.map → amd/NavigationList-ae9fcc27.js.map} +1 -1
  131. package/amd/NavigationListItem-cd84dcba.js +2 -0
  132. package/{es/NavigationListItem-193a315a.js.map → amd/NavigationListItem-cd84dcba.js.map} +1 -1
  133. package/amd/NumberInputText-e2cf1795.js +1 -1
  134. package/amd/{OverflowTabBar-1dd5c327.js → OverflowTabBar-0ff69ae0.js} +2 -2
  135. package/amd/{OverflowTabBar-1dd5c327.js.map → OverflowTabBar-0ff69ae0.js.map} +1 -1
  136. package/amd/OverflowTabBarItem-74276a21.js +2 -0
  137. package/amd/{OverflowTabBarItem-f8128e3d.js.map → OverflowTabBarItem-74276a21.js.map} +1 -1
  138. package/amd/PRIVATE_BaseCardView.js +1 -1
  139. package/amd/PRIVATE_Chart.js +1 -1
  140. package/amd/PRIVATE_CheckboxControl.js +1 -1
  141. package/amd/PRIVATE_CheckboxRadioField.js +1 -1
  142. package/amd/PRIVATE_ClearIcon.js +1 -1
  143. package/amd/PRIVATE_DatePickerHeader.js +1 -1
  144. package/amd/PRIVATE_DatePickerLayout.js +1 -1
  145. package/amd/PRIVATE_EmbeddedIconButton.js +1 -1
  146. package/amd/PRIVATE_FormControls.js +1 -1
  147. package/amd/PRIVATE_IconSwitchButton.js +1 -1
  148. package/amd/PRIVATE_Icons/CheckboxMixed.js +1 -1
  149. package/amd/PRIVATE_Icons/CheckboxOff.js +1 -1
  150. package/amd/PRIVATE_Icons/CheckboxOn.js +1 -1
  151. package/amd/PRIVATE_Icons/DragV.js +1 -1
  152. package/amd/PRIVATE_Icons/WarningS.js +1 -1
  153. package/amd/PRIVATE_List.js +1 -1
  154. package/amd/PRIVATE_LoadMoreCollection.js +1 -1
  155. package/amd/PRIVATE_Message.js +1 -1
  156. package/amd/PRIVATE_MessageLayer.js +1 -1
  157. package/amd/PRIVATE_MonthView.js +1 -1
  158. package/amd/PRIVATE_MonthYearGridView.js +1 -1
  159. package/amd/PRIVATE_PlotArea.js +1 -1
  160. package/amd/PRIVATE_RevealToggleIcon.js +1 -1
  161. package/amd/PRIVATE_RichSelectionCommon.js +1 -1
  162. package/amd/PRIVATE_SelectCommon.js +1 -1
  163. package/amd/PRIVATE_StyledCard.js +1 -1
  164. package/amd/PRIVATE_StyledCheckbox.js +1 -1
  165. package/amd/PRIVATE_Table.js +1 -1
  166. package/amd/PRIVATE_ThemedIcons/CalendarIcon.js +1 -1
  167. package/amd/PRIVATE_ThemedIcons/ChartMarqueeSelectIcon.js +1 -1
  168. package/amd/PRIVATE_ThemedIcons/ChartPanIcon.js +1 -1
  169. package/amd/PRIVATE_ThemedIcons/ChartZoomIcon.js +1 -1
  170. package/amd/PRIVATE_ThemedIcons/CheckIcon.js +1 -1
  171. package/amd/PRIVATE_ThemedIcons/CheckboxMixedIcon.js +1 -1
  172. package/amd/PRIVATE_ThemedIcons/CheckboxOffIcon.js +1 -1
  173. package/amd/PRIVATE_ThemedIcons/CheckboxOnIcon.js +1 -1
  174. package/amd/PRIVATE_ThemedIcons/CloseIcon.js +1 -1
  175. package/amd/PRIVATE_ThemedIcons/CollapseIcon.js +1 -1
  176. package/amd/PRIVATE_ThemedIcons/CollapseUpIcon.js +1 -1
  177. package/amd/PRIVATE_ThemedIcons/DecrementIcon.js +1 -1
  178. package/amd/PRIVATE_ThemedIcons/DeleteIcon.js +1 -1
  179. package/amd/PRIVATE_ThemedIcons/DirectionalCollapseArrowIcon.js +1 -1
  180. package/amd/PRIVATE_ThemedIcons/DirectionalExpandArrowIcon.js +1 -1
  181. package/amd/PRIVATE_ThemedIcons/DragHandleIcon.js +1 -1
  182. package/amd/PRIVATE_ThemedIcons/DropdownArrowIcon.js +1 -1
  183. package/amd/PRIVATE_ThemedIcons/ExpandIcon.js +1 -1
  184. package/amd/PRIVATE_ThemedIcons/HelpIcon.js +1 -1
  185. package/amd/PRIVATE_ThemedIcons/IncrementIcon.js +1 -1
  186. package/amd/PRIVATE_ThemedIcons/MenuButtonDropdownIcon.js +1 -1
  187. package/amd/PRIVATE_ThemedIcons/MessageConfirmationIcon.js +1 -1
  188. package/amd/PRIVATE_ThemedIcons/MessageErrorIcon.js +1 -1
  189. package/amd/PRIVATE_ThemedIcons/MessageInfoIcon.js +1 -1
  190. package/amd/PRIVATE_ThemedIcons/MessageWarningIcon.js +1 -1
  191. package/amd/PRIVATE_ThemedIcons/MinusIcon.js +1 -1
  192. package/amd/PRIVATE_ThemedIcons/NavDownIcon.js +1 -1
  193. package/amd/PRIVATE_ThemedIcons/OverviewHorizontalDragHandleIcon.js +1 -1
  194. package/amd/PRIVATE_ThemedIcons/PlusIcon.js +1 -1
  195. package/amd/PRIVATE_ThemedIcons/RadioOffIcon.js +1 -1
  196. package/amd/PRIVATE_ThemedIcons/RadioOnIcon.js +1 -1
  197. package/amd/PRIVATE_ThemedIcons/SortAscendingIcon.js +1 -1
  198. package/amd/PRIVATE_ThemedIcons/SortDescendingIcon.js +1 -1
  199. package/amd/PRIVATE_ThemedIcons/ViewHideIcon.js +1 -1
  200. package/amd/PRIVATE_ThemedIcons/ViewIcon.js +1 -1
  201. package/amd/PRIVATE_TimeComponent.js +1 -1
  202. package/amd/PRIVATE_VirtualizedCollection.js +1 -1
  203. package/amd/PRIVATE_VisOverview.js +1 -1
  204. package/amd/PRIVATE_VisTabularDatatip.js +1 -1
  205. package/amd/PictoChart-98b892fb.js +1 -1
  206. package/amd/PieChart-19890d12.js +1 -1
  207. package/amd/{Popup-3e2566da.js → Popup-b0704743.js} +2 -2
  208. package/amd/{Popup-3e2566da.js.map → Popup-b0704743.js.map} +1 -1
  209. package/amd/{ProgressBar-99c0ff2a.js → ProgressBar-8ab08930.js} +2 -2
  210. package/amd/{ProgressBar-99c0ff2a.js.map → ProgressBar-8ab08930.js.map} +1 -1
  211. package/amd/ProgressButton-cd0c21df.js +1 -1
  212. package/amd/ProgressButtonLabelLayout-76d8a3e7.js +1 -1
  213. package/amd/{ProgressCircle-0046c4c8.js → ProgressCircle-9c36b39c.js} +2 -2
  214. package/amd/{ProgressCircle-0046c4c8.js.map → ProgressCircle-9c36b39c.js.map} +1 -1
  215. package/amd/RadioItem-1a02d3dc.js +1 -1
  216. package/amd/RatingGauge-1c40dae3.js +1 -1
  217. package/amd/ReadonlyTextFieldInput-d6c6dbc4.js +1 -1
  218. package/amd/RemovableNavigationListItem-cf7a0648.js +2 -0
  219. package/amd/{RemovableNavigationListItem-1f69907c.js.map → RemovableNavigationListItem-cf7a0648.js.map} +1 -1
  220. package/amd/RemovableTabBarItem-5c240801.js +1 -1
  221. package/amd/{ReorderableTabBar-23f7e3c3.js → ReorderableTabBar-2983fae4.js} +2 -2
  222. package/amd/{ReorderableTabBar-23f7e3c3.js.map → ReorderableTabBar-2983fae4.js.map} +1 -1
  223. package/amd/RevealToggleIcon-c22626da.js +1 -1
  224. package/amd/{ScatterChart-e6f8d49a.js → ScatterChart-2acbcccd.js} +2 -2
  225. package/amd/{ScatterChart-e6f8d49a.js.map → ScatterChart-2acbcccd.js.map} +1 -1
  226. package/amd/SectionalLegend-713bdefb.js +1 -1
  227. package/amd/SectionedContent-f508dbae.js +2 -0
  228. package/amd/{SectionedContent-ef1f844c.js.map → SectionedContent-f508dbae.js.map} +1 -1
  229. package/amd/{SelectMultiple-a159ccbf.js → SelectMultiple-19db7af2.js} +2 -2
  230. package/amd/{SelectMultiple-a159ccbf.js.map → SelectMultiple-19db7af2.js.map} +1 -1
  231. package/amd/{SelectSingle-e3d0d8d2.js → SelectSingle-7edde065.js} +2 -2
  232. package/amd/{SelectSingle-e3d0d8d2.js.map → SelectSingle-7edde065.js.map} +1 -1
  233. package/amd/SelectionCard-38a1007f.js +2 -0
  234. package/amd/{SelectionCard-a8a3bb2d.js.map → SelectionCard-38a1007f.js.map} +1 -1
  235. package/amd/Selector-fcfe7801.js +1 -1
  236. package/amd/{SelectorAll-de289397.js → SelectorAll-3f85b285.js} +2 -2
  237. package/amd/{SelectorAll-de289397.js.map → SelectorAll-3f85b285.js.map} +1 -1
  238. package/amd/{Sheet-404b38fa.js → Sheet-08578790.js} +2 -2
  239. package/amd/{Sheet-404b38fa.js.map → Sheet-08578790.js.map} +1 -1
  240. package/amd/SplitMenuButton-a2001b04.js +1 -1
  241. package/amd/StyledCard-1f13531d.js +2 -0
  242. package/amd/{StyledCard-09c9f9c0.js.map → StyledCard-1f13531d.js.map} +1 -1
  243. package/amd/{StyledLabelValueLayout-2524f5c3.js → StyledLabelValueLayout-0353a9b8.js} +2 -2
  244. package/amd/{StyledLabelValueLayout-2524f5c3.js.map → StyledLabelValueLayout-0353a9b8.js.map} +1 -1
  245. package/amd/StyledTextField-5dcd2ff4.js +1 -1
  246. package/amd/TabBar-0b3704ca.js +2 -0
  247. package/amd/{TabBar-ca32462a.js.map → TabBar-0b3704ca.js.map} +1 -1
  248. package/amd/TabBarItem-4ff2ef15.js +1 -1
  249. package/amd/TabBarLayout-95e78962.js +1 -1
  250. package/amd/TabBarMixed-1cfdf66e.js +2 -0
  251. package/amd/{TabBarMixed-dab4e4a2.js.map → TabBarMixed-1cfdf66e.js.map} +1 -1
  252. package/amd/{TabBarMixedSeparator-53d205c8.js → TabBarMixedSeparator-b4c6eb9d.js} +2 -2
  253. package/amd/{TabBarMixedSeparator-53d205c8.js.map → TabBarMixedSeparator-b4c6eb9d.js.map} +1 -1
  254. package/amd/{Table-f5ebf3d4.js → Table-f1101855.js} +2 -2
  255. package/amd/{Table-f5ebf3d4.js.map → Table-f1101855.js.map} +1 -1
  256. package/amd/{TableView-e8cab364.js → TableView-c72953df.js} +2 -2
  257. package/amd/{TableView-e8cab364.js.map → TableView-c72953df.js.map} +1 -1
  258. package/amd/TagCloud-39552a78.js +1 -1
  259. package/amd/TextArea-fe8d9067.js +2 -0
  260. package/amd/TextArea-fe8d9067.js.map +1 -0
  261. package/amd/TextAreaAutosize-c9c00a1c.js +2 -0
  262. package/amd/{TextAreaAutosize-8cac0a54.js.map → TextAreaAutosize-c9c00a1c.js.map} +1 -1
  263. package/amd/TextField-c16917d8.js +1 -1
  264. package/amd/TextFieldInput-e86a1d08.js +1 -1
  265. package/amd/Theme-redwood/theme.css +237 -237
  266. package/amd/Theme-stable/theme.css +298 -298
  267. package/amd/TimeComponentCanvas2D-82ebf0c7.js +1 -1
  268. package/amd/Toolbar-fe110698.js +1 -1
  269. package/amd/TruncatingBadge-1a265367.js +1 -1
  270. package/amd/TruncatingText-eb4bd8ab.js +1 -1
  271. package/amd/UNSAFE_ActionCard.js +1 -1
  272. package/amd/UNSAFE_BarChart/__test__/BarChart.spec.js +1 -1
  273. package/amd/UNSAFE_BarChart.js +1 -1
  274. package/amd/UNSAFE_BaseButton.js +1 -1
  275. package/amd/UNSAFE_Button.js +1 -1
  276. package/amd/UNSAFE_ButtonLayout/tests/ButtonLayout.spec.js +1 -1
  277. package/amd/UNSAFE_ButtonSet.js +1 -1
  278. package/amd/UNSAFE_ButtonSetButton.js +1 -1
  279. package/amd/UNSAFE_ButtonSetIconButton.js +1 -1
  280. package/amd/UNSAFE_ButtonSetItem.js +1 -1
  281. package/amd/UNSAFE_ButtonSetMultiple.js +1 -1
  282. package/amd/UNSAFE_ButtonSetSingle.js +1 -1
  283. package/amd/UNSAFE_Card.js +1 -1
  284. package/amd/UNSAFE_CardFlexView.js +1 -1
  285. package/amd/UNSAFE_CardGridView.js +1 -1
  286. package/amd/UNSAFE_Center.js +1 -1
  287. package/amd/UNSAFE_Checkbox.js +1 -1
  288. package/amd/UNSAFE_CheckboxItem.js +1 -1
  289. package/amd/UNSAFE_CheckboxSet.js +1 -1
  290. package/amd/UNSAFE_Chip.js +1 -1
  291. package/amd/UNSAFE_Collapsible.js +1 -1
  292. package/amd/UNSAFE_ComboChart.js +1 -1
  293. package/amd/UNSAFE_ComponentMessage.js +1 -1
  294. package/amd/UNSAFE_ConveyorBelt.js +1 -1
  295. package/amd/UNSAFE_DatePicker.js +1 -1
  296. package/amd/UNSAFE_Diagram.js +1 -1
  297. package/amd/UNSAFE_Dialog.js +1 -1
  298. package/amd/UNSAFE_DragHandle.js +1 -1
  299. package/amd/UNSAFE_DrawerLayout.js +1 -1
  300. package/amd/UNSAFE_DrawerPopup.js +1 -1
  301. package/amd/UNSAFE_Dropdown.js +1 -1
  302. package/amd/UNSAFE_Environment.js +1 -1
  303. package/amd/UNSAFE_ExpandableList.js +1 -1
  304. package/amd/UNSAFE_FilePicker.js +1 -1
  305. package/amd/UNSAFE_Flex.js +1 -1
  306. package/amd/UNSAFE_Floating.js +1 -1
  307. package/amd/UNSAFE_FormLayout.js +1 -1
  308. package/amd/UNSAFE_Gantt.js +1 -1
  309. package/amd/UNSAFE_Grid.js +1 -1
  310. package/amd/UNSAFE_HighlightText.js +1 -1
  311. package/amd/UNSAFE_Icon.js +1 -1
  312. package/amd/UNSAFE_IconButton.js +1 -1
  313. package/amd/UNSAFE_IconMenuButton.js +1 -1
  314. package/amd/UNSAFE_IconProgressButton.js +1 -1
  315. package/amd/UNSAFE_IconToggleButton.js +1 -1
  316. package/amd/UNSAFE_Indexer.js +1 -1
  317. package/amd/UNSAFE_InputDateMask.js +1 -1
  318. package/amd/UNSAFE_InputDatePicker.js +1 -1
  319. package/amd/UNSAFE_InputPassword.js +1 -1
  320. package/amd/UNSAFE_InputSensitiveText.js +1 -1
  321. package/amd/UNSAFE_InputText.js +1 -1
  322. package/amd/UNSAFE_InputTimeMask.js +1 -1
  323. package/amd/UNSAFE_Label.js +1 -1
  324. package/amd/UNSAFE_LabelValueLayout.js +1 -1
  325. package/amd/UNSAFE_LabelledLink.js +1 -1
  326. package/amd/UNSAFE_Layer.js +1 -1
  327. package/amd/UNSAFE_Legend.js +1 -1
  328. package/amd/UNSAFE_LineAreaChart.js +1 -1
  329. package/amd/UNSAFE_Link.js +1 -1
  330. package/amd/UNSAFE_ListItemLayout.js +1 -1
  331. package/amd/UNSAFE_ListView.js +1 -1
  332. package/amd/UNSAFE_LiveRegion.js +1 -1
  333. package/amd/UNSAFE_Menu.js +1 -1
  334. package/amd/UNSAFE_MenuButton.js +1 -1
  335. package/amd/UNSAFE_MessageBanner.js +1 -1
  336. package/amd/UNSAFE_MessageToast.js +1 -1
  337. package/amd/UNSAFE_MeterBar.js +1 -1
  338. package/amd/UNSAFE_MeterCircle.js +1 -1
  339. package/amd/UNSAFE_Modal.js +1 -1
  340. package/amd/UNSAFE_NavigationList.js +1 -1
  341. package/amd/UNSAFE_NavigationListCommon.js +1 -1
  342. package/amd/UNSAFE_NumberInputText.js +1 -1
  343. package/amd/UNSAFE_OverflowTabBar.js +1 -1
  344. package/amd/UNSAFE_PictoChart.js +1 -1
  345. package/amd/UNSAFE_PieChart/__test__/PieChart.spec.js +1 -1
  346. package/amd/UNSAFE_PieChart.js +1 -1
  347. package/amd/UNSAFE_Popup.js +1 -1
  348. package/amd/UNSAFE_ProgressBar.js +1 -1
  349. package/amd/UNSAFE_ProgressButton.js +1 -1
  350. package/amd/UNSAFE_ProgressButtonLabelLayout.js +1 -1
  351. package/amd/UNSAFE_ProgressCircle.js +1 -1
  352. package/amd/UNSAFE_RadioItem.js +1 -1
  353. package/amd/UNSAFE_RadioSet.js +1 -1
  354. package/amd/UNSAFE_RatingGauge.js +1 -1
  355. package/amd/UNSAFE_ReorderableTabBar.js +1 -1
  356. package/amd/UNSAFE_RichCheckboxSet.js +1 -1
  357. package/amd/UNSAFE_RichRadioSet.js +1 -1
  358. package/amd/UNSAFE_RichSelectionItem.js +1 -1
  359. package/amd/UNSAFE_ScatterChart.js +1 -1
  360. package/amd/UNSAFE_SectionalLegend.js +1 -1
  361. package/amd/UNSAFE_SelectMultiple.js +1 -1
  362. package/amd/UNSAFE_SelectSingle.js +1 -1
  363. package/amd/UNSAFE_SelectionCard.js +1 -1
  364. package/amd/UNSAFE_Selector.js +1 -1
  365. package/amd/UNSAFE_SelectorAll.js +1 -1
  366. package/amd/UNSAFE_Sheet/__test__/Sheet.spec.js +1 -1
  367. package/amd/UNSAFE_Sheet.js +1 -1
  368. package/amd/UNSAFE_SplitMenuButton.js +1 -1
  369. package/amd/UNSAFE_TabBar.js +1 -1
  370. package/amd/UNSAFE_TabBarCommon.js +1 -1
  371. package/amd/UNSAFE_TabBarMixed.js +1 -1
  372. package/amd/UNSAFE_TableView.js +1 -1
  373. package/amd/UNSAFE_TagCloud.js +1 -1
  374. package/amd/UNSAFE_TextArea.js +1 -1
  375. package/amd/UNSAFE_TextAreaAutosize.js +1 -1
  376. package/amd/UNSAFE_TextField.js +1 -1
  377. package/amd/UNSAFE_ToggleButton.js +1 -1
  378. package/amd/UNSAFE_Toolbar/tests/Toolbar.spec.js +1 -1
  379. package/amd/UNSAFE_Toolbar.js +1 -1
  380. package/amd/UNSAFE_Train.js +1 -1
  381. package/amd/UNSAFE_TruncatingBadge.js +1 -1
  382. package/amd/UNSAFE_TruncatingText.js +1 -1
  383. package/amd/UNSAFE_UserAssistance.js +1 -1
  384. package/amd/UNSAFE_View.js +1 -1
  385. package/amd/UNSAFE_VirtualizedListView.js +1 -1
  386. package/amd/UNSAFE_VisProgressiveLoader/__test__/VisProgressiveLoader.spec.js +1 -1
  387. package/amd/UNSAFE_VisProgressiveLoader.js +1 -1
  388. package/amd/UNSAFE_VisStatusMessage.js +1 -1
  389. package/amd/UNSAFE_WindowOverlay.js +1 -1
  390. package/amd/{View-db26162c.js → View-b5d6b669.js} +2 -2
  391. package/amd/{View-db26162c.js.map → View-b5d6b669.js.map} +1 -1
  392. package/amd/{VirtualizedCollection-63223f5e.js → VirtualizedCollection-897516a5.js} +2 -2
  393. package/amd/{VirtualizedCollection-63223f5e.js.map → VirtualizedCollection-897516a5.js.map} +1 -1
  394. package/amd/{VirtualizedListView-d353d174.js → VirtualizedListView-0b9e1c53.js} +2 -2
  395. package/amd/{VirtualizedListView-d353d174.js.map → VirtualizedListView-0b9e1c53.js.map} +1 -1
  396. package/amd/{VisNoData-7090c864.js → VisNoData-32b7088b.js} +2 -2
  397. package/amd/{VisNoData-7090c864.js.map → VisNoData-32b7088b.js.map} +1 -1
  398. package/amd/{VisProgressiveLoader-6a3b479f.js → VisProgressiveLoader-8cf832a4.js} +2 -2
  399. package/amd/{VisProgressiveLoader-6a3b479f.js.map → VisProgressiveLoader-8cf832a4.js.map} +1 -1
  400. package/amd/{VisTabularDatatip-0b630f9d.js → VisTabularDatatip-03ba9ae5.js} +2 -2
  401. package/amd/{VisTabularDatatip-0b630f9d.js.map → VisTabularDatatip-03ba9ae5.js.map} +1 -1
  402. package/amd/{WindowOverlay-c390f525.js → WindowOverlay-19cd633a.js} +2 -2
  403. package/amd/{WindowOverlay-c390f525.js.map → WindowOverlay-19cd633a.js.map} +1 -1
  404. package/amd/{YearsGridView-e645d5de.js → YearsGridView-84898309.js} +2 -2
  405. package/amd/{YearsGridView-e645d5de.js.map → YearsGridView-84898309.js.map} +1 -1
  406. package/amd/hoc/PRIVATE_withDirectionIcon.js +1 -1
  407. package/amd/hoc/PRIVATE_withThemeIcon.js +1 -1
  408. package/amd/hoc/UNSAFE_withThemeProps.js +1 -1
  409. package/amd/hooks/PRIVATE_useChartContextMenu.js +1 -1
  410. package/amd/hooks/PRIVATE_useChartDatatip.js +1 -1
  411. package/amd/hooks/PRIVATE_useChartEvents.js +1 -1
  412. package/amd/hooks/PRIVATE_useChartMarquee.js +1 -1
  413. package/amd/hooks/PRIVATE_useCssVars.js +1 -1
  414. package/amd/hooks/PRIVATE_useCurrentKey.js +1 -1
  415. package/amd/hooks/PRIVATE_useDatatip.js +1 -1
  416. package/amd/hooks/PRIVATE_useFloating.js +1 -1
  417. package/amd/hooks/PRIVATE_useReorderable.js +1 -1
  418. package/amd/hooks/PRIVATE_useRovingTabIndexContainer.js +1 -1
  419. package/amd/hooks/PRIVATE_useSelection.js +1 -1
  420. package/amd/hooks/PRIVATE_useTabBar.js +1 -1
  421. package/amd/hooks/PRIVATE_useTooltipOnTruncation.js +1 -1
  422. package/amd/hooks/PRIVATE_useVisContextMenu.js +1 -1
  423. package/amd/hooks/PRIVATE_useVisDragModeControls.js +1 -1
  424. package/amd/hooks/PRIVATE_useVisEvents.js +1 -1
  425. package/amd/hooks/PRIVATE_useVisMeterEvents.js +1 -1
  426. package/amd/hooks/PRIVATE_useVisSelection.js +1 -1
  427. package/amd/hooks/UNSAFE_useColorScheme.js +1 -1
  428. package/amd/hooks/UNSAFE_useCurrentBgColor.js +1 -1
  429. package/amd/hooks/UNSAFE_useDensity.js +1 -1
  430. package/amd/hooks/UNSAFE_useOutsideClick.js +1 -1
  431. package/amd/hooks/UNSAFE_usePrefixSuffix.js +1 -1
  432. package/amd/hooks/UNSAFE_useScale.js +1 -1
  433. package/amd/hooks/UNSAFE_useTestId.js +1 -1
  434. package/amd/hooks/UNSAFE_useTheme.js +1 -1
  435. package/amd/hooks/UNSAFE_useThemeInterpolations.js +1 -1
  436. package/amd/hooks/UNSAFE_useTooltip.js +1 -1
  437. package/amd/hooks/UNSAFE_useTranslationBundle.js +1 -1
  438. package/amd/hooks/UNSAFE_useUser.js +1 -1
  439. package/amd/{index-91628308.js → index-9fe6dba4.js} +2 -2
  440. package/amd/index-9fe6dba4.js.map +1 -0
  441. package/amd/listViewSelectionTests-cda5abdf.js +1 -1
  442. package/amd/{popupUtils-97c14340.js → popupUtils-4c7037ca.js} +2 -2
  443. package/amd/{popupUtils-97c14340.js.map → popupUtils-4c7037ca.js.map} +1 -1
  444. package/amd/{render-26bfba97.js → render-60c60d58.js} +2 -2
  445. package/amd/{render-26bfba97.js.map → render-60c60d58.js.map} +1 -1
  446. package/amd/{tabbableUtils-e35b5cb9.js → tabbableUtils-91cb6674.js} +2 -2
  447. package/amd/{tabbableUtils-e35b5cb9.js.map → tabbableUtils-91cb6674.js.map} +1 -1
  448. package/amd/{testData-1796f319.js → testData-752ed27b.js} +2 -2
  449. package/amd/{testData-1796f319.js.map → testData-752ed27b.js.map} +1 -1
  450. package/amd/tooltipUtils-36ddb881.js +2 -0
  451. package/amd/{tooltipUtils-30886397.js.map → tooltipUtils-36ddb881.js.map} +1 -1
  452. package/amd/useCellNavigation-4138513e.js +1 -1
  453. package/amd/useChartContextMenu-59a5f8c0.js +1 -1
  454. package/amd/useChartDatatip-777fcfb2.js +2 -0
  455. package/amd/{useChartDatatip-b75883b6.js.map → useChartDatatip-777fcfb2.js.map} +1 -1
  456. package/amd/{useColorScheme-6b864d5c.js → useColorScheme-09a67d56.js} +2 -2
  457. package/amd/{useColorScheme-6b864d5c.js.map → useColorScheme-09a67d56.js.map} +1 -1
  458. package/amd/useContextMenu-dacffeb2.js +1 -1
  459. package/amd/useCssVars-311f2956.js +2 -0
  460. package/amd/{useCssVars-cc825c54.js.map → useCssVars-311f2956.js.map} +1 -1
  461. package/amd/{useCurrentBgColor-df47f8a8.js → useCurrentBgColor-dc922fe6.js} +2 -2
  462. package/amd/{useCurrentBgColor-df47f8a8.js.map → useCurrentBgColor-dc922fe6.js.map} +1 -1
  463. package/amd/useCurrentKey-e8791885.js +2 -0
  464. package/amd/{useCurrentKey-b0a79216.js.map → useCurrentKey-e8791885.js.map} +1 -1
  465. package/amd/{useDatatip-be9b251b.js → useDatatip-8a63fb35.js} +2 -2
  466. package/amd/{useDatatip-be9b251b.js.map → useDatatip-8a63fb35.js.map} +1 -1
  467. package/amd/{useDensity-27fffd88.js → useDensity-90a49922.js} +2 -2
  468. package/amd/{useDensity-27fffd88.js.map → useDensity-90a49922.js.map} +1 -1
  469. package/amd/{useFloating-f9bd3c51.js → useFloating-4b145893.js} +2 -2
  470. package/amd/{useFloating-f9bd3c51.js.map → useFloating-4b145893.js.map} +1 -1
  471. package/amd/useKeyboardEvents-f8b3ead1.js +2 -0
  472. package/amd/{useKeyboardEvents-ce9c81d0.js.map → useKeyboardEvents-f8b3ead1.js.map} +1 -1
  473. package/amd/useLegendContextMenu-c4a44c23.js +1 -1
  474. package/amd/useMeterDatatip-5d0b02c1.js +2 -0
  475. package/amd/{useMeterDatatip-f8bca628.js.map → useMeterDatatip-5d0b02c1.js.map} +1 -1
  476. package/amd/useNavigationListItem-d79484b7.js +2 -0
  477. package/{es/useNavigationListItem-a28f2c34.js.map → amd/useNavigationListItem-d79484b7.js.map} +1 -1
  478. package/amd/{useOutsideClick-43ce7043.js → useOutsideClick-8e7ab184.js} +2 -2
  479. package/amd/{useOutsideClick-43ce7043.js.map → useOutsideClick-8e7ab184.js.map} +1 -1
  480. package/amd/{usePopupAnimation-65dec4e2.js → usePopupAnimation-1be03bd7.js} +2 -2
  481. package/amd/{usePopupAnimation-65dec4e2.js.map → usePopupAnimation-1be03bd7.js.map} +1 -1
  482. package/amd/{usePrefixSuffix-5147bdc9.js → usePrefixSuffix-2612edcd.js} +2 -2
  483. package/amd/{usePrefixSuffix-5147bdc9.js.map → usePrefixSuffix-2612edcd.js.map} +1 -1
  484. package/amd/{useReorderableItem-9e759302.js → useReorderableItem-41e78941.js} +2 -2
  485. package/amd/{useReorderableItem-9e759302.js.map → useReorderableItem-41e78941.js.map} +1 -1
  486. package/amd/{useRovingTabIndexContainer-cfc9aacb.js → useRovingTabIndexContainer-6ff38598.js} +2 -2
  487. package/amd/{useRovingTabIndexContainer-cfc9aacb.js.map → useRovingTabIndexContainer-6ff38598.js.map} +1 -1
  488. package/amd/{useScale-716d3432.js → useScale-b77dadab.js} +2 -2
  489. package/amd/{useScale-716d3432.js.map → useScale-b77dadab.js.map} +1 -1
  490. package/amd/{useSelectCommon-380baecd.js → useSelectCommon-70527342.js} +2 -2
  491. package/amd/{useSelectCommon-380baecd.js.map → useSelectCommon-70527342.js.map} +1 -1
  492. package/amd/{useSelectDrill-113ae3ae.js → useSelectDrill-b64a92ea.js} +2 -2
  493. package/amd/{useSelectDrill-113ae3ae.js.map → useSelectDrill-b64a92ea.js.map} +1 -1
  494. package/amd/{useSelection-5f192f9f.js → useSelection-5ea9a696.js} +2 -2
  495. package/amd/{useSelection-5f192f9f.js.map → useSelection-5ea9a696.js.map} +1 -1
  496. package/amd/{useSelection-80e262f2.js → useSelection-6e62de17.js} +2 -2
  497. package/amd/{useSelection-80e262f2.js.map → useSelection-6e62de17.js.map} +1 -1
  498. package/amd/useTabBar-7a16a1af.js +1 -1
  499. package/amd/{useTestId-c286f212.js → useTestId-0140aa44.js} +2 -2
  500. package/amd/{useTestId-c286f212.js.map → useTestId-0140aa44.js.map} +1 -1
  501. package/amd/{useTheme-9c1f6f33.js → useTheme-4fb0ea9d.js} +2 -2
  502. package/amd/{useTheme-9c1f6f33.js.map → useTheme-4fb0ea9d.js.map} +1 -1
  503. package/amd/useThemeInterpolations-3ca974f9.js +2 -0
  504. package/amd/{useThemeInterpolations-f8cbec71.js.map → useThemeInterpolations-3ca974f9.js.map} +1 -1
  505. package/amd/{useTooltip-7b915f4c.js → useTooltip-682ae8ca.js} +2 -2
  506. package/amd/{useTooltip-7b915f4c.js.map → useTooltip-682ae8ca.js.map} +1 -1
  507. package/amd/useTooltipOnTruncation-7721f587.js +2 -0
  508. package/amd/{useTooltipOnTruncation-0310f431.js.map → useTooltipOnTruncation-7721f587.js.map} +1 -1
  509. package/amd/{useTranslationBundle-7c40cb58.js → useTranslationBundle-68275657.js} +2 -2
  510. package/amd/{useTranslationBundle-7c40cb58.js.map → useTranslationBundle-68275657.js.map} +1 -1
  511. package/amd/{useUser-797287de.js → useUser-e8dd7f7c.js} +2 -2
  512. package/amd/{useUser-797287de.js.map → useUser-e8dd7f7c.js.map} +1 -1
  513. package/amd/useVisDragModeControls-f187d8b2.js +1 -1
  514. package/amd/{useVisEvents-a8ea4ced.js → useVisEvents-1d3ca08e.js} +2 -2
  515. package/amd/{useVisEvents-a8ea4ced.js.map → useVisEvents-1d3ca08e.js.map} +1 -1
  516. package/amd/utils/PRIVATE_tooltipUtils.js +1 -1
  517. package/amd/utils/PRIVATE_visTestUtils.js +1 -1
  518. package/amd/utils/UNSAFE_popupUtils.js +1 -1
  519. package/amd/{withDirectionIcon-6df16f77.js → withDirectionIcon-754809be.js} +2 -2
  520. package/amd/{withDirectionIcon-6df16f77.js.map → withDirectionIcon-754809be.js.map} +1 -1
  521. package/amd/withThemeProps-cab1ae08.js +1 -1
  522. package/cjs/{BaseCardView-5c483f52.js → BaseCardView-0be36db0.js} +2 -2
  523. package/cjs/{BaseCardView-5c483f52.js.map → BaseCardView-0be36db0.js.map} +1 -1
  524. package/cjs/{CardFlexView-385f1b2d.js → CardFlexView-2547fc13.js} +2 -2
  525. package/cjs/{CardFlexView-385f1b2d.js.map → CardFlexView-2547fc13.js.map} +1 -1
  526. package/cjs/{CardGridView-d337b9f4.js → CardGridView-c355e9d4.js} +2 -2
  527. package/cjs/{CardGridView-d337b9f4.js.map → CardGridView-c355e9d4.js.map} +1 -1
  528. package/cjs/ExpandableList-0a0d75b3.js +1 -1
  529. package/cjs/GroupLoadingIndicator-824d658f.js +1 -1
  530. package/cjs/{Indexer-a4a2d6b8.js → Indexer-099ecbad.js} +2 -2
  531. package/cjs/{Indexer-a4a2d6b8.js.map → Indexer-099ecbad.js.map} +1 -1
  532. package/cjs/{List-bad74e43.js → List-24abb3df.js} +3 -4
  533. package/cjs/{List-bad74e43.js.map → List-24abb3df.js.map} +1 -1
  534. package/cjs/{ListView-80a9c725.js → ListView-7e894199.js} +2 -2
  535. package/cjs/{ListView-80a9c725.js.map → ListView-7e894199.js.map} +1 -1
  536. package/cjs/{LoadMoreCollection-73112ff0.js → LoadMoreCollection-69bc038c.js} +2 -2
  537. package/cjs/{LoadMoreCollection-73112ff0.js.map → LoadMoreCollection-69bc038c.js.map} +1 -1
  538. package/cjs/PRIVATE_BaseCardView.js +3 -3
  539. package/cjs/PRIVATE_List.js +4 -4
  540. package/cjs/PRIVATE_LoadMoreCollection.js +2 -2
  541. package/cjs/PRIVATE_SelectCommon.js +5 -5
  542. package/cjs/PRIVATE_Table.js +3 -3
  543. package/cjs/PRIVATE_VirtualizedCollection.js +2 -2
  544. package/cjs/{SelectMultiple-3569988d.js → SelectMultiple-3582b180.js} +2 -2
  545. package/cjs/{SelectMultiple-3569988d.js.map → SelectMultiple-3582b180.js.map} +1 -1
  546. package/cjs/{SelectSingle-43d6953e.js → SelectSingle-d4a4de82.js} +2 -2
  547. package/cjs/{SelectSingle-43d6953e.js.map → SelectSingle-d4a4de82.js.map} +1 -1
  548. package/cjs/{Table-6987731e.js → Table-f225ad02.js} +2 -2
  549. package/cjs/{Table-6987731e.js.map → Table-f225ad02.js.map} +1 -1
  550. package/cjs/{TableView-1bed3e0b.js → TableView-6dcc1bd7.js} +2 -2
  551. package/cjs/{TableView-1bed3e0b.js.map → TableView-6dcc1bd7.js.map} +1 -1
  552. package/cjs/Theme-redwood/theme.css +227 -227
  553. package/cjs/Theme-stable/theme.css +386 -386
  554. package/cjs/UNSAFE_CardFlexView.js +4 -4
  555. package/cjs/UNSAFE_CardGridView.js +4 -4
  556. package/cjs/UNSAFE_ExpandableList.js +3 -3
  557. package/cjs/UNSAFE_Indexer.js +2 -2
  558. package/cjs/UNSAFE_ListView.js +5 -5
  559. package/cjs/UNSAFE_SelectMultiple.js +6 -6
  560. package/cjs/UNSAFE_SelectSingle.js +6 -6
  561. package/cjs/UNSAFE_TableView.js +4 -4
  562. package/cjs/UNSAFE_VirtualizedListView.js +5 -5
  563. package/cjs/{VirtualizedCollection-00aedb8b.js → VirtualizedCollection-9e8c48b9.js} +2 -2
  564. package/cjs/{VirtualizedCollection-00aedb8b.js.map → VirtualizedCollection-9e8c48b9.js.map} +1 -1
  565. package/cjs/{VirtualizedListView-ad3219ba.js → VirtualizedListView-0a4f07ca.js} +2 -2
  566. package/cjs/{VirtualizedListView-ad3219ba.js.map → VirtualizedListView-0a4f07ca.js.map} +1 -1
  567. package/cjs/{useSelectCommon-38a38427.js → useSelectCommon-21c36506.js} +2 -2
  568. package/cjs/{useSelectCommon-38a38427.js.map → useSelectCommon-21c36506.js.map} +1 -1
  569. package/es/{useNavigationListItem-a28f2c34.js → BaseNavigationListItem-af84a9ee.js} +41 -3
  570. package/{amd/BaseNavigationListItem-84f4be5c.js.map → es/BaseNavigationListItem-af84a9ee.js.map} +1 -1
  571. package/es/CheckboxSet-140804f2.js +49 -0
  572. package/es/CheckboxSet-140804f2.js.map +1 -0
  573. package/es/{InputDatePicker-a659ed3a.js → InputDatePicker-163d1e3f.js} +2 -2
  574. package/es/{InputDatePicker-a659ed3a.js.map → InputDatePicker-163d1e3f.js.map} +1 -1
  575. package/es/{NavigationList-fb05e081.js → NavigationListItem-07f041e6.js} +7 -3
  576. package/{amd/NavigationListItem-32ded4a5.js.map → es/NavigationListItem-07f041e6.js.map} +1 -1
  577. package/es/{OverflowTabBar-894c7cd9.js → OverflowTabBar-f0b62902.js} +3 -3
  578. package/es/{OverflowTabBar-894c7cd9.js.map → OverflowTabBar-f0b62902.js.map} +1 -1
  579. package/es/{OverflowTabBarItem-a578401b.js → OverflowTabBarItem-7acbcb71.js} +3 -4
  580. package/es/{OverflowTabBarItem-a578401b.js.map → OverflowTabBarItem-7acbcb71.js.map} +1 -1
  581. package/es/{RemovableNavigationListItem-21cd36b7.js → RemovableNavigationListItem-9cb23511.js} +2 -3
  582. package/es/{RemovableNavigationListItem-21cd36b7.js.map → RemovableNavigationListItem-9cb23511.js.map} +1 -1
  583. package/es/{ReorderableTabBar-c280e7d4.js → ReorderableTabBar-fc76a33b.js} +2 -2
  584. package/es/{ReorderableTabBar-c280e7d4.js.map → ReorderableTabBar-fc76a33b.js.map} +1 -1
  585. package/es/SegmentStyles.styles.css +11 -8
  586. package/es/SegmentStyles.styles2.css +8 -11
  587. package/es/{TabBar-4d7054f7.js → TabBar-2858ff9c.js} +1 -6
  588. package/es/{TabBar-4d7054f7.js.map → TabBar-2858ff9c.js.map} +1 -1
  589. package/es/{TabBarMixed-b8e2427c.js → TabBarMixed-a4beabce.js} +1 -6
  590. package/es/{TabBarMixed-b8e2427c.js.map → TabBarMixed-a4beabce.js.map} +1 -1
  591. package/es/Theme-redwood/theme.css +453 -453
  592. package/es/Theme-stable/theme.css +507 -507
  593. package/es/UNSAFE_CheckboxItem.js +83 -31
  594. package/es/UNSAFE_CheckboxItem.js.map +1 -1
  595. package/es/UNSAFE_CheckboxSet.js +10 -44
  596. package/es/UNSAFE_CheckboxSet.js.map +1 -1
  597. package/es/UNSAFE_InputDateMask/themes/SegmentStyles.css.js +1 -1
  598. package/es/UNSAFE_InputDateMask.js +1 -1
  599. package/es/UNSAFE_InputDatePicker.js +92 -92
  600. package/es/UNSAFE_InputTimeMask/themes/SegmentStyles.css.js +1 -1
  601. package/es/UNSAFE_InputTimeMask.js +1 -1
  602. package/es/UNSAFE_NavigationList.js +26 -28
  603. package/es/UNSAFE_NavigationList.js.map +1 -1
  604. package/es/UNSAFE_NavigationListCommon.js +56 -57
  605. package/es/UNSAFE_NavigationListCommon.js.map +1 -1
  606. package/es/UNSAFE_OverflowTabBar.js +27 -29
  607. package/es/UNSAFE_OverflowTabBar.js.map +1 -1
  608. package/es/UNSAFE_ReorderableTabBar.js +14 -25
  609. package/es/UNSAFE_ReorderableTabBar.js.map +1 -1
  610. package/es/UNSAFE_RichCheckboxSet.js +28 -25
  611. package/es/UNSAFE_RichCheckboxSet.js.map +1 -1
  612. package/es/UNSAFE_RichSelectionItem.js +183 -44
  613. package/es/UNSAFE_RichSelectionItem.js.map +1 -1
  614. package/es/UNSAFE_TabBar.js +26 -28
  615. package/es/UNSAFE_TabBar.js.map +1 -1
  616. package/es/UNSAFE_TabBarCommon.js +18 -20
  617. package/es/UNSAFE_TabBarCommon.js.map +1 -1
  618. package/es/UNSAFE_TabBarMixed.js +37 -39
  619. package/es/UNSAFE_TabBarMixed.js.map +1 -1
  620. package/package.json +2 -2
  621. package/amd/BaseNavigationListItem-84f4be5c.js +0 -2
  622. package/amd/Card-70e5f9f2.js +0 -2
  623. package/amd/CardFlexView-f7fdfac8.js +0 -2
  624. package/amd/CardGridView-b8a60fae.js +0 -2
  625. package/amd/CompactLabelAssistance-9f9f658d.js +0 -2
  626. package/amd/Grid-a8a51c37.js +0 -2
  627. package/amd/HighlightText-ded0d51b.js +0 -2
  628. package/amd/InputDatePicker-03bdeb95.js +0 -2
  629. package/amd/List-0da6ee9c.js +0 -2
  630. package/amd/LiveRegion-1917f798.js +0 -2
  631. package/amd/LoadMoreCollection-a6adbc3f.js +0 -2
  632. package/amd/MaxLengthCounter-9a95922c.js +0 -2
  633. package/amd/MaxLengthCounter-9a95922c.js.map +0 -1
  634. package/amd/NavigationListItem-32ded4a5.js +0 -2
  635. package/amd/OverflowTabBarItem-f8128e3d.js +0 -2
  636. package/amd/RemovableNavigationListItem-1f69907c.js +0 -2
  637. package/amd/SectionedContent-ef1f844c.js +0 -2
  638. package/amd/SelectionCard-a8a3bb2d.js +0 -2
  639. package/amd/StyledCard-09c9f9c0.js +0 -2
  640. package/amd/TabBar-ca32462a.js +0 -2
  641. package/amd/TabBarMixed-dab4e4a2.js +0 -2
  642. package/amd/TextArea-0ec1a311.js +0 -2
  643. package/amd/TextArea-0ec1a311.js.map +0 -1
  644. package/amd/TextAreaAutosize-8cac0a54.js +0 -2
  645. package/amd/index-91628308.js.map +0 -1
  646. package/amd/tooltipUtils-30886397.js +0 -2
  647. package/amd/useChartDatatip-b75883b6.js +0 -2
  648. package/amd/useCssVars-cc825c54.js +0 -2
  649. package/amd/useCurrentKey-b0a79216.js +0 -2
  650. package/amd/useKeyboardEvents-ce9c81d0.js +0 -2
  651. package/amd/useMeterDatatip-f8bca628.js +0 -2
  652. package/amd/useThemeInterpolations-f8cbec71.js +0 -2
  653. package/amd/useTooltipOnTruncation-0310f431.js +0 -2
  654. package/es/BaseNavigationListItem-1c75c13f.js +0 -47
  655. package/es/CheckboxSetContext-1be56556.js +0 -9
  656. package/es/CheckboxSetContext-1be56556.js.map +0 -1
  657. package/es/NavigationListItem-193a315a.js +0 -10
@@ -1 +1 @@
1
- {"version":3,"file":"ListView-cdfac903.js","sources":["../../src/UNSAFE_ListView/ScrollPositionUtils.ts","../../src/UNSAFE_ListView/ListViewReorderableItem.tsx","../../src/UNSAFE_ListView/ListViewContextMenu.tsx","../../src/UNSAFE_ListView/useListViewContextMenu.ts","../../src/UNSAFE_ListView/ListView.tsx","../../src/UNSAFE_ListView/useListViewCurrentItemOverride.tsx","../../src/UNSAFE_ListView/useListViewReorder.ts"],"sourcesContent":["/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { getKey } from '../utils/PRIVATE_collectionUtils';\n\n/**\n * Type for scroll position in ListView\n */\nexport type ListViewScrollPosition<K> = {\n offsetY?: number;\n key?: K;\n y?: number;\n};\n\n/**\n * Returns the key for the row at the given index\n */\nconst getKeyForIndex = (root: HTMLElement, index: number) => {\n if (root != null) {\n const rowElements = root.querySelectorAll(`[role='row']`);\n if (rowElements.length > index) {\n return getKey(rowElements[index] as HTMLElement);\n }\n }\n return null;\n};\n\nexport function getScrollPosition<K>(root: HTMLDivElement, newScrollTop?: number) {\n // ensure scroll position y value is initialized\n const scrollTop = Math.abs(newScrollTop == null ? root.scrollTop : newScrollTop);\n\n const scrollPosition: ListViewScrollPosition<K> = {\n y: scrollTop,\n key: undefined,\n offsetY: undefined\n };\n\n let rowBottom = 0;\n const rowElements = root.querySelectorAll(`[role='row']`);\n if (rowElements.length > 0) {\n if (scrollTop === 0) {\n scrollPosition.key = getKeyForIndex(root, 0) as K;\n scrollPosition.offsetY = 0;\n return scrollPosition;\n }\n }\n for (let i = 0; i < rowElements.length; i++) {\n const rowHeight = rowElements[i].getBoundingClientRect().height;\n rowBottom += rowHeight;\n if (scrollTop < rowBottom) {\n scrollPosition.key = getKeyForIndex(root, i) as K;\n scrollPosition.offsetY = rowHeight + scrollTop - rowBottom;\n break;\n }\n }\n return scrollPosition;\n}\n\n/**\n * Helper to set the scroll position on the ListView.\n */\nexport function setScrollPosition<K>(\n root: HTMLDivElement,\n scrollPosition?: ListViewScrollPosition<K>\n) {\n const y = _getScrollTopFromScrollPosition(root, scrollPosition);\n root.scrollTop = y != null ? y : 0;\n}\n\n/**\n * Helper to determine the 'y' value of a given scroll position.\n */\nfunction _getScrollTopFromScrollPosition<K>(\n root: HTMLDivElement,\n scrollPosition?: ListViewScrollPosition<K>\n) {\n if (scrollPosition != null) {\n let key;\n let useRow = false;\n if (scrollPosition.key != null) {\n // key takes precedence over everything else\n useRow = true;\n key = scrollPosition.key;\n } else if (scrollPosition.offsetY != null && scrollPosition.y == null) {\n // offsetY can be used on its own if it is the only vertical aspect provided\n useRow = true;\n key = getScrollPosition(root).key;\n }\n if (useRow) {\n if (key != null) {\n let y = 0;\n const rowElements = root.querySelectorAll(`[role ='row']`);\n for (let i = 0; i < rowElements.length; i++) {\n if (key === getKey(rowElements[i] as HTMLElement)) {\n return y + (scrollPosition.offsetY != null ? scrollPosition.offsetY : 0);\n }\n y += rowElements[i].getBoundingClientRect().height;\n }\n }\n } else if (scrollPosition.y != null) {\n return scrollPosition.y;\n }\n }\n // either nothing was provided, or what was provided was invalid\n return undefined;\n}\n","import { memo } from 'preact/compat';\nimport { useRef, useCallback } from 'preact/hooks';\nimport { useReorderableItem } from '../hooks/PRIVATE_useReorderable';\nimport { ReorderableItemProps } from '../UNSAFE_Collection/Reorderable.types';\nimport { ITEM_SELECTOR } from '../utils/PRIVATE_collectionUtils';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport { styles } from './themes/ListViewStyles.css';\nimport { isKeyDefined } from '../utils/UNSAFE_keys';\n\nexport type ListReorderableItemProps<K> = ReorderableItemProps<K>;\n\n/**\n * A private item that will be used by ReorderableCardFlexView, location TBD (could be moved to PRIVATE_CardFlexView)\n */\nexport function ListViewReorderableItem<K extends string | number>({\n children,\n dragKey,\n setDragKey,\n onReorder,\n rootRef,\n itemKey\n}: ListReorderableItemProps<K> & { itemKey: K }) {\n const itemRef = useRef<HTMLDivElement | null>(null);\n const itemStyles = {\n itemOverlayFront: styles.reorderableItemOverlayFront,\n itemOverlayRear: styles.reorderableItemOverlayRear,\n itemDragger: styles.reorderableItemDragger\n };\n const getItem = () => itemRef?.current?.closest(ITEM_SELECTOR);\n const setTransferData = useCallback(\n (event: DragEvent) => {\n event.dataTransfer?.setData('text/listview-items-key', JSON.stringify(itemKey));\n },\n [itemKey]\n );\n const { rootProps, isDragged, overlayZoneBeforeProps, overlayZoneAfterProps } =\n useReorderableItem({\n isDisabled: onReorder ? false : true,\n dragKey,\n setDragKey,\n onReorder,\n rootRef,\n ref: itemRef,\n getItem,\n setTransferData,\n itemStyles,\n itemSelector: ITEM_SELECTOR,\n isVertical: true\n });\n const classes = classNames([rootProps?.class, styles.reorderableItemDnd]);\n\n return (\n <div {...rootProps} class={classes}>\n {children}\n {!isDragged && isKeyDefined(dragKey) && (\n <>\n <div {...overlayZoneBeforeProps}></div>\n <div {...overlayZoneAfterProps}></div>\n </>\n )}\n </div>\n );\n}\n\nexport const MemoizeListViewReorderableItem = memo(\n ListViewReorderableItem,\n <K,>(prev: ListReorderableItemProps<K>, next: ListReorderableItemProps<K>) => {\n if (prev && next) {\n return prev?.children === next?.children && prev?.dragKey === next?.dragKey;\n }\n return false;\n }\n);\n","/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { ComponentProps } from 'preact';\n\nimport { ListItemContext } from '#UNSAFE_Collection';\nimport { Menu } from '#UNSAFE_Menu';\nimport { ListViewContextMenuConfig } from './List.types';\n\nexport type Props<K extends string | number, D> = Omit<ComponentProps<typeof Menu>, 'children'> & {\n contextMenuConfig: ListViewContextMenuConfig<K, D>;\n} & { contextMenuContext: ListItemContext<K, D> };\n\n/**\n * The internal component used to render a custom context menu\n */\nexport function ListViewContextMenu<K extends string | number, D>({\n contextMenuConfig,\n contextMenuContext,\n ...menuProps\n}: Props<K, D>) {\n const accessibleLabel = contextMenuConfig.accessibleLabel;\n\n return (\n <>\n <Menu\n {...menuProps}\n {...(accessibleLabel && {\n 'aria-label': accessibleLabel\n })}>\n {menuProps.isOpen && contextMenuConfig.itemsRenderer(contextMenuContext)}\n </Menu>\n </>\n );\n}\n","import type { ComponentProps, RefObject } from 'preact';\nimport { useCallback, useState, useRef } from 'preact/hooks';\n\nimport { DataState, ListItemContext, CurrentKeyDetail } from '#UNSAFE_Collection';\nimport { Menu } from '#UNSAFE_Menu';\nimport { findItemContext } from '#hooks/PRIVATE_useItemAction';\nimport { useContextMenuGesture } from '#hooks/UNSAFE_useContextMenuGesture';\nimport { ITEM_SELECTOR, findElementByKey, keyExtractor } from '#utils/PRIVATE_collectionUtils';\nimport { ListView } from './ListView';\n\ntype MenuProps = Pick<\n ComponentProps<typeof Menu>,\n 'anchorRef' | 'initialFocus' | 'placement' | 'offsetValue' | 'isOpen'\n>;\n\nconst TOUCH_OFFSET_VALUE = 40;\n\nconst menuPropGestureStates: Record<\n 'mouse' | 'keyboard' | 'touch',\n Omit<Required<MenuProps>, 'anchorRef' | 'isOpen'>\n> = {\n mouse: {\n initialFocus: 'menu',\n placement: 'bottom-start',\n offsetValue: 0\n },\n keyboard: {\n initialFocus: 'firstItem',\n placement: 'bottom-start',\n offsetValue: 0\n },\n touch: {\n initialFocus: 'menu',\n placement: 'end',\n offsetValue: TOUCH_OFFSET_VALUE\n }\n};\n\nconst initialMenuProps: MenuProps = {\n isOpen: false,\n initialFocus: 'menu',\n placement: 'bottom-start',\n offsetValue: 0,\n anchorRef: { current: null }\n};\n\ntype ListViewProps<K extends string | number, D> = ComponentProps<typeof ListView<K, D>>;\n\nexport const useListViewContextMenu = <K extends string | number, D>(\n dataState: DataState<K, D> | null,\n contextMenuConfig: ListViewProps<K, D>['contextMenuConfig'],\n scrollListRef: RefObject<HTMLElement | null>,\n updateCurrentKey: (key: K) => void\n) => {\n /*Context Menu section\n TODO: A version of context Menu listview will be merged using useContextMenuGesture instead. Once it's merged we \n can go back to this to create a hook or utility that could be share among all collection comps. JET-60320\n */\n\n /* \n Steps to open a menu:\n 1.- useContextMenu handler is called when menu is supposed to be opened.\n 2.- We set contextMenuContext when contextMenuRenderer is called.\n 3.- We dispatch opening the menu with the correct anchor.\n 5.- Menu receives updated props and updated contextMenuContext.\n 6.- Menu is opened. \n\n */\n\n //Supposed to be updated when menu is about to be opened\n //We set an initial key value for the context menu context, to allow user use object destructuring inside the\n //contextMenuRenderer. It doesn't matter if the key is not correct at the initial rendering since menu starts\n //being closed always\n const [contextMenuContext, setContextMenuContext] = useState<ListItemContext<K, D>>();\n\n const [menuProps, setMenuProps] = useState<MenuProps>(initialMenuProps);\n\n const currentKeyRef = useRef<K>();\n const notifyCurrentKeyChanged = (detail: CurrentKeyDetail<K>) => {\n currentKeyRef.current = detail.value;\n };\n\n const { triggerProps } = useContextMenuGesture(\n ({ gesture, anchor, target }) => {\n let anchorBasedOnGesture = anchor;\n if (gesture === 'keyboard') {\n //We find the element where the position of the menu is going to be based of\n const elem = findElementByKey(\n scrollListRef.current as HTMLElement,\n currentKeyRef.current as K,\n ITEM_SELECTOR\n );\n\n //We set the correct anchor\n anchorBasedOnGesture = elem ? elem : anchor;\n\n const context = findItemContext(\n currentKeyRef.current as K,\n dataState as DataState<string | number | null, D>\n );\n\n setContextMenuContext(context as ListItemContext<K, D>);\n } else {\n //We search for the key using the target of the event\n const key = keyExtractor(target as HTMLElement, ITEM_SELECTOR);\n\n const context = findItemContext(key, dataState as DataState<string | number | null, D>);\n\n setContextMenuContext(context as ListItemContext<K, D>);\n\n //We update the key so when we close logical focus is on the correct item\n updateCurrentKey(key as K);\n }\n setMenuProps({\n ...menuPropGestureStates[gesture],\n anchorRef: { current: anchorBasedOnGesture },\n isOpen: true\n });\n },\n {\n isDisabled: !contextMenuConfig //If there is no a context menu renderer we disable the hook\n }\n );\n\n const handleCloseContextMenu = useCallback<Required<ComponentProps<typeof Menu>>['onClose']>(\n (detail) => {\n /* \n TODO: Focus ring should be visible when context menu was closed because of selecting an item using keyboard, \n but should not be visible when the selection was done using mouse or touch. This would probably means menu \n onClose API is going to be changed a little bit so we can satisfy this requirement. JET-62372\n */\n //Focus has to be set on the current target that was obtained\n //during context menu gesture when menu is dismissed or item is \"selected\"\n if (detail.reason === 'dismissed' || detail.reason === 'itemAction') {\n scrollListRef.current?.focus({ preventScroll: true });\n }\n // We close the menu.The only prop that matters here is isOpen\n setMenuProps({ ...initialMenuProps });\n },\n [scrollListRef]\n );\n\n return {\n menuProps: { ...menuProps, onClose: handleCloseContextMenu },\n onClose: handleCloseContextMenu,\n contextMenuContext: contextMenuContext as ListItemContext<K, D>,\n triggerProps,\n notifyCurrentKeyChanged\n } as const;\n};\n","/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { JSX } from 'preact';\nimport { ForwardedRef, forwardRef } from 'preact/compat';\nimport { useImperativeHandle, useRef, useLayoutEffect } from 'preact/hooks';\nimport { ReorderableContext } from '../hooks/PRIVATE_useReorderable';\nimport { DataState, CurrentKeyDetail } from '../UNSAFE_Collection';\nimport { HiddenAccessible } from '../UNSAFE_HiddenAccessible';\nimport { List } from '../PRIVATE_List';\nimport { ListProps, ListViewContextMenuConfig, ListViewHandle } from './List.types';\nimport {\n getScrollPosition,\n setScrollPosition,\n ListViewScrollPosition\n} from './ScrollPositionUtils';\nimport { MemoizeListViewReorderableItem } from './ListViewReorderableItem';\nimport { useListViewReorder } from './useListViewReorder';\nimport { ListViewContextMenu } from './ListViewContextMenu';\nimport { useListViewContextMenu } from './useListViewContextMenu';\nimport { useListViewCurrentItemOverride } from './useListViewCurrentItemOverride';\n\n/**\n * Props specific to non-virtualized ListView\n */\ntype NonVirtualizedListProps<K, D> = {\n /**\n * The data that is used to render each item in ListView. If the value is null, then ListView will show nothing\n * if hasMore is false, or loading indicator if hasMore is true.\n */\n data: D[] | null;\n /**\n * A callback function to extract the key which is used to identify the item.\n */\n getRowKey: (data: D) => K;\n /**\n * Whether there are more data available to load. By default this returns false.\n */\n hasMore?: boolean;\n /**\n * An optional callback function which is invoked when user scrolls to the end of the list.\n */\n onLoadMore?: () => void;\n\n /**\n * Configuration used to specify a context menu.\n */\n contextMenuConfig?: ListViewContextMenuConfig<K, D>;\n};\n\n/**\n * Props for the ListView Component\n */\nexport type Props<K, D> = Pick<\n ListProps<K, D>,\n | 'aria-label'\n | 'aria-labelledby'\n | 'children'\n | 'gridlines'\n | 'currentItemOverride'\n | 'onPersistCurrentItem'\n | 'onItemAction'\n | 'onSelectionChange'\n | 'promotedSection'\n | 'selectedKeys'\n | 'selectionMode'\n | 'viewportConfig'\n | 'testId'\n | 'scrollPositionOverride'\n | 'onReorder'\n | 'itemPadding'\n> &\n NonVirtualizedListProps<K, D>;\n/**\n * A list view displays data items as a list or a grid with highly interactive features.\n */\nexport const ListView = forwardRef(\n <K extends string | number, D>(props: Props<K, D>, ref?: ForwardedRef<ListViewHandle<K>>) => {\n const { contextMenuConfig } = props;\n const scrollPositionRef = useRef<ListViewScrollPosition<K>>();\n const listRef = useRef<HTMLDivElement | null>(null);\n\n const { currentItemOverride, updateCurrentItemOverride } = useListViewCurrentItemOverride(\n props.currentItemOverride\n );\n\n const dataMetadata = props.data\n ? props.data.map((aData: D) => {\n const key = props.getRowKey(aData);\n return { data: aData, metadata: { key } };\n })\n : null;\n\n const loadRange = props.onLoadMore ? props.onLoadMore : () => {};\n const dataState = dataMetadata\n ? ({\n offset: 0,\n data: dataMetadata,\n sizePrecision: props.hasMore ? 'atLeast' : 'exact',\n totalSize: dataMetadata.length\n } as DataState<K, D>)\n : null;\n\n useImperativeHandle(ref!, () => ({\n getScrollPosition: () => {\n if (listRef.current) {\n return getScrollPosition(listRef.current);\n }\n return { y: 0 };\n },\n focus: () => {\n if (listRef.current) {\n listRef.current.focus();\n }\n }\n }));\n\n // update scroll position if a new value is provided\n useLayoutEffect(() => {\n if (listRef.current && scrollPositionRef.current !== props.scrollPositionOverride) {\n setScrollPosition(listRef.current, props.scrollPositionOverride);\n scrollPositionRef.current = props.scrollPositionOverride;\n }\n }, [props.scrollPositionOverride]);\n\n /**\n * Reorder Section\n */\n const isReorderEnabled = props.onReorder != undefined;\n const {\n reorderProps,\n reorderItemProps,\n reorderContext,\n reorderInstructionsId,\n reorderInstructions\n } = useListViewReorder({\n onReorder: props.onReorder,\n rootRef: listRef,\n viewportConfig: props.viewportConfig\n });\n\n const { triggerProps, menuProps, contextMenuContext, notifyCurrentKeyChanged } =\n useListViewContextMenu(dataState, contextMenuConfig, listRef, updateCurrentItemOverride);\n\n const onPersistCurrentItem = (detail: CurrentKeyDetail<K>) => {\n props.onPersistCurrentItem?.(detail);\n notifyCurrentKeyChanged(detail);\n };\n\n if (isReorderEnabled && reorderItemProps) {\n return (\n <>\n <ReorderableContext.Provider value={reorderContext}>\n <List\n {...props}\n aria-describedby={reorderInstructionsId}\n contextMenuTriggerProps={triggerProps}\n reorderProps={reorderProps}\n onLoadRange={loadRange}\n scrollerRef={listRef}\n data={dataState}\n currentItemOverride={currentItemOverride}\n onPersistCurrentItem={onPersistCurrentItem}>\n {(context) => (\n <MemoizeListViewReorderableItem\n {...reorderItemProps}\n itemKey={context.metadata.key}>\n {props.children(context)}\n </MemoizeListViewReorderableItem>\n )}\n </List>\n <span id={reorderInstructionsId}>\n <HiddenAccessible>{reorderInstructions}</HiddenAccessible>\n </span>\n </ReorderableContext.Provider>\n {contextMenuConfig && (\n <ListViewContextMenu\n {...menuProps}\n contextMenuConfig={contextMenuConfig}\n contextMenuContext={contextMenuContext}\n />\n )}\n </>\n );\n }\n\n return (\n <>\n <List\n {...props}\n onLoadRange={loadRange}\n scrollerRef={listRef}\n data={dataState}\n contextMenuTriggerProps={triggerProps}\n currentItemOverride={currentItemOverride}\n onPersistCurrentItem={onPersistCurrentItem}>\n {props.children}\n </List>\n {contextMenuConfig && (\n <ListViewContextMenu\n {...menuProps}\n contextMenuConfig={contextMenuConfig}\n contextMenuContext={contextMenuContext}\n />\n )}\n </>\n );\n }\n) as <K extends string | number, D>(\n props: Props<K, D> & { ref?: ForwardedRef<ListViewHandle<K>> }\n) => JSX.Element;\n","import { useCallback, useRef } from 'preact/hooks';\nimport { Item as CurrentItem } from '#UNSAFE_Collection';\nimport { ListProps } from './List.types';\n\n/**\n * This hook handles the currentItemOverride passing to PRIVATE_List layer.\n *\n * If the app provided new value for 'currentItemOverride', we pass that down to PRIVATE_List layer;\n * otherwise, we will pass down the value of internal override, which would be the value\n * updated by useListViewContextMenu hook\n *\n * @param currentItemOverride\n */\nexport const useListViewCurrentItemOverride = <K extends string | number, D>(\n currentItemOverride: ListProps<K, D>['currentItemOverride']\n) => {\n // the override that will be passed down to PRIVATE_List layer\n const listOverrideRef = useRef<CurrentItem<K>>();\n\n // track the currentItemOverride attribute set by app\n const appOverrideRef = useRef<CurrentItem<K>>();\n if (appOverrideRef.current !== currentItemOverride) {\n appOverrideRef.current = currentItemOverride;\n listOverrideRef.current = currentItemOverride;\n }\n\n // track the internal override updated by useListViewContextMenu hook\n // we can just update ref here since the hook will trigger a state update for its context, which will trigger a rerender\n const updateCurrentItemOverride = useCallback((key: K) => {\n listOverrideRef.current = { rowKey: key };\n }, []);\n\n return {\n currentItemOverride: listOverrideRef.current,\n updateCurrentItemOverride\n };\n};\n","import type { RefObject } from 'preact';\nimport { useState, useEffect, useRef } from 'preact/hooks';\nimport { mergeProps } from '../utils/UNSAFE_mergeProps';\nimport { ITEM_SELECTOR, dragToScroll, findElementByKey } from '../utils/PRIVATE_collectionUtils';\nimport { ViewportConfig } from '../hooks/UNSAFE_useViewportIntersect';\nimport { useReorderable } from '../hooks/PRIVATE_useReorderable';\nimport { scrollToVisible } from '../PRIVATE_List';\nimport { ListProps } from './List.types';\n\ntype useListViewReorderProps<K, D> = Pick<ListProps<K, D>, 'onReorder'> & {\n rootRef: RefObject<HTMLDivElement>;\n viewportConfig?: ViewportConfig;\n};\n\nexport const useListViewReorder = <K extends string | number, D>({\n onReorder,\n rootRef,\n viewportConfig\n}: useListViewReorderProps<K, D>) => {\n const isReorderEnabled = onReorder != undefined;\n\n const [dragKey, setDragKey] = useState<K | undefined>(undefined);\n const { reorderProps, reorderContext, reorderInstructionsId, reorderInstructions } =\n useReorderable({\n onReorder,\n rootRef,\n itemSelector: ITEM_SELECTOR,\n isDisabled: !isReorderEnabled,\n columns: 1\n });\n\n // ensure the current item is scrolled into view during keyboard reordering,\n // disable that during mouse reordering\n const reorderScrollIntoView = useRef(false);\n useEffect(() => {\n if (isReorderEnabled && reorderScrollIntoView.current) {\n const rootElement = rootRef.current as HTMLElement;\n const elem = findElementByKey(\n rootElement,\n reorderContext.currentItemKey.current as K,\n ITEM_SELECTOR\n );\n if (elem) {\n const scroller = viewportConfig?.scroller() || rootElement;\n // make sure item is visible\n scrollToVisible(elem, scroller, 0);\n reorderScrollIntoView.current = false;\n }\n }\n });\n\n if (!isReorderEnabled) {\n return {\n reorderProps,\n reorderContext,\n reorderInstructionsId,\n reorderInstructions\n } as const;\n }\n\n const handleKeyDown = (event: KeyboardEvent) => {\n // listview only do keyboard reordering with arrow up/down keys\n if (\n isReorderEnabled &&\n (event.key === 'ArrowUp' || event.key === 'ArrowDown') &&\n (event.metaKey || event.ctrlKey) &&\n event.shiftKey\n ) {\n reorderScrollIntoView.current = true;\n reorderProps.onKeyDown?.(event);\n }\n };\n\n const handleDragOver = (event: DragEvent) => {\n if (dragKey !== undefined) {\n reorderScrollIntoView.current = false;\n dragToScroll(event, dragKey !== undefined, rootRef.current);\n }\n };\n\n const reorderEventProps = mergeProps({ onKeyDown: handleKeyDown, onDragOver: handleDragOver });\n\n const reorderItemProps = {\n dragKey,\n setDragKey,\n onReorder,\n rootRef\n };\n\n return {\n reorderProps: reorderEventProps,\n reorderItemProps,\n reorderContext,\n reorderInstructionsId,\n reorderInstructions\n } as const;\n};\n"],"names":["getKeyForIndex","root","index","rowElements","querySelectorAll","length","getKey","getScrollPosition","newScrollTop","scrollTop","Math","abs","scrollPosition","y","key","undefined","offsetY","rowBottom","i","rowHeight","getBoundingClientRect","height","setScrollPosition","useRow","_getScrollTopFromScrollPosition","MemoizeListViewReorderableItem","memo","children","dragKey","setDragKey","onReorder","rootRef","itemKey","itemRef","useRef","itemStyles","itemOverlayFront","styles","reorderableItemOverlayFront","itemOverlayRear","reorderableItemOverlayRear","itemDragger","reorderableItemDragger","setTransferData","useCallback","event","dataTransfer","setData","JSON","stringify","rootProps","isDragged","overlayZoneBeforeProps","overlayZoneAfterProps","useReorderableItem","isDisabled","ref","getItem","current","closest","ITEM_SELECTOR","itemSelector","isVertical","classes","classNames","class","reorderableItemDnd","_jsxs","isKeyDefined","jsxs","_Fragment","Fragment","_jsx","jsx","prev","next","ListViewContextMenu","contextMenuConfig","contextMenuContext","menuProps","accessibleLabel","Menu","isOpen","itemsRenderer","menuPropGestureStates","mouse","initialFocus","placement","offsetValue","keyboard","touch","initialMenuProps","anchorRef","ListView","forwardRef","props","scrollPositionRef","listRef","currentItemOverride","updateCurrentItemOverride","listOverrideRef","appOverrideRef","rowKey","useListViewCurrentItemOverride","dataMetadata","data","map","aData","metadata","getRowKey","loadRange","onLoadMore","dataState","offset","sizePrecision","hasMore","totalSize","useImperativeHandle","focus","useLayoutEffect","scrollPositionOverride","isReorderEnabled","reorderProps","reorderItemProps","reorderContext","reorderInstructionsId","reorderInstructions","viewportConfig","useState","useReorderable","columns","reorderScrollIntoView","useEffect","rootElement","elem","findElementByKey","currentItemKey","scroller","scrollToVisible","mergeProps","onKeyDown","metaKey","ctrlKey","shiftKey","onDragOver","dragToScroll","useListViewReorder","triggerProps","notifyCurrentKeyChanged","scrollListRef","updateCurrentKey","setContextMenuContext","setMenuProps","currentKeyRef","useContextMenuGesture","gesture","anchor","target","anchorBasedOnGesture","context","findItemContext","keyExtractor","handleCloseContextMenu","detail","reason","preventScroll","onClose","value","useListViewContextMenu","onPersistCurrentItem","ReorderableContext","Provider","List","contextMenuTriggerProps","onLoadRange","scrollerRef","id","HiddenAccessible"],"mappings":"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"}
1
+ {"version":3,"file":"ListView-325e1814.js","sources":["../../src/UNSAFE_ListView/ScrollPositionUtils.ts","../../src/UNSAFE_ListView/ListViewReorderableItem.tsx","../../src/UNSAFE_ListView/ListViewContextMenu.tsx","../../src/UNSAFE_ListView/useListViewContextMenu.ts","../../src/UNSAFE_ListView/ListView.tsx","../../src/UNSAFE_ListView/useListViewCurrentItemOverride.tsx","../../src/UNSAFE_ListView/useListViewReorder.ts"],"sourcesContent":["/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { getKey } from '../utils/PRIVATE_collectionUtils';\n\n/**\n * Type for scroll position in ListView\n */\nexport type ListViewScrollPosition<K> = {\n offsetY?: number;\n key?: K;\n y?: number;\n};\n\n/**\n * Returns the key for the row at the given index\n */\nconst getKeyForIndex = (root: HTMLElement, index: number) => {\n if (root != null) {\n const rowElements = root.querySelectorAll(`[role='row']`);\n if (rowElements.length > index) {\n return getKey(rowElements[index] as HTMLElement);\n }\n }\n return null;\n};\n\nexport function getScrollPosition<K>(root: HTMLDivElement, newScrollTop?: number) {\n // ensure scroll position y value is initialized\n const scrollTop = Math.abs(newScrollTop == null ? root.scrollTop : newScrollTop);\n\n const scrollPosition: ListViewScrollPosition<K> = {\n y: scrollTop,\n key: undefined,\n offsetY: undefined\n };\n\n let rowBottom = 0;\n const rowElements = root.querySelectorAll(`[role='row']`);\n if (rowElements.length > 0) {\n if (scrollTop === 0) {\n scrollPosition.key = getKeyForIndex(root, 0) as K;\n scrollPosition.offsetY = 0;\n return scrollPosition;\n }\n }\n for (let i = 0; i < rowElements.length; i++) {\n const rowHeight = rowElements[i].getBoundingClientRect().height;\n rowBottom += rowHeight;\n if (scrollTop < rowBottom) {\n scrollPosition.key = getKeyForIndex(root, i) as K;\n scrollPosition.offsetY = rowHeight + scrollTop - rowBottom;\n break;\n }\n }\n return scrollPosition;\n}\n\n/**\n * Helper to set the scroll position on the ListView.\n */\nexport function setScrollPosition<K>(\n root: HTMLDivElement,\n scrollPosition?: ListViewScrollPosition<K>\n) {\n const y = _getScrollTopFromScrollPosition(root, scrollPosition);\n root.scrollTop = y != null ? y : 0;\n}\n\n/**\n * Helper to determine the 'y' value of a given scroll position.\n */\nfunction _getScrollTopFromScrollPosition<K>(\n root: HTMLDivElement,\n scrollPosition?: ListViewScrollPosition<K>\n) {\n if (scrollPosition != null) {\n let key;\n let useRow = false;\n if (scrollPosition.key != null) {\n // key takes precedence over everything else\n useRow = true;\n key = scrollPosition.key;\n } else if (scrollPosition.offsetY != null && scrollPosition.y == null) {\n // offsetY can be used on its own if it is the only vertical aspect provided\n useRow = true;\n key = getScrollPosition(root).key;\n }\n if (useRow) {\n if (key != null) {\n let y = 0;\n const rowElements = root.querySelectorAll(`[role ='row']`);\n for (let i = 0; i < rowElements.length; i++) {\n if (key === getKey(rowElements[i] as HTMLElement)) {\n return y + (scrollPosition.offsetY != null ? scrollPosition.offsetY : 0);\n }\n y += rowElements[i].getBoundingClientRect().height;\n }\n }\n } else if (scrollPosition.y != null) {\n return scrollPosition.y;\n }\n }\n // either nothing was provided, or what was provided was invalid\n return undefined;\n}\n","import { memo } from 'preact/compat';\nimport { useRef, useCallback } from 'preact/hooks';\nimport { useReorderableItem } from '../hooks/PRIVATE_useReorderable';\nimport { ReorderableItemProps } from '../UNSAFE_Collection/Reorderable.types';\nimport { ITEM_SELECTOR } from '../utils/PRIVATE_collectionUtils';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport { styles } from './themes/ListViewStyles.css';\nimport { isKeyDefined } from '../utils/UNSAFE_keys';\n\nexport type ListReorderableItemProps<K> = ReorderableItemProps<K>;\n\n/**\n * A private item that will be used by ReorderableCardFlexView, location TBD (could be moved to PRIVATE_CardFlexView)\n */\nexport function ListViewReorderableItem<K extends string | number>({\n children,\n dragKey,\n setDragKey,\n onReorder,\n rootRef,\n itemKey\n}: ListReorderableItemProps<K> & { itemKey: K }) {\n const itemRef = useRef<HTMLDivElement | null>(null);\n const itemStyles = {\n itemOverlayFront: styles.reorderableItemOverlayFront,\n itemOverlayRear: styles.reorderableItemOverlayRear,\n itemDragger: styles.reorderableItemDragger\n };\n const getItem = () => itemRef?.current?.closest(ITEM_SELECTOR);\n const setTransferData = useCallback(\n (event: DragEvent) => {\n event.dataTransfer?.setData('text/listview-items-key', JSON.stringify(itemKey));\n },\n [itemKey]\n );\n const { rootProps, isDragged, overlayZoneBeforeProps, overlayZoneAfterProps } =\n useReorderableItem({\n isDisabled: onReorder ? false : true,\n dragKey,\n setDragKey,\n onReorder,\n rootRef,\n ref: itemRef,\n getItem,\n setTransferData,\n itemStyles,\n itemSelector: ITEM_SELECTOR,\n isVertical: true\n });\n const classes = classNames([rootProps?.class, styles.reorderableItemDnd]);\n\n return (\n <div {...rootProps} class={classes}>\n {children}\n {!isDragged && isKeyDefined(dragKey) && (\n <>\n <div {...overlayZoneBeforeProps}></div>\n <div {...overlayZoneAfterProps}></div>\n </>\n )}\n </div>\n );\n}\n\nexport const MemoizeListViewReorderableItem = memo(\n ListViewReorderableItem,\n <K,>(prev: ListReorderableItemProps<K>, next: ListReorderableItemProps<K>) => {\n if (prev && next) {\n return prev?.children === next?.children && prev?.dragKey === next?.dragKey;\n }\n return false;\n }\n);\n","/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { ComponentProps } from 'preact';\n\nimport { ListItemContext } from '#UNSAFE_Collection';\nimport { Menu } from '#UNSAFE_Menu';\nimport { ListViewContextMenuConfig } from './List.types';\n\nexport type Props<K extends string | number, D> = Omit<ComponentProps<typeof Menu>, 'children'> & {\n contextMenuConfig: ListViewContextMenuConfig<K, D>;\n} & { contextMenuContext: ListItemContext<K, D> };\n\n/**\n * The internal component used to render a custom context menu\n */\nexport function ListViewContextMenu<K extends string | number, D>({\n contextMenuConfig,\n contextMenuContext,\n ...menuProps\n}: Props<K, D>) {\n const accessibleLabel = contextMenuConfig.accessibleLabel;\n\n return (\n <>\n <Menu\n {...menuProps}\n {...(accessibleLabel && {\n 'aria-label': accessibleLabel\n })}>\n {menuProps.isOpen && contextMenuConfig.itemsRenderer(contextMenuContext)}\n </Menu>\n </>\n );\n}\n","import type { ComponentProps, RefObject } from 'preact';\nimport { useCallback, useState, useRef } from 'preact/hooks';\n\nimport { DataState, ListItemContext, CurrentKeyDetail } from '#UNSAFE_Collection';\nimport { Menu } from '#UNSAFE_Menu';\nimport { findItemContext } from '#hooks/PRIVATE_useItemAction';\nimport { useContextMenuGesture } from '#hooks/UNSAFE_useContextMenuGesture';\nimport { ITEM_SELECTOR, findElementByKey, keyExtractor } from '#utils/PRIVATE_collectionUtils';\nimport { ListView } from './ListView';\n\ntype MenuProps = Pick<\n ComponentProps<typeof Menu>,\n 'anchorRef' | 'initialFocus' | 'placement' | 'offsetValue' | 'isOpen'\n>;\n\nconst TOUCH_OFFSET_VALUE = 40;\n\nconst menuPropGestureStates: Record<\n 'mouse' | 'keyboard' | 'touch',\n Omit<Required<MenuProps>, 'anchorRef' | 'isOpen'>\n> = {\n mouse: {\n initialFocus: 'menu',\n placement: 'bottom-start',\n offsetValue: 0\n },\n keyboard: {\n initialFocus: 'firstItem',\n placement: 'bottom-start',\n offsetValue: 0\n },\n touch: {\n initialFocus: 'menu',\n placement: 'end',\n offsetValue: TOUCH_OFFSET_VALUE\n }\n};\n\nconst initialMenuProps: MenuProps = {\n isOpen: false,\n initialFocus: 'menu',\n placement: 'bottom-start',\n offsetValue: 0,\n anchorRef: { current: null }\n};\n\ntype ListViewProps<K extends string | number, D> = ComponentProps<typeof ListView<K, D>>;\n\nexport const useListViewContextMenu = <K extends string | number, D>(\n dataState: DataState<K, D> | null,\n contextMenuConfig: ListViewProps<K, D>['contextMenuConfig'],\n scrollListRef: RefObject<HTMLElement | null>,\n updateCurrentKey: (key: K) => void\n) => {\n /*Context Menu section\n TODO: A version of context Menu listview will be merged using useContextMenuGesture instead. Once it's merged we \n can go back to this to create a hook or utility that could be share among all collection comps. JET-60320\n */\n\n /* \n Steps to open a menu:\n 1.- useContextMenu handler is called when menu is supposed to be opened.\n 2.- We set contextMenuContext when contextMenuRenderer is called.\n 3.- We dispatch opening the menu with the correct anchor.\n 5.- Menu receives updated props and updated contextMenuContext.\n 6.- Menu is opened. \n\n */\n\n //Supposed to be updated when menu is about to be opened\n //We set an initial key value for the context menu context, to allow user use object destructuring inside the\n //contextMenuRenderer. It doesn't matter if the key is not correct at the initial rendering since menu starts\n //being closed always\n const [contextMenuContext, setContextMenuContext] = useState<ListItemContext<K, D>>();\n\n const [menuProps, setMenuProps] = useState<MenuProps>(initialMenuProps);\n\n const currentKeyRef = useRef<K>();\n const notifyCurrentKeyChanged = (detail: CurrentKeyDetail<K>) => {\n currentKeyRef.current = detail.value;\n };\n\n const { triggerProps } = useContextMenuGesture(\n ({ gesture, anchor, target }) => {\n let anchorBasedOnGesture = anchor;\n if (gesture === 'keyboard') {\n //We find the element where the position of the menu is going to be based of\n const elem = findElementByKey(\n scrollListRef.current as HTMLElement,\n currentKeyRef.current as K,\n ITEM_SELECTOR\n );\n\n //We set the correct anchor\n anchorBasedOnGesture = elem ? elem : anchor;\n\n const context = findItemContext(\n currentKeyRef.current as K,\n dataState as DataState<string | number | null, D>\n );\n\n setContextMenuContext(context as ListItemContext<K, D>);\n } else {\n //We search for the key using the target of the event\n const key = keyExtractor(target as HTMLElement, ITEM_SELECTOR);\n\n const context = findItemContext(key, dataState as DataState<string | number | null, D>);\n\n setContextMenuContext(context as ListItemContext<K, D>);\n\n //We update the key so when we close logical focus is on the correct item\n updateCurrentKey(key as K);\n }\n setMenuProps({\n ...menuPropGestureStates[gesture],\n anchorRef: { current: anchorBasedOnGesture },\n isOpen: true\n });\n },\n {\n isDisabled: !contextMenuConfig //If there is no a context menu renderer we disable the hook\n }\n );\n\n const handleCloseContextMenu = useCallback<Required<ComponentProps<typeof Menu>>['onClose']>(\n (detail) => {\n /* \n TODO: Focus ring should be visible when context menu was closed because of selecting an item using keyboard, \n but should not be visible when the selection was done using mouse or touch. This would probably means menu \n onClose API is going to be changed a little bit so we can satisfy this requirement. JET-62372\n */\n //Focus has to be set on the current target that was obtained\n //during context menu gesture when menu is dismissed or item is \"selected\"\n if (detail.reason === 'dismissed' || detail.reason === 'itemAction') {\n scrollListRef.current?.focus({ preventScroll: true });\n }\n // We close the menu.The only prop that matters here is isOpen\n setMenuProps({ ...initialMenuProps });\n },\n [scrollListRef]\n );\n\n return {\n menuProps: { ...menuProps, onClose: handleCloseContextMenu },\n onClose: handleCloseContextMenu,\n contextMenuContext: contextMenuContext as ListItemContext<K, D>,\n triggerProps,\n notifyCurrentKeyChanged\n } as const;\n};\n","/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { JSX } from 'preact';\nimport { ForwardedRef, forwardRef } from 'preact/compat';\nimport { useImperativeHandle, useRef, useLayoutEffect } from 'preact/hooks';\nimport { ReorderableContext } from '../hooks/PRIVATE_useReorderable';\nimport { DataState, CurrentKeyDetail } from '../UNSAFE_Collection';\nimport { HiddenAccessible } from '../UNSAFE_HiddenAccessible';\nimport { List } from '../PRIVATE_List';\nimport { ListProps, ListViewContextMenuConfig, ListViewHandle } from './List.types';\nimport {\n getScrollPosition,\n setScrollPosition,\n ListViewScrollPosition\n} from './ScrollPositionUtils';\nimport { MemoizeListViewReorderableItem } from './ListViewReorderableItem';\nimport { useListViewReorder } from './useListViewReorder';\nimport { ListViewContextMenu } from './ListViewContextMenu';\nimport { useListViewContextMenu } from './useListViewContextMenu';\nimport { useListViewCurrentItemOverride } from './useListViewCurrentItemOverride';\n\n/**\n * Props specific to non-virtualized ListView\n */\ntype NonVirtualizedListProps<K, D> = {\n /**\n * The data that is used to render each item in ListView. If the value is null, then ListView will show nothing\n * if hasMore is false, or loading indicator if hasMore is true.\n */\n data: D[] | null;\n /**\n * A callback function to extract the key which is used to identify the item.\n */\n getRowKey: (data: D) => K;\n /**\n * Whether there are more data available to load. By default this returns false.\n */\n hasMore?: boolean;\n /**\n * An optional callback function which is invoked when user scrolls to the end of the list.\n */\n onLoadMore?: () => void;\n\n /**\n * Configuration used to specify a context menu.\n */\n contextMenuConfig?: ListViewContextMenuConfig<K, D>;\n};\n\n/**\n * Props for the ListView Component\n */\nexport type Props<K, D> = Pick<\n ListProps<K, D>,\n | 'aria-label'\n | 'aria-labelledby'\n | 'children'\n | 'gridlines'\n | 'currentItemOverride'\n | 'onPersistCurrentItem'\n | 'onItemAction'\n | 'onSelectionChange'\n | 'promotedSection'\n | 'selectedKeys'\n | 'selectionMode'\n | 'viewportConfig'\n | 'testId'\n | 'scrollPositionOverride'\n | 'onReorder'\n | 'itemPadding'\n> &\n NonVirtualizedListProps<K, D>;\n/**\n * A list view displays data items as a list or a grid with highly interactive features.\n */\nexport const ListView = forwardRef(\n <K extends string | number, D>(props: Props<K, D>, ref?: ForwardedRef<ListViewHandle<K>>) => {\n const { contextMenuConfig } = props;\n const scrollPositionRef = useRef<ListViewScrollPosition<K>>();\n const listRef = useRef<HTMLDivElement | null>(null);\n\n const { currentItemOverride, updateCurrentItemOverride } = useListViewCurrentItemOverride(\n props.currentItemOverride\n );\n\n const dataMetadata = props.data\n ? props.data.map((aData: D) => {\n const key = props.getRowKey(aData);\n return { data: aData, metadata: { key } };\n })\n : null;\n\n const loadRange = props.onLoadMore ? props.onLoadMore : () => {};\n const dataState = dataMetadata\n ? ({\n offset: 0,\n data: dataMetadata,\n sizePrecision: props.hasMore ? 'atLeast' : 'exact',\n totalSize: dataMetadata.length\n } as DataState<K, D>)\n : null;\n\n useImperativeHandle(ref!, () => ({\n getScrollPosition: () => {\n if (listRef.current) {\n return getScrollPosition(listRef.current);\n }\n return { y: 0 };\n },\n focus: () => {\n if (listRef.current) {\n listRef.current.focus();\n }\n }\n }));\n\n // update scroll position if a new value is provided\n useLayoutEffect(() => {\n if (listRef.current && scrollPositionRef.current !== props.scrollPositionOverride) {\n setScrollPosition(listRef.current, props.scrollPositionOverride);\n scrollPositionRef.current = props.scrollPositionOverride;\n }\n }, [props.scrollPositionOverride]);\n\n /**\n * Reorder Section\n */\n const isReorderEnabled = props.onReorder != undefined;\n const {\n reorderProps,\n reorderItemProps,\n reorderContext,\n reorderInstructionsId,\n reorderInstructions\n } = useListViewReorder({\n onReorder: props.onReorder,\n rootRef: listRef,\n viewportConfig: props.viewportConfig\n });\n\n const { triggerProps, menuProps, contextMenuContext, notifyCurrentKeyChanged } =\n useListViewContextMenu(dataState, contextMenuConfig, listRef, updateCurrentItemOverride);\n\n const onPersistCurrentItem = (detail: CurrentKeyDetail<K>) => {\n props.onPersistCurrentItem?.(detail);\n notifyCurrentKeyChanged(detail);\n };\n\n if (isReorderEnabled && reorderItemProps) {\n return (\n <>\n <ReorderableContext.Provider value={reorderContext}>\n <List\n {...props}\n aria-describedby={reorderInstructionsId}\n contextMenuTriggerProps={triggerProps}\n reorderProps={reorderProps}\n onLoadRange={loadRange}\n scrollerRef={listRef}\n data={dataState}\n currentItemOverride={currentItemOverride}\n onPersistCurrentItem={onPersistCurrentItem}>\n {(context) => (\n <MemoizeListViewReorderableItem\n {...reorderItemProps}\n itemKey={context.metadata.key}>\n {props.children(context)}\n </MemoizeListViewReorderableItem>\n )}\n </List>\n <span id={reorderInstructionsId}>\n <HiddenAccessible>{reorderInstructions}</HiddenAccessible>\n </span>\n </ReorderableContext.Provider>\n {contextMenuConfig && (\n <ListViewContextMenu\n {...menuProps}\n contextMenuConfig={contextMenuConfig}\n contextMenuContext={contextMenuContext}\n />\n )}\n </>\n );\n }\n\n return (\n <>\n <List\n {...props}\n onLoadRange={loadRange}\n scrollerRef={listRef}\n data={dataState}\n contextMenuTriggerProps={triggerProps}\n currentItemOverride={currentItemOverride}\n onPersistCurrentItem={onPersistCurrentItem}>\n {props.children}\n </List>\n {contextMenuConfig && (\n <ListViewContextMenu\n {...menuProps}\n contextMenuConfig={contextMenuConfig}\n contextMenuContext={contextMenuContext}\n />\n )}\n </>\n );\n }\n) as <K extends string | number, D>(\n props: Props<K, D> & { ref?: ForwardedRef<ListViewHandle<K>> }\n) => JSX.Element;\n","import { useCallback, useRef } from 'preact/hooks';\nimport { Item as CurrentItem } from '#UNSAFE_Collection';\nimport { ListProps } from './List.types';\n\n/**\n * This hook handles the currentItemOverride passing to PRIVATE_List layer.\n *\n * If the app provided new value for 'currentItemOverride', we pass that down to PRIVATE_List layer;\n * otherwise, we will pass down the value of internal override, which would be the value\n * updated by useListViewContextMenu hook\n *\n * @param currentItemOverride\n */\nexport const useListViewCurrentItemOverride = <K extends string | number, D>(\n currentItemOverride: ListProps<K, D>['currentItemOverride']\n) => {\n // the override that will be passed down to PRIVATE_List layer\n const listOverrideRef = useRef<CurrentItem<K>>();\n\n // track the currentItemOverride attribute set by app\n const appOverrideRef = useRef<CurrentItem<K>>();\n if (appOverrideRef.current !== currentItemOverride) {\n appOverrideRef.current = currentItemOverride;\n listOverrideRef.current = currentItemOverride;\n }\n\n // track the internal override updated by useListViewContextMenu hook\n // we can just update ref here since the hook will trigger a state update for its context, which will trigger a rerender\n const updateCurrentItemOverride = useCallback((key: K) => {\n listOverrideRef.current = { rowKey: key };\n }, []);\n\n return {\n currentItemOverride: listOverrideRef.current,\n updateCurrentItemOverride\n };\n};\n","import type { RefObject } from 'preact';\nimport { useState, useEffect, useRef } from 'preact/hooks';\nimport { mergeProps } from '../utils/UNSAFE_mergeProps';\nimport { ITEM_SELECTOR, dragToScroll, findElementByKey } from '../utils/PRIVATE_collectionUtils';\nimport { ViewportConfig } from '../hooks/UNSAFE_useViewportIntersect';\nimport { useReorderable } from '../hooks/PRIVATE_useReorderable';\nimport { scrollToVisible } from '../PRIVATE_List';\nimport { ListProps } from './List.types';\n\ntype useListViewReorderProps<K, D> = Pick<ListProps<K, D>, 'onReorder'> & {\n rootRef: RefObject<HTMLDivElement>;\n viewportConfig?: ViewportConfig;\n};\n\nexport const useListViewReorder = <K extends string | number, D>({\n onReorder,\n rootRef,\n viewportConfig\n}: useListViewReorderProps<K, D>) => {\n const isReorderEnabled = onReorder != undefined;\n\n const [dragKey, setDragKey] = useState<K | undefined>(undefined);\n const { reorderProps, reorderContext, reorderInstructionsId, reorderInstructions } =\n useReorderable({\n onReorder,\n rootRef,\n itemSelector: ITEM_SELECTOR,\n isDisabled: !isReorderEnabled,\n columns: 1\n });\n\n // ensure the current item is scrolled into view during keyboard reordering,\n // disable that during mouse reordering\n const reorderScrollIntoView = useRef(false);\n useEffect(() => {\n if (isReorderEnabled && reorderScrollIntoView.current) {\n const rootElement = rootRef.current as HTMLElement;\n const elem = findElementByKey(\n rootElement,\n reorderContext.currentItemKey.current as K,\n ITEM_SELECTOR\n );\n if (elem) {\n const scroller = viewportConfig?.scroller() || rootElement;\n // make sure item is visible\n scrollToVisible(elem, scroller, 0);\n reorderScrollIntoView.current = false;\n }\n }\n });\n\n if (!isReorderEnabled) {\n return {\n reorderProps,\n reorderContext,\n reorderInstructionsId,\n reorderInstructions\n } as const;\n }\n\n const handleKeyDown = (event: KeyboardEvent) => {\n // listview only do keyboard reordering with arrow up/down keys\n if (\n isReorderEnabled &&\n (event.key === 'ArrowUp' || event.key === 'ArrowDown') &&\n (event.metaKey || event.ctrlKey) &&\n event.shiftKey\n ) {\n reorderScrollIntoView.current = true;\n reorderProps.onKeyDown?.(event);\n }\n };\n\n const handleDragOver = (event: DragEvent) => {\n if (dragKey !== undefined) {\n reorderScrollIntoView.current = false;\n dragToScroll(event, dragKey !== undefined, rootRef.current);\n }\n };\n\n const reorderEventProps = mergeProps({ onKeyDown: handleKeyDown, onDragOver: handleDragOver });\n\n const reorderItemProps = {\n dragKey,\n setDragKey,\n onReorder,\n rootRef\n };\n\n return {\n reorderProps: reorderEventProps,\n reorderItemProps,\n reorderContext,\n reorderInstructionsId,\n reorderInstructions\n } as const;\n};\n"],"names":["getKeyForIndex","root","index","rowElements","querySelectorAll","length","getKey","getScrollPosition","newScrollTop","scrollTop","Math","abs","scrollPosition","y","key","undefined","offsetY","rowBottom","i","rowHeight","getBoundingClientRect","height","setScrollPosition","useRow","_getScrollTopFromScrollPosition","MemoizeListViewReorderableItem","memo","children","dragKey","setDragKey","onReorder","rootRef","itemKey","itemRef","useRef","itemStyles","itemOverlayFront","styles","reorderableItemOverlayFront","itemOverlayRear","reorderableItemOverlayRear","itemDragger","reorderableItemDragger","setTransferData","useCallback","event","dataTransfer","setData","JSON","stringify","rootProps","isDragged","overlayZoneBeforeProps","overlayZoneAfterProps","useReorderableItem","isDisabled","ref","getItem","current","closest","ITEM_SELECTOR","itemSelector","isVertical","classes","classNames","class","reorderableItemDnd","_jsxs","isKeyDefined","jsxs","_Fragment","Fragment","_jsx","jsx","prev","next","ListViewContextMenu","contextMenuConfig","contextMenuContext","menuProps","accessibleLabel","Menu","isOpen","itemsRenderer","menuPropGestureStates","mouse","initialFocus","placement","offsetValue","keyboard","touch","initialMenuProps","anchorRef","ListView","forwardRef","props","scrollPositionRef","listRef","currentItemOverride","updateCurrentItemOverride","listOverrideRef","appOverrideRef","rowKey","useListViewCurrentItemOverride","dataMetadata","data","map","aData","metadata","getRowKey","loadRange","onLoadMore","dataState","offset","sizePrecision","hasMore","totalSize","useImperativeHandle","focus","useLayoutEffect","scrollPositionOverride","isReorderEnabled","reorderProps","reorderItemProps","reorderContext","reorderInstructionsId","reorderInstructions","viewportConfig","useState","useReorderable","columns","reorderScrollIntoView","useEffect","rootElement","elem","findElementByKey","currentItemKey","scroller","scrollToVisible","mergeProps","onKeyDown","metaKey","ctrlKey","shiftKey","onDragOver","dragToScroll","useListViewReorder","triggerProps","notifyCurrentKeyChanged","scrollListRef","updateCurrentKey","setContextMenuContext","setMenuProps","currentKeyRef","useContextMenuGesture","gesture","anchor","target","anchorBasedOnGesture","context","findItemContext","keyExtractor","handleCloseContextMenu","detail","reason","preventScroll","onClose","value","useListViewContextMenu","onPersistCurrentItem","ReorderableContext","Provider","List","contextMenuTriggerProps","onLoadRange","scrollerRef","id","HiddenAccessible"],"mappings":"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"}
@@ -0,0 +1,2 @@
1
+ define(['exports', 'preact/jsx-runtime', 'preact/hooks', 'css!./LiveRegionStyles.styles.css', './useTestId-0140aa44'], (function(e,t,s,i,n){"use strict";e.LiveRegion=function({testId:e,atomic:i="false",children:c="",timeout:a=100,type:o="polite"}){const u=function(e,t){const[i,n]=s.useState(""),c=s.useCallback((()=>n(e)),[e]),a=s.useCallback((()=>setTimeout(c,t)),[c,t]);return s.useEffect((()=>{const e=a();return()=>clearTimeout(e)}),[a]),i}(c,a),r=n.useTestId(e);return t.jsx("span",{"aria-live":o,"aria-atomic":i,class:"LiveRegionStyles_offScreenStyle__1uvpdtw0",...r,children:u})}}));
2
+ //# sourceMappingURL=LiveRegion-17fea064.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"LiveRegion-1917f798.js","sources":["../../src/UNSAFE_LiveRegion/LiveRegion.tsx"],"sourcesContent":["import { useCallback, useEffect, useState } from 'preact/hooks';\nimport { offScreenStyle } from './LiveRegionStyles.css';\nimport { TestIdProps, useTestId } from '#hooks/UNSAFE_useTestId';\n\ntype Props = TestIdProps & {\n /**\n * Whether this live region is atomic\n */\n atomic?: 'true' | 'false';\n\n /**\n * The text to be read out in the live region\n */\n children?: string;\n\n /**\n * Timeout for updating the text\n */\n timeout?: number;\n\n /**\n * The value for the aria-live attribute\n */\n type?: 'assertive' | 'polite' | 'off';\n};\n\n/**\n * A helper component that renders an aria-live region\n *\n * TODO: Create a more centralized component that can handle aria-live region for\n * the whole application and use context api to communicate\n */\nfunction LiveRegion({\n testId,\n atomic = 'false',\n children = '',\n timeout = 100,\n type = 'polite'\n}: Props) {\n const ariaLiveText = useLiveText(children, timeout);\n const testIdProps = useTestId(testId);\n\n return (\n <span aria-live={type} aria-atomic={atomic} class={offScreenStyle} {...testIdProps}>\n {ariaLiveText}\n </span>\n );\n}\n\n/**\n * A custom hook for handling the aria-live region\n *\n * @param text The aria-live text to use\n * @param timeout The timeout for setting the aria-live text async\n * @returns The aria-live text\n */\nfunction useLiveText(text: string, timeout: number) {\n const [liveText, setLiveText] = useState('');\n const updateText = useCallback(() => setLiveText(text), [text]);\n const updateTextAsync = useCallback(() => setTimeout(updateText, timeout), [updateText, timeout]);\n\n useEffect(() => {\n const timeoutId = updateTextAsync();\n\n return () => clearTimeout(timeoutId);\n }, [updateTextAsync]);\n\n return liveText;\n}\n\nexport { LiveRegion };\n"],"names":["testId","atomic","children","timeout","type","ariaLiveText","text","liveText","setLiveText","useState","updateText","useCallback","updateTextAsync","setTimeout","useEffect","timeoutId","clearTimeout","useLiveText","testIdProps","useTestId","_jsx","jsx","class"],"mappings":"6JAgCA,UAAoBA,OAClBA,EAAMC,OACNA,EAAS,QAAOC,SAChBA,EAAW,GAAEC,QACbA,EAAU,IAAGC,KACbA,EAAO,WAEP,MAAMC,EAiBR,SAAqBC,EAAcH,GACjC,MAAOI,EAAUC,GAAeC,EAAQA,SAAC,IACnCC,EAAaC,EAAAA,aAAY,IAAMH,EAAYF,IAAO,CAACA,IACnDM,EAAkBD,eAAY,IAAME,WAAWH,EAAYP,IAAU,CAACO,EAAYP,IAQxF,OANAW,EAAAA,WAAU,KACR,MAAMC,EAAYH,IAElB,MAAO,IAAMI,aAAaD,EAAU,GACnC,CAACH,IAEGL,CACT,CA7BuBU,CAAYf,EAAUC,GACrCe,EAAcC,YAAUnB,GAE9B,OACEoB,EAAAC,IAAA,OAAA,CAAA,YAAiBjB,EAAI,cAAeH,EAAQqB,qDAA2BJ,EAAWhB,SAC/EG,GAGP"}
1
+ {"version":3,"file":"LiveRegion-17fea064.js","sources":["../../src/UNSAFE_LiveRegion/LiveRegion.tsx"],"sourcesContent":["import { useCallback, useEffect, useState } from 'preact/hooks';\nimport { offScreenStyle } from './LiveRegionStyles.css';\nimport { TestIdProps, useTestId } from '#hooks/UNSAFE_useTestId';\n\ntype Props = TestIdProps & {\n /**\n * Whether this live region is atomic\n */\n atomic?: 'true' | 'false';\n\n /**\n * The text to be read out in the live region\n */\n children?: string;\n\n /**\n * Timeout for updating the text\n */\n timeout?: number;\n\n /**\n * The value for the aria-live attribute\n */\n type?: 'assertive' | 'polite' | 'off';\n};\n\n/**\n * A helper component that renders an aria-live region\n *\n * TODO: Create a more centralized component that can handle aria-live region for\n * the whole application and use context api to communicate\n */\nfunction LiveRegion({\n testId,\n atomic = 'false',\n children = '',\n timeout = 100,\n type = 'polite'\n}: Props) {\n const ariaLiveText = useLiveText(children, timeout);\n const testIdProps = useTestId(testId);\n\n return (\n <span aria-live={type} aria-atomic={atomic} class={offScreenStyle} {...testIdProps}>\n {ariaLiveText}\n </span>\n );\n}\n\n/**\n * A custom hook for handling the aria-live region\n *\n * @param text The aria-live text to use\n * @param timeout The timeout for setting the aria-live text async\n * @returns The aria-live text\n */\nfunction useLiveText(text: string, timeout: number) {\n const [liveText, setLiveText] = useState('');\n const updateText = useCallback(() => setLiveText(text), [text]);\n const updateTextAsync = useCallback(() => setTimeout(updateText, timeout), [updateText, timeout]);\n\n useEffect(() => {\n const timeoutId = updateTextAsync();\n\n return () => clearTimeout(timeoutId);\n }, [updateTextAsync]);\n\n return liveText;\n}\n\nexport { LiveRegion };\n"],"names":["testId","atomic","children","timeout","type","ariaLiveText","text","liveText","setLiveText","useState","updateText","useCallback","updateTextAsync","setTimeout","useEffect","timeoutId","clearTimeout","useLiveText","testIdProps","useTestId","_jsx","jsx","class"],"mappings":"6JAgCA,UAAoBA,OAClBA,EAAMC,OACNA,EAAS,QAAOC,SAChBA,EAAW,GAAEC,QACbA,EAAU,IAAGC,KACbA,EAAO,WAEP,MAAMC,EAiBR,SAAqBC,EAAcH,GACjC,MAAOI,EAAUC,GAAeC,EAAQA,SAAC,IACnCC,EAAaC,EAAAA,aAAY,IAAMH,EAAYF,IAAO,CAACA,IACnDM,EAAkBD,eAAY,IAAME,WAAWH,EAAYP,IAAU,CAACO,EAAYP,IAQxF,OANAW,EAAAA,WAAU,KACR,MAAMC,EAAYH,IAElB,MAAO,IAAMI,aAAaD,EAAU,GACnC,CAACH,IAEGL,CACT,CA7BuBU,CAAYf,EAAUC,GACrCe,EAAcC,YAAUnB,GAE9B,OACEoB,EAAAC,IAAA,OAAA,CAAA,YAAiBjB,EAAI,cAAeH,EAAQqB,qDAA2BJ,EAAWhB,SAC/EG,GAGP"}
@@ -0,0 +1,2 @@
1
+ define(['exports', 'preact/jsx-runtime', 'preact', './Collection-46cfa244', './useViewportIntersect-b2d47a4b'], (function(e,o,t,r,n){"use strict";const i="oj-collection-loadmore",s=`.${i}`;e.LOADMORE_STYLE_CLASS=i,e.LoadMoreCollection=function({data:e,children:i,viewportConfig:c,hasMore:a,onLoadMore:l,loadMoreIndicator:d,suggestions:u,loadMoreThreshold:h=1}){return n.useViewportIntersect(c,Math.max(h,1),0,s,(()=>{e&&l()})),e?o.jsxs(t.Fragment,{children:[u,o.jsx(r.Collection,{items:e,children:i}),a&&d]}):o.jsx("div",{})}}));
2
+ //# sourceMappingURL=LoadMoreCollection-83413a59.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"LoadMoreCollection-a6adbc3f.js","sources":["../../src/PRIVATE_LoadMoreCollection/LoadMoreCollection.tsx"],"sourcesContent":["/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * Licensed under The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { ComponentChildren, Fragment } from 'preact';\nimport { ItemContext } from '../UNSAFE_Collection';\nimport { Collection } from '../PRIVATE_Collection';\nimport { useViewportIntersect, ViewportConfig } from '../hooks/UNSAFE_useViewportIntersect';\n\n/**\n * Props for the LoadMoreCollection component\n */\ntype Props<D> = {\n /**\n * A DataState object that provide information including data and metadata to the LoadMoreCollection.\n */\n data: D[] | null;\n\n /**\n * Renderer callback used to render each item\n */\n children: (context: ItemContext<D>) => ComponentChildren;\n\n /**\n * Viewport configuration including specifying the element which is used to determine what range\n * of data to render\n */\n viewportConfig: ViewportConfig;\n\n /**\n * Whether there are still more data to load. Internally, LoadMoreCollection will render the load\n * more indicator at the bottom if this is true\n */\n hasMore: boolean;\n\n /**\n * Callback function to handle when user scrolls to the end of the component and there are more items to load.\n * The function should update data prop on the component to include the next set of items fetched.\n */\n onLoadMore: () => void;\n\n /**\n * Optionally specify the custom load more indicator\n */\n loadMoreIndicator?: ComponentChildren;\n\n /**\n * Optionally provide the suggestion indicator sparkle\n */\n suggestions?: ComponentChildren;\n\n /**\n * Optionally specify how far in pixel from the bottom should load more occurs\n */\n loadMoreThreshold?: number;\n};\n\nexport const LOADMORE_STYLE_CLASS = 'oj-collection-loadmore';\n\nconst DEFAULT_MARGIN = 1;\nconst LOAD_MORE_SELECTOR = `.${LOADMORE_STYLE_CLASS}`;\n\n/**\n * Component that only render items in the specified viewport.\n * @param props\n */\nexport function LoadMoreCollection<D>({\n data,\n children,\n viewportConfig,\n hasMore,\n onLoadMore,\n loadMoreIndicator,\n suggestions,\n loadMoreThreshold = DEFAULT_MARGIN\n}: Props<D>) {\n // detect if viewport has changed and it needs to re-render based on a new range\n useViewportIntersect(\n viewportConfig,\n Math.max(loadMoreThreshold, DEFAULT_MARGIN),\n 0,\n LOAD_MORE_SELECTOR,\n () => {\n if (data) {\n onLoadMore();\n }\n }\n );\n\n // if DataState is invalid (including not specified), just render blank\n if (!data) {\n return <div />;\n }\n\n // might need to support elementType prop in the future to allow customization of what\n // type of element to render for the root\n return (\n <Fragment>\n {suggestions}\n <Collection items={data}>{children}</Collection>\n {hasMore && loadMoreIndicator}\n </Fragment>\n );\n}\n"],"names":["LOADMORE_STYLE_CLASS","LOAD_MORE_SELECTOR","data","children","viewportConfig","hasMore","onLoadMore","loadMoreIndicator","suggestions","loadMoreThreshold","useViewportIntersect","Math","max","_jsxs","Fragment","_jsx","jsx","Collection","items"],"mappings":"6IA4Da,MAAAA,EAAuB,yBAG9BC,EAAqB,IAAID,kDAMzB,UAAgCE,KACpCA,EAAIC,SACJA,EAAQC,eACRA,EAAcC,QACdA,EAAOC,WACPA,EAAUC,kBACVA,EAAiBC,YACjBA,EAAWC,kBACXA,EAfqB,IA+BrB,OAbAC,uBACEN,EACAO,KAAKC,IAAIH,EApBU,GAqBnB,EACAR,GACA,KACMC,GACFI,GACD,IAKAJ,EAOHW,EAAAA,KAACC,EAAAA,SAAQ,CAAAX,SAAA,CACNK,EACDO,EAAAC,IAACC,aAAW,CAAAC,MAAOhB,EAAIC,SAAGA,IACzBE,GAAWE,KATPQ,eAYX"}
1
+ {"version":3,"file":"LoadMoreCollection-83413a59.js","sources":["../../src/PRIVATE_LoadMoreCollection/LoadMoreCollection.tsx"],"sourcesContent":["/**\n * @license\n * Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.\n * Licensed under The Universal Permissive License (UPL), Version 1.0\n * as shown at https://oss.oracle.com/licenses/upl/\n * @ignore\n */\nimport { ComponentChildren, Fragment } from 'preact';\nimport { ItemContext } from '../UNSAFE_Collection';\nimport { Collection } from '../PRIVATE_Collection';\nimport { useViewportIntersect, ViewportConfig } from '../hooks/UNSAFE_useViewportIntersect';\n\n/**\n * Props for the LoadMoreCollection component\n */\ntype Props<D> = {\n /**\n * A DataState object that provide information including data and metadata to the LoadMoreCollection.\n */\n data: D[] | null;\n\n /**\n * Renderer callback used to render each item\n */\n children: (context: ItemContext<D>) => ComponentChildren;\n\n /**\n * Viewport configuration including specifying the element which is used to determine what range\n * of data to render\n */\n viewportConfig: ViewportConfig;\n\n /**\n * Whether there are still more data to load. Internally, LoadMoreCollection will render the load\n * more indicator at the bottom if this is true\n */\n hasMore: boolean;\n\n /**\n * Callback function to handle when user scrolls to the end of the component and there are more items to load.\n * The function should update data prop on the component to include the next set of items fetched.\n */\n onLoadMore: () => void;\n\n /**\n * Optionally specify the custom load more indicator\n */\n loadMoreIndicator?: ComponentChildren;\n\n /**\n * Optionally provide the suggestion indicator sparkle\n */\n suggestions?: ComponentChildren;\n\n /**\n * Optionally specify how far in pixel from the bottom should load more occurs\n */\n loadMoreThreshold?: number;\n};\n\nexport const LOADMORE_STYLE_CLASS = 'oj-collection-loadmore';\n\nconst DEFAULT_MARGIN = 1;\nconst LOAD_MORE_SELECTOR = `.${LOADMORE_STYLE_CLASS}`;\n\n/**\n * Component that only render items in the specified viewport.\n * @param props\n */\nexport function LoadMoreCollection<D>({\n data,\n children,\n viewportConfig,\n hasMore,\n onLoadMore,\n loadMoreIndicator,\n suggestions,\n loadMoreThreshold = DEFAULT_MARGIN\n}: Props<D>) {\n // detect if viewport has changed and it needs to re-render based on a new range\n useViewportIntersect(\n viewportConfig,\n Math.max(loadMoreThreshold, DEFAULT_MARGIN),\n 0,\n LOAD_MORE_SELECTOR,\n () => {\n if (data) {\n onLoadMore();\n }\n }\n );\n\n // if DataState is invalid (including not specified), just render blank\n if (!data) {\n return <div />;\n }\n\n // might need to support elementType prop in the future to allow customization of what\n // type of element to render for the root\n return (\n <Fragment>\n {suggestions}\n <Collection items={data}>{children}</Collection>\n {hasMore && loadMoreIndicator}\n </Fragment>\n );\n}\n"],"names":["LOADMORE_STYLE_CLASS","LOAD_MORE_SELECTOR","data","children","viewportConfig","hasMore","onLoadMore","loadMoreIndicator","suggestions","loadMoreThreshold","useViewportIntersect","Math","max","_jsxs","Fragment","_jsx","jsx","Collection","items"],"mappings":"6IA4Da,MAAAA,EAAuB,yBAG9BC,EAAqB,IAAID,kDAMzB,UAAgCE,KACpCA,EAAIC,SACJA,EAAQC,eACRA,EAAcC,QACdA,EAAOC,WACPA,EAAUC,kBACVA,EAAiBC,YACjBA,EAAWC,kBACXA,EAfqB,IA+BrB,OAbAC,uBACEN,EACAO,KAAKC,IAAIH,EApBU,GAqBnB,EACAR,GACA,KACMC,GACFI,GACD,IAKAJ,EAOHW,EAAAA,KAACC,EAAAA,SAAQ,CAAAX,SAAA,CACNK,EACDO,EAAAC,IAACC,aAAW,CAAAC,MAAOhB,EAAIC,SAAGA,IACzBE,GAAWE,KATPQ,eAYX"}
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', './useDebounce-8b4d8cfb', './useTranslationBundle-7c40cb58', './LiveRegion-1917f798'], (function(e,n,t,i,o){"use strict";e.MaxLengthLiveRegion=function({maxLength:e,testId:c,valueLength:r=0}){const s=t.useDebounce(e-r,500),u=i.useTranslationBundle("@oracle/oraclejet-preact").formControl_maxLengthRemaining({CHARACTER_COUNT:`${s}`});return n.jsx(o.LiveRegion,{testId:c,children:u})}}));
2
- //# sourceMappingURL=MaxLengthLiveRegion-46bb45da.js.map
1
+ define(['exports', 'preact/jsx-runtime', './useDebounce-8b4d8cfb', './useTranslationBundle-68275657', './LiveRegion-17fea064'], (function(e,n,t,i,o){"use strict";e.MaxLengthLiveRegion=function({maxLength:e,testId:a,valueLength:r=0}){const s=t.useDebounce(e-r,500),u=i.useTranslationBundle("@oracle/oraclejet-preact").formControl_maxLengthRemaining({CHARACTER_COUNT:`${s}`});return n.jsx(o.LiveRegion,{testId:a,children:u})}}));
2
+ //# sourceMappingURL=MaxLengthLiveRegion-ecc0c894.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MaxLengthLiveRegion-46bb45da.js","sources":["../../src/UNSAFE_TextField/MaxLengthLiveRegion.tsx"],"sourcesContent":["import { useDebounce } from '../hooks/UNSAFE_useDebounce';\nimport { useTranslationBundle } from '../hooks/UNSAFE_useTranslationBundle';\nimport { BundleType } from '../resources/nls/bundle';\nimport { LiveRegion } from '../UNSAFE_LiveRegion';\nimport { TestIdProps } from '#hooks/UNSAFE_useTestId';\n\ntype Props = TestIdProps & {\n maxLength: number;\n valueLength?: number;\n};\n\nconst MAX_LENGTH_UPDATE_DELAY = 500;\n\nexport function MaxLengthLiveRegion({ maxLength, testId, valueLength = 0 }: Props) {\n // Comment copied from InputBase.js in Big JET:\n // Only update the aria-live div when the user has paused for more than\n // 500 milliseconds. That way, we avoid queued up aria-live messages which\n // would be annoying and not helpful. The 500ms was agreed upon in the\n // accessibility review meeting.\n const debouncedRemainingChars = useDebounce(maxLength - valueLength, MAX_LENGTH_UPDATE_DELAY);\n const translations = useTranslationBundle<BundleType>('@oracle/oraclejet-preact');\n const remainingCharsTranslatedString = translations.formControl_maxLengthRemaining({\n CHARACTER_COUNT: `${debouncedRemainingChars}`\n });\n\n return <LiveRegion testId={testId}>{remainingCharsTranslatedString}</LiveRegion>;\n}\n"],"names":["maxLength","testId","valueLength","debouncedRemainingChars","useDebounce","remainingCharsTranslatedString","useTranslationBundle","formControl_maxLengthRemaining","CHARACTER_COUNT","_jsx","LiveRegion","children"],"mappings":"mLAaM,UAA8BA,UAAEA,EAASC,OAAEA,EAAMC,YAAEA,EAAc,IAMrE,MAAMC,EAA0BC,EAAWA,YAACJ,EAAYE,EAR1B,KAUxBG,EADeC,uBAAiC,4BACFC,+BAA+B,CACjFC,gBAAiB,GAAGL,MAGtB,OAAOM,EAAAA,IAACC,EAAAA,WAAW,CAAAT,OAAQA,EAAMU,SAAGN,GACtC"}
1
+ {"version":3,"file":"MaxLengthLiveRegion-ecc0c894.js","sources":["../../src/UNSAFE_TextField/MaxLengthLiveRegion.tsx"],"sourcesContent":["import { useDebounce } from '../hooks/UNSAFE_useDebounce';\nimport { useTranslationBundle } from '../hooks/UNSAFE_useTranslationBundle';\nimport { BundleType } from '../resources/nls/bundle';\nimport { LiveRegion } from '../UNSAFE_LiveRegion';\nimport { TestIdProps } from '#hooks/UNSAFE_useTestId';\n\ntype Props = TestIdProps & {\n maxLength: number;\n valueLength?: number;\n};\n\nconst MAX_LENGTH_UPDATE_DELAY = 500;\n\nexport function MaxLengthLiveRegion({ maxLength, testId, valueLength = 0 }: Props) {\n // Comment copied from InputBase.js in Big JET:\n // Only update the aria-live div when the user has paused for more than\n // 500 milliseconds. That way, we avoid queued up aria-live messages which\n // would be annoying and not helpful. The 500ms was agreed upon in the\n // accessibility review meeting.\n const debouncedRemainingChars = useDebounce(maxLength - valueLength, MAX_LENGTH_UPDATE_DELAY);\n const translations = useTranslationBundle<BundleType>('@oracle/oraclejet-preact');\n const remainingCharsTranslatedString = translations.formControl_maxLengthRemaining({\n CHARACTER_COUNT: `${debouncedRemainingChars}`\n });\n\n return <LiveRegion testId={testId}>{remainingCharsTranslatedString}</LiveRegion>;\n}\n"],"names":["maxLength","testId","valueLength","debouncedRemainingChars","useDebounce","remainingCharsTranslatedString","useTranslationBundle","formControl_maxLengthRemaining","CHARACTER_COUNT","_jsx","LiveRegion","children"],"mappings":"mLAaM,UAA8BA,UAAEA,EAASC,OAAEA,EAAMC,YAAEA,EAAc,IAMrE,MAAMC,EAA0BC,EAAWA,YAACJ,EAAYE,EAR1B,KAUxBG,EADeC,uBAAiC,4BACFC,+BAA+B,CACjFC,gBAAiB,GAAGL,MAGtB,OAAOM,EAAAA,IAACC,EAAAA,WAAW,CAAAT,OAAQA,EAAMU,SAAGN,GACtC"}
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', 'preact/compat', './Dropdown-73238fd5', 'preact/hooks', './mergeProps-bcfa6a92', './classNames-08d99695', './useUser-797287de', './MenuItem-1a324975', './UNSAFE_Menu/themes/MenuStyles.css', './useTestId-c286f212', './UNSAFE_Menu/themes/DropdownMenuStyles.css', './Sheet-404b38fa', './useModal-536cb7ff', './Layer-139c23c4', './LayerHost-733ade2f', './UNSAFE_Menu/themes/SheetMenuStyles.css'], (function(e,n,s,t,o,r,a,u,l,c,i,d,m,f,p,h,b){"use strict";const y=({children:e,"aria-label":s,currentFocus:t="menu",display:d,closeSubmenu:m,menuId:f,menuLevel:p,anchorRef:h})=>{const{onClose:b,testId:y}=l.useMenuContext(),{direction:v}=u.useUser(),x=o.useRef(null),k=o.useRef({wasMouseMoved:!1,lastMouseLeaveMenuItemdRelatedTarget:null}),[C,S]=o.useState(),[g,w]=o.useState(!1),[j,E]=o.useState(!1),F=o.useCallback((e=>{S(e.key),"keyboard"===e.reason?w(!0):w(!1)}),[]),I=o.useCallback((()=>{const e=n=>{const s=l.keyElemExtractor(n.target),t=s?.key,o=s?.elem;if(t&&o){k.current.wasMouseMoved=!0;const n=new MouseEvent("mouseenter");o.dispatchEvent(n),x.current?.removeEventListener("mousemove",e)}};x.current?.addEventListener("mousemove",e)}),[]),{currentKeyProps:L}=function(e,n,s,t,r){const a=o.useMemo((()=>({ArrowDown:n,ArrowUp:e,Home:s,End:t})),[n,e,s,t]),u=o.useCallback((e=>{if(r){const n=a[e.key];if(n&&!e.shiftKey){const s=n();s&&r({key:s,reason:"keyboard"}),e.preventDefault()}}}),[r,a]);return{currentKeyProps:null==r?{}:{onKeyDown:u}}}(l.getPrevNext(x.current,!0,C),l.getPrevNext(x.current,!1,C),(()=>l.getNVisible(x.current,0)),(()=>l.getLastVisible(x.current)),F);o.useEffect((()=>{const e=x.current;let n;if("none"!==t&&e)if("menu"===t){F({key:void 0,reason:"click"});const s=()=>{e.focus()};"sheet"===d?s():n=setTimeout((()=>{s()}),M)}else if("firstItem"===t){const e=l.getNVisible(x.current,0);e&&F({key:e,reason:"keyboard"})}else if("secondItem"===t){const e=l.getNVisible(x.current,1);e&&F({key:e,reason:"keyboard"})}return()=>{clearTimeout(n)}}),[F,t,p,d,h]),o.useEffect((()=>{I()}),[I]);const P=i.useTestId(y);return n.jsx("div",{...f&&{id:f},ref:x,tabIndex:C||"main"!==p&&"sheet"!==d?-1:0,role:"menu","aria-label":s,class:a.classNames([c.menuStyles.menuContainerStyle,c.menuStyles[`${d}MenuContainerStyle`]]),...r.mergeProps(L,l.getKeyboardCloseProps(b,p),l.getCloseSubmenuEvent(v,m),l.getMenuContainerFocusMethods((()=>{x.current?.contains(document.activeElement)||(w(!1),E(!1))}),(()=>{E(!0)})),l.getMenuContainerMouseLeave((e=>{e.relatedTarget&&e.relatedTarget.isEqualNode(k.current.lastMouseLeaveMenuItemdRelatedTarget)||(F({key:void 0,reason:"mouseEnter"}),x.current?.focus())})),l.getMenuPointerDown()),...P,children:n.jsx(l.MenuContainerContext.Provider,{value:{menuContainerRef:x,currentKey:C,showFocusRing:g,changeKey:F,menuContainerGeneralInformation:k,isContainerFocused:j},children:e})})},M=0,v=s.forwardRef((({anchorRef:e,defaultPlacement:o,offsetValue:r,closeSubmenu:a,children:u,"aria-label":c,currentFocus:i,menuId:m,menuLevel:f,flipOptions:p,isOpen:h},b)=>{const{onClose:M}=l.useMenuContext(),v=s.useCallback((e=>{if("sub"!==f&&"outsideMousedown"===e.reason){const n=l.keyElemExtractor(e.target)?.key;n||M?.({reason:"outsideClick",target:e.target})}}),[M,f]);return n.jsx(t.Dropdown,{onClose:v,isOpen:h,placement:o,anchorRef:e,flipOptions:p,offset:r,shiftOptions:{mainAxis:!1,crossAxis:!1},children:n.jsx("div",{class:d.dropdownMenuStyles.base,style:{minWidth:x},ref:b,children:n.jsx(y,{menuLevel:f,closeSubmenu:a,"aria-label":c,currentFocus:i,menuId:m,display:"dropdown",anchorRef:e,children:u})})})})),x=200,k=({children:e})=>n.jsx("div",{class:b.sheetMenuStyles.modalWrapper,children:e}),C=s.forwardRef((({children:e},s)=>n.jsx("div",{class:b.sheetMenuStyles.modalContainer,ref:s,children:e}))),S=({backdropVisible:e=!1})=>n.jsx("div",{class:a.classNames([b.sheetMenuStyles.modalBackdrop,e&&b.sheetMenuStyles.modalBackdropVisible])}),g=({children:e,"aria-label":s,currentFocus:t,anchorRef:r,closeSubmenu:a,menuLevel:u})=>{const{onClose:c}=l.useMenuContext();o.useEffect((()=>{const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}}),[]);const i=o.useCallback((()=>{c?.({reason:"dismissed"})}),[c]),{backdropRef:d}=f.useModal({isOpen:!0,onBackdropClick:i}),{swipeProps:h}=m.useSheetSwipe(i);return n.jsx(p.Layer,{logicalParentRef:r,children:n.jsxs(k,{children:[n.jsx(S,{backdropVisible:"main"===u}),n.jsx(C,{ref:d,children:n.jsx("div",{class:b.sheetMenuStyles.sheetMenuContainerWrapper,...h,children:n.jsx(y,{"aria-label":s,currentFocus:t,display:"sheet",closeSubmenu:a,menuLevel:u,children:e})})})]})})},w=l.getIsMobile();e.DropdownMenu=v,e.Menu=({onClose:e,isOpen:s,testId:t,initialFocus:o="menu",placement:r,offsetValue:a,...u})=>n.jsx(l.MenuContext.Provider,{value:{onClose:e,isMobile:w,testId:t},children:n.jsx(n.Fragment,{children:w?n.jsx(n.Fragment,{children:s?n.jsx(g,{...u,currentFocus:o,menuLevel:"main"}):null}):n.jsx(v,{...u,isOpen:s,currentFocus:o,menuLevel:"main",defaultPlacement:r,offsetValue:a,flipOptions:{crossAxis:!0,mainAxis:!0,fallbackPlacements:["bottom-start","bottom-end","top-start","top-end","end-top","start-top","end-bottom","start-bottom"]}})})}),e.SheetMenu=g}));
1
+ define(['exports', 'preact/jsx-runtime', 'preact/compat', './Dropdown-3d2abe1f', 'preact/hooks', './mergeProps-bcfa6a92', './classNames-08d99695', './useUser-e8dd7f7c', './MenuItem-1a324975', './UNSAFE_Menu/themes/MenuStyles.css', './useTestId-0140aa44', './UNSAFE_Menu/themes/DropdownMenuStyles.css', './Sheet-08578790', './useModal-536cb7ff', './Layer-69221878', './LayerHost-27dfba9e', './UNSAFE_Menu/themes/SheetMenuStyles.css'], (function(e,n,s,t,o,r,a,u,l,c,i,d,m,f,p,h,b){"use strict";const y=({children:e,"aria-label":s,currentFocus:t="menu",display:d,closeSubmenu:m,menuId:f,menuLevel:p,anchorRef:h})=>{const{onClose:b,testId:y}=l.useMenuContext(),{direction:v}=u.useUser(),x=o.useRef(null),k=o.useRef({wasMouseMoved:!1,lastMouseLeaveMenuItemdRelatedTarget:null}),[C,S]=o.useState(),[g,w]=o.useState(!1),[j,E]=o.useState(!1),F=o.useCallback((e=>{S(e.key),"keyboard"===e.reason?w(!0):w(!1)}),[]),I=o.useCallback((()=>{const e=n=>{const s=l.keyElemExtractor(n.target),t=s?.key,o=s?.elem;if(t&&o){k.current.wasMouseMoved=!0;const n=new MouseEvent("mouseenter");o.dispatchEvent(n),x.current?.removeEventListener("mousemove",e)}};x.current?.addEventListener("mousemove",e)}),[]),{currentKeyProps:L}=function(e,n,s,t,r){const a=o.useMemo((()=>({ArrowDown:n,ArrowUp:e,Home:s,End:t})),[n,e,s,t]),u=o.useCallback((e=>{if(r){const n=a[e.key];if(n&&!e.shiftKey){const s=n();s&&r({key:s,reason:"keyboard"}),e.preventDefault()}}}),[r,a]);return{currentKeyProps:null==r?{}:{onKeyDown:u}}}(l.getPrevNext(x.current,!0,C),l.getPrevNext(x.current,!1,C),(()=>l.getNVisible(x.current,0)),(()=>l.getLastVisible(x.current)),F);o.useEffect((()=>{const e=x.current;let n;if("none"!==t&&e)if("menu"===t){F({key:void 0,reason:"click"});const s=()=>{e.focus()};"sheet"===d?s():n=setTimeout((()=>{s()}),M)}else if("firstItem"===t){const e=l.getNVisible(x.current,0);e&&F({key:e,reason:"keyboard"})}else if("secondItem"===t){const e=l.getNVisible(x.current,1);e&&F({key:e,reason:"keyboard"})}return()=>{clearTimeout(n)}}),[F,t,p,d,h]),o.useEffect((()=>{I()}),[I]);const P=i.useTestId(y);return n.jsx("div",{...f&&{id:f},ref:x,tabIndex:C||"main"!==p&&"sheet"!==d?-1:0,role:"menu","aria-label":s,class:a.classNames([c.menuStyles.menuContainerStyle,c.menuStyles[`${d}MenuContainerStyle`]]),...r.mergeProps(L,l.getKeyboardCloseProps(b,p),l.getCloseSubmenuEvent(v,m),l.getMenuContainerFocusMethods((()=>{x.current?.contains(document.activeElement)||(w(!1),E(!1))}),(()=>{E(!0)})),l.getMenuContainerMouseLeave((e=>{e.relatedTarget&&e.relatedTarget.isEqualNode(k.current.lastMouseLeaveMenuItemdRelatedTarget)||(F({key:void 0,reason:"mouseEnter"}),x.current?.focus())})),l.getMenuPointerDown()),...P,children:n.jsx(l.MenuContainerContext.Provider,{value:{menuContainerRef:x,currentKey:C,showFocusRing:g,changeKey:F,menuContainerGeneralInformation:k,isContainerFocused:j},children:e})})},M=0,v=s.forwardRef((({anchorRef:e,defaultPlacement:o,offsetValue:r,closeSubmenu:a,children:u,"aria-label":c,currentFocus:i,menuId:m,menuLevel:f,flipOptions:p,isOpen:h},b)=>{const{onClose:M}=l.useMenuContext(),v=s.useCallback((e=>{if("sub"!==f&&"outsideMousedown"===e.reason){const n=l.keyElemExtractor(e.target)?.key;n||M?.({reason:"outsideClick",target:e.target})}}),[M,f]);return n.jsx(t.Dropdown,{onClose:v,isOpen:h,placement:o,anchorRef:e,flipOptions:p,offset:r,shiftOptions:{mainAxis:!1,crossAxis:!1},children:n.jsx("div",{class:d.dropdownMenuStyles.base,style:{minWidth:x},ref:b,children:n.jsx(y,{menuLevel:f,closeSubmenu:a,"aria-label":c,currentFocus:i,menuId:m,display:"dropdown",anchorRef:e,children:u})})})})),x=200,k=({children:e})=>n.jsx("div",{class:b.sheetMenuStyles.modalWrapper,children:e}),C=s.forwardRef((({children:e},s)=>n.jsx("div",{class:b.sheetMenuStyles.modalContainer,ref:s,children:e}))),S=({backdropVisible:e=!1})=>n.jsx("div",{class:a.classNames([b.sheetMenuStyles.modalBackdrop,e&&b.sheetMenuStyles.modalBackdropVisible])}),g=({children:e,"aria-label":s,currentFocus:t,anchorRef:r,closeSubmenu:a,menuLevel:u})=>{const{onClose:c}=l.useMenuContext();o.useEffect((()=>{const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}}),[]);const i=o.useCallback((()=>{c?.({reason:"dismissed"})}),[c]),{backdropRef:d}=f.useModal({isOpen:!0,onBackdropClick:i}),{swipeProps:h}=m.useSheetSwipe(i);return n.jsx(p.Layer,{logicalParentRef:r,children:n.jsxs(k,{children:[n.jsx(S,{backdropVisible:"main"===u}),n.jsx(C,{ref:d,children:n.jsx("div",{class:b.sheetMenuStyles.sheetMenuContainerWrapper,...h,children:n.jsx(y,{"aria-label":s,currentFocus:t,display:"sheet",closeSubmenu:a,menuLevel:u,children:e})})})]})})},w=l.getIsMobile();e.DropdownMenu=v,e.Menu=({onClose:e,isOpen:s,testId:t,initialFocus:o="menu",placement:r,offsetValue:a,...u})=>n.jsx(l.MenuContext.Provider,{value:{onClose:e,isMobile:w,testId:t},children:n.jsx(n.Fragment,{children:w?n.jsx(n.Fragment,{children:s?n.jsx(g,{...u,currentFocus:o,menuLevel:"main"}):null}):n.jsx(v,{...u,isOpen:s,currentFocus:o,menuLevel:"main",defaultPlacement:r,offsetValue:a,flipOptions:{crossAxis:!0,mainAxis:!0,fallbackPlacements:["bottom-start","bottom-end","top-start","top-end","end-top","start-top","end-bottom","start-bottom"]}})})}),e.SheetMenu=g}));
2
2
  //# sourceMappingURL=Menu-bb715ef5.js.map
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', './ButtonLabelLayout-ce54dfdc', './ChevronDown-502b16f2', './Menu-bb715ef5', './MenuItem-1a324975', 'preact/hooks', 'preact', './mergeProps-bcfa6a92', './logger-0f873e29', './LayerHost-733ade2f', 'preact/compat', 'css!./TooltipContentStyles.styles.css', 'module', './hooks/UNSAFE_useTooltip/themes/redwood/TooltipContentVariants.css', './tooltipUtils-30886397', 'css!./IconStyle.styles.css', './SelectMenuGroupContext-67f24a8f', './UNSAFE_Separator/themes/SeparatorStyles.css', 'css!./MenuSeparatorStyles.styles.css', 'module', './UNSAFE_Menu/themes/redwood/MenuSeparatorVariants.css', './useMenuAction-4ecda01c', './BaseButton-c86afd54'], (function(e,t,o,s,n,a,r,u,i,l,c,d,p,h,f,M,m,y,b,S,T,g,B,x){"use strict";const v=d.forwardRef((({children:e,label:a,suffix:l,variant:c="outlined",isDisabled:d=!1,isMenuOpen:p=!1,onToggleMenu:h,size:f="md",type:M="button",width:m,icon:y,testId:b,"aria-describedby":S,onBlur:T,onFocus:g,onMouseEnter:v,onMouseLeave:w,onTouchEnd:E,onTouchStart:F},A)=>{const I=r.useRef(null);r.useImperativeHandle(A,(()=>I.current),[I]);const{triggerProps:L,menuProps:j}=B.useMenuAction({isDisabled:d,onToggleMenu:h,isMenuOpen:p,anchorRef:I}),C={type:"button",buttonType:M},D={onBlur:T,onFocus:g,onMouseEnter:v,onMouseLeave:w,onTouchEnd:E,onTouchStart:F},N=t.jsx(x.BaseButton,{...i.mergeProps(L,D),styling:p?["min","active"]:["min"],elementDetails:C,isDisabled:d,variant:c,width:m,size:f,ref:I,testId:b,"aria-label":l?`${a} ${l}`:a,"aria-describedby":S,children:t.jsx(o.ButtonLabelLayout,{display:"all",suffix:l,startIcon:y,endIcon:t.jsx(s.SvgChevronDown,{}),size:f,children:a})});return d?N:t.jsxs(u.Fragment,{children:[N,t.jsx(n.Menu,{...j,"aria-label":a,offsetValue:4,children:e})]})}));v.displayName="MenuButton",e.MenuButton=v}));
1
+ define(['exports', 'preact/jsx-runtime', './ButtonLabelLayout-ce54dfdc', './ChevronDown-502b16f2', './Menu-bb715ef5', './MenuItem-1a324975', 'preact/hooks', 'preact', './mergeProps-bcfa6a92', './logger-0f873e29', './LayerHost-27dfba9e', 'preact/compat', 'css!./TooltipContentStyles.styles.css', 'module', './hooks/UNSAFE_useTooltip/themes/redwood/TooltipContentVariants.css', './tooltipUtils-36ddb881', 'css!./IconStyle.styles.css', './SelectMenuGroupContext-67f24a8f', './UNSAFE_Separator/themes/SeparatorStyles.css', 'css!./MenuSeparatorStyles.styles.css', 'module', './UNSAFE_Menu/themes/redwood/MenuSeparatorVariants.css', './useMenuAction-4ecda01c', './BaseButton-c86afd54'], (function(e,t,o,s,n,a,r,u,i,l,c,d,p,h,f,b,M,m,y,S,T,g,B,x){"use strict";const v=d.forwardRef((({children:e,label:a,suffix:l,variant:c="outlined",isDisabled:d=!1,isMenuOpen:p=!1,onToggleMenu:h,size:f="md",type:b="button",width:M,icon:m,testId:y,"aria-describedby":S,onBlur:T,onFocus:g,onMouseEnter:v,onMouseLeave:w,onTouchEnd:E,onTouchStart:F},A)=>{const I=r.useRef(null);r.useImperativeHandle(A,(()=>I.current),[I]);const{triggerProps:L,menuProps:j}=B.useMenuAction({isDisabled:d,onToggleMenu:h,isMenuOpen:p,anchorRef:I}),C={type:"button",buttonType:b},D={onBlur:T,onFocus:g,onMouseEnter:v,onMouseLeave:w,onTouchEnd:E,onTouchStart:F},N=t.jsx(x.BaseButton,{...i.mergeProps(L,D),styling:p?["min","active"]:["min"],elementDetails:C,isDisabled:d,variant:c,width:M,size:f,ref:I,testId:y,"aria-label":l?`${a} ${l}`:a,"aria-describedby":S,children:t.jsx(o.ButtonLabelLayout,{display:"all",suffix:l,startIcon:m,endIcon:t.jsx(s.SvgChevronDown,{}),size:f,children:a})});return d?N:t.jsxs(u.Fragment,{children:[N,t.jsx(n.Menu,{...j,"aria-label":a,offsetValue:4,children:e})]})}));v.displayName="MenuButton",e.MenuButton=v}));
2
2
  //# sourceMappingURL=MenuButton-66e5430a.js.map
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', 'preact/hooks', './Text-0609bf4d', './classNames-08d99695', './useId-c9578d26', './mergeProps-bcfa6a92', './usePress-949a0d03', './useUser-797287de', './useComponentTheme-5aa41a8f', './mergeInterpolations-9ede4cf7', './flexitem-5db48325', './useInteractionStyle-ee1dc0c0', 'preact', 'preact/compat', './clientHints-fff66be9', './useToggle-a29f97af', './UNSAFE_Menu/themes/redwood/MenuItemTheme'], (function(e,n,t,o,r,s,a,u,i,l,c,d,m,f,p,g,y,h){"use strict";const C=e=>e.dataset.ojMenuItemKey,b=e=>{const n=e.closest("[data-oj-menu-item-key]");if(n){const e=C(n);return void 0===e?null:{key:e,elem:n}}return null},M=(e,n)=>{if(!n)return{};return{onKeyDown:t=>{"ltr"===e?"ArrowRight"===t.key&&n?.():"ArrowLeft"===t.key&&n?.()}}},v=f.createContext({isMobile:!1,onClose:()=>null,testId:""});function x(){return t.useContext(v)}const I=f.createContext({menuContainerRef:{current:null},currentKey:void 0,showFocusRing:!1,changeKey:()=>{},isContainerFocused:!1,menuContainerGeneralInformation:{current:{wasMouseMoved:!1,lastMouseLeaveMenuItemdRelatedTarget:null}}});function k(){return t.useContext(I)}const w=p.forwardRef((({id:e,label:s,onAction:f,startIcon:p,endIcon:g,role:C,isChecked:b,isDisabled:v=!1,variant:I="standard",type:w,hoverInfo:j,openSubmenu:S,menuItemLabelWeight:T="normal",isSubmenuOpen:P,submenuId:R,submenuRef:E,itemKey:F},L)=>{const{onClose:A}=x(),{currentKey:D,changeKey:K,showFocusRing:N,menuContainerRef:U,menuContainerGeneralInformation:O,isContainerFocused:q}=k(),B=t.useRef(null),{direction:G}=i.useUser(),H=D===e,V=t.useCallback((e=>{"submenu"!==w&&A?.({reason:"itemAction"}),f?.(e)}),[w,A,f]),{hoverProps:z}=function(e){const{bool:n,setTrue:t,setFalse:o}=y.useToggle(!1);return{hoverProps:{ontouchend:t,onMouseEnter:t=>{n?o():e.onMouseEnter(t)},onMouseLeave:n=>{e.onMouseLeave(n)}}}}({onMouseEnter:n=>{j?.hoverStatus.current.recentClose||j?.hoverStatus.current.pendingUnhover||(j&&O.current.wasMouseMoved&&(j.hoverStatus.current.pendingUnhover=!0),O.current.wasMouseMoved&&(j?.hoverProps.onMouseEnter(n),K({key:e,reason:"mouseEnter"})))},onMouseLeave:e=>{j&&(j.hoverStatus.current.pendingUnhover=!1),(U.current?.contains(e.relatedTarget)||E?.current?.parentElement?.contains(e.relatedTarget))&&(O.current.lastMouseLeaveMenuItemdRelatedTarget=e.relatedTarget)}}),{pressProps:W}=u.usePress(V,{isDisabled:v});t.useLayoutEffect((()=>{H&&B.current?.focus()}),[H]);const{interactionProps:$}=m.useInteractionStyle({isDisabled:v}),{classes:_,styles:{iconLabelContainer:J,iconContainer:Q,startIconContainer:X,labelContainer:Y,endIconContainer:Z}}=l.useComponentTheme(h.MenuItemRedwoodTheme,{current:H?"isCurrent":"notCurrent",focusRing:N?"isFocusRing":"notFocusRing",variant:v?"disabled":I,containerFocused:q?"isContainerFocused":"notContainerFocused",submenuOpen:P?"isSubmenuOpen":"notSubmenuOpen"}),ee=c.mergeInterpolations([...Object.values(d.flexitemInterpolations)]),{class:ne,...te}=ee({flex:"1 1 auto",alignSelf:"center"}),{class:oe,...re}=ee({flex:"0 0 auto",alignSelf:"center"}),se=r.classNames([oe,J,Q,X]),ae=r.classNames([ne,J,Y]),ue=r.classNames([oe,J,Q,Z]);return n.jsx("div",{role:"presentation",...void 0!==R&&"submenu"===w&&{"aria-owns":R},children:n.jsxs("a",{ref:e=>{B.current=e,"function"==typeof L?L(e):L&&(L.current=e)},"data-oj-label":s,"data-oj-key":F,class:_,...a.mergeProps($,z,W,M(G,S),(ie=e,le=K,{onClick:()=>{le({key:ie,reason:"click"})}})),role:C,"data-oj-menu-item-key":e,..."submenu"===w&&{"aria-haspopup":!0,"aria-expanded":"bold"===T||!!P},...v&&{"aria-disabled":!0},..."select"===w&&{"aria-checked":!!b},tabIndex:H?0:-1,children:[p&&n.jsx("span",{style:re,class:se,children:p}),n.jsx("span",{style:te,class:ae,children:n.jsx(o.Text,{variant:"inherit",size:"md",weight:T,children:s})}),g&&n.jsx("span",{style:re,class:ue,children:g})]})});var ie,le}));e.BaseMenuItem=w,e.MenuContainerContext=I,e.MenuContext=v,e.MenuItem=function(e){const o=s.useId(),r=t.useMemo((()=>`oj-menu-item-${o}`),[o]);return n.jsx(w,{...e,role:"menuitem",type:"simple",id:r})},e.getCloseSubmenuEvent=(e,n)=>{if(!n)return{};return{onKeyDown:t=>{("Escape"===t.key||"ltr"===e&&"ArrowLeft"===t.key||"rtl"===e&&"ArrowRight"===t.key)&&(t.stopPropagation(),n?.())}}},e.getIsMobile=()=>{const{deviceType:e}=g.getClientHints();return"phone"===e},e.getKeyboardCloseProps=(e,n)=>({onKeyDown:t=>{"Tab"===t.key?(t.stopPropagation(),e?.({reason:"dismissed"}),t.preventDefault()):"Escape"===t.key&&"main"===n&&(t.stopPropagation(),e?.({reason:"dismissed"}))}}),e.getLastVisible=e=>{if(e){const n=e.querySelectorAll("[data-oj-menu-item-key]"),t=n[n.length-1];if(t){const e=C(t);if(e)return e}}return null},e.getMenuContainerFocusMethods=(e,n)=>({onBlur:()=>{setTimeout((()=>{e()}),100)},onFocus:()=>{n()}}),e.getMenuContainerMouseLeave=e=>({onMouseLeave:n=>{e(n)}}),e.getMenuPointerDown=()=>({onPointerDown:e=>{const n=b(e.target);n?.key||e.preventDefault()}}),e.getNVisible=(e,n)=>{if(e){const t=e.querySelectorAll("[data-oj-menu-item-key]")[n];if(t){const e=C(t);if(e)return e}}return null},e.getPrevNext=(e,n,t)=>()=>{if(e){const o=Array.from(e.querySelectorAll("[data-oj-menu-item-key]"));let r=o.findIndex((e=>C(e)===t))+(n?-1:1);const s=o.length-1;r<0&&(r=s),r>s&&(r=0);const a=C(o[r]);return a||null}return null},e.keyElemExtractor=b,e.useMenuContainerContext=k,e.useMenuContext=x}));
1
+ define(['exports', 'preact/jsx-runtime', 'preact/hooks', './Text-0609bf4d', './classNames-08d99695', './useId-c9578d26', './mergeProps-bcfa6a92', './usePress-949a0d03', './useUser-e8dd7f7c', './useComponentTheme-5aa41a8f', './mergeInterpolations-9ede4cf7', './flexitem-5db48325', './useInteractionStyle-ee1dc0c0', 'preact', 'preact/compat', './clientHints-fff66be9', './useToggle-a29f97af', './UNSAFE_Menu/themes/redwood/MenuItemTheme'], (function(e,n,t,o,r,s,a,u,i,l,c,d,m,f,p,g,y,h){"use strict";const C=e=>e.dataset.ojMenuItemKey,b=e=>{const n=e.closest("[data-oj-menu-item-key]");if(n){const e=C(n);return void 0===e?null:{key:e,elem:n}}return null},M=(e,n)=>{if(!n)return{};return{onKeyDown:t=>{"ltr"===e?"ArrowRight"===t.key&&n?.():"ArrowLeft"===t.key&&n?.()}}},v=f.createContext({isMobile:!1,onClose:()=>null,testId:""});function x(){return t.useContext(v)}const I=f.createContext({menuContainerRef:{current:null},currentKey:void 0,showFocusRing:!1,changeKey:()=>{},isContainerFocused:!1,menuContainerGeneralInformation:{current:{wasMouseMoved:!1,lastMouseLeaveMenuItemdRelatedTarget:null}}});function k(){return t.useContext(I)}const w=p.forwardRef((({id:e,label:s,onAction:f,startIcon:p,endIcon:g,role:C,isChecked:b,isDisabled:v=!1,variant:I="standard",type:w,hoverInfo:j,openSubmenu:S,menuItemLabelWeight:T="normal",isSubmenuOpen:P,submenuId:R,submenuRef:E,itemKey:F},L)=>{const{onClose:A}=x(),{currentKey:D,changeKey:K,showFocusRing:N,menuContainerRef:U,menuContainerGeneralInformation:O,isContainerFocused:q}=k(),B=t.useRef(null),{direction:G}=i.useUser(),H=D===e,V=t.useCallback((e=>{"submenu"!==w&&A?.({reason:"itemAction"}),f?.(e)}),[w,A,f]),{hoverProps:z}=function(e){const{bool:n,setTrue:t,setFalse:o}=y.useToggle(!1);return{hoverProps:{ontouchend:t,onMouseEnter:t=>{n?o():e.onMouseEnter(t)},onMouseLeave:n=>{e.onMouseLeave(n)}}}}({onMouseEnter:n=>{j?.hoverStatus.current.recentClose||j?.hoverStatus.current.pendingUnhover||(j&&O.current.wasMouseMoved&&(j.hoverStatus.current.pendingUnhover=!0),O.current.wasMouseMoved&&(j?.hoverProps.onMouseEnter(n),K({key:e,reason:"mouseEnter"})))},onMouseLeave:e=>{j&&(j.hoverStatus.current.pendingUnhover=!1),(U.current?.contains(e.relatedTarget)||E?.current?.parentElement?.contains(e.relatedTarget))&&(O.current.lastMouseLeaveMenuItemdRelatedTarget=e.relatedTarget)}}),{pressProps:W}=u.usePress(V,{isDisabled:v});t.useLayoutEffect((()=>{H&&B.current?.focus()}),[H]);const{interactionProps:$}=m.useInteractionStyle({isDisabled:v}),{classes:_,styles:{iconLabelContainer:J,iconContainer:Q,startIconContainer:X,labelContainer:Y,endIconContainer:Z}}=l.useComponentTheme(h.MenuItemRedwoodTheme,{current:H?"isCurrent":"notCurrent",focusRing:N?"isFocusRing":"notFocusRing",variant:v?"disabled":I,containerFocused:q?"isContainerFocused":"notContainerFocused",submenuOpen:P?"isSubmenuOpen":"notSubmenuOpen"}),ee=c.mergeInterpolations([...Object.values(d.flexitemInterpolations)]),{class:ne,...te}=ee({flex:"1 1 auto",alignSelf:"center"}),{class:oe,...re}=ee({flex:"0 0 auto",alignSelf:"center"}),se=r.classNames([oe,J,Q,X]),ae=r.classNames([ne,J,Y]),ue=r.classNames([oe,J,Q,Z]);return n.jsx("div",{role:"presentation",...void 0!==R&&"submenu"===w&&{"aria-owns":R},children:n.jsxs("a",{ref:e=>{B.current=e,"function"==typeof L?L(e):L&&(L.current=e)},"data-oj-label":s,"data-oj-key":F,class:_,...a.mergeProps($,z,W,M(G,S),(ie=e,le=K,{onClick:()=>{le({key:ie,reason:"click"})}})),role:C,"data-oj-menu-item-key":e,..."submenu"===w&&{"aria-haspopup":!0,"aria-expanded":"bold"===T||!!P},...v&&{"aria-disabled":!0},..."select"===w&&{"aria-checked":!!b},tabIndex:H?0:-1,children:[p&&n.jsx("span",{style:re,class:se,children:p}),n.jsx("span",{style:te,class:ae,children:n.jsx(o.Text,{variant:"inherit",size:"md",weight:T,children:s})}),g&&n.jsx("span",{style:re,class:ue,children:g})]})});var ie,le}));e.BaseMenuItem=w,e.MenuContainerContext=I,e.MenuContext=v,e.MenuItem=function(e){const o=s.useId(),r=t.useMemo((()=>`oj-menu-item-${o}`),[o]);return n.jsx(w,{...e,role:"menuitem",type:"simple",id:r})},e.getCloseSubmenuEvent=(e,n)=>{if(!n)return{};return{onKeyDown:t=>{("Escape"===t.key||"ltr"===e&&"ArrowLeft"===t.key||"rtl"===e&&"ArrowRight"===t.key)&&(t.stopPropagation(),n?.())}}},e.getIsMobile=()=>{const{deviceType:e}=g.getClientHints();return"phone"===e},e.getKeyboardCloseProps=(e,n)=>({onKeyDown:t=>{"Tab"===t.key?(t.stopPropagation(),e?.({reason:"dismissed"}),t.preventDefault()):"Escape"===t.key&&"main"===n&&(t.stopPropagation(),e?.({reason:"dismissed"}))}}),e.getLastVisible=e=>{if(e){const n=e.querySelectorAll("[data-oj-menu-item-key]"),t=n[n.length-1];if(t){const e=C(t);if(e)return e}}return null},e.getMenuContainerFocusMethods=(e,n)=>({onBlur:()=>{setTimeout((()=>{e()}),100)},onFocus:()=>{n()}}),e.getMenuContainerMouseLeave=e=>({onMouseLeave:n=>{e(n)}}),e.getMenuPointerDown=()=>({onPointerDown:e=>{const n=b(e.target);n?.key||e.preventDefault()}}),e.getNVisible=(e,n)=>{if(e){const t=e.querySelectorAll("[data-oj-menu-item-key]")[n];if(t){const e=C(t);if(e)return e}}return null},e.getPrevNext=(e,n,t)=>()=>{if(e){const o=Array.from(e.querySelectorAll("[data-oj-menu-item-key]"));let r=o.findIndex((e=>C(e)===t))+(n?-1:1);const s=o.length-1;r<0&&(r=s),r>s&&(r=0);const a=C(o[r]);return a||null}return null},e.keyElemExtractor=b,e.useMenuContainerContext=k,e.useMenuContext=x}));
2
2
  //# sourceMappingURL=MenuItem-1a324975.js.map
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', 'preact/hooks', './Flex-590160eb', './UNSAFE_MessageBanner/themes/redwood/MessageBannerTheme', './useComponentTheme-5aa41a8f', './timer-571d3748', './classNames-08d99695', './Close-a88a3dcf', './IconButton-368fba34', './useTranslationBundle-7c40cb58', './PRIVATE_Message/themes/MessageStyles.css', 'preact', './MessageFormattingUtils-2e19d8de', './MessagesManager-2c4c218f', './utils-32e81a13'], (function(e,s,a,t,n,r,o,l,c,i,u,m,d,g,f,y){"use strict";function v({onAction:e,variant:a="banner"}){const t=u.useTranslationBundle("@oracle/oraclejet-preact"),n=s.jsx(i.IconButton,{"aria-label":t.message_close(),size:"sm",variant:"borderless",onAction:e,children:s.jsx(c.SvgClose,{})}),r=l.classNames([m.messageCloseButtonStyles.base,m.messageCloseButtonStyles[a]]);return s.jsx("div",{class:r,"data-oj-message-close-button":"",children:n})}function p({item:e,renderer:a}){const t=l.classNames([m.messageStartIconStyles.base,m.messageStartIconStyles.toast,m.messageStartIconStyles.customToast]);return s.jsx("div",{class:t,role:"presentation","data-oj-message-custom-icon":"",children:a(e)})}function b(e){const{detail:a}=e.data;return g.isValidValueForProp(a)?s.jsx(d.Fragment,{children:a}):null}function x({item:e,renderer:a,variant:t="banner"}){const n=null!=a,r=(a??b)(e);if(null==r)return null;const o=l.classNames([m.messageDetailStyles.base,m.messageDetailStyles[t]]);return s.jsx("div",{class:o,...n?{"data-oj-message-custom-detail":""}:{},children:r})}function j({children:e,variant:a="banner"}){const t=l.classNames([m.messageHeaderStyles.base,m.messageHeaderStyles[a]]);return s.jsx("div",{role:"presentation",class:t,children:e})}function S({value:e,variant:a="banner"}){const t=l.classNames([m.messageTimestampStyles[a]]),n=g.formatTimestamp(e);return s.jsx("div",{class:t,children:n})}function h(e){return g.isValidValueForProp(e,"severity")&&"none"!==e}e.Message=function({detailRenderer:e,iconRenderer:c,item:i,onClose:u,messageRef:d=(()=>{}),variant:b="pageBanner"}){const{closeAffordance:C="on",severity:B="error",sound:M,summary:T,timestamp:k}=i.data,{autoTimeout:F="off"}=i.data,I=function(e){return"pageBanner"===e||"sectionBanner"===e?"banner":"toast"}(b),N=a.useCallback((()=>{u?.(i)}),[i,u]),V=a.useCallback((e=>{"Escape"===e.key&&"on"===C&&u?.(i)}),[C,i,u]),A="toast"===I&&"off"!==F,R=a.useRef(),P="on"===F?5e3:"number"==typeof F?F:5e3,E=a.useCallback((()=>{R.current||(R.current=new o.Timer(N,P))}),[N,P]),U=a.useCallback((()=>{R.current&&(R.current.clear(),R.current=void 0)}),[]),w=a.useCallback((()=>{R.current?.pause()}),[]),D=a.useCallback((()=>{R.current?.resume()}),[]);a.useEffect((()=>(g.isValidValueForProp(M)&&f.playSound(M),A&&E(),()=>{U()})),[]);const{variantClasses:_}=r.useComponentTheme(n.MessageBannerRedwoodTheme,{severity:B}),H=l.classNames(["banner"===I&&_,m.messageStyles.base[I],"toast"!==b&&f.severityBasedStyleClass(B,I),"sectionBanner"===b&&m.messageStyles.section]),$=l.classNames([m.messageStyles.content.base,m.messageStyles.content[I]]);return s.jsx("div",{ref:d,class:H,role:"alert","aria-atomic":"true","data-oj-key":`${typeof i.key}-${i.key}`,tabIndex:0,onKeyUp:V,onFocusIn:w,onFocusOut:D,children:s.jsxs("div",{class:$,children:[c?s.jsx(p,{item:i,renderer:c}):h(B)?s.jsx(f.MessageStartIcon,{severity:B,variant:I}):null,s.jsxs(t.Flex,{direction:"column",flex:"1",gap:y.xUnits(2),children:[s.jsxs(j,{variant:I,children:[s.jsx(f.MessageSummary,{variant:I,text:T,role:"heading","aria-level":2}),g.isValidValueForProp(k,"timestamp")&&"toast"!==b&&s.jsx(S,{variant:I,value:k})]}),s.jsx(x,{variant:I,item:i,renderer:e})]}),"on"===C&&s.jsx(v,{variant:I,onAction:N})]})})},e.MessageCloseButton=v,e.MessageDetail=x,e.MessageTimestamp=S}));
1
+ define(['exports', 'preact/jsx-runtime', 'preact/hooks', './Flex-b8764305', './UNSAFE_MessageBanner/themes/redwood/MessageBannerTheme', './useComponentTheme-5aa41a8f', './timer-571d3748', './classNames-08d99695', './Close-a88a3dcf', './IconButton-368fba34', './useTranslationBundle-68275657', './PRIVATE_Message/themes/MessageStyles.css', 'preact', './MessageFormattingUtils-2e19d8de', './MessagesManager-2c4c218f', './utils-32e81a13'], (function(e,s,a,t,n,r,o,l,i,c,u,m,d,g,f,y){"use strict";function v({onAction:e,variant:a="banner"}){const t=u.useTranslationBundle("@oracle/oraclejet-preact"),n=s.jsx(c.IconButton,{"aria-label":t.message_close(),size:"sm",variant:"borderless",onAction:e,children:s.jsx(i.SvgClose,{})}),r=l.classNames([m.messageCloseButtonStyles.base,m.messageCloseButtonStyles[a]]);return s.jsx("div",{class:r,"data-oj-message-close-button":"",children:n})}function p({item:e,renderer:a}){const t=l.classNames([m.messageStartIconStyles.base,m.messageStartIconStyles.toast,m.messageStartIconStyles.customToast]);return s.jsx("div",{class:t,role:"presentation","data-oj-message-custom-icon":"",children:a(e)})}function x(e){const{detail:a}=e.data;return g.isValidValueForProp(a)?s.jsx(d.Fragment,{children:a}):null}function b({item:e,renderer:a,variant:t="banner"}){const n=null!=a,r=(a??x)(e);if(null==r)return null;const o=l.classNames([m.messageDetailStyles.base,m.messageDetailStyles[t]]);return s.jsx("div",{class:o,...n?{"data-oj-message-custom-detail":""}:{},children:r})}function j({children:e,variant:a="banner"}){const t=l.classNames([m.messageHeaderStyles.base,m.messageHeaderStyles[a]]);return s.jsx("div",{role:"presentation",class:t,children:e})}function S({value:e,variant:a="banner"}){const t=l.classNames([m.messageTimestampStyles[a]]),n=g.formatTimestamp(e);return s.jsx("div",{class:t,children:n})}function h(e){return g.isValidValueForProp(e,"severity")&&"none"!==e}e.Message=function({detailRenderer:e,iconRenderer:i,item:c,onClose:u,messageRef:d=(()=>{}),variant:x="pageBanner"}){const{closeAffordance:C="on",severity:B="error",sound:M,summary:T,timestamp:k}=c.data,{autoTimeout:F="off"}=c.data,I=function(e){return"pageBanner"===e||"sectionBanner"===e?"banner":"toast"}(x),N=a.useCallback((()=>{u?.(c)}),[c,u]),V=a.useCallback((e=>{"Escape"===e.key&&"on"===C&&u?.(c)}),[C,c,u]),A="toast"===I&&"off"!==F,R=a.useRef(),P="on"===F?5e3:"number"==typeof F?F:5e3,E=a.useCallback((()=>{R.current||(R.current=new o.Timer(N,P))}),[N,P]),U=a.useCallback((()=>{R.current&&(R.current.clear(),R.current=void 0)}),[]),w=a.useCallback((()=>{R.current?.pause()}),[]),D=a.useCallback((()=>{R.current?.resume()}),[]);a.useEffect((()=>(g.isValidValueForProp(M)&&f.playSound(M),A&&E(),()=>{U()})),[]);const{variantClasses:_}=r.useComponentTheme(n.MessageBannerRedwoodTheme,{severity:B}),H=l.classNames(["banner"===I&&_,m.messageStyles.base[I],"toast"!==x&&f.severityBasedStyleClass(B,I),"sectionBanner"===x&&m.messageStyles.section]),$=l.classNames([m.messageStyles.content.base,m.messageStyles.content[I]]);return s.jsx("div",{ref:d,class:H,role:"alert","aria-atomic":"true","data-oj-key":`${typeof c.key}-${c.key}`,tabIndex:0,onKeyUp:V,onFocusIn:w,onFocusOut:D,children:s.jsxs("div",{class:$,children:[i?s.jsx(p,{item:c,renderer:i}):h(B)?s.jsx(f.MessageStartIcon,{severity:B,variant:I}):null,s.jsxs(t.Flex,{direction:"column",flex:"1",gap:y.xUnits(2),children:[s.jsxs(j,{variant:I,children:[s.jsx(f.MessageSummary,{variant:I,text:T,role:"heading","aria-level":2}),g.isValidValueForProp(k,"timestamp")&&"toast"!==x&&s.jsx(S,{variant:I,value:k})]}),s.jsx(b,{variant:I,item:c,renderer:e})]}),"on"===C&&s.jsx(v,{variant:I,onAction:N})]})})},e.MessageCloseButton=v,e.MessageDetail=b,e.MessageTimestamp=S}));
2
2
  //# sourceMappingURL=Message-d66cc7e9.js.map
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', './Flex-590160eb', './WindowOverlay-c390f525', './useUser-797287de', './Layer-139c23c4', 'preact/compat', './LayerHost-733ade2f'], (function(t,e,o,s,r,i,a,n){"use strict";t.MessageLayer=({children:t,offset:a,testId:n,position:c="bottom"})=>{const l=c.split("-")[0];let p;p="number"==typeof a?{mainAxis:a,crossAxis:a}:"top"==l||"bottom"==l?{mainAxis:a?.vertical,crossAxis:a?.horizontal}:{mainAxis:a?.horizontal,crossAxis:a?.vertical};const{direction:d}=r.useUser(),m="ltr"===d;let b;switch(c){case"top-left":b=m?"top-start":"top-end";break;case"top-right":b=m?"top-end":"top-start";break;case"bottom-left":b=m?"bottom-start":"bottom-end";break;case"bottom-right":b=m?"bottom-end":"bottom-start";break;default:b=c}return e.jsx(i.Layer,{priority:"messages",level:"topLevel",children:e.jsx(s.WindowOverlay,{placement:b,offset:p,children:e.jsx("div",{"data-testid":n,children:e.jsx(o.Flex,{direction:"column",gap:"2x",children:t})})})})},t.positions=["top","top-left","top-right","top-start","top-end","bottom","bottom-left","bottom-right","bottom-start","bottom-end"]}));
2
- //# sourceMappingURL=MessageLayer-a439ce52.js.map
1
+ define(['exports', 'preact/jsx-runtime', './Flex-b8764305', './WindowOverlay-19cd633a', './useUser-e8dd7f7c', './Layer-69221878', 'preact/compat', './LayerHost-27dfba9e'], (function(t,e,o,s,r,i,a,n){"use strict";t.MessageLayer=({children:t,offset:a,testId:n,position:c="bottom"})=>{const l=c.split("-")[0];let d;d="number"==typeof a?{mainAxis:a,crossAxis:a}:"top"==l||"bottom"==l?{mainAxis:a?.vertical,crossAxis:a?.horizontal}:{mainAxis:a?.horizontal,crossAxis:a?.vertical};const{direction:p}=r.useUser(),m="ltr"===p;let b;switch(c){case"top-left":b=m?"top-start":"top-end";break;case"top-right":b=m?"top-end":"top-start";break;case"bottom-left":b=m?"bottom-start":"bottom-end";break;case"bottom-right":b=m?"bottom-end":"bottom-start";break;default:b=c}return e.jsx(i.Layer,{priority:"messages",level:"topLevel",children:e.jsx(s.WindowOverlay,{placement:b,offset:d,children:e.jsx("div",{"data-testid":n,children:e.jsx(o.Flex,{direction:"column",gap:"2x",children:t})})})})},t.positions=["top","top-left","top-right","top-start","top-end","bottom","bottom-left","bottom-right","bottom-start","bottom-end"]}));
2
+ //# sourceMappingURL=MessageLayer-d39be82d.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MessageLayer-a439ce52.js","sources":["../../src/PRIVATE_MessageLayer/MessageLayer.tsx"],"sourcesContent":["import { ComponentChildren } from 'preact';\nimport { Flex } from '../UNSAFE_Flex';\nimport { WindowOverlay, WindowOverlayPlacement } from '../UNSAFE_WindowOverlay';\nimport { useUser } from '../hooks/UNSAFE_useUser';\nimport { Layer } from '../UNSAFE_Layer';\n\nconst positions = [\n 'top',\n 'top-left',\n 'top-right',\n 'top-start',\n 'top-end',\n 'bottom',\n 'bottom-left',\n 'bottom-right',\n 'bottom-start',\n 'bottom-end'\n] as const;\n\ntype Position = (typeof positions)[number];\n\ntype Offset =\n | number\n | {\n horizontal?: number;\n vertical?: number;\n };\n\ntype Props = {\n children: ComponentChildren;\n\n /**\n * Defines the fixed position where the notifications will to be placed on the screen.\n * - top-start resolves to top-left in LTR (top-right in RTL)\n * - top-end resolves to top-right in LTR (top-left in RTL)\n * - bottom-start resolves to bottom-left in LTR (bottom-right in RTL)\n * - bottom-end resolves to bottom-right in LTR (bottom-left in RTL)\n *\n * default bottom\n */\n position?: Position;\n\n /**\n * Defines an offset (in pixels) in the placement. Value can be supplied as a number or\n * an object with horizontal and vertical values.\n *\n * default 0\n */\n offset?: Offset;\n\n /**\n * The test id which is assigned to the \"data-testid\" for the component's element.\n * Used for test automation, it is assigned to the wrapper element rendered by the component.\n */\n testId?: string;\n};\n\nconst MessageLayer = ({ children, offset, testId, position = 'bottom' }: Props) => {\n const side = position.split('-')[0];\n let windowOverlayOffset;\n if (typeof offset === 'number') {\n windowOverlayOffset = { mainAxis: offset, crossAxis: offset };\n } else if (side == 'top' || side == 'bottom') {\n windowOverlayOffset = { mainAxis: offset?.vertical, crossAxis: offset?.horizontal };\n } else {\n windowOverlayOffset = { mainAxis: offset?.horizontal, crossAxis: offset?.vertical };\n }\n\n const { direction } = useUser();\n const isLtr = direction === 'ltr';\n let windowOverlayPlacement: WindowOverlayPlacement | undefined;\n switch (position) {\n case 'top-left':\n windowOverlayPlacement = isLtr ? 'top-start' : 'top-end';\n break;\n case 'top-right':\n windowOverlayPlacement = isLtr ? 'top-end' : 'top-start';\n break;\n case 'bottom-left':\n windowOverlayPlacement = isLtr ? 'bottom-start' : 'bottom-end';\n break;\n case 'bottom-right':\n windowOverlayPlacement = isLtr ? 'bottom-end' : 'bottom-start';\n break;\n default:\n windowOverlayPlacement = position;\n break;\n }\n return (\n <Layer priority=\"messages\" level=\"topLevel\">\n <WindowOverlay placement={windowOverlayPlacement} offset={windowOverlayOffset}>\n <div data-testid={testId}>\n <Flex direction=\"column\" gap=\"2x\">\n {children}\n </Flex>\n </div>\n </WindowOverlay>\n </Layer>\n );\n};\n\nexport type { Position, Offset };\nexport { MessageLayer, positions };\n"],"names":["children","offset","testId","position","side","split","windowOverlayOffset","mainAxis","crossAxis","vertical","horizontal","direction","useUser","isLtr","windowOverlayPlacement","_jsx","Layer","priority","level","WindowOverlay","placement","jsx","Flex","gap"],"mappings":"2NAyDqB,EAAGA,WAAUC,SAAQC,SAAQC,WAAW,aAC3D,MAAMC,EAAOD,EAASE,MAAM,KAAK,GACjC,IAAIC,EAEFA,EADoB,iBAAXL,EACa,CAAEM,SAAUN,EAAQO,UAAWP,GACpC,OAARG,GAAyB,UAARA,EACJ,CAAEG,SAAUN,GAAQQ,SAAUD,UAAWP,GAAQS,YAEjD,CAAEH,SAAUN,GAAQS,WAAYF,UAAWP,GAAQQ,UAG3E,MAAME,UAAEA,GAAcC,EAAAA,UAChBC,EAAsB,QAAdF,EACd,IAAIG,EACJ,OAAQX,GACN,IAAK,WACHW,EAAyBD,EAAQ,YAAc,UAC/C,MACF,IAAK,YACHC,EAAyBD,EAAQ,UAAY,YAC7C,MACF,IAAK,cACHC,EAAyBD,EAAQ,eAAiB,aAClD,MACF,IAAK,eACHC,EAAyBD,EAAQ,aAAe,eAChD,MACF,QACEC,EAAyBX,EAG7B,OACEY,EAAAA,IAACC,EAAAA,OAAMC,SAAS,WAAWC,MAAM,WAAUlB,SACzCe,EAAAA,IAACI,EAAAA,cAAa,CAACC,UAAWN,EAAwBb,OAAQK,EACxDN,SAAAe,EAAAM,IAAA,MAAA,CAAA,cAAkBnB,EAChBF,SAAAe,EAAAA,IAACO,EAAAA,KAAK,CAAAX,UAAU,SAASY,IAAI,cAC1BvB,SAKT,cA5Fc,CAChB,MACA,WACA,YACA,YACA,UACA,SACA,cACA,eACA,eACA"}
1
+ {"version":3,"file":"MessageLayer-d39be82d.js","sources":["../../src/PRIVATE_MessageLayer/MessageLayer.tsx"],"sourcesContent":["import { ComponentChildren } from 'preact';\nimport { Flex } from '../UNSAFE_Flex';\nimport { WindowOverlay, WindowOverlayPlacement } from '../UNSAFE_WindowOverlay';\nimport { useUser } from '../hooks/UNSAFE_useUser';\nimport { Layer } from '../UNSAFE_Layer';\n\nconst positions = [\n 'top',\n 'top-left',\n 'top-right',\n 'top-start',\n 'top-end',\n 'bottom',\n 'bottom-left',\n 'bottom-right',\n 'bottom-start',\n 'bottom-end'\n] as const;\n\ntype Position = (typeof positions)[number];\n\ntype Offset =\n | number\n | {\n horizontal?: number;\n vertical?: number;\n };\n\ntype Props = {\n children: ComponentChildren;\n\n /**\n * Defines the fixed position where the notifications will to be placed on the screen.\n * - top-start resolves to top-left in LTR (top-right in RTL)\n * - top-end resolves to top-right in LTR (top-left in RTL)\n * - bottom-start resolves to bottom-left in LTR (bottom-right in RTL)\n * - bottom-end resolves to bottom-right in LTR (bottom-left in RTL)\n *\n * default bottom\n */\n position?: Position;\n\n /**\n * Defines an offset (in pixels) in the placement. Value can be supplied as a number or\n * an object with horizontal and vertical values.\n *\n * default 0\n */\n offset?: Offset;\n\n /**\n * The test id which is assigned to the \"data-testid\" for the component's element.\n * Used for test automation, it is assigned to the wrapper element rendered by the component.\n */\n testId?: string;\n};\n\nconst MessageLayer = ({ children, offset, testId, position = 'bottom' }: Props) => {\n const side = position.split('-')[0];\n let windowOverlayOffset;\n if (typeof offset === 'number') {\n windowOverlayOffset = { mainAxis: offset, crossAxis: offset };\n } else if (side == 'top' || side == 'bottom') {\n windowOverlayOffset = { mainAxis: offset?.vertical, crossAxis: offset?.horizontal };\n } else {\n windowOverlayOffset = { mainAxis: offset?.horizontal, crossAxis: offset?.vertical };\n }\n\n const { direction } = useUser();\n const isLtr = direction === 'ltr';\n let windowOverlayPlacement: WindowOverlayPlacement | undefined;\n switch (position) {\n case 'top-left':\n windowOverlayPlacement = isLtr ? 'top-start' : 'top-end';\n break;\n case 'top-right':\n windowOverlayPlacement = isLtr ? 'top-end' : 'top-start';\n break;\n case 'bottom-left':\n windowOverlayPlacement = isLtr ? 'bottom-start' : 'bottom-end';\n break;\n case 'bottom-right':\n windowOverlayPlacement = isLtr ? 'bottom-end' : 'bottom-start';\n break;\n default:\n windowOverlayPlacement = position;\n break;\n }\n return (\n <Layer priority=\"messages\" level=\"topLevel\">\n <WindowOverlay placement={windowOverlayPlacement} offset={windowOverlayOffset}>\n <div data-testid={testId}>\n <Flex direction=\"column\" gap=\"2x\">\n {children}\n </Flex>\n </div>\n </WindowOverlay>\n </Layer>\n );\n};\n\nexport type { Position, Offset };\nexport { MessageLayer, positions };\n"],"names":["children","offset","testId","position","side","split","windowOverlayOffset","mainAxis","crossAxis","vertical","horizontal","direction","useUser","isLtr","windowOverlayPlacement","_jsx","Layer","priority","level","WindowOverlay","placement","jsx","Flex","gap"],"mappings":"2NAyDqB,EAAGA,WAAUC,SAAQC,SAAQC,WAAW,aAC3D,MAAMC,EAAOD,EAASE,MAAM,KAAK,GACjC,IAAIC,EAEFA,EADoB,iBAAXL,EACa,CAAEM,SAAUN,EAAQO,UAAWP,GACpC,OAARG,GAAyB,UAARA,EACJ,CAAEG,SAAUN,GAAQQ,SAAUD,UAAWP,GAAQS,YAEjD,CAAEH,SAAUN,GAAQS,WAAYF,UAAWP,GAAQQ,UAG3E,MAAME,UAAEA,GAAcC,EAAAA,UAChBC,EAAsB,QAAdF,EACd,IAAIG,EACJ,OAAQX,GACN,IAAK,WACHW,EAAyBD,EAAQ,YAAc,UAC/C,MACF,IAAK,YACHC,EAAyBD,EAAQ,UAAY,YAC7C,MACF,IAAK,cACHC,EAAyBD,EAAQ,eAAiB,aAClD,MACF,IAAK,eACHC,EAAyBD,EAAQ,aAAe,eAChD,MACF,QACEC,EAAyBX,EAG7B,OACEY,EAAAA,IAACC,EAAAA,OAAMC,SAAS,WAAWC,MAAM,WAAUlB,SACzCe,EAAAA,IAACI,EAAAA,cAAa,CAACC,UAAWN,EAAwBb,OAAQK,EACxDN,SAAAe,EAAAM,IAAA,MAAA,CAAA,cAAkBnB,EAChBF,SAAAe,EAAAA,IAACO,EAAAA,KAAK,CAAAX,UAAU,SAASY,IAAI,cAC1BvB,SAKT,cA5Fc,CAChB,MACA,WACA,YACA,YACA,UACA,SACA,cACA,eACA,eACA"}
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', 'preact/hooks', './LayerHost-733ade2f', './EnvironmentProvider-806b8f3a', './useMessagesFocusManager-8777bce0', './useBreakpointValues-3a067093', './MessagesContext-602a69a2', './useMessagesContext-1395a997', './useTranslationBundle-7c40cb58', './Message-d66cc7e9', 'preact', './utils-32e81a13', './useComponentTheme-5aa41a8f', './useTestId-c286f212', 'css!./TooltipContentStyles.styles.css', 'module', './hooks/UNSAFE_useTooltip/themes/redwood/TooltipContentVariants.css', './tooltipUtils-30886397', 'css!./IconStyle.styles.css', './IconButton-368fba34', 'css!./MessageStyles.styles.css', './MessageFormattingUtils-2e19d8de', './MessagesManager-2c4c218f', './Flex-590160eb', './FocusTrap-d351e5c9', './LiveRegion-1917f798', './UNSAFE_MessageToast/themes/redwood/MessageToastTheme', './MessageLayer-a439ce52'], (function(e,s,t,n,o,a,r,i,l,c,u,d,g,m,f,h,p,y,M,v,x,T,R,F,b,k,C,S,j){"use strict";const E={entering:e=>({from:{transform:`translate(0, ${e.offsetHeight}px)`,opacity:1},to:{transform:"translate(0, 0)",opacity:1},end:{transform:"unset",opacity:1},options:{duration:250}}),exiting:{from:{opacity:1},to:{opacity:0},end:{opacity:0},options:{duration:250}}},U={opacity:0};e.MessageToast=function({data:e,detailRendererKey:n,iconRendererKey:i,renderers:d,onClose:h,offset:p,position:y,testId:M}){const v=f.useTestId(M),x=t.useRef(new Map),T=t.useRef(null),R=t.useRef(null),I=t.useRef(null),[L,w]=t.useState(),[B,_]=t.useState(e.length>0),[z,A]=t.useState(!1),N=c.useTranslationBundle("@oracle/oraclejet-preact"),{UNSAFE_messagesLayerId:V}=l.useMessagesContext(),$=t.useRef(e.length),H=t.useRef(0);$.current=e.length,t.useImperativeHandle(I,(()=>({focus:()=>!!e.length&&(T.current=x.current.get(e[0].key)??null,A(!0),!0),contains:s=>!(!e.length||!s)&&(R.current?.contains(s)??!1)})),[e]);const{controller:K,handlers:P}=a.useMessageFocusManager(I,{onFocus:t.useCallback((()=>{w(N.message_navigationFromMessagesRegion())}),[N]),onFocusLeave:t.useCallback((()=>{A(!1)}),[])},{handleEscapeKey:!1}),W=t.useCallback(((s,t,n)=>{const o=n?.contains(document.activeElement);if(0===$.current)return _(!1),A(!1),void(o&&setTimeout((()=>K.restorePriorFocus()),0));const a=t+1<e.length?t+1:t-1;if(a>-1&&o){const s=e[a].key;x.current.get(s)?.focus()}}),[K,e]),D=t.useCallback((e=>s=>x.current.set(e,s)),[]);t.useEffect((()=>{const s=H.current;if(H.current=e.length,e.length)return _(!0),e.length>s&&w(N.message_navigationToMessagesRegion()),void K.prioritize();w(s?N.messageToast_allMessagesClosed():"")}),[K,e.length,N]);const q=r.useBreakpointValues({sm:`calc(100vw - ${g.xUnits(8)})`,md:`calc(100vw - ${g.xUnits(12)})`,lg:`calc(150 * ${g.xUnits(1)})`}),G=r.useBreakpointValues({sm:{horizontal:"number"==typeof p?p:p?.horizontal??0,vertical:16+("number"==typeof p?p:p?.vertical??0)},lg:{horizontal:"number"==typeof p?p:p?.horizontal??0,vertical:24+("number"==typeof p?p:p?.vertical??0)}}),{classes:J}=m.useComponentTheme(S.MessageToastRedwoodTheme);return B||0!==e.length?s.jsxs(o.EnvironmentProvider,{environment:{colorScheme:"dark"},children:[s.jsx(j.MessageLayer,{offset:G,position:y,children:s.jsx("div",{class:J,ref:R,tabIndex:-1,id:V,...P,...v,children:s.jsx(k.FocusTrap,{autoFocusRef:T,isDisabled:!z,children:s.jsx(b.Flex,{direction:"column",gap:"1x",align:"center",maxWidth:q,children:s.jsx(F.MessagesManager,{animationStates:E,initialAnimationStyles:U,data:e,onMessageWillRemove:W,children:({item:e})=>s.jsx(u.Message,{messageRef:D(e.key),item:e,detailRenderer:F.getRenderer(e,n,d),iconRenderer:F.getRenderer(e,i,d),onClose:h,variant:"toast"},e.key)})})})})}),s.jsx(C.LiveRegion,{children:L})]}):s.jsx(C.LiveRegion,{children:L})}}));
1
+ define(['exports', 'preact/jsx-runtime', 'preact/hooks', './LayerHost-27dfba9e', './EnvironmentProvider-bbf80843', './useMessagesFocusManager-8777bce0', './useBreakpointValues-3a067093', './MessagesContext-602a69a2', './useMessagesContext-1395a997', './useTranslationBundle-68275657', './Message-d66cc7e9', 'preact', './utils-32e81a13', './useComponentTheme-5aa41a8f', './useTestId-0140aa44', 'css!./TooltipContentStyles.styles.css', 'module', './hooks/UNSAFE_useTooltip/themes/redwood/TooltipContentVariants.css', './tooltipUtils-36ddb881', 'css!./IconStyle.styles.css', './IconButton-368fba34', 'css!./MessageStyles.styles.css', './MessageFormattingUtils-2e19d8de', './MessagesManager-2c4c218f', './Flex-b8764305', './FocusTrap-d351e5c9', './LiveRegion-17fea064', './UNSAFE_MessageToast/themes/redwood/MessageToastTheme', './MessageLayer-d39be82d'], (function(e,s,t,n,o,a,r,i,l,c,u,d,g,m,f,h,p,y,M,v,x,T,R,b,F,k,C,S,j){"use strict";const E={entering:e=>({from:{transform:`translate(0, ${e.offsetHeight}px)`,opacity:1},to:{transform:"translate(0, 0)",opacity:1},end:{transform:"unset",opacity:1},options:{duration:250}}),exiting:{from:{opacity:1},to:{opacity:0},end:{opacity:0},options:{duration:250}}},U={opacity:0};e.MessageToast=function({data:e,detailRendererKey:n,iconRendererKey:i,renderers:d,onClose:h,offset:p,position:y,testId:M}){const v=f.useTestId(M),x=t.useRef(new Map),T=t.useRef(null),R=t.useRef(null),I=t.useRef(null),[L,w]=t.useState(),[B,_]=t.useState(e.length>0),[z,A]=t.useState(!1),N=c.useTranslationBundle("@oracle/oraclejet-preact"),{UNSAFE_messagesLayerId:V}=l.useMessagesContext(),$=t.useRef(e.length),H=t.useRef(0);$.current=e.length,t.useImperativeHandle(I,(()=>({focus:()=>!!e.length&&(T.current=x.current.get(e[0].key)??null,A(!0),!0),contains:s=>!(!e.length||!s)&&(R.current?.contains(s)??!1)})),[e]);const{controller:K,handlers:P}=a.useMessageFocusManager(I,{onFocus:t.useCallback((()=>{w(N.message_navigationFromMessagesRegion())}),[N]),onFocusLeave:t.useCallback((()=>{A(!1)}),[])},{handleEscapeKey:!1}),W=t.useCallback(((s,t,n)=>{const o=n?.contains(document.activeElement);if(0===$.current)return _(!1),A(!1),void(o&&setTimeout((()=>K.restorePriorFocus()),0));const a=t+1<e.length?t+1:t-1;if(a>-1&&o){const s=e[a].key;x.current.get(s)?.focus()}}),[K,e]),D=t.useCallback((e=>s=>x.current.set(e,s)),[]);t.useEffect((()=>{const s=H.current;if(H.current=e.length,e.length)return _(!0),e.length>s&&w(N.message_navigationToMessagesRegion()),void K.prioritize();w(s?N.messageToast_allMessagesClosed():"")}),[K,e.length,N]);const q=r.useBreakpointValues({sm:`calc(100vw - ${g.xUnits(8)})`,md:`calc(100vw - ${g.xUnits(12)})`,lg:`calc(150 * ${g.xUnits(1)})`}),G=r.useBreakpointValues({sm:{horizontal:"number"==typeof p?p:p?.horizontal??0,vertical:16+("number"==typeof p?p:p?.vertical??0)},lg:{horizontal:"number"==typeof p?p:p?.horizontal??0,vertical:24+("number"==typeof p?p:p?.vertical??0)}}),{classes:J}=m.useComponentTheme(S.MessageToastRedwoodTheme);return B||0!==e.length?s.jsxs(o.EnvironmentProvider,{environment:{colorScheme:"dark"},children:[s.jsx(j.MessageLayer,{offset:G,position:y,children:s.jsx("div",{class:J,ref:R,tabIndex:-1,id:V,...P,...v,children:s.jsx(k.FocusTrap,{autoFocusRef:T,isDisabled:!z,children:s.jsx(F.Flex,{direction:"column",gap:"1x",align:"center",maxWidth:q,children:s.jsx(b.MessagesManager,{animationStates:E,initialAnimationStyles:U,data:e,onMessageWillRemove:W,children:({item:e})=>s.jsx(u.Message,{messageRef:D(e.key),item:e,detailRenderer:b.getRenderer(e,n,d),iconRenderer:b.getRenderer(e,i,d),onClose:h,variant:"toast"},e.key)})})})})}),s.jsx(C.LiveRegion,{children:L})]}):s.jsx(C.LiveRegion,{children:L})}}));
2
2
  //# sourceMappingURL=MessageToast-19703f73.js.map
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', './classNames-08d99695', './SuccessS-64274879', './ErrorS-f5d0be49', './InformationS-3dc89e6f', './WarningS-5c328a13', './Flex-590160eb', './PRIVATE_Message/themes/MessageStyles.css', './useTranslationBundle-7c40cb58', './useTestId-c286f212', './logger-0f873e29', './soundUtils-f6535f03', './MessageFormattingUtils-2e19d8de', 'preact', 'preact/hooks', './TransitionGroup-3b9d81b6', './useAnimation-5a74955f', './MessagesContext-602a69a2', './useMessagesContext-1395a997', './Transition-04efcc49'], (function(e,n,t,a,s,i,r,o,c,l,u,d,g,m,f,y,S,v,x,h,p){"use strict";const b={confirmation:a.SvgSuccessS,error:s.SvgErrorS,info:i.SvgInformationS,warning:r.SvgWarningS};const I=(e,n="common")=>d.warn(`JET Message(${n}): ${e}`);function j(e,n="common"){throw new Error(`JET Message(${n}) - ${e}`)}const E={};function M({animationStates:e=E,initialAnimationStyles:t,onEntering:a,onExiting:s,...i}){const[r,o]=y.useState("entering"),c=y.useRef(),l=y.useRef(),{controller:u,nodeRef:d}=v.useAnimation(r,{animationStates:e,isAnimatedOnMount:!0,onAnimationEnd:y.useCallback((()=>{c.current?.(),c.current=void 0,l.current?.(),l.current=void 0}),[])}),{addBusyState:g}=h.useMessagesContext(),m=y.useCallback(((n,t,s)=>{c.current&&(c.current=void 0,u.cancel()),l.current?.(),l.current=void 0,a?.(n,void 0,s),o("entering"),void 0!==e.entering||void 0!==e["exiting => entering"]?(c.current=t,l.current=g?.("messages animating")):t?.()}),[e,u,g,a]),f=y.useCallback(((n,t,a)=>{c.current&&(c.current=void 0,u.cancel()),l.current?.(),l.current=void 0,s?.(n,void 0,a),o("exiting"),void 0!==e.exiting||void 0!==e["entering => exiting"]?(c.current=t,l.current=g?.("messages animating")):t?.()}),[e,u,g,s]);return y.useLayoutEffect((()=>()=>l.current?.()),[]),n.jsx("div",{ref:d,style:t,children:n.jsx(p.Transition,{...i,onEntering:m,onExiting:f})})}e.MessageStartIcon=function({severity:e,testId:a,variant:s="banner"}){const i=b[e],r=l.useTranslationBundle("@oracle/oraclejet-preact"),d={confirmation:r.message_confirmation(),error:r.message_error(),info:r.message_info(),warning:r.message_warning()},g=u.useTestId(a),m="inline"!==s?n.jsx(o.Flex,{align:"center",height:"100%",children:n.jsx("span",{class:c.startIconContainerStyles[s],role:"img","aria-label":d[e],children:n.jsx(i,{})})}):n.jsx("span",{class:c.startIconContainerStyles.inline,role:"img","aria-label":d[e],children:n.jsx(i,{})});return n.jsx("div",{class:t.classNames([c.messageStartIconStyles.base,c.messageStartIconStyles[s],c.severityIconStyles[s]]),role:"presentation",...g,children:m})},e.MessageSummary=function({"aria-level":e,role:a,text:s,testId:i,variant:r="banner"}){const o=u.useTestId(i),l=t.classNames([c.messageSummaryStyles.base,c.messageSummaryStyles[r]]);return n.jsx("div",{"aria-level":e,role:a,class:l,...o,children:s})},e.MessagesManager=function({data:e,animationStates:t,children:a,initialAnimationStyles:s,onMessageWillRemove:i}){const r=y.useCallback((async(e,n)=>{n&&i?.(n.key,n.index,e)}),[i]);return n.jsx(S.TransitionGroup,{elementType:f.Fragment,children:e.map(((e,i)=>n.jsx(M,{animationStates:t,initialAnimationStyles:s,metadata:{index:i,key:e.key},onExited:r,children:a?.({index:i,item:e})},e.key)))})},e.getRenderer=function(e,n,t,a){if(!n||!t)return;const s="function"==typeof n?n(e):n;return null!=s?(s in t||j(`${s} is not a valid template name for the message with key=${e.key}`,a),t[s]):void 0},e.isSeverityIconNeeded=function(e){return m.isValidValueForProp(e,"severity")&&"none"!==e},e.playSound=async function(e){if("none"!==e)if("default"!==e)try{await g.playAudioFromURL(e)}catch(n){I(`Failed to play the audio from the url ${e}. ${n}.`)}else try{g.playDefaultNotificationSound()}catch(e){I(`Failed to play the default sound. ${e}.`)}},e.severityBasedStyleClass=function(e,n){return m.isValidValueForProp(e,"severity")&&"none"!==e?`oj-c-message${n}-${e}`:""},e.throwError=j}));
1
+ define(['exports', 'preact/jsx-runtime', './classNames-08d99695', './SuccessS-64274879', './ErrorS-f5d0be49', './InformationS-3dc89e6f', './WarningS-5c328a13', './Flex-b8764305', './PRIVATE_Message/themes/MessageStyles.css', './useTranslationBundle-68275657', './useTestId-0140aa44', './logger-0f873e29', './soundUtils-f6535f03', './MessageFormattingUtils-2e19d8de', 'preact', 'preact/hooks', './TransitionGroup-3b9d81b6', './useAnimation-5a74955f', './MessagesContext-602a69a2', './useMessagesContext-1395a997', './Transition-04efcc49'], (function(e,n,t,a,s,i,r,o,c,l,u,d,g,m,f,y,S,v,x,h,p){"use strict";const I={confirmation:a.SvgSuccessS,error:s.SvgErrorS,info:i.SvgInformationS,warning:r.SvgWarningS};const b=(e,n="common")=>d.warn(`JET Message(${n}): ${e}`);function j(e,n="common"){throw new Error(`JET Message(${n}) - ${e}`)}const E={};function M({animationStates:e=E,initialAnimationStyles:t,onEntering:a,onExiting:s,...i}){const[r,o]=y.useState("entering"),c=y.useRef(),l=y.useRef(),{controller:u,nodeRef:d}=v.useAnimation(r,{animationStates:e,isAnimatedOnMount:!0,onAnimationEnd:y.useCallback((()=>{c.current?.(),c.current=void 0,l.current?.(),l.current=void 0}),[])}),{addBusyState:g}=h.useMessagesContext(),m=y.useCallback(((n,t,s)=>{c.current&&(c.current=void 0,u.cancel()),l.current?.(),l.current=void 0,a?.(n,void 0,s),o("entering"),void 0!==e.entering||void 0!==e["exiting => entering"]?(c.current=t,l.current=g?.("messages animating")):t?.()}),[e,u,g,a]),f=y.useCallback(((n,t,a)=>{c.current&&(c.current=void 0,u.cancel()),l.current?.(),l.current=void 0,s?.(n,void 0,a),o("exiting"),void 0!==e.exiting||void 0!==e["entering => exiting"]?(c.current=t,l.current=g?.("messages animating")):t?.()}),[e,u,g,s]);return y.useLayoutEffect((()=>()=>l.current?.()),[]),n.jsx("div",{ref:d,style:t,children:n.jsx(p.Transition,{...i,onEntering:m,onExiting:f})})}e.MessageStartIcon=function({severity:e,testId:a,variant:s="banner"}){const i=I[e],r=l.useTranslationBundle("@oracle/oraclejet-preact"),d={confirmation:r.message_confirmation(),error:r.message_error(),info:r.message_info(),warning:r.message_warning()},g=u.useTestId(a),m="inline"!==s?n.jsx(o.Flex,{align:"center",height:"100%",children:n.jsx("span",{class:c.startIconContainerStyles[s],role:"img","aria-label":d[e],children:n.jsx(i,{})})}):n.jsx("span",{class:c.startIconContainerStyles.inline,role:"img","aria-label":d[e],children:n.jsx(i,{})});return n.jsx("div",{class:t.classNames([c.messageStartIconStyles.base,c.messageStartIconStyles[s],c.severityIconStyles[s]]),role:"presentation",...g,children:m})},e.MessageSummary=function({"aria-level":e,role:a,text:s,testId:i,variant:r="banner"}){const o=u.useTestId(i),l=t.classNames([c.messageSummaryStyles.base,c.messageSummaryStyles[r]]);return n.jsx("div",{"aria-level":e,role:a,class:l,...o,children:s})},e.MessagesManager=function({data:e,animationStates:t,children:a,initialAnimationStyles:s,onMessageWillRemove:i}){const r=y.useCallback((async(e,n)=>{n&&i?.(n.key,n.index,e)}),[i]);return n.jsx(S.TransitionGroup,{elementType:f.Fragment,children:e.map(((e,i)=>n.jsx(M,{animationStates:t,initialAnimationStyles:s,metadata:{index:i,key:e.key},onExited:r,children:a?.({index:i,item:e})},e.key)))})},e.getRenderer=function(e,n,t,a){if(!n||!t)return;const s="function"==typeof n?n(e):n;return null!=s?(s in t||j(`${s} is not a valid template name for the message with key=${e.key}`,a),t[s]):void 0},e.isSeverityIconNeeded=function(e){return m.isValidValueForProp(e,"severity")&&"none"!==e},e.playSound=async function(e){if("none"!==e)if("default"!==e)try{await g.playAudioFromURL(e)}catch(n){b(`Failed to play the audio from the url ${e}. ${n}.`)}else try{g.playDefaultNotificationSound()}catch(e){b(`Failed to play the default sound. ${e}.`)}},e.severityBasedStyleClass=function(e,n){return m.isValidValueForProp(e,"severity")&&"none"!==e?`oj-c-message${n}-${e}`:""},e.throwError=j}));
2
2
  //# sourceMappingURL=MessagesManager-2c4c218f.js.map
@@ -1,2 +1,2 @@
1
- define(['exports', 'preact/jsx-runtime', './TrackResizeContainer-c6b5de04', './classNames-08d99695', './mergeProps-bcfa6a92', 'preact/hooks', './useUser-797287de', './useMeterDatatip-f8bca628', './useKeyboardEvents-ce9c81d0', './meterUtils-775a2dde', './utils-32e81a13', './UNSAFE_MeterBar/themes/MeterBarContract.css', './size-f0e638ec', './UNSAFE_MeterBar/themes/MeterBarStyles.css', './utils-948bcf60', './TabbableModeContext-a9c97640', './useTabbableMode-dc440317', './useComponentTheme-5aa41a8f', './UNSAFE_MeterBar/themes/redwood/MeterBarTheme', './useTestId-c286f212', './useTextDimensions-030c6dbd', './useCssVars-cc825c54', './Common/themes/themeContract.css', './LinearMeter-d1e744c1'], (function(e,t,r,a,i,n,s,o,l,c,h,d,u,m,x,f,p,g,$,b,S,y,z,v){"use strict";const T=15,C=5,k=4;function M(e){if(!e)return{width:0,height:0};const t=e.getBoundingClientRect();return{width:t.width,height:t.height}}const B=function(e,t,r,a,i,n){const s=[];return e.start&&s.push(t?r:a),e.end&&s.push(t?i:n),s},L=function(e,t,r,a){return r&&(e.start&&!a&&(r-=16),e.end&&!a&&(r-=16)),t&&r&&(r-=2*t+2*k),r},V=function(e,t,r,a){return r&&(e.start&&a&&(r-=16),e.end&&a&&(r-=16)),t&&r&&(r-=2*t+2*k),r},w=function(e,t,r){const a=`${h.xUnits(4)} + ${k}px`;return r?`calc(${a} + ${t}px) 0 calc(${a} + ${t}px) 0`:`0 calc(${a} + ${e}px) 0 calc(${a} + ${e}px)`};function R(e,t,r,a,i,n,s){const o=n||h.xUnits(C),l=`calc(${o} - ${s||d.meterBarVars.size})`;return r?i?`${e?"-50%":"50%"} calc(-100% - ${l} - ${k}px)`:`${e?"-50%":"50%"} calc(${o} + ${k}px)`:a?i?`calc(100% + ${l} + ${k}px) ${t?"50%":"-50%"}`:`calc(0px - ${o} - ${k}px) ${t?"50%":"-50%"}`:i?`calc(-100% - ${l} - ${k}px) ${t?"50%":"-50%"}`:`calc(${o} + ${k}px) ${t?"50%":"-50%"}`}function j(e,t,r,a,i){const n=`calc(${h.xUnits(C)} - ${d.meterBarVars.size})`,s=k,o=e.start&&e.end;if(a)return t?`calc(${i.height+s}px + ${n}) 0 calc(${i.height+s}px + ${n}) 0`:`0 calc(${i.width+s}px + ${n}) 0 calc(${i.width+s}px + ${n})`;if(r){if(o)return t?`${n} 0 ${n}`:`0 ${n} 0 ${n}`;if(e.start&&!e.end)return t?`${n} 0 0 0`:`0 ${n} 0 0`;if(!e.start&&e.end)return t?`0 0 ${n} 0`:`0 0 0 ${n}`}}function F(e,t,r,a,i,n){return{width:e?n:t?u.sizeToCSS(r):void 0,height:e?i:t?void 0:u.sizeToCSS(r),margin:e?w(a.width,a.height,t):void 0}}function H(e,t,r,a){return{left:e?`max(${r}px, ${t?100-a:a}%)`:void 0,right:e?void 0:`max(${r}px, ${t?a:100-a}%)`}}function U(e,t,r){if(0!==r||t)return 100===r?t?e?"3px":"0 3px":e?"-2px":"0 2px":e?t?"1px 0":"-1px 0":t?"0 -1px":"0 1px"}function D(e,t,r,a,i,n,s){return{...e?H(t,a,n/2,i):{},bottom:e?void 0:r?`max(${s/2-k}px, ${i}%)`:void 0,top:e||r?void 0:`max(${s/2-k}px, ${100-i}%)`,maxWidth:e?void 0:h.xUnits(T)}}function I({orientation:e,percent:r,color:i,position:n,length:o,label:l,maxLabelWidth:c,maxLabelHeight:h,trackSize:d,labelStyle:u}){const f="horizontal"===e,{direction:p}=s.useUser(),g="rtl"===p,$="start"===n,b=`${r}%`,S=f?void 0:o,y=f?o:void 0,z=r<50&&!g||r>50&&g,v=r<50;return t.jsxs(t.Fragment,{children:[t.jsx("div",{class:a.classNames([m.styles.referenceLinesBaseStyle,f?m.styles.referenceLinesHorizontalStyle:m.styles.referenceLinesVerticalStyle,$?f?m.styles.referenceLinesHoriontalStartStyle:g?m.styles.referenceLinesVerticalStartRtlStyle:m.styles.referenceLinesVerticalStartLtrStyle:""]),style:{left:f&&!g?b:void 0,right:f&&g?b:void 0,bottom:f?void 0:b,backgroundColor:x.getVisThresholdColor(i),width:S,height:y,translate:U(f,g,r)}}),l&&t.jsx("div",{className:m.styles.labelDivStyle,style:{...D(f,z,v,g,r,c,h),translate:R(z,v,f,g,$,o,d),...u},children:l})]})}function N({color:e,length:r,orientation:i,...n}){const{direction:o}=s.useUser(),l="horizontal"===i,c="rtl"===o;return t.jsx("div",{class:a.classNames([m.styles.thresholdBarBaseStyle,l?c?m.styles.thresholdBarHorizontalBarTrackSectionRtlStyle:m.styles.thresholdBarHorizontalBarTrackSectionLtrStyle:m.styles.thresholdBarVerticalBarTrackSectionStyle,n.class]),style:{width:l?r:"100%",height:l?"100%":r,backgroundColor:x.getVisThresholdColor(e)}})}function E({max:e=100,min:r=0,value:u=0,step:m=1,length:x="100%",width:f,height:T,size:C,orientation:k="horizontal",isTrackRendered:w=!0,thresholdDisplay:R="all",indicatorSize:H=1,testId:U,baseline:D,isReadonly:E,...P}){const A=b.useTestId(U);c.validateRange(r,e,u,m,E,D);const W=n.useRef(),_="horizontal"===k,K=n.useRef(null),X=n.useRef(M(null)),{direction:Y,forcedColors:q}=s.useUser(),G="rtl"===Y;n.useEffect((()=>{(P.onCommit||P.onInput)&&(X.current=M(K.current))}),[C,x,k,P.onCommit,P.onInput]);const{textMeasureContent:J,getTextDimensions:O}=S.useTextDimensions(),Q=n.useRef(!1),Z=o.usePointerEvents(u,(t=>{if(t.target==K.current)return function(e,t,r,a,i,n,s){const o=t.current;if(!o||0===o.width)return;let l;if("horizontal"===n){const t=e.offsetX;l=r+(a-r)*(s?o.width-t:t)/o.width}else l=r+(a-r)*(o.height-e.offsetY)/o.height;return l=Math.round(l/i)*i,Math.max(r,Math.min(a,l))}(t,X,r,e,m,k,G)}),K,W,Q,P.onCommit,P.onInput),ee=l.useKeyboardEvents(u,r,e,m,W,P.onCommit,P.onInput),{datatipContent:te,datatipProps:re}=o.useMeterDatatip(u,Q,P.datatip,P["aria-describedby"]),ae=c.getMeterAriaProps(u,r,e,P["aria-label"],P["aria-labelledby"],P.thresholds),ie=i.mergeProps(Z,ee,re,ae),ne=100*((void 0!==D?Math.max(r,Math.min(D,e)):r)-r)/(e-r),se=100*(u-r)/(e-r),oe=Math.min(ne,se),le=`${Math.abs(ne-se)}%`,ce=100*Math.max(0,Math.min(1,H))+"%",{trackColor:he,indicatorColor:de}=c.getTrackAndIndicatorColor(u,R,P.trackColor,P.indicatorColor,P.thresholds),ue=function(e){let t={start:!1,end:!1};return e&&(t=e.reduce(((e,t)=>(e.start=e.start||"start"===t.position,e.end=e.end||"end"===t.position||null==t.position,e)),t)),t}(P.referenceLines),me=P.onCommit||P.onInput,{isTabbable:xe}=p.useTabbableMode(),{classes:fe,styles:{interactiveStyle:pe,barValueBaseStyle:ge,barValueVerticalStyle:$e,barValueHorizontalStyle:be,barValueHighContrastStyle:Se,barTrackBaseStyle:ye,barTrackHorizontalSizeStyle:ze,barTrackVerticalSizeStyle:ve,barTrackBorderStyle:Te,barTrackMarginTopFitStyle:Ce,barTrackMarginStartFitStyle:ke,barTrackMarginBottomFitStyle:Me,barTrackMarginEndFitStyle:Be,trackSectionHorizontalFirstStyle:Le,trackSectionHorizontalLastStyle:Ve,trackSectionVerticalFirstStyle:we,trackSectionVerticalLastStyle:Re,trackSectionRoundedCornersStyle:je}}=g.useComponentTheme($.MeterBarRedwoodTheme,{size:C,orientation:k}),Fe="fit"===C,He=c.hasLabelledReferenceLine(P.referenceLines),Ue=c.getDefaultReferenceLineLabelFontSize("sm"),De=n.useMemo((()=>[{tokenVar:Ue,key:"labelFontSize",cssProp:"font-size"},{tokenVar:z.typographyVars.body.md.lineHeight,key:"lineHeight",cssProp:"line-height"}]),[Ue]),{resolvedVars:Ie,cssContent:Ne}=y.useCssVars(De),{dims:Ee,maxRefLabelDims:Pe}=c.getMaxRefLabelDims(Ie.fontSize,Ie.lineHeight,P.referenceLines,O),Ae=L(ue,Pe.width,f,_),We=V(ue,Pe.height,T,_),_e=_?We:Ae;return t.jsxs(t.Fragment,{children:[t.jsx("div",{tabIndex:xe?0:-1,...A,...ie,style:F(Fe,_,x,Pe,We,Ae),class:a.classNames([fe,...Fe?B(ue,_,Ce,ke,Me,Be):[]]),children:t.jsxs(v.BarTrack,{ref:K,orientation:k,color:!w||"all"===R&&P.thresholds?"transparent":he,class:a.classNames([ye,me?pe:"",_?ze:ve,!w||"all"===R&&P.thresholds?void 0:Te]),style:{margin:Fe?void 0:j(ue,_,!!P.referenceLines?.length,He,Pe)},children:["all"===R&&P.thresholds?.filter((t=>t.max>r&&t.max<=e)).sort(((e,t)=>e.max-t.max)).map(((a,i,n)=>{const s=0===i?a.max-r:a.max-n[i-1].max,o=_?Ve:Re;let l=0===i?_?Le:we:"";return a.max===e&&(l=0===i?je:o),t.jsxs(t.Fragment,{children:[t.jsx(N,{class:l,orientation:k,length:100*s/(e-r)+"%",color:a.color}),w&&i===n.length-1&&a.max<e?t.jsx(N,{class:o,color:he,orientation:k,length:100*(e-n[i].max)/(e-r)+"%"}):""]})})),t.jsx(v.BarValue,{left:_&&!G?`${oe}%`:void 0,bottom:_?void 0:`${oe}%`,right:_&&G?`${oe}%`:void 0,width:_?le:"100%",height:_?"100%":le,length:le,size:ce,orientation:k,class:a.classNames([ge,_?be:$e,"active"===q?Se:""]),color:de}),P.referenceLines?.map(((a,i)=>t.jsx(I,{label:a.label,labelStyle:{fontSize:Ie.labelFontSize,...a.labelStyle},color:a.color,maxLabelWidth:Ee[i]?.width,maxLabelHeight:Ee[i]?.height,orientation:k,percent:100*(a.value-r)/(e-r),position:a.position,trackSize:Fe?`${_e}px`:d.meterBarVars.size,length:Fe?`calc(${h.xUnits(4)} + ${_e}px)`:void 0})))]})}),Ne,te,J]})}e.MeterBar=function({orientation:e,length:a,size:i,...n}){return t.jsx(t.Fragment,{children:"fit"===i?t.jsx(r.TrackResizeContainer,{width:"100%",height:"100%",children:(r,a)=>t.jsx(E,{width:r,height:a,orientation:e,size:i,...n})}):t.jsx(E,{size:i,length:a,orientation:e,...n})})}}));
1
+ define(['exports', 'preact/jsx-runtime', './TrackResizeContainer-c6b5de04', './classNames-08d99695', './mergeProps-bcfa6a92', 'preact/hooks', './useUser-e8dd7f7c', './useMeterDatatip-5d0b02c1', './useKeyboardEvents-f8b3ead1', './meterUtils-775a2dde', './utils-32e81a13', './UNSAFE_MeterBar/themes/MeterBarContract.css', './size-f0e638ec', './UNSAFE_MeterBar/themes/MeterBarStyles.css', './utils-948bcf60', './TabbableModeContext-a9c97640', './useTabbableMode-dc440317', './useComponentTheme-5aa41a8f', './UNSAFE_MeterBar/themes/redwood/MeterBarTheme', './useTestId-0140aa44', './useTextDimensions-030c6dbd', './useCssVars-311f2956', './Common/themes/themeContract.css', './LinearMeter-d1e744c1'], (function(e,t,r,a,i,n,s,o,l,c,h,d,u,m,x,f,p,g,$,b,S,y,z,v){"use strict";const T=15,C=5,k=4;function M(e){if(!e)return{width:0,height:0};const t=e.getBoundingClientRect();return{width:t.width,height:t.height}}const B=function(e,t,r,a,i,n){const s=[];return e.start&&s.push(t?r:a),e.end&&s.push(t?i:n),s},L=function(e,t,r,a){return r&&(e.start&&!a&&(r-=16),e.end&&!a&&(r-=16)),t&&r&&(r-=2*t+2*k),r},V=function(e,t,r,a){return r&&(e.start&&a&&(r-=16),e.end&&a&&(r-=16)),t&&r&&(r-=2*t+2*k),r},w=function(e,t,r){const a=`${h.xUnits(4)} + ${k}px`;return r?`calc(${a} + ${t}px) 0 calc(${a} + ${t}px) 0`:`0 calc(${a} + ${e}px) 0 calc(${a} + ${e}px)`};function R(e,t,r,a,i,n,s){const o=n||h.xUnits(C),l=`calc(${o} - ${s||d.meterBarVars.size})`;return r?i?`${e?"-50%":"50%"} calc(-100% - ${l} - ${k}px)`:`${e?"-50%":"50%"} calc(${o} + ${k}px)`:a?i?`calc(100% + ${l} + ${k}px) ${t?"50%":"-50%"}`:`calc(0px - ${o} - ${k}px) ${t?"50%":"-50%"}`:i?`calc(-100% - ${l} - ${k}px) ${t?"50%":"-50%"}`:`calc(${o} + ${k}px) ${t?"50%":"-50%"}`}function j(e,t,r,a,i){const n=`calc(${h.xUnits(C)} - ${d.meterBarVars.size})`,s=k,o=e.start&&e.end;if(a)return t?`calc(${i.height+s}px + ${n}) 0 calc(${i.height+s}px + ${n}) 0`:`0 calc(${i.width+s}px + ${n}) 0 calc(${i.width+s}px + ${n})`;if(r){if(o)return t?`${n} 0 ${n}`:`0 ${n} 0 ${n}`;if(e.start&&!e.end)return t?`${n} 0 0 0`:`0 ${n} 0 0`;if(!e.start&&e.end)return t?`0 0 ${n} 0`:`0 0 0 ${n}`}}function F(e,t,r,a,i,n){return{width:e?n:t?u.sizeToCSS(r):void 0,height:e?i:t?void 0:u.sizeToCSS(r),margin:e?w(a.width,a.height,t):void 0}}function H(e,t,r,a){return{left:e?`max(${r}px, ${t?100-a:a}%)`:void 0,right:e?void 0:`max(${r}px, ${t?a:100-a}%)`}}function U(e,t,r){if(0!==r||t)return 100===r?t?e?"3px":"0 3px":e?"-2px":"0 2px":e?t?"1px 0":"-1px 0":t?"0 -1px":"0 1px"}function D(e,t,r,a,i,n,s){return{...e?H(t,a,n/2,i):{},bottom:e?void 0:r?`max(${s/2-k}px, ${i}%)`:void 0,top:e||r?void 0:`max(${s/2-k}px, ${100-i}%)`,maxWidth:e?void 0:h.xUnits(T)}}function I({orientation:e,percent:r,color:i,position:n,length:o,label:l,maxLabelWidth:c,maxLabelHeight:h,trackSize:d,labelStyle:u}){const f="horizontal"===e,{direction:p}=s.useUser(),g="rtl"===p,$="start"===n,b=`${r}%`,S=f?void 0:o,y=f?o:void 0,z=r<50&&!g||r>50&&g,v=r<50;return t.jsxs(t.Fragment,{children:[t.jsx("div",{class:a.classNames([m.styles.referenceLinesBaseStyle,f?m.styles.referenceLinesHorizontalStyle:m.styles.referenceLinesVerticalStyle,$?f?m.styles.referenceLinesHoriontalStartStyle:g?m.styles.referenceLinesVerticalStartRtlStyle:m.styles.referenceLinesVerticalStartLtrStyle:""]),style:{left:f&&!g?b:void 0,right:f&&g?b:void 0,bottom:f?void 0:b,backgroundColor:x.getVisThresholdColor(i),width:S,height:y,translate:U(f,g,r)}}),l&&t.jsx("div",{className:m.styles.labelDivStyle,style:{...D(f,z,v,g,r,c,h),translate:R(z,v,f,g,$,o,d),...u},children:l})]})}function N({color:e,length:r,orientation:i,...n}){const{direction:o}=s.useUser(),l="horizontal"===i,c="rtl"===o;return t.jsx("div",{class:a.classNames([m.styles.thresholdBarBaseStyle,l?c?m.styles.thresholdBarHorizontalBarTrackSectionRtlStyle:m.styles.thresholdBarHorizontalBarTrackSectionLtrStyle:m.styles.thresholdBarVerticalBarTrackSectionStyle,n.class]),style:{width:l?r:"100%",height:l?"100%":r,backgroundColor:x.getVisThresholdColor(e)}})}function E({max:e=100,min:r=0,value:u=0,step:m=1,length:x="100%",width:f,height:T,size:C,orientation:k="horizontal",isTrackRendered:w=!0,thresholdDisplay:R="all",indicatorSize:H=1,testId:U,baseline:D,isReadonly:E,...P}){const A=b.useTestId(U);c.validateRange(r,e,u,m,E,D);const W=n.useRef(),_="horizontal"===k,K=n.useRef(null),X=n.useRef(M(null)),{direction:Y,forcedColors:q}=s.useUser(),G="rtl"===Y;n.useEffect((()=>{(P.onCommit||P.onInput)&&(X.current=M(K.current))}),[C,x,k,P.onCommit,P.onInput]);const{textMeasureContent:J,getTextDimensions:O}=S.useTextDimensions(),Q=n.useRef(!1),Z=o.usePointerEvents(u,(t=>{if(t.target==K.current)return function(e,t,r,a,i,n,s){const o=t.current;if(!o||0===o.width)return;let l;if("horizontal"===n){const t=e.offsetX;l=r+(a-r)*(s?o.width-t:t)/o.width}else l=r+(a-r)*(o.height-e.offsetY)/o.height;return l=Math.round(l/i)*i,Math.max(r,Math.min(a,l))}(t,X,r,e,m,k,G)}),K,W,Q,P.onCommit,P.onInput),ee=l.useKeyboardEvents(u,r,e,m,W,P.onCommit,P.onInput),{datatipContent:te,datatipProps:re}=o.useMeterDatatip(u,Q,P.datatip,P["aria-describedby"]),ae=c.getMeterAriaProps(u,r,e,P["aria-label"],P["aria-labelledby"],P.thresholds),ie=i.mergeProps(Z,ee,re,ae),ne=100*((void 0!==D?Math.max(r,Math.min(D,e)):r)-r)/(e-r),se=100*(u-r)/(e-r),oe=Math.min(ne,se),le=`${Math.abs(ne-se)}%`,ce=100*Math.max(0,Math.min(1,H))+"%",{trackColor:he,indicatorColor:de}=c.getTrackAndIndicatorColor(u,R,P.trackColor,P.indicatorColor,P.thresholds),ue=function(e){let t={start:!1,end:!1};return e&&(t=e.reduce(((e,t)=>(e.start=e.start||"start"===t.position,e.end=e.end||"end"===t.position||null==t.position,e)),t)),t}(P.referenceLines),me=P.onCommit||P.onInput,{isTabbable:xe}=p.useTabbableMode(),{classes:fe,styles:{interactiveStyle:pe,barValueBaseStyle:ge,barValueVerticalStyle:$e,barValueHorizontalStyle:be,barValueHighContrastStyle:Se,barTrackBaseStyle:ye,barTrackHorizontalSizeStyle:ze,barTrackVerticalSizeStyle:ve,barTrackBorderStyle:Te,barTrackMarginTopFitStyle:Ce,barTrackMarginStartFitStyle:ke,barTrackMarginBottomFitStyle:Me,barTrackMarginEndFitStyle:Be,trackSectionHorizontalFirstStyle:Le,trackSectionHorizontalLastStyle:Ve,trackSectionVerticalFirstStyle:we,trackSectionVerticalLastStyle:Re,trackSectionRoundedCornersStyle:je}}=g.useComponentTheme($.MeterBarRedwoodTheme,{size:C,orientation:k}),Fe="fit"===C,He=c.hasLabelledReferenceLine(P.referenceLines),Ue=c.getDefaultReferenceLineLabelFontSize("sm"),De=n.useMemo((()=>[{tokenVar:Ue,key:"labelFontSize",cssProp:"font-size"},{tokenVar:z.typographyVars.body.md.lineHeight,key:"lineHeight",cssProp:"line-height"}]),[Ue]),{resolvedVars:Ie,cssContent:Ne}=y.useCssVars(De),{dims:Ee,maxRefLabelDims:Pe}=c.getMaxRefLabelDims(Ie.fontSize,Ie.lineHeight,P.referenceLines,O),Ae=L(ue,Pe.width,f,_),We=V(ue,Pe.height,T,_),_e=_?We:Ae;return t.jsxs(t.Fragment,{children:[t.jsx("div",{tabIndex:xe?0:-1,...A,...ie,style:F(Fe,_,x,Pe,We,Ae),class:a.classNames([fe,...Fe?B(ue,_,Ce,ke,Me,Be):[]]),children:t.jsxs(v.BarTrack,{ref:K,orientation:k,color:!w||"all"===R&&P.thresholds?"transparent":he,class:a.classNames([ye,me?pe:"",_?ze:ve,!w||"all"===R&&P.thresholds?void 0:Te]),style:{margin:Fe?void 0:j(ue,_,!!P.referenceLines?.length,He,Pe)},children:["all"===R&&P.thresholds?.filter((t=>t.max>r&&t.max<=e)).sort(((e,t)=>e.max-t.max)).map(((a,i,n)=>{const s=0===i?a.max-r:a.max-n[i-1].max,o=_?Ve:Re;let l=0===i?_?Le:we:"";return a.max===e&&(l=0===i?je:o),t.jsxs(t.Fragment,{children:[t.jsx(N,{class:l,orientation:k,length:100*s/(e-r)+"%",color:a.color}),w&&i===n.length-1&&a.max<e?t.jsx(N,{class:o,color:he,orientation:k,length:100*(e-n[i].max)/(e-r)+"%"}):""]})})),t.jsx(v.BarValue,{left:_&&!G?`${oe}%`:void 0,bottom:_?void 0:`${oe}%`,right:_&&G?`${oe}%`:void 0,width:_?le:"100%",height:_?"100%":le,length:le,size:ce,orientation:k,class:a.classNames([ge,_?be:$e,"active"===q?Se:""]),color:de}),P.referenceLines?.map(((a,i)=>t.jsx(I,{label:a.label,labelStyle:{fontSize:Ie.labelFontSize,...a.labelStyle},color:a.color,maxLabelWidth:Ee[i]?.width,maxLabelHeight:Ee[i]?.height,orientation:k,percent:100*(a.value-r)/(e-r),position:a.position,trackSize:Fe?`${_e}px`:d.meterBarVars.size,length:Fe?`calc(${h.xUnits(4)} + ${_e}px)`:void 0})))]})}),Ne,te,J]})}e.MeterBar=function({orientation:e,length:a,size:i,...n}){return t.jsx(t.Fragment,{children:"fit"===i?t.jsx(r.TrackResizeContainer,{width:"100%",height:"100%",children:(r,a)=>t.jsx(E,{width:r,height:a,orientation:e,size:i,...n})}):t.jsx(E,{size:i,length:a,orientation:e,...n})})}}));
2
2
  //# sourceMappingURL=MeterBar-9f58cfad.js.map