make header scrollable Y->X

This commit is contained in:
Henry Jameson 2024-12-23 23:15:35 +02:00
parent e2bcbd51bb
commit 0bbdea0e90
2 changed files with 7 additions and 1 deletions

View file

@ -135,6 +135,9 @@ const EmojiPicker = {
Popover
},
methods: {
groupScroll (e) {
e.currentTarget.scrollLeft += e.deltaY + e.deltaX
},
updateEmojiSize () {
const css = window.getComputedStyle(this.$refs.popover.$el)
const emojiSize = css.getPropertyValue('--emojiSize')

View file

@ -8,7 +8,9 @@
@close="onPopoverClosed"
>
<template #content>
<div class="heading">
<div
class="heading"
>
<!--
Body scroll lock needs to be on every scrollable element on safari iOS.
Here we tell it to enable scrolling for this element.
@ -18,6 +20,7 @@
ref="header"
v-body-scroll-lock="isInModal"
class="emoji-tabs"
@wheel.prevent="groupScroll"
>
<span
v-for="group in filteredEmojiGroups"