updated welsh translations

This commit is contained in:
2023-05-23 10:38:03 +01:00
parent dc43d7f2b4
commit 275258562e
45 changed files with 677 additions and 7698 deletions
+7 -2
View File
@@ -2,6 +2,7 @@ import Document, { Html, Head, Main, NextScript } from "next/document";
import SkipLink from "../components/skiplink";
import { Tracking, TrackingNoScript } from "../components/tracking";
import { nanoid } from "nanoid";
import { setCookie } from "nookies";
class MyDocument extends Document {
static async getInitialProps(ctx) {
@@ -19,12 +20,16 @@ class MyDocument extends Document {
useGATracking = false;
}
setCookie(ctx, "pedw_locale", ctx.locale, {
path: "/",
});
return { ...initialProps, useGATracking };
}
render() {
const googleTagManagerID = process.env.GOOGLE_TAG_MANAGER || null;
const { useGATracking } = this.props;
const { useGATracking, locale } = this.props;
const generatedNonce = nanoid();
@@ -39,7 +44,7 @@ class MyDocument extends Document {
csp += `style-src 'self' https://fonts.googleapis.com 'unsafe-inline' data:;`;
return (
<Html lang="en">
<Html lang={locale}>
<Head>
<meta httpEquiv="Content-Security-Policy" content={csp} />
{useGATracking && (