fix(design-system): 컴포넌트 토큰을 복사하지 않고 읽게 한다 (UI-03)
계약에 있는 컴포넌트 토큰 4개를 읽는 스타일이 없었다. 기본 버튼은 bg-action을 직접 썼고, 현재 메뉴는 --navigation-active-background의 계산식을 다시 적었다. 그래서 서비스가 이 토큰으로 브랜드를 바꿔도 화면이 바뀌지 않았다. 기본 버튼과 현재 메뉴가 토큰을 읽게 했다. 변형 버튼은 뒤에 오는 같은 우선순위 규칙이라 그대로 덮어쓴다. check:design-system이 계약의 컴포넌트 토큰을 읽는 스타일이 하나도 없으면 실패한다. 위험: 기본 버튼 배경 지정 방식이 utility에서 토큰으로 바뀐다. 보이는 색은 같다. 검증: 바꾸기 전 검사가 토큰 4개를 보고했고, 바꾼 뒤 통과했다.
This commit is contained in:
@@ -12,19 +12,20 @@
|
||||
}
|
||||
|
||||
.ui-button {
|
||||
@apply rounded-control bg-action px-4 py-2 font-semibold;
|
||||
@apply rounded-control px-4 py-2 font-semibold;
|
||||
display: inline-flex;
|
||||
min-height: 2.75rem;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border: 0;
|
||||
color: var(--color-on-action);
|
||||
background: var(--button-primary-background);
|
||||
color: var(--button-primary-content);
|
||||
text-decoration: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.ui-button:hover {
|
||||
@apply bg-action-hover;
|
||||
background: var(--button-primary-hover);
|
||||
}
|
||||
|
||||
.ui-button:disabled {
|
||||
|
||||
Reference in New Issue
Block a user