* update tv show ui * update tv season ui * list episode details on tv season page * remove episode page * remove breadcrumbs * move home link * code cleanup * update screenshots
23 lines
641 B
C#
23 lines
641 B
C#
using System;
|
|
using System.Threading.Tasks;
|
|
using Microsoft.AspNetCore.Components;
|
|
using Microsoft.JSInterop;
|
|
|
|
namespace ErsatzTV.Extensions
|
|
{
|
|
public static class NavigationManagerExtensions
|
|
{
|
|
public static ValueTask NavigateToFragmentAsync(this NavigationManager navigationManager, IJSRuntime jSRuntime)
|
|
{
|
|
Uri uri = navigationManager.ToAbsoluteUri(navigationManager.Uri);
|
|
|
|
if (uri.Fragment.Length == 0)
|
|
{
|
|
return default;
|
|
}
|
|
|
|
return jSRuntime.InvokeVoidAsync("blazorHelpers.scrollToFragment", uri.Fragment.Substring(1));
|
|
}
|
|
}
|
|
}
|