import * as React from "react" ; import { Link } from "react-router-dom" ; import { DashboardActivityItemBaseProps , DashboardActivityItemTitleProps } from "./DashboardTypes" ; import { StyledDashboardActivityItemTitle } from "./DashboardStyledComponents" ; const DashboardActivityItemTitle = props => { const titleChild = props . viewDetailURL ? < Link to = { props . viewDetailURL } > { props . title } < /Link> : props.title; return < StyledDashboardActivityItemTitle > { titleChild } < /StyledDashboardActivityItemTitle>; } ; export default React . memo ( DashboardActivityItemTitle ) ;