Component libraryRoles and permissions
Components/Blocks

Roles and permissions

Pro

Assign workspace roles and inspect direct or inherited permissions in matrix and compact list views.

npx shadcn@latest add @tidal-pro/roles-permissions
Desktop viewport

Installation

Pro source is gated. Configure the @tidal-pro registry using the agent guide. Create an access key from your account after purchasing.

Terminal
npx shadcn@latest add @tidal-pro/roles-permissions

Import components/ui/tidal.css, components/ui/roles-permissions.css, then add the component inside a tidal-scope wrapper. Its scoped design tokens keep it independent of your existing CSS.

Usage

Complete example source · Dependency and asset manifest

Loading the complete example…

API & behavior

title, consumer-owned roles with unique IDs/plain select labels, permission definitions with unique IDs/group IDs, controlled direct grants and view are required. Optional inherited grants render checked read-only permissions. Optional controlled members expose native single-select role assignment. Matrix and role-list views share the same controlled values; native view buttons render only with onViewChange. Individual and group checkbox callbacks receive proposals after caller handlers and honor prevention. Group toggles expose checked/mixed effective state while proposing only editable permission IDs. Native permission/group inputs support callback prop/ref factories, names, external forms and native attributes while checked/type remain owned. Member selects preserve native props/ref, external form, caller accessible-name/description attributes and linked unknown-value validation. Root, matrix-region and view-button props/refs are supported; root aria-disabled and unsafe markup are excluded. disabled locks every owned control. Unknown role or permission references surface linked configuration feedback and disable mutations without changing caller data; blank or duplicate role, permission or member IDs suppress ambiguous keyed collections. The matrix receives a keyboard tab stop only while measured overflow exists unless a tabIndex is supplied. Consumers own authorization, effective-policy evaluation beyond supplied direct/inherited sets, mutation, confirmation, requests and persistence. The component does not enforce access, fetch, export, store or authenticate.

Style with the --t-* CSS variables. Set data-theme="dark" on your tidal-scope wrapper for a dark surface. Motion respects the system’s reduced-motion preference.

Building with an agent?Give it the installation guide and component catalog.