Skip to content

Commit

Permalink
[#13] css 사이즈 및 애니메이션 조정
Browse files Browse the repository at this point in the history
  • Loading branch information
chaduhwan committed May 12, 2024
1 parent ddae438 commit 56d38d0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/components/common/toggle/ToggleRoot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import { theme } from '@/styles/theme'
import styled from 'styled-components'

const StyledRoot = styled(Switch.Root)`
width: 42px;
height: 25px;
width: 58px;
height: 31px;
background-color: ${theme.color.grey200};
border-radius: 9999px;
position: relative;
Expand Down
7 changes: 3 additions & 4 deletions src/components/common/toggle/ToggleThumb.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,16 @@ import styled from 'styled-components'

const StyledThumb = styled(Switch.SwitchThumb)`
display: block;
width: 21px;
height: 21px;
width: 25px;
height: 25px;
background-color: ${theme.color.white};
border-radius: 9999px;
box-shadow: 0 2px 2px var(--black-a7);
transition: transform 300ms;
transform: translateX(2px);
will-change: transform;
&[data-state='checked'] {
transform: translateX(19px);
transform: translateX(30px);
}
`

Expand Down

0 comments on commit 56d38d0

Please sign in to comment.