File
color
|
Type : string
|
Default value : 'text-black'
|
|
message
|
Type : string
|
Default value : 'NO_DATA_FOUND'
|
|
import { Component, Input } from '@angular/core';
@Component({
selector: 'app-no-data',
templateUrl: './no-data.component.html',
styleUrls: ['./no-data.component.scss'],
})
export class NoDataComponent {
@Input() message = 'NO_DATA_FOUND';
@Input() color = 'text-black';
constructor() { }
}
<div class="message">
<h5 class="{{color}}"> {{message | translate}} </h5>
</div>
@import "~@project-sunbird/sb-styles/assets/_variables.scss";
.message{
text-align: center;
margin: auto;
}
.text-primary {
color: var(--primary-color);
}
.text-black {
color: var(--app-black);
}
Legend
Html element with directive