mirror of
https://git.youjo.love/youjo/youjo-fe.git
synced 2024-11-20 05:49:54 +01:00
Allow using mouse wheel to navigate through the emoji tabs
This commit is contained in:
parent
169282ea42
commit
e06348ee33
2 changed files with 9 additions and 1 deletions
|
@ -62,6 +62,10 @@ const EmojiPicker = {
|
||||||
this.scrolledGroup(target)
|
this.scrolledGroup(target)
|
||||||
this.triggerLoadMore(target)
|
this.triggerLoadMore(target)
|
||||||
},
|
},
|
||||||
|
onWheel (e) {
|
||||||
|
e.preventDefault()
|
||||||
|
this.$refs['emoji-tabs'].scrollBy(e.deltaY, 0)
|
||||||
|
},
|
||||||
highlight (key) {
|
highlight (key) {
|
||||||
this.setShowStickers(false)
|
this.setShowStickers(false)
|
||||||
this.activeGroup = key
|
this.activeGroup = key
|
||||||
|
|
|
@ -1,7 +1,11 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="emoji-picker panel panel-default panel-body">
|
<div class="emoji-picker panel panel-default panel-body">
|
||||||
<div class="heading">
|
<div class="heading">
|
||||||
<span class="emoji-tabs">
|
<span
|
||||||
|
class="emoji-tabs"
|
||||||
|
@wheel="onWheel"
|
||||||
|
ref="emoji-tabs"
|
||||||
|
>
|
||||||
<span
|
<span
|
||||||
v-for="group in emojis"
|
v-for="group in emojis"
|
||||||
:key="group.id"
|
:key="group.id"
|
||||||
|
|
Loading…
Reference in a new issue