Check in the PM product requirements, refreshed QA acceptance evidence, shared execution split plans, and current-phase status notes so the repo matches the current delivery baseline. Co-Authored-By: Paperclip <noreply@paperclip.ing>
1.7 KiB
1.7 KiB
HAC-22 DB Switcher Hardening
Date: 2026-03-31 UTC
Owner: Senior Frontend Engineer
Issue: HAC-22
Scope: desktop-v1 user-visible frontend hardening only
Context
apps/desktopalready ships a visible DB switcher, but the current UI only renders four fixed choices:db0,db1,db2, anddb5.- Current product scope already includes one active standalone Redis connection, explicit DB context, and DB-scoped browse / inspect / command flows.
- The hardcoded four-item list is weaker than the current product boundary and makes shell-level verification less representative for operators who need to move across common DB indexes.
Decision
- Do not expand product scope or alter backend contracts.
- Keep the existing rail placement and interaction model for the DB switcher.
- Widen the visible DB switcher to a predictable default operator range and ensure the currently active DB remains selectable even when it falls outside the default range.
Planned Implementation
- Add a shared frontend helper that returns DB labels for the switcher.
- Default the visible range to
db0throughdb15. - If the active DB falls outside that range, inject it into the visible list and keep the options numerically ordered.
- Cover the helper with focused Vitest cases.
- Update shared frontend and QA docs so runbooks no longer imply a four-item-only DB switcher.
Acceptance
- The visible DB switcher no longer depends on a four-item hardcoded list.
- Operators can select common DB indexes from
db0throughdb15without editing connection drafts. - An active DB outside the default range still appears in the switcher and stays selectable.
pnpm --filter @redis-gui/desktop testandpnpm run desktop:buildremain green.