mirror of
https://github.com/revoltchat/revite.git
synced 2024-11-09 16:53:36 -05:00
fix(home / seasonal): correctly read state
This commit is contained in:
parent
bb707fb287
commit
5797eb3686
1 changed files with 3 additions and 6 deletions
|
@ -45,13 +45,10 @@ export default observer(() => {
|
|||
const client = useContext(AppContext);
|
||||
const state = useApplicationState();
|
||||
|
||||
const toggleSeasonalTheme = () =>
|
||||
state.settings.set(
|
||||
"appearance:seasonal",
|
||||
!state.settings.get("appearance:seasonal"),
|
||||
);
|
||||
|
||||
const seasonalTheme = state.settings.get("appearance:seasonal", true);
|
||||
const toggleSeasonalTheme = () =>
|
||||
state.settings.set("appearance:seasonal", !seasonalTheme);
|
||||
|
||||
const isDecember = !isTouchscreenDevice && new Date().getMonth() === 11;
|
||||
const snowflakes = useMemo(() => {
|
||||
const flakes = [];
|
||||
|
|
Loading…
Reference in a new issue