Follow-up to83837adaaddressing the critical-review feedback: - Duplicate ConditionKind type consolidated: the one in api/queries/alertRules.ts (which was nullable — wrong) is gone; single source of truth lives in this module. - Module moved out of api/ into pages/Alerts/ where it belongs. api/ is the data layer; labels + hide lists are view-layer concerns. - Hidden values formalised: Comparator.EQ and JvmAggregation.LATEST are intentionally not surfaced in dropdowns (noisy / wrong feature boundary, see in-file comments). They remain in the type unions so rules that carry those values save/load correctly — we just don't advertise them in the UI. - JvmAggregation declaration order restored to MAX/AVG/MIN (matches what users saw before83837ada). LATEST declared last; hidden. - Snapshot tests for every visible *_OPTIONS array — reviewer signal in future PRs when a backend enum change or hide-list edit silently reshapes the dropdown. - `toOptions` gains a JSDoc noting that label-map declaration order is load-bearing (ES2015 Object.keys insertion-order guarantee). - **Honest about the springdoc schema quirk**: the generated polymorphic condition types resolve to `never` at the TypeScript level (two conflicting `kind` discriminators — the class-name literal and the Jackson enum — intersect to never), which silently defeated `Record<T, string>` exhaustiveness. The previous commit's "schema-derived enums" claim was accurate only for the flat-field enums (ConditionKind, Severity, TargetKind); condition-specific enums (RouteMetric, Comparator, JvmAggregation, ExchangeFireMode) were silently `never`. Those are now declared as hand-written string-literal unions with a top-of-file comment spelling out the issue and the regen-and-compare workflow. Real upstream fix is a backend-side adjustment to how springdoc emits polymorphic `@JsonSubTypes` — out of scope for this phase. Verified: ui build green, 56/56 vitest pass (49 pre-existing + 7 new enum snapshots). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Cameleer UI
React SPA built with @cameleer/design-system v0.1.28, TanStack Query, and Zustand.
Development
npm install
npm run dev
By default the dev server proxies /api/* to http://localhost:8081. To proxy to a remote server instead:
VITE_API_TARGET=http://192.168.50.86:30081 npm run dev
No CORS issues — Vite's proxy makes API calls server-side.
Build
npm run build
API Types
Regenerate TypeScript types from a running backend:
npm run generate-api # Requires backend running on :8081
Key Features
- Composable sidebar with accordion behavior (Applications / Starred / Admin sections)
- Context-aware cmd-k search: shows apps/routes/exchanges on operational pages, users/groups/roles on admin pages
- LIVE mode toggle: when ON, queries poll at intervals (5s-30s); when OFF, sidebar clicks trigger manual refresh
- Route control bar with state-aware buttons (start/stop/suspend/resume) and confirmation dialogs
- Event-type icons in agent timeline with severity-based coloring