Profile: Fix scrolling to tap on Android

This commit is contained in:
Alexander Zinchuk 2021-08-27 21:09:06 +03:00
parent 5a444dbb50
commit 94d6a5d5eb
2 changed files with 2 additions and 6 deletions

View File

@ -288,14 +288,10 @@ const RightHeader: FC<OwnProps & StateProps & DispatchProps> = ({
const buttonClassName = buildClassName(
'animated-close-icon',
isBackButton && 'state-back',
(shouldSkipTransition || shouldSkipAnimation) && 'no-transition',
);
// Add class in the next AF to synchronize with animation with Transition components
useEffect(() => {
backButtonRef.current!.classList.toggle('state-back', isBackButton);
}, [isBackButton]);
return (
<div className="RightHeader">
<Button

View File

@ -47,7 +47,7 @@ export default function useProfileState(
}
const tabListEl = container.querySelector<HTMLDivElement>('.TabList');
if (!tabListEl || tabListEl.offsetTop > container.scrollTop) {
if (!tabListEl) {
return;
}