Skip to content

Commit cd57d27

Browse files
committed
feat(site): frame place-haejo and contents-haejo solution icons
Resize logos to 256x256, frame place-haejo with white bg and shadow, fill contents-haejo background with logo blue (#1373f4). Introduce ICON_FRAMES map to centralize per-solution icon styling.
1 parent 4efaf33 commit cd57d27

3 files changed

Lines changed: 26 additions & 5 deletions

File tree

components/site/solution-card.tsx

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,33 @@ interface SolutionCardProps {
1010
solution: Solution;
1111
}
1212

13+
interface IconFrame {
14+
containerClass: string;
15+
imageClass: string;
16+
}
17+
18+
const ICON_FRAMES: Record<string, IconFrame> = {
19+
shopzy: {
20+
containerClass:
21+
"bg-white shadow-[0_2px_8px_rgba(15,23,42,0.08)] ring-1 ring-black/5",
22+
imageClass: "h-11 w-11",
23+
},
24+
"place-haejo": {
25+
containerClass:
26+
"bg-white shadow-[0_2px_8px_rgba(15,23,42,0.08)] ring-1 ring-black/5",
27+
imageClass: "h-12 w-12",
28+
},
29+
"contents-haejo": {
30+
containerClass:
31+
"bg-[#1373f4] shadow-[0_2px_8px_rgba(15,23,42,0.08)] ring-1 ring-black/5",
32+
imageClass: "h-12 w-12",
33+
},
34+
};
35+
1336
export function SolutionCard({ solution }: SolutionCardProps) {
1437
const initial = solution.name.charAt(0);
1538
const iconSrc = solution.iconSrc;
16-
const isShopzy = solution.id === "shopzy";
39+
const iconFrame = ICON_FRAMES[solution.id];
1740
const anchorRef = useRef<HTMLAnchorElement>(null);
1841

1942
const handleMouseMove = (event: MouseEvent<HTMLAnchorElement>) => {
@@ -55,9 +78,7 @@ export function SolutionCard({ solution }: SolutionCardProps) {
5578
aria-hidden
5679
className={cn(
5780
"relative grid h-14 w-14 place-items-center overflow-hidden rounded-full",
58-
isShopzy
59-
? "bg-white shadow-[0_2px_8px_rgba(15,23,42,0.08)] ring-1 ring-black/5"
60-
: "bg-[var(--color-bg-soft)]",
81+
iconFrame ? iconFrame.containerClass : "bg-[var(--color-bg-soft)]",
6182
)}
6283
>
6384
<Image
@@ -68,7 +89,7 @@ export function SolutionCard({ solution }: SolutionCardProps) {
6889
unoptimized
6990
className={cn(
7091
"object-cover",
71-
isShopzy ? "h-11 w-11" : "h-full w-full",
92+
iconFrame ? iconFrame.imageClass : "h-full w-full",
7293
)}
7394
/>
7495
</span>

public/icons/contents-haejo.png

-635 KB
Loading

public/icons/place-haejo.png

-28.6 KB
Loading

0 commit comments

Comments
 (0)