feat static pages system with dynamic footer and safe html rendering
This commit is contained in:
36
src/app/shared/models/config/static-page.model.ts
Normal file
36
src/app/shared/models/config/static-page.model.ts
Normal file
@@ -0,0 +1,36 @@
|
||||
export interface LocalizedHtmlContent {
|
||||
[locale: string]: string;
|
||||
}
|
||||
|
||||
export interface LocalizedTextContent {
|
||||
[locale: string]: string;
|
||||
}
|
||||
|
||||
export interface StaticPageConfig {
|
||||
route: string;
|
||||
title: LocalizedTextContent;
|
||||
content: LocalizedHtmlContent;
|
||||
seo?: {
|
||||
title?: LocalizedTextContent;
|
||||
description?: LocalizedTextContent;
|
||||
robots?: string;
|
||||
};
|
||||
visible?: boolean;
|
||||
}
|
||||
|
||||
export interface LegacyStaticPageConfig {
|
||||
key: string;
|
||||
route: string | { path: string; exact?: boolean };
|
||||
title?: string | LocalizedTextContent;
|
||||
content?: string | LocalizedHtmlContent | { value?: string; contentType?: string; source?: string };
|
||||
visible?: boolean;
|
||||
}
|
||||
|
||||
export type StaticPagesConfig = Record<string, StaticPageConfig> | LegacyStaticPageConfig[];
|
||||
|
||||
export interface ResolvedStaticPage {
|
||||
key: string;
|
||||
route: string;
|
||||
title: string;
|
||||
html: string;
|
||||
}
|
||||
Reference in New Issue
Block a user