refactor: replace hardcoded SVGs with lucide-react icons in quest-table

This commit is contained in:
syntaxbullet
2026-01-16 15:27:15 +01:00
parent 5491551544
commit 4ecbffd617

View File

@@ -4,6 +4,7 @@ import { Badge } from "./ui/badge";
import { Skeleton } from "./ui/skeleton";
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "./ui/tooltip";
import { cn } from "../lib/utils";
import { FileText, RefreshCw } from "lucide-react";
interface QuestListItem {
id: number;
@@ -94,24 +95,7 @@ function EmptyQuestState() {
return (
<div className="flex flex-col items-center justify-center py-12 text-center animate-in fade-in duration-500">
<div className="rounded-full bg-muted/50 p-4 mb-4">
<svg
xmlns="http://www.w3.org/2000/svg"
width="32"
height="32"
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
strokeWidth="2"
strokeLinecap="round"
strokeLinejoin="round"
className="text-muted-foreground"
>
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z" />
<polyline points="14 2 14 8 20 8" />
<line x1="16" y1="13" x2="8" y2="13" />
<line x1="16" y1="17" x2="8" y2="17" />
<polyline points="10 9 9 9 8 9" />
</svg>
<FileText className="w-8 h-8 text-muted-foreground" />
</div>
<h3 className="text-lg font-semibold text-foreground">No quests available</h3>
<p className="text-muted-foreground mt-1 max-w-sm">
@@ -239,26 +223,10 @@ export function QuestTable({ quests, isInitialLoading, isRefreshing, onRefresh }
)}
title="Refresh quests"
>
<svg
xmlns="http://www.w3.org/2000/svg"
width="18"
height="18"
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
strokeWidth="2"
strokeLinecap="round"
strokeLinejoin="round"
className={cn(
"text-muted-foreground transition-transform",
<RefreshCw className={cn(
"w-[18px] h-[18px] text-muted-foreground transition-transform",
isRefreshing && "animate-spin"
)}
>
<path d="M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8" />
<path d="M3 3v5h5" />
<path d="M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16" />
<path d="M16 21h5v-5" />
</svg>
)} />
</button>
</div>
</div>