add game badge to server overview

This commit is contained in:
RaidMax
2022-06-04 09:58:30 -05:00
parent ee56a5db1f
commit c493fbe13d
4 changed files with 11 additions and 4 deletions

View File

@ -15,7 +15,9 @@
foreach (var snapshot in Model.ClientHistory.ClientCounts)
{
snapshot.MapAlias = GetMapName(snapshot.Map);
}
};
string MakeAbbreviation(string gameName) => string.Join("", gameName.Split(' ').Select(word => char.ToUpper(word.First())).ToArray());
}
<div class="card mt-20 mb-20 ml-0 mr-0 p-0">
@ -42,6 +44,7 @@
class="text-light align-self-center">
<i class="oi oi-spreadsheet ml-5 mr-5"></i>
</a>
<span class="ml-5 mr-5 text-light badge font-weight-light" data-toggle="tooltip" data-title="@ViewBag.Localization[$"GAME_{Model.Game}"]">@MakeAbbreviation(ViewBag.Localization[$"GAME_{Model.Game}"])</span>
</div>
</div>
<!-- second column -->
@ -52,6 +55,7 @@
<span>&ndash;</span>
<span>@Model.GameType</span>
}
</div>
<!-- third column -->
<div class="align-self-center d-flex flex-column flex-lg-row col-12 col-lg-2 justify-content-end">