mirror of
https://github.com/usememos/memos.git
synced 2025-06-05 22:09:59 +02:00
fix: mouse hover in heatmap
This commit is contained in:
@ -59,9 +59,9 @@ const UsageHeatMap: React.FC<Props> = () => {
|
||||
return;
|
||||
}
|
||||
|
||||
const targetEl = event.target as HTMLElement;
|
||||
popupRef.current.style.left = targetEl.offsetLeft + "px";
|
||||
popupRef.current.style.top = targetEl.offsetTop - 4 + "px";
|
||||
const bounding = utils.getElementBounding(event.target as HTMLElement);
|
||||
popupRef.current.style.left = bounding.left + "px";
|
||||
popupRef.current.style.top = bounding.top - 4 + "px";
|
||||
}, []);
|
||||
|
||||
const handleUsageStatItemMouseLeave = useCallback(() => {
|
||||
|
Reference in New Issue
Block a user