Files
web/types/requests/currentBlockPage.ts
2024-02-22 16:33:00 +01:00

55 lines
1.4 KiB
TypeScript

import { BlocksTypenameEnum } from "./utils/typename"
import type { Contact } from "./asides/contact"
import type { PuffAside } from "./asides/puff"
import type { Hero } from "./hero"
import type { List } from "./blocks/list"
import type { PuffBlock } from "./blocks/puff"
import type { Preamble } from "./preamble"
import type { Text } from "./blocks/text"
import type { AllRequestResponse } from "./utils/all"
import type {
AsideTypenameEnum,
Typename,
PagesTypenameEnum,
} from "./utils/typename"
export type Asides =
| Typename<Contact, AsideTypenameEnum.CurrentBlocksPageAsideContact>
| Typename<PuffAside, AsideTypenameEnum.CurrentBlocksPageAsidePuff>
export type Blocks =
| Typename<List, BlocksTypenameEnum.CurrentBlocksPageBlocksList>
| Typename<PuffBlock, BlocksTypenameEnum.CurrentBlocksPageBlocksPuffs>
| Typename<Text, BlocksTypenameEnum.CurrentBlocksPageBlocksText>
export type Breadcrumb = {
href: string
title: string
}
export type Breadcrumbs = {
parents: Breadcrumb[]
title: string
}
export type BlockPage = {
__typename: PagesTypenameEnum.CurrentBlocksPage
aside: Asides[]
blocks: Blocks[]
breadcrumbs: Breadcrumbs
hero: Hero
preamble: Preamble
system: {
created_at: string
uid: string
updated_at: string
}
title: string
url: string
}
export type GetCurrentBlockPageData = {
all_current_blocks_page: AllRequestResponse<BlockPage>
}