13 Commits

Author SHA1 Message Date
danijel-lf
d71e30bb3a fix(web-next): support USE_DEV_SEED=false and load root .env globally
- Add USE_DEV_SEED=false branch to bindAll dispatcher
- Use dotenv-cli to inject root .env into all Turbo tasks
- Add globalDependencies for .env cache invalidation
2026-05-26 14:13:31 +02:00
7c7a65f7e3 feat: pnpm fallow + fallow:audit scripts, turbo task entry 2026-05-13 08:51:45 +02:00
dfd6e1c3cc feat: wire pnpm conformance script + turbo task 2026-05-12 23:58:10 +02:00
131efd5d2f feat(core-audit): admin tRPC procedure for eraseSubject
Adds auditProcedure (adminOnly middleware + defineErrorMiddleware([])) in
core-audit/src/integrations/api/procedures.ts. Adds createAuditRouter that
captures an IAuditLog and exposes a single eraseSubject mutation with zod
input validation. Non-admins receive FORBIDDEN. Barrel re-exports
pseudonymize, createAuditErasureHook, createAuditRouter, auditRouter,
AuditRouter, auditProcedure, AdminTrpcUser. Adds AUDIT_PSEUDONYM_SALT to
turbo.json globalEnv to clear lint warnings.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 16:25:09 +02:00
a98e41d080 chore: workspace green check (Task 56)
Three issues uncovered by the full pnpm typecheck/test/boundaries pass
and resolved here:

- core-testing was importing IEventBus / IJobQueue from core-events /
  core-shared, creating two boundary violations (tooling → core) and a
  build-graph cycle. Inlined the type aliases (mirroring how
  RecordingTracer / RecordingLogger handle ITracer / ILogger).
  recording-event-bus.test.ts replaces defineEvent() with an inline
  descriptor literal so no runtime import is needed either. core-events
  and core-shared are removed from core-testing dependencies.

- turbo.json: typecheck and test no longer dependsOn ^typecheck / ^build.
  Each package's tsc / vitest resolves cross-package types via
  node_modules independently, and dropping the topological dep avoids the
  spurious cycle warning that appeared once core-testing started
  importing core-events / core-shared.

- turbo.json: feature.dependencies.allow gains "feature". Cross-feature
  event flow (ADR-015) requires a consumer feature to import the
  publisher's event contract directly. The dangerous form (importing
  the publisher's handler/use-case/repo) is still blocked by E1's
  no-handler-reexport ESLint rule and the missing public exports.

- TaskConfig<"slug-string"> → TaskConfig<{ input; output }> in the gen
  job task template (and the shipped send-welcome-email.task.ts) since
  runtime-generated slugs aren't keys of TypedJobs['tasks'].
2026-05-08 17:21:47 +02:00
d4b23cf35d chore(turbo): declare instrumentation env vars in globalEnv
Adds WEB_NEXT_SENTRY_DSN, NEXT_PUBLIC_WEB_NEXT_SENTRY_DSN, CMS_SENTRY_DSN,
WEB_TANSTACK_SENTRY_DSN, VITE_WEB_TANSTACK_SENTRY_DSN, VITE_GIT_COMMIT_SHA,
SENTRY_AUTH_TOKEN, SENTRY_ORG, SENTRY_PROJECT_{WEB_NEXT,CMS,WEB_TANSTACK},
SENTRY_TRACES_SAMPLE_RATE, SENTRY_ENVIRONMENT, VERCEL_GIT_COMMIT_SHA,
NEXT_PUBLIC_VERCEL_GIT_COMMIT_SHA, and VERCEL_ENV.

Clears turbo/no-undeclared-env-vars warnings on init-server.ts /
init-client.ts / bind-production.ts / next.config.mjs.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-07 20:31:52 +02:00
61dde18b53 chore(turbo): declare USE_DEV_SEED in globalEnv
Earlier commit 74b88f7 attempted this but the Edit failed silently
without a prior Read. ESLint's turbo/no-undeclared-env-vars rule was
still flagging the warning.
2026-05-06 19:21:24 +02:00
bd50a67662 feat(storybook): wire @storybook/test-runner for story smoke tests
Every story is now executed as a smoke test (mount + no console errors)
via @storybook/test-runner. New script: pnpm test:stories runs
build-storybook then test-storybook against the static build.

Spec: §6.8

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-05 19:10:41 +02:00
eb55a698f3 fix(turbo-boundaries): resolve 32 violations
- Re-tag core-trpc as core-composition (transitively reaches features
  through core-api's AppRouter type) and allow core-composition packages
  to depend on other core-composition packages in turbo.json
- Add @payloadcms/richtext-lexical as direct dep of apps/cms (was pulled
  transitively via core-cms; Payload's importMap.js imports it directly)
- Add @storybook/react as devDep of core-ui and apps/storybook (stories
  belong with components per Atomic Design)
- Update apps/storybook .storybook/{main,preview}.ts to point at
  packages/core-ui (was still referencing deleted packages/ui) and export
  CSS via package exports instead of direct file import
- Add JSDoc type annotation to Payload-generated importMap.js to suppress
  TypeScript's TS2742 error from complex inferred types
- Add storybook-static to eslint ignores in core-eslint base config

pnpm turbo boundaries now reports zero violations.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-05 12:12:27 +02:00
9899e213ca build(turbo): add boundaries enforcement matching ESLint dependency graph
Per-package tags + root boundaries block now enforce the same three-tag
model as eslint-plugin-boundaries:
- app          → may depend on: app, core, core-composition, feature, tooling
- feature      → may depend on: core, tooling
- core         → may depend on: core, core-composition, tooling
- core-composition (core-api, core-cms) → may depend on: core, feature, tooling
- tooling (core-eslint, core-typescript) → may depend on: tooling

Tags applied: 4 apps (app), 3 core foundation packages (core),
2 core composition packages (core-composition), 5 features (feature),
2 tooling packages (tooling). All test suites pass.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-05 11:59:44 +02:00
3856701252 fix(lint): exempt next-env.d.ts triple-slash + declare globalEnv vars
next-env.d.ts is a generated file using triple-slash references that
TypeScript requires. ESLint exemption added in apps/web-next config only.
Also declare CI, DATABASE_URL, PAYLOAD_SECRET, NODE_ENV in turbo.json
globalEnv so turbo/no-undeclared-env-vars stops warning.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-05 10:02:33 +02:00
520749c4e3 build: add root test:e2e task aggregating per-app Playwright suites 2026-05-05 09:29:37 +02:00
6cff55d6d3 feat: scaffold root workspace files (Turborepo + pnpm) 2026-04-06 14:04:41 +02:00