Skip to content

Commit

Permalink
fix: style을 잘못 전달하던 문제 해결
Browse files Browse the repository at this point in the history
  • Loading branch information
ImxYJL committed Aug 7, 2024
1 parent 8fb70af commit 61b0f89
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion frontend/src/components/common/Checkbox/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ interface CheckboxProps extends CheckboxStyleProps {

const Checkbox = ({ id, name, isChecked, isDisabled, onChange, $style }: CheckboxProps) => {
return (
<S.CheckboxContainer style={$style}>
<S.CheckboxContainer $style={$style}>
<S.CheckboxLabel>
<input
id={id}
Expand Down
4 changes: 1 addition & 3 deletions frontend/src/components/common/Checkbox/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ import styled from '@emotion/styled';
import { CheckboxStyleProps } from './index';

export const CheckboxContainer = styled.div<CheckboxStyleProps>`
width: ${(props) => props.$style?.width || '2.8rem'};
height: ${(props) => props.$style?.height || '2.8rem'};
padding: 0;
background-color: transparent;
Expand All @@ -18,6 +15,7 @@ export const CheckboxContainer = styled.div<CheckboxStyleProps>`
width: 0;
height: 0;
}
${({ $style }) => $style && { ...$style }};
`;

export const CheckboxLabel = styled.label`
Expand Down

0 comments on commit 61b0f89

Please sign in to comment.