mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-07 08:26:10 +00:00
* refactor(ui): migrate the regenerate key and team member forms to react-hook-form and shadcn Moves RegenerateKeyModal and EditMembership off antd Form onto react-hook-form plus the shadcn field kit, and onto semantic color tokens so both are dark-mode ready. The antd Modal shell and Alert stay as they are. The submitted payload is unchanged on both. Payload construction is extracted into regenerateKeyPayload.ts and memberFormValues.ts and unit tested there, and each component keeps an integration test that was written against the antd original and proven green before any source changed. RegenerateKeyModal keeps antd InputNumber's precision=2 rounding of max_budget. The rounding is string-exact rather than float based, so 1.005 still submits as 1.01 the way antd did. Submission stays on the modal footer button, so Enter still does nothing. EditMembership omits noValidate. Its numeric fields are already native number inputs carrying min and step, so browser constraint validation blocks a bad submit today and continues to. That is pinned by tests. * fix(ui): accept null-valued fields the proxy returns for keys and members The proxy returns null rather than omitting the key for an unset key_alias, user_email or user_id. antd had no schema and forwarded whatever came back, but z.string().optional() accepts undefined and rejects null, so regenerating an alias-less key or editing a member with no email failed validation and silently never submitted. Widen those three fields to nullish() and pin each with a test that seeds null and submits without touching the field. Each test passes against the pre-migration antd component and failed against the migration before this commit, and the payloads it asserts are the ones antd put on the wire. |
||
|---|---|---|
| .. | ||
| litellm-dashboard | ||
| Dockerfile | ||
| nginx.conf | ||