I found out that after I upgraded Debian from 11 to 12 the screen share functions from firefox and chrome (for example from a google meet meeting) is not working anymore. I did not share my screen with my colleagues.
In Debian 12 you are probably using PipeWire, Wayland and Gnome 43.
The solution for me was as simple as that:
apt install xdg-desktop-portal-gnome
This way firefox and chrome can reach gnome services inside the sandbox and the screen share is now working as expected.