Agent Tests for API, MAUI, and Slop Features
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
@inject IGlossaryService glossaryService
|
||||
@inject IGlossaryDialogService glossaryDialogService
|
||||
|
||||
@if (TermId == null)
|
||||
{
|
||||
<span>Missing term</span>
|
||||
}
|
||||
else
|
||||
{
|
||||
var term = glossaryService.GetTerm(TermId);
|
||||
if (term != null)
|
||||
{
|
||||
<button class="glossaryLabel @term.Category.ToLowerInvariant()" @onclick="TermLabelClicked"
|
||||
title="@term.ShortDefinition">
|
||||
@term.Term
|
||||
</button>
|
||||
}
|
||||
}
|
||||
|
||||
@code {
|
||||
|
||||
[Parameter] public string TermId { get; set; } = default!;
|
||||
|
||||
void TermLabelClicked()
|
||||
{
|
||||
glossaryDialogService.AddDialog(TermId);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user