Fix stick picker chevron offset calculation
This commit is contained in:
parent
115e773317
commit
ed24f19a3f
1 changed files with 2 additions and 2 deletions
|
@ -315,8 +315,8 @@ export default class Stickerpicker extends React.Component {
|
||||||
|
|
||||||
// Offset the chevron location, which is relative to the left of the context menu
|
// Offset the chevron location, which is relative to the left of the context menu
|
||||||
// (10 = offset when context menu would not be displayed off viewport)
|
// (10 = offset when context menu would not be displayed off viewport)
|
||||||
// (8 = value required in practice (possibly 10 - 2 where the 2 = context menu borders)
|
// (2 = context menu borders)
|
||||||
const stickerPickerChevronOffset = Math.max(10, 8 + window.pageXOffset + buttonRect.left - x);
|
const stickerPickerChevronOffset = Math.max(10, 2 + window.pageXOffset + buttonRect.left - x);
|
||||||
|
|
||||||
const y = (buttonRect.top + (buttonRect.height / 2) + window.pageYOffset) - 19;
|
const y = (buttonRect.top + (buttonRect.height / 2) + window.pageYOffset) - 19;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue