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

Including the viewer inside an Iframe #655

Open
kerautret opened this issue Feb 27, 2023 · 4 comments
Open

Including the viewer inside an Iframe #655

kerautret opened this issue Feb 27, 2023 · 4 comments

Comments

@kerautret
Copy link
Contributor

Hi Kitware dev team!
If I am not wrong, it is not possible to include the itkVtkViewer inside an iFrame ?
I know that the embedding is a better way but in the IPOL framework we see some issue to include the viewer inside the online demo system. (some error like Refused to load blob:with reference to something like worker-src directive of the Content Security Policy. promiseEmptyOnRejected — itkVtkViewerCDN.js:16:268570 if you see where it can comes from).

We were successfully used the viewer that is really excellent from our previous online demonstration but we were planning to extend it on the new system witch will be more safe for a longer visibility in longer term.
(I tried to include the viewer on this ipol online demo

@thewtex
Copy link
Member

thewtex commented Mar 1, 2023

Hi @kerautret !

It should -- we use the viewer in a iframe in itkwidgets.

The ipol demo is awesome!! Is this using the latest version of the viewer?

@kerautret
Copy link
Contributor Author

Hi @thewtex !
Thanks! In fact I was testing the iFrame with the doc url with here: https://kitware.github.io/itk-vtk-viewer/app/?fileToLoad=https://data.kitware.com/api/v1/file/564a65d58d777f7522dbfb61/download/data.nrrd as given in the official page and is was not working in my basic test page: https://ipol-geometry.loria.fr/Sites/testIFrame.html

However I remember from your remark of version I tested on the viewer app from our server and I tested it works:
Capture d’écran 2023-03-01 à 21 21 04
So I am confident to make working on the online demonstration of new system (just not direct to test because there are rewriting url script to update) I will test of the base work it could perfect.
Perhaps it could be good to update the version on the doc page since perhaps other people can think that iframe did not work ?

@kerautret
Copy link
Contributor Author

So nice it works ;) 🎉 Thanks for the help and iframe orient, excellent it will be easy now to use in online demo as a standard in IPOL !

Capture d’écran 2023-03-01 à 21 50 38

@thewtex
Copy link
Member

thewtex commented Mar 10, 2023

@kerautret fantastic!!

I am not sure which doc page you were looking at, but a PR would be appreciated: https://github.com/Kitware/itk-vtk-viewer/tree/master/doc/content/docs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants