@page "/console"
@using System.Collections.Concurrent
@implements IDisposable

<h3>@Localizer["Title"]</h3>

<h4>@Localizer["Description"]</h4>

<DemoBlock Title="@Localizer["NormalTitle"]" Introduction="@Localizer["NormalIntro"]" Name="Normal">
    <Console Items="@Messages" Height="126" IsAutoScroll="false" />
</DemoBlock>

<DemoBlock Title="@Localizer["ColorTitle"]" Introduction="@Localizer["ColorIntro"]" Name="Color">
    <Console Items="@ColorMessages" Height="126" />
</DemoBlock>

<DemoBlock Title="@Localizer["IsAutoScrollTitle"]" Introduction="@Localizer["IsAutoScrollIntro"]" Name="IsAutoScroll">
    <p class="mt-3">@((MarkupString)Localizer["IsAutoScrollDescription"].Value)</p>
    <Console Items="@Messages" Height="126" IsAutoScroll="true" />
</DemoBlock>

<DemoBlock Title="@Localizer["OnClearTitle"]" Introduction="@Localizer["OnClearIntro"]" Name="OnClear">
    <Console Items="@Messages" Height="126" OnClear="@OnClear" />
</DemoBlock>

<DemoBlock Title="@Localizer["ShowAutoScrollTitle"]" Introduction="@Localizer["ShowAutoScrollIntro"]" Name="ShowAutoScroll">
    <p>@((MarkupString)Localizer["ShowAutoScrollDescription"].Value)</p>
    <Console Items="@Messages" Height="126" ShowAutoScroll="true" OnClear="@OnClear" />
</DemoBlock>

<AttributeTable Items="@GetAttributes()" />

<AttributeTable Items="@GetItemAttributes()" Title="@Localizer["ConsoleMessageItem"]" />
