Skip to content

Commit

Permalink
fix(date-picker): Fixed import and hide function #3034 (#3961)
Browse files Browse the repository at this point in the history
* fix(date-picker): Fixed import and hide function #3034

* fix(date-picker): Fixes in date picker #3034

* fix(date-picker): Fixed Circular dependency detected #3034
  • Loading branch information
sboykova authored and bkulov committed Feb 20, 2019
1 parent 4dab8fe commit 4dfcaf2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { Component, ViewChild, Input, Output, EventEmitter, HostListener, HostBinding } from '@angular/core';
import { DatePickerInteractionMode, IgxCalendarComponent } from 'igniteui-angular';
import { DatePickerInteractionMode } from './date-picker.component';
import { IgxCalendarComponent } from '../calendar';

/**
* @hidden
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ import {
HorizontalAlignment,
PositionSettings,
ConnectedPositioningStrategy
} from '../services';
} from '../services/index';
import { DateRangeDescriptor } from '../core/dates/dateRange';
import { EditorProvider } from '../core/edit-provider';
import { IgxButtonModule } from '../directives/button/button.directive';
Expand Down Expand Up @@ -806,7 +806,9 @@ export class IgxDatePickerComponent implements IDatePicker, ControlValueAccessor
*@hidden
*/
public ngOnDestroy(): void {
this._overlayService.hideAll();
if (this._componentID) {
this._overlayService.hide(this._componentID);
}
this._destroy$.next(true);
this._destroy$.complete();
}
Expand Down Expand Up @@ -1122,6 +1124,7 @@ export class IgxDatePickerComponent implements IDatePicker, ControlValueAccessor

private _onClosed(): void {
this.collapsed = true;
this._componentID = null;
this.onClose.emit(this);

if (this.getEditElement()) {
Expand Down

0 comments on commit 4dfcaf2

Please sign in to comment.