UNPKG

@drivy/cobalt

Version:

Opinionated design system for Drivy's projects.

22 lines (19 loc) 1.12 kB
import React from 'react'; import camelize from '../../utils/camelize.js'; import 'lodash.throttle'; import cx from 'classnames'; const iconSource = "search"; const SearchIcon = ({ color, size = 24, contained = false, className, }) => { const computedClassName = cx(className, `cobalt-Icon cobalt-Icon--${iconSource}`, { [`c-fill-${camelize(color || "")}`]: color, "cobalt-Icon--size16": size === 16, "cobalt-Icon--size20": size === 20, "cobalt-Icon--size32": size === 32, "cobalt-Icon--contained": contained, }); const wrap = (content) => (React.createElement("span", { className: computedClassName }, content)); return wrap(React.createElement("svg", { viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg" }, React.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "m19.313 21.082-4.24-4.24a7.457 7.457 0 1 1 1.768-1.768l4.24 4.24a.75.75 0 0 1 0 1.061l-.707.707a.75.75 0 0 1-1.06 0ZM5.802 10.76a4.957 4.957 0 1 0 9.914 0 4.957 4.957 0 0 0-9.914 0Z" }))); }; export { SearchIcon as default }; //# sourceMappingURL=SearchIcon.js.map