Auto adjust window size

This commit is contained in:
syuilo 2020-10-19 19:42:55 +09:00
parent 6932d86240
commit 87b15df47b

View File

@ -315,11 +315,13 @@ export default defineComponent({
// //
applyTransformHeight(height) { applyTransformHeight(height) {
if (height > window.innerHeight) height = window.innerHeight;
(this.$el as any).style.height = height + 'px'; (this.$el as any).style.height = height + 'px';
}, },
// //
applyTransformWidth(width) { applyTransformWidth(width) {
if (width > window.innerWidth) width = window.innerWidth;
(this.$el as any).style.width = width + 'px'; (this.$el as any).style.width = width + 'px';
}, },