@tonyfreed/card-core
Version:
Core components and types for Ildex card system
74 lines • 1.71 kB
TypeScript
import { ILink } from "./link.interface";
import { IProfile } from "./profile.interface";
import { IFooter } from "./footer.interface";
import { Language } from "./language.interface";
export interface ICard {
id: string;
accountId: string;
slug: string;
sections: ICardSection[];
config: ICardConfig;
status: {
published: boolean;
lastModified: Date;
version: string;
};
}
export interface ICardSection {
id: string;
type: CardSectionType;
order: number;
data: IProfile | ILink[] | IFooter;
config: Record<string, any>;
isActive: boolean;
}
export declare enum CardSectionType {
PROFILE = "profile",
LINKS = "links",
FOOTER = "footer",
LANGUAGE_SELECTOR = "language-selector"
}
export interface ICardConfig {
theme: ThemeConfig;
layout: {
template: string;
settings: Record<string, any>;
};
languages: {
default: Language;
available: Language[];
fallback: Language;
};
}
export interface ThemeConfig {
colors: {
primary: string;
secondary: string;
background: string;
text: string;
textSecondary: string;
link: string;
linkHover: string;
};
typography: {
fontFamily: string;
fontSize: {
small: string;
medium: string;
large: string;
heading: string;
};
};
spacing: {
small: string;
medium: string;
large: string;
};
borderRadius: string;
shadows: {
small: string;
medium: string;
large: string;
};
}
//# sourceMappingURL=card.interface.d.ts.map