outposts: include outposts build hash in state

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer
2021-12-30 15:16:31 +01:00
parent c249b55ff5
commit d03b0b8152
3 changed files with 25 additions and 1 deletions

View File

@ -32,6 +32,13 @@ export class OutpostHealthElement extends LitElement {
if (!this.outpostHealth) {
return html`<ak-spinner></ak-spinner>`;
}
let versionString = this.outpostHealth.version;
if (this.outpostHealth.buildHash) {
versionString = `${versionString} (build ${this.outpostHealth.buildHash.substring(
0,
8,
)})`;
}
return html` <ul>
<li>
<ak-label color=${PFColor.Green}>
@ -44,7 +51,7 @@ export class OutpostHealthElement extends LitElement {
>${t`${this.outpostHealth.version}, should be ${this.outpostHealth.versionShould}`}
</ak-label>`
: html`<ak-label color=${PFColor.Green}
>${t`Version: ${this.outpostHealth.version || ""}`}
>${t`Version: ${versionString}`}
</ak-label>`}
</li>
</ul>`;