Fix config editor breaking on non-100% zoom levels

This commit is contained in:
Dragory 2020-04-08 23:50:56 +03:00
parent 48a9e0e883
commit 2c0bcb012a
No known key found for this signature in database
GPG key ID: 5F387BA66DF8AAC1

View file

@ -101,7 +101,7 @@
const editorElem = this.$refs.aceEditor.$el; const editorElem = this.$refs.aceEditor.$el;
const newWidth = editorElem.parentNode.clientWidth; const newWidth = editorElem.parentNode.clientWidth;
const rect = editorElem.getBoundingClientRect(); const rect = editorElem.getBoundingClientRect();
const newHeight = window.innerHeight - rect.top - 48; const newHeight = Math.round(window.innerHeight - rect.top - 48);
this.resizeEditor(newWidth, newHeight); this.resizeEditor(newWidth, newHeight);
}, },
resizeEditor(newWidth, newHeight) { resizeEditor(newWidth, newHeight) {