mirror of
https://github.com/lantean-code/qbtmud.git
synced 2025-10-22 20:42:24 +00:00
Update layout to remove hacks and rely only on flexbox
This commit is contained in:
@@ -2,45 +2,48 @@
|
||||
<MudMenuItem Icon="@Icons.Material.Filled.DriveFileRenameOutline" OnClick="RenameFileContextMenu">Rename</MudMenuItem>
|
||||
</MudMenu>
|
||||
|
||||
<div style="overflow-x: auto; white-space: nowrap; width: 100%;">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.DriveFileRenameOutline" OnClick="RenameFileToolbar" title="Rename" />
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.ViewColumn" Color="Color.Inherit" OnClick="ColumnOptions" title="Choose Columns" />
|
||||
<MudDivider Vertical="true" />
|
||||
<MudMenu Icon="@Icons.Material.Outlined.FileDownloadOff" Label="Do Not Download" AnchorOrigin="Origin.BottomLeft" TransformOrigin="Origin.TopLeft" title="Do Not Download">
|
||||
<MudMenuItem OnClick="DoNotDownloadLessThan100PercentAvailability">Less Than 100% Availability</MudMenuItem>
|
||||
<MudMenuItem OnClick="DoNotDownloadLessThan80PercentAvailability">Less than 80% Availability</MudMenuItem>
|
||||
<MudMenuItem OnClick="DoNotDownloadCurrentlyFilteredFiles">Currently Filtered Files</MudMenuItem>
|
||||
</MudMenu>
|
||||
<MudMenu Icon="@Icons.Material.Outlined.FileDownload" Label="Normal Priority" AnchorOrigin="Origin.BottomLeft" TransformOrigin="Origin.TopLeft" title="Download">
|
||||
<MudMenuItem OnClick="NormalPriorityLessThan100PercentAvailability">Less Than 100% Availability</MudMenuItem>
|
||||
<MudMenuItem OnClick="NormalPriorityLessThan80PercentAvailability">Less than 80% Availability</MudMenuItem>
|
||||
<MudMenuItem OnClick="NormalPriorityCurrentlyFilteredFiles">Currently Filtered Files</MudMenuItem>
|
||||
</MudMenu>
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.FilterList" OnClick="ShowFilterDialog" title="Filter" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.FilterListOff" OnClick="RemoveFilter" title="Remove Filter" />
|
||||
<MudSpacer />
|
||||
<MudTextField T="string" Value="SearchText" ValueChanged="SearchTextChanged" Immediate="true" DebounceInterval="500" Placeholder="Filter file list" Adornment="Adornment.Start" AdornmentIcon="@Icons.Material.Filled.Search" IconSize="Size.Medium" Class="mt-0"></MudTextField>
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar content-panel__toolbar--scroll">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.DriveFileRenameOutline" OnClick="RenameFileToolbar" title="Rename" />
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.ViewColumn" Color="Color.Inherit" OnClick="ColumnOptions" title="Choose Columns" />
|
||||
<MudDivider Vertical="true" />
|
||||
<MudMenu Icon="@Icons.Material.Outlined.FileDownloadOff" Label="Do Not Download" AnchorOrigin="Origin.BottomLeft" TransformOrigin="Origin.TopLeft" title="Do Not Download">
|
||||
<MudMenuItem OnClick="DoNotDownloadLessThan100PercentAvailability">Less Than 100% Availability</MudMenuItem>
|
||||
<MudMenuItem OnClick="DoNotDownloadLessThan80PercentAvailability">Less than 80% Availability</MudMenuItem>
|
||||
<MudMenuItem OnClick="DoNotDownloadCurrentlyFilteredFiles">Currently Filtered Files</MudMenuItem>
|
||||
</MudMenu>
|
||||
<MudMenu Icon="@Icons.Material.Outlined.FileDownload" Label="Normal Priority" AnchorOrigin="Origin.BottomLeft" TransformOrigin="Origin.TopLeft" title="Download">
|
||||
<MudMenuItem OnClick="NormalPriorityLessThan100PercentAvailability">Less Than 100% Availability</MudMenuItem>
|
||||
<MudMenuItem OnClick="NormalPriorityLessThan80PercentAvailability">Less than 80% Availability</MudMenuItem>
|
||||
<MudMenuItem OnClick="NormalPriorityCurrentlyFilteredFiles">Currently Filtered Files</MudMenuItem>
|
||||
</MudMenu>
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.FilterList" OnClick="ShowFilterDialog" title="Filter" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.FilterListOff" OnClick="RemoveFilter" title="Remove Filter" />
|
||||
<MudSpacer />
|
||||
<MudTextField T="string" Value="SearchText" ValueChanged="SearchTextChanged" Immediate="true" DebounceInterval="500" Placeholder="Filter file list" Adornment="Adornment.Start" AdornmentIcon="@Icons.Material.Filled.Search" IconSize="Size.Medium" Class="mt-0"></MudTextField>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
<div class="content-panel__body">
|
||||
<DynamicTable
|
||||
@ref="Table"
|
||||
T="ContentItem"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Files"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="true"
|
||||
PreSorted="true"
|
||||
SelectedItemChanged="SelectedItemChanged"
|
||||
SortColumnChanged="SortColumnChanged"
|
||||
SortDirectionChanged="SortDirectionChanged"
|
||||
OnTableDataContextMenu="TableDataContextMenu"
|
||||
OnTableDataLongPress="TableDataLongPress"
|
||||
Class="file-list content-panel__table"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<DynamicTable
|
||||
@ref="Table"
|
||||
T="ContentItem"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Files"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="true"
|
||||
PreSorted="true"
|
||||
SelectedItemChanged="SelectedItemChanged"
|
||||
SortColumnChanged="SortColumnChanged"
|
||||
SortDirectionChanged="SortDirectionChanged"
|
||||
OnTableDataContextMenu="TableDataContextMenu"
|
||||
OnTableDataLongPress="TableDataLongPress"
|
||||
Class="file-list"
|
||||
/>
|
||||
|
||||
@code {
|
||||
private RenderFragment<RowContext<ContentItem>> NameColumn
|
||||
{
|
||||
|
@@ -6,19 +6,25 @@
|
||||
}
|
||||
</MudMenu>
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.AddCircle" Color="Color.Info" OnClick="AddPeer">Add peer</MudIconButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.DisabledByDefault" Color="Color.Error" OnClick="BanPeerToolbar" Disabled="@(SelectedItem is null)">Ban peer</MudIconButton>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.ViewColumn" Color="Color.Inherit" OnClick="ColumnOptions" title="Choose Columns" />
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.AddCircle" Color="Color.Info" OnClick="AddPeer">Add peer</MudIconButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.DisabledByDefault" Color="Color.Error" OnClick="BanPeerToolbar" Disabled="@(SelectedItem is null)">Ban peer</MudIconButton>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.ViewColumn" Color="Color.Inherit" OnClick="ColumnOptions" title="Choose Columns" />
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
<DynamicTable T="Peer"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Peers"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="true"
|
||||
OnTableDataLongPress="TableDataLongPress"
|
||||
OnTableDataContextMenu="TableDataContextMenu"
|
||||
SelectedItemChanged="SelectedItemChanged"
|
||||
Class="details-list" />
|
||||
<div class="content-panel__body">
|
||||
<DynamicTable T="Peer"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Peers"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="true"
|
||||
OnTableDataLongPress="TableDataLongPress"
|
||||
OnTableDataContextMenu="TableDataContextMenu"
|
||||
SelectedItemChanged="SelectedItemChanged"
|
||||
Class="details-list content-panel__table" />
|
||||
</div>
|
||||
</div>
|
@@ -8,25 +8,31 @@
|
||||
}
|
||||
</MudMenu>
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.AddCircle" Color="Color.Info" OnClick="AddTracker">Add trackers</MudIconButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Edit" Color="Color.Info" OnClick="EditTrackerToolbar" Disabled="@(SelectedItem is null)">Edit tracker URL</MudIconButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Delete" Color="Color.Error" OnClick="RemoveTrackerToolbar" Disabled="@(SelectedItem is null)">Remove tracker</MudIconButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.FolderCopy" Color="Color.Info" OnClick="CopyTrackerUrlToolbar" Disabled="@(SelectedItem is null)">Copy tracker url</MudIconButton>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.ViewColumn" Color="Color.Inherit" OnClick="ColumnOptions" title="Choose Columns" />
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.AddCircle" Color="Color.Info" OnClick="AddTracker">Add trackers</MudIconButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Edit" Color="Color.Info" OnClick="EditTrackerToolbar" Disabled="@(SelectedItem is null)">Edit tracker URL</MudIconButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Delete" Color="Color.Error" OnClick="RemoveTrackerToolbar" Disabled="@(SelectedItem is null)">Remove tracker</MudIconButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.FolderCopy" Color="Color.Info" OnClick="CopyTrackerUrlToolbar" Disabled="@(SelectedItem is null)">Copy tracker url</MudIconButton>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.ViewColumn" Color="Color.Inherit" OnClick="ColumnOptions" title="Choose Columns" />
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
<DynamicTable @ref="Table"
|
||||
T="Lantean.QBitTorrentClient.Models.TorrentTracker"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Trackers"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
PreSorted="true"
|
||||
SortDirectionChanged="SortDirectionChanged"
|
||||
SortColumnChanged="SortColumnChanged"
|
||||
OnTableDataLongPress="TableDataLongPress"
|
||||
OnTableDataContextMenu="TableDataContextMenu"
|
||||
SelectedItemChanged="SelectedItemChanged"
|
||||
Class="file-list" />
|
||||
<div class="content-panel__body">
|
||||
<DynamicTable @ref="Table"
|
||||
T="Lantean.QBitTorrentClient.Models.TorrentTracker"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Trackers"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
PreSorted="true"
|
||||
SortDirectionChanged="SortDirectionChanged"
|
||||
SortColumnChanged="SortColumnChanged"
|
||||
OnTableDataLongPress="TableDataLongPress"
|
||||
OnTableDataContextMenu="TableDataContextMenu"
|
||||
SelectedItemChanged="SelectedItemChanged"
|
||||
Class="file-list content-panel__table" />
|
||||
</div>
|
||||
</div>
|
@@ -1,6 +1,10 @@
|
||||
<DynamicTable T="Lantean.QBitTorrentClient.Models.WebSeed"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="WebSeeds"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
Class="details-list" />
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__body">
|
||||
<DynamicTable T="Lantean.QBitTorrentClient.Models.WebSeed"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="WebSeeds"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
Class="details-list content-panel__table" />
|
||||
</div>
|
||||
</div>
|
@@ -1,9 +1,11 @@
|
||||
@inherits LayoutComponentBase
|
||||
@layout LoggedInLayout
|
||||
|
||||
<MudDrawer Open="DrawerOpen" ClipMode="DrawerClipMode.Always" Elevation="2" Overlay="false">
|
||||
<TorrentsListNav Torrents="Torrents" SelectedTorrent="@SelectedTorrent" SortDirection="SortDirection" SortColumn="@SortColumn" />
|
||||
</MudDrawer>
|
||||
<MudMainContent>
|
||||
@Body
|
||||
</MudMainContent>
|
||||
<div class="app-shell__body">
|
||||
<MudDrawer Open="DrawerOpen" ClipMode="DrawerClipMode.Always" Elevation="2" Overlay="false" Class="app-shell__sidebar">
|
||||
<TorrentsListNav Torrents="Torrents" SelectedTorrent="@SelectedTorrent" SortDirection="SortDirection" SortColumn="@SortColumn" />
|
||||
</MudDrawer>
|
||||
<MudMainContent Class="app-shell__main">
|
||||
@Body
|
||||
</MudMainContent>
|
||||
</div>
|
@@ -1,11 +1,13 @@
|
||||
@inherits LayoutComponentBase
|
||||
@layout LoggedInLayout
|
||||
|
||||
<MudDrawer Open="DrawerOpen" ClipMode="DrawerClipMode.Always" Elevation="2" Overlay="false">
|
||||
<FiltersNav CategoryChanged="CategoryChanged" StatusChanged="StatusChanged" TagChanged="TagChanged" TrackerChanged="TrackerChanged" />
|
||||
</MudDrawer>
|
||||
<MudMainContent>
|
||||
<CascadingValue Value="SearchTermChanged" Name="SearchTermChanged">
|
||||
@Body
|
||||
</CascadingValue>
|
||||
</MudMainContent>
|
||||
<div class="app-shell__body">
|
||||
<MudDrawer Open="DrawerOpen" ClipMode="DrawerClipMode.Always" Elevation="2" Overlay="false" Class="app-shell__sidebar">
|
||||
<FiltersNav CategoryChanged="CategoryChanged" StatusChanged="StatusChanged" TagChanged="TagChanged" TrackerChanged="TrackerChanged" />
|
||||
</MudDrawer>
|
||||
<MudMainContent Class="app-shell__main">
|
||||
<CascadingValue Value="SearchTermChanged" Name="SearchTermChanged">
|
||||
@Body
|
||||
</CascadingValue>
|
||||
</MudMainContent>
|
||||
</div>
|
@@ -12,19 +12,51 @@
|
||||
<CascadingValue Value="Torrents">
|
||||
<CascadingValue Value="_torrentsVersion" Name="TorrentsVersion">
|
||||
<CascadingValue Value="MainData">
|
||||
<CascadingValue Value="Preferences">
|
||||
<CascadingValue Value="SortColumnChanged" Name="SortColumnChanged">
|
||||
<CascadingValue Value="SortColumn" Name="SortColumn">
|
||||
<CascadingValue Value="SortDirectionChanged" Name="SortDirectionChanged">
|
||||
<CascadingValue Value="SortDirection" Name="SortDirection">
|
||||
<CascadingValue Value="CategoryChanged" Name="CategoryChanged">
|
||||
<CascadingValue Value="StatusChanged" Name="StatusChanged">
|
||||
<CascadingValue Value="TagChanged" Name="TagChanged">
|
||||
<CascadingValue Value="TrackerChanged" Name="TrackerChanged">
|
||||
<CascadingValue Value="SearchTermChanged" Name="SearchTermChanged">
|
||||
<CascadingValue Value="@(MainData?.LostConnection ?? false)" Name="LostConnection">
|
||||
<CascadingValue Value="Version" Name="Version">
|
||||
@Body
|
||||
<CascadingValue Value="Preferences">
|
||||
<CascadingValue Value="SortColumnChanged" Name="SortColumnChanged">
|
||||
<CascadingValue Value="SortColumn" Name="SortColumn">
|
||||
<CascadingValue Value="SortDirectionChanged" Name="SortDirectionChanged">
|
||||
<CascadingValue Value="SortDirection" Name="SortDirection">
|
||||
<CascadingValue Value="CategoryChanged" Name="CategoryChanged">
|
||||
<CascadingValue Value="StatusChanged" Name="StatusChanged">
|
||||
<CascadingValue Value="TagChanged" Name="TagChanged">
|
||||
<CascadingValue Value="TrackerChanged" Name="TrackerChanged">
|
||||
<CascadingValue Value="SearchTermChanged" Name="SearchTermChanged">
|
||||
<CascadingValue Value="@(MainData?.LostConnection ?? false)" Name="LostConnection">
|
||||
<CascadingValue Value="Version" Name="Version">
|
||||
<div class="app-shell">
|
||||
@Body
|
||||
<MudAppBar Bottom="true" Elevation="0" Dense="true" Class="app-shell__status-bar">
|
||||
@if (MainData?.LostConnection == true)
|
||||
{
|
||||
<MudText Class="mx-2 mb-1 d-none d-sm-flex" Color="Color.Error">qBittorrent client is not reachable</MudText>
|
||||
}
|
||||
<MudSpacer />
|
||||
<MudText Class="mx-2 mb-1 d-none d-sm-flex">@DisplayHelpers.Size(MainData?.ServerState.FreeSpaceOnDisk, "Free space: ")</MudText>
|
||||
<MudDivider Vertical="true" Class="d-none d-sm-flex" />
|
||||
<MudText Class="mx-2 mb-1 d-none d-sm-flex">DHT @(MainData?.ServerState.DHTNodes ?? 0) nodes</MudText>
|
||||
<MudDivider Vertical="true" Class="d-none d-sm-flex" />
|
||||
@{
|
||||
var (icon, colour) = GetConnectionIcon(MainData?.ServerState.ConnectionStatus);
|
||||
}
|
||||
<MudIcon Class="mx-1 mb-1" Icon="@icon" Color="@colour" Title="@MainData?.ServerState.ConnectionStatus" />
|
||||
<MudDivider Vertical="true" Class="" />
|
||||
<MudIcon Class="mx-1 mb-1" Icon="@Icons.Material.Outlined.Speed" Color="@((MainData?.ServerState.UseAltSpeedLimits ?? false) ? Color.Error : Color.Success)" />
|
||||
<MudDivider Vertical="true" Class="" />
|
||||
<MudIcon Class="ml-1 mb-1" Icon="@Icons.Material.Filled.KeyboardDoubleArrowDown" Color="Color.Success" />
|
||||
<MudText Class="mr-1 mb-1">
|
||||
@DisplayHelpers.Size(MainData?.ServerState.DownloadInfoSpeed, null, "/s")
|
||||
@DisplayHelpers.Size(MainData?.ServerState.DownloadInfoData, "(", ")")
|
||||
</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIcon Class="ml-1 mb-1" Icon="@Icons.Material.Filled.KeyboardDoubleArrowUp" Color="Color.Info" />
|
||||
<MudText Class="mr-1 mb-1">
|
||||
@DisplayHelpers.Size(MainData?.ServerState.UploadInfoSpeed, null, "/s")
|
||||
@DisplayHelpers.Size(MainData?.ServerState.UploadInfoData, "(", ")")
|
||||
</MudText>
|
||||
</MudAppBar>
|
||||
</div>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
@@ -37,35 +69,5 @@
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
<MudAppBar Bottom="true" Fixed="true" Elevation="0" Dense="true" Style="background-color: var(--mud-palette-dark-lighten); z-index: 900">
|
||||
@if (MainData?.LostConnection == true)
|
||||
{
|
||||
<MudText Class="mx-2 mb-1 d-none d-sm-flex" Color="Color.Error">qBittorrent client is not reachable</MudText>
|
||||
}
|
||||
<MudSpacer />
|
||||
<MudText Class="mx-2 mb-1 d-none d-sm-flex">@DisplayHelpers.Size(MainData?.ServerState.FreeSpaceOnDisk, "Free space: ")</MudText>
|
||||
<MudDivider Vertical="true" Class="d-none d-sm-flex" />
|
||||
<MudText Class="mx-2 mb-1 d-none d-sm-flex">DHT @(MainData?.ServerState.DHTNodes ?? 0) nodes</MudText>
|
||||
<MudDivider Vertical="true" Class="d-none d-sm-flex" />
|
||||
@{
|
||||
var (icon, colour) = GetConnectionIcon(MainData?.ServerState.ConnectionStatus);
|
||||
}
|
||||
<MudIcon Class="mx-1 mb-1" Icon="@icon" Color="@colour" Title="@MainData?.ServerState.ConnectionStatus" />
|
||||
<MudDivider Vertical="true" Class="" />
|
||||
<MudIcon Class="mx-1 mb-1" Icon="@Icons.Material.Outlined.Speed" Color="@((MainData?.ServerState.UseAltSpeedLimits ?? false) ? Color.Error : Color.Success)" />
|
||||
<MudDivider Vertical="true" Class="" />
|
||||
<MudIcon Class="ml-1 mb-1" Icon="@Icons.Material.Filled.KeyboardDoubleArrowDown" Color="Color.Success" />
|
||||
<MudText Class="mr-1 mb-1">
|
||||
@DisplayHelpers.Size(MainData?.ServerState.DownloadInfoSpeed, null, "/s")
|
||||
@DisplayHelpers.Size(MainData?.ServerState.DownloadInfoData, "(", ")")
|
||||
</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIcon Class="ml-1 mb-1" Icon="@Icons.Material.Filled.KeyboardDoubleArrowUp" Color="Color.Info" />
|
||||
<MudText Class="mr-1 mb-1">
|
||||
@DisplayHelpers.Size(MainData?.ServerState.UploadInfoSpeed, null, "/s")
|
||||
@DisplayHelpers.Size(MainData?.ServerState.UploadInfoData, "(", ")")
|
||||
</MudText>
|
||||
</MudAppBar>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
@@ -1,11 +1,13 @@
|
||||
@inherits LayoutComponentBase
|
||||
@layout LoggedInLayout
|
||||
|
||||
<MudDrawer Open="DrawerOpen" ClipMode="DrawerClipMode.Always" Elevation="2" Overlay="false">
|
||||
<MudNavMenu>
|
||||
<ApplicationActions IsMenu="false" Preferences="Preferences" />
|
||||
</MudNavMenu>
|
||||
</MudDrawer>
|
||||
<MudMainContent>
|
||||
@Body
|
||||
</MudMainContent>
|
||||
<div class="app-shell__body">
|
||||
<MudDrawer Open="DrawerOpen" ClipMode="DrawerClipMode.Always" Elevation="2" Overlay="false" Class="app-shell__sidebar">
|
||||
<MudNavMenu>
|
||||
<ApplicationActions IsMenu="false" Preferences="Preferences" />
|
||||
</MudNavMenu>
|
||||
</MudDrawer>
|
||||
<MudMainContent Class="app-shell__main">
|
||||
@Body
|
||||
</MudMainContent>
|
||||
</div>
|
||||
|
@@ -2,14 +2,14 @@
|
||||
{
|
||||
public class FileRow
|
||||
{
|
||||
public string OriginalName { get; set; }
|
||||
public required string OriginalName { get; set; }
|
||||
public string? NewName { get; set; }
|
||||
public bool IsFolder { get; set; }
|
||||
public string Name { get; set; }
|
||||
public required string Name { get; set; }
|
||||
public int Level { get; set; }
|
||||
public bool Renamed { get; set; }
|
||||
public string? ErrorMessage { get; set; }
|
||||
public string Path { get; set; }
|
||||
public required string Path { get; set; }
|
||||
|
||||
public override bool Equals(object? obj)
|
||||
{
|
||||
|
@@ -1,18 +1,22 @@
|
||||
@page "/about"
|
||||
@layout OtherLayout
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">About</MudText>
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">About</MudText>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
<MudTabs Elevation="2" ApplyEffectsToContainer="true">
|
||||
<MudTabPanel Text="About">
|
||||
<MudContainer MaxWidth="MaxWidth.ExtraExtraLarge" Class="mt-3">
|
||||
<div class="content-panel__body">
|
||||
<MudTabs Elevation="2" ApplyEffectsToContainer="true">
|
||||
<MudTabPanel Text="About">
|
||||
<MudContainer MaxWidth="MaxWidth.ExtraExtraLarge" Class="mt-3 content-panel__container">
|
||||
<MudGrid Class="mt-0 mb-4">
|
||||
<MudItem xs="12" sm="3" md="2" lg="2" xl="1" Class="d-flex justify-center">
|
||||
<MudImage Src="images/mascot.png" Alt="Mascot" Class="ma-6"
|
||||
@@ -1104,4 +1108,6 @@
|
||||
<MudText Typo="Typo.body1" Class="py-1">The free IP to Country Lite database by DB-IP is used for resolving the countries of peers. The database is licensed under the Creative Commons Attribution 4.0 International License (<MudLink Target="https://db-ip.com/" Href="https://db-ip.com/" rel="noopener ">https://db-ip.com/</MudLink>)</MudText>
|
||||
</MudContainer>
|
||||
</MudTabPanel>
|
||||
</MudTabs>
|
||||
</MudTabs>
|
||||
</div>
|
||||
</div>
|
@@ -1,36 +1,41 @@
|
||||
@page "/blocks"
|
||||
@layout OtherLayout
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">Blocked IPs</MudText>
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">Blocked IPs</MudText>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
<div class="content-panel__body">
|
||||
<MudCard Elevation="1" Class="ml-4 mr-4 mb-4">
|
||||
<MudCardContent>
|
||||
<EditForm Model="Model" OnSubmit="Submit">
|
||||
<MudGrid>
|
||||
<MudItem md="10">
|
||||
<MudTextField T="string" Label="Criteria" @bind-Value="Model.Criteria" Variant="Variant.Outlined" />
|
||||
</MudItem>
|
||||
<MudItem md="2">
|
||||
<MudButton ButtonType="ButtonType.Submit" FullWidth="true" Color="Color.Primary" EndIcon="@Icons.Material.Filled.Search" Variant="Variant.Filled" Class="mt-6">Filter</MudButton>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</EditForm>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
|
||||
<MudCard Elevation="1" Class="ml-4 mr-4 mb-4">
|
||||
<MudCardContent>
|
||||
<EditForm Model="Model" OnSubmit="Submit">
|
||||
<MudGrid>
|
||||
<MudItem md="10">
|
||||
<MudTextField T="string" Label="Criteria" @bind-Value="Model.Criteria" Variant="Variant.Outlined" />
|
||||
</MudItem>
|
||||
<MudItem md="2">
|
||||
<MudButton ButtonType="ButtonType.Submit" FullWidth="true" Color="Color.Primary" EndIcon="@Icons.Material.Filled.Search" Variant="Variant.Filled" Class="mt-6">Filter</MudButton>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</EditForm>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
|
||||
<DynamicTable @ref="Table"
|
||||
T="Lantean.QBitTorrentClient.Models.PeerLog"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
RowClassFunc="RowClass"
|
||||
Class="search-list" />
|
||||
<DynamicTable @ref="Table"
|
||||
T="Lantean.QBitTorrentClient.Models.PeerLog"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
RowClassFunc="RowClass"
|
||||
Class="search-list content-panel__table" />
|
||||
</div>
|
||||
</div>
|
@@ -1,24 +1,30 @@
|
||||
@page "/categories"
|
||||
@layout OtherLayout
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">Categories</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Filled.PlaylistAdd" OnClick="AddCategory" title="Add Category" />
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">Categories</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Filled.PlaylistAdd" OnClick="AddCategory" title="Add Category" />
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
<DynamicTable @ref="Table"
|
||||
T="Category"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
Class="details-list" />
|
||||
<div class="content-panel__body">
|
||||
<DynamicTable @ref="Table"
|
||||
T="Category"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
Class="details-list content-panel__table" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@code {
|
||||
private RenderFragment<RowContext<Category>> ActionsColumn
|
||||
|
@@ -1,41 +1,45 @@
|
||||
@page "/details/{hash}"
|
||||
@layout DetailsLayout
|
||||
|
||||
<div style="overflow-x: auto; white-space: nowrap; width: 100%;">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
@if (Hash is not null)
|
||||
{
|
||||
<TorrentActions RenderType="RenderType.InitialIconsOnly" Hashes="@([Hash])" Torrents="MainData.Torrents" Preferences="Preferences" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">@Name</MudText>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar content-panel__toolbar--scroll">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
@if (Hash is not null)
|
||||
{
|
||||
<TorrentActions RenderType="RenderType.InitialIconsOnly" Hashes="@([Hash])" Torrents="MainData.Torrents" Preferences="Preferences" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">@Name</MudText>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
@if (ShowTabs)
|
||||
{
|
||||
<CascadingValue Value="RefreshInterval" Name="RefreshInterval">
|
||||
<MudTabs Elevation="2" ApplyEffectsToContainer="true" @bind-ActivePanelIndex="ActiveTab" KeepPanelsAlive="true" Border="true">
|
||||
<MudTabPanel Text="General">
|
||||
<GeneralTab Hash="@Hash" Active="@(ActiveTab == 0)" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Trackers">
|
||||
<TrackersTab Hash="@Hash" Active="@(ActiveTab == 1)" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Peers">
|
||||
<PeersTab Hash="@Hash" Active="@(ActiveTab == 2)" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="HTTP Sources">
|
||||
<WebSeedsTab Hash="@Hash" Active="@(ActiveTab == 3)" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Content">
|
||||
<FilesTab Hash="@Hash" Active="@(ActiveTab == 4)" />
|
||||
</MudTabPanel>
|
||||
</MudTabs>
|
||||
</CascadingValue>
|
||||
}
|
||||
<div class="content-panel__body">
|
||||
@if (ShowTabs)
|
||||
{
|
||||
<CascadingValue Value="RefreshInterval" Name="RefreshInterval">
|
||||
<MudTabs Elevation="2" ApplyEffectsToContainer="true" @bind-ActivePanelIndex="ActiveTab" KeepPanelsAlive="true" Border="true">
|
||||
<MudTabPanel Text="General">
|
||||
<GeneralTab Hash="@Hash" Active="@(ActiveTab == 0)" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Trackers">
|
||||
<TrackersTab Hash="@Hash" Active="@(ActiveTab == 1)" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Peers">
|
||||
<PeersTab Hash="@Hash" Active="@(ActiveTab == 2)" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="HTTP Sources">
|
||||
<WebSeedsTab Hash="@Hash" Active="@(ActiveTab == 3)" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Content">
|
||||
<FilesTab Hash="@Hash" Active="@(ActiveTab == 4)" />
|
||||
</MudTabPanel>
|
||||
</MudTabs>
|
||||
</CascadingValue>
|
||||
}
|
||||
</div>
|
||||
</div>
|
@@ -1,44 +1,49 @@
|
||||
@page "/log"
|
||||
@layout OtherLayout
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">Execution Log</MudText>
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">Execution Log</MudText>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
<div class="content-panel__body">
|
||||
<MudCard Elevation="1" Class="ml-4 mr-4 mb-4">
|
||||
<MudCardContent>
|
||||
<EditForm Model="Model" OnSubmit="Submit">
|
||||
<MudGrid>
|
||||
<MudItem md="7">
|
||||
<MudTextField T="string" Label="Criteria" @bind-Value="Model.Criteria" Variant="Variant.Outlined" />
|
||||
</MudItem>
|
||||
<MudItem md="3">
|
||||
<MudSelect @ref="CategoryMudSelect" T="string" Label="Categories" SelectedValues="Model.SelectedTypes" SelectedValuesChanged="SelectedValuesChanged" Variant="Variant.Outlined" MultiSelection="true" MultiSelectionTextFunc="GenerateSelectedText" SelectAll="true">
|
||||
<MudSelectItem Value="@("Normal")">Normal</MudSelectItem>
|
||||
<MudSelectItem Value="@("Info")">Info</MudSelectItem>
|
||||
<MudSelectItem Value="@("Warning")">Warning</MudSelectItem>
|
||||
<MudSelectItem Value="@("Critical")">Critical</MudSelectItem>
|
||||
</MudSelect>
|
||||
</MudItem>
|
||||
<MudItem md="2">
|
||||
<MudButton ButtonType="ButtonType.Submit" FullWidth="true" Color="Color.Primary" EndIcon="@Icons.Material.Filled.Search" Variant="Variant.Filled" Class="mt-6">Filter</MudButton>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</EditForm>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
|
||||
<MudCard Elevation="1" Class="ml-4 mr-4 mb-4">
|
||||
<MudCardContent>
|
||||
<EditForm Model="Model" OnSubmit="Submit">
|
||||
<MudGrid>
|
||||
<MudItem md="7">
|
||||
<MudTextField T="string" Label="Criteria" @bind-Value="Model.Criteria" Variant="Variant.Outlined" />
|
||||
</MudItem>
|
||||
<MudItem md="3">
|
||||
<MudSelect @ref="CategoryMudSelect" T="string" Label="Categories" SelectedValues="Model.SelectedTypes" SelectedValuesChanged="SelectedValuesChanged" Variant="Variant.Outlined" MultiSelection="true" MultiSelectionTextFunc="GenerateSelectedText" SelectAll="true">
|
||||
<MudSelectItem Value="@("Normal")">Normal</MudSelectItem>
|
||||
<MudSelectItem Value="@("Info")">Info</MudSelectItem>
|
||||
<MudSelectItem Value="@("Warning")">Warning</MudSelectItem>
|
||||
<MudSelectItem Value="@("Critical")">Critical</MudSelectItem>
|
||||
</MudSelect>
|
||||
</MudItem>
|
||||
<MudItem md="2">
|
||||
<MudButton ButtonType="ButtonType.Submit" FullWidth="true" Color="Color.Primary" EndIcon="@Icons.Material.Filled.Search" Variant="Variant.Filled" Class="mt-6">Filter</MudButton>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</EditForm>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
|
||||
<DynamicTable @ref="Table"
|
||||
T="Lantean.QBitTorrentClient.Models.Log"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
RowClassFunc="RowClass"
|
||||
Class="search-list" />
|
||||
<DynamicTable @ref="Table"
|
||||
T="Lantean.QBitTorrentClient.Models.Log"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
RowClassFunc="RowClass"
|
||||
Class="search-list content-panel__table" />
|
||||
</div>
|
||||
</div>
|
@@ -3,41 +3,63 @@
|
||||
|
||||
<NavigationLock ConfirmExternalNavigation="@(UpdatePreferences is not null)" OnBeforeInternalNavigation="ValidateExit" />
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">Settings</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Save" OnClick="Save" Disabled="@(LostConnection || UpdatePreferences is null)" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Undo" OnClick="Undo" Disabled="@(LostConnection || UpdatePreferences is null)" />
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">Settings</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Save" OnClick="Save" Disabled="@(LostConnection || UpdatePreferences is null)" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Undo" OnClick="Undo" Disabled="@(LostConnection || UpdatePreferences is null)" />
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
<MudTabs Elevation="2" ApplyEffectsToContainer="true" @bind-ActivePanelIndex="ActiveTab" Border="true">
|
||||
<MudTabPanel Text="Behaviour">
|
||||
<BehaviourOptions @ref="BehaviourOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Downloads">
|
||||
<DownloadsOptions @ref="DownloadsOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Connection">
|
||||
<ConnectionOptions @ref="ConnectionOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Speed">
|
||||
<SpeedOptions @ref="SpeedOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="BitTorrent">
|
||||
<BitTorrentOptions @ref="BitTorrentOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="RSS">
|
||||
<RSSOptions @ref="RSSOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Web UI">
|
||||
<WebUIOptions @ref="WebUIOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Advanced">
|
||||
<AdvancedOptions @ref="AdvancedOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</MudTabPanel>
|
||||
</MudTabs>
|
||||
<div class="content-panel__body">
|
||||
<MudTabs Elevation="2" ApplyEffectsToContainer="true" @bind-ActivePanelIndex="ActiveTab" Border="true">
|
||||
<MudTabPanel Text="Behaviour">
|
||||
<div class="options-tab-contents">
|
||||
<BehaviourOptions @ref="BehaviourOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</div>
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Downloads">
|
||||
<div class="options-tab-contents">
|
||||
<DownloadsOptions @ref="DownloadsOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</div>
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Connection">
|
||||
<div class="options-tab-contents">
|
||||
<ConnectionOptions @ref="ConnectionOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</div>
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Speed">
|
||||
<div class="options-tab-contents">
|
||||
<SpeedOptions @ref="SpeedOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</div>
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="BitTorrent">
|
||||
<div class="options-tab-contents">
|
||||
<BitTorrentOptions @ref="BitTorrentOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</div>
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="RSS">
|
||||
<div class="options-tab-contents">
|
||||
<RSSOptions @ref="RSSOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</div>
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Web UI">
|
||||
<div class="options-tab-contents">
|
||||
<WebUIOptions @ref="WebUIOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</div>
|
||||
</MudTabPanel>
|
||||
<MudTabPanel Text="Advanced">
|
||||
<div class="options-tab-contents">
|
||||
<AdvancedOptions @ref="AdvancedOptions" Preferences="Preferences" UpdatePreferences="@UpdatePreferences" PreferencesChanged="PreferencesChanged" />
|
||||
</div>
|
||||
</MudTabPanel>
|
||||
</MudTabs>
|
||||
</div>
|
||||
</div>
|
@@ -1,73 +1,79 @@
|
||||
@page "/rss"
|
||||
@layout OtherLayout
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">RSS</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Subscriptions" OnClick="NewSubscription" title="New subscription" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.MarkEmailRead" OnClick="MarkAsRead" Disabled="@(SelectedFeed is null)" title="Mark items read" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Update" OnClick="UpdateAll" title="Update all" />
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.DownloadForOffline" OnClick="EditDownloadRules" title="Edit auto downloading rules" />
|
||||
</MudToolBar>
|
||||
|
||||
<MudContainer MaxWidth="MaxWidth.ExtraExtraLarge">
|
||||
<MudGrid Class="rss-contents">
|
||||
<MudItem xs="4" Style="height: 100%">
|
||||
<MudList T="string" SelectionMode="SelectionMode.SingleSelection" SelectedValue="SelectedFeed" SelectedValueChanged="SelectedFeedChanged" Dense>
|
||||
<MudListItem Icon="@Icons.Material.Filled.MarkEmailUnread" Text="@($"Unread ({UnreadCount})")" Value="@("unread")" />
|
||||
@foreach (var (key, feed) in Feeds)
|
||||
{
|
||||
<MudListItem Icon="@(feed.IsLoading ? Icons.Material.Filled.Sync : Icons.Material.Filled.Wifi)" Class="@(feed.IsLoading ? "spin-animation" : "")" Text="@($"{feed.Title} ({feed.UnreadCount})")" Value="@key" />
|
||||
}
|
||||
</MudList>
|
||||
</MudItem>
|
||||
<MudItem xs="4" Style="height: 100%; overflow: auto">
|
||||
@if (Articles.Count > 0)
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudList T="string" SelectionMode="SelectionMode.SingleSelection" SelectedValue="SelectedArticle" SelectedValueChanged="SelectedArticleChanged" Dense>
|
||||
@foreach (var article in Articles)
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">RSS</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Subscriptions" OnClick="NewSubscription" title="New subscription" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.MarkEmailRead" OnClick="MarkAsRead" Disabled="@(SelectedFeed is null)" title="Mark items read" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Update" OnClick="UpdateAll" title="Update all" />
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.DownloadForOffline" OnClick="EditDownloadRules" title="Edit auto downloading rules" />
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
<div class="content-panel__body">
|
||||
<MudContainer MaxWidth="MaxWidth.ExtraExtraLarge" Class="content-panel__container">
|
||||
<MudGrid Class="rss-contents">
|
||||
<MudItem xs="4" Style="height: 100%">
|
||||
<MudList T="string" SelectionMode="SelectionMode.SingleSelection" SelectedValue="SelectedFeed" SelectedValueChanged="SelectedFeedChanged" Dense>
|
||||
<MudListItem Icon="@Icons.Material.Filled.MarkEmailUnread" Text="@($"Unread ({UnreadCount})")" Value="@("unread")" />
|
||||
@foreach (var (key, feed) in Feeds)
|
||||
{
|
||||
<MudListItem Icon="@(feed.IsLoading ? Icons.Material.Filled.Sync : Icons.Material.Filled.Wifi)" Class="@(feed.IsLoading ? "spin-animation" : "")" Text="@($"{feed.Title} ({feed.UnreadCount})")" Value="@key" />
|
||||
}
|
||||
</MudList>
|
||||
</MudItem>
|
||||
<MudItem xs="4" Style="height: 100%; overflow: auto">
|
||||
@if (Articles.Count > 0)
|
||||
{
|
||||
<MudListItem Text="@article.Title" Value="article.Id" Icon="@Icons.Material.Filled.Check" IconColor="@(article.IsRead ? Color.Success : Color.Transparent)" />
|
||||
<MudList T="string" SelectionMode="SelectionMode.SingleSelection" SelectedValue="SelectedArticle" SelectedValueChanged="SelectedArticleChanged" Dense>
|
||||
@foreach (var article in Articles)
|
||||
{
|
||||
<MudListItem Text="@article.Title" Value="article.Id" Icon="@Icons.Material.Filled.Check" IconColor="@(article.IsRead ? Color.Success : Color.Transparent)" />
|
||||
}
|
||||
</MudList>
|
||||
}
|
||||
</MudList>
|
||||
}
|
||||
else
|
||||
{
|
||||
<MudSkeleton SkeletonType="SkeletonType.Rectangle" Height="100%" Animation="Animation.False" Width="100%" />
|
||||
}
|
||||
</MudItem>
|
||||
<MudItem xs="4" Style="height: 100%">
|
||||
@if (Article is not null)
|
||||
{
|
||||
<MudCard>
|
||||
<MudCardHeader>
|
||||
<CardHeaderContent>
|
||||
<MudText Typo="Typo.h6" Style="overflow-wrap: anywhere">@Article.Title</MudText>
|
||||
</CardHeaderContent>
|
||||
<CardHeaderActions>
|
||||
<MudMenu Icon="@Icons.Material.Filled.MoreVert" Dense>
|
||||
<MudMenuItem Icon="@Icons.Material.Filled.Download" OnClick="c => DownloadItem(Article.TorrentURL)" title="Download">Download</MudMenuItem>
|
||||
<MudMenuItem Icon="@Icons.Material.Filled.Link" Href="@Article.TorrentURL" Target="@Article.TorrentURL" title="Download">Open torrent URL</MudMenuItem>
|
||||
</MudMenu>
|
||||
</CardHeaderActions>
|
||||
</MudCardHeader>
|
||||
else
|
||||
{
|
||||
<MudSkeleton SkeletonType="SkeletonType.Rectangle" Height="100%" Animation="Animation.False" Width="100%" />
|
||||
}
|
||||
</MudItem>
|
||||
<MudItem xs="4" Style="height: 100%">
|
||||
@if (Article is not null)
|
||||
{
|
||||
<MudCard>
|
||||
<MudCardHeader>
|
||||
<CardHeaderContent>
|
||||
<MudText Typo="Typo.h6" Style="overflow-wrap: anywhere">@Article.Title</MudText>
|
||||
</CardHeaderContent>
|
||||
<CardHeaderActions>
|
||||
<MudMenu Icon="@Icons.Material.Filled.MoreVert" Dense>
|
||||
<MudMenuItem Icon="@Icons.Material.Filled.Download" OnClick="c => DownloadItem(Article.TorrentURL)" title="Download">Download</MudMenuItem>
|
||||
<MudMenuItem Icon="@Icons.Material.Filled.Link" Href="@Article.TorrentURL" Target="@Article.TorrentURL" title="Download">Open torrent URL</MudMenuItem>
|
||||
</MudMenu>
|
||||
</CardHeaderActions>
|
||||
</MudCardHeader>
|
||||
|
||||
<MudCardContent>
|
||||
<MudText Typo="Typo.subtitle2">@Article.Date</MudText>
|
||||
<MudText Typo="Typo.body1">@Article.Description</MudText>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
}
|
||||
else
|
||||
{
|
||||
<MudSkeleton SkeletonType="SkeletonType.Rectangle" Height="100%" Animation="Animation.False" Width="100%" />
|
||||
}
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</MudContainer>
|
||||
<MudCardContent>
|
||||
<MudText Typo="Typo.subtitle2">@Article.Date</MudText>
|
||||
<MudText Typo="Typo.body1">@Article.Description</MudText>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
}
|
||||
else
|
||||
{
|
||||
<MudSkeleton SkeletonType="SkeletonType.Rectangle" Height="100%" Animation="Animation.False" Width="100%" />
|
||||
}
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</MudContainer>
|
||||
</div>
|
||||
</div>
|
@@ -1,62 +1,67 @@
|
||||
@page "/search"
|
||||
@layout OtherLayout
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">Search</MudText>
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">Search</MudText>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
<div class="content-panel__body">
|
||||
<MudCard Elevation="1" Class="ml-4 mr-4 mb-4">
|
||||
<MudCardContent>
|
||||
<EditForm Model="Model" OnValidSubmit="DoSearch">
|
||||
<MudGrid>
|
||||
<MudItem xs="12" md="4">
|
||||
<MudTextField T="string" Label="Criteria" @bind-Value="Model.SearchText" Variant="Variant.Outlined" />
|
||||
</MudItem>
|
||||
<MudItem xs="12" md="3">
|
||||
<MudSelect T="string" Label="Categories" @bind-Value="Model.SelectedCategory" Variant="Variant.Outlined">
|
||||
@foreach (var (value, name) in Categories)
|
||||
{
|
||||
<MudSelectItem Value="value">@name</MudSelectItem>
|
||||
if (value == "all")
|
||||
{
|
||||
<MudDivider />
|
||||
}
|
||||
}
|
||||
</MudSelect>
|
||||
</MudItem>
|
||||
<MudItem xs="12" md="3">
|
||||
<MudSelect T="string" Label="Plugins" @bind-Value="Model.SelectedPlugin" Variant="Variant.Outlined">
|
||||
<MudSelectItem Value="@("all")">All</MudSelectItem>
|
||||
@if (Plugins.Count > 0)
|
||||
{
|
||||
<MudDivider />
|
||||
|
||||
<MudCard Elevation="1" Class="ml-4 mr-4 mb-4">
|
||||
<MudCardContent>
|
||||
<EditForm Model="Model" OnValidSubmit="DoSearch">
|
||||
<MudGrid>
|
||||
<MudItem xs="12" md="4">
|
||||
<MudTextField T="string" Label="Criteria" @bind-Value="Model.SearchText" Variant="Variant.Outlined" />
|
||||
</MudItem>
|
||||
<MudItem xs="12" md="3">
|
||||
<MudSelect T="string" Label="Categories" @bind-Value="Model.SelectedCategory" Variant="Variant.Outlined">
|
||||
@foreach (var (value, name) in Categories)
|
||||
{
|
||||
<MudSelectItem Value="value">@name</MudSelectItem>
|
||||
if (value == "all")
|
||||
{
|
||||
<MudDivider />
|
||||
}
|
||||
}
|
||||
</MudSelect>
|
||||
</MudItem>
|
||||
<MudItem xs="12" md="3">
|
||||
<MudSelect T="string" Label="Plugins" @bind-Value="Model.SelectedPlugin" Variant="Variant.Outlined">
|
||||
<MudSelectItem Value="@("all")">All</MudSelectItem>
|
||||
@if (Plugins.Count > 0)
|
||||
{
|
||||
<MudDivider />
|
||||
}
|
||||
@foreach (var (value, name) in Plugins)
|
||||
{
|
||||
<MudSelectItem Value="value">@name</MudSelectItem>
|
||||
}
|
||||
</MudSelect>
|
||||
</MudItem>
|
||||
<MudItem xs="12" md="2">
|
||||
<MudButton ButtonType="ButtonType.Submit" FullWidth="true" Color="Color.Primary" EndIcon="@Icons.Material.Filled.Search" Variant="Variant.Filled" Class="mt-6">@(_searchId is null ? "Search" : "Stop")</MudButton>
|
||||
</MudItem>
|
||||
|
||||
</MudGrid>
|
||||
</EditForm>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
|
||||
}
|
||||
@foreach (var (value, name) in Plugins)
|
||||
{
|
||||
<MudSelectItem Value="value">@name</MudSelectItem>
|
||||
}
|
||||
</MudSelect>
|
||||
</MudItem>
|
||||
<MudItem xs="12" md="2">
|
||||
<MudButton ButtonType="ButtonType.Submit" FullWidth="true" Color="Color.Primary" EndIcon="@Icons.Material.Filled.Search" Variant="Variant.Filled" Class="mt-6">@(_searchId is null ? "Search" : "Stop")</MudButton>
|
||||
</MudItem>
|
||||
|
||||
</MudGrid>
|
||||
</EditForm>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
|
||||
<DynamicTable @ref="Table"
|
||||
T="Lantean.QBitTorrentClient.Models.SearchResult"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
Class="search-list" />
|
||||
<DynamicTable @ref="Table"
|
||||
T="Lantean.QBitTorrentClient.Models.SearchResult"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
Class="search-list content-panel__table" />
|
||||
</div>
|
||||
</div>
|
@@ -1,62 +1,68 @@
|
||||
@page "/statistics"
|
||||
@layout OtherLayout
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">Statistics</MudText>
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudDivider Vertical="true" />
|
||||
<MudText Class="pl-5 no-wrap">Statistics</MudText>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
<MudContainer MaxWidth="MaxWidth.ExtraExtraLarge" Class="details-tab-contents">
|
||||
<MudText Typo="Typo.subtitle2" Class="pt-6">User statistics</MudText>
|
||||
<MudGrid>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="All-time uploaded">@DisplayHelpers.Size(ServerState?.AllTimeUploaded)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="All-time downloaded">@DisplayHelpers.Size(ServerState?.AllTimeDownloaded)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="All-time share ratio">@DisplayHelpers.EmptyIfNull(ServerState?.GlobalRatio, format: "0.00")</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Session waste">@DisplayHelpers.Size(ServerState?.TotalWastedSession)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Connected peers">@DisplayHelpers.EmptyIfNull(ServerState?.TotalPeerConnections)</MudField>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
<div class="content-panel__body">
|
||||
<MudContainer MaxWidth="MaxWidth.ExtraExtraLarge" Class="details-tab-contents content-panel__container">
|
||||
<MudText Typo="Typo.subtitle2" Class="pt-6">User statistics</MudText>
|
||||
<MudGrid>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="All-time uploaded">@DisplayHelpers.Size(ServerState?.AllTimeUploaded)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="All-time downloaded">@DisplayHelpers.Size(ServerState?.AllTimeDownloaded)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="All-time share ratio">@DisplayHelpers.EmptyIfNull(ServerState?.GlobalRatio, format: "0.00")</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Session waste">@DisplayHelpers.Size(ServerState?.TotalWastedSession)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Connected peers">@DisplayHelpers.EmptyIfNull(ServerState?.TotalPeerConnections)</MudField>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
|
||||
<MudText Typo="Typo.subtitle2" Class="pt-6">Cache statistics</MudText>
|
||||
<MudGrid>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Read cache hits">@DisplayHelpers.Percentage(ServerState?.ReadCacheHits)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Total buffer size">@DisplayHelpers.Size(ServerState?.TotalBuffersSize)</MudField>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
<MudText Typo="Typo.subtitle2" Class="pt-6">Cache statistics</MudText>
|
||||
<MudGrid>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Read cache hits">@DisplayHelpers.Percentage(ServerState?.ReadCacheHits)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Total buffer size">@DisplayHelpers.Size(ServerState?.TotalBuffersSize)</MudField>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
|
||||
<MudText Typo="Typo.subtitle2" Class="pt-6">Performance statistics</MudText>
|
||||
<MudGrid>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Write cache overload">@DisplayHelpers.Percentage(ServerState?.WriteCacheOverload)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Read cache overload">@DisplayHelpers.Percentage(ServerState?.ReadCacheOverload)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Queued I/O jobs">@DisplayHelpers.EmptyIfNull(ServerState?.QueuedIOJobs)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Average time in queue">@DisplayHelpers.EmptyIfNull(ServerState?.AverageTimeQueue, suffix: "ms")</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Total queued size">@DisplayHelpers.Size(ServerState?.TotalQueuedSize)</MudField>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</MudContainer>
|
||||
<MudText Typo="Typo.subtitle2" Class="pt-6">Performance statistics</MudText>
|
||||
<MudGrid>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Write cache overload">@DisplayHelpers.Percentage(ServerState?.WriteCacheOverload)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Read cache overload">@DisplayHelpers.Percentage(ServerState?.ReadCacheOverload)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Queued I/O jobs">@DisplayHelpers.EmptyIfNull(ServerState?.QueuedIOJobs)</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Average time in queue">@DisplayHelpers.EmptyIfNull(ServerState?.AverageTimeQueue, suffix: "ms")</MudField>
|
||||
</MudItem>
|
||||
<MudItem xs="12">
|
||||
<MudField Label="Total queued size">@DisplayHelpers.Size(ServerState?.TotalQueuedSize)</MudField>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</MudContainer>
|
||||
</div>
|
||||
</div>
|
@@ -1,24 +1,30 @@
|
||||
@page "/tags"
|
||||
@layout OtherLayout
|
||||
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">Tags</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Filled.NewLabel" OnClick="AddTag" title="Add Tag" />
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
@if (!DrawerOpen)
|
||||
{
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.NavigateBefore" OnClick="NavigateBack" title="Back to torrent list" />
|
||||
<MudDivider Vertical="true" />
|
||||
}
|
||||
<MudText Class="px-5 no-wrap">Tags</MudText>
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Filled.NewLabel" OnClick="AddTag" title="Add Tag" />
|
||||
</MudToolBar>
|
||||
</div>
|
||||
|
||||
<DynamicTable @ref="Table"
|
||||
T="string"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
Class="details-list" />
|
||||
<div class="content-panel__body">
|
||||
<DynamicTable @ref="Table"
|
||||
T="string"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Results"
|
||||
MultiSelection="false"
|
||||
SelectOnRowClick="false"
|
||||
Class="details-list content-panel__table" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@code {
|
||||
private RenderFragment<RowContext<string>> ActionsColumn
|
||||
|
@@ -7,38 +7,41 @@
|
||||
<TorrentActions RenderType="RenderType.MenuItems" Hashes="GetContextMenuTargetHashes()" PrimaryHash="@(ContextMenuItem?.Hash)" Torrents="MainData.Torrents" Preferences="Preferences" />
|
||||
</MudMenu>
|
||||
|
||||
<div style="overflow-x: auto; white-space: nowrap; width: 100%;">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.AddLink" OnClick="AddTorrentLink" title="Add torrent link" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.AddCircle" OnClick="AddTorrentFile" title="Add torrent file" />
|
||||
<MudDivider Vertical="true" />
|
||||
<TorrentActions RenderType="RenderType.InitialIconsOnly" Hashes="GetSelectedTorrentsHashes()" Torrents="MainData.Torrents" Preferences="Preferences" />
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Info" Color="Color.Inherit" Disabled="@(!ToolbarButtonsEnabled)" OnClick="ShowTorrentToolbar" title="View torrent details" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.ViewColumn" Color="Color.Inherit" OnClick="ColumnOptions" title="Choose Columns" />
|
||||
<MudSpacer />
|
||||
<MudTextField Value="SearchText" TextChanged="SearchTextChanged" Immediate="true" DebounceInterval="1000" Placeholder="Filter torrent list" Adornment="Adornment.Start" AdornmentIcon="@Icons.Material.Filled.Search" IconSize="Size.Medium" Class="mt-0"></MudTextField>
|
||||
</MudToolBar>
|
||||
<div class="content-panel">
|
||||
<div class="content-panel__toolbar content-panel__toolbar--scroll">
|
||||
<MudToolBar Gutters="false" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.AddLink" OnClick="AddTorrentLink" title="Add torrent link" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.AddCircle" OnClick="AddTorrentFile" title="Add torrent file" />
|
||||
<MudDivider Vertical="true" />
|
||||
<TorrentActions RenderType="RenderType.InitialIconsOnly" Hashes="GetSelectedTorrentsHashes()" Torrents="MainData.Torrents" Preferences="Preferences" />
|
||||
<MudDivider Vertical="true" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Info" Color="Color.Inherit" Disabled="@(!ToolbarButtonsEnabled)" OnClick="ShowTorrentToolbar" title="View torrent details" />
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.ViewColumn" Color="Color.Inherit" OnClick="ColumnOptions" title="Choose Columns" />
|
||||
<MudSpacer />
|
||||
<MudTextField Value="SearchText" TextChanged="SearchTextChanged" Immediate="true" DebounceInterval="1000" Placeholder="Filter torrent list" Adornment="Adornment.Start" AdornmentIcon="@Icons.Material.Filled.Search" IconSize="Size.Medium" Class="mt-0"></MudTextField>
|
||||
</MudToolBar>
|
||||
</div>
|
||||
<div class="content-panel__body">
|
||||
<MudContainer MaxWidth="MaxWidth.ExtraExtraLarge" Class="ma-0 pa-0 content-panel__container">
|
||||
<DynamicTable
|
||||
@ref="Table"
|
||||
T="Torrent"
|
||||
Class="torrent-list content-panel__table"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Torrents"
|
||||
OnRowClick="RowClick"
|
||||
MultiSelection="true"
|
||||
SelectOnRowClick="true"
|
||||
SelectedItemsChanged="SelectedItemsChanged"
|
||||
SortColumnChanged="SortColumnChangedHandler"
|
||||
SortDirectionChanged="SortDirectionChangedHandler"
|
||||
OnTableDataContextMenu="TableDataContextMenu"
|
||||
OnTableDataLongPress="TableDataLongPress"
|
||||
/>
|
||||
</MudContainer>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<MudContainer MaxWidth="MaxWidth.ExtraExtraLarge" Class="ma-0 pa-0">
|
||||
<DynamicTable
|
||||
@ref="Table"
|
||||
T="Torrent"
|
||||
Class="torrent-list"
|
||||
ColumnDefinitions="Columns"
|
||||
Items="Torrents"
|
||||
OnRowClick="RowClick"
|
||||
MultiSelection="true"
|
||||
SelectOnRowClick="true"
|
||||
SelectedItemsChanged="SelectedItemsChanged"
|
||||
SortColumnChanged="SortColumnChangedHandler"
|
||||
SortDirectionChanged="SortDirectionChangedHandler"
|
||||
OnTableDataContextMenu="TableDataContextMenu"
|
||||
OnTableDataLongPress="TableDataLongPress"
|
||||
/>
|
||||
</MudContainer>
|
||||
|
||||
@code {
|
||||
private static RenderFragment<RowContext<Torrent>> ProgressBarColumn
|
||||
{
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#blazor-error-ui {
|
||||
#blazor-error-ui {
|
||||
background: lightyellow;
|
||||
bottom: 0;
|
||||
box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
|
||||
@@ -65,15 +65,16 @@ code {
|
||||
}
|
||||
|
||||
.mud-appbar.mud-appbar-fixed-bottom {
|
||||
height: 35px;
|
||||
height: var(--app-status-bar-height);
|
||||
}
|
||||
|
||||
.mud-main-content {
|
||||
padding-bottom: 35px;
|
||||
padding: var(--mud-appbar-height) 0 var(--app-status-bar-height);
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.mud-drawer-fixed.mud-drawer-mini.mud-drawer-clipped-always, .mud-drawer-fixed.mud-drawer-persistent:not(.mud-drawer-clipped-never), .mud-drawer-fixed.mud-drawer-responsive.mud-drawer-clipped-always, .mud-drawer-fixed.mud-drawer-temporary.mud-drawer-clipped-always {
|
||||
height: calc(100% - var(--mud-appbar-height) - 35px);
|
||||
height: calc(100% - var(--mud-appbar-height) - var(--app-status-bar-height));
|
||||
}
|
||||
|
||||
.w-100 {
|
||||
@@ -154,25 +155,68 @@ code {
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
.torrent-list .mud-table-container {
|
||||
height: calc(100vh - 160px);
|
||||
/*. Layout helpers */
|
||||
.content-panel {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
.file-list .mud-table-container {
|
||||
height: calc(100vh - 245px);
|
||||
.content-panel__toolbar {
|
||||
flex: 0 0 auto;
|
||||
}
|
||||
|
||||
.details-list .mud-table-container {
|
||||
height: calc(100vh - 200px);
|
||||
.content-panel__toolbar--scroll {
|
||||
overflow-x: auto;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.details-tab-contents {
|
||||
height: calc(100vh - 200px);
|
||||
overflow: auto;
|
||||
.content-panel__body {
|
||||
flex: 1 1 auto;
|
||||
min-height: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.content-panel__container {
|
||||
flex: 1 1 auto;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
.content-panel__table {
|
||||
flex: 1 1 auto;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
.content-panel__table .mud-table-container {
|
||||
flex: 1 1 auto;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.content-panel__body > .mud-tabs { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
|
||||
.content-panel__body > .mud-tabs .mud-tabs-panels { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
|
||||
.content-panel__body > .mud-tabs .mud-tab-panel { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
|
||||
.content-panel__body > .mud-tabs .mud-tab-panel > .mud-tab-panel-content { flex: 1 1 auto; min-height: 0; overflow: auto; }
|
||||
|
||||
.torrent-list .mud-table-container,
|
||||
.file-list .mud-table-container,
|
||||
.details-list .mud-table-container,
|
||||
.search-list .mud-table-container {
|
||||
height: calc(100vh - 260px);
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.details-tab-contents,
|
||||
.options-tab-contents,
|
||||
.rss-contents {
|
||||
flex: 1 1 auto;
|
||||
min-height: 0;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
tr.log-normal td {
|
||||
@@ -220,10 +264,6 @@ td .folder-button {
|
||||
padding: 6px 16px 6px 16px !important;
|
||||
}
|
||||
|
||||
.rss-contents {
|
||||
height: calc(100vh - 149px);
|
||||
}
|
||||
|
||||
@keyframes spin {
|
||||
0% {
|
||||
transform: rotate(0deg);
|
||||
@@ -255,4 +295,74 @@ td .folder-button {
|
||||
|
||||
.mud-popover .mud-divider:last-child {
|
||||
display: none;
|
||||
}
|
||||
:root {
|
||||
--app-viewport-height: 100vh;
|
||||
--app-status-bar-height: 35px;
|
||||
}
|
||||
|
||||
@supports (height: 100dvh) {
|
||||
:root {
|
||||
--app-viewport-height: 100dvh;
|
||||
}
|
||||
}
|
||||
|
||||
html,
|
||||
body {
|
||||
height: var(--app-viewport-height);
|
||||
min-height: var(--app-viewport-height);
|
||||
}
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
overflow: hidden;
|
||||
overscroll-behavior: none;
|
||||
}
|
||||
|
||||
#app,
|
||||
.mud-layout {
|
||||
height: 100%;
|
||||
min-height: 100%;
|
||||
}
|
||||
|
||||
.app-shell {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
min-height: 0;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.app-shell__body {
|
||||
display: flex;
|
||||
flex: 1 1 auto;
|
||||
min-height: 0;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.app-shell__sidebar {
|
||||
flex: 0 0 auto;
|
||||
}
|
||||
|
||||
.app-shell__main {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex: 1 1 auto;
|
||||
min-height: 0;
|
||||
overflow: hidden;
|
||||
padding: var(--mud-appbar-height) 0 var(--app-status-bar-height);
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.app-shell__status-bar.mud-appbar {
|
||||
flex: 0 0 var(--app-status-bar-height);
|
||||
height: var(--app-status-bar-height);
|
||||
width: 100%;
|
||||
background-color: var(--mud-palette-dark-lighten);
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.app-shell__status-bar .mud-toolbar {
|
||||
width: 100%;
|
||||
}
|
Reference in New Issue
Block a user