Skip to content

Members and Roles as two sidebar entries - #301

Merged
samerzughul merged 1 commit into
releases/r10.0from
hamza/feature/team-nav-split
Sep 13, 2026
Merged

samerzughul merged 1 commit into
releases/r10.0from
hamza/feature/team-nav-split

Conversation

@hamzahalq

Copy link
Copy Markdown
Contributor

Closes HAM-57.

Members and Roles were tabs inside one "Team" page gated on users.view OR roles.view. They are now two sidebar entries under Administration, each gated on its own permission — a session holding only one no longer lands on a page whose other half is a dead tab. The role editor's access preview lists them separately for the same reason.

URLs are unchanged (/team/members, /team/roles) since the audit trail deep-links to /team/members/:id; /team stays as a redirect for existing bookmarks.

Verified in the browser, and the 12 tests in team-roles.spec.ts + permissions-enforcement.spec.ts pass.

🤖 Generated with Claude Code

Each is gated on its own permission, so a session holding only one of
them no longer lands on a page whose other half is a dead tab.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Sep 13, 2026 •

Copy link
Copy Markdown

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: simplify9/coderabbit/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Advanced

Run ID: edc64ca3-02d2-4240-b83f-a0ed0b70d930

📥 Commits

Reviewing files that changed from the base of the PR and between 342c216 and 60cbc79.

📒 Files selected for processing (6)
  • SW.Bitween.Web/ClientApp/src/nav.ts
  • SW.Bitween.Web/ClientApp/src/pages/team/MemberDrawer.tsx
  • SW.Bitween.Web/ClientApp/src/pages/team/MembersPage.tsx
  • SW.Bitween.Web/ClientApp/src/pages/team/RolesPage.tsx
  • SW.Bitween.Web/ClientApp/src/pages/team/TeamPage.tsx
  • SW.Bitween.Web/ClientApp/src/router.tsx
💤 Files with no reviewable changes (1)
  • SW.Bitween.Web/ClientApp/src/pages/team/TeamPage.tsx

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.

📜 Recent review details
🔇 Additional comments (5)
SW.Bitween.Web/ClientApp/src/pages/team/MemberDrawer.tsx (1)

15-15: LGTM!

SW.Bitween.Web/ClientApp/src/pages/team/MembersPage.tsx (1)

7-7: LGTM!

Also applies to: 29-29, 71-90

SW.Bitween.Web/ClientApp/src/pages/team/RolesPage.tsx (1)

7-7: LGTM!

Also applies to: 11-11, 16-20, 26-34, 36-40

SW.Bitween.Web/ClientApp/src/router.tsx (1)

46-48: LGTM!

Also applies to: 59-64, 125-150

SW.Bitween.Web/ClientApp/src/nav.ts (1)

17-17: LGTM!

Also applies to: 100-104


📝 Summary

Summary

  • Split Administration navigation into separate Members and Roles entries.
  • Gate each entry with its corresponding permission: users.view or roles.view.
  • Replaced the combined team page with standalone pages and preserved /team redirect behavior.
  • Kept existing URLs, including /team/members and /team/roles.
  • Updated page headers and role access preview labels.

Risk: risk:low

Security-sensitive areas: Client-side permission enforcement and route visibility changed. Members and Roles no longer appear or become accessible through a page containing an unauthorized tab. No backend authorization changes are included.

Test coverage: Verified with 12 tests in team-roles.spec.ts and permissions-enforcement.spec.ts.

Operational concerns: No migration or deployment procedure is required. Existing bookmarks remain supported through /team redirect handling. Rollback requires reverting the navigation and routing changes together.

Walkthrough

The team area now uses separate Members and Roles pages. Routes, permission guards, legacy /team redirection, Administration navigation, page headers, and component imports were updated.

Changes

Team area restructuring

Layer / File(s) Summary
Rename and standardize team pages
SW.Bitween.Web/ClientApp/src/pages/team/...
The Members and Roles components were renamed to MembersPage and RolesPage. Both use PageHeader. The obsolete TeamPage was removed.
Split team routes
SW.Bitween.Web/ClientApp/src/router.tsx
Separate Members and Roles routes now use their respective permission guards. The /team route redirects based on users.view.
Update Administration navigation
SW.Bitween.Web/ClientApp/src/nav.ts
The single Team item was replaced with Members and Roles items using separate paths, permissions, and icons.

Priority: ⬇️ Low

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Bug fix

Suggested labels: security, risk:critical

Suggested reviewers: mmalkhatib

Merge Risk: ⚪ Minimal · up to 60cbc

Members and Roles routes are independently permission-gated, and legacy team links continue to redirect to an accessible page for users with either view permission.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 6 functions across 5 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the primary change: Members and Roles become separate sidebar entries.
Description check ✅ Passed The description accurately explains the separate entries, permission gating, preserved URLs, redirect behavior, and test verification.
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.
  • Fix all pre-merge checks with AI

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.

@samerzughul
samerzughul merged commit d419b4d into releases/r10.0 Sep 13, 2026
5 checks passed
@hamzahalq
hamzahalq deleted the hamza/feature/team-nav-split branch September 13, 2026 07:31
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