# Node Permission Directive The `NodePermissionDirective` allows you to disable an HTML element or Angular component by taking a collection of the `MinimalNodeEntity` instances and checking the particular permission. The decorated element will be disabled if: - there are no nodes in the collection - at least one of the nodes has no expected permission ## Basic example The best example to show `NodePermissionDirective` in action is by binding DocumentList selection property to a toolbar button. For example the "Delete" button should be disabled if no selection is present or if user has no rights to delete at least one node in the selection. ```html ... ``` The button will become disabled by default, and is going to change its state once user selects/unselects one or multiple documents that current user has permission to delete. ## Properties | Name | Type | Default | Description | | --- | --- | --- | --- | | adf-node-permission | [Permissions](https://github.com/Alfresco/alfresco-ng2-components/blob/master/ng2-components/ng2-alfresco-core/src/models/permissions.enum.ts) | null | Node permission to check (create, delete, update, updatePermissions, !create, !delete, !update, !updatePermissions)| | adf-nodes | MinimalNodeEntity[] | [] | Nodes to check permission for |