mirror of
https://github.com/wavetermdev/backup.git
synced 2026-08-05 13:57:07 -07:00
uselayouteffect for window controls overlay callback
This commit is contained in:
@@ -336,7 +336,7 @@ function AppBackground() {
|
||||
}),
|
||||
[bgRef, style]
|
||||
);
|
||||
React.useEffect(getAvgColor, [getAvgColor]);
|
||||
React.useLayoutEffect(getAvgColor, [getAvgColor]);
|
||||
useResizeObserver(bgRef, getAvgColor);
|
||||
|
||||
return <div ref={bgRef} className="app-background" style={style} />;
|
||||
|
||||
Reference in New Issue
Block a user