feat(dashboard): auto light/dark mode
All checks were successful
Build and Publish Docker Image / build-and-push (push) Successful in 1m13s
All checks were successful
Build and Publish Docker Image / build-and-push (push) Successful in 1m13s
impelemnt auto light/dark mode based on lat/lon Co-authored-by: Ona <no-reply@ona.com>
This commit is contained in:
@@ -16,6 +16,7 @@ import {
|
||||
stepToBrightness,
|
||||
} from "./light-control"
|
||||
import { StatusSeverity, TubeLine, formatLineName, tflDisruptionsQuery } from "./tfl"
|
||||
import { useAutoTheme } from "./use-auto-theme"
|
||||
import {
|
||||
DEFAULT_LATITUDE,
|
||||
DEFAULT_LONGITUDE,
|
||||
@@ -32,6 +33,8 @@ function App() {
|
||||
|
||||
const store = useStore()
|
||||
|
||||
useAutoTheme(DEFAULT_LATITUDE, DEFAULT_LONGITUDE)
|
||||
|
||||
useEffect(() => {
|
||||
const ws = websocket.current
|
||||
|
||||
|
||||
Reference in New Issue
Block a user