2024-08-04 17:53:19 -05:00
|
|
|
@using LANCommander.Launcher.Models
|
2024-05-30 00:31:38 -05:00
|
|
|
@using System.Diagnostics
|
2024-05-29 20:01:46 -05:00
|
|
|
@inject SDK.Client Client
|
2024-11-12 02:35:28 -06:00
|
|
|
@inject InstallService InstallService
|
2024-06-11 00:24:29 -05:00
|
|
|
@inject GameService GameService
|
2024-11-12 02:35:28 -06:00
|
|
|
@inject NavigationManager NavigationManager
|
Add localization support to launcher
Adds localization across the launcher and includes English, German, Spanish, French, Italian, Japanese, Korean, Dutch, Portuguese, Ukranian, and Chinese. These localizations were generated by Claude 3.5 and need to be reviewed by a human for accuracy.
2025-08-18 21:29:38 -05:00
|
|
|
@inject LocalizationService LocalizationService
|
2024-11-12 02:35:28 -06:00
|
|
|
|
2025-02-22 00:26:54 -06:00
|
|
|
<Flex Justify="FlexJustify.Center" Align="FlexAlign.Center" Gap="FlexGap.Small" Class="footer">
|
|
|
|
|
<div style="flex: 1;">
|
|
|
|
|
@if (NavigationManager.Uri.Contains("/Depot"))
|
|
|
|
|
{
|
Add localization support to launcher
Adds localization across the launcher and includes English, German, Spanish, French, Italian, Japanese, Korean, Dutch, Portuguese, Ukranian, and Chinese. These localizations were generated by Claude 3.5 and need to be reviewed by a human for accuracy.
2025-08-18 21:29:38 -05:00
|
|
|
<Button Type="@ButtonType.Text" Icon="@IconType.Outline.Hdd" OnClick="@(() => NavigationManager.NavigateTo("/"))">@LocalizationService.GetString("Library")</Button>
|
2025-02-22 00:26:54 -06:00
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
2025-06-09 20:01:54 +02:00
|
|
|
if (Client.Settings?.EnableUserLibraries ?? false)
|
2025-02-22 00:26:54 -06:00
|
|
|
{
|
|
|
|
|
<ConnectionStateView>
|
|
|
|
|
<Online>
|
Add localization support to launcher
Adds localization across the launcher and includes English, German, Spanish, French, Italian, Japanese, Korean, Dutch, Portuguese, Ukranian, and Chinese. These localizations were generated by Claude 3.5 and need to be reviewed by a human for accuracy.
2025-08-18 21:29:38 -05:00
|
|
|
<Button Type="@ButtonType.Text" Icon="@IconType.Outline.AppstoreAdd" OnClick="@(() => NavigationManager.NavigateTo("/Depot"))">@LocalizationService.GetString("Depot")</Button>
|
2025-02-22 00:26:54 -06:00
|
|
|
</Online>
|
|
|
|
|
<Offline>
|
Add localization support to launcher
Adds localization across the launcher and includes English, German, Spanish, French, Italian, Japanese, Korean, Dutch, Portuguese, Ukranian, and Chinese. These localizations were generated by Claude 3.5 and need to be reviewed by a human for accuracy.
2025-08-18 21:29:38 -05:00
|
|
|
<Tooltip Title="@LocalizationService.GetString("YouAreCurrentlyOffline")" Placement="Placement.TopLeft">
|
|
|
|
|
<Button Type="@ButtonType.Text" Icon="@IconType.Outline.AppstoreAdd" Disabled>@LocalizationService.GetString("Depot")</Button>
|
2025-02-22 00:26:54 -06:00
|
|
|
</Tooltip>
|
|
|
|
|
</Offline>
|
|
|
|
|
</ConnectionStateView>
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</div>
|
2024-05-27 17:07:28 -05:00
|
|
|
|
2025-06-09 20:01:54 +02:00
|
|
|
<ConnectionStateView>
|
|
|
|
|
<Online>
|
|
|
|
|
@if (InstallService.Queue.Any(qi => qi.State))
|
|
|
|
|
{
|
|
|
|
|
<div class="downloader" @onclick="() => ShowDownloadQueue()" style="flex-shrink: 0;">
|
|
|
|
|
<CurrentDownloadItem ShowIcon="true"/>
|
|
|
|
|
</div>
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
Add localization support to launcher
Adds localization across the launcher and includes English, German, Spanish, French, Italian, Japanese, Korean, Dutch, Portuguese, Ukranian, and Chinese. These localizations were generated by Claude 3.5 and need to be reviewed by a human for accuracy.
2025-08-18 21:29:38 -05:00
|
|
|
<Button Type="@ButtonType.Text" Icon="@IconType.Outline.Download" OnClick="() => ShowDownloadQueue()">@LocalizationService.GetString("Downloads")</Button>
|
2025-06-09 20:01:54 +02:00
|
|
|
}
|
|
|
|
|
</Online>
|
|
|
|
|
<Offline>
|
Add localization support to launcher
Adds localization across the launcher and includes English, German, Spanish, French, Italian, Japanese, Korean, Dutch, Portuguese, Ukranian, and Chinese. These localizations were generated by Claude 3.5 and need to be reviewed by a human for accuracy.
2025-08-18 21:29:38 -05:00
|
|
|
<Tooltip Title="@LocalizationService.GetString("YouAreCurrentlyOffline")" Placement="Placement.TopLeft">
|
|
|
|
|
<Button Type="@ButtonType.Text" Icon="@IconType.Outline.Download" Disabled>@LocalizationService.GetString("Downloads")</Button>
|
2025-06-09 20:01:54 +02:00
|
|
|
</Tooltip>
|
|
|
|
|
</Offline>
|
|
|
|
|
</ConnectionStateView>
|
2024-11-12 02:35:28 -06:00
|
|
|
|
2025-02-22 00:26:54 -06:00
|
|
|
<div style="flex: 1; text-align: right;">
|
Add localization support to launcher
Adds localization across the launcher and includes English, German, Spanish, French, Italian, Japanese, Korean, Dutch, Portuguese, Ukranian, and Chinese. These localizations were generated by Claude 3.5 and need to be reviewed by a human for accuracy.
2025-08-18 21:29:38 -05:00
|
|
|
<Tooltip Title="@LocalizationService.GetString("ComingSoon")" Placement="Placement.TopRight">
|
|
|
|
|
<Button Type="@ButtonType.Text" Icon="@IconType.Outline.Team" Disabled>@LocalizationService.GetString("Friends")</Button>
|
2025-02-22 00:26:54 -06:00
|
|
|
</Tooltip>
|
|
|
|
|
</div>
|
2024-11-12 02:35:28 -06:00
|
|
|
</Flex>
|
2024-05-27 17:07:28 -05:00
|
|
|
|
2024-08-09 01:24:24 -05:00
|
|
|
<DownloadQueue @ref="DownloadQueue" />
|
2024-05-29 20:13:38 -05:00
|
|
|
|
2024-05-27 17:07:28 -05:00
|
|
|
@code {
|
2025-01-18 20:25:39 -06:00
|
|
|
[CascadingParameter] public bool Connected { get; set; }
|
2025-06-09 20:01:54 +02:00
|
|
|
|
2024-05-29 20:13:38 -05:00
|
|
|
bool DownloadQueueVisible = false;
|
|
|
|
|
|
2024-08-09 01:24:24 -05:00
|
|
|
DownloadQueue DownloadQueue;
|
|
|
|
|
|
2024-06-12 01:28:26 -05:00
|
|
|
protected override async Task OnInitializedAsync()
|
|
|
|
|
{
|
2024-10-26 15:48:47 -05:00
|
|
|
InstallService.OnQueueChanged += async () =>
|
2024-06-12 01:28:26 -05:00
|
|
|
{
|
|
|
|
|
await InvokeAsync(StateHasChanged);
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
|
2024-05-29 20:13:38 -05:00
|
|
|
async Task ShowDownloadQueue()
|
|
|
|
|
{
|
2024-08-09 01:24:24 -05:00
|
|
|
await DownloadQueue.Show();
|
2024-05-29 20:13:38 -05:00
|
|
|
}
|
2024-05-27 17:07:28 -05:00
|
|
|
}
|