import { ChangeDetectionStrategy, Component, input } from '@angular/core'; import { BodyReadouts } from './body-readouts'; /** * The Measured/Derived rows and the provenance footnote, shared by the detail page's info panel * and the system view's object card. `bodyReadouts` already guarantees the two surfaces agree * on the numbers; this guarantees they agree on the pixels — the markup used to be pasted four * times across the two templates, which is exactly the drift the shared data model exists to * prevent. */ @Component({ selector: 'app-readout-sections', changeDetection: ChangeDetectionStrategy.OnPush, template: ` @if (readouts().measured.length) {
Measured
Derived
{{ readouts().provenance }}
` }) export class ReadoutSectionsComponent { readonly readouts = input.required