add click callback and remove icon if is not editable (#4516)

This commit is contained in:
Eugenio Romano
2019-03-28 18:52:43 +00:00
committed by GitHub
parent 71fc1fd039
commit 944ca8e5d8
11 changed files with 60 additions and 18 deletions

View File

@@ -57,7 +57,7 @@ export class CardViewTextItemComponent implements OnChanges {
}
isClickable(): boolean {
return this.property.clickable;
return !!this.property.clickable;
}
hasIcon(): boolean {
@@ -97,6 +97,10 @@ export class CardViewTextItemComponent implements OnChanges {
}
clicked(): void {
this.cardViewUpdateService.clicked(this.property);
if (typeof this.property.clickCallBack === 'function') {
this.property.clickCallBack();
} else {
this.cardViewUpdateService.clicked(this.property);
}
}
}