diff --git a/src/styled.tsx b/src/styled.tsx index 7d5d21a..c48b400 100644 --- a/src/styled.tsx +++ b/src/styled.tsx @@ -1,3 +1,4 @@ +import React from 'react'; import styled from '@emotion/styled'; import colors from './colors'; @@ -7,7 +8,16 @@ export const paraGraphDefaultStyle = { lineHeight: '20px', }; -const Button = styled.button<{ hideBackground?: boolean }>` +interface ButtonBaseProps + extends React.ButtonHTMLAttributes { + type?: React.ButtonHTMLAttributes['type']; +} + +const ButtonBase = ({ type = 'button', ...props }: ButtonBaseProps) => { + return ; +}; + +const Button = styled(ButtonBase)<{ hideBackground?: boolean }>` appearance: none; margin: 0; border: 0; @@ -23,8 +33,6 @@ const Button = styled.button<{ hideBackground?: boolean }>` } `; -Button.defaultProps = { type: 'button' }; - const CircleButton = styled(Button)` font-size: 14px; font-weight: bold;