@oracle/oraclejet-preact 14.0.17 → 14.0.18

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 (1053) hide show
  1. package/amd/Badge-cab31023.js +2 -0
  2. package/amd/{Badge-64e6fcda.js.map → Badge-cab31023.js.map} +1 -1
  3. package/amd/BaseButton-d3a7182f.js +2 -0
  4. package/amd/{BaseButton-e1bc5ecf.js.map → BaseButton-d3a7182f.js.map} +1 -1
  5. package/amd/Button-af8ce77b.js +2 -0
  6. package/amd/{Button-b2cfdb96.js.map → Button-af8ce77b.js.map} +1 -1
  7. package/amd/Chip-af7e2e0a.js +2 -0
  8. package/amd/{Chip-8bc3f2b3.js.map → Chip-af7e2e0a.js.map} +1 -1
  9. package/amd/{ClearIcon-53a9483c.js → ClearIcon-34e3a42e.js} +2 -2
  10. package/amd/{ClearIcon-53a9483c.js.map → ClearIcon-34e3a42e.js.map} +1 -1
  11. package/amd/{Collection-5a0a180f.js → Collection-e330f093.js} +1 -1
  12. package/amd/{Collection-5a0a180f.js.map → Collection-e330f093.js.map} +1 -1
  13. package/amd/ComponentMessage-bc697e9f.js +2 -0
  14. package/amd/{ComponentMessage-e03ada1f.js.map → ComponentMessage-bc697e9f.js.map} +1 -1
  15. package/amd/ComponentMessageContainer-302d6f66.js +2 -0
  16. package/amd/{ComponentMessageContainer-9215ce8b.js.map → ComponentMessageContainer-302d6f66.js.map} +1 -1
  17. package/amd/Divider-7d1b810d.js +2 -0
  18. package/amd/{Divider-2c1748b0.js.map → Divider-7d1b810d.js.map} +1 -1
  19. package/amd/{FilePicker-2c58043c.js → FilePicker-8ceee4cf.js} +2 -2
  20. package/amd/{FilePicker-2c58043c.js.map → FilePicker-8ceee4cf.js.map} +1 -1
  21. package/amd/Flex-98329367.js +2 -0
  22. package/amd/{Flex-d51505a6.js.map → Flex-98329367.js.map} +1 -1
  23. package/amd/{Floating-2b860872.js → Floating-5426966f.js} +2 -2
  24. package/amd/{Floating-2b860872.js.map → Floating-5426966f.js.map} +1 -1
  25. package/amd/FocusTrap-ee186ec0.js +2 -0
  26. package/amd/{FocusTrap-bf73a011.js.map → FocusTrap-ee186ec0.js.map} +1 -1
  27. package/amd/FormControlUtils-aaa1780b.js +2 -0
  28. package/amd/{FormControlUtils-1e2d5800.js.map → FormControlUtils-aaa1780b.js.map} +1 -1
  29. package/amd/Heading-4549ceb5.js +2 -0
  30. package/amd/{Heading-6c8f6318.js.map → Heading-4549ceb5.js.map} +1 -1
  31. package/amd/HiddenAccessible-776680bb.js +2 -0
  32. package/amd/{HiddenAccessible-7e5881b5.js.map → HiddenAccessible-776680bb.js.map} +1 -1
  33. package/amd/{HighlightText-117937f5.js → HighlightText-7e6f527d.js} +2 -2
  34. package/amd/{HighlightText-117937f5.js.map → HighlightText-7e6f527d.js.map} +1 -1
  35. package/amd/Icon-27ae306b.js +2 -0
  36. package/amd/{Icon-e13a0a05.js.map → Icon-27ae306b.js.map} +1 -1
  37. package/amd/Indexer-bb90382a.js +2 -0
  38. package/amd/{Indexer-c64c1c3d.js.map → Indexer-bb90382a.js.map} +1 -1
  39. package/amd/{InlineHelpSource-b2b78fc8.js → InlineHelpSource-e56e0e9b.js} +2 -2
  40. package/amd/{InlineHelpSource-b2b78fc8.js.map → InlineHelpSource-e56e0e9b.js.map} +1 -1
  41. package/amd/Link-9f4479c8.js +2 -0
  42. package/amd/{Link-11912f1b.js.map → Link-9f4479c8.js.map} +1 -1
  43. package/amd/List-54c58bf9.js +2 -0
  44. package/amd/{List-db591b68.js.map → List-54c58bf9.js.map} +1 -1
  45. package/amd/ListItemTextLayout-dc43e6a0.js +2 -0
  46. package/amd/{ListItemTextLayout-6c5aa001.js.map → ListItemTextLayout-dc43e6a0.js.map} +1 -1
  47. package/amd/{ListView-3b659e28.js → ListView-313d1b48.js} +2 -2
  48. package/amd/{ListView-3b659e28.js.map → ListView-313d1b48.js.map} +1 -1
  49. package/amd/{LoadMoreCollection-dc306d8b.js → LoadMoreCollection-5c05fef2.js} +2 -2
  50. package/amd/{LoadMoreCollection-dc306d8b.js.map → LoadMoreCollection-5c05fef2.js.map} +1 -1
  51. package/amd/Menu-f4102653.js +2 -0
  52. package/amd/{Menu-d9e4a334.js.map → Menu-f4102653.js.map} +1 -1
  53. package/amd/MenuDivider-f3573f9c.js +2 -0
  54. package/amd/{MenuDivider-0fbf7393.js.map → MenuDivider-f3573f9c.js.map} +1 -1
  55. package/amd/MenuItem-943593c4.js +2 -0
  56. package/amd/{MenuItem-09ddb137.js.map → MenuItem-943593c4.js.map} +1 -1
  57. package/amd/{Message.types-e4f47631.js → Message.types-58377c0f.js} +1 -1
  58. package/amd/{Message.types-e4f47631.js.map → Message.types-58377c0f.js.map} +1 -1
  59. package/amd/MessageCloseButton-92785492.js +2 -0
  60. package/amd/{MessageCloseButton-91b80681.js.map → MessageCloseButton-92785492.js.map} +1 -1
  61. package/amd/MessageDetail-da0140ec.js +2 -0
  62. package/amd/{MessageDetail-b6aa38c5.js.map → MessageDetail-da0140ec.js.map} +1 -1
  63. package/amd/{MessageFormattingUtils-ad3c7998.js → MessageFormattingUtils-0d3af9ea.js} +2 -2
  64. package/amd/{MessageFormattingUtils-ad3c7998.js.map → MessageFormattingUtils-0d3af9ea.js.map} +1 -1
  65. package/amd/MessageLayer-e763fade.js +2 -0
  66. package/amd/{MessageLayer-02c10111.js.map → MessageLayer-e763fade.js.map} +1 -1
  67. package/amd/MessageStartIcon-65875f63.js +2 -0
  68. package/amd/{MessageStartIcon-2755fe36.js.map → MessageStartIcon-65875f63.js.map} +1 -1
  69. package/amd/MessageSummary-d89ee92b.js +2 -0
  70. package/amd/{MessageSummary-7effa6f2.js.map → MessageSummary-d89ee92b.js.map} +1 -1
  71. package/amd/MessageTimestamp-d95637f1.js +2 -0
  72. package/amd/{MessageTimestamp-5bbfed00.js.map → MessageTimestamp-d95637f1.js.map} +1 -1
  73. package/amd/MessageToast-c1209114.js +2 -0
  74. package/amd/{MessageToast-b74f06cc.js.map → MessageToast-c1209114.js.map} +1 -1
  75. package/amd/{MessageUtils-dfc71879.js → MessageUtils-6057c9b6.js} +2 -2
  76. package/amd/{MessageUtils-dfc71879.js.map → MessageUtils-6057c9b6.js.map} +1 -1
  77. package/amd/MessagesManager-d46677ed.js +2 -0
  78. package/amd/{MessagesManager-5c36e297.js.map → MessagesManager-d46677ed.js.map} +1 -1
  79. package/amd/MeterCircle-4e803ab5.js +2 -0
  80. package/amd/{MeterCircle-952e7f59.js.map → MeterCircle-4e803ab5.js.map} +1 -1
  81. package/amd/Modal-2b3340c6.js +2 -0
  82. package/amd/{Modal-6fa6b6c6.js.map → Modal-2b3340c6.js.map} +1 -1
  83. package/amd/{NumberInputText-b9ed8606.js → NumberInputText-f5ff6513.js} +2 -2
  84. package/amd/{NumberInputText-b9ed8606.js.map → NumberInputText-f5ff6513.js.map} +1 -1
  85. package/amd/PRIVATE_Collection.js +1 -1
  86. package/amd/PRIVATE_List.css +15 -15
  87. package/amd/PRIVATE_List.js +1 -1
  88. package/amd/PRIVATE_Message.css +27 -27
  89. package/amd/PRIVATE_Message.js +1 -1
  90. package/amd/PRIVATE_Message.js.map +1 -1
  91. package/amd/PRIVATE_MessageLayer.css +7 -7
  92. package/amd/PRIVATE_MessageLayer.js +1 -1
  93. package/amd/PRIVATE_Meter.js +1 -1
  94. package/amd/PRIVATE_SelectCommon.css +13 -13
  95. package/amd/PRIVATE_SelectCommon.js +1 -1
  96. package/amd/PRIVATE_SelectCommon.js.map +1 -1
  97. package/amd/PRIVATE_VirtualizedCollection.js +1 -1
  98. package/amd/ReadonlyTextFieldInput-21372f6f.js +2 -0
  99. package/amd/{ReadonlyTextFieldInput-dea043dd.js.map → ReadonlyTextFieldInput-21372f6f.js.map} +1 -1
  100. package/amd/{SelectMenuItem-e5e89b97.js → SelectMenuItem-b9add23c.js} +2 -2
  101. package/amd/{SelectMenuItem-e5e89b97.js.map → SelectMenuItem-b9add23c.js.map} +1 -1
  102. package/amd/SelectMultiple-34cda10e.js +2 -0
  103. package/amd/{SelectMultiple-32a90b41.js.map → SelectMultiple-34cda10e.js.map} +1 -1
  104. package/amd/{SelectSingle-cda46f86.js → SelectSingle-9d1a30c7.js} +2 -2
  105. package/amd/{SelectSingle-cda46f86.js.map → SelectSingle-9d1a30c7.js.map} +1 -1
  106. package/amd/Skeleton-9609a702.js +2 -0
  107. package/amd/{Skeleton-aa6570c4.js.map → Skeleton-9609a702.js.map} +1 -1
  108. package/amd/{Spacer-0f11773d.js → Spacer-53cc7de2.js} +2 -2
  109. package/amd/{Spacer-0f11773d.js.map → Spacer-53cc7de2.js.map} +1 -1
  110. package/amd/SplitMenuButton-da63e0b6.js +2 -0
  111. package/amd/{SplitMenuButton-72b8de27.js.map → SplitMenuButton-da63e0b6.js.map} +1 -1
  112. package/amd/Text-442082b8.js +2 -0
  113. package/amd/{Text-781e64c9.js.map → Text-442082b8.js.map} +1 -1
  114. package/amd/TextArea-d45836f7.js +2 -0
  115. package/amd/{TextArea-89a244ab.js.map → TextArea-d45836f7.js.map} +1 -1
  116. package/amd/{TextAreaAutosize-3182a5cd.js → TextAreaAutosize-0c2ab14a.js} +2 -2
  117. package/amd/{TextAreaAutosize-3182a5cd.js.map → TextAreaAutosize-0c2ab14a.js.map} +1 -1
  118. package/amd/TextFieldInput-2719b778.js +2 -0
  119. package/amd/{TextFieldInput-40ce4927.js.map → TextFieldInput-2719b778.js.map} +1 -1
  120. package/amd/UNSAFE_AspectRatio.css +1 -1
  121. package/amd/UNSAFE_AspectRatio.js +1 -1
  122. package/amd/UNSAFE_Avatar.css +8 -8
  123. package/amd/UNSAFE_Avatar.js +1 -1
  124. package/amd/UNSAFE_Avatar.js.map +1 -1
  125. package/amd/UNSAFE_Badge.css +13 -13
  126. package/amd/UNSAFE_Badge.js +1 -1
  127. package/amd/UNSAFE_BaseButton.css +15 -15
  128. package/amd/UNSAFE_BaseButton.js +1 -1
  129. package/amd/UNSAFE_Button.css +8 -8
  130. package/amd/UNSAFE_Button.js +1 -1
  131. package/amd/UNSAFE_Center.js +1 -1
  132. package/amd/UNSAFE_Chip.css +7 -7
  133. package/amd/UNSAFE_Chip.js +1 -1
  134. package/amd/UNSAFE_Collapsible.css +8 -8
  135. package/amd/UNSAFE_Collapsible.js +1 -1
  136. package/amd/UNSAFE_Collapsible.js.map +1 -1
  137. package/amd/UNSAFE_ComponentMessage.css +2 -2
  138. package/amd/UNSAFE_ComponentMessage.js +1 -1
  139. package/amd/UNSAFE_Divider.css +1 -1
  140. package/amd/UNSAFE_Divider.js +1 -1
  141. package/amd/UNSAFE_FilePicker.css +6 -6
  142. package/amd/UNSAFE_FilePicker.js +1 -1
  143. package/amd/UNSAFE_Flex.css +2 -2
  144. package/amd/UNSAFE_Flex.js +1 -1
  145. package/amd/UNSAFE_Floating.js +1 -1
  146. package/amd/UNSAFE_FocusTrap.css +2 -2
  147. package/amd/UNSAFE_FocusTrap.js +1 -1
  148. package/amd/UNSAFE_Grid.css +1 -1
  149. package/amd/UNSAFE_Grid.js +1 -1
  150. package/amd/UNSAFE_Heading.css +9 -9
  151. package/amd/UNSAFE_Heading.js +1 -1
  152. package/amd/UNSAFE_HiddenAccessible.css +1 -1
  153. package/amd/UNSAFE_HiddenAccessible.js +1 -1
  154. package/amd/UNSAFE_HighlightText.css +1 -1
  155. package/amd/UNSAFE_HighlightText.js +1 -1
  156. package/amd/UNSAFE_Icon.css +21 -21
  157. package/amd/UNSAFE_Icon.js +1 -1
  158. package/amd/UNSAFE_Icons.js +1 -1
  159. package/amd/UNSAFE_Indexer.css +7 -7
  160. package/amd/UNSAFE_Indexer.js +1 -1
  161. package/amd/UNSAFE_InputPassword.css +1 -1
  162. package/amd/UNSAFE_InputPassword.js +1 -1
  163. package/amd/UNSAFE_InputPassword.js.map +1 -1
  164. package/amd/UNSAFE_InputText.css +1 -1
  165. package/amd/UNSAFE_InputText.js +1 -1
  166. package/amd/UNSAFE_Label.css +13 -13
  167. package/amd/UNSAFE_Label.js +1 -1
  168. package/amd/UNSAFE_Label.js.map +1 -1
  169. package/amd/UNSAFE_LabelValueLayout.css +9 -9
  170. package/amd/UNSAFE_LabelValueLayout.js +1 -1
  171. package/amd/UNSAFE_LabelValueLayout.js.map +1 -1
  172. package/amd/UNSAFE_Link.css +5 -5
  173. package/amd/UNSAFE_Link.js +1 -1
  174. package/amd/UNSAFE_ListItemLayout.css +9 -9
  175. package/amd/UNSAFE_ListItemLayout.js +1 -1
  176. package/amd/UNSAFE_ListView.js +1 -1
  177. package/amd/UNSAFE_LiveRegion.css +1 -1
  178. package/amd/UNSAFE_LiveRegion.js +1 -1
  179. package/amd/UNSAFE_LiveRegion.js.map +1 -1
  180. package/amd/UNSAFE_LoadMoreCollection.js +1 -1
  181. package/amd/UNSAFE_Menu.css +17 -17
  182. package/amd/UNSAFE_Menu.js +1 -1
  183. package/amd/UNSAFE_MessageBanner.js +1 -1
  184. package/amd/UNSAFE_MessageToast.css +1 -1
  185. package/amd/UNSAFE_MessageToast.js +1 -1
  186. package/amd/UNSAFE_MeterBar.css +43 -43
  187. package/amd/UNSAFE_MeterBar.js +1 -1
  188. package/amd/UNSAFE_MeterBar.js.map +1 -1
  189. package/amd/UNSAFE_MeterCircle.css +46 -46
  190. package/amd/UNSAFE_MeterCircle.js +1 -1
  191. package/amd/UNSAFE_Modal.css +3 -3
  192. package/amd/UNSAFE_Modal.js +1 -1
  193. package/amd/UNSAFE_NumberInputText.js +1 -1
  194. package/amd/UNSAFE_PrefixSuffix.css +8 -8
  195. package/amd/UNSAFE_PrefixSuffix.js +1 -1
  196. package/amd/UNSAFE_PrefixSuffix.js.map +1 -1
  197. package/amd/UNSAFE_ProgressBar.css +6 -6
  198. package/amd/UNSAFE_ProgressBar.js +1 -1
  199. package/amd/UNSAFE_ProgressBar.js.map +1 -1
  200. package/amd/UNSAFE_ProgressCircle.css +6 -6
  201. package/amd/UNSAFE_ProgressCircle.js +1 -1
  202. package/amd/UNSAFE_ProgressCircle.js.map +1 -1
  203. package/amd/UNSAFE_RatingGauge.css +20 -20
  204. package/amd/UNSAFE_RatingGauge.js +1 -1
  205. package/amd/UNSAFE_RatingGauge.js.map +1 -1
  206. package/amd/UNSAFE_SelectMultiple.css +1 -1
  207. package/amd/UNSAFE_SelectMultiple.js +1 -1
  208. package/amd/UNSAFE_SelectSingle.js +1 -1
  209. package/amd/UNSAFE_Selector.css +5 -5
  210. package/amd/UNSAFE_Selector.js +1 -1
  211. package/amd/UNSAFE_Selector.js.map +1 -1
  212. package/amd/UNSAFE_Skeleton.css +1 -1
  213. package/amd/UNSAFE_Skeleton.js +1 -1
  214. package/amd/UNSAFE_Spacer.js +1 -1
  215. package/amd/UNSAFE_SplitMenuButton.css +5 -5
  216. package/amd/UNSAFE_SplitMenuButton.js +1 -1
  217. package/amd/UNSAFE_Text.css +25 -25
  218. package/amd/UNSAFE_Text.js +1 -1
  219. package/amd/UNSAFE_TextArea.css +3 -3
  220. package/amd/UNSAFE_TextArea.js +1 -1
  221. package/amd/UNSAFE_TextAreaAutosize.js +1 -1
  222. package/amd/UNSAFE_TextField.css +58 -58
  223. package/amd/UNSAFE_TextField.js +1 -1
  224. package/amd/UNSAFE_TextField.js.map +1 -1
  225. package/amd/UNSAFE_ThemedIcons.js +1 -1
  226. package/amd/UNSAFE_UserAssistance.css +8 -8
  227. package/amd/UNSAFE_UserAssistance.js +1 -1
  228. package/amd/UNSAFE_UserAssistance.js.map +1 -1
  229. package/amd/UNSAFE_View.js +1 -1
  230. package/amd/UNSAFE_VirtualizedListView.js +1 -1
  231. package/amd/{VirtualizedCollection-bbd10093.js → VirtualizedCollection-d591f44d.js} +2 -2
  232. package/amd/{VirtualizedCollection-bbd10093.js.map → VirtualizedCollection-d591f44d.js.map} +1 -1
  233. package/amd/{VirtualizedListView-95394fe3.js → VirtualizedListView-071ddc47.js} +2 -2
  234. package/amd/{VirtualizedListView-95394fe3.js.map → VirtualizedListView-071ddc47.js.map} +1 -1
  235. package/amd/{_curry1-8ff28a98.js → _curry1-e9025233.js} +1 -1
  236. package/amd/{_curry1-8ff28a98.js.map → _curry1-e9025233.js.map} +1 -1
  237. package/amd/_curry2-722350a9.js +2 -0
  238. package/amd/{_curry2-4707be52.js.map → _curry2-722350a9.js.map} +1 -1
  239. package/amd/_curry3-8a91848a.js +2 -0
  240. package/amd/{_curry3-ccc05acd.js.map → _curry3-8a91848a.js.map} +1 -1
  241. package/amd/_has-f54967fe.js +2 -0
  242. package/amd/{_has-707f8be4.js.map → _has-f54967fe.js.map} +1 -1
  243. package/amd/{classNames-e64f6be5.js → classNames-f3dd3ee3.js} +1 -1
  244. package/amd/{classNames-e64f6be5.js.map → classNames-f3dd3ee3.js.map} +1 -1
  245. package/amd/{clientHints-e7f42d0c.js → clientHints-eee7d2aa.js} +1 -1
  246. package/amd/{clientHints-e7f42d0c.js.map → clientHints-eee7d2aa.js.map} +1 -1
  247. package/amd/flexbox-926e15dc.js +2 -0
  248. package/amd/{flexbox-779e73ea.js.map → flexbox-926e15dc.js.map} +1 -1
  249. package/amd/flexitem-e03beddd.js +2 -0
  250. package/amd/{flexitem-e6a6355c.js.map → flexitem-e03beddd.js.map} +1 -1
  251. package/amd/hooks/PRIVATE_useDvtMeterEvents.js +1 -1
  252. package/amd/hooks/PRIVATE_useSingleSelection.js +1 -1
  253. package/amd/hooks/UNSAFE_useAnimation.js +1 -1
  254. package/amd/hooks/UNSAFE_useFloating.js +1 -1
  255. package/amd/hooks/UNSAFE_useFocusWithin.js +1 -1
  256. package/amd/hooks/UNSAFE_useFocusableTextField.js +1 -1
  257. package/amd/hooks/UNSAFE_usePrefixSuffix.js +1 -1
  258. package/amd/hooks/UNSAFE_useTextFieldInputHandlers.js +1 -1
  259. package/amd/hooks/UNSAFE_useTooltip.css +4 -4
  260. package/amd/hooks/UNSAFE_useTooltip.js +1 -1
  261. package/amd/hooks/UNSAFE_useTooltip.js.map +1 -1
  262. package/amd/{index-28b36e2a.js → index-504efee4.js} +1 -1
  263. package/amd/{index-28b36e2a.js.map → index-504efee4.js.map} +1 -1
  264. package/amd/{index-e91138c6.js → index-9cd290d0.js} +2 -2
  265. package/amd/{index-e91138c6.js.map → index-9cd290d0.js.map} +1 -1
  266. package/amd/{index-680090e2.js → index-bb78541d.js} +2 -2
  267. package/amd/{index-680090e2.js.map → index-bb78541d.js.map} +1 -1
  268. package/amd/{keys-8e8a35ab.js → keys-3b7ed071.js} +2 -2
  269. package/amd/{keys-8e8a35ab.js.map → keys-3b7ed071.js.map} +1 -1
  270. package/amd/{listViewSelectionTests-e2df65b8.js → listViewSelectionTests-ccde1b1b.js} +2 -2
  271. package/amd/{listViewSelectionTests-e2df65b8.js.map → listViewSelectionTests-ccde1b1b.js.map} +1 -1
  272. package/amd/{listViewTabbableModeTests-ea8d948e.js → listViewTabbableModeTests-abf9cb9f.js} +2 -2
  273. package/amd/{listViewTabbableModeTests-ea8d948e.js.map → listViewTabbableModeTests-abf9cb9f.js.map} +1 -1
  274. package/amd/{listViewTestFixtures-f4f207ee.js → listViewTestFixtures-f8d4627f.js} +1 -1
  275. package/amd/{listViewTestFixtures-f4f207ee.js.map → listViewTestFixtures-f8d4627f.js.map} +1 -1
  276. package/amd/{menuTestsUtils-e6b0f3d8.js → menuTestsUtils-2266c5d8.js} +1 -1
  277. package/amd/{menuTestsUtils-e6b0f3d8.js.map → menuTestsUtils-2266c5d8.js.map} +1 -1
  278. package/amd/{stringUtils-46474c2b.js → stringUtils-5a1d41c7.js} +1 -1
  279. package/amd/{stringUtils-46474c2b.js.map → stringUtils-5a1d41c7.js.map} +1 -1
  280. package/amd/{testHelpers-073a6174.js → testHelpers-639a8e60.js} +1 -1
  281. package/amd/{testHelpers-073a6174.js.map → testHelpers-639a8e60.js.map} +1 -1
  282. package/amd/{tslib.es6-74fb34cf.js → tslib.es6-9d88853c.js} +1 -1
  283. package/amd/{tslib.es6-74fb34cf.js.map → tslib.es6-9d88853c.js.map} +1 -1
  284. package/amd/{useAnimation-74110f0c.js → useAnimation-eff230e0.js} +2 -2
  285. package/amd/{useAnimation-74110f0c.js.map → useAnimation-eff230e0.js.map} +1 -1
  286. package/amd/{useFocusWithin-21c56c22.js → useFocusWithin-11de5fd9.js} +1 -1
  287. package/amd/{useFocusWithin-21c56c22.js.map → useFocusWithin-11de5fd9.js.map} +1 -1
  288. package/amd/{useSingleSelection-49e1c3a4.js → useSingleSelection-e61f25c4.js} +1 -1
  289. package/amd/{useSingleSelection-49e1c3a4.js.map → useSingleSelection-e61f25c4.js.map} +1 -1
  290. package/amd/utils/PRIVATE_clientHints.js +1 -1
  291. package/amd/utils/PRIVATE_tabbableUtils.js +1 -1
  292. package/amd/utils/UNSAFE_classNames.js +1 -1
  293. package/amd/utils/UNSAFE_interpolations/boxalignment.css +15 -15
  294. package/amd/utils/UNSAFE_interpolations/boxalignment.js +1 -1
  295. package/amd/utils/UNSAFE_interpolations/boxalignment.js.map +1 -1
  296. package/amd/utils/UNSAFE_interpolations/dimensions.js +1 -1
  297. package/amd/utils/UNSAFE_interpolations/flexbox.css +7 -7
  298. package/amd/utils/UNSAFE_interpolations/flexbox.js +1 -1
  299. package/amd/utils/UNSAFE_interpolations/flexitem.css +7 -7
  300. package/amd/utils/UNSAFE_interpolations/flexitem.js +1 -1
  301. package/amd/utils/UNSAFE_interpolations/text.css +3 -3
  302. package/amd/utils/UNSAFE_interpolations/text.js +1 -1
  303. package/amd/utils/UNSAFE_interpolations/text.js.map +1 -1
  304. package/amd/utils/UNSAFE_logger.js +1 -1
  305. package/amd/utils/UNSAFE_mergeInterpolations.js +1 -1
  306. package/amd/utils/UNSAFE_stringUtils.js +1 -1
  307. package/amd/utils/UNSAFE_units.js +1 -1
  308. package/cjs/{Badge-1c904d15.js → Badge-dd3eef10.js} +16 -16
  309. package/cjs/{Badge-1c904d15.js.map → Badge-dd3eef10.js.map} +1 -1
  310. package/cjs/{BaseButton-d631ce3d.js → BaseButton-3d84f55e.js} +20 -20
  311. package/cjs/{BaseButton-d631ce3d.js.map → BaseButton-3d84f55e.js.map} +1 -1
  312. package/cjs/{Button-62d2d090.js → Button-87aeedd0.js} +13 -13
  313. package/cjs/{Button-62d2d090.js.map → Button-87aeedd0.js.map} +1 -1
  314. package/cjs/{Chip-d53b25e1.js → Chip-06d7c1cf.js} +10 -10
  315. package/cjs/{Chip-d53b25e1.js.map → Chip-06d7c1cf.js.map} +1 -1
  316. package/cjs/{ClearIcon-fa92ac1e.js → ClearIcon-687936c1.js} +3 -3
  317. package/cjs/{ClearIcon-fa92ac1e.js.map → ClearIcon-687936c1.js.map} +1 -1
  318. package/cjs/{Collection-104ad9c1.js → Collection-32e31dfa.js} +2 -2
  319. package/cjs/{Collection-104ad9c1.js.map → Collection-32e31dfa.js.map} +1 -1
  320. package/cjs/{ComponentMessage-a1377b54.js → ComponentMessage-dc9a4dfc.js} +8 -8
  321. package/cjs/{ComponentMessage-a1377b54.js.map → ComponentMessage-dc9a4dfc.js.map} +1 -1
  322. package/cjs/{ComponentMessageContainer-ccd03f90.js → ComponentMessageContainer-536bfde8.js} +5 -5
  323. package/cjs/{ComponentMessageContainer-ccd03f90.js.map → ComponentMessageContainer-536bfde8.js.map} +1 -1
  324. package/cjs/{Divider-71ec152d.js → Divider-dfa457e1.js} +3 -3
  325. package/cjs/{Divider-71ec152d.js.map → Divider-dfa457e1.js.map} +1 -1
  326. package/cjs/{FilePicker-8ac52da3.js → FilePicker-01ddf36b.js} +14 -14
  327. package/cjs/{FilePicker-8ac52da3.js.map → FilePicker-01ddf36b.js.map} +1 -1
  328. package/cjs/{Flex-0477300a.js → Flex-80d4a30b.js} +8 -8
  329. package/cjs/{Flex-0477300a.js.map → Flex-80d4a30b.js.map} +1 -1
  330. package/cjs/{Floating-38a935e0.js → Floating-1b5183bb.js} +3 -3
  331. package/cjs/{Floating-38a935e0.js.map → Floating-1b5183bb.js.map} +1 -1
  332. package/cjs/{FocusTrap-b78486ab.js → FocusTrap-7206e429.js} +5 -5
  333. package/cjs/{FocusTrap-b78486ab.js.map → FocusTrap-7206e429.js.map} +1 -1
  334. package/cjs/{FormControlUtils-91272b5d.js → FormControlUtils-19d009cf.js} +5 -5
  335. package/cjs/{FormControlUtils-91272b5d.js.map → FormControlUtils-19d009cf.js.map} +1 -1
  336. package/cjs/{Heading-ccafafdc.js → Heading-c9179536.js} +13 -13
  337. package/cjs/{Heading-ccafafdc.js.map → Heading-c9179536.js.map} +1 -1
  338. package/cjs/{HiddenAccessible-553a8ebd.js → HiddenAccessible-40bf241a.js} +3 -3
  339. package/cjs/{HiddenAccessible-553a8ebd.js.map → HiddenAccessible-40bf241a.js.map} +1 -1
  340. package/cjs/{HighlightText-35317372.js → HighlightText-cf41c8b9.js} +3 -3
  341. package/cjs/{HighlightText-35317372.js.map → HighlightText-cf41c8b9.js.map} +1 -1
  342. package/cjs/{Icon-4ae27889.js → Icon-1154552a.js} +25 -25
  343. package/cjs/{Icon-4ae27889.js.map → Icon-1154552a.js.map} +1 -1
  344. package/cjs/{Indexer-978a0622.js → Indexer-b4a6eb04.js} +16 -16
  345. package/cjs/{Indexer-978a0622.js.map → Indexer-b4a6eb04.js.map} +1 -1
  346. package/cjs/{InlineHelpSource-b7376517.js → InlineHelpSource-be5cb936.js} +3 -3
  347. package/cjs/{InlineHelpSource-b7376517.js.map → InlineHelpSource-be5cb936.js.map} +1 -1
  348. package/cjs/{Link-c79255e5.js → Link-4ebff501.js} +8 -8
  349. package/cjs/{Link-c79255e5.js.map → Link-4ebff501.js.map} +1 -1
  350. package/cjs/{List-623a3ebe.js → List-0ddfbf65.js} +23 -23
  351. package/cjs/{List-623a3ebe.js.map → List-0ddfbf65.js.map} +1 -1
  352. package/cjs/{ListItemTextLayout-dd6e0d99.js → ListItemTextLayout-0f8ed8ce.js} +13 -13
  353. package/cjs/{ListItemTextLayout-dd6e0d99.js.map → ListItemTextLayout-0f8ed8ce.js.map} +1 -1
  354. package/cjs/{ListView-bbcb9698.js → ListView-2e522c3b.js} +3 -3
  355. package/cjs/{ListView-bbcb9698.js.map → ListView-2e522c3b.js.map} +1 -1
  356. package/cjs/{LoadMoreCollection-f702c6e6.js → LoadMoreCollection-48388df1.js} +3 -3
  357. package/cjs/{LoadMoreCollection-f702c6e6.js.map → LoadMoreCollection-48388df1.js.map} +1 -1
  358. package/cjs/{Menu-65df5ed6.js → Menu-877075be.js} +6 -6
  359. package/cjs/{Menu-65df5ed6.js.map → Menu-877075be.js.map} +1 -1
  360. package/cjs/{MenuDivider-d8d791eb.js → MenuDivider-b7d8b30b.js} +4 -4
  361. package/cjs/{MenuDivider-d8d791eb.js.map → MenuDivider-b7d8b30b.js.map} +1 -1
  362. package/cjs/{MenuItem-3c1a6e60.js → MenuItem-4cd1055f.js} +19 -19
  363. package/cjs/{MenuItem-3c1a6e60.js.map → MenuItem-4cd1055f.js.map} +1 -1
  364. package/cjs/{Message.types-70248ba1.js → Message.types-4c9cc6fe.js} +2 -2
  365. package/cjs/{Message.types-70248ba1.js.map → Message.types-4c9cc6fe.js.map} +1 -1
  366. package/cjs/{MessageCloseButton-f820af87.js → MessageCloseButton-48097f98.js} +9 -9
  367. package/cjs/{MessageCloseButton-f820af87.js.map → MessageCloseButton-48097f98.js.map} +1 -1
  368. package/cjs/{MessageDetail-4711b78d.js → MessageDetail-34a424f0.js} +7 -7
  369. package/cjs/{MessageDetail-4711b78d.js.map → MessageDetail-34a424f0.js.map} +1 -1
  370. package/cjs/{MessageFormattingUtils-7caa7444.js → MessageFormattingUtils-55d306ba.js} +4 -4
  371. package/cjs/{MessageFormattingUtils-7caa7444.js.map → MessageFormattingUtils-55d306ba.js.map} +1 -1
  372. package/cjs/{MessageLayer-8502ce6b.js → MessageLayer-05f63bc1.js} +11 -11
  373. package/cjs/{MessageLayer-8502ce6b.js.map → MessageLayer-05f63bc1.js.map} +1 -1
  374. package/cjs/{MessageStartIcon-5affbd2c.js → MessageStartIcon-b410dde3.js} +11 -11
  375. package/cjs/{MessageStartIcon-5affbd2c.js.map → MessageStartIcon-b410dde3.js.map} +1 -1
  376. package/cjs/{MessageSummary-d698a63e.js → MessageSummary-2adfa7d2.js} +7 -7
  377. package/cjs/{MessageSummary-d698a63e.js.map → MessageSummary-2adfa7d2.js.map} +1 -1
  378. package/cjs/{MessageTimestamp-efee7c01.js → MessageTimestamp-5608c4e2.js} +5 -5
  379. package/cjs/{MessageTimestamp-efee7c01.js.map → MessageTimestamp-5608c4e2.js.map} +1 -1
  380. package/cjs/{MessageToast-7900fef9.js → MessageToast-f4b82659.js} +9 -9
  381. package/cjs/{MessageToast-7900fef9.js.map → MessageToast-f4b82659.js.map} +1 -1
  382. package/cjs/{MessageUtils-3d2dab4e.js → MessageUtils-e2823fcb.js} +3 -3
  383. package/cjs/{MessageUtils-3d2dab4e.js.map → MessageUtils-e2823fcb.js.map} +1 -1
  384. package/cjs/{MessagesManager-dea7c6af.js → MessagesManager-96192a54.js} +4 -4
  385. package/cjs/{MessagesManager-dea7c6af.js.map → MessagesManager-96192a54.js.map} +1 -1
  386. package/cjs/{MeterCircle-ce5a8542.js → MeterCircle-d02b10d5.js} +50 -50
  387. package/cjs/{MeterCircle-ce5a8542.js.map → MeterCircle-d02b10d5.js.map} +1 -1
  388. package/cjs/{Modal-c5cbae06.js → Modal-3b65616d.js} +6 -6
  389. package/cjs/{Modal-c5cbae06.js.map → Modal-3b65616d.js.map} +1 -1
  390. package/cjs/{NumberInputText-956c2a03.js → NumberInputText-3444611b.js} +7 -7
  391. package/cjs/{NumberInputText-956c2a03.js.map → NumberInputText-3444611b.js.map} +1 -1
  392. package/cjs/PRIVATE_Collection.js +2 -2
  393. package/cjs/PRIVATE_List.js +23 -23
  394. package/cjs/PRIVATE_Message.js +41 -41
  395. package/cjs/PRIVATE_Message.js.map +1 -1
  396. package/cjs/PRIVATE_MessageLayer.js +12 -12
  397. package/cjs/PRIVATE_Meter.js +2 -2
  398. package/cjs/PRIVATE_SelectCommon.js +54 -54
  399. package/cjs/PRIVATE_SelectCommon.js.map +1 -1
  400. package/cjs/PRIVATE_TransitionGroup.js +1 -1
  401. package/cjs/PRIVATE_VirtualizedCollection.js +3 -3
  402. package/cjs/{ReadonlyTextFieldInput-df7d9551.js → ReadonlyTextFieldInput-d865482d.js} +13 -13
  403. package/cjs/{ReadonlyTextFieldInput-df7d9551.js.map → ReadonlyTextFieldInput-d865482d.js.map} +1 -1
  404. package/cjs/{SelectMenuItem-a6d468ae.js → SelectMenuItem-7d9f72d0.js} +5 -5
  405. package/cjs/{SelectMenuItem-a6d468ae.js.map → SelectMenuItem-7d9f72d0.js.map} +1 -1
  406. package/cjs/{SelectMultiple-e9b17517.js → SelectMultiple-14a1b030.js} +8 -8
  407. package/cjs/{SelectMultiple-e9b17517.js.map → SelectMultiple-14a1b030.js.map} +1 -1
  408. package/cjs/{SelectSingle-97528530.js → SelectSingle-1201ad16.js} +4 -4
  409. package/cjs/{SelectSingle-97528530.js.map → SelectSingle-1201ad16.js.map} +1 -1
  410. package/cjs/{Skeleton-30eb135d.js → Skeleton-ebb80651.js} +5 -5
  411. package/cjs/{Skeleton-30eb135d.js.map → Skeleton-ebb80651.js.map} +1 -1
  412. package/cjs/{Spacer-c033ccbf.js → Spacer-cbe5f5fd.js} +4 -4
  413. package/cjs/{Spacer-c033ccbf.js.map → Spacer-cbe5f5fd.js.map} +1 -1
  414. package/cjs/{SplitMenuButton-93f8cccc.js → SplitMenuButton-1edb6ad2.js} +14 -14
  415. package/cjs/{SplitMenuButton-93f8cccc.js.map → SplitMenuButton-1edb6ad2.js.map} +1 -1
  416. package/cjs/{Text-08aefee7.js → Text-69b799c8.js} +28 -28
  417. package/cjs/{Text-08aefee7.js.map → Text-69b799c8.js.map} +1 -1
  418. package/cjs/{TextArea-1b9f629e.js → TextArea-3944b602.js} +8 -8
  419. package/cjs/{TextArea-1b9f629e.js.map → TextArea-3944b602.js.map} +1 -1
  420. package/cjs/{TextAreaAutosize-7589acc1.js → TextAreaAutosize-682f455c.js} +5 -5
  421. package/cjs/{TextAreaAutosize-7589acc1.js.map → TextAreaAutosize-682f455c.js.map} +1 -1
  422. package/cjs/{TextFieldInput-f7b50890.js → TextFieldInput-c70fae2b.js} +33 -33
  423. package/cjs/{TextFieldInput-f7b50890.js.map → TextFieldInput-c70fae2b.js.map} +1 -1
  424. package/cjs/UNSAFE_AspectRatio.js +8 -8
  425. package/cjs/UNSAFE_AspectRatio.js.map +1 -1
  426. package/cjs/UNSAFE_Avatar.js +11 -11
  427. package/cjs/UNSAFE_Avatar.js.map +1 -1
  428. package/cjs/UNSAFE_Badge.js +3 -3
  429. package/cjs/UNSAFE_BaseButton.js +9 -9
  430. package/cjs/UNSAFE_Button.js +10 -10
  431. package/cjs/UNSAFE_Center.js +11 -11
  432. package/cjs/UNSAFE_Chip.js +3 -3
  433. package/cjs/UNSAFE_Collapsible.js +26 -26
  434. package/cjs/UNSAFE_Collapsible.js.map +1 -1
  435. package/cjs/UNSAFE_Collection.js +1 -1
  436. package/cjs/UNSAFE_ComponentMessage.js +33 -33
  437. package/cjs/UNSAFE_Divider.js +7 -7
  438. package/cjs/UNSAFE_EmptyList.js +1 -1
  439. package/cjs/UNSAFE_Environment.js +1 -1
  440. package/cjs/UNSAFE_FilePicker.js +14 -14
  441. package/cjs/UNSAFE_Flex.js +11 -11
  442. package/cjs/UNSAFE_Floating.js +3 -3
  443. package/cjs/UNSAFE_FocusTrap.js +6 -6
  444. package/cjs/UNSAFE_Grid.js +9 -9
  445. package/cjs/UNSAFE_Heading.js +9 -9
  446. package/cjs/UNSAFE_HiddenAccessible.js +2 -2
  447. package/cjs/UNSAFE_HighlightText.js +2 -2
  448. package/cjs/UNSAFE_Icon.js +7 -7
  449. package/cjs/UNSAFE_Icons.js +8 -8
  450. package/cjs/UNSAFE_Indexer.js +16 -16
  451. package/cjs/UNSAFE_InputPassword.js +40 -40
  452. package/cjs/UNSAFE_InputText.js +39 -39
  453. package/cjs/UNSAFE_Label.js +16 -16
  454. package/cjs/UNSAFE_Label.js.map +1 -1
  455. package/cjs/UNSAFE_LabelValueLayout.js +20 -20
  456. package/cjs/UNSAFE_LabelValueLayout.js.map +1 -1
  457. package/cjs/UNSAFE_Layer.js +1 -1
  458. package/cjs/UNSAFE_Link.js +3 -3
  459. package/cjs/UNSAFE_ListItemLayout.js +10 -10
  460. package/cjs/UNSAFE_ListView.js +24 -24
  461. package/cjs/UNSAFE_LiveRegion.js +2 -2
  462. package/cjs/UNSAFE_LiveRegion.js.map +1 -1
  463. package/cjs/UNSAFE_LoadMoreCollection.js +3 -3
  464. package/cjs/UNSAFE_Menu.js +15 -15
  465. package/cjs/UNSAFE_MessageBanner.js +30 -30
  466. package/cjs/UNSAFE_MessageToast.js +33 -33
  467. package/cjs/UNSAFE_MeterBar.js +49 -49
  468. package/cjs/UNSAFE_MeterBar.js.map +1 -1
  469. package/cjs/UNSAFE_MeterCircle.js +7 -7
  470. package/cjs/UNSAFE_Modal.js +7 -7
  471. package/cjs/UNSAFE_NumberInputText.js +39 -39
  472. package/cjs/UNSAFE_PrefixSuffix.js +10 -10
  473. package/cjs/UNSAFE_PrefixSuffix.js.map +1 -1
  474. package/cjs/UNSAFE_ProgressBar.js +9 -9
  475. package/cjs/UNSAFE_ProgressBar.js.map +1 -1
  476. package/cjs/UNSAFE_ProgressCircle.js +9 -9
  477. package/cjs/UNSAFE_ProgressCircle.js.map +1 -1
  478. package/cjs/UNSAFE_RatingGauge.js +26 -26
  479. package/cjs/UNSAFE_RatingGauge.js.map +1 -1
  480. package/cjs/UNSAFE_SelectMultiple.js +47 -47
  481. package/cjs/UNSAFE_SelectSingle.js +46 -46
  482. package/cjs/UNSAFE_Selector.js +22 -22
  483. package/cjs/UNSAFE_Selector.js.map +1 -1
  484. package/cjs/UNSAFE_Skeleton.js +8 -8
  485. package/cjs/UNSAFE_Spacer.js +10 -10
  486. package/cjs/UNSAFE_SplitMenuButton.js +22 -22
  487. package/cjs/UNSAFE_Text.js +8 -8
  488. package/cjs/UNSAFE_TextArea.js +39 -39
  489. package/cjs/UNSAFE_TextAreaAutosize.js +40 -40
  490. package/cjs/UNSAFE_TextField.js +35 -35
  491. package/cjs/UNSAFE_TextField.js.map +1 -1
  492. package/cjs/UNSAFE_ThemedIcons.js +9 -9
  493. package/cjs/UNSAFE_UserAssistance.js +41 -41
  494. package/cjs/UNSAFE_UserAssistance.js.map +1 -1
  495. package/cjs/UNSAFE_View.js +9 -9
  496. package/cjs/UNSAFE_VirtualizedListView.js +24 -24
  497. package/cjs/UNSAFE_WindowOverlay.js +1 -1
  498. package/cjs/{VirtualizedCollection-25a65ecb.js → VirtualizedCollection-c710b854.js} +3 -3
  499. package/cjs/{VirtualizedCollection-25a65ecb.js.map → VirtualizedCollection-c710b854.js.map} +1 -1
  500. package/cjs/{VirtualizedListView-23cde093.js → VirtualizedListView-65256b0a.js} +3 -3
  501. package/cjs/{VirtualizedListView-23cde093.js.map → VirtualizedListView-65256b0a.js.map} +1 -1
  502. package/cjs/{_curry1-8041d5c4.js → _curry1-bf67b632.js} +2 -2
  503. package/cjs/{_curry1-8041d5c4.js.map → _curry1-bf67b632.js.map} +1 -1
  504. package/cjs/{_curry2-314ae9ee.js → _curry2-7aab976d.js} +3 -3
  505. package/cjs/{_curry2-314ae9ee.js.map → _curry2-7aab976d.js.map} +1 -1
  506. package/cjs/{_curry3-9710c9f6.js → _curry3-9bb3e2a9.js} +4 -4
  507. package/cjs/{_curry3-9710c9f6.js.map → _curry3-9bb3e2a9.js.map} +1 -1
  508. package/cjs/{_has-fbcc6ed0.js → _has-eba0409e.js} +3 -3
  509. package/cjs/{_has-fbcc6ed0.js.map → _has-eba0409e.js.map} +1 -1
  510. package/cjs/{classNames-c244c6b5.js → classNames-d9ff1188.js} +2 -2
  511. package/cjs/{classNames-c244c6b5.js.map → classNames-d9ff1188.js.map} +1 -1
  512. package/cjs/{clientHints-7abe2495.js → clientHints-769016be.js} +2 -2
  513. package/cjs/{clientHints-7abe2495.js.map → clientHints-769016be.js.map} +1 -1
  514. package/cjs/{flexbox-d7555029.js → flexbox-de6ca4d3.js} +10 -10
  515. package/cjs/{flexbox-d7555029.js.map → flexbox-de6ca4d3.js.map} +1 -1
  516. package/cjs/{flexitem-d9e85c86.js → flexitem-5b4f11b0.js} +10 -10
  517. package/cjs/{flexitem-d9e85c86.js.map → flexitem-5b4f11b0.js.map} +1 -1
  518. package/cjs/hooks/PRIVATE_useCollectionFocusRing.js +1 -1
  519. package/cjs/hooks/PRIVATE_useCurrentKey.js +1 -1
  520. package/cjs/hooks/PRIVATE_useDvtMeterEvents.js +6 -6
  521. package/cjs/hooks/PRIVATE_useItemAction.js +1 -1
  522. package/cjs/hooks/PRIVATE_useMessagesFocusManager.js +1 -1
  523. package/cjs/hooks/PRIVATE_useSelection.js +1 -1
  524. package/cjs/hooks/PRIVATE_useSingleSelection.js +2 -2
  525. package/cjs/hooks/PRIVATE_useTabbableModeSet.js +1 -1
  526. package/cjs/hooks/UNSAFE_useActionable.js +1 -1
  527. package/cjs/hooks/UNSAFE_useActive.js +1 -1
  528. package/cjs/hooks/UNSAFE_useAnimation.js +3 -3
  529. package/cjs/hooks/UNSAFE_useBreakpointValues.js +1 -1
  530. package/cjs/hooks/UNSAFE_useBreakpoints.js +1 -1
  531. package/cjs/hooks/UNSAFE_useClearIcon.js +1 -1
  532. package/cjs/hooks/UNSAFE_useColorScheme.js +1 -1
  533. package/cjs/hooks/UNSAFE_useContainerBreakpointValues.js +1 -1
  534. package/cjs/hooks/UNSAFE_useContainerBreakpoints.js +1 -1
  535. package/cjs/hooks/UNSAFE_useCurrentValueReducer.js +1 -1
  536. package/cjs/hooks/UNSAFE_useDebounce.js +1 -1
  537. package/cjs/hooks/UNSAFE_useFloating.js +2 -2
  538. package/cjs/hooks/UNSAFE_useFocus.js +1 -1
  539. package/cjs/hooks/UNSAFE_useFocusWithin.js +2 -2
  540. package/cjs/hooks/UNSAFE_useFocusableTextField.js +3 -3
  541. package/cjs/hooks/UNSAFE_useFormContext.js +1 -1
  542. package/cjs/hooks/UNSAFE_useFormFieldContext.js +1 -1
  543. package/cjs/hooks/UNSAFE_useFormVariantContext.js +1 -1
  544. package/cjs/hooks/UNSAFE_useHover.js +1 -1
  545. package/cjs/hooks/UNSAFE_useId.js +1 -1
  546. package/cjs/hooks/UNSAFE_useLengthFilter.js +1 -1
  547. package/cjs/hooks/UNSAFE_useLoadingIndicatorTimer.js +1 -1
  548. package/cjs/hooks/UNSAFE_useLongPress.js +1 -1
  549. package/cjs/hooks/UNSAFE_useMessagesContext.js +1 -1
  550. package/cjs/hooks/UNSAFE_useOutsideClick.js +1 -1
  551. package/cjs/hooks/UNSAFE_usePan.js +1 -1
  552. package/cjs/hooks/UNSAFE_usePrefixSuffix.js +2 -2
  553. package/cjs/hooks/UNSAFE_usePress.js +1 -1
  554. package/cjs/hooks/UNSAFE_useScale.js +1 -1
  555. package/cjs/hooks/UNSAFE_useSwipe.js +1 -1
  556. package/cjs/hooks/UNSAFE_useTabbableMode.js +1 -1
  557. package/cjs/hooks/UNSAFE_useTap.js +1 -1
  558. package/cjs/hooks/UNSAFE_useTextField.js +1 -1
  559. package/cjs/hooks/UNSAFE_useTextFieldInputHandlers.js +2 -2
  560. package/cjs/hooks/UNSAFE_useTheme.js +1 -1
  561. package/cjs/hooks/UNSAFE_useTimer.js +1 -1
  562. package/cjs/hooks/UNSAFE_useToggle.js +1 -1
  563. package/cjs/hooks/UNSAFE_useTooltip.js +10 -10
  564. package/cjs/hooks/UNSAFE_useTooltip.js.map +1 -1
  565. package/cjs/hooks/UNSAFE_useTouch.js +1 -1
  566. package/cjs/hooks/UNSAFE_useTranslationBundle.js +1 -1
  567. package/cjs/hooks/UNSAFE_useUncontrolledState.js +1 -1
  568. package/cjs/hooks/UNSAFE_useUser.js +1 -1
  569. package/cjs/hooks/UNSAFE_useViewportIntersect.js +1 -1
  570. package/cjs/{index-68cf332c.js → index-1896f42d.js} +3 -3
  571. package/cjs/{index-68cf332c.js.map → index-1896f42d.js.map} +1 -1
  572. package/cjs/{index-e0e5d9e7.js → index-9ceb8dc7.js} +3 -3
  573. package/cjs/{index-e0e5d9e7.js.map → index-9ceb8dc7.js.map} +1 -1
  574. package/cjs/{index-9fff364f.js → index-d6689974.js} +2 -2
  575. package/cjs/{index-9fff364f.js.map → index-d6689974.js.map} +1 -1
  576. package/cjs/{keys-b25c25eb.js → keys-d802590e.js} +4 -4
  577. package/cjs/{keys-b25c25eb.js.map → keys-d802590e.js.map} +1 -1
  578. package/cjs/{listViewSelectionTests-8d288d41.js → listViewSelectionTests-2aa6aa20.js} +4 -4
  579. package/cjs/{listViewSelectionTests-8d288d41.js.map → listViewSelectionTests-2aa6aa20.js.map} +1 -1
  580. package/cjs/{listViewTabbableModeTests-7f85f29a.js → listViewTabbableModeTests-7d116923.js} +4 -4
  581. package/cjs/{listViewTabbableModeTests-7f85f29a.js.map → listViewTabbableModeTests-7d116923.js.map} +1 -1
  582. package/cjs/{listViewTestFixtures-cad51293.js → listViewTestFixtures-cfb634b1.js} +2 -2
  583. package/cjs/{listViewTestFixtures-cad51293.js.map → listViewTestFixtures-cfb634b1.js.map} +1 -1
  584. package/cjs/{menuTestsUtils-793c53c2.js → menuTestsUtils-50c22440.js} +2 -2
  585. package/cjs/{menuTestsUtils-793c53c2.js.map → menuTestsUtils-50c22440.js.map} +1 -1
  586. package/cjs/resources/nls/ar/bundle.js +1 -1
  587. package/cjs/resources/nls/ar-XB/bundle.js +1 -1
  588. package/cjs/resources/nls/bg/bundle.js +1 -1
  589. package/cjs/resources/nls/bs/bundle.js +1 -1
  590. package/cjs/resources/nls/bs-Cyrl/bundle.js +1 -1
  591. package/cjs/resources/nls/bundle.js +1 -1
  592. package/cjs/resources/nls/cs/bundle.js +1 -1
  593. package/cjs/resources/nls/da/bundle.js +1 -1
  594. package/cjs/resources/nls/de/bundle.js +1 -1
  595. package/cjs/resources/nls/el/bundle.js +1 -1
  596. package/cjs/resources/nls/en/bundle.js +1 -1
  597. package/cjs/resources/nls/en-XA/bundle.js +1 -1
  598. package/cjs/resources/nls/en-XC/bundle.js +1 -1
  599. package/cjs/resources/nls/es/bundle.js +1 -1
  600. package/cjs/resources/nls/et/bundle.js +1 -1
  601. package/cjs/resources/nls/fi/bundle.js +1 -1
  602. package/cjs/resources/nls/fr/bundle.js +1 -1
  603. package/cjs/resources/nls/fr-CA/bundle.js +1 -1
  604. package/cjs/resources/nls/he/bundle.js +1 -1
  605. package/cjs/resources/nls/hr/bundle.js +1 -1
  606. package/cjs/resources/nls/hu/bundle.js +1 -1
  607. package/cjs/resources/nls/is/bundle.js +1 -1
  608. package/cjs/resources/nls/it/bundle.js +1 -1
  609. package/cjs/resources/nls/ja/bundle.js +1 -1
  610. package/cjs/resources/nls/ko/bundle.js +1 -1
  611. package/cjs/resources/nls/lt/bundle.js +1 -1
  612. package/cjs/resources/nls/lv/bundle.js +1 -1
  613. package/cjs/resources/nls/ms/bundle.js +1 -1
  614. package/cjs/resources/nls/nl/bundle.js +1 -1
  615. package/cjs/resources/nls/no/bundle.js +1 -1
  616. package/cjs/resources/nls/pl/bundle.js +1 -1
  617. package/cjs/resources/nls/pt/bundle.js +1 -1
  618. package/cjs/resources/nls/pt-PT/bundle.js +1 -1
  619. package/cjs/resources/nls/ro/bundle.js +1 -1
  620. package/cjs/resources/nls/ru/bundle.js +1 -1
  621. package/cjs/resources/nls/sk/bundle.js +1 -1
  622. package/cjs/resources/nls/sl/bundle.js +1 -1
  623. package/cjs/resources/nls/sr/bundle.js +1 -1
  624. package/cjs/resources/nls/sr-Latn/bundle.js +1 -1
  625. package/cjs/resources/nls/supportedLocales.js +1 -1
  626. package/cjs/resources/nls/sv/bundle.js +1 -1
  627. package/cjs/resources/nls/th/bundle.js +1 -1
  628. package/cjs/resources/nls/tr/bundle.js +1 -1
  629. package/cjs/resources/nls/uk/bundle.js +1 -1
  630. package/cjs/resources/nls/vi/bundle.js +1 -1
  631. package/cjs/resources/nls/zh-Hans/bundle.js +1 -1
  632. package/cjs/resources/nls/zh-Hant/bundle.js +1 -1
  633. package/cjs/{stringUtils-c1b20b4c.js → stringUtils-8504b445.js} +2 -2
  634. package/cjs/{stringUtils-c1b20b4c.js.map → stringUtils-8504b445.js.map} +1 -1
  635. package/cjs/{testHelpers-6b988fc9.js → testHelpers-082f70b3.js} +2 -2
  636. package/cjs/{testHelpers-6b988fc9.js.map → testHelpers-082f70b3.js.map} +1 -1
  637. package/cjs/translationBundle.js +1 -1
  638. package/cjs/{tslib.es6-3a9a7bce.js → tslib.es6-9f910ae4.js} +2 -2
  639. package/cjs/{tslib.es6-3a9a7bce.js.map → tslib.es6-9f910ae4.js.map} +1 -1
  640. package/cjs/{useAnimation-e9cefe9a.js → useAnimation-744ceb4b.js} +3 -3
  641. package/cjs/{useAnimation-e9cefe9a.js.map → useAnimation-744ceb4b.js.map} +1 -1
  642. package/cjs/{useFocusWithin-9463bf9c.js → useFocusWithin-1f6549f5.js} +2 -2
  643. package/cjs/{useFocusWithin-9463bf9c.js.map → useFocusWithin-1f6549f5.js.map} +1 -1
  644. package/cjs/{useSingleSelection-c8ec4756.js → useSingleSelection-34133303.js} +2 -2
  645. package/cjs/{useSingleSelection-c8ec4756.js.map → useSingleSelection-34133303.js.map} +1 -1
  646. package/cjs/utils/PRIVATE_clientHints.js +2 -2
  647. package/cjs/utils/PRIVATE_collectionUtils.js +1 -1
  648. package/cjs/utils/PRIVATE_dvtTestUtils.js +1 -1
  649. package/cjs/utils/PRIVATE_floatingUtils.js +1 -1
  650. package/cjs/utils/PRIVATE_meterUtils.js +1 -1
  651. package/cjs/utils/PRIVATE_refUtils.js +1 -1
  652. package/cjs/utils/PRIVATE_tabbableUtils.js +4 -4
  653. package/cjs/utils/PRIVATE_timer.js +1 -1
  654. package/cjs/utils/UNSAFE_arrayUtils.js +1 -1
  655. package/cjs/utils/UNSAFE_attributeUtils.js +1 -1
  656. package/cjs/utils/UNSAFE_classNames.js +2 -2
  657. package/cjs/utils/UNSAFE_componentUtils.js +1 -1
  658. package/cjs/utils/UNSAFE_dataProvider.js +1 -1
  659. package/cjs/utils/UNSAFE_filePickerUtils.js +1 -1
  660. package/cjs/utils/UNSAFE_getLocale.js +1 -1
  661. package/cjs/utils/UNSAFE_interpolations/aria.js +1 -1
  662. package/cjs/utils/UNSAFE_interpolations/borders.js +1 -1
  663. package/cjs/utils/UNSAFE_interpolations/boxalignment.js +19 -19
  664. package/cjs/utils/UNSAFE_interpolations/boxalignment.js.map +1 -1
  665. package/cjs/utils/UNSAFE_interpolations/colors.js +1 -1
  666. package/cjs/utils/UNSAFE_interpolations/dimensions.js +2 -2
  667. package/cjs/utils/UNSAFE_interpolations/flexbox.js +5 -5
  668. package/cjs/utils/UNSAFE_interpolations/flexitem.js +5 -5
  669. package/cjs/utils/UNSAFE_interpolations/grid.js +1 -1
  670. package/cjs/utils/UNSAFE_interpolations/griditem.js +1 -1
  671. package/cjs/utils/UNSAFE_interpolations/padding.js +1 -1
  672. package/cjs/utils/UNSAFE_interpolations/text.js +7 -7
  673. package/cjs/utils/UNSAFE_interpolations/text.js.map +1 -1
  674. package/cjs/utils/UNSAFE_keys.js +1 -1
  675. package/cjs/utils/UNSAFE_lengthFilter.js +1 -1
  676. package/cjs/utils/UNSAFE_logger.js +3 -3
  677. package/cjs/utils/UNSAFE_matchTranslationBundle.js +1 -1
  678. package/cjs/utils/UNSAFE_mergeInterpolations.js +6 -6
  679. package/cjs/utils/UNSAFE_mergeProps.js +1 -1
  680. package/cjs/utils/UNSAFE_meterTypes.js +1 -1
  681. package/cjs/utils/UNSAFE_roles.js +1 -1
  682. package/cjs/utils/UNSAFE_selectUtils.js +1 -1
  683. package/cjs/utils/UNSAFE_size.js +1 -1
  684. package/cjs/utils/UNSAFE_soundUtils.js +1 -1
  685. package/cjs/utils/UNSAFE_stringUtils.js +2 -2
  686. package/cjs/utils/UNSAFE_typeUtils.js +1 -1
  687. package/cjs/utils/UNSAFE_units.js +2 -2
  688. package/cjs/utils/UNSAFE_valueUpdateDetail.js +1 -1
  689. package/es/{ClearIcon-4c7deff5.js → ClearIcon-848af36a.js} +3 -3
  690. package/es/{ClearIcon-4c7deff5.js.map → ClearIcon-848af36a.js.map} +1 -1
  691. package/es/{LoadMoreCollection-8f06717c.js → LoadMoreCollection-ed658347.js} +2 -2
  692. package/es/{LoadMoreCollection-8f06717c.js.map → LoadMoreCollection-ed658347.js.map} +1 -1
  693. package/es/PRIVATE_Collection.js +1 -1
  694. package/es/PRIVATE_List.css +15 -15
  695. package/es/PRIVATE_List.js +24 -24
  696. package/es/PRIVATE_List.js.map +1 -1
  697. package/es/PRIVATE_Message.css +27 -27
  698. package/es/PRIVATE_Message.js +35 -35
  699. package/es/PRIVATE_Message.js.map +1 -1
  700. package/es/PRIVATE_MessageLayer.css +7 -7
  701. package/es/PRIVATE_MessageLayer.js +14 -14
  702. package/es/PRIVATE_MessageLayer.js.map +1 -1
  703. package/es/PRIVATE_Meter.js +2 -2
  704. package/es/PRIVATE_SelectCommon.css +13 -13
  705. package/es/PRIVATE_SelectCommon.js +22 -22
  706. package/es/PRIVATE_SelectCommon.js.map +1 -1
  707. package/es/PRIVATE_TransitionGroup.js +1 -1
  708. package/es/PRIVATE_VirtualizedCollection.js +1 -1
  709. package/es/UNSAFE_AspectRatio.css +1 -1
  710. package/es/UNSAFE_AspectRatio.js +7 -7
  711. package/es/UNSAFE_AspectRatio.js.map +1 -1
  712. package/es/UNSAFE_Avatar.css +8 -8
  713. package/es/UNSAFE_Avatar.js +10 -10
  714. package/es/UNSAFE_Avatar.js.map +1 -1
  715. package/es/UNSAFE_Badge.css +13 -13
  716. package/es/UNSAFE_Badge.js +14 -14
  717. package/es/UNSAFE_Badge.js.map +1 -1
  718. package/es/UNSAFE_BaseButton.css +15 -15
  719. package/es/UNSAFE_BaseButton.js +21 -21
  720. package/es/UNSAFE_BaseButton.js.map +1 -1
  721. package/es/UNSAFE_Button.css +8 -8
  722. package/es/UNSAFE_Button.js +14 -14
  723. package/es/UNSAFE_Button.js.map +1 -1
  724. package/es/UNSAFE_Center.js +7 -7
  725. package/es/UNSAFE_Chip.css +7 -7
  726. package/es/UNSAFE_Chip.js +8 -8
  727. package/es/UNSAFE_Chip.js.map +1 -1
  728. package/es/UNSAFE_Collapsible.css +8 -8
  729. package/es/UNSAFE_Collapsible.js +16 -16
  730. package/es/UNSAFE_Collapsible.js.map +1 -1
  731. package/es/UNSAFE_Collection.js +1 -1
  732. package/es/UNSAFE_ComponentMessage.css +2 -2
  733. package/es/UNSAFE_ComponentMessage.js +10 -10
  734. package/es/UNSAFE_ComponentMessage.js.map +1 -1
  735. package/es/UNSAFE_Divider.css +1 -1
  736. package/es/UNSAFE_Divider.js +6 -6
  737. package/es/UNSAFE_EmptyList.js +1 -1
  738. package/es/UNSAFE_Environment.js +1 -1
  739. package/es/UNSAFE_FilePicker.css +6 -6
  740. package/es/UNSAFE_FilePicker.js +13 -13
  741. package/es/UNSAFE_FilePicker.js.map +1 -1
  742. package/es/UNSAFE_Flex.css +2 -2
  743. package/es/UNSAFE_Flex.js +9 -9
  744. package/es/UNSAFE_Flex.js.map +1 -1
  745. package/es/UNSAFE_Floating.js +2 -2
  746. package/es/UNSAFE_FocusTrap.css +2 -2
  747. package/es/UNSAFE_FocusTrap.js +6 -6
  748. package/es/UNSAFE_FocusTrap.js.map +1 -1
  749. package/es/UNSAFE_Grid.css +1 -1
  750. package/es/UNSAFE_Grid.js +8 -8
  751. package/es/UNSAFE_Heading.css +9 -9
  752. package/es/UNSAFE_Heading.js +16 -16
  753. package/es/UNSAFE_Heading.js.map +1 -1
  754. package/es/UNSAFE_HiddenAccessible.css +1 -1
  755. package/es/UNSAFE_HiddenAccessible.js +2 -2
  756. package/es/UNSAFE_HiddenAccessible.js.map +1 -1
  757. package/es/UNSAFE_HighlightText.css +1 -1
  758. package/es/UNSAFE_HighlightText.js +2 -2
  759. package/es/UNSAFE_Icon.css +21 -21
  760. package/es/UNSAFE_Icon.js +24 -24
  761. package/es/UNSAFE_Icon.js.map +1 -1
  762. package/es/UNSAFE_Icons.js +3 -3
  763. package/es/UNSAFE_Indexer.css +7 -7
  764. package/es/UNSAFE_Indexer.js +15 -15
  765. package/es/UNSAFE_Indexer.js.map +1 -1
  766. package/es/UNSAFE_InputPassword.css +1 -1
  767. package/es/UNSAFE_InputPassword.js +10 -10
  768. package/es/UNSAFE_InputText.css +1 -1
  769. package/es/UNSAFE_InputText.js +9 -9
  770. package/es/UNSAFE_Label.css +13 -13
  771. package/es/UNSAFE_Label.js +15 -15
  772. package/es/UNSAFE_Label.js.map +1 -1
  773. package/es/UNSAFE_LabelValueLayout.css +9 -9
  774. package/es/UNSAFE_LabelValueLayout.js +16 -16
  775. package/es/UNSAFE_LabelValueLayout.js.map +1 -1
  776. package/es/UNSAFE_Layer.js +1 -1
  777. package/es/UNSAFE_Link.css +5 -5
  778. package/es/UNSAFE_Link.js +6 -6
  779. package/es/UNSAFE_Link.js.map +1 -1
  780. package/es/UNSAFE_ListItemLayout.css +9 -9
  781. package/es/UNSAFE_ListItemLayout.js +16 -16
  782. package/es/UNSAFE_ListItemLayout.js.map +1 -1
  783. package/es/UNSAFE_ListView.js +9 -9
  784. package/es/UNSAFE_LiveRegion.css +1 -1
  785. package/es/UNSAFE_LiveRegion.js +2 -2
  786. package/es/UNSAFE_LiveRegion.js.map +1 -1
  787. package/es/UNSAFE_LoadMoreCollection.js +2 -2
  788. package/es/UNSAFE_Menu.css +17 -17
  789. package/es/UNSAFE_Menu.js +24 -24
  790. package/es/UNSAFE_Menu.js.map +1 -1
  791. package/es/UNSAFE_MessageBanner.js +8 -8
  792. package/es/UNSAFE_MessageToast.css +1 -1
  793. package/es/UNSAFE_MessageToast.js +9 -9
  794. package/es/UNSAFE_MeterBar.css +43 -43
  795. package/es/UNSAFE_MeterBar.js +46 -46
  796. package/es/UNSAFE_MeterBar.js.map +1 -1
  797. package/es/UNSAFE_MeterCircle.css +46 -46
  798. package/es/UNSAFE_MeterCircle.js +49 -49
  799. package/es/UNSAFE_MeterCircle.js.map +1 -1
  800. package/es/UNSAFE_Modal.css +3 -3
  801. package/es/UNSAFE_Modal.js +7 -7
  802. package/es/UNSAFE_NumberInputText.js +8 -8
  803. package/es/UNSAFE_PrefixSuffix.css +8 -8
  804. package/es/UNSAFE_PrefixSuffix.js +9 -9
  805. package/es/UNSAFE_PrefixSuffix.js.map +1 -1
  806. package/es/UNSAFE_ProgressBar.css +6 -6
  807. package/es/UNSAFE_ProgressBar.js +8 -8
  808. package/es/UNSAFE_ProgressBar.js.map +1 -1
  809. package/es/UNSAFE_ProgressCircle.css +6 -6
  810. package/es/UNSAFE_ProgressCircle.js +8 -8
  811. package/es/UNSAFE_ProgressCircle.js.map +1 -1
  812. package/es/UNSAFE_RatingGauge.css +20 -20
  813. package/es/UNSAFE_RatingGauge.js +23 -23
  814. package/es/UNSAFE_RatingGauge.js.map +1 -1
  815. package/es/UNSAFE_SelectMultiple.css +1 -1
  816. package/es/UNSAFE_SelectMultiple.js +10 -10
  817. package/es/UNSAFE_SelectMultiple.js.map +1 -1
  818. package/es/UNSAFE_SelectSingle.js +9 -9
  819. package/es/UNSAFE_Selector.css +5 -5
  820. package/es/UNSAFE_Selector.js +13 -13
  821. package/es/UNSAFE_Selector.js.map +1 -1
  822. package/es/UNSAFE_Skeleton.css +1 -1
  823. package/es/UNSAFE_Skeleton.js +7 -7
  824. package/es/UNSAFE_Spacer.js +7 -7
  825. package/es/UNSAFE_SplitMenuButton.css +5 -5
  826. package/es/UNSAFE_SplitMenuButton.js +12 -12
  827. package/es/UNSAFE_SplitMenuButton.js.map +1 -1
  828. package/es/UNSAFE_Text.css +25 -25
  829. package/es/UNSAFE_Text.js +31 -31
  830. package/es/UNSAFE_Text.js.map +1 -1
  831. package/es/UNSAFE_TextArea.css +3 -3
  832. package/es/UNSAFE_TextArea.js +11 -11
  833. package/es/UNSAFE_TextArea.js.map +1 -1
  834. package/es/UNSAFE_TextAreaAutosize.js +8 -8
  835. package/es/UNSAFE_TextField.css +58 -58
  836. package/es/UNSAFE_TextField.js +65 -65
  837. package/es/UNSAFE_TextField.js.map +1 -1
  838. package/es/UNSAFE_ThemedIcons.js +3 -3
  839. package/es/UNSAFE_UserAssistance.css +8 -8
  840. package/es/UNSAFE_UserAssistance.js +16 -16
  841. package/es/UNSAFE_UserAssistance.js.map +1 -1
  842. package/es/UNSAFE_View.js +7 -7
  843. package/es/UNSAFE_VirtualizedListView.js +9 -9
  844. package/es/UNSAFE_WindowOverlay.js +1 -1
  845. package/es/{_curry1-67b0910f.js → _curry1-4510e9ba.js} +2 -2
  846. package/es/{_curry1-67b0910f.js.map → _curry1-4510e9ba.js.map} +1 -1
  847. package/es/{_curry2-6a92c5cc.js → _curry2-429608f9.js} +3 -3
  848. package/es/{_curry2-6a92c5cc.js.map → _curry2-429608f9.js.map} +1 -1
  849. package/es/{_curry3-a2537ff3.js → _curry3-080a03b5.js} +4 -4
  850. package/es/{_curry3-a2537ff3.js.map → _curry3-080a03b5.js.map} +1 -1
  851. package/es/{_has-37434ea6.js → _has-89f999a2.js} +3 -3
  852. package/es/{_has-37434ea6.js.map → _has-89f999a2.js.map} +1 -1
  853. package/es/hooks/PRIVATE_useCollectionFocusRing.js +1 -1
  854. package/es/hooks/PRIVATE_useCurrentKey.js +1 -1
  855. package/es/hooks/PRIVATE_useDvtMeterEvents.js +3 -3
  856. package/es/hooks/PRIVATE_useItemAction.js +1 -1
  857. package/es/hooks/PRIVATE_useMessagesFocusManager.js +1 -1
  858. package/es/hooks/PRIVATE_useSelection.js +1 -1
  859. package/es/hooks/PRIVATE_useSingleSelection.js +2 -2
  860. package/es/hooks/PRIVATE_useTabbableModeSet.js +1 -1
  861. package/es/hooks/UNSAFE_useActionable.js +1 -1
  862. package/es/hooks/UNSAFE_useActive.js +1 -1
  863. package/es/hooks/UNSAFE_useAnimation.js +2 -2
  864. package/es/hooks/UNSAFE_useBreakpointValues.js +1 -1
  865. package/es/hooks/UNSAFE_useBreakpoints.js +1 -1
  866. package/es/hooks/UNSAFE_useClearIcon.js +1 -1
  867. package/es/hooks/UNSAFE_useColorScheme.js +1 -1
  868. package/es/hooks/UNSAFE_useContainerBreakpointValues.js +1 -1
  869. package/es/hooks/UNSAFE_useContainerBreakpoints.js +1 -1
  870. package/es/hooks/UNSAFE_useCurrentValueReducer.js +1 -1
  871. package/es/hooks/UNSAFE_useDebounce.js +1 -1
  872. package/es/hooks/UNSAFE_useFloating.js +2 -2
  873. package/es/hooks/UNSAFE_useFocus.js +1 -1
  874. package/es/hooks/UNSAFE_useFocusWithin.js +1 -1
  875. package/es/hooks/UNSAFE_useFocusableTextField.js +2 -2
  876. package/es/hooks/UNSAFE_useFormContext.js +1 -1
  877. package/es/hooks/UNSAFE_useFormFieldContext.js +1 -1
  878. package/es/hooks/UNSAFE_useFormVariantContext.js +1 -1
  879. package/es/hooks/UNSAFE_useHover.js +1 -1
  880. package/es/hooks/UNSAFE_useId.js +1 -1
  881. package/es/hooks/UNSAFE_useLengthFilter.js +1 -1
  882. package/es/hooks/UNSAFE_useLoadingIndicatorTimer.js +1 -1
  883. package/es/hooks/UNSAFE_useLongPress.js +1 -1
  884. package/es/hooks/UNSAFE_useMessagesContext.js +1 -1
  885. package/es/hooks/UNSAFE_useOutsideClick.js +1 -1
  886. package/es/hooks/UNSAFE_usePan.js +1 -1
  887. package/es/hooks/UNSAFE_usePrefixSuffix.js +1 -1
  888. package/es/hooks/UNSAFE_usePress.js +1 -1
  889. package/es/hooks/UNSAFE_useScale.js +1 -1
  890. package/es/hooks/UNSAFE_useSwipe.js +1 -1
  891. package/es/hooks/UNSAFE_useTabbableMode.js +1 -1
  892. package/es/hooks/UNSAFE_useTap.js +1 -1
  893. package/es/hooks/UNSAFE_useTextField.js +1 -1
  894. package/es/hooks/UNSAFE_useTextFieldInputHandlers.js +1 -1
  895. package/es/hooks/UNSAFE_useTheme.js +1 -1
  896. package/es/hooks/UNSAFE_useTimer.js +1 -1
  897. package/es/hooks/UNSAFE_useToggle.js +1 -1
  898. package/es/hooks/UNSAFE_useTooltip.css +4 -4
  899. package/es/hooks/UNSAFE_useTooltip.js +7 -7
  900. package/es/hooks/UNSAFE_useTooltip.js.map +1 -1
  901. package/es/hooks/UNSAFE_useTouch.js +1 -1
  902. package/es/hooks/UNSAFE_useTranslationBundle.js +1 -1
  903. package/es/hooks/UNSAFE_useUncontrolledState.js +1 -1
  904. package/es/hooks/UNSAFE_useUser.js +1 -1
  905. package/es/hooks/UNSAFE_useViewportIntersect.js +1 -1
  906. package/es/{index-b6450488.js → index-2675270e.js} +2 -2
  907. package/es/{index-b6450488.js.map → index-2675270e.js.map} +1 -1
  908. package/es/{keys-c4b66ad0.js → keys-5c24d71a.js} +4 -4
  909. package/es/{keys-c4b66ad0.js.map → keys-5c24d71a.js.map} +1 -1
  910. package/es/resources/nls/ar/bundle.js +1 -1
  911. package/es/resources/nls/ar-XB/bundle.js +1 -1
  912. package/es/resources/nls/bg/bundle.js +1 -1
  913. package/es/resources/nls/bs/bundle.js +1 -1
  914. package/es/resources/nls/bs-Cyrl/bundle.js +1 -1
  915. package/es/resources/nls/bundle.js +1 -1
  916. package/es/resources/nls/cs/bundle.js +1 -1
  917. package/es/resources/nls/da/bundle.js +1 -1
  918. package/es/resources/nls/de/bundle.js +1 -1
  919. package/es/resources/nls/el/bundle.js +1 -1
  920. package/es/resources/nls/en/bundle.js +1 -1
  921. package/es/resources/nls/en-XA/bundle.js +1 -1
  922. package/es/resources/nls/en-XC/bundle.js +1 -1
  923. package/es/resources/nls/es/bundle.js +1 -1
  924. package/es/resources/nls/et/bundle.js +1 -1
  925. package/es/resources/nls/fi/bundle.js +1 -1
  926. package/es/resources/nls/fr/bundle.js +1 -1
  927. package/es/resources/nls/fr-CA/bundle.js +1 -1
  928. package/es/resources/nls/he/bundle.js +1 -1
  929. package/es/resources/nls/hr/bundle.js +1 -1
  930. package/es/resources/nls/hu/bundle.js +1 -1
  931. package/es/resources/nls/is/bundle.js +1 -1
  932. package/es/resources/nls/it/bundle.js +1 -1
  933. package/es/resources/nls/ja/bundle.js +1 -1
  934. package/es/resources/nls/ko/bundle.js +1 -1
  935. package/es/resources/nls/lt/bundle.js +1 -1
  936. package/es/resources/nls/lv/bundle.js +1 -1
  937. package/es/resources/nls/ms/bundle.js +1 -1
  938. package/es/resources/nls/nl/bundle.js +1 -1
  939. package/es/resources/nls/no/bundle.js +1 -1
  940. package/es/resources/nls/pl/bundle.js +1 -1
  941. package/es/resources/nls/pt/bundle.js +1 -1
  942. package/es/resources/nls/pt-PT/bundle.js +1 -1
  943. package/es/resources/nls/ro/bundle.js +1 -1
  944. package/es/resources/nls/ru/bundle.js +1 -1
  945. package/es/resources/nls/sk/bundle.js +1 -1
  946. package/es/resources/nls/sl/bundle.js +1 -1
  947. package/es/resources/nls/sr/bundle.js +1 -1
  948. package/es/resources/nls/sr-Latn/bundle.js +1 -1
  949. package/es/resources/nls/supportedLocales.js +1 -1
  950. package/es/resources/nls/sv/bundle.js +1 -1
  951. package/es/resources/nls/th/bundle.js +1 -1
  952. package/es/resources/nls/tr/bundle.js +1 -1
  953. package/es/resources/nls/uk/bundle.js +1 -1
  954. package/es/resources/nls/vi/bundle.js +1 -1
  955. package/es/resources/nls/zh-Hans/bundle.js +1 -1
  956. package/es/resources/nls/zh-Hant/bundle.js +1 -1
  957. package/es/translationBundle.js +1 -1
  958. package/es/{tslib.es6-7113fc10.js → tslib.es6-dd5b5d91.js} +2 -2
  959. package/es/{tslib.es6-7113fc10.js.map → tslib.es6-dd5b5d91.js.map} +1 -1
  960. package/es/{useSingleSelection-e2b693b8.js → useSingleSelection-b82a9c0d.js} +2 -2
  961. package/es/{useSingleSelection-e2b693b8.js.map → useSingleSelection-b82a9c0d.js.map} +1 -1
  962. package/es/utils/PRIVATE_clientHints.js +1 -1
  963. package/es/utils/PRIVATE_collectionUtils.js +1 -1
  964. package/es/utils/PRIVATE_dvtTestUtils.js +1 -1
  965. package/es/utils/PRIVATE_floatingUtils.js +1 -1
  966. package/es/utils/PRIVATE_meterUtils.js +1 -1
  967. package/es/utils/PRIVATE_refUtils.js +1 -1
  968. package/es/utils/PRIVATE_tabbableUtils.js +4 -4
  969. package/es/utils/PRIVATE_timer.js +1 -1
  970. package/es/utils/UNSAFE_arrayUtils.js +1 -1
  971. package/es/utils/UNSAFE_attributeUtils.js +1 -1
  972. package/es/utils/UNSAFE_classNames.js +1 -1
  973. package/es/utils/UNSAFE_componentUtils.js +1 -1
  974. package/es/utils/UNSAFE_dataProvider.js +1 -1
  975. package/es/utils/UNSAFE_filePickerUtils.js +1 -1
  976. package/es/utils/UNSAFE_getLocale.js +1 -1
  977. package/es/utils/UNSAFE_interpolations/aria.js +1 -1
  978. package/es/utils/UNSAFE_interpolations/borders.js +1 -1
  979. package/es/utils/UNSAFE_interpolations/boxalignment.css +15 -15
  980. package/es/utils/UNSAFE_interpolations/boxalignment.js +19 -19
  981. package/es/utils/UNSAFE_interpolations/boxalignment.js.map +1 -1
  982. package/es/utils/UNSAFE_interpolations/colors.js +1 -1
  983. package/es/utils/UNSAFE_interpolations/dimensions.js +2 -2
  984. package/es/utils/UNSAFE_interpolations/flexbox.css +7 -7
  985. package/es/utils/UNSAFE_interpolations/flexbox.js +11 -11
  986. package/es/utils/UNSAFE_interpolations/flexbox.js.map +1 -1
  987. package/es/utils/UNSAFE_interpolations/flexitem.css +7 -7
  988. package/es/utils/UNSAFE_interpolations/flexitem.js +11 -11
  989. package/es/utils/UNSAFE_interpolations/flexitem.js.map +1 -1
  990. package/es/utils/UNSAFE_interpolations/grid.js +1 -1
  991. package/es/utils/UNSAFE_interpolations/griditem.js +1 -1
  992. package/es/utils/UNSAFE_interpolations/padding.js +1 -1
  993. package/es/utils/UNSAFE_interpolations/text.css +3 -3
  994. package/es/utils/UNSAFE_interpolations/text.js +7 -7
  995. package/es/utils/UNSAFE_interpolations/text.js.map +1 -1
  996. package/es/utils/UNSAFE_keys.js +1 -1
  997. package/es/utils/UNSAFE_lengthFilter.js +1 -1
  998. package/es/utils/UNSAFE_logger.js +3 -3
  999. package/es/utils/UNSAFE_matchTranslationBundle.js +1 -1
  1000. package/es/utils/UNSAFE_mergeInterpolations.js +5 -5
  1001. package/es/utils/UNSAFE_mergeProps.js +1 -1
  1002. package/es/utils/UNSAFE_meterTypes.js +1 -1
  1003. package/es/utils/UNSAFE_roles.js +1 -1
  1004. package/es/utils/UNSAFE_selectUtils.js +1 -1
  1005. package/es/utils/UNSAFE_size.js +1 -1
  1006. package/es/utils/UNSAFE_soundUtils.js +1 -1
  1007. package/es/utils/UNSAFE_stringUtils.js +1 -1
  1008. package/es/utils/UNSAFE_typeUtils.js +1 -1
  1009. package/es/utils/UNSAFE_units.js +1 -1
  1010. package/es/utils/UNSAFE_valueUpdateDetail.js +1 -1
  1011. package/package.json +1 -1
  1012. package/amd/Badge-64e6fcda.js +0 -2
  1013. package/amd/BaseButton-e1bc5ecf.js +0 -2
  1014. package/amd/Button-b2cfdb96.js +0 -2
  1015. package/amd/Chip-8bc3f2b3.js +0 -2
  1016. package/amd/ComponentMessage-e03ada1f.js +0 -2
  1017. package/amd/ComponentMessageContainer-9215ce8b.js +0 -2
  1018. package/amd/Divider-2c1748b0.js +0 -2
  1019. package/amd/Flex-d51505a6.js +0 -2
  1020. package/amd/FocusTrap-bf73a011.js +0 -2
  1021. package/amd/FormControlUtils-1e2d5800.js +0 -2
  1022. package/amd/Heading-6c8f6318.js +0 -2
  1023. package/amd/HiddenAccessible-7e5881b5.js +0 -2
  1024. package/amd/Icon-e13a0a05.js +0 -2
  1025. package/amd/Indexer-c64c1c3d.js +0 -2
  1026. package/amd/Link-11912f1b.js +0 -2
  1027. package/amd/List-db591b68.js +0 -2
  1028. package/amd/ListItemTextLayout-6c5aa001.js +0 -2
  1029. package/amd/Menu-d9e4a334.js +0 -2
  1030. package/amd/MenuDivider-0fbf7393.js +0 -2
  1031. package/amd/MenuItem-09ddb137.js +0 -2
  1032. package/amd/MessageCloseButton-91b80681.js +0 -2
  1033. package/amd/MessageDetail-b6aa38c5.js +0 -2
  1034. package/amd/MessageLayer-02c10111.js +0 -2
  1035. package/amd/MessageStartIcon-2755fe36.js +0 -2
  1036. package/amd/MessageSummary-7effa6f2.js +0 -2
  1037. package/amd/MessageTimestamp-5bbfed00.js +0 -2
  1038. package/amd/MessageToast-b74f06cc.js +0 -2
  1039. package/amd/MessagesManager-5c36e297.js +0 -2
  1040. package/amd/MeterCircle-952e7f59.js +0 -2
  1041. package/amd/Modal-6fa6b6c6.js +0 -2
  1042. package/amd/ReadonlyTextFieldInput-dea043dd.js +0 -2
  1043. package/amd/SelectMultiple-32a90b41.js +0 -2
  1044. package/amd/Skeleton-aa6570c4.js +0 -2
  1045. package/amd/SplitMenuButton-72b8de27.js +0 -2
  1046. package/amd/Text-781e64c9.js +0 -2
  1047. package/amd/TextArea-89a244ab.js +0 -2
  1048. package/amd/TextFieldInput-40ce4927.js +0 -2
  1049. package/amd/_curry2-4707be52.js +0 -2
  1050. package/amd/_curry3-ccc05acd.js +0 -2
  1051. package/amd/_has-707f8be4.js +0 -2
  1052. package/amd/flexbox-779e73ea.js +0 -2
  1053. package/amd/flexitem-e6a6355c.js +0 -2
@@ -0,0 +1,2 @@
1
+ define(["exports","./tslib.es6-9d88853c","preact/jsx-runtime","./UNSAFE_Button","./index-bb78541d","./UNSAFE_Menu","./UNSAFE_BaseButton","./utils/UNSAFE_classNames","./hooks/UNSAFE_useTabbableMode","./utils/UNSAFE_interpolations/dimensions","./utils/UNSAFE_mergeInterpolations",'module',"preact/compat","preact/hooks","./classNames-f3dd3ee3","./BaseButton-d3a7182f","./Button-af8ce77b","./index-9cd290d0","./Menu-f4102653"],function(e,s,n,a,t,i,l,o,r,c,d,u,b,p,m,j,v,y,f){"use strict";const x="_5e5omo",B="dknfdd",g="d1jve9",h="_28fhxy",N=["embedded","min","noBorderRadiusStart"],_=[...N,"active"],k=["embedded","fill","noBorderRadiusEnd"],A=[...k,"active"],D=[...Object.values(c.dimensionInterpolations)],S=d.mergeInterpolations(D),E=b.forwardRef((e,a)=>{var{children:t,label:i="",variant:l="outlined",isDisabled:o=!1,size:c="md",onAction:d}=e,u=s.__rest(e,["children","label","variant","isDisabled","size","onAction"]);const[b,N]=p.useState(!1),[_,k]=p.useState(!1),A=S(u),{class:D}=A,E=s.__rest(A,["class"]),w=p.useCallback(e=>{" "===e.key||"Enter"===e.key?k(!0):"ArrowDown"==e.key&&(!o&&N(e=>!e),e.preventDefault())},[o,N,k]),F=p.useCallback(e=>{" "!==e.key&&"Enter"!==e.key||(!o&&d&&d(),k(!1))},[o,d,k]),z=p.useCallback(()=>{k(!1)},[k]),I=p.useRef(null);p.useImperativeHandle(a,()=>I.current,[I]);const M=()=>{N(!b)},R=e=>{var s;e.reason,null===(s=I.current)||void 0===s||s.focus(),N(!1)},C=m.classNames([x,o&&B]),$=m.classNames([g]),H=()=>n.jsx(j.BaseButton,Object.assign({elementDetails:{type:"span"},ref:I,isDisabled:o,styling:["container","min"],variant:l,size:c,accessibleLabel:i,ariaRoledescription:"split menu button, press down arrow to invoke menu",ariaExpanded:b},{children:n.jsxs(r.TabbableModeContext.Provider,Object.assign({value:{isTabbable:!1}},{children:[n.jsx(j.BaseButton,Object.assign({elementDetails:{type:"span"},variant:l,styling:U(_),size:c,isDisabled:o,ariaHidden:!0,onAction:d},{children:i})),n.jsx("div",{class:`${C}`}),n.jsx(j.BaseButton,Object.assign({elementDetails:{type:"span"},variant:l,styling:O(b),size:c,isDisabled:o,ariaHidden:!0,onAction:M},{children:n.jsx(v.ButtonLayout,{display:"icons",startIcon:n.jsx(y.SvgIcoNavDown,{}),size:c,styling:"embedded"})}))]}))}));return o?n.jsx("span",Object.assign({role:"toolbar",class:`${$} ${D}`,style:E},{children:H()})):n.jsxs("span",Object.assign({role:"toolbar",class:`${$} ${D}`,style:E,onKeyDown:!o&&w,onKeyUp:F,onBlur:z},{children:[H(),n.jsx(f.Menu,Object.assign({anchorRef:I,isOpen:b,onClose:R},{children:n.jsx("span",Object.assign({className:h},{children:t}))}))]}))});function O(e){return e?_:N}function U(e){return e?A:k}e.SplitMenuButton=E});
2
+ //# sourceMappingURL=SplitMenuButton-da63e0b6.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SplitMenuButton-72b8de27.js","sources":["../../src/UNSAFE_SplitMenuButton/SplitMenuButton.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 { ButtonLayout } from '../UNSAFE_Button';\nimport { NavDownIcon } from '../UNSAFE_ThemedIcons';\nimport { Menu } from '../UNSAFE_Menu';\n\nimport { BaseButton, StylingOptions } from '../UNSAFE_BaseButton';\n\nimport { HTMLAttributesSignalExcluded } from '../utils/UNSAFE_attributeUtils';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport type { DimensionProps } from '../utils/UNSAFE_interpolations/dimensions';\nimport { TabbableModeContext } from '../hooks/UNSAFE_useTabbableMode';\nimport { dimensionInterpolations } from '../utils/UNSAFE_interpolations/dimensions';\nimport { mergeInterpolations } from '../utils/UNSAFE_mergeInterpolations';\n\nimport { cssProps } from '@oracle/oraclejet-cssprops';\n\nimport { ComponentChildren } from 'preact';\nimport { forwardRef, ForwardedRef } from 'preact/compat';\nimport { useCallback, useState, useRef, useImperativeHandle } from 'preact/hooks';\n\ntype IntrinsicProps = Pick<HTMLAttributesSignalExcluded<HTMLElement>, 'title'>;\n\ntype WidthInterpolationProps = Pick<DimensionProps, 'width'>;\n\nexport type Props = IntrinsicProps &\n WidthInterpolationProps & {\n /**\n * children - One or more MenuItems\n */\n children?: ComponentChildren;\n\n /**\n * Specifies that the button element should be disabled.\n */\n isDisabled?: boolean;\n\n /**\n * The label rendered on the action side of the button. Used\n * to identify which child MenuItem action is invoked.\n */\n label?: string;\n\n /**\n * Indicates in what states the button has chrome (background and border).\n * \"outlined\"': \"Outlined buttons are salient, but lighter weight than\n * solid buttons. Outlined buttons are useful for secondary actions.\",\n * \"solid\"': \"Solid buttons stand out, and direct the user's attention to the\n * most important actions in the UI.\",\n * \"callToAction\"': \"A Call To Action (CTA) button guides the user to take or\n * complete the action that is the main goal of the page or page section. There\n * should only be one CTA button on a page at any given time.\",\n \n */\n variant?: 'outlined' | 'solid' | 'callToAction';\n\n /**\n * The size indicates how large the button is rendered: \"sm\", \"md\" (default), \"lg\".\n */\n size?: 'sm' | 'md' | 'lg';\n\n /**\n * Triggered when a button is clicked, whether by keyboard, mouse, or touch events.\n */\n onAction?: () => void;\n };\n\nexport const compStyles = {\n divider: cssProps`${{\n borderTopWidth: '0px',\n borderBottomWidth: '0px',\n borderRightWidth: '0px',\n borderLeftWidth: '1px',\n borderStyle: 'solid',\n height: '100%',\n display: 'inline-flex',\n borderColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-base-button-border-color)'\n }}`,\n\n disabledDivider: cssProps`${{\n borderColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-base-button-border-color-disabled)'\n }}`,\n\n icon: cssProps`${{\n display: 'contents'\n }}`,\n\n root: cssProps`${{\n display: 'inline-block'\n }}`,\n\n childrenMargins: cssProps`${{\n /* @ts-ignore */\n '& > *': {\n marginTop: '0 !important',\n marginBottom: '0 !important',\n marginLeft: '0 !important',\n marginRight: '0 !important'\n }\n }}`\n};\n\nconst menuButtonStyling = ['embedded', 'min', 'noBorderRadiusStart'] as StylingOptions[];\nconst menuButtonActiveStyling = [...menuButtonStyling, 'active'] as StylingOptions[];\n\nconst actionbuttonStyling = ['embedded', 'fill', 'noBorderRadiusEnd'] as StylingOptions[];\nconst actionButtonActiveStyling = [...actionbuttonStyling, 'active'] as StylingOptions[];\n\nconst interpolations = [...Object.values(dimensionInterpolations)];\n\nconst styleInterpolations = mergeInterpolations<DimensionProps>(interpolations);\n\n/**\n * A SplitMenuButton is a combined action and menu button.\n */\nexport const SplitMenuButton = forwardRef(\n (\n {\n children,\n label = '',\n variant = 'outlined',\n isDisabled = false,\n size = 'md',\n onAction,\n ...props\n }: Props,\n ref?: ForwardedRef<HTMLSpanElement>\n ) => {\n const [isMenuOpen, setIsMenuOpen] = useState<boolean>(false);\n const [isActive, setIsActive] = useState<boolean>(false);\n const { class: cls, ...styles } = styleInterpolations(props);\n\n // SPACE or ENTER on root area invokes action, as does CLICK/TAP on LEFT SIDE ACTION AREA\n // DOWN ARROW invokes menu, as does CLICK/TAP on RIGHT SIDE MENU AREA\n const onKeyDown = useCallback(\n (event: KeyboardEvent) => {\n if (event.key === ' ' || event.key === 'Enter') {\n setIsActive(true);\n } else if (event.key == 'ArrowDown') {\n !isDisabled && setIsMenuOpen((menuOpen: boolean) => !menuOpen);\n // Prevent page scroll for down arrow, user definitely wanted to show menu in this case.\n // Don't prevent other keypress defaults, as user may want to hold SPACE down to scroll page.\n event.preventDefault();\n }\n },\n [isDisabled, setIsMenuOpen, setIsActive]\n );\n\n const onKeyUp = useCallback(\n (event: KeyboardEvent) => {\n if (event.key === ' ' || event.key === 'Enter') {\n !isDisabled && onAction && onAction();\n setIsActive(false);\n }\n },\n [isDisabled, onAction, setIsActive]\n );\n\n const onBlur = useCallback(() => {\n setIsActive(false);\n }, [setIsActive]);\n\n const _ref = useRef<HTMLSpanElement>(null);\n useImperativeHandle(ref!, () => _ref.current!, [_ref]);\n\n const menuHandler = () => {\n setIsMenuOpen(!isMenuOpen);\n };\n\n const handleClose = (e: any) => {\n if (e.reason === 'cancel' || 'focusLoss') {\n _ref.current?.focus();\n }\n setIsMenuOpen(false);\n };\n\n const dividerStyles = classNames([\n compStyles.divider,\n isDisabled && compStyles.disabledDivider\n ]);\n\n const rootStyles = classNames([compStyles.root]);\n\n // Using Span for top button allows us to avoid :hover state rendering by\n // taking advantage of :enabled not on spans\n const rootButton = () => {\n return (\n <BaseButton\n elementDetails={{ type: 'span' }}\n ref={\n _ref as ForwardedRef<HTMLButtonElement> &\n ForwardedRef<HTMLAnchorElement> &\n ForwardedRef<HTMLSpanElement>\n }\n isDisabled={isDisabled}\n styling={['container', 'min']}\n variant={variant}\n size={size}\n accessibleLabel={label}\n ariaRoledescription=\"split menu button, press down arrow to invoke menu\"\n ariaExpanded={isMenuOpen}>\n <TabbableModeContext.Provider value={{ isTabbable: false }}>\n <BaseButton\n elementDetails={{ type: 'span' }}\n variant={variant}\n styling={getActionButtonStyling(isActive)}\n size={size}\n isDisabled={isDisabled}\n ariaHidden={true}\n onAction={onAction}>\n {label}\n </BaseButton>\n <div class={`${dividerStyles}`} />\n <BaseButton\n elementDetails={{ type: 'span' }}\n variant={variant}\n styling={getMenuButtonStyling(isMenuOpen)}\n size={size}\n isDisabled={isDisabled}\n ariaHidden={true}\n onAction={menuHandler}>\n <ButtonLayout\n display=\"icons\"\n startIcon={<NavDownIcon />}\n size={size}\n styling=\"embedded\"></ButtonLayout>\n </BaseButton>\n </TabbableModeContext.Provider>\n </BaseButton>\n );\n };\n\n if (isDisabled) {\n return (\n <span role=\"toolbar\" class={`${rootStyles} ${cls}`} style={styles}>\n {rootButton()}\n </span>\n );\n } else {\n return (\n <span\n role=\"toolbar\"\n class={`${rootStyles} ${cls}`}\n style={styles}\n onKeyDown={!isDisabled && onKeyDown}\n onKeyUp={onKeyUp}\n onBlur={onBlur}>\n {rootButton()}\n <Menu anchorRef={_ref} isOpen={isMenuOpen} onClose={handleClose}>\n <span className={compStyles.childrenMargins}>{children}</span>\n </Menu>\n </span>\n );\n }\n }\n);\n\nfunction getMenuButtonStyling(isActive: boolean) {\n return isActive ? menuButtonActiveStyling : menuButtonStyling;\n}\n\nfunction getActionButtonStyling(isActive: boolean) {\n return isActive ? actionButtonActiveStyling : actionbuttonStyling;\n}\n"],"names":["compStyles","menuButtonStyling","menuButtonActiveStyling","actionbuttonStyling","actionButtonActiveStyling","interpolations","Object","values","dimensionInterpolations","styleInterpolations","mergeInterpolations","SplitMenuButton","forwardRef","_a","ref","_b","props","class","cls","styles","__rest","onKeyDown","useCallback","event","key","isDisabled","setIsMenuOpen","menuOpen","onKeyUp","onAction","onBlur","setIsActive","_ref","useRef","useImperativeHandle","current","isMenuOpen","handleClose","e","reason","focus","_jsx","BaseButton","assign","elementDetails","type","styling","variant","size","accessibleLabel","label","ariaRoledescription","ariaExpanded","children","_jsxs","TabbableModeContext","Provider","value","isTabbable","jsx","getActionButtonStyling","isActive","ariaHidden","dividerStyles","getMenuButtonStyling","menuHandler","ButtonLayout","display","startIcon","NavDownIcon","SvgIcoNavDown","role","rootStyles","style","rootButton","Menu","anchorRef","isOpen","onClose","className"],"mappings":"seAwEA,MAAAA,EAAA,SAAAA,EAAA,WAAAA,EAAA,SAAAA,aAmCAC,EAAA,CAAA,WAAA,MAAA,uBACAC,EAAA,IAAAD,EAAA,UAEAE,EAAA,CAAA,WAAA,OAAA,qBACAC,EAAA,IAAAD,EAAA,UAEAE,EAAA,IAAAC,OAAAC,OAAAC,EAAAA,0BAEAC,EAAAC,EAAAA,oBAAAL,GAKAM,EAAAC,EAAAA,WAAA,CAAAC,EAAAC,yNAeIC,EAAAN,EAAAO,IAAAC,MAAAC,GAAAH,EAAAI,EAAAC,EAAAA,OAAAL,EAAA,CAAA,UAIAM,EAAAC,EAAAA,YAAAC,uCAIW,aAAAA,EAAAC,OACLC,GAAAC,EAAAC,IAAAA,iCASNC,EAAAN,EAAAA,YAAAC,oCAGME,GAAAI,GAAAA,qBAONC,EAAAR,EAAAA,YAAA,YAEA,CAAAS,IAEAC,EAAAC,SAAA,MACAC,EAAAA,oBAAApB,EAAA,IAAAkB,EAAAG,QAAA,CAAAH,iBAGEN,GAAAU,IAGFC,EAAAC,UACEA,EAAAC,OACE,QAAA1B,EAAAmB,EAAAG,eAAA,IAAAtB,GAAAA,EAAA2B,+BAMFxC,mCASAyC,MAAAC,EAAAA,WAAApC,OAAAqC,OAAA,CAAAC,eAAA,CAAAC,KAAA,QAAA/B,IAAAkB,EAAAP,WAAAA,EAAAqB,QAAA,CAAA,YAAA,OAAAC,QAAAA,EAAAC,KAAAA,EAAAC,gBAAAC,EAAAC,oBAAA,qDAAAC,aAAAhB,GAAA,CAAAiB,SAAAC,EAAAA,KAAAC,EAAAA,oBAAAC,SAAAlD,OAAAqC,OAAA,CAAAc,MAAA,CAAAC,YAAA,IAAA,CAAAL,SAAA,CAAAZ,EAAAkB,IAAAjB,aAAApC,OAAAqC,OAAA,CAAAC,eAAA,CAAAC,KAAA,QAAAE,QAAAA,EAAAD,QAAAc,EAAAC,GAAAb,KAAAA,EAAAvB,WAAAA,EAAAqC,YAAA,EAAAjC,SAAAA,GAAA,CAAAwB,SAAAH,KAAAT,EAAAkB,IAAA,MAAA,CAAA1C,MAAA,GAAA8C,MAAAtB,EAAAkB,IAAAjB,aAAApC,OAAAqC,OAAA,CAAAC,eAAA,CAAAC,KAAA,QAAAE,QAAAA,EAAAD,QAAAkB,EAAA5B,GAAAY,KAAAA,EAAAvB,WAAAA,EAAAqC,YAAA,EAAAjC,SAAAoC,GAAA,CAAAZ,SAAAZ,EAAAkB,IAAAO,eAAA,CAAAC,QAAA,QAAAC,UAAA3B,EAAAA,IAAA4B,EAAAC,cAAA,IAAAtB,KAAAA,EAAAF,QAAA,uBA8CF,OAAArB,yFAOE6B,OAAA,OAAAhD,OAAAqC,OAAA,CAAA4B,KAAA,UAAAtD,MAAA,GAAAuD,KAAAtD,IAAAuD,MAAAtD,EAAAE,WAAAI,GAAAJ,EAAAO,QAAAA,EAAAE,OAAAA,GAAA,CAAAuB,SAAA,CAAAqB,IAAAjC,EAAAkB,IAAAgB,EAAAA,KAAArE,OAAAqC,OAAA,CAAAiC,UAAA5C,EAAA6C,OAAAzC,EAAA0C,QAAAzC,GAAA,CAAAgB,SAAAZ,EAAAkB,IAAA,OAAArD,OAAAqC,OAAA,CAAAoC,UAAA/E,GAAA,CAAAqD,SAAAA,cAkBN,SAAAW,EAAAH,gBAIA,SAAAD,EAAAC"}
1
+ {"version":3,"file":"SplitMenuButton-da63e0b6.js","sources":["../../src/UNSAFE_SplitMenuButton/SplitMenuButton.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 { ButtonLayout } from '../UNSAFE_Button';\nimport { NavDownIcon } from '../UNSAFE_ThemedIcons';\nimport { Menu } from '../UNSAFE_Menu';\n\nimport { BaseButton, StylingOptions } from '../UNSAFE_BaseButton';\n\nimport { HTMLAttributesSignalExcluded } from '../utils/UNSAFE_attributeUtils';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport type { DimensionProps } from '../utils/UNSAFE_interpolations/dimensions';\nimport { TabbableModeContext } from '../hooks/UNSAFE_useTabbableMode';\nimport { dimensionInterpolations } from '../utils/UNSAFE_interpolations/dimensions';\nimport { mergeInterpolations } from '../utils/UNSAFE_mergeInterpolations';\n\nimport { cssProps } from '@oracle/oraclejet-cssprops';\n\nimport { ComponentChildren } from 'preact';\nimport { forwardRef, ForwardedRef } from 'preact/compat';\nimport { useCallback, useState, useRef, useImperativeHandle } from 'preact/hooks';\n\ntype IntrinsicProps = Pick<HTMLAttributesSignalExcluded<HTMLElement>, 'title'>;\n\ntype WidthInterpolationProps = Pick<DimensionProps, 'width'>;\n\nexport type Props = IntrinsicProps &\n WidthInterpolationProps & {\n /**\n * children - One or more MenuItems\n */\n children?: ComponentChildren;\n\n /**\n * Specifies that the button element should be disabled.\n */\n isDisabled?: boolean;\n\n /**\n * The label rendered on the action side of the button. Used\n * to identify which child MenuItem action is invoked.\n */\n label?: string;\n\n /**\n * Indicates in what states the button has chrome (background and border).\n * \"outlined\"': \"Outlined buttons are salient, but lighter weight than\n * solid buttons. Outlined buttons are useful for secondary actions.\",\n * \"solid\"': \"Solid buttons stand out, and direct the user's attention to the\n * most important actions in the UI.\",\n * \"callToAction\"': \"A Call To Action (CTA) button guides the user to take or\n * complete the action that is the main goal of the page or page section. There\n * should only be one CTA button on a page at any given time.\",\n \n */\n variant?: 'outlined' | 'solid' | 'callToAction';\n\n /**\n * The size indicates how large the button is rendered: \"sm\", \"md\" (default), \"lg\".\n */\n size?: 'sm' | 'md' | 'lg';\n\n /**\n * Triggered when a button is clicked, whether by keyboard, mouse, or touch events.\n */\n onAction?: () => void;\n };\n\nexport const compStyles = {\n divider: cssProps`${{\n borderTopWidth: '0px',\n borderBottomWidth: '0px',\n borderRightWidth: '0px',\n borderLeftWidth: '1px',\n borderStyle: 'solid',\n height: '100%',\n display: 'inline-flex',\n borderColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-base-button-border-color)'\n }}`,\n\n disabledDivider: cssProps`${{\n borderColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-base-button-border-color-disabled)'\n }}`,\n\n icon: cssProps`${{\n display: 'contents'\n }}`,\n\n root: cssProps`${{\n display: 'inline-block'\n }}`,\n\n childrenMargins: cssProps`${{\n /* @ts-ignore */\n '& > *': {\n marginTop: '0 !important',\n marginBottom: '0 !important',\n marginLeft: '0 !important',\n marginRight: '0 !important'\n }\n }}`\n};\n\nconst menuButtonStyling = ['embedded', 'min', 'noBorderRadiusStart'] as StylingOptions[];\nconst menuButtonActiveStyling = [...menuButtonStyling, 'active'] as StylingOptions[];\n\nconst actionbuttonStyling = ['embedded', 'fill', 'noBorderRadiusEnd'] as StylingOptions[];\nconst actionButtonActiveStyling = [...actionbuttonStyling, 'active'] as StylingOptions[];\n\nconst interpolations = [...Object.values(dimensionInterpolations)];\n\nconst styleInterpolations = mergeInterpolations<DimensionProps>(interpolations);\n\n/**\n * A SplitMenuButton is a combined action and menu button.\n */\nexport const SplitMenuButton = forwardRef(\n (\n {\n children,\n label = '',\n variant = 'outlined',\n isDisabled = false,\n size = 'md',\n onAction,\n ...props\n }: Props,\n ref?: ForwardedRef<HTMLSpanElement>\n ) => {\n const [isMenuOpen, setIsMenuOpen] = useState<boolean>(false);\n const [isActive, setIsActive] = useState<boolean>(false);\n const { class: cls, ...styles } = styleInterpolations(props);\n\n // SPACE or ENTER on root area invokes action, as does CLICK/TAP on LEFT SIDE ACTION AREA\n // DOWN ARROW invokes menu, as does CLICK/TAP on RIGHT SIDE MENU AREA\n const onKeyDown = useCallback(\n (event: KeyboardEvent) => {\n if (event.key === ' ' || event.key === 'Enter') {\n setIsActive(true);\n } else if (event.key == 'ArrowDown') {\n !isDisabled && setIsMenuOpen((menuOpen: boolean) => !menuOpen);\n // Prevent page scroll for down arrow, user definitely wanted to show menu in this case.\n // Don't prevent other keypress defaults, as user may want to hold SPACE down to scroll page.\n event.preventDefault();\n }\n },\n [isDisabled, setIsMenuOpen, setIsActive]\n );\n\n const onKeyUp = useCallback(\n (event: KeyboardEvent) => {\n if (event.key === ' ' || event.key === 'Enter') {\n !isDisabled && onAction && onAction();\n setIsActive(false);\n }\n },\n [isDisabled, onAction, setIsActive]\n );\n\n const onBlur = useCallback(() => {\n setIsActive(false);\n }, [setIsActive]);\n\n const _ref = useRef<HTMLSpanElement>(null);\n useImperativeHandle(ref!, () => _ref.current!, [_ref]);\n\n const menuHandler = () => {\n setIsMenuOpen(!isMenuOpen);\n };\n\n const handleClose = (e: any) => {\n if (e.reason === 'cancel' || 'focusLoss') {\n _ref.current?.focus();\n }\n setIsMenuOpen(false);\n };\n\n const dividerStyles = classNames([\n compStyles.divider,\n isDisabled && compStyles.disabledDivider\n ]);\n\n const rootStyles = classNames([compStyles.root]);\n\n // Using Span for top button allows us to avoid :hover state rendering by\n // taking advantage of :enabled not on spans\n const rootButton = () => {\n return (\n <BaseButton\n elementDetails={{ type: 'span' }}\n ref={\n _ref as ForwardedRef<HTMLButtonElement> &\n ForwardedRef<HTMLAnchorElement> &\n ForwardedRef<HTMLSpanElement>\n }\n isDisabled={isDisabled}\n styling={['container', 'min']}\n variant={variant}\n size={size}\n accessibleLabel={label}\n ariaRoledescription=\"split menu button, press down arrow to invoke menu\"\n ariaExpanded={isMenuOpen}>\n <TabbableModeContext.Provider value={{ isTabbable: false }}>\n <BaseButton\n elementDetails={{ type: 'span' }}\n variant={variant}\n styling={getActionButtonStyling(isActive)}\n size={size}\n isDisabled={isDisabled}\n ariaHidden={true}\n onAction={onAction}>\n {label}\n </BaseButton>\n <div class={`${dividerStyles}`} />\n <BaseButton\n elementDetails={{ type: 'span' }}\n variant={variant}\n styling={getMenuButtonStyling(isMenuOpen)}\n size={size}\n isDisabled={isDisabled}\n ariaHidden={true}\n onAction={menuHandler}>\n <ButtonLayout\n display=\"icons\"\n startIcon={<NavDownIcon />}\n size={size}\n styling=\"embedded\"></ButtonLayout>\n </BaseButton>\n </TabbableModeContext.Provider>\n </BaseButton>\n );\n };\n\n if (isDisabled) {\n return (\n <span role=\"toolbar\" class={`${rootStyles} ${cls}`} style={styles}>\n {rootButton()}\n </span>\n );\n } else {\n return (\n <span\n role=\"toolbar\"\n class={`${rootStyles} ${cls}`}\n style={styles}\n onKeyDown={!isDisabled && onKeyDown}\n onKeyUp={onKeyUp}\n onBlur={onBlur}>\n {rootButton()}\n <Menu anchorRef={_ref} isOpen={isMenuOpen} onClose={handleClose}>\n <span className={compStyles.childrenMargins}>{children}</span>\n </Menu>\n </span>\n );\n }\n }\n);\n\nfunction getMenuButtonStyling(isActive: boolean) {\n return isActive ? menuButtonActiveStyling : menuButtonStyling;\n}\n\nfunction getActionButtonStyling(isActive: boolean) {\n return isActive ? actionButtonActiveStyling : actionbuttonStyling;\n}\n"],"names":["compStyles","menuButtonStyling","menuButtonActiveStyling","actionbuttonStyling","actionButtonActiveStyling","interpolations","Object","values","dimensionInterpolations","styleInterpolations","mergeInterpolations","SplitMenuButton","forwardRef","_a","ref","_b","props","class","cls","styles","__rest","onKeyDown","useCallback","event","key","isDisabled","setIsMenuOpen","menuOpen","onKeyUp","onAction","onBlur","setIsActive","_ref","useRef","useImperativeHandle","current","isMenuOpen","handleClose","e","reason","focus","_jsx","BaseButton","assign","elementDetails","type","styling","variant","size","accessibleLabel","label","ariaRoledescription","ariaExpanded","children","_jsxs","TabbableModeContext","Provider","value","isTabbable","jsx","getActionButtonStyling","isActive","ariaHidden","dividerStyles","getMenuButtonStyling","menuHandler","ButtonLayout","display","startIcon","NavDownIcon","SvgIcoNavDown","role","rootStyles","style","rootButton","Menu","anchorRef","isOpen","onClose","className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A,GAAA,CAAAwB,SAAAH,KAAAT,EAAAkB,IAAA,MAAA,CAAA1C,MAAA,GAAA8C,MAAAtB,EAAAkB,IAAAjB,aAAApC,OAAAqC,OAAA,CAAAC,eAAA,CAAAC,KAAA,QAAAE,QAAAA,EAAAD,QAAAkB,EAAA5B,GAAAY,KAAAA,EAAAvB,WAAAA,EAAAqC,YAAA,EAAAjC,SAAAoC,GAAA,CAAAZ,SAAAZ,EAAAkB,IAAAO,eAAA,CAAAC,QAAA,QAAAC,UAAA3B,EAAAA,IAAA4B,EAAAC,cAAA,IAAAtB,KAAAA,EAAAF,QAAA,uBA8CF,OAAArB,yFAOE6B,OAAA,OAAAhD,OAAAqC,OAAA,CAAA4B,KAAA,UAAAtD,MAAA,GAAAuD,KAAAtD,IAAAuD,MAAAtD,EAAAE,WAAAI,GAAAJ,EAAAO,QAAAA,EAAAE,OAAAA,GAAA,CAAAuB,SAAA,CAAAqB,IAAAjC,EAAAkB,IAAAgB,EAAAA,KAAArE,OAAAqC,OAAA,CAAAiC,UAAA5C,EAAA6C,OAAAzC,EAAA0C,QAAAzC,GAAA,CAAAgB,SAAAZ,EAAAkB,IAAA,OAAArD,OAAAqC,OAAA,CAAAoC,UAAA/E,GAAA,CAAAqD,SAAAA,cAkBN,SAAAW,EAAAH,gBAIA,SAAAD,EAAAC"}
@@ -0,0 +1,2 @@
1
+ define(["exports","./tslib.es6-9d88853c","preact/jsx-runtime",'module',"./utils/UNSAFE_mergeInterpolations"],function(s,i,e,n,a){"use strict";const t={base:"_13kcnad",lineClamp:"_1c243rd",truncation:{none:"",clip:"punudh",ellipsis:"_1ptefyr"},variant:{primary:"m2a0xs",secondary:"nm74oq",disabled:"_6fxcus",danger:"s56kyn",warning:"iuwhms",success:"rwtfii",inherit:"vx49ic"},size:{"2xs":"_10bhqc",xs:"_1gde2mt",sm:"_1bri9ek",md:"_1kqxqrb",lg:"_1lqfe4",xl:"_16vgh5y",inherit:"_1sl5izl"},weight:{normal:"_1h6jeg8",semiBold:"_179p3jg",bold:"_15knisb",inherit:"_1umnk8r"},hyphens:{auto:"hwxdiv",none:"_7ezr4q"}},r=[()=>({class:t.base}),({size:s="inherit"})=>({class:t.size[s]}),({weight:s="inherit"})=>({class:t.weight[s]}),({variant:s="inherit"})=>({class:t.variant[s]}),({hyphens:s="auto"})=>({class:t.hyphens[s]}),({truncation:s="none"})=>({class:t.truncation[s]}),({lineClamp:s})=>s?{class:t.lineClamp,webkitLineClamp:s}:{}],l=a.mergeInterpolations(r);s.Text=function(s){var{children:n}=s,a=i.__rest(s,["children"]);const t=l(a),{class:r}=t,c=i.__rest(t,["class"]);return e.jsx("span",Object.assign({class:r,style:c,id:a.id},{children:e.jsx("span",Object.assign({className:"_1oqx029"},{children:n}))}))}});
2
+ //# sourceMappingURL=Text-442082b8.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Text-781e64c9.js","sources":["../../src/UNSAFE_Text/Text.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 { cssProps } from '@oracle/oraclejet-cssprops';\nimport { mergeInterpolations } from '../utils/UNSAFE_mergeInterpolations';\n\ntype StylePropsWithOutTruncate = {\n /**\n * Specifies text color. If set as \"inherit\", takes text color from its parent element.\n */\n variant?: 'primary' | 'secondary' | 'disabled' | 'danger' | 'warning' | 'success' | 'inherit';\n\n /**\n * Specifies font size and line height. If set as \"inherit\", takes font size and line height from its parent element.\n */\n size?: '2xs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'inherit';\n\n /**\n * Specifies the font weight. If set as \"inherit\", takes font weight from its parent element.\n */\n weight?: 'normal' | 'semiBold' | 'bold' | 'inherit';\n\n /**\n * Specifies if hyphens should be included when handling long words with no spaces.\n */\n hyphens?: 'auto' | 'none';\n};\ntype TruncateProps =\n | {\n /**\n * Truncates text at a specific number of lines and then displays an ellipsis (…) at the end of the last line. Parent of the element needs to have a specific width so text starts overflowing and produce a truncation.\n */\n lineClamp?: number;\n /**\n * Determines text behavior when text is truncated. Be aware of setting either lineClamp or truncation. Setting both props would produce a type error. In most cases, lineClamp=1 tries to put the ellipsis at the end of a \"word\". On the other hand, using truncation=\"ellipsis\" will show as much as possible text, then put the ellipsis at the end.\n */\n truncation?: never;\n }\n | {\n lineClamp?: never;\n truncation?: 'none' | 'clip' | 'ellipsis';\n };\ntype AdditionalProps = {\n /**\n * Specifies the text id\n */\n id?: string;\n\n /**\n * Specifies the children.\n */\n children?: string;\n};\ntype Props = StylePropsWithOutTruncate & TruncateProps & AdditionalProps;\n\nconst styles = {\n base: cssProps`${{\n overflowX: 'hidden',\n overflowY: 'hidden',\n overflowWrap: 'anywhere',\n display: 'inline'\n }}`,\n lineClamp: cssProps`${{\n display: '-webkit-box',\n WebkitBoxOrient: 'vertical'\n }}`,\n truncation: {\n none: '',\n clip: cssProps`${{\n textOverflow: 'clip',\n whiteSpace: 'nowrap',\n width: '100%',\n display: 'inline-block'\n }}`,\n ellipsis: cssProps`${{\n textOverflow: 'ellipsis',\n whiteSpace: 'nowrap',\n width: '100%',\n display: 'inline-block'\n }}`\n },\n variant: {\n primary: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-text-color-primary)'\n }}`,\n secondary: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-text-color-secondary)'\n }}`,\n disabled: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-text-color-disabled)'\n }}`,\n danger: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-danger-3)'\n }}`,\n warning: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-warning-3)'\n }}`,\n success: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-success-3)'\n }}`,\n inherit: cssProps`${{\n color: 'inherit'\n }}`\n },\n size: {\n '2xs': cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-2xs-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-2xs-line-height)'\n }}`,\n xs: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xs-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xs-line-height)'\n }}`,\n sm: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-sm-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-sm-line-height)'\n }}`,\n md: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-line-height)'\n }}`,\n lg: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-lg-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-lg-line-height)'\n }}`,\n xl: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xl-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xl-line-height)'\n }}`,\n inherit: cssProps`${{\n fontSize: 'inherit',\n lineHeight: 'inherit'\n }}`\n },\n weight: {\n normal: cssProps`${{\n fontWeight: 'normal'\n }}`,\n semiBold: cssProps`${{\n fontWeight: '600'\n }}`,\n bold: cssProps`${{\n fontWeight: '700'\n }}`,\n inherit: cssProps`${{\n fontWeight: 'inherit'\n }}`\n },\n hyphens: {\n auto: cssProps`${{\n hyphens: 'auto'\n }}`,\n none: cssProps`${{\n hyphens: 'none'\n }}`\n }\n};\nconst interpolations = [\n () => ({ class: styles.base }),\n ({ size = 'inherit' }: Pick<StylePropsWithOutTruncate, 'size'>) => ({\n class: styles.size[size]\n }),\n ({ weight = 'inherit' }: Pick<StylePropsWithOutTruncate, 'weight'>) => ({\n class: styles.weight[weight]\n }),\n ({ variant = 'inherit' }: Pick<StylePropsWithOutTruncate, 'variant'>) => ({\n class: styles.variant[variant]\n }),\n ({ hyphens = 'auto' }: Pick<StylePropsWithOutTruncate, 'hyphens'>) => ({\n class: styles.hyphens[hyphens]\n }),\n ({ truncation = 'none' }: Pick<TruncateProps, 'truncation'>) => ({\n class: styles.truncation[truncation]\n }),\n ({ lineClamp }: Pick<TruncateProps, 'lineClamp'>) =>\n !lineClamp ? {} : { class: styles.lineClamp, webkitLineClamp: lineClamp }\n];\nconst styleInterpolations = mergeInterpolations<Omit<Props, 'children'>>(interpolations);\nconst childrenStyles = cssProps`${{\n /* @ts-ignore */\n '& > *': {\n marginTop: '0 !important',\n marginBottom: '0 !important',\n marginLeft: '0 !important',\n marginRight: '0 !important'\n }\n}}`;\n\nexport function Text({ children, ...props }: Props) {\n const { class: cls, ...styles } = styleInterpolations(props);\n return (\n <span class={cls} style={styles} id={props.id}>\n <span className={childrenStyles}>{children}</span>\n </span>\n );\n}\n"],"names":["styles","truncation","none","variant","size","weight","hyphens","interpolations","class","styleInterpolations","mergeInterpolations","_a","children","props","__rest","_b","cls"],"mappings":"+IA2DA,MAAAA,EAAA,MAAA,qBAAA,UAWEC,WAAA,CACEC,KAAA,QADF,+BAeAC,QAAA,SAAA,mBAAA,kBAAA,gBAAA,mBAAA,mBAAA,+BAuBAC,KAAA,OAAA,cAAA,cAAA,YAAA,cAAA,YAAA,6BA8BAC,OAAA,QAAA,kBAAA,cAAA,4BAcAC,QAAA,MAAA,6BASFC,EAAA,8CAGIC,MAAAR,EAAAI,KAAAA,+BAGAI,MAAAR,EAAAK,OAAAA,gCAGAG,MAAAR,EAAAG,QAAAA,6BAGAK,MAAAR,EAAAM,QAAAA,gCAGAE,MAAAR,EAAAC,WAAAA,kEAKJQ,EAAAC,EAAAA,oBAAAH,UAWA,SAAAI,GAAqB,IAAAC,SAAAA,GAAAD,EAAAE,EAAAC,EAAAA,OAAAH,EAAA,CAAA,aACnB,MAAAI,EAAAN,EAAAI,IAAAL,MAAAQ,GAAAD,EAAAf,EAAAc,EAAAA,OAAAC,EAAA,CAAA,sHAXF"}
1
+ {"version":3,"file":"Text-442082b8.js","sources":["../../src/UNSAFE_Text/Text.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 { cssProps } from '@oracle/oraclejet-cssprops';\nimport { mergeInterpolations } from '../utils/UNSAFE_mergeInterpolations';\n\ntype StylePropsWithOutTruncate = {\n /**\n * Specifies text color. If set as \"inherit\", takes text color from its parent element.\n */\n variant?: 'primary' | 'secondary' | 'disabled' | 'danger' | 'warning' | 'success' | 'inherit';\n\n /**\n * Specifies font size and line height. If set as \"inherit\", takes font size and line height from its parent element.\n */\n size?: '2xs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'inherit';\n\n /**\n * Specifies the font weight. If set as \"inherit\", takes font weight from its parent element.\n */\n weight?: 'normal' | 'semiBold' | 'bold' | 'inherit';\n\n /**\n * Specifies if hyphens should be included when handling long words with no spaces.\n */\n hyphens?: 'auto' | 'none';\n};\ntype TruncateProps =\n | {\n /**\n * Truncates text at a specific number of lines and then displays an ellipsis (…) at the end of the last line. Parent of the element needs to have a specific width so text starts overflowing and produce a truncation.\n */\n lineClamp?: number;\n /**\n * Determines text behavior when text is truncated. Be aware of setting either lineClamp or truncation. Setting both props would produce a type error. In most cases, lineClamp=1 tries to put the ellipsis at the end of a \"word\". On the other hand, using truncation=\"ellipsis\" will show as much as possible text, then put the ellipsis at the end.\n */\n truncation?: never;\n }\n | {\n lineClamp?: never;\n truncation?: 'none' | 'clip' | 'ellipsis';\n };\ntype AdditionalProps = {\n /**\n * Specifies the text id\n */\n id?: string;\n\n /**\n * Specifies the children.\n */\n children?: string;\n};\ntype Props = StylePropsWithOutTruncate & TruncateProps & AdditionalProps;\n\nconst styles = {\n base: cssProps`${{\n overflowX: 'hidden',\n overflowY: 'hidden',\n overflowWrap: 'anywhere',\n display: 'inline'\n }}`,\n lineClamp: cssProps`${{\n display: '-webkit-box',\n WebkitBoxOrient: 'vertical'\n }}`,\n truncation: {\n none: '',\n clip: cssProps`${{\n textOverflow: 'clip',\n whiteSpace: 'nowrap',\n width: '100%',\n display: 'inline-block'\n }}`,\n ellipsis: cssProps`${{\n textOverflow: 'ellipsis',\n whiteSpace: 'nowrap',\n width: '100%',\n display: 'inline-block'\n }}`\n },\n variant: {\n primary: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-text-color-primary)'\n }}`,\n secondary: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-text-color-secondary)'\n }}`,\n disabled: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-text-color-disabled)'\n }}`,\n danger: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-danger-3)'\n }}`,\n warning: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-warning-3)'\n }}`,\n success: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-success-3)'\n }}`,\n inherit: cssProps`${{\n color: 'inherit'\n }}`\n },\n size: {\n '2xs': cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-2xs-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-2xs-line-height)'\n }}`,\n xs: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xs-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xs-line-height)'\n }}`,\n sm: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-sm-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-sm-line-height)'\n }}`,\n md: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-line-height)'\n }}`,\n lg: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-lg-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-lg-line-height)'\n }}`,\n xl: cssProps`${{\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xl-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xl-line-height)'\n }}`,\n inherit: cssProps`${{\n fontSize: 'inherit',\n lineHeight: 'inherit'\n }}`\n },\n weight: {\n normal: cssProps`${{\n fontWeight: 'normal'\n }}`,\n semiBold: cssProps`${{\n fontWeight: '600'\n }}`,\n bold: cssProps`${{\n fontWeight: '700'\n }}`,\n inherit: cssProps`${{\n fontWeight: 'inherit'\n }}`\n },\n hyphens: {\n auto: cssProps`${{\n hyphens: 'auto'\n }}`,\n none: cssProps`${{\n hyphens: 'none'\n }}`\n }\n};\nconst interpolations = [\n () => ({ class: styles.base }),\n ({ size = 'inherit' }: Pick<StylePropsWithOutTruncate, 'size'>) => ({\n class: styles.size[size]\n }),\n ({ weight = 'inherit' }: Pick<StylePropsWithOutTruncate, 'weight'>) => ({\n class: styles.weight[weight]\n }),\n ({ variant = 'inherit' }: Pick<StylePropsWithOutTruncate, 'variant'>) => ({\n class: styles.variant[variant]\n }),\n ({ hyphens = 'auto' }: Pick<StylePropsWithOutTruncate, 'hyphens'>) => ({\n class: styles.hyphens[hyphens]\n }),\n ({ truncation = 'none' }: Pick<TruncateProps, 'truncation'>) => ({\n class: styles.truncation[truncation]\n }),\n ({ lineClamp }: Pick<TruncateProps, 'lineClamp'>) =>\n !lineClamp ? {} : { class: styles.lineClamp, webkitLineClamp: lineClamp }\n];\nconst styleInterpolations = mergeInterpolations<Omit<Props, 'children'>>(interpolations);\nconst childrenStyles = cssProps`${{\n /* @ts-ignore */\n '& > *': {\n marginTop: '0 !important',\n marginBottom: '0 !important',\n marginLeft: '0 !important',\n marginRight: '0 !important'\n }\n}}`;\n\nexport function Text({ children, ...props }: Props) {\n const { class: cls, ...styles } = styleInterpolations(props);\n return (\n <span class={cls} style={styles} id={props.id}>\n <span className={childrenStyles}>{children}</span>\n </span>\n );\n}\n"],"names":["styles","truncation","none","variant","size","weight","hyphens","interpolations","class","styleInterpolations","mergeInterpolations","_a","children","props","__rest","_b","cls"],"mappings":"+IA2DA,MAAAA,EAAA,MAAA,qBAAA,WAWEC,WAAA,CACEC,KAAA,QADF,8BAeAC,QAAA,SAAA,mBAAA,kBAAA,iBAAA,iBAAA,iBAAA,2BAuBAC,KAAA,OAAA,aAAA,cAAA,cAAA,cAAA,aAAA,+BA8BAC,OAAA,QAAA,oBAAA,gBAAA,+BAcAC,QAAA,MAAA,0BASFC,EAAA,8CAGIC,MAAAR,EAAAI,KAAAA,+BAGAI,MAAAR,EAAAK,OAAAA,gCAGAG,MAAAR,EAAAG,QAAAA,6BAGAK,MAAAR,EAAAM,QAAAA,gCAGAE,MAAAR,EAAAC,WAAAA,kEAKJQ,EAAAC,EAAAA,oBAAAH,UAWA,SAAAI,GAAqB,IAAAC,SAAAA,GAAAD,EAAAE,EAAAC,EAAAA,OAAAH,EAAA,CAAA,aACnB,MAAAI,EAAAN,EAAAI,IAAAL,MAAAQ,GAAAD,EAAAf,EAAAc,EAAAA,OAAAC,EAAA,CAAA,sHAXF"}
@@ -0,0 +1,2 @@
1
+ define(["exports","preact/jsx-runtime","preact","preact/compat","./hooks/UNSAFE_useFormContext","./hooks/UNSAFE_useFormFieldContext","./hooks/UNSAFE_useFocusableTextField","./UNSAFE_Label","./UNSAFE_TextField","./hooks/UNSAFE_useTextField","./UNSAFE_UserAssistance","./hooks/UNSAFE_useLengthFilter",'module',"./utils/UNSAFE_classNames","preact/hooks","./hooks/UNSAFE_usePress","./classNames-f3dd3ee3","./hooks/UNSAFE_useCurrentValueReducer","./ReadonlyTextFieldInput-21372f6f","./TextFieldInput-2719b778"],function(e,s,n,t,a,i,l,o,r,u,c,d,x,h,g,b,F,m,p,v){"use strict";const j="_1tekyeq",L="_4m7hxn",f="_1y283d3",A=()=>{};function C({maxLength:e,valueLength:n=0,onClick:t}){const{isFocused:a}=i.useFormFieldContext(),l=g.useCallback(e=>{e.preventDefault()},[]),o=F.classNames([!a&&L]),{pressProps:r}=b.usePress(null!=t?t:A);return s.jsx("div",Object.assign({class:j,onMouseDown:l},r,{children:s.jsxs("span",Object.assign({class:o},{children:[s.jsx("span",Object.assign({class:f},{children:n})),s.jsx("span",Object.assign({class:f},{children:"/"})),s.jsx("span",Object.assign({class:f},{children:e}))]}))}))}const y=t.forwardRef(({ariaDescribedBy:e,assistiveText:x,autoComplete:h="off",autoFocus:g=!1,helpSourceLink:b,helpSourceText:F,isDisabled:j,isReadonly:L,isRequired:f=!1,isRequiredShown:A,label:y,labelEdge:S,labelStartWidth:R,maxLength:E,maxLengthCounter:U="remaining",maxLengthUnit:k,messages:T,placeholder:O,resize:N,role:_,rows:D,textAlign:I,userAssistanceDensity:P,value:w,variant:V="default",onInput:q,onCommit:B},M)=>{const{currentCommitValue:W,dispatch:z}=m.useCurrentValueReducer({value:w}),H=t.useCallback(e=>{z({type:"input",payload:e.value}),null==q||q(e)},[q]),G=t.useCallback(e=>{z({type:"commit",payload:e.value}),null==B||B(e)},[B]),{isDisabled:J,isReadonly:K,labelEdge:Q,labelStartWidth:X,textAlign:Y,userAssistanceDensity:Z}=a.useFormContext(),$=null!=j?j:J,ee=null!=L?L:K,se=null!=S?S:Q,ne=null!=R?R:X,te=null!=I?I:Y,ae=null!=P?P:Z,{enabledElementRef:ie,readonlyElementRef:le,focusProps:oe,isFocused:re}=l.useFocusableTextField({isDisabled:$,isReadonly:ee,ref:M}),{formFieldContext:ue,inputProps:ce,labelProps:de,textFieldProps:xe,userAssistanceProps:he}=u.useTextField({ariaDescribedBy:e,contentVariant:"textarea",isDisabled:$,isFocused:re,isReadonly:ee,labelEdge:se,messages:T,styleVariant:V,value:w}),{isMaxLengthExceeded:ge,valueLength:be,onFilteredInput:Fe}=d.useLengthFilter({maxLength:E,maxLengthUnit:k,value:w,onInput:H,onCommit:G}),me="none"!==se?s.jsx(o.Label,Object.assign({},de,{children:y})):void 0,pe={label:"none"!==se?me:void 0,labelEdge:"none"!==se?se:void 0,labelStartWidth:"none"!==se?ne:void 0},ve="none"===se?y:void 0,je=$||ee?"efficient"!==ae?void 0:s.jsx(c.InlineUserAssistance,Object.assign({userAssistanceDensity:ae},he)):s.jsx(c.InlineUserAssistance,Object.assign({assistiveText:x,fieldLabel:y,helpSourceLink:b,helpSourceText:F,messages:T,isRequiredShown:A,userAssistanceDensity:ae},he));if(ee)return s.jsx(i.FormFieldContext.Provider,Object.assign({value:ue},{children:s.jsx(r.ReadonlyTextField,Object.assign({role:"presentation",inlineUserAssistance:je,variant:"textarea"},pe,{children:s.jsx(p.ReadonlyTextFieldInput,{ariaDescribedBy:e,ariaLabel:ve,ariaLabelledBy:de.id,as:"textarea",elementRef:le,rows:D,autoFocus:g,textAlign:te,value:w,variant:"textarea",hasInsideLabel:void 0!==y&&"inside"===se})}))}));const Le=t.useCallback(()=>{var e,s;const n=ie.current,t=n?n.value.length:null;null===(e=ie.current)||void 0===e||e.setSelectionRange(t,t),null===(s=ie.current)||void 0===s||s.focus()},[]),fe=s.jsxs(n.Fragment,{children:[s.jsx(v.TextFieldInput,Object.assign({as:"textarea",ariaLabel:ve,autoComplete:h,autoFocus:g,currentCommitValue:W,hasInsideLabel:void 0!==me&&"inside"===se,isRequired:f,inputRef:ie,onCommit:G,onInput:Fe,placeholder:O,role:_,rows:D,textAlign:te,value:w},ce)),"remaining"===U&&void 0!==E&&s.jsx(C,Object.assign({},{maxLength:E,valueLength:be,parentHasFocus:re,onClick:Le})),void 0!==E&&s.jsx(r.MaxLengthLiveRegion,Object.assign({},{isMaxLengthExceeded:ge,maxLength:E,valueLength:be}))]});return s.jsx(i.FormFieldContext.Provider,Object.assign({value:ue},{children:s.jsx(r.TextField,Object.assign({mainContent:fe,inlineUserAssistance:je,onBlur:null==oe?void 0:oe.onfocusout,onFocus:null==oe?void 0:oe.onfocusin,resize:N},xe,pe))}))});e.MaxLengthCounter=C,e.TextArea=y});
2
+ //# sourceMappingURL=TextArea-d45836f7.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"TextArea-89a244ab.js","sources":["../../src/UNSAFE_TextArea/MaxLengthCounter.tsx","../../src/UNSAFE_TextArea/TextArea.tsx"],"sourcesContent":["import { cssProps } from '@oracle/oraclejet-cssprops';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport { useCallback } from 'preact/hooks';\nimport { usePress } from '../hooks/UNSAFE_usePress';\nimport { useFormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\n\ntype Props = {\n maxLength: number;\n valueLength?: number;\n onClick?: () => void; // the calling component should focus on the appropriate element when clicked.\n};\n\nconst rootStyles = {\n base: cssProps`${{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-end',\n cursor: 'text',\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xs-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xs-line-height)',\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-text-color-secondary)',\n textDecorationLine: 'none',\n paddingTop: '0',\n paddingInlineEnd: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding)',\n paddingBottom: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-spacing-1x)',\n paddingInlineStart: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding)'\n }}`\n};\nconst remainingTextStyles = {\n hide: cssProps`${{\n visibility: 'hidden'\n }}`\n};\n// the spans surrounding the {valueLength}, / and {maxlength} need to be display: inline-block\n// so that the order is flipped horizontally in RTL.\nconst spanStyles = cssProps`${{\n display: 'inline-block'\n}}`;\n\nconst noop = () => {};\n\nexport function MaxLengthCounter({ maxLength, valueLength = 0, onClick }: Props) {\n const { isFocused } = useFormFieldContext();\n // We don't want mousedown on this component to do anything, so prevent the default behavior.\n const killEvent = useCallback((event: Event) => {\n event.preventDefault();\n }, []);\n const textClasses = classNames([!isFocused && remainingTextStyles.hide]);\n const { pressProps } = usePress(onClick ?? noop);\n return (\n <div class={rootStyles.base} onMouseDown={killEvent} {...pressProps}>\n <span class={textClasses}>\n <span class={spanStyles}>{valueLength}</span>\n <span class={spanStyles}>/</span>\n <span class={spanStyles}>{maxLength}</span>\n </span>\n </div>\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 */\n\nimport { ComponentProps, Fragment, Ref } from 'preact';\nimport { forwardRef, useCallback } from 'preact/compat';\nimport { useFormContext } from '../hooks/UNSAFE_useFormContext';\nimport { FormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { FocusableHandle, useFocusableTextField } from '../hooks/UNSAFE_useFocusableTextField';\nimport { Label } from '../UNSAFE_Label';\nimport {\n ReadonlyTextField,\n ReadonlyTextFieldInput,\n TextField,\n TextFieldInput\n} from '../UNSAFE_TextField';\nimport { useTextField } from '../hooks/UNSAFE_useTextField';\nimport { InlineUserAssistance } from '../UNSAFE_UserAssistance';\nimport { CountUnit, useLengthFilter } from '../hooks/UNSAFE_useLengthFilter';\nimport { MaxLengthLiveRegion } from '../UNSAFE_TextField';\nimport { MaxLengthCounter } from './MaxLengthCounter';\nimport { Size } from '../utils/UNSAFE_size';\nimport { useCurrentValueReducer } from '../hooks/UNSAFE_useCurrentValueReducer';\nimport { ValueUpdateDetail } from '../utils/UNSAFE_valueUpdateDetail';\n\ntype TextFieldProps = ComponentProps<typeof TextField>;\ntype TextFieldInputProps = ComponentProps<typeof TextFieldInput>;\ntype InlineUserAssistanceProps = ComponentProps<typeof InlineUserAssistance>;\n\ntype Props = {\n /**\n * The ID of an element (or space separated IDs of multiple elements) that\n * describes the input.\n */\n ariaDescribedBy?: TextFieldInputProps['ariaDescribedBy'];\n\n /**\n * Text to provide guidance to help the user understand what to enter.\n */\n assistiveText?: InlineUserAssistanceProps['assistiveText'];\n /**\n * Dictates component's autocomplete state.\n * This attribute indicates whether the value of the control can be automatically completed by the browser.\n * The common values are \"on\" and \"off\".\n */\n autoComplete?: TextFieldInputProps['autoComplete'];\n /**\n * Autofocus specifies whether the component will get focus when the page is loaded.\n * If it is set to true then the associated component will get input focus when the page is loaded.\n * Setting this property doesn't set the focus to the component; it tells the browser to focus\n * to it when the element is inserted in the document.\n */\n autoFocus?: TextFieldInputProps['autoFocus'];\n /**\n * Help source URL associated with the component.\n */\n helpSourceLink?: InlineUserAssistanceProps['helpSourceLink'];\n /**\n * Custom text to be rendered for the <code>helpSourceLink</code>.\n */\n helpSourceText?: InlineUserAssistanceProps['helpSourceText'];\n /**\n * Specifies whether the component is disabled.\n */\n isDisabled?: boolean;\n /**\n * Specifies whether the component is readonly.\n */\n isReadonly?: boolean;\n /**\n * Specifies for accessibility purposes whether a value is required.\n *\n * Setting this property to <code>false</code> means that a value is not required to be\n * committed by the user. Setting this property to <code>true</code> means that a value\n * is required to be committed by the user.\n */\n isRequired?: TextFieldInputProps['isRequired'];\n /**\n * Specifies whether to show an indicator on screen that a value is required, for example\n * before the user has committed a value.\n */\n isRequiredShown?: InlineUserAssistanceProps['isRequiredShown'];\n /**\n * Specifies the label associated with the field.\n */\n label: string;\n /**\n * Specifies where the label is positioned relative to the field.\n */\n labelEdge?: 'inside' | 'start' | 'top' | 'none';\n /**\n * Specifies the width of the label when <code>labelEdge</code> is <code>\"start\"</code>\n */\n labelStartWidth?: Size;\n /**\n * Specifies the maximum number of characters that can be entered in the input field.\n */\n maxLength?: number;\n /**\n * Determines whether the remaining number of characters that can be entered is shown or not.\n */\n maxLengthCounter?: 'none' | 'remaining';\n /**\n * Specifies how the input text characters are to be counted when maxLength is specified.\n */\n maxLengthUnit?: CountUnit;\n /**\n * Messages to show on screen that are associated with the component.\n */\n messages?: InlineUserAssistanceProps['messages'];\n /**\n * A short hint to display before the user enters a value.\n */\n placeholder?: TextFieldInputProps['placeholder'];\n /**\n * Specifies how the user is allowed to manually resize the TextArea component.\n */\n resize?: TextFieldProps['resize'];\n /**\n * Specifies the ARIA role type.\n */\n role?: TextFieldInputProps['role'];\n /**\n * Specifies the number of rows to display\n */\n rows?: TextFieldInputProps['rows'];\n /**\n * Specifies how to align text within the field.\n */\n textAlign?: TextFieldInputProps['textAlign'];\n /**\n * Specifies the density of the user assistance presentation. It can be set to:\n * <ul>\n * <li><code>'efficient'</code>: Show inline and reserve space to prevent layout reflow when user\n * assistance text is displayed.</li>\n * <li><code>'reflow'</code>: Show inline. Layout will reflow when text is displayed.</li>\n * </ul>\n */\n userAssistanceDensity?: InlineUserAssistanceProps['userAssistanceDensity'];\n /**\n * The current display value of the component.\n */\n value?: TextFieldInputProps['value'];\n /**\n * The style variant of the component.\n */\n variant?: TextFieldInputProps['variant'];\n /**\n * Callback invoked when the user commits the entered value by blurring out of the field.\n */\n onCommit?: TextFieldInputProps['onCommit'];\n /**\n * Callback invoked each time the user changes the value of the field. For example, if the user\n * types 'abcd', this callback will be called four times with the value as 'a', 'ab', 'abc' and 'abcd'\n * respectively.\n */\n onInput: TextFieldInputProps['onInput'];\n};\n\nexport const TextArea = forwardRef(\n (\n {\n ariaDescribedBy,\n assistiveText,\n autoComplete = 'off',\n autoFocus = false,\n helpSourceLink,\n helpSourceText,\n isDisabled: propIsDisabled,\n isReadonly: propIsReadonly,\n isRequired = false,\n isRequiredShown,\n label,\n labelEdge: propLabelEdge,\n labelStartWidth: propLabelStartWidth,\n maxLength,\n maxLengthCounter = 'remaining',\n maxLengthUnit,\n messages,\n placeholder,\n resize,\n role,\n rows,\n textAlign: propTextAlign,\n userAssistanceDensity: propUserAssistanceDensity,\n value,\n variant = 'default',\n onInput,\n onCommit\n }: Props,\n ref?: Ref<FocusableHandle>\n ) => {\n const { currentCommitValue, dispatch } = useCurrentValueReducer({ value });\n const onInputAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'input', payload: detail.value });\n onInput?.(detail);\n },\n [onInput]\n );\n const onCommitAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'commit', payload: detail.value });\n onCommit?.(detail);\n },\n [onCommit]\n );\n const {\n isDisabled: isFormDisabled,\n isReadonly: isFormReadonly,\n labelEdge: formLabelEdge,\n labelStartWidth: formLabelStartWidth,\n textAlign: formTextAlign,\n userAssistanceDensity: formUserAssistanceDensity\n } = useFormContext();\n // default to FormContext values if component properties are not specified\n const isDisabled = propIsDisabled ?? isFormDisabled;\n const isReadonly = propIsReadonly ?? isFormReadonly;\n const labelEdge = propLabelEdge ?? formLabelEdge;\n const labelStartWidth = propLabelStartWidth ?? formLabelStartWidth;\n const textAlign = propTextAlign ?? formTextAlign;\n const userAssistanceDensity = propUserAssistanceDensity ?? formUserAssistanceDensity;\n\n const { enabledElementRef, readonlyElementRef, focusProps, isFocused } = useFocusableTextField<\n HTMLTextAreaElement,\n HTMLTextAreaElement\n >({ isDisabled, isReadonly, ref });\n\n const { formFieldContext, inputProps, labelProps, textFieldProps, userAssistanceProps } =\n useTextField({\n ariaDescribedBy,\n contentVariant: 'textarea',\n isDisabled,\n isFocused,\n isReadonly,\n labelEdge,\n messages,\n styleVariant: variant,\n value\n });\n\n // Handle length filter for user-typed inputs and controlled inputs\n const { isMaxLengthExceeded, valueLength, onFilteredInput } = useLengthFilter({\n maxLength,\n maxLengthUnit,\n value,\n onInput: onInputAndDispatch,\n onCommit: onCommitAndDispatch\n });\n\n const labelComp = labelEdge !== 'none' ? <Label {...labelProps}>{label}</Label> : undefined;\n\n const fieldLabelProps = {\n label: labelEdge !== 'none' ? labelComp : undefined,\n labelEdge: labelEdge !== 'none' ? labelEdge : undefined,\n labelStartWidth: labelEdge !== 'none' ? labelStartWidth : undefined\n };\n\n const ariaLabel = labelEdge === 'none' ? label : undefined;\n\n const inlineUserAssistance =\n isDisabled || isReadonly ? (\n // save space for user assistance if density is 'efficient', even though we don't\n // render user assistance for disabled or readonly fields\n userAssistanceDensity !== 'efficient' ? undefined : (\n <InlineUserAssistance\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n )\n ) : (\n <InlineUserAssistance\n assistiveText={assistiveText}\n fieldLabel={label}\n helpSourceLink={helpSourceLink}\n helpSourceText={helpSourceText}\n messages={messages}\n isRequiredShown={isRequiredShown}\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n );\n\n if (isReadonly) {\n // TODO: We need to conditionally render the readonly innerReadonlyField as a textarea or div\n // also, the div will need to use white-space: pre-wrap so that the text will wrap like textarea\n // see JET-50636\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <ReadonlyTextField\n role=\"presentation\"\n inlineUserAssistance={inlineUserAssistance}\n variant=\"textarea\"\n {...fieldLabelProps}>\n <ReadonlyTextFieldInput\n ariaDescribedBy={ariaDescribedBy}\n ariaLabel={ariaLabel}\n ariaLabelledBy={labelProps.id}\n as=\"textarea\"\n elementRef={readonlyElementRef}\n rows={rows}\n autoFocus={autoFocus}\n textAlign={textAlign}\n value={value}\n variant=\"textarea\"\n hasInsideLabel={label !== undefined && labelEdge === 'inside'}\n />\n </ReadonlyTextField>\n </FormFieldContext.Provider>\n );\n }\n\n const onClickCounter = useCallback(() => {\n const elm = enabledElementRef.current;\n // for setSelectionRange(), len needs to be a number or null.\n const len = elm ? elm.value.length : null;\n // Since the counter element is after the text, clicking in this\n // should put the selection at the end of the text\n enabledElementRef.current?.setSelectionRange(len, len);\n // Clicking the counter should put the focus on the input field\n enabledElementRef.current?.focus();\n }, []);\n\n const mainContent = (\n <Fragment>\n <TextFieldInput\n as=\"textarea\"\n ariaLabel={ariaLabel}\n autoComplete={autoComplete}\n autoFocus={autoFocus}\n currentCommitValue={currentCommitValue}\n hasInsideLabel={labelComp !== undefined && labelEdge === 'inside'}\n isRequired={isRequired}\n inputRef={enabledElementRef}\n onCommit={onCommitAndDispatch}\n onInput={onFilteredInput}\n placeholder={placeholder}\n role={role}\n rows={rows}\n textAlign={textAlign}\n value={value}\n {...inputProps}\n />\n {maxLengthCounter === 'remaining' && maxLength !== undefined && (\n <MaxLengthCounter\n {...{ maxLength, valueLength, parentHasFocus: isFocused, onClick: onClickCounter }}\n />\n )}\n {maxLength !== undefined && (\n <MaxLengthLiveRegion {...{ isMaxLengthExceeded, maxLength, valueLength }} />\n )}\n </Fragment>\n );\n\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <TextField\n mainContent={mainContent}\n inlineUserAssistance={inlineUserAssistance}\n onBlur={focusProps?.onfocusout}\n onFocus={focusProps?.onfocusin}\n resize={resize}\n {...textFieldProps}\n {...fieldLabelProps}></TextField>\n </FormFieldContext.Provider>\n );\n }\n);\n"],"names":["rootStyles","remainingTextStyles","spanStyles","noop","MaxLengthCounter","maxLength","valueLength","onClick","isFocused","useFormFieldContext","killEvent","useCallback","event","textClasses","classNames","pressProps","usePress","_jsx","Object","assign","class","onMouseDown","children","_jsxs","jsxs","jsx","TextArea","forwardRef","ariaDescribedBy","assistiveText","autoComplete","autoFocus","helpSourceLink","helpSourceText","isDisabled","propIsDisabled","isReadonly","propIsReadonly","isRequired","isRequiredShown","label","labelEdge","propLabelEdge","labelStartWidth","propLabelStartWidth","maxLengthCounter","maxLengthUnit","messages","placeholder","resize","role","rows","textAlign","propTextAlign","userAssistanceDensity","propUserAssistanceDensity","value","variant","onInput","onCommit","ref","currentCommitValue","dispatch","useCurrentValueReducer","onInputAndDispatch","detail","type","payload","onCommitAndDispatch","isFormDisabled","isFormReadonly","formLabelEdge","formLabelStartWidth","formTextAlign","formUserAssistanceDensity","useFormContext","enabledElementRef","readonlyElementRef","focusProps","useFocusableTextField","formFieldContext","inputProps","labelProps","textFieldProps","userAssistanceProps","useTextField","contentVariant","styleVariant","isMaxLengthExceeded","onFilteredInput","useLengthFilter","labelComp","Label","undefined","fieldLabelProps","ariaLabel","inlineUserAssistance","InlineUserAssistance","fieldLabel","FormFieldContext","Provider","ReadonlyTextField","ReadonlyTextFieldInput","ariaLabelledBy","id","as","elementRef","hasInsideLabel","onClickCounter","elm","current","len","length","_a","setSelectionRange","_b","focus","mainContent","Fragment","TextFieldInput","inputRef","parentHasFocus","MaxLengthLiveRegion","TextField","onBlur","onfocusout","onFocus","onfocusin"],"mappings":"0jBAYA,MAAAA,WAgBAC,aAOAC,EAAA,UAIAC,EAAA,OAEA,SAAAC,GAAAC,UAAAA,EAAAC,YAAAA,EAAA,EAAAC,QAAAA,IACE,MAAAC,UAAAA,GAAAC,EAAAA,sBAEAC,EAAAC,EAAAA,YAAAC,4BAGAC,EAAAC,EAAAA,WAAA,EAAAN,GAAAP,KACAc,WAAAA,GAAAC,EAAAA,SAAAT,MAAAA,EAAAA,EAAAJ,GACA,OAAAc,MAAA,MAAAC,OAAAC,OAAA,CAAAC,MAAApB,EAAAqB,YAAAX,GAAAK,EAAA,CAAAO,SAAAC,EAAAC,KAAA,OAAAN,OAAAC,OAAA,CAAAC,MAAAP,GAAA,CAAAS,SAAA,CAAAL,EAAAQ,IAAA,OAAAP,OAAAC,OAAA,CAAAC,MAAAlB,GAAA,CAAAoB,SAAAhB,KAAAW,EAAAQ,IAAA,OAAAP,OAAAC,OAAA,CAAAC,MAAAlB,GAAA,CAAAoB,SAAA,OAAAL,EAAAQ,IAAA,OAAAP,OAAAC,OAAA,CAAAC,MAAAlB,GAAA,CAAAoB,SAAAjB,YCkHW,MAAAqB,EAAWC,EAAA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Q9C,MAAAA,QAAA,EAAAA,GAAY+C,WACpBC,QAAShD,MAAAA,QAAU,EAAVA,GAAYiD,UACrB9E,OAAQA,GACJkC,GACAW"}
1
+ {"version":3,"file":"TextArea-d45836f7.js","sources":["../../src/UNSAFE_TextArea/MaxLengthCounter.tsx","../../src/UNSAFE_TextArea/TextArea.tsx"],"sourcesContent":["import { cssProps } from '@oracle/oraclejet-cssprops';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport { useCallback } from 'preact/hooks';\nimport { usePress } from '../hooks/UNSAFE_usePress';\nimport { useFormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\n\ntype Props = {\n maxLength: number;\n valueLength?: number;\n onClick?: () => void; // the calling component should focus on the appropriate element when clicked.\n};\n\nconst rootStyles = {\n base: cssProps`${{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-end',\n cursor: 'text',\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xs-font-size)',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-xs-line-height)',\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-text-color-secondary)',\n textDecorationLine: 'none',\n paddingTop: '0',\n paddingInlineEnd: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding)',\n paddingBottom: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-spacing-1x)',\n paddingInlineStart: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding)'\n }}`\n};\nconst remainingTextStyles = {\n hide: cssProps`${{\n visibility: 'hidden'\n }}`\n};\n// the spans surrounding the {valueLength}, / and {maxlength} need to be display: inline-block\n// so that the order is flipped horizontally in RTL.\nconst spanStyles = cssProps`${{\n display: 'inline-block'\n}}`;\n\nconst noop = () => {};\n\nexport function MaxLengthCounter({ maxLength, valueLength = 0, onClick }: Props) {\n const { isFocused } = useFormFieldContext();\n // We don't want mousedown on this component to do anything, so prevent the default behavior.\n const killEvent = useCallback((event: Event) => {\n event.preventDefault();\n }, []);\n const textClasses = classNames([!isFocused && remainingTextStyles.hide]);\n const { pressProps } = usePress(onClick ?? noop);\n return (\n <div class={rootStyles.base} onMouseDown={killEvent} {...pressProps}>\n <span class={textClasses}>\n <span class={spanStyles}>{valueLength}</span>\n <span class={spanStyles}>/</span>\n <span class={spanStyles}>{maxLength}</span>\n </span>\n </div>\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 */\n\nimport { ComponentProps, Fragment, Ref } from 'preact';\nimport { forwardRef, useCallback } from 'preact/compat';\nimport { useFormContext } from '../hooks/UNSAFE_useFormContext';\nimport { FormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { FocusableHandle, useFocusableTextField } from '../hooks/UNSAFE_useFocusableTextField';\nimport { Label } from '../UNSAFE_Label';\nimport {\n ReadonlyTextField,\n ReadonlyTextFieldInput,\n TextField,\n TextFieldInput\n} from '../UNSAFE_TextField';\nimport { useTextField } from '../hooks/UNSAFE_useTextField';\nimport { InlineUserAssistance } from '../UNSAFE_UserAssistance';\nimport { CountUnit, useLengthFilter } from '../hooks/UNSAFE_useLengthFilter';\nimport { MaxLengthLiveRegion } from '../UNSAFE_TextField';\nimport { MaxLengthCounter } from './MaxLengthCounter';\nimport { Size } from '../utils/UNSAFE_size';\nimport { useCurrentValueReducer } from '../hooks/UNSAFE_useCurrentValueReducer';\nimport { ValueUpdateDetail } from '../utils/UNSAFE_valueUpdateDetail';\n\ntype TextFieldProps = ComponentProps<typeof TextField>;\ntype TextFieldInputProps = ComponentProps<typeof TextFieldInput>;\ntype InlineUserAssistanceProps = ComponentProps<typeof InlineUserAssistance>;\n\ntype Props = {\n /**\n * The ID of an element (or space separated IDs of multiple elements) that\n * describes the input.\n */\n ariaDescribedBy?: TextFieldInputProps['ariaDescribedBy'];\n\n /**\n * Text to provide guidance to help the user understand what to enter.\n */\n assistiveText?: InlineUserAssistanceProps['assistiveText'];\n /**\n * Dictates component's autocomplete state.\n * This attribute indicates whether the value of the control can be automatically completed by the browser.\n * The common values are \"on\" and \"off\".\n */\n autoComplete?: TextFieldInputProps['autoComplete'];\n /**\n * Autofocus specifies whether the component will get focus when the page is loaded.\n * If it is set to true then the associated component will get input focus when the page is loaded.\n * Setting this property doesn't set the focus to the component; it tells the browser to focus\n * to it when the element is inserted in the document.\n */\n autoFocus?: TextFieldInputProps['autoFocus'];\n /**\n * Help source URL associated with the component.\n */\n helpSourceLink?: InlineUserAssistanceProps['helpSourceLink'];\n /**\n * Custom text to be rendered for the <code>helpSourceLink</code>.\n */\n helpSourceText?: InlineUserAssistanceProps['helpSourceText'];\n /**\n * Specifies whether the component is disabled.\n */\n isDisabled?: boolean;\n /**\n * Specifies whether the component is readonly.\n */\n isReadonly?: boolean;\n /**\n * Specifies for accessibility purposes whether a value is required.\n *\n * Setting this property to <code>false</code> means that a value is not required to be\n * committed by the user. Setting this property to <code>true</code> means that a value\n * is required to be committed by the user.\n */\n isRequired?: TextFieldInputProps['isRequired'];\n /**\n * Specifies whether to show an indicator on screen that a value is required, for example\n * before the user has committed a value.\n */\n isRequiredShown?: InlineUserAssistanceProps['isRequiredShown'];\n /**\n * Specifies the label associated with the field.\n */\n label: string;\n /**\n * Specifies where the label is positioned relative to the field.\n */\n labelEdge?: 'inside' | 'start' | 'top' | 'none';\n /**\n * Specifies the width of the label when <code>labelEdge</code> is <code>\"start\"</code>\n */\n labelStartWidth?: Size;\n /**\n * Specifies the maximum number of characters that can be entered in the input field.\n */\n maxLength?: number;\n /**\n * Determines whether the remaining number of characters that can be entered is shown or not.\n */\n maxLengthCounter?: 'none' | 'remaining';\n /**\n * Specifies how the input text characters are to be counted when maxLength is specified.\n */\n maxLengthUnit?: CountUnit;\n /**\n * Messages to show on screen that are associated with the component.\n */\n messages?: InlineUserAssistanceProps['messages'];\n /**\n * A short hint to display before the user enters a value.\n */\n placeholder?: TextFieldInputProps['placeholder'];\n /**\n * Specifies how the user is allowed to manually resize the TextArea component.\n */\n resize?: TextFieldProps['resize'];\n /**\n * Specifies the ARIA role type.\n */\n role?: TextFieldInputProps['role'];\n /**\n * Specifies the number of rows to display\n */\n rows?: TextFieldInputProps['rows'];\n /**\n * Specifies how to align text within the field.\n */\n textAlign?: TextFieldInputProps['textAlign'];\n /**\n * Specifies the density of the user assistance presentation. It can be set to:\n * <ul>\n * <li><code>'efficient'</code>: Show inline and reserve space to prevent layout reflow when user\n * assistance text is displayed.</li>\n * <li><code>'reflow'</code>: Show inline. Layout will reflow when text is displayed.</li>\n * </ul>\n */\n userAssistanceDensity?: InlineUserAssistanceProps['userAssistanceDensity'];\n /**\n * The current display value of the component.\n */\n value?: TextFieldInputProps['value'];\n /**\n * The style variant of the component.\n */\n variant?: TextFieldInputProps['variant'];\n /**\n * Callback invoked when the user commits the entered value by blurring out of the field.\n */\n onCommit?: TextFieldInputProps['onCommit'];\n /**\n * Callback invoked each time the user changes the value of the field. For example, if the user\n * types 'abcd', this callback will be called four times with the value as 'a', 'ab', 'abc' and 'abcd'\n * respectively.\n */\n onInput: TextFieldInputProps['onInput'];\n};\n\nexport const TextArea = forwardRef(\n (\n {\n ariaDescribedBy,\n assistiveText,\n autoComplete = 'off',\n autoFocus = false,\n helpSourceLink,\n helpSourceText,\n isDisabled: propIsDisabled,\n isReadonly: propIsReadonly,\n isRequired = false,\n isRequiredShown,\n label,\n labelEdge: propLabelEdge,\n labelStartWidth: propLabelStartWidth,\n maxLength,\n maxLengthCounter = 'remaining',\n maxLengthUnit,\n messages,\n placeholder,\n resize,\n role,\n rows,\n textAlign: propTextAlign,\n userAssistanceDensity: propUserAssistanceDensity,\n value,\n variant = 'default',\n onInput,\n onCommit\n }: Props,\n ref?: Ref<FocusableHandle>\n ) => {\n const { currentCommitValue, dispatch } = useCurrentValueReducer({ value });\n const onInputAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'input', payload: detail.value });\n onInput?.(detail);\n },\n [onInput]\n );\n const onCommitAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'commit', payload: detail.value });\n onCommit?.(detail);\n },\n [onCommit]\n );\n const {\n isDisabled: isFormDisabled,\n isReadonly: isFormReadonly,\n labelEdge: formLabelEdge,\n labelStartWidth: formLabelStartWidth,\n textAlign: formTextAlign,\n userAssistanceDensity: formUserAssistanceDensity\n } = useFormContext();\n // default to FormContext values if component properties are not specified\n const isDisabled = propIsDisabled ?? isFormDisabled;\n const isReadonly = propIsReadonly ?? isFormReadonly;\n const labelEdge = propLabelEdge ?? formLabelEdge;\n const labelStartWidth = propLabelStartWidth ?? formLabelStartWidth;\n const textAlign = propTextAlign ?? formTextAlign;\n const userAssistanceDensity = propUserAssistanceDensity ?? formUserAssistanceDensity;\n\n const { enabledElementRef, readonlyElementRef, focusProps, isFocused } = useFocusableTextField<\n HTMLTextAreaElement,\n HTMLTextAreaElement\n >({ isDisabled, isReadonly, ref });\n\n const { formFieldContext, inputProps, labelProps, textFieldProps, userAssistanceProps } =\n useTextField({\n ariaDescribedBy,\n contentVariant: 'textarea',\n isDisabled,\n isFocused,\n isReadonly,\n labelEdge,\n messages,\n styleVariant: variant,\n value\n });\n\n // Handle length filter for user-typed inputs and controlled inputs\n const { isMaxLengthExceeded, valueLength, onFilteredInput } = useLengthFilter({\n maxLength,\n maxLengthUnit,\n value,\n onInput: onInputAndDispatch,\n onCommit: onCommitAndDispatch\n });\n\n const labelComp = labelEdge !== 'none' ? <Label {...labelProps}>{label}</Label> : undefined;\n\n const fieldLabelProps = {\n label: labelEdge !== 'none' ? labelComp : undefined,\n labelEdge: labelEdge !== 'none' ? labelEdge : undefined,\n labelStartWidth: labelEdge !== 'none' ? labelStartWidth : undefined\n };\n\n const ariaLabel = labelEdge === 'none' ? label : undefined;\n\n const inlineUserAssistance =\n isDisabled || isReadonly ? (\n // save space for user assistance if density is 'efficient', even though we don't\n // render user assistance for disabled or readonly fields\n userAssistanceDensity !== 'efficient' ? undefined : (\n <InlineUserAssistance\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n )\n ) : (\n <InlineUserAssistance\n assistiveText={assistiveText}\n fieldLabel={label}\n helpSourceLink={helpSourceLink}\n helpSourceText={helpSourceText}\n messages={messages}\n isRequiredShown={isRequiredShown}\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n );\n\n if (isReadonly) {\n // TODO: We need to conditionally render the readonly innerReadonlyField as a textarea or div\n // also, the div will need to use white-space: pre-wrap so that the text will wrap like textarea\n // see JET-50636\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <ReadonlyTextField\n role=\"presentation\"\n inlineUserAssistance={inlineUserAssistance}\n variant=\"textarea\"\n {...fieldLabelProps}>\n <ReadonlyTextFieldInput\n ariaDescribedBy={ariaDescribedBy}\n ariaLabel={ariaLabel}\n ariaLabelledBy={labelProps.id}\n as=\"textarea\"\n elementRef={readonlyElementRef}\n rows={rows}\n autoFocus={autoFocus}\n textAlign={textAlign}\n value={value}\n variant=\"textarea\"\n hasInsideLabel={label !== undefined && labelEdge === 'inside'}\n />\n </ReadonlyTextField>\n </FormFieldContext.Provider>\n );\n }\n\n const onClickCounter = useCallback(() => {\n const elm = enabledElementRef.current;\n // for setSelectionRange(), len needs to be a number or null.\n const len = elm ? elm.value.length : null;\n // Since the counter element is after the text, clicking in this\n // should put the selection at the end of the text\n enabledElementRef.current?.setSelectionRange(len, len);\n // Clicking the counter should put the focus on the input field\n enabledElementRef.current?.focus();\n }, []);\n\n const mainContent = (\n <Fragment>\n <TextFieldInput\n as=\"textarea\"\n ariaLabel={ariaLabel}\n autoComplete={autoComplete}\n autoFocus={autoFocus}\n currentCommitValue={currentCommitValue}\n hasInsideLabel={labelComp !== undefined && labelEdge === 'inside'}\n isRequired={isRequired}\n inputRef={enabledElementRef}\n onCommit={onCommitAndDispatch}\n onInput={onFilteredInput}\n placeholder={placeholder}\n role={role}\n rows={rows}\n textAlign={textAlign}\n value={value}\n {...inputProps}\n />\n {maxLengthCounter === 'remaining' && maxLength !== undefined && (\n <MaxLengthCounter\n {...{ maxLength, valueLength, parentHasFocus: isFocused, onClick: onClickCounter }}\n />\n )}\n {maxLength !== undefined && (\n <MaxLengthLiveRegion {...{ isMaxLengthExceeded, maxLength, valueLength }} />\n )}\n </Fragment>\n );\n\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <TextField\n mainContent={mainContent}\n inlineUserAssistance={inlineUserAssistance}\n onBlur={focusProps?.onfocusout}\n onFocus={focusProps?.onfocusin}\n resize={resize}\n {...textFieldProps}\n {...fieldLabelProps}></TextField>\n </FormFieldContext.Provider>\n );\n }\n);\n"],"names":["rootStyles","remainingTextStyles","spanStyles","noop","MaxLengthCounter","maxLength","valueLength","onClick","isFocused","useFormFieldContext","killEvent","useCallback","event","textClasses","classNames","pressProps","usePress","_jsx","Object","assign","class","onMouseDown","children","_jsxs","jsxs","jsx","TextArea","forwardRef","ariaDescribedBy","assistiveText","autoComplete","autoFocus","helpSourceLink","helpSourceText","isDisabled","propIsDisabled","isReadonly","propIsReadonly","isRequired","isRequiredShown","label","labelEdge","propLabelEdge","labelStartWidth","propLabelStartWidth","maxLengthCounter","maxLengthUnit","messages","placeholder","resize","role","rows","textAlign","propTextAlign","userAssistanceDensity","propUserAssistanceDensity","value","variant","onInput","onCommit","ref","currentCommitValue","dispatch","useCurrentValueReducer","onInputAndDispatch","detail","type","payload","onCommitAndDispatch","isFormDisabled","isFormReadonly","formLabelEdge","formLabelStartWidth","formTextAlign","formUserAssistanceDensity","useFormContext","enabledElementRef","readonlyElementRef","focusProps","useFocusableTextField","formFieldContext","inputProps","labelProps","textFieldProps","userAssistanceProps","useTextField","contentVariant","styleVariant","isMaxLengthExceeded","onFilteredInput","useLengthFilter","labelComp","Label","undefined","fieldLabelProps","ariaLabel","inlineUserAssistance","InlineUserAssistance","fieldLabel","FormFieldContext","Provider","ReadonlyTextField","ReadonlyTextFieldInput","ariaLabelledBy","id","as","elementRef","hasInsideLabel","onClickCounter","elm","current","len","length","_a","setSelectionRange","_b","focus","mainContent","Fragment","TextFieldInput","inputRef","parentHasFocus","MaxLengthLiveRegion","TextField","onBlur","onfocusout","onFocus","onfocusin"],"mappings":"0jBAYA,MAAAA,aAgBAC,YAOAC,EAAA,WAIAC,EAAA,OAEA,SAAAC,GAAAC,UAAAA,EAAAC,YAAAA,EAAA,EAAAC,QAAAA,IACE,MAAAC,UAAAA,GAAAC,EAAAA,sBAEAC,EAAAC,EAAAA,YAAAC,4BAGAC,EAAAC,EAAAA,WAAA,EAAAN,GAAAP,KACAc,WAAAA,GAAAC,EAAAA,SAAAT,MAAAA,EAAAA,EAAAJ,GACA,OAAAc,MAAA,MAAAC,OAAAC,OAAA,CAAAC,MAAApB,EAAAqB,YAAAX,GAAAK,EAAA,CAAAO,SAAAC,EAAAC,KAAA,OAAAN,OAAAC,OAAA,CAAAC,MAAAP,GAAA,CAAAS,SAAA,CAAAL,EAAAQ,IAAA,OAAAP,OAAAC,OAAA,CAAAC,MAAAlB,GAAA,CAAAoB,SAAAhB,KAAAW,EAAAQ,IAAA,OAAAP,OAAAC,OAAA,CAAAC,MAAAlB,GAAA,CAAAoB,SAAA,OAAAL,EAAAQ,IAAA,OAAAP,OAAAC,OAAA,CAAAC,MAAAlB,GAAA,CAAAoB,SAAAjB,YCkHW,MAAAqB,EAAWC,EAAAA,WACtB,EAEIC,gBAAAA,EACAC,cAAAA,EACAC,aAAAA,EAAe,MACfC,UAAAA,GAAY,EACZC,eAAAA,EACAC,eAAAA,EACAC,WAAYC,EACZC,WAAYC,EACZC,WAAAA,GAAa,EACbC,gBAAAA,EACAC,MAAAA,EACAC,UAAWC,EACXC,gBAAiBC,EACjBvC,UAAAA,EACAwC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AAMkG,EAAMjC,GAAkBkC,QAExBC,EAAMF,EAAMA,EAAIrD,MAAMwD,OAAS,KAGV,QAA3BC,EAAArC,GAAkBkC,eAAS,IAAAG,GAAAA,EAAAC,kBAAkBH,EAAKA,GAEvB,QAA3BI,EAAAvC,GAAkBkC,eAAS,IAAAK,GAAAA,EAAAC,SAC1B,IAEGC,GACJ9F,EAAAA,KAAC+F,EAAQA,SAAA,CAAAhG,SAAA,CACPL,EAAAA,IAACsG,EAAAA,eACCrG,OAAAC,OAAA,CAAAsF,GAAG,WACHV,UAAWA,GACXjE,aAAcA,EACdC,UAAWA,EACX8B,mBAAoBA,EACpB8C,oBAA8Bd,IAAdF,IAAyC,WAAdlD,GAC3CH,WAAYA,EACZkF,SAAU5C,GACVjB,SAAUS,EACVV,QAAS+B,GACTzC,YAAaA,EACbE,KAAMA,EACNC,KAAMA,EACNC,UAAWA,GACXI,MAAOA,GACHyB,KAEgB,cAArBpC,QAAkDgD,IAAdxF,GACnCY,EAAAQ,IAACrB,EAAgBc,OAAAC,OAAA,GACX,CAAEd,UAAAA,EAAWC,YAAAA,GAAamH,eAAgBjH,GAAWD,QAASqG,WAGvDf,IAAdxF,GACCY,EAAAA,IAACyG,EAAAA,oBAAmBxG,OAAAC,OAAA,GAAK,CAAEqE,oBAAAA,GAAqBnF,UAAAA,EAAWC,YAAAA,SAKjE,OACEW,MAACkF,mBAAiBC,SAASlF,OAAAC,OAAA,CAAAqC,MAAOwB,IAChC,CAAA1D,SAAAL,EAAAQ,IAACkG,YACCzG,OAAAC,OAAA,CAAAkG,YAAaA,GACbrB,qBAAsBA,GACtB4B,OAAQ9C,MAAAA,QAAA,EAAAA,GAAY+C,WACpBC,QAAShD,MAAAA,QAAU,EAAVA,GAAYiD,UACrB9E,OAAQA,GACJkC,GACAW"}
@@ -1,2 +1,2 @@
1
- define(["exports","preact/jsx-runtime","preact","preact/compat","./hooks/UNSAFE_useFormContext","./hooks/UNSAFE_useFormFieldContext","./hooks/UNSAFE_useFocusableTextField","./UNSAFE_Label","./UNSAFE_TextField","./hooks/UNSAFE_useTextField","./UNSAFE_UserAssistance","./hooks/UNSAFE_useLengthFilter","preact/hooks","./hooks/UNSAFE_useCurrentValueReducer","./UNSAFE_TextArea","./ReadonlyTextFieldInput-dea043dd","./TextFieldInput-40ce4927","./TextArea-89a244ab"],function(e,t,n,s,a,i,l,o,r,u,d,c,x,g,m,h,p,F){"use strict";const b=({isReadonly:e,enabledElementRef:t,readonlyElementRef:n,minRows:s=2,maxRows:a,value:i})=>{x.useLayoutEffect(()=>{const i=e?n:t;if(null===i.current)return;if(i.current instanceof HTMLDivElement)return;const l=i.current,o=(e=>{const t=window.getComputedStyle(e),n=t.lineHeight;if("normal"===n)return 1.2*parseFloat(t.fontSize);return parseFloat(n)})(l);l.style.height="0";const{paddingHeight:r,borderHeight:u}=(e=>{const t=window.getComputedStyle(e);return{paddingHeight:parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),borderHeight:parseFloat(t.borderTop)+parseFloat(t.borderBottom)}})(l),d=o*s+r+u,c=l.scrollHeight+u;let x=0;if(void 0===a)x=c<d?d:c;else if(a>s){const e=o*a+r+u;x=c>e?e:c<d?d:c}else x=d;l.style.height=x+.5+"px"},[i,s,a,e])},v=s.forwardRef(({ariaDescribedBy:e,assistiveText:x,autoComplete:m="off",autoFocus:v=!1,helpSourceLink:f,helpSourceText:R,isDisabled:y,isReadonly:L,isRequired:A=!1,isRequiredShown:j,label:C,labelEdge:E,labelStartWidth:S,maxLength:T,maxLengthCounter:U="remaining",maxLengthUnit:w,maxRows:k,messages:D,minRows:I=2,placeholder:O,role:N,textAlign:_,userAssistanceDensity:H,value:B,variant:P="default",onInput:V,onCommit:M},q)=>{const{currentCommitValue:W,dispatch:z}=g.useCurrentValueReducer({value:B}),G=s.useCallback(e=>{z({type:"input",payload:e.value}),null==V||V(e)},[V]),J=s.useCallback(e=>{z({type:"commit",payload:e.value}),null==M||M(e)},[M]),{isDisabled:K,isReadonly:Q,labelEdge:X,labelStartWidth:Y,textAlign:Z,userAssistanceDensity:$}=a.useFormContext(),ee=null!=y?y:K,te=null!=L?L:Q,ne=null!=E?E:X,se=null!=S?S:Y,ae=null!=_?_:Z,ie=null!=H?H:$,{enabledElementRef:le,readonlyElementRef:oe,focusProps:re,isFocused:ue}=l.useFocusableTextField({isDisabled:ee,isReadonly:te,ref:q}),{formFieldContext:de,inputProps:ce,labelProps:xe,textFieldProps:ge,userAssistanceProps:me}=u.useTextField({ariaDescribedBy:e,contentVariant:"textarea",isDisabled:ee,isFocused:ue,isReadonly:te,labelEdge:ne,messages:D,styleVariant:P,value:B}),{isMaxLengthExceeded:he,valueLength:pe,onFilteredInput:Fe}=c.useLengthFilter({maxLength:T,maxLengthUnit:w,value:B,onInput:G,onCommit:J}),be="none"!==ne?t.jsx(o.Label,Object.assign({},xe,{children:C})):void 0,ve={label:"none"!==ne?be:void 0,labelEdge:"none"!==ne?ne:void 0,labelStartWidth:"none"!==ne?se:void 0},fe="none"===ne?C:void 0,Re=ee||te?"efficient"!==ie?void 0:t.jsx(d.InlineUserAssistance,Object.assign({userAssistanceDensity:ie},me)):t.jsx(d.InlineUserAssistance,Object.assign({assistiveText:x,fieldLabel:C,helpSourceLink:f,helpSourceText:R,messages:D,isRequiredShown:j,userAssistanceDensity:ie},me));if(b({isReadonly:te,enabledElementRef:le,readonlyElementRef:oe,minRows:I,maxRows:k,value:B}),te)return t.jsx(i.FormFieldContext.Provider,Object.assign({value:de},{children:t.jsx(r.ReadonlyTextField,Object.assign({role:"presentation",inlineUserAssistance:Re,variant:"textarea"},ve,{children:t.jsx(h.ReadonlyTextFieldInput,Object.assign({ariaDescribedBy:e,ariaLabel:fe,ariaLabelledBy:xe.id,elementRef:oe},k?{as:"textarea",rows:I}:{as:"div"},{autoFocus:v,textAlign:ae,value:B,variant:"textarea",hasInsideLabel:void 0!==C&&"inside"===ne}))}))}));const ye=s.useCallback(()=>{var e,t;const n=le.current,s=n?n.value.length:null;null===(e=le.current)||void 0===e||e.setSelectionRange(s,s),null===(t=le.current)||void 0===t||t.focus()},[]),Le=t.jsxs(n.Fragment,{children:[t.jsx(p.TextFieldInput,Object.assign({as:"textarea",ariaLabel:fe,autoComplete:m,autoFocus:v,currentCommitValue:W,hasInsideLabel:void 0!==be&&"inside"===ne,isRequired:A,inputRef:le,onCommit:J,onInput:Fe,placeholder:O,role:N,rows:I,textAlign:ae,value:B},ce)),"remaining"===U&&void 0!==T&&t.jsx(F.MaxLengthCounter,Object.assign({},{maxLength:T,valueLength:pe,parentHasFocus:ue,onClick:ye})),void 0!==T&&t.jsx(r.MaxLengthLiveRegion,Object.assign({},{isMaxLengthExceeded:he,maxLength:T,valueLength:pe}))]});return t.jsx(i.FormFieldContext.Provider,Object.assign({value:de},{children:t.jsx(r.TextField,Object.assign({mainContent:Le,inlineUserAssistance:Re,onBlur:null==re?void 0:re.onfocusout,onFocus:null==re?void 0:re.onfocusin},ge,ve))}))});e.TextAreaAutosize=v});
2
- //# sourceMappingURL=TextAreaAutosize-3182a5cd.js.map
1
+ define(["exports","preact/jsx-runtime","preact","preact/compat","./hooks/UNSAFE_useFormContext","./hooks/UNSAFE_useFormFieldContext","./hooks/UNSAFE_useFocusableTextField","./UNSAFE_Label","./UNSAFE_TextField","./hooks/UNSAFE_useTextField","./UNSAFE_UserAssistance","./hooks/UNSAFE_useLengthFilter","preact/hooks","./hooks/UNSAFE_useCurrentValueReducer","./UNSAFE_TextArea","./ReadonlyTextFieldInput-21372f6f","./TextFieldInput-2719b778","./TextArea-d45836f7"],function(e,t,n,s,a,i,l,o,r,u,d,c,x,g,m,h,p,F){"use strict";const b=({isReadonly:e,enabledElementRef:t,readonlyElementRef:n,minRows:s=2,maxRows:a,value:i})=>{x.useLayoutEffect(()=>{const i=e?n:t;if(null===i.current)return;if(i.current instanceof HTMLDivElement)return;const l=i.current,o=(e=>{const t=window.getComputedStyle(e),n=t.lineHeight;if("normal"===n)return 1.2*parseFloat(t.fontSize);return parseFloat(n)})(l);l.style.height="0";const{paddingHeight:r,borderHeight:u}=(e=>{const t=window.getComputedStyle(e);return{paddingHeight:parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),borderHeight:parseFloat(t.borderTop)+parseFloat(t.borderBottom)}})(l),d=o*s+r+u,c=l.scrollHeight+u;let x=0;if(void 0===a)x=c<d?d:c;else if(a>s){const e=o*a+r+u;x=c>e?e:c<d?d:c}else x=d;l.style.height=x+.5+"px"},[i,s,a,e])},v=s.forwardRef(({ariaDescribedBy:e,assistiveText:x,autoComplete:m="off",autoFocus:v=!1,helpSourceLink:f,helpSourceText:R,isDisabled:y,isReadonly:L,isRequired:A=!1,isRequiredShown:j,label:C,labelEdge:E,labelStartWidth:S,maxLength:T,maxLengthCounter:U="remaining",maxLengthUnit:w,maxRows:k,messages:D,minRows:I=2,placeholder:O,role:N,textAlign:_,userAssistanceDensity:H,value:B,variant:P="default",onInput:V,onCommit:M},q)=>{const{currentCommitValue:W,dispatch:z}=g.useCurrentValueReducer({value:B}),G=s.useCallback(e=>{z({type:"input",payload:e.value}),null==V||V(e)},[V]),J=s.useCallback(e=>{z({type:"commit",payload:e.value}),null==M||M(e)},[M]),{isDisabled:K,isReadonly:Q,labelEdge:X,labelStartWidth:Y,textAlign:Z,userAssistanceDensity:$}=a.useFormContext(),ee=null!=y?y:K,te=null!=L?L:Q,ne=null!=E?E:X,se=null!=S?S:Y,ae=null!=_?_:Z,ie=null!=H?H:$,{enabledElementRef:le,readonlyElementRef:oe,focusProps:re,isFocused:ue}=l.useFocusableTextField({isDisabled:ee,isReadonly:te,ref:q}),{formFieldContext:de,inputProps:ce,labelProps:xe,textFieldProps:ge,userAssistanceProps:me}=u.useTextField({ariaDescribedBy:e,contentVariant:"textarea",isDisabled:ee,isFocused:ue,isReadonly:te,labelEdge:ne,messages:D,styleVariant:P,value:B}),{isMaxLengthExceeded:he,valueLength:pe,onFilteredInput:Fe}=c.useLengthFilter({maxLength:T,maxLengthUnit:w,value:B,onInput:G,onCommit:J}),be="none"!==ne?t.jsx(o.Label,Object.assign({},xe,{children:C})):void 0,ve={label:"none"!==ne?be:void 0,labelEdge:"none"!==ne?ne:void 0,labelStartWidth:"none"!==ne?se:void 0},fe="none"===ne?C:void 0,Re=ee||te?"efficient"!==ie?void 0:t.jsx(d.InlineUserAssistance,Object.assign({userAssistanceDensity:ie},me)):t.jsx(d.InlineUserAssistance,Object.assign({assistiveText:x,fieldLabel:C,helpSourceLink:f,helpSourceText:R,messages:D,isRequiredShown:j,userAssistanceDensity:ie},me));if(b({isReadonly:te,enabledElementRef:le,readonlyElementRef:oe,minRows:I,maxRows:k,value:B}),te)return t.jsx(i.FormFieldContext.Provider,Object.assign({value:de},{children:t.jsx(r.ReadonlyTextField,Object.assign({role:"presentation",inlineUserAssistance:Re,variant:"textarea"},ve,{children:t.jsx(h.ReadonlyTextFieldInput,Object.assign({ariaDescribedBy:e,ariaLabel:fe,ariaLabelledBy:xe.id,elementRef:oe},k?{as:"textarea",rows:I}:{as:"div"},{autoFocus:v,textAlign:ae,value:B,variant:"textarea",hasInsideLabel:void 0!==C&&"inside"===ne}))}))}));const ye=s.useCallback(()=>{var e,t;const n=le.current,s=n?n.value.length:null;null===(e=le.current)||void 0===e||e.setSelectionRange(s,s),null===(t=le.current)||void 0===t||t.focus()},[]),Le=t.jsxs(n.Fragment,{children:[t.jsx(p.TextFieldInput,Object.assign({as:"textarea",ariaLabel:fe,autoComplete:m,autoFocus:v,currentCommitValue:W,hasInsideLabel:void 0!==be&&"inside"===ne,isRequired:A,inputRef:le,onCommit:J,onInput:Fe,placeholder:O,role:N,rows:I,textAlign:ae,value:B},ce)),"remaining"===U&&void 0!==T&&t.jsx(F.MaxLengthCounter,Object.assign({},{maxLength:T,valueLength:pe,parentHasFocus:ue,onClick:ye})),void 0!==T&&t.jsx(r.MaxLengthLiveRegion,Object.assign({},{isMaxLengthExceeded:he,maxLength:T,valueLength:pe}))]});return t.jsx(i.FormFieldContext.Provider,Object.assign({value:de},{children:t.jsx(r.TextField,Object.assign({mainContent:Le,inlineUserAssistance:Re,onBlur:null==re?void 0:re.onfocusout,onFocus:null==re?void 0:re.onfocusin},ge,ve))}))});e.TextAreaAutosize=v});
2
+ //# sourceMappingURL=TextAreaAutosize-0c2ab14a.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"TextAreaAutosize-3182a5cd.js","sources":["../../src/UNSAFE_TextAreaAutosize/ScrollHeightUtils.tsx","../../src/UNSAFE_TextAreaAutosize/useTextAreaAutosizing.tsx","../../src/UNSAFE_TextAreaAutosize/TextAreaAutosize.tsx"],"sourcesContent":["// returns the lineHeight as a number of pixels.\nexport const calculateLineHeight = (textarea: HTMLTextAreaElement): number => {\n const computedStyle = window.getComputedStyle(textarea);\n const computedlineHeight = computedStyle.lineHeight;\n if (computedlineHeight === 'normal') {\n // We get 'normal' for values 'initial', 'inherit', 'unset' and 'normal'\n // TODO: Unclear if we need this.\n // getComputedStyle always return fontSize in pixels. Not likely a float, but since it's legal\n // we use parseFloat()\n const fontSize = parseFloat(computedStyle.fontSize);\n return 1.2 * fontSize;\n }\n return parseFloat(computedlineHeight);\n};\nexport const getStylingHeight = (textarea: HTMLTextAreaElement) => {\n const cssStyle = window.getComputedStyle(textarea);\n const paddingTop = parseFloat(cssStyle.paddingTop);\n const paddingBottom = parseFloat(cssStyle.paddingBottom);\n const borderTop = parseFloat(cssStyle.borderTop);\n const borderBottom = parseFloat(cssStyle.borderBottom);\n return { paddingHeight: paddingTop + paddingBottom, borderHeight: borderTop + borderBottom };\n};\n","import { ComponentProps } from 'preact';\nimport { useLayoutEffect, Ref } from 'preact/hooks';\nimport { calculateLineHeight, getStylingHeight } from './ScrollHeightUtils';\nimport { TextAreaAutosize } from './TextAreaAutosize';\n\ntype PickedPropsFromTextAreaAutosize = Pick<\n ComponentProps<typeof TextAreaAutosize>,\n 'minRows' | 'maxRows' | 'value'\n>;\ntype Props = PickedPropsFromTextAreaAutosize & {\n isReadonly?: boolean;\n enabledElementRef: Ref<HTMLTextAreaElement>;\n readonlyElementRef: Ref<HTMLTextAreaElement | HTMLDivElement>;\n};\n\n// TODO: Make this fire when the container resizes - JET-50840\nexport const useTextAreaAutosizing = ({\n isReadonly,\n enabledElementRef,\n readonlyElementRef,\n minRows = 2,\n maxRows,\n value\n}: Props) => {\n useLayoutEffect(() => {\n const textareaRef = isReadonly ? readonlyElementRef : enabledElementRef;\n if (textareaRef.current === null) return;\n if (textareaRef.current instanceof HTMLDivElement) return; // We don't need to do anything if the readonlyElement is a DIV.\n const textarea = textareaRef.current;\n const lineHeight = calculateLineHeight(textarea);\n textarea.style.height = '0';\n const { paddingHeight, borderHeight } = getStylingHeight(textarea);\n const heightForMinRows = lineHeight * minRows + paddingHeight + borderHeight;\n const scrollHeight = textarea.scrollHeight + borderHeight;\n let resizedHeight = 0;\n // if maxRows is -1 the textarea will grow or shrink to fit all the content.\n // it won't shrink any less than rows.\n if (maxRows === undefined) {\n // we want to fit the entire scrollHeight, but we don't want\n // to shrink smaller than the height for rows.\n if (scrollHeight < heightForMinRows) {\n resizedHeight = heightForMinRows;\n } else {\n resizedHeight = scrollHeight;\n }\n } else if (maxRows > minRows) {\n // if maxRows is positive and greater than rows, the textarea will grow to fit the content\n // up to maxrows, or shrink to fit the content and down to rows.\n const heightForMaxRows = lineHeight * maxRows + paddingHeight + borderHeight;\n if (scrollHeight > heightForMaxRows) {\n resizedHeight = heightForMaxRows;\n } else if (scrollHeight < heightForMinRows) {\n resizedHeight = heightForMinRows;\n } else {\n resizedHeight = scrollHeight;\n }\n } else {\n resizedHeight = heightForMinRows;\n }\n // The 0.5 gaurantees that the clientHeight will be bigger than the scrollHeight, so no scrollbar appears.\n textarea.style.height = resizedHeight + 0.5 + 'px';\n }, [value, minRows, maxRows, isReadonly]);\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 */\n\nimport { ComponentProps, Fragment, Ref } from 'preact';\nimport { forwardRef, useCallback } from 'preact/compat';\nimport { useFormContext } from '../hooks/UNSAFE_useFormContext';\nimport { FormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { FocusableHandle, useFocusableTextField } from '../hooks/UNSAFE_useFocusableTextField';\nimport { Label } from '../UNSAFE_Label';\nimport {\n ReadonlyTextField,\n ReadonlyTextFieldInput,\n TextField,\n TextFieldInput\n} from '../UNSAFE_TextField';\nimport { useTextField } from '../hooks/UNSAFE_useTextField';\nimport { InlineUserAssistance } from '../UNSAFE_UserAssistance';\nimport { CountUnit, useLengthFilter } from '../hooks/UNSAFE_useLengthFilter';\nimport { MaxLengthLiveRegion } from '../UNSAFE_TextField';\nimport { useTextAreaAutosizing } from './useTextAreaAutosizing';\nimport { Size } from '../utils/UNSAFE_size';\nimport { useCurrentValueReducer } from '../hooks/UNSAFE_useCurrentValueReducer';\nimport { ValueUpdateDetail } from '../utils/UNSAFE_valueUpdateDetail';\nimport { MaxLengthCounter } from '../UNSAFE_TextArea';\n\ntype TextFieldInputProps = ComponentProps<typeof TextFieldInput>;\ntype InlineUserAssistanceProps = ComponentProps<typeof InlineUserAssistance>;\n\ntype Props = {\n /**\n * The ID of an element (or space separated IDs of multiple elements) that\n * describes the input.\n */\n ariaDescribedBy?: TextFieldInputProps['ariaDescribedBy'];\n /**\n * Text to provide guidance to help the user understand what to enter.\n */\n assistiveText?: InlineUserAssistanceProps['assistiveText'];\n /**\n * Dictates component's autocomplete state.\n * This attribute indicates whether the value of the control can be automatically completed by the browser.\n * The common values are \"on\" and \"off\".\n */\n autoComplete?: TextFieldInputProps['autoComplete'];\n /**\n * Autofocus specifies whether the component will get focus when the page is loaded.\n * If it is set to true then the associated component will get input focus when the page is loaded.\n * Setting this property doesn't set the focus to the component; it tells the browser to focus\n * to it when the element is inserted in the document.\n */\n autoFocus?: TextFieldInputProps['autoFocus'];\n /**\n * Help source URL associated with the component.\n */\n helpSourceLink?: InlineUserAssistanceProps['helpSourceLink'];\n /**\n * Custom text to be rendered for the <code>helpSourceLink</code>.\n */\n helpSourceText?: InlineUserAssistanceProps['helpSourceText'];\n /**\n * Specifies whether the component is disabled.\n */\n isDisabled?: boolean;\n /**\n * Specifies whether the component is readonly.\n */\n isReadonly?: boolean;\n /**\n * Specifies for accessibility purposes whether a value is required.\n *\n * Setting this property to <code>false</code> means that a value is not required to be\n * committed by the user. Setting this property to <code>true</code> means that a value\n * is required to be committed by the user.\n */\n isRequired?: TextFieldInputProps['isRequired'];\n /**\n * Specifies whether to show an indicator on screen that a value is required, for example\n * before the user has committed a value.\n */\n isRequiredShown?: InlineUserAssistanceProps['isRequiredShown'];\n /**\n * Specifies the label associated with the field.\n */\n label: string;\n /**\n * Specifies where the label is positioned relative to the field.\n */\n labelEdge?: 'inside' | 'start' | 'top' | 'none';\n /**\n * Specifies the width of the label when <code>labelEdge</code> is <code>\"start\"</code>\n */\n labelStartWidth?: Size;\n /**\n * Specifies the maximum number of characters that can be entered in the input field.\n */\n maxLength?: number;\n /**\n * Determines whether the remaining number of characters that can be entered is shown or not.\n */\n maxLengthCounter?: 'none' | 'remaining';\n /**\n * Specifies how the input text characters are to be counted when maxLength is specified.\n */\n maxLengthUnit?: CountUnit;\n /**\n * Specifies the maximum number of rows that the TextAreaAutosize is allowed to grow to.\n * If maxRows is less than minRows, it is ignored.\n */\n maxRows?: number;\n /**\n * Messages to show on screen that are associated with the component.\n */\n messages?: InlineUserAssistanceProps['messages'];\n /**\n * Specifies the minimum number of rows that the TextAreaAutosize is allowed to shrink to.\n */\n minRows?: number;\n /**\n * A short hint to display before the user enters a value.\n */\n placeholder?: TextFieldInputProps['placeholder'];\n /**\n * Specifies how the user is allowed to manually resize the TextArea component.\n */\n role?: TextFieldInputProps['role'];\n /**\n * Specifies the number of rows to display\n */\n textAlign?: TextFieldInputProps['textAlign'];\n /**\n * Specifies the density of the user assistance presentation. It can be set to:\n * <ul>\n * <li><code>'efficient'</code>: Show inline and reserve space to prevent layout reflow when user\n * assistance text is displayed.</li>\n * <li><code>'reflow'</code>: Show inline. Layout will reflow when text is displayed.</li>\n * </ul>\n */\n userAssistanceDensity?: InlineUserAssistanceProps['userAssistanceDensity'];\n /**\n * The current display value of the component.\n */\n value?: TextFieldInputProps['value'];\n /**\n * The style variant of the component.\n */\n variant?: TextFieldInputProps['variant'];\n /**\n * Callback invoked when the user commits the entered value by blurring out of the field.\n *\n */\n onCommit?: TextFieldInputProps['onCommit'];\n\n /**\n * Callback invoked when the user inputs a value.\n *\n */\n onInput: TextFieldInputProps['onInput'];\n};\nexport const TextAreaAutosize = forwardRef(\n (\n {\n ariaDescribedBy,\n assistiveText,\n autoComplete = 'off',\n autoFocus = false,\n helpSourceLink,\n helpSourceText,\n isDisabled: propIsDisabled,\n isReadonly: propIsReadonly,\n isRequired = false,\n isRequiredShown,\n label,\n labelEdge: propLabelEdge,\n labelStartWidth: propLabelStartWidth,\n maxLength,\n maxLengthCounter = 'remaining',\n maxLengthUnit,\n maxRows,\n messages,\n minRows = 2,\n placeholder,\n role,\n //TODO: Add counter to show the length remaining - JET-50752\n textAlign: propTextAlign,\n userAssistanceDensity: propUserAssistanceDensity,\n value,\n variant = 'default',\n onInput,\n onCommit\n }: Props,\n ref?: Ref<FocusableHandle>\n ) => {\n const { currentCommitValue, dispatch } = useCurrentValueReducer({ value });\n const onInputAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'input', payload: detail.value });\n onInput?.(detail);\n },\n [onInput]\n );\n const onCommitAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'commit', payload: detail.value });\n onCommit?.(detail);\n },\n [onCommit]\n );\n const {\n isDisabled: isFormDisabled,\n isReadonly: isFormReadonly,\n labelEdge: formLabelEdge,\n labelStartWidth: formLabelStartWidth,\n textAlign: formTextAlign,\n userAssistanceDensity: formUserAssistanceDensity\n } = useFormContext();\n // default to FormContext values if component properties are not specified\n const isDisabled = propIsDisabled ?? isFormDisabled;\n const isReadonly = propIsReadonly ?? isFormReadonly;\n const labelEdge = propLabelEdge ?? formLabelEdge;\n const labelStartWidth = propLabelStartWidth ?? formLabelStartWidth;\n const textAlign = propTextAlign ?? formTextAlign;\n const userAssistanceDensity = propUserAssistanceDensity ?? formUserAssistanceDensity;\n\n const { enabledElementRef, readonlyElementRef, focusProps, isFocused } = useFocusableTextField<\n HTMLTextAreaElement,\n HTMLTextAreaElement | HTMLDivElement\n >({ isDisabled, isReadonly, ref });\n\n const { formFieldContext, inputProps, labelProps, textFieldProps, userAssistanceProps } =\n useTextField({\n ariaDescribedBy,\n contentVariant: 'textarea',\n isDisabled,\n isFocused,\n isReadonly,\n labelEdge,\n messages,\n styleVariant: variant,\n value\n });\n\n // Handle length filter for user-typed inputs and controlled inputs\n const { isMaxLengthExceeded, valueLength, onFilteredInput } = useLengthFilter({\n maxLength,\n maxLengthUnit,\n value,\n onInput: onInputAndDispatch,\n onCommit: onCommitAndDispatch\n });\n\n const labelComp = labelEdge !== 'none' ? <Label {...labelProps}>{label}</Label> : undefined;\n\n const fieldLabelProps = {\n label: labelEdge !== 'none' ? labelComp : undefined,\n labelEdge: labelEdge !== 'none' ? labelEdge : undefined,\n labelStartWidth: labelEdge !== 'none' ? labelStartWidth : undefined\n };\n const ariaLabel = labelEdge === 'none' ? label : undefined;\n\n const inlineUserAssistance =\n isDisabled || isReadonly ? (\n // save space for user assistance if density is 'efficient', even though we don't\n // render user assistance for disabled or readonly fields\n userAssistanceDensity !== 'efficient' ? undefined : (\n <InlineUserAssistance\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n )\n ) : (\n <InlineUserAssistance\n assistiveText={assistiveText}\n fieldLabel={label}\n helpSourceLink={helpSourceLink}\n helpSourceText={helpSourceText}\n messages={messages}\n isRequiredShown={isRequiredShown}\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n );\n\n useTextAreaAutosizing({\n isReadonly,\n enabledElementRef,\n readonlyElementRef,\n minRows,\n maxRows,\n value\n });\n\n if (isReadonly) {\n // TODO: should be able to configure whether start/end content is shown when readonly\n // JET-49916 - Preact InputText: show start/end content when readonly\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <ReadonlyTextField\n role=\"presentation\"\n inlineUserAssistance={inlineUserAssistance}\n variant=\"textarea\"\n {...fieldLabelProps}>\n <ReadonlyTextFieldInput\n ariaDescribedBy={ariaDescribedBy}\n ariaLabel={ariaLabel}\n ariaLabelledBy={labelProps.id}\n elementRef={readonlyElementRef}\n {...(maxRows ? { as: 'textarea', rows: minRows } : { as: 'div' })}\n autoFocus={autoFocus}\n textAlign={textAlign}\n value={value}\n variant=\"textarea\"\n hasInsideLabel={label !== undefined && labelEdge === 'inside'}\n />\n </ReadonlyTextField>\n </FormFieldContext.Provider>\n );\n }\n\n const onClickCounter = useCallback(() => {\n const elm = enabledElementRef.current;\n // for setSelectionRange(), len needs to be a number or null.\n const len = elm ? elm.value.length : null;\n // Since the counter element is after the text, clicking in this\n // should put the selection at the end of the text\n enabledElementRef.current?.setSelectionRange(len, len);\n // Clicking the counter should put the focus on the input field\n enabledElementRef.current?.focus();\n }, []);\n\n const mainContent = (\n <Fragment>\n <TextFieldInput\n as=\"textarea\"\n ariaLabel={ariaLabel}\n autoComplete={autoComplete}\n autoFocus={autoFocus}\n currentCommitValue={currentCommitValue}\n hasInsideLabel={labelComp !== undefined && labelEdge === 'inside'}\n isRequired={isRequired}\n inputRef={enabledElementRef}\n onCommit={onCommitAndDispatch}\n onInput={onFilteredInput}\n placeholder={placeholder}\n role={role}\n rows={minRows}\n textAlign={textAlign}\n value={value}\n {...inputProps}\n />\n {maxLengthCounter === 'remaining' && maxLength !== undefined && (\n <MaxLengthCounter\n {...{ maxLength, valueLength, parentHasFocus: isFocused, onClick: onClickCounter }}\n />\n )}\n {maxLength !== undefined && (\n <MaxLengthLiveRegion {...{ isMaxLengthExceeded, maxLength, valueLength }} />\n )}\n </Fragment>\n );\n\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <TextField\n mainContent={mainContent}\n inlineUserAssistance={inlineUserAssistance}\n onBlur={focusProps?.onfocusout}\n onFocus={focusProps?.onfocusin}\n {...textFieldProps}\n {...fieldLabelProps}></TextField>\n </FormFieldContext.Provider>\n );\n }\n);\n"],"names":["useTextAreaAutosizing","isReadonly","enabledElementRef","readonlyElementRef","minRows","maxRows","value","useLayoutEffect","textareaRef","current","HTMLDivElement","textarea","lineHeight","computedStyle","window","getComputedStyle","computedlineHeight","parseFloat","fontSize","calculateLineHeight","style","height","paddingHeight","borderHeight","cssStyle","paddingTop","paddingBottom","borderTop","borderBottom","getStylingHeight","heightForMinRows","scrollHeight","resizedHeight","undefined","heightForMaxRows","TextAreaAutosize","forwardRef","ariaDescribedBy","assistiveText","autoComplete","autoFocus","helpSourceLink","helpSourceText","isDisabled","propIsDisabled","propIsReadonly","isRequired","isRequiredShown","label","labelEdge","propLabelEdge","labelStartWidth","propLabelStartWidth","maxLength","maxLengthCounter","maxLengthUnit","messages","placeholder","role","textAlign","propTextAlign","userAssistanceDensity","propUserAssistanceDensity","variant","onInput","onCommit","ref","currentCommitValue","dispatch","useCurrentValueReducer","onInputAndDispatch","useCallback","detail","type","payload","onCommitAndDispatch","isFormDisabled","isFormReadonly","formLabelEdge","formLabelStartWidth","formTextAlign","formUserAssistanceDensity","useFormContext","focusProps","isFocused","useFocusableTextField","formFieldContext","inputProps","labelProps","textFieldProps","userAssistanceProps","useTextField","contentVariant","styleVariant","isMaxLengthExceeded","valueLength","onFilteredInput","useLengthFilter","labelComp","_jsx","Label","Object","assign","fieldLabelProps","ariaLabel","inlineUserAssistance","jsx","InlineUserAssistance","fieldLabel","FormFieldContext","Provider","children","ReadonlyTextField","ReadonlyTextFieldInput","ariaLabelledBy","id","elementRef","as","rows","hasInsideLabel","onClickCounter","elm","len","length","_a","setSelectionRange","_b","focus","mainContent","_jsxs","Fragment","TextFieldInput","inputRef","MaxLengthCounter","parentHasFocus","onClick","MaxLengthLiveRegion","TextField","onBlur","onfocusout","onFocus","onfocusin"],"mappings":"wgBACO,MCeMA,EAAwB,EACnCC,WAAAA,EACAC,kBAAAA,EACAC,mBAAAA,EACAC,QAAAA,EAAU,EACVC,QAAAA,EACAC,MAAAA,MAEAC,EAAAA,gBAAgB,KACd,MAAMC,EAAcP,EAAaE,EAAqBD,EACtD,GAA4B,OAAxBM,EAAYC,QAAkB,OAClC,GAAID,EAAYC,mBAAmBC,eAAgB,OACnD,MAAMC,EAAWH,EAAYC,QACvBG,ED5ByB,CAACD,IAClC,MAAME,EAAgBC,OAAOC,iBAAiBJ,GACxCK,EAAqBH,EAAcD,WACzC,GAA2B,WAAvBI,EAMF,OAAO,IADUC,WAAWJ,EAAcK,UAG5C,OAAOD,WAAWD,ICiBGG,CAAoBR,GACvCA,EAASS,MAAMC,OAAS,IACxB,MAAMC,cAAEA,EAAaC,aAAEA,GDjBK,CAACZ,IAC/B,MAAMa,EAAWV,OAAOC,iBAAiBJ,GAKzC,MAAO,CAAEW,cAJUL,WAAWO,EAASC,YACjBR,WAAWO,EAASE,eAGUH,aAFlCN,WAAWO,EAASG,WACjBV,WAAWO,EAASI,gBCYCC,CAAiBlB,GACnDmB,EAAmBlB,EAAaR,EAAUkB,EAAgBC,EAC1DQ,EAAepB,EAASoB,aAAeR,EAC7C,IAAIS,EAAgB,EAGpB,QAAgBC,IAAZ5B,EAIA2B,EADED,EAAeD,EACDA,EAEAC,OAEb,GAAI1B,EAAUD,EAAS,CAG5B,MAAM8B,EAAmBtB,EAAaP,EAAUiB,EAAgBC,EAE9DS,EADED,EAAeG,EACDA,EACPH,EAAeD,EACRA,EAEAC,OAGlBC,EAAgBF,EAGlBnB,EAASS,MAAMC,OAASW,EAAgB,GAAM,MAC7C,CAAC1B,EAAOF,EAASC,EAASJ,KCsGlBkC,E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EAAW0C,YAAAA,SAKjE,OACEI,MAACU,EAAgBA,iBAACC,SAAST,OAAAC,OAAA,CAAAhG,MAAOgF,IAAgB,CAAAyB,SAChDZ,EAAAA,IAACsC,EAASA,UAAApC,OAAAC,OAAA,CACR0B,YAAaA,GACbvB,qBAAsBA,GACtBiC,OAAQvD,MAAAA,UAAAA,GAAYwD,WACpBC,QAASzD,MAAAA,UAAAA,GAAY0D,WACjBpD,GACAc"}
1
+ {"version":3,"file":"TextAreaAutosize-0c2ab14a.js","sources":["../../src/UNSAFE_TextAreaAutosize/ScrollHeightUtils.tsx","../../src/UNSAFE_TextAreaAutosize/useTextAreaAutosizing.tsx","../../src/UNSAFE_TextAreaAutosize/TextAreaAutosize.tsx"],"sourcesContent":["// returns the lineHeight as a number of pixels.\nexport const calculateLineHeight = (textarea: HTMLTextAreaElement): number => {\n const computedStyle = window.getComputedStyle(textarea);\n const computedlineHeight = computedStyle.lineHeight;\n if (computedlineHeight === 'normal') {\n // We get 'normal' for values 'initial', 'inherit', 'unset' and 'normal'\n // TODO: Unclear if we need this.\n // getComputedStyle always return fontSize in pixels. Not likely a float, but since it's legal\n // we use parseFloat()\n const fontSize = parseFloat(computedStyle.fontSize);\n return 1.2 * fontSize;\n }\n return parseFloat(computedlineHeight);\n};\nexport const getStylingHeight = (textarea: HTMLTextAreaElement) => {\n const cssStyle = window.getComputedStyle(textarea);\n const paddingTop = parseFloat(cssStyle.paddingTop);\n const paddingBottom = parseFloat(cssStyle.paddingBottom);\n const borderTop = parseFloat(cssStyle.borderTop);\n const borderBottom = parseFloat(cssStyle.borderBottom);\n return { paddingHeight: paddingTop + paddingBottom, borderHeight: borderTop + borderBottom };\n};\n","import { ComponentProps } from 'preact';\nimport { useLayoutEffect, Ref } from 'preact/hooks';\nimport { calculateLineHeight, getStylingHeight } from './ScrollHeightUtils';\nimport { TextAreaAutosize } from './TextAreaAutosize';\n\ntype PickedPropsFromTextAreaAutosize = Pick<\n ComponentProps<typeof TextAreaAutosize>,\n 'minRows' | 'maxRows' | 'value'\n>;\ntype Props = PickedPropsFromTextAreaAutosize & {\n isReadonly?: boolean;\n enabledElementRef: Ref<HTMLTextAreaElement>;\n readonlyElementRef: Ref<HTMLTextAreaElement | HTMLDivElement>;\n};\n\n// TODO: Make this fire when the container resizes - JET-50840\nexport const useTextAreaAutosizing = ({\n isReadonly,\n enabledElementRef,\n readonlyElementRef,\n minRows = 2,\n maxRows,\n value\n}: Props) => {\n useLayoutEffect(() => {\n const textareaRef = isReadonly ? readonlyElementRef : enabledElementRef;\n if (textareaRef.current === null) return;\n if (textareaRef.current instanceof HTMLDivElement) return; // We don't need to do anything if the readonlyElement is a DIV.\n const textarea = textareaRef.current;\n const lineHeight = calculateLineHeight(textarea);\n textarea.style.height = '0';\n const { paddingHeight, borderHeight } = getStylingHeight(textarea);\n const heightForMinRows = lineHeight * minRows + paddingHeight + borderHeight;\n const scrollHeight = textarea.scrollHeight + borderHeight;\n let resizedHeight = 0;\n // if maxRows is -1 the textarea will grow or shrink to fit all the content.\n // it won't shrink any less than rows.\n if (maxRows === undefined) {\n // we want to fit the entire scrollHeight, but we don't want\n // to shrink smaller than the height for rows.\n if (scrollHeight < heightForMinRows) {\n resizedHeight = heightForMinRows;\n } else {\n resizedHeight = scrollHeight;\n }\n } else if (maxRows > minRows) {\n // if maxRows is positive and greater than rows, the textarea will grow to fit the content\n // up to maxrows, or shrink to fit the content and down to rows.\n const heightForMaxRows = lineHeight * maxRows + paddingHeight + borderHeight;\n if (scrollHeight > heightForMaxRows) {\n resizedHeight = heightForMaxRows;\n } else if (scrollHeight < heightForMinRows) {\n resizedHeight = heightForMinRows;\n } else {\n resizedHeight = scrollHeight;\n }\n } else {\n resizedHeight = heightForMinRows;\n }\n // The 0.5 gaurantees that the clientHeight will be bigger than the scrollHeight, so no scrollbar appears.\n textarea.style.height = resizedHeight + 0.5 + 'px';\n }, [value, minRows, maxRows, isReadonly]);\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 */\n\nimport { ComponentProps, Fragment, Ref } from 'preact';\nimport { forwardRef, useCallback } from 'preact/compat';\nimport { useFormContext } from '../hooks/UNSAFE_useFormContext';\nimport { FormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { FocusableHandle, useFocusableTextField } from '../hooks/UNSAFE_useFocusableTextField';\nimport { Label } from '../UNSAFE_Label';\nimport {\n ReadonlyTextField,\n ReadonlyTextFieldInput,\n TextField,\n TextFieldInput\n} from '../UNSAFE_TextField';\nimport { useTextField } from '../hooks/UNSAFE_useTextField';\nimport { InlineUserAssistance } from '../UNSAFE_UserAssistance';\nimport { CountUnit, useLengthFilter } from '../hooks/UNSAFE_useLengthFilter';\nimport { MaxLengthLiveRegion } from '../UNSAFE_TextField';\nimport { useTextAreaAutosizing } from './useTextAreaAutosizing';\nimport { Size } from '../utils/UNSAFE_size';\nimport { useCurrentValueReducer } from '../hooks/UNSAFE_useCurrentValueReducer';\nimport { ValueUpdateDetail } from '../utils/UNSAFE_valueUpdateDetail';\nimport { MaxLengthCounter } from '../UNSAFE_TextArea';\n\ntype TextFieldInputProps = ComponentProps<typeof TextFieldInput>;\ntype InlineUserAssistanceProps = ComponentProps<typeof InlineUserAssistance>;\n\ntype Props = {\n /**\n * The ID of an element (or space separated IDs of multiple elements) that\n * describes the input.\n */\n ariaDescribedBy?: TextFieldInputProps['ariaDescribedBy'];\n /**\n * Text to provide guidance to help the user understand what to enter.\n */\n assistiveText?: InlineUserAssistanceProps['assistiveText'];\n /**\n * Dictates component's autocomplete state.\n * This attribute indicates whether the value of the control can be automatically completed by the browser.\n * The common values are \"on\" and \"off\".\n */\n autoComplete?: TextFieldInputProps['autoComplete'];\n /**\n * Autofocus specifies whether the component will get focus when the page is loaded.\n * If it is set to true then the associated component will get input focus when the page is loaded.\n * Setting this property doesn't set the focus to the component; it tells the browser to focus\n * to it when the element is inserted in the document.\n */\n autoFocus?: TextFieldInputProps['autoFocus'];\n /**\n * Help source URL associated with the component.\n */\n helpSourceLink?: InlineUserAssistanceProps['helpSourceLink'];\n /**\n * Custom text to be rendered for the <code>helpSourceLink</code>.\n */\n helpSourceText?: InlineUserAssistanceProps['helpSourceText'];\n /**\n * Specifies whether the component is disabled.\n */\n isDisabled?: boolean;\n /**\n * Specifies whether the component is readonly.\n */\n isReadonly?: boolean;\n /**\n * Specifies for accessibility purposes whether a value is required.\n *\n * Setting this property to <code>false</code> means that a value is not required to be\n * committed by the user. Setting this property to <code>true</code> means that a value\n * is required to be committed by the user.\n */\n isRequired?: TextFieldInputProps['isRequired'];\n /**\n * Specifies whether to show an indicator on screen that a value is required, for example\n * before the user has committed a value.\n */\n isRequiredShown?: InlineUserAssistanceProps['isRequiredShown'];\n /**\n * Specifies the label associated with the field.\n */\n label: string;\n /**\n * Specifies where the label is positioned relative to the field.\n */\n labelEdge?: 'inside' | 'start' | 'top' | 'none';\n /**\n * Specifies the width of the label when <code>labelEdge</code> is <code>\"start\"</code>\n */\n labelStartWidth?: Size;\n /**\n * Specifies the maximum number of characters that can be entered in the input field.\n */\n maxLength?: number;\n /**\n * Determines whether the remaining number of characters that can be entered is shown or not.\n */\n maxLengthCounter?: 'none' | 'remaining';\n /**\n * Specifies how the input text characters are to be counted when maxLength is specified.\n */\n maxLengthUnit?: CountUnit;\n /**\n * Specifies the maximum number of rows that the TextAreaAutosize is allowed to grow to.\n * If maxRows is less than minRows, it is ignored.\n */\n maxRows?: number;\n /**\n * Messages to show on screen that are associated with the component.\n */\n messages?: InlineUserAssistanceProps['messages'];\n /**\n * Specifies the minimum number of rows that the TextAreaAutosize is allowed to shrink to.\n */\n minRows?: number;\n /**\n * A short hint to display before the user enters a value.\n */\n placeholder?: TextFieldInputProps['placeholder'];\n /**\n * Specifies how the user is allowed to manually resize the TextArea component.\n */\n role?: TextFieldInputProps['role'];\n /**\n * Specifies the number of rows to display\n */\n textAlign?: TextFieldInputProps['textAlign'];\n /**\n * Specifies the density of the user assistance presentation. It can be set to:\n * <ul>\n * <li><code>'efficient'</code>: Show inline and reserve space to prevent layout reflow when user\n * assistance text is displayed.</li>\n * <li><code>'reflow'</code>: Show inline. Layout will reflow when text is displayed.</li>\n * </ul>\n */\n userAssistanceDensity?: InlineUserAssistanceProps['userAssistanceDensity'];\n /**\n * The current display value of the component.\n */\n value?: TextFieldInputProps['value'];\n /**\n * The style variant of the component.\n */\n variant?: TextFieldInputProps['variant'];\n /**\n * Callback invoked when the user commits the entered value by blurring out of the field.\n *\n */\n onCommit?: TextFieldInputProps['onCommit'];\n\n /**\n * Callback invoked when the user inputs a value.\n *\n */\n onInput: TextFieldInputProps['onInput'];\n};\nexport const TextAreaAutosize = forwardRef(\n (\n {\n ariaDescribedBy,\n assistiveText,\n autoComplete = 'off',\n autoFocus = false,\n helpSourceLink,\n helpSourceText,\n isDisabled: propIsDisabled,\n isReadonly: propIsReadonly,\n isRequired = false,\n isRequiredShown,\n label,\n labelEdge: propLabelEdge,\n labelStartWidth: propLabelStartWidth,\n maxLength,\n maxLengthCounter = 'remaining',\n maxLengthUnit,\n maxRows,\n messages,\n minRows = 2,\n placeholder,\n role,\n //TODO: Add counter to show the length remaining - JET-50752\n textAlign: propTextAlign,\n userAssistanceDensity: propUserAssistanceDensity,\n value,\n variant = 'default',\n onInput,\n onCommit\n }: Props,\n ref?: Ref<FocusableHandle>\n ) => {\n const { currentCommitValue, dispatch } = useCurrentValueReducer({ value });\n const onInputAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'input', payload: detail.value });\n onInput?.(detail);\n },\n [onInput]\n );\n const onCommitAndDispatch = useCallback(\n (detail: ValueUpdateDetail<string>) => {\n // Should dispatch happen first? This will queue up a re-render, ordering should not cause issues (this is async)\n dispatch({ type: 'commit', payload: detail.value });\n onCommit?.(detail);\n },\n [onCommit]\n );\n const {\n isDisabled: isFormDisabled,\n isReadonly: isFormReadonly,\n labelEdge: formLabelEdge,\n labelStartWidth: formLabelStartWidth,\n textAlign: formTextAlign,\n userAssistanceDensity: formUserAssistanceDensity\n } = useFormContext();\n // default to FormContext values if component properties are not specified\n const isDisabled = propIsDisabled ?? isFormDisabled;\n const isReadonly = propIsReadonly ?? isFormReadonly;\n const labelEdge = propLabelEdge ?? formLabelEdge;\n const labelStartWidth = propLabelStartWidth ?? formLabelStartWidth;\n const textAlign = propTextAlign ?? formTextAlign;\n const userAssistanceDensity = propUserAssistanceDensity ?? formUserAssistanceDensity;\n\n const { enabledElementRef, readonlyElementRef, focusProps, isFocused } = useFocusableTextField<\n HTMLTextAreaElement,\n HTMLTextAreaElement | HTMLDivElement\n >({ isDisabled, isReadonly, ref });\n\n const { formFieldContext, inputProps, labelProps, textFieldProps, userAssistanceProps } =\n useTextField({\n ariaDescribedBy,\n contentVariant: 'textarea',\n isDisabled,\n isFocused,\n isReadonly,\n labelEdge,\n messages,\n styleVariant: variant,\n value\n });\n\n // Handle length filter for user-typed inputs and controlled inputs\n const { isMaxLengthExceeded, valueLength, onFilteredInput } = useLengthFilter({\n maxLength,\n maxLengthUnit,\n value,\n onInput: onInputAndDispatch,\n onCommit: onCommitAndDispatch\n });\n\n const labelComp = labelEdge !== 'none' ? <Label {...labelProps}>{label}</Label> : undefined;\n\n const fieldLabelProps = {\n label: labelEdge !== 'none' ? labelComp : undefined,\n labelEdge: labelEdge !== 'none' ? labelEdge : undefined,\n labelStartWidth: labelEdge !== 'none' ? labelStartWidth : undefined\n };\n const ariaLabel = labelEdge === 'none' ? label : undefined;\n\n const inlineUserAssistance =\n isDisabled || isReadonly ? (\n // save space for user assistance if density is 'efficient', even though we don't\n // render user assistance for disabled or readonly fields\n userAssistanceDensity !== 'efficient' ? undefined : (\n <InlineUserAssistance\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n )\n ) : (\n <InlineUserAssistance\n assistiveText={assistiveText}\n fieldLabel={label}\n helpSourceLink={helpSourceLink}\n helpSourceText={helpSourceText}\n messages={messages}\n isRequiredShown={isRequiredShown}\n userAssistanceDensity={userAssistanceDensity}\n {...userAssistanceProps}\n />\n );\n\n useTextAreaAutosizing({\n isReadonly,\n enabledElementRef,\n readonlyElementRef,\n minRows,\n maxRows,\n value\n });\n\n if (isReadonly) {\n // TODO: should be able to configure whether start/end content is shown when readonly\n // JET-49916 - Preact InputText: show start/end content when readonly\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <ReadonlyTextField\n role=\"presentation\"\n inlineUserAssistance={inlineUserAssistance}\n variant=\"textarea\"\n {...fieldLabelProps}>\n <ReadonlyTextFieldInput\n ariaDescribedBy={ariaDescribedBy}\n ariaLabel={ariaLabel}\n ariaLabelledBy={labelProps.id}\n elementRef={readonlyElementRef}\n {...(maxRows ? { as: 'textarea', rows: minRows } : { as: 'div' })}\n autoFocus={autoFocus}\n textAlign={textAlign}\n value={value}\n variant=\"textarea\"\n hasInsideLabel={label !== undefined && labelEdge === 'inside'}\n />\n </ReadonlyTextField>\n </FormFieldContext.Provider>\n );\n }\n\n const onClickCounter = useCallback(() => {\n const elm = enabledElementRef.current;\n // for setSelectionRange(), len needs to be a number or null.\n const len = elm ? elm.value.length : null;\n // Since the counter element is after the text, clicking in this\n // should put the selection at the end of the text\n enabledElementRef.current?.setSelectionRange(len, len);\n // Clicking the counter should put the focus on the input field\n enabledElementRef.current?.focus();\n }, []);\n\n const mainContent = (\n <Fragment>\n <TextFieldInput\n as=\"textarea\"\n ariaLabel={ariaLabel}\n autoComplete={autoComplete}\n autoFocus={autoFocus}\n currentCommitValue={currentCommitValue}\n hasInsideLabel={labelComp !== undefined && labelEdge === 'inside'}\n isRequired={isRequired}\n inputRef={enabledElementRef}\n onCommit={onCommitAndDispatch}\n onInput={onFilteredInput}\n placeholder={placeholder}\n role={role}\n rows={minRows}\n textAlign={textAlign}\n value={value}\n {...inputProps}\n />\n {maxLengthCounter === 'remaining' && maxLength !== undefined && (\n <MaxLengthCounter\n {...{ maxLength, valueLength, parentHasFocus: isFocused, onClick: onClickCounter }}\n />\n )}\n {maxLength !== undefined && (\n <MaxLengthLiveRegion {...{ isMaxLengthExceeded, maxLength, valueLength }} />\n )}\n </Fragment>\n );\n\n return (\n <FormFieldContext.Provider value={formFieldContext}>\n <TextField\n mainContent={mainContent}\n inlineUserAssistance={inlineUserAssistance}\n onBlur={focusProps?.onfocusout}\n onFocus={focusProps?.onfocusin}\n {...textFieldProps}\n {...fieldLabelProps}></TextField>\n </FormFieldContext.Provider>\n );\n }\n);\n"],"names":["useTextAreaAutosizing","isReadonly","enabledElementRef","readonlyElementRef","minRows","maxRows","value","useLayoutEffect","textareaRef","current","HTMLDivElement","textarea","lineHeight","computedStyle","window","getComputedStyle","computedlineHeight","parseFloat","fontSize","calculateLineHeight","style","height","paddingHeight","borderHeight","cssStyle","paddingTop","paddingBottom","borderTop","borderBottom","getStylingHeight","heightForMinRows","scrollHeight","resizedHeight","undefined","heightForMaxRows","TextAreaAutosize","forwardRef","ariaDescribedBy","assistiveText","autoComplete","autoFocus","helpSourceLink","helpSourceText","isDisabled","propIsDisabled","propIsReadonly","isRequired","isRequiredShown","label","labelEdge","propLabelEdge","labelStartWidth","propLabelStartWidth","maxLength","maxLengthCounter","maxLengthUnit","messages","placeholder","role","textAlign","propTextAlign","userAssistanceDensity","propUserAssistanceDensity","variant","onInput","onCommit","ref","currentCommitValue","dispatch","useCurrentValueReducer","onInputAndDispatch","useCallback","detail","type","payload","onCommitAndDispatch","isFormDisabled","isFormReadonly","formLabelEdge","formLabelStartWidth","formTextAlign","formUserAssistanceDensity","useFormContext","focusProps","isFocused","useFocusableTextField","formFieldContext","inputProps","labelProps","textFieldProps","userAssistanceProps","useTextField","contentVariant","styleVariant","isMaxLengthExceeded","valueLength","onFilteredInput","useLengthFilter","labelComp","_jsx","Label","Object","assign","fieldLabelProps","ariaLabel","inlineUserAssistance","jsx","InlineUserAssistance","fieldLabel","FormFieldContext","Provider","children","ReadonlyTextField","ReadonlyTextFieldInput","ariaLabelledBy","id","elementRef","as","rows","hasInsideLabel","onClickCounter","elm","len","length","_a","setSelectionRange","_b","focus","mainContent","_jsxs","Fragment","TextFieldInput","inputRef","MaxLengthCounter","parentHasFocus","onClick","MaxLengthLiveRegion","TextField","onBlur","onfocusout","onFocus","onfocusin"],"mappings":"wgBACO,MCeMA,EAAwB,EACnCC,WAAAA,EACAC,kBAAAA,EACAC,mBAAAA,EACAC,QAAAA,EAAU,EACVC,QAAAA,EACAC,MAAAA,MAEAC,EAAAA,gBAAgB,KACd,MAAMC,EAAcP,EAAaE,EAAqBD,EACtD,GAA4B,OAAxBM,EAAYC,QAAkB,OAClC,GAAID,EAAYC,mBAAmBC,eAAgB,OACnD,MAAMC,EAAWH,EAAYC,QACvBG,ED5ByB,CAACD,IAClC,MAAME,EAAgBC,OAAOC,iBAAiBJ,GACxCK,EAAqBH,EAAcD,WACzC,GAA2B,WAAvBI,EAMF,OAAO,IADUC,WAAWJ,EAAcK,UAG5C,OAAOD,WAAWD,ICiBGG,CAAoBR,GACvCA,EAASS,MAAMC,OAAS,IACxB,MAAMC,cAAEA,EAAaC,aAAEA,GDjBK,CAACZ,IAC/B,MAAMa,EAAWV,OAAOC,iBAAiBJ,GAKzC,MAAO,CAAEW,cAJUL,WAAWO,EAASC,YACjBR,WAAWO,EAASE,eAGUH,aAFlCN,WAAWO,EAASG,WACjBV,WAAWO,EAASI,gBCYCC,CAAiBlB,GACnDmB,EAAmBlB,EAAaR,EAAUkB,EAAgBC,EAC1DQ,EAAepB,EAASoB,aAAeR,EAC7C,IAAIS,EAAgB,EAGpB,QAAgBC,IAAZ5B,EAIA2B,EADED,EAAeD,EACDA,EAEAC,OAEb,GAAI1B,EAAUD,EAAS,CAG5B,MAAM8B,EAAmBtB,EAAaP,EAAUiB,EAAgBC,EAE9DS,EADED,EAAeG,EACDA,EACPH,EAAeD,EACRA,EAEAC,OAGl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vF,IAAdoB,GACC8C,EAAAA,IAACqC,EAAAA,oBAAmBnC,OAAAC,OAAA,GAAK,CAAER,oBAAAA,GAAqBzC,UAAAA,EAAW0C,YAAAA,SAKjE,OACEI,MAACU,EAAgBA,iBAACC,SAAST,OAAAC,OAAA,CAAAhG,MAAOgF,IAAgB,CAAAyB,SAChDZ,EAAAA,IAACsC,EAASA,UAAApC,OAAAC,OAAA,CACR0B,YAAaA,GACbvB,qBAAsBA,GACtBiC,OAAQvD,MAAAA,UAAAA,GAAYwD,WACpBC,QAASzD,MAAAA,UAAAA,GAAY0D,WACjBpD,GACAc"}
@@ -0,0 +1,2 @@
1
+ define(["exports","./tslib.es6-9d88853c","preact/jsx-runtime",'module',"./hooks/UNSAFE_useFormFieldContext","./hooks/UNSAFE_useTabbableMode","./hooks/UNSAFE_useTextFieldInputHandlers","./utils/UNSAFE_classNames","./utils/UNSAFE_interpolations/text","./utils/UNSAFE_mergeInterpolations","./FormControlUtils-aaa1780b","./classNames-f3dd3ee3"],function(a,e,t,i,s,l,o,r,n,u,d,p){"use strict";const c="ofsao2",m="pjubr1",b="eec9kr",x="_14l2tf8",_="m7z0mf",f="_149nz3u",h="_5xnpfm",y="fge9jb",C="_5l0a3t",v="_4hgq27",F="_1jd71sp",I="_1mwcy9",N="_14tv5o7",w="_1ccckc4",g="_1veqkwz",S="_1nz7p0f",V="spid27",E="rlbief",U="_15ipr1z",j="_1188uur",k="zs5jwz",A="_1tmp069",L="_11x07sc",T="_1c3xb16",z="_1a21hz9",M="d3t6yo",D="n6a5de",K=[...Object.values(n.textInterpolations)],R=u.mergeInterpolations(K);a.TextFieldInput=a=>{var{as:i="input",ariaAutoComplete:r,ariaControls:n,ariaDescribedBy:u,ariaExpanded:c,ariaInvalid:m,ariaLabel:b,ariaLabelledBy:x,ariaValueMax:_,ariaValueMin:f,ariaValueNow:h,ariaValueText:y,autoComplete:C,autoFocus:K,currentCommitValue:q,hasEndContent:B=!1,hasInsideLabel:P=!1,hasPrefix:H=!1,hasStartContent:O=!1,hasSuffix:G=!1,id:J,inputRef:Q,placeholder:W,isRequired:X,role:Y,rows:Z,spellcheck:$,type:aa,value:ea="",variant:ta="default",onInput:ia,onCommit:sa,onKeyDown:la,onKeyUp:oa}=a,ra=e.__rest(a,["as","ariaAutoComplete","ariaControls","ariaDescribedBy","ariaExpanded","ariaInvalid","ariaLabel","ariaLabelledBy","ariaValueMax","ariaValueMin","ariaValueNow","ariaValueText","autoComplete","autoFocus","currentCommitValue","hasEndContent","hasInsideLabel","hasPrefix","hasStartContent","hasSuffix","id","inputRef","placeholder","isRequired","role","rows","spellcheck","type","value","variant","onInput","onCommit","onKeyDown","onKeyUp"]);const na=""!==ea,{isDisabled:ua,isFocused:da,isLoading:pa,isReadonly:ca}=s.useFormFieldContext(),ma=((a,e,t)=>!(a&&!e&&!t))(P,na,da)?W:void 0,{class:ba}=R(ra),xa=!ua&&H,_a=!ua&&G,fa=p.classNames(["oj-c-text-field-input",v,"default"===ta?p.classNames([T,"textarea"===i&&I,"input"===i&&F,"password"===aa&&N,!O&&!xa&&z,!B&&!_a&&M]):D,P&&p.classNames([g,"textarea"===i&&S,!na&&da&&V]),!P&&"textarea"!==i&&w,O&&!H&&E,B&&!G&&U,ua?k:j,xa&&A,_a&&L,ba]),ha=i||"input",ya=o.useTextFieldInputHandlers({currentCommitValue:q,value:ea,onInput:ia,onCommit:sa,onKeyDown:la}),{isTabbable:Ca,tabbableModeProps:va}=l.useTabbableMode();return t.jsx(ha,Object.assign({"aria-autocomplete":r,"aria-controls":n,"aria-describedby":u,"aria-expanded":c,"aria-invalid":m,"aria-label":pa?d.getLoadingAriaLabel():b||void 0,"aria-labelledby":x,"aria-required":!!X||void 0,"aria-valuemax":_,"aria-valuemin":f,"aria-valuenow":h,"aria-valuetext":y,autocomplete:C,autofocus:K,class:fa,disabled:ua,id:J,onKeyUp:oa,placeholder:ma,readonly:ca,ref:Q,role:Y,rows:Z,spellcheck:$,type:aa,value:ea},ya,!Ca&&va))},a.getInputId=a=>(null!=a?a:"")+"|input",a.getReadonlyClasses=(a,e,t)=>p.classNames([x,"textarea"===t&&f,a?_:y,"textarea"===t&&!a&&C,a&&e&&h]),a.getTextFieldClasses=(a,e)=>p.classNames([c,"embedded"===e&&m,!a&&b]),a.loadingStyles="_1m2pr13"});
2
+ //# sourceMappingURL=TextFieldInput-2719b778.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"TextFieldInput-40ce4927.js","sources":["../../src/UNSAFE_TextField/TextFieldUtils.ts","../../src/UNSAFE_TextField/TextFieldInput.tsx"],"sourcesContent":["import { classNames } from '../utils/UNSAFE_classNames';\nimport { cssProps } from '@oracle/oraclejet-cssprops';\n\nconst textFieldStyles = {\n base: cssProps`${{\n display: 'inline-block',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-line-height)',\n maxWidth: '100%',\n width: '100%',\n boxSizing: 'border-box'\n }}`,\n\n embedded: cssProps`${{\n height: '100%'\n }}`,\n\n nonReadonly: cssProps`${{\n fontWeight: '400',\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-font-size)'\n }}`\n};\n\nconst readonlyStyles = {\n base: cssProps`${{\n fontWeight: 'var(--oj-form-control-font-weight-read-only)',\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-font-size)',\n position: 'relative',\n borderStyle: 'solid',\n transitionProperty: 'border-color',\n transitionDuration: '0.1s',\n transitionTimingFunction: 'linear',\n borderRadius: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-border-radius)',\n flexDirection: 'row',\n alignItems: 'center',\n maxWidth: '100%',\n width: '100%',\n boxSizing: 'border-box'\n }}`,\n\n insideEnabledForm: cssProps`${{\n overflowX: 'hidden',\n overflowY: 'hidden',\n borderWidth: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-border-width)',\n borderColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-border-color-disabled)',\n backgroundColor: 'transparent',\n height: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-height)',\n minWidth: '1em',\n display: 'inline-flex',\n flex: '1'\n }}`,\n\n textarea: cssProps`${{\n height: 'auto'\n }}`,\n\n insideEnabledFormLabelInside: cssProps`${{\n minHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-inside-edge-height)'\n }}`,\n\n notInsideEnabledForm: cssProps`${{\n overflowX: 'visible',\n overflowY: 'visible',\n borderWidth: '0',\n backgroundColor: 'transparent',\n height: 'auto'\n }}`,\n\n textareaNotInsideEnabledForm: cssProps`${{\n paddingTop: '0',\n paddingBottom: '0'\n }}`\n};\n\n//Consolidating all loading styles on form elements here\nexport const loadingStyles = cssProps`${{\n backgroundColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-animation-skeleton-bg-end-color)',\n backgroundSize: '200% 200%',\n borderWidth: '0',\n // need to use a var for the animation name because otherwise linaria will obfuscate it\n // and make it different from the actual keyframes name\n animationName: 'var(--oj-c-PRIVATE-DO-NOT-USE-private-preact-text-field-animation-name-skeleton)',\n animationIterationCount: 'infinite',\n animationDirection: 'alternate',\n animationDuration: '1.5s',\n opacity: '1'\n}}`;\n\nexport const getTextFieldClasses = (readonly?: boolean, variant?: 'default' | 'embedded') => {\n return classNames([\n textFieldStyles.base,\n variant === 'embedded' && textFieldStyles.embedded,\n !readonly && textFieldStyles.nonReadonly\n ]);\n};\n\nexport const getReadonlyClasses = (\n isInsideNonReadonlyForm?: boolean,\n hasInsideLabel?: boolean,\n variant?: 'textarea'\n) => {\n const classes = classNames([\n readonlyStyles.base,\n variant === 'textarea' && readonlyStyles.textarea,\n isInsideNonReadonlyForm\n ? readonlyStyles.insideEnabledForm\n : readonlyStyles.notInsideEnabledForm,\n variant === 'textarea' &&\n !isInsideNonReadonlyForm &&\n readonlyStyles.textareaNotInsideEnabledForm,\n isInsideNonReadonlyForm && hasInsideLabel && readonlyStyles.insideEnabledFormLabelInside\n ]);\n return classes;\n};\n\nexport const getInputId = (id?: string) => {\n return (id ?? '') + '|input';\n};\n\nexport const isInputPlaceholderShown = (\n hasInsideLabel: boolean,\n hasValue: boolean,\n isFocused?: boolean\n) => {\n return !(hasInsideLabel && !hasValue && !isFocused);\n};\n","import { cssProps } from '@oracle/oraclejet-cssprops';\nimport { Ref } from 'preact';\nimport { useFormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { useTabbableMode } from '../hooks/UNSAFE_useTabbableMode';\nimport { useTextFieldInputHandlers } from '../hooks/UNSAFE_useTextFieldInputHandlers';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport type { TextProps } from '../utils/UNSAFE_interpolations/text';\nimport { textInterpolations } from '../utils/UNSAFE_interpolations/text';\nimport { mergeInterpolations } from '../utils/UNSAFE_mergeInterpolations';\nimport { ValueUpdateDetail } from '../utils/UNSAFE_valueUpdateDetail';\nimport { getLoadingAriaLabel } from './FormControlUtils';\nimport { isInputPlaceholderShown } from './TextFieldUtils';\nimport { HTMLAttributesSignalExcluded } from '../utils/UNSAFE_attributeUtils';\n\nconst rootStyles = {\n base: cssProps`${{\n // normally removing an outline can cause accessibility issues, however\n // on an input the cursor blinks so an outline is not required for\n // accessibility. As of 6-11-14 only chrome is putting\n // an outline on inputs anyway\n outlineStyle: 'none',\n outlineWidth: '0',\n boxSizing: 'border-box',\n fontFamily: 'inherit',\n lineHeight: 'inherit',\n fontWeight: 'inherit',\n border: '0',\n backgroundColor: 'transparent',\n width: '100%',\n\n '&::selection': {\n backgroundColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-bg-color-selected)'\n }\n }}`,\n // removes margin that Safari adds to the input element\n input: cssProps`${{\n margin: '0'\n }}`,\n textarea: cssProps`${{\n paddingTop:\n 'calc((var(--oj-c-PRIVATE-DO-NOT-USE-text-field-height) - 1rem * var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-line-height))/ 2 - 1px)',\n paddingBottom:\n 'calc((var(--oj-c-PRIVATE-DO-NOT-USE-text-field-height) - 1rem * var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-line-height))/ 2 - 1px)',\n\n resize: 'none'\n }}`,\n password: cssProps`${{\n '&::-ms-reveal': {\n display: 'none'\n }\n }}`,\n labelDefaultPadding: cssProps`${{\n paddingTop: 0,\n paddingBottom: 0\n }}`,\n labelInsideBase: cssProps`${{\n minHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-inside-edge-height)',\n paddingTop: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-inside-edge-padding-top)',\n paddingBottom: 0,\n\n '&:hover': {\n backgroundColor: 'transparent'\n }\n }}`,\n textareaLabelInsideBase: cssProps`${{\n paddingTop: 0,\n paddingBottom: 0,\n // We are using a transparent border here instead of padding, due to how textarea scrolls the padding off the screen\n // and the text content will clash with the inside label.\n borderColor: 'transparent',\n borderStyle: 'solid',\n borderBlockStartWidth:\n 'calc(var(--oj-c-PRIVATE-DO-NOT-USE-label-inside-edge-font-size) * var(--oj-c-PRIVATE-DO-NOT-USE-label-inside-edge-line-height) + var(--oj-c-PRIVATE-DO-NOT-USE-label-inside-edge-position-top))',\n // The 0.25rem is an aesthetically pleasing amount of bottom padding\n borderBlockEndWidth: '0.25rem'\n }}`,\n\n labelInsideNoValueAndHasFocus: cssProps`${{\n animationName:\n 'var(--oj-c-PRIVATE-DO-NOT-USE-private-preact-text-field-animation-name-placeholder)',\n animationDuration: 'var(--oj-c-PRIVATE-DO-NOT-USE-animation-duration-xlong)',\n animationTimingFunction: 'var(--oj-c-PRIVATE-DO-NOT-USE-animation-ease-in)'\n }}`,\n\n hasStartContent: cssProps`${{\n paddingInlineStart: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-icon-to-text-padding)'\n }}`,\n\n hasEndContent: cssProps`${{\n paddingInlineEnd: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-icon-to-text-padding)'\n }}`,\n\n defaultColor: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-color)'\n }}`,\n\n disabledColor: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-color-disabled)'\n }}`,\n // The 0.25em is the space between the prefix and the input. This is equivalent to ' '.\n hasPrefix: cssProps`${{\n paddingInlineStart: '.25em'\n }}`,\n\n hasSuffix: cssProps`${{\n paddingInlineEnd: '.25em'\n }}`,\n\n default: cssProps`${{\n fontSize: '100%'\n }}`,\n\n defaultPaddingStart: cssProps`${{\n paddingInlineStart: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding)'\n }}`,\n\n defaultPaddingEnd: cssProps`${{\n paddingInlineEnd: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding)'\n }}`,\n\n embedded: cssProps`${{\n color: 'inherit',\n fontSize: 'inherit',\n height: '100%',\n margin: 0,\n paddingBlock: 0,\n paddingInline:\n 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-embedded-padding, var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding))',\n\n // textarea styles\n resize: 'none',\n\n // input-password styles\n '&::-ms-reveal': {\n display: 'none'\n }\n }}`\n};\n\nconst interpolations = [...Object.values(textInterpolations)];\n\nconst styleInterpolations = mergeInterpolations<Props>(interpolations);\n\ntype Autocomplete = 'off' | 'on' | string;\n\ntype OrigPickedPropsFromInput = Pick<\n HTMLAttributesSignalExcluded<HTMLInputElement>,\n 'autofocus' | 'id' | 'placeholder' | 'required' | 'role' | 'spellcheck' | 'type'\n>;\ntype RenamedPropsFromInput = Omit<OrigPickedPropsFromInput, 'autofocus' | 'required'> & {\n autoFocus?: OrigPickedPropsFromInput['autofocus'];\n isRequired?: OrigPickedPropsFromInput['required'];\n};\ntype InputProps = {\n as?: 'input';\n type?: Pick<HTMLAttributesSignalExcluded<HTMLInputElement>, 'type'>['type'];\n rows?: never;\n inputRef?: Ref<HTMLInputElement>;\n hasPrefix?: boolean;\n hasSuffix?: boolean;\n};\n\ntype TextAreaProps = {\n as: 'textarea';\n type?: never;\n rows?: number;\n inputRef?: Ref<HTMLTextAreaElement>;\n hasPrefix?: never;\n hasSuffix?: never;\n};\n\ntype UniqueProps = InputProps | TextAreaProps;\n\ntype AriaProps = {\n ariaAutoComplete?: 'none' | 'inline' | 'list' | 'both';\n ariaControls?: string;\n ariaDescribedBy?: string;\n ariaExpanded?: boolean;\n ariaInvalid?: string;\n ariaLabel?: string;\n ariaLabelledBy?: string;\n ariaValueMax?: number;\n ariaValueMin?: number;\n ariaValueNow?: number;\n ariaValueText?: string;\n};\n\ntype Props = UniqueProps &\n TextProps &\n RenamedPropsFromInput &\n AriaProps & {\n autoComplete?: Autocomplete;\n // TODO: Should we expose has* props like these or should we pass this info\n // via FormFieldContext? (from review on 3/8/22)\n currentCommitValue?: string;\n hasEndContent?: boolean;\n hasInsideLabel?: boolean;\n hasStartContent?: boolean;\n value?: string;\n variant?: 'default' | 'embedded';\n onInput?: (detail: ValueUpdateDetail<string>) => void;\n onCommit?: (detail: ValueUpdateDetail<string>) => void;\n onKeyDown?: (event: KeyboardEvent) => void;\n onKeyUp?: (event: KeyboardEvent) => void;\n };\n\nexport const TextFieldInput = ({\n as = 'input',\n ariaAutoComplete,\n ariaControls,\n ariaDescribedBy,\n ariaExpanded,\n ariaInvalid,\n ariaLabel,\n ariaLabelledBy,\n ariaValueMax,\n ariaValueMin,\n ariaValueNow,\n ariaValueText,\n autoComplete,\n autoFocus,\n currentCommitValue,\n hasEndContent = false,\n hasInsideLabel = false,\n hasPrefix = false,\n hasStartContent = false,\n hasSuffix = false,\n id,\n inputRef,\n placeholder,\n isRequired,\n role,\n rows,\n spellcheck,\n type,\n value = '',\n variant = 'default',\n onInput,\n onCommit,\n onKeyDown,\n onKeyUp,\n ...props\n}: Props) => {\n const hasValue = value !== '';\n const { isDisabled, isFocused, isLoading, isReadonly } = useFormFieldContext();\n const myPlaceholder = isInputPlaceholderShown(hasInsideLabel, hasValue, isFocused)\n ? placeholder\n : undefined;\n const { class: styleInterpolationClasses } = styleInterpolations(props);\n const renderPrefix = !isDisabled && hasPrefix;\n const renderSuffix = !isDisabled && hasSuffix;\n const inputClasses = classNames([\n 'oj-c-text-field-input',\n rootStyles.base,\n variant === 'default'\n ? classNames([\n rootStyles.default,\n as === 'textarea' && rootStyles.textarea,\n as === 'input' && rootStyles.input,\n type === 'password' && rootStyles.password,\n !hasStartContent && !renderPrefix && rootStyles.defaultPaddingStart,\n !hasEndContent && !renderSuffix && rootStyles.defaultPaddingEnd\n ])\n : rootStyles.embedded,\n hasInsideLabel &&\n classNames([\n rootStyles.labelInsideBase,\n as === 'textarea' && rootStyles.textareaLabelInsideBase,\n !hasValue && isFocused && rootStyles.labelInsideNoValueAndHasFocus\n ]),\n !hasInsideLabel && as !== 'textarea' && rootStyles.labelDefaultPadding,\n // We want the input to have padding on itself. This gives the user more space to click on to set focus to the input.\n // The padding between the input and the icon is different than the padding between the input and prefix/suffix (since they are both text)\n // startcontentpadding+input+endcontentpadding\n hasStartContent && !hasPrefix && rootStyles.hasStartContent,\n hasEndContent && !hasSuffix && rootStyles.hasEndContent,\n isDisabled ? rootStyles.disabledColor : rootStyles.defaultColor,\n // prefix+prefixpadding+input+suffixpadding+suffix\n // if there is also a startcontent or end content,\n // the prefix/suffix will have that padding on it (see PrefixSuffix)\n renderPrefix && rootStyles.hasPrefix,\n renderSuffix && rootStyles.hasSuffix,\n styleInterpolationClasses\n ]);\n const Comp = as || 'input';\n const handlers = useTextFieldInputHandlers({\n currentCommitValue,\n value,\n onInput,\n onCommit,\n onKeyDown\n });\n // the implicit default for tabindex on an input is 0, so do not explicitly set it.\n // JET-52914 - Implement Tabbable mode API contract in InputText\n // if not tabbable, spread tabbableModeProps on component\n const { isTabbable, tabbableModeProps } = useTabbableMode();\n // TODO: for autoComplete='off', need to configure attrs appropriately to make sure it\n // works across browsers and versions (from review on 3/11/22)\n return (\n <Comp\n aria-autocomplete={ariaAutoComplete}\n aria-controls={ariaControls}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-invalid={ariaInvalid}\n aria-label={isLoading ? getLoadingAriaLabel() : ariaLabel ? ariaLabel : undefined}\n aria-labelledby={ariaLabelledBy}\n aria-required={isRequired ? true : undefined}\n aria-valuemax={ariaValueMax}\n aria-valuemin={ariaValueMin}\n aria-valuenow={ariaValueNow}\n aria-valuetext={ariaValueText}\n autocomplete={autoComplete}\n autofocus={autoFocus}\n class={inputClasses}\n disabled={isDisabled}\n id={id}\n onKeyUp={onKeyUp}\n placeholder={myPlaceholder}\n readonly={isReadonly}\n // @ts-ignore\n ref={inputRef}\n role={role}\n rows={rows}\n spellcheck={spellcheck}\n type={type}\n value={value}\n {...handlers}\n {...(!isTabbable && tabbableModeProps)}\n />\n );\n};\n"],"names":["textFieldStyles","readonlyStyles","rootStyles","interpolations","Object","values","textInterpolations","styleInterpolations","mergeInterpolations","_a","as","ariaAutoComplete","ariaControls","ariaDescribedBy","ariaExpanded","ariaInvalid","ariaLabel","ariaLabelledBy","ariaValueMax","ariaValueMin","ariaValueNow","ariaValueText","autoComplete","autoFocus","currentCommitValue","hasEndContent","hasInsideLabel","hasPrefix","hasStartContent","hasSuffix","id","inputRef","placeholder","isRequired","role","rows","spellcheck","type","value","variant","onInput","onCommit","onKeyDown","onKeyUp","props","__rest","hasValue","isDisabled","isFocused","isLoading","isReadonly","useFormFieldContext","renderPrefix","renderSuffix","classNames","Comp","_jsx","assign","getLoadingAriaLabel","undefined","autocomplete","autofocus","class","inputClasses","disabled","myPlaceholder","readonly","ref","handlers","isTabbable","tabbableModeProps","isInsideNonReadonlyForm"],"mappings":"qYAGA,MAAAA,EAAA,SAAAA,EAAA,WAAAA,WAmBAC,EAAA,QAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,SAAAA,WCRAC,EAAA,UAAAA,EAAA,SAAAA,EAAA,SAAAA,EAAA,SAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,SAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,WAAAA,EA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,UAAAQ,GAAAR,EACA,aAAAmC,IAAAnC,GACA0B,IAAAwB,IAAAlD,GACAuB,IAAA4B,IAAAnD,SAIJoD,EAAAA,WAAA,CACEpD,EACA,aAAAQ,GAAAR,GACA4C,IAAAE,IAAA9C,0BAMJ0B,IAAAD,GAAAzB,EACAuB,IAAAI,GAAA3B,0BASFqD,GAAA7C,GAAA,qKAcA,OAAA8C,MAAAD,GAAAnD,OAAAqD,OAAA,CAAA,oBAAA9C,EAAA,gBAAAC,EAAA,mBAAAC,EAAA,gBAAAC,EAAA,eAAAC,EAAA,aAAAkC,GAAAS,EAAAA,sBAAA1C,QAAA2C,EAAA,kBAAA1C,EAAA,kBAAAgB,QAAA0B,EAAA,gBAAAzC,EAAA,gBAAAC,EAAA,gBAAAC,EAAA,iBAAAC,EAAAuC,aAAAtC,EAAAuC,UAAAtC,EAAAuC,MAAAC,GAAAC,SAAAjB,GAAAjB,GAAAA,EAAAa,QAAAA,GAAAX,YAAAiC,GAAAC,SAAAhB,GAuBIiB,IAAApC,EAAAG,KAAAA,EAAAC,KAAAA,EAAAC,WAAAA,EAAAC,KAAAA,GAAAC,MAAAA,IAAA8B,IAAAC,IAAAC,mBD/MNxC,gDAnBA,CAAAyC,EAAA7C,EAAAa,kBAMItC,EACA,aAAAsC,GAAAtC,QAIA,aAAAsC,IACEgC,GACAtE,EACFsE,GAAA7C,GAAAzB,0BAtBJ,CAAAiE,EAAA3B,IACEe,EAAAA,WAAA,CACEtD,EACA,aAAAuC,GAAAvC,GACAkE,GAAAlE,oBAjBJ"}
1
+ {"version":3,"file":"TextFieldInput-2719b778.js","sources":["../../src/UNSAFE_TextField/TextFieldUtils.ts","../../src/UNSAFE_TextField/TextFieldInput.tsx"],"sourcesContent":["import { classNames } from '../utils/UNSAFE_classNames';\nimport { cssProps } from '@oracle/oraclejet-cssprops';\n\nconst textFieldStyles = {\n base: cssProps`${{\n display: 'inline-block',\n lineHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-line-height)',\n maxWidth: '100%',\n width: '100%',\n boxSizing: 'border-box'\n }}`,\n\n embedded: cssProps`${{\n height: '100%'\n }}`,\n\n nonReadonly: cssProps`${{\n fontWeight: '400',\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-font-size)'\n }}`\n};\n\nconst readonlyStyles = {\n base: cssProps`${{\n fontWeight: 'var(--oj-form-control-font-weight-read-only)',\n fontSize: 'var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-font-size)',\n position: 'relative',\n borderStyle: 'solid',\n transitionProperty: 'border-color',\n transitionDuration: '0.1s',\n transitionTimingFunction: 'linear',\n borderRadius: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-border-radius)',\n flexDirection: 'row',\n alignItems: 'center',\n maxWidth: '100%',\n width: '100%',\n boxSizing: 'border-box'\n }}`,\n\n insideEnabledForm: cssProps`${{\n overflowX: 'hidden',\n overflowY: 'hidden',\n borderWidth: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-border-width)',\n borderColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-border-color-disabled)',\n backgroundColor: 'transparent',\n height: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-height)',\n minWidth: '1em',\n display: 'inline-flex',\n flex: '1'\n }}`,\n\n textarea: cssProps`${{\n height: 'auto'\n }}`,\n\n insideEnabledFormLabelInside: cssProps`${{\n minHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-inside-edge-height)'\n }}`,\n\n notInsideEnabledForm: cssProps`${{\n overflowX: 'visible',\n overflowY: 'visible',\n borderWidth: '0',\n backgroundColor: 'transparent',\n height: 'auto'\n }}`,\n\n textareaNotInsideEnabledForm: cssProps`${{\n paddingTop: '0',\n paddingBottom: '0'\n }}`\n};\n\n//Consolidating all loading styles on form elements here\nexport const loadingStyles = cssProps`${{\n backgroundColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-animation-skeleton-bg-end-color)',\n backgroundSize: '200% 200%',\n borderWidth: '0',\n // need to use a var for the animation name because otherwise linaria will obfuscate it\n // and make it different from the actual keyframes name\n animationName: 'var(--oj-c-PRIVATE-DO-NOT-USE-private-preact-text-field-animation-name-skeleton)',\n animationIterationCount: 'infinite',\n animationDirection: 'alternate',\n animationDuration: '1.5s',\n opacity: '1'\n}}`;\n\nexport const getTextFieldClasses = (readonly?: boolean, variant?: 'default' | 'embedded') => {\n return classNames([\n textFieldStyles.base,\n variant === 'embedded' && textFieldStyles.embedded,\n !readonly && textFieldStyles.nonReadonly\n ]);\n};\n\nexport const getReadonlyClasses = (\n isInsideNonReadonlyForm?: boolean,\n hasInsideLabel?: boolean,\n variant?: 'textarea'\n) => {\n const classes = classNames([\n readonlyStyles.base,\n variant === 'textarea' && readonlyStyles.textarea,\n isInsideNonReadonlyForm\n ? readonlyStyles.insideEnabledForm\n : readonlyStyles.notInsideEnabledForm,\n variant === 'textarea' &&\n !isInsideNonReadonlyForm &&\n readonlyStyles.textareaNotInsideEnabledForm,\n isInsideNonReadonlyForm && hasInsideLabel && readonlyStyles.insideEnabledFormLabelInside\n ]);\n return classes;\n};\n\nexport const getInputId = (id?: string) => {\n return (id ?? '') + '|input';\n};\n\nexport const isInputPlaceholderShown = (\n hasInsideLabel: boolean,\n hasValue: boolean,\n isFocused?: boolean\n) => {\n return !(hasInsideLabel && !hasValue && !isFocused);\n};\n","import { cssProps } from '@oracle/oraclejet-cssprops';\nimport { Ref } from 'preact';\nimport { useFormFieldContext } from '../hooks/UNSAFE_useFormFieldContext';\nimport { useTabbableMode } from '../hooks/UNSAFE_useTabbableMode';\nimport { useTextFieldInputHandlers } from '../hooks/UNSAFE_useTextFieldInputHandlers';\nimport { classNames } from '../utils/UNSAFE_classNames';\nimport type { TextProps } from '../utils/UNSAFE_interpolations/text';\nimport { textInterpolations } from '../utils/UNSAFE_interpolations/text';\nimport { mergeInterpolations } from '../utils/UNSAFE_mergeInterpolations';\nimport { ValueUpdateDetail } from '../utils/UNSAFE_valueUpdateDetail';\nimport { getLoadingAriaLabel } from './FormControlUtils';\nimport { isInputPlaceholderShown } from './TextFieldUtils';\nimport { HTMLAttributesSignalExcluded } from '../utils/UNSAFE_attributeUtils';\n\nconst rootStyles = {\n base: cssProps`${{\n // normally removing an outline can cause accessibility issues, however\n // on an input the cursor blinks so an outline is not required for\n // accessibility. As of 6-11-14 only chrome is putting\n // an outline on inputs anyway\n outlineStyle: 'none',\n outlineWidth: '0',\n boxSizing: 'border-box',\n fontFamily: 'inherit',\n lineHeight: 'inherit',\n fontWeight: 'inherit',\n border: '0',\n backgroundColor: 'transparent',\n width: '100%',\n\n '&::selection': {\n backgroundColor: 'var(--oj-c-PRIVATE-DO-NOT-USE-core-bg-color-selected)'\n }\n }}`,\n // removes margin that Safari adds to the input element\n input: cssProps`${{\n margin: '0'\n }}`,\n textarea: cssProps`${{\n paddingTop:\n 'calc((var(--oj-c-PRIVATE-DO-NOT-USE-text-field-height) - 1rem * var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-line-height))/ 2 - 1px)',\n paddingBottom:\n 'calc((var(--oj-c-PRIVATE-DO-NOT-USE-text-field-height) - 1rem * var(--oj-c-PRIVATE-DO-NOT-USE-typography-body-md-line-height))/ 2 - 1px)',\n\n resize: 'none'\n }}`,\n password: cssProps`${{\n '&::-ms-reveal': {\n display: 'none'\n }\n }}`,\n labelDefaultPadding: cssProps`${{\n paddingTop: 0,\n paddingBottom: 0\n }}`,\n labelInsideBase: cssProps`${{\n minHeight: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-inside-edge-height)',\n paddingTop: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-inside-edge-padding-top)',\n paddingBottom: 0,\n\n '&:hover': {\n backgroundColor: 'transparent'\n }\n }}`,\n textareaLabelInsideBase: cssProps`${{\n paddingTop: 0,\n paddingBottom: 0,\n // We are using a transparent border here instead of padding, due to how textarea scrolls the padding off the screen\n // and the text content will clash with the inside label.\n borderColor: 'transparent',\n borderStyle: 'solid',\n borderBlockStartWidth:\n 'calc(var(--oj-c-PRIVATE-DO-NOT-USE-label-inside-edge-font-size) * var(--oj-c-PRIVATE-DO-NOT-USE-label-inside-edge-line-height) + var(--oj-c-PRIVATE-DO-NOT-USE-label-inside-edge-position-top))',\n // The 0.25rem is an aesthetically pleasing amount of bottom padding\n borderBlockEndWidth: '0.25rem'\n }}`,\n\n labelInsideNoValueAndHasFocus: cssProps`${{\n animationName:\n 'var(--oj-c-PRIVATE-DO-NOT-USE-private-preact-text-field-animation-name-placeholder)',\n animationDuration: 'var(--oj-c-PRIVATE-DO-NOT-USE-animation-duration-xlong)',\n animationTimingFunction: 'var(--oj-c-PRIVATE-DO-NOT-USE-animation-ease-in)'\n }}`,\n\n hasStartContent: cssProps`${{\n paddingInlineStart: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-icon-to-text-padding)'\n }}`,\n\n hasEndContent: cssProps`${{\n paddingInlineEnd: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-icon-to-text-padding)'\n }}`,\n\n defaultColor: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-color)'\n }}`,\n\n disabledColor: cssProps`${{\n color: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-color-disabled)'\n }}`,\n // The 0.25em is the space between the prefix and the input. This is equivalent to ' '.\n hasPrefix: cssProps`${{\n paddingInlineStart: '.25em'\n }}`,\n\n hasSuffix: cssProps`${{\n paddingInlineEnd: '.25em'\n }}`,\n\n default: cssProps`${{\n fontSize: '100%'\n }}`,\n\n defaultPaddingStart: cssProps`${{\n paddingInlineStart: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding)'\n }}`,\n\n defaultPaddingEnd: cssProps`${{\n paddingInlineEnd: 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding)'\n }}`,\n\n embedded: cssProps`${{\n color: 'inherit',\n fontSize: 'inherit',\n height: '100%',\n margin: 0,\n paddingBlock: 0,\n paddingInline:\n 'var(--oj-c-PRIVATE-DO-NOT-USE-text-field-embedded-padding, var(--oj-c-PRIVATE-DO-NOT-USE-text-field-text-to-edge-padding))',\n\n // textarea styles\n resize: 'none',\n\n // input-password styles\n '&::-ms-reveal': {\n display: 'none'\n }\n }}`\n};\n\nconst interpolations = [...Object.values(textInterpolations)];\n\nconst styleInterpolations = mergeInterpolations<Props>(interpolations);\n\ntype Autocomplete = 'off' | 'on' | string;\n\ntype OrigPickedPropsFromInput = Pick<\n HTMLAttributesSignalExcluded<HTMLInputElement>,\n 'autofocus' | 'id' | 'placeholder' | 'required' | 'role' | 'spellcheck' | 'type'\n>;\ntype RenamedPropsFromInput = Omit<OrigPickedPropsFromInput, 'autofocus' | 'required'> & {\n autoFocus?: OrigPickedPropsFromInput['autofocus'];\n isRequired?: OrigPickedPropsFromInput['required'];\n};\ntype InputProps = {\n as?: 'input';\n type?: Pick<HTMLAttributesSignalExcluded<HTMLInputElement>, 'type'>['type'];\n rows?: never;\n inputRef?: Ref<HTMLInputElement>;\n hasPrefix?: boolean;\n hasSuffix?: boolean;\n};\n\ntype TextAreaProps = {\n as: 'textarea';\n type?: never;\n rows?: number;\n inputRef?: Ref<HTMLTextAreaElement>;\n hasPrefix?: never;\n hasSuffix?: never;\n};\n\ntype UniqueProps = InputProps | TextAreaProps;\n\ntype AriaProps = {\n ariaAutoComplete?: 'none' | 'inline' | 'list' | 'both';\n ariaControls?: string;\n ariaDescribedBy?: string;\n ariaExpanded?: boolean;\n ariaInvalid?: string;\n ariaLabel?: string;\n ariaLabelledBy?: string;\n ariaValueMax?: number;\n ariaValueMin?: number;\n ariaValueNow?: number;\n ariaValueText?: string;\n};\n\ntype Props = UniqueProps &\n TextProps &\n RenamedPropsFromInput &\n AriaProps & {\n autoComplete?: Autocomplete;\n // TODO: Should we expose has* props like these or should we pass this info\n // via FormFieldContext? (from review on 3/8/22)\n currentCommitValue?: string;\n hasEndContent?: boolean;\n hasInsideLabel?: boolean;\n hasStartContent?: boolean;\n value?: string;\n variant?: 'default' | 'embedded';\n onInput?: (detail: ValueUpdateDetail<string>) => void;\n onCommit?: (detail: ValueUpdateDetail<string>) => void;\n onKeyDown?: (event: KeyboardEvent) => void;\n onKeyUp?: (event: KeyboardEvent) => void;\n };\n\nexport const TextFieldInput = ({\n as = 'input',\n ariaAutoComplete,\n ariaControls,\n ariaDescribedBy,\n ariaExpanded,\n ariaInvalid,\n ariaLabel,\n ariaLabelledBy,\n ariaValueMax,\n ariaValueMin,\n ariaValueNow,\n ariaValueText,\n autoComplete,\n autoFocus,\n currentCommitValue,\n hasEndContent = false,\n hasInsideLabel = false,\n hasPrefix = false,\n hasStartContent = false,\n hasSuffix = false,\n id,\n inputRef,\n placeholder,\n isRequired,\n role,\n rows,\n spellcheck,\n type,\n value = '',\n variant = 'default',\n onInput,\n onCommit,\n onKeyDown,\n onKeyUp,\n ...props\n}: Props) => {\n const hasValue = value !== '';\n const { isDisabled, isFocused, isLoading, isReadonly } = useFormFieldContext();\n const myPlaceholder = isInputPlaceholderShown(hasInsideLabel, hasValue, isFocused)\n ? placeholder\n : undefined;\n const { class: styleInterpolationClasses } = styleInterpolations(props);\n const renderPrefix = !isDisabled && hasPrefix;\n const renderSuffix = !isDisabled && hasSuffix;\n const inputClasses = classNames([\n 'oj-c-text-field-input',\n rootStyles.base,\n variant === 'default'\n ? classNames([\n rootStyles.default,\n as === 'textarea' && rootStyles.textarea,\n as === 'input' && rootStyles.input,\n type === 'password' && rootStyles.password,\n !hasStartContent && !renderPrefix && rootStyles.defaultPaddingStart,\n !hasEndContent && !renderSuffix && rootStyles.defaultPaddingEnd\n ])\n : rootStyles.embedded,\n hasInsideLabel &&\n classNames([\n rootStyles.labelInsideBase,\n as === 'textarea' && rootStyles.textareaLabelInsideBase,\n !hasValue && isFocused && rootStyles.labelInsideNoValueAndHasFocus\n ]),\n !hasInsideLabel && as !== 'textarea' && rootStyles.labelDefaultPadding,\n // We want the input to have padding on itself. This gives the user more space to click on to set focus to the input.\n // The padding between the input and the icon is different than the padding between the input and prefix/suffix (since they are both text)\n // startcontentpadding+input+endcontentpadding\n hasStartContent && !hasPrefix && rootStyles.hasStartContent,\n hasEndContent && !hasSuffix && rootStyles.hasEndContent,\n isDisabled ? rootStyles.disabledColor : rootStyles.defaultColor,\n // prefix+prefixpadding+input+suffixpadding+suffix\n // if there is also a startcontent or end content,\n // the prefix/suffix will have that padding on it (see PrefixSuffix)\n renderPrefix && rootStyles.hasPrefix,\n renderSuffix && rootStyles.hasSuffix,\n styleInterpolationClasses\n ]);\n const Comp = as || 'input';\n const handlers = useTextFieldInputHandlers({\n currentCommitValue,\n value,\n onInput,\n onCommit,\n onKeyDown\n });\n // the implicit default for tabindex on an input is 0, so do not explicitly set it.\n // JET-52914 - Implement Tabbable mode API contract in InputText\n // if not tabbable, spread tabbableModeProps on component\n const { isTabbable, tabbableModeProps } = useTabbableMode();\n // TODO: for autoComplete='off', need to configure attrs appropriately to make sure it\n // works across browsers and versions (from review on 3/11/22)\n return (\n <Comp\n aria-autocomplete={ariaAutoComplete}\n aria-controls={ariaControls}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-invalid={ariaInvalid}\n aria-label={isLoading ? getLoadingAriaLabel() : ariaLabel ? ariaLabel : undefined}\n aria-labelledby={ariaLabelledBy}\n aria-required={isRequired ? true : undefined}\n aria-valuemax={ariaValueMax}\n aria-valuemin={ariaValueMin}\n aria-valuenow={ariaValueNow}\n aria-valuetext={ariaValueText}\n autocomplete={autoComplete}\n autofocus={autoFocus}\n class={inputClasses}\n disabled={isDisabled}\n id={id}\n onKeyUp={onKeyUp}\n placeholder={myPlaceholder}\n readonly={isReadonly}\n // @ts-ignore\n ref={inputRef}\n role={role}\n rows={rows}\n spellcheck={spellcheck}\n type={type}\n value={value}\n {...handlers}\n {...(!isTabbable && tabbableModeProps)}\n />\n );\n};\n"],"names":["textFieldStyles","readonlyStyles","rootStyles","interpolations","Object","values","textInterpolations","styleInterpolations","mergeInterpolations","_a","as","ariaAutoComplete","ariaControls","ariaDescribedBy","ariaExpanded","ariaInvalid","ariaLabel","ariaLabelledBy","ariaValueMax","ariaValueMin","ariaValueNow","ariaValueText","autoComplete","autoFocus","currentCommitValue","hasEndContent","hasInsideLabel","hasPrefix","hasStartContent","hasSuffix","id","inputRef","placeholder","isRequired","role","rows","spellcheck","type","value","variant","onInput","onCommit","onKeyDown","onKeyUp","props","__rest","hasValue","isDisabled","isFocused","isLoading","isReadonly","useFormFieldContext","renderPrefix","renderSuffix","classNames","Comp","_jsx","assign","getLoadingAriaLabel","undefined","autocomplete","autofocus","class","inputClasses","disabled","myPlaceholder","readonly","ref","handlers","isTabbable","tabbableModeProps","isInsideNonReadonlyForm"],"mappings":"qYAGA,MAAAA,EAAA,SAAAA,EAAA,SAAAA,WAmBAC,EAAA,WAAAA,EAAA,SAAAA,EAAA,WAAAA,EAAA,UAAAA,EAAA,SAAAA,YCRAC,EAAA,UAAAA,EAAA,WAAAA,EAAA,UAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,SAAAA,EAAA,SAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,SAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,WAAAA,EAAA,SAAAA,WA6HAC,EAAA,IAAAC,OAAAC,OAAAC,EAAAA,qBAEAC,EAAAC,EAAAA,oBAAAL,oBAiEAM,IAA+B,IAAAC,GAAAA,EAAA,QAAAC,iBAAAA,EAAAC,aAAAA,EAAAC,gBAAAA,EAAAC,aAAAA,EAAAC,YAAAA,EAAAC,UAAAA,EAAAC,eAAAA,EAAAC,aAAAA,EAAAC,aAAAA,EAAAC,aAAAA,EAAAC,cAAAA,EAAAC,aAAAA,EAAAC,UAAAA,EAAAC,mBAAAA,EAAAC,cAAAA,GAAA,EAAAC,eAAAA,GAAA,EAAAC,UAAAA,GAAA,EAAAC,gBAAAA,GAAA,EAAAC,UAAAA,GAAA,EAAAC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C,UAAAtC,EAAAuC,MAAAC,GAAAC,SAAAjB,GAAAjB,GAAAA,EAAAa,QAAAA,GAAAX,YAAAiC,GAAAC,SAAAhB,GAuBIiB,IAAApC,EAAAG,KAAAA,EAAAC,KAAAA,EAAAC,WAAAA,EAAAC,KAAAA,GAAAC,MAAAA,IAAA8B,IAAAC,IAAAC,mBD/MNxC,gDAnBA,CAAAyC,EAAA7C,EAAAa,kBAMItC,EACA,aAAAsC,GAAAtC,QAIA,aAAAsC,IACEgC,GACAtE,EACFsE,GAAA7C,GAAAzB,0BAtBJ,CAAAiE,EAAA3B,IACEe,EAAAA,WAAA,CACEtD,EACA,aAAAuC,GAAAvC,GACAkE,GAAAlE,oBAjBJ"}
@@ -1 +1 @@
1
- .gbqada{position:relative;overflow-x:hidden;overflow-y:hidden;}.gbqada::before{content:'';display:block;padding-bottom:calc(100% / (var(--oj-c-PRIVATE-DO-NOT-USE-aspect-ratio)));}.gbqada > :first-child{position:absolute;top:0;bottom:0;left:0;right:0;width:100%;height:100%;}.gbqada > img{object-fit:cover;}.gbqada > video{object-fit:cover;}
1
+ ._1dl3qkl{position:relative;overflow-x:hidden;overflow-y:hidden;}._1dl3qkl::before{content:'';display:block;padding-bottom:calc(100% / (var(--oj-c-PRIVATE-DO-NOT-USE-aspect-ratio)));}._1dl3qkl > :first-child{position:absolute;top:0;bottom:0;left:0;right:0;width:100%;height:100%;}._1dl3qkl > img{object-fit:cover;}._1dl3qkl > video{object-fit:cover;}
@@ -1,2 +1,2 @@
1
- define(["exports","./tslib.es6-74fb34cf","preact/jsx-runtime","css!./UNSAFE_AspectRatio.css","./utils/UNSAFE_interpolations/dimensions","./utils/UNSAFE_mergeInterpolations","./utils/UNSAFE_classNames","./utils/UNSAFE_arrayUtils","./classNames-e64f6be5","./utils/UNSAFE_size","./_curry1-8ff28a98","./_curry3-ccc05acd","./_curry2-4707be52","./_has-707f8be4"],function(s,t,e,i,r,a,n,c,l,o,u,_,d,f){"use strict";const m=c.stringLiteralArray(["9/16","1/1","6/5","5/4","4/3","11/8","1.43/1","3/2","14/9","16/10","1.6180/1","5/3","16/9","1.85/1","1.9/1","2/1","2.2/1","64/21","2.4/1","2.414/1","2.76/1","32/9","18/5","4/1"]),b=c.stringLiteralArray(["maxWidth","minWidth","width"]),A=Array.from(b,s=>r.dimensionInterpolations[s]),p=a.mergeInterpolations(A);s.AspectRatio=function(s){var{children:i,ratio:r="1/1"}=s,a=t.__rest(s,["children","ratio"]);const n=p(a),{class:c}=n,o=t.__rest(n,["class"]),u=Object.assign(Object.assign({},o),{"--oj-c-PRIVATE-DO-NOT-USE-aspect-ratio":r});return e.jsx("div",Object.assign({class:l.classNames(["gbqada",c]),style:u},{children:i}))},s.ratios=m,Object.defineProperty(s,"__esModule",{value:!0})});
1
+ define(["exports","./tslib.es6-9d88853c","preact/jsx-runtime","css!./UNSAFE_AspectRatio.css","./utils/UNSAFE_interpolations/dimensions","./utils/UNSAFE_mergeInterpolations","./utils/UNSAFE_classNames","./utils/UNSAFE_arrayUtils","./classNames-f3dd3ee3","./utils/UNSAFE_size","./_curry1-e9025233","./_curry3-8a91848a","./_curry2-722350a9","./_has-f54967fe"],function(s,t,e,i,r,a,n,l,c,o,d,_,u,m){"use strict";const A=l.stringLiteralArray(["9/16","1/1","6/5","5/4","4/3","11/8","1.43/1","3/2","14/9","16/10","1.6180/1","5/3","16/9","1.85/1","1.9/1","2/1","2.2/1","64/21","2.4/1","2.414/1","2.76/1","32/9","18/5","4/1"]),p=l.stringLiteralArray(["maxWidth","minWidth","width"]),y=Array.from(p,s=>r.dimensionInterpolations[s]),N=a.mergeInterpolations(y);s.AspectRatio=function(s){var{children:i,ratio:r="1/1"}=s,a=t.__rest(s,["children","ratio"]);const n=N(a),{class:l}=n,o=t.__rest(n,["class"]),d=Object.assign(Object.assign({},o),{"--oj-c-PRIVATE-DO-NOT-USE-aspect-ratio":r});return e.jsx("div",Object.assign({class:c.classNames(["_1dl3qkl",l]),style:d},{children:i}))},s.ratios=A,Object.defineProperty(s,"__esModule",{value:!0})});
2
2
  //# sourceMappingURL=UNSAFE_AspectRatio.js.map
@@ -1,8 +1,8 @@
1
- ._1pn7q6f{display:inline-grid;height:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-size);width:var(--oj-c-PRIVATE-DO-NOT-USE--avatar-size);}
2
- .w4gouf{--oj-c-PRIVATE-DO-NOT-USE-avatar-border-radius:50%;}
3
- .m269t5 > *{margin-top:0 !important;margin-bottom:0 !important;margin-left:0 !important;margin-right:0 !important;}
4
- ._1rmizgw{border-radius:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-border-radius);align-self:stretch;align-items:center;justify-content:center;display:flex;height:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-size);width:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-size);grid-row-start:1;grid-column-start:1;grid-row-end:2;grid-column-end:2;background-position:center center;overflow-x:hidden;overflow-y:hidden;}
5
- ._1ffgif7{background-color:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-bg-color);color:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-text-color);background-size:196px 196px;background-image:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-pattern);}
6
- ._132zzfm{background-size:cover;}
7
- ._17vouva{font-size:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-initials-font-size);font-weight:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-initials-font-weight);}
8
- .sdqiv2{font-size:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-icon-font-size);}
1
+ .m17d6i{display:inline-grid;height:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-size);width:var(--oj-c-PRIVATE-DO-NOT-USE--avatar-size);}
2
+ ._7v49b6{--oj-c-PRIVATE-DO-NOT-USE-avatar-border-radius:50%;}
3
+ .hqvxdk > *{margin-top:0 !important;margin-bottom:0 !important;margin-left:0 !important;margin-right:0 !important;}
4
+ .e4lk5d{border-radius:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-border-radius);align-self:stretch;align-items:center;justify-content:center;display:flex;height:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-size);width:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-size);grid-row-start:1;grid-column-start:1;grid-row-end:2;grid-column-end:2;background-position:center center;overflow-x:hidden;overflow-y:hidden;}
5
+ ._1xg30zv{background-color:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-bg-color);color:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-text-color);background-size:196px 196px;background-image:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-pattern);}
6
+ .li6fvg{background-size:cover;}
7
+ ._1bkkpo3{font-size:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-initials-font-size);font-weight:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-initials-font-weight);}
8
+ ._1yuxmd0{font-size:var(--oj-c-PRIVATE-DO-NOT-USE-avatar-icon-font-size);}