From 0be849fdf0dd922dbf931097b6cf3a5c1fccda11 Mon Sep 17 00:00:00 2001 From: Mark Zheleznyakov Date: Thu, 27 Nov 2025 11:11:27 +0300 Subject: [PATCH] =?UTF-8?q?fix(frontend):=20=D0=A0=D0=B0=D0=B1=D0=BE=D1=82?= =?UTF-8?q?=D0=B0=20=D1=81=20=D1=86=D0=B2=D0=B5=D1=82=D0=BE=D0=B2=D1=8B?= =?UTF-8?q?=D0=BC=D0=B8=20=D1=81=D1=85=D0=B5=D0=BC=D0=B0=D0=BC=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/frontend/components/useColorScheme.ts | 1 - apps/frontend/components/useColorScheme.web.ts | 8 ++++++++ 2 files changed, 8 insertions(+), 1 deletion(-) delete mode 100644 apps/frontend/components/useColorScheme.ts create mode 100644 apps/frontend/components/useColorScheme.web.ts diff --git a/apps/frontend/components/useColorScheme.ts b/apps/frontend/components/useColorScheme.ts deleted file mode 100644 index 17e3c63..0000000 --- a/apps/frontend/components/useColorScheme.ts +++ /dev/null @@ -1 +0,0 @@ -export { useColorScheme } from 'react-native'; diff --git a/apps/frontend/components/useColorScheme.web.ts b/apps/frontend/components/useColorScheme.web.ts new file mode 100644 index 0000000..6dcd80d --- /dev/null +++ b/apps/frontend/components/useColorScheme.web.ts @@ -0,0 +1,8 @@ +// NOTE: The default React Native styling doesn't support server rendering. +// Server rendered styles should not change between the first render of the HTML +// and the first render on the client. Typically, web developers will use CSS media queries +// to render different styles on the client and server, these aren't directly supported in React Native +// but can be achieved using a styling library like Nativewind. +export function useColorScheme() { + return 'light'; +}