-
-
Notifications
You must be signed in to change notification settings - Fork 340
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
bugfix/inputchips-updates-twice #1768
bugfix/inputchips-updates-twice #1768
Conversation
🦋 Changeset detectedLatest commit: fb583a2 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 |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@Mahmoud-zino checking the Git Blame I see @Sarenor introduced this portion of the code per:
It looks like this was added to allow for null values to be handled by the autocomplete. Can the two of you sync on this and determine the best course of action here? My gut is telling me that just flat out removing this would introduce a regression. |
I just added the null-check, the initial code was added to handle duplicate values: Passing in an undefined list breaks the component though, and I'm not quite sure if we want that as intentional behaviour? |
Hmm, I wonder why the blame showed you. That's odd. |
Cause it was me that changed those lines the last time when I added the |
I will get back to this issue once I am done with the tree-view, I want to handle undefined without a reactive assignment, once this is done I think we can safely delete the reactive assignment. |
can you please provide your setup, I tried passing undefined and got no errors, It is working as expected, maybe I am missing something here... |
@Sarenor just pinging you to remind you about @Mahmoud-zino request above. |
@Mahmoud-zino Sorry, totally missed this while I was camping. |
@Sarenor this happens because we are accessing the lists to display what is selected/allowed/not-allowed etc... on the docs page. but the error is not coming from the component. so commenting this: <code class="code">{anythingList.length ? anythingList.join(', ') : 'No chips available.'}</code> the component will work as expected. |
@Mahmoud-zino you are indeed correct and I'm a fool! |
@Sarenor no no, it is just easy to miss 👍 |
Thanks for your cooperation @Mahmoud-zino @Sarenor I think with that we're good to move forward with this. I'll merge and we'll monitor the reaction from end users going forward. |
Linked Issue
Closes #1759
Description
after deleting
every thing works as expected and the value is updated only once.
I have tested it with all use cases from the docs.
Changsets
bugfix: InputChips updates bound value only once.
Checklist
Please read and apply all contribution requirements.
dev
branch (NEVERmaster
)docs/
,feat/
,chore/
,bugfix/
pnpm check
pnpm format
pnpm test