fix news button translation

This commit is contained in:
Aarni Halinen
2021-04-01 18:11:28 +03:00
parent feaaa981bd
commit 1f7d842b89
2 changed files with 8 additions and 2 deletions
+7 -1
View File
@@ -6,7 +6,13 @@ import Icon, { IconType } from "./Icon";
const ChangeLanguageButton: React.FC = (props) => {
const { language, changeLanguage } = i18nNext.i18n;
return (
<button {...props} type="button" onClick={() => changeLanguage(language === "fi" ? "en" : "fi")}>
<button
{...props}
type="button"
onClick={() => {
changeLanguage(language === "fi" ? "en" : "fi");
}}
>
<Icon name={language === "fi" ? IconType.GBFlag : IconType.FinlandFlag} />
</button>
);
+1 -1
View File
@@ -59,7 +59,7 @@ const News: React.FC<NewsProps> = ({ feed }) => {
text={post.description}
link={`/feed/${post.id}`}
buttonOnClick={noop}
buttonText={t("Lue lisää ")}
buttonText={`${t("Lue lisää")} `}
/>
))}
</CardSection>