@kadconsulting/dry
Version:
KAD Reusable Component Library
10 lines • 649 B
JavaScript
import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
import './Logo.scss';
import { Image } from '../@primitives/Image';
const Logo = ({ logoUrl, isnextjs, width, height }) => {
const sizeProps = width && height ? { width, height } : { fill: true };
return (_jsx(_Fragment, { children: isnextjs ? (_jsx(Image, { src: logoUrl ?? '/error', alt: 'Logo', ...sizeProps })) : typeof logoUrl === 'string' ? ( // this is just to satisfy TS no actual important logic here
_jsx("img", { src: logoUrl, alt: 'Logo' })) : (_jsx("div", { children: "Default Logo" })) }));
};
export default Logo;
//# sourceMappingURL=Logo.js.map