Commit 2273e500 authored by Tae Hoon's avatar Tae Hoon

detect body height change

parent dc766c1d
......@@ -46,9 +46,6 @@ const FloatingPostButton = {
} else {
this.deactivateFloatingPostButtonAutohide()
}
},
postStatusForms () {
this.$nextTick(() => this.checkHoverInlineReply())
}
},
methods: {
......@@ -56,11 +53,13 @@ const FloatingPostButton = {
window.addEventListener('scroll', this.handleScrollStart)
window.addEventListener('scroll', this.handleScrollEnd)
window.addEventListener('resize', this.handleResize)
window.addResizeListener(document.body, this.checkHoverInlineReply)
},
deactivateFloatingPostButtonAutohide () {
window.removeEventListener('scroll', this.handleScrollStart)
window.removeEventListener('scroll', this.handleScrollEnd)
window.removeEventListener('resize', this.handleResize)
window.removeResizeListener(document.body, this.checkHoverInlineReply)
},
openPostForm () {
this.$store.dispatch('openPostStatusModal')
......
......@@ -29,6 +29,7 @@ import VueClickOutside from 'v-click-outside'
import PortalVue from 'portal-vue'
import VBodyScrollLock from './directives/body_scroll_lock'
import VTooltip from 'v-tooltip'
import 'javascript-detect-element-resize'
import afterStoreSetup from './boot/after_store.js'
......
......@@ -4330,6 +4330,11 @@ istanbul@0.4.5, istanbul@^0.4.0:
which "^1.1.1"
wordwrap "^1.0.0"
javascript-detect-element-resize@^0.5.3:
version "0.5.3"
resolved "https://registry.yarnpkg.com/javascript-detect-element-resize/-/javascript-detect-element-resize-0.5.3.tgz#1a71cd51dfe565907f299012fe73a294104025de"
integrity sha1-GnHNUd/lZZB/KZAS/nOilBBAJd4=
js-base64@^2.1.9:
version "2.5.0"
resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-2.5.0.tgz#42255ba183ab67ce59a0dee640afdc00ab5ae93e"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment