Project Structure
The repository is a hybrid monorepo: a pnpm-managed React frontend at the root and a Cargo workspace for the Rust backend.
.
├── Cargo.toml # Rust workspace root (members: src-tauri, crates/*)
├── package.json # Frontend package + scripts (pnpm)
├── vite.config.ts # Vite config (dev server on :1420 for Tauri)
├── index.html # Frontend HTML entry
├── scripts/
│ └── generate-licenses.mjs # Build step: generates src/generated/licenses.ts
├── src/ # ── Frontend (React + TypeScript) ──
│ ├── App.tsx # Root component; routes edit vs. perform vs. display
│ ├── show.ts # Domain types (Show/Section/Cue) + helpers + mock
│ ├── components/ # Feature components
│ │ ├── ui/ # shadcn/ui primitives (CLI-managed)
│ │ ├── atoms/ # Small reusable components
│ │ ├── perform-mode/ # Perform mode view, toolbar, cue table
│ │ └── display/ # Live display window
│ ├── store/ # Zustand slices (show, mode, perform, import)
│ ├── hooks/ # use-file-actions, use-mobile
│ ├── lib/ # tauri bindings, events, window, utils
│ ├── providers/ # ThemeProvider
│ └── generated/ # Build output (gitignored)
├── src-tauri/ # ── Tauri app shell (package "nque") ──
│ ├── src/lib.rs # App builder, invoke_handler, display windows
│ ├── src/commands.rs # import_pdf_show command
│ ├── tauri.conf.json # Tauri configuration
│ └── capabilities/ # Tauri 2 capabilities
└── crates/ # ── Backend domain crates ──
├── shared/ # Cross-crate pure utilities
├── ocr/ # Ingest: PDF → text (native first, OCR fallback)
├── classify/ # Classify: line-level heading/direction/dialog
└── show/ # Construct + filter; Show types, file I/O, commands
Where things live
| Concern | Location |
|---|---|
| UI screens & components | src/components/ |
| Global state (Zustand) | src/store/ |
| Tauri command wrappers (TS) | src/lib/tauri.ts |
| Tauri event names (TS) | src/lib/events.ts |
| Rust command registration | src-tauri/src/lib.rs |
| PDF import command | src-tauri/src/commands.rs |
| OCR / PDF text extraction | crates/ocr/src/ |
| Line classification rules | crates/classify/src/rules.rs |
| Show construction & filtering | crates/show/src/pipeline.rs, filter.rs, parse.rs |
| Show file format & schema | crates/show/src/file.rs, schemas/show.schema.json |
Related reading: