UNPKG

lucid-ui

Version:

A UI component library from AppNexus.

25 lines 1.33 kB
import _ from 'lodash'; import React from 'react'; import Icon, { propTypes as iconPropTypes } from '../Icon'; import { lucidClassNames } from '../../../util/style-helpers'; import { omitProps } from '../../../util/component-types'; const cx = lucidClassNames.bind('&-WarningIcon'); export const WarningIcon = ({ className, isClickable, isDisabled, ...passThroughs }) => { return (React.createElement(Icon, Object.assign({}, omitProps(passThroughs, undefined, _.keys(WarningIcon.propTypes), false), _.pick(passThroughs, _.keys(iconPropTypes)), { isClickable: isClickable, isDisabled: isDisabled, className: cx('&', isDisabled && '&-is-disabled', isClickable && '&-is-clickable', className) }), React.createElement("path", { className: cx('&-background'), d: 'M.5 15h15L8 .5z' }), React.createElement("path", { className: cx('&-mark'), d: 'M7.99 5v4' }), React.createElement("circle", { className: cx('&-mark'), cx: '7.99', cy: '12', r: '.293' }))); }; WarningIcon.displayName = 'WarningIcon'; WarningIcon.peek = { description: ` A warning Icon. `, categories: ['visual design', 'icons'], extend: 'Icon', madeFrom: ['Icon'], }; WarningIcon.propTypes = iconPropTypes; WarningIcon.defaultProps = Icon.defaultProps; export default WarningIcon; //# sourceMappingURL=WarningIcon.js.map