Skip to content

Commit 4efd6f7

Browse files
authored
release(0.5.5): fix release 0.5.5 (#468)
1 parent ce5b0bc commit 4efd6f7

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

src/components/dropdown/nz-dropdown-button.component.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,10 @@ export class NzDropDownButtonComponent extends NzDropDownComponent implements On
8282
this._setTriggerWidth();
8383
}
8484
}
85-
this.nzVisible = visible;
86-
this.nzVisibleChange.emit(this.nzVisible);
85+
if (this.nzVisible !== visible) {
86+
this.nzVisible = visible;
87+
this.nzVisibleChange.emit(this.nzVisible);
88+
}
8789
this._changeDetector.markForCheck();
8890
}
8991

src/components/dropdown/nz-dropdown.component.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ export class NzDropDownComponent implements OnInit, OnDestroy, AfterViewInit {
125125
_clickDropDown($event) {
126126
$event.stopPropagation();
127127
if (this.nzClickHide) {
128-
this.nzVisible = false;
128+
this._hide();
129129
}
130130
}
131131

@@ -139,8 +139,10 @@ export class NzDropDownComponent implements OnInit, OnDestroy, AfterViewInit {
139139
this._setTriggerWidth();
140140
}
141141
}
142-
this.nzVisible = visible;
143-
this.nzVisibleChange.emit(this.nzVisible);
142+
if (this.nzVisible !== visible) {
143+
this.nzVisible = visible;
144+
this.nzVisibleChange.emit(this.nzVisible);
145+
}
144146
this._changeDetector.markForCheck();
145147
}
146148

0 commit comments

Comments
 (0)