UNPKG

@pagamio/frontend-commons-lib

Version:

Pagamio library for Frontend reusable components like the form engine and table container

112 lines (111 loc) 3.33 kB
interface ClientConfig { branding: { name: string; logo: { path: string; altText: string; width: number; height: number; }; navbarLogo?: { path: string; altText: string; width: number; height: number; }; }; theme: { colors: { primary: { 500: string; 600: string; 700: string; }; core: { primary: string; secondary: string; }; }; }; } interface CsvExportOptions { title?: string; includeTimestamp?: boolean; includeHeaders?: boolean; delimiter?: string; filename?: string; } interface PdfExportOptions { title?: string; subtitle?: string; colors?: { primary: { 500: string; 600: string; 700: string; }; core: { primary: string; secondary: string; }; }; logo?: { url: string; width?: number; height?: number; }; } interface XlsxExportOptions { title?: string; subtitle?: string; colors?: { primary: { 500: string; 600: string; 700: string; }; core: { primary: string; secondary: string; }; }; sheetName?: string; includeTimestamp?: boolean; autoFitColumns?: boolean; } /** * Creates PDF export options from client configuration * @param config - The client configuration object * @param title - Optional custom title for the PDF * @returns PdfExportOptions object configured with app theme and branding */ export declare const createPdfExportOptions: (config: ClientConfig, title?: string) => PdfExportOptions; /** * Creates Excel export options from client configuration * @param config - The client configuration object * @param title - Optional custom title for the Excel file * @param sheetName - Optional custom sheet name * @returns XlsxExportOptions object configured with app theme and branding */ export declare const createXlsxExportOptions: (config: ClientConfig, title?: string, sheetName?: string) => XlsxExportOptions; /** * Creates Excel export options with fallback values when no config is available * @param title - Optional custom title for the Excel file * @param sheetName - Optional custom sheet name * @returns XlsxExportOptions object with default styling */ export declare const createDefaultXlsxExportOptions: (title?: string, sheetName?: string) => XlsxExportOptions; /** * Creates CSV export options from client configuration * @param config - The client configuration object * @param title - Optional custom title for the CSV file * @returns CsvExportOptions object configured with app branding */ export declare const createCsvExportOptions: (config: ClientConfig, title?: string) => CsvExportOptions; /** * Creates CSV export options with fallback values when no config is available * @param title - Optional custom title for the CSV file * @returns CsvExportOptions object with default settings */ export declare const createDefaultCsvExportOptions: (title?: string) => CsvExportOptions; export {};