2025-04-30 01:44:16 +02:00
|
|
|
<template>
|
2025-08-28 07:41:51 +02:00
|
|
|
<div v-if="authStore.emojis.length > 0" class="grow">
|
|
|
|
|
<Table :emojis="authStore.emojis" :can-upload="canUpload" />
|
2025-04-30 01:44:16 +02:00
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script lang="ts" setup>
|
2025-05-26 11:19:15 +02:00
|
|
|
import { RolePermission } from "@versia/client/schemas";
|
2025-04-30 01:44:16 +02:00
|
|
|
import Table from "./table.vue";
|
|
|
|
|
|
2025-08-28 07:41:51 +02:00
|
|
|
const authStore = useAuthStore();
|
2025-04-30 01:44:16 +02:00
|
|
|
const canUpload = computed(
|
|
|
|
|
() =>
|
2025-08-28 07:41:51 +02:00
|
|
|
authStore.permissions.includes(RolePermission.ManageOwnEmojis) ||
|
|
|
|
|
authStore.permissions.includes(RolePermission.ManageEmojis),
|
2025-04-30 01:44:16 +02:00
|
|
|
);
|
|
|
|
|
</script>
|