Forum Discussion
JavaScript API problem with position of elements in Safari
Hey there,
I am working with the recently launched advanced JavaScript API in Articulate Storyline. I used it, to change the opacity of several images which display buttons on my slide. The images work like regular buttons, which change their states when clicked (the color of the button gets green or grey).
In JavaScript I used eventListeners on the images, and changed their opacity like this: btn.opacity = 100;
It worked fine and I tested it as review and scorm in Firefox and Edge.
Now I tried to test it in Safari on a Mac and suddenly the position of the images changes when I scroll through the scrollable container, which contains all the images. The strange thing is: The images are still on the correct position, but when I want to click them, the clickable area is not positioned on the images anymore. I looked up the position of the images in the DOM-Tree, and it is in fact not on the same position where I see the images.
Any ideas where that comes from or how to solve it? I attached a screenshot
1 Reply
Hello Phil25,
It sounds like you're doing some exciting work with the advanced JavaScript API in Articulate Storyline!
I recommend reaching out to our JavaScript Group in the community to see if others have come across this behavior when using Safari. Feel free to share a screen recording or a copy of your .story file there as well!