Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duplication of fly-out and banners #412

Open
bjlittle opened this issue Oct 28, 2024 · 1 comment · May be fixed by #415 or readthedocs/readthedocs.org#11765
Open

Duplication of fly-out and banners #412

bjlittle opened this issue Oct 28, 2024 · 1 comment · May be fixed by #415 or readthedocs/readthedocs.org#11765
Labels
Needed: design decision A core team decision is required

Comments

@bjlittle
Copy link

bjlittle commented Oct 28, 2024

Thanks for the new RTD addons, they're pretty awesome 💯

However, I have noticed now that the new addons are default, the fly-out is being replicated within an interactive tab in our geovista project (docs)

e.g., see this FVCOM Bathymetry interactive gallery example shown below (ensure to click the Interactive Scene tab) and notice the duplicated fly-out within the window. Note that, all addons are duplicated e.g., version banners at al

image

Is there something that you can fix on your side to prevent this happening?

This wasn't an issue previously.

Many thanks 🍻

@bjlittle bjlittle changed the title Duplication of fly-out Duplication of fly-out and banners Oct 28, 2024
@humitos
Copy link
Member

humitos commented Oct 28, 2024

Thanks for reporting this issue.

It took a quick look and I found that page performs a behind the scenes request to https://geovista.readthedocs.io/en/latest/_static/static_viewer.html with ?fileURL=../_images/generated/gallery/warp/images/sphx_glr_from_unstructured__fvcom_001.vtksz as argument

The final URL is https://geovista.readthedocs.io/en/latest/_static/static_viewer.html?fileURL=../_images/generated/gallery/warp/images/sphx_glr_from_unstructured__fvcom_001.vtksz

Since that URL is an HTML file, our CF worker is executed on that page and all the addons are added there as well. I don't have an answer to your question right now, but we will debugging/thinking a little more about this.

@humitos humitos added the Needed: design decision A core team decision is required label Oct 28, 2024
humitos added a commit that referenced this issue Oct 29, 2024
Check if addons library is being loaded inside an iframe, and skip loading it.

Closes #412
@humitos humitos linked a pull request Oct 29, 2024 that will close this issue
@github-project-automation github-project-automation bot moved this to Planned in 📍Roadmap Nov 5, 2024
humitos added a commit to readthedocs/readthedocs.org that referenced this issue Nov 13, 2024
Add an extra HTTP header to decide whether or not force the injection of addons
when the page is embedded (eg. iframe). By default, we are not loading addons if
embedded.

Required by readthedocs/addons#415
Closes readthedocs/addons#412
humitos added a commit to readthedocs/readthedocs.org that referenced this issue Nov 13, 2024
Add an extra addons config to decide whether or not force the injection of
addons when the page is embedded (eg. iframe). By default, we are not loading
addons if embedded.

Required by readthedocs/addons#415
Closes readthedocs/addons#412
humitos added a commit to readthedocs/readthedocs.org that referenced this issue Nov 13, 2024
Add an extra addons config to decide whether or not force the injection of
addons when the page is embedded (eg. iframe). By default, we are not loading
addons if embedded.

Required by readthedocs/addons#415
Closes readthedocs/addons#412
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needed: design decision A core team decision is required
Projects
Status: Planned
2 participants