fic: certification links now open in a new tab (#39180)

This commit is contained in:
David Sykes
2020-07-27 13:45:40 +01:00
committed by GitHub
parent de3492fded
commit 17d9b43747
2 changed files with 5 additions and 5 deletions

View File

@ -1,14 +1,12 @@
import React, { Fragment } from 'react';
import PropTypes from 'prop-types';
import { Link } from 'gatsby';
import { curry } from 'lodash';
import { createSelector } from 'reselect';
import { connect } from 'react-redux';
import { Row, Col } from '@freecodecamp/react-bootstrap';
import { certificatesByNameSelector } from '../../../redux';
import FullWidthRow from '../../helpers/FullWidthRow';
import { ButtonSpacer, Spacer } from '../../helpers';
import { ButtonSpacer, FullWidthRow, Link, Spacer } from '../../helpers';
import './certifications.css';
const mapStateToProps = (state, props) =>
@ -45,6 +43,7 @@ function renderCertShow(username, cert) {
<Col className='certifications' sm={10} smPush={1}>
<Link
className='btn btn-lg btn-primary btn-block'
external={true}
to={`/certification/${username}/${cert.showURL}`}
>
View {cert.title}

View File

@ -3,10 +3,10 @@ import PropTypes from 'prop-types';
import format from 'date-fns/format';
import { find, reverse, sortBy } from 'lodash';
import { Button, Modal, Table } from '@freecodecamp/react-bootstrap';
import { Link, useStaticQuery, graphql } from 'gatsby';
import { useStaticQuery, graphql } from 'gatsby';
import TimelinePagination from './TimelinePagination';
import { FullWidthRow } from '../../helpers';
import { FullWidthRow, Link } from '../../helpers';
import SolutionViewer from '../../settings/SolutionViewer';
import {
getCertIds,
@ -88,6 +88,7 @@ class TimelineInner extends Component {
{certPath ? (
<Link
className='timeline-cert-link'
external={true}
to={`certification/${username}/${certPath}`}
>
{challengeTitle}