@splunk/react-ui 5.0.0 → 5.2.0

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 (443) hide show
  1. package/Accordion.js +105 -84
  2. package/Anchor.js +9 -9
  3. package/Animation.js +2 -2
  4. package/Avatar.js +30 -30
  5. package/Box.js +2 -2
  6. package/Breadcrumbs.js +54 -54
  7. package/Button.js +36 -36
  8. package/ButtonGroup.js +9 -9
  9. package/ButtonSimple.js +2 -2
  10. package/CHANGELOG.md +44 -2
  11. package/Calendar.js +130 -130
  12. package/Card.js +308 -277
  13. package/CardLayout.js +10 -10
  14. package/Chip.js +44 -44
  15. package/Clickable.js +51 -51
  16. package/Code.js +654 -519
  17. package/CollapsiblePanel.js +158 -156
  18. package/Color.js +117 -117
  19. package/ColumnLayout.js +41 -41
  20. package/ComboBox.js +183 -199
  21. package/ControlGroup.js +186 -178
  22. package/Date.js +152 -150
  23. package/DefinitionList.js +124 -104
  24. package/Divider.js +2 -2
  25. package/DualListbox.js +706 -717
  26. package/File.js +407 -407
  27. package/FormRows.js +74 -71
  28. package/Heading.js +15 -15
  29. package/Image.js +38 -38
  30. package/JSONTree.js +695 -578
  31. package/Layer.js +64 -73
  32. package/Layout.js +10 -10
  33. package/Link.js +2 -2
  34. package/List.js +24 -24
  35. package/Markdown.js +150 -150
  36. package/Menu.js +64 -63
  37. package/Message.js +20 -20
  38. package/MessageBar.js +13 -13
  39. package/Modal.js +76 -76
  40. package/ModalLayer.js +6 -6
  41. package/Monogram.js +104 -78
  42. package/Multiselect.js +1181 -1080
  43. package/Number.js +115 -115
  44. package/Paginator.js +46 -46
  45. package/Paragraph.js +10 -10
  46. package/Popover.js +527 -446
  47. package/Progress.js +17 -17
  48. package/Prose.js +19 -19
  49. package/RadioBar.js +242 -228
  50. package/RadioList.js +175 -150
  51. package/Resize.js +20 -20
  52. package/ResultsMenu.js +63 -63
  53. package/ScreenReaderContent.js +13 -13
  54. package/Scroll.js +70 -70
  55. package/Search.js +155 -171
  56. package/Select.js +1150 -1049
  57. package/SidePanel.js +29 -29
  58. package/Slider.js +60 -60
  59. package/SlidingPanels.js +52 -52
  60. package/SplitButton.js +121 -93
  61. package/StaticContent.js +6 -6
  62. package/StepBar.js +104 -104
  63. package/Switch.js +47 -47
  64. package/TabBar.js +346 -323
  65. package/TabLayout.js +78 -78
  66. package/Table.js +1408 -1377
  67. package/Text.js +67 -67
  68. package/TextArea.js +100 -85
  69. package/Tooltip.js +209 -203
  70. package/TransitionOpen.js +11 -11
  71. package/Tree.js +452 -349
  72. package/Typography.js +15 -15
  73. package/WaitSpinner.js +6 -6
  74. package/package.json +17 -20
  75. package/stubs-dependencies.d.ts +0 -70
  76. package/stubs-splunkui.d.ts +4 -0
  77. package/types/src/Accordion/docs/examples/Controlled.d.ts +3 -0
  78. package/types/src/Accordion/docs/examples/Inset.d.ts +4 -0
  79. package/types/src/Accordion/docs/examples/Uncontrolled.d.ts +3 -0
  80. package/types/src/Anchor/docs/examples/Basic.d.ts +4 -0
  81. package/types/src/AnimationToggle/docs/examples/Provider.d.ts +4 -0
  82. package/types/src/AnimationToggle/docs/examples/ReducedMotionComponent.d.ts +4 -0
  83. package/types/src/AnimationToggle/docs/examples/ReducedMotionHook.d.ts +4 -0
  84. package/types/src/AnimationToggle/docs/examples/ToggleComponent.d.ts +4 -0
  85. package/types/src/Avatar/docs/examples/BackgroundColor.d.ts +4 -0
  86. package/types/src/Avatar/docs/examples/Basic.d.ts +4 -0
  87. package/types/src/Avatar/docs/examples/Image.d.ts +4 -0
  88. package/types/src/Avatar/docs/examples/Interactive.d.ts +4 -0
  89. package/types/src/Avatar/docs/examples/Size.d.ts +4 -0
  90. package/types/src/Breadcrumbs/docs/examples/Adornments.d.ts +4 -0
  91. package/types/src/Breadcrumbs/docs/examples/Basic.d.ts +3 -0
  92. package/types/src/Breadcrumbs/docs/examples/CustomizedClick.d.ts +4 -0
  93. package/types/src/Button/docs/examples/Basic.d.ts +3 -0
  94. package/types/src/Button/docs/examples/Block.d.ts +4 -0
  95. package/types/src/Button/docs/examples/Disabled.d.ts +4 -0
  96. package/types/src/Button/docs/examples/Icons.d.ts +4 -0
  97. package/types/src/Button/docs/examples/Menus.d.ts +4 -0
  98. package/types/src/Button/docs/examples/To.d.ts +4 -0
  99. package/types/src/ButtonGroup/docs/examples/Basic.d.ts +3 -0
  100. package/types/src/Card/docs/examples/Basic.d.ts +4 -0
  101. package/types/src/Card/docs/examples/Clickable.d.ts +4 -0
  102. package/types/src/Card/docs/examples/Full.d.ts +4 -0
  103. package/types/src/Card/docs/examples/HeadingTitle.d.ts +4 -0
  104. package/types/src/Card/docs/examples/Images.d.ts +4 -0
  105. package/types/src/Card/docs/examples/Selectable.d.ts +4 -0
  106. package/types/src/CardLayout/docs/examples/Basic.d.ts +3 -0
  107. package/types/src/CardLayout/docs/examples/Interactive.d.ts +4 -0
  108. package/types/src/Chip/docs/examples/Appearance.d.ts +3 -0
  109. package/types/src/Chip/docs/examples/CustomColors.d.ts +4 -0
  110. package/types/src/Chip/docs/examples/Disabled.d.ts +3 -0
  111. package/types/src/Chip/docs/examples/Icon.d.ts +3 -0
  112. package/types/src/Chip/docs/examples/Removable.d.ts +3 -0
  113. package/types/src/Chip/docs/examples/RemovableWithNonStringChildren.d.ts +4 -0
  114. package/types/src/Clickable/docs/examples/Disabled.d.ts +4 -0
  115. package/types/src/Code/Code.d.ts +17 -1
  116. package/types/src/Code/LineHighlights.d.ts +11 -0
  117. package/types/src/Code/LineNumbers.d.ts +6 -0
  118. package/types/src/Code/docs/examples/Default.d.ts +3 -0
  119. package/types/src/Code/docs/examples/HideIndent.d.ts +4 -0
  120. package/types/src/Code/docs/examples/Language.d.ts +4 -0
  121. package/types/src/Code/docs/examples/LineHighlights.d.ts +7 -0
  122. package/types/src/Code/docs/examples/LineNumbers.d.ts +7 -0
  123. package/types/src/Code/docs/examples/LineNumbersCustomStart.d.ts +7 -0
  124. package/types/src/CollapsiblePanel/docs/examples/Actions.d.ts +4 -0
  125. package/types/src/CollapsiblePanel/docs/examples/BasicControlled.d.ts +3 -0
  126. package/types/src/CollapsiblePanel/docs/examples/BasicUncontrolled.d.ts +3 -0
  127. package/types/src/CollapsiblePanel/docs/examples/Disabled.d.ts +7 -0
  128. package/types/src/CollapsiblePanel/docs/examples/MultiControlled.d.ts +3 -0
  129. package/types/src/CollapsiblePanel/docs/examples/MultiUncontrolled.d.ts +3 -0
  130. package/types/src/CollapsiblePanel/docs/examples/SingleOpenPanelGroupControlled.d.ts +4 -0
  131. package/types/src/CollapsiblePanel/docs/examples/SingleOpenPanelGroupInset.d.ts +4 -0
  132. package/types/src/CollapsiblePanel/docs/examples/SingleOpenPanelGroupUncontrolled.d.ts +4 -0
  133. package/types/src/CollapsiblePanel/docs/examples/Subtle.d.ts +4 -0
  134. package/types/src/Color/docs/examples/Controlled.d.ts +3 -0
  135. package/types/src/Color/docs/examples/CustomizedPalette.d.ts +4 -0
  136. package/types/src/Color/docs/examples/HideInput.d.ts +4 -0
  137. package/types/src/Color/docs/examples/Null.d.ts +4 -0
  138. package/types/src/Color/docs/examples/ThemeVariables.d.ts +4 -0
  139. package/types/src/Color/docs/examples/Transparent.d.ts +4 -0
  140. package/types/src/Color/docs/examples/Uncontrolled.d.ts +3 -0
  141. package/types/src/ColumnLayout/docs/examples/AlignItems.d.ts +4 -0
  142. package/types/src/ColumnLayout/docs/examples/Basic.d.ts +4 -0
  143. package/types/src/ColumnLayout/docs/examples/Dividers.d.ts +4 -0
  144. package/types/src/ColumnLayout/docs/examples/Gutters.d.ts +4 -0
  145. package/types/src/ComboBox/docs/examples/Controlled.d.ts +4 -0
  146. package/types/src/ComboBox/docs/examples/Fetching.d.ts +4 -0
  147. package/types/src/ComboBox/docs/examples/Headings.d.ts +3 -0
  148. package/types/src/ComboBox/docs/examples/Label.d.ts +4 -0
  149. package/types/src/ComboBox/docs/examples/Uncontrolled.d.ts +4 -0
  150. package/types/src/ControlGroup/docs/examples/Basic.d.ts +4 -0
  151. package/types/src/ControlGroup/docs/examples/CustomizedLabelTarget.d.ts +4 -0
  152. package/types/src/ControlGroup/docs/examples/Error.d.ts +4 -0
  153. package/types/src/ControlGroup/docs/examples/HelpWithErrorText.d.ts +4 -0
  154. package/types/src/ControlGroup/docs/examples/HelpWithLinks.d.ts +4 -0
  155. package/types/src/ControlGroup/docs/examples/LabelLeft.d.ts +4 -0
  156. package/types/src/ControlGroup/docs/examples/LayoutFill.d.ts +4 -0
  157. package/types/src/ControlGroup/docs/examples/LayoutFillJoin.d.ts +4 -0
  158. package/types/src/ControlGroup/docs/examples/LayoutNone.d.ts +4 -0
  159. package/types/src/ControlGroup/docs/examples/Required.d.ts +4 -0
  160. package/types/src/Date/Date.d.ts +6 -1
  161. package/types/src/Date/docs/examples/Basic.d.ts +3 -0
  162. package/types/src/Date/docs/examples/Controlled.d.ts +3 -0
  163. package/types/src/Date/docs/examples/CustomDate.d.ts +4 -0
  164. package/types/src/Date/docs/examples/Disabled.d.ts +3 -0
  165. package/types/src/Date/docs/examples/Error.d.ts +3 -0
  166. package/types/src/Date/docs/examples/HighlightToday.d.ts +4 -0
  167. package/types/src/Date/docs/examples/WithoutCalendar.d.ts +4 -0
  168. package/types/src/DefinitionList/DefinitionList.d.ts +23 -5
  169. package/types/src/DefinitionList/DefinitionListContext.d.ts +2 -0
  170. package/types/src/DefinitionList/docs/examples/Basic.d.ts +3 -0
  171. package/types/src/DefinitionList/docs/examples/CustomizedWidths.d.ts +7 -0
  172. package/types/src/DefinitionList/docs/examples/EmptyDescription.d.ts +4 -0
  173. package/types/src/DefinitionList/docs/examples/WithSeparator.d.ts +4 -0
  174. package/types/src/Divider/docs/examples/Appearance.d.ts +4 -0
  175. package/types/src/Divider/docs/examples/Basic.d.ts +3 -0
  176. package/types/src/Divider/docs/examples/CustomStyle.d.ts +4 -0
  177. package/types/src/Divider/docs/examples/Decorative.d.ts +4 -0
  178. package/types/src/Divider/docs/examples/Vertical.d.ts +3 -0
  179. package/types/src/Dropdown/docs/examples/Basic.d.ts +4 -0
  180. package/types/src/Dropdown/docs/examples/BasicMenu.d.ts +3 -0
  181. package/types/src/Dropdown/docs/examples/ControlledDropdown.d.ts +4 -0
  182. package/types/src/Dropdown/docs/examples/Dialog.d.ts +4 -0
  183. package/types/src/Dropdown/docs/examples/ScrollContainer.d.ts +4 -0
  184. package/types/src/Dropdown/docs/examples/ScrollingMenu.d.ts +4 -0
  185. package/types/src/Dropdown/docs/examples/Submenu.d.ts +3 -0
  186. package/types/src/Dropdown/docs/examples/TooltipButtonToggle.d.ts +4 -0
  187. package/types/src/DualListbox/Option.d.ts +1 -1
  188. package/types/src/DualListbox/docs/examples/Basic.d.ts +3 -0
  189. package/types/src/DualListbox/docs/examples/Controlled.d.ts +3 -0
  190. package/types/src/DualListbox/docs/examples/Fill.d.ts +4 -0
  191. package/types/src/File/docs/examples/CustomizedMessages.d.ts +4 -0
  192. package/types/src/File/docs/examples/Disabled.d.ts +3 -0
  193. package/types/src/File/docs/examples/DropAnywhere.d.ts +4 -0
  194. package/types/src/File/docs/examples/Error.d.ts +4 -0
  195. package/types/src/File/docs/examples/FullScreen.d.ts +4 -0
  196. package/types/src/File/docs/examples/Multi.d.ts +4 -0
  197. package/types/src/File/docs/examples/Progress.d.ts +4 -0
  198. package/types/src/File/docs/examples/Single.d.ts +4 -0
  199. package/types/src/FormRows/FormRows.d.ts +1 -1
  200. package/types/src/FormRows/docs/examples/Basic.d.ts +3 -0
  201. package/types/src/FormRows/docs/examples/Header.d.ts +4 -0
  202. package/types/src/FormRows/docs/examples/Menu.d.ts +4 -0
  203. package/types/src/FormRows/docs/examples/ReorderOnly.d.ts +4 -0
  204. package/types/src/Heading/docs/examples/Basic.d.ts +3 -0
  205. package/types/src/Heading/docs/examples/Variant.d.ts +4 -0
  206. package/types/src/Image/docs/examples/Basic.d.ts +3 -0
  207. package/types/src/JSONTree/JSONTreeItem.d.ts +5 -2
  208. package/types/src/JSONTree/docs/examples/Basic.d.ts +3 -0
  209. package/types/src/JSONTree/docs/examples/Events.d.ts +4 -0
  210. package/types/src/JSONTree/docs/examples/ExpandChildrenOnShiftKey.d.ts +4 -0
  211. package/types/src/Layer/docs/examples/Basic.d.ts +4 -0
  212. package/types/src/Layout/docs/examples/Basic.d.ts +3 -0
  213. package/types/src/Link/docs/examples/Basic.d.ts +4 -0
  214. package/types/src/Link/docs/examples/Disabled.d.ts +4 -0
  215. package/types/src/Link/docs/examples/NewWindow.d.ts +4 -0
  216. package/types/src/Link/docs/examples/Standalone.d.ts +4 -0
  217. package/types/src/List/docs/examples/CustomizedList.d.ts +4 -0
  218. package/types/src/List/docs/examples/OrderedList.d.ts +4 -0
  219. package/types/src/List/docs/examples/UnorderedList.d.ts +3 -0
  220. package/types/src/Markdown/Markdown.d.ts +1 -1
  221. package/types/src/Markdown/docs/examples/Basic.d.ts +4 -0
  222. package/types/src/Markdown/docs/examples/I18n.d.ts +4 -0
  223. package/types/src/Markdown/renderers/MarkdownBlockquote.d.ts +1 -1
  224. package/types/src/Markdown/renderers/MarkdownCodeBlock.d.ts +1 -1
  225. package/types/src/Markdown/renderers/index.d.ts +1 -1
  226. package/types/src/Menu/Item.d.ts +27 -10
  227. package/types/src/Menu/docs/examples/Adornments.d.ts +4 -0
  228. package/types/src/Menu/docs/examples/Basic.d.ts +3 -0
  229. package/types/src/Menu/docs/examples/Complex.d.ts +4 -0
  230. package/types/src/Menu/docs/examples/Descriptions.d.ts +4 -0
  231. package/types/src/Menu/docs/examples/Dimmed.d.ts +4 -0
  232. package/types/src/Menu/docs/examples/Disabled.d.ts +3 -0
  233. package/types/src/Menu/docs/examples/Dividers.d.ts +3 -0
  234. package/types/src/Menu/docs/examples/Headings.d.ts +4 -0
  235. package/types/src/Menu/docs/examples/Links.d.ts +4 -0
  236. package/types/src/Menu/docs/examples/MatchRanges.d.ts +4 -0
  237. package/types/src/Menu/docs/examples/Selectable.d.ts +4 -0
  238. package/types/src/Menu/docs/examples/SelectableWithAdornments.d.ts +4 -0
  239. package/types/src/Menu/docs/examples/Truncate.d.ts +4 -0
  240. package/types/src/Message/docs/examples/Basic.d.ts +3 -0
  241. package/types/src/Message/docs/examples/Content.d.ts +4 -0
  242. package/types/src/Message/docs/examples/Fill.d.ts +3 -0
  243. package/types/src/Message/docs/examples/Removable.d.ts +3 -0
  244. package/types/src/MessageBar/docs/examples/Basic.d.ts +4 -0
  245. package/types/src/MessageBar/docs/examples/Types.d.ts +4 -0
  246. package/types/src/MessageBar/docs/examples/WithActions.d.ts +3 -0
  247. package/types/src/Modal/Modal.d.ts +10 -3
  248. package/types/src/Modal/docs/examples/Basic.d.ts +3 -0
  249. package/types/src/Modal/docs/examples/InitialFocus.d.ts +4 -0
  250. package/types/src/Modal/docs/examples/TypicalUsage.d.ts +4 -0
  251. package/types/src/Modal/docs/examples/Undismissable.d.ts +4 -0
  252. package/types/src/Monogram/Monogram.d.ts +4 -0
  253. package/types/src/Monogram/docs/examples/BackgroundAuto.d.ts +4 -0
  254. package/types/src/Monogram/docs/examples/BackgroundCustom.d.ts +3 -0
  255. package/types/src/Monogram/docs/examples/Basic.d.ts +4 -0
  256. package/types/src/Monogram/docs/examples/Interactive.d.ts +4 -0
  257. package/types/src/Monogram/docs/examples/Size.d.ts +4 -0
  258. package/types/src/Multiselect/Compact.d.ts +1 -1
  259. package/types/src/Multiselect/Multiselect.d.ts +1 -1
  260. package/types/src/Multiselect/docs/examples/Children.d.ts +4 -0
  261. package/types/src/Multiselect/docs/examples/Compact.d.ts +4 -0
  262. package/types/src/Multiselect/docs/examples/Controlled.d.ts +3 -0
  263. package/types/src/Multiselect/docs/examples/CustomizeSelected.d.ts +4 -0
  264. package/types/src/Multiselect/docs/examples/Disabled.d.ts +3 -0
  265. package/types/src/Multiselect/docs/examples/Error.d.ts +3 -0
  266. package/types/src/Multiselect/docs/examples/Fetching.d.ts +4 -0
  267. package/types/src/Multiselect/docs/examples/Headings.d.ts +3 -0
  268. package/types/src/Multiselect/docs/examples/Icons.d.ts +3 -0
  269. package/types/src/Multiselect/docs/examples/LoadMoreOnScrollBottom.d.ts +4 -0
  270. package/types/src/Multiselect/docs/examples/NewValues.d.ts +4 -0
  271. package/types/src/Multiselect/docs/examples/TabInput.d.ts +4 -0
  272. package/types/src/Multiselect/docs/examples/Uncontrolled.d.ts +3 -0
  273. package/types/src/Number/docs/examples/Basic.d.ts +4 -0
  274. package/types/src/Number/docs/examples/Disabled.d.ts +3 -0
  275. package/types/src/Number/docs/examples/Error.d.ts +3 -0
  276. package/types/src/Number/docs/examples/Limits.d.ts +4 -0
  277. package/types/src/Number/docs/examples/Locale.d.ts +4 -0
  278. package/types/src/Number/docs/examples/Uncontrolled.d.ts +4 -0
  279. package/types/src/Paginator/docs/examples/Basic.d.ts +3 -0
  280. package/types/src/Paginator/docs/examples/Compact.d.ts +4 -0
  281. package/types/src/Paginator/docs/examples/CompactCustomLabel.d.ts +3 -0
  282. package/types/src/Paginator/docs/examples/CompactWithLabel.d.ts +3 -0
  283. package/types/src/Paginator/docs/examples/CustomPages.d.ts +4 -0
  284. package/types/src/Paginator/docs/examples/Labelled.d.ts +4 -0
  285. package/types/src/Paginator/docs/examples/PageControl.d.ts +4 -0
  286. package/types/src/Paragraph/docs/examples/Basic.d.ts +4 -0
  287. package/types/src/Popover/Popover.d.ts +1 -1
  288. package/types/src/Popover/PopoverProvider.d.ts +9 -1
  289. package/types/src/Popover/docs/examples/Basic.d.ts +4 -0
  290. package/types/src/Progress/docs/examples/Basic.d.ts +3 -0
  291. package/types/src/Progress/docs/examples/Type.d.ts +3 -0
  292. package/types/src/Prose/docs/examples/Basic.d.ts +3 -0
  293. package/types/src/Prose/docs/examples/Customize.d.ts +4 -0
  294. package/types/src/RadioBar/Option.d.ts +1 -1
  295. package/types/src/RadioBar/RadioBar.d.ts +13 -6
  296. package/types/src/RadioBar/RadioBarContext.d.ts +4 -2
  297. package/types/src/RadioBar/docs/examples/AdornmentAriaExamples.d.ts +5 -0
  298. package/types/src/RadioBar/docs/examples/Basic.d.ts +3 -0
  299. package/types/src/RadioBar/docs/examples/Disabled.d.ts +4 -0
  300. package/types/src/RadioBar/docs/examples/Error.d.ts +3 -0
  301. package/types/src/RadioBar/docs/examples/MenuBar.d.ts +4 -0
  302. package/types/src/RadioBar/docs/examples/Uncontrolled.d.ts +3 -0
  303. package/types/src/RadioList/RadioList.d.ts +2 -1
  304. package/types/src/RadioList/docs/examples/Basic.d.ts +4 -0
  305. package/types/src/RadioList/docs/examples/Disabled.d.ts +3 -0
  306. package/types/src/RadioList/docs/examples/Error.d.ts +3 -0
  307. package/types/src/RadioList/docs/examples/Row.d.ts +3 -0
  308. package/types/src/RadioList/docs/examples/Uncontrolled.d.ts +4 -0
  309. package/types/src/Resize/docs/examples/Appearance.d.ts +4 -0
  310. package/types/src/Resize/docs/examples/Basic.d.ts +4 -0
  311. package/types/src/Resize/docs/examples/Percentage.d.ts +4 -0
  312. package/types/src/Resize/docs/examples/SizingInner.d.ts +4 -0
  313. package/types/src/Resize/docs/examples/SizingOuter.d.ts +4 -0
  314. package/types/src/ScreenReaderContent/docs/examples/Basic.d.ts +4 -0
  315. package/types/src/ScreenReaderContent/docs/examples/SkipLink.d.ts +7 -0
  316. package/types/src/Scroll/Inner.d.ts +1 -1
  317. package/types/src/Scroll/docs/examples/Controlled.d.ts +4 -0
  318. package/types/src/Scroll/docs/examples/Uncontrolled.d.ts +4 -0
  319. package/types/src/ScrollContainerContext/docs/examples/Provider.d.ts +4 -0
  320. package/types/src/Search/docs/examples/Controlled.d.ts +4 -0
  321. package/types/src/Search/docs/examples/Loading.d.ts +4 -0
  322. package/types/src/Search/docs/examples/Options.d.ts +4 -0
  323. package/types/src/Search/docs/examples/OptionsLinks.d.ts +4 -0
  324. package/types/src/Select/Option.d.ts +1 -1
  325. package/types/src/Select/Select.d.ts +1 -1
  326. package/types/src/Select/SelectAllOption.d.ts +5 -10
  327. package/types/src/Select/SelectBase.d.ts +1 -1
  328. package/types/src/Select/docs/examples/Appearance.d.ts +4 -0
  329. package/types/src/Select/docs/examples/Basic.d.ts +4 -0
  330. package/types/src/Select/docs/examples/Children.d.ts +4 -0
  331. package/types/src/Select/docs/examples/Descriptions.d.ts +4 -0
  332. package/types/src/Select/docs/examples/Error.d.ts +3 -0
  333. package/types/src/Select/docs/examples/Fetching.d.ts +4 -0
  334. package/types/src/Select/docs/examples/Filter.d.ts +4 -0
  335. package/types/src/Select/docs/examples/Headings.d.ts +3 -0
  336. package/types/src/Select/docs/examples/Icons.d.ts +3 -0
  337. package/types/src/Select/docs/examples/LoadMoreOnScrollBottom.d.ts +4 -0
  338. package/types/src/Select/docs/examples/Prefix.d.ts +4 -0
  339. package/types/src/Select/docs/examples/Truncate.d.ts +4 -0
  340. package/types/src/Select/docs/examples/Uncontrolled.d.ts +4 -0
  341. package/types/src/SidePanel/docs/examples/Basic.d.ts +4 -0
  342. package/types/src/SidePanel/docs/examples/ChangeSize.d.ts +3 -0
  343. package/types/src/SidePanel/docs/examples/Composition.d.ts +4 -0
  344. package/types/src/Slider/docs/examples/Basic.d.ts +3 -0
  345. package/types/src/Slider/docs/examples/Controlled.d.ts +5 -1
  346. package/types/src/Slider/docs/examples/CustomLabels.d.ts +4 -0
  347. package/types/src/Slider/docs/examples/Disabled.d.ts +3 -0
  348. package/types/src/Slider/docs/examples/Error.d.ts +3 -0
  349. package/types/src/Slider/docs/examples/StepMarks.d.ts +4 -0
  350. package/types/src/SlidingPanels/docs/examples/Basic.d.ts +3 -0
  351. package/types/src/SlidingPanels/docs/examples/Dropdown.d.ts +3 -0
  352. package/types/src/SlidingPanels/docs/examples/Modal.d.ts +3 -0
  353. package/types/src/SplitButton/SplitButton.d.ts +6 -1
  354. package/types/src/SplitButton/docs/examples/Basic.d.ts +3 -0
  355. package/types/src/SplitButton/docs/examples/Block.d.ts +4 -0
  356. package/types/src/SplitButton/docs/examples/ChangeLabel.d.ts +4 -0
  357. package/types/src/SplitButton/docs/examples/Disabled.d.ts +3 -0
  358. package/types/src/StaticContent/docs/examples/Basic.d.ts +4 -0
  359. package/types/src/StaticContent/docs/examples/FieldValue.d.ts +4 -0
  360. package/types/src/StepBar/docs/examples/Basic.d.ts +3 -0
  361. package/types/src/StepBar/docs/examples/Error.d.ts +3 -0
  362. package/types/src/Switch/docs/examples/Basic.d.ts +4 -0
  363. package/types/src/Switch/docs/examples/Disabled.d.ts +3 -0
  364. package/types/src/Switch/docs/examples/Error.d.ts +3 -0
  365. package/types/src/TabBar/docs/examples/Basic.d.ts +3 -0
  366. package/types/src/TabBar/docs/examples/Disabled.d.ts +3 -0
  367. package/types/src/TabBar/docs/examples/Icons.d.ts +3 -0
  368. package/types/src/TabBar/docs/examples/Tooltips.d.ts +3 -0
  369. package/types/src/TabBar/docs/examples/Vertical.d.ts +3 -0
  370. package/types/src/TabBar/docs/examples/VerticalIcons.d.ts +3 -0
  371. package/types/src/TabBar/docs/examples/WithCount.d.ts +3 -0
  372. package/types/src/TabBar/tabBarUtils.d.ts +4 -0
  373. package/types/src/TabBar/types.d.ts +5 -0
  374. package/types/src/TabLayout/Panel.d.ts +0 -1
  375. package/types/src/TabLayout/docs/examples/AutoActivate.d.ts +4 -0
  376. package/types/src/TabLayout/docs/examples/Controlled.d.ts +4 -0
  377. package/types/src/TabLayout/docs/examples/Icons.d.ts +3 -0
  378. package/types/src/TabLayout/docs/examples/Uncontrolled.d.ts +3 -0
  379. package/types/src/TabLayout/docs/examples/Vertical.d.ts +3 -0
  380. package/types/src/TabLayout/docs/examples/VerticalIcons.d.ts +3 -0
  381. package/types/src/Table/Head.d.ts +1 -0
  382. package/types/src/Table/HeadCell.d.ts +2 -3
  383. package/types/src/Table/HeadDropdownCell.d.ts +2 -2
  384. package/types/src/Table/HeadInner.d.ts +4 -4
  385. package/types/src/Table/KeyboardSensor.d.ts +1 -1
  386. package/types/src/Table/RowDragCell.d.ts +1 -1
  387. package/types/src/Table/docs/examples/Basic.d.ts +3 -0
  388. package/types/src/Table/docs/examples/Click.d.ts +4 -0
  389. package/types/src/Table/docs/examples/ClickRows.d.ts +4 -0
  390. package/types/src/Table/docs/examples/Complex.d.ts +4 -0
  391. package/types/src/Table/docs/examples/DockedHeaderScrollbar.d.ts +4 -0
  392. package/types/src/Table/docs/examples/FilterColumnValues.d.ts +4 -0
  393. package/types/src/Table/docs/examples/FixedHeader.d.ts +4 -0
  394. package/types/src/Table/docs/examples/HeadDropdownCell.d.ts +4 -0
  395. package/types/src/Table/docs/examples/ReorderColumns.d.ts +4 -0
  396. package/types/src/Table/docs/examples/ReorderRows.d.ts +4 -0
  397. package/types/src/Table/docs/examples/Resizable.d.ts +4 -0
  398. package/types/src/Table/docs/examples/ResizableFill.d.ts +4 -0
  399. package/types/src/Table/docs/examples/RowActions.d.ts +4 -0
  400. package/types/src/Table/docs/examples/Selectable.d.ts +4 -0
  401. package/types/src/Table/docs/examples/SortableColumns.d.ts +4 -0
  402. package/types/src/Table/docs/examples/StripeRows.d.ts +3 -0
  403. package/types/src/Text/docs/examples/Basic.d.ts +4 -0
  404. package/types/src/Text/docs/examples/CustomizedIcon.d.ts +4 -0
  405. package/types/src/Text/docs/examples/Dimmed.d.ts +4 -0
  406. package/types/src/Text/docs/examples/Disabled.d.ts +4 -0
  407. package/types/src/Text/docs/examples/Error.d.ts +4 -0
  408. package/types/src/Text/docs/examples/Inline.d.ts +4 -0
  409. package/types/src/Text/docs/examples/Password.d.ts +4 -0
  410. package/types/src/Text/docs/examples/Uncontrolled.d.ts +4 -0
  411. package/types/src/TextArea/docs/examples/Basic.d.ts +4 -0
  412. package/types/src/TextArea/docs/examples/Disabled.d.ts +3 -0
  413. package/types/src/TextArea/docs/examples/Error.d.ts +4 -0
  414. package/types/src/TextArea/docs/examples/Inline.d.ts +4 -0
  415. package/types/src/TextArea/docs/examples/Uncontrolled.d.ts +4 -0
  416. package/types/src/Tooltip/Tooltip.d.ts +10 -5
  417. package/types/src/Tooltip/docs/examples/Basic.d.ts +4 -0
  418. package/types/src/Tooltip/docs/examples/ContentRelationship.d.ts +4 -0
  419. package/types/src/Tooltip/docs/examples/Controlled.d.ts +4 -0
  420. package/types/src/Tooltip/docs/examples/CustomDelay.d.ts +4 -0
  421. package/types/src/Tooltip/docs/examples/CustomProps.d.ts +4 -0
  422. package/types/src/Tooltip/docs/examples/Toggletip.d.ts +4 -0
  423. package/types/src/TransitionOpen/docs/examples/ExpandHeight.d.ts +3 -0
  424. package/types/src/TransitionOpen/docs/examples/ExpandWidth.d.ts +3 -0
  425. package/types/src/TransitionOpen/docs/examples/None.d.ts +4 -0
  426. package/types/src/TransitionOpen/docs/examples/SlideFromBottom.d.ts +4 -0
  427. package/types/src/TransitionOpen/docs/examples/SlideFromLeft.d.ts +4 -0
  428. package/types/src/TransitionOpen/docs/examples/SlideFromRight.d.ts +4 -0
  429. package/types/src/TransitionOpen/docs/examples/SlideFromTop.d.ts +4 -0
  430. package/types/src/Tree/Item.d.ts +63 -0
  431. package/types/src/Tree/Tree.d.ts +13 -6
  432. package/types/src/Tree/TreeContext.d.ts +1 -1
  433. package/types/src/Tree/docs/examples/Basic.d.ts +5 -0
  434. package/types/src/Tree/docs/examples/ClickableExpansion.d.ts +2 -0
  435. package/types/src/Tree/docs/examples/ClickableExpansionWithSelection.d.ts +2 -0
  436. package/types/src/Tree/index.d.ts +1 -1
  437. package/types/src/Typography/docs/examples/Basic.d.ts +4 -0
  438. package/types/src/WaitSpinner/docs/examples/Basic.d.ts +3 -0
  439. package/types/src/useControlled/useControlled.d.ts +3 -1
  440. package/useControlled.js +29 -13
  441. package/useResizeObserver.js +2 -2
  442. package/types/src/DefinitionList/docs/examples/Customize.d.ts +0 -3
  443. package/types/src/Tree/TreeItem.d.ts +0 -44
package/ControlGroup.js CHANGED
@@ -68,8 +68,8 @@
68
68
  const t = require("react");
69
69
  var n = e.n(t);
70
70
  // CONCATENATED MODULE: external "prop-types"
71
- const l = require("prop-types");
72
- var o = e.n(l);
71
+ const o = require("prop-types");
72
+ var l = e.n(o);
73
73
  // CONCATENATED MODULE: external "@splunk/react-ui/ScreenReaderContent"
74
74
  const i = require("@splunk/react-ui/ScreenReaderContent");
75
75
  var a = e.n(i);
@@ -100,33 +100,37 @@
100
100
  const g = require("@splunk/themes");
101
101
  // CONCATENATED MODULE: ./src/ControlGroup/ControlGroupStyles.ts
102
102
  var w = "24px";
103
- var S = y()(b()).withConfig({
104
- displayName: "ControlGroupStyles__StyledBox",
103
+ var O = y().div.withConfig({
104
+ displayName: "ControlGroupStyles__StyledHelp",
105
105
  componentId: "wjnyif-0"
106
- })([ "", " max-width:600px;margin-block-end:", ";&:last-child{margin-block-end:0;}", "" ], g.mixins.reset("flex"), g.variables.spacingLarge, (function(e) {
106
+ })([ "", ";", ";" ], g.mixins.reset("block"), g.mixins.typography("smallBody"));
107
+ var S = y().label.withConfig({
108
+ displayName: "ControlGroupStyles__StyledLabel",
109
+ componentId: "wjnyif-1"
110
+ })([ "", ";word-wrap:break-word;" ], g.mixins.typography("body", {
111
+ color: "active"
112
+ }));
113
+ var I = y()(b()).withConfig({
114
+ displayName: "ControlGroupStyles__StyledBox",
115
+ componentId: "wjnyif-2"
116
+ })([ "", " max-width:600px;margin-block-end:", ";&:last-child{margin-block-end:0;}", " ", "" ], g.mixins.reset("flex"), g.variables.spacingLarge, (function(e) {
107
117
  var r = e.$labelPosition;
108
118
  return r === "top" ? (0, f.css)([ "flex-direction:column;gap:", ";" ], g.variables.spacingXSmall) : (0,
109
119
  f.css)([ "flex-direction:row;gap:", ";" ], g.variables.spacingMedium);
120
+ }), (function(e) {
121
+ var r = e.$disabled;
122
+ return r && (0, f.css)([ "", "{color:", ";}", "{color:", ";}" ], /* sc-sel */ S, g.variables.contentColorDisabled, /* sc-sel */ O, g.variables.contentColorDisabled);
110
123
  }));
111
124
  // Aligns label to the top for case where labelPosition="left" and StyledControlsAndMessagingWrapper is taller than label.
112
- var O = y().div.withConfig({
125
+ var x = y().div.withConfig({
113
126
  displayName: "ControlGroupStyles__StyledLabelWrapper",
114
- componentId: "wjnyif-1"
127
+ componentId: "wjnyif-3"
115
128
  })([ "display:inline-flex;align-items:flex-start;gap:", ";flex-shrink:0;" ], g.variables.spacingXSmall);
116
- var I = y().label.withConfig({
117
- displayName: "ControlGroupStyles__StyledLabel",
118
- componentId: "wjnyif-2"
119
- })([ "", ";word-wrap:break-word;", ";" ], g.mixins.typography("body", {
120
- color: "active"
121
- }), (function(e) {
122
- var r = e.$disabled;
123
- return r && (0, f.css)([ "color:", ";" ], g.variables.contentColorDisabled);
124
- }));
125
129
  // Vertically centers label & tooltip.
126
130
  var C = y().div.withConfig({
127
131
  displayName: "ControlGroupStyles__StyledLabelInnerWrapper",
128
- componentId: "wjnyif-3"
129
- })([ "display:inline-flex;gap:", ";align-items:center;:has(", ":not(:empty)){min-height:", ";}" ], g.variables.spacingXSmall, /* sc-sel */ I, (0,
132
+ componentId: "wjnyif-4"
133
+ })([ "display:inline-flex;gap:", ";align-items:center;:has(", ":not(:empty)){min-height:", ";}" ], g.variables.spacingXSmall, /* sc-sel */ S, (0,
130
134
  g.pickVariant)("$labelPosition", {
131
135
  /* Ensures label is vertically centered with input */
132
136
  left: g.variables.inputHeight,
@@ -136,31 +140,24 @@
136
140
  */
137
141
  top: w
138
142
  }));
139
- var x = y()(h()).withConfig({
143
+ var j = y()(h()).withConfig({
140
144
  displayName: "ControlGroupStyles__StyledTooltip",
141
- componentId: "wjnyif-4"
145
+ componentId: "wjnyif-5"
142
146
  })([ "flex-shrink:0;& button{min-width:", ";min-height:", ";width:", ";height:", ";}" ], w, w, w, w);
143
- var j = y().div.withConfig({
147
+ var E = y().div.withConfig({
144
148
  displayName: "ControlGroupStyles__StyledControlsAndMessagingWrapper",
145
- componentId: "wjnyif-5"
149
+ componentId: "wjnyif-6"
146
150
  })([ "display:flex;flex-direction:column;gap:", ";min-width:0;", "" ], g.variables.spacingXSmall, (function(e) {
147
151
  var r = e.$controlsLayout;
148
152
  return r !== "none" && (0, f.css)([ "flex-grow:1;" ]);
149
153
  }));
150
- var E = y()(b()).withConfig({
154
+ var P = y()(b()).withConfig({
151
155
  displayName: "ControlGroupStyles__StyledControlsWrapper",
152
- componentId: "wjnyif-6"
156
+ componentId: "wjnyif-7"
153
157
  })([ "gap:", ";", "" ], g.variables.spacingMedium, (0, g.pickVariant)("$controlsLayout", {
154
158
  fillJoin: (0, f.css)([ "gap:0;" ]),
155
159
  stack: (0, f.css)([ "flex-direction:column;" ])
156
160
  }));
157
- var P = y().div.withConfig({
158
- displayName: "ControlGroupStyles__StyledHelp",
159
- componentId: "wjnyif-7"
160
- })([ "", ";", ";", ";" ], g.mixins.reset("block"), g.mixins.typography("smallBody"), (function(e) {
161
- var r = e.$disabled;
162
- return r && (0, f.css)([ "color:", ";" ], g.variables.contentColorDisabled);
163
- }));
164
161
  var k = y().span.withConfig({
165
162
  displayName: "ControlGroupStyles__StyledAsterisk",
166
163
  componentId: "wjnyif-8"
@@ -168,72 +165,72 @@
168
165
  // CONCATENATED MODULE: external "@splunk/ui-utils/i18n"
169
166
  const _ = require("@splunk/ui-utils/i18n");
170
167
  // CONCATENATED MODULE: external "@splunk/react-icons/ExclamationTriangle"
171
- const q = require("@splunk/react-icons/ExclamationTriangle");
172
- var D = e.n(q);
168
+ const T = require("@splunk/react-icons/ExclamationTriangle");
169
+ var q = e.n(T);
173
170
  // CONCATENATED MODULE: external "@splunk/themes/mixins"
174
- const T = require("@splunk/themes/mixins");
171
+ const D = require("@splunk/themes/mixins");
175
172
  // CONCATENATED MODULE: ./src/ControlGroup/ErrorMessageBarStyles.ts
176
173
  var M = y().div.withConfig({
177
174
  displayName: "ErrorMessageBarStyles__StyledErrorMessageBarWrapper",
178
175
  componentId: "sc-1praezx-0"
179
176
  })([ "display:flex;gap:", ";word-break:break-word;border-radius:", ";padding:", ";background-color:", ";" ], g.variables.spacingXSmall, g.variables.borderRadius, g.variables.spacingXSmall, g.variables.notificationColorNegativeWeak);
180
- var L = y()(D()).withConfig({
177
+ var L = y()(q()).withConfig({
181
178
  displayName: "ErrorMessageBarStyles__StyledIcon",
182
179
  componentId: "sc-1praezx-1"
183
180
  })([ "position:relative;fill:", ";" ], g.variables.interactiveColorAccentError);
184
181
  var N = y().p.withConfig({
185
182
  displayName: "ErrorMessageBarStyles__StyledErrorMessage",
186
183
  componentId: "sc-1praezx-2"
187
- })([ "", ";", ";" ], g.mixins.reset("block"), (0, T.typography)("smallBody", {
184
+ })([ "", ";", ";" ], g.mixins.reset("block"), (0, D.typography)("smallBody", {
188
185
  color: "active"
189
186
  }));
190
187
  // CONCATENATED MODULE: ./src/ControlGroup/ErrorMessageBar.tsx
191
- function $(e, r) {
188
+ function B(e, r) {
192
189
  if (null == e) return {};
193
- var t, n, l = G(e, r);
190
+ var t, n, o = G(e, r);
194
191
  if (Object.getOwnPropertySymbols) {
195
- var o = Object.getOwnPropertySymbols(e);
196
- for (n = 0; n < o.length; n++) {
197
- t = o[n], r.includes(t) || {}.propertyIsEnumerable.call(e, t) && (l[t] = e[t]);
192
+ var l = Object.getOwnPropertySymbols(e);
193
+ for (n = 0; n < l.length; n++) {
194
+ t = l[n], -1 === r.indexOf(t) && {}.propertyIsEnumerable.call(e, t) && (o[t] = e[t]);
198
195
  }
199
196
  }
200
- return l;
197
+ return o;
201
198
  }
202
199
  function G(e, r) {
203
200
  if (null == e) return {};
204
201
  var t = {};
205
202
  for (var n in e) {
206
203
  if ({}.hasOwnProperty.call(e, n)) {
207
- if (r.includes(n)) continue;
204
+ if (-1 !== r.indexOf(n)) continue;
208
205
  t[n] = e[n];
209
206
  }
210
207
  }
211
208
  return t;
212
209
  }
213
- var B = (0, _._)("Error: ");
214
- var A = {
215
- children: o().node.isRequired
210
+ var A = (0, _._)("Error: ");
211
+ var $ = {
212
+ children: l().node.isRequired
216
213
  };
217
214
  function W(e) {
218
- var r = e.children, t = $(e, [ "children" ]);
215
+ var r = e.children, t = B(e, [ "children" ]);
219
216
 
220
217
  return n().createElement(M, t, n().createElement(L, {
221
218
  variant: "filled"
222
- }), n().createElement(a(), null, B), n().createElement(N, null, r));
219
+ }), n().createElement(a(), null, A), n().createElement(N, null, r));
223
220
  }
224
- W.propTypes = A;
221
+ W.propTypes = $;
225
222
  /* harmony default export */ const F = W;
226
223
  // CONCATENATED MODULE: ./src/ControlGroup/ControlGroup.tsx
227
- function X(e) {
224
+ function R(e) {
228
225
  "@babel/helpers - typeof";
229
- return X = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
226
+ return R = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
230
227
  return typeof e;
231
228
  } : function(e) {
232
229
  return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
233
- }, X(e);
230
+ }, R(e);
234
231
  }
235
- function R() {
236
- return R = Object.assign ? Object.assign.bind() : function(e) {
232
+ function X() {
233
+ return X = Object.assign ? Object.assign.bind() : function(e) {
237
234
  for (var r = 1; r < arguments.length; r++) {
238
235
  var t = arguments[r];
239
236
  for (var n in t) {
@@ -241,31 +238,31 @@
241
238
  }
242
239
  }
243
240
  return e;
244
- }, R.apply(null, arguments);
241
+ }, X.apply(null, arguments);
245
242
  }
246
243
  function H(e, r) {
247
244
  if (null == e) return {};
248
- var t, n, l = J(e, r);
245
+ var t, n, o = J(e, r);
249
246
  if (Object.getOwnPropertySymbols) {
250
- var o = Object.getOwnPropertySymbols(e);
251
- for (n = 0; n < o.length; n++) {
252
- t = o[n], r.includes(t) || {}.propertyIsEnumerable.call(e, t) && (l[t] = e[t]);
247
+ var l = Object.getOwnPropertySymbols(e);
248
+ for (n = 0; n < l.length; n++) {
249
+ t = l[n], -1 === r.indexOf(t) && {}.propertyIsEnumerable.call(e, t) && (o[t] = e[t]);
253
250
  }
254
251
  }
255
- return l;
252
+ return o;
256
253
  }
257
254
  function J(e, r) {
258
255
  if (null == e) return {};
259
256
  var t = {};
260
257
  for (var n in e) {
261
258
  if ({}.hasOwnProperty.call(e, n)) {
262
- if (r.includes(n)) continue;
259
+ if (-1 !== r.indexOf(n)) continue;
263
260
  t[n] = e[n];
264
261
  }
265
262
  }
266
263
  return t;
267
264
  }
268
- function z(e, r) {
265
+ function V(e, r) {
269
266
  var t = Object.keys(e);
270
267
  if (Object.getOwnPropertySymbols) {
271
268
  var n = Object.getOwnPropertySymbols(e);
@@ -275,18 +272,18 @@
275
272
  }
276
273
  return t;
277
274
  }
278
- function K(e) {
275
+ function z(e) {
279
276
  for (var r = 1; r < arguments.length; r++) {
280
277
  var t = null != arguments[r] ? arguments[r] : {};
281
- r % 2 ? z(Object(t), !0).forEach((function(r) {
282
- V(e, r, t[r]);
283
- })) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : z(Object(t)).forEach((function(r) {
278
+ r % 2 ? V(Object(t), !0).forEach((function(r) {
279
+ K(e, r, t[r]);
280
+ })) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : V(Object(t)).forEach((function(r) {
284
281
  Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
285
282
  }));
286
283
  }
287
284
  return e;
288
285
  }
289
- function V(e, r, t) {
286
+ function K(e, r, t) {
290
287
  return (r = U(r)) in e ? Object.defineProperty(e, r, {
291
288
  value: t,
292
289
  enumerable: !0,
@@ -296,14 +293,14 @@
296
293
  }
297
294
  function U(e) {
298
295
  var r = Q(e, "string");
299
- return "symbol" == X(r) ? r : r + "";
296
+ return "symbol" == R(r) ? r : r + "";
300
297
  }
301
298
  function Q(e, r) {
302
- if ("object" != X(e) || !e) return e;
299
+ if ("object" != R(e) || !e) return e;
303
300
  var t = e[Symbol.toPrimitive];
304
301
  if (void 0 !== t) {
305
302
  var n = t.call(e, r || "default");
306
- if ("object" != X(n)) return n;
303
+ if ("object" != R(n)) return n;
307
304
  throw new TypeError("@@toPrimitive must return a primitive value.");
308
305
  }
309
306
  return ("string" === r ? String : Number)(e);
@@ -331,20 +328,20 @@
331
328
  function te(e, r) {
332
329
  var t = null == e ? null : "undefined" != typeof Symbol && e[Symbol.iterator] || e["@@iterator"];
333
330
  if (null != t) {
334
- var n, l, o, i, a = [], s = !0, c = !1;
331
+ var n, o, l, i, a = [], s = !0, c = !1;
335
332
  try {
336
- if (o = (t = t.call(e)).next, 0 === r) {
333
+ if (l = (t = t.call(e)).next, 0 === r) {
337
334
  if (Object(t) !== t) return;
338
335
  s = !1;
339
- } else for (;!(s = (n = o.call(t)).done) && (a.push(n.value), a.length !== r); s = !0) {
336
+ } else for (;!(s = (n = l.call(t)).done) && (a.push(n.value), a.length !== r); s = !0) {
340
337
  }
341
338
  } catch (e) {
342
- c = !0, l = e;
339
+ c = !0, o = e;
343
340
  } finally {
344
341
  try {
345
342
  if (!s && null != t["return"] && (i = t["return"](), Object(i) !== i)) return;
346
343
  } finally {
347
- if (c) throw l;
344
+ if (c) throw o;
348
345
  }
349
346
  }
350
347
  return a;
@@ -355,23 +352,23 @@
355
352
  }
356
353
  // props ControlGroup passes to configure its children's props
357
354
  // props ControlGroup may access and/or override on children
358
- var le = {
359
- children: o().node,
360
- controlsLayout: o().oneOf([ "fill", "fillJoin", "none", "stack" ]),
361
- elementRef: o().oneOfType([ o().func, o().object ]),
362
- error: o().oneOfType([ o().bool, o().string ]),
363
- help: o().node,
364
- hideLabel: o().bool,
365
- label: o().string.isRequired,
366
- labelFor: o().string,
367
- labelPosition: o().oneOf([ "left", "top" ]),
368
- labelWidth: o().oneOfType([ o().number, o().string ]),
369
- required: o().bool,
370
- tooltip: o().node,
371
- tooltipDefaultPlacement: o().oneOf([ "above", "below", "left", "right" ])
355
+ var oe = {
356
+ children: l().node,
357
+ controlsLayout: l().oneOf([ "fill", "fillJoin", "none", "stack" ]),
358
+ elementRef: l().oneOfType([ l().func, l().object ]),
359
+ error: l().oneOfType([ l().bool, l().string ]),
360
+ help: l().node,
361
+ hideLabel: l().bool,
362
+ label: l().string.isRequired,
363
+ labelFor: l().string,
364
+ labelPosition: l().oneOf([ "left", "top" ]),
365
+ labelWidth: l().oneOfType([ l().number, l().string ]),
366
+ required: l().bool,
367
+ tooltip: l().node,
368
+ tooltipDefaultPlacement: l().oneOf([ "above", "below", "left", "right" ])
372
369
  };
373
370
  // Style cloned onto child elements when fill behavior set.
374
- var oe = {
371
+ var le = {
375
372
  flexGrow: 1
376
373
  };
377
374
  function ie(e) {
@@ -391,8 +388,8 @@
391
388
  var n = 0;
392
389
  e.forEach((function(e, t) {
393
390
  if (ie(e) && e.props.inputId == null) {
394
- var l = ae("input-id", t), o = l.childKey, i = l.value;
395
- r[o] = i;
391
+ var o = ae("input-id", t), l = o.childKey, i = o.value;
392
+ r[l] = i;
396
393
  } else if (e.props.id == null) {
397
394
  var a = ae("id", t), s = a.childKey, c = a.value;
398
395
  r[s] = c;
@@ -408,13 +405,13 @@
408
405
  }
409
406
  function ce(e, r, t) {
410
407
  var n = "".concat(e, "-").concat(r);
411
- var l = t[n];
412
- if (!l || !l.length) {
408
+ var o = t[n];
409
+ if (!o || !o.length) {
413
410
  // By this point we should have already generated ids for each child and this code shouldn't get executed
414
411
  // But leaving this as a fallback
415
412
  return undefined;
416
413
  }
417
- return l;
414
+ return o;
418
415
  }
419
416
  function ue(e) {
420
417
  if (e.length === 0) {
@@ -424,99 +421,110 @@
424
421
  var n = e.find((function(e) {
425
422
  return e.type && e.type.componentType === "Text";
426
423
  }));
427
- var l = ie(t);
428
- var o = t.props, i = o.id, a = o.inputId;
424
+ var o = ie(t);
425
+ var l = t.props, i = l.id, a = l.inputId;
429
426
  // see function doc block for details
430
427
  if (e.length === 1 && (t === null || t === void 0 ? void 0 : t.props)) {
431
- return l ? a : i;
428
+ return o ? a : i;
432
429
  }
433
430
  if (n === null || n === void 0 ? void 0 : n.props) {
434
431
  return n.props.inputId;
435
432
  }
436
433
  if (t.props) {
437
- return l ? a : i;
434
+ return o ? a : i;
438
435
  }
439
436
  return undefined;
440
437
  }
441
438
  // Configure the Children
442
- function de(e, r, n) {
443
- var l = e.props, o = l.disabled, i = l.error, a = l.id, s = l.inputId, c = l.style;
444
- var u = n.childIds, d = n.controlsLayout, p = n.help, f = n.helpId, y = n.error, v = n.errorId, b = n.label, m = n.labelFor, h = n.labelId, g = n.numChildren, w = n.required, S = n.showErrorText;
445
- var O = {
439
+ function de(e, r, o) {
440
+ var l = e.props, i = l.disabled, a = l.error, s = l.id, c = l.inputId, u = l.style, d = l.children;
441
+ var p = o.childIds, f = o.controlsLayout, y = o.help, v = o.helpId, b = o.error, m = o.errorId, h = o.label, g = o.labelFor, w = o.labelId, O = o.numChildren, S = o.required, I = o.showErrorText;
442
+ var x = {
446
443
  key: e.key || r,
447
- labelledBy: h
444
+ labelledBy: w
448
445
  };
449
- if (d === "fillJoin") {
446
+ if (f === "fillJoin") {
450
447
  if (r > 0) {
451
- O.prepend = true;
448
+ x.prepend = true;
452
449
  }
453
- if (r < g - 1) {
454
- O.append = true;
450
+ if (r < O - 1) {
451
+ x.append = true;
455
452
  }
456
- if (O.prepend || O.append) {
457
- O.inline = false;
453
+ if (x.prepend || x.append) {
454
+ x.inline = false;
458
455
  }
459
456
  }
460
- if (d === "fill" && g > 1) {
461
- O.inline = true;
457
+ if (f === "fill" && O > 1) {
458
+ x.inline = true;
462
459
  }
463
- if (d === "stack") {
464
- O.inline = false;
460
+ if (f === "stack") {
461
+ x.inline = false;
465
462
  }
466
- if (p && typeof y === "boolean") {
467
- O.describedBy = f;
468
- } else if (p && typeof y === "string") {
469
- O.describedBy = "".concat(f, " ").concat(v);
470
- } else if (!p && typeof y === "string") {
471
- O.describedBy = v;
463
+ if (y && typeof b === "boolean") {
464
+ x.describedBy = v;
465
+ } else if (y && typeof b === "string") {
466
+ x.describedBy = "".concat(v, " ").concat(m);
467
+ } else if (!y && typeof b === "string") {
468
+ x.describedBy = m;
472
469
  }
473
- if (w) {
474
- O.required = true;
470
+ if (S) {
471
+ x.required = true;
475
472
  }
476
473
  // TODO: SUI-3402 refactor so that parent component doesn't have to know what it's child components are
477
474
  if (e.type.componentType === "Multiselect") {
478
- var I = e;
479
- if (!I.props.compact) {
480
- O.labelText = b;
475
+ var C = e;
476
+ if (!C.props.compact) {
477
+ x.labelText = h;
481
478
  }
482
479
  } else {
483
- O.labelText = b;
480
+ x.labelText = h;
484
481
  }
485
- if (g === 1 && (d === "fillJoin" || d === "fill")) {
482
+ if (O === 1 && (f === "fillJoin" || f === "fill")) {
486
483
  // Some controls like Select do not grow by default, so flexGrow is applied
487
484
  // The spread operator is used as css styles are not nested, so there is no need for a deep copy.
488
- O.style = c ? K(K({}, c), oe) : oe;
485
+ x.style = u ? z(z({}, u), le) : le;
489
486
  }
490
- if (!m && e) {
487
+ if (!g && e) {
491
488
  if (ie(e)) {
492
- O.inputId = s || ce("input-id", r, u);
489
+ x.inputId = c || ce("input-id", r, p);
493
490
  } else {
494
- O.id = a || ce("id", r, u);
491
+ x.id = s || ce("id", r, p);
495
492
  }
496
493
  }
497
- if (S && i === true) {
498
- O["aria-errormessage"] = v;
494
+ if (I && a === true) {
495
+ x["aria-errormessage"] = m;
496
+ }
497
+ var j = i !== null && i !== void 0 ? i : false;
498
+ // RadioBar and RadioList need special handling in the case where the parent grouping component is not set to disabled
499
+ // but all of the children are disabled.
500
+ var E = e.type.componentType === "RadioBar" || e.type.componentType === "RadioList";
501
+ if (E && !e.props.disabled) {
502
+ j = n().Children.toArray(d).every((function(e) {
503
+ var r;
504
+
505
+ return n().isValidElement(e) && ((r = e.props) === null || r === void 0 ? void 0 : r.disabled);
506
+ }));
499
507
  }
500
508
  return {
501
- child: (0, t.cloneElement)(e, O),
502
- childDisabled: o !== null && o !== void 0 ? o : false
509
+ child: (0, t.cloneElement)(e, x),
510
+ childDisabled: j
503
511
  };
504
512
  }
505
513
  function pe(e, r) {
506
514
  var t = e.length;
507
515
  var n = 0;
508
- var l = K({
516
+ var o = z({
509
517
  numChildren: t
510
518
  }, r);
511
- var o = e.map((function(e, r) {
512
- var t = de(e, r, l), o = t.child, i = t.childDisabled;
519
+ var l = e.map((function(e, r) {
520
+ var t = de(e, r, o), l = t.child, i = t.childDisabled;
513
521
  if (i === true) {
514
522
  n += 1;
515
523
  }
516
- return o;
524
+ return l;
517
525
  }));
518
526
  return {
519
- childrenFormatted: o,
527
+ childrenFormatted: l,
520
528
  controlGroupDisabled: n === t
521
529
  };
522
530
  }
@@ -539,7 +547,7 @@
539
547
  * attribute. If `inputId` is supported but not set a generated id is used instead. If `inputId` isn't
540
548
  * supported `id` is used. The `labelFor` prop may be used to override the `for` attribute.
541
549
  */ function ye(e) {
542
- var r = e.children, l = e.controlsLayout, o = l === void 0 ? "fill" : l, i = e.error, s = i === void 0 ? false : i, d = e.help, f = e.hideLabel, y = e.label, v = e.labelFor, b = e.labelPosition, m = b === void 0 ? "top" : b, h = e.labelWidth, g = h === void 0 ? fe : h, w = e.required, _ = w === void 0 ? false : w, q = e.tooltip, D = e.tooltipDefaultPlacement, T = H(e, [ "children", "controlsLayout", "error", "help", "hideLabel", "label", "labelFor", "labelPosition", "labelWidth", "required", "tooltip", "tooltipDefaultPlacement" ]);
550
+ var r = e.children, o = e.controlsLayout, l = o === void 0 ? "fill" : o, i = e.error, s = i === void 0 ? false : i, d = e.help, f = e.hideLabel, y = e.label, v = e.labelFor, b = e.labelPosition, m = b === void 0 ? "top" : b, h = e.labelWidth, g = h === void 0 ? fe : h, w = e.required, _ = w === void 0 ? false : w, T = e.tooltip, q = e.tooltipDefaultPlacement, D = H(e, [ "children", "controlsLayout", "error", "help", "hideLabel", "label", "labelFor", "labelPosition", "labelWidth", "required", "tooltip", "tooltipDefaultPlacement" ]);
543
551
  // @docs-props-type ControlGroupPropsBase
544
552
  var M = (0, t.useState)((function() {
545
553
  return {
@@ -547,10 +555,10 @@
547
555
  helpId: (0, u.createDOMID)("help"),
548
556
  labelId: (0, u.createDOMID)("label")
549
557
  };
550
- })), L = Y(M, 1), N = L[0], $ = N.errorId, G = N.helpId, B = N.labelId;
551
- /** Child ids need to be the same on each render because of SUI-2817 */ var A = (0,
552
- t.useState)({}), W = Y(A, 2), X = W[0], J = W[1];
553
- var z = (0, t.useState)(false), K = Y(z, 2), V = K[0], U = K[1];
558
+ })), L = Y(M, 1), N = L[0], B = N.errorId, G = N.helpId, A = N.labelId;
559
+ /** Child ids need to be the same on each render because of SUI-2817 */ var $ = (0,
560
+ t.useState)({}), W = Y($, 2), R = W[0], J = W[1];
561
+ var V = (0, t.useState)(false), z = Y(V, 2), K = z[0], U = z[1];
554
562
  var Q = c()(n().Children.count(r));
555
563
  var Z = (0, t.useCallback)((function(e) {
556
564
  J(e);
@@ -573,84 +581,84 @@
573
581
  J({});
574
582
  }
575
583
  // If childIds has already been populated, labelFor has a value, or if all children have ids then we don't need to make ids for the children.
576
- if (Object.keys(X).length === 0 && !v && !V) {
577
- var e = se(re), t = e.newChildIds, l = e.allChildrenHaveId;
584
+ if (Object.keys(R).length === 0 && !v && !K) {
585
+ var e = se(re), t = e.newChildIds, o = e.allChildrenHaveId;
578
586
  J(t);
579
- U(l);
587
+ U(o);
580
588
  }
581
- }), [ V, X, r, v, Q, Z, ee, re ]);
589
+ }), [ K, R, r, v, Q, Z, ee, re ]);
582
590
  var te = (0, t.useMemo)((function() {
583
591
  return {
584
592
  labelAttrs: {
585
593
  text: y,
586
- id: B
594
+ id: A
587
595
  }
588
596
  };
589
- }), [ y, B ]);
597
+ }), [ y, A ]);
590
598
  var ne = typeof s === "string";
591
- var le = ne && s !== "";
592
- var oe = Number.isFinite(g) ? "".concat(g, "px") : g;
599
+ var oe = ne && s !== "";
600
+ var le = Number.isFinite(g) ? "".concat(g, "px") : g;
593
601
  var ie = m === "left" ? {
594
- width: oe
602
+ width: le
595
603
  } : undefined;
596
604
  var ae = pe(re, {
597
- childIds: X,
598
- controlsLayout: o,
605
+ childIds: R,
606
+ controlsLayout: l,
599
607
  help: d,
600
608
  helpId: G,
601
609
  error: s,
602
- errorId: $,
610
+ errorId: B,
603
611
  label: y,
604
612
  labelFor: v,
605
- labelId: B,
613
+ labelId: A,
606
614
  required: _,
607
- showErrorText: le
615
+ showErrorText: oe
608
616
  }), ce = ae.childrenFormatted, de = ae.controlGroupDisabled;
609
617
  var ye = (0, t.useMemo)((function() {
610
618
  return v || ue(ce);
611
619
  }), [ ce, v ]);
612
- var ve = n().createElement(O, {
620
+ var ve = n().createElement(x, {
613
621
  style: ie,
614
622
  $labelPosition: m
615
623
  }, n().createElement(C, {
616
624
  $labelPosition: m
617
- }, n().createElement(I, {
625
+ }, n().createElement(S, {
618
626
  "data-test": "label",
619
- $disabled: de,
620
- id: B,
627
+ id: A,
621
628
  htmlFor: ye
622
629
  }, _ && n().createElement(k, {
623
630
  "aria-hidden": "true"
624
- }, "*"), y, !f && q && n().createElement(a(), null, q)), !f && q && n().createElement(x, {
631
+ }, "*"), y, !f && T && n().createElement(a(), null, T)), !f && T && n().createElement(j, {
625
632
  closeWhen: "notOnClick",
626
- content: q,
627
- defaultPlacement: D,
633
+ content: T,
634
+ defaultPlacement: q,
628
635
  "aria-hidden": "true"
629
636
  })));
630
637
 
631
- return n().createElement(S, R({
638
+ return n().createElement(I, X({
632
639
  "data-test": "control-group",
633
640
  "data-test-required": _,
641
+ "data-test-children-disabled": de,
634
642
  $labelPosition: m,
643
+ $disabled: de,
635
644
  "aria-invalid": !!s || undefined
636
- }, T), n().createElement(p.Provider, {
645
+ }, D), n().createElement(p.Provider, {
637
646
  value: te
638
- }, f ? n().createElement(a(), null, ve) : ve, n().createElement(j, {
639
- $controlsLayout: o
640
- }, n().createElement(E, {
641
- $controlsLayout: o,
647
+ }, f ? n().createElement(a(), null, ve) : ve, n().createElement(E, {
648
+ $controlsLayout: l
649
+ }, n().createElement(P, {
650
+ $controlsLayout: l,
642
651
  "data-test": "controls",
643
- flex: o !== "none"
644
- }, ce), le && n().createElement(F, {
652
+ flex: l !== "none"
653
+ }, ce), oe && n().createElement(F, {
645
654
  "data-test": "error",
646
- id: $
647
- }, s), d && n().createElement(P, {
655
+ id: B
656
+ }, s), d && n().createElement(O, {
648
657
  "data-test": "help",
649
- $disabled: de,
650
658
  id: G
651
659
  }, d))));
652
660
  }
653
- ye.propTypes = le;
661
+ ye.propTypes = oe;
654
662
  /* harmony default export */ const ve = ye;
655
663
  // CONCATENATED MODULE: ./src/ControlGroup/index.ts
656
664
  module.exports = r;