Use StillImage to render emojis in emoji picker
This commit is contained in:
parent
c93da0b865
commit
b77259a9a0
4 changed files with 36 additions and 8 deletions
|
|
@ -118,8 +118,19 @@ const EmojiPicker = {
|
|||
},
|
||||
initializeLazyLoad () {
|
||||
this.destroyLazyLoad()
|
||||
this.$lozad = lozad('img', {})
|
||||
this.$lozad.observe()
|
||||
this.$nextTick(() => {
|
||||
this.$lozad = lozad('.still-image.emoji-picker-emoji', {
|
||||
load: el => {
|
||||
const vn = el.__vue__
|
||||
if (!vn) {
|
||||
return
|
||||
}
|
||||
|
||||
vn.loadLazy()
|
||||
}
|
||||
})
|
||||
this.$lozad.observe()
|
||||
})
|
||||
},
|
||||
waitForDomAndInitializeLazyLoad () {
|
||||
this.$nextTick(() => this.initializeLazyLoad())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue