chore: clean up typings

This commit is contained in:
Arvid Norlin
2024-04-23 15:39:23 +02:00
parent b12ccfafef
commit 1e8f23de38
8 changed files with 71 additions and 66 deletions

View File

@@ -19,33 +19,33 @@ export enum ContentEntries {
AccountPageContentTextContent = "AccountPageContentTextContent",
}
export type Shortcut = {
type Shortcut = {
text: string
linkConnection: Edges<PageLink>
}
export type DynamicContent = {
type DynamicContent = {
component: DynamicContentComponents
title: string
preamble: string
title?: string
preamble?: string
link: { linkConnection: Edges<PageLink>; link_text: string }
}
export type AccountPageDynamicContent = Typename<
type AccountPageDynamicContent = Typename<
{ dynamic_content: DynamicContent },
ContentEntries.AccountPageContentDynamicContent
>
export type AccountPageContentShortcuts = Typename<
type AccountPageContentShortcuts = Typename<
{
title: string
preamble: string
title?: string
preamble?: string
shortcuts: { shortcuts: Shortcut[] }
},
ContentEntries.AccountPageContentShortcuts
>
export type AccountPageContentTextContent = Typename<
type AccountPageContentTextContent = Typename<
{
text_content: {
content: {
@@ -61,7 +61,7 @@ export type AccountPageContentItem =
| AccountPageContentShortcuts
| AccountPageContentTextContent
export type AccountPage = {
type AccountPage = {
url: string
title: string
content: AccountPageContentItem[]