Scheduling infrastructure for absolutely everyone.
fix: Bring back dir attr using Intl (#11806)
Alex van Andelff3a9d03a4c2
diff --git a/apps/web/pages/_document.tsx b/apps/web/pages/_document.tsxindex a033102ee51..06564ead2d2 100644--- a/apps/web/pages/_document.tsx+++ b/apps/web/pages/_document.tsx@@ -50,9 +50,18 @@ class MyDocument extends Document<Props> {const nonceParsed = z.string().safeParse(this.props.nonce);const nonce = nonceParsed.success ? nonceParsed.data : "";++ const intlLocale = new Intl.Locale(newLocale);+ // @ts-expect-error INFO: Typescript does not know about the Intl.Locale textInfo attribute+ const direction = intlLocale.textInfo?.direction;+ if (!direction) {+ throw new Error("NodeJS major breaking change detected, use getTextInfo() instead.");+ }+return (<Htmllang={newLocale}+ dir={direction}style={embedColorScheme ? { colorScheme: embedColorScheme as string } : undefined}><Head nonce={nonce}><script