Middle Column: Fix Scroll Down Button positioning (#1419)
This commit is contained in:
parent
663dffe18b
commit
e88de90ac7
@ -302,6 +302,7 @@
|
|||||||
.messaging-disabled {
|
.messaging-disabled {
|
||||||
.mask-image-disabled & {
|
.mask-image-disabled & {
|
||||||
box-shadow: 0 .25rem .5rem .125rem var(--color-default-shadow);
|
box-shadow: 0 .25rem .5rem .125rem var(--color-default-shadow);
|
||||||
|
border-radius: var(--border-radius-messages);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -270,6 +270,8 @@ const MiddleColumn: FC<StateProps & DispatchProps> = ({
|
|||||||
useHistoryBack(isMobileSearchActive, closeLocalTextSearch);
|
useHistoryBack(isMobileSearchActive, closeLocalTextSearch);
|
||||||
useHistoryBack(isSelectModeActive, exitMessageSelectMode);
|
useHistoryBack(isSelectModeActive, exitMessageSelectMode);
|
||||||
|
|
||||||
|
const isMessagingDisabled = Boolean(!isPinnedMessageList && !renderingCanPost && messageSendingRestrictionReason);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
id="MiddleColumn"
|
id="MiddleColumn"
|
||||||
@ -348,7 +350,7 @@ const MiddleColumn: FC<StateProps & DispatchProps> = ({
|
|||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
{!isPinnedMessageList && !renderingCanPost && messageSendingRestrictionReason && (
|
{isMessagingDisabled && (
|
||||||
<div className={messagingDisabledClassName}>
|
<div className={messagingDisabledClassName}>
|
||||||
<div className="messaging-disabled-inner">
|
<div className="messaging-disabled-inner">
|
||||||
<span>
|
<span>
|
||||||
@ -370,6 +372,7 @@ const MiddleColumn: FC<StateProps & DispatchProps> = ({
|
|||||||
<ScrollDownButton
|
<ScrollDownButton
|
||||||
isShown={renderingIsFabShown}
|
isShown={renderingIsFabShown}
|
||||||
canPost={renderingCanPost}
|
canPost={renderingCanPost}
|
||||||
|
withExtraShift={isMessagingDisabled || isSelectModeActive || isPinnedMessageList}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
{IS_SINGLE_COLUMN_LAYOUT && <MobileSearch isActive={Boolean(isMobileSearchActive)} />}
|
{IS_SINGLE_COLUMN_LAYOUT && <MobileSearch isActive={Boolean(isMobileSearchActive)} />}
|
||||||
|
|||||||
@ -61,7 +61,7 @@
|
|||||||
opacity: 1;
|
opacity: 1;
|
||||||
pointer-events: all;
|
pointer-events: all;
|
||||||
|
|
||||||
&.no-composer {
|
&.no-composer:not(.with-extra-shift) {
|
||||||
transform: translateY(4rem);
|
transform: translateY(4rem);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -20,6 +20,7 @@ import './ScrollDownButton.scss';
|
|||||||
type OwnProps = {
|
type OwnProps = {
|
||||||
isShown: boolean;
|
isShown: boolean;
|
||||||
canPost?: boolean;
|
canPost?: boolean;
|
||||||
|
withExtraShift?: boolean;
|
||||||
};
|
};
|
||||||
|
|
||||||
type StateProps = {
|
type StateProps = {
|
||||||
@ -36,6 +37,7 @@ const ScrollDownButton: FC<OwnProps & StateProps & DispatchProps> = ({
|
|||||||
canPost,
|
canPost,
|
||||||
messageListType,
|
messageListType,
|
||||||
unreadCount,
|
unreadCount,
|
||||||
|
withExtraShift,
|
||||||
focusNextReply,
|
focusNextReply,
|
||||||
}) => {
|
}) => {
|
||||||
const lang = useLang();
|
const lang = useLang();
|
||||||
@ -65,6 +67,7 @@ const ScrollDownButton: FC<OwnProps & StateProps & DispatchProps> = ({
|
|||||||
'ScrollDownButton',
|
'ScrollDownButton',
|
||||||
isShown && 'revealed',
|
isShown && 'revealed',
|
||||||
!canPost && 'no-composer',
|
!canPost && 'no-composer',
|
||||||
|
withExtraShift && 'with-extra-shift',
|
||||||
);
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user