Hacker News new | ask | show | jobs
by harmonium1729 987 days ago
Fun question. There are a couple options:

(1) the more straightforward (but less powerful) option is to use the dynamic bounds for a slider. Here, "a" is set to animate, but the bounds don't let it move if b=0: https://www.desmos.com/calculator/mqhhpso67r

(2) the more general feature that allows for complex scripting behavior is called "actions." Here's an example that uses that, where it's more of a genuine play/pause: https://www.desmos.com/calculator/gzqwx36lo0

It's a beta feature that needs to be enabled, but anyone can turn it on. More here: https://help.desmos.com/hc/en-us/articles/4407725009165-Acti...

1 comments

Thanks! I will pass those on