feat: update figma category card icons
This commit is contained in:
@@ -4,6 +4,7 @@ import type { Resource } from "../api";
|
||||
import { assetUrl } from "../api";
|
||||
import { useI18n } from "../i18n";
|
||||
import { useMemo, useState } from "react";
|
||||
import { cleanCategoryDisplayName } from "../utils/categoryDisplay";
|
||||
import { formatDateYmd } from "../utils/format";
|
||||
import { officialRecommendationCoverFallbacks } from "./FigmaBanner";
|
||||
import {
|
||||
@@ -46,12 +47,10 @@ export function RecommendedCard({
|
||||
}
|
||||
return assetUrl(original);
|
||||
}, [figmaCover, r.coverImage, r.previewUrl, useFigmaDesign]);
|
||||
const displayTitle = useFigmaDesign
|
||||
? "ARK 2026「共识加速计划」 🚀 邀请王霸榜 · 重磅回归"
|
||||
: r.title;
|
||||
const displayCategoryName = useFigmaDesign ? "项目资料" : r.categoryName;
|
||||
const dateStr = useFigmaDesign ? "2026-04-10" : formatDateYmd(r.updatedAt);
|
||||
const dateTime = useFigmaDesign ? "2026-04-10" : r.updatedAt;
|
||||
const displayTitle = r.title;
|
||||
const displayCategoryName = cleanCategoryDisplayName(r.categoryName);
|
||||
const dateStr = formatDateYmd(r.updatedAt);
|
||||
const dateTime = r.updatedAt;
|
||||
|
||||
const dl =
|
||||
r.isDownloadable && (r.fileUrl || r.previewUrl)
|
||||
@@ -68,7 +67,11 @@ export function RecommendedCard({
|
||||
<img
|
||||
src={cover}
|
||||
alt=""
|
||||
className="h-full w-full object-cover transition duration-300 group-hover:scale-[1.02]"
|
||||
className={`h-full w-full object-cover transition duration-300 ${
|
||||
useFigmaDesign
|
||||
? "origin-top scale-[1.08] group-hover:scale-[1.1]"
|
||||
: "group-hover:scale-[1.02]"
|
||||
}`}
|
||||
loading="lazy"
|
||||
/>
|
||||
) : (
|
||||
|
||||
Reference in New Issue
Block a user