mantinedev / mantine

A fully featured React components library
https://mantine.dev
MIT License
26.79k stars 1.9k forks source link

Popover `onOpen` called on each re-render. #7111

Open crabvk opened 5 days ago

crabvk commented 5 days ago

Dependencies check up

What version of @mantine/* packages do you have in package.json?

7.13.5

What package has an issue?

@mantine/core

What framework do you use?

Vite

In which browsers you can reproduce the issue?

All

Describe the bug

Update component state with Popover opened, onOpen triggered on each re-render. Expected onOpen to be called only once when I open Popover (as it works now) and nothing on re-renders (the bug).

If possible, include a link to a codesandbox with a minimal reproduction

https://codesandbox.io/p/sandbox/mantine-popover-bug-forked-8446wc

Possible fix

No response

Self-service

rtivital commented 5 days ago

Your sandbox is private, I cannot access it, please make it public.

crabvk commented 5 days ago

Should be accessible now.

ndelon commented 4 days ago

I reported a similar issue on the Combobox component few weeks ago: #7022 .

maxiadlovskii commented 3 days ago

I created another issue #7115 I think they might have the same root