ageller / Firefly

A WebGL interactive particle viewer
GNU Affero General Public License v3.0
64 stars 12 forks source link

colormap sliders don't like special characters in UInames #118

Closed agurvich closed 2 years ago

agurvich commented 2 years ago

We should think about how we handle UInames as keys, there are some places where we run eval on strings that contain a UIname. I just ran into an issue with the colormap sliders throwing syntax errors with eDR3-RV as a UIname that went away once I removed the hyphen. For now it's probably fine to just encourage users to not include special characters in their UInames but we should consider

  1. removing them ourselves
  2. adding support by differentiating between pkeys (that we use in the code) and UI names that are only referenced in the GUI pane (should not be too hard to do this, I think. basically a 1 liner where the label is created with d3 and then a couple lines in the frontend to allow users to set this manually).
agurvich commented 2 years ago

removed special characters from UI names in 37a51c35331b24a5202868ab017c2ff5be3c3f80