diff --git a/web/chat/message-action-buttons.js b/web/chat/message-action-buttons.js --- a/web/chat/message-action-buttons.js +++ b/web/chat/message-action-buttons.js @@ -28,7 +28,7 @@ TooltipTextItem, } from './tooltip.react'; -const ellipsisIconExcessVerticalWhitespace = 10; +const messageActionIconExcessVerticalWhitespace = 10; const openSidebarText = 'Go to sidebar'; const createSidebarText = 'Create sidebar'; @@ -69,22 +69,24 @@ const rect = event.currentTarget.getBoundingClientRect(); const { top, bottom, left, right, width, height } = rect; - const dotsPosition: ItemAndContainerPositionInfo = { + const iconPosition: ItemAndContainerPositionInfo = { containerPosition, itemPosition: { top: - top - containerPosition.top + ellipsisIconExcessVerticalWhitespace, + top - + containerPosition.top + + messageActionIconExcessVerticalWhitespace, bottom: bottom - containerPosition.top - - ellipsisIconExcessVerticalWhitespace, + messageActionIconExcessVerticalWhitespace, left: left - containerPosition.left, right: right - containerPosition.left, width, - height: height - ellipsisIconExcessVerticalWhitespace * 2, + height: height - messageActionIconExcessVerticalWhitespace * 2, }, }; - setPointingTo(dotsPosition); + setPointingTo(iconPosition); }, [containerPosition, tooltipVisible], );