Skip to content
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

Add radio input #340

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Add radio input #340

wants to merge 3 commits into from

Conversation

nvmusoke
Copy link
Contributor

This PR adds radio to the list of Rover UI Inputs

I also removed the onChange prop in Interactive Input to make it more flexible and so it can properly report synthetic events in the Actions tab.

Copy link
Contributor

@pixelbandito pixelbandito left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of nice-to-have comments.
Also, I don't see tests, but I'm ok with that being a follow-on.

<h1>Input.Radio</h1>
<Input
onChange={(e) =>
console.log(e.target.checked) ||
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't gonna hurt anything, but you don't need to leave a console log in here. If I did it for checkbox, it was a mistake.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

going to remove this from checkbox as well

putting IDs on input elements, but they are.
*/}
{/* eslint-disable-next-line jsx-a11y/label-has-associated-control */}
<label className="text-xl inline-block mb-2">
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You might be able to remove the eslint-disable by adding htmlFor="SampleRadio", since you're not using the InteractiveInput wrapper anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants