Fix hidden topbar again

This commit is contained in:
Eduard Kuzmenko 2022-03-28 22:17:17 +03:00
parent 481666bc82
commit 18f560ad4b
2 changed files with 5 additions and 4 deletions

4
.env
View File

@ -1,5 +1,5 @@
API_ID=1025907
API_HASH=452b0359b988148995f22ff0f4229750
VERSION=1.4.0
VERSION_FULL=1.4.0 (140)
BUILD=140
VERSION_FULL=1.4.0 (141)
BUILD=141

View File

@ -868,12 +868,13 @@ export default class ChatTopbar {
public setFloating = () => {
const containers = [this.chatAudio, this.pinnedMessage && this.pinnedMessage.pinnedMessageContainer].filter(Boolean);
const count = containers.reduce((acc, container) => {
const isFloating = container.isFloating();
this.container.classList.toggle(`is-pinned-${container.className}-floating`, isFloating);
if(!container.isVisible()) {
return acc;
}
const isFloating = container.isFloating();
this.container.classList.toggle(`is-pinned-${container.className}-floating`, isFloating);
return acc + +isFloating;
}, 0);
this.container.dataset.floating = '' + count;