mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-17 13:17:59 +00:00
Unify the drop zones into one component
This commit is contained in:
19 files changed
+278
-505
No files matched your search
@@ -5,8 +5,13 @@
|
||||
@attribute [Route(Routes.PLUGINS)]
|
||||
|
||||
@* The page is its own drop target: a plugin archive may be dropped anywhere on it, and there is no
|
||||
inner zone to hand that role to. Hence the page owns the scope state instead of reading it. *@
|
||||
<DropZoneScope State="@this.dropZoneScope" Class="inner-scrolling-context">
|
||||
inner zone to hand that role to. An area which takes drops itself is that target by definition. *@
|
||||
<PathDropZone IsArea="@true"
|
||||
IdPrefix="plugins-page"
|
||||
Class="inner-scrolling-context"
|
||||
Disabled="@(() => !this.CanCatchDroppedFile())"
|
||||
OnPathsDropped="@this.ImportDroppedPluginArchiveAsync"
|
||||
Context="isDropTarget">
|
||||
<MudStack Row="true" AlignItems="AlignItems.Center" Class="mb-2">
|
||||
<MudText Typo="Typo.h3">
|
||||
@T("Plugins")
|
||||
@@ -26,7 +31,7 @@
|
||||
|
||||
<InnerScrolling>
|
||||
|
||||
<MudTable Items="@PluginFactory.AvailablePlugins" Hover="@true" GroupBy="@this.groupConfig" Class="@this.PluginTableClass">
|
||||
<MudTable Items="@PluginFactory.AvailablePlugins" Hover="@true" GroupBy="@this.groupConfig" Class="@PluginTableClass(isDropTarget)">
|
||||
<ColGroup>
|
||||
<col style="width: 2em;" />
|
||||
<col style="width: 2.1em; "/>
|
||||
@@ -155,4 +160,4 @@
|
||||
</RowTemplate>
|
||||
</MudTable>
|
||||
</InnerScrolling>
|
||||
</DropZoneScope>
|
||||
</PathDropZone>
|
||||
Reference in new issue
Block a user