Closed wallacio closed 3 years ago
Update! This plugin is smarter than me. For anyone else finding themselves in this position, this appears to work:
Now, using multiple images with hotspots is a case of adding matrix blocks until your browser can't cope.
@wallacio thanks for the update! I tried to describe this, if the docs are unclear please let me know. It uses tree traversal to find the first field with a matching name. So there could be multiple levels between the fields. You could also use the same pattern and names at a different depths in your tree as long as they don't cross.
Are you still missing functionality or does this solve it for you?
No missing functionality but if there's any improvement to the docs to be made it would be an example of how to include multiple images, themselves with multiple hotspots in an entry. My use-case is various perspectives/views of a map (as an image, nothing with lat/long) on a page, map having a different placement of markers.
Thanks!
Hi @roelvanhintum I'm curious if the Image hotspot field supports the Neo plugin for building complex matrixes? I'm trying to set this up inside of a Neo block and not seeing the Hotspot button. My first guess is that there's an issue with the hierarchy / placement of the fields within the tree, but not sure if I'm missing something?
@matteveryday, the plugin traverses the tree, so it should find the field. I don't know if this works different with Neo.
Judging by the screenshot, the entry should be saved first after adding an image. The button should be visible after saving.
I should have mentioned that the screenshot is after already saving the entry. ha.
@matteveryday how is your field structured? I'm having some trouble reproducing this.
@roelvanhintum here's some screenshots of my structure for reference...
Block "Hero Hotspot Test" contains the image
field.
The Child Block "Hotspot Content" contains a simple heading and the hotspot
field. (in this sense, I'm attempting to add multiple hotspots to the same image with the repeatable child block similar to the SuperTable example above.
The hotspot
Image Hotspot field is set up to target the image
Asset field.
@matteveryday fixed in 1.1.0
@roelvanhintum Thank you! I updated and everything is working nicely now 😄
I have discovered that this doesn't allow multiple assets per entry. Or at least, the hotspot picker defaults to use the first asset in the list.
It would be great to see this plugin able to handle multiple assets, and hotspots unique to those assets, all in the same entry.