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

Dropdown onChange - Argument of type 'DropdownChangeEvent' is not assignable to parameter #14456

Closed
maxximo69 opened this issue Dec 31, 2023 · 4 comments
Labels
Resolution: Cannot Replicate Issue could not be replicated by Core Team Resolution: Stale Issue or pull request is inactivity and unfortunately it will be *closed* if there is no response

Comments

@maxximo69
Copy link

Describe the bug

On "ng serve" -> Failed to compile with this error: error TS2345: Argument of type 'DropdownChangeEvent' is not assignable to parameter of type 'Event'. Type 'DropdownChangeEvent' is missing the following properties from type 'Event': bubbles, cancelBubble, cancelable, composed, and 18 more.

Environment

<p-dropdown
#dropdown_i
styleClass="m-dropdownOverride"
scrollHeight="160px"
[autoDisplayFirst]="false"
[options]="tipos"
name="input1"
[(ngModel)]="tipoSelected"
optionLabel="mvalue"
(onChange)="myFunc($event)" <<----This
[showClear]="true"
formControlName="type_unit"
>

Reproducer

No response

Angular version

17.0.8

PrimeNG version

17.3.0

Build / Runtime

Angular CLI App

Language

TypeScript

Node version (for AoT issues node --version)

20.10.0

Browser(s)

Chrome

Steps to reproduce the behavior

No response

Expected behavior

No response

@maxximo69 maxximo69 added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Dec 31, 2023
@mehmetcetin01140 mehmetcetin01140 added Resolution: Cannot Replicate Issue could not be replicated by Core Team and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Jan 5, 2024
Copy link

github-actions bot commented Jan 5, 2024

We're unable to replicate your issue, if you are able to create a reproducer by using PrimeNG Issue Template or add details please edit this issue. This issue will be closed if no activities in 20 days.

@maxximo69
Copy link
Author

maxximo69 commented Jan 6, 2024

I apologize for the report. The error is caused by my mistake. In the .ts file reference function I specified the Event type for the parameter; I should have indicated any.
myFunc($event: Event){ } not working
myFunc($event: any) { } Work!
This report can be considered closed and solved
Thank you

Copy link

github-actions bot commented May 6, 2024

This issue has been automatically marked as stale. If this issue is still affecting you with the latest version, please leave any comment, and we will keep it open. We are sorry that we have not been able to prioritize it yet. If you have any new additional information, please include it with your comment!

@github-actions github-actions bot added the Resolution: Stale Issue or pull request is inactivity and unfortunately it will be *closed* if there is no response label May 6, 2024
Copy link

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please create a new issue with up-to-date information. Thank you for your understanding!

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Cannot Replicate Issue could not be replicated by Core Team Resolution: Stale Issue or pull request is inactivity and unfortunately it will be *closed* if there is no response
Projects
None yet
Development

No branches or pull requests

2 participants