Skip to content

Commit

Permalink
Adding Custom Header component implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
Yahima Duarte committed Sep 9, 2018
1 parent 62445b8 commit ab9942b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/modal-dialog.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ import {
IModalHeaderDialog,
ModalDialogOnAction
} from './modal-dialog.interface';
import {from, Observable, Subject} from 'rxjs';
import {AdHeaderDirective} from './modal-dialog.ad-header.directive';
import {ModalDialogHeaderType} from './modal-dialog.header-type';
import { from, Observable, Subject } from 'rxjs';
import { AdHeaderDirective } from './modal-dialog.ad-header.directive';
import { ModalDialogHeaderType } from './modal-dialog.header-type';

/**
* Modal dialog component
Expand Down
9 changes: 7 additions & 2 deletions tests/modal-dialog.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@ import { TestBed, ComponentFixture, fakeAsync, tick } from '@angular/core/testin
import { By } from '@angular/platform-browser';
import { BrowserDynamicTestingModule } from '@angular/platform-browser-dynamic/testing';
import { ModalDialogComponent } from '../src/modal-dialog.component';
import {IModalDialog, IModalDialogOptions, IModalHeaderDialog} from '../src/modal-dialog.interface';
import { IModalDialog, IModalDialogOptions, IModalHeaderDialog } from '../src/modal-dialog.interface';
import { CommonModule } from '@angular/common';
import { Subject, of } from 'rxjs';
import {AdHeaderDirective} from '../src/modal-dialog.ad-header.directive';
import { AdHeaderDirective } from '../src/modal-dialog.ad-header.directive';
import { ModalDialogHeaderType } from '../src/modal-dialog.header-type';

let fixture: ComponentFixture<ModalDialogComponent>;

Expand Down Expand Up @@ -271,6 +272,10 @@ describe('ModalDialog.Component:', () => {
component.dialogInit(fixture.componentRef, {
headerComponent: DummyHeaderComponent,
childComponent: DummyComponent,
settings: {
closeButtonClass: 'close theme-icon-close',
headerType: ModalDialogHeaderType.CUSTOM
},
data: data
});

Expand Down

0 comments on commit ab9942b

Please sign in to comment.