UNPKG

wix-style-react

Version:
44 lines 2.09 kB
export default IconButton; declare class IconButton extends React.PureComponent<any, any, any> { static contextType: React.Context<import("../WixStyleReactDefaultsOverrideProvider").WixStyleReactDefaultsOverride>; static displayName: string; static propTypes: { /** Render button as another component or a custom HTML tag */ as: PropTypes.Requireable<NonNullable<string | object | null | undefined>>; /** Specifies a CSS class name to be appended to the component’s root element */ className: PropTypes.Requireable<string>; /** Accept any WSR icon. In order to use external icons make sure to follow sizing guidelines and contact design system UX for approval. */ children: PropTypes.Requireable<PropTypes.ReactNodeLike>; /** Sets the skin of a component */ skin: PropTypes.Requireable<string>; /** Control the priority of a component */ priority: PropTypes.Requireable<string>; /** Control the size of a component */ size: PropTypes.Requireable<string>; /** Defines a callback function which is called whenever a button is clicked */ onClick: PropTypes.Requireable<(...args: any[]) => any>; /** Specify whether button should be disabled */ disabled: PropTypes.Requireable<boolean>; /** Applies a data-hook HTML attribute that can be used in the tests */ dataHook: PropTypes.Requireable<string>; /** Define a string value that labels the button element */ ariaLabel: PropTypes.Requireable<string>; /** Identify the element that labels the button element */ ariaLabelledBy: PropTypes.Requireable<string>; }; static defaultProps: { skin: string; priority: string; disabled: boolean; }; constructor(props: any); button: React.RefObject<any>; /** * Sets focus on the button element */ focus: () => void; render(): React.JSX.Element; } import React from 'react'; import PropTypes from 'prop-types'; //# sourceMappingURL=IconButton.d.ts.map