forked from pub-solar/pub.solar
v2: Fix german translations for hakken page
This commit is contained in:
parent
a9cffb80b8
commit
4e80a7e6de
|
@ -43,13 +43,13 @@ const getStartAndEnd = (date) => {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
export default ({ data, lang, className = '', }) => {
|
export default ({ data, language, className = '', }) => {
|
||||||
const strings = data.strings;
|
const strings = data.strings;
|
||||||
const dates = data.dates;
|
const dates = data.dates;
|
||||||
const t = (o) => o?.[lang] || '';
|
const t = (o) => o?.[language.slug] || '';
|
||||||
|
|
||||||
return <section
|
return <section
|
||||||
id={`dates-list-${lang}`}
|
id={`dates-list-${language.slug}`}
|
||||||
className={`ps-hakken-dates ${className}`}
|
className={`ps-hakken-dates ${className}`}
|
||||||
>
|
>
|
||||||
<h3>{t(strings.comingDates)}</h3>
|
<h3>{t(strings.comingDates)}</h3>
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
export default ({ otherLang, baseURL }) => <a
|
export default ({ otherLang, baseURL }) => <a
|
||||||
href={otherLang.urlPrefix ? `/${otherLang.urlPrefix }${baseURL}` : baseURL}
|
href={otherLang.urlPrefix ? `/${otherLang.urlPrefix }${baseURL}` : baseURL}
|
||||||
class="ps-homelink ps-homelink_lang"
|
className="ps-homelink ps-homelink_lang"
|
||||||
>{otherLang.slug}</a>
|
>{otherLang.slug}</a>
|
||||||
|
|
|
@ -45,8 +45,8 @@ export default ({
|
||||||
<main className="ps-main--page ps-page">
|
<main className="ps-main--page ps-page">
|
||||||
<div className="ps-page--contents">
|
<div className="ps-page--contents">
|
||||||
<section dangerouslySetInnerHTML={{ __html: md(content) }}></section>
|
<section dangerouslySetInnerHTML={{ __html: md(content) }}></section>
|
||||||
{showServices ? <Services lang="en" language={language} data={services} /> : null}
|
{showServices ? <Services language={language} data={services} /> : null}
|
||||||
{showHakkenDates ? <HakkenDates lang="en" data={hakken} /> : null}
|
{showHakkenDates ? <HakkenDates language={language} data={hakken} /> : null}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</main>
|
</main>
|
||||||
|
|
Loading…
Reference in a new issue