Skip to content

feat(input): Enlarge the size scale and drop the control shadow (v1.8.2) - #53

Open
woody-uiux wants to merge 2 commits into
mainfrom
feat/input-sizing
Open

woody-uiux wants to merge 2 commits into
mainfrom
feat/input-sizing

Conversation

@woody-uiux

@woody-uiux woody-uiux commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

바뀐 것

Input의 padding-x를 두 단계, border-radius를 한 단계 키웠습니다. Textarea도 같은 padding-xborder-radius를 따라갑니다. Textarea의 min-height는 그대로입니다.

height는 리뷰 의견대로 전부 원래대로 두었습니다. h-9 기준에 맞춰 만들어진 컴포넌트들이 함께 정리된 뒤에 다시 보겠습니다.

size height padding-x border-radius font-size
xs 24 8 → 12 8 → 10 12
sm 32 10 → 14 8 → 10 14
default 36 10 → 14 8 → 10 14
lg 40 10 → 14 8 → 10 14
xl 44 12 → 16 10 → 14 16
2xl 52 16 → 20 14 → 18 18

함께 정리한 것:

  • Input, Textarea, InputGroup, NativeSelect, Select, Checkbox에서 shadow-xs를 걷어냈습니다. 테두리만으로 입력칸이 충분히 읽히고, 그림자는 컨트롤을 바닥에서 떠 보이게 했습니다.
  • Input과 Textarea의 xs, sm에 있던 rounded-[min(var(--radius-md),8px)]과 10px 짝을 지웠습니다. 둘 다 기본 모서리 값으로 계산돼서 아무 일도 하지 않던 식입니다.
  • Input과 Textarea에 data-size를 붙였습니다. 변형 목록을 다시 적지 않고도 특정 크기만 겨냥할 수 있습니다.

남아 있는 문제

input-input-group 예시에서 보이는 테두리 상자는 Input이 아니라 InputGroup입니다. height, border-radius, padding을 바깥 상자가 갖고 안쪽 Input은 테두리 없이 들어가는데, 그 값이 Input의 것을 손으로 베낀 사본입니다 — h-9 / h-8 / h-6 / h-10 / h-11 / h-13, rounded-md / rounded-lg / rounded-xl. NativeSelect, Select, Button도 같은 값을 각자 베껴 쓰고 있습니다. 이번에 height를 원복한 이유이기도 합니다 — 한 곳만 올리면 나머지가 그대로 남습니다.

폼 컨트롤의 size scale이 한 곳에 정의되지 않고 다섯 컴포넌트에 흩어져 있는 게 원인입니다. InputGroup이 어긋난 것, 죽은 min() 식이 오래 살아남은 것, sm·default·lgheight 말고는 완전히 같아진 것이 전부 여기서 나옵니다.

여섯 단계의 height, padding-x, border-radius, font-size를 기존 토큰처럼 globals.css에 한 번만 정의하고 여섯 컴포넌트가 그것을 참조하는 방향이면 좋겠습니다. 색과 --radius는 이미 그렇게 되어 있으니 새 방식을 들이는 것은 아닙니다.

그때 sm, default, lg도 함께 봐주세요. height만 4px씩 다르고 padding-x, border-radius, font-size가 전부 같아서, 세 단계가 각자 자리를 차지할 만한지 의문입니다.

확인

bun test 130개 통과 · bun run build 정상, 정적 내보내기 검증 완료 · 변경 후 모든 size를 브라우저에서 직접 측정

Move every Input size up one step in height and rounding and two steps in
horizontal padding: the default control is now 40px tall with 14px of inner
padding and a 10px radius, matching the desktop text field in Karrot's Seed.
Textarea follows the same padding and rounding so a form mixing the two keeps
one edge. Its minimum heights are unchanged.

Drop shadow-xs from Input, Textarea, InputGroup, NativeSelect, Select and
Checkbox. The border alone carries a field, and the shadow made every control
float above the surface behind it.

Remove rounded-[min(var(--radius-md),8px)] and its 10px twin from the xs and sm
sizes. Both collapse to the base radius, so the expression never did anything.

Add data-size to Input and Textarea so a size can be targeted without repeating
the variant list.

Claude-Session: https://claude.ai/code/session_01ADsw5yhJV1xGhRkUpfAY83
@woody-uiux
woody-uiux requested a review from initred as a code owner September 4, 2026 08:37
Keep every Input height as it was -- 24 / 32 / 36 / 40 / 44 / 52px -- so the
components built around the h-9 default stay aligned. Only padding-x and
border-radius change in this PR; heights come back with the size scale work.

Claude-Session: https://claude.ai/code/session_01ADsw5yhJV1xGhRkUpfAY83
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant