JOYERIA.EXE · Pricing, inventory, sales and a bazaar store

PROJECT 05 / 11 · Web · PWA

Sales and inventory for a jewelry business

An installable web app for a jewelry and accessories business, made for the owner’s iPhone: she prices each piece from its real cost, sells with a cart and the camera as a scanner, keeps inventory, sends the sale note as an image and runs a loyalty card; at bazaars, customers build their cart on their own phone.

  • In production
  • Installable on the iPhone
  • 2026
In production VITE · REACT 19 · SUPABASE · PWA

01 / IMAGES.DIR

Project overview.

The app runs the business with real customers and real stock, so the real one stays untouched. These screenshots come from a copy I ran on my laptop with its own local database and made-up pieces, customers and sales; the brand’s logos and loyalty card were swapped for neutral ones and the pieces have no photos.

IMAGES.DIR
Home with today’s, this week’s and this month’s sales, a bazaar cart waiting and shortcuts; on the right, a new sale with two pieces in the cart (opens in a new tab)
Home with today’s, this week’s and this month’s sales, a bazaar cart waiting and shortcuts; on the right, a new sale with two pieces in the cart
The sale note as an image, ready to send by WhatsApp, with the loyalty card stamped; on the right, the customer with her stamps and her next discount (opens in a new tab)
The sale note as an image, ready to send by WhatsApp, with the loyalty card stamped; on the right, the customer with her stamps and her next discount
The bazaar store a customer opens from a QR, without signing in; on the right, the cart that reaches the owner, to charge it or wait for the transfer (opens in a new tab)
The bazaar store a customer opens from a QR, without signing in; on the right, the cart that reaches the owner, to charge it or wait for the transfer
Inventory with its own code, stock and price per piece; on the right, performance: sales, net profit, average ticket and margin (opens in a new tab)
Inventory with its own code, stock and price per piece; on the right, performance: sales, net profit, average ticket and margin
Sales history by day with the month’s total and profit; on the right, customers with their purchases and stamps (opens in a new tab)
Sales history by day with the month’s total and profit; on the right, customers with their purchases and stamps
The catalog to show customers in person, with prices and without costs; on the right, one-off expenses that count toward performance (opens in a new tab)
The catalog to show customers in person, with prices and without costs; on the right, one-off expenses that count toward performance
Local copy with made-up data · no brand

02 / STACK.INI

Tech stack.

What each piece does in this project. Hover over a tool, tap it or tab into the list to light it up.

  • React 19 · ViteInstallable app for the phone, as a static site
  • TypeScriptTyped pieces, sales, customers and orders
  • Tailwind CSS 4Interface designed for one hand on the iPhone
  • SupabasePostgreSQL with row-level security, sale rules in SQL functions, and photo storage
  • vite-plugin-pwa · DexieInstalls on the phone and queues sales without signal
  • ZXing · JsBarcodeScanning with the camera and printable barcode labels
  • html-to-imageThe sale note as an image to share
  • VercelHosting and deploys

03 / README.TXT

About the project.

README.TXT

Problem

The owner priced her pieces by eye, kept stock and sales in notes and lost track of what each piece had really cost once shipping was split across an order. At bazaars, taking orders by hand was slow.

Solution

An app installed on her iPhone that splits each order’s shipping across its pieces, suggests the price from the real cost, records each sale with its packaging and profit, and sends the note as an image. At bazaars, customers scan a QR, build their cart on their own phone and it reaches her ready to charge.

Key features

  1. Price from the real costPurchase cost plus the share of shipping by weight, with a default margin or a fixed profit and rounding up.
  2. Sell with the cameraSearch or scan the label’s barcode, choose the packaging and charge; the sale is saved even without signal and uploads itself later.
  3. Sale note and loyaltyThe note is generated as an image with the stamped loyalty card; the fifth and tenth purchases get a discount.
  4. Bazaar storeCustomers open the catalog from a QR, set pieces aside as they add them and send the cart; it reaches the owner to charge in cash or by transfer.
  5. Inventory and performancePieces and packaging with their stock, supplier orders that spread shipping, and performance with best sellers, slow movers and real margin.

Before handing it over, a test log checked the sign-in, the row-level security and the shipping split against the first real order, to the cent. Stock rules (no negative stock, cancellations that return the pieces) live in the database, not only in the screen.

Ready UTF-8 · LF · 28 L

04 / ARCHITECTURE.SYS

How it works.

Components and data flow, taken from the source code.

ARCHITECTURE.SYS

PHONES

  • Owner’s iPhoneInstalled app, unlocked with a PIN
  • Customer’s phoneBazaar store, no account

VERCEL · VITE

  • Installable web appStatic site with offline cache
  • Offline queueSales saved on the phone

DATA

  • SupabasePostgreSQL, SQL functions and Storage
Architecture diagram — From the counter or the bazaar table to the database: two kinds of phone, a static app and Supabase.

Data flow, step by step

  1. The owner unlocks the app with her PIN; inside, it signs in to the business’s only account.
  2. Each sale goes to a SQL function that checks stock, deducts pieces and packaging and saves the profit in one step.
  3. Without signal, the sale waits in a queue on the phone with its own identifier, so it is never recorded twice.
  4. At a bazaar, the customer’s cart sets pieces aside as she adds them and reaches the owner to charge.

Engineering notes

  • Real cost, not purchase priceShipping is split by weight across each order’s pieces and the average cost is updated on receipt, so the margin is the real one.
  • Rules in the databaseSelling, cancelling and adjusting stock are SQL functions, so the phone can’t leave stock negative or a sale half done.
  • Works without signalInventory is read from the phone’s cache and sales wait in a local queue until the connection comes back.
  • One account, one PINRow-level security on every table and sign-ups turned off; without the PIN, the public key only sees the bazaar store’s catalog.

05 / PROPERTIES.CPL

Project properties.

PROPERTIES.CPL · Sales and inventory system for a jewelry business

Platform
Web — installable app (PWA) on Vercel, made for the iPhone
Type
Sales, inventory and loyalty
Status
In production
Year
2026First commit: October 2026
My role
Design and full-stack development
Built for
A jewelry and accessories business (name withheld)
Repository
PrivateHandles real customers and sales

06 / LINKS.LNK