Icon
Description
Section titled “Description”The AEM Icon component is used to render an SVG icon based on the provided iconName and the styleId is used to determine the size and padding for the icon.
The AEM Icon component is built using the react icon componenticons
Properties
Section titled “Properties”| Prop | Type | Description | Optional |
|---|---|---|---|
icon | string | Given icon name to display from the library. If the provided icon name does not match the allowed list, nothing will be rendered. | ❌ |
styleIds | StyleId[] | An array of styles applied to the icon, including Icon Size, Padding top and Padding bottom. If no style is added, medium is used as default size | ✅ |
Example
Section titled “Example”import { IconAEM } from '@tmedxp/aem-react-components/atoms/icon';
const IconAEMExample = () => { return ( <IconAEM icon="map" styleId={['1588947753507', '1588947753506', '2588947753506']} /> );};
export { IconAEMExample };