Files
AI-Studio/app/MindWork AI Studio/Components/Changelog.razor.cs
T

28 lines
693 B
C#
Raw Normal View History

2024-06-02 20:52:30 +02:00
using Microsoft.AspNetCore.Components;
2024-08-21 08:30:01 +02:00
namespace AIStudio.Components;
2024-06-02 20:52:30 +02:00
2025-04-27 09:06:05 +02:00
public partial class Changelog : MSGComponentBase
2024-06-02 20:52:30 +02:00
{
[Inject]
private WebRootFiles WebRootFiles { get; set; } = null!;
2024-06-02 20:52:30 +02:00
#region Overrides of ComponentBase
protected override async Task OnInitializedAsync()
{
await this.ReadLogAsync();
await base.OnInitializedAsync();
}
#endregion
private Log SelectedLog { get; set; } = LOGS.MaxBy(n => n.Build);
private string LogContent { get; set; } = string.Empty;
private async Task ReadLogAsync()
{
this.LogContent = await this.WebRootFiles.ReadTextAsync($"changelog/{this.SelectedLog.Filename}");
2024-06-02 20:52:30 +02:00
}
}