mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2025-08-20 11:12:55 +00:00
Added configurable size to MudCopyClipboardButton and updated usage in ContentBlockComponent
This commit is contained in:
parent
8bec202278
commit
60f7743749
@ -1,4 +1,3 @@
|
||||
@using System.Runtime.CompilerServices
|
||||
@using AIStudio.Tools
|
||||
@using MudBlazor
|
||||
@using AIStudio.Components
|
||||
@ -40,8 +39,7 @@
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Delete" Color="Color.Error" OnClick="@this.RemoveBlock"/>
|
||||
</MudTooltip>
|
||||
}
|
||||
<MudCopyClipboardButton Content="@this.Content" Type="@this.Type"/>
|
||||
|
||||
<MudCopyClipboardButton Content="@this.Content" Type="@this.Type" Size="Size.Medium"/>
|
||||
</CardHeaderActions>
|
||||
</MudCardHeader>
|
||||
<MudCardContent>
|
||||
|
@ -1,3 +1,3 @@
|
||||
<MudTooltip Text="@this.TooltipMessage" Placement="Placement.Bottom">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.ContentCopy" Size="Size.Small" OnClick="@(() => this.HandleCopyClick())"/>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.ContentCopy" Size="@this.Size" OnClick="@(() => this.HandleCopyClick())"/>
|
||||
</MudTooltip>
|
@ -33,6 +33,12 @@ public partial class MudCopyClipboardButton : ComponentBase
|
||||
/// </summary>
|
||||
[Parameter]
|
||||
public string TooltipMessage { get; set; } = TB("Copies the content to the clipboard");
|
||||
|
||||
/// <summary>
|
||||
/// The size of the button. The default size is small.
|
||||
/// </summary>
|
||||
[Parameter]
|
||||
public Size Size { get; set; } = Size.Small;
|
||||
|
||||
[Inject]
|
||||
private ISnackbar Snackbar { get; init; } = null!;
|
||||
|
Loading…
Reference in New Issue
Block a user