diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2018-02-14 19:33:39 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2018-02-14 19:33:39 +0900 |
| commit | 00aaf300c4a8175a0412de93dc9392a647ab5bfa (patch) | |
| tree | 8b87a553199c46d3ffe721a8e6c7ed1ac3241239 /src | |
| parent | wip (diff) | |
| download | misskey-00aaf300c4a8175a0412de93dc9392a647ab5bfa.tar.gz misskey-00aaf300c4a8175a0412de93dc9392a647ab5bfa.tar.bz2 misskey-00aaf300c4a8175a0412de93dc9392a647ab5bfa.zip | |
wip
Diffstat (limited to 'src')
| -rw-r--r-- | src/web/app/desktop/views/components/window.vue | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/web/app/desktop/views/components/window.vue b/src/web/app/desktop/views/components/window.vue index 3a7531a6f1..414858a1e5 100644 --- a/src/web/app/desktop/views/components/window.vue +++ b/src/web/app/desktop/views/components/window.vue @@ -82,13 +82,15 @@ export default Vue.extend({ }, mounted() { - const main = this.$refs.main as any; - main.style.top = '15%'; - main.style.left = (window.innerWidth / 2) - (main.offsetWidth / 2) + 'px'; + Vue.nextTick(() => { + const main = this.$refs.main as any; + main.style.top = '15%'; + main.style.left = (window.innerWidth / 2) - (main.offsetWidth / 2) + 'px'; - window.addEventListener('resize', this.onBrowserResize); + window.addEventListener('resize', this.onBrowserResize); - this.open(); + this.open(); + }); }, destroyed() { |