Files
o2o-weather/frontend/src/lib/utils.ts
T
minaChoiandClaude Opus 5.5 f8b47f064a feat: 시안 B 화면을 기본 화면으로, Hey API로 백엔드 연결
- 예전 화면(/, /a)과 목업 데이터를 지우고 시안 B 를 / 로
- @hey-api/openapi-ts 로 타입·TanStack Query 함수 생성, 토큰·401 갱신 처리
- 공유는 기본 공유창, 없으면 링크 복사

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 11:32:22 +09:00

10 lines
307 B
TypeScript

export function cx(...parts: (string | false | null | undefined)[]) {
return parts.filter(Boolean).join(' ')
}
const RANK_COLOR = { 1: 'text-gold', 2: 'text-silver', 3: 'text-bronze' } as const
export function rankText(rank: number) {
return rank <= 3 ? RANK_COLOR[rank as 1 | 2 | 3] : 'text-ink-2'
}