diff --git a/supporters/briefs/mopro/channel-icons/babitalk.png b/supporters/briefs/mopro/channel-icons/babitalk.png new file mode 100644 index 0000000..9067af2 Binary files /dev/null and b/supporters/briefs/mopro/channel-icons/babitalk.png differ diff --git a/supporters/briefs/mopro/channel-icons/gangnamunni.png b/supporters/briefs/mopro/channel-icons/gangnamunni.png new file mode 100644 index 0000000..364124a Binary files /dev/null and b/supporters/briefs/mopro/channel-icons/gangnamunni.png differ diff --git a/supporters/briefs/mopro/channel-icons/instagram.svg b/supporters/briefs/mopro/channel-icons/instagram.svg new file mode 100644 index 0000000..012ace0 --- /dev/null +++ b/supporters/briefs/mopro/channel-icons/instagram.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/supporters/briefs/mopro/channel-icons/kakaotalk.svg b/supporters/briefs/mopro/channel-icons/kakaotalk.svg new file mode 100644 index 0000000..e3753ae --- /dev/null +++ b/supporters/briefs/mopro/channel-icons/kakaotalk.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/supporters/briefs/mopro/channel-icons/naverblog.svg b/supporters/briefs/mopro/channel-icons/naverblog.svg new file mode 100644 index 0000000..9bd8345 --- /dev/null +++ b/supporters/briefs/mopro/channel-icons/naverblog.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/supporters/briefs/mopro/channel-icons/naverplace.svg b/supporters/briefs/mopro/channel-icons/naverplace.svg new file mode 100644 index 0000000..83ff90a --- /dev/null +++ b/supporters/briefs/mopro/channel-icons/naverplace.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/supporters/briefs/mopro/channel-icons/youtube.svg b/supporters/briefs/mopro/channel-icons/youtube.svg new file mode 100644 index 0000000..4715e61 --- /dev/null +++ b/supporters/briefs/mopro/channel-icons/youtube.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/supporters/briefs/mopro/clinic.json b/supporters/briefs/mopro/clinic.json index bb2a8d1..ce32ef7 100644 --- a/supporters/briefs/mopro/clinic.json +++ b/supporters/briefs/mopro/clinic.json @@ -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 가 적용한다." -} \ No newline at end of file + "_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/ 로 복사한다." +} diff --git a/supporters/briefs/mopro/patch_site.py b/supporters/briefs/mopro/patch_site.py index 44591ee..5565d9c 100644 --- a/supporters/briefs/mopro/patch_site.py +++ b/supporters/briefs/mopro/patch_site.py @@ -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 = "
\n
\n
Inside
" +INTERVIEW_SECTION = """
+
+
Interview

Meet The Doctor

문건학 원장 인터뷰와 {clinic} 공식 채널입니다.

+
+ {interview.video &&
} + {interview.links.map((l) => ( +
+
{l.cat}
+

{l.title}

+

{l.desc}

+
{l.foot}
+
+ ))} +
+
+ +
+""" +# 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) && <> · {u.foot_youtube}}{has(surface('gangnamunni').url) && <> · {u.foot_gu}}

" +FOOTER_CHANNELS = """

+
    + {footerChannels.map((c) => ( +
  • {lang
  • + ))} +
""" +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()