Reworking the feed fetching

This commit is contained in:
Max Holleman 2023-05-16 15:37:49 +02:00
parent cfd955187b
commit b6867d2ece

View File

@ -5,14 +5,14 @@
@using WebSharpRSS.Models;
@using ToolQit.Extensions;
@inject NavigationManager _navManager;
@inject RssService _rssService
<MudStack Spacing="2">
<MudNavMenu>
@*<MudNavMenu>
<MudNavLink Href="/" Icon="@Icons.Material.Filled.Home">Home</MudNavLink>
</MudNavMenu>
<MudDivider DividerType="DividerType.FullWidth"/>
<MudText Typo="Typo.h5" Class="ml-5">Feeds</MudText>
<MudDivider DividerType="DividerType.FullWidth"/>*@
<MudTreeView Items="Categories" @bind-SelectedValue="SelectedItem" @bind-ActivatedItem="ActivatedItem" Hover="true">
<ItemTemplate>
<MudTreeViewItem @bind-Expanded="@context.IsExpanded" Items="@context.Feeds">
@ -50,7 +50,7 @@
HashSet<CategoryModel> cats = await _rssService.GetCategories();
await Task.Run(() => Categories.UnionWith(cats.Select(x => new TreeItemData(x)).ToHashSet()));
Log.Verbose(" Guide initialized!");
//await Task.Run(() => Categories = cats.Select(x => new TreeItemData(x)).ToHashSet());
}