@inherits ComponentBase

<TableContainer T="HostServiceEntity"
                @ref="Container"
                @bind-Search="Search"
                Title="@Title"
                Breadcrumbs="@Breadcrumbs"
                Data="LoadDataAsync">
    <Header>
        <MudTh>
            <MudTableSortLabel SortLabel="DisplayName" T="HostServiceEntity">
                Display Name
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="Name" T="HostServiceEntity">
                Name
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="StartMode" T="HostServiceEntity">
                Start
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="Delay" T="HostServiceEntity">
                Delay
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="ProcessId" T="HostServiceEntity">
                Process
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="Account" T="HostServiceEntity">
                Account
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="State" T="HostServiceEntity">
                State
            </MudTableSortLabel>
        </MudTh>
    </Header>
    <RowTemplate>
        <MudTd DataLabel="DisplayName">
                @context?.DisplayName
            </MudTd>
            <MudTd DataLabel="Name">
                @context?.Name
            </MudTd>
            <MudTd DataLabel="StartMode">
                @context?.StartMode?.ToString()
            </MudTd>
            <MudTd DataLabel="Delay">
                <MudCheckBox @bind-Checked="@context.Delay" Disabled DisableRipple />
            </MudTd>
            <MudTd DataLabel="Process Id">
                @(context?.ProcessId > 0 ? context?.ProcessId : "")
            </MudTd>
            <MudTd DataLabel="Account">
                @context?.Account
            </MudTd>
            <MudTd DataLabel="State">
                @{
                    var color = context?.State == "Running" ? Color.Success : Color.Error;
                    <MudText Color="color" Typo="Typo.inherit">@context?.State</MudText>
                }
            </MudTd>
    </RowTemplate>
</TableContainer>