fixup icons font path
This commit is contained in:
parent
20b8f0b99a
commit
21b0a7998d
@ -54,6 +54,7 @@ steps:
|
||||
Write-Host 'Build Configuration is $(buildConfiguration), Release Type is $(releaseType)'
|
||||
md -Force lib\open-iconic\font\css
|
||||
wget https://raw.githubusercontent.com/iconic/open-iconic/master/font/css/open-iconic-bootstrap.scss -o lib\open-iconic\font\css\open-iconic-bootstrap.scss
|
||||
((Get-Content -path lib\open-iconic\font\css\open-iconic-bootstrap.scss -Raw) -replace '../fonts/','/fonts/') | Set-Content -Path lib\open-iconic\font\css\open-iconic-bootstrap.scss
|
||||
failOnStderr: true
|
||||
workingDirectory: '$(Build.Repository.LocalPath)\WebfrontCore\wwwroot'
|
||||
|
||||
|
@ -60,7 +60,7 @@ namespace WebfrontCore.Controllers
|
||||
ViewBag.Title = Localization["WEBFRONT_TITLE_SCOREBOARD"];
|
||||
ViewBag.SelectedServerId = string.IsNullOrEmpty(serverId) ? Manager.GetServers().FirstOrDefault()?.ToString() : serverId;
|
||||
|
||||
return View(ProjectScoreboard(Manager.GetServers(), null, true, false));
|
||||
return View(ProjectScoreboard(Manager.GetServers(), null, true));
|
||||
}
|
||||
|
||||
[HttpGet("[controller]/{id}/scoreboard")]
|
||||
@ -79,7 +79,7 @@ namespace WebfrontCore.Controllers
|
||||
}
|
||||
|
||||
private static IEnumerable<ScoreboardInfo> ProjectScoreboard(IEnumerable<Server> servers, string order,
|
||||
bool down, bool includeDetails = true)
|
||||
bool down)
|
||||
{
|
||||
return servers.Select((server, index) => new ScoreboardInfo
|
||||
{
|
||||
@ -88,7 +88,7 @@ namespace WebfrontCore.Controllers
|
||||
MapName = server.CurrentMap.ToString(),
|
||||
ServerName = server.Hostname,
|
||||
ServerId = server.ToString(),
|
||||
ClientInfo = index == 0 && !includeDetails || includeDetails ? server.GetClientsAsList().Select(client =>
|
||||
ClientInfo = server.GetClientsAsList().Select(client =>
|
||||
new
|
||||
{
|
||||
stats = client.GetAdditionalProperty<EFClientStatistics>(StatManager.CLIENT_STATS_KEY),
|
||||
@ -107,7 +107,7 @@ namespace WebfrontCore.Controllers
|
||||
ZScore = clientData.stats?.ZScore == null || clientData.stats.ZScore == 0 ? null : clientData.stats.ZScore,
|
||||
Team = clientData.client.Team
|
||||
})
|
||||
.ToList() : new List<ClientScoreboardInfo>()
|
||||
.ToList()
|
||||
}).ToList();
|
||||
}
|
||||
}
|
||||
|
@ -1,12 +1,15 @@
|
||||
@using WebfrontCore.ViewModels
|
||||
@model IEnumerable<WebfrontCore.ViewModels.ScoreboardInfo>
|
||||
@{
|
||||
var selectedServer = Model?.FirstOrDefault(server => server.ServerId == ViewBag.SelectedServerId) ?? Model?.First();
|
||||
}
|
||||
|
||||
<div class="content mt-20 row">
|
||||
<div class="col-12 col-lg-9 col-xl-10">
|
||||
@if (Model is not null)
|
||||
{
|
||||
<div class=" scoreboard-container" data-server-id="@ViewBag.SelectedServerId">
|
||||
@await Html.PartialAsync("_Scoreboard", Model.FirstOrDefault(server => server.ServerId == ViewBag.SelectedServerId) ?? Model.First())
|
||||
<partial name="_Scoreboard" for="@selectedServer"/>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
|
@ -78,6 +78,6 @@
|
||||
</ProjectExtensions>
|
||||
|
||||
<Target Name="PreBuild" BeforeTargets="PreBuildEvent">
|
||||
<Exec Command="if $(ConfigurationName) == Debug ( 
powershell -Command wget https://raw.githubusercontent.com/iconic/open-iconic/master/font/css/open-iconic-bootstrap.scss -o $(ProjectDir)wwwroot\lib\open-iconic\font\css\open-iconic-bootstrap.scss
echo d | xcopy /f /y $(ProjectDir)wwwroot\lib\open-iconic\font\fonts $(ProjectDir)wwwroot\font\
)" />
|
||||
<Exec Command="if $(ConfigurationName) == Debug ( 
powershell -Command wget https://raw.githubusercontent.com/iconic/open-iconic/master/font/css/open-iconic-bootstrap.scss -o $(ProjectDir)wwwroot\lib\open-iconic\font\css\open-iconic-bootstrap.scss
echo d | xcopy /f /y $(ProjectDir)wwwroot\lib\open-iconic\font\fonts $(ProjectDir)wwwroot\font\
powershell -Command "((Get-Content -path $(ProjectDir)wwwroot\lib\open-iconic\font\css\open-iconic-bootstrap.scss -Raw) -replace '../fonts/','/fonts/') | Set-Content -Path $(ProjectDir)wwwroot\lib\open-iconic\font\css\open-iconic-bootstrap.scss"
)" />
|
||||
</Target>
|
||||
</Project>
|
||||
|
@ -1,7 +1,5 @@
|
||||
@import 'profile.scss';
|
||||
|
||||
$icon-font-path: '/font/' !default;
|
||||
|
||||
:root {
|
||||
--blue-color: #007ACC;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user