diff --git a/index.html b/index.html index 4fe3553..cf97a61 100644 --- a/index.html +++ b/index.html @@ -1,13 +1,24 @@ - + + Braids by Mira + + + + + + + + + +
diff --git a/public/robots.txt b/public/robots.txt new file mode 100644 index 0000000..c26cc1b --- /dev/null +++ b/public/robots.txt @@ -0,0 +1,5 @@ +User-agent: * +Disallow: /admin +Allow: / + +Sitemap: https://braidsbymira.vercel.app/sitemap.xml diff --git a/public/sitemap.xml b/public/sitemap.xml new file mode 100644 index 0000000..1a530c3 --- /dev/null +++ b/public/sitemap.xml @@ -0,0 +1,15 @@ + + + + https://braidsbymira.vercel.app/ + + + https://braidsbymira.vercel.app/shop + + + https://braidsbymira.vercel.app/book + + + https://braidsbymira.vercel.app/rules + + diff --git a/src/hooks/usePageTitle.ts b/src/hooks/usePageTitle.ts new file mode 100644 index 0000000..a2c9eff --- /dev/null +++ b/src/hooks/usePageTitle.ts @@ -0,0 +1,19 @@ +import { useEffect } from 'react' + +export default function usePageTitle(title: string, description?: string) { + useEffect(() => { + document.title = `${title} — Braids by Mira` + if (!description) return + let meta = document.querySelector('meta[name="description"]') + if (!meta) { + meta = document.createElement('meta') + meta.setAttribute('name', 'description') + document.head.appendChild(meta) + } + const previous = meta.getAttribute('content') + meta.setAttribute('content', description) + return () => { + if (previous) meta.setAttribute('content', previous) + } + }, [title, description]) +} diff --git a/src/pages/Book.tsx b/src/pages/Book.tsx index a910b8b..c463b34 100644 --- a/src/pages/Book.tsx +++ b/src/pages/Book.tsx @@ -7,9 +7,11 @@ import ServiceCard from '../components/ServiceCard' import StepProgress from '../components/StepProgress' import { fetchServices, type Service } from '../data/services' import type { TimeSlot } from '../data/availability' +import usePageTitle from '../hooks/usePageTitle' import styles from './Book.module.css' function Book() { + usePageTitle('Réserver', 'Réservez votre rendez-vous en ligne chez Braids by Mira.') const location = useLocation() const preselectedServiceId = (location.state as { serviceId?: string } | null)?.serviceId const booking = useBooking(preselectedServiceId) @@ -185,6 +187,121 @@ function Book() { onChange={(e) => booking.updateContact({ notes: e.target.value })} /> + +

Vos cheveux

+ +
+ + + {booking.errors.hairLength && {booking.errors.hairLength}} +
+ +
+ + + {booking.errors.hairType && {booking.errors.hairType}} +
+ +
+ + booking.updateIntake({ currentHairPhoto: e.target.files?.[0] ?? null })} + /> + Optionnel, mais fortement recommandé. +
+ +
+ +