@lumx/react 3.20.1-alpha.1 → 3.20.1-alpha.3

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 (230) hide show
  1. package/_internal/index.js.map +1 -1
  2. package/index.d.ts +35 -34
  3. package/index.js +212 -215
  4. package/index.js.map +1 -1
  5. package/package.json +10 -12
  6. package/src/components/alert-dialog/AlertDialog.stories.tsx +1 -1
  7. package/src/components/alert-dialog/AlertDialog.test.tsx +3 -4
  8. package/src/components/autocomplete/Autocomplete.stories.tsx +1 -1
  9. package/src/components/autocomplete/Autocomplete.test.tsx +3 -5
  10. package/src/components/autocomplete/Autocomplete.tsx +1 -1
  11. package/src/components/autocomplete/AutocompleteMultiple.stories.tsx +1 -1
  12. package/src/components/autocomplete/AutocompleteMultiple.test.tsx +0 -2
  13. package/src/components/autocomplete/AutocompleteMultiple.tsx +1 -1
  14. package/src/components/avatar/Avatar.stories.tsx +0 -2
  15. package/src/components/avatar/Avatar.test.tsx +0 -2
  16. package/src/components/avatar/Avatar.tsx +1 -1
  17. package/src/components/badge/Badge.stories.tsx +0 -1
  18. package/src/components/badge/Badge.test.tsx +0 -2
  19. package/src/components/badge/Badge.tsx +1 -1
  20. package/src/components/badge/BadgeWrapper.stories.tsx +0 -1
  21. package/src/components/badge/BadgeWrapper.test.tsx +0 -2
  22. package/src/components/badge/BadgeWrapper.tsx +1 -1
  23. package/src/components/button/Button.stories.tsx +0 -1
  24. package/src/components/button/Button.test.tsx +9 -11
  25. package/src/components/button/Button.tsx +0 -2
  26. package/src/components/button/ButtonGroup.stories.tsx +0 -2
  27. package/src/components/button/ButtonGroup.test.tsx +0 -2
  28. package/src/components/button/ButtonGroup.tsx +0 -2
  29. package/src/components/button/ButtonRoot.tsx +7 -37
  30. package/src/components/button/IconButton.test.tsx +0 -2
  31. package/src/components/button/IconButton.tsx +0 -2
  32. package/src/components/checkbox/Checkbox.test.tsx +3 -5
  33. package/src/components/chip/Chip.stories.tsx +0 -2
  34. package/src/components/chip/Chip.test.tsx +19 -19
  35. package/src/components/chip/Chip.tsx +1 -1
  36. package/src/components/chip/ChipGroup.stories.tsx +0 -2
  37. package/src/components/chip/ChipGroup.test.tsx +0 -2
  38. package/src/components/chip/ChipGroup.tsx +1 -1
  39. package/src/components/comment-block/CommentBlock.stories.tsx +0 -1
  40. package/src/components/comment-block/CommentBlock.test.tsx +0 -1
  41. package/src/components/comment-block/CommentBlock.tsx +1 -1
  42. package/src/components/date-picker/DatePicker.test.tsx +3 -5
  43. package/src/components/date-picker/DatePicker.tsx +1 -1
  44. package/src/components/date-picker/DatePickerControlled.test.tsx +6 -8
  45. package/src/components/date-picker/DatePickerField.test.tsx +3 -5
  46. package/src/components/dialog/Dialog.test.tsx +4 -6
  47. package/src/components/divider/Divider.test.tsx +0 -2
  48. package/src/components/divider/Divider.tsx +0 -2
  49. package/src/components/drag-handle/DragHandle.test.tsx +0 -2
  50. package/src/components/drag-handle/DragHandle.tsx +0 -2
  51. package/src/components/dropdown/Dropdown.stories.tsx +1 -1
  52. package/src/components/dropdown/Dropdown.test.tsx +3 -3
  53. package/src/components/dropdown/Dropdown.tsx +1 -1
  54. package/src/components/expansion-panel/ExpansionPanel.test.tsx +6 -7
  55. package/src/components/flag/Flag.test.tsx +0 -2
  56. package/src/components/flag/Flag.tsx +0 -2
  57. package/src/components/flex-box/FlexBox.stories.tsx +0 -2
  58. package/src/components/flex-box/FlexBox.test.tsx +0 -1
  59. package/src/components/flex-box/FlexBox.tsx +1 -1
  60. package/src/components/generic-block/GenericBlock.test.tsx +1 -1
  61. package/src/components/grid/Grid.tsx +0 -2
  62. package/src/components/grid/GridItem.tsx +0 -2
  63. package/src/components/grid-column/GridColumn.stories.tsx +0 -1
  64. package/src/components/grid-column/GridColumn.test.jsx +0 -2
  65. package/src/components/grid-column/GridColumn.tsx +1 -1
  66. package/src/components/heading/Heading.stories.tsx +0 -1
  67. package/src/components/heading/Heading.test.tsx +0 -2
  68. package/src/components/heading/Heading.tsx +0 -2
  69. package/src/components/heading/HeadingLevelProvider.tsx +1 -1
  70. package/src/components/icon/Icon.stories.tsx +30 -4
  71. package/src/components/icon/Icon.test.tsx +85 -4
  72. package/src/components/icon/Icon.tsx +0 -2
  73. package/src/components/image-block/ImageBlock.stories.tsx +0 -2
  74. package/src/components/image-block/ImageBlock.test.tsx +0 -1
  75. package/src/components/image-block/ImageBlock.tsx +1 -1
  76. package/src/components/image-block/ImageCaption.tsx +1 -1
  77. package/src/components/image-lightbox/ImageLightbox.stories.tsx +0 -1
  78. package/src/components/image-lightbox/ImageLightbox.test.tsx +11 -9
  79. package/src/components/image-lightbox/types.ts +0 -2
  80. package/src/components/inline-list/InlineList.stories.tsx +0 -1
  81. package/src/components/inline-list/InlineList.test.tsx +0 -2
  82. package/src/components/inline-list/InlineList.tsx +1 -1
  83. package/src/components/input-helper/InputHelper.test.tsx +0 -2
  84. package/src/components/input-helper/InputHelper.tsx +1 -1
  85. package/src/components/input-label/InputLabel.stories.tsx +0 -2
  86. package/src/components/input-label/InputLabel.test.tsx +0 -2
  87. package/src/components/input-label/InputLabel.tsx +1 -1
  88. package/src/components/lightbox/Lightbox.test.tsx +0 -2
  89. package/src/components/lightbox/Lightbox.tsx +1 -1
  90. package/src/components/link/Link.stories.tsx +0 -1
  91. package/src/components/link/Link.test.tsx +13 -13
  92. package/src/components/link/Link.tsx +9 -22
  93. package/src/components/link-preview/LinkPreview.test.tsx +0 -2
  94. package/src/components/link-preview/LinkPreview.tsx +0 -2
  95. package/src/components/list/List.stories.tsx +1 -1
  96. package/src/components/list/List.test.tsx +0 -2
  97. package/src/components/list/List.tsx +1 -1
  98. package/src/components/list/ListDivider.test.tsx +0 -2
  99. package/src/components/list/ListDivider.tsx +0 -2
  100. package/src/components/list/ListItem.test.tsx +5 -7
  101. package/src/components/list/ListItem.tsx +1 -1
  102. package/src/components/list/ListSubheader.test.tsx +0 -2
  103. package/src/components/list/ListSubheader.tsx +1 -1
  104. package/src/components/message/Message.test.tsx +1 -2
  105. package/src/components/message/Message.tsx +1 -1
  106. package/src/components/mosaic/Mosaic.test.tsx +3 -5
  107. package/src/components/mosaic/Mosaic.tsx +1 -1
  108. package/src/components/navigation/Navigation.stories.tsx +0 -2
  109. package/src/components/navigation/Navigation.test.tsx +0 -2
  110. package/src/components/navigation/Navigation.tsx +0 -2
  111. package/src/components/navigation/NavigationItem.test.tsx +0 -2
  112. package/src/components/navigation/NavigationItem.tsx +7 -11
  113. package/src/components/navigation/NavigationSection.test.tsx +0 -2
  114. package/src/components/navigation/NavigationSection.tsx +5 -4
  115. package/src/components/notification/Notification.test.tsx +4 -5
  116. package/src/components/notification/Notification.tsx +1 -1
  117. package/src/components/popover/Popover.test.tsx +0 -2
  118. package/src/components/popover/Popover.tsx +1 -1
  119. package/src/components/popover/usePopoverStyle.tsx +1 -1
  120. package/src/components/popover-dialog/PopoverDialog.test.tsx +1 -2
  121. package/src/components/popover-dialog/PopoverDialog.tsx +0 -2
  122. package/src/components/post-block/PostBlock.test.tsx +0 -2
  123. package/src/components/post-block/PostBlock.tsx +1 -1
  124. package/src/components/progress/Progress.tsx +0 -2
  125. package/src/components/progress/ProgressCircular.stories.tsx +0 -1
  126. package/src/components/progress/ProgressCircular.test.tsx +0 -2
  127. package/src/components/progress/ProgressCircular.tsx +0 -2
  128. package/src/components/progress/ProgressLinear.test.tsx +0 -2
  129. package/src/components/progress/ProgressLinear.tsx +0 -2
  130. package/src/components/progress-tracker/ProgressTracker.stories.tsx +1 -1
  131. package/src/components/progress-tracker/ProgressTracker.test.tsx +0 -2
  132. package/src/components/progress-tracker/ProgressTrackerProvider.test.tsx +0 -2
  133. package/src/components/progress-tracker/ProgressTrackerProvider.tsx +1 -1
  134. package/src/components/progress-tracker/ProgressTrackerStep.test.tsx +0 -2
  135. package/src/components/progress-tracker/ProgressTrackerStep.tsx +1 -1
  136. package/src/components/progress-tracker/ProgressTrackerStepPanel.test.tsx +0 -2
  137. package/src/components/progress-tracker/ProgressTrackerStepPanel.tsx +0 -2
  138. package/src/components/radio-button/RadioButton.test.tsx +3 -5
  139. package/src/components/radio-button/RadioButton.tsx +1 -1
  140. package/src/components/radio-button/RadioGroup.stories.tsx +1 -1
  141. package/src/components/radio-button/RadioGroup.test.tsx +0 -2
  142. package/src/components/radio-button/RadioGroup.tsx +1 -1
  143. package/src/components/select/Select.stories.tsx +1 -1
  144. package/src/components/select/Select.test.tsx +8 -9
  145. package/src/components/select/Select.tsx +1 -1
  146. package/src/components/select/SelectMultiple.stories.tsx +1 -1
  147. package/src/components/select/SelectMultiple.test.tsx +5 -7
  148. package/src/components/select/SelectMultiple.tsx +1 -1
  149. package/src/components/select/WithSelectContext.tsx +1 -1
  150. package/src/components/select/constants.ts +1 -1
  151. package/src/components/side-navigation/SideNavigation.test.tsx +0 -2
  152. package/src/components/side-navigation/SideNavigation.tsx +1 -1
  153. package/src/components/side-navigation/SideNavigationItem.test.tsx +2 -4
  154. package/src/components/side-navigation/SideNavigationItem.tsx +23 -28
  155. package/src/components/skeleton/SkeletonCircle.test.tsx +0 -2
  156. package/src/components/skeleton/SkeletonCircle.tsx +0 -2
  157. package/src/components/skeleton/SkeletonRectangle.test.tsx +0 -2
  158. package/src/components/skeleton/SkeletonRectangle.tsx +0 -2
  159. package/src/components/skeleton/SkeletonTypography.stories.tsx +0 -2
  160. package/src/components/skeleton/SkeletonTypography.test.tsx +0 -2
  161. package/src/components/skeleton/SkeletonTypography.tsx +1 -1
  162. package/src/components/slider/Slider.test.tsx +1 -3
  163. package/src/components/slider/Slider.tsx +1 -1
  164. package/src/components/slideshow/Slideshow.stories.tsx +0 -1
  165. package/src/components/slideshow/Slideshow.test.tsx +0 -2
  166. package/src/components/slideshow/SlideshowControls.stories.tsx +0 -2
  167. package/src/components/slideshow/SlideshowItem.tsx +0 -2
  168. package/src/components/slideshow/useSlideFocusManagement.tsx +1 -1
  169. package/src/components/switch/Switch.test.tsx +5 -7
  170. package/src/components/switch/Switch.tsx +1 -1
  171. package/src/components/table/Table.test.tsx +0 -2
  172. package/src/components/table/Table.tsx +0 -2
  173. package/src/components/table/TableBody.test.tsx +0 -2
  174. package/src/components/table/TableBody.tsx +0 -2
  175. package/src/components/table/TableCell.test.tsx +1 -3
  176. package/src/components/table/TableCell.tsx +0 -2
  177. package/src/components/table/TableHeader.test.tsx +0 -2
  178. package/src/components/table/TableHeader.tsx +0 -2
  179. package/src/components/table/TableRow.test.tsx +0 -2
  180. package/src/components/table/TableRow.tsx +0 -2
  181. package/src/components/tabs/Tab.test.tsx +0 -2
  182. package/src/components/tabs/Tab.tsx +1 -1
  183. package/src/components/tabs/TabList.test.tsx +0 -2
  184. package/src/components/tabs/TabPanel.test.tsx +0 -2
  185. package/src/components/tabs/TabPanel.tsx +0 -2
  186. package/src/components/tabs/TabProvider.test.tsx +0 -2
  187. package/src/components/tabs/TabProvider.tsx +1 -1
  188. package/src/components/tabs/Tabs.stories.tsx +1 -1
  189. package/src/components/text/Text.stories.tsx +1 -1
  190. package/src/components/text/Text.test.tsx +0 -2
  191. package/src/components/text/Text.tsx +0 -2
  192. package/src/components/text-field/TextField.test.tsx +9 -10
  193. package/src/components/text-field/TextField.tsx +1 -1
  194. package/src/components/thumbnail/Thumbnail.test.tsx +29 -7
  195. package/src/components/thumbnail/Thumbnail.tsx +11 -11
  196. package/src/components/toolbar/Toolbar.tsx +1 -1
  197. package/src/components/tooltip/Tooltip.stories.tsx +2 -1
  198. package/src/components/tooltip/Tooltip.test.tsx +14 -8
  199. package/src/components/uploader/Uploader.test.tsx +2 -4
  200. package/src/components/user-block/UserBlock.stories.tsx +0 -2
  201. package/src/components/user-block/UserBlock.test.tsx +1 -3
  202. package/src/hooks/useId.test.tsx +0 -1
  203. package/src/hooks/useInfiniteScroll.tsx +1 -1
  204. package/src/hooks/usePreviousValue.ts +0 -1
  205. package/src/stories/decorators/withChromaticForceScreenSize.tsx +0 -1
  206. package/src/stories/decorators/withNestedProps.tsx +0 -1
  207. package/src/stories/decorators/withThemedBackground.tsx +0 -2
  208. package/src/stories/decorators/withWrapper.tsx +0 -2
  209. package/src/stories/utils/CustomLink.tsx +0 -1
  210. package/src/testing/utils/ThemeSentinel.tsx +0 -1
  211. package/src/untypped-modules.d.ts +4 -0
  212. package/src/utils/ClickAwayProvider/ClickAwayProvider.stories.jsx +1 -1
  213. package/src/utils/ClickAwayProvider/ClickAwayProvider.tsx +1 -1
  214. package/src/utils/MaterialThemeSwitcher/MaterialThemeSwitcher.tsx +1 -1
  215. package/src/utils/Portal/Portal.test.tsx +0 -1
  216. package/src/utils/Portal/PortalProvider.stories.jsx +0 -1
  217. package/src/utils/Portal/PortalProvider.test.tsx +1 -2
  218. package/src/utils/date/getYearDisplayName.test.ts +1 -1
  219. package/src/utils/disabled/DisabledStateProvider.stories.tsx +0 -2
  220. package/src/utils/disabled/useDisableStateProps.test.tsx +2 -2
  221. package/src/utils/react/OnBeforeUnmount.tsx +1 -1
  222. package/src/utils/react/RawClickable.test.tsx +153 -0
  223. package/src/utils/react/RawClickable.tsx +65 -0
  224. package/src/utils/react/skipRender.tsx +2 -2
  225. package/src/utils/react/wrapChildrenIconWithSpaces.test.tsx +1 -1
  226. package/src/utils/type/HasPolymorphicAs.ts +0 -2
  227. package/src/utils/type/HasRequiredLinkHref.ts +1 -0
  228. package/src/utils/type/index.ts +1 -0
  229. package/utils/index.d.ts +6 -6
  230. package/src/utils/react/renderButtonOrLink.tsx +0 -16
package/index.js CHANGED
@@ -1173,25 +1173,54 @@ const IS_BROWSER = typeof navigator !== 'undefined' && !navigator.userAgent.incl
1173
1173
  */
1174
1174
  const VISUALLY_HIDDEN = 'visually-hidden';
1175
1175
 
1176
- const _excluded$1m = ["linkAs"];
1176
+ /** Same as `React.forwardRef` but inferring Ref type from the `as` prop. */
1177
+ const forwardRefPolymorphic = React__default.forwardRef;
1178
+
1179
+ const _excluded$1m = ["children", "onClick", "disabled", "isDisabled", "aria-disabled", "as"];
1177
1180
  /**
1178
- * Render link with default <a> HTML component or a custom one provided by `linkAs`.
1179
- *
1180
- * Can be used to inject the `Link` component from `react-router` and provide better a11y on LumX components.
1181
- *
1182
- * @param linkAs Custom link component.
1183
- * @param children Link children.
1184
- * @return A link.
1181
+ * Render clickable element (link, button or custom element)
1182
+ * (also does some basic disabled state handling)
1185
1183
  */
1186
- const renderLink = (_ref, ...children) => {
1187
- let {
1188
- linkAs
1189
- } = _ref,
1190
- forwardedProps = _objectWithoutProperties(_ref, _excluded$1m);
1191
- return /*#__PURE__*/React__default.createElement(linkAs || 'a', forwardedProps, ...children);
1192
- };
1184
+ const RawClickable = forwardRefPolymorphic((props, ref) => {
1185
+ const {
1186
+ children,
1187
+ onClick,
1188
+ disabled,
1189
+ isDisabled = disabled,
1190
+ 'aria-disabled': ariaDisabled,
1191
+ as
1192
+ } = props,
1193
+ forwardedProps = _objectWithoutProperties(props, _excluded$1m);
1194
+ const isAnyDisabled = isDisabled || ariaDisabled === 'true' || ariaDisabled === true;
1195
+ const Component = as;
1196
+ let clickableProps;
1197
+ if (Component === 'button') {
1198
+ clickableProps = {
1199
+ type: forwardedProps.type || 'button',
1200
+ disabled: isDisabled
1201
+ };
1202
+ } else {
1203
+ clickableProps = {
1204
+ tabIndex: isDisabled ? '-1' : forwardedProps.tabIndex
1205
+ };
1206
+ }
1207
+ return /*#__PURE__*/jsx(Component, _objectSpread2(_objectSpread2(_objectSpread2({
1208
+ ref: ref,
1209
+ "aria-disabled": isAnyDisabled || undefined
1210
+ }, forwardedProps), clickableProps), {}, {
1211
+ onClick: event => {
1212
+ if (isAnyDisabled) {
1213
+ event.stopPropagation();
1214
+ event.preventDefault();
1215
+ return;
1216
+ }
1217
+ onClick === null || onClick === void 0 ? void 0 : onClick(event);
1218
+ },
1219
+ children: children
1220
+ }));
1221
+ });
1193
1222
 
1194
- const _excluded$1l = ["aria-label", "children", "className", "color", "emphasis", "hasBackground", "href", "isSelected", "isActive", "isFocused", "isHovered", "linkAs", "name", "size", "target", "theme", "variant", "type", "fullWidth"];
1223
+ const _excluded$1l = ["aria-label", "children", "className", "color", "emphasis", "hasBackground", "isSelected", "isActive", "isFocused", "isHovered", "linkAs", "size", "theme", "variant", "fullWidth"];
1195
1224
  /**
1196
1225
  * Component display name.
1197
1226
  */
@@ -1248,18 +1277,14 @@ const ButtonRoot = forwardRef((props, ref) => {
1248
1277
  color,
1249
1278
  emphasis,
1250
1279
  hasBackground,
1251
- href,
1252
1280
  isSelected,
1253
1281
  isActive,
1254
1282
  isFocused,
1255
1283
  isHovered,
1256
1284
  linkAs,
1257
- name,
1258
1285
  size,
1259
- target,
1260
1286
  theme,
1261
1287
  variant,
1262
- type = 'button',
1263
1288
  fullWidth
1264
1289
  } = otherProps,
1265
1290
  forwardedProps = _objectWithoutProperties(otherProps, _excluded$1l);
@@ -1275,7 +1300,7 @@ const ButtonRoot = forwardRef((props, ref) => {
1275
1300
  color: adaptedColor,
1276
1301
  emphasis,
1277
1302
  isSelected,
1278
- isDisabled: isAnyDisabled,
1303
+ isDisabled: props.isDisabled || props['aria-disabled'],
1279
1304
  isActive,
1280
1305
  isFocused,
1281
1306
  isHovered,
@@ -1285,33 +1310,13 @@ const ButtonRoot = forwardRef((props, ref) => {
1285
1310
  variant,
1286
1311
  fullWidth
1287
1312
  }));
1288
-
1289
- /**
1290
- * If the linkAs prop is used, we use the linkAs component instead of a <button>.
1291
- * If there is an href attribute, we display an <a> instead of a <button>.
1292
- *
1293
- * However, in any case, if the component is disabled, we returned a <button> since disabled is not compatible with <a>.
1294
- */
1295
- if ((linkAs || !isEmpty(props.href)) && !isAnyDisabled) {
1296
- return renderLink(_objectSpread2(_objectSpread2({
1297
- linkAs
1298
- }, forwardedProps), {}, {
1299
- 'aria-label': ariaLabel,
1300
- href,
1301
- target,
1302
- className: buttonClassName,
1303
- ref: ref
1304
- }), children);
1305
- }
1306
- return /*#__PURE__*/jsx("button", _objectSpread2(_objectSpread2(_objectSpread2({}, forwardedProps), disabledStateProps), {}, {
1313
+ return /*#__PURE__*/jsx(RawClickable, _objectSpread2(_objectSpread2(_objectSpread2({
1314
+ as: linkAs || (forwardedProps.href ? 'a' : 'button')
1315
+ }, forwardedProps), disabledStateProps), {}, {
1307
1316
  "aria-disabled": isAnyDisabled,
1308
1317
  "aria-label": ariaLabel,
1309
1318
  ref: ref,
1310
1319
  className: buttonClassName,
1311
- name: name,
1312
- type:
1313
- // eslint-disable-next-line react/button-has-type
1314
- type,
1315
1320
  children: children
1316
1321
  }));
1317
1322
  });
@@ -3626,7 +3631,25 @@ const useKeyboardListNavigation = (items, ref, onListItemSelected, onListItemNav
3626
3631
  };
3627
3632
  };
3628
3633
 
3629
- const _excluded$18 = ["after", "before", "children", "className", "isHighlighted", "isSelected", "linkAs", "linkProps", "linkRef", "onItemSelected", "size"];
3634
+ const _excluded$18 = ["linkAs"];
3635
+ /**
3636
+ * Render link with default <a> HTML component or a custom one provided by `linkAs`.
3637
+ *
3638
+ * Can be used to inject the `Link` component from `react-router` and provide better a11y on LumX components.
3639
+ *
3640
+ * @param linkAs Custom link component.
3641
+ * @param children Link children.
3642
+ * @return A link.
3643
+ */
3644
+ const renderLink = (_ref, ...children) => {
3645
+ let {
3646
+ linkAs
3647
+ } = _ref,
3648
+ forwardedProps = _objectWithoutProperties(_ref, _excluded$18);
3649
+ return /*#__PURE__*/React__default.createElement(linkAs || 'a', forwardedProps, ...children);
3650
+ };
3651
+
3652
+ const _excluded$17 = ["after", "before", "children", "className", "isHighlighted", "isSelected", "linkAs", "linkProps", "linkRef", "onItemSelected", "size"];
3630
3653
  /**
3631
3654
  * Component display name.
3632
3655
  */
@@ -3681,7 +3704,7 @@ const ListItem = forwardRef((props, ref) => {
3681
3704
  onItemSelected,
3682
3705
  size = DEFAULT_PROPS$R.size
3683
3706
  } = otherProps,
3684
- forwardedProps = _objectWithoutProperties(otherProps, _excluded$18);
3707
+ forwardedProps = _objectWithoutProperties(otherProps, _excluded$17);
3685
3708
  const role = linkAs || linkProps.href ? 'link' : 'button';
3686
3709
  const onKeyDown = useMemo(() => {
3687
3710
  if (onItemSelected && role === 'link') return onEnterPressed(onItemSelected);
@@ -4169,7 +4192,7 @@ const useInteractiveList = options => {
4169
4192
  }, [items, activeItemIndex, onListItemSelected]);
4170
4193
  };
4171
4194
 
4172
- const _excluded$17 = ["children", "className", "isClickable", "itemPadding", "onListItemSelected", "tabIndex"];
4195
+ const _excluded$16 = ["children", "className", "isClickable", "itemPadding", "onListItemSelected", "tabIndex"];
4173
4196
  /**
4174
4197
  * Component display name.
4175
4198
  */
@@ -4204,7 +4227,7 @@ const InternalList = forwardRef((props, ref) => {
4204
4227
  onListItemSelected,
4205
4228
  tabIndex = DEFAULT_PROPS$Q.tabIndex
4206
4229
  } = props,
4207
- forwardedProps = _objectWithoutProperties(props, _excluded$17);
4230
+ forwardedProps = _objectWithoutProperties(props, _excluded$16);
4208
4231
  const listElementRef = useRef(null);
4209
4232
  const {
4210
4233
  items,
@@ -4232,6 +4255,9 @@ const List = Object.assign(InternalList, {
4232
4255
  useKeyboardListNavigation
4233
4256
  });
4234
4257
 
4258
+ /**
4259
+ * HOC component wrapping a component to skip render if predicate return falsy
4260
+ */
4235
4261
  const skipRender = (predicate, Component) => {
4236
4262
  const Wrapper = /*#__PURE__*/React__default.forwardRef((props, ref) => {
4237
4263
  if (!DOCUMENT) {
@@ -6644,7 +6670,7 @@ function usePopoverStyle({
6644
6670
  };
6645
6671
  }
6646
6672
 
6647
- const _excluded$16 = ["anchorRef", "as", "children", "className", "closeOnClickAway", "closeOnEscape", "elevation", "focusElement", "hasArrow", "isOpen", "onClose", "parentElement", "usePortal", "focusAnchorOnClose", "withFocusTrap", "boundaryRef", "fitToAnchorWidth", "fitWithinViewportHeight", "focusTrapZoneElement", "offset", "placement", "style", "theme", "zIndex"];
6673
+ const _excluded$15 = ["anchorRef", "as", "children", "className", "closeOnClickAway", "closeOnEscape", "elevation", "focusElement", "hasArrow", "isOpen", "onClose", "parentElement", "usePortal", "focusAnchorOnClose", "withFocusTrap", "boundaryRef", "fitToAnchorWidth", "fitWithinViewportHeight", "focusTrapZoneElement", "offset", "placement", "style", "theme", "zIndex"];
6648
6674
  /**
6649
6675
  * Component display name.
6650
6676
  */
@@ -6695,7 +6721,7 @@ const _InnerPopover = forwardRef((props, ref) => {
6695
6721
  theme,
6696
6722
  zIndex = DEFAULT_PROPS$P.zIndex
6697
6723
  } = props,
6698
- forwardedProps = _objectWithoutProperties(props, _excluded$16);
6724
+ forwardedProps = _objectWithoutProperties(props, _excluded$15);
6699
6725
  const popoverRef = useRef(null);
6700
6726
  const {
6701
6727
  styles,
@@ -6821,7 +6847,7 @@ const useInfiniteScroll = (ref, callback, callbackOnMount = false, scrollTrigger
6821
6847
  }, [callback, callbackOnMount]);
6822
6848
  };
6823
6849
 
6824
- const _excluded$15 = ["anchorRef", "children", "className", "closeOnClick", "closeOnClickAway", "closeOnEscape", "fitToAnchorWidth", "fitWithinViewportHeight", "isOpen", "offset", "focusAnchorOnClose", "onClose", "onInfiniteScroll", "placement", "shouldFocusOnOpen", "zIndex"];
6850
+ const _excluded$14 = ["anchorRef", "children", "className", "closeOnClick", "closeOnClickAway", "closeOnEscape", "fitToAnchorWidth", "fitWithinViewportHeight", "isOpen", "offset", "focusAnchorOnClose", "onClose", "onInfiniteScroll", "placement", "shouldFocusOnOpen", "zIndex"];
6825
6851
  /**
6826
6852
  * Component display name.
6827
6853
  */
@@ -6872,7 +6898,7 @@ const Dropdown = forwardRef((props, ref) => {
6872
6898
  shouldFocusOnOpen = DEFAULT_PROPS$O.shouldFocusOnOpen,
6873
6899
  zIndex
6874
6900
  } = props,
6875
- forwardedProps = _objectWithoutProperties(props, _excluded$15);
6901
+ forwardedProps = _objectWithoutProperties(props, _excluded$14);
6876
6902
  const innerRef = useRef(null);
6877
6903
  const listElement = useRef(null);
6878
6904
  useInfiniteScroll(innerRef, onInfiniteScroll);
@@ -6917,7 +6943,7 @@ Dropdown.displayName = COMPONENT_NAME$10;
6917
6943
  Dropdown.className = CLASSNAME$10;
6918
6944
  Dropdown.defaultProps = DEFAULT_PROPS$O;
6919
6945
 
6920
- const _excluded$14 = ["className", "closeMode", "children", "hasBackground", "hasHeaderDivider", "isOpen", "label", "onClose", "onOpen", "onToggleOpen", "theme", "toggleButtonProps"];
6946
+ const _excluded$13 = ["className", "closeMode", "children", "hasBackground", "hasHeaderDivider", "isOpen", "label", "onClose", "onOpen", "onToggleOpen", "theme", "toggleButtonProps"];
6921
6947
  /**
6922
6948
  * Component display name.
6923
6949
  */
@@ -6961,7 +6987,7 @@ const ExpansionPanel = forwardRef((props, ref) => {
6961
6987
  theme = defaultTheme,
6962
6988
  toggleButtonProps
6963
6989
  } = props,
6964
- forwardedProps = _objectWithoutProperties(props, _excluded$14);
6990
+ forwardedProps = _objectWithoutProperties(props, _excluded$13);
6965
6991
  const children = Children.toArray(anyChildren);
6966
6992
 
6967
6993
  // Partition children by types.
@@ -7067,7 +7093,7 @@ ExpansionPanel.displayName = COMPONENT_NAME$$;
7067
7093
  ExpansionPanel.className = CLASSNAME$$;
7068
7094
  ExpansionPanel.defaultProps = DEFAULT_PROPS$N;
7069
7095
 
7070
- const _excluded$13 = ["label", "icon", "color", "className", "theme", "truncate"];
7096
+ const _excluded$12 = ["label", "icon", "color", "className", "theme", "truncate"];
7071
7097
  const COMPONENT_NAME$_ = 'Flag';
7072
7098
  const CLASSNAME$_ = getRootClassName(COMPONENT_NAME$_);
7073
7099
  const DEFAULT_PROPS$M = {};
@@ -7089,7 +7115,7 @@ const Flag = forwardRef((props, ref) => {
7089
7115
  theme = defaultTheme,
7090
7116
  truncate
7091
7117
  } = props,
7092
- forwardedProps = _objectWithoutProperties(props, _excluded$13);
7118
+ forwardedProps = _objectWithoutProperties(props, _excluded$12);
7093
7119
  const flagColor = color || (theme === Theme.light ? ColorPalette.dark : ColorPalette.light);
7094
7120
  const isTruncated = !!truncate;
7095
7121
  return /*#__PURE__*/jsxs("div", _objectSpread2(_objectSpread2({}, forwardedProps), {}, {
@@ -7116,7 +7142,7 @@ Flag.displayName = COMPONENT_NAME$_;
7116
7142
  Flag.className = CLASSNAME$_;
7117
7143
  Flag.defaultProps = DEFAULT_PROPS$M;
7118
7144
 
7119
- const _excluded$12 = ["as", "children", "className", "fillSpace", "gap", "hAlign", "marginAuto", "noShrink", "orientation", "vAlign", "wrap"];
7145
+ const _excluded$11 = ["as", "children", "className", "fillSpace", "gap", "hAlign", "marginAuto", "noShrink", "orientation", "vAlign", "wrap"];
7120
7146
  /**
7121
7147
  * Component display name.
7122
7148
  */
@@ -7148,7 +7174,7 @@ const FlexBox = forwardRef((props, ref) => {
7148
7174
  vAlign,
7149
7175
  wrap
7150
7176
  } = props,
7151
- forwardedProps = _objectWithoutProperties(props, _excluded$12);
7177
+ forwardedProps = _objectWithoutProperties(props, _excluded$11);
7152
7178
  return /*#__PURE__*/jsx(Component, _objectSpread2(_objectSpread2({
7153
7179
  ref: ref
7154
7180
  }, forwardedProps), {}, {
@@ -7165,7 +7191,7 @@ const FlexBox = forwardRef((props, ref) => {
7165
7191
  FlexBox.displayName = COMPONENT_NAME$Z;
7166
7192
  FlexBox.className = CLASSNAME$Z;
7167
7193
 
7168
- const _excluded$11 = ["className", "figure", "figureProps", "children", "actions", "actionsProps", "gap", "orientation", "contentProps"];
7194
+ const _excluded$10 = ["className", "figure", "figureProps", "children", "actions", "actionsProps", "gap", "orientation", "contentProps"];
7169
7195
  /**
7170
7196
  * Component display name.
7171
7197
  */
@@ -7214,7 +7240,7 @@ const BaseGenericBlock = forwardRef((props, ref) => {
7214
7240
  orientation = DEFAULT_PROPS$L.orientation,
7215
7241
  contentProps
7216
7242
  } = props,
7217
- forwardedProps = _objectWithoutProperties(props, _excluded$11);
7243
+ forwardedProps = _objectWithoutProperties(props, _excluded$10);
7218
7244
  const sections = React__default.useMemo(() => {
7219
7245
  // Split children by section type
7220
7246
  const [[figureChild], [contentChild], [actionsChild], ...otherChildren] = partitionMulti(Children.toArray(children), [isFigure, isContent, isActions]);
@@ -7330,7 +7356,7 @@ function wrapChildrenIconWithSpaces(children) {
7330
7356
  });
7331
7357
  }
7332
7358
 
7333
- const _excluded$10 = ["as", "children", "className", "color", "colorVariant", "noWrap", "typography", "truncate", "whiteSpace", "style"];
7359
+ const _excluded$$ = ["as", "children", "className", "color", "colorVariant", "noWrap", "typography", "truncate", "whiteSpace", "style"];
7334
7360
  /**
7335
7361
  * Component display name.
7336
7362
  */
@@ -7366,7 +7392,7 @@ const Text = forwardRef((props, ref) => {
7366
7392
  whiteSpace,
7367
7393
  style
7368
7394
  } = props,
7369
- forwardedProps = _objectWithoutProperties(props, _excluded$10);
7395
+ forwardedProps = _objectWithoutProperties(props, _excluded$$);
7370
7396
  const typographyClass = typography && getTypographyClassName(typography);
7371
7397
 
7372
7398
  // Truncate mode
@@ -7437,7 +7463,7 @@ const useHeadingLevel = () => {
7437
7463
  };
7438
7464
  };
7439
7465
 
7440
- const _excluded$$ = ["children", "as", "className"];
7466
+ const _excluded$_ = ["children", "as", "className"];
7441
7467
  /**
7442
7468
  * Component display name.
7443
7469
  */
@@ -7464,7 +7490,7 @@ const Heading = forwardRef((props, ref) => {
7464
7490
  as,
7465
7491
  className
7466
7492
  } = props,
7467
- forwardedProps = _objectWithoutProperties(props, _excluded$$);
7493
+ forwardedProps = _objectWithoutProperties(props, _excluded$_);
7468
7494
  const {
7469
7495
  headingElement
7470
7496
  } = useHeadingLevel();
@@ -7505,7 +7531,7 @@ const HeadingLevelProvider = ({
7505
7531
  });
7506
7532
  };
7507
7533
 
7508
- const _excluded$_ = ["children", "className", "gutter", "hAlign", "orientation", "vAlign", "wrap"];
7534
+ const _excluded$Z = ["children", "className", "gutter", "hAlign", "orientation", "vAlign", "wrap"];
7509
7535
  /**
7510
7536
  * Component display name.
7511
7537
  */
@@ -7541,7 +7567,7 @@ const Grid = forwardRef((props, ref) => {
7541
7567
  vAlign,
7542
7568
  wrap = DEFAULT_PROPS$I.wrap
7543
7569
  } = props,
7544
- forwardedProps = _objectWithoutProperties(props, _excluded$_);
7570
+ forwardedProps = _objectWithoutProperties(props, _excluded$Z);
7545
7571
  return /*#__PURE__*/jsx("div", _objectSpread2(_objectSpread2({
7546
7572
  ref: ref
7547
7573
  }, forwardedProps), {}, {
@@ -7562,7 +7588,7 @@ Grid.displayName = COMPONENT_NAME$V;
7562
7588
  Grid.className = CLASSNAME$V;
7563
7589
  Grid.defaultProps = DEFAULT_PROPS$I;
7564
7590
 
7565
- const _excluded$Z = ["children", "className", "width", "align", "order"];
7591
+ const _excluded$Y = ["children", "className", "width", "align", "order"];
7566
7592
  /**
7567
7593
  * Component display name.
7568
7594
  */
@@ -7588,7 +7614,7 @@ const GridItem = forwardRef((props, ref) => {
7588
7614
  align,
7589
7615
  order
7590
7616
  } = props,
7591
- forwardedProps = _objectWithoutProperties(props, _excluded$Z);
7617
+ forwardedProps = _objectWithoutProperties(props, _excluded$Y);
7592
7618
  return /*#__PURE__*/jsx("div", _objectSpread2(_objectSpread2({
7593
7619
  ref: ref
7594
7620
  }, forwardedProps), {}, {
@@ -7604,7 +7630,7 @@ const GridItem = forwardRef((props, ref) => {
7604
7630
  GridItem.displayName = COMPONENT_NAME$U;
7605
7631
  GridItem.className = CLASSNAME$U;
7606
7632
 
7607
- const _excluded$Y = ["as", "gap", "maxColumns", "itemMinWidth", "children", "className", "style"];
7633
+ const _excluded$X = ["as", "gap", "maxColumns", "itemMinWidth", "children", "className", "style"];
7608
7634
  /**
7609
7635
  * Component display name.
7610
7636
  */
@@ -7639,7 +7665,7 @@ const GridColumn = forwardRef((props, ref) => {
7639
7665
  className,
7640
7666
  style = {}
7641
7667
  } = props,
7642
- forwardedProps = _objectWithoutProperties(props, _excluded$Y);
7668
+ forwardedProps = _objectWithoutProperties(props, _excluded$X);
7643
7669
  return /*#__PURE__*/jsx(Component, _objectSpread2(_objectSpread2({}, forwardedProps), {}, {
7644
7670
  ref: ref,
7645
7671
  className: classNames(className, CLASSNAME$T),
@@ -7655,7 +7681,7 @@ GridColumn.displayName = COMPONENT_NAME$T;
7655
7681
  GridColumn.className = CLASSNAME$T;
7656
7682
  GridColumn.defaultProps = DEFAULT_PROPS$H;
7657
7683
 
7658
- const _excluded$X = ["className", "color", "colorVariant", "hasShape", "icon", "size", "theme", "alt", "ref"];
7684
+ const _excluded$W = ["className", "color", "colorVariant", "hasShape", "icon", "size", "theme", "alt", "ref"];
7659
7685
  /**
7660
7686
  * Component display name.
7661
7687
  */
@@ -7690,7 +7716,7 @@ const Icon$1 = props => {
7690
7716
  alt,
7691
7717
  ref
7692
7718
  } = props,
7693
- forwardedProps = _objectWithoutProperties(props, _excluded$X);
7719
+ forwardedProps = _objectWithoutProperties(props, _excluded$W);
7694
7720
  const [color, colorVariant] = resolveColorWithVariants(propColor, propColorVariant);
7695
7721
 
7696
7722
  // Color
@@ -7832,7 +7858,7 @@ const ImageCaption = props => {
7832
7858
  });
7833
7859
  };
7834
7860
 
7835
- const _excluded$W = ["actions", "align", "alt", "captionPosition", "captionStyle", "className", "description", "descriptionProps", "fillHeight", "image", "size", "tags", "theme", "thumbnailProps", "title", "titleProps"];
7861
+ const _excluded$V = ["actions", "align", "alt", "captionPosition", "captionStyle", "className", "description", "descriptionProps", "fillHeight", "image", "size", "tags", "theme", "thumbnailProps", "title", "titleProps"];
7836
7862
  const ImageBlockCaptionPosition = {
7837
7863
  below: 'below',
7838
7864
  over: 'over'
@@ -7891,7 +7917,7 @@ const ImageBlock = forwardRef((props, ref) => {
7891
7917
  title,
7892
7918
  titleProps
7893
7919
  } = props,
7894
- forwardedProps = _objectWithoutProperties(props, _excluded$W);
7920
+ forwardedProps = _objectWithoutProperties(props, _excluded$V);
7895
7921
  return /*#__PURE__*/jsxs("figure", _objectSpread2(_objectSpread2({
7896
7922
  ref: ref
7897
7923
  }, forwardedProps), {}, {
@@ -8272,7 +8298,7 @@ const ImageSlide = /*#__PURE__*/React__default.memo(props => {
8272
8298
  });
8273
8299
  }, isEqual);
8274
8300
 
8275
- const _excluded$V = ["image", "imgRef"];
8301
+ const _excluded$U = ["image", "imgRef"];
8276
8302
  /** Internal image slideshow component for ImageLightbox */
8277
8303
  const ImageSlideshow = ({
8278
8304
  activeImageIndex,
@@ -8378,7 +8404,7 @@ const ImageSlideshow = ({
8378
8404
  image,
8379
8405
  imgRef
8380
8406
  } = _ref,
8381
- imageProps = _objectWithoutProperties(_ref, _excluded$V);
8407
+ imageProps = _objectWithoutProperties(_ref, _excluded$U);
8382
8408
  const isActive = index === activeIndex;
8383
8409
  return /*#__PURE__*/jsx(ImageSlide, {
8384
8410
  isActive: isActive,
@@ -8590,7 +8616,7 @@ function useImageLightbox(props) {
8590
8616
  };
8591
8617
  }
8592
8618
 
8593
- const _excluded$U = ["className", "isOpen", "closeButtonProps", "onClose", "parentElement", "activeImageIndex", "slideshowControlsProps", "slideGroupLabel", "images", "zoomOutButtonProps", "zoomInButtonProps", "activeImageRef"];
8619
+ const _excluded$T = ["className", "isOpen", "closeButtonProps", "onClose", "parentElement", "activeImageIndex", "slideshowControlsProps", "slideGroupLabel", "images", "zoomOutButtonProps", "zoomInButtonProps", "activeImageRef"];
8594
8620
  const Inner = forwardRef((props, ref) => {
8595
8621
  const {
8596
8622
  className,
@@ -8606,7 +8632,7 @@ const Inner = forwardRef((props, ref) => {
8606
8632
  zoomInButtonProps,
8607
8633
  activeImageRef: propImageRef
8608
8634
  } = props,
8609
- forwardedProps = _objectWithoutProperties(props, _excluded$U);
8635
+ forwardedProps = _objectWithoutProperties(props, _excluded$T);
8610
8636
  const currentPaginationItemRef = React__default.useRef(null);
8611
8637
  const footerRef = React__default.useRef(null);
8612
8638
  const imageRef = React__default.useRef(null);
@@ -8664,7 +8690,7 @@ const ImageLightbox = Object.assign(Inner, {
8664
8690
  useImageLightbox
8665
8691
  });
8666
8692
 
8667
- const _excluded$T = ["className", "color", "colorVariant", "typography", "children", "wrap"];
8693
+ const _excluded$S = ["className", "color", "colorVariant", "typography", "children", "wrap"];
8668
8694
  /**
8669
8695
  * Component display name.
8670
8696
  */
@@ -8696,7 +8722,7 @@ const InlineList = forwardRef((props, ref) => {
8696
8722
  children,
8697
8723
  wrap
8698
8724
  } = props,
8699
- forwardedProps = _objectWithoutProperties(props, _excluded$T);
8725
+ forwardedProps = _objectWithoutProperties(props, _excluded$S);
8700
8726
  const typographyClassName = typography && getTypographyClassName(typography);
8701
8727
  return (
8702
8728
  /*#__PURE__*/
@@ -8743,7 +8769,7 @@ const INPUT_HELPER_CONFIGURATION = {
8743
8769
  }
8744
8770
  };
8745
8771
 
8746
- const _excluded$S = ["children", "className", "kind", "theme"];
8772
+ const _excluded$R = ["children", "className", "kind", "theme"];
8747
8773
  /**
8748
8774
  * Component display name.
8749
8775
  */
@@ -8776,7 +8802,7 @@ const InputHelper = forwardRef((props, ref) => {
8776
8802
  kind = DEFAULT_PROPS$D.kind,
8777
8803
  theme = defaultTheme
8778
8804
  } = props,
8779
- forwardedProps = _objectWithoutProperties(props, _excluded$S);
8805
+ forwardedProps = _objectWithoutProperties(props, _excluded$R);
8780
8806
  const {
8781
8807
  color
8782
8808
  } = INPUT_HELPER_CONFIGURATION[kind] || {};
@@ -8795,7 +8821,7 @@ InputHelper.displayName = COMPONENT_NAME$O;
8795
8821
  InputHelper.className = CLASSNAME$O;
8796
8822
  InputHelper.defaultProps = DEFAULT_PROPS$D;
8797
8823
 
8798
- const _excluded$R = ["children", "className", "htmlFor", "isRequired", "theme", "typography"];
8824
+ const _excluded$Q = ["children", "className", "htmlFor", "isRequired", "theme", "typography"];
8799
8825
  /**
8800
8826
  * Component display name.
8801
8827
  */
@@ -8828,7 +8854,7 @@ const InputLabel = forwardRef((props, ref) => {
8828
8854
  theme = defaultTheme,
8829
8855
  typography
8830
8856
  } = props,
8831
- forwardedProps = _objectWithoutProperties(props, _excluded$R);
8857
+ forwardedProps = _objectWithoutProperties(props, _excluded$Q);
8832
8858
  const typographyClass = typography && getTypographyClassName(typography);
8833
8859
  return /*#__PURE__*/jsx("label", _objectSpread2(_objectSpread2({
8834
8860
  ref: ref
@@ -8847,7 +8873,7 @@ InputLabel.displayName = COMPONENT_NAME$N;
8847
8873
  InputLabel.className = CLASSNAME$N;
8848
8874
  InputLabel.defaultProps = DEFAULT_PROPS$C;
8849
8875
 
8850
- const _excluded$Q = ["aria-labelledby", "ariaLabelledBy", "aria-label", "ariaLabel", "children", "className", "closeButtonProps", "isOpen", "onClose", "parentElement", "focusElement", "preventAutoClose", "theme", "zIndex"];
8876
+ const _excluded$P = ["aria-labelledby", "ariaLabelledBy", "aria-label", "ariaLabel", "children", "className", "closeButtonProps", "isOpen", "onClose", "parentElement", "focusElement", "preventAutoClose", "theme", "zIndex"];
8851
8877
  /**
8852
8878
  * Component display name.
8853
8879
  */
@@ -8882,7 +8908,7 @@ const Lightbox = forwardRef((props, ref) => {
8882
8908
  theme,
8883
8909
  zIndex
8884
8910
  } = props,
8885
- forwardedProps = _objectWithoutProperties(props, _excluded$Q);
8911
+ forwardedProps = _objectWithoutProperties(props, _excluded$P);
8886
8912
  if (!DOCUMENT) {
8887
8913
  // Can't render in SSR.
8888
8914
  return null;
@@ -8982,7 +9008,7 @@ const Lightbox = forwardRef((props, ref) => {
8982
9008
  Lightbox.displayName = COMPONENT_NAME$M;
8983
9009
  Lightbox.className = CLASSNAME$M;
8984
9010
 
8985
- const _excluded$P = ["children", "className", "color", "colorVariant", "href", "leftIcon", "linkAs", "rightIcon", "target", "typography"];
9011
+ const _excluded$O = ["children", "className", "color", "colorVariant", "leftIcon", "rightIcon", "typography", "linkAs"];
8986
9012
  /**
8987
9013
  * Component display name.
8988
9014
  */
@@ -9002,7 +9028,6 @@ const CLASSNAME$L = getRootClassName(COMPONENT_NAME$L);
9002
9028
  */
9003
9029
  const Link = forwardRef((props, ref) => {
9004
9030
  const {
9005
- isAnyDisabled,
9006
9031
  disabledStateProps,
9007
9032
  otherProps
9008
9033
  } = useDisableStateProps(props);
@@ -9011,28 +9036,17 @@ const Link = forwardRef((props, ref) => {
9011
9036
  className,
9012
9037
  color: propColor,
9013
9038
  colorVariant: propColorVariant,
9014
- href,
9015
9039
  leftIcon,
9016
- linkAs,
9017
9040
  rightIcon,
9018
- target,
9019
- typography
9041
+ typography,
9042
+ linkAs
9020
9043
  } = otherProps,
9021
- forwardedProps = _objectWithoutProperties(otherProps, _excluded$P);
9044
+ forwardedProps = _objectWithoutProperties(otherProps, _excluded$O);
9022
9045
  const [color, colorVariant] = resolveColorWithVariants(propColor, propColorVariant);
9023
- const isLink = linkAs || href;
9024
- const Component = isLink && !isAnyDisabled ? linkAs || 'a' : 'button';
9025
- const baseProps = {};
9026
- if (Component === 'button') {
9027
- baseProps.type = 'button';
9028
- Object.assign(baseProps, disabledStateProps);
9029
- } else if (isLink) {
9030
- baseProps.href = href;
9031
- baseProps.target = target;
9032
- }
9033
- return /*#__PURE__*/jsx(Component, _objectSpread2(_objectSpread2(_objectSpread2({
9034
- ref: ref
9035
- }, forwardedProps), baseProps), {}, {
9046
+ return /*#__PURE__*/jsx(RawClickable, _objectSpread2(_objectSpread2(_objectSpread2({
9047
+ ref: ref,
9048
+ as: linkAs || (forwardedProps.href ? 'a' : 'button')
9049
+ }, forwardedProps), disabledStateProps), {}, {
9036
9050
  className: classNames(className, handleBasicClasses({
9037
9051
  prefix: CLASSNAME$L,
9038
9052
  color,
@@ -9056,7 +9070,7 @@ const Link = forwardRef((props, ref) => {
9056
9070
  Link.displayName = COMPONENT_NAME$L;
9057
9071
  Link.className = CLASSNAME$L;
9058
9072
 
9059
- const _excluded$O = ["className", "description", "link", "linkAs", "linkProps", "size", "theme", "thumbnailProps", "title", "titleHeading"];
9073
+ const _excluded$N = ["className", "description", "link", "linkAs", "linkProps", "size", "theme", "thumbnailProps", "title", "titleHeading"];
9060
9074
  /**
9061
9075
  * Component display name.
9062
9076
  */
@@ -9096,7 +9110,7 @@ const LinkPreview = forwardRef((props, ref) => {
9096
9110
  title,
9097
9111
  titleHeading = DEFAULT_PROPS$B.titleHeading
9098
9112
  } = props,
9099
- forwardedProps = _objectWithoutProperties(props, _excluded$O);
9113
+ forwardedProps = _objectWithoutProperties(props, _excluded$N);
9100
9114
  // Use title heading as title wrapper (see DEFAULT_PROPS for the default value).
9101
9115
  const TitleHeading = titleHeading;
9102
9116
  return /*#__PURE__*/jsx("article", _objectSpread2(_objectSpread2({
@@ -9160,7 +9174,7 @@ LinkPreview.displayName = COMPONENT_NAME$K;
9160
9174
  LinkPreview.className = CLASSNAME$K;
9161
9175
  LinkPreview.defaultProps = DEFAULT_PROPS$B;
9162
9176
 
9163
- const _excluded$N = ["className"];
9177
+ const _excluded$M = ["className"];
9164
9178
  /**
9165
9179
  * Component display name.
9166
9180
  */
@@ -9182,7 +9196,7 @@ const ListDivider = forwardRef((props, ref) => {
9182
9196
  const {
9183
9197
  className
9184
9198
  } = props,
9185
- forwardedProps = _objectWithoutProperties(props, _excluded$N);
9199
+ forwardedProps = _objectWithoutProperties(props, _excluded$M);
9186
9200
  return /*#__PURE__*/jsx("li", _objectSpread2(_objectSpread2({
9187
9201
  ref: ref
9188
9202
  }, forwardedProps), {}, {
@@ -9192,7 +9206,7 @@ const ListDivider = forwardRef((props, ref) => {
9192
9206
  ListDivider.displayName = COMPONENT_NAME$J;
9193
9207
  ListDivider.className = CLASSNAME$J;
9194
9208
 
9195
- const _excluded$M = ["children", "className"];
9209
+ const _excluded$L = ["children", "className"];
9196
9210
  /**
9197
9211
  * Component display name.
9198
9212
  */
@@ -9215,7 +9229,7 @@ const ListSubheader = forwardRef((props, ref) => {
9215
9229
  children,
9216
9230
  className
9217
9231
  } = props,
9218
- forwardedProps = _objectWithoutProperties(props, _excluded$M);
9232
+ forwardedProps = _objectWithoutProperties(props, _excluded$L);
9219
9233
  return /*#__PURE__*/jsx("li", _objectSpread2(_objectSpread2({
9220
9234
  ref: ref
9221
9235
  }, forwardedProps), {}, {
@@ -9226,7 +9240,7 @@ const ListSubheader = forwardRef((props, ref) => {
9226
9240
  ListSubheader.displayName = COMPONENT_NAME$I;
9227
9241
  ListSubheader.className = CLASSNAME$I;
9228
9242
 
9229
- const _excluded$L = ["children", "className", "hasBackground", "kind", "icon", "closeButtonProps"];
9243
+ const _excluded$K = ["children", "className", "hasBackground", "kind", "icon", "closeButtonProps"];
9230
9244
  /**
9231
9245
  * Component display name.
9232
9246
  */
@@ -9275,7 +9289,7 @@ const Message = forwardRef((props, ref) => {
9275
9289
  icon: customIcon,
9276
9290
  closeButtonProps
9277
9291
  } = props,
9278
- forwardedProps = _objectWithoutProperties(props, _excluded$L);
9292
+ forwardedProps = _objectWithoutProperties(props, _excluded$K);
9279
9293
  const {
9280
9294
  color,
9281
9295
  icon
@@ -9313,7 +9327,7 @@ const Message = forwardRef((props, ref) => {
9313
9327
  Message.displayName = COMPONENT_NAME$H;
9314
9328
  Message.className = CLASSNAME$H;
9315
9329
 
9316
- const _excluded$K = ["className", "theme", "thumbnails", "onImageClick"],
9330
+ const _excluded$J = ["className", "theme", "thumbnails", "onImageClick"],
9317
9331
  _excluded2$2 = ["image", "onClick", "align"];
9318
9332
  /**
9319
9333
  * Component display name.
@@ -9345,7 +9359,7 @@ const Mosaic = forwardRef((props, ref) => {
9345
9359
  thumbnails,
9346
9360
  onImageClick
9347
9361
  } = props,
9348
- forwardedProps = _objectWithoutProperties(props, _excluded$K);
9362
+ forwardedProps = _objectWithoutProperties(props, _excluded$J);
9349
9363
  const handleImageClick = useMemo(() => {
9350
9364
  if (!onImageClick) return undefined;
9351
9365
  return (index, onClick) => event => {
@@ -9398,10 +9412,7 @@ Mosaic.displayName = COMPONENT_NAME$G;
9398
9412
  Mosaic.className = CLASSNAME$G;
9399
9413
  Mosaic.defaultProps = DEFAULT_PROPS$A;
9400
9414
 
9401
- /** Same as `React.forwardRef` but inferring Ref type from the `as` prop. */
9402
- const forwardRefPolymorphic = React__default.forwardRef;
9403
-
9404
- const _excluded$J = ["className", "icon", "label", "isCurrentPage", "as"];
9415
+ const _excluded$I = ["className", "icon", "label", "isCurrentPage", "as"];
9405
9416
  /**
9406
9417
  * Component display name.
9407
9418
  */
@@ -9419,15 +9430,12 @@ const NavigationItem = Object.assign(forwardRefPolymorphic((props, ref) => {
9419
9430
  isCurrentPage,
9420
9431
  as: Element = 'a'
9421
9432
  } = props,
9422
- forwardedProps = _objectWithoutProperties(props, _excluded$J);
9433
+ forwardedProps = _objectWithoutProperties(props, _excluded$I);
9423
9434
  const theme = useTheme();
9424
9435
  const {
9425
9436
  tooltipLabel,
9426
9437
  labelRef
9427
9438
  } = useOverflowTooltipLabel(label);
9428
- const buttonProps = Element === 'button' ? {
9429
- type: 'button'
9430
- } : {};
9431
9439
  return /*#__PURE__*/jsx("li", {
9432
9440
  className: classNames(className, handleBasicClasses({
9433
9441
  prefix: CLASSNAME$F,
@@ -9436,14 +9444,15 @@ const NavigationItem = Object.assign(forwardRefPolymorphic((props, ref) => {
9436
9444
  children: /*#__PURE__*/jsx(Tooltip, {
9437
9445
  label: tooltipLabel,
9438
9446
  placement: Placement.TOP,
9439
- children: /*#__PURE__*/jsxs(Element, _objectSpread2(_objectSpread2(_objectSpread2({
9447
+ children: /*#__PURE__*/jsxs(RawClickable, _objectSpread2(_objectSpread2({
9448
+ as: Element,
9440
9449
  className: handleBasicClasses({
9441
9450
  prefix: `${CLASSNAME$F}__link`,
9442
9451
  isSelected: isCurrentPage
9443
9452
  }),
9444
9453
  ref: ref,
9445
9454
  "aria-current": isCurrentPage ? 'page' : undefined
9446
- }, buttonProps), forwardedProps), {}, {
9455
+ }, forwardedProps), {}, {
9447
9456
  children: [icon ? /*#__PURE__*/jsx(Icon, {
9448
9457
  className: `${CLASSNAME$F}__icon`,
9449
9458
  icon: icon,
@@ -9468,7 +9477,7 @@ const NavigationContext = /*#__PURE__*/createContext({
9468
9477
  orientation: Orientation.vertical
9469
9478
  });
9470
9479
 
9471
- const _excluded$I = ["children", "className", "label", "icon"];
9480
+ const _excluded$H = ["children", "className", "label", "icon"];
9472
9481
  /**
9473
9482
  * Component display name.
9474
9483
  */
@@ -9485,7 +9494,7 @@ const NavigationSection = forwardRef((props, ref) => {
9485
9494
  label,
9486
9495
  icon
9487
9496
  } = props,
9488
- forwardedProps = _objectWithoutProperties(props, _excluded$I);
9497
+ forwardedProps = _objectWithoutProperties(props, _excluded$H);
9489
9498
  const [isOpen, setIsOpen] = useState(false);
9490
9499
  const buttonRef = useRef(null);
9491
9500
  const sectionId = useId();
@@ -9500,7 +9509,9 @@ const NavigationSection = forwardRef((props, ref) => {
9500
9509
  theme
9501
9510
  })),
9502
9511
  ref: ref,
9503
- children: [/*#__PURE__*/jsxs("button", _objectSpread2(_objectSpread2({}, forwardedProps), {}, {
9512
+ children: [/*#__PURE__*/jsxs(RawClickable, _objectSpread2(_objectSpread2({
9513
+ as: "button"
9514
+ }, forwardedProps), {}, {
9504
9515
  "aria-controls": sectionId,
9505
9516
  "aria-expanded": isOpen,
9506
9517
  className: classNames(`${CLASSNAME$F}__link`),
@@ -9509,7 +9520,6 @@ const NavigationSection = forwardRef((props, ref) => {
9509
9520
  setIsOpen(!isOpen);
9510
9521
  event.stopPropagation();
9511
9522
  },
9512
- type: "button",
9513
9523
  children: [icon ? /*#__PURE__*/jsx(Icon, {
9514
9524
  className: `${CLASSNAME$F}__icon`,
9515
9525
  icon: icon,
@@ -9557,7 +9567,7 @@ const NavigationSection = forwardRef((props, ref) => {
9557
9567
  NavigationSection.displayName = COMPONENT_NAME$E;
9558
9568
  NavigationSection.className = CLASSNAME$E;
9559
9569
 
9560
- const _excluded$H = ["children", "className", "theme", "orientation"];
9570
+ const _excluded$G = ["children", "className", "theme", "orientation"];
9561
9571
  /**
9562
9572
  * Component display name.
9563
9573
  */
@@ -9582,7 +9592,7 @@ const Navigation = forwardRef((props, ref) => {
9582
9592
  theme = defaultTheme,
9583
9593
  orientation = DEFAULT_PROPS$z.orientation
9584
9594
  } = props,
9585
- forwardedProps = _objectWithoutProperties(props, _excluded$H);
9595
+ forwardedProps = _objectWithoutProperties(props, _excluded$G);
9586
9596
  return /*#__PURE__*/jsx(ThemeProvider, {
9587
9597
  value: theme,
9588
9598
  children: /*#__PURE__*/jsx("nav", _objectSpread2(_objectSpread2({
@@ -9635,7 +9645,7 @@ const NOTIFICATION_CONFIGURATION = {
9635
9645
  }
9636
9646
  };
9637
9647
 
9638
- const _excluded$G = ["actionLabel", "className", "content", "isOpen", "onActionClick", "onClick", "theme", "type", "zIndex", "usePortal", "style"];
9648
+ const _excluded$F = ["actionLabel", "className", "content", "isOpen", "onActionClick", "onClick", "theme", "type", "zIndex", "usePortal", "style"];
9639
9649
  /**
9640
9650
  * Component display name.
9641
9651
  */
@@ -9677,7 +9687,7 @@ const Notification = forwardRef((props, ref) => {
9677
9687
  usePortal = DEFAULT_PROPS$y.usePortal,
9678
9688
  style
9679
9689
  } = props,
9680
- forwardedProps = _objectWithoutProperties(props, _excluded$G);
9690
+ forwardedProps = _objectWithoutProperties(props, _excluded$F);
9681
9691
  if (!DOCUMENT) {
9682
9692
  // Can't render in SSR.
9683
9693
  return null;
@@ -9741,7 +9751,7 @@ Notification.displayName = COMPONENT_NAME$C;
9741
9751
  Notification.className = CLASSNAME$C;
9742
9752
  Notification.defaultProps = DEFAULT_PROPS$y;
9743
9753
 
9744
- const _excluded$F = ["children", "isOpen", "focusElement", "aria-label", "label", "className"];
9754
+ const _excluded$E = ["children", "isOpen", "focusElement", "aria-label", "label", "className"];
9745
9755
  /**
9746
9756
  * Component display name.
9747
9757
  */
@@ -9773,7 +9783,7 @@ const PopoverDialog = forwardRef((props, ref) => {
9773
9783
  label = ariaLabel,
9774
9784
  className
9775
9785
  } = props,
9776
- forwardedProps = _objectWithoutProperties(props, _excluded$F);
9786
+ forwardedProps = _objectWithoutProperties(props, _excluded$E);
9777
9787
  return /*#__PURE__*/jsx(Popover, _objectSpread2(_objectSpread2({}, forwardedProps), {}, {
9778
9788
  ref: ref,
9779
9789
  className: classNames(className, CLASSNAME$B),
@@ -9799,7 +9809,7 @@ PopoverDialog.displayName = COMPONENT_NAME$B;
9799
9809
  PopoverDialog.className = CLASSNAME$B;
9800
9810
  PopoverDialog.defaultProps = DEFAULT_PROPS$x;
9801
9811
 
9802
- const _excluded$E = ["actions", "attachments", "author", "className", "meta", "onClick", "orientation", "tags", "text", "theme", "thumbnailProps", "title"];
9812
+ const _excluded$D = ["actions", "attachments", "author", "className", "meta", "onClick", "orientation", "tags", "text", "theme", "thumbnailProps", "title"];
9803
9813
  /**
9804
9814
  * Component display name.
9805
9815
  */
@@ -9840,7 +9850,7 @@ const PostBlock = forwardRef((props, ref) => {
9840
9850
  thumbnailProps,
9841
9851
  title
9842
9852
  } = props,
9843
- forwardedProps = _objectWithoutProperties(props, _excluded$E);
9853
+ forwardedProps = _objectWithoutProperties(props, _excluded$D);
9844
9854
  return /*#__PURE__*/jsxs("div", _objectSpread2(_objectSpread2({
9845
9855
  ref: ref,
9846
9856
  className: classNames(className, handleBasicClasses({
@@ -9897,7 +9907,7 @@ PostBlock.displayName = COMPONENT_NAME$A;
9897
9907
  PostBlock.className = CLASSNAME$A;
9898
9908
  PostBlock.defaultProps = DEFAULT_PROPS$w;
9899
9909
 
9900
- const _excluded$D = ["className", "theme"];
9910
+ const _excluded$C = ["className", "theme"];
9901
9911
  /**
9902
9912
  * Component display name.
9903
9913
  */
@@ -9926,7 +9936,7 @@ const ProgressLinear = forwardRef((props, ref) => {
9926
9936
  className,
9927
9937
  theme = defaultTheme
9928
9938
  } = props,
9929
- forwardedProps = _objectWithoutProperties(props, _excluded$D);
9939
+ forwardedProps = _objectWithoutProperties(props, _excluded$C);
9930
9940
  return /*#__PURE__*/jsxs("div", _objectSpread2(_objectSpread2({
9931
9941
  ref: ref
9932
9942
  }, forwardedProps), {}, {
@@ -9945,7 +9955,7 @@ ProgressLinear.displayName = COMPONENT_NAME$z;
9945
9955
  ProgressLinear.className = CLASSNAME$z;
9946
9956
  ProgressLinear.defaultProps = DEFAULT_PROPS$v;
9947
9957
 
9948
- const _excluded$C = ["className", "theme", "size", "display"];
9958
+ const _excluded$B = ["className", "theme", "size", "display"];
9949
9959
  /**
9950
9960
  * Component display name.
9951
9961
  */
@@ -9979,7 +9989,7 @@ const ProgressCircular = forwardRef((props, ref) => {
9979
9989
  size = DEFAULT_PROPS$u.size,
9980
9990
  display = DEFAULT_PROPS$u.display
9981
9991
  } = props,
9982
- forwardedProps = _objectWithoutProperties(props, _excluded$C);
9992
+ forwardedProps = _objectWithoutProperties(props, _excluded$B);
9983
9993
  const Element = display === 'block' ? 'div' : 'span';
9984
9994
  return /*#__PURE__*/jsxs(Element, _objectSpread2(_objectSpread2({
9985
9995
  ref: ref
@@ -10012,7 +10022,7 @@ ProgressCircular.displayName = COMPONENT_NAME$y;
10012
10022
  ProgressCircular.className = CLASSNAME$y;
10013
10023
  ProgressCircular.defaultProps = DEFAULT_PROPS$u;
10014
10024
 
10015
- const _excluded$B = ["className", "theme", "variant"];
10025
+ const _excluded$A = ["className", "theme", "variant"];
10016
10026
  const ProgressVariant = {
10017
10027
  linear: 'linear',
10018
10028
  circular: 'circular'
@@ -10054,7 +10064,7 @@ const Progress = forwardRef((props, ref) => {
10054
10064
  theme = defaultTheme,
10055
10065
  variant = DEFAULT_PROPS$t.variant
10056
10066
  } = props,
10057
- forwardedProps = _objectWithoutProperties(props, _excluded$B);
10067
+ forwardedProps = _objectWithoutProperties(props, _excluded$A);
10058
10068
  return /*#__PURE__*/jsxs("div", _objectSpread2(_objectSpread2({
10059
10069
  ref: ref
10060
10070
  }, forwardedProps), {}, {
@@ -10192,7 +10202,7 @@ const useTabProviderContextState = () => {
10192
10202
  return context === null || context === void 0 ? void 0 : context[0];
10193
10203
  };
10194
10204
 
10195
- const _excluded$A = ["children", "onChange"];
10205
+ const _excluded$z = ["children", "onChange"];
10196
10206
  const DEFAULT_PROPS$s = {
10197
10207
  isLazy: INIT_STATE.isLazy,
10198
10208
  shouldActivateOnFocus: INIT_STATE.shouldActivateOnFocus
@@ -10214,7 +10224,7 @@ const ProgressTrackerProvider = props => {
10214
10224
  children,
10215
10225
  onChange
10216
10226
  } = props,
10217
- propState = _objectWithoutProperties(props, _excluded$A);
10227
+ propState = _objectWithoutProperties(props, _excluded$z);
10218
10228
  const [state, dispatch] = useReducer(reducer, INIT_STATE);
10219
10229
 
10220
10230
  // On prop state change => dispatch update.
@@ -10318,7 +10328,7 @@ const useRovingTabIndex = ({
10318
10328
  [parentRef, ...extraDependencies]);
10319
10329
  };
10320
10330
 
10321
- const _excluded$z = ["aria-label", "children", "className"];
10331
+ const _excluded$y = ["aria-label", "children", "className"];
10322
10332
  /**
10323
10333
  * Component display name.
10324
10334
  */
@@ -10350,7 +10360,7 @@ const ProgressTracker = forwardRef((props, ref) => {
10350
10360
  children,
10351
10361
  className
10352
10362
  } = props,
10353
- forwardedProps = _objectWithoutProperties(props, _excluded$z);
10363
+ forwardedProps = _objectWithoutProperties(props, _excluded$y);
10354
10364
  const stepListRef = React__default.useRef(null);
10355
10365
  useRovingTabIndex({
10356
10366
  parentRef: stepListRef,
@@ -10391,7 +10401,7 @@ ProgressTracker.displayName = COMPONENT_NAME$w;
10391
10401
  ProgressTracker.className = CLASSNAME$w;
10392
10402
  ProgressTracker.defaultProps = DEFAULT_PROPS$r;
10393
10403
 
10394
- const _excluded$y = ["className", "hasError", "helper", "id", "isActive", "isComplete", "label", "onFocus", "onKeyPress", "tabIndex"];
10404
+ const _excluded$x = ["className", "hasError", "helper", "id", "isActive", "isComplete", "label", "onFocus", "onKeyPress", "tabIndex"];
10395
10405
  /**
10396
10406
  * Component display name.
10397
10407
  */
@@ -10433,7 +10443,7 @@ const ProgressTrackerStep = forwardRef((props, ref) => {
10433
10443
  onKeyPress,
10434
10444
  tabIndex = -1
10435
10445
  } = otherProps,
10436
- forwardedProps = _objectWithoutProperties(otherProps, _excluded$y);
10446
+ forwardedProps = _objectWithoutProperties(otherProps, _excluded$x);
10437
10447
  const state = useTabProviderContext('tab', id);
10438
10448
  const isActive = propIsActive || (state === null || state === void 0 ? void 0 : state.isActive);
10439
10449
  const changeToCurrentTab = useCallback(() => {
@@ -10503,7 +10513,7 @@ ProgressTrackerStep.displayName = COMPONENT_NAME$v;
10503
10513
  ProgressTrackerStep.className = CLASSNAME$v;
10504
10514
  ProgressTrackerStep.defaultProps = DEFAULT_PROPS$q;
10505
10515
 
10506
- const _excluded$x = ["children", "id", "className", "isActive"];
10516
+ const _excluded$w = ["children", "id", "className", "isActive"];
10507
10517
  /**
10508
10518
  * Component display name.
10509
10519
  */
@@ -10535,7 +10545,7 @@ const ProgressTrackerStepPanel = forwardRef((props, ref) => {
10535
10545
  className,
10536
10546
  isActive: propIsActive
10537
10547
  } = props,
10538
- forwardedProps = _objectWithoutProperties(props, _excluded$x);
10548
+ forwardedProps = _objectWithoutProperties(props, _excluded$w);
10539
10549
  const state = useTabProviderContext('tabPanel', id);
10540
10550
  const isActive = propIsActive || (state === null || state === void 0 ? void 0 : state.isActive);
10541
10551
  return /*#__PURE__*/jsx("div", _objectSpread2(_objectSpread2({
@@ -10556,7 +10566,7 @@ ProgressTrackerStepPanel.displayName = COMPONENT_NAME$u;
10556
10566
  ProgressTrackerStepPanel.className = CLASSNAME$u;
10557
10567
  ProgressTrackerStepPanel.defaultProps = DEFAULT_PROPS$p;
10558
10568
 
10559
- const _excluded$w = ["checked", "className", "helper", "id", "inputRef", "isChecked", "label", "name", "onChange", "theme", "value", "inputProps"];
10569
+ const _excluded$v = ["checked", "className", "helper", "id", "inputRef", "isChecked", "label", "name", "onChange", "theme", "value", "inputProps"];
10560
10570
  /**
10561
10571
  * Component display name.
10562
10572
  */
@@ -10600,7 +10610,7 @@ const RadioButton = forwardRef((props, ref) => {
10600
10610
  value,
10601
10611
  inputProps
10602
10612
  } = otherProps,
10603
- forwardedProps = _objectWithoutProperties(otherProps, _excluded$w);
10613
+ forwardedProps = _objectWithoutProperties(otherProps, _excluded$v);
10604
10614
  const generatedInputId = useId();
10605
10615
  const inputId = id || generatedInputId;
10606
10616
  const handleChange = event => {
@@ -10660,7 +10670,7 @@ RadioButton.displayName = COMPONENT_NAME$t;
10660
10670
  RadioButton.className = CLASSNAME$t;
10661
10671
  RadioButton.defaultProps = DEFAULT_PROPS$o;
10662
10672
 
10663
- const _excluded$v = ["children", "className"];
10673
+ const _excluded$u = ["children", "className"];
10664
10674
  /**
10665
10675
  * Component display name.
10666
10676
  */
@@ -10683,7 +10693,7 @@ const RadioGroup = forwardRef((props, ref) => {
10683
10693
  children,
10684
10694
  className
10685
10695
  } = props,
10686
- forwardedProps = _objectWithoutProperties(props, _excluded$v);
10696
+ forwardedProps = _objectWithoutProperties(props, _excluded$u);
10687
10697
  return /*#__PURE__*/jsx("div", _objectSpread2(_objectSpread2({
10688
10698
  ref: ref
10689
10699
  }, forwardedProps), {}, {
@@ -10718,7 +10728,7 @@ function useListenFocus(ref) {
10718
10728
  return isFocus;
10719
10729
  }
10720
10730
 
10721
- const _excluded$u = ["children", "className", "focusElement", "isMultiple", "closeOnClick", "disabled", "error", "hasError", "helper", "id", "isDisabled", "isEmpty", "isOpen", "isRequired", "isValid", "label", "onClear", "onDropdownClose", "onInfiniteScroll", "onInputClick", "placeholder", "theme", "value", "variant"];
10731
+ const _excluded$t = ["children", "className", "focusElement", "isMultiple", "closeOnClick", "disabled", "error", "hasError", "helper", "id", "isDisabled", "isEmpty", "isOpen", "isRequired", "isValid", "label", "onClear", "onDropdownClose", "onInfiniteScroll", "onInputClick", "placeholder", "theme", "value", "variant"];
10722
10732
  /** The display name of the component. */
10723
10733
  const COMPONENT_NAME$r = 'Select';
10724
10734
 
@@ -10752,7 +10762,7 @@ const WithSelectContext = (SelectElement, props, ref) => {
10752
10762
  value,
10753
10763
  variant
10754
10764
  } = props,
10755
- forwardedProps = _objectWithoutProperties(props, _excluded$u);
10765
+ forwardedProps = _objectWithoutProperties(props, _excluded$t);
10756
10766
  const generatedSelectId = useId();
10757
10767
  const selectId = id || generatedSelectId;
10758
10768
  const anchorRef = useRef(null);
@@ -10839,7 +10849,7 @@ const SelectVariant = {
10839
10849
  chip: 'chip'
10840
10850
  };
10841
10851
 
10842
- const _excluded$t = ["anchorRef", "clearButtonProps", "handleKeyboardNav", "hasError", "hasInputClear", "icon", "id", "isDisabled", "isEmpty", "isRequired", "isValid", "label", "onClear", "onInputClick", "placeholder", "selectedValueRender", "theme", "value", "variant", "selectElementRef"];
10852
+ const _excluded$s = ["anchorRef", "clearButtonProps", "handleKeyboardNav", "hasError", "hasInputClear", "icon", "id", "isDisabled", "isEmpty", "isRequired", "isValid", "label", "onClear", "onInputClick", "placeholder", "selectedValueRender", "theme", "value", "variant", "selectElementRef"];
10843
10853
 
10844
10854
  /** The display name of the component. */
10845
10855
  const COMPONENT_NAME$q = 'Select';
@@ -10881,7 +10891,7 @@ const SelectField = props => {
10881
10891
  variant,
10882
10892
  selectElementRef
10883
10893
  } = props,
10884
- forwardedProps = _objectWithoutProperties(props, _excluded$t);
10894
+ forwardedProps = _objectWithoutProperties(props, _excluded$s);
10885
10895
  return /*#__PURE__*/jsxs(Fragment, {
10886
10896
  children: [variant === SelectVariant.input && /*#__PURE__*/jsxs(Fragment, {
10887
10897
  children: [label && /*#__PURE__*/jsx("div", {
@@ -10982,7 +10992,7 @@ Select.className = CLASSNAME$q;
10982
10992
  Select.defaultProps = DEFAULT_PROPS$n;
10983
10993
  Select.className = CLASSNAME$q;
10984
10994
 
10985
- const _excluded$s = ["anchorRef", "handleKeyboardNav", "hasError", "icon", "id", "isDisabled", "isEmpty", "isRequired", "isValid", "label", "onClear", "onInputClick", "placeholder", "selectedChipRender", "selectedValueRender", "theme", "value", "variant", "selectElementRef"];
10995
+ const _excluded$r = ["anchorRef", "handleKeyboardNav", "hasError", "icon", "id", "isDisabled", "isEmpty", "isRequired", "isValid", "label", "onClear", "onInputClick", "placeholder", "selectedChipRender", "selectedValueRender", "theme", "value", "variant", "selectElementRef"];
10986
10996
  /** The display name of the component. */
10987
10997
  const COMPONENT_NAME$p = 'Select';
10988
10998
 
@@ -11032,7 +11042,7 @@ const SelectMultipleField = props => {
11032
11042
  variant,
11033
11043
  selectElementRef
11034
11044
  } = props,
11035
- forwardedProps = _objectWithoutProperties(props, _excluded$s);
11045
+ forwardedProps = _objectWithoutProperties(props, _excluded$r);
11036
11046
  return /*#__PURE__*/jsxs(Fragment, {
11037
11047
  children: [variant === SelectVariant.input && /*#__PURE__*/jsxs(Fragment, {
11038
11048
  children: [label && /*#__PURE__*/jsx("div", {
@@ -11126,7 +11136,7 @@ SelectMultiple.displayName = COMPONENT_NAME$p;
11126
11136
  SelectMultiple.className = CLASSNAME$p;
11127
11137
  SelectMultiple.defaultProps = DEFAULT_PROPS$m;
11128
11138
 
11129
- const _excluded$r = ["children", "className", "theme"];
11139
+ const _excluded$q = ["children", "className", "theme"];
11130
11140
  /**
11131
11141
  * Component display name.
11132
11142
  */
@@ -11151,7 +11161,7 @@ const SideNavigation = forwardRef((props, ref) => {
11151
11161
  className,
11152
11162
  theme = defaultTheme
11153
11163
  } = props,
11154
- forwardedProps = _objectWithoutProperties(props, _excluded$r);
11164
+ forwardedProps = _objectWithoutProperties(props, _excluded$q);
11155
11165
  const content = Children.toArray(children).filter(isComponent(SideNavigationItem));
11156
11166
  return /*#__PURE__*/jsx("ul", _objectSpread2(_objectSpread2({
11157
11167
  ref: ref
@@ -11163,22 +11173,6 @@ const SideNavigation = forwardRef((props, ref) => {
11163
11173
  SideNavigation.displayName = COMPONENT_NAME$o;
11164
11174
  SideNavigation.className = CLASSNAME$o;
11165
11175
 
11166
- const _excluded$q = ["linkAs", "href"];
11167
- /**
11168
- * Render <button> HTML component, fallbacks to `<a>` when a `href` is provided or a custom component with `linkAs`.
11169
- */
11170
- const renderButtonOrLink = (props, ...children) => {
11171
- const {
11172
- linkAs,
11173
- href
11174
- } = props,
11175
- forwardedProps = _objectWithoutProperties(props, _excluded$q);
11176
- if (linkAs || href) return renderLink(props, ...children);
11177
- return /*#__PURE__*/React__default.createElement('button', _objectSpread2({
11178
- type: 'button'
11179
- }, forwardedProps), ...children);
11180
- };
11181
-
11182
11176
  const _excluded$p = ["children", "className", "emphasis", "icon", "isOpen", "isSelected", "label", "linkAs", "linkProps", "onActionClick", "onClick", "toggleButtonProps", "closeMode"];
11183
11177
  /**
11184
11178
  * Component display name.
@@ -11244,18 +11238,18 @@ const SideNavigationItem = forwardRef((props, ref) => {
11244
11238
  })),
11245
11239
  children: [shouldSplitActions ? /*#__PURE__*/jsxs("div", {
11246
11240
  className: `${CLASSNAME$n}__wrapper`,
11247
- children: [renderLink(_objectSpread2(_objectSpread2({
11248
- linkAs
11241
+ children: [/*#__PURE__*/jsxs(RawClickable, _objectSpread2(_objectSpread2({
11242
+ as: linkAs || (linkProps !== null && linkProps !== void 0 && linkProps.href ? 'a' : 'button')
11249
11243
  }, linkProps), {}, {
11250
11244
  className: `${CLASSNAME$n}__link`,
11251
- onClick,
11252
- tabIndex: 0
11253
- }), icon && /*#__PURE__*/jsx(Icon, {
11254
- className: `${CLASSNAME$n}__icon`,
11255
- icon: icon,
11256
- size: Size.xs
11257
- }), /*#__PURE__*/jsx("span", {
11258
- children: label
11245
+ onClick: onClick,
11246
+ children: [icon && /*#__PURE__*/jsx(Icon, {
11247
+ className: `${CLASSNAME$n}__icon`,
11248
+ icon: icon,
11249
+ size: Size.xs
11250
+ }), /*#__PURE__*/jsx("span", {
11251
+ children: label
11252
+ })]
11259
11253
  })), /*#__PURE__*/jsx(IconButton, _objectSpread2(_objectSpread2({}, toggleButtonProps), {}, {
11260
11254
  className: `${CLASSNAME$n}__toggle`,
11261
11255
  icon: isOpen ? mdiChevronUp : mdiChevronDown,
@@ -11263,22 +11257,23 @@ const SideNavigationItem = forwardRef((props, ref) => {
11263
11257
  emphasis: Emphasis.low,
11264
11258
  onClick: onActionClick
11265
11259
  }, ariaProps))]
11266
- }) : renderButtonOrLink(_objectSpread2(_objectSpread2({
11267
- linkAs
11260
+ }) : /*#__PURE__*/jsxs(RawClickable, _objectSpread2(_objectSpread2(_objectSpread2({
11261
+ as: linkAs || (linkProps !== null && linkProps !== void 0 && linkProps.href ? 'a' : 'button')
11268
11262
  }, linkProps), {}, {
11269
11263
  className: `${CLASSNAME$n}__link`,
11270
- tabIndex: 0,
11271
- onClick
11272
- }, ariaProps), icon && /*#__PURE__*/jsx(Icon, {
11273
- className: `${CLASSNAME$n}__icon`,
11274
- icon: icon,
11275
- size: Size.xs
11276
- }), /*#__PURE__*/jsx("span", {
11277
- children: label
11278
- }), hasContent && /*#__PURE__*/jsx(Icon, {
11279
- className: `${CLASSNAME$n}__chevron`,
11280
- icon: isOpen ? mdiChevronUp : mdiChevronDown,
11281
- size: Size.xs
11264
+ onClick: onClick
11265
+ }, ariaProps), {}, {
11266
+ children: [icon && /*#__PURE__*/jsx(Icon, {
11267
+ className: `${CLASSNAME$n}__icon`,
11268
+ icon: icon,
11269
+ size: Size.xs
11270
+ }), /*#__PURE__*/jsx("span", {
11271
+ children: label
11272
+ }), hasContent && /*#__PURE__*/jsx(Icon, {
11273
+ className: `${CLASSNAME$n}__chevron`,
11274
+ icon: isOpen ? mdiChevronUp : mdiChevronDown,
11275
+ size: Size.xs
11276
+ })]
11282
11277
  })), (closeMode === 'hide' || showChildren) && /*#__PURE__*/jsx("ul", {
11283
11278
  className: `${CLASSNAME$n}__children`,
11284
11279
  id: contentId,
@@ -13725,7 +13720,8 @@ const Thumbnail = forwardRef((props, ref) => {
13725
13720
  var _loadingPlaceholderIm;
13726
13721
  const {
13727
13722
  isAnyDisabled,
13728
- otherProps
13723
+ otherProps,
13724
+ disabledStateProps
13729
13725
  } = useDisableStateProps(props);
13730
13726
  const defaultTheme = useTheme() || Theme.light;
13731
13727
  const {
@@ -13775,17 +13771,18 @@ const Thumbnail = forwardRef((props, ref) => {
13775
13771
  imageErrorStyle.display = 'none';
13776
13772
  }
13777
13773
  const isLink = Boolean((linkProps === null || linkProps === void 0 ? void 0 : linkProps.href) || linkAs);
13778
- const isButton = !!forwardedProps.onClick;
13779
- const isClickable = !isAnyDisabled && (isButton || isLink);
13780
- let Wrapper = 'div';
13774
+ const isClickable = !isAnyDisabled && Boolean(isLink || !!forwardedProps.onClick);
13775
+ const Wrapper = isClickable ? RawClickable : 'div';
13781
13776
  const wrapperProps = _objectSpread2({}, forwardedProps);
13782
- if (!isAnyDisabled && isLink) {
13783
- Wrapper = linkAs || 'a';
13784
- Object.assign(wrapperProps, linkProps);
13785
- } else if (!isAnyDisabled && isButton) {
13786
- Wrapper = 'button';
13787
- wrapperProps.type = forwardedProps.type || 'button';
13788
- wrapperProps['aria-label'] = forwardedProps['aria-label'] || alt;
13777
+ if (isClickable) {
13778
+ Object.assign(wrapperProps, {
13779
+ as: linkAs || (linkProps !== null && linkProps !== void 0 && linkProps.href ? 'a' : 'button')
13780
+ }, disabledStateProps);
13781
+ if (isLink) {
13782
+ Object.assign(wrapperProps, linkProps);
13783
+ } else {
13784
+ wrapperProps['aria-label'] = forwardedProps['aria-label'] || alt;
13785
+ }
13789
13786
  }
13790
13787
 
13791
13788
  // If we have a loading placeholder image that is really loaded (complete)