import { ARCHITECTURE_ATTRIBUTION, ARCHITECTURE_META } from "#configuration/strings/architecture.strings"; import { ARCHITECTURE_DESCRIPTION, ARCHITECTURE_TITLE } from "#configuration/strings/page.strings"; import { CREATIVE_COMMONS, SITE_URL, pagePath } from "#assets/link.assets"; import { mountTabSwitching, renderTabbedPage } from "#presentation/widgets/tab.widget"; import { ARCHITECTURE_PAGE } from "#core/ids/page.ids"; import { ARCHITECTURE_TABS } from "#configuration/strings/site.strings"; import { ARCHITECTURE_TONE } from "#configuration/constants/tab.constants"; import { METHODOLOGY_AUTHOR } from "#configuration/strings/methodology.strings"; import type { PageDefinition } from "#types/page.types"; import type { SchemaEntity } from "#types/schema.types"; import type { TabbedPage } from "#types/tab.types"; import { renderLicensedFooter } from "#presentation/renderers/methodology.renderer"; const ARCHITECTURE_ENTITY: SchemaEntity = { "@type": "CreativeWork", author: { "@type": "Person", name: METHODOLOGY_AUTHOR }, description: ARCHITECTURE_DESCRIPTION, license: CREATIVE_COMMONS, name: ARCHITECTURE_META.title, url: SITE_URL + pagePath(ARCHITECTURE_PAGE), version: ARCHITECTURE_META.version, }; const renderArchitectureFooter = function renderArchitectureFooter(): Element { return renderLicensedFooter(ARCHITECTURE_ATTRIBUTION); }; const DEFINITION: TabbedPage = { footer: renderArchitectureFooter, layout: "chapter", meta: ARCHITECTURE_META, page: ARCHITECTURE_PAGE, tabs: ARCHITECTURE_TABS, tone: ARCHITECTURE_TONE, }; const renderArchitecture = function renderArchitecture(): Element { return renderTabbedPage(DEFINITION); }; void mountTabSwitching(DEFINITION); export const PAGE: PageDefinition = { content: { kind: "tabbed", layout: DEFINITION.layout, meta: ARCHITECTURE_META, tabs: ARCHITECTURE_TABS }, description: ARCHITECTURE_DESCRIPTION, entities: [ARCHITECTURE_ENTITY], id: ARCHITECTURE_PAGE, render: renderArchitecture, title: ARCHITECTURE_TITLE, };