29 lines
498 B
Plaintext
29 lines
498 B
Plaintext
@implements IDisposable;
|
|
|
|
@inject IGlossaryDialogService glossaryDialogService
|
|
|
|
@if (glossaryDialogService.HasDialog())
|
|
{
|
|
<GlossaryDialogComponent></GlossaryDialogComponent>
|
|
}
|
|
|
|
@code {
|
|
|
|
protected override void OnInitialized()
|
|
{
|
|
base.OnInitialized();
|
|
glossaryDialogService.Subscribe(OnUpdate);
|
|
}
|
|
|
|
void IDisposable.Dispose()
|
|
{
|
|
glossaryDialogService.Unsubscribe(OnUpdate);
|
|
}
|
|
|
|
void OnUpdate()
|
|
{
|
|
InvokeAsync(StateHasChanged);
|
|
}
|
|
|
|
}
|