Skip to content

Commit

Permalink
Update FileValidation.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
KyngKai909 authored Apr 10, 2024
1 parent 4031423 commit d1830a0
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions packages/nextjs/components/FileValidation.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,14 @@ const FileValidation = ({
const stateBadge = useMemo(() => {
switch (state) {
case "Completed":
return "success";
return "bg-green-500 text-white";
case "Needs Review":
return "error";
return "bg-red-500 text-white";
case "Processing":
return "warning";
return "bg-yellow-500 text-black";
case "Not started":
default:
return "neutral";
return "bg-base-300 text-zinc-400";
}
}, [state]);

Expand Down Expand Up @@ -148,13 +148,7 @@ const FileValidation = ({
</select>
) : (
<div
className={`badge badge-${stateBadge} text-${
stateBadge === "neutral"
? "secondary"
: stateBadge === "warning"
? "black"
: stateBadge
} h-6 rounded-lg text-[10px] font-normal capitalize`}
className={`badge badge-${stateBadge} pointer-events-auto rounded-lg h-6 px-2 text-[10px] font-normal capitalize`}
onDoubleClick={() => setIsBadgeEdit(x => !x)}
>
{state ?? "Not started"}
Expand Down

0 comments on commit d1830a0

Please sign in to comment.