Kenia db5283ee24
ui: Refactor topology components (#9339)
* Refactor Stats and Series components

* Refactor metrics error message for ingress-gateway

* Fix upLines icon positioning

* Remove unused variable from being passed down to Stats
2020-12-08 10:47:55 -05:00

34 lines
679 B
Handlebars

{{#if (not @noMetricsReason)}}
<DataSource
@src={{uri @nspace @dc 'metrics' @endpoint @service @protocol}}
@onchange={{action 'statsUpdate'}}
@onerror={{action (mut error) value="error"}}
/>
{{/if}}
<div class="stats">
{{#if hasLoaded }}
{{#each stats as |stat|}}
<dl {{tooltip
stat.desc
options=(hash
allowHTML=true
)
}}>
<dt>
{{stat.value}}
</dt>
<dd>
{{stat.label}}
</dd>
</dl>
{{else}}
<span>No Metrics Available</span>
{{/each}}
{{else}}
<TopologyMetrics::Status
@noMetricsReason={{@noMetricsReason}}
@error={{error}}
/>
{{/if}}
</div>