Slider.marker.opacity = 0 works in Builder but not online

URL of experiment:
https://run.pavlovia.org/jenkim9/judge-the-passage-of-time/html

Description of the problem:
I am using a slider in my experiment, and do not want any kind of marker. Instead of storing the slider response, I am recording the mouse position on click while the slider is visible. The mouse click ends the routine, rather than the slider response itself. In other words, the slider is only there as a cosmetic tool to help people gauge where to click to make their estimate.

The marker sometimes pops up and sometimes doesn’t, and it can be distracting. I have used a code component with the following in the Begin Routine tab:

slider.marker.opacity = 0

This works like a charm when I run the experiment via Builder, but when I run it online, I get an error message saying “TypeError: slider.marker is undefined”. (You will see this in the version linked above).

It seems the online JS version of the script no longer recognises the slider as “slider”. Is there another piece of code that will do this? Or another place to put this code?

I realise an easier option would be to create an image of the slider offline and simply display this, but I would like to know if it is possible to remove the slider marker for an online study.

Any help is appreciated.

It is possible that in JS “slider.marker” is read not as a name but as in input? Maybe try name it slide_marker and see if the issue is resolved

I’m afraid that didn’t work. The error is now: " ReferenceError: slider_marker is not defined".

I think I’ll take the easy route and just use an image instead, but hopefully this issue will be picked up by the devs.

Hello,

I have the same issue. Any news about how to access marker opacity online?

Thank you!

I’m also experiencing a similar issue with my slider - it works perfectly fine in Builder, but not when uploaded to Pavlovia. When the study runs in Pavlovia, all the routines with sliders in are just skipped.

Did anyone find a solution to this problem?

1 Like