Navigation & layout - Replace per-page hardcoded nav/footer with shared nav.js (client-side injection) - Add nginx reverse proxy back to docker-compose for clean localhost routing - Rename /color-picker/ to /color/ across nav, directory, and references eStore admin - Add variation hiding controls (mirrors existing modifier hiding) - Add delivery rate editor (base fee + per-mile per tier, persisted to data/) - Fix all missing BASE prefix on fetch calls (admin PATCH/DELETE, availability, slots, colors) - Mount estore/data/ as a Docker volume so admin config survives rebuilds Booking & calendar - Set pickup calendar events to TRANSPARENT (free) so they don't block delivery slots - Skip CANCELLED events in busy-time calculation - Re-check slot availability at checkout before charging (409 on conflict) Phone & email validation - Auto-format phone as (XXX) XXX-XXXX as user types - Require exactly 10 digits; tighten email regex Confirmation emails (store alert + customer) - Full item detail per line: name, price, add-ons, colors, note - Charges breakdown: subtotal, delivery fee, tax, total - Delivery window: simplified M/D/YY h:mm – h:mm AM/PM format - .ics calendar attachment on customer confirmation Delivery rates - Extract configurable rates to delivery-rates.ts (server-only, no fs in client bundle) - calcDelivery() accepts optional rates param; delivery-quote route passes configured rates Content - Change all "40+ latex colors" references to "70+" Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
56 lines
1.8 KiB
TypeScript
56 lines
1.8 KiB
TypeScript
'use client'
|
|
|
|
import { useState } from 'react'
|
|
import Link from 'next/link'
|
|
import { BASE } from '@/lib/basepath'
|
|
|
|
// Use <a> for links that leave the estore (main site pages) so Next.js basePath
|
|
// is not prepended. Use <Link> only for internal estore routes.
|
|
export default function Navbar() {
|
|
const [isOpen, setIsOpen] = useState(false)
|
|
|
|
return (
|
|
<nav
|
|
className="navbar is-info is-spaced has-shadow"
|
|
role="navigation"
|
|
aria-label="main navigation"
|
|
>
|
|
<div className="navbar-brand is-size-1">
|
|
<a className="navbar-item" href="/">
|
|
{/* eslint-disable-next-line @next/next/no-img-element */}
|
|
<img
|
|
style={{ backgroundColor: 'white' }}
|
|
src={`${BASE}/images/logo/BeachPartyBalloons-logo.webp`}
|
|
alt="Beach Party Balloons logo"
|
|
/>
|
|
</a>
|
|
|
|
<a
|
|
role="button"
|
|
className={`navbar-burger ${isOpen ? 'is-active' : ''}`}
|
|
aria-label="menu"
|
|
aria-expanded={isOpen}
|
|
onClick={() => setIsOpen(!isOpen)}
|
|
>
|
|
<span aria-hidden="true" />
|
|
<span aria-hidden="true" />
|
|
<span aria-hidden="true" />
|
|
<span aria-hidden="true" />
|
|
</a>
|
|
</div>
|
|
|
|
<div className={`navbar-menu has-text-right ${isOpen ? 'is-active' : ''}`}>
|
|
<div className="navbar-end">
|
|
<a className="navbar-item" href="/">Home</a>
|
|
<Link className="navbar-item is-tab is-active" href="/">Shop</Link>
|
|
<a className="navbar-item" href="/about/">About Us</a>
|
|
<a className="navbar-item" href="/faq/">FAQ</a>
|
|
<a className="navbar-item" href="/gallery/">Gallery</a>
|
|
<a className="navbar-item" href="/color/">Colors</a>
|
|
<a className="navbar-item" href="/contact/">Contact</a>
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
)
|
|
}
|