"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.GlLogo = void 0;
var jsx_runtime_1 = require("react/jsx-runtime");
var react_svg_1 = require("react-svg");
var react_1 = require("react");
var theme_1 = require("../theme");
exports.GlLogo = react_1.memo(function (props) {
    var className = props.className, logoUrl = props.logoUrl, fill = props.fill, height = props.height, width = props.width;
    var _a = useStyles({ fill: fill, width: width, height: height }), classes = _a.classes, cx = _a.cx;
    return logoUrl.endsWith(".svg") ? (jsx_runtime_1.jsx(react_svg_1.ReactSVG, { src: logoUrl, className: cx(classes.root, classes.svg, className) }, void 0)) : (jsx_runtime_1.jsx("img", { src: logoUrl, className: cx(classes.root, className), alt: "logo" }, void 0));
});
var useStyles = theme_1.makeStyles()(function (theme, _a) {
    var fill = _a.fill, height = _a.height, width = _a.width;
    return ({
        "root": {
            width: width,
            height: height,
        },
        "svg": {
            "& svg": {
                "fill": fill !== null && fill !== void 0 ? fill : theme.colors.useCases.typography.textPrimary,
                "width": "100%",
                "height": "100%",
            },
        },
    });
});
//# sourceMappingURL=GlLogo.js.map