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.
25 lines (24 loc) • 1.85 kB
TypeScript
/**
* Icon component to display various icons based on the provided name.
* It supports different sizes and optional class names and IDs.
* @component
* @param {Object} props - Component properties.
* @param {("success" | "danger" | "warning" | "pinFailed" | "pinSuccess" | "resetPassFailed" | "resetPassSuccess" | "verifFailed" | "verifSuccess" | "dataDone" | "emailSent" | "emptyFile" | "emptyPortfolio" | "emptyProduct" | "emptySearch" | "emptyTransaction" | "emptyNews" | "idRegistered" | "limit" | "mobileSent" | "noInternet" | "paperDestroyer" | "somethingWrong" | "underMaintenance" | "unknownImage" | "bankingProduct" | "bonds" | "forex" | "mld" | "mutualFund")} props.name - Name of the icon to display.
* @param {number} [props.size=50] - Size of the icon in pixels (default is 50).
* @param {string} [props.className=""] - Additional CSS classes for customization.
* @param {string} [props.id] - Optional ID for testing purposes.
* @returns {JSX.Element} The Icon component.
* @example
* <Icon name="success" size={40} className="custom-icon" id="icon-success" />
* This component renders an image of the specified icon with the given size and optional class name and ID.
* @example
* <Icon name="danger" />
*/
interface IconProps {
name?: "success" | "danger" | "warning" | "pinFailed" | "pinSuccess" | "resetPassFailed" | "resetPassSuccess" | "verifFailed" | "verifSuccess" | "dataDone" | "emailSent" | "emptyFile" | "emptyPortfolio" | "emptyProduct" | "emptySearch" | "emptyTransaction" | "emptyNews" | "idRegistered" | "limit" | "mobileSent" | "noInternet" | "paperDestroyer" | "somethingWrong" | "underMaintenance" | "unknownImage" | "bankingProduct" | "bonds" | "forex" | "mld" | "mutualFund";
size?: number;
className?: string;
id?: string;
}
declare const Icon: React.FC<IconProps>;
export default Icon;