# CLAUDE.md This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. ## Two desktop shells — same frontend This repo ships **two interchangeable desktop shells** that both load the exact same `index.html`: 1. **Electron** (original, root of repo) — heavier (~70MB installer) but mature/familiar 2. **Tauri** (`tauri/` subfolder) — much lighter (~2MB installer, ~8MB exe) using the OS's built-in WebView2 instead of bundled Chromium `index.html` (plus `vendor/`) is the **single source of truth** for the UI — never duplicate or fork it. The Tauri shell's `tauri/dist/` is a *generated* copy (gitignored, rebuilt by `tauri/sync-frontend.js` before each `dev`/`build`run) — edit `index.html` at the repo root, never inside `tauri/dist/`. ### Electron commands (run from repo root) - `npm start` — run the app as an Electron desktop window (loads `index.html` via `main.js`) - `npm run serve` — run a plain Node HTTP server (`server.js`) at http://localhost:3010, serving the same `index.html` for browser-based testing - `npm run build` — package the Windows installer via `electron-builder` (NSIS, output goes to `dist/`) ### Tauri commands (run from `tauri/`) - `npm run dev` — sync the frontend into `tauri/dist/` and launch the Tauri dev shell - `npm run build` — sync the frontend and produce MSI + NSIS installers (output in `tauri/src-tauri/target/release/bundle/`) - `npm run serve` — same static server as the Electron side, for browser-based testing - Requires the Rust toolchain (`rustup`/`cargo`) plus MSVC Build Tools and WebView2 (Tauri prerequisites) — see https://tauri.app/start/prerequisites/ There is no test suite, linter, or build step for the app code itself — `index.html` is loaded directly (as a file in Electron/Tauri, or statically served). To verify a change, just reload the app/page in whichever shell you're using. ## Architecture This is a single-page Electron desktop app (also runnable as a static page) for calculating NMFC freight class from shipment dimensions and weight. Almost all logic lives in one file: - **`index.html`** — contains everything: markup, CSS (`