UNPKG

@uiw/react-shields

Version:

Shields.io for react component, Quality metadata badges for open source projects.

29 lines 894 B
import _extends from "@babel/runtime/helpers/extends"; import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/objectWithoutPropertiesLoose"; var _excluded = ["href", "anchor", "imgSrc", "platform", "type", "user", "repo", "base", "children"]; import React from 'react'; import { jsx as _jsx } from "react/jsx-runtime"; export var Internal = /*#__PURE__*/React.forwardRef((props, ref) => { var { href, anchor = {}, imgSrc } = props, other = _objectWithoutPropertiesLoose(props, _excluded); if (href) { return /*#__PURE__*/_jsx("a", _extends({}, anchor, { href: href, children: /*#__PURE__*/_jsx("img", _extends({ alt: "", ref: ref, src: imgSrc }, other)) })); } return /*#__PURE__*/_jsx("img", _extends({ alt: "", ref: ref, src: imgSrc }, other)); }); Internal.displayName = 'Internal';