internal links now use the Link component instead of the LinkContainer component, because the later is intended for use with react-bootstrap components and not for simple translated strings.

Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
Philip Molares 2020-06-06 11:45:54 +02:00 committed by Philip Molares
parent a376c95fab
commit 575407ab6d

View file

@ -1,11 +1,11 @@
import React, { Fragment } from 'react' import React, { Fragment } from 'react'
import { LinkContainer } from 'react-router-bootstrap' import { Link } from 'react-router-dom'
import { ForkAwesomeIcon } from '../../fork-awesome/fork-awesome-icon' import { ForkAwesomeIcon } from '../../fork-awesome/fork-awesome-icon'
import { LinkWithTextProps } from './types' import { LinkWithTextProps } from './types'
export const InternalLink: React.FC<LinkWithTextProps> = ({ href, text, icon, className = 'text-light' }) => { export const InternalLink: React.FC<LinkWithTextProps> = ({ href, text, icon, className = 'text-light' }) => {
return ( return (
<LinkContainer to={href} <Link to={href}
className={className}> className={className}>
<Fragment> <Fragment>
{ {
@ -17,6 +17,6 @@ export const InternalLink: React.FC<LinkWithTextProps> = ({ href, text, icon, cl
} }
{text} {text}
</Fragment> </Fragment>
</LinkContainer> </Link>
) )
} }