@kiwicom/smart-faq
Version:
Smart FAQ
55 lines (49 loc) • 1.27 kB
JavaScript
// @flow
import * as React from 'react';
import { NewWindow } from '@kiwicom/orbit-components/lib/icons';
import Translate from '@kiwicom/nitro/lib/components/Translate';
import { withLanguage } from '../context/Language';
type Props = {
translationKey?: string,
textColor?: string,
language: string,
};
const ContactPageLink = ({
translationKey,
textColor = '#171b1e',
language = 'en',
}: Props) => {
return (
<div className="contactUs">
<a target="_blank" href={`/${language}/content/feedback`}>
{translationKey ? (
<Translate t={translationKey} />
) : (
'Go to contact page.'
)}
<span className="open-icon">
<NewWindow size="small" color="attention" customColor={textColor} />
</span>
</a>
<style jsx>
{`
.contactUs {
display: inline-block;
text-align: center;
margin-bottom: 16px;
}
a {
color: ${textColor};
font-size: 14px;
text-decoration: none;
font-weight: bold;
}
a .open-icon {
margin-left: 6px;
}
`}
</style>
</div>
);
};
export default withLanguage(ContactPageLink);