Cobracase is an online store for custom phone cases. Customers upload an image, place it on their phone, and order the case. It's a Next.js app with PostgreSQL through Drizzle ORM, Kinde for sign-in, and Stripe for payments.
What it does
Case configurator
Customers drag in an image, then move and resize it over a mockup of the phone. They pick the case color, the phone model, the material, and the finish, and see the result before they check out.
Checkout
Stripe Checkout takes card payments and collects a shipping address for Morocco or the US. A webhook listens for completed sessions, marks the order as paid, and saves the shipping and billing addresses.
Confirmation email
Once an order is paid, Resend sends a thank-you email built with React Email.
Admin dashboard
An admin account sees every paid order, can change each order's status, and tracks revenue for the last week and month against a goal.
What was hard
Cropping the design to the case
The customer positions the image on screen, but the order needs an image cut to the exact case area. The configurator redraws the image on a canvas at the position and size the customer chose, crops it to the case, and uploads the result as the final design.