Fix label association and error handling in user override select

What does this MR do and why?

Follow-up fixes from the review of !253351 (merged), addressing the three deferred discussions tracked in https://gitlab.com/gitlab-org/gitlab/-/issues/628085

References

Screenshots or screen recordings

The only visible UI change is a danger GlAlert that appears above the user select when a search request fails (previously the failure was silent). Screenshots could not be captured in this development environment; the error state can be viewed in the added WithSearchError Storybook story instead.

No error Error
Screenshot_2026-09-10_at_17.23.36 Screenshot_2026-09-11_at_01.23.26

How to set up and validate locally

  1. Run the specs:
    yarn jest ee/spec/frontend/usage_quotas/wallet_agnostic_credits_dashboard/credit_caps
  2. Run Storybook with yarn storybook, open EE / Usage quotas / Wallet agnostic credits dashboard / Credit caps / User override select, and check the Default and WithSearchError stories.
  3. On the GitLab Credits dashboard, open the Add override modal and confirm clicking the Users label focuses the token selector input (label/for association now resolves to the input's id).

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Kos Palchyk

Merge request reports

Loading
Loading