Skip to content

PermissionGateProps

PermissionGateProps = object

Defined in: packages/ui/src/types.ts:1195

Props for the PermissionGate component.

Conditionally renders children based on action permission status from @cfast/actions. When the action is permitted, children is rendered. When forbidden but not invisible, fallback is rendered. When the action is invisible (no relation at all), nothing is rendered.

WhenForbidden for the related behavior modes used by ActionButton.

action: ActionHookResult

Defined in: packages/ui/src/types.ts:1197

Action hook result providing permission status.


children: ReactNode

Defined in: packages/ui/src/types.ts:1199

Content rendered when the action is permitted.


optional fallback: ReactNode

Defined in: packages/ui/src/types.ts:1201

Content rendered when the action is forbidden but not invisible.