This commit is contained in:
hailin 2025-03-25 15:26:30 +08:00
parent 981e3d1eae
commit 88396f0057
1 changed files with 6 additions and 2 deletions

View File

@ -146,7 +146,12 @@ export function DetailPageHeader({ data }: { data: any }) {
onClick={() => handleClick("icon")}
disabled={loading}
>
{data?.icon || "Deploy"}
{typeof data?.icon === "string" &&
(data.icon.startsWith("http") || data.icon.startsWith("/")) ? (
<img src={data.icon} alt="icon" className="w-12 h-12 object-contain" />
) : (
data?.icon || "Deploy"
)}
</button>
{/* 右信息区域(带图标) */}
@ -181,7 +186,6 @@ export function DetailPageHeader({ data }: { data: any }) {
}
// export function Header() {
// const router = useRouter();