Commit 096cad2
Joel Klabo
fix: ensure theme toggle uses current theme value
Previously the theme toggle callback referenced nextTheme which was
computed at render time. Now it computes the new theme value inline
to avoid any potential stale closure issues.
Fixes #2921 parent 6723808 commit 096cad2
1 file changed
Lines changed: 4 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
71 | | - | |
| 71 | + | |
| 72 | + | |
72 | 73 | | |
73 | | - | |
| 74 | + | |
74 | 75 | | |
75 | 76 | | |
76 | | - | |
| 77 | + | |
77 | 78 | | |
78 | 79 | | |
79 | 80 | | |
| |||
0 commit comments