LiftDesign System
Beta
English 시작하기
  1. Components
  2. Product
  3. Banner

Components / Product

Banner — 구현

페이지 수준 안내·경고

Context
Product
콘텐츠
원본 발췌
사용 가능성
implemented
검증
static-only 2026-11-18
기준 revision
Lift 1.2.3 21b492d68648…
원문 언어
KO
banner.md ↗

지원 환경

Lift 1.2.3 의 참조 구현은 React 18 함수 컴포넌트다. 스타일은 인라인이고 색은 Product 토큰(hsl(var(--*)))을 참조하므로 styles.product.css 가 로드돼 있어야 한다. npm 패키지와의 대응은 이 저장소에서 확인하지 못했다.

API

components/_types.d.ts 의 BannerProps 를 그대로 옮겼다.

proptypedefaultdoc
tone"success" | "warning" | "info" | "error"info
titleReact.ReactNode—
childrenReact.ReactNode—
rolestring—기본값: error는 "alert", 나머지는 "status". 정적 안내면 role="note"로 낮춘다.
styleReact.CSSProperties—

코드

가져오기 한 줄과 사용 지침 원문의 예시 코드다.

jsx · import
import { Banner } from "./components/display/Banner.jsx";
jsx · Banner.prompt.md
<Banner tone="info" title="분당 60건 제한">Free 플랜은 분당 60건까지 보냅니다.</Banner>
<Banner tone="error" title="색인 서버에 연결하지 못했습니다">자동으로 재시도 중입니다 (3/5).</Banner>
<Banner tone="warning" title="크레딧 82% 사용">이번 달 한도까지 18GB 남았습니다.</Banner>

토큰 연결

구현 파일이 var() 로 직접 참조하는 토큰. 조건에 따라 이름을 조립하는 토큰(예: --state-${tone}-fg)은 빠진다.

--font-sans, --state-

출처