mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2025-05-03 06:39:47 +00:00
Added more options for showing / hiding footer actions
This commit is contained in:
parent
c910d1d78b
commit
0e2fe757a8
@ -47,6 +47,8 @@
|
|||||||
<MudStack Row="@true" Wrap="Wrap.Wrap" Class="ma-1">
|
<MudStack Row="@true" Wrap="Wrap.Wrap" Class="ma-1">
|
||||||
|
|
||||||
@if (!this.FooterButtons.Any(x => x.Type is ButtonTypes.SEND_TO))
|
@if (!this.FooterButtons.Any(x => x.Type is ButtonTypes.SEND_TO))
|
||||||
|
{
|
||||||
|
@if (this.ShowSendTo)
|
||||||
{
|
{
|
||||||
<MudMenu StartIcon="@Icons.Material.Filled.Apps" EndIcon="@Icons.Material.Filled.KeyboardArrowDown" Label="Send to ..." Variant="Variant.Filled" Style="@this.GetSendToColor()" Class="rounded">
|
<MudMenu StartIcon="@Icons.Material.Filled.Apps" EndIcon="@Icons.Material.Filled.KeyboardArrowDown" Label="Send to ..." Variant="Variant.Filled" Style="@this.GetSendToColor()" Class="rounded">
|
||||||
@foreach (var assistant in Enum.GetValues<Components>().OrderBy(n => n.Name().Length))
|
@foreach (var assistant in Enum.GetValues<Components>().OrderBy(n => n.Name().Length))
|
||||||
@ -60,6 +62,7 @@
|
|||||||
}
|
}
|
||||||
</MudMenu>
|
</MudMenu>
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@foreach (var button in this.FooterButtons)
|
@foreach (var button in this.FooterButtons)
|
||||||
{
|
{
|
||||||
@ -95,13 +98,19 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@if (this.ShowCopyResult)
|
||||||
|
{
|
||||||
<MudButton Variant="Variant.Filled" StartIcon="@Icons.Material.Filled.ContentCopy" OnClick="() => this.CopyToClipboard()">
|
<MudButton Variant="Variant.Filled" StartIcon="@Icons.Material.Filled.ContentCopy" OnClick="() => this.CopyToClipboard()">
|
||||||
Copy result
|
Copy result
|
||||||
</MudButton>
|
</MudButton>
|
||||||
|
}
|
||||||
|
|
||||||
|
@if (this.ShowReset)
|
||||||
|
{
|
||||||
<MudButton Variant="Variant.Filled" Style="@this.GetResetColor()" StartIcon="@Icons.Material.Filled.Refresh" OnClick="() => this.InnerResetForm()">
|
<MudButton Variant="Variant.Filled" Style="@this.GetResetColor()" StartIcon="@Icons.Material.Filled.Refresh" OnClick="() => this.InnerResetForm()">
|
||||||
Reset
|
Reset
|
||||||
</MudButton>
|
</MudButton>
|
||||||
|
}
|
||||||
|
|
||||||
@if (this.SettingsManager.ConfigurationData.LLMProviders.ShowProviderConfidence)
|
@if (this.SettingsManager.ConfigurationData.LLMProviders.ShowProviderConfidence)
|
||||||
{
|
{
|
||||||
|
@ -75,6 +75,12 @@ public abstract partial class AssistantBase : ComponentBase, IMessageBusReceiver
|
|||||||
|
|
||||||
protected virtual bool ShowDedicatedProgress => false;
|
protected virtual bool ShowDedicatedProgress => false;
|
||||||
|
|
||||||
|
protected virtual bool ShowSendTo => true;
|
||||||
|
|
||||||
|
protected virtual bool ShowCopyResult => true;
|
||||||
|
|
||||||
|
protected virtual bool ShowReset => true;
|
||||||
|
|
||||||
protected virtual ChatThread ConvertToChatThread => this.chatThread ?? new();
|
protected virtual ChatThread ConvertToChatThread => this.chatThread ?? new();
|
||||||
|
|
||||||
protected virtual IReadOnlyList<IButtonData> FooterButtons => [];
|
protected virtual IReadOnlyList<IButtonData> FooterButtons => [];
|
||||||
|
Loading…
Reference in New Issue
Block a user