Skip to content

fix: PAT project list and assorted SDK view fixes#1633

Merged
rohanchkrabrty merged 9 commits into
mainfrom
fix-pat-project-logic
May 20, 2026
Merged

fix: PAT project list and assorted SDK view fixes#1633
rohanchkrabrty merged 9 commits into
mainfrom
fix-pat-project-logic

Conversation

@rohanchkrabrty
Copy link
Copy Markdown
Contributor

Summary

  • Switch PAT form and details views to listProjectsByCurrentUser (with nonInherited: false) so the project picker reflects the caller's actual access; stale scope project IDs are filtered out before rendering.
  • Add project member management flows (member list, add/remove, role assignment) and refresh project/team detail views.
  • Normalize empty-state icons across views-new — fixed 40×40 image with a shared emptyStateIcon flex-center class in place of width="100%".
  • Polish dialog and alert-dialog styles; drop redundant footer style overrides.
  • Update PAT roles to use the new role RPC and fix the SDK action menu behaviour.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 20, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
frontier Ready Ready Preview, Comment May 20, 2026 7:47am

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 20, 2026

Warning

Rate limit exceeded

@rohanchkrabrty has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 17 minutes and 33 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 6217674c-b127-4be9-a185-1c1f38cf9b07

📥 Commits

Reviewing files that changed from the base of the PR and between e5105b9 and a80f7d9.

📒 Files selected for processing (8)
  • web/sdk/react/views-new/pat/components/pat-form-dialog.tsx
  • web/sdk/react/views-new/pat/pat-details-view.tsx
  • web/sdk/react/views-new/pat/pat-view.module.css
  • web/sdk/react/views-new/pat/pat-view.tsx
  • web/sdk/react/views-new/projects/projects-view.module.css
  • web/sdk/react/views-new/projects/projects-view.tsx
  • web/sdk/react/views-new/teams/teams-view.module.css
  • web/sdk/react/views-new/teams/teams-view.tsx
📝 Walkthrough

Walkthrough

This PR upgrades the Apsara UI library from rc.6 to rc.8 and modernizes dialog layouts and component behaviors across the codebase, including migrating to the AlertDialog API, removing fixed dialog widths, adding isFetched tracking to data-fetching hooks, refactoring ProjectsView and TeamsView with permission-based rendering and fetch-state-aware skeleton handling, and applying consistent visual patterns for icons and table cell interactions.

Changes

Unified Apsara Upgrade and Layout Modernization

Layer / File(s) Summary
Dependency upgrade and hook enhancements
web/apps/admin/package.json, web/apps/client-demo/package.json, web/sdk/package.json, web/sdk/react/hooks/useOrganizationProjects.ts, web/sdk/react/hooks/useOrganizationTeams.ts
Bumps @raystack/apsara from 1.0.0-rc.6 to 1.0.0-rc.8 across all package.json files; adds isFetched boolean field to both hooks' return values, computed as the logical OR of per-query isFetched states.
Dialog to AlertDialog API migration and content sizing
web/apps/admin/src/components/assign-role.tsx, web/sdk/admin/components/AssignRole.tsx, web/sdk/admin/views/organizations/details/..., web/sdk/admin/views/users/details/..., web/sdk/react/components/image-upload/image-upload.tsx, web/sdk/react/views-new/billing/components/confirm-cycle-switch-dialog.tsx, web/sdk/react/views-new/general/components/delete-organization-dialog.tsx, web/sdk/react/views-new/members/components/..., web/sdk/react/views-new/pat/components/..., web/sdk/react/views-new/plans/components/..., web/sdk/react/views-new/projects/components/..., web/sdk/react/views-new/security/components/..., web/sdk/react/views-new/service-accounts/components/..., web/sdk/react/views-new/sessions/components/..., web/sdk/react/views-new/teams/components/..., web/sdk/react/views-new/tokens/components/add-tokens-dialog.tsx
Systematically removes fixed width props from Dialog/AlertDialog content components; migrates Dialog-based dialogs to AlertDialog with Header/Body/Footer subcomponent structure, including AlertDialog.Title, AlertDialog.Description, and AlertDialog.Close for improved semantic layout.
Member and role management dialog updates
web/sdk/react/views-new/members/components/update-role-dialog.tsx, web/sdk/react/views-new/members/members-view.tsx, web/sdk/react/views-new/members/components/member-columns.tsx
Migrates UpdateRoleDialog to AlertDialog API with handle prop type update; replaces complex policy delete/create flow with direct setOrganizationMemberRole mutation call; updates member column icon from vertical to horizontal dots.
Icon and empty-state visual updates
web/sdk/react/views-new/billing/billing-view.tsx, web/sdk/react/views-new/pat/pat-view.tsx, web/sdk/react/views-new/service-accounts/service-accounts-view.tsx, web/sdk/react/views-new/members/members-view.tsx, web/sdk/react/views-new/teams/team-details-view.tsx, web/sdk/react/views-new/service-accounts/components/service-account-columns.tsx, web/sdk/react/views-new/teams/components/service-account-columns.tsx
Replaces Radix icon components (e.g., ExclamationTriangleIcon, LockClosedIcon) with imported SVG assets for empty states; updates action menu icons from DotsVerticalIcon to DotsHorizontalIcon across member and project tables.
Table and action cell styling with hover effects
web/sdk/react/views-new/projects/components/member-columns.module.css, web/sdk/react/views-new/projects/components/project-columns.module.css, web/sdk/react/views-new/teams/components/member-columns.module.css, web/sdk/react/views-new/teams/components/team-columns.module.css, web/sdk/react/views-new/projects/project-details-view.module.css, web/sdk/react/views-new/teams/team-details-view.module.css, web/sdk/react/views-new/members/members-view.module.css, web/sdk/react/views-new/projects/projects-view.module.css, web/sdk/react/views-new/pat/pat-view.module.css, web/sdk/react/views-new/teams/teams-view.module.css, web/sdk/react/views-new/projects/components/member-columns.tsx, web/sdk/react/views-new/projects/components/project-columns.tsx, web/sdk/react/views-new/teams/components/member-columns.tsx, web/sdk/react/views-new/teams/components/team-columns.tsx
Adds .actionsCell CSS class with hover-reveal pattern (visibility: hidden by default, visibility: visible on tr:hover); applies consistent padding (var(--rs-space-3)) to table row cells; applies styles to action cells in column components.
Form field and dialog content simplification
web/sdk/react/views-new/projects/components/edit-project-dialog.tsx, web/sdk/react/views-new/projects/components/edit-project-dialog.module.css
Removes privacy field from form schema and form initialization; removes privacy radio UI and .radioOptions CSS class; simplifies project editing to title-only.
ProjectsView refactoring with permissions and filtering
web/sdk/react/views-new/projects/projects-view.tsx, web/sdk/react/views-new/projects/projects-view.module.css, web/sdk/react/views-new/projects/components/add-member-menu.tsx
Introduces local showOrgProjects state, derives permission flags (canCreateProject, canListOrgProjects), adds organization filter Select with callback; changes empty-state rendering to early-return branch when hasNoProjects; extracts AddMemberMenuContent component supporting both menu and submenu modes; adds "Add a member" submenu to project dropdown.
TeamsView improvements with fetch state and empty state
web/sdk/react/views-new/teams/teams-view.tsx, web/sdk/react/views-new/teams/teams-view.module.css
Integrates isFetched from useOrganizationTeams to derive showInitialSkeleton state; adds early-return EmptyState when hasNoTeams with conditional team-creation action; updates table header search/filter Select to be conditionally rendered and controlled based on showInitialSkeleton.
PAT and service-account dialogs and views
web/sdk/react/views-new/pat/components/pat-form-dialog.tsx, web/sdk/react/views-new/pat/pat-details-view.tsx, web/sdk/react/views-new/pat/pat-view.tsx, web/sdk/react/views-new/pat/pat-view.module.css, web/sdk/react/views-new/service-accounts/components/delete-service-account-dialog.tsx, web/sdk/react/views-new/service-accounts/components/revoke-token-dialog.tsx, web/sdk/react/views-new/service-accounts/components/revoke-pat-dialog.module.css, web/sdk/react/views-new/service-accounts/components/revoke-token-dialog.module.css
Switches PAT/service-account project queries from listOrganizationProjects to listProjectsByCurrentUser with nonInherited: false; updates empty-state icons and styling; refactors AlertDialog layouts to use Header/Title/Description/Footer subcomponents; removes custom .body CSS styling for bottom border.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

Possibly related PRs

Suggested reviewers

  • rohilsurana
  • rsbh
  • paanSinghCoder
🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@rohanchkrabrty rohanchkrabrty changed the base branch from main to fix-member-update-role May 20, 2026 07:05
@coveralls
Copy link
Copy Markdown

coveralls commented May 20, 2026

Coverage Report for CI Build 26148916078

Coverage remained the same at 42.592%

Details

  • Coverage remained the same as the base build.
  • Patch coverage: No coverable lines changed in this PR.
  • No coverage regressions found.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 37953
Covered Lines: 16165
Line Coverage: 42.59%
Coverage Strength: 11.91 hits per line

💛 - Coveralls

Base automatically changed from fix-member-update-role to main May 20, 2026 07:39
@rohanchkrabrty rohanchkrabrty merged commit f61db6e into main May 20, 2026
8 checks passed
@rohanchkrabrty rohanchkrabrty deleted the fix-pat-project-logic branch May 20, 2026 08:07
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.

3 participants