I trying to integrate some user feedback tools into out application, and part of this required embedding an iframe into the application. I am using Privacy Badger, and it blocks all the content of the iframe and changes the display property to none all the time. That's all well and good, i'm not trying to force this past peoples privacy extensions, however I do want to be able to detect if it has been removed, and just display some placeholder text like "This was removed by an adblocker. Feel free to email us if you have feedback" so that the app doesn't feel broken.
My Current Attempt: Code Sandbox
This however doesn't display the fallback as I would like it to.
I have tried various renditions of this method, all without luck.
Essentially what I want is this:
Detect if the iframe element has it's display property set to none, and render a fallback in it's place if that is true.