Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | 1x 1x 5x 12x | import { ChangeDetectionStrategy, Component, Input } from '@angular/core';
import { HttpError } from 'ish-core/models/http-error/http-error.model';
/**
* The Server Error Page Component informs the user about an occurred error on server side.
*
* @example
* <ish-server-error-page
* [error]="generalError"
* ></ish-server-error-page>
*/
@Component({
selector: 'ish-server-error',
templateUrl: './server-error.component.html',
changeDetection: ChangeDetectionStrategy.OnPush,
})
export class ServerErrorComponent {
/**
* The occurred error.
*/
@Input({ required: true }) error: HttpError | string;
@Input() type: string;
expanded = false;
get httpError() {
return this.error as HttpError;
}
get stringError() {
return this.error as string;
}
expand() {
this.expanded = true;
}
}
|