diff --git a/src/components/ordering/MenuBackdrop.module.scss b/src/components/ordering/MenuBackdrop.module.scss new file mode 100644 index 0000000..7d9e8d5 --- /dev/null +++ b/src/components/ordering/MenuBackdrop.module.scss @@ -0,0 +1,20 @@ +@use '../../styles/variables' as *; + +.backdrop { + position: fixed; + inset: 0; + z-index: -1; + overflow: hidden; + pointer-events: none; +} + +.icon { + position: absolute; + color: $color-primary; + opacity: 0.08; + + svg { + width: 100%; + height: 100%; + } +} diff --git a/src/components/ordering/MenuBackdrop.tsx b/src/components/ordering/MenuBackdrop.tsx new file mode 100644 index 0000000..538ad43 --- /dev/null +++ b/src/components/ordering/MenuBackdrop.tsx @@ -0,0 +1,87 @@ +import styles from './MenuBackdrop.module.scss' + +const PizzaIcon = () => ( + + + + + + +) + +const BurgerIcon = () => ( + + + + + + + +) + +const FriesIcon = () => ( + + + + +) + +const ICONS = [PizzaIcon, BurgerIcon, FriesIcon] + +// Fixed, hand-placed positions rather than random ones — random values would +// differ between the server-rendered and first client-rendered HTML and +// trigger a hydration mismatch. +const PLACEMENTS = [ + { top: '6%', left: '6%', size: 72, rotate: -14 }, + { top: '14%', left: '86%', size: 56, rotate: 20 }, + { top: '30%', left: '46%', size: 64, rotate: -6 }, + { top: '46%', left: '10%', size: 52, rotate: 10 }, + { top: '58%', left: '90%', size: 68, rotate: -18 }, + { top: '72%', left: '30%', size: 58, rotate: 14 }, + { top: '82%', left: '68%', size: 60, rotate: -8 }, + { top: '4%', left: '40%', size: 44, rotate: 8 }, + { top: '38%', left: '78%', size: 46, rotate: -22 }, + { top: '64%', left: '52%', size: 40, rotate: 16 }, + { top: '90%', left: '12%', size: 50, rotate: -10 }, + { top: '20%', left: '20%', size: 42, rotate: 24 }, +] + +export const MenuBackdrop = () => ( + +) diff --git a/src/routes/index.tsx b/src/routes/index.tsx index 61a370a..7e9272e 100644 --- a/src/routes/index.tsx +++ b/src/routes/index.tsx @@ -1,5 +1,6 @@ import { createFileRoute } from '@tanstack/react-router' +import { MenuBackdrop } from '#/components/ordering/MenuBackdrop.tsx' import { MenuList } from '#/components/ordering/MenuList.tsx' import { useBasket } from '#/lib/basket.tsx' import { getBrand } from '#/server/brand.ts' @@ -13,10 +14,11 @@ const OrderingPage = () => { return (
+

Zero cooks, all machine. A robotic kitchen grills, assembles, and - plates your order in real time — watch it happen live, from click to - pickup. + plates your tasty menu in real time — watch it happen live, from + click to pickup.