diff --git a/resources/lang/en.json b/resources/lang/en.json index f2c01b89b..3e991d634 100644 --- a/resources/lang/en.json +++ b/resources/lang/en.json @@ -691,6 +691,7 @@ "retreating": "retreating", "retaliate": "Retaliate", "boat": "Boat", + "seconds_abbrev": "{seconds}s", "alliance_request_status": "{name} {status} your alliance request", "alliance_accepted": "accepted", "alliance_rejected": "rejected", diff --git a/src/client/graphics/layers/EventsDisplay.ts b/src/client/graphics/layers/EventsDisplay.ts index a09d1b9e8..7aec93bf2 100644 --- a/src/client/graphics/layers/EventsDisplay.ts +++ b/src/client/graphics/layers/EventsDisplay.ts @@ -930,12 +930,18 @@ export class EventsDisplay extends LitElement implements Layer {
${this.outgoingBoats.map((boat) => { const etaSeconds = this.estimateBoatEtaSeconds(boat); + const etaText = + etaSeconds !== null + ? translateText("events_display.seconds_abbrev", { + seconds: etaSeconds, + }) + : ""; return html`
${this.renderButton({ content: html`${translateText("events_display.boat")}: ${renderTroops(boat.troops())}${etaSeconds !== null - ? html` (${etaSeconds}s)` + ? html` (${etaText})` : ""}`, onClick: () => this.emitGoToUnitEvent(boat), className: "text-left text-blue-400",