|
|
@ -328,6 +328,7 @@ export class EmojiArea { |
|
|
|
) { |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
let closestHeaderIndex = this.headerOffsets.findIndex( |
|
|
|
offset => offset >= Math.round(this.emojis.scrollTop) |
|
|
|
); |
|
|
@ -345,6 +346,10 @@ export class EmojiArea { |
|
|
|
closestHeaderIndex = this.headerOffsets.length; |
|
|
|
} |
|
|
|
|
|
|
|
if (this.headerOffsets[closestHeaderIndex] === this.emojis.scrollTop) { |
|
|
|
closestHeaderIndex++; |
|
|
|
} |
|
|
|
|
|
|
|
this.currentCategory = closestHeaderIndex - 1; |
|
|
|
if (this.options.showCategoryButtons) { |
|
|
|
this.categoryButtons.setActiveButton(this.currentCategory); |
|
|
|