Skip to content

Commit

Permalink
Update ChatMessage.razor
Browse files Browse the repository at this point in the history
  • Loading branch information
BeepBeepBopBop committed Nov 29, 2024
1 parent c63c19e commit aaf4a33
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions LM-Kit-Maestro/UI/Razor/Components/ChatMessage.razor
Original file line number Diff line number Diff line change
Expand Up @@ -25,43 +25,43 @@
{


<div class="messageFooter @(MessageJustTerminated ? "show" : "hide")">
<div class="messageFooterContent @(MessageViewModel.Sender == MessageSender.User ? "userMessageFooterContent" : "")">
<div class="messageFooter @(MessageJustTerminated ? "show" : "hide")">
<div class="messageFooterContent @(MessageViewModel.Sender == MessageSender.User ? "userMessageFooterContent" : "")">
@if (HasMultipleResponses)
{
<button @onclick="OnPreviousResponseButtonClicked" class="chatActionButton material-icons">
chevron_left
</button>
<button @onclick="OnPreviousResponseButtonClicked" class="chatActionButton material-icons">
chevron_left
</button>

<span class="messageFooterText">
<span class="messageFooterText">
@($"{responseIndex + 1} / {MessageViewModel.PreviousContent.Count + 1}")
</span>
</span>

<button @onclick="OnNextResponseButtonClicked" class="chatActionButton material-icons">
chevron_right
</button>
<button @onclick="OnNextResponseButtonClicked" class="chatActionButton material-icons">
chevron_right
</button>
}

<button @onclick="OnCopyMessageButtonClicked" class="chatActionButton material-icons">
<button @onclick="OnCopyMessageButtonClicked" class="chatActionButton material-icons">
@(MessageJustCopied ? "check" : "content_copy")
</button>
</button>

@if (MessageViewModel.Sender == MessageSender.Assistant)
{
<button @onclick="OnRegenerateResponseButtonClicked" class="chatActionButton material-icons">
sync
</button>
<button @onclick="OnRegenerateResponseButtonClicked" class="chatActionButton material-icons">
sync
</button>

@if (MessageViewModel.TerminationReason != LMKit.TextGeneration.TextGenerationResult.StopReason.Unknown)
{
<span class="assistantResponseInfo messageFooterText">
<span class="assistantResponseInfo messageFooterText">
@($"{MessageViewModel.GeneratedTokens} tokens • Termination reason: {MessageViewModel.TerminationReason}")
</span>
</span>

}
}
</div>
</div>
</div>
</div>
}

</div>
Expand Down

0 comments on commit aaf4a33

Please sign in to comment.