[fix] solution/site: 사진 카드를 PhotoCard 하나로 통일 — 템플릿마다 제각각이던 축제·명소 카드
같은 템플릿 안에서도 축제 카드(흰 바탕·글 안쪽)와 명소 카드(바탕 없음·글 아래)가 따로 놀았다. 실측(9종 전수): 제목 굵기 400/500/700/900, 사진 모서리 0/12/18/22px 가 한 화면에 섞여 있었다. - kit/Card.tsx·card.css: 사진 3:2 + 제목 1줄 + 거리 1줄 + 설명 2줄. 템플릿 차이는 --kc-* 변수만 - 9종 Around·Festival, 고택 인물: 사진 카드를 PhotoCard 로 교체. 맛집·홈 목록 행은 그대로 - 템플릿 CSS: 모서리·글꼴·강조색 변수와 그리드 간격. 일러스트는 상자형, 빅타이포는 선 격자 - 모바일 캐러셀 화살표가 카드를 가려 1024px 미만에서 숨김 - docs/TEMPLATE_DESIGN.md: 사진 카드 규칙 tsc·eslint 통과 · vitest 123 passed · 12개 사이트 굽기 · 카드 모양 템플릿당 1종 확인 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
089886fe1e
commit
4831e2d25d
27 files changed
+282
-178
No files matched your search
@@ -2,6 +2,7 @@ import {useState} from 'react';
|
||||
import type {LocalPlace} from '@o2o/shared';
|
||||
import {useSite} from '@site/lib/site-context';
|
||||
import {naverMapSearchUrl} from '@site/lib/format';
|
||||
import {PhotoCard} from '../kit/Card';
|
||||
import {Sheet} from '../paper/Sheet';
|
||||
import {useWide} from './useWide';
|
||||
|
||||
@@ -66,18 +67,14 @@ export function Around() {
|
||||
);
|
||||
|
||||
const card = (place: LocalPlace) => (
|
||||
<button key={place.name} type="button" className="place" onClick={() => setOpen(place)}>
|
||||
{place.imageUrl && (
|
||||
<div className="ph">
|
||||
<img src={place.imageUrl} alt={place.name} loading="lazy" />
|
||||
</div>
|
||||
)}
|
||||
<div className="bd">
|
||||
<h3>{place.name}</h3>
|
||||
{place.distanceText && <small>{place.distanceText}</small>}
|
||||
{place.description && <p className="clamp">{place.description}</p>}
|
||||
</div>
|
||||
</button>
|
||||
<PhotoCard
|
||||
key={place.name}
|
||||
image={place.imageUrl}
|
||||
title={place.name}
|
||||
meta={place.distanceText}
|
||||
desc={place.description}
|
||||
onClick={() => setOpen(place)}
|
||||
/>
|
||||
);
|
||||
|
||||
return (
|
||||
@@ -94,15 +91,13 @@ export function Around() {
|
||||
</div>
|
||||
<div className="guide guide--3">
|
||||
{rail.slice(0, railMax).map((place) => (
|
||||
<button key={place.name} type="button" className="place" onClick={() => setOpen(place)}>
|
||||
<div className="ph">
|
||||
<img src={place.imageUrl} alt={place.name} loading="lazy" />
|
||||
</div>
|
||||
<div className="bd">
|
||||
<h3>{place.name}</h3>
|
||||
{place.distanceText && <small>{place.distanceText}</small>}
|
||||
</div>
|
||||
</button>
|
||||
<PhotoCard
|
||||
key={place.name}
|
||||
image={place.imageUrl}
|
||||
title={place.name}
|
||||
meta={place.distanceText}
|
||||
onClick={() => setOpen(place)}
|
||||
/>
|
||||
))}
|
||||
</div>
|
||||
<a href="#/area" className="more">
|
||||
|
||||
Reference in new issue
Block a user