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

TypeDefinitions for Message Control missing #366

Closed
tsinghammer opened this issue Mar 27, 2018 · 2 comments
Closed

TypeDefinitions for Message Control missing #366

tsinghammer opened this issue Mar 27, 2018 · 2 comments
Assignees
Labels
Type: Bug Issue contains a defect related to a specific component.
Milestone

Comments

@tsinghammer
Copy link

At the moment we use your component messages / message in our project.
Unfortunately the events "onRemove / onClick" are missing in the type definitions for the control.
Could you please amend the component typings?
Thank you in advance.

@MariuszKogut
Copy link
Contributor

MariuszKogut commented Mar 27, 2018

Maybe it's a good idea to extend your existing message typings. I use the following typings for your message stuff:

export interface Message {
  severity: 'success' | 'info' | 'warn' | 'error';
  summary: string;
  detail: string;
  sticky: boolean;
}

export interface MessageComponent {
  show(message: Message): Function;
}

@mertsincan
Copy link
Member

Firstly, Message component doesn't have onRemove and onClick events. For Messages component, parameter type is message object. You can find the values of message object under Message API section in https://www.primefaces.org/primereact/#/messages

Also, I added the definitions of onRemove and onClick to Messages.

@mertsincan mertsincan self-assigned this Apr 2, 2018
@mertsincan mertsincan added the Type: Bug Issue contains a defect related to a specific component. label Apr 2, 2018
@mertsincan mertsincan added this to the 1.5.1 milestone Apr 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a defect related to a specific component.
Projects
None yet
Development

No branches or pull requests

3 participants