-
Notifications
You must be signed in to change notification settings - Fork 3
Add values to Checkbox Group's value
in order of selection
#577
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
Conversation
🦋 Changeset detectedLatest commit: ad80886 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
fac88c5
to
df0a1a1
Compare
df0a1a1
to
552311b
Compare
src/checkbox-group.ts
Outdated
this.value = this.value.filter((value) => { | ||
return ( | ||
// No idea why TypeScript thinks `event.target` is possibly `null` | ||
// when filtering given it's narrowed out above. |
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 you may be running into https://stackoverflow.com/a/79173023
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.
Aha. I might just delete the comment. Any objections?
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.
nope!
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.
✅ ad80886
🚀 Description
A minor detail to match Dropdown and because consumers likely expect us not to mess with the order of the values.
📋 Checklist
🔬 How to Test
value
attribute is["two", "three", "one"]
.value
attribute is["two", "one"]
.value
attribute is["two", "one", "three"]
.📸 Images/Videos of Functionality
N/A