import * as classNames from 'classnames';
import CountUp from 'react-countup';
import { throttle } from 'lodash';
-import { Link } from 'react-router';
import { FeaturedProject } from '../utils';
import CoverageRating from '../../../../components/ui/CoverageRating';
import DuplicationsRating from '../../../../components/ui/DuplicationsRating';
import Rating from '../../../../components/ui/Rating';
import { formatMeasure } from '../../../../helpers/measures';
import { getMetricName } from '../../../overview/utils';
-import { getProjectUrl, getBaseUrl } from '../../../../helpers/urls';
+import { getProjectUrl, getBaseUrl, getPathUrlAsString } from '../../../../helpers/urls';
import './FeaturedProjects.css';
interface Props {
export function ProjectCard({ project, order, viewable }: ProjectCardProps) {
return (
<div className="sc-project-card-container" style={{ order }}>
- <Link className="sc-project-card" to={getProjectUrl(project.key)}>
+ <a className="sc-project-card" href={getPathUrlAsString(getProjectUrl(project.key))}>
<div className="sc-project-card-header">
<OrganizationAvatar
className="no-border spacer-bottom"
distribution={project.languages.join(';')}
/>
</div>
- </Link>
+ </a>
</div>
);
}
}
}
>
- <Link
+ <a
className="sc-project-card"
- onlyActiveOnIndex={false}
- style={Object {}}
- to={
- Object {
- "pathname": "/dashboard",
- "query": Object {
- "branch": undefined,
- "id": "sonarsource-jfrog.simple-js-php-project",
- },
- }
- }
+ href="/dashboard?id=sonarsource-jfrog.simple-js-php-project"
>
<div
className="sc-project-card-header"
distribution="js;php"
/>
</div>
- </Link>
+ </a>
</div>
`;