Files
vexplor/frontend/components/common/ValidationMessage.tsx
DDD1542 4f10b5e42d refactor: 전체 프론트엔드 하드코딩 색상 → CSS 변수 일괄 치환
447+ 파일, 4500+ 줄 변경:
- gray-* → border/bg-muted/text-foreground/text-muted-foreground
- blue-* → primary/ring
- red-* → destructive
- green-* → emerald (일관성)
- indigo-* → primary
- yellow/orange → amber (통일)
- dark mode 변형도 시맨틱 토큰으로 변환

Made-with: Cursor
2026-03-09 14:31:59 +09:00

24 lines
591 B
TypeScript

import React from "react";
import { cn } from "@/lib/utils";
interface ValidationMessageProps {
message?: string;
isValid?: boolean;
isLoading?: boolean;
className?: string;
}
export function ValidationMessage({ message, isValid, isLoading, className }: ValidationMessageProps) {
if (isLoading) {
return <p className={cn("text-sm text-muted-foreground", className)}> ...</p>;
}
if (!message) {
return null;
}
return (
<p className={cn("text-sm transition-colors", isValid ? "text-emerald-600" : "text-destructive", className)}>{message}</p>
);
}