|
|
@ -1,7 +1,7 @@ |
|
|
import {Component} from '@angular/core'; |
|
|
import { Component } from '@angular/core'; |
|
|
import {ReplaySubject} from 'rxjs'; |
|
|
import { ReplaySubject } from 'rxjs'; |
|
|
import {Confirmation} from '../../models/confirmation'; |
|
|
import { Confirmation } from '../../models/confirmation'; |
|
|
|
|
|
//
|
|
|
@Component({ |
|
|
@Component({ |
|
|
selector: 'abp-confirmation', |
|
|
selector: 'abp-confirmation', |
|
|
templateUrl: './confirmation.component.html', |
|
|
templateUrl: './confirmation.component.html', |
|
|
@ -20,9 +20,9 @@ export class ConfirmationComponent { |
|
|
this.clear(status); |
|
|
this.clear(status); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
getIconClass({severity, options}: Confirmation.DialogData): string { |
|
|
getIconClass({ severity, options }: Confirmation.DialogData): string { |
|
|
if (options && options.icon) { |
|
|
if (options && options.icon) { |
|
|
return options.icon |
|
|
return options.icon; |
|
|
} |
|
|
} |
|
|
switch (severity) { |
|
|
switch (severity) { |
|
|
case 'info': |
|
|
case 'info': |
|
|
@ -38,12 +38,11 @@ export class ConfirmationComponent { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
isCustomIconExists({options}: Confirmation.DialogData): boolean { |
|
|
isCustomIconExists({ options }: Confirmation.DialogData): boolean { |
|
|
return !!(options && (options.iconTemplate || options.icon)) |
|
|
return !!(options && (options.iconTemplate || options.icon)); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
isIconTemplateExits({options}: Confirmation.DialogData): boolean { |
|
|
isIconTemplateExits({ options }: Confirmation.DialogData): boolean { |
|
|
return !!(options && options.iconTemplate) |
|
|
return !!(options && options.iconTemplate); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
|