import { create, tsx } from '@dojo/framework/core/vdom';
import theme from '../middleware/theme';
import { formatAriaProperties } from '../common/util';
import * as css from '../theme/default/icon.m.css';
const factory = create({ theme }).properties();
export const Icon = factory(function Icon({ properties, middleware: { theme } }) {
    const { aria = {}, type, altText, size } = properties();
    const classes = theme.classes(css);
    const sizeClass = size && classes[size];
    return (tsx("i", Object.assign({ classes: [theme.variant(), classes.root, classes.icon, classes[type], sizeClass], role: "img", "aria-hidden": altText ? 'false' : 'true', "aria-label": altText }, formatAriaProperties(aria))));
});
export default Icon;

/*# sourceMappingURL=index.mjs.map*/