fix(team-members): render load failures distinctly (SH-324)

This commit is contained in:
Codex Review Integration 2026-09-16 22:38:53 -03:00
parent de79daefb1
commit 1df3e5d292
2 changed files with 17 additions and 1 deletions

View file

@ -27,6 +27,7 @@ export function TeamMembersTable({
}: {
rows: TeamMemberListItem[];
isLoading: boolean;
hasError: boolean;
tab: "active" | "inactive";
onOpen: (member: TeamMemberListItem) => void;
}) {
@ -52,6 +53,15 @@ export function TeamMembersTable({
<CircularProgress size={28} />
</TableCell>
</TableRow>
) : hasError ? (
<TableRow>
<TableCell colSpan={8} align="center" sx={{ py: 8 }}>
<Typography sx={{ fontWeight: 600 }}>Unable to load team members</Typography>
<Typography variant="body2" color="text.secondary">
Check your connection and try again.
</Typography>
</TableCell>
</TableRow>
) : rows.length === 0 ? (
<TableRow>
<TableCell colSpan={8} align="center" sx={{ py: 8 }}>

View file

@ -152,7 +152,13 @@ export default function TeamMembersListPage() {
)}
<Box sx={{ flex: 1, overflow: "auto", p: 2 }}>
<TeamMembersTable rows={rows} isLoading={isLoading} tab={tab} onOpen={setSelectedMember} />
<TeamMembersTable
rows={rows}
isLoading={isLoading}
hasError={Boolean(error)}
tab={tab}
onOpen={setSelectedMember}
/>
</Box>
<Stack