sul-cidr / histonets

Histonets is an application to convert images of scanned maps into digital networks
https://histonets.stanford.edu
Other
20 stars 0 forks source link

Selectively build json to feed into histonets pipeline #67

Closed csbailey5t closed 7 years ago

csbailey5t commented 7 years ago

We only want to run actions such as histonets equalize or histonets posterize when the user has selected a value that is not the default for those actions. So, we need to build the json based on changes in the UI.

I could see this happening at least two ways. One, we create on/off buttons for each of the six image cleaning steps to enable or disable them. We would need to make clear to the user that some of these image cleaning steps (such as posterization or equalization) do change the image when applied even at the default.

Or, we check each field to determine if it is different from the default value, and, if so, add that action and its value into the json to be fed to the pipeline.

Either way, we would need to make clear to the user when an action will be run and when not.

mejackreed commented 7 years ago

I think we can take advantage of building out some of these forms in React. That gives us the state mgmt we need, and keeps the RailsMagic alive. Potentially react components here can live inside of

<%= form_for @collection_template, method: :put, url: wizard_path do |f| %>
# Insert react forms here
<% end %>