Skip to content

fix(dashboard): make API Manager key table usable on mobile - #4556

Merged
diegosouzapw merged 3 commits into
cheaper-inference:release/v3.8.33from
janeza2:fix/api-manager-mobile-responsive
Jun 21, 2026
Merged

diegosouzapw merged 3 commits into
cheaper-inference:release/v3.8.33from
janeza2:fix/api-manager-mobile-responsive

Conversation

@janeza2

@janeza2 janeza2 commented Jun 21, 2026

Copy link
Copy Markdown
Contributor

Summary

The registered API keys table on /dashboard/api-manager was unusable on small screens:

  • The 12-column grid collapsed and squeezed content (long key names, badges, costs) into overlapping unreadable rows
  • All action icons (view costs, regenerate, edit permissions, delete) were gated behind hover, which does not exist on touch devices
  • The "key only available at creation" info lock was also hover-gated
  • There was no horizontal scroll fallback

Changes

File Change
ApiManagerPageClient.tsx Wrap both key tables (normal + quota) in overflow-x-auto so they can be scrolled sideways instead of collapsing. Add min-w-[760px] to header + row so columns keep their intended widths and the scroll is meaningful. Switch all hover-gated icons (cost / regenerate / permissions / delete + the "key only available at creation" info lock) to opacity-100 sm:opacity-0 sm:group-hover:opacity-100, so they are always visible on mobile (<sm) while keeping the desktop hover-reveal behavior.

Behavior

Screen Before After
Desktop (>=640px) Hover to reveal icons Same — unchanged (sm: keeps hover-reveal)
Mobile / tablet (<640px) Icons hidden, table collapsed, no scroll Icons always visible, table scrolls horizontally

Verification

  • All 47 api-manager unit tests pass (api-manager-page-static, api-manager-quota-keys-section, api-manager-filters, etc.)
  • No new TypeScript or ESLint errors
  • any budget unchanged (no any introduced)
  • Backward compatible: desktop behavior preserved via sm: prefix

Test plan

  • Open /dashboard/api-manager on a narrow viewport (<640px) — confirm the table now scrolls horizontally instead of collapsing, and that view-costs / regenerate / permissions / delete icons are visible without hovering.
  • Open the same page on desktop (>=640px) — confirm the action icons still hide by default and reveal on row hover (no regression).
  • Verify the same behavior for the Quota keys section (it shares the same row component).

The registered API keys table on /dashboard/api-manager was unusable on
small screens: the 12-column grid collapsed and squeezed content, action
icons (view costs, regenerate, permissions, delete) were hidden behind
hover which doesn't exist on touch, and there was no horizontal scroll.

- Wrap both key tables (normal + quota) in overflow-x-auto so they can
  be scrolled sideways instead of collapsing.
- Add min-w-[760px] to header + row so columns keep their intended widths
  and the scroll is meaningful.
- Switch all hover-gated icons (cost/regenerate/permissions/delete + the
  'key only available at creation' info lock) to opacity-100 on mobile
  and keep the hover-reveal behavior on >=sm screens.

Co-authored-by: Cursor <cursoragent@cursor.com>
@janeza2
janeza2 requested a review from diegosouzapw as a code owner June 21, 2026 20:19
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@diegosouzapw
diegosouzapw changed the base branch from main to release/v3.8.33 June 21, 2026 21:19
Diego Rodrigues de Sa e Souza and others added 2 commits June 21, 2026 18:23
…->2983

Mobile-responsive table fix adds a horizontal-scroll wrapper + min-w + mobile-visible
action buttons (+4 lines). Baseline bumped to match (wc+1). Fast-gate PR->release does
not run check:file-size; reconciled in-branch per Hard Rule cheaper-inference#9.

Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>
@diegosouzapw

Copy link
Copy Markdown
Collaborator

Thanks @janeza2! The horizontal-scroll wrapper + min-w-[760px] and mobile-visible action buttons (opacity-100 sm:opacity-0) make the key table usable on small screens without affecting desktop. I pushed one tiny follow-up bumping the ApiManagerPageClient.tsx file-size baseline (2979→2983) to match the +4 lines, since the fast-gate doesn't run that check. Merging into release/v3.8.33. 🙏

@diegosouzapw
diegosouzapw merged commit 9447de0 into cheaper-inference:release/v3.8.33 Jun 21, 2026
3 checks passed
@diegosouzapw diegosouzapw mentioned this pull request Jun 22, 2026
tkgo11 pushed a commit to tkgo11/OmniRoute that referenced this pull request Sep 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants