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

Mimic the behavior of the select input for dropdown by preventing a user from deselecting an item #1012

Closed
charliepy opened this issue Oct 24, 2023 · 2 comments
Assignees
Labels
🪄 enhancement New feature or request 🔵 priority-3 3. Lower priority issue

Comments

@charliepy
Copy link

Reproduction

https://formkit.link/4b5216e10aaa9ff02d09c1d6f28669f2

Describe the bug

I would like to prevent a user from "deselecting" a currently selected item when clicking the list item again

Environment

• OS: [Windows 10]
• Browser [Chrome]
• Version [FormKit 1.2]

@charliepy charliepy added ⛑ Needs triage The issue has not yet been examined by the FormKit team. 🐛 bug-report Bug is reported, but not verified by team labels Oct 24, 2023
@sashamilenkovic sashamilenkovic self-assigned this Oct 24, 2023
@sashamilenkovic sashamilenkovic added 🪄 enhancement New feature or request and removed 🐛 bug-report Bug is reported, but not verified by team ⛑ Needs triage The issue has not yet been examined by the FormKit team. labels Oct 24, 2023
@justin-schroeder justin-schroeder added the 🔵 priority-3 3. Lower priority issue label Dec 11, 2023
@justin-schroeder
Copy link
Member

This is now resolved with a new prop: deselect="false"

https://formkit.link/31bd8404d5a28a81ae2a1ab45060b60a

You’ll need to update to 0.119.1. Thanks!

@charliepy
Copy link
Author

Thank you @sashamilenkovic @justin-schroeder

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🪄 enhancement New feature or request 🔵 priority-3 3. Lower priority issue
Projects
None yet
Development

No branches or pull requests

3 participants