Files
grimmory/booklore-ui/CONTRIBUTING.md
T
James Cox 69d50d4fb5 feat(devex): add a unified just command surface
- Command surface:
  - add a root `Justfile` with namespaced `api`, `ui`, and `release` modules so humans and agents can use the same entrypoints from the repo root
  - add project-local Justfiles for `booklore-api`, `booklore-ui`, and `tools/release` so each area remains self-contained and can still be driven from inside its own directory
  - standardize local developer workflows around `just check`, `just test`, `just api run`, `just ui dev`, `just db-up`, and `just image-build`

- Workflow integration:
  - update the reusable test suite workflow to install `just` and run backend and frontend CI steps through the Justfiles instead of hardcoded shell commands
  - update the semantic-release workflows to install `just` and invoke release tooling via `just release install`, `just release preview`, and `just release run`
  - keep the Docker image publication workflows on the native Docker actions while moving the project-command logic into the canonical command surface

- Documentation:
  - split backend and frontend implementation guidance into `booklore-api/README.md`, `booklore-api/CONTRIBUTING.md`, `booklore-ui/README.md`, and `booklore-ui/CONTRIBUTING.md`
  - simplify the top-level `README.md` and `CONTRIBUTING.md` so they stay focused on overview, policy, and navigation while pointing to component-specific guides for deeper detail
  - align contributor-facing examples on the `just` interface instead of mixing ad hoc Gradle, npm, Docker, and Compose commands

- Developer environment:
  - add `mise.toml` to pin the expected Java and Node toolchain versions for local work
  - switch the development Compose defaults from the old Booklore database values to Grimmory-oriented defaults
  - keep the command layout ready for a future API/UI split without forcing that packaging change yet
2026-04-22 17:26:35 -04:00

67 lines
2.3 KiB
Markdown

# Contributing to Grimmory UI
This document covers frontend-specific development and review expectations for `booklore-ui`.
For repository-wide contribution policy, branch strategy, PR requirements, and release semantics, start with [../CONTRIBUTING.md](../CONTRIBUTING.md).
## Preferred Command Surface
Use [`Justfile`](Justfile) when possible:
```bash
just # List frontend recipes
just install # Install or update dependencies for local development
just install-ci # Install dependencies exactly as CI does
just dev # Start the local dev server
just test # Run frontend tests
just check # Run the standard local verification pass
just lint # Run the frontend linter
just build # Build the production bundle
```
From the repository root, the same recipes are available through the `ui` namespace:
```bash
just ui install
just ui install-ci
just ui dev
just ui test
just ui check
just ui lint
```
## Frontend Conventions
- Follow the Angular style guide.
- All components are standalone. Do not add NgModules.
- Use `inject()` for dependency injection instead of constructor injection.
- Prefer PrimeNG components and project styling patterns over custom one-off UI primitives.
- Use SCSS for styling and keep the visual language consistent with the existing application.
- Use Transloco for user-facing strings. New strings belong under `src/i18n/`.
- Keep UI changes responsive for desktop and mobile layouts.
- Tests should use Vitest, not Karma or Jasmine.
## i18n and UI Copy
- Update all relevant locale files when adding or renaming translation keys.
- Keep translation-key changes separate from bulk JSON reformatting whenever practical.
- Prefer Grimmory naming for UI-visible labels and keys, while preserving compatibility shims only when they are still required by existing backend or migration behavior.
## Validation Before Opening a PR
Run the frontend checks locally before sending a PR:
```bash
just install
just check
```
If your change affects layout, responsive behavior, or interaction design, also run the full stack locally and capture screenshots or a short screen recording for the PR.
If you specifically want to mirror the stricter CI dependency policy, run:
```bash
just install-ci
just ci-check
```