Adds Content deletion

This commit is contained in:
2024-08-16 18:14:56 -04:00
parent 44bf1a0e12
commit af51a23677
2 changed files with 15 additions and 2 deletions

View File

@@ -6,6 +6,7 @@
<template v-for="content in contents" :key="content">
<content-card :content="content"
class="my-1"
@content:deleted="onContentDeleted"
></content-card>
</template>
@@ -40,6 +41,10 @@ const page_size = 10
const errorMessage = ref()
let last_id = null
async function onContentDeleted(contentId) {
contents.value = contents.value.filter(c => c.id !== contentId)
}
const creatorIdWatcher = watch(
() => props.creatorId,
(newCreatorId) => {