I once jokingly said I’d stop creating H5P content types when I succeeded in having built one for every letter in the alphabet. I am one step closer now, because here’s my latest creation that starts with an X: X-ray!
It is obviously a spin-off of Image Zoom that was released recently. I could simply have added a switch to that content type, so it could serve for both zooming and raying. However, I can think of a couple of features in the future that don’t make sense for both modes and I like the good old Unix philosophy:
Make each program do one thing well. To do a new job, build afresh rather than complicate old programs by adding new “features”. (Doug McIlroy)
So, here you can:
- Choose one image for the background (the X-ray image) and one for the foreground (the normal image).
- Select the image width and position (useful for those who cannot control the width of H5P content on their platform).
- Change the X-ray lens size.
- Decide not to darken the background when x-raying.
- Decide not to x-ray automatically, but to require the user to activate it.
- Decide to not show the little x-ray indicator in the lower right corner – but it’s useful to have it there as it’s the button to toggle if you’re controlling the content type with the keyboard.
Want to use it already?
I’ll ask the H5P core team to review the content type and to release it on the H5P Hub, but this process usually takes some time. If you want to use the content type right away, just download the demo content above via the Reuse button underneath the content, and then upload the .h5p file onto your H5P platform in the H5P Hub. That will install the required libraries if you have permission to install H5P libraries – if not, your system admin will need to help you with that. The source code is available as well: https://github.com/otacke/h5p-x-ray