@drivy/cobalt
Version:
Opinionated design system for Drivy's projects.
34 lines (33 loc) • 1.64 kB
JavaScript
import { jsx, jsxs } from "react/jsx-runtime";
import classnames from "classnames";
import { camelize } from "../../utils/index.js";
const iconSource = "calendar";
const CalendarIcon = ({ color, size = 24, contained = false, className })=>{
const computedClassName = classnames(className, `cobalt-Icon cobalt-Icon--${iconSource}`, {
[`c-fill-${camelize(color || "")}`]: color,
"cobalt-Icon--size16": 16 === size,
"cobalt-Icon--size20": 20 === size,
"cobalt-Icon--size32": 32 === size,
"cobalt-Icon--contained": contained
});
return /*#__PURE__*/ jsx("span", {
className: computedClassName,
children: /*#__PURE__*/ jsxs("svg", {
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 24 24",
children: [
/*#__PURE__*/ jsx("title", {
children: iconSource
}),
/*#__PURE__*/ jsx("path", {
fillRule: "evenodd",
d: "M8.25 3.75H15.75V1.5H17.25V3.75H20.25C21.078 3.75 21.75 4.422 21.75 5.25V13.5L15 20.25H3.75L3.597 20.242C2.84 20.165 2.25 19.527 2.25 18.75V5.25C2.25 4.422 2.922 3.75 3.75 3.75H6.75V1.5H8.25zM3.75 18.75H14.25V15C14.25 13.757 15.257 12.75 16.5 12.75H20.25V9.75H3.75zM16.5 14.25C16.086 14.25 15.75 14.586 15.75 15V17.379L18.879 14.25zM3.75 8.25H20.25V5.25H17.25V6.75H15.75V5.25H8.25V6.75H6.75V5.25H3.75z",
clipRule: "evenodd"
})
]
})
});
};
const _generated_CalendarIcon = CalendarIcon;
export default _generated_CalendarIcon;
//# sourceMappingURL=CalendarIcon.js.map