Started adding archive ui

This commit is contained in:
Masu Baumgartner 2024-05-13 16:20:38 +02:00
parent 406f7cad65
commit 923a3c18b8
3 changed files with 5 additions and 2 deletions

View file

@ -57,6 +57,7 @@ public class FileManagerFeature : MoonlightFeature
await pluginService.RegisterImplementation<IFileManagerContextAction>(new DeleteContextAction());
await pluginService.RegisterImplementation<IFileManagerSelectionAction>(new MoveSelectionAction());
await pluginService.RegisterImplementation<IFileManagerSelectionAction>(new ArchiveSelectionAction());
await pluginService.RegisterImplementation<IFileManagerSelectionAction>(new DeleteSelectionAction());
await pluginService.RegisterImplementation<IFileManagerCreateAction>(new CreateFileAction());

View file

@ -95,7 +95,8 @@ else
OnEntryClicked="OnEntryClicked"
OnNavigateUpClicked="OnNavigateUpClicked"
OnSelectionChanged="OnSelectionChanged"
EnableContextMenu="true">
EnableContextMenu="true"
ShowUploadPrompt="true">
<ContextMenuTemplate>
@foreach (var action in ContextActions)
{

View file

@ -210,7 +210,7 @@
</tbody>
</table>
@if (Entries.Length == 0)
@if (Entries.Length == 0 && ShowUploadPrompt)
{
<div class="py-4">
<IconAlert Color="primary" Title="No files and folders found" Icon="bx-cloud-upload">
@ -240,6 +240,7 @@
[Parameter] public bool ShowDate { get; set; } = true;
[Parameter] public bool ShowSelect { get; set; } = true;
[Parameter] public bool ShowNavigateUp { get; set; } = true;
[Parameter] public bool ShowUploadPrompt { get; set; } = false;
[Parameter] public RenderFragment<FileEntry>? ContextMenuTemplate { get; set; }
[Parameter] public bool EnableContextMenu { get; set; } = false;