diff options
author | Paul Slaughter <pslaughter@gitlab.com> | 2018-07-25 19:31:25 +0300 |
---|---|---|
committer | Paul Slaughter <pslaughter@gitlab.com> | 2018-07-25 19:31:25 +0300 |
commit | a8e599f86ec1698ae1d6b1d3941196debdf6db99 (patch) | |
tree | d27790df80e8f872075f2bd84a52153700ad4637 /app/assets/javascripts/vue_shared/components/panel_resizer.vue | |
parent | 8b0f926a558a04578636a0354c06e4cec1db9c3b (diff) |
Fix Web IDE editor resizing on sidebar reset size
Diffstat (limited to 'app/assets/javascripts/vue_shared/components/panel_resizer.vue')
-rw-r--r-- | app/assets/javascripts/vue_shared/components/panel_resizer.vue | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/assets/javascripts/vue_shared/components/panel_resizer.vue b/app/assets/javascripts/vue_shared/components/panel_resizer.vue index 438b2fee159..7947ae1e4da 100644 --- a/app/assets/javascripts/vue_shared/components/panel_resizer.vue +++ b/app/assets/javascripts/vue_shared/components/panel_resizer.vue @@ -44,8 +44,15 @@ methods: { resetSize(e) { e.preventDefault(); + this.$emit('resize-start', this.size); + this.size = this.startSize; this.$emit('update:size', this.size); + + // End resizing on next tick so that listeners can react to DOM changes + this.$nextTick(() => { + this.$emit('resize-end', this.size); + }); }, startDrag(e) { if (this.enabled) { |