You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
472 B
17 lines
472 B
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
import * as React from 'react';
|
|
export default function Icon(_ref) {
|
|
var icon = _ref.icon,
|
|
props = _ref.props,
|
|
children = _ref.children;
|
|
var iconNode;
|
|
|
|
if (typeof icon === 'function') {
|
|
iconNode = /*#__PURE__*/React.createElement(icon, _objectSpread({}, props));
|
|
} else {
|
|
// Compatible for origin definition
|
|
iconNode = icon;
|
|
}
|
|
|
|
return iconNode || children || null;
|
|
} |