UNPKG

@icons-pack/react-simple-icons

Version:

This package provides the Simple Icons packaged as a set of React components.

43 lines (38 loc) 2.51 kB
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); } function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; } import React, { forwardRef } from 'react'; import PropTypes from 'prop-types'; var Stimulus = /*#__PURE__*/forwardRef(function Stimulus(_ref, ref) { var _ref$color = _ref.color, color = _ref$color === void 0 ? 'currentColor' : _ref$color, _ref$size = _ref.size, size = _ref$size === void 0 ? 24 : _ref$size, _ref$title = _ref.title, title = _ref$title === void 0 ? 'stimulus' : _ref$title, others = _objectWithoutPropertiesLoose(_ref, ["color", "size", "title"]); return /*#__PURE__*/React.createElement("svg", _extends({ xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: color, viewBox: "0 0 24 24", ref: ref }, others), /*#__PURE__*/React.createElement("title", null, title), /*#__PURE__*/React.createElement("path", { d: "M.704 0A.704.704 0 000 .704v2.824h5.648a3.064 3.064 0 011.312.36l3.232 1.9a.4.4 0 010 .712l-1.536.904a1.308 1.308 0 01-1.2 0l-1.2-.7a3.084 3.084 0 00-1.316-.36H0v4.236h4.94a3.028 3.028 0 001.316-.36l10.8-6.344a3.008 3.008 0 011.312-.36H24V.692A.704.704 0 0023.296 0zM19.06 6.352a3.084 3.084 0 00-1.316.36l-10.8 6.348a3.064 3.064 0 01-1.312.36H0v4.236h4.94a3.084 3.084 0 001.316-.36l10.8-6.348a3.064 3.064 0 011.312-.36H24V6.352h-3.376zm0 7.072a3.084 3.084 0 00-1.316.36l-10.8 6.344a3.008 3.008 0 01-1.312.36H0v2.824A.708.708 0 00.704 24h22.592a.708.708 0 00.704-.7v-2.824h-5.648a3.008 3.008 0 01-1.312-.36l-3.232-1.896a.4.4 0 010-.716l1.536-.9a1.308 1.308 0 011.2 0l1.2.696a3.028 3.028 0 001.316.36H24v-4.236h-3.376z" })); }); Stimulus.propTypes = { /** * Hex color or color name */ color: PropTypes.string, /** * The size of the Icon. */ size: PropTypes.oneOfType([PropTypes.string, PropTypes.number]), /** * The title provides an accessible short text description to the SVG */ title: PropTypes.string }; export default Stimulus;