57 lines
1.7 KiB
Plaintext
57 lines
1.7 KiB
Plaintext
@using LucideBlazor
|
|
@using Moonlight.Shared.Http.Responses.Admin
|
|
@using ShadcnBlazor.Emptys
|
|
@using ShadcnBlazor.Extras.Common
|
|
|
|
@inject HttpClient HttpClient
|
|
|
|
<div class="mt-5">
|
|
<LazyLoader Load="LoadAsync">
|
|
@if (StatusDto.IsEnabled)
|
|
{
|
|
if (StatusDto.IsReachable)
|
|
{
|
|
}
|
|
else
|
|
{
|
|
<Empty>
|
|
<EmptyHeader>
|
|
<EmptyMedia Variant="EmptyMediaVariant.Icon">
|
|
<CircleAlertIcon ClassName="text-red-500"/>
|
|
</EmptyMedia>
|
|
<EmptyTitle>Container Helper unreachable</EmptyTitle>
|
|
<EmptyDescription>
|
|
The container helper is unreachable. No management actions are available
|
|
</EmptyDescription>
|
|
</EmptyHeader>
|
|
</Empty>
|
|
}
|
|
}
|
|
else
|
|
{
|
|
<Empty>
|
|
<EmptyHeader>
|
|
<EmptyMedia Variant="EmptyMediaVariant.Icon">
|
|
<ToggleLeftIcon/>
|
|
</EmptyMedia>
|
|
<EmptyTitle>Container Helper is disabled</EmptyTitle>
|
|
<EmptyDescription>
|
|
The container helper is disabled on this instance.
|
|
This might be due to running a multiple container moonlight setup
|
|
</EmptyDescription>
|
|
</EmptyHeader>
|
|
</Empty>
|
|
}
|
|
</LazyLoader>
|
|
</div>
|
|
|
|
@code
|
|
{
|
|
private ContainerHelperStatusDto StatusDto;
|
|
|
|
private async Task LoadAsync(LazyLoader _)
|
|
{
|
|
StatusDto = (await HttpClient.GetFromJsonAsync<ContainerHelperStatusDto>("api/admin/ch/status"))!;
|
|
}
|
|
}
|