@anoki/fse-common
Version:
Common types for FSE
79 lines (78 loc) • 2.3 kB
TypeScript
import { Upload } from './upload-file';
import { WithMongooseProps } from './with-mongoose-props';
import { WithTranslations } from './with-translations';
import { GetValues } from '../constants';
export type SettingHeaderLink = {
label: string;
path?: string;
visible: boolean;
externalLink: boolean;
pageId?: string;
toTheRight?: boolean;
};
export type SettingFooterLink = {
label: string;
path?: string;
visible: boolean;
href?: string;
externalLink: boolean;
};
export type SettingTranslatedField = {
headerTitle: string;
headerShortTitle: string;
headerLinks: SettingHeaderLink[];
footerLinks: SettingFooterLink[];
backofficeTitle: string;
backofficeDescription: string;
bannerNewPortalTitle?: string;
bannerNewPortalSubtitle?: string;
bannerNewPortalLinkTitle?: string;
};
export type SettingProfileMenu = {
healthProfileVisible: boolean;
healthHistoryVisible: boolean;
};
export declare const ConsentReminderLayout: {
readonly BANNER: "banner";
readonly CARD: "card";
};
export declare const HeadingStyleEnum: {
readonly BASE: "base";
readonly REVISED: "revised";
};
export type ConsentTypeReminderLayout = GetValues<typeof ConsentReminderLayout>;
export type HeadingStyle = GetValues<typeof HeadingStyleEnum>;
export type SettingHome = {
consentReminderLayout: ConsentTypeReminderLayout;
newPortalBannerVisible?: boolean;
newPortalBannerLink?: string;
};
export type SettingFooter = {
FseMS: string;
FseMEF: string;
FseDGT: string;
FseUE: string;
FseIT: string;
externalLink: string;
externalLinkName: string;
};
export type Setting = WithMongooseProps<SettingTranslatedField & {
faviconLogo?: Upload;
headerLogo?: Upload;
headerLogo2?: Upload;
backofficeLogo?: Upload;
footerLogo?: Upload;
notificationsEnabled: boolean;
headingStyle: HeadingStyle;
profileMenu: SettingProfileMenu;
translations: WithTranslations<SettingTranslatedField>;
home: SettingHome;
footer: SettingFooter;
supportEnabled: true;
supportEmail: string;
supportPhone: string;
supportUrl?: string;
bannerNewPortalTitle?: string;
bannerNewPortalSubtitle?: string;
bannerNewPortalLinkTitle?: string;
}>;