Improved formatting

This commit is contained in:
Thorsten Sommer 2025-08-09 21:22:43 +02:00
parent c9dd01a1ec
commit 0e9b9770b3
Signed by: tsommer
GPG Key ID: 371BBA77A02C0108
2 changed files with 3 additions and 10 deletions

View File

@ -1,6 +1,3 @@
@using AIStudio.Chat <MudTooltip Text="@this.TooltipMessage" Placement="Placement.Bottom">
<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="Size.Small"
OnClick="@(() => HandleCopyClick())"/>
</MudTooltip> </MudTooltip>

View File

@ -32,7 +32,7 @@ public partial class MudCopyClipboardButton : ComponentBase
/// The tooltip that should be shown to the user. /// The tooltip that should be shown to the user.
/// </summary> /// </summary>
[Parameter] [Parameter]
public string ToolTipMessage { get; set; } = TB("Copies the content to the clipboard"); public string TooltipMessage { get; set; } = TB("Copies the content to the clipboard");
[Inject] [Inject]
private ISnackbar Snackbar { get; init; } = null!; private ISnackbar Snackbar { get; init; } = null!;
@ -43,13 +43,9 @@ public partial class MudCopyClipboardButton : ComponentBase
private async Task HandleCopyClick() private async Task HandleCopyClick()
{ {
if (this.Type == ContentType.NONE) if (this.Type == ContentType.NONE)
{
await this.CopyToClipboard(this.StringContent); await this.CopyToClipboard(this.StringContent);
}
else else
{
await this.CopyToClipboard(this.Content!); await this.CopyToClipboard(this.Content!);
}
} }
/// <summary> /// <summary>