2023-12-31 01:52:38 -05:00
|
|
|
<script setup lang="ts">
|
|
|
|
import SingleStory from "~/components/listings/singleStory.vue";
|
|
|
|
import { IStory } from "@models/stories";
|
2024-01-04 17:08:12 -05:00
|
|
|
definePageMeta({
|
|
|
|
middleware: ["auth"],
|
|
|
|
});
|
|
|
|
const { data: stories, error } = await useApiFetch<{ stories: IStory[]; total: number }>("/user/me/stories");
|
2023-12-31 01:52:38 -05:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<template>
|
2024-01-04 17:08:12 -05:00
|
|
|
<a-list :grid="{ gutter: [16, 16], md: 2, lg: 3, xxl: 3, sm: 1 }" :data-source="stories.stories">
|
2023-12-31 01:52:38 -05:00
|
|
|
<template #renderItem="{ item }">
|
|
|
|
<single-story :story="item" show-actions />
|
|
|
|
</template>
|
|
|
|
</a-list>
|
|
|
|
</template>
|