Display the usual loading circle icon while the embedded patron view
iframe is loading.
Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
+<div *ngIf="!loaded" class="m-3 p-3 d-flex justify-content-center">
+ <div><img src="/images/progressbar_green.gif"/></div>
+</div>
+
<ng-container *ngIf="url">
<iframe id='opac-iframe' class="w-100" (load)="handleLoad()" [src]="url">
</iframe>
export class OpacViewComponent {
url; // SafeResourceUrlImpl
+ loaded: boolean;
_recordId: number;
@Input() set recordId(id: number) {
const height = 50 + iframe.contentWindow.document.body.offsetHeight;
iframe.style.height = `${height}px`;
+ this.loaded = true;
}
}