Skip to content

Restrict admin-only controls in Settings based on member role - #312

Merged
Lakes41 merged 1 commit into
Adamantine-guild:mainfrom
bridgetthnkechi87-cloud:security/settings-role-gating
Jul 28, 2026
Merged

Restrict admin-only controls in Settings based on member role#312
Lakes41 merged 1 commit into
Adamantine-guild:mainfrom
bridgetthnkechi87-cloud:security/settings-role-gating

Conversation

@bridgetthnkechi87-cloud

Copy link
Copy Markdown
Contributor

Closes #292

Summary

Restricted the remaining ungated Settings controls based on the current mock user's role.

Changes

  • Reused the existing canEditSettings permission flow
  • Disabled the Light/Dark appearance controls for non-admin/read-only users
  • Preserved full access for owner/admin users
  • Kept the existing Settings read-only behavior and permission model unchanged

Notes

The dashboard already has centralized role and permission logic through the existing session and permission helpers. Most Settings controls were already gated. This PR focuses on the remaining gap: the Appearance toggle controls.

Testing

  • Verified the changed Settings file type-checks
  • UI-only role-gating change
  • No new auth model, middleware, API route, or permission system added

@Lakes41
Lakes41 merged commit 47f1e14 into Adamantine-guild:main Jul 28, 2026
1 check passed
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.

Restrict admin-only controls in Settings based on member role

2 participants