feat(contact): 푸터 연락처와 문의 폼 추가, 구글시트 적재·메일 알림 연동
연락처 통일 - 사이트 안에 이메일이 contact@o2o.kr · o2oteam@o2o.kr 두 갈래로 갈라져 있던 것을 sales@o2o.kr 하나로 통일 (lib/contact.ts 단일 출처) - 전화번호 010.2755.6463 을 처음으로 명시. discoveryContact.ts 는 기존 import 경로를 깨지 않도록 재내보내기만 한다 푸터·문의 폼 - 푸터에 전화·이메일과 문의하기 버튼 추가 (사업자명·주소는 확인된 값이 없어 넣지 않는다) - ContactModal 신규: 성함·회사·전화·이메일·문의내용. 화면 구조는 기존 DiscoveryLeadModal 을 그대로 따라 모달이 두 종류로 보이지 않게 한다 - Navbar 문의하기를 mailto 에서 모달로 교체. 메일 앱이 없는 사용자가 mailto 에서 이탈하던 것을 막는다 수신 경로 - submitLead: Apps Script 웹앱으로 POST. 이 사이트는 서버 없는 SPA 라 중간 서버를 두지 않았다. Apps Script 는 CORS 프리플라이트에 응답하지 않아 Content-Type 을 text/plain 으로 보내 simple request 로 맞춘다 - scripts/apps-script/lead-intake.gs: 구글시트 행 추가와 알림 메일을 한 실행에서 처리. 시트 트리거는 스크립트가 쓴 변경에 늦거나 누락되는 경우가 있어 doPost 안에서 바로 보낸다 - 엔드포인트 미설정·전송 실패 시 접수된 것처럼 보이지 않게 하고 메일 폴백을 띄운다 (기존 DiscoveryLeadModal 과 같은 규칙) 토큰 실값은 저장소에 넣지 않는다. 배포본 Apps Script 와 Vercel 환경변수(VITE_LEAD_ENDPOINT · VITE_LEAD_TOKEN)에만 둔다. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
c0804dd2bd
commit
9c47df561b
9 files changed
+523
-30
No files matched your search
+52
-11
@@ -1,21 +1,62 @@
|
||||
/**
|
||||
* Footer — 전역 하단.
|
||||
*
|
||||
* 2026-10-01: 연락처(전화·이메일)와 문의하기 버튼을 넣었다. 그 전에는 푸터에 연락 수단이
|
||||
* 하나도 없었다. 사업자명·주소는 확인된 값이 없어 넣지 않는다 (지어내지 않는다).
|
||||
*/
|
||||
import { useState } from 'react';
|
||||
import { Link } from 'react-router';
|
||||
import ContactModal from './ContactModal';
|
||||
import { CONTACT_EMAIL, CONTACT_PHONE, CONTACT_PHONE_HREF } from '../lib/contact';
|
||||
|
||||
export default function Footer() {
|
||||
const [contactOpen, setContactOpen] = useState(false);
|
||||
|
||||
return (
|
||||
<footer className="bg-white border-t border-slate-100 py-12 px-6">
|
||||
<div className="max-w-7xl mx-auto flex flex-col md:flex-row items-center justify-between gap-6">
|
||||
<Link to="/" className="flex items-center gap-2">
|
||||
<span className="font-serif text-3xl font-black tracking-[0.05em] bg-gradient-to-r from-[#4F1DA1] to-[#021341] bg-clip-text text-transparent">INFINITH</span>
|
||||
</Link>
|
||||
<div className="text-sm text-slate-500 text-center md:text-left">
|
||||
© {new Date().getFullYear()} INFINITH. All rights reserved. <br className="md:hidden" />
|
||||
Infinite Marketing for Premium Medical Business & Marketing Agency
|
||||
<footer className="bg-white border-t border-slate-100 py-12 px-6" data-no-print>
|
||||
<div className="max-w-7xl mx-auto flex flex-col gap-8">
|
||||
<div className="flex flex-col md:flex-row items-center justify-between gap-6">
|
||||
<Link to="/" className="flex items-center gap-2">
|
||||
<span className="font-serif text-3xl font-black tracking-[0.05em] bg-gradient-to-r from-[#4F1DA1] to-[#021341] bg-clip-text text-transparent">INFINITH</span>
|
||||
</Link>
|
||||
<div className="text-sm text-slate-500 text-center md:text-left">
|
||||
© {new Date().getFullYear()} INFINITH. All rights reserved. <br className="md:hidden" />
|
||||
Infinite Marketing for Premium Medical Business & Marketing Agency
|
||||
</div>
|
||||
<div className="flex items-center gap-6 text-sm font-medium text-slate-600">
|
||||
<a href="#" className="hover:text-primary-900 transition-colors">Privacy Policy</a>
|
||||
<a href="#" className="hover:text-primary-900 transition-colors">Terms of Service</a>
|
||||
</div>
|
||||
</div>
|
||||
<div className="flex items-center gap-6 text-sm font-medium text-slate-600">
|
||||
<a href="#" className="hover:text-primary-900 transition-colors">Privacy Policy</a>
|
||||
<a href="#" className="hover:text-primary-900 transition-colors">Terms of Service</a>
|
||||
|
||||
{/* 연락처 */}
|
||||
<div className="border-t border-slate-100 pt-7 flex flex-col md:flex-row md:items-center justify-between gap-5">
|
||||
<div className="flex flex-col sm:flex-row sm:items-center gap-x-6 gap-y-2 text-sm text-slate-600 text-center sm:text-left">
|
||||
<span>
|
||||
<span className="text-slate-400 mr-2">전화</span>
|
||||
<a href={CONTACT_PHONE_HREF} className="font-medium hover:text-primary-900 transition-colors">
|
||||
{CONTACT_PHONE}
|
||||
</a>
|
||||
</span>
|
||||
<span className="hidden sm:inline text-slate-200">·</span>
|
||||
<span>
|
||||
<span className="text-slate-400 mr-2">이메일</span>
|
||||
<a href={`mailto:${CONTACT_EMAIL}`} className="font-medium hover:text-primary-900 transition-colors">
|
||||
{CONTACT_EMAIL}
|
||||
</a>
|
||||
</span>
|
||||
</div>
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => setContactOpen(true)}
|
||||
className="self-center md:self-auto inline-flex items-center justify-center px-6 py-2.5 text-sm font-semibold text-white rounded-full transition-all shadow-sm hover:shadow-md bg-gradient-to-r from-[#4F1DA1] to-[#021341] hover:opacity-90"
|
||||
>
|
||||
문의하기
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<ContactModal open={contactOpen} onClose={() => setContactOpen(false)} source="footer" />
|
||||
</footer>
|
||||
);
|
||||
}
|
||||
Reference in new issue
Block a user