Improved naming

This commit is contained in:
Thorsten Sommer 2024-08-21 08:06:23 +02:00
parent e751a22bd2
commit 040e32b05b
Signed by: tsommer
GPG Key ID: 371BBA77A02C0108
3 changed files with 3 additions and 3 deletions

View File

@ -22,7 +22,7 @@
{ {
<MudProgressLinear Color="Color.Primary" Indeterminate="true" Class="mb-6" /> <MudProgressLinear Color="Color.Primary" Indeterminate="true" Class="mb-6" />
} }
<div id="@ASSISTANT_RESULT_DIV_ID" class="mr-2 mt-3"> <div id="@RESULT_DIV_ID" class="mr-2 mt-3">
@if (this.ShowResult && this.resultingContentBlock is not null) @if (this.ShowResult && this.resultingContentBlock is not null)
{ {
<ContentBlockComponent Role="@(this.resultingContentBlock.Role)" Type="@(this.resultingContentBlock.ContentType)" Time="@(this.resultingContentBlock.Time)" Content="@(this.resultingContentBlock.Content)"/> <ContentBlockComponent Role="@(this.resultingContentBlock.Role)" Type="@(this.resultingContentBlock.ContentType)" Time="@(this.resultingContentBlock.Time)" Content="@(this.resultingContentBlock.Content)"/>

View File

@ -28,7 +28,7 @@ public abstract partial class AssistantBase : ComponentBase
protected NavigationManager NavigationManager { get; init; } = null!; protected NavigationManager NavigationManager { get; init; } = null!;
internal const string AFTER_RESULT_DIV_ID = "afterAssistantResult"; internal const string AFTER_RESULT_DIV_ID = "afterAssistantResult";
internal const string ASSISTANT_RESULT_DIV_ID = "assistantResult"; internal const string RESULT_DIV_ID = "assistantResult";
protected abstract string Title { get; } protected abstract string Title { get; }

View File

@ -6,7 +6,7 @@ public static class JsRuntimeExtensions
{ {
public static async Task GenerateAndShowDiff(this IJSRuntime jsRuntime, string text1, string text2) public static async Task GenerateAndShowDiff(this IJSRuntime jsRuntime, string text1, string text2)
{ {
await jsRuntime.InvokeVoidAsync("generateDiff", text1, text2, AssistantBase.ASSISTANT_RESULT_DIV_ID, AssistantBase.AFTER_RESULT_DIV_ID); await jsRuntime.InvokeVoidAsync("generateDiff", text1, text2, AssistantBase.RESULT_DIV_ID, AssistantBase.AFTER_RESULT_DIV_ID);
} }
public static async Task ClearDiv(this IJSRuntime jsRuntime, string divId) public static async Task ClearDiv(this IJSRuntime jsRuntime, string divId)