Updated tags and creators pages.
All checks were successful
ci / build-test (push) Successful in 2m30s
ci / publish-image (push) Successful in 1m46s

This commit is contained in:
2026-04-20 00:36:53 -04:00
parent c203b2cbdb
commit da33973229
2 changed files with 118 additions and 40 deletions

View File

@@ -5,7 +5,9 @@
@using JSMR.Application.Creators.Queries.Search
@using JSMR.Application.Creators.Queries.Search.Contracts
@using JSMR.UI.Blazor.Components
@using JSMR.UI.Blazor.Filters
@using JSMR.UI.Blazor.Services
@using Microsoft.AspNetCore.WebUtilities
<PageTitle>Creators</PageTitle>
@@ -24,7 +26,9 @@
OnChange="HandleTableChange">
<ColumnDefinitions>
<AntDesign.PropertyColumn Property="c => c.Name" Title="Name" Sortable="true" SorterMultiple="4" />
<AntDesign.PropertyColumn Property="c => c.VoiceWorkCount" Title="Voice Works" Format="n0" HeaderStyle="width: 14em" Sortable="true" SorterMultiple="4" />
<AntDesign.PropertyColumn Property="c => c.VoiceWorkCount" Title="Voice Works" Format="n0" HeaderStyle="width: 10em" Sortable="true" SorterMultiple="4">
<AntDesign.Button Size="AntDesign.ButtonSize.Small" Type="AntDesign.ButtonType.Link" OnClick="@(e => NavigateToVoiceWorkSearch(context))" Style="display:flex;justify-self:flex-end;">@context.VoiceWorkCount.ToString("n0")</AntDesign.Button>
</AntDesign.PropertyColumn>
<AntDesign.PropertyColumn Property="c => c.Favorite" Title="Favorite" HeaderStyle="width: 8em" Sortable="true" SortDirections="new[] { AntDesign.SortDirection.Descending }" SorterMultiple="4">
@if (context.Favorite)
{
@@ -74,6 +78,9 @@
</style>
@code {
[Inject]
protected NavigationManager NavigationManager { get; set; } = default!;
public string? Keywords { get; set; }
public int PageNumber { get; set; } = 1;
public int PageSize { get; set; } = 100;
@@ -200,4 +207,18 @@
return finalSorts;
}
private void NavigateToVoiceWorkSearch(CreatorSearchItem item)
{
VoiceWorkFilterState state = new()
{
CreatorIds = [item.CreatorId]
};
//string basePath = new Uri(NavigationManager.Uri).GetLeftPart(UriPartial.Path);
string basePath = new Uri(NavigationManager.Uri).GetLeftPart(UriPartial.Authority);
string uri = QueryHelpers.AddQueryString($"{basePath}/voiceworks", state.ToQuery());
NavigationManager.NavigateTo(uri);
}
}