Skip to content

Commit ae5d2cc

Browse files
committed
refactor: DropDown 컴포넌트 Tailwind 유틸리티 클래스로 변환
1 parent 7f7031f commit ae5d2cc

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

src/shared/ui/DropDown/DropDown.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ export const DropDown = ({
2525
onToggle,
2626
onSelect,
2727
}: DropDownProps) => (
28-
<div className="relative flex flex-col gap-[var(--spacing-m)]" ref={dropdownRef}>
29-
<span className="typo-body-2 text-[var(--color-gray-900)]">{label}</span>
28+
<div className="gap-m relative flex flex-col" ref={dropdownRef}>
29+
<span className="typo-body-2 text-gray-900">{label}</span>
3030

3131
<div
3232
className="relative"
@@ -43,22 +43,22 @@ export const DropDown = ({
4343
readOnly
4444
value={value}
4545
placeholder={`${label}를 선택해 주세요`}
46-
className="w-full cursor-pointer [&_input]:h-[48px] [&_input]:pr-[40px] [&_input]:text-[16px] [&_input]:leading-[24px] [&_input]:text-[var(--color-gray-700)] [&_input]:placeholder:text-[var(--color-gray-400)]"
46+
className="[&_input]:pr-xxxl [&_input]:text-m [&_input]:leading-m w-full cursor-pointer [&_input]:h-[48px] [&_input]:text-gray-700 [&_input]:placeholder:text-gray-400"
4747
showCharacterCount={false}
4848
error={error}
4949
helperText={helperText}
5050
/>
51-
<CaretDownMdIcon className="pointer-events-none absolute top-1/2 right-[16px] h-5 w-5 -translate-y-1/2 text-[var(--color-gray-400)]" />
51+
<CaretDownMdIcon className="right-m pointer-events-none absolute top-1/2 h-5 w-5 -translate-y-1/2 text-gray-400" />
5252
</div>
5353

5454
{isOpen && (
55-
<div className="absolute top-full z-10 mt-[8px] flex w-full flex-col overflow-hidden rounded-[12px] border border-[var(--color-gray-200)] bg-white shadow-[0_8px_24px_rgba(0,0,0,0.08)]">
55+
<div className="mt-xxxs absolute top-full z-10 flex w-full flex-col overflow-hidden rounded-[12px] border border-gray-200 bg-white shadow-[0_8px_24px_rgba(0,0,0,0.08)]">
5656
{options.map((item) => (
5757
<button
5858
key={item}
5959
type="button"
6060
onClick={() => onSelect(item)}
61-
className="typo-body-1 flex h-[44px] items-center px-[16px] text-left text-[var(--color-gray-700)] hover:bg-[var(--color-gray-50)]"
61+
className="typo-body-1 px-m flex h-[44px] items-center text-left text-gray-700 hover:bg-gray-50"
6262
>
6363
{item}
6464
</button>

0 commit comments

Comments
 (0)