mirror of
https://github.com/kremalicious/umami.git
synced 2024-12-18 23:33:37 +01:00
21 lines
538 B
JavaScript
21 lines
538 B
JavaScript
import React from 'react';
|
|
import classNames from 'classnames';
|
|
import styles from './Icon.module.css';
|
|
|
|
export default function Icon({ icon, className, size = 'medium', ...props }) {
|
|
return (
|
|
<div
|
|
className={classNames(styles.icon, className, {
|
|
[styles.xlarge]: size === 'xlarge',
|
|
[styles.large]: size === 'large',
|
|
[styles.medium]: size === 'medium',
|
|
[styles.small]: size === 'small',
|
|
[styles.xsmall]: size === 'xsmall',
|
|
})}
|
|
{...props}
|
|
>
|
|
{icon}
|
|
</div>
|
|
);
|
|
}
|