diff options
| author | Armand Philippot <git@armandphilippot.com> | 2022-04-12 16:09:21 +0200 |
|---|---|---|
| committer | Armand Philippot <git@armandphilippot.com> | 2022-04-12 16:09:21 +0200 |
| commit | 27ff3104aabed240470d351bda02095d8169501f (patch) | |
| tree | e4b43947c1150201067d40622b52b65bd19f01a2 /src/components/atoms/buttons/button-link.tsx | |
| parent | ff3a251e75fafce7d95177010401483127973313 (diff) | |
chore: add a Summary component
Diffstat (limited to 'src/components/atoms/buttons/button-link.tsx')
| -rw-r--r-- | src/components/atoms/buttons/button-link.tsx | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/components/atoms/buttons/button-link.tsx b/src/components/atoms/buttons/button-link.tsx index 81229c8..77a7f7b 100644 --- a/src/components/atoms/buttons/button-link.tsx +++ b/src/components/atoms/buttons/button-link.tsx @@ -8,6 +8,10 @@ export type ButtonLinkProps = { */ 'aria-label'?: string; /** + * Set additional classnames to the button link. + */ + className?: string; + /** * True if it is an external link. Default: false. */ external?: boolean; @@ -18,7 +22,7 @@ export type ButtonLinkProps = { /** * ButtonLink shape. Default: rectangle. */ - shape?: 'rectangle' | 'square'; + shape?: 'circle' | 'rectangle' | 'square'; /** * Define an URL as target. */ @@ -32,6 +36,7 @@ export type ButtonLinkProps = { */ const ButtonLink: FC<ButtonLinkProps> = ({ children, + className, target, kind = 'secondary', shape = 'rectangle', @@ -44,14 +49,17 @@ const ButtonLink: FC<ButtonLinkProps> = ({ return external ? ( <a href={target} - className={`${styles.btn} ${kindClass} ${shapeClass}`} + className={`${styles.btn} ${kindClass} ${shapeClass} ${className}`} {...props} > {children} </a> ) : ( <Link href={target}> - <a className={`${styles.btn} ${kindClass} ${shapeClass}`} {...props}> + <a + className={`${styles.btn} ${kindClass} ${shapeClass} ${className}`} + {...props} + > {children} </a> </Link> |
