UNPKG

ds-smart-ui

Version:

Smart UI v1.0.5 — A production-ready React component library by PT Praisindo Teknologi. Covers inputs, navigation, data display, feedback, and layout with a unified design system, semantic Typography tokens, and full Storybook documentation.

38 lines (37 loc) 1.22 kB
import { ThemeConfig, ColorPalette } from './types'; /** * Mengonversi hex color ke RGB values * @param hex - Hex color string (e.g., '#1e88e5') * @returns RGB string (e.g., '30, 136, 229') */ export declare const hexToRgb: (hex: string) => string; /** * Generate gradient color dari color palette * @param color50 - Color shade 50 * @param colorWhite - White color * @returns Gradient string */ export declare const generateGradient: (color50: string, colorWhite: string) => string; /** * Deep merge two objects * @param target - Target object * @param source - Source object * @returns Merged object */ export declare const deepMerge: <T extends Record<string, any>>(target: T, source: Partial<T>) => T; /** * Apply theme to CSS variables * @param theme - Theme configuration */ export declare const applyTheme: (theme: ThemeConfig) => void; /** * Remove all theme CSS variables */ export declare const removeTheme: () => void; /** * Generate color palette dari base color * Utility function untuk generate semua shades dari satu warna * @param baseColor - Base color in hex format * @returns Color palette object */ export declare const generateColorPalette: (baseColor: string) => ColorPalette;