UNPKG

@adminium/ui

Version:

Arco Design React UI Library.

41 lines (36 loc) 1.33 kB
import _extends from "@babel/runtime/helpers/extends"; import React, { useContext } from 'react'; import { IconContext } from '../context'; function IconCommandComponent(iconProps, ref) { const _useContext = useContext(IconContext), _useContext$prefixCls = _useContext.prefixCls, prefixCls = _useContext$prefixCls === void 0 ? 'arco' : _useContext$prefixCls; const spin = iconProps.spin, className = iconProps.className; const props = { "aria-hidden": true, focusable: false, ref, ...iconProps, className: `${className ? className + ' ' : ''}${prefixCls}-icon ${prefixCls}-icon-command` }; if (spin) { props.className = `${props.className} ${prefixCls}-icon-loading`; } delete props.spin; delete props.isIcon; return /*#__PURE__*/React.createElement("svg", _extends({ fill: "none", stroke: "currentColor", strokeWidth: "4", viewBox: "0 0 48 48" }, props), /*#__PURE__*/React.createElement("path", { d: "M29 19v-6a6 6 0 1 1 6 6h-6Zm0 0v10m0-10H19m10 10v6a6 6 0 1 0 6-6h-6Zm0 0H19m0-10v10m0-10v-6a6 6 0 1 0-6 6h6Zm0 10v6a6 6 0 1 1-6-6h6Z" })); } const IconCommand = /*#__PURE__*/React.forwardRef(IconCommandComponent); IconCommand.defaultProps = { isIcon: true }; IconCommand.displayName = 'IconCommand'; export default IconCommand;