Shannyn Oberegger
Metal UI:

A rock music themed React component library
Project type: Front-end development and UI design, component library
For: Torrens University (CLD300 Component Library Development)
Role: Designer and front-end developer (individual project)
Tools: React, CSS Modules, Framer Motion, React Router, Font Awesome, CodeSandbox
Link to code: Metal UI code
Brief: Build a library of reusable web components using atomic design, then show them all on a library display page. I went with a 'Linkin Park' theme and built Button, Typography, Input, Chip, Card, Menu, Timeline, Navbar and Footer.
Outcome
A working library and docs site with nine themed components in light and dark mode.
Then a band website made using the component to show them in use.

Process
Design in Figma: Before writing any code, I designed every component in Figma. This let me check that the colours, fonts and spacing worked together across the whole library, and fix problems while they were still being designed.

Coding the Design: The Figma variables became one variables.css file holding the colours, fonts, spacing and borders, so changing one token updates the whole library.
Dark mode switches with a body.dark class. Dark mode failed silently in CSS Modules until I moved :global(body.dark) to the top level of the file.
Coding the motion: Timeline, Footer, Card and Navbar share one fade and slide up entrance that plays once on scroll. Cards also react to hover, and the Navbar animates a swap between an intro menu and the standard bar. Wrapping typography in animated elements added extra DOM nodes that broke flex and grid layouts, so I kept animation on parent components.
Using the Components: I combined all of the components into a webpage for the band Linkin Park. It shows how the components can be used together to create a sleek page with motion built in.

Coding the Components: Every component uses the same template: a functional component with children and variant props, plus its own CSS Module. Variants use plain if/else chains, so new components match the old ones. Card has horizontal and vertical layouts and glass and border styles. Timeline uses children composition, so it works as a compound component. I kept things simple where it counted, like using a native select instead of a custom dropdown.

