idyll icon indicating copy to clipboard operation
idyll copied to clipboard

Feature request: edit equation numbers

Open mathisonian opened this issue 8 years ago • 5 comments
trafficstars

Issue by rreusser Thursday May 25, 2017 at 23:28 GMT Originally opened as https://github.com/idyll-lang/idyll-default-components/issues/3


I'd love for my equation to look like this:

screen shot 2017-05-25 at 19 23 19

And then to be able to click the 15 and get this:

screen shot 2017-05-25 at 19 25 01

At the moment you can do this only with variables, not numbers. I'm having a bit of trouble understanding what a syntax for that would look like, but it seems reasonable at least. Thoughts?

mathisonian avatar Sep 01 '17 22:09 mathisonian

Comment by mathisonian Thursday May 25, 2017 at 23:36 GMT


Seems like a totally reasonable thing to want to do. I think the numbers would still have to be bound to a variable for it to make sense, but in this case you're displaying the value of the var itself and not a symbol.

While we're talking about equations, a couple things I've been meaning to do:

  • The inline range slider is pretty bad UX imo, at a minimum it should probably be a tooltip style thing that flys out of the number, or could also be something like the "draggable numbers" included in https://idyll-lang.github.io/idyll-regl-component/
  • Right now the only affordance a user has to know that certain elements of the equation are interactive is by hovering directly over the interactive part. Are there any thoughts on a better way to convey the interactivity?

mathisonian avatar Sep 01 '17 22:09 mathisonian

Comment by rreusser Thursday May 25, 2017 at 23:39 GMT


I have a tab open right now in which I'm playing around with style properties. For some reason it's being stubborn about the offset pixels, but what about current idyll link style:

screen shot 2017-05-25 at 19 38 27

mathisonian avatar Sep 01 '17 22:09 mathisonian

Comment by rreusser Thursday May 25, 2017 at 23:39 GMT


It's not quite visible enough in this example, but I think that could be slightly tweaked. The alternative is just making the number a solid color always.

mathisonian avatar Sep 01 '17 22:09 mathisonian

@codemayank - this would also be a fun front-end challenge to tackle.

I think we'd want to (1) make the numbers a different color or give them an obvious outline to indicate that they are dynamic, and make the interaction closer to the [Dynamic /] component rather than using a range slider.

In fact, we should probably drop the range slider altogether for equations, and use direct manipulation for both the variables and numbers.

mathisonian avatar May 28 '19 22:05 mathisonian

If we'd use $$...$$ and $...$ syntax (#314), we can then add dynamic variable parsing inside it and that could look like this:

[var name:"y" value:5 /]
[$$ y = @[value:y interactive:true color:"#000" hoverColor:"red" onChangeColor:"green"] $$]

I'm currently playing around with this idea.

michaltakac avatar Jul 30 '19 14:07 michaltakac