Merge branch 'develop' of github.com:ONLYOFFICE/DocSpace into develop

This commit is contained in:
Alexey Safronov 2022-09-08 15:03:48 +03:00
commit 5ee228ffbd
3 changed files with 5 additions and 23 deletions

View File

@ -142,7 +142,7 @@ const Layout = (props) => {
// }
const bannerHeight = isBannerVisible ? 80 : 0;
let vh = (windowHeight - 48 - bannerHeight) * 0.01;
let vh = (windowHeight - bannerHeight) * 0.01;
document.documentElement.style.setProperty("--vh", `${vh}px`);
setContentHeight(height);
};
@ -186,6 +186,6 @@ export default inject(({ auth, bannerStore }) => {
return {
isTabletView: auth.settingsStore.isTabletView,
setIsTabletView: auth.settingsStore.setIsTabletView,
isBannerVisible: bannerStore.isBannerVisible,
isBannerVisible: false, // bannerStore.isBannerVisible, TODO: use isBannerVisible from bannerStore after fix
};
})(observer(Layout));

View File

@ -19,30 +19,11 @@ const StyledMain = styled.main`
`;
const Main = React.memo((props) => {
// const orientationChanged = React.useCallback(() => {
// if (isIOS && !isFirefox) {
// let vh = (window.innerHeight - 48) * 0.01;
// document.documentElement.style.setProperty("--vh", `${vh}px`);
// }
// }, []);
// React.useEffect(() => {
// orientationChanged();
// if (isIOS && !isFirefox) {
// window.addEventListener("resize", orientationChanged);
// }
// return () => window.removeEventListener("resize", orientationChanged);
// }, []);
//console.log("Main render");
return <StyledMain className="main" {...props} />;
});
/*Main.defaultProps = {
fullscreen: false
};*/
Main.displayName = "Main";
export default Main;

View File

@ -28,7 +28,7 @@ class DeleteProfileEverDialogComponent extends React.Component {
};
}
onDeleteProfileEver = () => {
const { user, t, history, homepage, setFilter } = this.props;
const { user, t, history, homepage, setFilter, onClose } = this.props;
const filter = Filter.getDefault();
const params = filter.toUrlParams();
@ -47,7 +47,8 @@ class DeleteProfileEverDialogComponent extends React.Component {
setFilter(filter);
return;
})
.catch((error) => toastr.error(error));
.catch((error) => toastr.error(error))
.finally(() => onClose());
});
};