feat: add initial rendering of Account page data
This commit is contained in:
@@ -1,10 +1,18 @@
|
||||
import { AllRequestResponse } from "../utils/all"
|
||||
import type { TypenameInterface } from "../utils/typename"
|
||||
import type { Typename } from "../utils/typename"
|
||||
import type { Edges } from "../utils/edges"
|
||||
import { PageLink } from "../utils/pageLink"
|
||||
|
||||
export type PageLink = {
|
||||
url: string
|
||||
title: string
|
||||
export enum DynamicContentComponents {
|
||||
membership_overview = "membership_overview",
|
||||
benefits = "benefits",
|
||||
previous_stays = "previous_stays",
|
||||
upcoming_stays = "upcoming_stays",
|
||||
}
|
||||
|
||||
export enum ContentEntries {
|
||||
AccountPageContentDynamicContent = "AccountPageContentDynamicContent",
|
||||
AccountPageContentShortcuts = "AccountPageContentShortcuts",
|
||||
}
|
||||
|
||||
export type Shortcut = {
|
||||
@@ -12,19 +20,29 @@ export type Shortcut = {
|
||||
linkConnection: Edges<PageLink>
|
||||
}
|
||||
|
||||
export type Shortcuts = {
|
||||
title: string
|
||||
preamble: string
|
||||
shortcuts: Shortcut[]
|
||||
}
|
||||
|
||||
export type DynamicContent = {
|
||||
component: string
|
||||
component: DynamicContentComponents
|
||||
title: string
|
||||
link: { linkConnection: Edges<PageLink>; link_text: string }
|
||||
}
|
||||
|
||||
export type AccountPageContentItem = {}
|
||||
export type AccountPageDynamicContent = Typename<
|
||||
{ dynamic_content: DynamicContent },
|
||||
ContentEntries.AccountPageContentDynamicContent
|
||||
>
|
||||
|
||||
export type AccountPageContentShortcuts = Typename<
|
||||
{
|
||||
title: string
|
||||
preamble: string
|
||||
shortcuts: { shortcuts: Shortcut[] }
|
||||
},
|
||||
ContentEntries.AccountPageContentShortcuts
|
||||
>
|
||||
|
||||
export type AccountPageContentItem =
|
||||
| AccountPageDynamicContent
|
||||
| AccountPageContentShortcuts
|
||||
|
||||
export type AccountPage = {
|
||||
url: string
|
||||
|
||||
Reference in New Issue
Block a user