improve header display behavior

This commit is contained in:
SrGooglo 2023-10-10 13:36:21 +00:00
parent af20663266
commit 5178c719d5
2 changed files with 10 additions and 0 deletions

View File

@ -22,6 +22,14 @@ export default (props) => {
},
})
React.useEffect(() => {
if (render) {
app.layout.toggleDisableTopLayoutPadding(true)
} else {
app.layout.toggleDisableTopLayoutPadding(false)
}
}, [render])
return <Motion
style={{
y: spring(render ? 0 : 100,),

View File

@ -31,6 +31,8 @@
}
&.hidden {
display: none;
opacity: 0;
height: 0;
padding: 0;