diff --git a/.specify/memory/constitution.md b/.specify/memory/constitution.md index dd44daa..b0ba416 100644 --- a/.specify/memory/constitution.md +++ b/.specify/memory/constitution.md @@ -1,15 +1,17 @@ @@ -72,6 +74,12 @@ ### Data Minimization & Safe Logging - Payload-heavy content belongs in immutable snapshots/backup storage, not Inventory. - Logs MUST not contain secrets/tokens; monitoring MUST rely on run records + error codes (not log parsing). +### Badge Semantics Are Centralized (BADGE-001) +- Status-like badges (status/outcome/severity/risk/availability/boolean signals) MUST render via `BadgeCatalog` / `BadgeRenderer`. +- Filament resources/pages/widgets/views MUST NOT introduce ad-hoc status-like badge mappings (use a `BadgeDomain` instead). +- Introducing or changing a status-like value MUST include updating the relevant badge mapper and adding/updating tests for the mapping. +- Tag/category chips (e.g., type/platform/environment) are not status-like and are not governed by BADGE-001. + ### Spec-First Workflow - For any feature that changes runtime behavior, include or update `specs/-/` with `spec.md`, `plan.md`, `tasks.md`, and `checklists/requirements.md`. - New work branches from `dev` using `feat/-` (spec + code in the same PR). @@ -96,4 +104,4 @@ ### Versioning Policy (SemVer) - **MINOR**: new principle/section or materially expanded guidance. - **MAJOR**: removing/redefining principles in a backward-incompatible way. -**Version**: 1.2.1 | **Ratified**: 2026-01-03 | **Last Amended**: 2026-01-17 +**Version**: 1.3.0 | **Ratified**: 2026-01-03 | **Last Amended**: 2026-01-22 diff --git a/.specify/templates/plan-template.md b/.specify/templates/plan-template.md index 436949c..f30b962 100644 --- a/.specify/templates/plan-template.md +++ b/.specify/templates/plan-template.md @@ -39,6 +39,7 @@ ## Constitution Check - Run observability: long-running/remote/queued work creates/reuses `OperationRun`; start surfaces enqueue-only; Monitoring is DB-only; DB-only <2s actions may skip runs but security-relevant ones still audit-log - Automation: queued/scheduled ops use locks + idempotency; handle 429/503 with backoff+jitter - Data minimization: Inventory stores metadata + whitelisted meta; logs contain no secrets/tokens +- Badge semantics (BADGE-001): status-like badges use `BadgeCatalog` / `BadgeRenderer`; no ad-hoc mappings; new values include tests ## Project Structure diff --git a/.specify/templates/spec-template.md b/.specify/templates/spec-template.md index c1867e3..d39188a 100644 --- a/.specify/templates/spec-template.md +++ b/.specify/templates/spec-template.md @@ -82,6 +82,9 @@ ## Requirements *(mandatory)* (preview/confirmation/audit), tenant isolation, run observability (`OperationRun` type/identity/visibility), and tests. If security-relevant DB-only actions intentionally skip `OperationRun`, the spec MUST describe `AuditLog` entries. +**Constitution alignment (BADGE-001):** If this feature changes status-like badges (status/outcome/severity/risk/availability/boolean), +the spec MUST describe how badge semantics stay centralized (no ad-hoc mappings) and which tests cover any new/changed values. +