UNPKG

@actinc/dls

Version:

Design Language System (DLS) for ACT & Encoura front-end projects.

39 lines 1.51 kB
var __assign = (this && this.__assign) || function () { __assign = Object.assign || function(t) { for (var s, i = 1, n = arguments.length; i < n; i++) { s = arguments[i]; for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; } return t; }; return __assign.apply(this, arguments); }; import { jsx as _jsx } from "react/jsx-runtime"; /** * Copyright (c) ACT, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ import Link, { linkClasses } from '@mui/material/Link'; import { styled } from "../../../helpers/styled"; import { StyledTypography } from './styles'; var RenderNavigationItem = function (_a) { var isActive = _a.isActive, LinkComponent = _a.LinkComponent, linkProps = _a.LinkProps, title = _a.title; var StyledLink = styled(LinkComponent || Link)(function () { var _a; return (_a = {}, _a["&.".concat(linkClasses.root)] = { '&, &:hover': { color: 'unset', textDecoration: 'none', }, cursor: 'pointer', }, _a); }); return (_jsx(StyledLink, __assign({}, linkProps, { children: _jsx(StyledTypography, { "$isActive": isActive, color: "primary", children: title }) }))); }; export default RenderNavigationItem; //# sourceMappingURL=index.js.map