UNPKG

iconsax-react

Version:
172 lines (154 loc) 7.13 kB
import { _ as _objectWithoutProperties, a as _extends } from './_rollupPluginBabelHelpers-3bc641ae.js'; import React, { forwardRef } from 'react'; import PropTypes from 'prop-types'; var _excluded = ["variant", "color", "size"]; var Bold = function Bold(_ref) { var color = _ref.color; return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("path", { d: "M16.82 2H7.18C5.05 2 3.32 3.74 3.32 5.86v14.09c0 1.8 1.29 2.56 2.87 1.69l4.88-2.71c.52-.29 1.36-.29 1.87 0l4.88 2.71c1.58.88 2.87.12 2.87-1.69V5.86C20.68 3.74 18.95 2 16.82 2Zm-1.81 7.75c-.97.35-1.99.53-3.01.53-1.02 0-2.04-.18-3.01-.53a.75.75 0 0 1-.45-.96c.15-.39.58-.59.97-.45 1.61.58 3.38.58 4.99 0a.75.75 0 1 1 .51 1.41Z", fill: color })); }; var Broken = function Broken(_ref2) { var color = _ref2.color; return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("path", { d: "M9.25 9.05a8 8 0 0 0 5.5 0", stroke: color, strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }), /*#__PURE__*/React.createElement("path", { d: "M3.32 10v9.95c0 1.8 1.29 2.56 2.87 1.69l4.88-2.71c.52-.29 1.36-.29 1.87 0l4.88 2.71c1.58.88 2.87.12 2.87-1.69V5.86c0-2.12-1.74-3.86-3.86-3.86H7.18C5.05 2 3.32 3.74 3.32 5.86", stroke: color, strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" })); }; var Bulk = function Bulk(_ref3) { var color = _ref3.color; return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("path", { opacity: ".4", d: "M16.82 2H7.18C5.05 2 3.32 3.74 3.32 5.86v14.09c0 1.8 1.29 2.56 2.87 1.69l4.88-2.71c.52-.29 1.36-.29 1.87 0l4.88 2.71c1.58.88 2.87.12 2.87-1.69V5.86C20.68 3.74 18.95 2 16.82 2Z", fill: color }), /*#__PURE__*/React.createElement("path", { d: "M12 10.281c-1.02 0-2.04-.18-3.01-.53a.75.75 0 0 1-.45-.96c.15-.39.58-.59.97-.45 1.61.58 3.38.58 4.99 0a.75.75 0 1 1 .51 1.41c-.97.35-1.99.53-3.01.53Z", fill: color })); }; var Linear = function Linear(_ref4) { var color = _ref4.color; return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("path", { d: "M9.25 9.05a8 8 0 0 0 5.5 0", stroke: color, strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }), /*#__PURE__*/React.createElement("path", { d: "M16.82 2H7.18C5.05 2 3.32 3.74 3.32 5.86v14.09c0 1.8 1.29 2.56 2.87 1.69l4.88-2.71c.52-.29 1.36-.29 1.87 0l4.88 2.71c1.58.88 2.87.12 2.87-1.69V5.86C20.68 3.74 18.95 2 16.82 2Z", stroke: color, strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }), /*#__PURE__*/React.createElement("path", { d: "M16.82 2H7.18C5.05 2 3.32 3.74 3.32 5.86v14.09c0 1.8 1.29 2.56 2.87 1.69l4.88-2.71c.52-.29 1.36-.29 1.87 0l4.88 2.71c1.58.88 2.87.12 2.87-1.69V5.86C20.68 3.74 18.95 2 16.82 2Z", stroke: color, strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" })); }; var Outline = function Outline(_ref5) { var color = _ref5.color; return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("path", { d: "M12 10.281c-1.02 0-2.04-.18-3.01-.53a.75.75 0 0 1-.45-.96c.15-.39.58-.59.97-.45 1.61.58 3.38.58 4.99 0a.75.75 0 1 1 .51 1.41c-.97.35-1.99.53-3.01.53Z", fill: color }), /*#__PURE__*/React.createElement("path", { d: "M19.07 22.75c-.51 0-1.07-.15-1.61-.46l-4.88-2.71c-.29-.16-.86-.16-1.15 0l-4.88 2.71c-.99.55-2 .61-2.77.15-.77-.45-1.21-1.36-1.21-2.49V5.86c0-2.54 2.07-4.61 4.61-4.61h9.65c2.54 0 4.61 2.07 4.61 4.61v14.09c0 1.13-.44 2.04-1.21 2.49-.35.21-.75.31-1.16.31ZM12 17.96c.47 0 .93.1 1.3.31l4.88 2.71c.51.29.98.35 1.28.17.3-.18.47-.61.47-1.2V5.86c0-1.71-1.4-3.11-3.11-3.11H7.18a3.12 3.12 0 0 0-3.11 3.11v14.09c0 .59.17 1.03.47 1.2.3.17.76.12 1.28-.17l4.88-2.71c.37-.21.83-.31 1.3-.31Z", fill: color }), /*#__PURE__*/React.createElement("path", { d: "M19.07 22.75c-.51 0-1.07-.15-1.61-.46l-4.88-2.71c-.29-.16-.86-.16-1.15 0l-4.88 2.71c-.99.55-2 .61-2.77.15-.77-.45-1.21-1.36-1.21-2.49V5.86c0-2.54 2.07-4.61 4.61-4.61h9.65c2.54 0 4.61 2.07 4.61 4.61v14.09c0 1.13-.44 2.04-1.21 2.49-.35.21-.75.31-1.16.31ZM12 17.96c.47 0 .93.1 1.3.31l4.88 2.71c.51.29.98.35 1.28.17.3-.18.47-.61.47-1.2V5.86c0-1.71-1.4-3.11-3.11-3.11H7.18a3.12 3.12 0 0 0-3.11 3.11v14.09c0 .59.17 1.03.47 1.2.3.17.76.12 1.28-.17l4.88-2.71c.37-.21.83-.31 1.3-.31Z", fill: color })); }; var TwoTone = function TwoTone(_ref6) { var color = _ref6.color; return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("path", { opacity: ".4", d: "M9.25 9.05a8 8 0 0 0 5.5 0", stroke: color, strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }), /*#__PURE__*/React.createElement("path", { d: "M16.82 2H7.18C5.05 2 3.32 3.74 3.32 5.86v14.09c0 1.8 1.29 2.56 2.87 1.69l4.88-2.71c.52-.29 1.36-.29 1.87 0l4.88 2.71c1.58.88 2.87.12 2.87-1.69V5.86C20.68 3.74 18.95 2 16.82 2Z", stroke: color, strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }), /*#__PURE__*/React.createElement("path", { d: "M16.82 2H7.18C5.05 2 3.32 3.74 3.32 5.86v14.09c0 1.8 1.29 2.56 2.87 1.69l4.88-2.71c.52-.29 1.36-.29 1.87 0l4.88 2.71c1.58.88 2.87.12 2.87-1.69V5.86C20.68 3.74 18.95 2 16.82 2Z", stroke: color, strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" })); }; var chooseVariant = function chooseVariant(variant, color) { switch (variant) { case 'Bold': return /*#__PURE__*/React.createElement(Bold, { color: color }); case 'Broken': return /*#__PURE__*/React.createElement(Broken, { color: color }); case 'Bulk': return /*#__PURE__*/React.createElement(Bulk, { color: color }); case 'Linear': return /*#__PURE__*/React.createElement(Linear, { color: color }); case 'Outline': return /*#__PURE__*/React.createElement(Outline, { color: color }); case 'TwoTone': return /*#__PURE__*/React.createElement(TwoTone, { color: color }); default: return /*#__PURE__*/React.createElement(Linear, { color: color }); } }; var Archive = /*#__PURE__*/forwardRef(function (_ref7, ref) { var variant = _ref7.variant, color = _ref7.color, size = _ref7.size, rest = _objectWithoutProperties(_ref7, _excluded); return /*#__PURE__*/React.createElement("svg", _extends({}, rest, { xmlns: "http://www.w3.org/2000/svg", ref: ref, width: size, height: size, viewBox: "0 0 24 24", fill: "none" }), chooseVariant(variant, color)); }); Archive.propTypes = { variant: PropTypes.oneOf(['Linear', 'Bold', 'Broken', 'Bulk', 'Outline', 'TwoTone']), color: PropTypes.string, size: PropTypes.oneOfType([PropTypes.string, PropTypes.number]) }; Archive.defaultProps = { variant: 'Linear', color: 'currentColor', size: '24' }; Archive.displayName = 'Archive'; export { Archive as default };