feat: add permission checks to assistant empty states

This commit is contained in:
Shivam Mishra
2025-01-23 10:04:19 +05:30
parent ed44fc77e1
commit ad8c74c157
6 changed files with 17 additions and 5 deletions
@@ -1,4 +1,6 @@
<script setup>
import Policy from 'dashboard/components/policy.vue';
defineProps({
title: {
type: String,
@@ -8,6 +10,10 @@ defineProps({
type: String,
required: true,
},
actionPerms: {
type: Array,
default: () => [],
},
});
</script>
@@ -39,7 +45,9 @@ defineProps({
{{ subtitle }}
</p>
</div>
<slot name="actions" />
<Policy :permissions="actionPerms">
<slot name="actions" />
</Policy>
</div>
</div>
</div>