Newer
Older
import { INotificationOptions, NotificationOptions } from './notification-options.model';
import { NotificationType } from './notification-type';
import { isEmpty } from '../../empty.util';
import { Observable } from 'rxjs/Observable';
id: string;
type: NotificationType;
title?: Observable<string>;
content?: Observable<string>;
options?: INotificationOptions;
}
export class Notification implements INotification {
public id: string;
public type: NotificationType;
public title: Observable<string>;
public content: Observable<string>;
constructor(id: string,
type: NotificationType,
title?: Observable<string>,
content?: Observable<string>,
options?: NotificationOptions,
html?: any) {
this.id = id;
this.type = type;
this.title = title;
this.content = content;
this.options = isEmpty(options) ? new NotificationOptions() : options;