nebular icon indicating copy to clipboard operation
nebular copied to clipboard

Accordion trigger two time

Open Sirikakire opened this issue 2 years ago • 1 comments

Issue type

I'm submitting a ... (check one with "x")

  • [x ] bug report
  • [ ] feature request

Issue description

Current behavior: Trigger (collapsedChange) event emitter by open/close the nb-accordion-item if i opened the accordion, its logged true and false, otherwise, it logged true and true

Expected behavior: only logging true when open only logging false when close

Steps to reproduce: open and close the accordion Related code:

<nb-accordion class="shadow-none" *ngFor="let item of order">
  <nb-accordion-item class="mb-5" (collapsedChange)="something($event)">
    <nb-accordion-item-header>
    </nb-accordion-item-header>
    <nb-accordion-item-body> Item Content </nb-accordion-item-body>
  </nb-accordion-item> 
</nb-accordion>
something(isOpen: boolean): void {
    console.log(isOpen)
 }

log:

true
false
true
true
true
false
true
true

Other information:

npm, node, OS, Browser

Node, npm: v18.17.0 and 9.8.1
OS: Windows (7/8/10)
Browser: MSEdge

Angular, Nebular

"@angular/core": "^16.1.0",
"@nebular/eva-icons": "^11.0.0",
"@nebular/theme": "^11.0.0",

Sirikakire avatar Aug 30 '23 05:08 Sirikakire

Having the same issue.

Jzeemo avatar Jan 17 '24 06:01 Jzeemo