import type { DeepPartial } from '@/interfaces/config.interface'; import type { IElementsConfigurations } from '@/interfaces/configs/configurations.interface'; import type { IAddressComponent } from './address.interface'; import type { ICartComponent } from './cart.interface'; import type { ICheckoutComponent } from './checkout.interface'; import type { IProductComponent } from './product.interface'; import type { IProductListComponent } from './product-list.interface'; export interface IFontFamily { name: string; weights: number[]; } export interface IGlobalTheme { buttonCornerRadius: string; cardCornerRadius: string; headingFont: IFontFamily; paragraphFont: IFontFamily; primaryColor: string; accentColor: string; defaultTextColor: string; selectedTextColor: string; linkTextColor: string; errorColor: string; warningColor: string; successColor: string; drawerBackgroundColor: string; } export interface IPromoTicker { promoCode: string; text: string[]; separator: string; activeFrom: string; activeUntil: string; } export interface IExperienceFeatures { promoTicker: IPromoTicker[]; } export interface IGlobalLayout { enablePersonalization: boolean; personalizationText: string; personalizationCardStyle: 'outlined' | 'filled'; allowPromoCodes: boolean; inputFieldStyle: 'outlined' | 'filled'; showPoweredBy: boolean; poweredByMode: 'light' | 'dark'; } export interface IComponentGlobalConfigs { theme: IGlobalTheme; layout: IGlobalLayout; experienceFeatures: IExperienceFeatures; } export type UpdateComponentGlobalConfigs = DeepPartial; export interface IAllConfigs { configurations: IElementsConfigurations; global: IComponentGlobalConfigs; product: IProductComponent; productList: IProductListComponent; address: IAddressComponent; cart: ICartComponent; checkout: ICheckoutComponent; } export type ConfigsKeyType = 'all' | 'configurations' | 'global' | 'product' | 'address' | 'cart' | 'checkout' | 'productList'; export type ConfigsType = IAllConfigs | IElementsConfigurations | IComponentGlobalConfigs | IProductComponent | IAddressComponent | ICartComponent | ICheckoutComponent | IProductListComponent;