Files
tanabata/CLAUDE.md
T
H1K0 28f5b5d150 docs(project): sync docs with code and bump to 3.0.0
Prepare the 3.0.0 release:
- Bump the version in openapi.yaml and frontend/package.json to 3.0.0.
- Document the existing GET /health endpoint in openapi.yaml (served at the
  root, outside /api/v1) and refine the auth note.
- Add docs/REQUIREMENTS.md (product requirements, in English) and
  docs/ARCHITECTURE.md (system overview); remove the old Russian
  docs/Описание.md.
- Rewrite GO_PROJECT_STRUCTURE.md and FRONTEND_STRUCTURE.md to match the
  current code (dedup CLI, imagehash, real components/stores, Tailwind v4).
- Fix stale counts and references in CLAUDE.md and link the new docs from
  README.md.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-03 08:35:16 +03:00

2.0 KiB
Raw Blame History

Tanabata File Manager

Multi-user, tag-based web file manager for images and video.

Architecture

Monorepo: backend/ (Go) + frontend/ (SvelteKit).

  • Backend: Go + Gin + pgx v5 + goose migrations. Clean Architecture.
  • Frontend: SvelteKit SPA + Tailwind CSS + CSS custom properties.
  • DB: PostgreSQL 14+.
  • Auth: JWT Bearer tokens.

Key documents (read before coding)

  • openapi.yaml — full REST API specification (44 paths, 67 operations)
  • docs/REQUIREMENTS.md — product requirements (functional + non-functional)
  • docs/ARCHITECTURE.md — system architecture overview (layers, data flow, decisions)
  • docs/GO_PROJECT_STRUCTURE.md — backend architecture, layer rules, DI pattern
  • docs/FRONTEND_STRUCTURE.md — frontend architecture, CSS approach, API client
  • backend/migrations/ — database schema as goose migrations (4 schemas, 19 tables)

Design reference

Visual design tokens for the frontend (carried over from the previous Python/Flask version):

  • Color palette: #312F45 (bg), #9592B5 (accent), #444455 (tag default), #111118 (elevated)
  • Font: Epilogue (variable weight)
  • Dark theme is primary
  • Mobile-first layout with bottom navbar
  • 160×160 thumbnail grid for files
  • Colored tag pills
  • Floating selection bar for multi-select

Backend commands

cd backend
go run ./cmd/server          # run dev server
go test ./...                # run all tests

Frontend commands

cd frontend
npm run dev                  # vite dev server
npm run build                # production build
npm run generate:types       # regenerate API types from openapi.yaml

Conventions

  • Go: gofmt, no global state, context.Context as first param in all service methods
  • TypeScript: strict mode, named exports
  • SQL: snake_case, all migrations via goose
  • API errors: { code, message, details? }
  • Git: conventional commits with scope — type(scope): message
    • (backend) for Go backend code
    • (frontend) for SvelteKit/TypeScript code
    • (project) for root-level files (.gitignore, docs, structure)