Container Query
컨테이너 조회
컨테이너 쿼리는 CSS가 컴포넌트를 자기 컨테이너에 맞추게 해줘요. 화면 크기만 보는 게 아니라 컨테이너의 크기나 스타일을 확인해요.
다른 예시
제품 카드는 넓은 곳에서는 모든 정보를 보여줘요. 하지만 좁은 사이드바에서는 짧은 요약만 보여줘요.
주요 부분
- 01Outer constraint
- 02Content and spacing model
- 03Computed size or reflow result
사용할 때
재사용 가능한 구성 요소가 크기가 다른 레이아웃 영역에 나타날 때 컨테이너 쿼리를 사용하십시오.
다음 경우에는 사용하지 마세요
콘텐츠가 이미 잘 배치될 수 있는 경우 많은 쿼리 규칙을 절대 추가하지 마세요.
코드에서 사용된 이름
@container 출시하기 전에
Check content order, shared design values, component consistency, contrast, zoom, and layout changes by screen size. Verify every theme, language, and state. If there is motion, offer an equal reduced-motion experience.
Outcome:Complete the task with 컨테이너 조회 (Container Query)。 User context:제품 카드는 넓은 곳에서는 모든 정보를 보여줘요. 하지만 좁은 사이드바에서는 짧은 요약만 보여줘요. Design concept to apply:컨테이너 조회 (Container Query)。 Why it fits:재사용 가능한 구성 요소가 크기가 다른 레이아웃 영역에 나타날 때 컨테이너 쿼리를 사용하십시오. Do not use it when:콘텐츠가 이미 잘 배치될 수 있는 경우 많은 쿼리 규칙을 절대 추가하지 마세요. Design requirements: Set the content order, shared design values, and reusable components. Define how the layout changes by screen size and state. Keep useful design choices separate from decoration. Inclusion and resilience: Check contrast, zoom, languages, themes, and reduced motion when needed. Do not use color or effects as the only way to show meaning. Acceptance criteria: The design stays clear on phones and desktops, at zoom, in every theme, and in all supported languages. Interactive states stay clear and consistent. Evidence and limits (evidence boundary):공식 문서라고 해도 초안, 출시 후보, 최종 버전일 수 있어요. 상태와 브라우저나 플랫폼 지원 여부를 꼭 확인하세요. Unknowns to confirm: Brand limits, amount of content, supported themes and languages, target devices, and design-system rules.
이 요청을 확인하세요
Review how 컨테이너 조회 (Container Query) is used now. Definition: 컨테이너 쿼리는 CSS가 컴포넌트를 자기 컨테이너에 맞추게 해줘요. 화면 크기만 보는 게 아니라 컨테이너의 크기나 스타일을 확인해요. Release checks: Check content order, shared design values, component consistency, contrast, zoom, and layout changes by screen size. Verify every theme, language, and state. If there is motion, offer an equal reduced-motion experience. Before changing code, list the evidence, gaps, severity, and the smallest safe fix.