import { UUID, Slug, CategoryType } from "../common"; import { Article } from "./article"; import { Page } from "./page"; export type ParentCategory = { id: UUID; title: string; page: Page; slug: Slug; parent: ParentCategory | null; }; export type CategoryArticles = { count: number; list: Article[]; }; export type Category = { id: UUID; title: string; slug: Slug; page: Page; categoryType: CategoryType; parent: ParentCategory | null; createdAt: Date | null; updatedAt: Date | null; }; export type HierarchyCategory = { id: UUID; title: string; slug: Slug; page: Page; parent: ParentCategory | null; articles: CategoryArticles; }; export type CategoryArticleIds = { ids: UUID[]; count: number; };