@magicbell/magicbell-react
Version:
React components for building a notification inbox for your app
30 lines • 1.31 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.default = FooterLogo;
const tslib_1 = require("tslib");
const jsx_runtime_1 = require("@emotion/react/jsx-runtime");
/** @jsxImportSource @emotion/react */
const react_1 = require("@emotion/react");
const react_headless_1 = require("@magicbell/react-headless");
const ramda_1 = require("ramda");
const MagicBellLogo_js_1 = tslib_1.__importDefault(require("./MagicBellLogo.js"));
/**
* MagicBell Logo for the footer. If the customer has branding off, the logo is
* hidden.
*
* @example
* <FooterLogo />
*/
function FooterLogo() {
const inboxConfig = (0, react_headless_1.useConfig)((state) => state.inbox);
const hideBranding = (0, ramda_1.pathOr)(false, ['features', 'noMagicbellBranding', 'enabled'], inboxConfig);
const style = (0, react_1.css) `
height: 20px;
display: inline-flex;
align-items: center;
`;
if (hideBranding)
return (0, jsx_runtime_1.jsx)("div", { css: style });
return ((0, jsx_runtime_1.jsx)("div", { css: style, children: (0, jsx_runtime_1.jsx)("a", { href: "https://magicbell.io/?utm_source=widget", target: "_blank", rel: "noopener noreferrer", children: (0, jsx_runtime_1.jsx)(MagicBellLogo_js_1.default, {}) }) }));
}
//# sourceMappingURL=FooterLogo.js.map