Skip to content

Commit 9d9f103

Browse files
authored
fix: light dark hook theme check (#676)
1 parent c2bd615 commit 9d9f103

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/little-turtles-shake.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@utilitywarehouse/native-ui': patch
3+
---
4+
5+
Fix `useLightDark` theme name check

packages/native-ui/src/hooks/useLightDark.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import { UnistylesRuntime } from 'react-native-unistyles';
44

55
const useLightDark = (light: any, dark: any) => {
6-
return UnistylesRuntime.getTheme() === 'light' ? light : dark;
6+
return UnistylesRuntime.themeName === 'light' ? light : dark;
77
};
88

99
export default useLightDark;

0 commit comments

Comments
 (0)