feat: 모프로의원 허브 홈에 원장 인터뷰 섹션과 푸터 채널 아이콘을 추가한다

- 홈 'Doctors Explain' 아래 Interview 섹션: 라스트닥터 인터뷰 영상(외부 채널 출처 표시), 밀착인터뷰 글(제목·링크만), 공식 블로그 moprohair, 인스타그램 카드
- VideoLite 캡션에 channel 을 받아 외부 채널 영상의 출처를 병원 핸들 대신 표시한다
- 푸터에 유튜브·인스타그램·네이버 블로그·카카오톡 채널·네이버 플레이스·강남언니·바비톡 아이콘 링크를 넣고, 겹치던 유튜브·강남언니 글자 링크를 뺀다
- 값은 clinic.json(interview, footerChannels), 적용은 patch_site.py 가 빌드마다 다시 한다

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Haewon KamandClaude Opus 5.5 committed 2026-10-19 15:49:08 +09:00
1 parent 5ff4633926
commit b7f97ecfa6
9 files changed
+192 -2

No files matched your search

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

@@ -0,0 +1 @@
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path fill="#E4405F" d="M7.0301.084c-1.2768.0602-2.1487.264-2.911.5634-.7888.3075-1.4575.72-2.1228 1.3877-.6652.6677-1.075 1.3368-1.3802 2.127-.2954.7638-.4956 1.6365-.552 2.914-.0564 1.2775-.0689 1.6882-.0626 4.947.0062 3.2586.0206 3.6671.0825 4.9473.061 1.2765.264 2.1482.5635 2.9107.308.7889.72 1.4573 1.388 2.1228.6679.6655 1.3365 1.0743 2.1285 1.38.7632.295 1.6361.4961 2.9134.552 1.2773.056 1.6884.069 4.9462.0627 3.2578-.0062 3.668-.0207 4.9478-.0814 1.28-.0607 2.147-.2652 2.9098-.5633.7889-.3086 1.4578-.72 2.1228-1.3881.665-.6682 1.0745-1.3378 1.3795-2.1284.2957-.7632.4966-1.636.552-2.9124.056-1.2809.0692-1.6898.063-4.948-.0063-3.2583-.021-3.6668-.0817-4.9465-.0607-1.2797-.264-2.1487-.5633-2.9117-.3084-.7889-.72-1.4568-1.3876-2.1228C21.2982 1.33 20.628.9208 19.8378.6165 19.074.321 18.2017.1197 16.9244.0645 15.6471.0093 15.236-.005 11.977.0014 8.718.0076 8.31.0215 7.0301.0839m.1402 21.6932c-1.17-.0509-1.8053-.2453-2.2287-.408-.5606-.216-.96-.4771-1.3819-.895-.422-.4178-.6811-.8186-.9-1.378-.1644-.4234-.3624-1.058-.4171-2.228-.0595-1.2645-.072-1.6442-.079-4.848-.007-3.2037.0053-3.583.0607-4.848.05-1.169.2456-1.805.408-2.2282.216-.5613.4762-.96.895-1.3816.4188-.4217.8184-.6814 1.3783-.9003.423-.1651 1.0575-.3614 2.227-.4171 1.2655-.06 1.6447-.072 4.848-.079 3.2033-.007 3.5835.005 4.8495.0608 1.169.0508 1.8053.2445 2.228.408.5608.216.96.4754 1.3816.895.4217.4194.6816.8176.9005 1.3787.1653.4217.3617 1.056.4169 2.2263.0602 1.2655.0739 1.645.0796 4.848.0058 3.203-.0055 3.5834-.061 4.848-.051 1.17-.245 1.8055-.408 2.2294-.216.5604-.4763.96-.8954 1.3814-.419.4215-.8181.6811-1.3783.9-.4224.1649-1.0577.3617-2.2262.4174-1.2656.0595-1.6448.072-4.8493.079-3.2045.007-3.5825-.006-4.848-.0608M16.953 5.5864A1.44 1.44 0 1 0 18.39 4.144a1.44 1.44 0 0 0-1.437 1.4424M5.8385 12.012c.0067 3.4032 2.7706 6.1557 6.173 6.1493 3.4026-.0065 6.157-2.7701 6.1506-6.1733-.0065-3.4032-2.771-6.1565-6.174-6.1498-3.403.0067-6.156 2.771-6.1496 6.1738M8 12.0077a4 4 0 1 1 4.008 3.9921A3.9996 3.9996 0 0 1 8 12.0077"/></svg>

After

Width:  |  Height:  |  Size: 2.0 KiB

@@ -0,0 +1 @@
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path fill="#3C1E1E" d="M22.125 0H1.875C.8394 0 0 .8394 0 1.875v20.25C0 23.1606.8394 24 1.875 24h20.25C23.1606 24 24 23.1606 24 22.125V1.875C24 .8394 23.1606 0 22.125 0zM12 18.75c-.591 0-1.1697-.0413-1.7317-.1209-.5626.3965-3.813 2.6797-4.1198 2.7225 0 0-.1258.0489-.2328-.0141s-.0876-.2282-.0876-.2282c.0322-.2198.8426-3.0183.992-3.5333-2.7452-1.36-4.5701-3.7686-4.5701-6.5135C2.25 6.8168 6.6152 3.375 12 3.375s9.75 3.4418 9.75 7.6875c0 4.2457-4.3652 7.6875-9.75 7.6875zM8.0496 9.8672h-.8777v3.3417c0 .2963-.2523.5372-.5625.5372s-.5625-.2409-.5625-.5372V9.8672h-.8777c-.3044 0-.552-.2471-.552-.5508s.2477-.5508.552-.5508h2.8804c.3044 0 .552.2471.552.5508s-.2477.5508-.552.5508zm10.9879 2.9566a.558.558 0 0 1 .108.4167.5588.5588 0 0 1-.2183.371.5572.5572 0 0 1-.3383.1135.558.558 0 0 1-.4493-.2236l-1.3192-1.7479-.1952.1952v1.2273a.5635.5635 0 0 1-.5627.5628.563.563 0 0 1-.5625-.5625V9.3281c0-.3102.2523-.5625.5625-.5625s.5625.2523.5625.5625v1.209l1.5694-1.5694c.0807-.0807.1916-.1252.312-.1252.1404 0 .2814.0606.3871.1661.0985.0984.1573.2251.1654.3566.0082.1327-.036.2542-.1241.3425l-1.2818 1.2817 1.3845 1.8344zm-8.3502-3.5023c-.095-.2699-.3829-.5475-.7503-.5557-.3663.0083-.6542.2858-.749.5551l-1.3455 3.5415c-.1708.5305-.0217.7272.1333.7988a.8568.8568 0 0 0 .3576.0776c.2346 0 .4139-.0952.4678-.2481l.2787-.7297 1.7152.0001.2785.7292c.0541.1532.2335.2484.4681.2484a.8601.8601 0 0 0 .3576-.0775c.1551-.0713.3041-.2681.1329-.7999l-1.3449-3.5398zm-1.3116 2.4433l.5618-1.5961.5618 1.5961H9.3757zm5.9056 1.3836c0 .2843-.2418.5156-.5391.5156h-1.8047c-.2973 0-.5391-.2314-.5391-.5156V9.3281c0-.3102.2576-.5625.5742-.5625s.5742.2523.5742.5625v3.3047h1.1953c.2974 0 .5392.2314.5392.5156z"/></svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

@@ -0,0 +1 @@
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path fill="#03C75A" d="M16.273 12.845 7.376 0H0v24h7.726V11.156L16.624 24H24V0h-7.727v12.845Z"/></svg>

After

Width:  |  Height:  |  Size: 174 B

@@ -0,0 +1 @@
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path fill="#03C75A" d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7Zm0 9.5a2.5 2.5 0 1 1 0-5 2.5 2.5 0 0 1 0 5Z"/></svg>

After

Width:  |  Height:  |  Size: 207 B

@@ -0,0 +1 @@
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path fill="#FF0000" d="M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z"/></svg>

After

Width:  |  Height:  |  Size: 452 B

+80 -2
View File
@@ -57,5 +57,83 @@
"mapQuery": "MOPRO Clinic 157 Dosan-daero Gangnam-gu Seoul"
}
},
"_enNote": "2026-10-12 영문 값. 병원명·주소·원장 영문명은 공식 영문 페이지(mopro.co.kr/en/home/)와 홈페이지 구조화 데이터(employee 'Kunhak Moon') 표기. 대표자 '문건학'은 홈페이지 푸터 '대표자 : 문건학'(자동 수집값 '블로그'는 오류). sponsorNoticeEn·sideEffectNoticeEn·taglineEn 은 Claude 번역 초안으로 병원 확인 대기(haewon 결정 2026-10-12: 템플릿 규칙과 달리 영문 초안으로 교체). 강남언니 수치는 docs/reports/mopro/data/offsite.md 실측(2026-10-08). factSheetPatch·factSheetEn 은 워커가 읽지 않으므로 patch_site.py 가 적용한다."
}
"_enNote": "2026-10-12 영문 값. 병원명·주소·원장 영문명은 공식 영문 페이지(mopro.co.kr/en/home/)와 홈페이지 구조화 데이터(employee 'Kunhak Moon') 표기. 대표자 '문건학'은 홈페이지 푸터 '대표자 : 문건학'(자동 수집값 '블로그'는 오류). sponsorNoticeEn·sideEffectNoticeEn·taglineEn 은 Claude 번역 초안으로 병원 확인 대기(haewon 결정 2026-10-12: 템플릿 규칙과 달리 영문 초안으로 교체). 강남언니 수치는 docs/reports/mopro/data/offsite.md 실측(2026-10-08). factSheetPatch·factSheetEn 은 워커가 읽지 않으므로 patch_site.py 가 적용한다.",
"interview": {
"video": {
"id": "lzx2z4cWJt0",
"title": "[라스트닥터 3주년 인터뷰] 매출보다 직원행복 챙겼더니 일어난 3가지 변화",
"published": "2026-10-10",
"channel": "유튜브 @the_lastdoctor"
},
"links": [
{
"cat": "밀착 인터뷰 · 네이버 블로그",
"title": "모발설계자 문건학 원장 밀착인터뷰 _ 보이는 것 너머, 시간을 설계하다",
"desc": "문건학 원장 인터뷰 원문을 블로그에서 읽을 수 있습니다.",
"url": "https://blog.naver.com/all_artist/224436053883",
"foot": "2026-10-09 게시 · blog.naver.com/all_artist"
},
{
"cat": "공식 블로그",
"title": "모프로의원 네이버 블로그",
"desc": "모발이식·탈모 치료 정보를 모프로의원이 직접 올리는 블로그입니다.",
"url": "https://blog.naver.com/moprohair",
"foot": "blog.naver.com/moprohair"
},
{
"cat": "인스타그램",
"title": "모프로의원 인스타그램",
"desc": "모프로의원 공식 인스타그램 계정입니다.",
"url": "https://www.instagram.com/moproclinic/",
"foot": "@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 으로 쓴다.",
"footerChannels": [
{
"label": "유튜브",
"labelEn": "YouTube",
"url": "https://www.youtube.com/@moproclinic",
"icon": "youtube.svg"
},
{
"label": "인스타그램",
"labelEn": "Instagram",
"url": "https://www.instagram.com/moproclinic/",
"icon": "instagram.svg"
},
{
"label": "네이버 블로그",
"labelEn": "Naver Blog",
"url": "https://blog.naver.com/moprohair",
"icon": "naverblog.svg"
},
{
"label": "카카오톡 채널",
"labelEn": "KakaoTalk Channel",
"url": "https://pf.kakao.com/_rjAVG",
"icon": "kakaotalk.svg",
"bg": "#FEE500"
},
{
"label": "네이버 플레이스",
"labelEn": "Naver Place",
"url": "https://m.place.naver.com/hospital/1821744096/home",
"icon": "naverplace.svg"
},
{
"label": "강남언니",
"labelEn": "Gangnam Unni",
"url": "https://www.gangnamunni.com/hospitals/5447",
"icon": "gangnamunni.png"
},
{
"label": "바비톡",
"labelEn": "Babitalk",
"url": "https://babitalk.com/hospitals/4372",
"icon": "babitalk.png"
}
],
"_footerChannelsNote": "2026-10-19 haewon 지시로 푸터에 채널 아이콘을 싣는다. URL은 docs/reports/mopro/data/offsite.md 실측(2026-10-08). 블로그는 haewon이 '콘텐츠 메인'으로 준 moprohair(팩트 시트 자동 수집값 moproclinic은 기존 사례연구 블로그). Facebook 2개(팔로워 5·25, 홈페이지 링크 없음)·TikTok(팔로워 0)은 넣지 않았다. 아이콘: 유튜브·인스타그램·네이버·카카오톡은 simple-icons(CC0), 강남언니·바비톡은 각 사이트 파비콘, 플레이스는 지도 핀. patch_site.py 가 channel-icons/ 를 public/img/channels/ 로 복사한다."
}
+107
View File
@@ -12,12 +12,15 @@
2. 회복 일정 캘린더 파일 정보(PRODID·UID)에 남은 다른 병원 이름을 INFINITH·모프로로 바꾼다
3. clinic.json excludeImages 에 해당하는 파일을 public/img 전체에서 지운다(워커는 img/clinic 만 지운다)
3b. 영문 화면의 한글 노출을 정리한다(영문 사이트 이름·대표자·빈 값 문구, 팩트 시트 영문 값, 사진 없는 장소 이름 칸)
3c. 홈에 'Interview' 섹션(원장 인터뷰 영상·인터뷰 글·공식 블로그·인스타그램)을 넣는다(clinic.json interview)
3d. 푸터에 채널 아이콘 줄(유튜브·인스타그램·블로그·카카오톡·플레이스·강남언니·바비톡)을 넣는다(clinic.json footerChannels)
4. vercel.json 사이트 주소를 정식 주소로 넣고, 공유 이미지(og.jpg)를 '서포터즈' 없는 상단 문구로 다시 그린다
5. src 에 화면용 '서포터즈'가 남아 있으면 실패로 끝낸다
"""
import json
import os
import re
import shutil
import subprocess
import sys
@@ -131,6 +134,108 @@ def patch_english():
return changed
# 홈 'Interview' 섹션 (haewon 지시 2026-10-19). 원장 인터뷰 영상(외부 채널)과 인터뷰 글·공식 블로그·인스타그램 링크 카드
INTERVIEW_ANCHOR = " <section class=\"section light\">\n <div class=\"wrap-wide\">\n <div class=\"sec-head\"><div class=\"eyebrow\">Inside</div>"
INTERVIEW_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">문건학 원장 인터뷰와 {clinic} 공식 채널입니다.</p></div>
<div class="interview-grid">
{interview.video && <div class="interview-video"><VideoLite id={interview.video.id} title={interview.video.title} published={interview.video.published} channel={interview.video.channel} /></div>}
{interview.links.map((l) => (
<article class="card">
<div class="cat">{l.cat}</div>
<h3><a href={l.url} rel="noopener" target="_blank">{l.title}</a></h3>
<p>{l.desc}</p>
<div class="foot">{l.foot}</div>
</article>
))}
</div>
</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>
</section>
"""
# VideoLite 캡션은 병원 유튜브 핸들을 고정으로 붙인다. 외부 채널 영상은 channel 로 바꿔 쓴다
VIDEOLITE_REPLACEMENTS = [
("note?: string; compact?: boolean }", "note?: string; compact?: boolean; channel?: string }"),
("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 ?"),
]
def patch_home_interview():
interview = json.load(open(os.path.join(HERE, "clinic.json"), encoding="utf-8")).get("interview")
if not interview:
return 0
json.dump(interview, open(os.path.join(SITE, "src/data/interview.json"), "w", encoding="utf-8"), ensure_ascii=False, indent=2)
vp = os.path.join(SITE, "src/components/VideoLite.astro")
text = open(vp, encoding="utf-8").read()
for old, new in VIDEOLITE_REPLACEMENTS:
text = text.replace(old, new)
open(vp, "w", encoding="utf-8").write(text)
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
# 푸터 채널 아이콘 (haewon 지시 2026-10-19). 유튜브·강남언니 글자 링크는 아이콘 줄로 옮기고 홈페이지 링크만 남긴다
FOOTER_LINKS_OLD = "{has(surface('youtube').url) && <> · <a href={surface('youtube').url} rel=\"noopener\">{u.foot_youtube}</a></>}{has(surface('gangnamunni').url) && <> · <a href={surface('gangnamunni').url} rel=\"noopener\">{u.foot_gu}</a></>}</p>"
FOOTER_CHANNELS = """</p>
<ul class="foot-channels">
{footerChannels.map((c) => (
<li><a href={c.url} rel="noopener" target="_blank" title={lang === 'en' ? c.labelEn : c.label} style={c.bg ? `background:${c.bg}` : undefined}><img src={`/img/channels/${c.icon}`} alt={lang === 'en' ? c.labelEn : c.label} width="20" height="20" /></a></li>
))}
</ul>"""
FOOTER_CSS = """
/* 푸터 채널 아이콘 (patch_site.py 가 넣음) */
.site-footer .foot-channels { list-style: none; display: flex; flex-wrap: wrap; gap: 0.55rem; margin: 0.9rem 0 0; padding: 0; }
.site-footer .foot-channels a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 999px; background: #fff; transition: transform .2s, box-shadow .2s; }
.site-footer .foot-channels a:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.25); }
.site-footer .foot-channels img { width: 20px; height: 20px; display: block; }
"""
def patch_footer_channels():
channels = json.load(open(os.path.join(HERE, "clinic.json"), encoding="utf-8")).get("footerChannels")
if not channels:
return 0
dst = os.path.join(SITE, "public", "img", "channels")
os.makedirs(dst, exist_ok=True)
for c in channels:
shutil.copyfile(os.path.join(HERE, "channel-icons", c["icon"]), os.path.join(dst, c["icon"]))
json.dump(channels, open(os.path.join(SITE, "src/data/footerChannels.json"), "w", encoding="utf-8"), ensure_ascii=False, indent=2)
changed = 0
cp = os.path.join(SITE, "src/styles/global.css")
css = open(cp, encoding="utf-8").read()
if ".foot-channels" not in css:
open(cp, "w", encoding="utf-8").write(css.rstrip("\n") + "\n" + FOOTER_CSS)
changed += 1
bp = os.path.join(SITE, "src/layouts/Base.astro")
text = open(bp, encoding="utf-8").read()
if "data/footerChannels.json" not in text:
if FOOTER_LINKS_OLD not in text:
sys.exit("Base.astro 에서 푸터 유튜브·강남언니 링크 줄을 찾지 못해 채널 아이콘을 넣지 못함")
text = text.replace("import EN from '../data/factSheetEn.json';",
"import EN from '../data/factSheetEn.json';\nimport footerChannels from '../data/footerChannels.json';", 1)
text = text.replace(FOOTER_LINKS_OLD, FOOTER_CHANNELS, 1)
open(bp, "w", encoding="utf-8").write(text)
changed += 1
return changed
def remove_excluded_images():
prefixes = json.load(open(os.path.join(HERE, "clinic.json"), encoding="utf-8")).get("excludeImages", [])
removed = []
@@ -170,6 +275,8 @@ if __name__ == "__main__":
n = patch_copy()
n_en = patch_english()
print(f"영문 처리 {n_en}곳")
print(f"홈 인터뷰 섹션 {patch_home_interview()}곳")
print(f"푸터 채널 아이콘 {patch_footer_channels()}곳")
removed = remove_excluded_images()
set_site_url_and_share_image()
left = leftovers()