UNPKG

@intility/bifrost-react

Version:

React library for Intility's design system, Bifrost.

87 lines 1.72 kB
import { c as _c } from "react-compiler-runtime"; import { forwardRef } from "react"; import classnames from "classnames"; import Icon from "../Icon/Icon.js"; import { jsx as _jsx } from "react/jsx-runtime"; const CardLogo = /*#__PURE__*/forwardRef((t0, ref) => { const $ = _c(19); let className; let icon; let imageUrl; let props; let style; if ($[0] !== t0) { ({ className, style, icon, imageUrl, ...props } = t0); $[0] = t0; $[1] = className; $[2] = icon; $[3] = imageUrl; $[4] = props; $[5] = style; } else { className = $[1]; icon = $[2]; imageUrl = $[3]; props = $[4]; style = $[5]; } let t1; if ($[6] !== className) { t1 = classnames("bf-card-logo", className); $[6] = className; $[7] = t1; } else { t1 = $[7]; } const t2 = imageUrl && `url(${imageUrl})`; let t3; if ($[8] !== style || $[9] !== t2) { t3 = { ...style, backgroundImage: t2 }; $[8] = style; $[9] = t2; $[10] = t3; } else { t3 = $[10]; } let t4; if ($[11] !== icon) { t4 = icon && /*#__PURE__*/_jsx(Icon, { className: "bf-card-logo-icon", icon: icon }); $[11] = icon; $[12] = t4; } else { t4 = $[12]; } let t5; if ($[13] !== props || $[14] !== ref || $[15] !== t1 || $[16] !== t3 || $[17] !== t4) { t5 = /*#__PURE__*/_jsx("div", { ...props, className: t1, ref: ref, style: t3, children: t4 }); $[13] = props; $[14] = ref; $[15] = t1; $[16] = t3; $[17] = t4; $[18] = t5; } else { t5 = $[18]; } return t5; }); CardLogo.displayName = "Card.Logo"; export default CardLogo;