/* House of Windsor — UI primitives & chrome */ const { useState, useEffect, useRef } = React; /* ─── Wordmark ──────────────────────────────────────────────── */ function Wordmark({ variant = 'stacked', color }) { const style = color ? { color } : undefined; if (variant === 'compact') { return ( HOUSE OF WINDSOR JEWELLERS ); } return (
HOUSE OF WINDSOR JEWELLERS
); } /* ─── Diamond glyph used as ornament ────────────────────────── */ function DiamondGlyph({ size = 14, color = 'currentColor' }) { return ( ); } /* ─── Stars row ─────────────────────────────────────────────── */ function Stars({ n = 5, size = 14 }) { return ( {Array.from({ length: 5 }).map((_, i) => ( ))} ); } /* ─── Tripadvisor 5.0 chip ─────────────────────────────────── */ function TripadvisorChip({ tone = 'light' }) { const dark = tone === 'dark'; return ( {HOWJ.rating.score.toFixed(1)} · {HOWJ.rating.count} reviews on Tripadvisor ); } /* ─── Nav ──────────────────────────────────────────────────── */ function Nav({ route, setRoute, onBook, scrolled }) { const [mobileOpen, setMobileOpen] = useState(false); return (
{/* Mobile drawer */} {mobileOpen && (
)}
); } /* ─── WhatsApp FAB ──────────────────────────────────────────── */ function WhatsAppFab() { const href = `https://wa.me/${HOWJ.contact.whatsapp}?text=${encodeURIComponent("Hi House of Windsor, I'd like to book a consultation.")}`; return ( e.currentTarget.style.transform = 'scale(1.06)'} onMouseLeave={e => e.currentTarget.style.transform = 'scale(1)'} > ); } /* ─── Mobile bottom CTA bar ─────────────────────────────────── */ function MobileBookBar({ onBook }) { return (
Call
); } /* ─── Consultation modal ───────────────────────────────────── */ function ConsultationModal({ open, onClose, defaultCollection }) { const [step, setStep] = useState(0); const [form, setForm] = useState({ name: '', email: '', mobile: '', collection: defaultCollection || 'Engagement Rings', when: 'In the next two weeks', visit: 'In-showroom', message: '', }); const update = (k, v) => setForm(f => ({ ...f, [k]: v })); useEffect(() => { if (open) { setStep(0); if (defaultCollection) update('collection', defaultCollection); } }, [open, defaultCollection]); if (!open) return null; const totalSteps = 3; return (
e.stopPropagation()} style={{ background: 'var(--ivory)', maxWidth: 880, width: '100%', maxHeight: '92vh', overflow: 'auto', display: 'grid', gridTemplateColumns: 'minmax(0, 280px) 1fr', boxShadow: '0 40px 100px rgba(14,22,38,0.5)', }} className="modal-grid" > {/* Sidebar */} {/* Form */}
{/* progress */}
{Array.from({ length: totalSteps }).map((_, i) => (
))}
{step < totalSteps && (
Step {step + 1} of {totalSteps}
)} {step === 0 && ( <>

What are you looking to commission?

{['In-showroom', 'WhatsApp video', 'Phone call'].map(o => ( ))}
)} {step === 1 && ( <>

How can we reach you?

update('name', e.target.value)} placeholder="Full name" />
update('email', e.target.value)} placeholder="you@example.com" />
update('mobile', e.target.value)} placeholder="+44 …" />
)} {step === 2 && ( <>

One last look.

{[ ['Collection', form.collection], ['Meeting by', form.visit], ['Timeframe', form.when], ['Name', form.name || '—'], ['Email', form.email || '—'], ['Mobile', form.mobile || '—'], ['Note', form.message || '—'], ].map(([k, v]) => (
{k}
{v}
))}

By sending this you agree to be contacted by House of Windsor Jewellers about your enquiry. We do not share your details.

)} {step === 3 && (

Thank you{form.name ? `, ${form.name.split(' ')[0]}` : ''}.

We'll be in touch within one business day. In the meantime, feel free to message us directly on WhatsApp.

)} {step < totalSteps && (
)}
); } /* ─── Footer ───────────────────────────────────────────────── */ function Footer({ setRoute, onBook }) { return ( ); } /* ─── Page transition wrapper ──────────────────────────────── */ function PageFade({ k, children }) { return
{children}
; } Object.assign(window, { Wordmark, DiamondGlyph, Stars, TripadvisorChip, Nav, WhatsAppFab, MobileBookBar, ConsultationModal, Footer, PageFade, });