carbon-react 110.6.0 → 110.6.1

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.
@@ -6,9 +6,9 @@ export declare type ButtonTypes = "primary" | "secondary" | "tertiary" | "dashed
6
6
  export declare type SizeOptions = "small" | "medium" | "large";
7
7
  export declare type ButtonIconPosition = "before" | "after";
8
8
  export interface ButtonProps extends SpaceProps {
9
- /** Prop to specify the aria-label text.
10
- * Only to be used in Button when only an icon is rendered.
11
- * This is required to comply with WCAG 4.1.2 - Buttons must have discernible text
9
+ /**
10
+ * Prop to specify the aria-label attribute of the component
11
+ * Defaults to the iconType, when the component has only an icon
12
12
  */
13
13
  "aria-label"?: string;
14
14
  /** Color variants for new business themes: "primary" | "secondary" | "tertiary" | "darkBackground" */
@@ -141,7 +141,7 @@ const Button = /*#__PURE__*/React.forwardRef(({
141
141
  if (typeof activeRef === "function") activeRef(reference);
142
142
  }, [ref, forwardRef]);
143
143
  return /*#__PURE__*/React.createElement(StyledButton, _extends({
144
- "aria-label": !children && iconType ? ariaLabel || iconType : undefined,
144
+ "aria-label": !children && iconType ? ariaLabel || iconType : ariaLabel,
145
145
  as: !disabled && href ? "a" : "button",
146
146
  onKeyDown: href ? handleLinkKeyDown : undefined,
147
147
  draggable: false,
@@ -0,0 +1,8 @@
1
+ /// <reference types="react" />
2
+ import { StyledImageProps } from "./image.style";
3
+ export declare const Image: {
4
+ ({ alt, src, children, ...rest }: StyledImageProps): JSX.Element;
5
+ displayName: string;
6
+ };
7
+ export default Image;
8
+ export type { StyledImageProps as ImageProps } from "./image.style";