templates2.Content.Nuxt/shared/types.ts
w4c-templates 940313f8c5
Some checks failed
CI / quality (push) Has been cancelled
chore(template): publish Content.Nuxt
2026-10-11 23:26:40 +03:00

55 lines
1,020 B
TypeScript

export type SessionUser = {
id: string;
email: string;
name: string | null;
role: string;
};
export type PostAuthor = {
name: string;
slug: string;
bio?: string | null;
avatarColor?: string;
};
export type PostSummary = {
id: string;
slug: string;
title: string;
excerpt: string;
status?: string;
publishedAt: string | Date | null;
readingMinutes: number;
featured: boolean;
author: PostAuthor;
tags: { name: string; slug: string }[];
};
export type PostDetail = PostSummary & {
body: string;
updatedAt?: string | Date;
tagIds?: string[];
author: PostAuthor & { id?: string };
};
export type TagSummary = { id: string; name: string; slug: string; count?: number };
export type AuthorSummary = {
id: string;
name: string;
slug: string;
bio?: string | null;
avatarColor?: string;
count?: number;
};
export type DocSummary = {
id: string;
slug: string;
title: string;
section: string;
order: number;
status?: string;
updatedAt?: string | Date;
};