mirror of
https://github.com/chinchang/web-maker.git
synced 2025-07-29 17:50:09 +02:00
adjust body height when window resizes/zooms
This commit is contained in:
@@ -505,7 +505,12 @@ export default class App extends Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
componentDidMount() {
|
componentDidMount() {
|
||||||
document.body.style.height = `${window.innerHeight}px`;
|
function setBodySize() {
|
||||||
|
document.body.style.height = `${window.innerHeight}px`;
|
||||||
|
}
|
||||||
|
window.addEventListener('resize', () => {
|
||||||
|
setBodySize();
|
||||||
|
});
|
||||||
|
|
||||||
// Editor keyboard shortucuts
|
// Editor keyboard shortucuts
|
||||||
window.addEventListener('keydown', event => {
|
window.addEventListener('keydown', event => {
|
||||||
|
Reference in New Issue
Block a user