[mobile] fix flickering on editor launch

This commit is contained in:
maxkadushkin
2024-11-27 16:42:46 +03:00
parent 5b5df8f4c4
commit 2d4c909f8b
7 changed files with 32 additions and 12 deletions

View File

@ -14,10 +14,12 @@ body.theme-type-dark {
--background-navbar-word: #232323;
--background-navbar-cell: #232323;
--background-navbar-slide: #232323;
background-color: var(--background-primary, #232323);
}
.skl-navbar {
--box-logo-height: 0;
--box-logo-height: 0px;
--skl-navbar-height: 44px;
--skl-pixel-ratio: 1;
}

View File

@ -90,9 +90,6 @@ const MainPage = inject('storeDocumentInfo', 'users', 'storeAppOptions', 'storeV
}
useEffect(() => {
if ($$('.skl-container').length) {
$$('.skl-container').remove();
}
document.addEventListener('touchmove', touchMoveHandler);

View File

@ -1,4 +1,4 @@
import React, { Fragment } from 'react';
import React, { Fragment, useEffect } from 'react';
import { useTranslation } from 'react-i18next';
import { NavLeft, NavRight, Link } from 'framework7-react';
import { Device } from '../../../../common/mobile/utils/device';
@ -18,7 +18,16 @@ const ToolbarView = props => {
const isMobileView = props.isMobileView;
const docTitle = props.docTitle;
const isOpenModal = props.isOpenModal;
useEffect(() => {
if ( $$('.skl-container').length ) {
$$('.skl-container').remove();
}
return () => {
}
}, []);
return (
<Fragment>
<NavLeft>

View File

@ -126,9 +126,6 @@ class MainPage extends Component {
}
componentDidMount () {
if ($$('.skl-container').length) {
$$('.skl-container').remove();
}
document.addEventListener('touchmove', this.touchMoveHandler);

View File

@ -11,6 +11,15 @@ const ToolbarView = props => {
const isVersionHistoryMode = props.isVersionHistoryMode;
const isOpenModal = props.isOpenModal;
useEffect(() => {
if ( $$('.skl-container').length ) {
$$('.skl-container').remove();
}
return () => {
}
}, []);
return (
<Fragment>
<NavLeft>

View File

@ -119,9 +119,6 @@ class MainPage extends Component {
}
componentDidMount () {
if ($$('.skl-container').length) {
$$('.skl-container').remove();
}
document.addEventListener('touchmove', this.touchMoveHandler);

View File

@ -20,6 +20,15 @@ const ToolbarView = props => {
const isVersionHistoryMode = props.isVersionHistoryMode;
const isOpenModal = props.isOpenModal;
useEffect(() => {
if ( $$('.skl-container').length ) {
$$('.skl-container').remove();
}
return () => {
}
}, []);
return (
<Fragment>
<NavLeft>