-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/discrete continuous simple #85
Conversation
# Conflicts: # components/optimizer-configurator.tsx # components/optimizer-model.tsx
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
types/common.ts
Outdated
name: string | ||
description: string | ||
minVal: number | ||
maxVal: number | ||
minVal: string |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should try to preserve the type as number and rely on the "discrete" flag
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The text field returns a string to useForm (even with type="number") and in this simple version the discrete flag is set by checking for "." in the string. You can force useForm to return a number but 1.0 becomes 1 before the check, so I'm not sure how we would check for that without having the explicitly set "discrete" option from the UI. So... maybe change it back to number, when we make the better version with an option to set it from the UI?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed - we should change it back when discrete becomes an explicit option
… add empty plots card
No description provided.