File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ import React from 'react';
22import * as S from './styles' ;
33
44type ButtonSizesType = 'small' | 'regular' | 'large' ;
5+
56type ButtonVariantsType =
67 | 'primary'
78 | 'secondary'
@@ -38,18 +39,19 @@ export type ButtonProps = {
3839 * Set the loading status of button
3940 */
4041 loading ?: boolean ;
41- } ;
42+ } & Pick < React . ButtonHTMLAttributes < HTMLButtonElement > , 'className' > ;
4243
4344/**
4445 * API documentation for the React Button component. Learn about the available props, and the CSS API.
4546 */
4647export const Button = ( {
4748 children,
4849 variant = 'primary' ,
49- size = 'regular' ,
5050 isFullWidth = false ,
51+ size = 'regular' ,
5152 disabled = false ,
5253 onClick,
54+ ...props
5355} : ButtonProps ) => {
5456 return (
5557 < S . Container
@@ -58,6 +60,7 @@ export const Button = ({
5860 isFullWidth = { isFullWidth }
5961 disabled = { disabled }
6062 onClick = { onClick }
63+ { ...props }
6164 >
6265 < span > { children } </ span >
6366 </ S . Container >
You can’t perform that action at this time.
0 commit comments