Fix breaking layout in desktop PWA mode

Fix chat border-left
This commit is contained in:
Eduard Kuzmenko 2021-05-13 04:44:31 +04:00
parent 9f52b147b9
commit 4822a2867e
4 changed files with 9 additions and 4 deletions

View File

@ -101,7 +101,7 @@ export default class ChatInput {
public sendSilent: true;
private recorder: any;
private recording = false;
public recording = false;
private recordCanceled = false;
private recordTimeEl: HTMLElement;
private recordRippleEl: HTMLElement;

View File

@ -289,7 +289,7 @@ export default class ChatSelection {
}
} */
blurActiveElement(); // * for mobile keyboards
blurActiveElement();
let transform = '', borderRadius = '';
const forwards = !!this.selectedMids.size || forceSelection;

View File

@ -486,7 +486,10 @@ export class AppImManager {
e.target !== chat.input.messageInput &&
target.tagName !== 'INPUT' &&
!target.hasAttribute('contenteditable') &&
!isTouchSupported) {
!isTouchSupported &&
(!mediaSizes.isMobile || this.tabId === 1) &&
!this.chat.selection.isSelecting &&
!this.chat.input.recording) {
chat.input.messageInput.focus();
placeCaretAtEnd(chat.input.messageInput);
}
@ -689,6 +692,7 @@ export class AppImManager {
}
this.tabId = id;
blurActiveElement();
if(mediaSizes.isMobile && prevTabId === 2 && id < 2) {
document.body.classList.remove(RIGHT_COLUMN_ACTIVE_CLASSNAME);
}

View File

@ -484,7 +484,8 @@ $chat-helper-size: 39px;
}
body.is-left-column-shown & {
transform: translate3d(26.5rem, 0, 0);
//transform: translate3d(26.5rem, 0, 0);
transform: translate3d(26.5625rem, 0, 0); // + 1px to show left border
.sidebar-close-button {
transform: rotate(180deg);