aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAnderson Shindy Oki <[email protected]>2024-12-02 09:41:42 +0900
committerAnderson Shindy Oki <[email protected]>2024-12-02 09:41:42 +0900
commit48f78a74c5335b6e612c5e51113f0aea8d7f04b6 (patch)
tree04bbf31f2a18a8f6c5bc1da7bb4674570f7aace9
parent669ed069f52e4f5bb95fa85d431ba2cdb6b57429 (diff)
downloadbazarr-48f78a74c5335b6e612c5e51113f0aea8d7f04b6.tar.gz
bazarr-48f78a74c5335b6e612c5e51113f0aea8d7f04b6.zip
Fixed match popover positionfix/match-popover-position
-rw-r--r--frontend/src/components/StateIcon.tsx8
1 files changed, 4 insertions, 4 deletions
diff --git a/frontend/src/components/StateIcon.tsx b/frontend/src/components/StateIcon.tsx
index 27d6ab4df..da2b2b80f 100644
--- a/frontend/src/components/StateIcon.tsx
+++ b/frontend/src/components/StateIcon.tsx
@@ -9,7 +9,7 @@ import {
Stack,
Text,
} from "@mantine/core";
-import { useHover, useMediaQuery } from "@mantine/hooks";
+import { useDisclosure, useMediaQuery } from "@mantine/hooks";
import {
faCheckCircle,
faExclamationCircle,
@@ -33,7 +33,7 @@ const StateIcon: FunctionComponent<StateIconProps> = ({
}) => {
const hasIssues = dont.length > 0;
- const { hovered, ref } = useHover();
+ const [opened, { close, open }] = useDisclosure(false);
const isMobile = useMediaQuery(`(max-width: ${em(750)})`);
@@ -52,9 +52,9 @@ const StateIcon: FunctionComponent<StateIconProps> = ({
};
return (
- <Popover opened={hovered} position="top" width={360} withArrow withinPortal>
+ <Popover position="left" opened={opened} width={360} withArrow withinPortal>
<Popover.Target>
- <Text ref={ref}>
+ <Text onMouseEnter={open} onMouseLeave={close}>
<PopoverTarget />
</Text>
</Popover.Target>