iPhone mirroring is available from macOS 15.
When running an app with iPhone mirroring
Can I know whether the app currently being mirrored is running at the top of the Mac app or screen?
Or is there a way to know whether it is hidden by another app on the Mac or re-displayed?
If not, I hope it will be added in a future update.
And I hope there is an API that can tell whether the current app is connected to iPhone mirroring or not.