logo

pleroma-fe

My custom branche(s) on git.pleroma.social/pleroma/pleroma-fe git clone https://hacktivis.me/git/pleroma-fe.git
commit: 76019d1e0349ecf170d660b8324145677b1e472c
parent a7387332ed3a3a26de1f818d0bf6b967ab778d4a
Author: tusooa <tusooa@kazv.moe>
Date:   Fri,  6 Jan 2023 13:14:38 -0500

Fix emoji picker off-by-1 error

Diffstat:

Msrc/components/emoji_picker/emoji_picker.js2+-
Msrc/components/emoji_picker/emoji_picker.scss2+-
Msrc/components/emoji_picker/emoji_picker.vue1+
3 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/components/emoji_picker/emoji_picker.js b/src/components/emoji_picker/emoji_picker.js @@ -244,7 +244,7 @@ const EmojiPicker = { if (!this.$refs['emoji-groups']) { return } - this.width = this.$refs['emoji-groups'].$el.offsetWidth + this.width = this.$refs['emoji-groups'].$el.clientWidth }) } }, diff --git a/src/components/emoji_picker/emoji_picker.scss b/src/components/emoji_picker/emoji_picker.scss @@ -7,7 +7,7 @@ $emoji-picker-emoji-size: 32px; .emoji-picker { width: 25em; - max-width: 100vw; + max-width: calc(100vw - 20px); // popover gives 10px margin from window edge display: flex; flex-direction: column; background-color: $fallback--bg; diff --git a/src/components/emoji_picker/emoji_picker.vue b/src/components/emoji_picker/emoji_picker.vue @@ -83,6 +83,7 @@ :emit-update="true" @update="onScroll" @visible="recalculateItemPerRow" + @resize="recalculateItemPerRow" > <template #default="{ item: group, index, active }"> <DynamicScrollerItem