TheDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/apursley2012/player-one/llms.txt
Use this file to discover all available pages before exploring further.
Navigation component is the primary wayfinding system for the Player One portfolio. It renders as an unobtrusive fixed button in the bottom-right corner of every page, labeled INVENTORY with a menu icon. Pressing it summons a full-screen modal overlay styled as an arcade stage-select screen, complete with a CRT scanline layer, glitching heading, and a grid of illuminated route tiles.
Route Configuration
Navigation is driven by a static route config array containing seven entries. Each entry carries apath, a display label, and a Lucide React icon component.
| Path | Label | Icon |
|---|---|---|
/ | TITLE SCREEN | Gamepad2 |
/about | LORE | User |
/projects | LEVEL SELECT | CodeXml |
/skills | HIGH SCORES | Trophy |
/writing | CODEX | BookOpen |
/case-studies | BOSS BATTLES | Briefcase |
/contact | SAVE GAME | Phone |
Usage
Navigation uses React Router’s useLocation hook internally, so it must be rendered inside a <BrowserRouter> (or equivalent) context.Visual & Behavioral Description
The INVENTORY Button
A small fixed button anchored to the bottom-right of the viewport (fixed bottom-6 right-6 z-50). It carries the font-pixel class (Press Start 2P) and is styled with a magenta border and magenta box-glow (border-arcade-magenta, box-glow-magenta). Clicking it sets internal isOpen state to true, triggering the modal.
Modal Overlay
When open,AnimatePresence from Framer Motion mounts the overlay with a fade-in animation. The modal occupies the full viewport and layers the following:
- CRTOverlay — the standard scanline + vignette component is rendered inside the modal for an immersive display effect.
- SELECT STAGE heading — rendered with a CSS
glitchkeyframe animation in lime (font-pixel), visually flickering to reinforce the retro aesthetic. The modal itself carries a lime border and lime box-glow (border-arcade-lime,box-glow-lime). - Route grid — a responsive CSS grid of route tiles, each showing the route’s icon and label.
Active Route Highlighting
useLocation() compares the current pathname against each route’s path. The active tile receives:
- A magenta border (
border-arcade-magenta) with a magenta background tint - An
animate-pulsearrow indicator displayed alongside the label - A
◀text indicator appended after the label
Closing the Modal
The overlay can be dismissed by clicking the close button (top-right✕) or by clicking directly on a route link, which also triggers React Router navigation.
Implementation Notes
Where It’s Used
Navigation is mounted once at the application root (typically inside App.jsx or the top-level router component) so it persists across all route changes without re-mounting. Its z-[100] stacking context ensures it floats above page content, the HUD, and any page-level CRT overlays.