The documentation page for the chips component shows incorrect information

UI Components for JSF
Post Reply
pablo.fradua
Posts: 5
Joined: 21 Oct 2021, 14:59

21 Oct 2021, 15:26

The documentation page for the Chips component is incorrect regarding the Ajax behaviour events (and also refers to the Rating component):
Rating provides rate and cancel as ajax behavior events. A defined listener for rate event will be executed by passing an org.primefaces.event.RateEvent as a parameter and cancel event will be invoked with no parameter.
The example shows code that doesn't work either:

Code: Select all

<p:chip label="text" removable="true">
    <p:ajax event="click" listener="#{chipBean.onclick}" update="msgs"/>
    <p:ajax event="close" listener="#{chipBean.onclose}" update="msgs"/>
</p:chip>
<p:messages id="msgs" />
I believe it should be select instead of click.
Environment
  • PF 12
  • Jakarta Faces 4.0.1
  • Payara 6

Melloware
Posts: 3717
Joined: 22 Apr 2013, 15:48

21 Oct 2021, 20:40

PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 13.0.0 / PF Extensions 13.0.0
PrimeReact 9.6.1

pablo.fradua
Posts: 5
Joined: 21 Oct 2021, 14:59

22 Oct 2021, 09:08

Thanks!
I thought about submitting a pull request with the change, would you have preferred it that way?
Environment
  • PF 12
  • Jakarta Faces 4.0.1
  • Payara 6

Melloware
Posts: 3717
Joined: 22 Apr 2013, 15:48

22 Oct 2021, 11:04

That would have been great too. We always like it when people submit PRs!
PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 13.0.0 / PF Extensions 13.0.0
PrimeReact 9.6.1

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 34 guests