Open macfreek opened 10 years ago
Some free-form thinking how to support this feature.
<div>
) does not highlight the area. Both effects are undesired.Is there a particular reason to add mouseover and mouseout events to each area, even if highlighting is disabled?
Could ImageMapster be changed so that:
Would you accept a patch with this change, or would such change pose unexpected side-effects?
You can test that this at: http://jsfiddle.net/macfreek/SLa95/3/
While all tests in imagemapster-test-runner.html pass, it wouldn't hurt to check how this works, in particular when combining selections and highlights.
FYI, I converted the dist file to contain MS-DOS line-breaks only, so I could push that too.
Would it be possible to disable automatic highlight events upon mouseover/mouseout events?
I have a imagemap with small textboxes to add some additional information (kind of like tooltips, but sticky). In code:
Ideally, I like the area and div to behave as if it was one area. This is similar to a areagroup with a boundList. Unfortunately, the items in an boundList do not automatically highlight or select. This needs to be programmed. See for example http://jsfiddle.net/macfreek/SLa95/1/ Unfortunately, there is a rather annoying 'flickering' when moving the cursor between div and area. This is caused by a mouseout from one element and a subsequent mouseover from the other element. This is particular visible if the highlight fade is set to a high value (in the above example 0.5 sec).
The common solution is to group the elements, and use mouseenter/mouseleave instead of mouseover/mouseout. See for example http://jsfiddle.net/macfreek/SLa95/2/ Unfortunately, while the mouseenter/mouseleave take care of everything, ImageMapster still fires redundant mapster('highlight', null) events, causing un-highlighting when moving the mouse from an area to a div.
Would it be possible to disable automatic highlights (from mouseover/mouseout events), and so everything manually?