Merge pull request '모프로의원 허브 영문 홈에 원장 인터뷰 섹션 추가' (#5) from feat/mopro-en-interview into main

This commit was merged in pull request #5.
This commit is contained in:
haewonkam committed 2026-10-19 07:06:26 +00:00
commit 998d609fd8
2 files changed
+69 -15

No files matched your search

+19 -5
View File
@@ -63,7 +63,9 @@
"id": "lzx2z4cWJt0",
"title": "[라스트닥터 3주년 인터뷰] 매출보다 직원행복 챙겼더니 일어난 3가지 변화",
"published": "2026-10-10",
"channel": "유튜브 @the_lastdoctor"
"channel": "유튜브 @the_lastdoctor",
"titleEn": "Third-anniversary interview: what changed after putting staff before revenue (in Korean)",
"channelEn": "YouTube @the_lastdoctor"
},
"links": [
{
@@ -71,25 +73,37 @@
"title": "모발설계자 문건학 원장 밀착인터뷰 _ 보이는 것 너머, 시간을 설계하다",
"desc": "문건학 원장 인터뷰 원문을 블로그에서 읽을 수 있습니다.",
"url": "https://blog.naver.com/all_artist/224436053883",
"foot": "2026-10-09 게시 · blog.naver.com/all_artist"
"foot": "2026-10-09 게시 · blog.naver.com/all_artist",
"catEn": "Interview · Naver Blog",
"titleEn": "In-depth interview with Dr. Kunhak Moon (in Korean)",
"descEn": "Read the full interview with Dr. Kunhak Moon on the original blog.",
"footEn": "Published 2026-10-09 · blog.naver.com/all_artist"
},
{
"cat": "공식 블로그",
"title": "모프로의원 네이버 블로그",
"desc": "모발이식·탈모 치료 정보를 모프로의원이 직접 올리는 블로그입니다.",
"url": "https://blog.naver.com/moprohair",
"foot": "blog.naver.com/moprohair"
"foot": "blog.naver.com/moprohair",
"catEn": "Official Blog",
"titleEn": "MOPRO Clinic Naver Blog (in Korean)",
"descEn": "Hair transplant and hair loss treatment information posted by the clinic.",
"footEn": "blog.naver.com/moprohair"
},
{
"cat": "인스타그램",
"title": "모프로의원 인스타그램",
"desc": "모프로의원 공식 인스타그램 계정입니다.",
"url": "https://www.instagram.com/moproclinic/",
"foot": "@moproclinic"
"foot": "@moproclinic",
"catEn": "Instagram",
"titleEn": "MOPRO Clinic Instagram",
"descEn": "The clinic's official Instagram account.",
"footEn": "@moproclinic"
}
]
},
"_interviewNote": "2026-10-19 haewon 지시로 홈 'Interview' 섹션에 싣는다. 영상은 외부 채널(@the_lastdoctor) 인터뷰라 캡션에 그 채널을 밝힌다. 밀착인터뷰는 외부 에이전시 블로그(all_artist) 글이라 제목·링크만 싣고 본문은 옮기지 않는다(haewon 결정 2026-10-19). 게시일은 유튜브 uploadDate(2026-10-09 PDT)·블로그 게시 표기 실측. patch_site.py 가 src/data/interview.json 으로 쓴다.",
"_interviewNote": "2026-10-19 haewon 지시로 홈 'Interview' 섹션에 싣는다. 영상은 외부 채널(@the_lastdoctor) 인터뷰라 캡션에 그 채널을 밝힌다. 밀착인터뷰는 외부 에이전시 블로그(all_artist) 글이라 제목·링크만 싣고 본문은 옮기지 않는다(haewon 결정 2026-10-19). 게시일은 유튜브 uploadDate(2026-10-09 PDT)·블로그 게시 표기 실측. patch_site.py 가 src/data/interview.json 으로 쓴다. 2026-10-19 영문 홈에도 싣는다(haewon 지시). *En 값은 Claude 번역 초안이며, 한국어 콘텐츠는 제목에 '(in Korean)'을 붙인다.",
"footerChannels": [
{
"label": "유튜브",
+50 -10
View File
@@ -12,7 +12,7 @@
2. 회복 일정 캘린더 파일 정보(PRODID·UID)에 남은 다른 병원 이름을 INFINITH·모프로로 바꾼다
3. clinic.json excludeImages 에 해당하는 파일을 public/img 전체에서 지운다(워커는 img/clinic 만 지운다)
3b. 영문 화면의 한글 노출을 정리한다(영문 사이트 이름·대표자·빈 값 문구, 팩트 시트 영문 값, 사진 없는 장소 이름 칸)
3c. 홈에 'Interview' 섹션(원장 인터뷰 영상·인터뷰 글·공식 블로그·인스타그램)을 넣는다(clinic.json interview)
3c. 한국어·영문 홈에 'Interview' 섹션(원장 인터뷰 영상·인터뷰 글·공식 블로그·인스타그램)을 넣는다(clinic.json interview)
3d. 푸터에 채널 아이콘 줄(유튜브·인스타그램·블로그·카카오톡·플레이스·강남언니·바비톡)을 넣는다(clinic.json footerChannels)
4. vercel.json 사이트 주소를 정식 주소로 넣고, 공유 이미지(og.jpg)를 '서포터즈' 없는 상단 문구로 다시 그린다
5. src 에 화면용 '서포터즈'가 남아 있으면 실패로 끝낸다
@@ -165,7 +165,36 @@ VIDEOLITE_REPLACEMENTS = [
("const { id, title, speaker, published, note, compact = false } = Astro.props;",
"const { id, title, speaker, published, note, compact = false, channel } = Astro.props;"),
("{handle}{note ?", "{channel ?? handle}{note ?"),
# 영문 홈에서 쓸 수 있게 lang='en' 이면 재생 버튼 설명·썸네일 대체 문구·게시일 표기를 영어로 낸다
("channel?: string }", "channel?: string; lang?: string }"),
("compact = false, channel }", "compact = false, channel, lang }"),
("aria-label={`영상 재생: ${title}`}", "aria-label={lang === 'en' ? `Play video: ${title}` : `영상 재생: ${title}`}"),
("alt={`유튜브 영상 썸네일: ${title}`}", "alt={lang === 'en' ? `YouTube video thumbnail: ${title}` : `유튜브 영상 썸네일: ${title}`}"),
("{published ? `${published} 게시 · ` : ''}", "{published ? (lang === 'en' ? `Published ${published} · ` : `${published} 게시 · `) : ''}"),
]
# 영문 홈 Interview 섹션: Clinic Facts 아래, Principles 위. 값은 clinic.json interview 의 *En
INTERVIEW_EN_ANCHOR = " <section class=\"section dark\"><div class=\"wrap-wide\">\n <div class=\"sec-head\"><div class=\"eyebrow\" style=\"color:var(--purple-300)\">Principles</div>"
INTERVIEW_EN_SECTION = """ <section class="section light"><div class="wrap-wide">
<div class="sec-head"><div class="eyebrow">Interview</div><h2>Meet The Doctor</h2><p class="sub">Interviews with Dr. Kunhak Moon and the clinic's official channels.</p></div>
<div class="interview-grid">
{interview.video && <div class="interview-video"><VideoLite id={interview.video.id} title={interview.video.titleEn} published={interview.video.published} channel={interview.video.channelEn} lang="en" /></div>}
{interview.links.map((l) => (
<article class="card">
<div class="cat">{l.catEn}</div>
<h3><a href={l.url} rel="noopener" target="_blank">{l.titleEn}</a></h3>
<p>{l.descEn}</p>
<div class="foot">{l.footEn}</div>
</article>
))}
</div>
<style>
.interview-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 1.25rem; }
.interview-video { grid-row: span 3; align-self: start; }
.interview-video :global(figure) { margin: 0; }
@media (max-width: 860px) { .interview-grid { grid-template-columns: 1fr; } .interview-video { grid-row: auto; } }
</style>
</div></section>
"""
def patch_home_interview():
@@ -178,17 +207,28 @@ def patch_home_interview():
for old, new in VIDEOLITE_REPLACEMENTS:
text = text.replace(old, new)
open(vp, "w", encoding="utf-8").write(text)
changed = 0
ip = os.path.join(SITE, "src/pages/index.astro")
text = open(ip, encoding="utf-8").read()
if "data/interview.json" in text:
return 0
if INTERVIEW_ANCHOR not in text:
sys.exit("index.astro 에서 Inside 섹션을 찾지 못해 Interview 섹션을 넣지 못함")
text = text.replace("import Gallery from '../components/Gallery.astro';",
"import Gallery from '../components/Gallery.astro';\nimport interview from '../data/interview.json';", 1)
text = text.replace(INTERVIEW_ANCHOR, INTERVIEW_SECTION + INTERVIEW_ANCHOR, 1)
open(ip, "w", encoding="utf-8").write(text)
return 1
if "data/interview.json" not in text:
if INTERVIEW_ANCHOR not in text:
sys.exit("index.astro 에서 Inside 섹션을 찾지 못해 Interview 섹션을 넣지 못함")
text = text.replace("import Gallery from '../components/Gallery.astro';",
"import Gallery from '../components/Gallery.astro';\nimport interview from '../data/interview.json';", 1)
text = text.replace(INTERVIEW_ANCHOR, INTERVIEW_SECTION + INTERVIEW_ANCHOR, 1)
open(ip, "w", encoding="utf-8").write(text)
changed += 1
ep = os.path.join(SITE, "src/pages/en/index.astro")
text = open(ep, encoding="utf-8").read()
if "data/interview.json" not in text:
if INTERVIEW_EN_ANCHOR not in text:
sys.exit("en/index.astro 에서 Principles 섹션을 찾지 못해 Interview 섹션을 넣지 못함")
text = text.replace("import VisitMap from '../../components/VisitMap.astro';",
"import VisitMap from '../../components/VisitMap.astro';\nimport VideoLite from '../../components/VideoLite.astro';\nimport interview from '../../data/interview.json';", 1)
text = text.replace(INTERVIEW_EN_ANCHOR, INTERVIEW_EN_SECTION + INTERVIEW_EN_ANCHOR, 1)
open(ep, "w", encoding="utf-8").write(text)
changed += 1
return changed
# 푸터 채널 아이콘 (haewon 지시 2026-10-19). 유튜브·강남언니 글자 링크는 아이콘 줄로 옮기고 홈페이지 링크만 남긴다