Skip to content

Commit

Permalink
fix(module:popover): fix programmatically changing not trigger ngMode…
Browse files Browse the repository at this point in the history
…lChange (#5053)

Co-authored-by: SamYum <[email protected]>
  • Loading branch information
rppig42 and rppig authored Apr 17, 2020
1 parent d210f4d commit dbc2cd3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions components/tooltip/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,7 @@ export abstract class NzTooltipBaseComponent implements OnDestroy {
const visible = toBoolean(value);
if (this._visible !== visible) {
this._visible = visible;
this.nzVisibleChange.next(visible);
}
}

Expand Down
4 changes: 2 additions & 2 deletions components/tooltip/tooltip.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,12 +117,12 @@ describe('nz-tooltip', () => {
component.visible = true;
waitingForTooltipToggling();
expect(overlayContainerElement.textContent).toContain(title);
expect(component.visibilityTogglingCount).toBe(0);
expect(component.visibilityTogglingCount).toBe(1);

component.visible = false;
waitingForTooltipToggling();
expect(overlayContainerElement.textContent).not.toContain(title);
expect(component.visibilityTogglingCount).toBe(0);
expect(component.visibilityTogglingCount).toBe(2);
}));
});

Expand Down

0 comments on commit dbc2cd3

Please sign in to comment.