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

Fix #14367: Dropdown selected item template #14643

Merged

Conversation

ty-ler
Copy link
Contributor

@ty-ler ty-ler commented Jan 27, 2024

Fixes #14367

I didn't want to create a duplicate issue for this problem, but did create a very simple demo of the issue in Stackblitz:
https://stackblitz.com/edit/stackblitz-starters-xxhaw6?file=src/main.ts

Copy link

vercel bot commented Jan 27, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
primeng ⬜️ Ignored (Inspect) Visit Preview Jan 27, 2024 3:28pm

@rosenthalj rosenthalj mentioned this pull request Jan 30, 2024
@rosenthalj
Copy link
Contributor

Issue #14367 is really two bugs :

  1. Having {{ item.label }}
    throws Cannot read properties of undefined (reading 'label') error if no item is selected initially
  2. if you have [filter]="true" and you have a selected an item, then start typing in the filter input the selected item is not displayed
    (Note: these descriptions were taken directly from this "Describe the bug" section at the top of issue Component: Dropdown #14367)

After examining the changes in this pull request #14643, it appears that only the first bug of issue #14367 is fixed by this pull request. The "very simple demo" reproducer provided in this pull request only attempts to fix the first bug.

Pull request #14665 fixes the second bug of issue #14367

@ty-ler
Copy link
Contributor Author

ty-ler commented Jan 30, 2024

Yes, this PR is basically just to address the first bug regarding the selected item template.

@cetincakiroglu cetincakiroglu merged commit 9b75c71 into primefaces:master Feb 1, 2024
2 checks passed
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.

Component: Dropdown
3 participants