Commit Graph
6 Commits
Author SHA1 Message Date
James Cox dc2c1ec395 chore(frontend-lint): tune stylelint for Angular and legacy SCSS patterns
- Stylelint configuration:
  - ignore Angular-specific pseudo-elements such as `::host`
  - stop flagging underscore-prefixed SCSS partial imports that match the existing layout partial convention
  - drop empty-source and precision-only checks that were adding noise without improving maintainability
- Lint surface:
  - keep the higher-signal duplicate-selector, naming, and font-family checks in place
  - reduce the manual stylelint queue from 62 findings to 10 actionable errors

- Validation:
  - `just ui stylelint` now reports 10 errors after the config update
2026-04-22 17:26:41 -04:00
James Cox e2a8e6a1d6 style(frontend): apply the first eslint autofix pass
- ESLint autofixes:
  - apply the safe automatic ESLint rewrites without taking on manual typing, accessibility, or Angular inject migrations
  - normalize `==` and `!=` comparisons in templates, convert `Array<T>` to `T[]`, and tighten a small set of `let` declarations to `const`
  - remove `autofocus` attributes that ESLint can rewrite mechanically
- Cleanup scope:
  - keep this pass limited to files changed by `ng lint --fix` so the remaining 702 manual ESLint findings stay isolated for later review

- Validation:
  - `env YARN_ENABLE_GLOBAL_CACHE=0 YARN_CACHE_FOLDER=../.yarn/cache corepack yarn lint:eslint --fix` reduced the remaining ESLint count from 721 to 702 before stopping on non-fixable issues
2026-04-22 17:26:40 -04:00
James Cox 34fc60050f style(frontend): apply the first stylelint autofix pass
- SCSS autofixes:
  - apply Stylelint's automatic fixes across the frontend stylesheet set without touching TypeScript or Angular templates
  - normalize zero values, shorthand properties, selector casing, and similar mechanical stylesheet rewrites
  - keep this pass limited to autofix output so the remaining manual stylelint findings stay isolated for later review
- Cleanup scope:
  - update component SCSS and shared layout styles only where Stylelint could rewrite them mechanically
  - leave the unresolved manual stylelint findings in place for a smaller follow-up pass

- Validation:
  - `just ui stylelint-fix` reduced the remaining stylelint count from 140 to 62 before stopping on non-fixable issues
2026-04-22 17:26:40 -04:00
James Cox cef000d425 chore(frontend-lint): add local typecheck and stylelint commands
- Frontend package scripts:
  - add a dedicated `typecheck` script for `tsc --noEmit`
  - split ESLint into `lint:eslint` and add `lint:styles` plus `lint:styles:fix`
  - keep the top-level `lint` script as a combined frontend lint entrypoint
  - restore `postcss` so the frontend dependency graph satisfies the peer requirements used by Angular build tooling and Stylelint
- Frontend command surface:
  - add `typecheck`, `stylelint`, and `stylelint-fix` recipes to `frontend/Justfile`
  - expand the frontend `check` and `ci-check` recipes to include typechecking, stylesheet linting, and a production build
- Stylelint configuration:
  - add `frontend/stylelint.config.js` using the standard SCSS config as the base
  - pare back the noisiest formatting and notation rules so the initial lint layer stays actionable instead of forcing a repo-wide SCSS rewrite
- Lockfile:
  - refresh `frontend/yarn.lock` for the new frontend lint dependencies

- Validation:
  - `just ui install`
  - `just ui typecheck`
  - `just ui stylelint` currently reports 140 errors, with 76 marked autofixable
2026-04-22 17:26:40 -04:00
James Cox 4855f36d46 build(yarn): migrate frontend and release tooling to yarn 4
- Frontend package management:
  - add a repo-root `.yarnrc.yml` that pins Yarn to the `node-modules` linker with a local cache
  - add the modern Yarn package manager declaration to `frontend/package.json`
  - replace the frontend npm lockfile with `frontend/yarn.lock`
  - move the frontend Just recipes to Corepack-managed Yarn commands for install, audit, build, test, and lint
  - run the production build in CI-style mode so non-interactive Yarn builds behave consistently
- Release automation:
  - add the modern Yarn package manager declaration to `tools/release/package.json`
  - replace the release tooling npm lockfile with `tools/release/yarn.lock`
  - switch the release Just recipes from `npm` and `npx` to Corepack-managed Yarn scripts
- CI and local runtime wiring:
  - switch the frontend and release GitHub Actions caches from npm lockfiles to Yarn lockfiles
  - update the root `doctor` output and contributor prerequisites to report Yarn and Corepack instead of npm
  - update the dev compose UI container to Node 24 with immutable Yarn installs
  - restore the Docker frontend build stage to install and build through Yarn, including the shared cache path
- Repository hygiene:
  - ignore the repo-local Yarn cache and per-project Yarn state directories created by modern Yarn installs

- Validation:
  - `just ui install-ci`
  - `just release install`
  - `just ui build`
  - `just image-build linux/amd64 codex-yarn-port-test` was not runnable because the local Docker daemon was unavailable
2026-04-22 17:26:40 -04:00
James Cox 874b013f75 refactor(frontend): rename booklore-ui to frontend
- Frontend path:
  - rename the tracked Angular app tree from `booklore-ui/` to `frontend/`
  - preserve file contents during the move so this commit stays focused on the path change itself
- Frontend docs:
  - update the moved frontend README and contribution guide where they refer to the renamed folder
  - keep those edits limited to path references introduced by the directory rename
2026-04-22 17:26:39 -04:00