From e05e0d5bf8fe6aa4f43f42e6717e45b544084196 Mon Sep 17 00:00:00 2001 From: Blake Mason Date: Tue, 21 Nov 2023 15:16:00 -0800 Subject: [PATCH] [F] Rockman pop up uses site language --- pages/_app.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pages/_app.js b/pages/_app.js index d3bb646f..9c35e57e 100644 --- a/pages/_app.js +++ b/pages/_app.js @@ -14,9 +14,11 @@ const PLAUSIBLE_DOMAIN = process.env.NEXT_PUBLIC_PLAUSIBLE_DOMAIN; const SURVEY_SPARROW = process.env.NEXT_PUBLIC_SURVEY_SPARROW; function Client({ Component, pageProps }) { + const lang = pageProps?.data?.language || "en-US"; + const authData = useAuthentication({ typeHandle: pageProps?.data?.typeHandle || "", - language: pageProps?.data?.language || "en-US", + language: lang, localized: pageProps?.data?.localized || [], }); @@ -85,7 +87,7 @@ function Client({ Component, pageProps }) { rm.parentNode.removeChild(rm); } } - sparrowLaunch({/*add custom params here*/}); + sparrowLaunch({sparrowLang: "${lang}"}); `, }} />